query_id
stringlengths
32
32
query
stringlengths
7
29.6k
positive_passages
listlengths
1
1
negative_passages
listlengths
88
101
3f65f48576207f023567259f815109fa
Function to remove the IntroVideo and Instructions
[ { "docid": "b4f68ae8dc395a09235c93ab377d1d05", "score": "0.67402834", "text": "function removeIntro() {\n $('#intro-speach').fadeOut(\"slow\", function() {\n $('#intro-speach').empty();\n });\n}", "title": "" } ]
[ { "docid": "0220c2c7c14a426ca766c1c3f0dfca3a", "score": "0.7045807", "text": "function skipIntro(video){\n\t\n\tmodalHandler.close('introWrapper');\n\tvideo.currentTime = 0;\n\tvideo.pause();\n}", "title": "" }, { "docid": "b816a822b5121135714e68117747f71b", "score": "0.6960405", "text": "function hideIntro(){\n \n // notFound.style.display = 'none';\n \n // introEl.style.display = 'none';\n \n showMovieEl.style.display = 'block';\n\n \n}", "title": "" }, { "docid": "e088abc3b2d10b172348af2997365231", "score": "0.68001074", "text": "function IframeRemove() {\n\n videoData.isShow = false;\n videoData.isEmbbed = false;\n\n // Remove class 'ready'\n // Remove Iframe\n $video.removeClass(ns +'video-ready');\n videoData.$iframe.attr('src', 'about:blank').remove();\n }", "title": "" }, { "docid": "9b5042161e0a508d7fb6cf5555545f4f", "score": "0.6660642", "text": "function hideIntro () {\n clearTimeout(timeout)\n $(CONTAINER).remove()\n}", "title": "" }, { "docid": "f9637f1ff05fa476b0e6418c2782bd65", "score": "0.64521277", "text": "function removeIntro() {\n console.log(`removeIntro worked`);\n $('.hide').toggle();\n $('.hide').prop('hidden', false);\n $('.content-wrap').toggle();\n}", "title": "" }, { "docid": "d8d289844b091de96db97cb6d25f73fe", "score": "0.6423887", "text": "function closeIntro(e) {\n $('.intro').hide();\n }", "title": "" }, { "docid": "7b834db26d617f3ce192e110d7d935cf", "score": "0.6408679", "text": "function cerrarVideoTutorial(){\n\t$('#videoTutorial_perfil').get(0).pause();\n\t$(\"#div_videoTutorial\").hide(\"slower\");\n}", "title": "" }, { "docid": "717f3817a2e8649a26e57be5c8176199", "score": "0.6340347", "text": "function removePreview() {\n window.document.body.removeChild(previewElement_bg);\n window.document.body.removeChild(previewElement);\n window.document.body.removeChild(userPageElement);\n window.document.body.removeChild(closeBtnElmnt);\n window.document.head.removeChild(document.getElementById(\"aiva_vendor_css\"));\n window.document.head.removeChild(document.getElementById(\"aiva_css\"));\n while (document.getElementById(\"aiva_font\")) {\n window.document.head.removeChild(document.getElementById(\"aiva_font\"));\n }\n }", "title": "" }, { "docid": "717f3817a2e8649a26e57be5c8176199", "score": "0.6340347", "text": "function removePreview() {\n window.document.body.removeChild(previewElement_bg);\n window.document.body.removeChild(previewElement);\n window.document.body.removeChild(userPageElement);\n window.document.body.removeChild(closeBtnElmnt);\n window.document.head.removeChild(document.getElementById(\"aiva_vendor_css\"));\n window.document.head.removeChild(document.getElementById(\"aiva_css\"));\n while (document.getElementById(\"aiva_font\")) {\n window.document.head.removeChild(document.getElementById(\"aiva_font\"));\n }\n }", "title": "" }, { "docid": "ce71a95fca6b802d6481956acd02dc31", "score": "0.62880963", "text": "function menuFromStruct(){\n instructions.removeChildren();\n stage.removeChild(instructions);\n titleLoader();\n}", "title": "" }, { "docid": "69582ed4bb536bafa4b7ee0e369e7f17", "score": "0.6244998", "text": "static remove() {\n let container = document.querySelector('#js-youtube');\n\n container.innerHTML = '';\n }", "title": "" }, { "docid": "fb8f585baadd8bdf0beb9743bd759d77", "score": "0.62433004", "text": "function removeContent() {\n //character.clearCharacterLPCanvas();\n monster.clearMonsterLPCanvas();\n}", "title": "" }, { "docid": "59bc2c3fcd8891251ee90e5f08daae53", "score": "0.62402844", "text": "function finishIntro() {\n\n if (mainDisplay.getState() === WORK_FROM_HOME_MODE) {\n debugData = new DebugData();\n createLegend();\n hideElement(getElement('landing-screen-wrapper'));\n showGroup([mainDisplay.addRemove, mainDisplay.largeYearDisplay, mainDisplay.legend]);\n mainDisplay.setCurYear(mainDisplay.curYear);\n showGroup([getElement('location-title'), getElement('scenario-title')])\n } else {\n mainDisplay.setState(INTROMODE);\n hideAllLayers(); // Hides all layers\n showGroup([getElement('landing-screen-wrapper'), getElement('location-title'), getElement('scenario-title')])\n }\n\n mainDisplay.initializingMarkers = false;\n hideElement(camWrap);\n\n removeChild(getElement(\"lower-section-wrapper\"), initializeWrapper);\n removeChild(camWrap, rightSideWrapper);\n\n updateElementStyle(getElement(\"lower-section-wrapper\"), [{ 'cursor': 'pointer' }]);\n\n }", "title": "" }, { "docid": "d11c2a79a2e49c12a8b85e6558239cb1", "score": "0.62387776", "text": "function clearPlayer(){\n var iframelimp= $(\"iframe\").contents().find(\"iframe\").contents();\n iframelimp.find(\"#windowads\").remove();\n iframelimp.find(\".logo\").remove();\n $(\"#ventana-flotante\").remove();\n }", "title": "" }, { "docid": "63c18ce39fe083e863c9f034cbb79374", "score": "0.6218301", "text": "function removeBeforeStartingQuiz(){\n removeStartButton();\n removeStartingQuestion();\n}", "title": "" }, { "docid": "4c1767b0297f8c4c071a91528ded2654", "score": "0.62163025", "text": "function stlClearTrack() {\r\n videoSubtitle.track.mode = \"disabled\";\r\n videoSubtitle.remove();\r\n videoSubtitle = document.createElement(\"track\");\r\n videoSubtitle.label = \"YTSubtitleLoader\";\r\n videoSubtitle.default = true;\r\n videoSubtitle.src = \"data:text/vtt,\";\r\n video.appendChild(videoSubtitle);\r\n}", "title": "" }, { "docid": "2b328267a6bbf2187a67db2a66787984", "score": "0.61837214", "text": "function removeGameElements() {\n\n //hides video and card holder\n remoteVideo.style.display = 'none';\n cardHolder.style.display = 'none';\n\n}", "title": "" }, { "docid": "613a1b77e4b2a19eaf81180067f90354", "score": "0.61806536", "text": "function clearRecommendedFields() {\n $('#video-game-title').text('');\n $('#video-game-poster').attr('src', \"\").attr('alt', '');\n $('#video-game-rating').text('Searching...');\n $('#video-game-spinner').show();\n $('#video-game-plot').text('');\n $('#video-game-score').text('');\n $('#video-game-full-url').text('');\n}", "title": "" }, { "docid": "d844cd2e3900b1bd4dc5463574f72804", "score": "0.6154797", "text": "function hideIntro (){\n \n intro.classList.add('hidden') ;\n //createHTML(questions)\n quizArea.classList.remove('hidden');\n displayQuestion();\n}", "title": "" }, { "docid": "021562d4285621e5a1172bfc6601d071", "score": "0.6081801", "text": "function destroyWebContent() {\n $(\"#webControls\").remove();\n $(\".fullscreenContent\").remove();\n $(\"#mainContent\").show();\n}", "title": "" }, { "docid": "5da4a480863cd9643c6e4901bda293ce", "score": "0.60781544", "text": "function menuFromCredits(){\n credits.removeChildren();\n stage.removeChild(credits);\n titleLoader();\n}", "title": "" }, { "docid": "d5e1ffa91000e2e24eeedbec25e51274", "score": "0.6056041", "text": "function resetExperiment()\n{ \n \n // background.visible = false;\n removeMultichoice();\n removeMissingText();\n removeBanner();\n removeLearn();\n PIEscene.remove(tick);\n PIEscene.remove(wrong);\n PIEscene.remove(correct_text);\n PIErender();\n \n // tick.visible=false;\n // wrong.visible=false;\n \n //initialiseScene();\n\n //initialiseControls();\n\n\n \n}", "title": "" }, { "docid": "6c1c6081676cf96ff5f4063259370081", "score": "0.6051575", "text": "function removeInstructions()\n{\n document.getElementById(\"instructions\").style.display = \"none\";\n}", "title": "" }, { "docid": "bd87dd1f10d702d00a5206c0881c2d36", "score": "0.6011216", "text": "function removeYouTubeAds() {\n\t$(\".promoted-videos\").remove();\n\t$(\"[id*='ad_creative']\").remove();\n}", "title": "" }, { "docid": "b9bad8f7e0de3340f735484007fcb01e", "score": "0.59998554", "text": "function removeVideoOverlay(){\n var overlays = $('.video-overlay');\n for(var i = 0; i < overlays.length; i++){\n hide(overlays.get(i), true);\n }\n}", "title": "" }, { "docid": "b444aabe73d8dd97db271657f456733e", "score": "0.5999019", "text": "function removePlayPause(options) {\n $.each(options.features, function (i) {\n if (this === 'playpause') {\n options.features.splice(i, 1);\n }\n });\n}", "title": "" }, { "docid": "c04973b9eb13bb955c9cb4955059c95c", "score": "0.5976851", "text": "function remove(ev){\n ev.target.parentNode.removeChild(ev.target);\n var wordImage = document.getElementById(\"start\").getElementsByTagName('img');\n if(wordImage.length == 0) document.getElementById(\"launch\").classList.add(\"hide\");\n}", "title": "" }, { "docid": "1ae7f05723d20c1c87e29cb60bfc185b", "score": "0.5934094", "text": "function vidDone(){\n done = true\n intro.hide()\n ins.play()\n}", "title": "" }, { "docid": "3dc1047ef2def90a61571f1e668adb73", "score": "0.5920113", "text": "function revindVideoToStart()\n {\n mmuVideo.load();\n }", "title": "" }, { "docid": "98cdb56bac8d40f29d3f8a1ed3fd95a1", "score": "0.5917674", "text": "function bauhausVideoUnwrap(){\n\tvar pTags = jQuery( '.fluid-width-video-wrapper, iframe, video' );\n\tif ( pTags.parent().is( 'p' ) ) {\n\t\tpTags.unwrap();\n\t }\n}", "title": "" }, { "docid": "5786446163d2483688a15e1a92590b79", "score": "0.5893742", "text": "function clean_injection () {\n var elem;\n while((elem = document.getElementById(\"injplay\"))){\n elem.remove();\n }\n while((elem = document.getElementById(\"injpause\"))){\n elem.remove();\n }\n}", "title": "" }, { "docid": "802b8e2f4f82e1fa39f14545aa607f0f", "score": "0.5888901", "text": "function resetIntro() {\n var dataTable = document.getElementById(\"dataAreaContainer\");\n dataTable.parentNode.removeChild(dataTable);\n }", "title": "" }, { "docid": "4b7ede8c9d5b0b17d5c757ab12924df2", "score": "0.58828735", "text": "function closeVideo() {\n $('.video-embed').empty();\n $('.video-player').hide();\n}", "title": "" }, { "docid": "3f28429dcf49b93f021c98ba20c54b0f", "score": "0.58702415", "text": "function removeWalkthrough() {\n $('.modal-background').remove();\n }", "title": "" }, { "docid": "ee9d97dca5097bdedb49305026c520cf", "score": "0.586031", "text": "function destroy () {\n\n\t\t/**\n\t\t * Save a copy of the video player markup.\n\t\t */\n\t\tvar videoPlayerMarkup = videoPlayer.html();\n\t\tvideoPlayerMarkup = $( videoPlayerMarkup ).removeAttr( 'autoplay' );\n\n\t\t/**\n\t\t * Remove video events.\n\t\t */\n\t\tvideo.off( 'play', videoStarted );\n\t\tvideo.off( 'ended', videoEnded );\n\t\tvideo.off( 'timeupdate', videoProgress );\n\n\t\t/**\n\t\t * Remove video player markup from\n\t\t * the DOM.\n\t\t */\n\t\tvideoPlayer.html('');\n\n\t\t/**\n\t\t * Re-apply video player markup back\n\t\t * to the DOM and re-initialize the\n\t\t * video player.\n\t\t */\n\t\tTweenMax.delayedCall( 0.05, function () {\n\n\t\t\tvideoPlayer.html( videoPlayerMarkup );\n\t\t\tinit();\n\t\t});\n\t}", "title": "" }, { "docid": "a9304927f131a106be69f8d022562ca2", "score": "0.58576113", "text": "function redisplay()\r\n{\r\n RemoveVideos(displayVideos);\r\n}", "title": "" }, { "docid": "d2ec61192ce7248e69095775fdd976c3", "score": "0.5837784", "text": "function trailerOff(){\n\t$('.movieinfo h2, .movieinfo p, .movieinfo .actions, .goTrailer, .trailerImage').fadeIn('fast');\n}", "title": "" }, { "docid": "4a85817671ee862593809e81279824e4", "score": "0.58346444", "text": "function reproducirVideo() {\n document.getElementById(\"trailer-video\").style.visibility = 'visible'\n document.getElementById(\"play\").style.visibility = 'hidden'\n }", "title": "" }, { "docid": "b99869c81feb25868dd098276b4a759f", "score": "0.5833815", "text": "function removeTextStart(){\n\tgame.world.remove(buttonEasy);\n\tgame.world.remove(buttonMed);\n\tgame.world.remove(buttonHard);\n\tgame.world.remove(startText);\n\tgame.stage.backgroundColor = '#3598db';\n}", "title": "" }, { "docid": "d70a73358d3083494118e9bbedc0ef3f", "score": "0.58323085", "text": "function hideIntroContent() {\n for (var i = 0; i < 4; i++) {\n document.getElementsByClassName(\"hide-after-start\")[i].style.cssText = \"display:none;\";\n }\n}", "title": "" }, { "docid": "376559fdf17e76b50395ee3c42b87762", "score": "0.5827736", "text": "function removeTuneInAds() {\n\t$(\".ad-block\").remove();\n\t$(\"#leader_ad_container\").remove();\n\t$(\".outside_ad\").remove();\n}", "title": "" }, { "docid": "9c9f836e7999e3666923afed83f97e6e", "score": "0.5824509", "text": "remove() {\n // set '+' toggle for all views of the snippet\n this.els.forEach((el) => {\n const toggle = el.querySelector(\".toggle\");\n toggle.classList.remove(\"remove\");\n toggle.classList.add(\"add\");\n });\n\n // remove view from the collection div\n this.collected.remove();\n }", "title": "" }, { "docid": "e274f1002fc8d754c58b97d555a0b1b4", "score": "0.58094674", "text": "function restore() {\n document.body.removeChild(document.getElementById(\"overlay\"));\n document.body.removeChild(document.getElementById(\"iconImage\"));\n document.body.removeChild(document.getElementById(\"arrow1\"));\n document.body.removeChild(document.getElementById(\"arrow2\"));\n document.body.removeChild(document.getElementById(\"arrow3\"));\n document.body.removeChild(document.getElementById(\"sparkersPanel\"));\n \n}", "title": "" }, { "docid": "7c902780b1ed62ce41428bcceb079497", "score": "0.57974136", "text": "function hideIntro() {\n\tvar intro = document.getElementById(\"intro\");\n\tintro.style.display = \"none\";\n\twindow.onmousemove = getMousePosition;\n\tvar audio = document.getElementById(\"sound\");\n\taudio.play();\n}", "title": "" }, { "docid": "4aedc5e4b48eefc98ac89f1243964287", "score": "0.5775002", "text": "function intro_default() {\r\n intro_section.classList.remove(\"intro_hover\");\r\n intro_header.classList.remove(\"intro_hover\");\r\n intro_section.style.background = null;\r\n nav_hover_default(nav_home);\r\n}", "title": "" }, { "docid": "3803b64acffe3f2ff82d70a7184979ea", "score": "0.5770964", "text": "function removeTheCaptions(actli,opt) {\n\n\n\t\t\t\t\t\tactli.find('.tp-caption').each(function(i) {\n\t\t\t\t\t\t\tvar nextcaption=jQuery(this); //actli.find('.tp-caption:eq('+i+')');\n\n\t\t\t\t\t\t\tif (nextcaption.find('iframe').length>0) {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t// VIMEO VIDEO PAUSE\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tvar ifr = nextcaption.find('iframe');\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tvar id = ifr.attr('id');\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tvar froogaloop = $f(id);\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tfroogaloop.api(\"pause\");\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tclearTimeout(nextcaption.data('timerplay'));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t} catch(e) {}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//YOU TUBE PAUSE\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tvar player=nextcaption.data('player');\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tplayer.stopVideo();\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tclearTimeout(nextcaption.data('timerplay'));\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t} catch(e) {}\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// IF HTML5 VIDEO IS EMBEDED\n\t\t\t\t\t\t\tif (nextcaption.find('video').length>0) {\n\t\t\t\t\t\t\t\t\t\t\ttry{\n\t\t\t\t\t\t\t\t\t\t\t\tnextcaption.find('video').each(function(i) {\n\t\t\t\t\t\t\t\t\t\t\t\t\tvar html5vid = jQuery(this).parent();\n\t\t\t\t\t\t\t\t\t\t\t\t\tvar videoID =html5vid.attr('id');\n\t\t\t\t\t\t\t\t\t\t\t\t\tclearTimeout(html5vid.data('timerplay'));\n\t\t\t\t\t\t\t\t\t\t\t\t\tvideojs(videoID).ready(function(){\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tvar myPlayer = this;\n\t\t\t\t\t\t\t\t\t\t\t\t\t\tmyPlayer.pause();\n\t\t\t\t\t\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t\t\t\t\t\t})\n\t\t\t\t\t\t\t\t\t\t\t}catch(e) {}\n\t\t\t\t\t\t\t\t\t\t} // END OF VIDEO JS FUNCTIONS\n\t\t\t\t\t\t\ttry {\n\t\t\t\t\t\t\t\t\tendMoveCaption(nextcaption,opt,0);\n\t\t\t\t\t\t\t\t} catch(e) {}\n\n\n\n\t\t\t\t\t\t});\n\t\t\t\t}", "title": "" }, { "docid": "bf28c7b61ad0701ad2fae3d6f7067e6a", "score": "0.57700926", "text": "function reset() {\n if (flag.hascanvas) {\n document.documentElement.removeChild(canvas);\n document.documentElement.removeChild(tips);\n }\n flag.isPress = false;\n flag.hascanvas = false;\n }", "title": "" }, { "docid": "fdd5fc31cafce58667346642d65b3e48", "score": "0.57681715", "text": "function destroyStructure(){\n //reseting the `top` or `translate` properties to 0\n silentScroll(0);\n\n //loading all the lazy load content\n $('img[data-src], source[data-src], audio[data-src], iframe[data-src]', container).forEach(function(item){\n setSrc(item, 'src');\n });\n\n $('img[data-srcset]').forEach(function(item){\n setSrc(item, 'srcset');\n });\n\n remove($(SECTION_NAV_SEL + ', ' + SLIDES_NAV_SEL + ', ' + SLIDES_ARROW_SEL));\n\n //removing inline styles\n css($(SECTION_SEL), {\n 'height': '',\n 'background-color' : '',\n 'padding': ''\n });\n\n css($(SLIDE_SEL), {\n 'width': ''\n });\n\n css(container, {\n 'height': '',\n 'position': '',\n '-ms-touch-action': '',\n 'touch-action': ''\n });\n\n css($htmlBody, {\n 'overflow': '',\n 'height': ''\n });\n\n // remove .fp-enabled class\n removeClass($html, ENABLED);\n\n // remove .fp-responsive class\n removeClass($body, RESPONSIVE);\n\n // remove all of the .fp-viewing- classes\n $body.className.split(/\\s+/).forEach(function (className) {\n if (className.indexOf(VIEWING_PREFIX) === 0) {\n removeClass($body, className);\n }\n });\n\n //removing added classes\n $(SECTION_SEL + ', ' + SLIDE_SEL).forEach(function(item){\n if(options.scrollOverflowHandler && options.scrollOverflow){\n options.scrollOverflowHandler.remove(item);\n }\n removeClass(item, TABLE + ' ' + ACTIVE + ' ' + COMPLETELY);\n var previousStyles = item.getAttribute('data-fp-styles');\n if(previousStyles){\n item.setAttribute('style', item.getAttribute('data-fp-styles'));\n }\n\n //removing anchors if they were not set using the HTML markup\n if(hasClass(item, SECTION) && !g_initialAnchorsInDom){\n item.removeAttribute('data-anchor');\n }\n });\n\n //removing the applied transition from the fullpage wrapper\n removeAnimation(container);\n\n //Unwrapping content\n [TABLE_CELL_SEL, SLIDES_CONTAINER_SEL,SLIDES_WRAPPER_SEL].forEach(function(selector){\n $(selector, container).forEach(function(item){\n //unwrap not being use in case there's no child element inside and its just text\n unwrap(item);\n });\n });\n\n //removing the applied transition from the fullpage wrapper\n css(container, {\n '-webkit-transition': 'none',\n 'transition': 'none'\n });\n\n //scrolling the page to the top with no animation\n window.scrollTo(0, 0);\n\n //removing selectors\n var usedSelectors = [SECTION, SLIDE, SLIDES_CONTAINER];\n usedSelectors.forEach(function(item){\n removeClass($('.' + item), item);\n });\n }", "title": "" }, { "docid": "89e0f37c50de017a9eb8d8934bad3cf7", "score": "0.5764133", "text": "function showIntro() {\n w3.removeClass(\"#shareIntro\", \"w3-hide\")\n w3.addClass(\"#shareIntroShow\", \"w3-hide\")\n}", "title": "" }, { "docid": "f0a017271a361ed09e8c9c8ecaabca02", "score": "0.57623166", "text": "function reset() {\n if (flag.hascanvas) {\n document.documentElement.removeChild(canvas);\n document.documentElement.removeChild(tips);\n }\n flag.isPress = false;\n flag.hascanvas = false;\n }", "title": "" }, { "docid": "db8f8050322798e567d952dd6fbabae3", "score": "0.57541835", "text": "function destroyStructure(){\n //reseting the `top` or `translate` properties to 0\n silentScroll(0);\n\n //loading all the lazy load content\n $('img[data-src], source[data-src], audio[data-src], iframe[data-src]', container).forEach(function(item){\n setSrc(item, 'src');\n });\n\n $('img[data-srcset]').forEach(function(item){\n setSrc(item, 'srcset');\n });\n\n remove($(SECTION_NAV_SEL + ', ' + SLIDES_NAV_SEL + ', ' + SLIDES_ARROW_SEL));\n\n //removing inline styles\n css($(SECTION_SEL), {\n 'height': '',\n 'backgroundColor' : '',\n 'padding': ''\n });\n\n css($(SLIDE_SEL), {\n 'width': ''\n });\n\n css(container, {\n 'height': '',\n 'position': '',\n 'msTouchAction': '',\n 'touchAction': ''\n });\n\n css($htmlBody, {\n 'overflow': '',\n 'height': ''\n });\n\n // remove .fp-enabled class\n removeClass($html, ENABLED);\n\n // remove .fp-responsive class\n removeClass($body, RESPONSIVE);\n\n // remove all of the .fp-viewing- classes\n $body.className.split(/\\s+/).forEach(function (className) {\n if (className.indexOf(VIEWING_PREFIX) === 0) {\n removeClass($body, className);\n }\n });\n\n //removing added classes\n $(SECTION_SEL + ', ' + SLIDE_SEL).forEach(function(item){\n if(options.scrollOverflowHandler && options.scrollOverflow){\n options.scrollOverflowHandler.remove(item);\n }\n removeClass(item, TABLE + ' ' + ACTIVE + ' ' + COMPLETELY);\n var previousStyles = item.getAttribute('data-fp-styles');\n if(previousStyles){\n item.setAttribute('style', item.getAttribute('data-fp-styles'));\n }\n\n //removing anchors if they were not set using the HTML markup\n if(hasClass(item, SECTION) && !g_initialAnchorsInDom){\n item.removeAttribute('data-anchor');\n }\n });\n\n //removing the applied transition from the fullpage wrapper\n removeAnimation(container);\n\n //Unwrapping content\n [TABLE_CELL_SEL, SLIDES_CONTAINER_SEL,SLIDES_WRAPPER_SEL].forEach(function(selector){\n $(selector, container).forEach(function(item){\n //unwrap not being use in case there's no child element inside and its just text\n unwrap(item);\n });\n });\n\n //removing the applied transition from the fullpage wrapper\n css(container, {\n 'webkitTransition': 'none',\n 'transition': 'none'\n });\n\n //scrolling the page to the top with no animation\n window.scrollTo(0, 0);\n\n //removing selectors\n var usedSelectors = [SECTION, SLIDE, SLIDES_CONTAINER];\n usedSelectors.forEach(function(item){\n removeClass($('.' + item), item);\n });\n }", "title": "" }, { "docid": "00088d71b7914eb2d216aade5e282034", "score": "0.5751107", "text": "function hidePreview(){\n\t\tif (preview!=null){\n\t\t\tscene.remove(preview);\n\t\t}\n\t\tpreview = null;\n\t}", "title": "" }, { "docid": "a2b691a0e31dfefce3cfee0d8d84efc8", "score": "0.57471615", "text": "while (helpId.childNodes[0]) {\n helpId.removeChild(helpId.childNodes[0]);\n }", "title": "" }, { "docid": "dcd1c4eb7e20be238c9f561aba8a1c52", "score": "0.5736194", "text": "function RemoveVideo(nodeId) {\n const video = document.getElementById(nodeId);\n if (video) video.remove();\n}", "title": "" }, { "docid": "5bc2365b6ba14c4117b0bef6ea32a143", "score": "0.5728209", "text": "function hideVideoElements() {\n webgazer.showPredictionPoints(false);\n webgazer.showVideo(false);\n webgazer.showFaceOverlay(false);\n webgazer.showFaceFeedbackBox(false);\n //webgazer.showGazeDot(false);\n }", "title": "" }, { "docid": "38d1b3544da45c5efb1baa8cf968bfa8", "score": "0.57223964", "text": "function startGameAgain(e){\n winScreen.removeChildren();\n stage.removeChild(winScreen);\n titleLoader();\n}", "title": "" }, { "docid": "e33ac02722b8c9ba3a3304c85c9d52e3", "score": "0.5712142", "text": "function destroy () {\n if (!this.$options.head) return\n util.undoTitle(diffTitle)\n util.undo()\n }", "title": "" }, { "docid": "e33ac02722b8c9ba3a3304c85c9d52e3", "score": "0.5712142", "text": "function destroy () {\n if (!this.$options.head) return\n util.undoTitle(diffTitle)\n util.undo()\n }", "title": "" }, { "docid": "68208861418aaa8c6239b1514e69b80d", "score": "0.57088596", "text": "function clearWithout() {\n Scene.getItems().forEach(function(item) {\n if(item.id() !== \"jhQlZHx1Vp\" && //camera\n item.id() !== \"IM76dkNzE5\" && //hud pivot\n item.id() !== \"a7mnFAUKlz\" && //scoreboard\n item.id() !== \"p75QJwda5M\" && //menu button\n item.id() !== \"3boBy4pikv\" && //how to play\n item.id() !== \"1LOddouqRv\" && //heart3\n item.id() !== \"Y00bLu1NP3\" && //heart2\n item.id() !== \"DEDXiUxLa0\") //heart1 \n item.deleteFromScene();\n });\n}", "title": "" }, { "docid": "9bcde952a58a49f5ae906345831639af", "score": "0.5707275", "text": "function clearInfoFields(){\n $(\"#movie-title\").children(\"h1\").remove();\n $(\"#movie-length\").children(\"p\").remove();\n $(\"#movie-country\").children(\"p\").remove();\n $(\"#movie-language\").children(\"p\").remove();\n $(\"#infoImgWrapper\").children(\"img\").remove();\n $(\"#descriptionWrapper\").children(\"textarea\").remove();\n}", "title": "" }, { "docid": "46c80b600352a530ef498049c92e256c", "score": "0.57033217", "text": "resetInformation(genreContainer) {\n genreContainer.querySelectorAll('*').forEach(node => {\n if(node.tagName != \"P\") {\n node.remove()\n }\n })\n }", "title": "" }, { "docid": "9d2410103542af412a99bb23985d93aa", "score": "0.5696226", "text": "function removePlayfull() {\n editingField.classList.remove('playfull-note')\n templateData = \"undefined\";\n}", "title": "" }, { "docid": "9feeadfcffef56a30e507b723687d1fe", "score": "0.56899995", "text": "function erase_puzzle(){\n $('#playCanvas').html('');\n $('#makeCanvas').html('');\n}", "title": "" }, { "docid": "49efe598a04c7e016587f490031fcaf6", "score": "0.56887466", "text": "function removeTheCaptions(actli, opt) {\n actli.find('.tp-caption').each(function(i) {\n var nextcaption = jQuery(this);\n //actli.find('.tp-caption:eq('+i+')');\n if (nextcaption.find('iframe').length > 0) {\n // VIMEO VIDEO PAUSE\n try {\n var ifr = nextcaption.find('iframe');\n var id = ifr.attr('id');\n var froogaloop = $f(id);\n froogaloop.api(\"pause\");\n clearTimeout(nextcaption.data('timerplay'));\n } catch (e) {}\n //YOU TUBE PAUSE\n try {\n var player = nextcaption.data('player');\n player.stopVideo();\n clearTimeout(nextcaption.data('timerplay'));\n } catch (e) {}\n }\n // IF HTML5 VIDEO IS EMBEDED\n if (nextcaption.find('video').length > 0) {\n try {\n nextcaption.find('video').each(function(i) {\n var html5vid = jQuery(this).parent();\n var videoID = html5vid.attr('id');\n clearTimeout(html5vid.data('timerplay'));\n videojs(videoID).ready(function() {\n var myPlayer = this;\n myPlayer.pause();\n });\n })\n } catch (e) {}\n }\n // END OF VIDEO JS FUNCTIONS\n try {\n endMoveCaption(nextcaption, opt, 0);\n } catch (e) {}\n });\n }", "title": "" }, { "docid": "95286313112bf24ad212d8e0153c3968", "score": "0.5681175", "text": "function play_intro() {\n wallpaper.style.display = \"none\";\n intro.style.display = \"block\";\n intro_video.play();\n intro.classList.add(\"intro_animation\");\n setTimeout(() => {\n site.style.display = \"block\";\n }, 15000);\n setTimeout(() => {\n intro.style.display = \"none\";\n }, 16000);\n}", "title": "" }, { "docid": "884359286a60990f6b687604356f545f", "score": "0.567899", "text": "function removeTheCaptions(actli, opt) {\n\n\n actli.find('.tp-caption').each(function(i) {\n var nextcaption = jQuery(this); //actli.find('.tp-caption:eq('+i+')');\n\n if (nextcaption.find('iframe').length > 0) {\n // VIMEO VIDEO PAUSE\n try {\n var ifr = nextcaption.find('iframe');\n var id = ifr.attr('id');\n var froogaloop = $f(id);\n froogaloop.api(\"pause\");\n clearTimeout(nextcaption.data('timerplay'));\n } catch (e) {}\n //YOU TUBE PAUSE\n try {\n var player = nextcaption.data('player');\n player.stopVideo();\n clearTimeout(nextcaption.data('timerplay'));\n } catch (e) {}\n }\n\n // IF HTML5 VIDEO IS EMBEDED\n if (nextcaption.find('video').length > 0) {\n try {\n nextcaption.find('video').each(function(i) {\n var html5vid = jQuery(this).parent();\n var videoID = html5vid.attr('id');\n clearTimeout(html5vid.data('timerplay'));\n videojs(videoID).ready(function() {\n var myPlayer = this;\n myPlayer.pause();\n });\n })\n } catch (e) {}\n } // END OF VIDEO JS FUNCTIONS\n try {\n endMoveCaption(nextcaption, opt, 0);\n } catch (e) {}\n\n\n\n });\n }", "title": "" }, { "docid": "0134a8f4cb8bf686fb35300958e9f8fb", "score": "0.56740737", "text": "function unrenderMPC(){\n while(mainPageContent.firstChild){\n mainPageContent.removeChild(mainPageContent.firstChild)\n }\n}", "title": "" }, { "docid": "08640a4b60b195532cc46045b47411c2", "score": "0.5661485", "text": "function removeMovies() {\n const movies = document.querySelectorAll('.movie-wrapper');\n\n movies.forEach(function(movieWrapper) {\n movieWrapper.outerHTML = '';\n });\n noMoviesMessage(true);\n removeMoviesButton(false);\n}", "title": "" }, { "docid": "d1312df31789c364470e5a136bf3f29f", "score": "0.5655148", "text": "function removePacmanLivesImg() {\n game.livesDom.removeChild(document.getElementById(\"life\" + game.player.lives));\n}", "title": "" }, { "docid": "3ad11b3f9cc19050055c84e5cb1327c6", "score": "0.5652198", "text": "function stopVideo() {}", "title": "" }, { "docid": "d7cd4f249a5d29386f0cd79fd20cef95", "score": "0.56381047", "text": "function clearMovieArea() {\n movieArea.innerHTML = \"\";\n}", "title": "" }, { "docid": "dcabcd84260e2bd2fab75d8ee51bfeca", "score": "0.56351304", "text": "function reset_tutorial() {\n\tget_tutorial();\n}", "title": "" }, { "docid": "1489daf58312653184e0b0242fcb4ec8", "score": "0.5634558", "text": "function removeStartLink() {\n\t$(\"#startWualaButton\").remove();\n}", "title": "" }, { "docid": "4a5c4f4efe46c00004628260ee5a85df", "score": "0.5632831", "text": "function unmuteVideo() {}", "title": "" }, { "docid": "7c57c498375eef855da0908b75402406", "score": "0.5632515", "text": "function onwheneva() {\n replaceNoscript(media)\n }", "title": "" }, { "docid": "719b546f2da36f971d2010fb4a7e069c", "score": "0.562157", "text": "function removeVkontakteAds() {\n\t$(\"#left_ads\").css(\"display\", \"none\");\n}", "title": "" }, { "docid": "07219c73acb904f1532933af50e93515", "score": "0.56206733", "text": "function clearInfoBox(){\n let pic = document.getElementById(\"landmark_image\");\n let charts = document.getElementById(\"box\");\n let dot_info = document.getElementById(\"dot_info\");\n let welcome_board = document.getElementById(\"welcome\");\n while(dot_info.lastChild){\n dot_info.removeChild(dot_info.lastChild);\n }\n pic.src = \"\";\n\n while(charts.lastChild){\n charts.removeChild(charts.lastChild);\n }\n\n while(welcome_board.lastChild){\n welcome_board.removeChild(welcome_board.lastChild);\n }\n}", "title": "" }, { "docid": "48fd8d033f88bd29fc361464d3847d7c", "score": "0.5618729", "text": "function removeExamples(box){\n\tlet linesArray = $(box).html().split('\\n');\n\tlet examplesIndex = linesArray.indexOf(\"/** &lt;examples&gt;\");\n\tlinesArray.splice(examplesIndex, 0, '<span class=\"examplesToRemove\">');\n\tlinesArray.push('</span>');\n\tlet newContent = linesArray.join('\\n');\n\t$(box).html(newContent);\n\t$('.examplesToRemove').hide();\n}", "title": "" }, { "docid": "780d3cd275c343ddb4b29f03e865bcc3", "score": "0.5614963", "text": "function loadIntroductionModule (){\n document.getElementById('proj-intro-concept').style.display = 'block';\n var videoIntroCircular = document.getElementById('linear-circular-video');\n videoIntroCircular.pause();\n videoIntroCircular.currentTime = 0;\n setTimeout(function(){videoIntroCircular.play();}, 2000);\n currentProjection = 'proj-intro-concept';\n}", "title": "" }, { "docid": "475b69492ef1f59f48f1af9b3c306cf8", "score": "0.56087023", "text": "function cleanUp() {\n if (hasFiles) {\n markers.replaceWith(function(idx) {\n return files.get(idx);\n });\n }\n form.remove();\n iframe.attr(\"src\", \"javascript:false;\").remove();\n }", "title": "" }, { "docid": "f2d2d967915a04a40a2dbdef2aacaaa7", "score": "0.5608203", "text": "function hideVideos () {\n for (videoSample in videos) {\n videos[videoSample].video.hide()\n }\n}", "title": "" }, { "docid": "032cbac63eff81082574c75a45d3f421", "score": "0.56034744", "text": "function remove_empty_captions(){\n $('#slider-wrapper div.nivo-html-caption').each(function(){\n // var caption_title = $.trim($(this).find('h3').first().text());\n var caption_text = $.trim( $(this).find('p').first().text() );\n if('' == caption_text){\n var id = '#' + $(this).attr('id');\n $(this).remove();\n $('#slider img[title=\"' + id + '\"]').attr('title', '');\n }\n }); \n\n $('div.banner_text div.banner_caption').each(function(){\n var caption_title = $.trim($(this).find('h3').first().text());\n var caption_text = $.trim($(this).find('p').first().text());\n if('' == caption_title){\n $(this).remove();\n }\n });\n\n var currUrl = window.location.pathname;\n if(currUrl.indexOf(\"index.html\") < 0){\n \tcurrUrl = currUrl + \"index.html\";\n }\n\n var currUrl2 = currUrl.substring(0,currUrl.indexOf('index.html'));\n var currUrl3 = currUrl.substring(0,currUrl.indexOf('/index.html'))\n\n //Hide the two side navs (the current and parent ones)\n $(\"#currnav\").hide();\n $(\"#prevnav\").hide();\n\n //Append the new side nav structure to the nav node, with the current parent nav item\n $(\".secnav\").append(\n \t\"<ul class='sn1' role='navigation'>\"\n \t+\"<li class='selected'>\"+ $(\"ul#prevnav li\").has(\"a[href='\"+currUrl+\"']\").text() \n \t+\"<li class='selected'>\"+ $(\"ul#prevnav li\").has(\"a[href='\"+currUrl2+\"']\").text() \n \t+\"<li class='selected'>\"+ $(\"ul#prevnav li\").has(\"a[href='\"+currUrl3+\"']\").text() \n \t+\"<ul class='sn1 navexpand' style='float:none'></ul></li>\"\n \t+\"</ul>\"\n );\n\n //Add the current side nav to the proper spot\n $(\"ul#currnav li a\").each(function(){\n \t$(\".navexpand\").append(\n \t\t\"<li>\"\n \t\t+\"<a href='\" + $(this).attr('href') + \"'>\"\n \t\t+ $(this).text() \n \t\t+\"</a></li>\")\n });\n\n //Add the other parent nav items\n $(\"ul#prevnav li a\").each(function(){\n \tif($(this).attr(\"href\") != currUrl && $(this).attr(\"href\") != currUrl2 && $(this).attr(\"href\") != currUrl3){\n \t\t$(\".secnav ul[class='sn1']\").append($(this).parent()); \n \t}\n });\n\n }", "title": "" }, { "docid": "20e3d561c6a11f7414a2c4de07bc80c4", "score": "0.56021976", "text": "function prepareVideoWall()\n{\n\tvar html5video = document.getElementsByTagName(\"video\")[0];\n\tif (html5video != undefined)\n\t{\n\t\thtml5video.removeEventListener(\"ended\", reShowBars);\n\t\thtml5video.addEventListener(\"ended\", reShowBars);\n\t}\n}", "title": "" }, { "docid": "77bafb95f33e53fa69cbe240db69e55c", "score": "0.56005865", "text": "function destroySkeleton()\n\t{\n\t\tradardiv.removeChild( skeleton.frame );\n\t}", "title": "" }, { "docid": "6260b4cf49062b8377e81d5c48edfeaf", "score": "0.5597011", "text": "function destroyStructure() {\n //reseting the `top` or `translate` properties to 0\n silentScroll(0);\n\n //loading all the lazy load content\n container.find('img[data-src], source[data-src], audio[data-src], iframe[data-src]').each(function () {\n setSrc($(this), 'src');\n });\n\n container.find('img[data-srcset]').each(function () {\n setSrc($(this), 'srcset');\n });\n\n $(SECTION_NAV_SEL + ', ' + SLIDES_NAV_SEL + ', ' + SLIDES_ARROW_SEL).remove();\n\n //removing inline styles\n $(SECTION_SEL).css({\n 'height': '',\n 'background-color': '',\n 'padding': ''\n });\n\n $(SLIDE_SEL).css({\n 'width': ''\n });\n\n container.css({\n 'height': '',\n 'position': '',\n '-ms-touch-action': '',\n 'touch-action': ''\n });\n\n $htmlBody.css({\n 'overflow': '',\n 'height': ''\n });\n\n // remove .fp-enabled class\n $('html').removeClass(ENABLED);\n\n // remove .fp-responsive class\n $body.removeClass(RESPONSIVE);\n\n // remove all of the .fp-viewing- classes\n $.each($body.get(0).className.split(/\\s+/), function (index, className) {\n if (className.indexOf(VIEWING_PREFIX) === 0) {\n $body.removeClass(className);\n }\n });\n\n //removing added classes\n $(SECTION_SEL + ', ' + SLIDE_SEL).each(function () {\n if (options.scrollOverflowHandler) {\n options.scrollOverflowHandler.remove($(this));\n }\n $(this).removeClass(TABLE + ' ' + ACTIVE);\n $(this).attr('style', $(this).data('fp-styles'));\n });\n\n removeAnimation(container);\n\n //Unwrapping content\n container.find(TABLE_CELL_SEL + ', ' + SLIDES_CONTAINER_SEL + ', ' + SLIDES_WRAPPER_SEL).each(function () {\n //unwrap not being use in case there's no child element inside and its just text\n $(this).replaceWith(this.childNodes);\n });\n\n //removing the applied transition from the fullpage wrapper\n container.css({\n '-webkit-transition': 'none',\n 'transition': 'none'\n });\n\n //scrolling the page to the top with no animation\n $htmlBody.scrollTop(0);\n\n //removing selectors\n var usedSelectors = [SECTION, SLIDE, SLIDES_CONTAINER];\n $.each(usedSelectors, function (index, value) {\n $('.' + value).removeClass(value);\n });\n }", "title": "" }, { "docid": "6260b4cf49062b8377e81d5c48edfeaf", "score": "0.5597011", "text": "function destroyStructure() {\n //reseting the `top` or `translate` properties to 0\n silentScroll(0);\n\n //loading all the lazy load content\n container.find('img[data-src], source[data-src], audio[data-src], iframe[data-src]').each(function () {\n setSrc($(this), 'src');\n });\n\n container.find('img[data-srcset]').each(function () {\n setSrc($(this), 'srcset');\n });\n\n $(SECTION_NAV_SEL + ', ' + SLIDES_NAV_SEL + ', ' + SLIDES_ARROW_SEL).remove();\n\n //removing inline styles\n $(SECTION_SEL).css({\n 'height': '',\n 'background-color': '',\n 'padding': ''\n });\n\n $(SLIDE_SEL).css({\n 'width': ''\n });\n\n container.css({\n 'height': '',\n 'position': '',\n '-ms-touch-action': '',\n 'touch-action': ''\n });\n\n $htmlBody.css({\n 'overflow': '',\n 'height': ''\n });\n\n // remove .fp-enabled class\n $('html').removeClass(ENABLED);\n\n // remove .fp-responsive class\n $body.removeClass(RESPONSIVE);\n\n // remove all of the .fp-viewing- classes\n $.each($body.get(0).className.split(/\\s+/), function (index, className) {\n if (className.indexOf(VIEWING_PREFIX) === 0) {\n $body.removeClass(className);\n }\n });\n\n //removing added classes\n $(SECTION_SEL + ', ' + SLIDE_SEL).each(function () {\n if (options.scrollOverflowHandler) {\n options.scrollOverflowHandler.remove($(this));\n }\n $(this).removeClass(TABLE + ' ' + ACTIVE);\n $(this).attr('style', $(this).data('fp-styles'));\n });\n\n removeAnimation(container);\n\n //Unwrapping content\n container.find(TABLE_CELL_SEL + ', ' + SLIDES_CONTAINER_SEL + ', ' + SLIDES_WRAPPER_SEL).each(function () {\n //unwrap not being use in case there's no child element inside and its just text\n $(this).replaceWith(this.childNodes);\n });\n\n //removing the applied transition from the fullpage wrapper\n container.css({\n '-webkit-transition': 'none',\n 'transition': 'none'\n });\n\n //scrolling the page to the top with no animation\n $htmlBody.scrollTop(0);\n\n //removing selectors\n var usedSelectors = [SECTION, SLIDE, SLIDES_CONTAINER];\n $.each(usedSelectors, function (index, value) {\n $('.' + value).removeClass(value);\n });\n }", "title": "" }, { "docid": "bf6824ba62b80a550c2307b4ea76d738", "score": "0.5591987", "text": "function stop() {\n // reset everything to init state\n busy = true;\n $(center).removeClass();\n if (imageObj != null) { imageObj.onload = imageObj.onerror = null; imageObj = null; }\n if (ajaxReq != null) { ajaxReq.abort(); ajaxReq = null; } \n if (slideshowTimeout != null) {clearTimeout(slideshowTimeout); slideshowTimeout = null; }\n if (busyTimeout != null) {clearTimeout(busyTimeout); busyTimeout = null; }\n if (closeTimeout != null) {clearTimeout(closeTimeout); closeTimeout = null; }\n if (inlineObj != null) {\n // put inline object back to it's place\n $(inlineParent).append($(inlineObj).css({display: inlineDisplay}));\n inlineObj = inlineParent = inlineDisplay = null;\n }\n videoWidescreen = loadError = false;\n resourceWidth = resourceHeight = 0;\n $(container).empty();\n $(center).css({borderRadius: options.cornerRadius});\n $(bottomContainer).css({borderBottomLeftRadius: options.cornerRadius, borderBottomRightRadius: options.cornerRadius});\n $([center, bottom]).stop(true);\n $([navLinks, caption, number]).css({display: 'none'});\n $([caption, number]).removeClass().html(\"\");\n $([container, bottomContainer, prevLink, nextLink]).stop(true).css({display: \"none\"});\n }", "title": "" }, { "docid": "3903a1db5693ecd24cecbc52deae5c4f", "score": "0.5589226", "text": "function removeAnnoyingCode(){\r\n showOrHideClass('b-4', 'none');\r\n showOrHideClass('b-3', 'none');\r\n var idsToDelete = new Array (\r\n\t\t\t\t 'info',\r\n\t\t\t\t 'aContainer',\r\n\t\t\t\t 'premium',\r\n\t\t\t\t 'tableFooters',\r\n\t\t\t\t 'priceTable');\r\n for (var i = 0; i < idsToDelete.length ; i++){\r\n\tcurrElement = document.getElementById(idsToDelete[i]);\r\n\tcurrElement.style.display = \"none\";\r\n }\r\n\r\n var partWithNoId = document.getElementsByTagName('div')[120];\r\n partWithNoId.style.display = \"none\";\r\n}", "title": "" }, { "docid": "f1ab4dde09f29366271f988da00899c9", "score": "0.55856454", "text": "function _discardVideo() {\n var filepath = file.split(\"/\");\n var fileEnd = filepath[6];\n var fileString = fileEnd.toString();\n var myFolder = fileSystemModule.knownFolders.temp();\n myFile = myFolder.getFile(fileString);\n if (myFile) {\n myFile.remove();\n } else {\n console.error(\"Couldn't remove \" + fileString + \" because the file does not exist.\");\n }\n}", "title": "" }, { "docid": "9fa8626a70519be0eb138572d0166c68", "score": "0.55842465", "text": "function skip() {\n var fullText = \"\";\n for (let i = 0; i < texts.length; i++) {\n fullText += texts[i] + \"<br>\";\n }\n $(\"#texte\").html(fullText);\n $(\"#next\").html(\"C'est parti !\").off('click').attr(\"id\", \"start\");\n $(\"#skipIntroduction\").remove();\n $(\"#start\").click(function () {\n $(\"#introduction\").remove();\n nextFlag(levelCounter.getValue());\n start = new Date();\n $(\"body\").removeClass(\"popup\");\n $(\"#scoreBoard\").show();\n $(\"#time\").show();\n $(\"#joker\").fadeIn();\n $('#skip').fadeIn();\n music.play();\n inGame = true;\n })\n}", "title": "" }, { "docid": "a3546a5c064bafb0226b4d7e1caa6d1c", "score": "0.5580926", "text": "function removeTopContents(){\n\ttop.remove(\"answersVector\");\n\ttop.remove(\"questionObject\");\n\ttop.remove(\"featureArray\");\n\ttop.remove(\"constraintData\");\n\ttop.remove(\"linkArray\");\n\ttop.remove(\"checkedVals\");\n\ttop.remove(\"changedLinkData\");\n}", "title": "" }, { "docid": "af7e7c8260941825e0ded4b1af9d1a2e", "score": "0.55805844", "text": "function clean(e, tag) {\n var targetList = e.getElementsByTagName(tag);\n var isEmbed = (tag == 'object' || tag == 'embed');\n\n for (var y = targetList.length - 1; y >= 0; y--) {\n /* Allow youtube and vimeo videos through as people usually want to see those. */\n if (isEmbed && targetList[y].innerHTML.search(regexps.videoRe) !== -1) {\n continue;\n }\n if (targetList[y] && targetList[y].parentNode) {\n var oParentNode = targetList[y].parentNode;\n oParentNode.removeChild(targetList[y]);\n }\n }\n }", "title": "" }, { "docid": "e9c9f58bf5ede1284baac7fd7eade1b1", "score": "0.55766153", "text": "function removeMinusOneImage() {\n minusOneImg.style.visibility = \"hidden\";\n document.body.removeChild(minusOneImg)\n }", "title": "" }, { "docid": "5700faf00bc192ae6f310bcaf98c0aa6", "score": "0.55699116", "text": "function suicide() {\n console.log(`Playing Favourites ${version} content script orphaned`);\n wrapObserver.disconnect();\n observer.disconnect();\n window.removeEventListener(\"PlayingFavouritesLoad\", suicide);\n document.getElementById(\"main\").removeEventListener(\"click\", protectAvoids, true);\n}", "title": "" }, { "docid": "7d1048add912b15990c5f5d91a85fc8b", "score": "0.5569605", "text": "function _finish() {\r\n\t\t\t$('#jquery-videobox').remove();\r\n\t\t\t$('#jquery-overlay').fadeOut(function() { $('#jquery-overlay').remove(); });\r\n\t\t\t// Show some elements to avoid conflict with overlay in IE. These elements appear above the overlay.\r\n\t\t\t$('embed, object, select').css({ 'visibility' : 'visible' });\r\n\t\t}", "title": "" }, { "docid": "8735d6918a26e8a29420cae70dc68408", "score": "0.5562763", "text": "function removeHTML5Player () {\n\t// TODO: does HTML5 video need any specific disposal?\n\tvar el = get(this.id);\n\tif (el)\n\t remove(el);\n}", "title": "" }, { "docid": "54be72f0fb950d1465ac671a43728d22", "score": "0.5559179", "text": "function instructionsButtonClicked(event) {\n stage.removeChild(game);\n player.destroy();\n game.removeAllChildren();\n game.removeAllEventListeners();\n currentState = constants.INSTRUCTIONS_STATE;\n changeState(currentState);\n }", "title": "" }, { "docid": "c2c40b0386427f43a6fa54955ea3f13a", "score": "0.55588686", "text": "function clearThePreview()\n{\n $('.link-preview-container').remove();\n $('.discussion-image-btn').css('display','block');\n sitePreviewResult = {};\n previewLink = null;\n previewLinkLogo = null;\n previewLinkDescription = null;\n previewLinkTitle = null;\n}", "title": "" }, { "docid": "74ca82d8cda65d602b8dca1e2b695da2", "score": "0.5557212", "text": "function passPage2(){\n document.getElementById(\"homescreen\").style.display=\"none\";\n document.getElementById(\"showMovies\").style.display=\"block\";\n //document.getElementById(\"showMovies\").style.display=\"none\";\n document.getElementById(\"video\").innerHTML=\"\";\n}", "title": "" }, { "docid": "2e9a4f60de3743b8526f883dace6d45a", "score": "0.5555004", "text": "function step2() {\n $('#their-videos').empty();\n $('#join-room').focus();\n\n //Maximize Self Camera\n maximizeCamera();\n }", "title": "" } ]
c4099f7471e142c3529e52479406ee4d
Sort function to sort ranges by start position.
[ { "docid": "96ee64b337f1b0a03a16ede6d7e9b726", "score": "0.7910273", "text": "function sortByRangeStart (a, b) {\n return a.start - b.start\n}", "title": "" } ]
[ { "docid": "ea0c1ca6fb250033e06eb4168a10572a", "score": "0.799007", "text": "function sortByRangeStart(a, b) {\n\t return a.start - b.start;\n\t}", "title": "" }, { "docid": "ea0c1ca6fb250033e06eb4168a10572a", "score": "0.799007", "text": "function sortByRangeStart(a, b) {\n\t return a.start - b.start;\n\t}", "title": "" }, { "docid": "f68c07784bfdd2929e71349944b749eb", "score": "0.79646796", "text": "function sortByRangeStart (a, b) {\n\t return a.start - b.start\n\t}", "title": "" }, { "docid": "f68c07784bfdd2929e71349944b749eb", "score": "0.79646796", "text": "function sortByRangeStart (a, b) {\n\t return a.start - b.start\n\t}", "title": "" }, { "docid": "a72d5ccc2b2e26177fe366ab552f8a1e", "score": "0.7957905", "text": "function sortByRangeStart(a, b) {\n return a.start - b.start;\n}", "title": "" }, { "docid": "a72d5ccc2b2e26177fe366ab552f8a1e", "score": "0.7957905", "text": "function sortByRangeStart(a, b) {\n return a.start - b.start;\n}", "title": "" }, { "docid": "a72d5ccc2b2e26177fe366ab552f8a1e", "score": "0.7957905", "text": "function sortByRangeStart(a, b) {\n return a.start - b.start;\n}", "title": "" }, { "docid": "70c55959d683f02314832fbc2d5edc23", "score": "0.70046455", "text": "function sortByRangeIndex(a, b) {\n\t return a.index - b.index;\n\t}", "title": "" }, { "docid": "70c55959d683f02314832fbc2d5edc23", "score": "0.70046455", "text": "function sortByRangeIndex(a, b) {\n\t return a.index - b.index;\n\t}", "title": "" }, { "docid": "abe445a39898109681229c806c00dff3", "score": "0.69732624", "text": "function sortByRangeIndex (a, b) {\n\t return a.index - b.index\n\t}", "title": "" }, { "docid": "abe445a39898109681229c806c00dff3", "score": "0.69732624", "text": "function sortByRangeIndex (a, b) {\n\t return a.index - b.index\n\t}", "title": "" }, { "docid": "dbc76d2ad67002d701308011fbc04e33", "score": "0.6952638", "text": "function sortByRangeIndex(a, b) {\n return a.index - b.index;\n}", "title": "" }, { "docid": "dbc76d2ad67002d701308011fbc04e33", "score": "0.6952638", "text": "function sortByRangeIndex(a, b) {\n return a.index - b.index;\n}", "title": "" }, { "docid": "dbc76d2ad67002d701308011fbc04e33", "score": "0.6952638", "text": "function sortByRangeIndex(a, b) {\n return a.index - b.index;\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "822222312ef77b25952bfaacecdd438f", "score": "0.6906382", "text": "function sortByRangeIndex (a, b) {\n return a.index - b.index\n}", "title": "" }, { "docid": "efb9b4f2d458bbd573e62993b6e4535b", "score": "0.6549934", "text": "function sortByStart(period1, period2){ return period1.start > period2.start; }", "title": "" }, { "docid": "e1a26c14f4583d0899d2bf1e8e447ab2", "score": "0.6546154", "text": "function sortRange(r) {\n if (r.minimum > r.maximum) {\n return new RangeMinMax(r.maximum, r.minimum);\n }\n return r;\n}", "title": "" }, { "docid": "4e60d0b2b7ede9e83becae9cffb44afc", "score": "0.6282235", "text": "function sortRanges(ranges, mapType) {\n ranges = ranges.sort(function (a, b) {\n return parseFloat(b.SoS) - parseFloat(a.SoS);\n });\n return ranges;\n }", "title": "" }, { "docid": "fbcc024ce41228bb619d26d2ce5ae4a4", "score": "0.61181027", "text": "function sortArrayByInt(a, b){\n\t//set the element to the beginning tier number\n\tvar a = a.start;\n\tvar b = b.start;\n\n\t// return whether it is greator or smaller\n\treturn ((a < b) ? -1 : ((a > b) ? 1 : 0));\n}", "title": "" }, { "docid": "0eb161515a2bfc2bd8f7ad8baa69b18c", "score": "0.61153674", "text": "function partition(arr, start = 0, end = arr.length - 1) {\n // pivot is set at the end of the array\n // the pivot is a number we will compare other numbers against,\n // and eventually this one number will be set into a \n // sorted position\n let pivot = arr[end],\n // this is where the pivot will move to become sorted\n pIndex = start;\n \n // go over the array from the start to end - 1\n // (because the last element is the pivot),\n // make sure that all the elements less than the pivot \n // remain to the left of the pivot, and everything greater\n // is on the right of the pivot \n for (let i = start; i < end; i++) {\n if (arr[i] <= pivot) {\n swap(arr, i, pIndex);\n pIndex++;\n }\n }\n\n // once the rest of the numbers are set in place,\n // pIndex is at the position where the pivot should be\n // in order to be considered sorted. \n // therefore we're swapping the end index (where the pivot\n // currently is) with the pIndex position.\n swap(arr, end, pIndex);\n\n // pIndex is then returned to be used for recursive calls\n return pIndex;\n}", "title": "" }, { "docid": "6c97744c00d2562449c7e9abd87beada", "score": "0.6058676", "text": "function compareRanges(range1, range2) {\r\n\treturn range1.start - range2.start; // earlier ranges go first\r\n}", "title": "" }, { "docid": "f9a44435ad38ddf194cf7613b106fc5b", "score": "0.60389996", "text": "function compareRanges(range1, range2) {\n\treturn range1.start - range2.start; // earlier ranges go first\n}", "title": "" }, { "docid": "f9a44435ad38ddf194cf7613b106fc5b", "score": "0.60389996", "text": "function compareRanges(range1, range2) {\n\treturn range1.start - range2.start; // earlier ranges go first\n}", "title": "" }, { "docid": "f9a44435ad38ddf194cf7613b106fc5b", "score": "0.60389996", "text": "function compareRanges(range1, range2) {\n\treturn range1.start - range2.start; // earlier ranges go first\n}", "title": "" }, { "docid": "f9a44435ad38ddf194cf7613b106fc5b", "score": "0.60389996", "text": "function compareRanges(range1, range2) {\n\treturn range1.start - range2.start; // earlier ranges go first\n}", "title": "" }, { "docid": "f9a44435ad38ddf194cf7613b106fc5b", "score": "0.60389996", "text": "function compareRanges(range1, range2) {\n\treturn range1.start - range2.start; // earlier ranges go first\n}", "title": "" }, { "docid": "0cc1345f69a683db6a34a9abdc889318", "score": "0.60300773", "text": "static _sortBefore(siblings, idx, sortKey) {\n let max = siblings[idx] ? siblings[idx].data[sortKey] : null;\n let min = siblings[idx - 1] ? siblings[idx - 1].data[sortKey] : null;\n return [min, max];\n }", "title": "" }, { "docid": "5c1eddd282ff3086644b0f9f6ad915c4", "score": "0.6005432", "text": "function compareRanges(range1, range2) {\n\t\treturn range1.start - range2.start; // earlier ranges go first\n\t}", "title": "" }, { "docid": "5c1eddd282ff3086644b0f9f6ad915c4", "score": "0.6005432", "text": "function compareRanges(range1, range2) {\n\t\treturn range1.start - range2.start; // earlier ranges go first\n\t}", "title": "" }, { "docid": "8fb2bbd25aca56c9602e44dc70b4944c", "score": "0.59840083", "text": "function sortFunc(a, b) {\n var aStartP = a.StartPoint;\n var bStartP = b.StartPoint;\n\n var aDate = a.DateTime;\n var bDate = b.DateTime;\n\n if (aDate == bDate) {\n return (aStartP < bStartP) ? -1 : (aStartP > bStartP) ? 1 : 0;\n }\n else {\n return (aDate < bDate) ? -1 : 1;\n }\n}", "title": "" }, { "docid": "58b5ca5cb4b83840415b7b57eb215de1", "score": "0.58693326", "text": "function quickSort(list, start = 0, end=list.length-1) {\n if (start < end) {\n let pIndex = partition(list, start, end); // call partition or randomizedPartition for better time complexity\n quickSort(list, start, pIndex-1);\n quickSort(list, pIndex+1, end);\n }\n return list;\n}", "title": "" }, { "docid": "090c48cc5b97f95aac1286bd0c3934d3", "score": "0.5868108", "text": "function partition(values,start,end){\n var tempArray = values;\n var value = values[start];\n swap(values,start,end);\n for(var i = start;i<end;i++){\n if(values[i]<=value){\n swap(values,start++,i);\n }\n }\n swap(values,end,start);\n return start;\n\n}", "title": "" }, { "docid": "6a4558fbaaae1e56e54b18ee15700191", "score": "0.58608466", "text": "function quickSort(arr, start, end) {\n if (start >= end) {\n return\n }\n var pIndex = partition(arr, start, end)\n quickSort(arr, start, pIndex-1)\n quickSort(arr, pIndex+1, end)\n return arr\n}", "title": "" }, { "docid": "6793f2dff2027fdcaa46c702c9b9f569", "score": "0.5846765", "text": "sort() {\n this.linkedList.add('start',this.list.slice(),1);\n\n this.linkedList.add('check',this.list.slice(),3);\n\n if (this.list.length <= 1) {\n this.linkedList.add('end',this.list.slice(),5);\n return this.list;\n }//check to see if the list is only one element or shorter\n\n for (let indexStart = 0; indexStart <= this.list.length - 1; indexStart++) {\n\n this.linkedList.add('iterator',indexStart,11);\n\n let minIndex = null;\n\n this.linkedList.add('minindex',minIndex,13);\n\n for (let indexIterator = indexStart; indexIterator <= this.list.length - 1; indexIterator++) {\n \n this.linkedList.add('comparator',minIndex,16);\n this.linkedList.add('comparee',indexIterator,18);\n \n if (this.list[indexIterator] < this.list[minIndex] || minIndex === null) {\n minIndex = indexIterator;//searching for lowest index\n \n }\n this.linkedList.add('comparator',minIndex,20);\n\n }\n let smallerNumber = this.list[indexStart];\n this.list[indexStart] = this.list[minIndex];\n this.list[minIndex] = smallerNumber;\n this.linkedList.add('swap',[minIndex,indexStart],27);\n \n }\n\n // this.linkedList.add('end',minIndex,29);\n\n return this.list;\n }", "title": "" }, { "docid": "af68e980c612639548d4a94f02d7eb12", "score": "0.58430994", "text": "function mergeSort(array, start, end) {\n // base case\n if (start < end) {\n // find the middle point\n let middle = Math.floor((start + end) / 2);\n\n mergeSort(array, start, middle); // sort first half\n mergeSort(array, middle + 1, end); // sort second half\n\n // merge the sorted halves\n merge(array, start, middle, end);\n }\n}", "title": "" }, { "docid": "29ce6de563da473239beaad0ca183d66", "score": "0.5835555", "text": "function sortRec(a, start, end) {\n if (end - start < 2) {\n return;\n }\n\n const originalPivotIndex = medianPivotIndex(a, start, end);\n const finalPivotIndex = partition(a, start, end, originalPivotIndex);\n sortRec(a, start, finalPivotIndex);\n sortRec(a, finalPivotIndex + 1, end);\n}", "title": "" }, { "docid": "0a20164d5963115ac977ab111cb6285f", "score": "0.5821569", "text": "function quickSort(array, start = 0, end = array.length) {\n // break case if start is greater or equal to end\n if (start >= end) {\n return array;\n }\n \n const middle = partition(array, start, end);\n array = quickSort(array, start, middle);\n array = quickSort(array, middle + 1, end);\n return array;\n}", "title": "" }, { "docid": "4d9716069d3bc004c9071c97ba998c07", "score": "0.58128107", "text": "doSort(low, high) {\n\t\tif(low < high) {\n\t\t\tlet sortedPos = this.partition(low, high);\n\t\t\tlow < sortedPos -1 ? this.doSort(low , sortedPos) : '';\n\t\t\thigh > sortedPos ? this.doSort(sortedPos + 1, high) : '';\n\t\t} else {\n\t\t\t//console.log(this.arrData);\n\t\t}\n\t}", "title": "" }, { "docid": "fcd95acee2249baa5e1a843728f6730e", "score": "0.577977", "text": "function quickSort(list, start = 0, end = list.length - 1) {\n if (start < end) {\n const pivotIndex = pivot(list, start, end);\n quickSort(list, start, pivotIndex - 1);\n quickSort(list, pivotIndex + 1, end);\n }\n return list;\n}", "title": "" }, { "docid": "cee4868689555409d3206212761c0964", "score": "0.57694864", "text": "function selectionSort(arr) {\n // let start = 0, min = arr[0], minIdx = 0 //NO THIS DOESN'T WORK BUT MIN AT THE START WILL ALWAYS BE THE SMALLEST IF YOU SET MIN TO BE OUTSIDE OF THE LOOP!\n let start = 0,\n min,\n minIdx,\n shouldSwap = false;\n while (start < arr.length) {\n //last number should already be sorted at the time we handle the 2nd to last number\n min = arr[start];\n minIdx = start;\n for (let i = start; i < arr.length; i++) {\n if (arr[i] < min) {\n min = arr[i];\n minIdx = i;\n shouldSwap = true;\n }\n }\n if (shouldSwap) [arr[start], arr[minIdx]] = [arr[minIdx], arr[start]];\n start++;\n }\n return arr;\n}", "title": "" }, { "docid": "9e7b5e122dd8f791732dbbc2986c0cbf", "score": "0.5758189", "text": "sortAnnotations () {\n this._annotations.sort((a,b) => {\n return a.range.start < b.range.start ? -1 : (a.range.start > b.range.start ? 1 : 0);\n });\n }", "title": "" }, { "docid": "3e47cf76a65b15a4ae89d915882f71ec", "score": "0.57543945", "text": "function arrangeListByPivot(list, start, end, pivotIndex) {\n\n for (let i = end - 1; i >= start; i--) {\n\n if (list[i] > list[pivotIndex]) {\n\n // do two swaps.\n if ((pivotIndex - i) != 1) {\n [list[pivotIndex], list[pivotIndex - 1]] = [list[pivotIndex - 1], list[pivotIndex]];\n // console.log('swap');\n }\n\n [list[pivotIndex], list[i]] = [list[i], list[pivotIndex]];\n // console.log('swap');\n\n // The new index for the pivot\n pivotIndex--;\n\n }\n\n }\n\n return pivotIndex;\n}", "title": "" }, { "docid": "ad5d5ed8b530ea1c697f57e2a2d880b1", "score": "0.574595", "text": "function merge_sort(arr,start,end){\n let count = 0 \n if(start < end){ // 0< 5\n let mid = Math.floor((start+end)/2) // \n merge_sort(arr,start,mid)\n merge_sort(arr,mid+1,end)\n count += mergeSortFunction(arr,start,end)\n }\n return count\n }", "title": "" }, { "docid": "58406c92f55d81465b9eda1ac75ec4e7", "score": "0.5738594", "text": "function sortByStartDate(a,b) {\n if (a.startDate < b.startDate) {\n return -1;\n }\n if (a.startDate > b.startDate) {\n return 1;\n }\n return 0;\n }", "title": "" }, { "docid": "8ec0ec8aea4a17049be06d544aed8f40", "score": "0.573842", "text": "_resortPoints(points, start, stop) {\n let sorted = [];\n\n if (points.indexOf(start) === -1 || points.indexOf(stop) === -1) {\n throw Error('Point array must consist both start and stop elements');\n }\n\n let idx = points.indexOf(start) + 1;\n let condition = true; // constant condition is eslint error\n while (condition) {\n if (idx >= points.length) idx = 0;\n if (points[idx] === stop) condition = false;\n else sorted.push(points[idx++]);\n }\n\n return sorted;\n }", "title": "" }, { "docid": "2811c0b0ff7bd53b4ef6019255cc173c", "score": "0.5729594", "text": "quickSort(arr, start, end) {\n // console.log(arr);\n let pivot_index;\n if (start < end) {\n pivot_index = this.partition(arr, start, end);\n\n this.quickSort(arr, start, pivot_index - 1);\n this.quickSort(arr, pivot_index + 1, end);\n }\n return arr;\n }", "title": "" }, { "docid": "40d45d2863d82669d519753a6d13a37b", "score": "0.5726084", "text": "function compareStartEnd(min0, max0, min1, max1) {\n return max0 > min1 && min0 < max1;\n}", "title": "" }, { "docid": "af9abd3366b9632ebbb39ec59bb94b91", "score": "0.5721785", "text": "function quickSort(array, start = 0, end = array.length){\n if(start >= 0) {\n return array\n }\n\n const middle = partition(array, start, end)\n array = quickSort(array, start, middle)\n array = quickSort(array, middle + 1, end)\n return array\n}", "title": "" }, { "docid": "5706dcdde40b192211086947f953cfd8", "score": "0.5707", "text": "function partition(arr, start, end){\n if(!start) start = 0; \n if(!end) end = arr.length - 1; \n var pivot = arr[end];\n var pindex = start; \n for(var i = start; i < end; i++){\n if(arr[i] <= pivot){\n var temp = arr[i];\n arr[i] = arr[pindex];\n arr[pindex] = temp; \n pindex++;\n }\n }\n\n arr[end] = arr[pindex];\n arr[pindex] = pivot; \n return pindex;\n}", "title": "" }, { "docid": "aa7d188c702b6e1f2b29d3660b1254c0", "score": "0.56898266", "text": "function quickSort(array, start = 0, end = array.length) {\n if (start >= end) {\n return array;\n }\n const middle = partition(array, start, end);\n array = quickSort(array, start, middle);\n array = quickSort(array, middle + 1, end);\n return array;\n}", "title": "" }, { "docid": "d92604711b87de1a3c07dabeb2cbb975", "score": "0.568969", "text": "function quickSort(array, start = 0, end = array.length) {\n if (start >= end) {\n return array;\n }\n const middle = partition(array, start, end);\n array = quickSort(array, start, middle);\n array = quickSort(array, middle + 1, end);\n return array;\n}", "title": "" }, { "docid": "46992f3816fef271bf95c0b24682cb98", "score": "0.56873953", "text": "function range(start=0, end, step=1) {\n\t/*\n\tif (start === undefined) {\n\t\tstart = 0\n\t}\n\tif (step === undefined) {\n\t\tstep = 1\n\t}\n\t*/\n\tlst = [];\n\tfirst = start;\n\tlast = end;\n\tif (step > 0) {\n\t\t// Rereading the textbook, the start is alwas the beginning number\n\t\t// of the range, not the 'lower' number. Whoops.\n\t\t//first = start\n\t\t//last = end\n\t\ttest = (i) => i <= end;\n\t} else if (step < 0) {\n\t\t//first = end\n\t\t//last = start\n\t\ttest = (i) => i >= end;\n\t}\n\n\tfor (let i = first; test(i); i += step) {\n\t\tlst.push(i)\n\t}\n\treturn lst\n}", "title": "" }, { "docid": "089693049fc13a2de8e896aceaeb56e1", "score": "0.5640853", "text": "function sortbyloctime(x,y){\n\tif (x.frag===y.frag) {\n\t if ((x.tstamp)&&(y.tstamp)) {\n\t\tif (x.tstamp<y.tstamp) return -1;\n\t\telse if (x.tstamp>y.tstamp) return 1;\n\t\telse return 0;}\n\t else if (x.tstamp) return 1;\n\t else if (y.tstamp) return -1;\n\t else return 0;}\n\telse if (x.ends_at<=y.starts_at) return 1;\n\telse if (x.starts_at>=y.ends_at) return -1;\n\telse if ((x.ends_at-x.starts_at)>(y.ends_at-y.starts_at))\n\t return 1;\n\telse return -1;}", "title": "" }, { "docid": "02ffe3f4bb1123fad91d58cef5e9295a", "score": "0.5636076", "text": "function selectionsort(){\n var t,l;\n for(var i=0;i<=79;i++){\n var mini=i;\n for(var j=i+1;j<=80;j++){\n if(arr[j]<arr[mini]) \n mini =j;\n }\n var temp=arr[i];\n arr[i]=arr[mini];\n arr[mini]=temp;\n t=arr[i]+\"px\";\n l=arr[mini]+\"px\";\n task1(i,mini,t,l);\n }\n count=0;\n }", "title": "" }, { "docid": "2ebfdebb7e96460e918bedd4e3364ff9", "score": "0.56315374", "text": "function qSort(array, start = 0, end = array.length) {\n if (start >= end) {\n return array;\n }\n const middle = partition(array, start, end);\n array = qSort(array, start, middle);\n array = qSort(array, middle + 1, end);\n return array;\n}", "title": "" }, { "docid": "2391ec34ed247da2708186daef98cb89", "score": "0.5622661", "text": "function normalizeSelection(ranges,primIndex){var prim=ranges[primIndex];ranges.sort(function(a,b){return cmp(a.from(),b.from());});primIndex=indexOf(ranges,prim);for(var i=1;i<ranges.length;i++){var cur=ranges[i],prev=ranges[i-1];if(cmp(prev.to(),cur.from())>=0){var from=minPos(prev.from(),cur.from()),to=maxPos(prev.to(),cur.to());var inv=prev.empty()?cur.from()==cur.head:prev.from()==prev.head;if(i<=primIndex){--primIndex;}ranges.splice(--i,2,new Range(inv?to:from,inv?from:to));}}return new Selection(ranges,primIndex);}", "title": "" }, { "docid": "8f86c3b27b38779b43a1a96049652de0", "score": "0.56201833", "text": "eventSorter(a, b) {\n const startA = a.dataStartMs || a.startDateMS,\n // dataXX are used if configured with fillTicks\n endA = a.dataEndMs || a.endDateMS,\n startB = b.dataStartMs || b.startDateMS,\n endB = b.dataEndMs || b.endDateMS,\n sameStart = startA === startB;\n\n if (sameStart) {\n if (endA - endB === 0) {\n return a.eventRecord.name < b.eventRecord.name ? -1 : 1;\n }\n\n return endA > endB ? -1 : 1;\n }\n\n return startA < startB ? -1 : 1;\n }", "title": "" }, { "docid": "de94b81bdcdfd792f54edced221e6cd8", "score": "0.5613841", "text": "compare(s) {\n if ( s.start < this.start ) {\n return 1;\n } else if ( s.start > this.start ) {\n return -1;\n } else if ( s.end < this.end ) {\n return 1;\n } else if ( s.end > this.end ) {\n return -1;\n }\n return 0;\n }", "title": "" }, { "docid": "de94b81bdcdfd792f54edced221e6cd8", "score": "0.5613841", "text": "compare(s) {\n if ( s.start < this.start ) {\n return 1;\n } else if ( s.start > this.start ) {\n return -1;\n } else if ( s.end < this.end ) {\n return 1;\n } else if ( s.end > this.end ) {\n return -1;\n }\n return 0;\n }", "title": "" }, { "docid": "2a1a2485c165bef7e84a4feafc945568", "score": "0.5597502", "text": "eventSorter(a, b) {\n const startA = a.dataStartMs || a.startMs,\n // dataXX are used if configured with fillTicks\n endA = a.dataEndMs || a.endMs,\n startB = b.dataStartMs || b.startMs,\n endB = b.dataEndMs || b.endMs,\n sameStart = startA === startB;\n\n if (sameStart) {\n if (endA - endB === 0) {\n return a.event.name < b.event.name ? -1 : 1;\n }\n\n return endA > endB ? -1 : 1;\n }\n\n return startA < startB ? -1 : 1;\n }", "title": "" }, { "docid": "612e7938d5f19a33a6c782c67574ed39", "score": "0.55877525", "text": "function qSort(array, start = 0, end = array.length) {\n if (start >= end) {\n return array;\n }\n\n let middle = partition(array, start, end);\n array = qSort(array, start, middle);\n array = qSort(array, middle + 1, end);\n return array;\n}", "title": "" }, { "docid": "3a1481f40965a4d75d2378a40c15c19e", "score": "0.5564221", "text": "function selectionSort(input) {\n for (var i=0; i < input.length; i++) {\n var currMin = input[i];\n var oldIndex = i;\n for (var j=i+1; j < input.length; j++) {\n if (input[j] < currMin) {\n currMin = input[j];\n oldIndex = j;\n } \n } \n var temp = input[i];\n input[i] = currMin;\n input[oldIndex] = temp;\n } \n return input;\n}", "title": "" }, { "docid": "29b3d44630c9a492967c7f21af77edff", "score": "0.55606514", "text": "function sortingAscendent(a,b){ //Sort numbers from lowest to highest\n return a > b ? 1 : b > a ? -1 : 0;\n}", "title": "" }, { "docid": "6c68a909c837cdfcb81fcfccb3382b81", "score": "0.5560012", "text": "function selectionSort(numList) {\n // Initializes min and splice it off the list and puts it in front of list\n let min = Math.min(...numList);\n numList.unshift(numList.splice(numList.indexOf(min), 1))\n\n for(let i = 1; i < numList.length; i++) {\n if(numList[i] >= numList[i+1]) {\n // const x = [numList[i+1], numList[i]];\n [numList[i], numList[i+1]] = [numList[i+1], numList[i]];\n }\n else {\n continue\n } \n }\n console.log(`${numList}`)\n for(let i = 0; i < numList.length; i++) {\n if(numList[i] <= numList[i+1]) {\n continue\n }\n else if(numList[i+1] === undefined) {\n continue\n }\n else {\n console.log(`Not sorted ${numList}`)\n return false\n }\n }\n return true\n}", "title": "" }, { "docid": "3b9fcd2227603752c65d59f221923268", "score": "0.5543117", "text": "selectionSort(nums) {\n let len = nums.length;\n for (let i = 0; i < len; i++) {\n let min = i;\n for (let j = i + 1; j < len; j++) {\n if (nums[min] > nums[j]) {\n min = j;\n }\n }\n if (min !== i) {\n let tmp = nums[i];\n nums[i] = nums[min];\n nums[min] = tmp;\n }\n }\n return nums;\n }", "title": "" }, { "docid": "d5a558dc99788443f8b116dd36bfec55", "score": "0.55381685", "text": "function selectionSort(array){\n\tvar numbers = array.splice(1,+array[0]),\n\t\tlen = +array[0],\n\t\tmin,\n\t\ttemp;\n for (var i = 0; i < len; i += 1) {\n min = i,\n\t\ttemp = 0;\n for (var j = i+1; j < len; j += 1) {\n if (+numbers[j] < +numbers[min]) {\n min = j;\n }\n }\n temp = numbers[i];\n\t\tnumbers[i] = numbers[min];\n\t\tnumbers[min] = temp;\n\t\tconsole.log(numbers[i]);\n }\n}", "title": "" }, { "docid": "9212838926ad16f0696ac047a6c9ad4d", "score": "0.5526053", "text": "function combineRanges (ranges) {\n\t var ordered = ranges.map(mapWithIndex).sort(sortByRangeStart)\n\n\t for (var j = 0, i = 1; i < ordered.length; i++) {\n\t var range = ordered[i]\n\t var current = ordered[j]\n\n\t if (range.start > current.end + 1) {\n\t // next range\n\t ordered[++j] = range\n\t } else if (range.end > current.end) {\n\t // extend range\n\t current.end = range.end\n\t current.index = Math.min(current.index, range.index)\n\t }\n\t }\n\n\t // trim ordered array\n\t ordered.length = j + 1\n\n\t // generate combined range\n\t var combined = ordered.sort(sortByRangeIndex).map(mapWithoutIndex)\n\n\t // copy ranges type\n\t combined.type = ranges.type\n\n\t return combined\n\t}", "title": "" }, { "docid": "9212838926ad16f0696ac047a6c9ad4d", "score": "0.5526053", "text": "function combineRanges (ranges) {\n\t var ordered = ranges.map(mapWithIndex).sort(sortByRangeStart)\n\n\t for (var j = 0, i = 1; i < ordered.length; i++) {\n\t var range = ordered[i]\n\t var current = ordered[j]\n\n\t if (range.start > current.end + 1) {\n\t // next range\n\t ordered[++j] = range\n\t } else if (range.end > current.end) {\n\t // extend range\n\t current.end = range.end\n\t current.index = Math.min(current.index, range.index)\n\t }\n\t }\n\n\t // trim ordered array\n\t ordered.length = j + 1\n\n\t // generate combined range\n\t var combined = ordered.sort(sortByRangeIndex).map(mapWithoutIndex)\n\n\t // copy ranges type\n\t combined.type = ranges.type\n\n\t return combined\n\t}", "title": "" }, { "docid": "6b52d4a89ccf2860c07b77fa6946a5c8", "score": "0.5525982", "text": "function SelectionSort(data){\n for(let i = 0; i < data.length; i++){\n let minIndex = i\n for(let j =i+1; j < data.length; j++){\n if(data[j] < data[minIndex]){\n minIndex = j\n }\n }\n swap(data,i, minIndex)\n }\n return data\n}", "title": "" }, { "docid": "873163188ef2bc0e599b7f59295c9ed1", "score": "0.55231404", "text": "function quickSort(array, start = 0, end = array.length) {\n if (start >= end) {\n return array\n }\n // recursively sort the 2 halves of the array util halves are length of 0 or 1\n const middle = partition(array, start, end)\n array = quickSort(array, start, middle)\n array = quickSort(array, middle + 1, end)\n return array\n}", "title": "" }, { "docid": "1e26c006bc30818b892ecb50e41ada48", "score": "0.5518746", "text": "function pivot(arr, start=0, end=arr.length-1) {\n function swap(array, i, j) {\n let temp = array[i];\n array[i] = array[j];\n array[j] = temp;\n }\n\n let pivot = arr[start];\n // This variable keeps track of where will we swap our pivot to\n // Starts at start\n let swapIdx = start; \n\n // Start at +1 because there's no need to compare start to itself\n for (let i = start + 1; i < arr.length; i++) {\n if (pivot > arr[i]) {\n // If there's something less than 'start'\n // Move swapIdx up, so at the end we can swap start = swapIdx\n swapIdx++;\n // Each time through, swap swapIdx with i: 2 <-> 8 then 1 <-> 8... etc. Refer to console.\n // Which at the very end should place the 'start' at the correct spot\n swap(arr,swapIdx,i); \n console.log(arr);\n }\n }\n swap(arr,start,swapIdx); // Now finally, after loop, swap start with swapIdx\n return swapIdx;\n}", "title": "" }, { "docid": "c949f602e93e69a64e1f54c3d235578b", "score": "0.55112255", "text": "function partitionLomuto(arr, start, end) {\n const pivot = arr[end]; // choose element as pivot\n let i = start; // pivot location\n\n for (let j = start; j < end; j++) {\n if (arr[j] <= pivot) {\n swap(arr, i, j);\n i++;\n }\n }\n // move a pivot to its proper location\n swap(arr, i, end);\n return i;\n}", "title": "" }, { "docid": "f6987895bb2b2b71047dfb0ba3714de6", "score": "0.54991084", "text": "function range(start, end) {\n var arrRange = [];\n if (start < end) {\n for (i = start; i <= end; i++) {\n arrRange.push(i);\n }\n }\n else {\n for (i = start; i >= end; i--) {\n arrRange.push(i);\n }\n }\n return arrRange\n}", "title": "" }, { "docid": "f295c04454b93c379756c29833e54dce", "score": "0.5496753", "text": "function selectionSort(array) {\n let unsortedIndex = 0 // the start of the unsorted portion \n\t\n\twhile (unsortedIndex < array.length-1){\n\t\tlet smallestIndex = unsortedIndex // create ability to track smallest int in array\n\t\tfor (let i = unsortedIndex + 1; i < array.length; i++){ // find smallest on each loop\n\t\t\tif (array[i] < array[smallestIndex]){ // \n\t\t\t\tsmallestIndex = i\n\t\t\t\t}\n\t\t\t}\n\t\tswap(unsortedIndex,smallestIndex, array) //make smalleste change places with start of unsorted\n\t\t\n\t\tunsortedIndex++ // make new start to unsorted section of array, any item before this is sorted\n\t}\n\treturn array\n}", "title": "" }, { "docid": "b54ec62e60147b23f0f83e09e612e265", "score": "0.54579556", "text": "function compareRanges(a, b) {\n const aVal = a[0][Constants.PartitionKeyRange.MinInclusive];\n const bVal = b[0][Constants.PartitionKeyRange.MinInclusive];\n if (aVal > bVal) {\n return 1;\n }\n if (aVal < bVal) {\n return -1;\n }\n return 0;\n }", "title": "" }, { "docid": "34b191dfad61f1e0fb56a138c75cc844", "score": "0.54398024", "text": "function selectionSort(arr){\n var len = arr.length;\n for (let n = 0; n < len; n++) {\n var minInd = n;\n var min = arr[minInd];\n for (let i = n; i < len; i++) {\n if (arr[i] < min) {\n minInd = i;\n min = arr[minInd];\n }\n }\n if (n !== minInd) {\n let temp = arr[n];\n arr[n] = arr[minInd];\n arr[minInd] = temp;\n }\n }\n return arr;\n}", "title": "" }, { "docid": "789115cb353cdd79c21ffb146af15b99", "score": "0.5433752", "text": "function partition(array, start, end) {\n const pivot = array[end - 1];\n let j = start;\n \n for (let i = start; i < end - 1; i++) {\n if (array[i] <= pivot) {\n swap(array, i, j);\n j++;\n }\n }\n\n swap(array, end - 1, j);\n // [1, 5, 13]\n return j;\n}", "title": "" }, { "docid": "1334b6f1d6c2ae090691e7cfd1924dde", "score": "0.542941", "text": "function Selection_Sort(arr, compare_Function) {\r\n function compare(a, b) {\r\n return a - b;\r\n }\r\n let min = 0;\r\n let index = 0;\r\n let temp = 0;\r\n\r\n compare_Function = compare_Function || compare;\r\n\r\n for (let i = 0; i < arr.length; i += 1) {\r\n index = i;\r\n min = arr[i];\r\n\r\n for (let j = i + 1; j < arr.length; j += 1) {\r\n if (compare_Function(min, arr[j]) > 0) {\r\n min = arr[j];\r\n index = j;\r\n }\r\n }\r\n\r\n temp = arr[i];\r\n arr[i] = min;\r\n arr[index] = temp;\r\n }\r\n\r\n return arr;\r\n}", "title": "" }, { "docid": "7d8f13bc39a5483b0be0cb7bc8089717", "score": "0.542231", "text": "function range(start, end, step){\n let rnge = [];\n if (step<0 && start>end){\n for (start; end <= start; start += step)\n rnge.push(start);\n }\n else if (step>0 && start<end){\n for (start; start <= end; start += step){\n rnge.push(start);\n }\n }\n else for (start; start <= end; start++){rnge.push(start);}\n return rnge;\n }", "title": "" }, { "docid": "6a17eebf7985db6a7761913b5be93bc1", "score": "0.54218054", "text": "function selectionSort(arr) {\n for (i = 0; i < arr.length; i++) {\n var min = 0;\n for (j = min; j < arr.length; j++) {\n if (arr[min] > arr[j + 1]) {\n var temp = arr[min];\n arr[min] = arr[j + 1];\n arr[j + 1] = temp;\n }\n }\n }\n}", "title": "" }, { "docid": "d4f75eb03f3aae14d799390f202c7ea1", "score": "0.5418147", "text": "function pivot(arr, start = 0, end = arr.length - 1) {\n\n const swap = (arr, idx1, idx2) => {\n [arr[idx1], arr[idx2]] = [arr[idx2], arr[idx1]];\n };\n // We are assuming the pivot is always the first element\n let pivot = arr[start];\n let swapIdx = start;\n\n for (let i = start + 1; i <= end; i++) {\n if (pivot > arr[i]) {\n swapIdx++;\n swap(arr, swapIdx, i);\n }\n }\n // Swap the pivot from the start the swapPoint\n swap(arr, start, swapIdx);\n return swapIdx;\n}", "title": "" }, { "docid": "62b6f28f01414a7f0b765aa0968dcc81", "score": "0.54153943", "text": "function partition(array, start, end) {\n //grab the last value for pivot\n let pivot = array[end - 1];\n //capture start in a variable (the index of the pivot)\n let j = start;\n\n for (let i = start; i < end - 1; i++) {\n //if any element is less than or equal to pivot, swap the array's elements i and j\n //increase the start count\n if (array[i] <= pivot) {\n swap(array, i, j);\n j++;\n }\n }\n //makes sure that j is being swapped with pivot, to place pivot correctly\n swap(array, end - 1, j);\n // console.log('j:', j);\n return j;\n}", "title": "" } ]
784fab2e4f0760e34e380247f1c8556a
Sets the data of the held object if it exists, otherwise 1 for the id
[ { "docid": "e2b29df0e6e8e61772275095aff15aed", "score": "0.0", "text": "setArrayFromGraspData(array, offset) {\n if(this._heldObject && this._heldObject._pivotPoint.parent == this._grasp) {\n array[offset] = this._heldObject.id;\n this._heldObject.setArrayFromPhysicsData(array, offset + 1);\n } else {\n array[offset] = -1;\n }\n\n }", "title": "" } ]
[ { "docid": "a90e46d6d7f942eacb08db0daf7aa4d6", "score": "0.6266121", "text": "add(data) {\r\n const existing = this.get(data.id);\r\n if (existing && existing.patch) {\r\n existing.patch(data);\r\n this.cache.set(data.id, existing);\r\n }\r\n if (existing)\r\n return existing;\r\n if (data instanceof this.holdable) {\r\n this.cache.set(data.id, data);\r\n return data;\r\n }\r\n else {\r\n const obj = new this.holdable(this.client, data);\r\n this.cache.set(obj.id, obj);\r\n return obj;\r\n }\r\n }", "title": "" }, { "docid": "d27c63f0cbf5c6f58e2e97beae7e8a6f", "score": "0.62220424", "text": "function checkOrGenerateId (data) {\n data = data || {};\n if (!data._id) {\n data._id = apos.utils.generateId();\n }\n return data;\n }", "title": "" }, { "docid": "9baed9f4f2159d6d32c33708071eedb3", "score": "0.62176716", "text": "setHasData(value) {\n heimdall.increment(setHasData);\n this.hasData = value;\n }", "title": "" }, { "docid": "8e429d8915a805f8d481932689158a5d", "score": "0.61067885", "text": "set id (v) { \n this._id[0] = v; \n }", "title": "" }, { "docid": "b969603a47f36ee162dbabcf43bf0542", "score": "0.60116357", "text": "get id() {\n return this.data;\n }", "title": "" }, { "docid": "b969603a47f36ee162dbabcf43bf0542", "score": "0.60116357", "text": "get id() {\n return this.data;\n }", "title": "" }, { "docid": "b3c00fe418fef92453f31fcc0096b3be", "score": "0.6003867", "text": "function updateObjById(id, num) {\n\tvar jsonStr = cookieObj.get(\"datas\");\n\tvar listObj = JSON.parse(jsonStr);\n\tfor(var i = 0, len = listObj.length; i < len; i++) {\n\t\tif(listObj[i].pid == id) {\n\t\t\tlistObj[i].pCount = listObj[i].pCount + num;\n\t\t\tbreak;\n\t\t}\n\t}\n\treturn updateData(listObj)\n}", "title": "" }, { "docid": "309e1b8e8677fe11d68e0701c47cd54a", "score": "0.5998897", "text": "update (id, data) {\n debug('update',id, this._getKey(id), data);\n return super.update(this._getKey(id), data);\n }", "title": "" }, { "docid": "4e242f7b4e231e5cbc08765fb6f94b80", "score": "0.5937726", "text": "set id(id){\r\n this._id = id;\r\n }", "title": "" }, { "docid": "ddbe05290f8a427d141e49a0c09835f7", "score": "0.59113556", "text": "static incrementId(){\n this._id = this.id + 1;\n }", "title": "" }, { "docid": "55f311cf49a4762589ed94548ba320e5", "score": "0.5909219", "text": "function set(table, objectData, callback) {\n getStore(table, function (err, store) {\n if (err) return callback(err);\n\n objectData.id = objectData.id ? objectData.id.toString() : _id();\n store.put(objectData, function (result) {\n callback(null, result);\n }, function (err) {\n void 0;\n callback(err);\n });\n });\n }", "title": "" }, { "docid": "e314f6f47673be4adbe562bbb72076e9", "score": "0.5899952", "text": "function prepareAdd(data, id) {\n data._id = (+data.id > 0) ? +data.id : id\n if (!data.id) data.id = data._id\n else if (+data.id > 0) data.id = +data.id\n return data\n}", "title": "" }, { "docid": "c68ab60faada950514d754a06f190f59", "score": "0.5873876", "text": "setIdNew(id) {\n newId = true;\n idNew = id;\n this.createJson();\n }", "title": "" }, { "docid": "1a2e0cf503e1906e12df541cf7954add", "score": "0.58705705", "text": "function setID(data) {\n for (let i = 0; i < maxNumberOfPlayers + 1; i++) {\n if (i == maxNumberOfPlayers) {\n return i;\n }\n if (usersInRoom[data.room][i] == 0) {\n usersInRoom[data.room][i] = 1; //if specific user is not online, then assign this ID\n playerNamesInRoom[data.room][i] = data.player;\n console.log(\"User \" + i + \" connected.\");\n return i;\n }\n }\n\n }", "title": "" }, { "docid": "cc9235011b67d55866d6d4c5f960429e", "score": "0.5858661", "text": "function u(t){return null==t.getId()&&t.setId(o()()),t}", "title": "" }, { "docid": "52e891968ad7841c71b6e93d877ea2fd", "score": "0.58577186", "text": "get id() {\n return this.data.id;\n }", "title": "" }, { "docid": "c664c135ed2330b1ae0e3670cc2de640", "score": "0.58461547", "text": "function _setTaskDataById(id, data){\n var updates = {}, newTask = null;\n // Update\n for(var i in __CURRENT.__TASKS){\n if(typeof __CURRENT.__TASKS[i].id != 'undefined' && __CURRENT.__TASKS[i].id == id){\n if(data){\n for(var field in data){\n var fieldIsNew = typeof __CURRENT.__TASKS[i].data[field] == 'undefined';\n var fieldIsDifferent = fieldIsNew || (!fieldIsNew && __CURRENT.__TASKS[i].data[field] != data[field]);\n if(fieldIsDifferent){\n __CURRENT.__TASKS[i].data[field] = data[field];\n //console.log('change registered');\n\n // If target task is current task, update it\n if(__CURRENT.__TASK && __CURRENT.__TASKS[i].id == __CURRENT.__TASK.id){\n //console.log('current task change registered');\n __CURRENT.__TASK.data[field] = data[field];\n }\n\n updates[field] = data[field];\n //newTask = __CURRENT.__TASKS[i];\n\n }\n }\n }\n }\n }\n }", "title": "" }, { "docid": "c9ac74a41a6e2e471ffe81e283a3d41b", "score": "0.58286613", "text": "function add() {\n\t\t\tdataRef.transaction(function(dataObj) {\n\t\t\t\treturn (dataObj || 0) + 1;\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "bc1ef92447d35e0c7951ad3a58ff60f5", "score": "0.57767564", "text": "_updateData(data) {\n if (!this._internal) return;\n data.$ready = true;\n data[TAGID] = this.props[TAGID];\n this.__updating = true;\n this._setData(data);\n }", "title": "" }, { "docid": "3c37206f49735b51328e88eeaa864298", "score": "0.5762473", "text": "static async updateOne(collectionName, data) {\n try {\n const db = mongodb.getDB();\n let result = await db.db().collection(collectionName).updateOne({\n \"_id\": data._id\n }, {\n $set: buildUpdateObject(data)\n }, {\n upsert: false\n });\n return result;\n } catch (err) {\n throw err;\n }\n }", "title": "" }, { "docid": "9df52624addddbb44f6b1891107781c5", "score": "0.5750136", "text": "function storeData(id, data, doIndex) {\n\tif (doIndex) {\n\t\taddToIndex(id)\n\t}\n\tstore.set(id, data);\n\treturn data;\n}", "title": "" }, { "docid": "bc1d84851de33ee126c4eef4da8f2908", "score": "0.57460773", "text": "set id(value) {\n this._id = value;\n }", "title": "" }, { "docid": "5604429e5f6021e385e01ebeed9eb45b", "score": "0.5738826", "text": "reInitDataFetch() {\n this._objectid = (this.modeladapter.value ? this.modeladapter.value[this.modeladapter.STORE_ITEM_INDEX_PROP] : null);\n if (this._objectid)\n this.setAttribute(\"objectid\", this._objectid)\n else\n this.removeAttribute(\"objectid\");\n if (store.connected) this.connected(); else this.disconnected();\n }", "title": "" }, { "docid": "2ce73553ab66ab72d4b5856d61a01a0e", "score": "0.57347775", "text": "function setData(data){\n db.idSource = data.idSource;\n db.assemblies = data.assemblies;\n buildIdToName();\n }", "title": "" }, { "docid": "25b78922c3fccbafc112c150cf135082", "score": "0.5697153", "text": "putWithId(id, data, options) {\n // Transactions maybe better but unfortunately we cannot use it to remove data and we need to keep\n // consistency.\n return this.exists(id, options).then((exists) => {\n if (!exists) {\n return Promise.reject(httpError(404));\n }\n return this.connection.call('child', id).call('set', data);\n }).return([id, null]);\n }", "title": "" }, { "docid": "9f6993d13b74267d1c6be8f4f6aba6cc", "score": "0.5663569", "text": "function update (id, data, cb) {\n let key\n if (id) {\n key = ds.key([kind, parseInt(id, 10)])\n } else {\n console.error('NO ID')\n key = ds.key(kind)\n }\n\n console.error('KEY IS', key)\n\n const entity = {\n key: key,\n data: toDatastore(data, ['description'])\n }\n\n console.error('ENTITY IS', entity)\n ds.save(\n entity,\n (err) => {\n console.error('ERROR SAVING: ', err)\n data.id = entity.key.id\n cb(err, err ? null : data)\n }\n )\n}", "title": "" }, { "docid": "ec84e44c2f47f28304e471f5f7a3ad91", "score": "0.56573236", "text": "function getId(){\n var id = 0;\n for(var i = 0; i<data.length; i++) {\n id = Math.max(id, data[i].id());\n }\n return id + 1;\n }", "title": "" }, { "docid": "9ef8bac9b2445703e17bf49fcda45420", "score": "0.5653434", "text": "setCurObjs(id, data) {\n var state = this.state\n var obj = {}\n\n if (id != null) {\n obj.curItem = data.items && data.items.length > 0 ? {...data.items[0]} : state.curItem\n obj.curImage = data.files && data.files.length > 0 ? {...data.files[0]} : state.curImage\n obj.curCategory = data.categories && data.categories.length > 0 ? {...data.categories[0]} : state.curCategory\n this.setState(obj)\n }\n else {\n obj.curItem = this.blank.item()\n obj.curImage = this.blank.image()\n obj.curCategory = this.blank.category()\n this.setState(obj)\n }\n }", "title": "" }, { "docid": "efabe58c52b967d4b3d7f21073e95398", "score": "0.5647109", "text": "updateId(id) {\n this._id = id;\n }", "title": "" }, { "docid": "a693b390706b943835d2831be5d491b0", "score": "0.5642019", "text": "findId(id = null) {\n\t\tif (id !== null) {\n\n\t\t\tthis.data = this.getData()\n\t\t\tthis.currentKey = this.getRowKey(id, this.data)\n\n\t\t\tif (this.data.length >= 1 && this.data[this.currentKey]) {\n\n\t\t\t\tconst data_item = this.data[this.currentKey]\n\t\t\t\n\t\t\t\tfor(let field in data_item) {\n\t\t\t\t\tthis[field] = data_item[field]\n\t\t\t\t}\n\t\t\t\tthis.obj.id = data_item.id\n\t\t\t\tthis.currentId = this.obj.id\n\t\t\t\tthis.data = []\n\t\t\t\tthis.currentKey = null\n\n\t\t\t} else return false\n\t\t} else {\n\n\t\t\tthis.setData()\n\t\t\tthis.limit(1, 0)\n\t\t\tthis.findAll()\n\n\t\t\tif (this.data.length >= 1) {\n\n\t\t\t\t// this.currentKey = this.getRowKey(this.currentId)\n\t\t\t\t\n\t\t\t\tconst data_item = this.data[0]\n\n\t\t\t\tthis.data = []\n\n\t\t\t\tfor(let field in data_item) {\n\t\t\t\t\tthis.obj[field] = data_item[field]\n\t\t\t\t}\n\t\t\t\tthis.obj.id = data_item.id\n\t\t\t\tthis.currentKey = null\n\t\t\t\tthis.currentId = this.obj.id\n\t\t\t}\n\t\t}\n\t\treturn this.obj\n\t}", "title": "" }, { "docid": "7ecbb06bebfc006271cf38d927333237", "score": "0.5637556", "text": "update(collection, id, data) {\n // retornamos con el then, nos reqgresa una instancia de la base de datos\n return (\n this.connect()\n .then((db) => {\n // retornamos la base de datos, le pasamos el nombre de la aplicacion\n // updateOne, si no existe lo creo , o lo actualisa, con $set.\n // no es nesesario el array, por que devuelve un objeto\n return db\n .collection(collection)\n .updateOne({ _id: ObjectId(id) }, { $set: data }, { upsert: true });\n })\n // .then((resultado) => resultado.updsertedId || id);\n .then((resultado) => resultado.upsertedId || id)\n );\n }", "title": "" }, { "docid": "6e9ba5975fdc4b8bae0600ac45fb14f4", "score": "0.5635282", "text": "set data(value) { this._data = value; }", "title": "" }, { "docid": "ce1fa86ad3da99e473080d001d49e146", "score": "0.56239754", "text": "update(id, dinetable) {\n return 1;\n }", "title": "" }, { "docid": "ff44d2e72c85c93d978aa9c30b714ee4", "score": "0.56183225", "text": "_updateObjectId(){\n const newId = Math.round( Math.random() * 100 );\n this.myObject = {\n ...this.myObject,\n id: newId,\n };\n }", "title": "" }, { "docid": "02b48f74991e736a14326b3b2ec80db1", "score": "0.5608823", "text": "function update (id, data, cb) {\n let key;\n if (id) {\n key = ds.key([kind, id+'']);\n } else {\n key = ds.key([kind, uuidv4()]);\n }\n\n const entity = {\n key: key,\n data: toDatastore(data, ['description'])\n };\n\n ds.save(\n entity,\n (err) => {\n data.id = entity.key.name;\n cb(err, err ? null : data);\n }\n );\n}", "title": "" }, { "docid": "3cf31f8e3409784cd490eaae8deb0451", "score": "0.558391", "text": "function t_set_id(obj){t_id++;id='t_'+t_id; if(obj.id){return obj.id;}try {obj.setAttribute('id',id);} catch(e){obj.id=id;}return id;}", "title": "" }, { "docid": "4ec478facf7749c18a3058ecbdc57734", "score": "0.55822134", "text": "function r(e){return Object.defineProperty(e.data(),\"id\",{value:e.id})}", "title": "" }, { "docid": "903af969e1f6b048b44192fec8cead79", "score": "0.55820304", "text": "set id(v) {\n this._id = v;\n }", "title": "" }, { "docid": "903af969e1f6b048b44192fec8cead79", "score": "0.55820304", "text": "set id(v) {\n this._id = v;\n }", "title": "" }, { "docid": "d2647611c7a031429055150544db4c50", "score": "0.5571959", "text": "function updateOne(id, object) {\n\tconst docRef = db.collection(DATA).doc(id)\n\tdocRef.update(object)\n}", "title": "" }, { "docid": "a1e095cf45b00bc4f7bb392c1fb3747f", "score": "0.55366254", "text": "function updateData(obj) {\n var objFound_bool = false;\n for (var i = 0; i < meal_list.length; i++) {\n if (obj.member_id === meal_list[i].member_id) {\n objFound_bool = true;\n meal_list[i] = obj\n //console.log(\"data updated\")\n }\n }\n if (!objFound_bool) {\n meal_list.push(obj)\n //console.log(\"data inserted\")\n }\n }", "title": "" }, { "docid": "3f173fa85dc0c8f9eb5f6c2f4c0cd4ce", "score": "0.5526744", "text": "_set (context, id) {\n this.special.set(context, id)\n }", "title": "" }, { "docid": "c3ebfba90be5bc5c8a43ddac7cab5f0a", "score": "0.55216223", "text": "function addData(dl) {\n SetdataNew([\n ...dataNew,\n {\n ...dl, //object thieu id\n id: uuidv4(), //tu sinh id\n },\n ]);\n }", "title": "" }, { "docid": "ddfc4ddd6086da76c17da65acb04c079", "score": "0.55174214", "text": "function SetupItemID(itemData, $item, prop, opts) {\n\n // Check object exist on Tween\n if( itemData.tweenID === UNDE ) {\n itemData.tweenID = tw.id;\n }\n\n else {\n\n /**\n * UPDATE PROPERTIES OF ITEM WHEN ID-ITEM !== ID-TWEEN\n */\n if( itemData.tweenID != tw.id ) {\n\n // Noties to reset 'prop' & 'opts'\n opts.isNew = true;\n\n // Update time of object\n itemData.tsInit = tw.tsCur;\n itemData.tCur = 0;\n\n // Re-register current 'prop' & 'opts'\n itemData = DB.Update($item, prop, opts);\n itemData.tweenID = tw.id;\n }\n }\n }", "title": "" }, { "docid": "ddfc4ddd6086da76c17da65acb04c079", "score": "0.55174214", "text": "function SetupItemID(itemData, $item, prop, opts) {\n\n // Check object exist on Tween\n if( itemData.tweenID === UNDE ) {\n itemData.tweenID = tw.id;\n }\n\n else {\n\n /**\n * UPDATE PROPERTIES OF ITEM WHEN ID-ITEM !== ID-TWEEN\n */\n if( itemData.tweenID != tw.id ) {\n\n // Noties to reset 'prop' & 'opts'\n opts.isNew = true;\n\n // Update time of object\n itemData.tsInit = tw.tsCur;\n itemData.tCur = 0;\n\n // Re-register current 'prop' & 'opts'\n itemData = DB.Update($item, prop, opts);\n itemData.tweenID = tw.id;\n }\n }\n }", "title": "" }, { "docid": "e6199cc900e0cf2c7a4384c6d3a95867", "score": "0.55163807", "text": "function setHouseId(id){\n houseId = id;\n}", "title": "" }, { "docid": "37789ba01d1aac663edb805b50a3895b", "score": "0.5516297", "text": "_update (id, data, params) {\n if (id in this.store) {\n // We don't want our id to change type if it can be coerced\n const oldId = this.store[id][this._id];\n\n id = oldId == id ? oldId : id; // eslint-disable-line\n\n data = _.extend({}, data, { [this._id]: id });\n this.store[id] = data;\n\n return Promise.resolve(this.store[id])\n .then(_select(params, this.id));\n }\n\n return Promise.reject(\n new errors.NotFound(`No record found for id '${id}'`)\n );\n }", "title": "" }, { "docid": "ecb3c42597b0c3708306f3d9c702cebd", "score": "0.55076694", "text": "static findAndSetObject(arrayProxy, obj){\n var idx = arrayProxy.indexOf(obj.get('id'));\n if(idx >= 0){\n arrayProxy.removeAt(idx);\n arrayProxy.insertAt(idx, obj);\n return true;\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "1a449dad6f4d427e493a502662356be1", "score": "0.5504958", "text": "_create (data, params) {\n let id = data[this._id] || this._uId++;\n let current = _.extend({}, data, { [this._id]: id });\n\n return Promise.resolve((this.store[id] = current))\n .then(_select(params, this.id));\n }", "title": "" }, { "docid": "ce6456dbf9f126c5c2f55bb51d7952e9", "score": "0.5488216", "text": "setData(data) {\n // convert to Immutable if not\n this.data = data;\n }", "title": "" }, { "docid": "8539b6fd499aa93d983942ccfb6adf36", "score": "0.5471759", "text": "async function update(id, data) {\n let ref;\n if (id === null) {\n ref = db.collection(collection).doc();\n } else {\n ref = db.collection(collection).doc(id);\n }\n data.id = ref.id;\n toDB.prepareDataSettersForDB(data);\n data = {...data};\n await ref.set(data);\n return data;\n}", "title": "" }, { "docid": "c6ace2bcc426ae47066981e93736234f", "score": "0.5450885", "text": "function setAssociatedObj(type, id) {\r\n // Check if the case already created; If yes - then update case. Otherwise, prepare associated object for case creation.\r\n log('Updating associated object');\r\n\tif(KDF.getParams().caseid) {\r\n KDF.customdata('update_case', 'create', true, true, {\r\n 'caseid': KDF.getParams().caseid,\r\n 'final_title': KDF.getVal('le_title'),\r\n 'final_desc': KDF.getVal('le_description'),\r\n 'obj_type': type,\r\n 'obj_id': id\r\n });\r\n }\r\n else {\r\n KDF.setVal('le_associated_obj_type', type);\r\n KDF.setVal('le_associated_obj_id', id); \r\n }\r\n}", "title": "" }, { "docid": "14c99467911af5675381fe1931e7f4bd", "score": "0.5450134", "text": "function update (id, data, cb) {\n let key;\n if (id) {\n key = ds.key([kind, parseInt(id, 10)]);\n } else {\n key = ds.key(kind);\n }\n\n const entity = {\n key: key,\n data: toDatastore(data, ['menu'])\n };\n\n ds.save(\n entity,\n (err) => {\n data.id = entity.key.id;\n cb(err, err ? null : data);\n }\n );\n}", "title": "" }, { "docid": "b359d728f09e6ce07ddb0a3fbfcb4236", "score": "0.54467106", "text": "function setData(data){\n data && K.mix(stored_data, data);\n}", "title": "" }, { "docid": "b7bf162c30d4d91cd03b0f8a03c3ed6b", "score": "0.54399824", "text": "function set(id, object, member) {\n\n var old = 0;\n var obj = getObject(object);\n var type = obj.type;\n\n if (type === VECTOR_TYPE) {\n old = obj.elem[member];\n obj.elem[member] = id;\n }\n else {\n old = obj[member];\n obj[member] = id;\n }\n\n if (id !== 0) {\n incr(id, object, member);\n }\n\n if (old !== 0) {\n decr(old, object, member);\n }\n}", "title": "" }, { "docid": "b3b119a07d555c9815cc3b07ea504a9b", "score": "0.54380816", "text": "setValue(id) {\n const unit = this.store.peekRecord(this.identifier, id);\n set(this, `changesetObj.${this.relatedBy}`, unit);\n }", "title": "" }, { "docid": "1e260a132d2519dcfbb5b42e3252fa82", "score": "0.5431527", "text": "saveToStorage(object) {\n var id;\n id = v8Util.getHiddenValue(object, 'atomId');\n if (!id) {\n id = ++this.nextId;\n this.storage[id] = {\n count: 0,\n object: object\n };\n v8Util.setHiddenValue(object, 'atomId', id);\n }\n ++this.storage[id].count;\n return id;\n }", "title": "" }, { "docid": "c86fdbcc1490179eaeaca79b279bb594", "score": "0.5427373", "text": "async update(condition,data){\n return await BaseEntity.updateUniqueOne(this.model,condition,data)\n }", "title": "" }, { "docid": "44adb50418ee1aedf52157eda5536585", "score": "0.5424148", "text": "function objectId(o) {\n var prop = \"|**objectid**|\"; // private property name for storing ids\n if (!o.hasOwnProperty(prop))\n // If the object has no id\n o[prop] = Set._v2s.next++; // Assign it the next available\n return o[prop]; // Return the id.\n }", "title": "" }, { "docid": "15545f897c8ff732d2fb3570dca22f57", "score": "0.5422873", "text": "get id() {return this._id}", "title": "" }, { "docid": "bbd2722141375de94a3637564fcc5a8b", "score": "0.541036", "text": "getOrSetId() {\n\t\t//debugger\n\t\tlet id = this.el.field.getAttribute('id')\n\t\tlet name = this.el.field.getAttribute('name')\n\t\t// generate if none of both\n\t\tif (!id && !name)\n\t\t\tname = id =\n\t\t\t\tthis.el.field.type + '_' + Math.round(Math.random() * 1000000000)\n\t\t// sync id and name\n\t\tif (!id && name) id = name\n\t\tif (!name && id) name = id\n\n\t\tthis.el.field.setAttribute('id', id)\n\t\tthis.el.field.setAttribute('name', name)\n\t}", "title": "" }, { "docid": "f40bfb972a14e8dead7b817fd6c3c75c", "score": "0.5409299", "text": "function DS_update (kind, id, data, cb) {\n log(\"DS_update \"+kind+\" \"+id);\n var key;\n if (id) { key = ds.key([kind, parseInt(id, 10)]);\n } else {\n if(schema[kind].created) { data.created = Date.now(); }\n key = ds.key(kind);\n }\n if(schema[kind].modified) { data.modified = Date.now(); }\n\n var qid = DS_UpdateIdString(kind,id);\n DS_setCached(qid,data,function(err){\n var entity = { key: key, data: DS_toDatastore(data, kind) };\n DS_ensureSession(function (tryAgainOnDatabaseTimeout) {\n ds.save( entity, function (err) {\n data.id = entity.key.id;\n if(schema[kind].id == t_STR && data.id) { data.id = data.id.toString(); }\n if(err) {\n if(!tryAgainOnDatabaseTimeout(err)) {\n var errorMsg = \"DS update \"+qid+\" \";\n if(typeof err === 'string') { errorMsg += err;}\n else { errorMsg += JSON.stringify(err);}\n return cb(errorMsg);\n }else{return;}\n }\n cb(err, data);\n });\n });\n });\n}", "title": "" }, { "docid": "600706e398b7ab9cab00a4c6356f5927", "score": "0.5404027", "text": "get id() {return this._id; }", "title": "" }, { "docid": "b731bb32daa89518b5a21146ae1f7186", "score": "0.5399922", "text": "postWithId(id, data, options) {\n // Transactions maybe better but unfortunately we cannot use it to remove data and we need to keep\n // consistency.\n return this.exists(id, options).then((exists) => {\n if (exists) {\n return Promise.reject(httpError(409, 'Conflict: duplicate id'));\n }\n return this.connection.call('child', id).call('set', data);\n }).return([id, null]);\n }", "title": "" }, { "docid": "21a918d554db9d9936daece680cd9756", "score": "0.5397788", "text": "set SetId(value) { this.#id = id }", "title": "" }, { "docid": "2e5be5e076f55a15f52979be506b04f4", "score": "0.5397373", "text": "setData() {\n\t\tthis.data = this.getData()\n\t}", "title": "" }, { "docid": "26c030b3688587932cb7d5ab82da2db8", "score": "0.5381207", "text": "function setId(i) {\n id = i;\n}", "title": "" }, { "docid": "16bbd3b78cea18f571af94ea2e003f7e", "score": "0.5378184", "text": "updateItemUnit(state, data) {\n const ind = findIndex(state.item_units, (r) => {\n return r.id === data.id\n })\n\n const itemunit = state.item_units[ind]\n\n for (const prop in data) {\n itemunit[prop] = data[prop]\n }\n }", "title": "" }, { "docid": "27429edc0a8f7c82b884c8446a0e0c59", "score": "0.53759515", "text": "addToLogicalId(data) {\n // if the construct is locked, it means we are already synthesizing and then\n // we can't modify the hash because we might have already calculated it.\n if (this.node.locked) {\n throw new Error('Cannot modify the logical ID when the construct is locked');\n }\n this.hashComponents.push(data);\n }", "title": "" }, { "docid": "ed9db3bf88201351f1a418d8ae89f666", "score": "0.5371216", "text": "toID(field, data, version) {\n let dataArray;\n if (Array.isArray(data)) {\n dataArray = data;\n } else {\n dataArray = [data];\n }\n let keyByVal;\n if (version === 'old') {\n keyByVal = this.old.keyByVal;\n } else {\n keyByVal = this.keyByVal;\n }\n for (let i = 0; i < dataArray.length; i++) {\n if (keyByVal !== null &&\n typeof dataArray[i][field] !== 'undefined' &&\n typeof keyByVal[dataArray[i][field]] !== 'undefined') {\n dataArray[i][field] = keyByVal[dataArray[i][field]];\n }\n }\n }", "title": "" }, { "docid": "a9d9c87a71a14f55b114a3eae0e7e56a", "score": "0.53616136", "text": "function processSingle (data) {\n setSingle(data)\n}", "title": "" }, { "docid": "8b57247d3e93787fa16644ad11e9d56f", "score": "0.5361145", "text": "async getID() {\n var thisBinded = this;\n thisBinded.savedData = \"\";\n thisBinded.savedData = await AsyncStorage.getItem(ID);\n thisBinded.firstName = await AsyncStorage.getItem(storedName);\n thisBinded.savedData = JSON.stringify(thisBinded.savedData);\n if (thisBinded.savedData != null && thisBinded.savedData != \"\" && thisBinded.savedData != \"null\") {\n thisBinded.setState({id: thisBinded.savedData});\n thisBinded.setState({name: thisBinded.firstName});\n }\n }", "title": "" }, { "docid": "84dd86d671f71ecff96656d50e4f5782", "score": "0.5358558", "text": "set id(newId) {\n this._id = newId;\n }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "5154f4e42c323dca3bcdfb47d6b67da5", "score": "0.53551537", "text": "get id() { return this._id; }", "title": "" }, { "docid": "092ce7b85a545d07907a4640329b9046", "score": "0.53158927", "text": "addSocketId(data, callback) {\n usersDb\n .update({\n _id: new ObjectID(data.id),\n },\n data.value, (err, res) => {\n callback(err, res.result);\n });\n }", "title": "" }, { "docid": "95e829b35e670a99c0cd0afa01eec693", "score": "0.5311516", "text": "function setUserID() {\n if(!exists(USER_ID)) {\n var id = uniq_id();\n save(USER_ID, id);\n console.log('Set User ID: ' + id);\n } else {\n console.log('User already has ID: ' + get(USER_ID));\n }\n}", "title": "" }, { "docid": "006b48ce021fca0602a34571d969ae63", "score": "0.5303772", "text": "save() {\n\n\t\tlet data = this.getData()\n\t\tif (!Array.isArray(data)) data = []\n\n\t\tconst schema = this.schema()\n\n\t\tlet data_obj = {}\n\t\tfor (let key in this.obj) {\n\t\t\tlet value = this.Validate.type(key, this.obj[key])\n\t\t\tif (value != undefined && schema[key]) {\n\t\t\t\tdata_obj[key] = Plugin.valueToType(schema[key], this.obj[key])\n\t\t\t}\n\t\t}\n\n\t\tif (this.currentId == null) {\n\t\t\tlet table_config = this.config()\n\t\t\ttable_config.last_id++\n\t\t\tthis.obj.id = table_config.last_id\n\t\t\tdata_obj.id = this.obj.id\n\t\t\tthis.currentId = table_config.last_id\n\t\t\tthis.Validate.Config.put(table_config)\n\t\t\tdata.push(data_obj)\n\t\t} else if (this.currentId != null) {\n\t\t\tthis.currentKey = this.getRowKey(this.currentId, data)\n\t\t\tthis.obj.id = this.currentId\n\t\t\tdata_obj.id = this.obj.id\n\t\t\tdata[this.currentKey] = data_obj\n\n\t\t} else return false\n\n\t\tthis.Validate.Data.put(data)\n\t\tthis.data = []\n\n\t\t//this.settings.consoleLog('save() --> ', this.currentId)\n\n\t\treturn true\n\t}", "title": "" }, { "docid": "40a8edaab4592ec3bccf57c897c61ce4", "score": "0.53024095", "text": "async updateById(data, id) {\n var result = await this.update(data, {\n where: {\n _id: id\n }\n });\n return result ? result[0] : null;\n }", "title": "" }, { "docid": "d87a2d2c7edc2b8266d0e458d11d5048", "score": "0.52976626", "text": "function update_data(data) {\n if (db) {\n const put_transaction = db.transaction(\"user\", \"readwrite\");\n const objectStore = put_transaction.objectStore(\"user\");\n\n return new Promise((resolve, reject) => {\n put_transaction.onerror = function (event) {\n console.log(\"Problem Getting Data\");\n resolve(false);\n };\n\n put_transaction.onsuccess = function (event) {\n console.log(\"Successfully Updated Data\");\n resolve(true);\n };\n\n objectStore.put(data);\n });\n }\n}", "title": "" }, { "docid": "d92ef909653feca83a5f655fcc4cb755", "score": "0.5295517", "text": "saveDataBuilding() {\n // Prepare data\n let data = {\n id: this.tempRecord.id,\n name: this.tempRecord.name,\n floor_count: this.tempRecord.floor_count,\n room_count: this.tempRecord.room_count,\n block_id: this.tempRecord.block.id,\n building_type_id: this.tempRecord.building_type.id,\n url: '/buildings',\n function: 'createBuildings',\n };\n this.isLoading = true;\n if (0 == data.id) {\n this.createRecord(data);\n } else {\n data.url = '/buildings/' + data.id;\n data.function = 'updateBuildings';\n this.updateRecord(data);\n }\n\n return;\n }", "title": "" }, { "docid": "3be6fd375d53e6be298db76a440ad449", "score": "0.5284309", "text": "set data(data) {\n\t\tthis.item = data;\n\t}", "title": "" }, { "docid": "f491804cb3452037daf9e6a37c3c05aa", "score": "0.52792776", "text": "function updateItemData(id, key, name, def) {\n var pos = items.findIndex(function(item) { return item.id == id; });\n items[pos] = { id:Number(id), key:key, name:name, def:def }\n }", "title": "" }, { "docid": "5d11e1663169cfe50443eeede5ed2397", "score": "0.52760416", "text": "updateClientInfo(clientData) {\n const key = this.clients.findIndex(e => e.id === parseInt(clientData.id, 10));\n if (key < 0) {\n // There are no clients with the given id\n this.addClient(clientData);\n } else {\n this.clients[key] = clientData;\n }\n this.saveToStorage();\n }", "title": "" }, { "docid": "aac93ceeac8dc95f33d72dd74769a130", "score": "0.5273354", "text": "function setObject(type, id, userobject) {\n // see https://redis.io/commands/hmset\n return hmsetAsync(makeKey(type, id), userobject);\n}", "title": "" }, { "docid": "1e40fb23ebe3e4f18b4497612ff5a3fd", "score": "0.5269299", "text": "changeSelectionData (field, data){\n // Pick the item with the matching uid stored in selected.\n this.items.filter((e, i, a) => {\n return e['uid'] == this.selected; \n })[0][field] = data;\n }", "title": "" }, { "docid": "2ca19dd8eb657713ced10f24fb19e6c8", "score": "0.52690333", "text": "async function update(id, data) {\n let ref;\n if (id === null) {\n ref = db.collection(collection).doc();\n } else {\n ref = db.collection(collection).doc(id);\n }\n\n data.id = ref.id;\n data = {...data};\n await ref.set(data);\n return data;\n}", "title": "" }, { "docid": "1d34d7701c66caf62c4fc5c77be2198d", "score": "0.52675027", "text": "toID(data, field) {\n if (Array.isArray(data)) {\n for (let i = 0; i < data.length; i++) {\n if (typeof data[i][field] !== 'undefined' && typeof this.keyByVal[data[i][field]] !== 'undefined') {\n data[i][field] = this.keyByVal[data[i][field]];\n }\n }\n } else if (typeof data[field] !== 'undefined' && typeof this.keyByVal[data[field]] !== 'undefined') {\n data[field] = this.keyByVal[data[field]];\n }\n }", "title": "" }, { "docid": "1d0d64f9e0f5fe1f9cfedfa8941865c0", "score": "0.52552646", "text": "update(id, obj){\n for(let i=0; i<this.gamesDb.length; i++){\n if(this.gamesDb[i].id === id){\n this.gamesDb[i].name = obj.name;\n this.gamesDb[i].rate = obj.rate;\n this.gamesDb[i].genre = obj.genre;\n return this.gamesDb[i];\n }\n } \n }", "title": "" }, { "docid": "23c141f094670c549bc18b51e90ade80", "score": "0.52550286", "text": "putDataToDB(t, c, p) {\n let currentIds = this.state.data.map(data => data.id);\n let idToBeAdded = 0;\n while (currentIds.includes(idToBeAdded)) {\n ++idToBeAdded;\n }\n\n const self = this\n\n axios.post(\"/api/putData\", {\n id: idToBeAdded,\n title: t,\n content: c,\n position: p,\n author: self.props.getUser\n })\n .then(response => {\n self.setState({\n showModal: false\n })\n self.getDataFromDb()\n })\n .catch(err => {\n console.log(err)\n });\n }", "title": "" }, { "docid": "32584857ebbcab952e40b0ffca177394", "score": "0.52499896", "text": "get id () { return this._id }", "title": "" }, { "docid": "4dd813016e4a8e4c06198d1e4ba29023", "score": "0.5241346", "text": "_setPickingId() {\n this._pickingId = this.getPickingId();\n }", "title": "" }, { "docid": "3feca684a6a1425c551f6199dae1c5c5", "score": "0.52406704", "text": "get id() {\n return this._id;\n }", "title": "" }, { "docid": "98a316b9c2a6d1dcff570f0b6d18080c", "score": "0.52282244", "text": "_addItem(item) {\r\n const fullItem = ensureFullItem(item, __classPrivateFieldGet(this, _idProp));\r\n const id = fullItem[__classPrivateFieldGet(this, _idProp)];\r\n // check whether this id is already taken\r\n if (__classPrivateFieldGet(this, _data).has(id)) {\r\n // item already exists\r\n throw new Error(\"Cannot add item: item with id \" + id + \" already exists\");\r\n }\r\n __classPrivateFieldGet(this, _data).set(id, fullItem);\r\n ++this.length;\r\n return id;\r\n }", "title": "" }, { "docid": "282a7710249ba3a7663c4b57f6cebcab", "score": "0.52243346", "text": "get id() { return this._.id; }", "title": "" }, { "docid": "282a7710249ba3a7663c4b57f6cebcab", "score": "0.52243346", "text": "get id() { return this._.id; }", "title": "" } ]
6626a319c734dac071975a3991d8e303
A cmp function for determining the leftmost event
[ { "docid": "0a6220530159d151b70ff3aa50e0a7d4", "score": "0.0", "text": "function compareDaySegCols(a, b) {\n\treturn a.leftCol - b.leftCol;\n}", "title": "" } ]
[ { "docid": "00a65d6b8c2fef6e590f2a2f99661c10", "score": "0.6687278", "text": "function compareEvent(a, b) {\n\tif (a.scheduledTime < b.scheduledTime) {\n\t\treturn -1;\n\t}\n\n\tif (a.scheduledTime > b.scheduledTime) {\n\t\treturn 1;\n\t}\n\n\treturn 0;\n}", "title": "" }, { "docid": "5becbc6acc2d7cd7ce515411e928d91f", "score": "0.6407461", "text": "function compareEvent(a, b) {\n var d =\n (a.a[0] - b.a[0]) ||\n (a.a[1] - b.a[1]) ||\n (a.type - b.type)\n if(d) { return d }\n if(a.type !== EVENT_POINT) {\n d = orient(a.a, a.b, b.b)\n if(d) { return d }\n }\n return a.idx - b.idx\n}", "title": "" }, { "docid": "5becbc6acc2d7cd7ce515411e928d91f", "score": "0.6407461", "text": "function compareEvent(a, b) {\n var d =\n (a.a[0] - b.a[0]) ||\n (a.a[1] - b.a[1]) ||\n (a.type - b.type)\n if(d) { return d }\n if(a.type !== EVENT_POINT) {\n d = orient(a.a, a.b, b.b)\n if(d) { return d }\n }\n return a.idx - b.idx\n}", "title": "" }, { "docid": "2a1a2485c165bef7e84a4feafc945568", "score": "0.63972133", "text": "eventSorter(a, b) {\n const startA = a.dataStartMs || a.startMs,\n // dataXX are used if configured with fillTicks\n endA = a.dataEndMs || a.endMs,\n startB = b.dataStartMs || b.startMs,\n endB = b.dataEndMs || b.endMs,\n sameStart = startA === startB;\n\n if (sameStart) {\n if (endA - endB === 0) {\n return a.event.name < b.event.name ? -1 : 1;\n }\n\n return endA > endB ? -1 : 1;\n }\n\n return startA < startB ? -1 : 1;\n }", "title": "" }, { "docid": "476ad6f4ff0d58f3a09072f4661031ab", "score": "0.6322372", "text": "function Comparator (a, b){\n var aEntry = (a.e) || a;\n var bEntry = (b.e) || b;\n if (aEntry < bEntry){ return -1; };\n if (aEntry > bEntry){ return 1; };\n return 0;\n}", "title": "" }, { "docid": "f014ca29611777ccc7de8c5a42f88f0c", "score": "0.614168", "text": "function compareevents(a, b) {\n if (a.start_date.getTime() > b.start_date.getTime()) {\n return 1;\n } else {\n return -1;\n }\n}", "title": "" }, { "docid": "cac7cc709c84bd0e1568d2ecba49f7b7", "score": "0.60215425", "text": "function compare(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,i=0,a=Math.min(r,n);i<a;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0}", "title": "" }, { "docid": "aad38c57917e64752d1ed653b113dca6", "score": "0.6012848", "text": "function compare(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,o=0,a=Math.min(r,n);o<a;++o)if(e[o]!==t[o]){r=e[o],n=t[o];break}return r<n?-1:n<r?1:0}", "title": "" }, { "docid": "28614f017f4f19a380b4c9cb959ef11b", "score": "0.6012441", "text": "function compare(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,i=0,o=Math.min(r,n);i<o;++i)if(e[i]!==t[i]){r=e[i],n=t[i];break}return r<n?-1:n<r?1:0}", "title": "" }, { "docid": "7c869d44202f6c620e6663a85add24cb", "score": "0.6010389", "text": "function compare(e,t){if(e===t)return 0;for(var r=e.length,n=t.length,o=0,i=Math.min(r,n);o<i;++o)if(e[o]!==t[o]){r=e[o],n=t[o];break}return r<n?-1:n<r?1:0}", "title": "" }, { "docid": "fe31d15725680ef37d678b0f8c6c9293", "score": "0.6008628", "text": "function cmp(a,b){return a.line-b.line||a.ch-b.ch;}", "title": "" }, { "docid": "8f86c3b27b38779b43a1a96049652de0", "score": "0.6003432", "text": "eventSorter(a, b) {\n const startA = a.dataStartMs || a.startDateMS,\n // dataXX are used if configured with fillTicks\n endA = a.dataEndMs || a.endDateMS,\n startB = b.dataStartMs || b.startDateMS,\n endB = b.dataEndMs || b.endDateMS,\n sameStart = startA === startB;\n\n if (sameStart) {\n if (endA - endB === 0) {\n return a.eventRecord.name < b.eventRecord.name ? -1 : 1;\n }\n\n return endA > endB ? -1 : 1;\n }\n\n return startA < startB ? -1 : 1;\n }", "title": "" }, { "docid": "c48902f35b2241d02843eb370db89f16", "score": "0.59874606", "text": "function compare (a, b) {\n\t return a > b ? 1 : a < b ? -1 : 0\n\t}", "title": "" }, { "docid": "c48902f35b2241d02843eb370db89f16", "score": "0.59874606", "text": "function compare (a, b) {\n\t return a > b ? 1 : a < b ? -1 : 0\n\t}", "title": "" }, { "docid": "c48902f35b2241d02843eb370db89f16", "score": "0.59874606", "text": "function compare (a, b) {\n\t return a > b ? 1 : a < b ? -1 : 0\n\t}", "title": "" }, { "docid": "7165bad25fbae2c4be7f9a894611117c", "score": "0.596907", "text": "function cmp(a, b) {\n\t if(a < b) {\n\t return -1;\n\t } else if(a > b) {\n\t return 1;\n\t } else {\n\t return 0;\n\t }\n\t }", "title": "" }, { "docid": "7165bad25fbae2c4be7f9a894611117c", "score": "0.596907", "text": "function cmp(a, b) {\n\t if(a < b) {\n\t return -1;\n\t } else if(a > b) {\n\t return 1;\n\t } else {\n\t return 0;\n\t }\n\t }", "title": "" }, { "docid": "7b30009ba961225ef177c3a124f6c922", "score": "0.5967499", "text": "function cmp(a, b) {\n return a < b ? -1 : a > b ? 1 : 0;\n }", "title": "" }, { "docid": "588cc5459c6b096ab00ff0b75c8f7920", "score": "0.5921466", "text": "function compare(e,r){if(e===r)return 0;for(var n=e.length,i=r.length,o=0,a=Math.min(n,i);o<a;++o)if(e[o]!==r[o]){n=e[o],i=r[o];break}return n<i?-1:i<n?1:0}", "title": "" }, { "docid": "3723de13f1627fb76ee954c8f962b33d", "score": "0.58966446", "text": "if (summary[prevHighest] > summary[direction]) {\n return prevHighest;\n }", "title": "" }, { "docid": "6ebba753a496e98bdf28d27976ae49e3", "score": "0.58285475", "text": "function sortMostUrgetFirst(a, b) {\n a.frames = a.frames.sort(sortMostRecentFirst);\n b.frames = b.frames.sort(sortMostRecentFirst);\n let aFrame = a.frames[0]; // most recent frame is not at 0\n let bFrame = b.frames[0];\n let aOngoing = aFrame.until === undefined;\n let bOngoing = bFrame.until === undefined;\n if (aOngoing != bOngoing)\n return aOngoing ? -1 : 1;\n let aLevel = aFrame.level;\n let bLevel = bFrame.level;\n if (aLevel != bLevel)\n return aLevel === 'red' ? -1 : 1;\n return bFrame.since - aFrame.since; // start with most recent item\n }", "title": "" }, { "docid": "6ebba753a496e98bdf28d27976ae49e3", "score": "0.58285475", "text": "function sortMostUrgetFirst(a, b) {\n a.frames = a.frames.sort(sortMostRecentFirst);\n b.frames = b.frames.sort(sortMostRecentFirst);\n let aFrame = a.frames[0]; // most recent frame is not at 0\n let bFrame = b.frames[0];\n let aOngoing = aFrame.until === undefined;\n let bOngoing = bFrame.until === undefined;\n if (aOngoing != bOngoing)\n return aOngoing ? -1 : 1;\n let aLevel = aFrame.level;\n let bLevel = bFrame.level;\n if (aLevel != bLevel)\n return aLevel === 'red' ? -1 : 1;\n return bFrame.since - aFrame.since; // start with most recent item\n }", "title": "" }, { "docid": "f4442e7bce2319de51362cbeb8c3a0ed", "score": "0.58238477", "text": "function posCmp(a, b) {\n return (a.line - b.line) || (a.ch - b.ch);\n}", "title": "" }, { "docid": "8825d004dce3c03403b3575ab9538861", "score": "0.58120096", "text": "function cmp(a, b) {\n\treturn a.line - b.line || a.ch - b.ch;\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "042a10db0804bf393ccdda557e8ca55e", "score": "0.5799007", "text": "function compare (a, b) {\n return a > b ? 1 : a < b ? -1 : 0\n}", "title": "" }, { "docid": "fc2f4858d757dffe5a3b6b3f23e8188e", "score": "0.576042", "text": "compare(a, b) {\n if (a === b) return 0;\n return a < b ? -1 : 1;\n }", "title": "" }, { "docid": "9309f779c907b33dd9e1afe8e06c0bfb", "score": "0.57338667", "text": "function Vt(t, e, n) {\n for (var r = 0, i = 0; i < t.position.length; i++) {\n var o = e[i], s = t.position[i];\n if (r = o.field.isKeyField() ? Q.comparator(Q.fromName(s.referenceValue), n.key) : it(s, n.field(o.field)), \n \"desc\" /* DESCENDING */ === o.dir && (r *= -1), 0 !== r) break;\n }\n return t.before ? r <= 0 : r < 0;\n}", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "58e51ece7b64d7bbc64d419d2e572867", "score": "0.5723133", "text": "function cmp(a, b) { return a.line - b.line || a.ch - b.ch }", "title": "" }, { "docid": "974323e7cc6f0669c96aa7e81d778bcf", "score": "0.5722702", "text": "function ue(t, e, n) {\n let s = 0;\n for (let i = 0; i < t.position.length; i++) {\n const r = e[i], o = t.position[i];\n if (r.field.isKeyField()) s = bt.comparator(bt.fromName(o.referenceValue), n.key); else {\n s = St(o, n.data.field(r.field));\n }\n if (\"desc\" /* DESCENDING */ === r.dir && (s *= -1), 0 !== s) break;\n }\n return t.before ? s <= 0 : s < 0;\n}", "title": "" }, { "docid": "0cbcc2edab16b749f02c9ee404a3d541", "score": "0.57198054", "text": "function compare(a, b) {\n return a > b ? 1 : a < b ? -1 : 0;\n}", "title": "" }, { "docid": "b9ac7fbbf0e9813b818c91a9acaee24f", "score": "0.5691128", "text": "function cmp(a, b) {\n return a.line - b.line || a.ch - b.ch;\n }", "title": "" }, { "docid": "b9ac7fbbf0e9813b818c91a9acaee24f", "score": "0.5691128", "text": "function cmp(a, b) {\n return a.line - b.line || a.ch - b.ch;\n }", "title": "" }, { "docid": "4cd283ff0449dd8003661b26ff5faf44", "score": "0.5688023", "text": "function compare(a, b) {\n return a < b ? -1 : a > b ? 1 : 0;\n}", "title": "" }, { "docid": "e36c4caed2d60864d4d1b49a6d34c872", "score": "0.5677576", "text": "function dzn_sortCondAsc(a,b) {\n\t\t\treturn (a-b);\n\t\t}", "title": "" }, { "docid": "fb0302bb5b6b2c0630459db27b9ccf26", "score": "0.5674715", "text": "_compareLanes(a, b) {\n const priorityA = this.LANES_PRIORITY[a.type];\n const priorityB = this.LANES_PRIORITY[b.type];\n if (priorityA != priorityB) {\n return priorityA - priorityB;\n }\n\n // Otherwise compare the events\n if (a.events.length && !b.events.length) {\n return -1;\n }\n if (!a.events.length && b.events.length) {\n return 1;\n }\n if (a.events.length && b.events.length) {\n const eventA = a.events[0];\n const eventB = b.events[0];\n if (eventA.msStart < eventB.msStart) {\n return -1;\n }\n if (eventA.msStart > eventB.msStart) {\n return 1;\n }\n }\n\n // Alphabet comparison\n if (a.title < b.title) {\n return -1;\n }\n if (a.title > b.title) {\n return 1;\n }\n return 0;\n }", "title": "" }, { "docid": "8a4326d05aef57c8942c99a1983e2a30", "score": "0.56637555", "text": "static ts(t, e) {\n return Rt.comparator(t.key, e.key) || Z(t.ls, e.ls);\n }", "title": "" }, { "docid": "dd2467269e2d47d6eeed4df90f500cea", "score": "0.56540024", "text": "function sortEvents(_ref) {\n var _ref$evtA = _ref.evtA,\n aStart = _ref$evtA.start,\n aEnd = _ref$evtA.end,\n aAllDay = _ref$evtA.allDay,\n aZIndex = _ref$evtA.zIndex,\n _ref$evtB = _ref.evtB,\n bStart = _ref$evtB.start,\n bEnd = _ref$evtB.end,\n bAllDay = _ref$evtB.allDay,\n bZIndex = _ref$evtB.zIndex\n var startSort =\n +(0, _dates.startOf)(aStart, 'day') - +(0, _dates.startOf)(bStart, 'day')\n var durA = (0, _dates.diff)(aStart, (0, _dates.ceil)(aEnd, 'day'), 'day')\n var durB = (0, _dates.diff)(bStart, (0, _dates.ceil)(bEnd, 'day'), 'day')\n var zIndex = zIndexSort(aZIndex, bZIndex)\n return (\n startSort ||\n // sort by start Day first\n Math.max(durB, 1) - Math.max(durA, 1) ||\n // events spanning multiple days go first\n !!bAllDay - !!aAllDay ||\n // then allDay single day events\n zIndex ||\n //custom sort by zIndex\n +aStart - +bStart ||\n // then sort by start time\n +aEnd - +bEnd // then sort by end time\n )\n}", "title": "" }, { "docid": "be8e5f50a7d78d2754e0d3ba2d5611fc", "score": "0.5638483", "text": "function Qt(t, e, n) {\n for (var r = 0, i = 0; i < t.position.length; i++) {\n var o = e[i], s = t.position[i];\n if (r = o.field.isKeyField() ? at.comparator(at.fromName(s.referenceValue), n.key) : lt(s, n.data.field(o.field)), \n \"desc\" /* DESCENDING */ === o.dir && (r *= -1), 0 !== r) break;\n }\n return t.before ? r <= 0 : r < 0;\n }", "title": "" }, { "docid": "739914f41703fa9846c55bfbe781a610", "score": "0.56337166", "text": "function compare(left, right) {\n return left < right ? -1 : left > right ? 1 : 0;\n}", "title": "" }, { "docid": "739914f41703fa9846c55bfbe781a610", "score": "0.56337166", "text": "function compare(left, right) {\n return left < right ? -1 : left > right ? 1 : 0;\n}", "title": "" }, { "docid": "739914f41703fa9846c55bfbe781a610", "score": "0.56337166", "text": "function compare(left, right) {\n return left < right ? -1 : left > right ? 1 : 0;\n}", "title": "" }, { "docid": "739914f41703fa9846c55bfbe781a610", "score": "0.56337166", "text": "function compare(left, right) {\n return left < right ? -1 : left > right ? 1 : 0;\n}", "title": "" }, { "docid": "739914f41703fa9846c55bfbe781a610", "score": "0.56337166", "text": "function compare(left, right) {\n return left < right ? -1 : left > right ? 1 : 0;\n}", "title": "" }, { "docid": "739914f41703fa9846c55bfbe781a610", "score": "0.56337166", "text": "function compare(left, right) {\n return left < right ? -1 : left > right ? 1 : 0;\n}", "title": "" }, { "docid": "bc14d502aa0fb208cad4adda59d5b6a4", "score": "0.5630741", "text": "function compareEvents(a, b) {\n const bandA = a.date\n const bandB = b.date\n let comparison = 0\n if (bandA > bandB) {\n comparison = 1\n } else if (bandA < bandB) {\n comparison = -1\n }\n return comparison\n }", "title": "" }, { "docid": "7fa088e16a15bdce7618c5bb40c938cf", "score": "0.56133515", "text": "function compare(a, b) {\n if (a.timeStamp > b.timeStamp) {\n return -1;\n }\n\n if (a.timeStamp < b.timeStamp) {\n return 1;\n }\n\n return 0;\n }", "title": "" }, { "docid": "7fa088e16a15bdce7618c5bb40c938cf", "score": "0.56133515", "text": "function compare(a, b) {\n if (a.timeStamp > b.timeStamp) {\n return -1;\n }\n\n if (a.timeStamp < b.timeStamp) {\n return 1;\n }\n\n return 0;\n }", "title": "" }, { "docid": "63ddbeae1021a87cb529e094c4d68215", "score": "0.56006444", "text": "function DEFAULT_COMPARE(a, b) {\n return a > b ? 1 : a < b ? -1 : 0;\n }", "title": "" }, { "docid": "63ddbeae1021a87cb529e094c4d68215", "score": "0.56006444", "text": "function DEFAULT_COMPARE(a, b) {\n return a > b ? 1 : a < b ? -1 : 0;\n }", "title": "" }, { "docid": "dffff32ec0f9dad2d95c982f95b522c6", "score": "0.5598237", "text": "function da(a,b){var c=b.priority-a.priority;return 0!==c?c:a.name!==b.name?a.name<b.name?-1:1:a.index-b.index}", "title": "" }, { "docid": "47819f06e5a15464517d143d681dbecc", "score": "0.55914307", "text": "function min() {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" }, { "docid": "cc07bb0971e108dc9ecaaaeac46d0a7d", "score": "0.5575162", "text": "function min () {\n\t var args = [].slice.call(arguments, 0);\n\n\t return pickBy('isBefore', args);\n\t }", "title": "" } ]
b54c0bf8030f316e18c26a70d7087c6e
function to get tags
[ { "docid": "7925f930ffaca1c9698481d753e93e8b", "score": "0.0", "text": "function getTags (selectedId) {\n $.post(\"includes/select_tags.php\", {\n selectedId: selectedId\n }, function(data) {\n $(\"#TagsId\").append(data);\n });\n}", "title": "" } ]
[ { "docid": "1b99047917e4bbb34012aff0959dcb21", "score": "0.7761388", "text": "function getTags() {\n\tvar tagString = \" \";\n\tfor (let tag of safeQueryA(\"[href*='/tag/']\")) {\n\t\ttagString += tag.innerText.replace(/[#]/g, '') + \" \";\n\t};\n\treturn tagString.replace(/[,\\\\/:?<>\\t\\n\\v\\f\\r]/g, '_');\n}", "title": "" }, { "docid": "f6857e0fa468b3bfe77eb23c75ce8fc2", "score": "0.7393324", "text": "get tags () {\n\t\t\treturn this.node('tag', this.tagroot);\n\t\t}", "title": "" }, { "docid": "5bf7ef39ea3850cd0613e45c7739e680", "score": "0.71890926", "text": "getTags() {\n const tagList = [];\n for (const tag in this.tagDictionary) {\n tagList.push(tag);\n }\n return tagList;\n }", "title": "" }, { "docid": "67cbe1ffd2e1d7b24246644541083ef3", "score": "0.70368165", "text": "getTags(){\n\n\t\tif( !this.tags )\n\t\t\treturn [];\n\t\t\n\t\tlet out = [];\n\t\tfor( let tag of this.tags )\n\t\t\tout.push(tag);\n\n\t\treturn out;\n\n\t}", "title": "" }, { "docid": "c6f4f3cf4452959d148fa4a2cd1076fa", "score": "0.6973741", "text": "get tag() {}", "title": "" }, { "docid": "c6f4f3cf4452959d148fa4a2cd1076fa", "score": "0.6973741", "text": "get tag() {}", "title": "" }, { "docid": "c6f4f3cf4452959d148fa4a2cd1076fa", "score": "0.6973741", "text": "get tag() {}", "title": "" }, { "docid": "5292925e973fa569cbd91353a8c8a8fc", "score": "0.69690037", "text": "function listTag(tag) {\r\n\r\n scanTTPTags();\r\n\r\n if (tag == \"\")\r\n return TheTTPTags;\r\n\r\n //console.log(\"TTP tags \", TheTTPTags);\r\n const regex = new RegExp(tag);\r\n\r\n const res = TheTTPTags.filter(elt => elt.tag.match(regex));\r\n //console.log(res);\r\n return res;\r\n}", "title": "" }, { "docid": "cb4cedefdb3c27bf0775a7d722b6a439", "score": "0.69577044", "text": "function getTags(tagsJson){\n var tags = \"<p style=\\\"word-spacing: 0.5rem;\\\">\";\n for(var i = 0; i < tagsJson.tag.length; i++){\n tags += \"<a href=\\\"#\" + tagsJson.tag[i].raw + \"\\\" onClick=\\\"searchByTag(this);\\\">\" + tagsJson.tag[i].raw + \"<\\/a> \";\n }\n tags += \"</p>\";\n return tags;\n}", "title": "" }, { "docid": "c402d5f6c311e2fed6d0fa730acc7528", "score": "0.68250114", "text": "getTags(args) {\n const params = getUrlParams(args);\n return fetcher(`${this.host}/rest/tags${params}`, { headers: this.headers });\n }", "title": "" }, { "docid": "5d446a79d10a9f106aac68336e779f9a", "score": "0.6796522", "text": "function getTagNames() {\n return currentTags.getTags().map(tag => tag.getTag());\n }", "title": "" }, { "docid": "ba17d2977150a1308650832f724ee1b9", "score": "0.6782895", "text": "getAllTags() { \n var tags = [];\n var i=1;\n for (var x = 0; x < this.props.products.length; x++) {\n for (var y = 0; y < this.props.products[x].tags.length; y++) {\n if ( this.isTagMissing(tags, this.props.products[x].tags[y])) {\n var tag={id:i,name:this.props.products[x].tags[y].name};\n tags.push(tag);\n i++;\n }\n }\n }\n\n return tags;\n }", "title": "" }, { "docid": "ffcf592110f62c17adb05fe4537b4075", "score": "0.67747194", "text": "tagged(tag) {\n let results = [];\n let tags = this._tags.get(tag);\n if (_.isEmpty(tags)) {\n tags.forEach(($abstract) => {\n results.push(this.make($abstract));\n });\n }\n return results;\n }", "title": "" }, { "docid": "e9a6415a48a26bb3cfb3c1d4acfa5a1d", "score": "0.6729284", "text": "function getAllTagsOnScreen(){ \n const tagDivs = [...document.querySelectorAll(\".commentTagDiv\")];\n let retVal = [];\n tagDivs.forEach(tagDiv => {\n let tag = tagDiv.textContent.substring(0, tagDiv.textContent.length - 1)\n retVal.push(tag)});\n return retVal;\n}", "title": "" }, { "docid": "2810aebc1da978343ac8ac2e18d28f97", "score": "0.66954976", "text": "get tags() {\n return this.tagList\n }", "title": "" }, { "docid": "55d2fcf5990b3f30d1fd92db73044a16", "score": "0.6676341", "text": "async _getTags(sentence) {\n try {\n const pos = await import('pos')\n const words = new pos.Lexer().lex(sentence.trim())\n const tagger = new pos.Tagger()\n const taggedWords = tagger.tag(words)\n return taggedWords.map(taggedWord => taggedWord[1])\n }\n catch(e) {\n console.log('Error getting tags')\n }\n }", "title": "" }, { "docid": "8c583b5a563bf0d58d735de0c6a781b8", "score": "0.6660485", "text": "getTags(attrSelector) {\n if (!attrSelector) return [];\n const list /*NodeList*/ = this._doc.querySelectorAll(`meta[${attrSelector}]`);\n return list ? [].slice.call(list) : [];\n }", "title": "" }, { "docid": "b63e61dfa6e3aa0ab99e3a4e2feba067", "score": "0.6650778", "text": "function GetTagsHTML(result) {\n var tagsHTML = `<div class=\"panel-scroll\">`;\n\n var i = 0;\n\n tags.forEach(function (item, index, array) {\n var name = item.key;\n var dedupedEntities = [];\n\n if (Array.isArray(result[name])) {\n result[name].forEach(function (tagValue, i, tagArray) {\n name = name.replace(\"_clean\", \"\");\n if (i == 0) {\n tagsHTML += `${name}: `;\n }\n if (i <= 100) {\n if ($.inArray(tagValue, dedupedEntities) === -1) { //! in array\n dedupedEntities.push(tagValue);\n if (tagValue.length > 30) { // check tag name length\n // create substring of tag name length if too long\n tagValue = tagValue.substring(0, 50);\n }\n tagsHTML += `<button class=\"tag tag-${name}\" onclick=\"HighlightTag(event)\">${tagValue}</button>`;\n i++;\n }\n }\n });\n if (dedupedEntities.length > 0) {\n tagsHTML += \"<br/>\";\n }\n }\n });\n tagsHTML += \"</div>\"\n return tagsHTML;\n}", "title": "" }, { "docid": "8fce1d8dbd4b9dd1e33080a02d9f3d39", "score": "0.6649597", "text": "function getProjectTags(project_id){\n var ret = '';\n var tTags = alasql('SELECT * FROM tags WHERE project_id=?', [ project_id ]);\n for(var i=0;i<tTags.length;i++){\n var tTag = tTags[i];\n ret += '<span class=\"label label-info\">' + tTag.tag + '</span> ';\n }\n return ret;\n}", "title": "" }, { "docid": "25d35a49e93e7e8bbd6280629ff47964", "score": "0.664148", "text": "function getTags(id) {\n\t$.getJSON((\"tags.php?i=\" + id), function(json) {\n\t\tvar output = \"\";\n\t\tif (json.length > 0) {\n\t\t\toutput += \"Tags:<br/>\";\n\t\t\tfor(var i=0; i< json.length; i++) {\n\t\t\t\toutput += \"<span class='searchTag' onclick='searchTag(\\\"\" + json[i].title + \"\\\");'>\";\n\t\t\t\toutput += json[i].title;\n\t\t\t\toutput += \"</span>\";\n\t\t\t\tif (json[i].permanency == 0) {\n\t\t\t\t\toutput += \"<span class='dropTag' onclick='dropTag(\\\"\" + id + \"\\\", \\\"\" + json[i].id + \"\\\");' >(-)</span> \";\n\t\t\t\t} else {\n\t\t\t\t\toutput += \"<span class='dropTag' onclick='alert(\\\"This tag has been permanently added to this location\\\")' > </span> \";\n\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\n\t\t\t}\t\t\t\t\n\t\t}\n\t\t$(\"#tags\").html(output);\n\t\tpopulateOptions(id);\n\t});\t\n}", "title": "" }, { "docid": "ab635dcefdd992beb8b9813fa26986f7", "score": "0.6603067", "text": "function getTags()\n{\n\n var data = new XMLHttpRequest();\n data.open( \"GET\", \"https://cataas.com/api/tags\", false ); // false for synchronous request\n data.send( null );\n \n if(data.readyState === XMLHttpRequest.DONE)\n {\n if(data.status != 200)\n {\n return \"\"\n }\n const hel = JSON.parse(data.responseText)\n \n return hel\n }\n else\n {\n return \"\"\n }\n \n \n\n}", "title": "" }, { "docid": "13effd8d3243dc37a7878dc37e1f5a92", "score": "0.659217", "text": "_getTagAndTags(obj, tagName, tagsName)\n {\n valid(obj, 'object')\n valid(tagName, 'string')\n valid(tagsName, 'string')\n\n var arr = []\n\n if (tagName in obj) {\n arr = obj[tagName]\n }\n\n if (tagsName in obj) {\n for (let value of obj[tagsName]) {\n arr = arr.concat(value[tagName])\n }\n }\n\n return arr\n }", "title": "" }, { "docid": "20a13dc28dcb608771b2f01af529f1d8", "score": "0.6591006", "text": "function getTagNames(sel) {\n\tvar hash = {}; // this avoids dupes\n\tfor (var a=0;a<sel.items.length;a++){\n\t\thash[sel.items[a][sel.items[a].length-1].tagName]=null;\n\t}\n\tvar result = [];\n\tfor (var tag in hash){if(hash.hasOwnProperty(tag)){result.push(tag);}}\n\treturn result;\n}", "title": "" }, { "docid": "8d144b4e01dab658c2ffe406593ec50c", "score": "0.6588452", "text": "function sh_extractTags(element, tags) {\n var result = {};\n result.text = [];\n result.tags = tags;\n result.pos = 0;\n sh_extractTagsFromNodeList(element.childNodes, result);\n return result.text.join('');\n}", "title": "" }, { "docid": "76c63cd426c0ac1cb6a3408fba58aa1c", "score": "0.65871227", "text": "function extract_tag(tag_name)//, target) //person, entity or place //get trasforma l'obj di map in un'array \n{ var x = $(\".\"+tag_name).map(function(){return this.innerHTML}).get(); //mappa l'html attraverso le classi e ritorna un this.innerHtml nella callback \n var x_unique = [...new Set(x)]; //spread operator, gli elementi che map ritrova vengono convertiti in un set dalla singola variabile x senza usare un for \n //set = elimina elementi duplicati \n var list_inside = x_unique.join('</li><li onclick = \"onClick_tag(this)\">');\n //di base: tony de nonno </li> <li> Giuseppino; l'open e il closing tag di list_inside vengono montati nel content \n content = \"<h5>\" + capitalize(tag_name) + \":\" + '</h5> <li onclick = \"onClick_tag(this)\">' + list_inside + \"</li>\";\n //$(target).append(content);\n return content;\n}", "title": "" }, { "docid": "d0b70bb78c8bae2f5c381ee2680277d7", "score": "0.65707743", "text": "getTags() {\n if (_.isArray(this.tags) && !_.isEmpty(this.tags))\n return this.tags;\n\n return this.Api.get('/tags', { sort: 'id', limit: 200 })\n .then((success) => {\n let tags = _.isArray(success.data) ? success.data : [];\n this.tags = tags;\n\n return tags;\n });\n }", "title": "" }, { "docid": "f007a92e8fab65ccaf598fb4e245db2b", "score": "0.65658873", "text": "function getCurrentTags(name,date){\n let tags = [];\n let events = db.assemblies[name].events;\n for (let i=0;i<events.length;i++) {\n let event = events[i];\n if (event.date >= date) break;\n if (event.verb == 'add-tag') { \n if (!(tags.includes(event.object))) tags.push(event.object);\n } else if (event.verb == 'remove-tag') tags = tags.filter(value => value != event.object );\n else if (event.verb == 'expire-into') tags = [];\n }\n return tags;\n }", "title": "" }, { "docid": "5dc8c95bdc9b1fe182fb58e3eeee3044", "score": "0.65423024", "text": "function getActiveTags() {\n\treturn data.activeTags;\n}", "title": "" }, { "docid": "55b47d19e20da5bb969c83c9c58f7be1", "score": "0.6539571", "text": "tagFor(type) {\n return elementTagsByType.get(type);\n }", "title": "" }, { "docid": "ef9401972eee687fbae7be44ffa475bf", "score": "0.6521077", "text": "fullTags() {\r\n let result = new Set();\r\n for (let tag of this.tags) {\r\n for (let subtag of extractSubtags(tag))\r\n result.add(subtag);\r\n }\r\n return result;\r\n }", "title": "" }, { "docid": "a547588b748fc05ba40da23659daf1bd", "score": "0.6474652", "text": "getTags(attrSelector) {\n if (!attrSelector)\n return [];\n const list /*NodeList*/ = this._doc.querySelectorAll(`meta[${attrSelector}]`);\n return list ? [].slice.call(list) : [];\n }", "title": "" }, { "docid": "83162c2419ec4910a7c024e9ac6372bb", "score": "0.6471509", "text": "function getTags(str) {\n let tags = [];\n let newWord = \"\";\n\n for (let i = 0; i < str.length; i++) {\n let char = str[i];\n if (char === \"<\" || char !== \">\") {\n newWord += char;\n }\n if (char === \">\") {\n newWord += char;\n tags.push(newWord);\n newWord = \"\";\n }\n }\n return tags;\n}", "title": "" }, { "docid": "7fdac9ad4d900feef16581ec1ddac688", "score": "0.64674526", "text": "static get tags () \n\t{ \n\t\tif (!Lexer._tags) Lexer._tags = {};\n\t\treturn Lexer._tags;\n\t}", "title": "" }, { "docid": "0538d620cc9ce6358de93c38420a8fde", "score": "0.6450698", "text": "GetTag() {}", "title": "" }, { "docid": "13c71d8fa6418d7f6ffd5507b34b7f99", "score": "0.64499414", "text": "getTags(attrSelector) {\n if (!attrSelector)\n return [];\n const list /*NodeList*/ = this._doc.querySelectorAll(`meta[${attrSelector}]`);\n return list ? [].slice.call(list) : [];\n }", "title": "" }, { "docid": "13c71d8fa6418d7f6ffd5507b34b7f99", "score": "0.64499414", "text": "getTags(attrSelector) {\n if (!attrSelector)\n return [];\n const list /*NodeList*/ = this._doc.querySelectorAll(`meta[${attrSelector}]`);\n return list ? [].slice.call(list) : [];\n }", "title": "" }, { "docid": "13c71d8fa6418d7f6ffd5507b34b7f99", "score": "0.64499414", "text": "getTags(attrSelector) {\n if (!attrSelector)\n return [];\n const list /*NodeList*/ = this._doc.querySelectorAll(`meta[${attrSelector}]`);\n return list ? [].slice.call(list) : [];\n }", "title": "" }, { "docid": "49883d46dad21c99ace53602767aa46f", "score": "0.64420354", "text": "function getTag(string, tag, number = 1) {\n const open = \"<\" + tag\n const close = \"</\" + tag + \">\"\n let returnVal = []\n let data = string\n \n for (i = 0; i < number; i++) {\n const openIndex = data.indexOf(open)+open.length+1\n const closeIndex = data.indexOf(close) \n if (closeIndex >= 0) {\n returnVal.push(data.slice(openIndex, closeIndex))\n data = data.slice(closeIndex + close.length)\n } else {\n const hrefMatches = [...data.matchAll(/<link.+?href=\\\"(.+?)\\\".+?>/g)]\n if (hrefMatches && hrefMatches[0] && hrefMatches[0][1]) returnVal.push(hrefMatches[0][1])\n data = data.slice(openIndex)\n } \n }\n return returnVal\n }", "title": "" }, { "docid": "e8e544a69141f642f84183116d4df2a0", "score": "0.6431214", "text": "async getTags() {\n await until(_ => this.tags != null);\n\n return this.tags;\n }", "title": "" }, { "docid": "abfdb31971e39e1771428b0c21ec812c", "score": "0.6415035", "text": "function getPostTags() {\n var tags = '';\n for (let i = 0; i < postTagsArr.length; i++) {\n const t = postTagsArr[i];\n if (i == postTagsArr.length - 1) {\n tags += t;\n break;\n }\n tags += t + ', ';\n }\n if (tags == '') {\n tags = null\n }\n\n return tags;\n}", "title": "" }, { "docid": "c8c5369895682f1902a661bc2917aea2", "score": "0.64031255", "text": "get selectedTags()\n {\n let tagList = [];\n let bookmarkTags = this.root;\n for(let entry of bookmarkTags.querySelectorAll(\".popup-bookmark-tag-entry\"))\n {\n if(!entry.classList.contains(\"selected\"))\n continue;\n tagList.push(entry.dataset.tag);\n }\n return tagList;\n }", "title": "" }, { "docid": "f2f9400dda1eeda72a67d9df916ffcb6", "score": "0.63599616", "text": "function getCleanTags(){\n var raw_tag_list = tagify.value, \n tags = \"\";\n raw_tag_list.forEach(function(tag_json) {\n tags = tags + clean_text(tag_json['value']) + \" \"\n }); \n return tags\n}", "title": "" }, { "docid": "11019b7dc8b004e6568573372daa509d", "score": "0.63569146", "text": "function extractTags(text, tag) {\n\tif (_.isString(tag)) {\n\t\tvar openTag = '<' + tag + '[^>]*>',\n\t\t\tcloseTag = '<\\/' + tag + '>',\n\t\t\tsplit = text.split(new RegExp('(' + openTag + '|' + closeTag + ')')),\n\t\t\topen = 0,\n\t\t\tret = [];\n\t\tsplit.forEach(function(t, i){\n\t\t\tif (t.match(openTag)) {\n\t\t\t\topen++;\n\t\t\t}\n\t\t\tif (t.match(closeTag)) {\n\t\t\t\topen--;\n\t\t\t}\n\t\t\tif (open == 0 && !t.match(closeTag)) {\n\t\t\t\tret.push(t);\n\t\t\t\tif (i != split.length -1) {\n\t\t\t\t\tret.push('');\n\t\t\t\t}\n\t\t\t} else {\n\t\t\t\tret[ret.length - 1] += t;\n\t\t\t}\n\t\t});\n\t\treturn ret;\n\t} else if (_.isArray(tag)) {\n\t\treturn tag.reduce(function(text, tag){\n\t\t\treturn _.flatten(text.map(function(t, i){\n\t\t\t\treturn i % 2 ? t : extractTags(t, tag);\n\t\t\t}));\n\t\t}, [text]);\n\t} else {\n\t\treturn text;\n\t}\n}", "title": "" }, { "docid": "9d3b425c6117e87f7740d85d00a05eaa", "score": "0.6351821", "text": "function getAllDevTags(page){\n var tags = new Array();\n var tagsWithoutLetters = new Array();\n // var re = /(DEV(-|[0-9])*)/g;\n var re = /(DEV([aA-zZ]|-|[0-9])*)/g; //catches EMS\n \n tags = page.match(re);\n\n if (tags == null){\n alert(\"error, no dev tag matches found\");\n }else{\n for (var i = 0; i<tags.length; i++){\n tagsWithoutLetters[i] = tags[i].substring(4); //removes DEV-\n }\n }\n return tagsWithoutLetters;\n}", "title": "" }, { "docid": "0abd507ef2856d2a32cce2715fd527de", "score": "0.63345677", "text": "async getTags() {\n var _a;\n return await this._client.helix.tags.getStreamTagsByIds((_a = this._data.tag_ids) !== null && _a !== void 0 ? _a : []);\n }", "title": "" }, { "docid": "77df14b69166e383d2e6b6d401237329", "score": "0.6326998", "text": "async loadTags() {\n let additionalTags = []\n\n /*\n If a workspace exists and user has chosen to use the workspace preferences for tags,\n else use global settings.\n */\n if (FUNCTIONS.isWorkspace() &&\n (nova.workspace.config.get('todo.workspace-custom-tags') == 'Use Workspace Preferences')) {\n additionalTags = Configuration.PREFERENCE_TAGS.filter((tag) => {\n return nova.workspace.config.get(`todo.workspace-tag-${tag}`)\n })\n } else {\n additionalTags = Configuration.PREFERENCE_TAGS.filter((tag) => {\n return nova.config.get(`todo.global-tag-${tag}`)\n })\n }\n\n let tags = [...Configuration.DEFAULT_TAGS, ...additionalTags]\n tags = tags.map((tag) => { return tag.toUpperCase() })\n\n return tags\n }", "title": "" }, { "docid": "1e7780cd9a05228044f2a51cc751ce5b", "score": "0.6309271", "text": "renderTags(){\n\t\tif(this.state.tags.length > 0){ //si hay tags, los renderizamos\n\t\t\tvar tags = [];\n\t\t\tthis.state.tags.forEach( tag =>{\n\t\t\t\ttags.push(<Tag key={\"liTag-\"+tag.id} id={tag.id} name={tag.name} ajaxQuitTag={this.ajaxQuitTag} />)\n\t\t\t})\n\n\t\t\treturn tags\n\t\t}\n\t}", "title": "" }, { "docid": "0d7444e7ec3a2435b81fdb396c1e9ae3", "score": "0.6293203", "text": "function input_tagable_get_values($this) {\n\tvar values = $('ul.tag_list span.value', $this.parent().parent()).map(function(ind, ele){\t\t\t\n\t\treturn $(ele).text();\n\t});\n\treturn values;\n}", "title": "" }, { "docid": "76082325a219db3004f402235b3c24f1", "score": "0.62891334", "text": "function loadTagLists() {\n\tapparelTags = getInitialTags(\"apparel\");\n\tcelebrityTags = getInitialTags(\"celebrity\");\n\tcolorTags = getInitialTags(\"color\");\n\tdemographicsTags = \t[\"masculine\",\"feminine\",\"asian\",\"black\",\"african american\",\"hispanic\",\"latino\",\"spanish\",\"white\",\"american indian\",\"alaska native\",\"native hawaiian\",\"pacific islander\",\"middle eastern\",\"north african\"];\n\tfoodTags = getInitialTags(\"food\");\n\tgeneralTags = getInitialTags(\"general\");\n\tlogoTags = getInitialTags(\"logo\");\n\tmoderationTags = getInitialTags(\"moderation\");\n\tnsfwTags = getInitialTags(\"nsfw\");\n\ttravelTags = getInitialTags(\"travel\");\n\tweddingTags = getInitialTags(\"wedding\");\n}", "title": "" }, { "docid": "e53d01330123c4d2f998a8ffa35407c7", "score": "0.62758493", "text": "static get tagNames() {\n return DesignSystemProvider._tagNames;\n }", "title": "" }, { "docid": "17b6e14d5cb2ab629c02a400855fbabd", "score": "0.62735575", "text": "getAllTags(input) {\n return fetch(`/tags?tag=${input}`, {credentials: 'include'})\n .then((response) => {\n return response.json()\n })\n .then((json) => {\n return { options: json};\n })\n }", "title": "" }, { "docid": "6767330c0f8394c9c80ed1c626da9be8", "score": "0.6260148", "text": "function $groupByTagName(tagName)\n{\n var elements = document.getElementsByTagName(tagName);\n return elements;\n}", "title": "" }, { "docid": "94387a0a83cf7bc54f2dccc2af5d6ceb", "score": "0.6239354", "text": "function buildTagList(tags, fileId)\n{\n\tvar items = [];\n\t$.each(tags, function(key, val) {\n\t\titems.push(buildTagListItem(val, fileId));\n\t});\n\t\n\treturn items;\n}", "title": "" }, { "docid": "8bf26a6dcd0afa57eaaddffbe66ec626", "score": "0.62385345", "text": "function getTagsByType() {\n return tagsByType;\n }", "title": "" }, { "docid": "a7b1fe288da4330868ae42e79e588bb1", "score": "0.6238492", "text": "function getAllTags() {\n TagService.getTags().success(function(data) {\n vm.tagList = data.amount > 0 ? data.tags : [];\n vm.tagFirstSelectOption = vm.tagList ? 'Select tag' : 'No tags found, try again later';\n }).error(function(err) {\n vm.tagFirstSelectOption = 'No tags found, try again later';\n });\n }", "title": "" }, { "docid": "1bd5a1548339d935e8a714f1c7c8715e", "score": "0.62274593", "text": "getTags() {\n if (Tags.length) {\n Tags.sort((a, b) =>\n a.name.toLowerCase().localeCompare(b.name.toLowerCase())\n );\n } else {\n this.defaultTag;\n }\n\n return Tags;\n }", "title": "" }, { "docid": "899d17e2c5ba37385aacbc40866b93d4", "score": "0.6220652", "text": "function getElementsByTags(tags, arr){\n var i, j, contains;\n var ret = [];\n\n for (i = 0; i < arr.length; i++){\n contains = true;\n for (j = 0; j < tags.length; j++){\n if(arr[i].tags.indexOf(tags[j]) === -1){\n contains = false;\n break;\n }\n }\n\n if(contains){\n ret.push(arr[i]);\n }\n }\n\n return ret;\n}", "title": "" }, { "docid": "607412066c90ec2fd0e04ea9226f4d71", "score": "0.62168694", "text": "function getTagFields()\n {\n tagFields = new Array();\n var form;\n if (arguments.length == 1) {\n try {\n form = window.opener.document.f;\n } catch (e) {\n return false;\n }\n } else form = document.f;\n var name;\n var tag;\n for (var i=0; i < form.elements.length; i++) {\n name = form.elements[i].name;\n if (name && name.indexOf(\"tag_\") == 0 && name.indexOf(\"_indicator\") > 0) {\n tag = name.substr(4,3);\n tagFields[tag] = true;\n }\n }\n return true;\n }//getTagFields", "title": "" }, { "docid": "f71b7fe2fee93549cb03734414e4d4e8", "score": "0.6175289", "text": "displayTags(...tags){\n // console.log(arguments); // The old way\n console.log(tags);\n }", "title": "" }, { "docid": "81e041465e54785f94f6f4d251627acb", "score": "0.616967", "text": "function getTags(callback) {\r\n if (localStorage.tags == null || localStorage.tags == \"null\" || localStorage.tags == undefined || localStorage.tags == \"undefined\") {\r\n localStorage.tags = \"[]\";\r\n }\r\n\r\n callback(JSON.parse(localStorage.tags));\r\n }", "title": "" }, { "docid": "144119dc4185a75f89d8cfd274ec9eae", "score": "0.6167803", "text": "function getByTag(tagName){\n if(typeof(tagName)!==\"string\"){\n alert(\"Not correct tag name!\");\n } \n\n // return the node\n return document.getElementsByTagName(tagName.toUpperCase());\n}", "title": "" }, { "docid": "0a88cbef445d135d1a62af97e1bca396", "score": "0.61571217", "text": "function extractTags(html) {\n var data = {img: [], link: [], meta: []}\n\n new htmlParser.Parser({\n onopentag: function(name, attr){\n if (data[name]) {\n data[name].push({attributes: attr || {}})\n }\n }\n }).write(html)\n\n return data\n}", "title": "" }, { "docid": "4b6a1788056ae05756df348381c3f1a8", "score": "0.6155375", "text": "get tagIds() {\n var _a;\n return (_a = this._data.tag_ids) !== null && _a !== void 0 ? _a : [];\n }", "title": "" }, { "docid": "03bdcc3a1f6e94667d90d2cc51245a50", "score": "0.61423594", "text": "getTagList(){\n \n // Set by default only stores unique values.\n let tagListSet = new Set();\n\n this.data.forEach(data => {\n data.tags.forEach(tag => {\n tagListSet.add(tag);\n })\n })\n\n\n return tagListSet;\n\n }", "title": "" }, { "docid": "a9edd58fa359bb0a1b5d547d32f20675", "score": "0.6135468", "text": "function getTaggedePhotos(tagName) {\r\n fetch('https://api.tumblr.com/v2/tagged?tag=' + tagName + '&api_key=nDyNYIx6W8FFkaCCdIP36222htrVE8QrOCpkgArLE9tPx3Khu5')\r\n .then(function(response) { \r\n return response.json(); // make the response viewable in json format\r\n })\r\n .then(function(result) {\r\n \r\n const items = result.response;\r\n\r\n for(let i =0; i<items.length; i++){\r\n const item = items[i];\r\n \r\n if(item.photos!=undefined){\r\n\r\n const altSizes=item.photos[0].alt_sizes\r\n const imgSrc = altSizes[altSizes.length - 2].url;\r\n \r\n const img = document.createElement('img');\r\n\r\n img.src= imgSrc;\r\n\r\n const li = document.createElement('li');\r\n li.appendChild(img);\r\n //li.innerHTML= imgSrc;\r\n list.appendChild(img);\r\n }\r\n\r\n }\r\n\r\n return items;\r\n }\r\n )\r\n }", "title": "" }, { "docid": "305b16fac72437426900741e49cb23cf", "score": "0.6128819", "text": "function serviceGetModelTags(req, resp) {\n\t\tlogger.info(\"<Service> GetModelTags.\");\n\t\tvar getData = parseRequest(req, ['id']);\n\t\t\n\t\twriteHeaders(resp);\n\t\tgetModelTags(getData.id, function (err, obj) {\n\t\t\tif (err) error(2, resp);\n\t\t\telse resp.end(JSON.stringify({tags: obj.tags})); \n\t\t});\n\t}", "title": "" }, { "docid": "ac39ee8c15dc4b040cd143ccb59fbcd9", "score": "0.61268914", "text": "function findTags(name) {\r\n var request = $http({\r\n method: 'GET',\r\n url: API_URL + '/v3/tags/'+(name? '?filter=name%3D' + encodeURIComponent(name):''),\r\n headers: {\r\n \"Content-Type\": \"application/json\"\r\n }\r\n });\r\n return _processRequest(request);\r\n }", "title": "" }, { "docid": "a72aadc15985021f23be292a02085c79", "score": "0.6117347", "text": "function getSharedTags() {\n var tiles = layer.selectedTiles;\n if (tiles.length == 1) {\n sharedTags = tiles[0].tags;\n } else {\n // get the shared tags\n sharedTags = [];\n $.each(tiles[0].tags, function(index, tag) {\n var shared = true;\n for (var i = 1, len = tiles.length; i < len; i++) {\n if (tiles[i].tags.indexOf(tag) == -1) {\n shared = false;\n }\n }\n if (shared) {\n sharedTags.push(tag);\n }\n });\n }\n\n unsharedTags = [];\n if (layer.selectedTiles.length > 1 && sharedTags) {\n $.each(layer.selectedTiles, function(i, tile) {\n $.each(tile.tags, function(j, tag) {\n if (sharedTags.indexOf(tag) == -1 &&\n unsharedTags.indexOf(tag) == -1) {\n unsharedTags.push(tag);\n }\n });\n });\n }\n }", "title": "" }, { "docid": "aa3ee5cbd027e7090e38a74eb30dd19f", "score": "0.60979825", "text": "function extractText(tagName) {\r\n\r\n var res = [];\r\n var tags = el.querySelectorAll(tagName);\r\n for (var i = 0; i < tags.length; i++) {\r\n if (tags[i].innerText) res.push(tags[i].innerText);\r\n }\r\n return res;\r\n }", "title": "" }, { "docid": "13a49721302694ece7317e3b4cf8a0f4", "score": "0.60826635", "text": "static getBookTagsById(id) {\n for (let i = 0; i < books.length; i++) {\n if(books[i].id == id) {\n return books[i].bookTags\n }\n }\n }", "title": "" }, { "docid": "fd7e6a8e9632d1062f147fe0f4b63e86", "score": "0.6074511", "text": "function $$(tag_name){\r\n\treturn document.getElementsByTagName(tag_name);\r\n}", "title": "" }, { "docid": "188f6de1b1ff6f8956788144e8e4867a", "score": "0.6073651", "text": "async function getAllAssetTags() {\n const assetTags = await restApis._getAll(`${ADDIN_URL}/api/OneNoteAddIn/GetAllAssetTags`);\n\n return assetTags;\n}", "title": "" }, { "docid": "9338be4aa37e730d77db5ace8ce512eb", "score": "0.6070161", "text": "gt(tagName, root = undefined) {\n return (typeof root == 'undefined' ? this.r() : root).getElementsByTagName(tagName);\n }", "title": "" }, { "docid": "5a34060c00a4291cc51ab799211ed972", "score": "0.60599303", "text": "function creatingTags(data) {\n let tags = document.getElementById('tags');\n data.tags.forEach(function (item, i){\n let tag = ce(\"li\", item, \"tag\");\n tags.append(tag);\n }\n )\n }", "title": "" }, { "docid": "4c0a05cf43d0ec993f3d840b7e47dc0d", "score": "0.6044574", "text": "function getTaggedPreviews() {\r\n let selectedTag = document.querySelector(\".selected-tag-div\"); \r\n let selectedTagText = \"\";\r\n let previewArray = [];\r\n if (selectedTag.getAttribute(\"id\") === \"main-tag\") {\r\n for (let previewTag of document.querySelectorAll(\".preview-entry\")) {\r\n if (!previewTag.classList.contains(\"deleted\")) {\r\n previewArray.push(previewTag);\r\n }\r\n }\r\n } else if (selectedTag.parentNode.getAttribute(\"id\") === \"folders-list\") {\r\n selectedTagText = selectedTag.childNodes[1].innerText.toLowerCase();\r\n previewArray = document.querySelectorAll(`.${selectedTagText}`);\r\n } else {\r\n selectedTagText = selectedTag.childNodes[1].value;\r\n for (let item of document.querySelectorAll(\".preview-entry\")) {\r\n for (let tag of item.querySelectorAll(\".preview-tag\")) {\r\n if (tag.innerText === selectedTagText && !item.classList.contains(\"deleted\")) {\r\n previewArray.push(item);\r\n }\r\n }\r\n }\r\n }\r\n let idArray = [];\r\n for (let preview of previewArray) {\r\n idArray.push(preview.getAttribute(\"id\"));\r\n }\r\n return idArray;\r\n}", "title": "" }, { "docid": "5089ed69a618e601bd545ab42c30654e", "score": "0.6043699", "text": "function getInner(tag){ return tag.innerHTML;}", "title": "" }, { "docid": "38ead706aa342bd1389a2e4f670f026b", "score": "0.60365945", "text": "function tags() {\n debug('tags')\n var c = spawn('git', [ 'tag' ], { cwd: 'repo' })\n var output = ''\n c.stdout.setEncoding('utf8')\n c.stderr.pipe(process.stderr)\n c.stdout.on('data', function(d) { output += d })\n c.on('close', function(code) {\n if (code)\n throw 'failed to get tags'\n var t = output.trim().split(/\\n/).filter(function(tag) {\n tag = tag.replace(/^(v|=|release-?)+/, '')\n if (tag.indexOf(obj.version) === 0) {\n // found it!\n return true\n }\n })[0]\n if (!t) {\n console.log('%s@%s tag not found', obj.name, obj.version)\n return getTar()\n }\n checkout(t)\n })\n}", "title": "" }, { "docid": "5e319c8c6d93916cd6c3b34acfcd670e", "score": "0.60363895", "text": "function get(x, y) { return x.getElementsByTagName(y); }", "title": "" }, { "docid": "1681d5b83d5c2cc77d0633ebbefa5000", "score": "0.60328144", "text": "showTags() {\n this.tags.forEach((tag) => {\n console.log(this.title, tag);\n });\n }", "title": "" }, { "docid": "3ba33c2fb90869539be7ef32837191fd", "score": "0.6026562", "text": "function getTagList() {\n\n\tlet bodystring = 'action=gettags&filename=' + filename;\n\t\n\tconst requestOptions = {\n\t\tmethod: 'POST',\n\t\theaders: { 'Content-Type': 'application/x-www-form-urlencoded' },\n\t\tbody: bodystring,\n\t};\n\n\tfetch('api/report.php', requestOptions)\n\t.then(async response => {\n\t\tconst data = await response.json();\n\t\t\t\t\n\t\tdocument.getElementById(\"taglist_div\").innerHTML = \"\";\n\t\t\n\t\tlet taglist_markup = \"\";\n\t\n\t\tfor (var key in data[\"tags\"]) {\n\t\t\ttaglist_markup += '<div style=\"margin-bottom:1em;display:inline-block;\">' +\n\t\t\t\t'<button id=\"tagdelete_' + key + '\" style=\"height: 24px;\" class=\"glyphicon glyphicon-remove-circle deletetag\"></button>' +\n\t\t\t\t'<span class=\"tag tagbg1 taglist_tag\" id=\"tag_' + key + '\" style=\"display:block-inline;\">' + key + '</span>' +\n\t\t\t'</div>';\n\t\t};\n\t\t\n\t\tdocument.getElementById(\"taglist_div\").innerHTML = taglist_markup;\n\t\t\n\t\tlet report_tag_markup = \"\";\t\t \n\t\t\n\t\tfor (var key in data[\"reporttags\"]) {\n\t\t\tdocument.getElementById(\"tag_\" + key).classList.add(\"tagselected\");\n\t\t\treport_tag_markup += '<span class=\"tag tagbg2 tagselected\" style=\"display:block-inline;margin-right:10px;\">' + key + '</span>';\t\t\t\t\t\n\t\t};\n\t\t\t\t\t\t\t\t\n\t\tdocument.getElementById(\"report_tags\").innerHTML = report_tag_markup;\t\t\n\n\t})\n\t.catch(error => {\n\t\tconsole.error(error);\n\t});\n\n}", "title": "" }, { "docid": "fa0979af20213cf338f7850654ee5a21", "score": "0.6016899", "text": "function getAllTags() {\n fetch(\n \"https://dashboard.algorithme.co/wp-json/wp/v2/tags?slug=\" + dynamicSearch\n )\n .then(res => res.json())\n .then(getSearchResults);\n}", "title": "" }, { "docid": "6d07da1e2dc17473db881e6aaf375eb3", "score": "0.59917426", "text": "findTags()\n {\n while(this.index < this.tokens.length)\n {\n var tok = this.tokens[this.index];\n if(tok.type == tok_type.STRING)\n {\n // Action Tag\n if(TAGS.indexOf(tok.string) >= 0)\n this.tokens[this.index].type = tok_type.TAG;\n // In text tag\n else if(TEXT_MODIFIERS.indexOf(tok.string) >= 0)\n this.tokens[this.index].type = tok_type.INV_MOD;\n }\n\n ++this.index;\n }\n\n this.index = 0;\n }", "title": "" }, { "docid": "a99e0810fdfb2b3e9944a1c949da1d1f", "score": "0.598759", "text": "function getTeamTags(teamId) {\n var tags;\n $.each(teams, function(index, team) {\n if (team.short_name === teamId) {\n tags = team.tag;\n return false;\n }\n });\n\n return tags;\n }", "title": "" }, { "docid": "8ed916367629b1f469ea3a93fab12fd5", "score": "0.5982077", "text": "function findAll(test,nodes){var _a;var result=[];var stack=nodes.filter(tagtypes_1.isTag);var elem;while(elem=stack.shift()){var children=(_a=elem.children)===null||_a===void 0?void 0:_a.filter(tagtypes_1.isTag);if(children&&children.length>0){stack.unshift.apply(stack,children);}if(test(elem))result.push(elem);}return result;}", "title": "" }, { "docid": "6059b96bf00a85a5d618ee7babe4b4be", "score": "0.5964806", "text": "function canImportTags()\n{\n return true;\n}", "title": "" }, { "docid": "a5bb569593145cdcdc16d5ee98878838", "score": "0.59625655", "text": "function getSearchBarTags(){\n return $searchbar.val().split(\",\");\n }", "title": "" }, { "docid": "7d498029fd6516a19611aa977fdc2784", "score": "0.59616303", "text": "function getAllTags(callback) {\n var xhttp = new XMLHttpRequest();\n xhttp.onreadystatechange = function(){\n if(xhttp.readyState == 4 && xhttp.status == 200) {\n callback(xhttp.response);\n }\n };\n xhttp.open(\"GET\", serverUrl + \"/getAllTags\", true);\n xhttp.send();\n}", "title": "" }, { "docid": "788a60f6ab61e0d91fde575bc022cfdd", "score": "0.5955691", "text": "function extractSubtags(tag) {\r\n let result = [tag];\r\n while (tag.includes(\"/\")) {\r\n tag = tag.substring(0, tag.lastIndexOf(\"/\"));\r\n result.push(tag);\r\n }\r\n return result;\r\n}", "title": "" }, { "docid": "24616c1fe852b80dd014bf66f10ca1a7", "score": "0.5950098", "text": "function tagRoothood(arr){// typeof arrs = Array.length >1 // create a 'tree' of embedded tag !\r\n\tlet r0=newTag(arr[0]),r=r0,t;\r\n\tfor(let i=1;i<arr.length;i++){\r\n\t\tt=toDom(newTag(arr[i]),r);\r\n\t\tr=t;\r\n\t}\r\n\treturn r0;\r\n}", "title": "" }, { "docid": "6792581d87bb9f23c5295876bdf31ade", "score": "0.59356", "text": "function $t() {\n\treturn document.getElementsByTagName(arguments[0]);\n}", "title": "" }, { "docid": "4d6843bcdff5d2086aa1a9e86d1d452c", "score": "0.5931211", "text": "function tagHTML(index){\n var allrows = '';\n $.each(dataslayer.tags[index],function(q,v){\n if (v.tid && (dataslayer.options.ignoredTags.indexOf(v.tid)>-1)) return;\n if (v.utmac && (dataslayer.options.ignoredTags.indexOf(v.utmac)>-1)) return;\n\n var therow = '';\n \n if(((v.reqType=='classic') || (v.reqType=='dc_js')) && dataslayer.options.showClassic)\n therow = parseClassic(v,index + '_' + q);\n else if ((v.reqType=='universal') && dataslayer.options.showUniversal)\n therow = parseUniversal(v,index + '_' + q);\n else if ((v.reqType=='floodlight') && dataslayer.options.showFloodlight)\n therow = parseFloodlight(v);\n else if ((v.reqType=='sitecatalyst') && dataslayer.options.showSitecatalyst)\n therow = parseSiteCatalyst(v,index + '_' + q);\n else\n return; \n\n therow = '<li class=\"event submenu dlnum'+index+' '+v.reqType+'\"><table cols=2>'+therow+'</table></li>\\n';\n if (q<(dataslayer.tags[index].length-1)) therow = '<li class=\"eventbreak submenu dlnum'+index+' '+v.reqType+'\"></li>\\n'+therow;\n allrows = therow + allrows;\n }\n );\nreturn allrows;\n}", "title": "" }, { "docid": "44fdbaf0ad836d4d950a4eba57d6b090", "score": "0.59260285", "text": "function getTags(blockType) {\n\t switch (blockType) {\n\t case _draftJsUtils.BLOCK_TYPE.HEADER_ONE:\n\t return ['h1'];\n\t case _draftJsUtils.BLOCK_TYPE.HEADER_TWO:\n\t return ['h2'];\n\t case _draftJsUtils.BLOCK_TYPE.HEADER_THREE:\n\t return ['h3'];\n\t case _draftJsUtils.BLOCK_TYPE.HEADER_FOUR:\n\t return ['h4'];\n\t case _draftJsUtils.BLOCK_TYPE.HEADER_FIVE:\n\t return ['h5'];\n\t case _draftJsUtils.BLOCK_TYPE.HEADER_SIX:\n\t return ['h6'];\n\t case _draftJsUtils.BLOCK_TYPE.UNORDERED_LIST_ITEM:\n\t case _draftJsUtils.BLOCK_TYPE.ORDERED_LIST_ITEM:\n\t return ['li'];\n\t case _draftJsUtils.BLOCK_TYPE.BLOCKQUOTE:\n\t return ['blockquote'];\n\t case _draftJsUtils.BLOCK_TYPE.CODE:\n\t return ['pre', 'code'];\n\t default:\n\t return ['p'];\n\t }\n\t}", "title": "" }, { "docid": "2ea938906ff06f48a9ab15d18eafc303", "score": "0.5921889", "text": "getList() {\n return this.element.shadowRoot\n ? this.element.shadowRoot.querySelector('tag-list')\n : this.element.querySelector('tag-list');\n }", "title": "" }, { "docid": "e35cc6cee4b455319db6bcebfa7c0aa7", "score": "0.59204906", "text": "_filterTags() {\n const oThis = this;\n\n const tags = oThis.textToFilter.match(/(^|\\s)#\\w+/g);\n\n if (tags) {\n for (let ind = 0; ind < tags.length; ind++) {\n const tagName = tags[ind].trim().substring(1);\n\n if (tagName.length > tagConstants.maxTagLength) {\n continue;\n }\n\n oThis.tags.push(tagName);\n\n oThis.tagNames[tagName] = 1;\n oThis.lowerCaseTagNames.push(tagName.toLowerCase());\n oThis.tagsFromText.push(tagName);\n\n oThis.lowercaseTagNamesToActualTextsMap[tagName.toLowerCase()] =\n oThis.lowercaseTagNamesToActualTextsMap[tagName.toLowerCase()] || [];\n oThis.lowercaseTagNamesToActualTextsMap[tagName.toLowerCase()].push(tagName);\n }\n }\n }", "title": "" }, { "docid": "2fb213865c01c634461ec797361340b2", "score": "0.5913913", "text": "generateFilterTags() {\n let tags = Object.keys(this.context.state.filterData).map((tag, i) => <span id={'filter_' + tag} onClick={this.toggleTag.bind(this, tag)} key={i}><Chip className=\"filter_tag\">{tag}</Chip></span>);\n return tags;\n }", "title": "" }, { "docid": "34acd3b327b73794975acca8fad0dae6", "score": "0.5909094", "text": "function create_tags(tag_lists,cat_name){\n var text_content = \"\"\n for (z = 0; z<tag_lists.length; z++){\n if(tag_lists[z][2] == cat_name){\n console.log(tag_lists[z][2])\n text_content += '<li class=\"update_tab tag_item\" id=' + tag_lists[z][0] + ' name=' + tag_lists[z][1]+'>'\n text_content += '<a href=\"#\" class=\"nav-link active\">' + tag_lists[z][2] + '</a></li>'\n }\n else{\n text_content += '<li class=\"update_tab tag_item\" id=' + tag_lists[z][0] + ' name=' + tag_lists[z][1]+'>'\n text_content += '<a href=\"#\" class=\"nav-link text-light\">' + tag_lists[z][2] + '</a></li>'\n }\n }\n text_content += '<li class=\"add_new_tabs\"><a href=\"#\" class=\"nav-link text-light\"><i class=\"fa fa-plus\"></i></a></li>'\n return text_content\n}", "title": "" }, { "docid": "8b00decade763a31c96b9a00064d48b0", "score": "0.5902811", "text": "function renderTags(tags)\n {\n return tags.map(d => `\n <span class=${d}>${d}</span>\n `).join('');\n }", "title": "" }, { "docid": "9f20e87f887a8198f5418302f6d5beed", "score": "0.58999324", "text": "static getTagsById(id) {\n let tempArray = []\n\n for (let i = 0; i < tags.length; i++) {\n if(tags[i].id == id) {\n tempArray.push(tags[i].name)\n }\n }\n\n return tempArray\n }", "title": "" }, { "docid": "0dcf74571d948355808404c73faa65c7", "score": "0.5876664", "text": "get tagroot () {\n\t\t\treturn this.node('tags', this.shadow);\n\t\t}", "title": "" }, { "docid": "4b2083b812d8e705fa67b1cd4211f231", "score": "0.5872015", "text": "function getTagStatus() {\r\n return get('/tags/gettagstatus').then(function (res) {\r\n return res.data;\r\n }).catch(function (err) {\r\n return err.response.data;\r\n });\r\n}", "title": "" }, { "docid": "443186333d81f76d1ec1c19f874eac4e", "score": "0.58710676", "text": "function loadTags(tag) {\n\tconst fd = new FormData();\n\n\tfd.append('tag', tag);\n\tfd.append('cache', '[object Object]');\n\tfd.append('startIndex', '0');\n\tfd.append('size', '-1');\n\tfd.append('pageSize', '-1');\n\tfd.append('page', `${shutterflySite}/_/tags`);\n\tfd.append('nodeId', '3');\n\tfd.append('layout', 'ManagementTags');\n\tfd.append('version', '0');\n\tfd.append('format', 'js');\n\tfd.append('t', Shr.AR.t);\n\tfd.append('h', Shr.AR.h);\n\n\treturn fetch(`https://cmd.shutterfly.com/commands/tagsmanagement/gettags?site=${shutterflySite}&`, {\n\t\tmethod: 'POST',\n\t\tbody: fd,\n\t\tcredentials: 'include'\n\t})\n\t\t.then(rsp => rsp.text());\n}", "title": "" } ]
953369e6f09616c1f2fedb90e814787e
ensures that any boolean values in config.gypi get stringified
[ { "docid": "16bb667e77189941d9e5ea3846fce600", "score": "0.7291716", "text": "function boolsToString (k, v) {\n if (typeof v === 'boolean') {\n return String(v)\n }\n return v\n }", "title": "" } ]
[ { "docid": "6067a6075de576ed7d2d873c062a64ec", "score": "0.70387113", "text": "function boolToString(b) {\n if (b)\n return \"true\";\n return \"false\";\n }", "title": "" }, { "docid": "899b2be29354157217bf1aaa1d5a8852", "score": "0.70030546", "text": "function booleanToString(b){\n //your code here\n return b.toString()\n\n}", "title": "" }, { "docid": "6436e3b088a79b4998485306658dc6ff", "score": "0.6957587", "text": "function booleanToString(b){\n return b.toString()\n}", "title": "" }, { "docid": "79600fccd7ca7d3314997e1cbad70028", "score": "0.6872973", "text": "function booleanString(val) {\n return util.booleanify(val);\n}", "title": "" }, { "docid": "6ca6b433d428160b78c58f8d59e49295", "score": "0.6865269", "text": "function boolToString(value, provider) {\r\n return value.toString();\r\n}", "title": "" }, { "docid": "c9bfd9140ce665f426fae93676d04e7a", "score": "0.68544763", "text": "function stringifyTrueFalse(boolean) {\n return boolean ? 'true' : 'false';\n}", "title": "" }, { "docid": "5b13cd313d3afb6aaf8ce80dca0ce89b", "score": "0.68391836", "text": "function boolToString(value) {\n if (value == true) return 'true'\n else if (value == false) return 'false'\n else return value\n}", "title": "" }, { "docid": "41c391132d93f643bbdc1e96114a1ff8", "score": "0.67404354", "text": "function boolean_to_string(boo) {\n return boo ? \"true\" : \"false\"\n}", "title": "" }, { "docid": "6351d8321524d2e2057838e2d0e3973f", "score": "0.6603072", "text": "function booleanToString(b){\n let boolean =b.toString();\n console.log(boolean)\n return boolean\n}", "title": "" }, { "docid": "6e847f4d33c7cafdae1bfb665860a685", "score": "0.65735704", "text": "function translateConfigOptionToBool(value) {\n\tif(value === \"true\" || value === 1) {\n\t\treturn true;\n\t} else {\n\t\treturn false;\n\t}\n}", "title": "" }, { "docid": "2228ec59f3fa5f939f30c752e8b35ae5", "score": "0.65551347", "text": "function boolText(val) {\n if (val) return \"ON\";\n if (!val) return \"OFF\";\n}", "title": "" }, { "docid": "e3bf89b45594feb9cf5850cba48ccad2", "score": "0.654893", "text": "function boolToString(flag){\n if(flag === true){\n return 'true';\n } else if (flag === false){\n return 'false';\n }//end conditional\n}// end boolToString function", "title": "" }, { "docid": "e4a3fb9af34f9855a83751f2681ce0cc", "score": "0.6358868", "text": "function setBoolText(inBool) {\n var tempStr = \"NO\";\n if (inBool) {\n tempStr = \"YES\";\n }\n return tempStr;\n }", "title": "" }, { "docid": "b62291f2bb96b60cdc0db0202c6a3bc2", "score": "0.6346868", "text": "function booleanify(val) {\n if (val === \"true\") return true;\n if (val === \"false\") return false;\n return val;\n}", "title": "" }, { "docid": "8303a97c940dfd240e2cf6b7935b31e2", "score": "0.63134295", "text": "function title_case_boolean_values(bool_value) {\n if (bool_value == true) {\n return \"True\"\n }\n else {\n return \"False\"\n }\n}", "title": "" }, { "docid": "967ff7bed04957ed697a136970b4644c", "score": "0.629311", "text": "function coerceBooleanProperty(value){return value!=null&&\"\"+value!=='false';}", "title": "" }, { "docid": "b608ddade6376b1a4b944323cd3c9597", "score": "0.6274", "text": "function loftloader_check_boolean(value){\n\t\treturn (value === true) ? 'on' : value;\n\t}", "title": "" }, { "docid": "3d321bfde00f985df182ba480c98d8b9", "score": "0.621733", "text": "function boolToStr(opt)\n{\n\tif (opt == false)\n\t\treturn \"no\";\n\telse if (opt == true)\n\t\treturn \"yes\";\n\terror = 1;\n\treturn \"*** undefined ***\";\n}", "title": "" }, { "docid": "dc9aececd69fd23d84c68cc9c9370506", "score": "0.62088406", "text": "function makeStrings(dict) {\n Object.keys(dict).forEach(function(key) {\n if(dict[key] == null || dict[key] == true || dict[key] == false) {\n dict[key] = \"\\\"\"+dict[key]+\"\\\"\"\n }\n });\n return dict;\n}", "title": "" }, { "docid": "91b65bf4830d4203475f7675ce2d74a8", "score": "0.6186727", "text": "function translateBoolean(bool:boolean,vari:int):String{\n\tif(vari == 0) {\n\t\tif(bool){return \"on\";}\n\t\telse {return \"off\";}\n\t}\n\tif(vari == 1) {\n\t\tif(bool){return \"active\";}\n\t\telse {return \"passive\";}\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "d947af74ed135f92f03d8a0f708b341d", "score": "0.61442333", "text": "function booleanDictToString(dict) {\n\t\tconst selected = Object.keys(dict).filter(key => dict[key]);\n\t\treturn selected.join(\", \");\n\t}", "title": "" }, { "docid": "08ffa425ba0c1cacb3b26ad2394d4512", "score": "0.6136496", "text": "function convertToHandlebarsFalse(bool) {\n\t\treturn bool ? true : '';\n\t}", "title": "" }, { "docid": "d27be99dee79a7986cb336b3f562ee5e", "score": "0.606422", "text": "function toBoolean(value) {\n if (value && value.length !== 0) {\n var v = angular.lowercase(\"\" + value);\n value = !(v == 'f' || v == '0' || v == 'false' || v == 'no' || v == 'n' || v == '[]');\n } else {\n value = false;\n }\n return value;\n }", "title": "" }, { "docid": "cc65adc93ace4f19044d6bba8b388ede", "score": "0.6053298", "text": "function boolOrBoolString(value) {\n return value === \"true\" ? true : isBoolean(value) ? value : false;\n}", "title": "" }, { "docid": "34f6c997e027ca2604759d9647f4ea56", "score": "0.6036535", "text": "function isBoolean(input){\n return input.toString();\n}", "title": "" }, { "docid": "7aac78f025a90da8c757378d571c8881", "score": "0.6034598", "text": "function plBooleanXML(pl, name)\n{\n if (!pl)\n return \"\";\n return `<${name}>${pl.getBoolean(name) ? \"true\": \"false\"}</${name}>`;\n}", "title": "" }, { "docid": "2ac85f3ab906e8b73b3f4348334cdbca", "score": "0.5976287", "text": "function coerceBooleanProperty(value) {\n\t return value != null && \"\" + value !== 'false';\n\t}", "title": "" }, { "docid": "fbf3c6ed3a14885eae0656d8a4399d34", "score": "0.5970184", "text": "function IsBooleanString(annotationOptions) {\n return function (object, propertyName) {\n MetadataStorage_1.defaultMetadataStorage.addValidationMetadata({\n type: ValidationTypes_1.ValidationTypes.IS_BOOLEAN_STRING,\n sanitize: false,\n object: object,\n propertyName: propertyName,\n groups: annotationOptions && annotationOptions.groups ? annotationOptions.groups : undefined,\n message: annotationOptions && annotationOptions.message ? annotationOptions.message : undefined,\n always: annotationOptions && annotationOptions.always ? annotationOptions.always : undefined,\n each: annotationOptions && annotationOptions.each ? annotationOptions.each : undefined\n });\n };\n}", "title": "" }, { "docid": "1f7b729825b6b4a8825b8528e27c0e25", "score": "0.5934106", "text": "function booWho2(bool){\n return Object.prototype.toString.call(bool) === '[object Boolean]';\n}", "title": "" }, { "docid": "79057ed6386e6aaeaaa6be01acd5cacc", "score": "0.589961", "text": "english(bool) {\n if (bool) {\n return \"Yes\"\n }\n else {\n return \"No\"\n }\n }", "title": "" }, { "docid": "38c6445ce1e114898b8d2f29a46ce21c", "score": "0.58900946", "text": "function booWho3(bool){\n return _type(bool) === 'boolean';\n}", "title": "" }, { "docid": "4c47b19a93aa423b52fae75d4985572c", "score": "0.5861668", "text": "function boolStrNum(){return{type:[Boolean,String,Number],default:false};}", "title": "" }, { "docid": "aff43cc8f1743c18f2609850a8d47742", "score": "0.58437926", "text": "function nukeStringToBoolean(string) {\n if (typeof string === 'string' || string instanceof String) {\n switch (string.toLowerCase().trim()) {\n case \"true\": case \"yes\": case \"1\": return true;\n case \"false\": case \"no\": case \"0\": case null: return false;\n default: return Boolean(string);\n }\n }\n return string;\n}", "title": "" }, { "docid": "68d2b88fac3e2ecc60840a342a82ff54", "score": "0.5826526", "text": "function testBool(string) {\n if (string === \"true\") {\n return true;\n }\n else if (string === \"false\") {\n return false;\n }\n else if (string === \"null\") {\n return null;\n }\n else {\n return \"number\";\n }\n }", "title": "" }, { "docid": "3bd31d7335faea134743656e8f857b92", "score": "0.5819464", "text": "function interpretBooleanInput(string) {\r\n if (string == \"true\")\r\n return true;\r\n if (string == \"false\")\r\n return false;\r\n return string;\r\n}", "title": "" }, { "docid": "f4b701edf75a5dcb528f9c209630f067", "score": "0.57813036", "text": "function booWho(bool) {\n if (isNaN(bool)) {\n bool = false;\n }\n else if (bool == null || bool == undefined) {\n bool = false;\n }\n\n else if (typeof (bool) != \"boolean\") {\n bool = false;\n }\n else if (bool.toString() === \"true\") {\n bool = true;\n }\n else if (bool.toString() === \"false\") {\n bool = true;\n\n }\n return bool;\n\n}", "title": "" }, { "docid": "b25ad633b5dae071b82d8f1ad2399ced", "score": "0.5778999", "text": "parseBool(s) {\n if (s == 'ON')\n return 1;\n else if (s == 'OFF')\n return 0;\n else\n return -1;\n }", "title": "" }, { "docid": "82cc8ab50928eda71d7c30cc44f0c9f5", "score": "0.5776112", "text": "function _parseBoolean(bool) {\n bool = bool === undefined ? false : bool.toString().toLowerCase();\n if (lodash.includes(['true', 'on', '1', 'yes'], bool)) {\n bool = true;\n } else if (lodash.includes(['false', 'off', '0', 'no'], bool)) {\n bool = false;\n } else {\n bool = undefined;\n }\n return bool;\n }", "title": "" }, { "docid": "e6d29d3aec87ae4e9801d92a687b5edc", "score": "0.57595295", "text": "function toBool(str) { return str === 'true' ? true : false; }", "title": "" }, { "docid": "96cbe9af10a544a8b9e5c09caf560057", "score": "0.5754644", "text": "function booWho(bool) {\n if (typeof bool == \"boolean\"){\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "d407dff9dbff1b099b67449f60d941a9", "score": "0.5708644", "text": "get configType(){\n return Config.ConfigTypeEnum.BOOLEAN;\n }", "title": "" }, { "docid": "bd7485b761bb54c4fb62f9b7de0aeb29", "score": "0.5703791", "text": "function boolToWord( bool ){\r\n return bool ? 'Yes':'No';\r\n}", "title": "" }, { "docid": "793dcdba37e07393f585f39c952f1c5e", "score": "0.56754", "text": "function getBool(v_var)\n{\n\treturn ($p.string.getVar(this.vars,v_var)==1?true:false);\n}", "title": "" }, { "docid": "309cd714c31c89f8d6f09cff1cba13b4", "score": "0.5644481", "text": "function boolToWord( bool ){\n //...\n if (bool == true){\n return \"Yes\"\n }\n else if (bool == false){\n return \"No\"\n }\n}", "title": "" }, { "docid": "47f4060abfe254e111a278767fbb666a", "score": "0.56202966", "text": "function booWho(bool) {\n if(typeof(bool) === 'boolean'){\n return true;\n }else{\n return false;\n }\n}", "title": "" }, { "docid": "6795182433bea68ccda4703975d94bbb", "score": "0.5619731", "text": "function getBooleanParamHtml(paramName) {\n return \"<label for=\\\"conan-submissions-parameter-\" + paramName + \"-input\\\">\" +\n paramName + \": \" +\n \"</label>\" +\n \"<input id=\\\"conan-submissions-parameter-\" + paramName + \"-input\\\" \" +\n \"name=\\\"\" + paramName + \"\\\"\" +\n \"title=\\\"\" + paramName + \"\\\"\" +\n \"type=\\\"checkbox\\\"\" +\n \"onkeypress=\\\"submitOnEnter(event);\\\"\" +\n \"class=\\\"ui-widget ui-widget-content\\\"/>\";\n}", "title": "" }, { "docid": "3c6c89217b66dc1ecf7054d3901c294b", "score": "0.5617298", "text": "function confBool(obj, field) {\n if (field in obj)\n obj[field] = bool(obj[field]);\n}", "title": "" }, { "docid": "78cd16f15fcf9a92d6ead4911a1190f4", "score": "0.5617067", "text": "boolean(value) {\n if (typeof (value) === \"boolean\") {\n return value;\n }\n if (typeof (value) === \"string\") {\n value = value.toLowerCase();\n if (value === \"true\") {\n return true;\n }\n if (value === \"false\") {\n return false;\n }\n }\n throw new Error(\"invalid boolean - \" + value);\n }", "title": "" }, { "docid": "78cd16f15fcf9a92d6ead4911a1190f4", "score": "0.5617067", "text": "boolean(value) {\n if (typeof (value) === \"boolean\") {\n return value;\n }\n if (typeof (value) === \"string\") {\n value = value.toLowerCase();\n if (value === \"true\") {\n return true;\n }\n if (value === \"false\") {\n return false;\n }\n }\n throw new Error(\"invalid boolean - \" + value);\n }", "title": "" }, { "docid": "55033811f21e33abfa917491b19476d0", "score": "0.56140363", "text": "function toBoolean(str) {\n if (str === 'false' || str === 'False') return false;\n if (str === 'true' || str === 'True') return true;\n return str;\n}", "title": "" }, { "docid": "95c1e620909457d4c6a868d4acced0b2", "score": "0.5606083", "text": "function boolStrNum() {\n return {\n type: [Boolean, String, Number],\n default: false\n };\n}", "title": "" }, { "docid": "95c1e620909457d4c6a868d4acced0b2", "score": "0.5606083", "text": "function boolStrNum() {\n return {\n type: [Boolean, String, Number],\n default: false\n };\n}", "title": "" }, { "docid": "95c1e620909457d4c6a868d4acced0b2", "score": "0.5606083", "text": "function boolStrNum() {\n return {\n type: [Boolean, String, Number],\n default: false\n };\n}", "title": "" }, { "docid": "95c1e620909457d4c6a868d4acced0b2", "score": "0.5606083", "text": "function boolStrNum() {\n return {\n type: [Boolean, String, Number],\n default: false\n };\n}", "title": "" }, { "docid": "95c1e620909457d4c6a868d4acced0b2", "score": "0.5606083", "text": "function boolStrNum() {\n return {\n type: [Boolean, String, Number],\n default: false\n };\n}", "title": "" }, { "docid": "95c1e620909457d4c6a868d4acced0b2", "score": "0.5606083", "text": "function boolStrNum() {\n return {\n type: [Boolean, String, Number],\n default: false\n };\n}", "title": "" }, { "docid": "b9f2789df90e2da61f6c58f9df25e6c2", "score": "0.55895805", "text": "function stringToBoolean(string){\n\tvar out = false;\n\tif (string)\n\t\tout = Boolean(JSON.parse(string.toLowerCase().replace('no','false').replace('yes','true')))\n\treturn out;\n}", "title": "" }, { "docid": "f93690255bf8f20fcad1736e3c0b314b", "score": "0.5574916", "text": "function boolToWord( bool ){\n return bool == true ? 'Yes' : 'No';\n}", "title": "" }, { "docid": "8de517bff20483d9f7f41d98bcef9d4b", "score": "0.5564917", "text": "function boo(bool) {\n\t//check typeof bool\n\treturn typeof bool === \"boolean\";\n}", "title": "" }, { "docid": "f696a62425db1c978c9a62aa28a9d650", "score": "0.55392414", "text": "function toBool(value) {\n return toLower(value) == \"true\";\n}", "title": "" }, { "docid": "09b4e37ef82d0eea1999f83a9d4a7430", "score": "0.55357647", "text": "function boolToWord( bool ){\n if (typeof bool === 'boolean')\n return bool ? 'Yes' : 'No';\n}", "title": "" }, { "docid": "dda4fab46de1265d04efc849e6256dd6", "score": "0.553007", "text": "function isString(input) {\n if (typeof input === 'boolean') {\n return 'true';\n }\n}", "title": "" }, { "docid": "3e97ce320f23c867af1e91f19693ff01", "score": "0.5516282", "text": "isSuppressed () {\n return this.booleanLiteral('nypl:suppressed')\n }", "title": "" }, { "docid": "938e1e74f509e97a66c33b589a70a137", "score": "0.55148643", "text": "enterBooleanLiteral(ctx) {\n\t}", "title": "" }, { "docid": "56dd9ab572d2942294afb26ba758beaa", "score": "0.55048937", "text": "function boolToWord( bool ){\n return bool === true ? \"Yes\" : \"No\";\n}", "title": "" }, { "docid": "0b9a38a4043dc52e338623141902a702", "score": "0.54937893", "text": "function ourTrueOrFalse(isItTrue) {\n if (isItTrue) { \n return \"Yes, it's true\";\n }\n return \"No, it's false\";\n}", "title": "" }, { "docid": "bf5341da8ba2f90ccb09948e52174361", "score": "0.54929155", "text": "function convertToBoolProperty(val) {\n if (typeof val === 'string') {\n val = val.toLowerCase().trim();\n return (val === 'true' || val === '');\n }\n return !!val;\n}", "title": "" }, { "docid": "fdbf4375f8f41fc3c65114a59dc3a7ae", "score": "0.54706466", "text": "function correctBoolType(results) {\n for (let i = 0; i < results.length; i++) {\n if (results[i].type == \"boolean\") { results[i].type = \"True / False\"; }\n }\n return results;\n}", "title": "" }, { "docid": "03307ab0e2d55f393f40aa4fadce946c", "score": "0.54630774", "text": "static getBooleanValue(key) {\n switch (key) {\n case snapToGrid:\n case directionalDrag:\n case dragOnlyX:\n case dragOnlyY:\n case magneticSnap:\n case itemStatistics:\n return Boolean(Configuration.getData()[key]);\n default:\n throw new Error('Invalid Boolean configuration parameter: ' + key);\n }\n }", "title": "" }, { "docid": "bbe771263fe031d3be5be150b24e9498", "score": "0.54614043", "text": "set preformatted(value) {\n if (!latte._isBoolean(value))\n throw new latte.InvalidArgumentEx('value', value);\n this._preformatted = value;\n this._updateWhitespace();\n }", "title": "" }, { "docid": "11a19864197b34a7817da5302aa202f0", "score": "0.5456347", "text": "function stringifyBoolMatrix(matrix) {\n return '[\\n [' + matrix.map(row2Str).join('],\\n [') + ']\\n]';\n\n function row2Str(row) {\n return row.map(cell => cell ? ' true' : 'false').join(', ');\n }\n}", "title": "" }, { "docid": "e08b03763c3ce198086ea7d880a4a005", "score": "0.5455512", "text": "function processBooleanString(str){\n if (typeof str === 'boolean'){\n return str;\n }\n \n if (str.match(/^t/i)){\n return true;\n } else if (str.match(/^f/i)){\n return false;\n }\n throw new Error(\"Cannot process Boolean input string: \" + str);\n}", "title": "" }, { "docid": "0122b2edf67fe6f65babcdaa56765787", "score": "0.5455502", "text": "function booWho(bool){\n return typeof bool === 'boolean';\n}", "title": "" }, { "docid": "1230dfb76a1bc579aa7e7d2f301b7b59", "score": "0.54526967", "text": "function booWho(bool) {\n\n // if the type of input is a boolean,\n if (typeof bool == \"boolean\") {\n \n // then return true\n return true;\n \n // otherwise,\n } else {\n \n // return false\n return false;\n }\n }", "title": "" }, { "docid": "f439ca802cb002af48db340472a30466", "score": "0.5437101", "text": "function toBoolean(value) {\n if (value && value.length !== 0) {\n value = !(value == '0' || value == 'false');\n } else {\n value = false;\n }\n return value;\n}", "title": "" }, { "docid": "729dbb219f001d7f50407750ebabb661", "score": "0.54355854", "text": "boolean(value) {\n if (typeof (value) === \"boolean\") {\n return value;\n }\n if (typeof (value) === \"string\") {\n value = value.toLowerCase();\n if (value === \"true\") {\n return true;\n }\n if (value === \"false\") {\n return false;\n }\n }\n throw new Error(\"invalid boolean - \" + value);\n }", "title": "" }, { "docid": "a4ece9394ce53707302e403b40aeebac", "score": "0.5435296", "text": "function toBoolean(value) {\r\n return value.toString().toLowerCase() === 'true';\r\n}", "title": "" }, { "docid": "3b3edbe409122dc0ffeac44339a7b378", "score": "0.5416255", "text": "function boolToWord(bool) {\n return bool ? \"Yes\" : \"No\";\n}", "title": "" }, { "docid": "48db65990fad8da2c1ddfd1cb031e9d3", "score": "0.5400139", "text": "function toBool(str)\n{\n if (\"false\" === str)\n return false;\n else \n return str;\n}", "title": "" }, { "docid": "ea572804822c9653eb92f0799ad0fc9d", "score": "0.5398851", "text": "async transform(value, metadata) {\n if (value === true || value === 'true') {\n return true;\n }\n if (value === false || value === 'false') {\n return false;\n }\n throw this.exceptionFactory('Validation failed (boolean string is expected)');\n }", "title": "" }, { "docid": "ea572804822c9653eb92f0799ad0fc9d", "score": "0.5398851", "text": "async transform(value, metadata) {\n if (value === true || value === 'true') {\n return true;\n }\n if (value === false || value === 'false') {\n return false;\n }\n throw this.exceptionFactory('Validation failed (boolean string is expected)');\n }", "title": "" }, { "docid": "7ffcc1743abb4a196da502027ba1fdb0", "score": "0.53985775", "text": "function vtb(d) {\n return (d === 'true');\n}", "title": "" }, { "docid": "30d6d50c4849aaed111e15c50f2e87ae", "score": "0.5398421", "text": "visitBooleanLiteral(ctx) {\n\t return this.visitChildren(ctx);\n\t}", "title": "" }, { "docid": "1f3e50b4e20a41d7029c9b9c63d907a9", "score": "0.5397026", "text": "function renderValue(value) {\n var stringValue = value ? 'true' : 'false';\n return (0, _translation.translate)('display.checkbox.' + stringValue);\n}", "title": "" }, { "docid": "9ff7bc786a717b19c4db7ae9fc9a48c3", "score": "0.5393959", "text": "function envToBool(env = '') {\n if (typeof env !== 'string') {\n log('envToBool: input was not a string!');\n return false;\n }\n return ['1', 'on', 'yes', 'true'].indexOf(env.toLowerCase()) !== -1;\n}", "title": "" }, { "docid": "4acccbfc8a8fd77f67209dbeb614479b", "score": "0.53823984", "text": "function normalizeBooleanValue(value) {\n switch (typeof (value)) {\n case TYPE_BOOLEAN:\n return value;\n case TYPE_NUMBER:\n return !!value;\n case TYPE_STRING:\n return value.toLowerCase() === \"true\";\n default:\n return false;\n }\n}", "title": "" }, { "docid": "91ff4ecb2bffd72bc5c845b239c52df6", "score": "0.53807306", "text": "function boolIcon(val) {\r\n\tvar icon = 'application/images/bool/false2.png';\r\n\tif(val == \"true\" || val == 1 || val == true) {\r\n\t\ticon = 'application/images/bool/true.png';\r\n\t}\r\n\treturn '<img src=\"' + icon + '\" style=\"width: 16px; height: 16px; padding: 0px; margin: 0px;\">';\r\n}", "title": "" }, { "docid": "6b521c85586c71303fb5e1f114eb99a7", "score": "0.53741217", "text": "set defaultBool(value) {}", "title": "" }, { "docid": "a608daaa0c2d254bd03c487f23b5b00f", "score": "0.5367386", "text": "function parseBoolean(strIn) {\n if (strIn) {\n if (strIn.toLowerCase() == 'true') return true;\n }\n // Default return\n return false;\n}", "title": "" }, { "docid": "7c16dcbe5d0ccce6c8caa07478371f68", "score": "0.5360884", "text": "function boolToWord(bool) {\n return bool ? 'Yes' : 'No';\n}", "title": "" }, { "docid": "bfe96e197364b1e44b026be9d306abca", "score": "0.5358685", "text": "function parseBool(value) {\n if (typeof value === \"string\") {\n value = value.replace(/^\\s+|\\s+$/g, \"\").toLowerCase();\n if (value === \"true\" || value === \"false\")\n return value === \"true\";\n }\n return; // returns undefined\n}", "title": "" }, { "docid": "b05ec11bacc20b8920a7b43fc2661974", "score": "0.5355398", "text": "function welcomeToBooleans() {\n\t// Only change code below this line\n\n\treturn true // Change this line\n\n\t// Only change code above this line\n}", "title": "" }, { "docid": "9fbb6a4dee3f606e80dbc1419bfa56ba", "score": "0.5348174", "text": "function onOrOff(bool){\r\n /**\r\n * Returns a string corresponding to whether it is on or off\r\n * \r\n * @param {boolean} bool value to be checked\r\n * @returns {string} state \"On\" or \"Off\"\r\n */\r\n let state = (bool) ? \"On\" : \"Off\";\r\n return state;\r\n}", "title": "" }, { "docid": "3c9b85ed65c0abd783485cffa528b686", "score": "0.5348141", "text": "function buildYamlArray(myArray){\n var newString = \"\";\n for(var i = 0; i < myArray.length; i++) {\n var obj = myArray[i];\n if (obj != false && obj != \"\" && obj != \"false\" && obj != null && obj != undefined ) {\n newString = newString + ' \\n- \"' + obj.toString().trim() + '\"';\n }\n }\n return(newString)\n }", "title": "" }, { "docid": "8122db441222d84db65ae798e789891c", "score": "0.5341079", "text": "function truefalse(debug){\n let check = document.getElementById('estrutura')\n if (check.checked){\n debug = true\n } \n else{\n debug = false\n } \n return (debug)\n}", "title": "" }, { "docid": "3719c0696cfdcb89a4c4e3034868fdaa", "score": "0.53346825", "text": "function updateBoolean(name) {\n name = ' ' + name;\n function update(value) {\n switch (value) {\n case true:\n case 'true':\n return name;\n }\n return '';\n }\n update[UID] = true;\n return update;\n}", "title": "" }, { "docid": "1958f6d5b35af84fa6bde2ffbb115055", "score": "0.5333437", "text": "function isTrue(yes) {\n console.log(yes ? \"true\" : \"false\");\n}", "title": "" }, { "docid": "29807d5855a9a259af44c9fafc0c212a", "score": "0.5328143", "text": "function booleanYesNo(val) {\r\n return (val == 1) ? \"Yes\" : \"No\";\r\n}", "title": "" }, { "docid": "8ff820d03599cac54fb2568fa901fe2b", "score": "0.531784", "text": "function welcomeToBooleans() {\n\n // Only change code below this line\n \n return true; // Change this line\n \n // Only change code above this line\n }", "title": "" }, { "docid": "8d718bdb74709fab1c9d3d1b0a26d2bd", "score": "0.5317603", "text": "function parse_boolean(str) {\n if (str === undefined) return false;\n switch(str.toLowerCase()) {\n case 'true': case 't': case '1': return true;\n default: return false;\n }\n}", "title": "" } ]
63803ebcc5aa7ab81317e74d96b883b7
This function retrieves query string values from the current URL
[ { "docid": "3ee41270771fddcf300548a580194e66", "score": "0.0", "text": "function getParameterByName(name, url) {\n if (!url) url = window.location.href;\n name = name.replace(/[\\[\\]]/g, \"\\\\$&\");\n var regex = new RegExp(\"[?&]\" + name + \"(=([^&#]*)|&|#|$)\"),\n results = regex.exec(url);\n if (!results) return null;\n if (!results[2]) return '';\n return decodeURIComponent(results[2].replace(/\\+/g, \" \"));\n}", "title": "" } ]
[ { "docid": "1afd7c47c5cc5152386a9b3549d6fd05", "score": "0.8227329", "text": "function getParams() {\n return qs.parse(window.location.search);\n}", "title": "" }, { "docid": "9bdc2c66d14b5038d777dc9437397cda", "score": "0.80736244", "text": "function getQueryString() {\n var result = {}, queryString = location.search.substring(1),\n re = /([^&=]+)=([^&]*)/g, m;\n\n while (m = re.exec(queryString)) {\n result[decodeURIComponent(m[1])] = decodeURIComponent(m[2]);\n }\n\n return result;\n }", "title": "" }, { "docid": "85ea478716f4df01857f64c9c53efa1e", "score": "0.8000241", "text": "function getQueryString() {\n return window.location.search\n .substr(1)\n .split('&')\n .map(item => item.split('='))\n .reduce((acc, curr) => {\n acc[curr[0]] = curr[1];\n return acc;\n }, {});\n}", "title": "" }, { "docid": "66a6a80b2a9aab4fe7df2ac5e3a75b02", "score": "0.7887371", "text": "function get_url_params() {\n var url_params = new URLSearchParams(window.location.search);\n\n return url_params;\n}", "title": "" }, { "docid": "70f2e728667a1396a6d208e6aa38e65f", "score": "0.7769021", "text": "function getQuery(){\n\n\tvar data = window.location.search.substring(1).split('&'), query = {};\n\n\tfor (var i = 0; i < data.length; i++){\n\n\t\tdata[i] = data[i].split('=');\n\n\t\tquery[data[i][0]] = data[i][1];\n\n\t}\n\n\treturn query;\n\n}", "title": "" }, { "docid": "218e0b26b4be08f2fd43788b3fbd8fb0", "score": "0.77567303", "text": "function getUrlParams() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "title": "" }, { "docid": "d306d3a487668ee5defd75ccf2bdd06c", "score": "0.77291226", "text": "function urlQueryValues() {}", "title": "" }, { "docid": "4484bca8b3a59d4d646348fd46367042", "score": "0.77118874", "text": "function get_url_params() {\n var $_GET = {};\n\n document.location.search.replace(/\\??(?:([^=]+)=([^&]*)&?)/g, function () {\n function decode(s) {\n return decodeURIComponent(s.split(\"+\").join(\" \"));\n }\n\n $_GET[decode(arguments[1])] = decode(arguments[2]);\n });\n return $_GET;\n}", "title": "" }, { "docid": "e34d8b1f5f10da19da625a1fb412b647", "score": "0.76736856", "text": "function getQueryParams() {\n var url = window.location.href;\n var query = {};\n var params = url.substr(url.lastIndexOf('?') + 1).split('&');\n params.forEach(function (item) {\n var col = item.split('=');\n query[decodeURIComponent(col[0])] = decodeURIComponent(col[1]);\n });\n return query;\n}", "title": "" }, { "docid": "05879e4a8e488036afaafda868157652", "score": "0.7666086", "text": "function getURLParams()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "58f37065aea72d11d8c50ad65a4d6258", "score": "0.7645614", "text": "function getUrlParams(){\r\n var url = decodeURIComponent(location.href);\r\n var query = url.split('?')[1];\r\n var params = {};\r\n if (query !== ''){\r\n var arr = query.split('&');\r\n for (var i of arr) {\r\n var entry = i.split('=');\r\n var key = entry[0];\r\n var value = entry[1];\r\n params[key] = value;\r\n }\r\n }\r\n return params;\r\n}", "title": "" }, { "docid": "11d0dbf8db919bbda6f31394ccc4776f", "score": "0.7625924", "text": "function getUrlParams()\n {\n var decodedUri = decodeURIComponent(window.location.href);\n var params = [], hash;\n var hashes = decodedUri.slice(decodedUri.indexOf('?') + 1).split('&');\n\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n if (hash[1]) {\n params.push(hash[1].replace('+', ' '));\n }\n }\n return params;\n }", "title": "" }, { "docid": "92db1b54fd1b94edc99a5b8a442d8ca1", "score": "0.7623696", "text": "function getURLArgs() {\n var query_string = {};\n let query = window.location.search.substring(1);\n let vars = query.split(\"&\");\n \n for (let i=0;i<vars.length;i++) {\n let pair = vars[i].split(\"=\");\n //if is the first entry with that name\n if (typeof query_string[pair[0]] === \"undefined\") {\n query_string[pair[0]] = decodeURIComponent(pair[1]);\n //if is the second entry with that name\n } else if (typeof query_string[pair[0]] === \"string\") {\n let arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n query_string[pair[0]] = arr;\n //if is the third or more entry with that name\n } else {\n query_string[pair[0]].push(decodeURIComponent(pair[1]));\n }\n } \n return query_string;\n }", "title": "" }, { "docid": "e1dcc2eb205739cdb0973ebc625587b8", "score": "0.76166755", "text": "function getRequest(){\n\tvar params = window.location.search.replace('?','').split('&').reduce(\n\t\tfunction(prev, curr){\n\t\t\tvar temp = curr.split('=');\n\t\t\tprev[decodeURIComponent(temp[0])] = decodeURIComponent(temp[1]);\n\t\t\treturn prev;\n\t\t},{}\n\t);\n\treturn params;\n}", "title": "" }, { "docid": "76cdc94e82e3077d35cab1df75313b6d", "score": "0.7597326", "text": "function QueryString() {\n var query_string = {};\n var query = window.location.search.substring(1);\n return query;\n}", "title": "" }, { "docid": "76cdc94e82e3077d35cab1df75313b6d", "score": "0.7597326", "text": "function QueryString() {\n var query_string = {};\n var query = window.location.search.substring(1);\n return query;\n}", "title": "" }, { "docid": "070959f799700bff22ab03a4ab239bda", "score": "0.75877494", "text": "getQueryParams() {\n // This function is anonymous, is executed immediately and\n // the return value is assigned to QueryString!\n var query_string = {};\n var query = window.location.search.substring(1);\n var vars = query.split(\"&\");\n\n for (var i=0;i<vars.length;i++) {\n var pair = vars[i].split(\"=\");\n // If first entry with this name\n if (typeof query_string[pair[0]] === \"undefined\") {\n query_string[pair[0]] = decodeURIComponent(pair[1]);\n // If second entry with this name\n } else if (typeof query_string[pair[0]] === \"string\") {\n var arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n query_string[pair[0]] = arr;\n // If third or later entry with this name\n } else {\n query_string[pair[0]].push(decodeURIComponent(pair[1]));\n }\n }\n return query_string;\n }", "title": "" }, { "docid": "1b7eb47faca62dfba67d90f66ed775d2", "score": "0.7569192", "text": "function getParametersFromUrl() {\n let queryDict = {}\n location.search.substr(1).split(\"&\").forEach(function(item) {queryDict[item.split(\"=\")[0]] = item.split(\"=\")[1]})\n return queryDict\n}", "title": "" }, { "docid": "d877e7bdcd62e567c62c2b35e812e577", "score": "0.7543299", "text": "function getUrlParameters() {\n\tvar vars = [], hash;\n\tvar hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\tfor (var i = 0; i < hashes.length; i++) {\n\t\thash = hashes[i].split('=');\n\t\tvars.push(hash[0]);\n\t\tvars[hash[0]] = hash[1];\n\t}\n\treturn vars;\n}", "title": "" }, { "docid": "6a9d45ef3472002f0c9551b407fa2271", "score": "0.7542654", "text": "function getURL() {\n var query_string = {};\n var query = window.location.search.substring(1);\n var vars = query.split(\"&\");\n for (var i=0;i<vars.length;i++) {\n var pair = vars[i].split(\"=\");\n // If first entry with this name\n if (typeof query_string[pair[0]] === \"undefined\") {\n query_string[pair[0]] = decodeURIComponent(pair[1]);\n // If second entry with this name\n } else if (typeof query_string[pair[0]] === \"string\") {\n var arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n query_string[pair[0]] = arr;\n // If third or later entry with this name\n } else {\n query_string[pair[0]].push(decodeURIComponent(pair[1]));\n }\n }\n return query_string;\n}", "title": "" }, { "docid": "73f20c538693322a93440f6571c8723a", "score": "0.75407135", "text": "function GetUrlQueryString(key) {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars[key];\n }", "title": "" }, { "docid": "534304fbdb758c48735f01925aa1d208", "score": "0.75340223", "text": "function getURLParams() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n}", "title": "" }, { "docid": "3be47d38c93d1e67aa4f0ae4d78f9314", "score": "0.7504971", "text": "function GetUrlParams() { \n var e, \n d = function (s) { return decodeURIComponent(s.replace(/\\+/g, \" \")); }, \n q = window.location.search.substring(1), \n r = /([^&=]+)=?([^&]*)/g; \n \n while (e = r.exec(q)) \n urlParams[d(e[1])] = d(e[2]); \n}", "title": "" }, { "docid": "f3ef20c8bd3c6d2b0f81af83a6400c3f", "score": "0.74649173", "text": "function getQueryParams() {\n\tvar query = location.search.substr(1);\n\tvar data = query.split(\"&\");\n\tvar result = {};\n\tfor(var i=0; i<data.length; i++) {\n\t\tvar item = data[i].split(\"=\");\n\t\tresult[item[0]] = item[1];\n\t}\n\treturn result;\n}", "title": "" }, { "docid": "6805e1d7f8ea48412f536d18c43a48e2", "score": "0.7464574", "text": "getUrlParams() {\n\n //var my_url_var = window.location.href;\n let my_url_var = (window.location != window.parent.location) ?\n document.referrer :\n document.location.href;\n\n let params_list = my_url_var.split(\"?\");\n\n let final = {};\n\n if (params_list.length > 1) {\n\n let params_parsed = params_list[1].split(\"&\");\n\n for (let i = 0; i < params_parsed.length; i++) {\n let p_couple = params_parsed[i].split(\"=\");\n final[p_couple[0]] = p_couple[1];\n }\n }\n\n return final;\n }", "title": "" }, { "docid": "bec16fab585d6006a9705b63ccbf4cca", "score": "0.7444101", "text": "function parseCurrentUrlParams () {\n\t\tme.urlParams = me.paramsToObject(window.location.search.substr(1));\n\t}", "title": "" }, { "docid": "a2a44ada0fe3e2b83786af3b55127027", "score": "0.74170506", "text": "function getParams() {\n var res = {}\n var params = location.search.substr(1).split('&')\n\n for (var value; value = params.pop();) {\n var tmp = value.split('=')\n res[tmp[0]] = decodeURIComponent(tmp[1])\n }\n\n return res\n}", "title": "" }, { "docid": "9d69102ce325a52dcc5eac6c762c5d14", "score": "0.7415156", "text": "function getURLParams() {\n\tvar query = window.location.search.substring(1);\n\tvar vars = query.split(\"&\");\n\tvar query_string = {};\n\tfor (var i = 0; i < vars.length; i++) {\n\t\tvar pair = vars[i].split(\"=\");\n\t\tvar key = decodeURIComponent(pair[0]);\n\t\tvar value = decodeURIComponent(pair[1]);\n\t\t// If first entry with this name\n\t\tif (typeof query_string[key] === \"undefined\") {\n\t\t\tquery_string[key] = decodeURIComponent(value);\n\t\t\t// If second entry with this name\n\t\t} \n\t\telse if (typeof query_string[key] === \"string\") {\n\t\t\tvar arr = [query_string[key], decodeURIComponent(value)];\n\t\t\tquery_string[key] = arr;\n\t\t\t// If third or later entry with this name\n\t\t} \n\t\telse {\n\t\t\tquery_string[key].push(decodeURIComponent(value));\n\t\t}\n\t}\n\treturn query_string;\n}", "title": "" }, { "docid": "0126beb251b907f93562663333ac3f30", "score": "0.7394707", "text": "function getURLParameters () {\n let paramstrings = window.location.search.substr(1).split('&');\n\n if (paramstrings == '') {\n return {};\n }\n\n let params = {};\n\n for (let i = 0; i < paramstrings.length; ++i) {\n let param = paramstrings[i].split('=', 2);\n if (param.length == 1)\n params[param[0]] = '';\n else\n params[param[0]] = decodeURIComponent(param[1].replace(/\\+/g, ' '));\n }\n\n return params;\n}", "title": "" }, { "docid": "6a59e06a2bc5c4aee0cccba0d2b20c85", "score": "0.739229", "text": "function getUrlParams() {\n\tvar vars = {};\n\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi,\n\t\t\tfunction(m, key, value) {\n\t\t\t\tvars[key] = value;\n\t\t\t});\n\treturn vars;\n}", "title": "" }, { "docid": "d4a032c24e5f898a8d69a32dd9fa757f", "score": "0.7386339", "text": "function getQueryStrings(){\n var queryString = window.location.search || '';\n var keyValPairs = [];\n var params = {};\n queryString = queryString.substr(1);\n\n if (queryString.length){\n keyValPairs = queryString.split('&');\n for (pairNum in keyValPairs){\n var key = keyValPairs[pairNum].split('=')[0];\n if (!key.length) continue;\n if (typeof params[key] === 'undefined')\n params[key] = [];\n params[key].push(keyValPairs[pairNum].split('=')[1]);\n }\n }\n return params;\n}", "title": "" }, { "docid": "995dc321c47d7959f5fe8fc136b3a698", "score": "0.73787665", "text": "function getQueryParameters() {\n\tvar queryString = document.location.search;\n\tvar params = {};\n\tqueryString.replace(/^\\?/,'').split(\"&\").map( function(s) {\n\t\tvar part = s.split(\"=\");\n\t\tvar key = part[0];\n\t\tvar value = decodeURIComponent(part[1]);\n\t\tparams[key] = value;\n\t});\n\treturn params;\n}", "title": "" }, { "docid": "d1d263a2db2e8269bb71da94ec9d3ce4", "score": "0.737832", "text": "function getParameters() {\n\t\t\t var searchString = window.location.search.substring(1)\n\t\t\t\t, params = searchString.split(\"&\")\n\t\t\t\t, hash = {}\n\t\t\t\t;\n\n\t\t\t for (var i = 0; i < params.length; i++) {\n\t\t\t\tvar val = params[i].split(\"=\");\n\t\t\t\thash[unescape(val[0])] = unescape(val[1]);\n\t\t\t }\n\t\t\t return hash;\n\t\t\t}", "title": "" }, { "docid": "34903b3c416daac12d9872e54ba8e228", "score": "0.73728645", "text": "function getQueryVariables() {\n var inits = {}\n , query = window.location.search.substring(1).split(\"&\")\n , arg // loop variable\n\n ;\n query.forEach(function(q) {\n arg = q.split(\"=\");\n if(arg[0].length && arg[1].length)\n inits[arg[0]] = decodeURIComponent(arg[1]);\n })\n ;\n return inits;\n} // getQueryVariables()", "title": "" }, { "docid": "fd2fe52fc2d718bd000c285ee348c5e3", "score": "0.73680145", "text": "function getUrlVars() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "title": "" }, { "docid": "b32abff7eb57dee187a618f18900b7af", "score": "0.7349389", "text": "function getUrlArgs() {\n\tvar qs = (location.search.length > 0 ? location.search.substring(1) : \"\")\n\tvar args = {};\n\tvar items = qs.split(\"&\");\n\tvar item = null;\n\tname = null;\n\tvalue = null;\n\tfor (var i = 0; i < items.length; i++) {\n\t\titem = items[i].split(\"=\");\n\t\tname = decodeURIComponent(item[0]);\n\t\tvalue = decodeURIComponent(item[1]);\n\t\targs[name] = value;\n\t}\n\treturn args;\n}", "title": "" }, { "docid": "215ba0c178b7f157fc9f70918e472bd0", "score": "0.73440146", "text": "function getQueryStrings() { \n var assoc = {};\n var decode = function (s) { return decodeURIComponent(s.replace(/\\+/g, \" \")); };\n var queryString = location.search.substring(1); \n var keyValues = queryString.split('&'); \n\n for(var i in keyValues) { \n var key = keyValues[i].split('=');\n if (key.length > 1) {\n assoc[decode(key[0])] = decode(key[1]);\n }\n } \n\n return assoc; \n }", "title": "" }, { "docid": "987e734248e50bff10f6a6b50a0ecb6d", "score": "0.7343455", "text": "function q(){\n\t// This function is anonymous, is executed immediately and\n\t// the return value is assigned to QueryString!\n\tvar query_string = {};\n\tvar query = window.location.search.substring(1);\n\tvar found = false;\n\tvar vars = query.split(\"&\");\n\tfor (var i=0;i<vars.length;i++) {\n\t\tvar pair = vars[i].split(\"=\");\n\t\tif(pair[i] != \"\"){\n\t\t\t// If first entry with this name\n\t\t\tif (typeof query_string[pair[0]] === \"undefined\") {\n\t\t\t\tquery_string[pair[0]] = decodeURIComponent(pair[1]);\n\t\t\t// If second entry with this name\n\t\t\t} else if (typeof query_string[pair[0]] === \"string\"){\n\t\t\t\tvar arr = [ query_string[pair[0]],decodeURIComponent(pair[1]) ];\n\t\t\t\tquery_string[pair[0]] = arr;\n\t\t\t// If third or later entry with this name\n\t\t\t} else {\n\t\t\t\tquery_string[pair[0]].push(decodeURIComponent(pair[1]));\n\t\t\t}\n\t\t\tfound = true;\n\t\t}\n\t}\n\t//if(found) console.log(\"query_string: \", query_string);\n\t//\telse console.log(\"no query_string\");\n\treturn query_string;\n}", "title": "" }, { "docid": "afad1f2e5ee231e9cc960964fb31076c", "score": "0.73412514", "text": "function getUrlVars(){\r\n var vars = [];\r\n var loc = window.location.search.substring(1);\r\n var hashes = loc.split('&');\r\n for(var i = 0; i < hashes.length; i++){\r\n var hash = hashes[i].split('=');\r\n vars.push(hash[0]);\r\n vars[hash[0]] = hash[1];\r\n }\r\n return vars;\r\n}", "title": "" }, { "docid": "93bdeeefac8298dc0d3cb9e93189ba75", "score": "0.7332897", "text": "function parseURLVars() {\n //First grab the url\n let url = window.location.href;\n //Check if we have a GET value in there, if not return empty\n if (url.indexOf(\"?\") < 0) return \"\";\n //Now only read the get part\n let get = url.split('?')[1];\n //Split the get part into pairs, each is a key value pair\n let pairs = get.split(\"&\");\n //Iterate over the pairs, and only once you see keyword we return the value\n var returnValue = \"\";\n pairs.forEach(function (pair) {\n if (pair.split(\"=\")[0].toLowerCase() == \"keyword\") {\n returnValue = pair.split(\"=\")[1];\n }\n let parts = pair.split('=');\n GET[decodeURI(parts[0])] = decodeURI(parts[1]);\n });\n}", "title": "" }, { "docid": "b8f9b1ff463c191a18752a3fce32d7a1", "score": "0.73298013", "text": "function getVars(){\n var loc = document.location.href;\n var getString = loc.split('?');\n if(getString[1]){\n var GET = getString[1].split('&');\n var get = {};//This object will be filled with the key-value pairs and returned.\n\n for(var i = 0, l = GET.length; i < l; i++){\n var tmp = GET[i].split('=');\n get[tmp[0]] = unescape(decodeURI(tmp[1]));\n }\n return get;\n }else{\n return \"\";\n }\n}", "title": "" }, { "docid": "d354b2928c9021b2888f1798f0841e2c", "score": "0.7323783", "text": "getQueryString( key ) {\n var value = window.location.search.match( new RegExp( \"[?&]\" + key + \"=([^&]*)(&?)\", \"i\" ) );\n return value ? value[1] : value;\n }", "title": "" }, { "docid": "cec959946fb646a081fd4726f96040a6", "score": "0.7316601", "text": "function getQueryString(key) {\n var dictionary = {}, qs = window.location.search.replace(\"?\", \"\"), pairs = qs.split(\"&\");\n pairs.forEach(function (val) {\n var pair = val.split(\"=\");\n dictionary[pair[0]] = pair[1];\n });\n if (key) {\n return dictionary[key];\n }\n return dictionary;\n }", "title": "" }, { "docid": "a05f6b91fae3deda64a36dccff46ce3e", "score": "0.73128843", "text": "function getQueryString(){ \n zquery = parent.location.search; \n zquery = zquery.substring(1,zquery.length); \n return (zquery);\n}", "title": "" }, { "docid": "fc502cf265be348d8dcb04f0e3e7f0d2", "score": "0.731072", "text": "function getUrlVars() {\n\t\t\tvar vars = {};\n\t\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value;\n\t\t\t});\n\t\t\treturn vars;\n\t\t}", "title": "" }, { "docid": "112fef160721af875e7ad8a47a5fed4c", "score": "0.730499", "text": "function getUrlVars()\n {\n var vars = {};\n if (window.location.href.indexOf('?') !==-1) {\n var url = window.location.href.split('?');\n var hashes = url[1].split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n var hash = hashes[i].split('=');\n vars[hash[0]] = hash[1];\n }\n }\n \n return vars;\n }", "title": "" }, { "docid": "6ac2b9ca190ad9c5714e15e7e52e35fb", "score": "0.7304677", "text": "function getUrlVars() {\n\tif (window.location.href.indexOf('?') === -1) {\n\t\treturn [];\n\t}\n\n\tvar vars = [];\n\tvar hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\tjQuery.each(hashes, function(i, hash) {\n\t\thash = hashes[i].split('=');\n\t\tvars.push(hash[0]);\n\t\tvars[hash[0]] = decodeURIComponent(hash[1]);\n\t});\n\treturn vars;\n}", "title": "" }, { "docid": "ab8243223fb2e147fe52e8ac06ce8801", "score": "0.72987014", "text": "function getUrlVars()\r\n{\r\n var vars = [], hash;\r\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\r\n for(var i = 0; i < hashes.length; i++)\r\n {\r\n hash = hashes[i].split('=');\r\n vars.push(hash[0]);\r\n vars[hash[0]] = hash[1];\r\n }\r\n return vars;\r\n}", "title": "" }, { "docid": "60c546cc6777a412d7582e90257be1e0", "score": "0.72959185", "text": "function getURLParams() {\n try {\n var search = location.search.substring(1);\n return search ? JSON.parse('{\"' + search.replace(/&/g, '\",\"').replace(/=/g, '\":\"') + '\"}',\n function(key, value) {\n return key === \"\" ? value : decodeURIComponent(value);\n }) : {};\n } catch (_) {\n return {};\n }\n}", "title": "" }, { "docid": "4e08443575386bf14d69f2b8629732c8", "score": "0.72898364", "text": "function getUrlVars()\n {\n var vars = [], hash;\n var vhref = window.location.href;\n //console.log('vhref:'+vhref);\n var hashes = vhref.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "title": "" }, { "docid": "39ea19e48d8fb4c8441d3b9bd061ab4f", "score": "0.728121", "text": "function parseQueryString() {\n var query = {};\n var args = document.location.search.substring(1).split('&');\n for (var arg in args) {\n var m = args[arg].split('=');\n query[decodeURIComponent(m[0])] = decodeURIComponent(m[1]);\n }\n\n return query;\n}", "title": "" }, { "docid": "b03cfd373432d810c9ce6c6c6b9306ce", "score": "0.72772443", "text": "function getUrlVars() \n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "335a4feb2ee041986462dff14c505e86", "score": "0.7274374", "text": "function getUrlVars() {\n\t\t\t\n\t\t\t\n\t\t\tvar vars = {};\n\t\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value;\n\t\t\t});\n\t\t\treturn vars;\n\t\t\t\n\t\t}", "title": "" }, { "docid": "f87deda548edc851b1f998e34f71f143", "score": "0.72730553", "text": "function getSearchParameters() {\n var prmstr = window.location.search.substr(1);\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n}", "title": "" }, { "docid": "13be029416284a3e4207fed835f17f17", "score": "0.7268915", "text": "function getQuerystring(e,a){null==a&&(a=\"\"),e=e.replace(/[\\[]/,\"\\\\[\").replace(/[\\]]/,\"\\\\]\");var t=new RegExp(\"[\\\\?&]\"+e+\"=([^&#]*)\"),o=t.exec(window.location.href);return null==o?a:o[1]}", "title": "" }, { "docid": "fb0b5d86dfba630e92d4a944661accab", "score": "0.7266098", "text": "function getUrlVars() {\n\t\t\tvar vars = {};\n\t\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\t\tvars[key] = value;\n\t\t\t});\n\t\t\treturn vars;\n\t\t}", "title": "" }, { "docid": "9a2f3ecb42b21c008948d56dc97b5bb5", "score": "0.7265419", "text": "function getQueryStrings() { \n var assoc = {};\n var decode = function (s) { return decodeURIComponent(s.replace(/\\+/g, \" \")); };\n var queryString = location.search.substring(1); \n var keyValues = queryString.split('&'); \n\n for(var i in keyValues) { \n var key = keyValues[i].split('=');\n if (key.length > 1) {\n assoc[decode(key[0])] = decode(key[1]);\n }\n } \n\n return assoc; \n}", "title": "" }, { "docid": "6cba5ca426d0e8da0c1769a1a5b7df65", "score": "0.72625726", "text": "function GetUrlVars() {\nvar vars = {};\nvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars[key] = value;\n});\nreturn vars;\n}", "title": "" }, { "docid": "6f0d26e73a3a327157c567fee9869bbc", "score": "0.7254483", "text": "function getUrlVars()\n {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n\n return vars;\n }", "title": "" }, { "docid": "e0f74db17260bdf3a12d511bac2cd892", "score": "0.7245245", "text": "function getUrlVars()\n\t{\n\t var vars = [], hash;\n\t var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\t for(var i = 0; i < hashes.length; i++)\n\t {\n\t hash = hashes[i].split('=');\n\t vars.push(hash[0]);\n\t vars[hash[0]] = hash[1];\n\t }\n\t return vars;\n\t}", "title": "" }, { "docid": "e0f74db17260bdf3a12d511bac2cd892", "score": "0.7245245", "text": "function getUrlVars()\n\t{\n\t var vars = [], hash;\n\t var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n\t for(var i = 0; i < hashes.length; i++)\n\t {\n\t hash = hashes[i].split('=');\n\t vars.push(hash[0]);\n\t vars[hash[0]] = hash[1];\n\t }\n\t return vars;\n\t}", "title": "" }, { "docid": "3b7795c3c97655904264c6b947fb98d1", "score": "0.72445637", "text": "function getURLParameters() {\n var params = {};\n if (location.search) {\n var parts = location.search.substring(1).split(\"&\");\n for (var i = 0; i < parts.length; i++) {\n var pair = parts[i].split(\"=\");\n if (!pair[0]) {\n continue;\n }\n params[pair[0]] = pair[1] || \"\";\n }\n }\n return params;\n}", "title": "" }, { "docid": "56dc7c7e56839de02732e0bdef4f510d", "score": "0.72401434", "text": "function getUrlVars() { \r\n var vars = {}, hash;\r\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\r\n for(var i = 0; i < hashes.length; i++)\r\n {\r\n hash = hashes[i].split('=');\r\n vars[hash[0]] = hash[1];\r\n }\r\n console.log(vars);\r\n return vars;\r\n }", "title": "" }, { "docid": "ca2352ff9bd94982d5b4836ded5c0f6e", "score": "0.72309345", "text": "function ekGetSearchParams() {\n var result = {};\n var searchParams = window.location.href.split('?');\n if (searchParams && searchParams.length > 1) {\n var vals = searchParams[1].split('&');\n for (var i = 0; i < vals.length; i++) {\n var next = vals[i].split('=');\n var key = next[0];\n var val = decodeURIComponent(next[1].replace(/\\+/g,' '));\n result[key] = val;\n }\n }\n return result;\n }", "title": "" }, { "docid": "8b07cb195ec3d7cd9285d21cd5b7b5e6", "score": "0.723056", "text": "function $_GET(name) {\n\tvar match = RegExp('[?&]' + name + '=([^&]*)').exec(window.location.search);\n\treturn match && decodeURIComponent(match[1].replace(/\\+/g,' '));\n}", "title": "" }, { "docid": "fc94ba5f5430223230c13efd2ebb99d8", "score": "0.7226944", "text": "function getUrlVars() {\n \t\tvar vars = {};\n \t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n \t\tvars[key] = value;\n \t\t});\n \t\treturn vars;\n\t\t}", "title": "" }, { "docid": "fc94ba5f5430223230c13efd2ebb99d8", "score": "0.7226944", "text": "function getUrlVars() {\n \t\tvar vars = {};\n \t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n \t\tvars[key] = value;\n \t\t});\n \t\treturn vars;\n\t\t}", "title": "" }, { "docid": "b3543b999f718d2a22bfb7cea0e5c77a", "score": "0.7224262", "text": "function getUrlVars() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "title": "" }, { "docid": "f5de19acb17930c61786afc9a6d4aa10", "score": "0.7216983", "text": "function getURL() {\r\n let loc = document.location.href;\r\n\r\n if (loc.indexOf('?') > 0) {\r\n let getString = loc.split('?')[1];\r\n let GET = getString.split('&');\r\n var get = {};\r\n for (var i = 0, l = GET.length; i < l; i++) {\r\n var tmp = GET[i].split('=');\r\n get[tmp[0]] = unescape(decodeURI(tmp[1]));\r\n }\r\n return get;\r\n }\r\n}", "title": "" }, { "docid": "9f05183310b2e9975e64dbafcc53883d", "score": "0.72144186", "text": "function getUrlVars() {\r\n\tvar vars = {};\r\n\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\r\n\t\tvars[key] = value;\r\n\t});\r\n\treturn vars;\r\n}", "title": "" }, { "docid": "6f075b42a6af8e245b7ce47a1f4df747", "score": "0.72126454", "text": "function getUrlVars() {\r\n var vars = {};\r\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \r\n function(m,key,value) {\r\n vars[key] = value;\r\n });\r\n return vars;\r\n }", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "e737e88df6da29461a613739ea3a7af7", "score": "0.72120976", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "d0539055779014d7d79e19b96158b3ad", "score": "0.7206521", "text": "function getUrlVars() {\n //var vars = {};\n var vars;\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars = key + '=' + value;\n });\n return vars;\n}", "title": "" }, { "docid": "2f90e910ed2703308d3d39020b620f12", "score": "0.72026795", "text": "function getUrlParams() \n{\n var paramMap = {};\n\n if (location.search.length === 0) {\n return paramMap;\n }\n\n var parts = location.search.substring(1).split(\"&\");\n\n for (var i = 0; i < parts.length; i ++) {\n var component = parts[i].split(\"=\");\n paramMap [decodeURIComponent(component[0])] = decodeURIComponent(component[1]);\n }\n\n return paramMap;\n}", "title": "" }, { "docid": "1dca959f8493fb17d16a349f2a9bfa43", "score": "0.72002083", "text": "function getUrlVars() {\n var vars = [],\n hash;\n var hashes = window.location.href\n .slice(window.location.href.indexOf(\"?\") + 1)\n .split(\"&\");\n for (var i = 0; i < hashes.length; i++) {\n hash = hashes[i].split(\"=\");\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n }", "title": "" }, { "docid": "124e67ab5c4f9b01790aa2357cfc99a1", "score": "0.72000533", "text": "function getURLSearch() {\n return window.location.search.substring(1);\n}", "title": "" }, { "docid": "8d2445c3391406650c96f0a980bf9c3a", "score": "0.7193835", "text": "function get_query_param(param) {\n var urlKeyValuePairs = {}\n window.location.href.split(\"#\")[1].split(\"&\").forEach(function(d) {\n var m = d.split(\"=\");\n urlKeyValuePairs[m[0]] = m[1]\n })\n return urlKeyValuePairs[param].split(',')\n}", "title": "" }, { "docid": "8d2445c3391406650c96f0a980bf9c3a", "score": "0.7193835", "text": "function get_query_param(param) {\n var urlKeyValuePairs = {}\n window.location.href.split(\"#\")[1].split(\"&\").forEach(function(d) {\n var m = d.split(\"=\");\n urlKeyValuePairs[m[0]] = m[1]\n })\n return urlKeyValuePairs[param].split(',')\n}", "title": "" }, { "docid": "68ea78094fc35c0bc621aa620842e81f", "score": "0.7190027", "text": "function getSearchParameters() {\n var prmstr = window.location.search.substr(1);\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\n }", "title": "" }, { "docid": "7fed62d0cf3fef8b94a77889a3b831b2", "score": "0.7183375", "text": "function GetQueryString(name){\r\n\t var reg = new RegExp(\"(^|&)\"+ name +\"=([^&]*)(&|$)\");\r\n\t var r = window.location.search.substr(1).match(reg);\r\n\t if(r!=null)return unescape(r[2]); return null;\r\n\t}", "title": "" }, { "docid": "b2780be0d6091224dad32a01383d0f1c", "score": "0.7181943", "text": "function getUrlVars(){\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "3bd70fba714cc8045d0feeb2fa5a4098", "score": "0.7175852", "text": "function umGetQueryString(name){\n var reg = new RegExp(\"(^|&)\"+ name +\"=([^&]*)(&|$)\");\n var r = window.location.search.substr(1).match(reg);\n if(r!=null)return unescape(r[2]); return null;\n}", "title": "" }, { "docid": "f728664e2c1367cb0d6152fdfe4244ea", "score": "0.7168845", "text": "function getSearchParameters() {\r\n var prmstr = window.location.search.substr(1);\r\n return prmstr != null && prmstr != \"\" ? transformToAssocArray(prmstr) : {};\r\n }", "title": "" }, { "docid": "fc2715e672593f1d859125d03e6fa472", "score": "0.71687484", "text": "function getUrlVars()\r\n{\r\n var vars = {};\r\n\r\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value)\r\n {\r\n vars[key] = value;\r\n });\r\n return vars;\r\n}", "title": "" }, { "docid": "8fb99ee7bc7338c6a42c838daee73584", "score": "0.71686745", "text": "function getQuerystring(key) {\n var regex, qs;\n key = key.replace(/[\\[]/, \"\\\\\\[\").replace(/[\\]]/, \"\\\\\\]\");\n regex = new RegExp(\"[\\\\?&]\" + key + \"=([^&#]*)\");\n qs = regex.exec(window.location.href);\n if (qs === null) {\n return null;\n } else {\n return qs[1];\n }\n }", "title": "" }, { "docid": "5235e120563b66b5a9ac2a0ae54b154c", "score": "0.7161658", "text": "function getUrlVars()\n{\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n\thash = hashes[i].split('=');\n\tvars.push(hash[0]);\n\tvars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "4bc520dc1e91701fd577a6eaaefd3e28", "score": "0.7161402", "text": "function getQueryString(name) {\n name = name.replace(/[\\[]/, \"\\\\[\").replace(/[\\]]/, \"\\\\]\");\n var regex = new RegExp(\"[\\\\?&]\" + name + \"=([^&#]*)\"),\n results = regex.exec(location.search);\n return results === null ? \"\" : decodeURIComponent(results[1].replace(/\\+/g, \" \"));\n}", "title": "" }, { "docid": "cc2b76fd4b513ed16382847df17b86f2", "score": "0.7158646", "text": "function getParams()\n{\n var idx = document.URL.indexOf('?');\n var params = [];\n if (idx != -1) {\n var pairs = document.URL.substring(idx+1, document.URL.length).split('&');\n for (var i=0; i<pairs.length; i++)\n {\n nameVal = pairs[i].split('=');\n params[nameVal[0]] = nameVal[1];\n }\n }\n return params;\n}", "title": "" }, { "docid": "d2396dbd1f7da1aa3c3e4a3abf9c533e", "score": "0.7152736", "text": "get queryString(){\n\t\tconst qm = this._href.lastIndexOf('?');\n\t\tif(qm < 0){\n\t\t\treturn '';\n\t\t}\n\t\treturn this._href.substring(qm);\n\t}", "title": "" }, { "docid": "01decfa331fe9b23fbf51c92fbca0c9c", "score": "0.7149782", "text": "function getUrlVars() {\n var vars = [], hash;\n var hashes = window.location.href.slice(window.location.href.indexOf('?') + 1).split('&');\n for(var i = 0; i < hashes.length; i++)\n {\n hash = hashes[i].split('=');\n vars.push(hash[0]);\n vars[hash[0]] = hash[1];\n }\n return vars;\n}", "title": "" }, { "docid": "927178c46fd44df199a4a7675dee03d1", "score": "0.71488875", "text": "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \n function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "title": "" }, { "docid": "927178c46fd44df199a4a7675dee03d1", "score": "0.71488875", "text": "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \n function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "title": "" }, { "docid": "0b1fcba615cb29939746a9bb8862ad0a", "score": "0.7148323", "text": "function getUrlVars() {\n\t\tvar vars = {};\n\t\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n\t\t\tvars[key] = value;\n\t\t});\n\t\treturn vars;\n\t}", "title": "" }, { "docid": "7b6d8999a41d670c2d3091bc28612f36", "score": "0.71461064", "text": "function getUrlVars()\r\n\t{\r\n\tvar vars = {};\r\n\tvar parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, \r\n\t\tfunction(m,key,value) {\r\n\t\t vars[key] = value;\r\n\t\t});\r\n\treturn vars;\r\n\t}", "title": "" }, { "docid": "a99b3d4aaab8c79afa8d7ccae0d68888", "score": "0.71445465", "text": "function getUrlVars() {\n var vars = {};\n var parts = window.location.href.replace(/[?&]+([^=&]+)=([^&]*)/gi, function(m,key,value) {\n vars[key] = value;\n });\n return vars;\n }", "title": "" } ]
970b975dd1bfcce7f487a3f0d3cac0b0
Function to retrieve validation rules for a given objectType.
[ { "docid": "7155a3c289b79648fd4c8dfffc58ae91", "score": "0.7276633", "text": "function getValidationRules(objtype) {\n return serverCall('getValidationRules', new Array(objtype), null, false);\n}", "title": "" } ]
[ { "docid": "80375bf66d68cf86754035a35c2b1714", "score": "0.5244269", "text": "function getRules(){\n let constraints = document.getElementsByClassName(\"constraintRow\");\n var ruleList= [];\n for (let con of constraints){\n var ruleobj = {};\n let property = con.children[0].options[con.children[0].selectedIndex].value;\n let operator = con.children[1].options[con.children[1].selectedIndex].value;\n let value = con.children[2].options[con.children[2].selectedIndex].value;\n if (checkRules(property,operator,value)){\n ruleobj[\"property\"] = property;\n ruleobj[\"operator\"] = operator;\n ruleobj[\"value\"] = value;\n ruleList.push(ruleobj);\n }else {\n ruleList.push(\"EMPTYFIELD\");\n }\n\n }\n return ruleList;\n}", "title": "" }, { "docid": "dac30e7faa8dd085cd8241e4cdb92f4b", "score": "0.5061281", "text": "getValidatorData(Rule){\n // max size byte\n let validators = this.getSchemaElement().validators;\n for(let v=0;v<validators.length;v++){\n if(validators[v].type==Rule){\n return validators[v];\n }\n }\n return null;\n }", "title": "" }, { "docid": "d2e09ab29adabbd84d5517a728a70d4b", "score": "0.49344304", "text": "function _getRules(element){\n\t\t\t\tvar rulesParsed = element.attr('class');\n\t\t\t\tif(rulesParsed){\n\t\t\t\t\tvar rules = rulesParsed.split(' ');\n\t\t\t\t\t_validate(element, rules);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "8c26a168351e441429240fdcd82ff59e", "score": "0.4923038", "text": "function getActiveValidationRules() {\n\n var validationRules = [];\n\n if (m_validationRules.SingleSeatBetweenSeats) {\n validationRules.push(new SeatRule(m_validationRules.SingleSeatBetweenSeats, checkSingleSeatBetweenSeats));\n }\n\n if (m_validationRules.SingleSeatGapFromAisle) {\n validationRules.push(new SeatRule(m_validationRules.SingleSeatGapFromAisle, checkSingleSeatGapFromAisle));\n }\n\n if (m_validationRules.SingleSeatGapFromSoldSeats) {\n validationRules.push(new SeatRule(m_validationRules.SingleSeatGapFromSoldSeats, checkSingleSeatGapFromSoldSeats));\n }\n\n if (m_validationRules.MustFillSofa) {\n validationRules.push(new SeatRule(m_validationRules.MustFillSofa, checkSofaFull));\n }\n\n if (m_validationRules.EnforceCompanionSeatRule) {\n validationRules.push(new SeatRule(m_validationRules.EnforceCompanionSeatRule, checkCompanionSeats));\n }\n\n return validationRules;\n\n}", "title": "" }, { "docid": "5f2a37ecee010e67fa4ef0c77d9d6f76", "score": "0.49217972", "text": "function visitUsingRules(schema, typeInfo, documentAST, rules) {\n var context = new ValidationContext(schema, documentAST, typeInfo);\n var visitors = rules.map(function (rule) {\n return rule(context);\n });\n // Visit the whole document with each instance of all provided rules.\n Object(__WEBPACK_IMPORTED_MODULE_2__language_visitor__[\"c\" /* visit */])(documentAST, Object(__WEBPACK_IMPORTED_MODULE_2__language_visitor__[\"e\" /* visitWithTypeInfo */])(typeInfo, Object(__WEBPACK_IMPORTED_MODULE_2__language_visitor__[\"d\" /* visitInParallel */])(visitors)));\n return context.getErrors();\n}", "title": "" }, { "docid": "5f2a37ecee010e67fa4ef0c77d9d6f76", "score": "0.49217972", "text": "function visitUsingRules(schema, typeInfo, documentAST, rules) {\n var context = new ValidationContext(schema, documentAST, typeInfo);\n var visitors = rules.map(function (rule) {\n return rule(context);\n });\n // Visit the whole document with each instance of all provided rules.\n Object(__WEBPACK_IMPORTED_MODULE_2__language_visitor__[\"c\" /* visit */])(documentAST, Object(__WEBPACK_IMPORTED_MODULE_2__language_visitor__[\"e\" /* visitWithTypeInfo */])(typeInfo, Object(__WEBPACK_IMPORTED_MODULE_2__language_visitor__[\"d\" /* visitInParallel */])(visitors)));\n return context.getErrors();\n}", "title": "" }, { "docid": "60e18053a1c0e4046661c4bdf0e6026a", "score": "0.48498732", "text": "function globalValidationRules() {\r\n\r\n // var rules = new Rules();\r\n // rules.addMulti([{\r\n // \"user_id\": {\r\n // required: true,\r\n // int: true\r\n // }\r\n // }, {\r\n // \"lat\": {\r\n // lat: true\r\n // }\r\n // }, {\r\n // \"lon\": {\r\n // lon: true\r\n // }\r\n // }]);\r\n // return rules;\r\n\r\n}", "title": "" }, { "docid": "c18f216ead7e740dda890a244ea6098b", "score": "0.48489803", "text": "get rules() {\n\t\treturn this.__rules;\n\t}", "title": "" }, { "docid": "1b500136bdfe15e6b3d88ceaf756680e", "score": "0.4811898", "text": "function getCSSRules(style) {\n let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n const rules = [];\n styleDefinitions.forEach(definition => {\n if (typeof definition.generate === 'function') {\n rules.push(...definition.generate(style, options));\n }\n });\n return rules;\n}", "title": "" }, { "docid": "d68500674368c81a78528bc4c3843897", "score": "0.4802052", "text": "function all() {\n\t for (var _len = arguments.length, validators = new Array(_len), _key = 0; _key < _len; _key++) {\n\t validators[_key] = arguments[_key];\n\t }\n\t\n\t function allPropTypes() {\n\t for (var _len2 = arguments.length, args = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n\t args[_key2] = arguments[_key2];\n\t }\n\t\n\t var error = null;\n\t validators.forEach(function (validator) {\n\t if (error != null) {\n\t return;\n\t }\n\t\n\t var result = validator.apply(void 0, args);\n\t\n\t if (result != null) {\n\t error = result;\n\t }\n\t });\n\t return error;\n\t }\n\t\n\t return (0, _createChainableTypeChecker[\"default\"])(allPropTypes);\n\t}", "title": "" }, { "docid": "d882d3c3cae001104784012086633507", "score": "0.47744447", "text": "function visitUsingRules(schema, typeInfo, documentAST, rules) {\n\t var context = new ValidationContext(schema, documentAST, typeInfo);\n\t var visitors = rules.map(function (rule) {\n\t return rule(context);\n\t });\n\t // Visit the whole document with each instance of all provided rules.\n\t (0, _visitor.visit)(documentAST, (0, _visitor.visitWithTypeInfo)(typeInfo, (0, _visitor.visitInParallel)(visitors)));\n\t return context.getErrors();\n\t}", "title": "" }, { "docid": "8639c851cb6804fbb67c4d1f1b2953d3", "score": "0.47307345", "text": "function visitUsingRules(schema, typeInfo, documentAST, rules) {\n var context = new _ValidationContext2.default(schema, documentAST, typeInfo);\n var visitors = rules.map(function (rule) {\n return rule(context);\n });\n // Visit the whole document with each instance of all provided rules.\n (0, _visitor.visit)(documentAST, (0, _visitor.visitWithTypeInfo)(typeInfo, (0, _visitor.visitInParallel)(visitors)));\n return context.getErrors();\n}", "title": "" }, { "docid": "a2bdacb20a20483142c85cb093c3bade", "score": "0.47291118", "text": "function visitUsingRules(schema, typeInfo, documentAST, rules) {\n\t var context = new ValidationContext(schema, documentAST, typeInfo);\n\t var visitors = rules.map(function (rule) {\n\t return rule(context);\n\t });\n\t // Visit the whole document with each instance of all provided rules.\n\t (0, _languageVisitor.visit)(documentAST, (0, _languageVisitor.visitWithTypeInfo)(typeInfo, (0, _languageVisitor.visitInParallel)(visitors)));\n\t return context.getErrors();\n\t}", "title": "" }, { "docid": "e2ec20ddb3fda44872446de3eb5873c2", "score": "0.47152457", "text": "validationRules() {\n if(this.validation && this.validation.$params) {\n return this.validation.$params;\n }\n return {};\n }", "title": "" }, { "docid": "f9f669d42593ca78ac48822527876ec9", "score": "0.4710268", "text": "function validateProps(type, obj, validator) {\r\n // set default valiators based on type and override\r\n if (type === 'string' && !validator) {\r\n validator = defaultStrValidator;\r\n } else if (!validator) {\r\n validator = defaultValidator;\r\n }\r\n\r\n // filter and return\r\n const invalidPropList = Object.keys(obj).filter(\r\n prop => !validator(obj[prop])\r\n );\r\n return invalidPropList.length\r\n ? [\r\n `The following fields are empty or invalid: ${invalidPropList.join(', ')}`\r\n ] : [];\r\n }", "title": "" }, { "docid": "91af2ad11fd0ec36556b9a8bad7e1246", "score": "0.46830827", "text": "function findMatchedRules(rules, owner) {\n const matchOwner = (actorType, key) =>\n (actorType === 'user' && key === owner.email) ||\n (actorType === 'team' && key === owner.name);\n\n const actorHasOwner = ([actorType, key]) =>\n actorType === owner.type && matchOwner(actorType, key);\n\n return rules\n .filter(([_, ruleActors]) => ruleActors.find(actorHasOwner))\n .map(([rule]) => rule);\n}", "title": "" }, { "docid": "4d3e8a7e91a886cf9946d0e650048b71", "score": "0.46809453", "text": "function rulelist() {\n this.many1(this.choicef(rule, ws_seq));\n return this.rules;\n}", "title": "" }, { "docid": "18fee3c8f07d16084d2b20c7e22d2fac", "score": "0.46711388", "text": "function checker() {\n for (var _len5 = arguments.length, validators = Array(_len5), _key5 = 0; _key5 < _len5; _key5++) {\n validators[_key5] = arguments[_key5];\n }\n\n return function (obj) {\n return validators.reduce(function (errs, check) {\n if (check(obj)) {\n return errs;\n } else {\n return [].concat((0, _toConsumableArray3.default)(errs), [check.message]);\n }\n }, []);\n };\n}", "title": "" }, { "docid": "cd72abe324df133751cbe7ab3ba3a133", "score": "0.4660267", "text": "function RbmGetStyleSheetRules(styleSheet){\n try {\n return RbmBrowserType.IE ? styleSheet.rules : styleSheet.cssRules;\n }\n catch(e) {\n return null;\n }\n}", "title": "" }, { "docid": "f9fe1c377e8a8c00bc319cafad4f21f8", "score": "0.46419063", "text": "function getFailRules (openapi) {\n let failRules = [];\n\n if(openapi){\n failRules.push('edit-object-property-restriction');\n failRules.push('add-object-property-restriction');\n failRules.push('add-required-object-property');\n failRules.push('add-required-param');\n failRules.push('add-required-header');\n failRules.push('edit-array-items-type');\n failRules.push('edit-object-property-required');\n failRules.push('edit-object-property-type');\n failRules.push('edit-operation-id');\n failRules.push('edit-param-collection-format');\n failRules.push('edit-param-in');\n failRules.push('edit-param-required');\n failRules.push('edit-param-type');\n failRules.push('delete-object-property');\n failRules.push('delete-param');\n // Openapi specific rules below\n failRules.push('add-required-param-component-openapi');\n failRules.push('add-required-header-component-openapi');\n failRules.push('edit-param-required-component-openapi');\n failRules.push('edit-param-type-openapi');\n failRules.push('edit-param-type-component-openapi');\n failRules.push('edit-response-openapi');\n } else { // Swagger 2.0 rules\n failRules.push('edit-object-property-restriction');\n failRules.push('add-object-property-restriction');\n failRules.push('add-required-object-property');\n failRules.push('add-required-param');\n failRules.push('add-required-header');\n failRules.push('edit-array-items-type');\n failRules.push('edit-base-path');\n failRules.push('edit-object-property-required');\n failRules.push('edit-object-property-type');\n failRules.push('edit-operation-id');\n failRules.push('edit-param-collection-format');\n failRules.push('edit-param-in');\n failRules.push('edit-param-required');\n failRules.push('edit-param-type');\n failRules.push('delete-object-property');\n failRules.push('delete-param');\n }\n\n return failRules;\n}", "title": "" }, { "docid": "1e343de8462f12cb561c3b880d782345", "score": "0.46293998", "text": "validationRuleKeys() {\n let res = [];\n for(let key in this.validationRules) {\n if(this.validationRules.hasOwnProperty(key)) {\n res.push(key);\n }\n }\n return res;\n }", "title": "" }, { "docid": "7244d0f353bec16d95d224ac20d34541", "score": "0.46152997", "text": "function getSheetRules (stylesheet) {\n var sheet_media = stylesheet.media && stylesheet.media.mediaText\n // if this sheet is disabled skip it\n if (stylesheet.disabled) return []\n // if this sheet's media is specified and doesn't match the viewport then skip it\n if (sheet_media && sheet_media.length && !window.matchMedia(sheet_media).matches) return []\n // get the style rules of this sheet\n //debug(294, stylesheet)\n const raw_rules = stylesheet.cssRules\n if (typeof raw_rules === 'undefined' || raw_rules === null) return []\n return Array.from(stylesheet.cssRules)\n }", "title": "" }, { "docid": "f91ebfaa6876995ca18a164082478b26", "score": "0.4614586", "text": "getValidationDefinition() {\n var self = this, \n dataentry = self.dataentry,\n schema = dataentry.schema;\n if (!schema) return {};\n var o = {}, x;\n for (x in schema) {\n var validationEvent = schema[x].validationEvent || self.validationEvent;\n // support multiple events:\n var names = validationEvent.split(/,|;/g);\n var functionName = \"validation_\" + x;\n _.each(names, name => {\n name = name.trim();\n var ev = `${name} [name='${x}']`;\n o[ev] = functionName;\n })\n // store handler\n self.fn[functionName] = self.getValidationEventHandler(x);\n }\n return o;\n }", "title": "" }, { "docid": "f342d25454b1d652a9ace3d51ebe5965", "score": "0.46118796", "text": "coreValidate(objectOrSchemaName, objectOrValidationOptions, maybeValidatorOptions) {\n const object = typeof objectOrSchemaName === 'string' ? objectOrValidationOptions : objectOrSchemaName;\n const options = typeof objectOrSchemaName === 'string' ? maybeValidatorOptions : objectOrValidationOptions;\n const schema = typeof objectOrSchemaName === 'string' ? objectOrSchemaName : undefined;\n const executor = new ValidationExecutor(this, options);\n const validationErrors = [];\n executor.execute(object, schema, validationErrors);\n return Promise.all(executor.awaitingPromises).then(() => {\n return executor.stripEmptyErrors(validationErrors);\n });\n }", "title": "" }, { "docid": "e6804ae03fd5e64160da7e1d26b9a41d", "score": "0.45964524", "text": "getRules(grammarNode){\n let rules = []\n if (grammarNode['friendly node type name'] == 'rule'){\n rules.push(grammarNode)\n return rules\n }else if (grammarNode['friendly node type name'] == 'rule list'){\n if (grammarNode.rules.length > 0){\n for (let i = 0; i < grammarNode.rules.length; i++){\n let childRules = this.getRules(grammarNode.rules[i])\n rules = rules.concat(childRules)\n }\n }\n return rules\n }else{\n //This is an error\n throw \"Error getting rules.\"\n }\n }", "title": "" }, { "docid": "a8b6472430f41525e0c41360a297df63", "score": "0.455893", "text": "async validate(obj, validationModels){\n let errors = [];\n for(let i=0; i<validationModels.length; i++){\n let error = await this.evaluate(obj, validationModels[i]);\n if(error)errors.push(error);\n }\n if(errors.length>0) {\n return errors;\n } else { \n return false;\n }\n }", "title": "" }, { "docid": "fa64159dedc8328a1ffd29f768c23f78", "score": "0.4545778", "text": "getElementRules(element, ruleList) {\n if (typeof element !== \"undefined\") {\n element = $(element);\n\n var rule = undefined;\n\n // Get the elements id\n var id = element.prop('id').toLowerCase();\n\n // Get the element name\n var name = element.prop('name').toLowerCase();\n\n ruleList = (typeof ruleList === 'undefined' ? this.settings.rules : ruleList);\n\n // Match the element with a rule set\n $.each(ruleList, function (key, item) {\n var fields = item.fields.split(', ');\n\n for (var i = 0; i < fields.length; i++) {\n var field = fields[i].toLowerCase();\n var findBy = (name.length > 0 ? name : id);\n var label = null;\n\n if (findBy.length !== 0) {\n try {\n label = element.parent().find('label[for=' + (name.length > 0 ? name : id) + ']');\n } catch(e) {\n // The label selector was invalid, exclude the label search\n label = null;\n }\n }\n\n if ((id.length > 0 && id.includes(field)) || (name.length > 0 && name.includes(field)) || (label !== null && label.length !== 0 && label.text().includes(field))) {\n rule = item;\n return false;\n }\n }\n });\n }\n return rule;\n }", "title": "" }, { "docid": "90e01d69d9d247b6185cd88ad31f3630", "score": "0.45175368", "text": "validate(object, schema = this.__schema, fieldParent, isRequired) {\n\t\tlet errors = new Map();\n\n\t\t// Used to track which props were validated.\n\t\tconst objectProps = new Set(Object.keys(object));\n\n\t\t// If the object is required (it means that\n\t\t// this is a recursive call, and the object type\n\t\t// has required set to true), then throw if it is empty.\n\t\tif (isRequired === true && objectProps.size === 0) {\n\t\t\tthrow Error(`The object \"${fieldParent}\" is required, but left empty`);\n\t\t}\n\n\t\t// Loop over the keys in the schema (not over the object to validate).\n\t\tfor (const fieldName in schema) {\n\t\t\tconst fieldValue = object[fieldName];\n\t\t\tconst fieldSchema = schema[fieldName];\n\n\t\t\ttry {\n\t\t\t\t// Validate the prop against its field schema.\n\t\t\t\tthis.validateProp(fieldValue, fieldSchema, fieldName, fieldParent);\n\t\t\t} catch (error) {\n\t\t\t\t// Else it is a validation error then add it to the errors list.\n\t\t\t\tif (error instanceof Map) {\n\t\t\t\t\terrors = new Map([...errors, ...error]);\n\n\t\t\t\t\t// Remove the prop from the list of properties left in the object.\n\t\t\t\t\tobjectProps.delete(fieldName);\n\n\t\t\t\t\t// Jump to the next loop\n\t\t\t\t\tcontinue;\n\t\t\t\t}\n\n\t\t\t\t// If this is not a validation error, then throw it.\n\t\t\t\tif (error.propPath === undefined) throw error;\n\n\t\t\t\t// Add the error into the errors set.\n\t\t\t\terrors.set(error.propPath, error.message);\n\t\t\t}\n\n\t\t\t// Remove the prop from the list of properties left in the object.\n\t\t\tobjectProps.delete(fieldName);\n\t\t}\n\n\t\t// If there are still props in the list of properties checked\n\t\t// it means that the object has props that were not specified in the schema.\n\t\tif (objectProps.size > 0) {\n\t\t\tlet invalidProps = Array.from(objectProps);\n\n\t\t\t// If this is a recursive call, then we append the\n\t\t\t// parent field name to the prop to make it easier to debug.\n\t\t\tif (fieldParent !== undefined) {\n\t\t\t\tinvalidProps = invalidProps.map(prop => fieldParent + '.' + prop);\n\t\t\t}\n\n\t\t\tfor (const prop of invalidProps) {\n\t\t\t\terrors.set(prop, 'Unknown property');\n\t\t\t}\n\t\t}\n\n\t\t// If there are errors in the set, throw it.\n\t\tif (errors.size > 0) throw errors;\n\t}", "title": "" }, { "docid": "514e8d95b4120acca03a4a09b41bb31d", "score": "0.4511106", "text": "function getCondFmtRulesForRange(range, sheet){\n var condFmtRules = sheet.getConditionalFormatRules()\n var rulesForRange = []\n for (var i = 0; i < condFmtRules.length; i++) {\n var rulesRanges = condFmtRules[i].getRanges()\n for(var j=0; j<rulesRanges.length; j++){\n //check if the range is wholly within a conditional formatting rule\n if(range.getColumn() >= rulesRanges[j].getColumn() && range.getLastColumn() <= rulesRanges[j].getLastColumn()) {\n if(range.getRow() >= rulesRanges[j].getRow() && range.getLastRow() <= rulesRanges[j].getLastRow()) {\n rulesForRange.push(condFmtRules[i])\n }\n }\n }\n }\n return rulesForRange\n}", "title": "" }, { "docid": "7b71fa25fefa1e0a4ed6b180fb731a4d", "score": "0.45015186", "text": "function validate(schemaNameOrObject, objectOrValidationOptions, maybeValidatorOptions) {\n if (typeof schemaNameOrObject === \"string\") {\n return getFromContainer(Validator).validate(schemaNameOrObject, objectOrValidationOptions, maybeValidatorOptions);\n }\n else {\n return getFromContainer(Validator).validate(schemaNameOrObject, objectOrValidationOptions);\n }\n }", "title": "" }, { "docid": "602f67c14c8f328c3511bdb4688d11f3", "score": "0.446062", "text": "validateRule(rule, value) {\n // For a given rule, get the first letter of the string name of its\n // constructor function. \"R\" -> RegExp, \"F\" -> Function (these shouldn't\n // conflict with any other types one might specify). Note: instead of\n // getting .toString from a new object {} or Object.prototype, I'm assuming\n // that exports will always be an object, and using its .toString method.\n // Bad idea? Let me know by filing an issue\n let type = this.toString.call(rule).charAt(8);\n // If regexp, match. If function, invoke. Otherwise, compare. Note that ==\n // is used because type coercion is needed, as `value` will always be a\n // string, but `rule` might not.\n return type === \"R\" ? rule.test(value) : type === \"F\" ? rule(value) : rule == value;\n }", "title": "" }, { "docid": "77990e443e045ea0bee7dd07ed49a7e2", "score": "0.44597304", "text": "validate(objectOrSchemaName, objectOrValidationOptions, maybeValidatorOptions) {\n return this.coreValidate(objectOrSchemaName, objectOrValidationOptions, maybeValidatorOptions);\n }", "title": "" }, { "docid": "fb907d83e2204e9e3c71403e6638cb46", "score": "0.44467995", "text": "function Rules() {\n }", "title": "" }, { "docid": "591f86fd1e9b397969e9a49463b91941", "score": "0.4441408", "text": "function getStyleRules(selector) {\n for (var i = 0; i < sbgnStyleSheet.length; i++) {\n var currentStyle = sbgnStyleSheet[i];\n if (currentStyle.selector == selector) {\n return currentStyle.properties;\n }\n }\n}", "title": "" }, { "docid": "e8e6c8e418453e0fa97358a139c88460", "score": "0.44128346", "text": "function normalizeRules(rules){\n// if falsy value return an empty object.\nvar acc={};\nObject.defineProperty(acc,'_$$isNormalized',{\nvalue:true,\nwritable:false,\nenumerable:false,\nconfigurable:false});\n\nif(!rules){\nreturn acc;\n}\n// Object is already normalized, skip.\nif(isObject(rules)&&rules._$$isNormalized){\nreturn rules;\n}\nif(isObject(rules)){\nreturn Object.keys(rules).reduce(function(prev,curr){\nvar params=[];\nif(rules[curr]===true){\nparams=[];\n}else\nif(Array.isArray(rules[curr])){\nparams=rules[curr];\n}else\nif(isObject(rules[curr])){\nparams=rules[curr];\n}else\n{\nparams=[rules[curr]];\n}\nif(rules[curr]!==false){\nprev[curr]=buildParams(curr,params);\n}\nreturn prev;\n},acc);\n}\n/* istanbul ignore if */\nif(typeof rules!=='string'){\nwarn('rules must be either a string or an object.');\nreturn acc;\n}\nreturn rules.split('|').reduce(function(prev,rule){\nvar parsedRule=parseRule(rule);\nif(!parsedRule.name){\nreturn prev;\n}\nprev[parsedRule.name]=buildParams(parsedRule.name,parsedRule.params);\nreturn prev;\n},acc);\n}", "title": "" }, { "docid": "7bef493040a70725b64b30434d970460", "score": "0.43954048", "text": "function getCSSRules() {\n\t\n\t\t// Remove commented out stuff\n\t\tcss_data = css_data.replace(/\\/\\*[\\s\\S]*?\\*\\//g,'');\n\t\n\t\tvar bits = css_data.split('}');\n\t\t\n\t\t$.each(bits,function() {\n\t\t\tvar rule = $.trim(this);\n\t\t\t\n\t\t\tif(!rule) return;\n\t\t\t\n\t\t\tvar rule_data = parseRule(rule);\n\t\t\t\n\t\t\tif(!rule_data) return;\n\t\t\t\t\n\t\t\tif(rule_data.selector.indexOf(',') != -1) {\n\t\t\t\t// Multiple selectors\n\t\t\t\tvar selectors = rule_data.selector.split(',');\n\t\t\t\t$.each(selectors, function(i,sel) {\n\t\t\t\t\trules.push({\n\t\t\t\t\t\t'selector':\t\t$.trim(sel),\n\t\t\t\t\t\t'properties':\trule_data.properties\n\t\t\t\t\t});\n\t\t\t\t});\n\t\t\t\t\n\t\t\t} else {\n\t\t\t\t// One selector\n\t\t\t\trules.push(rule_data);\n\t\t\t}\n\n\t\t});\n\t\t\n\t\treturn rules;\n\t}", "title": "" }, { "docid": "ba38db4f7c7e09fc82defa2f939269de", "score": "0.43864805", "text": "applyRulesToTargetField(validatableView, viewMode, field, onlyRulesOfType) {\n logger(`Checking rules for form ${validatableView.getId()}, data field ${field.id} of type ${onlyRulesOfType}`);\n // which rules apply?\n let rules = this.getRulesForFieldChange(validatableView, field.id, false);\n let result = {\n ruleFailed: false\n };\n // get the rules for the field, filtered by the condition response type\n if (onlyRulesOfType) {\n logger(`Only validating rules of type ${onlyRulesOfType}`);\n let ruleSubset = [];\n rules.forEach((rule) => {\n if (rule.response === onlyRulesOfType) {\n ruleSubset.push(rule);\n }\n });\n rules = ruleSubset;\n }\n rules.forEach((rule) => {\n let response = this.executeRule(viewMode, rule);\n if (response.ruleFailed) {\n flogger(`Rule failed for form ${validatableView.getId()} with field ${field.displayName} with message ${response.message}`);\n result.ruleFailed = true;\n result.message = response.message;\n }\n });\n // if we haven't failed yet and we have validators\n this.viewValidators.forEach((validator) => {\n let ruleCheck = validator.applyRulesToTargetField(validatableView, viewMode, field, onlyRulesOfType);\n if (ruleCheck.ruleFailed) {\n flogger(`FormFieldValidator - Rule failed for form ${validatableView.getId()} with field ${field.displayName} with message ${ruleCheck.message}`);\n result.ruleFailed = true;\n result.message = ruleCheck.message;\n }\n });\n return result;\n }", "title": "" }, { "docid": "a0f64065f7e05f1ec59832fcb91c2f48", "score": "0.43618318", "text": "getRuleList() {\r\n return this.styleRules;\r\n }", "title": "" }, { "docid": "f795b2a726f0da313befa488660a9268", "score": "0.4345057", "text": "validate(props = {}, componentName) {\n const result = { isValid: true };\n Object.keys(this.propTypes).forEach(key => {\n let validator = this.propTypes[key];\n let error = validator(props, key, componentName);\n if (error !== null) {\n result.isValid = false;\n result.errors = result.errors || {};\n result.errors[key] = error;\n }\n });\n return result;\n }", "title": "" }, { "docid": "6d339231a14d87dcb2b106d22a9249a6", "score": "0.43450287", "text": "function compileObjectSchema(schemaObj, jsonSchema) {\n if (isOfSchemaType(jsonSchema, 'map'))\n return undefined;\n\n const minProperties = compileMinProperties(schemaObj, jsonSchema);\n const maxProperties = compileMaxProperties(schemaObj, jsonSchema);\n const requiredProperties = compileRequiredProperties(schemaObj, jsonSchema);\n const requiredPattern = compileRequiredPattern(schemaObj, jsonSchema);\n\n const dependencies = compileDependencies(schemaObj, jsonSchema);\n const objectChildren = compileObjectChildren(schemaObj, jsonSchema);\n\n if ((minProperties\n || maxProperties\n || requiredProperties\n || requiredPattern\n || dependencies\n || objectChildren) === undefined)\n return undefined;\n\n const isMinProperties = minProperties || trueThat;\n const isMaxProperties = maxProperties || trueThat;\n\n const hasRequiredProperties = requiredProperties || trueThat;\n const hasRequiredPattern = requiredPattern || trueThat;\n\n const hasDependencies = dependencies || trueThat;\n const validateChildren = objectChildren || trueThat;\n\n return function validateObjectSchema(data, dataRoot) {\n if (isObjectType(data)) {\n const dataKeys = Object.keys(data);\n const dataLen = dataKeys.length;\n if (!isMinProperties(dataLen))\n return false;\n if (!isMaxProperties(dataLen))\n return false;\n if (!hasRequiredProperties(dataKeys))\n return false;\n if (!hasRequiredPattern(dataKeys))\n return false;\n if (!hasDependencies(data, dataRoot, dataKeys))\n return false;\n if (!validateChildren(data, dataRoot, dataKeys))\n return false;\n }\n return true;\n };\n}", "title": "" }, { "docid": "69e3cd2a403d24fd5848d6ae26a8b310", "score": "0.4344428", "text": "function jsonschema(obj) {\n var methods, m, schema, t;\n\n if (obj && obj.api) {\n for (var model in obj.api) {\n methods = obj.api[model].methods;\n if (methods) {\n for (var method in methods) {\n m = methods[method]\n if (m.params) {\n schema = {type: \"object\", properties: {} };\n if (m.required) schema.required = m.required;\n for (var key in m.params) {\n if (typeof m.params[key] == 'string') {\n t = m.params[key];\n if (t == 'date') t = 'string';\n schema.properties[key] = { type: t }; \n } else {\n schema.properties[key] = m.params[key]; \n }\n }\n m.jsonschema = schema;\n }\n }\n }\n }\n }\n \n return obj;\n}", "title": "" }, { "docid": "32c0f68dab1e42a67ce5411d02e991f3", "score": "0.43415344", "text": "async listGroupRules(response) {\n const contentType = ObjectSerializer_1.ObjectSerializer.normalizeMediaType(response.headers['content-type']);\n if ((0, util_1.isCodeInRange)('200', response.httpStatusCode)) {\n const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), 'Array<GroupRule>', '');\n return body;\n }\n if ((0, util_1.isCodeInRange)('403', response.httpStatusCode)) {\n const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), 'Error', '');\n throw new exception_1.ApiException(403, 'Forbidden', body, response.headers);\n }\n if ((0, util_1.isCodeInRange)('429', response.httpStatusCode)) {\n const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), 'Error', '');\n throw new exception_1.ApiException(429, 'Too Many Requests', body, response.headers);\n }\n // Work around for missing responses in specification, e.g. for petstore.yaml\n if (response.httpStatusCode >= 200 && response.httpStatusCode <= 299) {\n const body = ObjectSerializer_1.ObjectSerializer.deserialize(ObjectSerializer_1.ObjectSerializer.parse(await response.body.text(), contentType), 'Array<GroupRule>', '');\n return body;\n }\n throw new exception_1.ApiException(response.httpStatusCode, 'Unknown API Status Code!', await response.getBodyAsAny(), response.headers);\n }", "title": "" }, { "docid": "1e4fcf4cc2e566c90296f97d6dc69db4", "score": "0.43338448", "text": "function validateRule(rule, value) {\n // For a given rule, get the first letter of the string name of its\n // constructor function. \"R\" -> RegExp, \"F\" -> Function (these shouldn't\n // conflict with any other types one might specify). Note: instead of\n // getting .toString from a new object {} or Object.prototype, I'm assuming\n // that exports will always be an object, and using its .toString method.\n // Bad idea? Let me know by filing an issue\n var type = exports.toString.call(rule).charAt(8);\n // If regexp, match. If function, invoke. Otherwise, compare. Note that ==\n // is used because type coercion is needed, as `value` will always be a\n // string, but `rule` might not.\n return type === \"R\" ? rule.test(value) : type === \"F\" ? rule(value) : rule == value;\n }", "title": "" }, { "docid": "4f0b7b5d5040acd25badc17c3dcd20e9", "score": "0.43207908", "text": "function checkType(type, value) {\n\t\t\t\tif (type) {\n\t\t\t\t\tif (typeof type == 'string' && type != 'any' && (type == 'null' ? value !== null : typeof value != type) && !(value instanceof Array && type == 'array') && !(value instanceof Date && type == 'date') && !(type == 'integer' && value % 1 === 0)) {\n\t\t\t\t\t\treturn [{ property: path, message: typeof value + \" value found, but a \" + type + \" is required\" }];\n\t\t\t\t\t}\n\t\t\t\t\tif (type instanceof Array) {\n\t\t\t\t\t\tvar unionErrors = [];\n\t\t\t\t\t\tfor (var j = 0; j < type.length; j++) {\n\t\t\t\t\t\t\t// a union type\n\t\t\t\t\t\t\tif (!(unionErrors = checkType(type[j], value)).length) {\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (unionErrors.length) {\n\t\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (typeof type == 'object') {\n\t\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\t\terrors = [];\n\t\t\t\t\t\tcheckProp(value, type, path);\n\t\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\t\treturn theseErrors;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn [];\n\t\t\t}", "title": "" }, { "docid": "203696ce56c40a2fcfc7591421590ea7", "score": "0.4320174", "text": "function validate(obj){\n\t\n\tif(obj===undefined){\n\t\treturn false;\n\t}\n \n\tif(is_undefined(obj.days)){\n\t\t//console.log('TT obj is not valid missing: tt.days');\n\t\treturn false;\n\t}\n\n\tif(is_undefined(obj.session_type)){\n\t\t//console.log('TT obj is not valid missing: tt.session_type');\n\t\treturn false;\n\t}\n \n\tif(is_undefined(obj.meta)){\n\t\t//console.log('TT obj is not valid missing: tt.meta');\n\t\treturn false;\n\t}\n\n\t/* Check all sub classes have the required fields???? */\n\n\t/* ------- Check all days ------- */\n\tlet n_days = obj.days.length;\n\tlet greatest_s_type = obj.session_type.length-1;\n\n\tfor(let i = 0; i < n_days; i++){\n\t\tlet n_t_slots = obj.days[i].length;\n\t\tfor(let j = 0; j<n_t_slots; j++){\n\t\t\tif(!is_logically_valid_time_slot(obj.days[i][j])){\n\t\t\t\t//console.log('TT obj is not valid day['+i+']['+j+'] time slot isn\\'t logically valid');\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t\tif(obj.days[i][j].session > greatest_s_type || obj.days[i][j].session < 0){\n\t\t\t\t//console.log('TT obj is not valid day['+i+']['+j+'] times slot doesn\\'t point to an existing session');\n\t\t\t\treturn false;\n\t\t\t}\n\n\t\t}\n\t}\n\n\treturn true;\n}", "title": "" }, { "docid": "6f0c6c5444d77557dc1fcd7613fe5ab0", "score": "0.43141875", "text": "function Validator(rules) {\n var key;\n\n this.rules = [];\n\n if (rules && ensure.isObject(rules)) {\n // Add rules defined in instantiation\n for (key in rules) {\n if (rules.hasOwnProperty(key)) {\n // If we got an array, we have multiple rules for this field\n if (ensure.isArray(rules[key])) {\n rules[key].forEach(function (rule) {\n this.addRule(key, rule);\n }, this);\n } else {\n this.addRule(key, rules[key]);\n }\n }\n }\n }\n }", "title": "" }, { "docid": "9fdd043002aa82a6fd11f592d7312158", "score": "0.43003124", "text": "function getMatchesRules ($el) {\n var styleSheets = slice.call(document.styleSheets),\n matches = [];\n\n if (styleSheets) {\n styleSheets.forEach(function (item, index) {\n if (item.cssRules) {\n var rules = slice.call(item.cssRules);\n rules.forEach(function (rule, rindex) {\n if ($el.matches(rule.selectorText)) {\n matches.push({\n styleSheet: index,\n rule: rindex,\n cssText: rule.cssText,\n selectorText: rule.selectorText,\n href: item.href || item.ownerNode.getAttribute('href')\n });\n } \n });\n }\n });\n }\n return matches;\n }", "title": "" }, { "docid": "4b50be25bb78b02c67bdd14968c517d6", "score": "0.43000174", "text": "function loadRules() {\n try {\n rules = JSON.parse(getPref(\"rules\"));\n } catch(e) {\n // Well, just do nothing.\n Cu.reportError(\"Error reading rules.\");\n }\n\n // Loop over each ruleset\n for each (let rule in rules) {\n try {\n rule.pattern = stringToRegExp(rule.pattern);\n // By default match every account or conversation name.\n rule.accountName =\n rule.accountName ? stringToRegExp(rule.accountName) : /.*/;\n rule.conversationName =\n rule.conversationName ? stringToRegExp(rule.conversationName) : /.*/;\n } catch(e) {\n Cu.reportError(\"Error parsing rules: \" + e);\n rules = [];\n return;\n }\n\n // Count the number of capturing groups: ( )\n // We don't want non-capturing or look-aheads: (?: ), (?= ), (?! )\n rule.capturingGroups = 0;\n for (var i = 0; i < (rule.pattern.source.length - 1); i++) {\n if (rule.pattern.source.charAt(i) == \"(\" &&\n rule.pattern.source.charAt(i + 1) != \"?\")\n rule.capturingGroups++;\n else if (rule.pattern.source.charAt(i) == \"\\\\\") {\n // If we're escaping the next character, skip it.\n i++;\n }\n }\n\n if (!rule.protocols)\n rule.protocols = [];\n }\n}", "title": "" }, { "docid": "3d38a74aa17e074ba4a1da925cb8312b", "score": "0.4299248", "text": "function ruleList(results) {\n\tvar allArray = Object.getOwnPropertyNames(results);\n\tconsole.log(allArray);\n\tfor (i=0; i<allArray.length; i++){\n\t\tconsole.log(results[allArray[i]]);\n\t\tif (typeof results[allArray[i]] === \"object\"){\n\t\t\tconsole.log(\"ok\");\n\t\t}\n\t}\n//\tvar test = results[allArray[0]];\n//\tconsole.log(test);\n//\tvar test1 = results[allArray[1]];\n//\tconsole.log(test1);\n}", "title": "" }, { "docid": "3aa5c28ab519b325cf8cd5a3d54b41fc", "score": "0.4282984", "text": "function getRule( date, zone, isUTC ) {\n var ruleset = zone[1];\n var basicOffset = getBasicOffset( zone );\n\n // Convert a date to UTC. Depending on the 'type' parameter, the date\n // parameter may be:\n // 'u', 'g', 'z': already UTC (no adjustment)\n // 's': standard time (adjust for time zone offset but not for DST)\n // 'w': wall clock time (adjust for both time zone and DST offset)\n //\n // DST adjustment is done using the rule given as third argument\n var convertDateToUTC = function( date, type, rule ) {\n var offset = 0;\n\n if(type === 'u' || type === 'g' || type === 'z') { // UTC\n offset = 0;\n } else if(type === 's') { // Standard Time\n offset = basicOffset;\n } else if(type === 'w' || !type ) { // Wall Clock Time\n offset = getAdjustedOffset(basicOffset,rule);\n } else {\n throw(\"unknown type \"+type);\n }\n offset *= 60*1000; // to millis\n\n return new Date( date.getTime() + offset );\n }\n\n // Step 1: Find applicable rules for this year.\n // Step 2: Sort the rules by effective date.\n // Step 3: Check requested date to see if a rule has yet taken effect this year. If not,\n // Step 4: Get the rules for the previous year. If there isn't an applicable rule for last year, then\n // there probably is no current time offset since they seem to explicitly turn off the offset\n // when someone stops observing DST.\n // FIXME if this is not the case and we'll walk all the way back (ugh).\n // Step 5: Sort the rules by effective date.\n // Step 6: Apply the most recent rule before the current time.\n\n var convertRuleToExactDateAndTime = function( yearAndRule, prevRule )\n {\n var year = yearAndRule[0];\n var rule = yearAndRule[1];\n\n // Assume that the rule applies to the year of the given date.\n var months = {\n \"Jan\": 0, \"Feb\": 1, \"Mar\": 2, \"Apr\": 3, \"May\": 4, \"Jun\": 5,\n \"Jul\": 6, \"Aug\": 7, \"Sep\": 8, \"Oct\": 9, \"Nov\": 10, \"Dec\": 11\n };\n\n var days = {\n \"sun\": 0, \"mon\": 1, \"tue\": 2, \"wed\": 3, \"thu\": 4, \"fri\": 5, \"sat\": 6\n }\n\n var hms = parseTimeString( rule[ 5 ] );\n var effectiveDate;\n\n if ( !isNaN( rule[ 4 ] ) ) // If we have a specific date, use that!\n {\n effectiveDate = new Date( Date.UTC( year, months[ rule[ 3 ] ], rule[ 4 ], hms[ 1 ], hms[ 2 ], hms[ 3 ], 0 ) );\n }\n else // Let's hunt for the date.\n {\n var targetDay,\n operator;\n\n if ( rule[ 4 ].substr( 0, 4 ) === \"last\" ) // Example: lastThu\n {\n // Start at the last day of the month and work backward.\n effectiveDate = new Date( Date.UTC( year, months[ rule[ 3 ] ] + 1, 1, hms[ 1 ] - 24, hms[ 2 ], hms[ 3 ], 0 ) );\n targetDay = days[ rule[ 4 ].substr( 4, 3 ).toLowerCase( ) ];\n operator = \"<=\";\n }\n else // Example: Sun>=15\n {\n // Start at the specified date.\n effectiveDate = new Date( Date.UTC( year, months[ rule[ 3 ] ], rule[ 4 ].substr( 5 ), hms[ 1 ], hms[ 2 ], hms[ 3 ], 0 ) );\n targetDay = days[ rule[ 4 ].substr( 0, 3 ).toLowerCase( ) ];\n operator = rule[ 4 ].substr( 3, 2 );\n }\n\n var ourDay = effectiveDate.getUTCDay( );\n\n if ( operator === \">=\" ) // Go forwards.\n {\n effectiveDate.setUTCDate( effectiveDate.getUTCDate( ) + ( targetDay - ourDay + ( ( targetDay < ourDay ) ? 7 : 0 ) ) );\n }\n else // Go backwards. Looking for the last of a certain day, or operator is \"<=\" (less likely).\n {\n effectiveDate.setUTCDate( effectiveDate.getUTCDate( ) + ( targetDay - ourDay - ( ( targetDay > ourDay ) ? 7 : 0 ) ) );\n }\n }\n\n // if previous rule is given, correct for the fact that the starting time of the current\n // rule may be specified in local time\n if(prevRule) {\n effectiveDate = convertDateToUTC(effectiveDate, hms[4], prevRule);\n }\n\n return effectiveDate;\n }\n\n var findApplicableRules = function( year, ruleset )\n {\n var applicableRules = [];\n\n for (var i = 0; ruleset && i < ruleset.length; i++)\n {\n if ( Number( ruleset[ i ][ 0 ] ) <= year ) // Exclude future rules.\n {\n if (\n Number( ruleset[ i ][ 1 ] ) >= year // Date is in a set range.\n || ( Number( ruleset[ i ][ 0 ] ) === year && ruleset[ i ][ 1 ] === \"only\" ) // Date is in an \"only\" year.\n || ruleset[ i ][ 1 ] === \"max\" // We're in a range from the start year to infinity.\n )\n {\n // It's completely okay to have any number of matches here.\n // Normally we should only see two, but that doesn't preclude other numbers of matches.\n // These matches are applicable to this year.\n applicableRules.push( [year, ruleset[ i ]] );\n }\n }\n }\n\n return applicableRules;\n }\n\n var compareDates = function( a, b, prev )\n {\n if ( a.constructor !== Date ) {\n a = convertRuleToExactDateAndTime( a, prev );\n } else if(prev) {\n a = convertDateToUTC(a, isUTC?'u':'w', prev);\n }\n if ( b.constructor !== Date ) {\n b = convertRuleToExactDateAndTime( b, prev );\n } else if(prev) {\n b = convertDateToUTC(b, isUTC?'u':'w', prev);\n }\n\n a = Number( a );\n b = Number( b );\n\n return a - b;\n }\n\n var year = date.getUTCFullYear( );\n var applicableRules;\n\n applicableRules = findApplicableRules( year, _this.rules[ ruleset ] );\n applicableRules.push( date );\n // While sorting, the time zone in which the rule starting time is specified\n // is ignored. This is ok as long as the timespan between two DST changes is\n // larger than the DST offset, which is probably always true.\n // As the given date may indeed be close to a DST change, it may get sorted\n // to a wrong position (off by one), which is corrected below.\n applicableRules.sort( compareDates );\n\n if ( applicableRules.indexOf( date ) < 2 ) { // If there are not enough past DST rules...\n applicableRules = applicableRules.concat(findApplicableRules( year-1, _this.rules[ ruleset ] ));\n applicableRules.sort( compareDates );\n }\n\n var pinpoint = applicableRules.indexOf( date );\n if ( pinpoint > 1 && compareDates( date, applicableRules[pinpoint-1], applicableRules[pinpoint-2][1] ) < 0 ) {\n // the previous rule does not really apply, take the one before that\n return applicableRules[ pinpoint - 2 ][1];\n } else if ( pinpoint > 0 && pinpoint < applicableRules.length - 1 && compareDates( date, applicableRules[pinpoint+1], applicableRules[pinpoint-1][1] ) > 0) {\n // the next rule does already apply, take that one\n return applicableRules[ pinpoint + 1 ][1];\n } else if ( pinpoint === 0 ) {\n // no applicable rule found in this and in previous year\n return null;\n } else {\n return applicableRules[ pinpoint - 1 ][1];\n }\n }", "title": "" }, { "docid": "5c526df6e1c3bd9f3c2c5fbb3d24a42d", "score": "0.42668104", "text": "function checkType(type, value) {\n if (type) {\n if (typeof type == 'string' && type != 'any' && (type == 'null' ? value !== null : typeof value != type) && !(value instanceof Array && type == 'array') && !(value instanceof Date && type == 'date') && !(type == 'integer' && value % 1 === 0)) {\n return [{\n property: path,\n message: typeof value + \" value found, but a \" + type + \" is required\"\n }];\n }\n\n if (type instanceof Array) {\n var unionErrors = [];\n\n for (var j = 0; j < type.length; j++) {\n // a union type\n if (!(unionErrors = checkType(type[j], value)).length) {\n break;\n }\n }\n\n if (unionErrors.length) {\n return unionErrors;\n }\n } else if (typeof type == 'object') {\n var priorErrors = errors;\n errors = [];\n checkProp(value, type, path);\n var theseErrors = errors;\n errors = priorErrors;\n return theseErrors;\n }\n }\n\n return [];\n }", "title": "" }, { "docid": "45f84e9ccdc4cb2f46e5613860bb9c89", "score": "0.42650434", "text": "function getRule(dt, zone, isUTC, cacheKey) {\n\t var date = typeof dt === 'number' ? new Date(dt) : dt;\n\t var ruleset = zone[1];\n\t var basicOffset = zone[0];\n\n\t // If the zone has a DST rule like '1:00', create a rule and return it\n\t // instead of looking it up in the parsed rules\n\t var staticDstMatch = ruleset.match(/^([0-9]):([0-9][0-9])$/);\n\t if (staticDstMatch) {\n\t\treturn [-1000000, 'max', '-', 'Jan', 1, [0, 0, 0], parseInt(staticDstMatch[1],10) * 60 + parseInt(staticDstMatch[2], 10), '-'];\n\t }\n\n\t //Convert a date to UTC. Depending on the 'type' parameter, the date\n\t // parameter may be:\n\t //\n\t // - `u`, `g`, `z`: already UTC (no adjustment).\n\t //\n\t // - `s`: standard time (adjust for time zone offset but not for DST)\n\t //\n\t // - `w`: wall clock time (adjust for both time zone and DST offset).\n\t //\n\t // DST adjustment is done using the rule given as third argument.\n\t var convertDateToUTC = function (date, type, rule) {\n\t\tvar offset = 0;\n\n\t\tif (type === 'u' || type === 'g' || type === 'z') { // UTC\n\t\t offset = 0;\n\t\t} else if (type === 's') { // Standard Time\n\t\t offset = basicOffset;\n\t\t} else if (type === 'w' || !type) { // Wall Clock Time\n\t\t offset = getAdjustedOffset(basicOffset, rule[6]);\n\t\t} else {\n\t\t throw new Error('unknown type ' + type);\n\t\t}\n\t\toffset *= 60 * 1000; // to millis\n\n\t\treturn new Date(date.getTime() + offset);\n\t };\n\n\t //Step 1: Find applicable rules for this year.\n\t //\n\t //Step 2: Sort the rules by effective date.\n\t //\n\t //Step 3: Check requested date to see if a rule has yet taken effect this year. If not,\n\t //\n\t //Step 4: Get the rules for the previous year. If there isn't an applicable rule for last year, then\n\t // there probably is no current time offset since they seem to explicitly turn off the offset\n\t // when someone stops observing DST.\n\t //\n\t // FIXME if this is not the case and we'll walk all the way back (ugh).\n\t //\n\t //Step 5: Sort the rules by effective date.\n\t //Step 6: Apply the most recent rule before the current time.\n\t var convertRuleToExactDateAndTime = function (yearAndRule, prevRule) {\n\t\tvar year = yearAndRule[0]\n\t\t , rule = yearAndRule[1];\n\t\t // Assume that the rule applies to the year of the given date.\n\n\t\tvar hms = rule[5];\n\t\tvar effectiveDate;\n\n\t\tif (!EXACT_DATE_TIME[year])\n\t\t EXACT_DATE_TIME[year] = {};\n\n\t\t// Result for given parameters is already stored\n\t\tif (EXACT_DATE_TIME[year][rule])\n\t\t effectiveDate = EXACT_DATE_TIME[year][rule];\n\t\telse {\n\t\t //If we have a specific date, use that!\n\t\t if (!isNaN(rule[4])) {\n\t\t effectiveDate = new Date(Date.UTC(year, SHORT_MONTHS[rule[3]], rule[4], hms[0], hms[1], hms[2], 0));\n\t\t }\n\t\t //Let's hunt for the date.\n\t\t else {\n\t\t var targetDay\n\t\t , operator;\n\t\t //Example: `lastThu`\n\t\t if (rule[4].substr(0, 4) === 'last') {\n\t\t // Start at the last day of the month and work backward.\n\t\t effectiveDate = new Date(Date.UTC(year, SHORT_MONTHS[rule[3]] + 1, 1, hms[0] - 24, hms[1], hms[2], 0));\n\t\t targetDay = SHORT_DAYS[rule[4].substr(4, 3)];\n\t\t operator = '<=';\n\t\t }\n\t\t //Example: `Sun>=15`\n\t\t else {\n\t\t //Start at the specified date.\n\t\t effectiveDate = new Date(Date.UTC(year, SHORT_MONTHS[rule[3]], rule[4].substr(5), hms[0], hms[1], hms[2], 0));\n\t\t targetDay = SHORT_DAYS[rule[4].substr(0, 3)];\n\t\t operator = rule[4].substr(3, 2);\n\t\t }\n\t\t var ourDay = effectiveDate.getUTCDay();\n\t\t //Go forwards.\n\t\t if (operator === '>=') {\n\t\t effectiveDate.setUTCDate(effectiveDate.getUTCDate() + (targetDay - ourDay + ((targetDay < ourDay) ? 7 : 0)));\n\t\t }\n\t\t //Go backwards. Looking for the last of a certain day, or operator is '<=' (less likely).\n\t\t else {\n\t\t effectiveDate.setUTCDate(effectiveDate.getUTCDate() + (targetDay - ourDay - ((targetDay > ourDay) ? 7 : 0)));\n\t\t }\n\t\t }\n\t\t EXACT_DATE_TIME[year][rule] = effectiveDate;\n\t\t}\n\n\n\t\t//If previous rule is given, correct for the fact that the starting time of the current\n\t\t// rule may be specified in local time.\n\t\tif (prevRule) {\n\t\t effectiveDate = convertDateToUTC(effectiveDate, hms[3], prevRule);\n\t\t}\n\t\treturn effectiveDate;\n\t };\n\n\t var findApplicableRules = function (year, ruleset) {\n\t\tvar applicableRules = [];\n\t\tfor (var i = 0; ruleset && i < ruleset.length; i++) {\n\t\t //Exclude future rules.\n\t\t if (ruleset[i][0] <= year &&\n\t\t (\n\t\t // Date is in a set range.\n\t\t ruleset[i][1] >= year ||\n\t\t // Date is in an 'only' year.\n\t\t (ruleset[i][0] === year && ruleset[i][1] === 'only') ||\n\t\t //We're in a range from the start year to infinity.\n\t\t ruleset[i][1] === 'max'\n\t\t )\n\t\t ) {\n\t\t //It's completely okay to have any number of matches here.\n\t\t // Normally we should only see two, but that doesn't preclude other numbers of matches.\n\t\t // These matches are applicable to this year.\n\t\t applicableRules.push([year, ruleset[i]]);\n\t\t }\n\t\t}\n\t\treturn applicableRules;\n\t };\n\n\t var compareDates = function (a, b, prev) {\n\t\tvar year, rule;\n\t\tif (!(a instanceof Date)) {\n\t\t year = a[0];\n\t\t rule = a[1];\n\t\t a = (!prev && EXACT_DATE_TIME[year] && EXACT_DATE_TIME[year][rule])\n\t\t ? EXACT_DATE_TIME[year][rule]\n\t\t : convertRuleToExactDateAndTime(a, prev);\n\t\t} else if (prev) {\n\t\t a = convertDateToUTC(a, isUTC ? 'u' : 'w', prev);\n\t\t}\n\t\tif (!(b instanceof Date)) {\n\t\t year = b[0];\n\t\t rule = b[1];\n\t\t b = (!prev && EXACT_DATE_TIME[year] && EXACT_DATE_TIME[year][rule]) ? EXACT_DATE_TIME[year][rule]\n\t\t : convertRuleToExactDateAndTime(b, prev);\n\t\t} else if (prev) {\n\t\t b = convertDateToUTC(b, isUTC ? 'u' : 'w', prev);\n\t\t}\n\t\ta = Number(a);\n\t\tb = Number(b);\n\t\treturn a - b;\n\t };\n\n\t var year = date.getUTCFullYear();\n\t var applicableRules;\n\n\n\t var cache=timezoneJS.ruleCache[cacheKey];\n\t if(!cache) cache=timezoneJS.ruleCache[cacheKey]={};\n\t applicableRules=cache[year];\n\t if(!applicableRules){\n\t\t applicableRules = findApplicableRules(year-1, _this.rules[ruleset]);\n\t\t applicableRules = applicableRules.concat(findApplicableRules(year, _this.rules[ruleset]));\n\t\t applicableRules.sort(compareDates); // Probably already sorted?\n\t\t cache[year]=applicableRules;\n\t }\n\n\t if(!applicableRules || !applicableRules.length) return null;\t // No applicable rules\n\n\t var prev;\n\t for(var i=applicableRules.length-1;i>=0;i--){\n\t\t if(i>0) prev=applicableRules[i-1][1];\n\t\t else prev=null;\n\t\t var rule=applicableRules[i];\n\t\t if(!rule[2]){\n\t\t\trule[2]=convertRuleToExactDateAndTime(rule, prev);\t // cache the exactDateAndTime, this saves a lot of cycles!\n\t\t }\n\t\t if(compareDates(date, rule, prev)>=0) return rule[1];\n\t }\n\t return null;\n\n\t /*\n\t applicableRules = findApplicableRules(year, _this.rules[ruleset]);\n\t applicableRules.push(date);\n\t //While sorting, the time zone in which the rule starting time is specified\n\t // is ignored. This is ok as long as the timespan between two DST changes is\n\t // larger than the DST offset, which is probably always true.\n\t // As the given date may indeed be close to a DST change, it may get sorted\n\t // to a wrong position (off by one), which is corrected below.\n\t applicableRules.sort(compareDates);\n\n\t //If there are not enough past DST rules...\n\t if (_arrIndexOf.call(applicableRules, date) < 2) {\n\t\tapplicableRules = applicableRules.concat(findApplicableRules(year-1, _this.rules[ruleset]));\n\t\tapplicableRules.sort(compareDates);\n\t }\n\t var pinpoint = _arrIndexOf.call(applicableRules, date);\n\t if (pinpoint > 1 && compareDates(date, applicableRules[pinpoint-1], applicableRules[pinpoint-2][1]) < 0) {\n\t\t//The previous rule does not really apply, take the one before that.\n\t\treturn applicableRules[pinpoint - 2][1];\n\t } else if (pinpoint > 0 && pinpoint < applicableRules.length - 1 && compareDates(date, applicableRules[pinpoint+1], applicableRules[pinpoint-1][1]) > 0) {\n\n\t\t//The next rule does already apply, take that one.\n\t\treturn applicableRules[pinpoint + 1][1];\n\t } else if (pinpoint === 0) {\n\t\t//No applicable rule found in this and in previous year.\n\t\treturn null;\n\t }\n\t return applicableRules[pinpoint - 1][1];\n\t */\n\t }", "title": "" }, { "docid": "4a5a1a6e99b24dfbc781f851b5b4154a", "score": "0.42625895", "text": "function validate$1(schemaNameOrObject, objectOrValidationOptions, maybeValidatorOptions) {\n if (typeof schemaNameOrObject === \"string\") {\n return getFromContainer(Validator).validate(schemaNameOrObject, objectOrValidationOptions, maybeValidatorOptions);\n }\n else {\n return getFromContainer(Validator).validate(schemaNameOrObject, objectOrValidationOptions);\n }\n}", "title": "" }, { "docid": "5749606d08aa600fa4634441aeebc991", "score": "0.42616302", "text": "obeyedRules() {\n return onlyKeys(this.validationRules, this.obeyedRuleKeys);\n }", "title": "" }, { "docid": "dffa62dbe8885fd23b8511d3283ddc0f", "score": "0.42599306", "text": "function getValidationSchema() {\n const patterns = Func.getValidationPatterns();\n\n if (patterns.clientId === null\n || patterns.codeChallenge === null\n || patterns.state === null\n || patterns.language === null\n || patterns.locale === null) {\n\n throw new ValidationError('Pattern for validation schema is not defined.');\n }\n\n return {\n type: 'object',\n properties: {\n client_id: {type: 'string', pattern: patterns.clientId},\n code_challenge: {type: 'string', pattern: patterns.codeChallenge},\n code_challenge_method: {type: 'string', enum: ['S256']},\n email: {type: 'string', format: 'email'},\n redirect_uri: {type: 'string', format: 'uri'},\n response_type: {type: 'string', enum: ['code']},\n state: {type: 'string', pattern: patterns.state},\n language: {type: 'string', pattern: patterns.language},\n locale: {type: 'string', pattern: patterns.locale}\n },\n required: ['client_id', 'code_challenge', 'code_challenge_method', 'email', 'redirect_uri', 'response_type', 'state']\n };\n}", "title": "" }, { "docid": "92c0d837798460423d6e0fb8e1611eb9", "score": "0.4251268", "text": "function getValidationSchema() {\n const patterns = Func.getValidationPatterns();\n\n if (patterns.clientId === null\n || patterns.codeVerifier === null\n || patterns.code === null) {\n \n throw new ValidationError('Pattern for validation schema is not defined.');\n }\n\n return {\n type: 'object',\n properties: {\n client_id: {type: 'string', pattern: patterns.clientId},\n code_verifier: {type: 'string', pattern: patterns.codeVerifier},\n code: {type: 'string', pattern: patterns.code},\n redirect_uri: {type: 'string', format: 'uri'},\n grant_type: {type: 'string', enum: ['authorization_code']}\n },\n required: ['grant_type', 'code', 'redirect_uri', 'client_id', 'code_verifier']\n };\n}", "title": "" }, { "docid": "0caa1b6db64605a1f36a953bee10fedb", "score": "0.42468837", "text": "function io_rule (call) {\n let errors = []\n\n let argument_types = []\n\n for (let i = 0; i < call.argtypes.length; i++) {\n let type = calculate_type(call.argtypes[i])\n if (type.error) errors.push(type.result)\n argument_types.push(type.result)\n }\n\n let constraint = call.type_info.parameter_constraint\n\n for (let i = 0; i < argument_types.length; i++) {\n if (!constraint(argument_types[i])) {\n let reason = '@io-wrong-argument-type'\n let received = stringify(argument_types[i])\n let name = call.name\n let at = i + 1\n\n errors.push({reason, received, at})\n }\n }\n\n let error = errors.length > 0\n\n let result\n if (error) {\n let reason = '@io-errors-found'\n let name = call.name\n result = {reason, name, errors}\n }\n else\n result = call.type_info.return_type\n\n return {error, result}\n}", "title": "" }, { "docid": "4479847e38e5a9320a79ff095314e8d9", "score": "0.424086", "text": "function getRule(date, zone, isUTC) {\n var ruleset = zone[1];\n var basicOffset = getBasicOffset(zone);\n\n // Convert a date to UTC. Depending on the 'type' parameter, the date\n // parameter may be:\n // 'u', 'g', 'z': already UTC (no adjustment)\n // 's': standard time (adjust for time zone offset but not for DST)\n // 'w': wall clock time (adjust for both time zone and DST offset)\n //\n // DST adjustment is done using the rule given as third argument\n var convertDateToUTC = function(date, type, rule) {\n var offset = 0;\n\n if (type == 'u' || type == 'g' || type == 'z') { // UTC\n offset = 0;\n } else if (type == 's') { // Standard Time\n offset = basicOffset;\n } else if (type == 'w' || !type) { // Wall Clock Time\n offset = getAdjustedOffset(basicOffset, rule);\n } else {\n throw(\"unknown type \" + type);\n }\n offset *= 60 * 1000; // to millis\n\n return new Date(date.getTime() + offset);\n }\n\n // Step 1: Find applicable rules for this year.\n // Step 2: Sort the rules by effective date.\n // Step 3: Check requested date to see if a rule has yet taken effect this year. If not,\n // Step 4: Get the rules for the previous year. If there isn't an applicable rule for last year, then\n // there probably is no current time offset since they seem to explicitly turn off the offset\n // when someone stops observing DST.\n // FIXME if this is not the case and we'll walk all the way back (ugh).\n // Step 5: Sort the rules by effective date.\n // Step 6: Apply the most recent rule before the current time.\n\n var convertRuleToExactDateAndTime = function(yearAndRule, prevRule) {\n var year = yearAndRule[0];\n var rule = yearAndRule[1];\n\n // Assume that the rule applies to the year of the given date.\n var months = {\n \"Jan\": 0, \"Feb\": 1, \"Mar\": 2, \"Apr\": 3, \"May\": 4, \"Jun\": 5,\n \"Jul\": 6, \"Aug\": 7, \"Sep\": 8, \"Oct\": 9, \"Nov\": 10, \"Dec\": 11\n };\n\n var days = {\n \"sun\": 0, \"mon\": 1, \"tue\": 2, \"wed\": 3, \"thu\": 4, \"fri\": 5, \"sat\": 6\n }\n\n var hms = parseTimeString(rule[ 5 ]);\n var effectiveDate;\n\n if (!isNaN(rule[ 4 ])) // If we have a specific date, use that!\n {\n effectiveDate = new Date(Date.UTC(year, months[ rule[ 3 ] ], rule[ 4 ], hms[ 1 ], hms[ 2 ], hms[ 3 ], 0));\n }\n else // Let's hunt for the date.\n {\n var targetDay,\n operator;\n\n if (rule[ 4 ].substr(0, 4) === \"last\") // Example: lastThu\n {\n // Start at the last day of the month and work backward.\n effectiveDate = new Date(Date.UTC(year, months[ rule[ 3 ] ] + 1, 1, hms[ 1 ] - 24, hms[ 2 ], hms[ 3 ], 0));\n targetDay = days[ rule[ 4 ].substr(4, 3).toLowerCase() ];\n operator = \"<=\";\n }\n else // Example: Sun>=15\n {\n // Start at the specified date.\n effectiveDate = new Date(Date.UTC(year, months[ rule[ 3 ] ], rule[ 4 ].substr(5), hms[ 1 ], hms[ 2 ], hms[ 3 ], 0));\n targetDay = days[ rule[ 4 ].substr(0, 3).toLowerCase() ];\n operator = rule[ 4 ].substr(3, 2);\n }\n\n var ourDay = effectiveDate.getUTCDay();\n\n if (operator === \">=\") // Go forwards.\n {\n effectiveDate.setUTCDate(effectiveDate.getUTCDate() + ( targetDay - ourDay + ( ( targetDay < ourDay ) ? 7 : 0 ) ));\n }\n else // Go backwards. Looking for the last of a certain day, or operator is \"<=\" (less likely).\n {\n effectiveDate.setUTCDate(effectiveDate.getUTCDate() + ( targetDay - ourDay - ( ( targetDay > ourDay ) ? 7 : 0 ) ));\n }\n }\n\n // if previous rule is given, correct for the fact that the starting time of the current\n // rule may be specified in local time\n if (prevRule) {\n effectiveDate = convertDateToUTC(effectiveDate, hms[4], prevRule);\n }\n\n return effectiveDate;\n }\n\n var findApplicableRules = function(year, ruleset) {\n var applicableRules = [];\n\n for (var i in ruleset) {\n if (Number(ruleset[ i ][ 0 ]) <= year) // Exclude future rules.\n {\n if (\n Number(ruleset[ i ][ 1 ]) >= year // Date is in a set range.\n || ( Number(ruleset[ i ][ 0 ]) === year && ruleset[ i ][ 1 ] === \"only\" ) // Date is in an \"only\" year.\n || ruleset[ i ][ 1 ] === \"max\" // We're in a range from the start year to infinity.\n ) {\n // It's completely okay to have any number of matches here.\n // Normally we should only see two, but that doesn't preclude other numbers of matches.\n // These matches are applicable to this year.\n applicableRules.push([year, ruleset[ i ]]);\n }\n }\n }\n\n return applicableRules;\n }\n\n var compareDates = function(a, b, prev) {\n if (a.constructor !== Date) {\n a = convertRuleToExactDateAndTime(a, prev);\n } else if (prev) {\n a = convertDateToUTC(a, isUTC ? 'u' : 'w', prev);\n }\n if (b.constructor !== Date) {\n b = convertRuleToExactDateAndTime(b, prev);\n } else if (prev) {\n b = convertDateToUTC(b, isUTC ? 'u' : 'w', prev);\n }\n\n a = Number(a);\n b = Number(b);\n\n return a - b;\n }\n\n var year = date.getUTCFullYear();\n var applicableRules;\n\n applicableRules = findApplicableRules(year, _this.rules[ ruleset ]);\n applicableRules.push(date);\n // While sorting, the time zone in which the rule starting time is specified\n // is ignored. This is ok as long as the timespan between two DST changes is\n // larger than the DST offset, which is probably always true.\n // As the given date may indeed be close to a DST change, it may get sorted\n // to a wrong position (off by one), which is corrected below.\n applicableRules.sort(compareDates);\n\n if (applicableRules.indexOf(date) < 2) { // If there are not enough past DST rules...\n applicableRules = applicableRules.concat(findApplicableRules(year - 1, _this.rules[ ruleset ]));\n applicableRules.sort(compareDates);\n }\n\n var pinpoint = applicableRules.indexOf(date);\n if (pinpoint > 1 && compareDates(date, applicableRules[pinpoint - 1], applicableRules[pinpoint - 2][1]) < 0) {\n // the previous rule does not really apply, take the one before that\n return applicableRules[ pinpoint - 2 ][1];\n } else if (pinpoint > 0 && pinpoint < applicableRules.length - 1 && compareDates(date, applicableRules[pinpoint + 1], applicableRules[pinpoint - 1][1]) > 0) {\n // the next rule does already apply, take that one\n return applicableRules[ pinpoint + 1 ][1];\n } else if (pinpoint === 0) {\n // no applicable rule found in this and in previous year\n return null;\n } else {\n return applicableRules[ pinpoint - 1 ][1];\n }\n }", "title": "" }, { "docid": "ddfeff5a482a6430df7aa9ad40ef731a", "score": "0.4237072", "text": "function checkForm() {\n for (var fieldset in options.rulesets) {\n var ruleset = options.rulesets[fieldset];\n\n // if the rule value is a string or a function then assume\n // it applies to the fieldset as a whole\n if (!$.isPlainObject(ruleset)) {\n triggerRule(fieldset, \"*\", ruleset);\n continue;\n }\n\n // if the value was an object, iterate its key/vals and trigger\n // a rule on each of them, bound to the outer fieldset\n for (var selector in ruleset) {\n var rule = ruleset[selector];\n triggerRule(fieldset, selector, rule);\n }\n }\n }", "title": "" }, { "docid": "ec42d9023f1f3f795d3948db1134b0a2", "score": "0.42368534", "text": "GetRule(ruleID){\n var rule = null;\n this.Rules.forEach(element => {\n if(element.id == ruleID){\n rule = element;\n }\n });\n return rule;\n }", "title": "" }, { "docid": "449d854c342dbea27324ea8b95ea63d4", "score": "0.42321873", "text": "getRule(ruleName){\n for (let i = 0; i < this.rules.length; i++){\n if (this.rules[i].name == ruleName){\n return this.rules[i]\n }\n }\n console.log('Unrecognized rule name:' + ruleName)\n return null\n }", "title": "" }, { "docid": "d31c41e22b0c861a60ec210f77d592b5", "score": "0.4229749", "text": "function RbmGetStyleSheetRule(className){\n for(var i = 0; i < document.styleSheets.length; i ++){\n var styleSheet = document.styleSheets[i];\n var rules = RbmGetStyleSheetRules(styleSheet);\n if(rules != null){\n for(var j = 0; j < rules.length; j ++){\n if(rules[j].selectorText == \".\" + className){\n return rules[j];\n }\n }\n }\n }\n return null;\n}", "title": "" }, { "docid": "2644456ab462a4d01afa57ce83a1530c", "score": "0.42207202", "text": "fromObject(input) {\n // If ImageMatchingRules exist, create them from the Object data\n // and add them to the Viewport's imageMatchingRules array\n if (input.imageMatchingRules) {\n input.imageMatchingRules.forEach(ruleObject => {\n var rule = new ImageMatchingRule();\n rule.fromObject(ruleObject);\n this.imageMatchingRules.push(rule);\n });\n }\n\n // If SeriesMatchingRules exist, create them from the Object data\n // and add them to the Viewport's seriesMatchingRules array\n if (input.seriesMatchingRules) {\n input.seriesMatchingRules.forEach(ruleObject => {\n var rule = new SeriesMatchingRule();\n rule.fromObject(ruleObject);\n this.seriesMatchingRules.push(rule);\n });\n }\n\n // If StudyMatchingRules exist, create them from the Object data\n // and add them to the Viewport's studyMatchingRules array\n if (input.studyMatchingRules) {\n input.studyMatchingRules.forEach(ruleObject => {\n var rule = new StudyMatchingRule();\n rule.fromObject(ruleObject);\n this.studyMatchingRules.push(rule);\n });\n }\n\n // If ViewportSettings exist, add them to the current protocol\n if (input.viewportSettings) {\n this.viewportSettings = input.viewportSettings;\n }\n }", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "e9fc1b497d994a4280ed1de2e5dcdc64", "score": "0.42142454", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "308c69ea26db92e29564e456b06ce4e0", "score": "0.42028156", "text": "function validate_rules() {\n let valid = false;\n let rules = testrules.value;\n \n statustext.textContent = 'Validating ... // Code to be added';\n setTimeout(function() {\n statustext.textContent = '';\n }, statusDelay);\n\n //TODO: validate JSON\n\n return valid;\n}", "title": "" }, { "docid": "28286ae0df6a074081ef43fa9b545fe7", "score": "0.42019856", "text": "function validate(obj, documentSchema, options) {\n return documentSchema.validate(obj, options)\n}", "title": "" }, { "docid": "7cd265a3a9d013acf40183d6b812116d", "score": "0.42005935", "text": "function checkType(type, value) {\n\t\t\t\tif (type) {\n\t\t\t\t\tif (typeof type == 'string' && type != 'any' && (type == 'null' ? value !== null : (typeof value === 'undefined' ? 'undefined' : _typeof(value)) != type) && !(value instanceof Array && type == 'array') && !(value instanceof Date && type == 'date') && !(type == 'integer' && value % 1 === 0)) {\n\t\t\t\t\t\treturn [{ property: path, message: (typeof value === 'undefined' ? 'undefined' : _typeof(value)) + \" value found, but a \" + type + \" is required\" }];\n\t\t\t\t\t}\n\t\t\t\t\tif (type instanceof Array) {\n\t\t\t\t\t\tvar unionErrors = [];\n\t\t\t\t\t\tfor (var j = 0; j < type.length; j++) {\n\t\t\t\t\t\t\t// a union type\n\t\t\t\t\t\t\tif (!(unionErrors = checkType(type[j], value)).length) {\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif (unionErrors.length) {\n\t\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if ((typeof type === 'undefined' ? 'undefined' : _typeof(type)) == 'object') {\n\t\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\t\terrors = [];\n\t\t\t\t\t\tcheckProp(value, type, path);\n\t\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\t\treturn theseErrors;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn [];\n\t\t\t}", "title": "" }, { "docid": "3b44f6f164aed437c0ae989beab13cb1", "score": "0.4198745", "text": "function getRuleType(rule){\n\t\t\t\tif(rule && rule.parent && rule.parent.url){\n\t\t\t\t\tvar url=rule.parent.url;\n\t\t\t\t\tif(/^themes\\//.test(url) || /\\/themes\\//.test(url)){\n\t\t\t\t\t\treturn 'theme';\n\t\t\t\t\t}else{\n\t\t\t\t\t\treturn 'queried';\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t\n\t\t\t}", "title": "" }, { "docid": "645bb0f7f4e08e0e5861fc56201fb8b4", "score": "0.41836312", "text": "getRules() {\n return []\n .concat(this.commonRules)\n .concat(this.domainSensitiveRules)\n .concat(this.exceptionRules)\n .concat(this.extendedCssRules);\n }", "title": "" }, { "docid": "2aa28298a09ad4862fb745d25c53de42", "score": "0.41777217", "text": "function validateSection (objSchema, section) {\n if (_.isEmpty(objSchema)) {\n return []\n }\n\n const { swagger } = joiToSwagger(objSchema)\n const requiredNamesSet = new Set(swagger.required)\n\n return _.map(swagger.properties, ({ description, ...schema }, name) => ({\n description,\n in: section,\n name,\n required: requiredNamesSet.has(name),\n schema,\n }))\n}", "title": "" }, { "docid": "94428a5916e0ea6e76f34830ff440469", "score": "0.41756114", "text": "validate(inputs = null) {\n this.inputs = inputs;\n\n /* inputs can not be null */\n try {\n if (this.inputs === null) throw \"no object provided for validation\";\n } catch (err) {\n console.log(err);\n }\n\n /* iterate over all schema key and validate according to given inputs data*/\n for (let schemaKey in this.schema) {\n try {\n if (\n this.schema[schemaKey].type === null ||\n this.schema[schemaKey].type === undefined\n ) {\n throw `type field required for [${schemaKey}] `;\n } else {\n switch (this.schema[schemaKey].type) {\n case \"text\":\n this.validatedObj.fields[schemaKey] = {};\n this.validateText(schemaKey);\n }\n }\n } catch (err) {\n console.log(err);\n return;\n }\n }\n return this.validatedObj;\n }", "title": "" }, { "docid": "167cb512e65a09309308369006df6403", "score": "0.417443", "text": "function Validator(object) {\n this.object = object;\n validations = {};\n}", "title": "" }, { "docid": "502168ea97a77745c8978956fb76f6ba", "score": "0.41654006", "text": "function getValidationOptions() {\n return validationOptions.getValidationOptions();\n }", "title": "" }, { "docid": "2533096c6fbf76cc02b5d1437a47e6f9", "score": "0.41616684", "text": "rulelist(rules, range) {\n return { type: common_1.nodeType.rulelist, rules, range };\n }", "title": "" }, { "docid": "0956212b40f7aa5057a1db6117aa6e9f", "score": "0.41606656", "text": "function checkType(type,value){\n\t\t\tif(type){\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t}\n\t\t\t\tif(type instanceof Array){\n\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t}\n\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\terrors = [];\n\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\treturn theseErrors;\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn [];\n\t\t}", "title": "" }, { "docid": "b2893a8f391d5e6037145f0bc24de872", "score": "0.41593412", "text": "function isRule(thing) {\n return getIriAll(thing, rdf.type).includes(acp.Rule);\n}", "title": "" }, { "docid": "3095367b911410887b212efeba210da1", "score": "0.41589585", "text": "function checkType(type,value){\r\n\t\t\tif(type){\r\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t}\r\n\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\terrors = [];\r\n\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}", "title": "" }, { "docid": "3095367b911410887b212efeba210da1", "score": "0.41589585", "text": "function checkType(type,value){\r\n\t\t\tif(type){\r\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t}\r\n\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\terrors = [];\r\n\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}", "title": "" }, { "docid": "3095367b911410887b212efeba210da1", "score": "0.41589585", "text": "function checkType(type,value){\r\n\t\t\tif(type){\r\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t}\r\n\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\terrors = [];\r\n\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}", "title": "" }, { "docid": "3095367b911410887b212efeba210da1", "score": "0.41589585", "text": "function checkType(type,value){\r\n\t\t\tif(type){\r\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t}\r\n\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\terrors = [];\r\n\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}", "title": "" }, { "docid": "3095367b911410887b212efeba210da1", "score": "0.41589585", "text": "function checkType(type,value){\r\n\t\t\tif(type){\r\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t}\r\n\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\terrors = [];\r\n\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}", "title": "" }, { "docid": "3095367b911410887b212efeba210da1", "score": "0.41589585", "text": "function checkType(type,value){\r\n\t\t\tif(type){\r\n\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t}\r\n\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\terrors = [];\r\n\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t\treturn [];\r\n\t\t}", "title": "" }, { "docid": "e4c2ee78c72a28cfe50cd8d6d99b3549", "score": "0.4156288", "text": "function checkType(type,value){\r\n\t\t\t\tif(type){\r\n\t\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\t\terrors = [];\r\n\t\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn [];\r\n\t\t\t}", "title": "" }, { "docid": "e4c2ee78c72a28cfe50cd8d6d99b3549", "score": "0.4156288", "text": "function checkType(type,value){\r\n\t\t\t\tif(type){\r\n\t\t\t\t\tif(typeof type == 'string' && type != 'any' &&\r\n\t\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\r\n\t\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\r\n\t\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\r\n\t\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\r\n\t\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(type instanceof Array){\r\n\t\t\t\t\t\tvar unionErrors=[];\r\n\t\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\r\n\t\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\r\n\t\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif(unionErrors.length){\r\n\t\t\t\t\t\t\treturn unionErrors;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t}else if(typeof type == 'object'){\r\n\t\t\t\t\t\tvar priorErrors = errors;\r\n\t\t\t\t\t\terrors = [];\r\n\t\t\t\t\t\tcheckProp(value,type,path);\r\n\t\t\t\t\t\tvar theseErrors = errors;\r\n\t\t\t\t\t\terrors = priorErrors;\r\n\t\t\t\t\t\treturn theseErrors;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\t\t\t\treturn [];\r\n\t\t\t}", "title": "" }, { "docid": "fd908478a5ea31cb1b8572cbf5f18975", "score": "0.4153788", "text": "function getRulesFromFile(data, ruleType) {\n var defer = $q.defer();\n rulesService.loadServicePaths().then(function (stacks) {\n try {\n stacks = stacks.servicePaths;\n $log.info('Trying to get rules from the following structure: ', data);\n var rulesCandidates = JSON.parse(data);\n if (angular.isDefined(rulesCandidates.id)) {\n rulesCandidates = {'if': rulesCandidates};\n }\n\n defer.resolve(rulesBuilderService.unmarshallJSONRulesForPreview(\n rulesCandidates,\n undefined,\n ruleType === PATH_RULE ? stacks : null,\n ruleType,\n ruleType === PATH_RULE ? pathRulesBuilderService : urlRulesBuilderService));\n } catch (e) {\n defer.reject();\n rulesAlertsService.genericError('can\\'t parse file');\n $log.error('can\\'t parse file', e);\n }\n },\n function (error) {\n defer.reject();\n $log.error('Error loading stacks');\n });\n return defer.promise;\n }", "title": "" }, { "docid": "07a436f8d38e8100122d4098f608eadc", "score": "0.41317025", "text": "function checkType(type,value){\n\t\t\t\tif(type){\n\t\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t\t}\n\t\t\t\t\tif(type instanceof Array){\n\t\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t\t}\n\t\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\t\terrors = [];\n\t\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\t\treturn theseErrors;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn [];\n\t\t\t}", "title": "" }, { "docid": "07a436f8d38e8100122d4098f608eadc", "score": "0.41317025", "text": "function checkType(type,value){\n\t\t\t\tif(type){\n\t\t\t\t\tif(typeof type == 'string' && type != 'any' &&\n\t\t\t\t\t\t\t(type == 'null' ? value !== null : typeof value != type) &&\n\t\t\t\t\t\t\t!(value instanceof Array && type == 'array') &&\n\t\t\t\t\t\t\t!(value instanceof Date && type == 'date') &&\n\t\t\t\t\t\t\t!(type == 'integer' && value%1===0)){\n\t\t\t\t\t\treturn [{property:path,message:(typeof value) + \" value found, but a \" + type + \" is required\"}];\n\t\t\t\t\t}\n\t\t\t\t\tif(type instanceof Array){\n\t\t\t\t\t\tvar unionErrors=[];\n\t\t\t\t\t\tfor(var j = 0; j < type.length; j++){ // a union type\n\t\t\t\t\t\t\tif(!(unionErrors=checkType(type[j],value)).length){\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t\tif(unionErrors.length){\n\t\t\t\t\t\t\treturn unionErrors;\n\t\t\t\t\t\t}\n\t\t\t\t\t}else if(typeof type == 'object'){\n\t\t\t\t\t\tvar priorErrors = errors;\n\t\t\t\t\t\terrors = [];\n\t\t\t\t\t\tcheckProp(value,type,path);\n\t\t\t\t\t\tvar theseErrors = errors;\n\t\t\t\t\t\terrors = priorErrors;\n\t\t\t\t\t\treturn theseErrors;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\treturn [];\n\t\t\t}", "title": "" }, { "docid": "ec1b21656db31e5f0f896662cfd199f3", "score": "0.4129916", "text": "function getRuleParts(input) {\n var re = new RegExp('^iglu:((?:(?:[a-zA-Z0-9-_]+|\\\\*).)+(?:[a-zA-Z0-9-_]+|\\\\*))/([a-zA-Z0-9-_.]+|\\\\*)/jsonschema/([1-9][0-9]*|\\\\*)-(0|[1-9][0-9]*|\\\\*)-(0|[1-9][0-9]*|\\\\*)$');\n var matches = re.exec(input);\n if (matches !== null && validateVendor(matches[1]))\n return matches.slice(1, 6);\n return undefined;\n}", "title": "" }, { "docid": "4742ee167f19b0d932e9171a85407c0f", "score": "0.41242602", "text": "function checkType(type, value) {\n if (type) {\n if (typeof type == 'string' && type != 'any' && (type == 'null' ? value !== null : (typeof value === 'undefined' ? 'undefined' : _typeof(value)) != type) && !(value instanceof Array && type == 'array') && !(value instanceof Date && type == 'date') && !(type == 'integer' && value % 1 === 0)) {\n return [{\n property: path,\n message: (typeof value === 'undefined' ? 'undefined' : _typeof(value)) + \" value found, but a \" + type + \" is required\"\n }];\n }\n if (type instanceof Array) {\n var unionErrors = [];\n for (var j = 0; j < type.length; j++) {// a union type\n if (!(unionErrors = checkType(type[j], value)).length) {\n break;\n }\n }\n if (unionErrors.length) {\n return unionErrors;\n }\n } else if ((typeof type === 'undefined' ? 'undefined' : _typeof(type)) == 'object') {\n var priorErrors = errors;\n errors = [];\n checkProp(value, type, path);\n var theseErrors = errors;\n errors = priorErrors;\n return theseErrors;\n }\n }\n return [];\n }", "title": "" }, { "docid": "69da037d9d3c6d2e245cc8191ba8a97a", "score": "0.41213778", "text": "function GetAllViewRowsAsRuleObjects()\n {\n var ruleTableRows = [];\n\n $('#CRUDthisTable tbody tr').each(function (index, value)\n {\n var row = GetViewRowObject(index);\n ruleTableRows.push(row);\n });\n\n return ruleTableRows;\n }", "title": "" }, { "docid": "3ee44175055a4f951b232351ac72a982", "score": "0.41164213", "text": "function object_object(rule, value, callback, source, options) {\n var errors = [];\n var validate = rule.required || !rule.required && source.hasOwnProperty(rule.field);\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n es_rule.required(rule, value, source, errors, options);\n if (value !== undefined) {\n es_rule.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}", "title": "" }, { "docid": "3ee44175055a4f951b232351ac72a982", "score": "0.41164213", "text": "function object_object(rule, value, callback, source, options) {\n var errors = [];\n var validate = rule.required || !rule.required && source.hasOwnProperty(rule.field);\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n es_rule.required(rule, value, source, errors, options);\n if (value !== undefined) {\n es_rule.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}", "title": "" }, { "docid": "3ee44175055a4f951b232351ac72a982", "score": "0.41164213", "text": "function object_object(rule, value, callback, source, options) {\n var errors = [];\n var validate = rule.required || !rule.required && source.hasOwnProperty(rule.field);\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n es_rule.required(rule, value, source, errors, options);\n if (value !== undefined) {\n es_rule.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}", "title": "" }, { "docid": "3ee44175055a4f951b232351ac72a982", "score": "0.41164213", "text": "function object_object(rule, value, callback, source, options) {\n var errors = [];\n var validate = rule.required || !rule.required && source.hasOwnProperty(rule.field);\n if (validate) {\n if (isEmptyValue(value) && !rule.required) {\n return callback();\n }\n es_rule.required(rule, value, source, errors, options);\n if (value !== undefined) {\n es_rule.type(rule, value, source, errors, options);\n }\n }\n callback(errors);\n}", "title": "" } ]
48a9eaedbd6ee602a1a68ff4afc81d38
Object for calculation moving band sizes
[ { "docid": "9a4334f490531de3caf266fe36ee9a55", "score": "0.6232638", "text": "function BondSizeValues(screenSize) {\n\n // значения констант\n this.visibleImagesCount = 10;\n this.nonvisibleImagesCount = 2;\n this.imagesHeightPerc = .15;\n this.imageMargin = 0;\n\n this.screenSize = screenSize;\n\n this.totalImagesCount = function()\n {\n return this.visibleImagesCount + this.nonvisibleImagesCount;\n };\n\n this.getImageWidth = function()\n {\n return (this.screenSize.getWidth() / this.visibleImagesCount);\n };\n\n this.getBandWidth = function()\n {\n return (this.getImageWidth() + this.imageMargin)*this.totalImagesCount();\n };\n\n this.getVisibleAreaWidth = function()\n {\n return (this.getImageWidth() + this.imageMargin/2)*this.visibleImagesCount;\n };\n\n this.getBandHeight = function()\n {\n console.log(\"getBandHeight: \" + (this.screenSize.getHeight()*this.imagesHeightPerc));\n return this.screenSize.getHeight()*this.imagesHeightPerc;\n };\n\n}", "title": "" } ]
[ { "docid": "5290603cfbfad2cfec506406cf33d647", "score": "0.6986091", "text": "get size() {\r\n return 6 * this.sides + 6 * this.sides * this.bands;\r\n }", "title": "" }, { "docid": "fa9ef7b9268472a0f97c3699956e0923", "score": "0.59895146", "text": "_updateSize(getter) {\n const that = this;\n\n if (that.sizeMode === 'circle' && getter === undefined) {\n return;\n }\n\n const minCoordinates = that._minCoordinates,\n maxCoordinates = that._maxCoordinates;\n let top = minCoordinates[0],\n bottom = maxCoordinates[0];\n\n for (let i = 1; i < minCoordinates.length; i++) {\n top = Math.min(top, minCoordinates[i]);\n }\n\n for (let i = 1; i < maxCoordinates.length; i++) {\n bottom = Math.max(bottom, maxCoordinates[i]);\n }\n\n const gaugeClientRect = that.getBoundingClientRect();\n\n if (that.digitalDisplay) {\n const digitalDisplayClientRect = that.$.digitalDisplay.getBoundingClientRect();\n\n top = Math.min(top, digitalDisplayClientRect.top - gaugeClientRect.top);\n bottom = Math.max(bottom, digitalDisplayClientRect.bottom - gaugeClientRect.top);\n }\n\n if (that.analogDisplayType !== 'needle') {\n const trackBBox = that._track.getBBox();\n\n top = Math.min(top, trackBBox.y);\n bottom = Math.max(bottom, trackBBox.y + trackBBox.height);\n }\n\n for (let i = 0; i < that._ranges.length; i++) {\n const rangeBBox = that._ranges[i].getBBox();\n\n top = Math.min(top, rangeBBox.y - gaugeClientRect.top);\n bottom = Math.max(bottom, rangeBBox.y + rangeBBox.height - gaugeClientRect.top);\n }\n\n top -= 2;\n\n const newHeight = bottom - top;\n\n if (getter === undefined) {\n that._preventResizeHandler = true;\n\n that.style.height = newHeight + 'px';\n that.$.container.style.marginTop = -1 * top + 'px';\n\n that._measurements.cachedHeight = newHeight;\n }\n else {\n return Math.round(newHeight);\n }\n }", "title": "" }, { "docid": "a401296584c2de3ed447d9664efc0d5f", "score": "0.5957889", "text": "function calculateSizes () {\n // Figure out the parent size minus padding.\n var a = elements[this.a].element;\n var b = elements[this.b].element;\n\n this.size = a[getBoundingClientRect]()[dimension] + b[getBoundingClientRect]()[dimension] + this.aGutterSize + this.bGutterSize;\n this.start = a[getBoundingClientRect]()[position];\n }", "title": "" }, { "docid": "3232b8388d6448fc334639f7bd29c26c", "score": "0.5912747", "text": "function updateRubberbandSizeData(loc) {\n shapeBoundingBox.width = Math.abs(loc.x - mousedown.x);\n shapeBoundingBox.height = Math.abs(loc.y - mousedown.y);\n\n // if the current x is greater than starting x, then the left of the \n // shape bounding box is mousedown\n // otherwise, the left would be the current loc's value\n // this is for both x and y, with left and top respectively\n if (loc.x > mousedown.x) {\n shapeBoundingBox.left = mousedown.x;\n } else {\n shapeBoundingBox.left = loc.x;\n }\n\n if (loc.y > mousedown.y) {\n shapeBoundingBox.top = mousedown.y;\n } else {\n shapeBoundingBox.top = loc.y;\n }\n}", "title": "" }, { "docid": "b4d2c4558633c71712df925975e99c1a", "score": "0.58623725", "text": "function calculateSizes() {\n // Figure out the parent size minus padding.\n var a = elements[this.a].element;\n var b = elements[this.b].element;\n\n var aBounds = a[getBoundingClientRect]();\n var bBounds = b[getBoundingClientRect]();\n\n this.size =\n aBounds[dimension] +\n bBounds[dimension] +\n this[aGutterSize] +\n this[bGutterSize];\n this.start = aBounds[position];\n this.end = aBounds[positionEnd];\n }", "title": "" }, { "docid": "6094996b127065a91f8acf792b634e8b", "score": "0.5832777", "text": "function UpdateRubberbandSizeData (loc) {\n\n shapeBoundingBox.width = Math.abs(loc.x - mousedown.x)\n shapeBoundingBox.height = Math.abs(loc.y - mousedown.y)\n\n if (loc.x > mousedown.x) {\n shapeBoundingBox.left = mousedown.x\n } else {\n shapeBoundingBox.left = loc.x\n }\n\n if (loc.y > mousedown.y) {\n shapeBoundingBox.top = mousedown.y\n } else {\n shapeBoundingBox.top = loc.y\n }\n}", "title": "" }, { "docid": "17b8e129e65ce718319b48f89351fe05", "score": "0.5812502", "text": "setWidth () {\n //I dont want it to fully extend out, only 90%. I also want it to not ever be smaller than the rod itself, so i subtract rod width (and a little extra for improved visual) from 90 and add it as a baseline.\n this.width = ((this.rank / numberOfDisks) * 86) + 4\n }", "title": "" }, { "docid": "be6363632da06b8338d1a77b4810a53d", "score": "0.5811423", "text": "get sizes() {\n return this.relativeSizes();\n }", "title": "" }, { "docid": "1520b8460abbfd80cc1d2cf3cd3861c6", "score": "0.5808759", "text": "function band() {\n var scale = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_1__ordinal__[\"a\" /* default */])().unknown(undefined),\n domain = scale.domain,\n ordinalRange = scale.range,\n range = [0, 1],\n step,\n bandwidth,\n round = false,\n paddingInner = 0,\n paddingOuter = 0,\n align = 0.5;\n\n delete scale.unknown;\n\n function rescale() {\n var n = domain().length,\n reverse = range[1] < range[0],\n start = range[reverse - 0],\n stop = range[1 - reverse];\n step = (stop - start) / Math.max(1, n - paddingInner + paddingOuter * 2);\n if (round) step = Math.floor(step);\n start += (stop - start - step * (n - paddingInner)) * align;\n bandwidth = step * (1 - paddingInner);\n if (round) start = Math.round(start), bandwidth = Math.round(bandwidth);\n var values = __webpack_require__.i(__WEBPACK_IMPORTED_MODULE_0_d3_array__[\"g\" /* range */])(n).map(function(i) { return start + step * i; });\n return ordinalRange(reverse ? values.reverse() : values);\n }\n\n scale.domain = function(_) {\n return arguments.length ? (domain(_), rescale()) : domain();\n };\n\n scale.range = function(_) {\n return arguments.length ? (range = [+_[0], +_[1]], rescale()) : range.slice();\n };\n\n scale.rangeRound = function(_) {\n return range = [+_[0], +_[1]], round = true, rescale();\n };\n\n scale.bandwidth = function() {\n return bandwidth;\n };\n\n scale.step = function() {\n return step;\n };\n\n scale.round = function(_) {\n return arguments.length ? (round = !!_, rescale()) : round;\n };\n\n scale.padding = function(_) {\n return arguments.length ? (paddingInner = paddingOuter = Math.max(0, Math.min(1, _)), rescale()) : paddingInner;\n };\n\n scale.paddingInner = function(_) {\n return arguments.length ? (paddingInner = Math.max(0, Math.min(1, _)), rescale()) : paddingInner;\n };\n\n scale.paddingOuter = function(_) {\n return arguments.length ? (paddingOuter = Math.max(0, Math.min(1, _)), rescale()) : paddingOuter;\n };\n\n scale.align = function(_) {\n return arguments.length ? (align = Math.max(0, Math.min(1, _)), rescale()) : align;\n };\n\n scale.copy = function() {\n return band()\n .domain(domain())\n .range(range)\n .round(round)\n .paddingInner(paddingInner)\n .paddingOuter(paddingOuter)\n .align(align);\n };\n\n return rescale();\n}", "title": "" }, { "docid": "49654502c1ca5167bc11e2c53850f5b2", "score": "0.57994545", "text": "updateSize() {\n let orderObject = 0;\n let hBeforeElements = 42;\n let wBoundary = BOUNDARY_ATTR_SIZE.BOUND_WIDTH;\n let marginTop = 3;\n\n this.member.forEach(mem => {\n if (mem.show) {\n\n if (mem.type == \"B\") {\n let boundaryObj = _.find(this.dataContainer.boundary, {\"id\": mem.id});\n boundaryObj.updateSize();\n }\n\n const { width, height } = this.objectUtils.getBBoxObject(`#${mem.id}`);\n orderObject++;\n hBeforeElements += height;\n if (width >= wBoundary)\n wBoundary = width + 10;\n }\n });\n\n let hBoundary = hBeforeElements + marginTop * orderObject + 2;\n\n this.setHeight(hBoundary);\n this.setWidth(wBoundary);\n }", "title": "" }, { "docid": "e254cd77bb2cbc6a223b2244a4d4de2d", "score": "0.5789293", "text": "getDimensions() {\n return { halfWidth: this.halfWidth, halfHeight: this.halfHeight };\n }", "title": "" }, { "docid": "2a43f730e48b055c49af0df9f7ca4296", "score": "0.57686853", "text": "updateDimensions() {\n // this is the true current width\n // it is used to calculate the ink bar position & pagination offset\n this.setProperties({\n left: this.element.offsetLeft,\n width: this.element.offsetWidth\n });\n }", "title": "" }, { "docid": "ea1e186bad7d7b3e194ae97093e2b95c", "score": "0.5746618", "text": "function e(e,r){const i=r||e.extent,o=e.width,c=Object(_core_unitUtils_js__WEBPACK_IMPORTED_MODULE_0__[\"getMetersPerUnitForSR\"])(i&&i.spatialReference);return i&&o?i.width/o*c*_core_unitUtils_js__WEBPACK_IMPORTED_MODULE_0__[\"inchesPerMeter\"]*96:0}", "title": "" }, { "docid": "ea1e186bad7d7b3e194ae97093e2b95c", "score": "0.5746618", "text": "function e(e,r){const i=r||e.extent,o=e.width,c=Object(_core_unitUtils_js__WEBPACK_IMPORTED_MODULE_0__[\"getMetersPerUnitForSR\"])(i&&i.spatialReference);return i&&o?i.width/o*c*_core_unitUtils_js__WEBPACK_IMPORTED_MODULE_0__[\"inchesPerMeter\"]*96:0}", "title": "" }, { "docid": "31ff7088a51ad15586863c42b7dd7f94", "score": "0.5706845", "text": "get SizePixels() {\n return this.internal.SizePixels;\n }", "title": "" }, { "docid": "e2b841207f408adac346f08e2ad7d1d2", "score": "0.5677662", "text": "function updateRubberbandOnMove(loc) {\n updateRubberbandSizeData(loc);\n drawRubberBandShape(loc);\n}", "title": "" }, { "docid": "e7dcf2554696a83f895c6d76432915db", "score": "0.5669672", "text": "casted() {\n this.size += this.deform;\n this.size2 += this.deform2;\n\n if (this.size >= this.sizeMax) {\n this.size = 1;\n }\n if (this.size2 >= this.sizeMax2) {\n this.size2 = 1;\n }\n }", "title": "" }, { "docid": "c761ae7fa88fc106a1864f9c5c27b29b", "score": "0.5664669", "text": "function setSizes() {\n if (self === top) {\n partSize = Math.floor(windowH / 40);\n } else {\n partSize = Math.floor($(self).width() / 45);\n }\n\n maxH = fixSize(maxH);\n maxW = fixSize(maxW);\n minH = fixSize($cover.height());\n minW = fixSize($cover.width());\n\n $stage.height(maxH);\n $stage.width(maxH);\n $stage.attr({\n width: $stage.width(),\n height: $stage.height()\n });\n\n $('.stageh').attr({\n max: maxH,\n min: minH + 80,\n value: maxH,\n step: partSize\n });\n $('.stagew').attr({\n max: maxW,\n min: minW + 20,\n value: maxH,\n step: partSize\n });\n\n ptsInStgH = $stage.height() / partSize;\n ptsInStgW = $stage.width() / partSize;\n\n Stage.bottom = $stage.height();\n Stage.right = $stage.width();\n\n console.log('Global interval: ' + partSize);\n }", "title": "" }, { "docid": "88104302f68e7881482df6fe98e538d8", "score": "0.5660226", "text": "function _draw_bands(_this) {\n let theHTML = \"\";\n let ranges = [{\n from: _this.verticalSpeedStep * 4,\n to: _this.verticalSpeedStep * 12,\n zero: 60,\n tickHeight: _this.tape_size[2] / 2,\n tapeLength: _this.tape_size[2],\n step: _this.verticalSpeedStep\n },\n {\n from: _this.verticalSpeedStep * 2,\n to: _this.verticalSpeedStep * 4,\n zero: 163,\n tickHeight: _this.tape_size[1] / 2,\n tapeLength: _this.tape_size[1],\n step: _this.verticalSpeedStep\n },\n {\n from: 0,\n to: _this.verticalSpeedStep * 2,\n zero: 192,\n tickHeight: _this.tape_size[0] / 2,\n tapeLength: _this.tape_size[0],\n step: _this.verticalSpeedStep\n },\n {\n from: -_this.verticalSpeedStep * 2,\n to: 0,\n zero: 192,\n tickHeight: _this.tape_size[0] / 2,\n tapeLength: _this.tape_size[0],\n step: _this.verticalSpeedStep\n },\n {\n from: -_this.verticalSpeedStep * 4,\n to: -_this.verticalSpeedStep * 2,\n zero: 222,\n tickHeight: _this.tape_size[1] / 2,\n tapeLength: _this.tape_size[1],\n step: _this.verticalSpeedStep\n },\n {\n from: -_this.verticalSpeedStep * 12,\n to: -_this.verticalSpeedStep * 4,\n zero: 324,\n tickHeight: _this.tape_size[2] / 2,\n tapeLength: _this.tape_size[2],\n step: _this.verticalSpeedStep\n }\n ];\n\n function moduloRange(seg, range) {\n if (seg.to > range.from && seg.from <= range.to) {\n // (seg.from >= range.from && seg.from <= range.to\n // || seg.from <= range.from && seg.to >= range.to)) {\n let p = (seg.from >= range.from) ? seg.from : range.from;\n let q = (seg.to < range.to) ? seg.to : range.to;\n return (p < q) ? {\n from: p,\n to: q\n } : {\n from: q,\n to: p\n };\n }\n return null;\n }\n // console.log(\"ranges\", ranges);\n // console.log(\"vspeed-bands\", _this.bands);\n _.each(_this.bands, function (segments, alert) {\n if (segments.length > 0) {\n let segs = [];\n // console.log(\"segments\", segments);\n segments.forEach(function (segment, i) {\n // console.log(\"original segment\", segments[i]);\n ranges.forEach(function (range) {\n let moduloSeg = moduloRange(segment, range);\n if (moduloSeg) {\n // console.log(\"moduloSeg\", moduloSeg);\n let height = (moduloSeg.to - moduloSeg.from) / _this.verticalSpeedStep * range.tickHeight;\n // console.log(\"height\", height);\n // place the segment in the right place on the tape\n segs.push({\n top: range.zero - (moduloSeg.from / range.step * range.tickHeight) - height,\n left: 30,\n width: 4,\n height: height,\n from: moduloSeg.from,\n to: moduloSeg.to,\n id: \"vspeed-band-\" + alert + \"-\" + i\n });\n }\n });\n });\n theHTML += Handlebars.compile(vspeedBandsTemplate)({\n segments: segs,\n color: bandColors[alert].color,\n dash: bandColors[alert].style === \"dash\"\n });\n }\n // console.log(theHTML);\n });\n $(\"#\" + _this.id + \"-bands\").html(theHTML);\n }", "title": "" }, { "docid": "539d96aa4bee62a95ffe635b203b73da", "score": "0.56579924", "text": "function vpm_calculateSize() {\n\t\tvpm_windwidth = vpm_win.width();\n\t\t// Get the value of the Units Toggle Button\n\t\tvar vpm_units = vpm_checkMonkeyUnits();\n\t\t// If the toggle is set to EMs this if captures that and translated the numbers to EMs\n\t\tif (vpm_units == 'em') {\n\t\t\tvar vpm_emSize = vpm_body.css('font-size');\n\t\t\tvar vpm_emWidth = vpm_windwidth / parseInt(vpm_emSize);\n\t\t\tvpm_windwidth = vpm_emWidth; \n\t\t}\n\t\tvpm_windowWidthOutput();\n\t}", "title": "" }, { "docid": "5f7e607d65893270c65546e2044f1bc5", "score": "0.5656207", "text": "adjustHeight() {\n let wrapperRect = this.container.getBoundingClientRect();\n let newHeight = wrapperRect.bottom - wrapperRect.top;\n let chn = this.getNumOfChannels();\n\n this.params.height = parseInt(newHeight/chn);\n }", "title": "" }, { "docid": "c153a8f2c1405ef84cc1cf8be49002df", "score": "0.56548125", "text": "shrink(){\n this.width=this.width+this.diminish;\n }", "title": "" }, { "docid": "969fba6bf41f7d3b4fea2560574e5688", "score": "0.56368166", "text": "calcChartSize() {\n var parent_height = getRealHeight($(\"#\" + config.tag));\n var subtitle_height = $(\"#subdiscipline_title\").outerHeight(true);\n\n var toolbar_height = $(\"#toolbar\").outerHeight(true) || 0;\n var title_image_height = $(\"#title_image\").outerHeight(true) || 0;\n const CHART_HEIGHT_CORRECTION = 15;\n const CHART_HEIGHT_CORRECTION_TOOLBAR = 15;\n\n // Set available_height and available_width\n if (parent_height === 0) {\n this.available_height = Math.max(document.documentElement.clientHeight, window.innerHeight || 0) - Math.max(subtitle_height, title_image_height) - toolbar_height;\n } else {\n this.available_height = $(\"#\" + config.tag).height() - Math.max(subtitle_height, title_image_height) - toolbar_height;\n }\n\n this.available_height = this.available_height - ((toolbar_height > 0)?(CHART_HEIGHT_CORRECTION_TOOLBAR):(CHART_HEIGHT_CORRECTION));\n\n if (window.headstartInstance.is(\"multiples\")) {\n var multiples_height = $(\".tl-title\").outerHeight(true);\n this.available_height = this.available_height - multiples_height;\n this.available_width = $(\"#\" + config.tag).width();\n } else {\n this.available_width = $(\"#\" + config.tag).width() - $(\"#list_explorer\").width() - $(\"#modals\").width();\n }\n\n // Set current_vis_size\n if (this.available_width > config.min_width && this.available_height > config.min_height) {\n if (this.available_width >= this.available_height) {\n this.current_vis_size = this.available_height;\n } else {\n this.current_vis_size = this.available_width;\n }\n } else {\n this.current_vis_size = this.getMinSize();\n }\n\n if (this.current_vis_size > config.max_height) {\n this.current_vis_size = config.max_height;\n }\n \n //Set current_vis_width for streamgraph\n if(this.available_width > config.min_width) {\n this.current_vis_width = this.available_width;\n } else {\n this.current_vis_width = config.min_width;\n }\n }", "title": "" }, { "docid": "07fc5edd867cd2e4eb5e1f4f103917ad", "score": "0.5601592", "text": "function calculate16by9() {\n $(this).css('height', $(this).parent().width() * 9 / 16);\n }", "title": "" }, { "docid": "37afd84d90b684ac0cd879ed4ae7be78", "score": "0.559103", "text": "function calculateHeightWidth() \n {\n frsWidth = frs.innerWidth();\n\n var minus_resize = options.width - frsWidth;\n var percent_minus = (minus_resize / options.width) * 100;\n frsHeight = options.height - (options.height * percent_minus / 100);\n\n // max and min height\n if(frsHeight <= options.minHeight)\n {\n frsHeight = options.minHeight;\n }\n else if(frsHeight >= options.maxHeight && options.maxHeight > 0)\n {\n frsHeight = options.maxHeight;\n }\n\n applyImageSize() // apply image size\n }", "title": "" }, { "docid": "67985917d2ad12862ead715434a5fe51", "score": "0.5541207", "text": "ReSize() {\n var width = this.girdElement.width()\n var height = this.girdElement.height()\n var maxNumX = Math.floor(width / this.minX)\n var maxNumY = Math.floor(height / this.minY)\n if (this.items.length < maxNumX) maxNumX = this.items.length\n if (this.items.length < maxNumY) maxNumY = this.items.length\n var collectNx = Math.ceil(this.items.length / maxNumX)\n var collectNy = Math.ceil(this.items.length / maxNumY)\n\n var maxX = 0\n var maxY = 0\n for (var index = 0; index < this.items.length; index++) {\n var item = this.items[index]\n item.rankCX = Math.floor(item.xRank / collectNx)\n if (item.rankCX > maxX) maxX = item.rankCX\n item.rankCY = Math.floor(item.yRank / collectNy)\n if (item.rankCY > maxY) maxY = item.rankCY\n item.visible = false\n }\n\n var W = Math.floor(width / (maxX + 1))\n var H = Math.floor(height / (maxY + 1))\n this.eachW = Math.min(W, H)\n this.eachH = Math.min(W, H)\n this.columN = maxX + 1\n this.rowN = maxY + 1\n\n //console.log('width '+width)\n //console.log('items '+this.items.length)\n //console.log('colum '+this.columN)\n //console.log('row '+this.rowN)\n\n //Matrix\n this.girdMatrix = []\n for (var i = 0; i < this.rowN; i++) {\n this.girdMatrix[i] = []\n\n for (var k = 0; k < this.columN; k++) {\n this.girdMatrix[i][k] = \"0\";\n }\n }\n //Init visible\n\n for (var k = 0; k < this.eleItems.length; k++) {\n this.eleItems[k].visible = false\n }\n\n //put \n var count = 0\n for (var i = 0; i < this.items.length; i++) {\n var gx = this.items[i].rankCX\n var gy = this.items[i].rankCY\n\n if (this.girdMatrix[gy][gx] == \"0\") {\n this.girdMatrix[gy][gx] = this.items[i]\n this.items[i].MoveTo = [gx * this.eachW, (this.rowN - gy - 1) * this.eachH]\n this.items[i].visible = true\n } else {\n var [tx, ty] = this.FindClosetPos(gx, gy)\n if (tx != -1) {\n this.girdMatrix[ty][tx] = this.items[i]\n this.items[i].MoveTo = [tx * this.eachW, (this.rowN - ty - 1) * this.eachH]\n this.items[i].visible = true\n count++\n } else {\n this.items[i].visible = false\n break;\n }\n }\n }\n //console.log(count)\n\n //updata UI \n var o = {}\n for (var k = 0; k < this.eleItems.length; k++) {\n var item = this.eleItems[k]\n if (!item.visible) {\n //check exist\n var checkEle = $('#' + item.productID + \"_Item_LB\")\n if (typeof checkEle.html() != \"undefined\") {\n checkEle.remove()\n $('#' + item.productID + \"_Item_CB\").remove()\n }\n continue;\n }\n\n o['ID'] = item.productID\n\n //check exist\n var checkEle = $('#' + item.productID + \"_Item_LB\")\n if (typeof checkEle.html() == \"undefined\") {\n //add\n var s = FormatTemplate(this.temp, o)\n\n var add = $('#RSGird').append(s);\n\n //function\n\n var cb = $('#' + item.productID + \"_Item_CB\")\n var lb = $('#' + item.productID + \"_Item_LB\")\n cb.checkboxradio({\n icon: false\n }).on(\"change\", function(e) {\n var id = $(this).attr('productID')\n if ($(this).is(\":checked\")) {\n if (typeof selectList[id] == 'undefined') {\n selectList[id] = true\n } else {\n selectList[id] = true\n }\n } else {\n if (typeof selectList[id] == 'undefined') {\n //selectList[id]=false\n } else {\n //selectList[id]=false\n delete selectList[id]\n }\n }\n //console.log(selectList)\n $(document).trigger('sai_SelectChange');\n })\n if (typeof selectList[item.productID] != 'undefined') {\n cb.prop('checked', true);\n cb.checkboxradio('refresh')\n }\n\n lb.css(\"background\", \"rgb(255,255,255) url(\\\"\" + item.img + \"\\\") 50% 50% repeat-x\")\n .animate({ width: this.eachW, height: this.eachH, left: item.MoveTo[0], top: item.MoveTo[1] })\n\n } else {\n //move \n\n $('#' + item.productID + \"_Item_LB\").css(\"background\", \"rgb(255,255,255) url(\\\"\" + item.img + \"\\\") 50% 50% repeat-x\")\n .animate({ width: this.eachW, height: this.eachH, left: item.MoveTo[0], top: item.MoveTo[1] })\n }\n }\n }", "title": "" }, { "docid": "ed0678476bc8845fffddbb34edc55de7", "score": "0.5538956", "text": "get size() {\r\n return 12 * this.sides;\r\n }", "title": "" }, { "docid": "bc5bf3f5b79e36b5042b02f374f536f4", "score": "0.5537092", "text": "function get_size(size)\n{\n return(size*(max_draw_size - min_draw_size) + min_draw_size)\n}", "title": "" }, { "docid": "ee01ae98d46f7a0e434f9e760ee284d9", "score": "0.551198", "text": "getSize () {\r\n return {\r\n width: this.size.x,\r\n height: this.size.y\r\n }\r\n }", "title": "" }, { "docid": "82544ade74aa572b644f5920dd460199", "score": "0.5502359", "text": "calcMediumDur(subs){\r\n let m = 0\r\n subs.forEach((l,key)=>{\r\n m = m + l.dur\r\n })\r\n return m / (subs[(subs.length - 1)].index)\r\n }", "title": "" }, { "docid": "68ddbf5618c8c65de1431ce10eca9489", "score": "0.54971176", "text": "function size(i) {\n return sizeScale(data[i].value);\n }", "title": "" }, { "docid": "6556d17097225d0e4e014c14062bdfc4", "score": "0.5484196", "text": "function baseSize ( ) {\r\n\t\treturn $Base[['width', 'height'][options.ort]]();\r\n\t}", "title": "" }, { "docid": "a6df0af0d4771a6fdca9257217f1c572", "score": "0.54789877", "text": "function sizeFn() {\n\treturn function (d) {\n\t\treturn function(t) {\n\t\t\t// add π / 2 to shift the starting point\n\t\t\t// otherwise, want to take the time with respect to smaller sub sections\n\t\t\tvar θ = t * π / 2 + π / 2\n\t\t\treturn 100 * initRadius * Math.abs(_cos(θ));\n\t\t}\n\t}\n}", "title": "" }, { "docid": "35100ae3f0d3e96bf33c67c20f5a92ea", "score": "0.54677206", "text": "getDimensions() {\n return {\n w: this._w,\n h: this._h\n };\n }", "title": "" }, { "docid": "40787ca316d53d6feae092adf0cc9f14", "score": "0.5453096", "text": "function baseSize ( ) {\n return $Base[['width', 'height'][options.ort]]();\n }", "title": "" }, { "docid": "13ed8eb1bb310e54ab4ce0718a56dfab", "score": "0.54506224", "text": "dimensions() {\n return [\n this.availableWidth() - (this.margins.left + this.margins.right),\n this.availableHeight() - (this.margins.top + this.margins.bottom),\n ];\n }", "title": "" }, { "docid": "cb697643b5019b7b5d33d44640ce86a5", "score": "0.54377526", "text": "function baseSize ( ) {\n\t\treturn $Base[['width', 'height'][options.ort]]();\n\t}", "title": "" }, { "docid": "6f44861c5a1611f8f9df793573a6860d", "score": "0.54330105", "text": "get Size() {\n\t\treturn {\n\t\t\tx: this.limitX,\n\t\t\ty: this.limitY,\n\t\t};\n\t}", "title": "" }, { "docid": "a4b16b5f4b40ec5dd0cba8d0d36169e9", "score": "0.5429485", "text": "function updateSizeType() {\n let arr = unitSize();\n \n if (arr[0] >= large) {\n status.size = \"large\"; \n } else if(arr[0] >= medium){\n status.size = \"medium\";\n } else if(arr[0] >= small){\n status.size = \"small\";\n } else if(arr[0] >= xsmall){\n status.size = \"xsmall\";\n } else if(arr[0] <= xsmall){\n status.size = \"xsmall\";\n }\n}", "title": "" }, { "docid": "00ca8695f538e5fc062e69d8c70e076c", "score": "0.54202867", "text": "function measure() {\n\t\t\n\t\t// Call our validate routine and make sure all component properties have been set\n\t\tviz.validate();\n\t\t\n\t\t// Get our size based on height, width, and margin\n\t\tsize = vizuly2.util.size(scope.margin, scope.width, scope.height, scope.parent);\n\t\t\n\t\t//If we have fixed bar width then we will override the width of the component\n\t\tif (scope.barWidth != 'auto') {\n\t\t\tbarWidth = scope.barWidth;\n\t\t\tbarPadding = calculateBarPadding(scope.barPadding, barWidth);\n\t\t\tgroupWidth = (scope.layout == vizuly2.viz.layout.STACKED) ? (barWidth + barPadding) : (barWidth + barPadding) * scope.data.length;\n\t\t\tgroupPadding = calculateGroupPadding(scope.groupPadding, groupWidth);\n\t\t\tsize.width = (groupWidth + groupPadding) * scope.data[0].length;\n\t\t\tsize.left = (size.measuredWidth - size.width)/2;\n\t\t\tsize.right = size.left;\n\t\t}\n\t\telse {\n\t\t\t// The width of each group of bars for a given data point and all of series\n\t\t\tgroupWidth = (size.width / scope.data[0].length) * .9;\n\t\t\tgroupPadding = calculateGroupPadding(scope.groupPadding, groupWidth);\n\t\t\tgroupWidth = groupWidth - groupPadding;\n\t\t\t// The width of an individual bar for a given data point a single series\n\t\t\tbarWidth = (scope.layout == vizuly2.viz.layout.STACKED) ? groupWidth : (groupWidth / scope.data.length);\n\t\t\tbarPadding = calculateBarPadding((scope.layout == vizuly2.viz.layout.STACKED) ? 0 : scope.barPadding, barWidth);\n\t\t\tif (barPadding > barWidth) barPadding = barWidth-2;\n\t\t\tbarWidth = barWidth - barPadding;\n\t\t}\n\t\t\n\t\t\n\t\t// If we don't have a defined x-scale then determine one\n\t\tif (scope.xScale == 'undefined') {\n\t\t\tscope.xScale = vizuly2.util.getTypedScale(viz.x()(scope.data[0][0]));\n\t\t}\n\t\t\n\t\t// Set our domains for the yScale (categories)\n\t\t// Assumes ordinal scale if we have a string, otherwise min and max will do;\n\t\tif (typeof scope.x(scope.data[0][0]) == 'string') {\n\t\t\tscope.xScale.domain(scope.data[0].map(function (d) {\n\t\t\t\treturn scope.x(d);\n\t\t\t}));\n\t\t}\n\t\telse {\n\t\t\tscope.xScale.domain([\n\t\t\t\td3.min(scope.data[0],\n\t\t\t\t function (d) {\n\t\t\t\t\t return scope.x(d);\n\t\t\t\t }),\n\t\t\t\td3.max(scope.data[0], function (d) {\n\t\t\t\t\treturn scope.x(d);\n\t\t\t\t})\n\t\t\t]);\n\t\t}\n\t\t\n\t\t// This assumes all series share the same key value for the x-axis and are ordered accordingly.\n\t\tstackSeries = [];\n\t\tvar stackKeys = [];\n\t\t\n\t\tscope.data.forEach(function (series, i) {\n\t\t\tstackKeys.push('series' + i);\n\t\t})\n\t\t\n\t\tfor (var columnIndex = 0; columnIndex < scope.data[0].length; columnIndex++) {\n\t\t\tvar row = {};\n\t\t\tscope.data.forEach(function (series, i) {\n\t\t\t\trow['series' + i] = {}\n\t\t\t\trow['series' + i].data = series[columnIndex];\n\t\t\t})\n\t\t\tstackSeries.push(row);\n\t\t}\n\t\t\n\t\tvar offset = (scope.layout == vizuly2.viz.layout.STACKED) ? d3.stackOffsetDiverging : vizuly2.util.stackOffsetBaseline;\n\t\t\n\t\t// The d3.stack handles all of the d.x and d.y measurements for various stack layouts - we will let it do its magic here\n\t\tstack = d3.stack()\n\t\t .value(function (d, i) {\n\t\t\t var datum = d[i].data;\n\t\t\t return scope.y(datum);\n\t\t })\n\t\t .keys(stackKeys)\n\t\t .offset(offset);\n\t\t\n\t\t// Apply the stack magic to our data - note this is a destructive operation and assumes certain properties can be mutated (x, x0, y, y0)\n\t\tstackSeries = stack(stackSeries);\n\t\t\n\t\t// We set our xScale domain based on whether we have a stacked or clustered layout\n\t\tscope.yScale.domain([\n\t\t\tMath.min(0, d3.min(stackSeries, function (series) { return d3.min(series, function (d) { return (scope.layout == vizuly2.viz.layout.STACKED && stackSeries.length > 1) ? d[0] : d[1]; })})),\n\t\t\td3.max(stackSeries, function (series) { return d3.max(series, function (d) { return d[1]; })})\n\t\t]);\n\t\t\n\t\t// Set our ranges for each scale\n\t\tscope.yScale.range([size.height, 0]);\n\t\t\n\t\tseriesOffset = 0;\n\t\t\n\t\tvar xScaleOffset = 0;\n\t\t\n\t\tif (typeof scope.xScale.clamp != 'undefined') {\n\t\t\tseriesOffset = (groupWidth + groupPadding)/2;\n\t\t\txScaleOffset = groupWidth;\n\t\t}\n\t\t\n\t\tscope.xScale.range([0, size.width - xScaleOffset]);\n\t\t\n\t\tscope.xAxis.scale(scope.xScale);\n\t\tscope.yAxis.scale(scope.yScale);\n\t\t\n\t\tscope.xAxis.tickFormat(scope.xTickFormat).tickSize(-size.height);\n\t\tscope.yAxis.tickFormat(scope.yTickFormat).tickSize(-size.width).ticks(5);\n\t\t\n\t\tscope.size = size;\n\t\t\n\t\t// Tell everyone we are done making our measurements\n\t\tscope.dispatch.apply('measured', viz);\n\t}", "title": "" }, { "docid": "f380c35b8d7c42af72723884fc397783", "score": "0.5406765", "text": "calculateSprintWidth () {\n debug && console.log(Util.timestamp(), 'D3CapacityPlanSprintHandler.calculateSprintWidth');\n let self = this,\n chart = this.chart;\n \n // Calculate an unscaled sizing\n chart.unscaled = {};\n chart.unscaled.bodyWidth = chart.svg.node()\n .getBoundingClientRect().width - chart.config.margin.left - chart.config.margin.right - chart.config.sprints.padding - chart.bodyLeft;\n chart.unscaled.sprintWidth = parseInt(chart.unscaled.bodyWidth / (chart.data.sprints.length + 0.2));\n chart.unscaled.sprintBodyWidth = parseInt(chart.unscaled.sprintWidth * 0.75);\n chart.unscaled.linkSectionWidth = chart.unscaled.sprintWidth - chart.unscaled.sprintBodyWidth;\n \n // Calculate the proposed scale\n chart.proposedScale = Math.max(Math.min(chart.unscaled.linkSectionWidth / (chart.config.releases.width * 2), 1), chart.config.minScale);\n debug && console.log('D3CapacityPlanSprintHandler.calculateSprintWidth unscaled:', chart.data.sprints.length, chart.unscaled, chart.proposedScale);\n \n // Calculate the size based on the current scale\n chart.bodyWidth = (chart.scaleClientRect(chart.svg.node().getBoundingClientRect()).width) -\n chart.config.margin.left - chart.config.margin.right - chart.config.sprints.padding - chart.bodyLeft;\n chart.sprintWidth = parseInt(chart.bodyWidth / (chart.data.sprints.length + 0.2));\n chart.sprintBodyWidth = parseInt(chart.sprintWidth * 0.75);\n chart.linkSectionWidth = chart.sprintWidth - chart.sprintBodyWidth;\n \n }", "title": "" }, { "docid": "1dec951be72842bb682227393f2e032a", "score": "0.5402142", "text": "function totalBlockSqd() {\nif (totalBlocks === 16) { gridPoints = [0, 200, 400, 600]; }\nelse if (totalBlocks === 25) { gridPoints = [0, 200, 400, 600, 800]; }\nelse if (totalBlocks === 36) { gridPoints = [0, 200, 400, 600, 800, 1000]; }\nelse if (totalBlocks === 49) { gridPoints = [0, 200, 400, 600, 800, 1000, 1200]; }\nelse if (totalBlocks === 64) { gridPoints = [0, 200, 400, 600, 800, 1000,1200,1400]; }\nelse if (totalBlocks === 81) { gridPoints = [0, 200, 400, 600, 800, 1000,1200,1400, 1600]; } \nelse if (totalBlocks === 100) { gridPoints = [0, 200, 400, 600, 800, 1000,1200,1400, 1600, 1800]; } \n\n\nblockRow = gridPoints.length;\nblockAmount = blockRow * blockRow;\nartBWidth = gridPoints[gridPoints.length - 1] + 200;\n\n}", "title": "" }, { "docid": "768f3f8216b99e71bc10fd347ce59973", "score": "0.53940785", "text": "function initSizeParams() {\n\n //set thumb outer size:\n var arrThumbs = g_objStripInner.children(\".ug-thumb-wrapper\");\n var firstThumb = jQuery(arrThumbs[0]);\n var thumbsRealWidth = firstThumb.outerWidth();\n var thumbsRealHeight = firstThumb.outerHeight();\n\n if (g_isVertical == false) {\t\t\t//horizontal\n g_sizes.thumbSize = thumbsRealWidth;\n g_sizes.thumbSecondSize = thumbsRealHeight;\n g_sizes.stripSize = g_objStrip.width();\n g_sizes.stripInnerSize = g_objStripInner.width();\n } else {\t\t//vertical\n g_sizes.thumbSize = thumbsRealHeight;\n g_sizes.thumbSecondSize = thumbsRealWidth;\n g_sizes.stripSize = g_objStrip.height();\n ;\n g_sizes.stripInnerSize = g_objStripInner.height();\n }\n\n }", "title": "" }, { "docid": "e4460d2b80bf4c329dd0978cfb01677f", "score": "0.5385061", "text": "update() {\n let lastWave = this.wavesArray[this.wavesArray.length - 1];\n let firstWave = this.wavesArray[0];\n let firstStartPoint = firstWave.startPoint;\n let lastStartPoint = lastWave.startPoint;\n if (firstStartPoint > -buffer) {\n let newWidth = generateNumber(this.lowestWidth, this.widthRange);\n let newHeight = newWidth * this.magnitude;\n this.wavesArray.unshift(new WaveBit(this.canvas, this.height, this.color, newWidth, newHeight, firstStartPoint, this.isOscillating, this.speed, firstWave.getLifeCycle()));\n }\n if (this.width + buffer < lastStartPoint) {\n lastWave.remove();\n this.wavesArray.pop();\n }\n this.wavesArray.forEach((wave) => {\n wave.update();\n });\n }", "title": "" }, { "docid": "70fd0f42b331faa2b9c082033eb0813e", "score": "0.53784156", "text": "get size() {\n return this._analyser.size;\n }", "title": "" }, { "docid": "70fd0f42b331faa2b9c082033eb0813e", "score": "0.53784156", "text": "get size() {\n return this._analyser.size;\n }", "title": "" }, { "docid": "3b3c5f20f988c3d16a34f1ea2cbc0199", "score": "0.53723943", "text": "get size() {\n return this._analyser.size;\n }", "title": "" }, { "docid": "3b3c5f20f988c3d16a34f1ea2cbc0199", "score": "0.53723943", "text": "get size() {\n return this._analyser.size;\n }", "title": "" }, { "docid": "cf9cc5d7f53c05a2745990f4ca625b50", "score": "0.5367788", "text": "getCurrentSize() {\n return this.ballHolder.items.length;\n }", "title": "" }, { "docid": "f92d345ee879ec07e5b196b1212c07e9", "score": "0.53646225", "text": "setImageWidth(someNumber) {\n this.imageScale = someNumber / this.animationArray[0].height;\n }", "title": "" }, { "docid": "efee3774cb9f6a0bf5a0e44871176a4a", "score": "0.53642946", "text": "@computed('dimensions', 'quantity') volumeByQty({ height, width, length }, q) {\n return ((height * width * length) / 139) * q;\n }", "title": "" }, { "docid": "91a9ab9a34be1aa2d246eb3ce45a8179", "score": "0.53636456", "text": "function dimensionCalc() {\n if (width > height) {\n vMax = width / 100;\n vMin = height / 100;\n circleRad = height * 0.45;\n } else {\n vMax = height / 100;\n vMin = width / 100;\n circleRad = width * 0.45;\n }\n}", "title": "" }, { "docid": "00c76ff40afac990658c6289cdadcb7d", "score": "0.53578115", "text": "updateDimensions() {\n let width = this.DollarContainer.current.clientWidth\n let height = this.DollarContainer.current.clientHeight\n let itemWidth = this.props.itemWidth\n let itemHeight = this.props.itemHeight\n\n if (width > height * (itemWidth / itemHeight)) {\n console.log(\"Width is greater than height \" + width + \" , \" + height)\n this.setState({ width: height * (itemWidth / itemHeight), height: height })\n } else {\n console.log(\"height is greater than height \" + width + \" , \" + height)\n this.setState({ height: width * (itemHeight / itemWidth), width: width })\n }\n }", "title": "" }, { "docid": "489b86cdbb15339baefdb0fe217045eb", "score": "0.5353192", "text": "get fretBoardWidth() {return this.fretWidth*instrument.fretNumber}", "title": "" }, { "docid": "df3d8b74b6cae60d4293f042273fab40", "score": "0.53454137", "text": "getDimensions() {\n return _spaceDimensions;\n }", "title": "" }, { "docid": "53167afa30168f7c82c7c62bff666435", "score": "0.5345185", "text": "get mainAxisSize() {\n let value = 0;\n this.items.forEach(item => {\n value += item[this.mainLayoutSize] || 0;\n });\n return value;\n }", "title": "" }, { "docid": "53167afa30168f7c82c7c62bff666435", "score": "0.5345185", "text": "get mainAxisSize() {\n let value = 0;\n this.items.forEach(item => {\n value += item[this.mainLayoutSize] || 0;\n });\n return value;\n }", "title": "" }, { "docid": "3166d7c8576e540a911cf3a084e2a842", "score": "0.5343146", "text": "calcLength(limb) {\n var upper = this.skeleton.bones[limb.upper];\n var lower = this.skeleton.bones[limb.lower];\n var scaling = this.rootMesh.scaling.x;\n limb.upperLength = upper.getAbsolutePosition().subtract(lower.getAbsolutePosition()).length()*scaling;\n if ( lower.children && lower.children[0] ) {\n limb.lowerLength = lower.getAbsolutePosition().subtract(lower.children[0].getAbsolutePosition()).length()*scaling;\n } else {\n limb.lowerLength = 0;\n }\n limb.length = limb.upperLength+limb.lowerLength;\n this.log(\"Length of \"+upper.name+\": \"+limb.upperLength+\", \"+lower.name+\": \"+limb.lowerLength);\n }", "title": "" }, { "docid": "ed47dafdc8ce5db49d75443d7a32550e", "score": "0.5341142", "text": "function sizePorts(count_year) {\n count_year = parseInt(count_year)\n if(count_year === 2003){\n // if(count_year = parseInt(count_year)){\n $('#mi-vessel-icon').hide();\n $('#mi-shipChange-text').hide();\n $('#mi-shipChange-nd').show();\n }else{\n $('#mi-shipChange-nd').hide();\n $('#mi-vessel-icon').show();\n $('#mi-shipChange-text').show();\n }\n var scaleRange = [],\n minSize = [],\n maxSize = [],\n tc = 0,\n pc = 0, pLabel;\n for (var i = 0; i < port_data.length; i++) {\n var d = port_data[i];\n //if(parseInt(d.year) === count_year){\n scaleRange.push(parseInt(d.calls));\n //}\n }\n\n var minSize = d3.min(scaleRange),\n maxSize = d3.max(scaleRange),\n portScale = d3.scale.pow()\n .exponent(0.8)\n .domain([minSize, maxSize])\n .range([5, 19]);\n\n // loop through data and size metros related to primary\n for (var i = 0; i < port_data.length; i++) {\n var d = port_data[i],\n r, j = 0;\n\n //identify measurement of moves\n r = portScale(parseInt(d.calls));\n\n if (parseInt(d.year) === count_year && d.calls > 0) {\n tc = Number(tc) + Number(d.calls);\n var elem = d3.select('#port_' + d.link_id);\n elem.attr('r', r)\n .classed({'mi-no-activity':false})\n .select('circle')\n .transition()\n .duration(500)\n .attr('r', r)\n .attr('i', j)\n .attr('val', d.calls)\n .attr('name', portname(d.link_id));\n j++\n }else if (parseInt(d.year) === count_year){\n var elem = d3.select('#port_' + d.link_id);\n elem.attr('r', 4)\n .classed({'mi-no-activity':true})\n .select('circle')\n .transition()\n .duration(500)\n .attr('r', 4)\n .attr('val', d.calls)\n .attr('name', portname(d.link_id));\n }\n\n if (parseInt(d.year) === (count_year - 1)) {\n pc = Number(pc) + Number(d.calls);\n }\n }\n\n for (var i = 0; i < port_data.length; i++) {\n var d = port_data[i];\n if(parseInt(d.year) === (count_year - 1)){\n var elem = d3.select('#port_' + d.link_id);\n elem.select('circle').attr('prev', d.calls);\n }\n }\n\n $(\"svg circle\").unbind('mouseenter mouseleave');\n\n $('#mi-vessel-count').html(numeral(tc).format('0,0'));\n var totalCallChange = ((tc - pc) / pc)*100;\n $('#mi-vessel-percent').html((totalCallChange).toFixed(0) + '%');\n\n if (totalCallChange > 5) {\n $('#mi-vessel-icon').html(ind_up);\n } else if (totalCallChange < -5) {\n $('#mi-vessel-icon').html(ind_down);\n } else {\n $('#mi-vessel-icon').html(ind_even);\n }\n\n packPorts(); //run packer on resized ports\n\n d3.selectAll('.port circle').on('mouseover', null);\n d3.selectAll('.port circle').on('mouseout', null);\n d3.selectAll('.port circle')\n .on('mouseover', function(e) {\n d3.select(this).classed(\"active\", true);\n var a = this.getAttribute('val'), p = this.getAttribute('prev'), n = this.getAttribute('name');\n var portCallChange = ((a - p) / p)*100;\n if(isFinite(portCallChange)){\n $('#mi-vessel-percent').html((portCallChange).toFixed(0) + '%');\n }else{\n $('#mi-vessel-percent').html('&#8734;');\n }\n $('#mi-vessel-count').html(numeral(a).format('0,0'));\n $('#mi-vessel-title').html(n);\n if (portCallChange > 5) {\n $('#mi-vessel-icon').html(ind_up);\n } else if (portCallChange < -5) {\n $('#mi-vessel-icon').html(ind_down);\n } else {\n $('#mi-vessel-icon').html(ind_even);\n }\n\n })\n .on('mouseout', function(e) {\n d3.select(this).classed(\"active\", false);//.style(\"stroke-width\", 0);\n $('#mi-vessel-count').html(numeral(tc).format('0,0'));\n $('#mi-vessel-percent').html((totalCallChange).toFixed(0) + '%');\n $('#mi-vessel-title').html('All Ports of Entry');\n if (totalCallChange > 5) {\n $('#mi-vessel-icon').html(ind_up);\n } else if (totalCallChange < -5) {\n $('#mi-vessel-icon').html(ind_down);\n } else {\n $('#mi-vessel-icon').html(ind_even);\n }\n });\n d3.selectAll('.port text')\n .on('mouseover', function(e) {\n var item = $(this).parent().children('circle');\n item.toggleClass(\"active\");\n var a = item.attr('val'), p = item.attr('prev'), n = item.attr('name');\n var portCallChange = ((a - p) / p)*100;\n if(isFinite(portCallChange)){\n $('#mi-vessel-percent').html((portCallChange).toFixed(0) + '%');\n }else{\n $('#mi-vessel-percent').html('&#8734;');\n }\n $('#mi-vessel-count').html(numeral(a).format('0,0'));\n $('#mi-vessel-title').html(n);\n if (portCallChange > 5) {\n $('#mi-vessel-icon').html(ind_up);\n } else if (portCallChange < -5) {\n $('#mi-vessel-icon').html(ind_down);\n } else {\n $('#mi-vessel-icon').html(ind_even);\n }\n })\n .on('mouseout', function(e) {\n var item = $(this).parent().children('circle');\n item.toggleClass(\"active\");\n $('#mi-vessel-count').html(numeral(tc).format('0,0'));\n $('#mi-vessel-percent').html((totalCallChange).toFixed(0) + '%');\n $('#mi-vessel-title').html('All Ports of Entry');\n if (totalCallChange > 5) {\n $('#mi-vessel-icon').html(ind_up);\n } else if (totalCallChange < -5) {\n $('#mi-vessel-icon').html(ind_down);\n } else {\n $('#mi-vessel-icon').html(ind_even);\n }\n });\n }", "title": "" }, { "docid": "fd2b62eddf36a280e1328f407b251b17", "score": "0.5337366", "text": "getWidth() {\n return this.maxX - this.minX;\n }", "title": "" }, { "docid": "3b39cd23e2f7b92f3cc72a7adae6e872", "score": "0.53351796", "text": "function calcArtDimensions() {\n // const rulerConverter = 17.456666;\n const rulerConverter = 16;\n let curWidth = $('#design-display').width();\n let curHeight = $('#design-display').height();\n let widthInInches = curWidth / rulerConverter;\n let heightInInches = curHeight / rulerConverter;\n widthInInches = widthInInches.toFixed(2);\n $('.current-width').text(`${widthInInches}\"`);\n heightInInches = heightInInches.toFixed(2);\n $('.current-height').text(`${heightInInches}\"`);\n }", "title": "" }, { "docid": "6c1a9d82d82164cef6e9ffa30f4c42c7", "score": "0.5334664", "text": "getImageWidth() {\n return (this.animationArray[0].width * this.imageScale)\n }", "title": "" }, { "docid": "13cde6ce476733b502bb7ddb19160730", "score": "0.532937", "text": "updateSize(S, B) {\n this.s = S;\n this.b = B;\n }", "title": "" }, { "docid": "fcd9fbace9704628bf20c3b0b6a92e04", "score": "0.5328054", "text": "function multBands(img,distDir,by){\r\n var out = img.multiply(ee.Image(distDir).multiply(by));\r\n out = out.copyProperties(img,['system:time_start'])\r\n .copyProperties(img);\r\n return out;\r\n }", "title": "" }, { "docid": "2d455eecee0b3e18f0990af87ff3f604", "score": "0.5319341", "text": "function calculate_bandwidth(band) {\r\n var units = [\"bps\", \"Kbps\", \"Mbps\", \"Gbps\"];\r\n var i = 0;\r\n while (band >= 1000) {\r\n band /= 1000;\r\n i++;\r\n }\r\n return String(band.toFixed(2)) + \" \" + units[i];\r\n }", "title": "" }, { "docid": "3da26465e1608c7c7ac2887c13f0c64a", "score": "0.5312024", "text": "getWidth() {\n return this.sliding_door_axes[0];\n }", "title": "" }, { "docid": "cb6a1bbe838ec756b9918401629ba42d", "score": "0.5311335", "text": "getSize() {\n switch(this.geomType) {\n case 'cube':\n return this.outerGeom.parameters.width;\n case 'cylinder':\n return this.outerGeom.parameters.radiusTop;\n case 'sphere':\n return this.outerGeom.parameters.radius;\n }\n }", "title": "" }, { "docid": "0c8516552e2290423b7fffb60fa0e864", "score": "0.530374", "text": "calculateArea(){\n return this.length * this.breadth;\n }", "title": "" }, { "docid": "ad8564ee231e8db470e73d2abc240925", "score": "0.53029305", "text": "updateDimensions() {\n let cx = this.center.components[0];\n let cy = this.center.components[1];\n let cz = this.center.components[2];\n\n this.min[0] = cx - this.radius;\n this.min[1] = cy - this.radius;\n this.min[2] = cz - this.radius;\n this.max[0] = cx + this.radius;\n this.max[1] = cy + this.radius;\n this.max[2] = cz + this.radius;\n\n // Precalculate to simplify ray test\n this.left = cx - this.radius;\n this.right = cx + this.radius;\n this.back = cz - this.radius;\n this.front = cz + this.radius;\n this.bottom = cy - this.radius;\n this.top = cy + this.radius;\n\n return this;\n }", "title": "" }, { "docid": "65ec77249d7d82d81346ef4fdf2eb3b8", "score": "0.5302846", "text": "calculateStepSize() {\n var tileBorder = 4;\n\n this.modelLength = this.getBot().userData.depth;\n this.stepSize = this.modelLength + (tileBorder * 2);\n }", "title": "" }, { "docid": "4e8a5f6ea34387207e315e5651d9c53a", "score": "0.53013515", "text": "function updateDimensions(event){\n\n\n\t//Only 2 sides need to be translated depending on what measurement is being changed\n\t//console.log(event.target.id, boxDepth, boxHeight, boxWidth);\n\tswitch(event.target.id){\n\t\tcase \"slider-width\":\n\t\tcase \"width-value\":\n\t\t\tmeshList[edgeType][1].geometry.translate((boxWidth-lastWidth)/2, 0, 0);\n\t\t\tmeshList[edgeType][3].geometry.translate((-(boxWidth-lastWidth))/2, 0, 0);\n\t\t\t/*outlineList[1].geometry.translate((boxWidth-lastWidth)/2, 0, 0);\n\t\t\toutlineList[3].geometry.translate((-(boxWidth-lastWidth))/2, 0, 0);*/\n\t\t\tbreak;\n\t\tcase \"slider-height\":\n\t\tcase \"height-value\":\n\t\t\tmeshList[edgeType][4].geometry.translate(0, (boxHeight-lastHeight)/2, 0);\n\t\t\tmeshList[edgeType][5].geometry.translate(0, (-(boxHeight-lastHeight))/2, 0);\n\t\t\t/*outlineList[4].geometry.translate(0, (boxHeight-lastHeight)/2, 0);\n\t\t\toutlineList[5].geometry.translate(0, (-(boxHeight-lastHeight))/2, 0);*/\n\t\t\tbreak;\n\t\tcase \"slider-depth\":\n\t\tcase \"depth-value\":\n\t\t\tmeshList[edgeType][0].geometry.translate(0, 0, (boxDepth-lastDepth)/2);\n\t\t\tmeshList[edgeType][2].geometry.translate(0, 0, (-(boxDepth-lastDepth))/2);\n\t\t\t/*outlineList[0].geometry.translate(0, 0, (boxDepth-lastDepth)/2);\n\t\t\toutlineList[2].geometry.translate(0, 0, (-(boxDepth-lastDepth))/2);*/\n\t\t\tbreak;\n\t}\n\n\t//We want two measurements of each box face to scale, and one to translate, in order to preserve eventual material thickness property\n\tfor(var i=0; i<6; i++){\n\t\tswitch(i){\n\t\t\tcase 0: //Front\n\t\t\t\tmeshList[edgeType][i].geometry.scale(boxWidth/lastWidth, boxHeight/lastHeight, 1);\n\t\t\t\t//outlineList[i].geometry.scale(boxWidth/lastWidth, boxHeight/lastHeight, 1);\n\t\t\t\tbreak;\n\t\t\tcase 1: //Right\n\t\t\t\tmeshList[edgeType][i].geometry.scale(1, boxHeight/lastHeight, boxDepth/lastDepth);\n\t\t\t\t//outlineList[i].geometry.scale(1, boxHeight/lastHeight, boxDepth/lastDepth);\n\t\t\t\tbreak;\n\t\t\tcase 2: //Back\n\t\t\t\tmeshList[edgeType][i].geometry.scale(boxWidth/lastWidth, boxHeight/lastHeight, 1);\n\t\t\t\t//outlineList[i].geometry.scale(boxWidth/lastWidth, boxHeight/lastHeight, 1);\n\t\t\t\tbreak;\n\t\t\tcase 3: //Left\n\t\t\t\tmeshList[edgeType][i].geometry.scale(1, boxHeight/lastHeight, boxDepth/lastDepth);\n\t\t\t\t//outlineList[i].geometry.scale(1, boxHeight/lastHeight, boxDepth/lastDepth);\n\t\t\t\tbreak;\n\t\t\tcase 4: //Top\n\t\t\t\tmeshList[edgeType][i].geometry.scale(boxWidth/lastWidth, 1, boxDepth/lastDepth);\n\t\t\t\t//outlineList[i].geometry.scale(boxWidth/lastWidth, 1, boxDepth/lastDepth);\n\t\t\t\tbreak;\n\t\t\tcase 5: //Bottom\n\t\t\t\tmeshList[edgeType][i].geometry.scale(boxWidth/lastWidth, 1, boxDepth/lastDepth);\n\t\t\t\t//outlineList[i].geometry.scale(boxWidth/lastWidth, 1, boxDepth/lastDepth);\n\t\t\t\tbreak;\n\t\t}\n\t\tmeshList[edgeType][i].geometry.verticesNeedUpdate = true;\n\t\t//outlineList[i].geometry.verticesNeedUpdate = true;\n\t}\n\n\tlastWidth = boxWidth;\n\tlastHeight = boxHeight;\n\tlastDepth = boxDepth;\n\n}", "title": "" }, { "docid": "a5a1d691a8a959257c24685b5983b9cb", "score": "0.5300747", "text": "tryCalculateResistance() {\r\n\r\n let bands = Array(this.totalBandCount).fill(undefined);\r\n \r\n //band colors are stored as color objects, and they need to be resolved to Known color names \r\n Object.keys(this.state.bandColor).forEach(key => {\r\n let color = this.state.bandColor[key];\r\n if(color) {\r\n bands[key] = this.rcc.resolveColor(color.rgb, key).name;\r\n }\r\n });\r\n\r\n let result;\r\n\r\n //if the 3rd band from the left has color, its a 5 band resistor\r\n if(bands[2]){\r\n result = this.rcc.getOhmsFrom5bands.apply(null, bands);\r\n }\r\n else{\r\n bands.splice(2,1);\r\n result = this.rcc.getOhmsFrom4bands.apply(null, bands);\r\n }\r\n\r\n if(result){\r\n this.setState({resistorData: result});\r\n }\r\n else{\r\n this.setState({resistorData: null});\r\n }\r\n }", "title": "" }, { "docid": "db77a5a50301bc60ab0ab1575c2cd005", "score": "0.5296908", "text": "function calculateBase(groupItem){\nvar extent;\nvar baseAxis=groupItem.axis;\nvar seriesModels=groupItem.seriesModels;\nvar seriesCount=seriesModels.length;\n\nvar boxWidthList=groupItem.boxWidthList=[];\nvar boxOffsetList=groupItem.boxOffsetList=[];\nvar boundList=[];\n\nvar bandWidth;\nif(baseAxis.type==='category'){\nbandWidth=baseAxis.getBandWidth();\n}else\n{\nvar maxDataCount=0;\neach$13(seriesModels,function(seriesModel){\nmaxDataCount=Math.max(maxDataCount,seriesModel.getData().count());\n});\nextent=baseAxis.getExtent(),\nMath.abs(extent[1]-extent[0])/maxDataCount;\n}\n\neach$13(seriesModels,function(seriesModel){\nvar boxWidthBound=seriesModel.get('boxWidth');\nif(!isArray(boxWidthBound)){\nboxWidthBound=[boxWidthBound,boxWidthBound];\n}\nboundList.push([\nparsePercent$1(boxWidthBound[0],bandWidth)||0,\nparsePercent$1(boxWidthBound[1],bandWidth)||0]);\n\n});\n\nvar availableWidth=bandWidth*0.8-2;\nvar boxGap=availableWidth/seriesCount*0.3;\nvar boxWidth=(availableWidth-boxGap*(seriesCount-1))/seriesCount;\nvar base=boxWidth/2-availableWidth/2;\n\neach$13(seriesModels,function(seriesModel,idx){\nboxOffsetList.push(base);\nbase+=boxGap+boxWidth;\n\nboxWidthList.push(\nMath.min(Math.max(boxWidth,boundList[idx][0]),boundList[idx][1]));\n\n});\n}", "title": "" }, { "docid": "5cad4c9862e147d480bc1d869d15a742", "score": "0.5284243", "text": "function get_bandos_(){\n \n return bandos;\n \n }", "title": "" }, { "docid": "1a8ed5b6522ecacc67aee101e7192ada", "score": "0.5281776", "text": "function prepareBarLength(itemModel,symbolRepeat,layout,opt,output){\nvar valueDim=opt.valueDim;\nvar symbolBoundingData=itemModel.get('symbolBoundingData');\nvar valueAxis=opt.coordSys.getOtherAxis(opt.coordSys.getBaseAxis());\nvar zeroPx=valueAxis.toGlobalCoord(valueAxis.dataToCoord(0));\nvar pxSignIdx=1-+(layout[valueDim.wh]<=0);\nvar boundingLength;\n\nif(isArray(symbolBoundingData)){\nvar symbolBoundingExtent=[\nconvertToCoordOnAxis(valueAxis,symbolBoundingData[0])-zeroPx,\nconvertToCoordOnAxis(valueAxis,symbolBoundingData[1])-zeroPx];\n\nsymbolBoundingExtent[1]<symbolBoundingExtent[0]&&symbolBoundingExtent.reverse();\nboundingLength=symbolBoundingExtent[pxSignIdx];\n}else\nif(symbolBoundingData!=null){\nboundingLength=convertToCoordOnAxis(valueAxis,symbolBoundingData)-zeroPx;\n}else\nif(symbolRepeat){\nboundingLength=opt.coordSysExtent[valueDim.index][pxSignIdx]-zeroPx;\n}else\n{\nboundingLength=layout[valueDim.wh];\n}\n\noutput.boundingLength=boundingLength;\n\nif(symbolRepeat){\noutput.repeatCutLength=layout[valueDim.wh];\n}\n\noutput.pxSign=boundingLength>0?1:boundingLength<0?-1:0;\n}", "title": "" }, { "docid": "4073b3ded48d86b09bef3a2984261cfc", "score": "0.5278555", "text": "calculateBrushWidth(pointerEvt){\n let brushWidth = this.brushManager.getCurrSize();\n if(pointerEvt.pressure){\n brushWidth = (pointerEvt.pressure*2) * brushWidth;\n }\n return brushWidth;\n }", "title": "" }, { "docid": "3d2732374744e2575922d9fcb49f0f8c", "score": "0.5275723", "text": "scale() {\n let offset = this.bb.__offset(this.bb_pos, 6);\n return offset ? this.bb.readInt32(this.bb_pos + offset) : 0;\n }", "title": "" }, { "docid": "eda187b982d5090bf5b5fc1693e3005c", "score": "0.5275498", "text": "function measure(args, callback) {\n typeset(args, (result) => {\n const [x0, y0, x1, y1] = result.blockBounds\n callback({\n width: x1 - x0,\n height: y1 - y0\n })\n }, {metricsOnly: true})\n }", "title": "" }, { "docid": "1a9f90e2e30f0cc7c663fa81b50fb41c", "score": "0.5266297", "text": "calculationSpeed (xLen, yLen, _short) {\n var proportion = 1;\n xLen = Math.abs(xLen);\n yLen = Math.abs(yLen);\n if (xLen > yLen) {\n proportion = xLen / yLen;\n } else if (xLen < yLen) {\n proportion = yLen / xLen;\n }\n return {\n shorObj: xLen < yLen ? 'x': 'y',\n shor: _short,\n len: Math.round(_short * proportion) < 5 ? Math.round(_short * proportion) : 5\n }\n }", "title": "" }, { "docid": "7944153de959a4b8db7c24c7891092ee", "score": "0.52633166", "text": "seekAndResize() {\n const defwidth = 960;\n const defheight = 420;\n let realWidth = this.canv.getWidth();\n let realHeight = this.canv.getHeight();\n let coef = 0;\n if (realHeight > realWidth) {\n if (realHeight > defheight) {\n coef = realHeight / defheight\n }\n else {\n coef = 1\n }\n }\n else {\n if (realWidth > defwidth) {\n coef = realWidth / defwidth\n }\n else {\n coef = 1\n }\n }\n return coef\n }", "title": "" }, { "docid": "02ef84357b9c264b2c2e40062817ce6c", "score": "0.5259265", "text": "surfaceArea() {\n return 2 * (this.newLength * this.newWidth + this.newLength * this.newHeight + this.newWidth * this.newHeight);\n }", "title": "" }, { "docid": "b6ddbe697936e19193f2076dbee488ac", "score": "0.52538186", "text": "surfaceArea(){\n return 6 * Math.pow(this.length, 2)\n }", "title": "" }, { "docid": "b564174bc607beb5f747662da7bab356", "score": "0.5252653", "text": "scale ( w, h ) {\n\n if ( this.checkParams( w, h, 0, 0 ) ) {\n\n let map = new Float32Array( w * h );\n\n let xScale = this.width / w;\n\n let zScale = this.depth / h;\n\n console.log('original width:' + this.width + ' new:' + w + 'original height:' + this.depth + ' new:' + h )\n\n console.log('xScale:' + xScale + ' zScale:' + zScale);\n\n for ( let z = 0; z < h; z++ ) {\n\n for ( let x = 0; x < w; x++ ) {\n\n map[ w * z + x ] = this.biCubic( x * xScale, z * zScale);\n\n }\n\n }\n\n console.log('WIDTH:' + w + \" HEIGHT:\" + h)\n\n this.map = map;\n\n this.width = w;\n\n this.depth = h;\n\n this.squareSize = Math.min( w, h );\n\n this.max = this.squareSize - 1;\n\n }\n\n }", "title": "" }, { "docid": "9545d6914bb1ce8ad3fcee0817e57430", "score": "0.52491754", "text": "getSize() {\n return MathUtils.cellsInGrid(this);\n }", "title": "" }, { "docid": "7829873b58b9f60c475b5f150bc8ed03", "score": "0.5245826", "text": "function barsResize() {\n\n // Layout variables\n width = d3Container.node().getBoundingClientRect().width;\n\n\n // Layout\n // -------------------------\n\n // Main svg width\n container.attr(\"width\", width);\n\n // Width of appended group\n svg.attr(\"width\", width);\n\n // Horizontal range\n x.rangeBands([0, width], 0.3);\n\n\n // Chart elements\n // -------------------------\n\n // Bars\n svg.selectAll('.d3-random-bars')\n .attr('width', x.rangeBand())\n .attr('x', function (d, i) {\n return x(i);\n });\n }", "title": "" }, { "docid": "dc8a09e0f334185e13ab51b3c1484694", "score": "0.5244158", "text": "getSize() {\n return this.currentSize;\n\n }", "title": "" }, { "docid": "169f546caeafecc3d7bd02d00b085db4", "score": "0.5242953", "text": "function barsResize() {\n\n // Layout variables\n width = d3Container.node().getBoundingClientRect().width;\n\n\n // Layout\n // -------------------------\n\n // Main svg width\n container.attr(\"width\", width);\n\n // Width of appended group\n svg.attr(\"width\", width);\n\n // Horizontal range\n x.rangeBands([0, width], 0.3);\n\n\n // Chart elements\n // -------------------------\n\n // Bars\n svg.selectAll('.d3-random-bars')\n .attr('width', x.rangeBand())\n .attr('x', function(d,i) {\n return x(i);\n });\n }", "title": "" }, { "docid": "80cb18e28bda6919ce984f637c49486f", "score": "0.5242813", "text": "measureSize(value) {\n return DomHelper.measureSize(value, this.subGrid ? this.subGrid.element : undefined);\n }", "title": "" }, { "docid": "65cb38d6e05128bd1c2aebd3dbc398e9", "score": "0.52425396", "text": "getQualityMeasures(maskedImage,segmentedImage,segmentedMaskedImage) {\n let indims=maskedImage.getDimensions();\n //let spa=maskedImage.getSpacing();\n let idata=maskedImage.getImageData();\n let sdata=segmentedMaskedImage.getImageData(); // masked image \n let bdata=segmentedImage.getImageData(); // background and non-background image\n let islicesize=indims[0]*indims[1];\n \n this.outputs['segm']=segmentedMaskedImage;\n \n let imageVar = this.variance(idata);\n let imageMean = this.mean(idata);\n console.log('variance:',imageVar);\n let signal = [];\n let noise = [];\n let wm = []; // white matter\n let gm = []; // gray matter\n let bm = []; // background\n let x_j = []; // voxel intensities\n let x_max = 0;\n\n signal.push(0.01);\n noise.push(0.01);\n bm.push(0.01);\n wm.push(0.01);\n gm.push(0.01);\n x_j.push(0.01);\n\n for (let k=0;k<indims[2];k++) {\n for (let j=0;j<indims[1];j++) {\n for (let i=0;i<indims[0];i++) {\n let inindex= i+j*indims[0]+k*islicesize;\n\n if(idata[inindex])\n x_j.push(idata[inindex]);\n x_max +=Math.pow(idata[inindex],2); \n\n if(idata[inindex] > imageMean){\n signal.push(idata[inindex]);\n }\n\n if(sdata[inindex]==1){\n wm.push(idata[inindex]);\n }else if(sdata[inindex]==2){\n gm.push(idata[inindex]);\n } else if(bdata[inindex]==0){ // from two-class segmentation\n bm.push(idata[inindex]);\n } \n\n }\n }\n }\n\n x_max = Math.sqrt(x_max);\n \n let snr = this.mean(signal)/(Math.sqrt(this.variance(bm))); // higher better\n let cjv = (Math.sqrt(this.variance(wm))+Math.sqrt(this.variance(gm)))/Math.abs(this.mean(wm)-this.mean(gm)); // lower better\n let cnr = Math.abs(this.mean(gm)-this.mean(wm))/Math.sqrt(this.variance(bm)+this.variance(wm)+this.variance(gm)); // higher better\n let efc = -x_j.map(function(v){ return v/x_max*Math.log(v/x_max);}).reduce((a,b)=>a+b); // lower better\n\n console.log('xj.length:',x_j.length);\n console.log('x_max:',x_max);\n console.log('signal.length:',signal.length);\n console.log('bm.length:',bm.length);\n console.log('wm.length:',wm.length);\n console.log('gm.length:',gm.length);\n console.log('image mean:',imageMean);\n console.log('image var:',imageVar);\n console.log('mean wm:',this.mean(wm));\n console.log('mean gm:',this.mean(gm));\n console.log('mean bm:',this.mean(bm));\n console.log('var gm:',this.variance(gm));\n console.log('var bm:',this.variance(bm));\n console.log('var wm:',this.variance(wm));\n console.log('snr:',snr);\n console.log('cjv:',cjv);\n console.log('cnr:',cnr);\n console.log('efc:',efc);\n return [snr,cnr,cjv,efc];\n }", "title": "" }, { "docid": "79a640f649b712bcc85c30938d875e8d", "score": "0.52348644", "text": "getDiameter() {\n return this.size;\n }", "title": "" }, { "docid": "a14601306696d02e61475530f2b2752b", "score": "0.5234779", "text": "function Copy$TW3ControlSizeInfo(s,d) {\n return d;\n}", "title": "" }, { "docid": "32a7321f638e94c787791d6c0b94cb1d", "score": "0.52291167", "text": "function adjustSliderSizes() {\n let newCamRect = cameraStream.getBoundingClientRect();\n speedController.width = 80;\n speedController.height = Math.round(newCamRect.height);\n turnController.width = Math.round(newCamRect.width);\n turnController.height = 80;\n // console.log(\"new Cam dimensions:\", Math.round(newCamRect.width), 'x', Math.round(newCamRect.height));\n speedSlider.resize();\n turnSlider.resize();\n}", "title": "" }, { "docid": "53e1b35b3794f0c6d6c3ef6c10b7c9f6", "score": "0.52273005", "text": "function baseSize ( ) {\n\t\treturn scope_Base['offset' + ['Width', 'Height'][options.ort]];\n\t}", "title": "" }, { "docid": "988faf039af13cc633756987ad606408", "score": "0.5227022", "text": "resetSize(){\n this.t_Boutons.forEach( tab => {\n tab.setScale(1)\n });\n }", "title": "" }, { "docid": "fc00434e4d9b42ae3039a77a5a5fbc45", "score": "0.5226978", "text": "get pixelScalingRatio() {\n return this.i.w;\n }", "title": "" }, { "docid": "783801244b593d0672a0956660d9ad51", "score": "0.5226489", "text": "boardSizeCalculated(width, height) {\n const gameControls = this.$('#game-controls');\n const playerLog = this.$('#player-log');\n const gameLog = this.$('#game-log');\n const gameControlsMarginBottom = parseInt(gameControls.css('margin-bottom'), 10);\n\n gameControls.outerHeight(0.6 * height);\n playerLog.outerHeight((0.4 * height) - gameControlsMarginBottom);\n gameLog.outerHeight(height);\n }", "title": "" }, { "docid": "a286ffc1ca4821a187bc4d30169f8a8d", "score": "0.5223904", "text": "_getMeasurements() {\n const that = this;\n\n if (!that._isVisible() || that._renderingSuspended) {\n that._renderingSuspended = true;\n return;\n }\n\n const measurements = that._measurements;\n\n measurements.cachedWidth = that.offsetWidth;\n measurements.cachedHeight = that.offsetHeight;\n\n measurements.radius = measurements.cachedWidth / 2;\n\n const measureElement = document.createElement('div');\n that.appendChild(measureElement);\n\n // ticks\n measureElement.className = 'jqx-tick';\n measurements.majorTickSize = measureElement.offsetWidth;\n measureElement.className += ' jqx-tick-minor';\n measurements.minorTickSize = measureElement.offsetWidth;\n\n // labels\n measureElement.className = 'jqx-label';\n const measureElementStyle = window.getComputedStyle(measureElement);\n measurements.fontSize = measureElementStyle.fontSize;\n measurements.fontFamily = measureElementStyle.fontFamily;\n measurements.fontWeight = measureElementStyle.fontWeight;\n measurements.fontStyle = measureElementStyle.fontStyle;\n\n measurements.trackWidth = 0;\n measurements.trackBorderWidth = 0;\n\n if (that.analogDisplayType === 'needle') {\n // needle\n measureElement.className = 'jqx-needle';\n measurements.needleWidth = measureElement.offsetWidth;\n measurements.needleLength = measureElement.offsetHeight;\n\n // ranges\n measureElement.className = 'jqx-range';\n measurements.rangeSize = measureElement.offsetWidth;\n }\n else { // 'fill' and 'line' case\n // track\n measureElement.className = 'jqx-track';\n measurements.trackBorderWidth = parseFloat(measureElementStyle.strokeWidth);\n measurements.trackWidth = Math.min(measureElement.offsetWidth, measurements.radius - measurements.trackBorderWidth)\n measurements.lineSize = measurements.trackWidth + measurements.trackBorderWidth;\n\n if (that.ticksPosition === 'track') {\n measurements.majorTickSize = measurements.lineSize;\n measurements.minorTickSize = measurements.majorTickSize / 2;\n }\n }\n\n that.removeChild(measureElement);\n }", "title": "" }, { "docid": "7d62094d8c5faf8524772c1daecee8e4", "score": "0.52219737", "text": "resize() {\n\t\t\t\t// defaults to grabbing dimensions from container element\n\t\t\t\tconst normalWidth = $sel.node().offsetWidth; // - marginLeft - marginRight\n\t\t\t\twidth = normalWidth * DPR;\n\t\t\t\tconst normalHeight = $sel.node().offsetHeight; // - marginTop - marginBottom\n\t\t\t\theight = normalHeight * DPR;\n\n\t\t\t\tif (window.innerWidth <= 1152) mobile = true;\n\t\t\t\tconst inner = window.innerWidth;\n\t\t\t\t// console.log({ inner, mobile });\n\n\t\t\t\theightLevels = bpKeys.map(d => (height / DPR) * breakPoints[d]);\n\n\t\t\t\t$svg.attr('width', width / DPR).attr('height', height / DPR);\n\n\t\t\t\t$canvas\n\t\t\t\t\t.attr('width', width)\n\t\t\t\t\t.attr('height', height)\n\t\t\t\t\t.style('width', `${width / DPR}px`)\n\t\t\t\t\t.style('height', `${height / DPR}px`);\n\n\t\t\t\tstopSectionWidth = width * 0.25;\n\n\t\t\t\tif (filter === 'ranked' || filter === 'skipCollege') {\n\t\t\t\t\tscaleX\n\t\t\t\t\t\t.range([marginLeft * DPR, width - marginRight * DPR])\n\t\t\t\t\t\t.domain([1, 100])\n\t\t\t\t\t\t.clamp(true);\n\n\t\t\t\t\tscaleXUnderdogs.range([0, 0]).domain([0, 0]);\n\n\t\t\t\t\tscaleXsvg\n\t\t\t\t\t\t.range([marginLeft, width / DPR - marginRight])\n\t\t\t\t\t\t.domain([1, 100])\n\t\t\t\t\t\t.clamp(true);\n\t\t\t\t} else if (filter === 'top10') {\n\t\t\t\t\tscaleX\n\t\t\t\t\t\t.range([marginLeft * DPR, width - marginRight * DPR])\n\t\t\t\t\t\t.domain([1, 10])\n\t\t\t\t\t\t.clamp(true);\n\n\t\t\t\t\tscaleXUnderdogs.range([0, 0]).domain([0, 0]);\n\n\t\t\t\t\tscaleXsvg\n\t\t\t\t\t\t.range([marginLeft, width / DPR - marginRight])\n\t\t\t\t\t\t.domain([1, 10])\n\t\t\t\t\t\t.clamp(true);\n\t\t\t\t} else {\n\t\t\t\t\tscaleX\n\t\t\t\t\t\t.range([\n\t\t\t\t\t\t\tmarginLeft * DPR,\n\t\t\t\t\t\t\twidth - stopSectionWidth - padding - marginRight * DPR\n\t\t\t\t\t\t])\n\t\t\t\t\t\t.domain([1, 100])\n\t\t\t\t\t\t.clamp(true);\n\n\t\t\t\t\tscaleXUnderdogs\n\t\t\t\t\t\t.range([width - stopSectionWidth, width - marginRight * DPR])\n\t\t\t\t\t\t.domain([0, 1]);\n\n\t\t\t\t\tscaleXsvg\n\t\t\t\t\t\t.range([\n\t\t\t\t\t\t\tmarginLeft,\n\t\t\t\t\t\t\t(width - stopSectionWidth - padding) / DPR - marginRight\n\t\t\t\t\t\t])\n\t\t\t\t\t\t.domain([1, 100])\n\t\t\t\t\t\t.clamp(true);\n\n\t\t\t\t\tscaleXsvgU\n\t\t\t\t\t\t.range([\n\t\t\t\t\t\t\t(width - stopSectionWidth) / DPR,\n\t\t\t\t\t\t\twidth / DPR - marginRight\n\t\t\t\t\t\t])\n\t\t\t\t\t\t.domain([0, 1]);\n\t\t\t\t}\n\n\t\t\t\t$bg\n\t\t\t\t\t.selectAll('.bg-block')\n\t\t\t\t\t.attr('width', (width + marginLeft + marginRight) / DPR)\n\t\t\t\t\t.attr('height', height / DPR - (height / DPR) * breakPoints.rookie)\n\t\t\t\t\t.attr('x', 0)\n\t\t\t\t\t.attr('y', (height / DPR) * breakPoints.bad)\n\t\t\t\t\t.lower()\n\t\t\t\t\t.attr('transform', `translate(${(marginLeft * DPR, 0)})`);\n\n\t\t\t\t$bg\n\t\t\t\t\t.selectAll('text')\n\t\t\t\t\t.attr(\n\t\t\t\t\t\t'transform',\n\t\t\t\t\t\t`translate(${marginLeft / 2}, ${((height / DPR) * 6) /\n\t\t\t\t\t\t\t8})rotate(-90)`\n\t\t\t\t\t)\n\t\t\t\t\t.attr('text-anchor', 'middle');\n\n\t\t\t\trectHeight = height * 0.05;\n\n\t\t\t\t$labels.selectAll('.label').attr('transform', (d, i) => {\n\t\t\t\t\tlet xPos = null;\n\t\t\t\t\tif (\n\t\t\t\t\t\tfilter == 'ranked' ||\n\t\t\t\t\t\tfilter == 'top10' ||\n\t\t\t\t\t\tfilter == 'skipCollege'\n\t\t\t\t\t)\n\t\t\t\t\t\txPos = width / 2 / DPR;\n\t\t\t\t\telse xPos = (width - stopSectionWidth) / 2 / DPR;\n\n\t\t\t\t\treturn `translate(${xPos}, ${(height * breakPoints[d]) / DPR -\n\t\t\t\t\t\trectHeight / 2 / DPR})`;\n\t\t\t\t});\n\n\t\t\t\t$labels.selectAll('.percentage__top').attr('transform', (d, i) => {\n\t\t\t\t\tlet xPos = null;\n\t\t\t\t\tif (\n\t\t\t\t\t\tfilter == 'ranked' ||\n\t\t\t\t\t\tfilter == 'top10' ||\n\t\t\t\t\t\tfilter == 'skipCollege'\n\t\t\t\t\t)\n\t\t\t\t\t\txPos = width / DPR - marginRight;\n\t\t\t\t\telse xPos = (width - stopSectionWidth - padding) / DPR - marginRight;\n\n\t\t\t\t\treturn `translate(${xPos}, ${(height / DPR) * breakPoints[d] -\n\t\t\t\t\t\trectHeight / 2 / DPR})`;\n\t\t\t\t});\n\n\t\t\t\t$labels.selectAll('.count__top').attr('transform', (d, i) => {\n\t\t\t\t\tlet xPos = null;\n\t\t\t\t\tif (\n\t\t\t\t\t\tfilter == 'ranked' ||\n\t\t\t\t\t\tfilter == 'top10' ||\n\t\t\t\t\t\tfilter == 'skipCollege'\n\t\t\t\t\t)\n\t\t\t\t\t\txPos = width / DPR - marginRight;\n\t\t\t\t\telse xPos = (width - stopSectionWidth - padding) / DPR - marginRight;\n\n\t\t\t\t\treturn `translate(${xPos}, ${(height / DPR) * breakPoints[d] +\n\t\t\t\t\t\trectHeight / 2 / DPR})`;\n\t\t\t\t});\n\n\t\t\t\trankAnn.attr(\n\t\t\t\t\t'transform',\n\t\t\t\t\td =>\n\t\t\t\t\t\t`translate(${scaleX(d.rank) / DPR}, ${marginTop +\n\t\t\t\t\t\t\t(height / DPR) * breakPoints.highSchool})`\n\t\t\t\t);\n\n\t\t\t\t// rankAnn.selectAll('line')\n\t\t\t\t// .attr('y1', d => ((height * breakPoints.highSchool) - (rectHeight / 2) + (radius / 2)) / DPR)\n\t\t\t\t// .attr('y2', d => -radius)\n\n\t\t\t\trankAnn\n\t\t\t\t\t.selectAll('text')\n\t\t\t\t\t.attr('transform', `translate(0, ${-(rectHeight / 2 / DPR)})`);\n\n\t\t\t\tif (\n\t\t\t\t\tfilter != 'ranked' &&\n\t\t\t\t\tfilter != 'top10' &&\n\t\t\t\t\tfilter != 'skipCollege'\n\t\t\t\t) {\n\t\t\t\t\tunderdogAnn.attr(\n\t\t\t\t\t\t'transform',\n\t\t\t\t\t\td =>\n\t\t\t\t\t\t\t`translate(0, ${marginTop +\n\t\t\t\t\t\t\t\t(height / DPR) * breakPoints.highSchool})`\n\t\t\t\t\t);\n\n\t\t\t\t\tunderdogAnn\n\t\t\t\t\t\t.selectAll('text')\n\t\t\t\t\t\t.attr(\n\t\t\t\t\t\t\t'transform',\n\t\t\t\t\t\t\td =>\n\t\t\t\t\t\t\t\t`translate(${scaleXUnderdogs(0.5) / DPR}, ${-(rectHeight / 2) /\n\t\t\t\t\t\t\t\t\tDPR})`\n\t\t\t\t\t\t);\n\n\t\t\t\t\t// underdogAnn.selectAll('line').attr('x2', stopSectionWidth - radius)\n\n\t\t\t\t\t$labels\n\t\t\t\t\t\t.selectAll('.percentage__underdog')\n\t\t\t\t\t\t.attr(\n\t\t\t\t\t\t\t'transform',\n\t\t\t\t\t\t\t(d, i) =>\n\t\t\t\t\t\t\t\t`translate(${(width - stopSectionWidth) / DPR}, ${(height *\n\t\t\t\t\t\t\t\t\tbreakPoints[d]) /\n\t\t\t\t\t\t\t\t\tDPR -\n\t\t\t\t\t\t\t\t\trectHeight / 2 / DPR})`\n\t\t\t\t\t\t);\n\n\t\t\t\t\t$labels\n\t\t\t\t\t\t.selectAll('.count__underdog')\n\t\t\t\t\t\t.attr(\n\t\t\t\t\t\t\t'transform',\n\t\t\t\t\t\t\t(d, i) =>\n\t\t\t\t\t\t\t\t`translate(${(width - stopSectionWidth) / DPR}, ${(height *\n\t\t\t\t\t\t\t\t\tbreakPoints[d]) /\n\t\t\t\t\t\t\t\t\tDPR +\n\t\t\t\t\t\t\t\t\trectHeight / 2 / DPR})`\n\t\t\t\t\t\t);\n\t\t\t\t}\n\n\t\t\t\t// setup data for canvas\n\t\t\t\tcircleData.forEach(d => {\n\t\t\t\t\t// const yPos = height * breakPoints[d.highest] + marginTop\n\t\t\t\t\td.y = height * breakPoints[d.highest] + marginTop * DPR;\n\t\t\t\t\td.maxY = d.y;\n\t\t\t\t\td.trans.duration = (d.maxY / height) * duration;\n\t\t\t\t\td.trans.i = d3.interpolate(marginTop * DPR, d.y);\n\n\t\t\t\t\tif (d.trans.delay > maxDelay) {\n\t\t\t\t\t\tmaxDelay = d.trans.delay;\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\tmoveCircles(0);\n\n\t\t\t\treturn Chart;\n\t\t\t}", "title": "" }, { "docid": "0b897ca2006b7111fd6ccb0984cab718", "score": "0.5221235", "text": "get heightmapScale() {}", "title": "" }, { "docid": "d99f8eb336b13aa1db9f955a0d350843", "score": "0.5220507", "text": "sizeCost(){\n this.size(s) = 7.99\n this.size(m) = 9.99\n this.size(l) = 12.99\n this.size(xL) = 15.99\n }", "title": "" } ]
ffa7ce625efa69877b330cb4d071fbcd
! vuerouter v3.1.3 (c) 2019 Evan You
[ { "docid": "33a95e2f8d336fc062200dbbbac06c9c", "score": "0.0", "text": "function i(t,e){0}", "title": "" } ]
[ { "docid": "afe3dd7a2e61842e503b12688db6ec28", "score": "0.59236264", "text": "function jj(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"source.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "650ff554859977bab92401016e1b7806", "score": "0.58901584", "text": "private public function m246() {}", "title": "" }, { "docid": "c6bf5e2fb1950b5a9d63ef3c7d49ff53", "score": "0.58327043", "text": "function TM(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}", "title": "" }, { "docid": "32205a62ce2d081f79c488ff5761ec22", "score": "0.5809691", "text": "function BO(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}", "title": "" }, { "docid": "524924ad25ce0c93fc1226a7d9a23873", "score": "0.5763012", "text": "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}", "title": "" }, { "docid": "44dfde9906fa1c183245d889a94dcfc2", "score": "0.57324106", "text": "private internal function m248() {}", "title": "" }, { "docid": "7979f84dad8207e51e0deade6e04275c", "score": "0.5665764", "text": "function Uk(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "377240f82c753e3a677f03aa56e69ce7", "score": "0.5650607", "text": "function Qw(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"geom.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "4cd6c6a03165fe5fe7afaa584c25e9d1", "score": "0.5647881", "text": "vampireWithName(name) {\n \n }", "title": "" }, { "docid": "6801d3f2760e1e67cd48ecc6ef0b2288", "score": "0.5626382", "text": "function yh(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"graticule.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "969751eccac62b6ac926ef9c3c5577b8", "score": "0.56123155", "text": "function fyv(){\n \n }", "title": "" }, { "docid": "8438b7520452861e3cff0dd67ec34862", "score": "0.560883", "text": "function iP(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"source.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "87ba68c22404f14f983ab256193c0855", "score": "0.56062", "text": "function version(){ return \"0.13.0\" }", "title": "" }, { "docid": "aa17f974551abc513df854077e29cd43", "score": "0.55362046", "text": "function vT(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"layer.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "59ee0cd20a60f3c4e164fe0ae17aae3c", "score": "0.5527801", "text": "function cO(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}", "title": "" }, { "docid": "d697f39d296e1d4579304bbfe3516768", "score": "0.5494741", "text": "function Wx(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"geom.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "f141d518ca89eb4b8698e53e0bb3a22f", "score": "0.5490542", "text": "function ow(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"geom.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "8c896f85656e646e838c96ef54aa014e", "score": "0.546708", "text": "function Ak(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "01554f48fc255ced0a5266393a871a19", "score": "0.5426855", "text": "function Rb(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "8001f78c9cdade50285058da7fd8b089", "score": "0.54206586", "text": "function VI(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"layer.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "7b51bc20e29b89571323a1d20b733292", "score": "0.5414179", "text": "function dp(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"geom.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "f2c59fe5d6363d0fd0613ddaafd330d4", "score": "0.5402503", "text": "function PD(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "358d4ff947caf228f6402fc6b8661935", "score": "0.5401026", "text": "function Ek(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "51f11806d4deca53045566d90db4c05b", "score": "0.54004705", "text": "function jx(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"geom.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "6061ca0f2878e37c5049bd05b4983bf1", "score": "0.53876567", "text": "function Bv(e){let{basename:t,children:n,window:r}=e,l=X.exports.useRef();l.current==null&&(l.current=gv({window:r}));let o=l.current,[i,u]=X.exports.useState({action:o.action,location:o.location});return X.exports.useLayoutEffect(()=>o.listen(u),[o]),X.exports.createElement(Fv,{basename:t,children:n,location:i.location,navigationType:i.action,navigator:o})}", "title": "" }, { "docid": "b33f113b364cb6a949568de25eed0541", "score": "0.5369406", "text": "transient private internal function m185() {}", "title": "" }, { "docid": "02837ad6e893f34d16dccbfd89dc7c66", "score": "0.5357003", "text": "upgrade() {}", "title": "" }, { "docid": "e1fd6370f9dceb24ecc3cd7ebbb8a8e8", "score": "0.534505", "text": "function SigV4Utils() { }", "title": "" }, { "docid": "df3165de138dfcac5bcb53ec8cd20430", "score": "0.5339762", "text": "function hA(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"geom.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.5338454", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "4ae32286f432c8ff3412f150247e5acf", "score": "0.5320311", "text": "function uf(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"layer.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "c14b45db203b359f20baa789ffa661d5", "score": "0.5315383", "text": "function $S(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "5d9e165e18c18f60bae16ce88f1f70b1", "score": "0.53140485", "text": "function comportement (){\n\t }", "title": "" }, { "docid": "0e52dce1ad3fab8aa31e9743d94760b9", "score": "0.52984524", "text": "function Hr(e,t){\"undefined\"!==typeof console&&(console.warn(\"[vue-i18n] \"+e),t&&console.warn(t.stack))}", "title": "" }, { "docid": "978011e2cb9dd2cf19deef860bb439a3", "score": "0.5295384", "text": "updated() {}", "title": "" }, { "docid": "8856138bb6543961d8b7ea6cd1159737", "score": "0.52895856", "text": "added(vrobject){}", "title": "" }, { "docid": "8eebc10081eef4c12f9e871190af2bcf", "score": "0.5280116", "text": "function JV(e,t){\"undefined\"!=typeof console&&(console.warn(\"[vue-i18n] \"+e),t&&console.warn(t.stack))}", "title": "" }, { "docid": "a34b6a2e582f2bbb1938b538a20a02b1", "score": "0.5267468", "text": "function vI(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"style.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "56ac4b701b4da0ccd0ef0d895f400c47", "score": "0.5259367", "text": "function Vt(){this.__data__=[]}", "title": "" }, { "docid": "cf9ce75761cad4941aee8bb5bc575522", "score": "0.5255636", "text": "transient final protected internal function m174() {}", "title": "" }, { "docid": "52b64fbfa48bc95d11ed241ebbfa874b", "score": "0.5240556", "text": "protected internal function m252() {}", "title": "" }, { "docid": "44c2773d4e8ded8ae878626a98656f4f", "score": "0.5222018", "text": "function VO(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};VO.installed||(VO.installed=!0,t.use(i,e),t.use(r,e),t.use(o,e),t.use(a,e),t.use(s,e),t.use(u,e),t.use(l,e),t.use(c,e),t.use(d,e),t.use(h,e),t.use(f,e),t.use(p,e),t.use(m,e),t.use(v,e),t.use(g,e),t.use(_,e),t.use(y,e),t.use(b,e),t.use(x,e),t.use(w,e),t.use(A,e),t.use(M,e),t.use(S,e),t.use(T,e),t.use(k,e),t.use(O,e),t.use(C,e),t.use(L,e),t.use(E,e),t.use(D,e),t.use(j,e),t.use(I,e),t.use(P,e),t.use(Y,e),t.use(F,e),t.use(R,e),t.use(N,e),t.use(B,e),t.use($,e),t.use(z,e),t.use(H,e),t.use(V,e),t.use(G,e))}", "title": "" }, { "docid": "a13b5679efa0326457eefcbcd955f21d", "score": "0.5202134", "text": "static get tag(){return\"hal-9000\"}", "title": "" }, { "docid": "c3c25cf1ec1e29fc7c48de89a7783e78", "score": "0.5182895", "text": "transient protected internal function m189() {}", "title": "" }, { "docid": "09648ea3551a514e00f5e9f2bd315686", "score": "0.518249", "text": "function EN(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"layer.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "db83a8be93f58d2c48a07806e9f53fa0", "score": "0.5163185", "text": "function WD(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"geom.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "4c1ea78d778fc7556b74a417f1e75309", "score": "0.5162381", "text": "function Bevy() {}", "title": "" }, { "docid": "f1600220fb205499b6e70b19797909a4", "score": "0.51562226", "text": "function zC(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"layer.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "70dcfee2e212cbd1ee6541f47f187bd1", "score": "0.51558906", "text": "install(Vue, options) {\n Vue.VERSION = 'v0.0.1';\n\n let userOptions = {...defaultOptions, ...options};\n // console.log(userOptions)\n\n // create a mixin\n Vue.mixin({\n // created() {\n // console.log(Vue.VERSION);\n // },\n\n\n });\n Vue.prototype.$italicHTML = function (text) {\n return '<i>' + text + '</i>';\n }\n Vue.prototype.$boldHTML = function (text) {\n return '<b>' + text + '</b>';\n }\n\n // define a global filter\n Vue.filter('preview', (value) => {\n if (!value) {\n return '';\n }\n return value.substring(0, userOptions.cutoff) + '...';\n })\n\n Vue.filter('localname', (value) => {\n if (!value) {\n return '';\n }\n var ln = value;\n if(value!= undefined){\n if ( value.lastIndexOf(\"#\") != -1) { ln = value.substr(value.lastIndexOf(\"#\")).substr(1)}\n else{ ln = value.substr(value.lastIndexOf(\"/\")).substr(1) }\n ln = ln.length == 0 ? value : ln\n }\n return ln\n })\n\n // add a custom directive\n Vue.directive('focus', {\n // When the bound element is inserted into the DOM...\n inserted: function (el) {\n // Focus the element\n el.focus();\n }\n })\n\n }", "title": "" }, { "docid": "53056a0df3247dcec136b6ef674b6870", "score": "0.5137486", "text": "function iT(t,e,n,i,r,o,a,s){var u=(\"function\"===typeof n?n.options:n)||{};return u.__file=\"layer.vue\",u.render||(u.render=t.render,u.staticRenderFns=t.staticRenderFns,u._compiled=!0,r&&(u.functional=!0)),u._scopeId=i,u}", "title": "" }, { "docid": "68377cbf34c2819c647cc0f38693f277", "score": "0.5121433", "text": "function __vue_normalize__(a,b,c,d,e){var f=(\"function\"==typeof c?c.options:c)||{};// For security concerns, we use only base name in production mode.\nreturn f.__file=\"/Users/hadefication/Packages/vue-chartisan/src/components/Pie.vue\",f.render||(f.render=a.render,f.staticRenderFns=a.staticRenderFns,f._compiled=!0,e&&(f.functional=!0)),f._scopeId=d,f}", "title": "" }, { "docid": "67fb1e0945a420ae9db984ef54bcf3d1", "score": "0.5119545", "text": "transient private protected internal function m182() {}", "title": "" }, { "docid": "f6bc26dff2d3b843c9e5b55439a19285", "score": "0.5114812", "text": "function vinewx(t=\"untitled\",s=!1){return new class{constructor(t,s){this.name=t,this.debug=s,this.isQX=\"undefined\"!=typeof $task,this.isLoon=\"undefined\"!=typeof $loon,this.isSurge=\"undefined\"!=typeof $httpClient&&!this.isLoon,this.isNode=\"function\"==typeof require,this.isJSBox=this.isNode&&\"undefined\"!=typeof $jsbox,this.node=(()=>this.isNode?{request:\"undefined\"!=typeof $request?void 0:require(\"request\"),fs:require(\"fs\")}:null)(),this.cache=this.initCache(),this.log(`INITIAL CACHE:\\n${JSON.stringify(this.cache)}`),Promise.prototype.delay=function(t){return this.then(function(s){return((t,s)=>new Promise(function(e){setTimeout(e.bind(null,s),t)}))(t,s)})}}get(t){return this.isQX?(\"string\"==typeof t&&(t={url:t,method:\"GET\"}),$task.fetch(t)):new Promise((s,e)=>{this.isLoon||this.isSurge?$httpClient.get(t,(t,i,o)=>{t?e(t):s({status:i.status,headers:i.headers,body:o})}):this.node.request(t,(t,i,o)=>{t?e(t):s({...i,status:i.statusCode,body:o})})})}post(t){return this.isQX?(\"string\"==typeof t&&(t={url:t}),t.method=\"POST\",$task.fetch(t)):new Promise((s,e)=>{this.isLoon||this.isSurge?$httpClient.post(t,(t,i,o)=>{t?e(t):s({status:i.status,headers:i.headers,body:o})}):this.node.request.post(t,(t,i,o)=>{t?e(t):s({...i,status:i.statusCode,body:o})})})}initCache(){if(this.isQX)return JSON.parse($prefs.valueForKey(this.name)||\"{}\");if(this.isLoon||this.isSurge)return JSON.parse($persistentStore.read(this.name)||\"{}\");if(this.isNode){const t=`${this.name}.json`;return this.node.fs.existsSync(t)?JSON.parse(this.node.fs.readFileSync(`${this.name}.json`)):(this.node.fs.writeFileSync(t,JSON.stringify({}),{flag:\"wx\"},t=>console.log(t)),{})}}persistCache(){const t=JSON.stringify(this.cache);this.log(`FLUSHING DATA:\\n${t}`),this.isQX&&$prefs.setValueForKey(t,this.name),(this.isLoon||this.isSurge)&&$persistentStore.write(t,this.name),this.isNode&&this.node.fs.writeFileSync(`${this.name}.json`,t,{flag:\"w\"},t=>console.log(t))}write(t,s){this.log(`SET ${s} = ${JSON.stringify(t)}`),this.cache[s]=t,this.persistCache()}read(t){return this.log(`READ ${t} ==> ${JSON.stringify(this.cache[t])}`),this.cache[t]}delete(t){this.log(`DELETE ${t}`),delete this.cache[t],this.persistCache()}notify(t,s,e,i){const o=\"string\"==typeof i?i:void 0,n=e+(null==o?\"\":`\\n${o}`);this.isQX&&(void 0!==o?$notify(t,s,e,{\"open-url\":o}):$notify(t,s,e,i)),this.isSurge&&$notification.post(t,s,n),this.isLoon&&$notification.post(t,s,e),this.isNode&&(this.isJSBox?require(\"push\").schedule({title:t,body:s?s+\"\\n\"+e:e}):console.log(`${t}\\n${s}\\n${n}\\n\\n`))}log(t){this.debug&&console.log(t)}info(t){console.log(t)}error(t){console.log(\"ERROR: \"+t)}wait(t){return new Promise(s=>setTimeout(s,t))}done(t={}){this.isQX||this.isLoon||this.isSurge?$done(t):this.isNode&&!this.isJSBox&&\"undefined\"!=typeof $context&&($context.headers=t.headers,$context.statusCode=t.statusCode,$context.body=t.body)}}(t,s)}", "title": "" }, { "docid": "e8dd8e0a1d10b4c52b65dc069dc3468d", "score": "0.51098806", "text": "function UserGallerie()\n{\n var Video=deserialize(\"Video\",{});\n // Vorschauliste bunt\n var VideoLinks=$x(\"//a[contains(@href,'watch?v=')]\")\n .map(function (a) { return { link:a.href, elem:('user'==Kategorie?$xs(\"ancestor::div[@class='video yt-tile-visible'] | ancestor::li[@class='channels-content-item']\",a):'channel'==Kategorie?$xs('../..',a):a.parentNode)||a }; })\n .map(function (vid) { vid.id=((vid.link||\"\").match(/v=([a-zA-Z0-9-_]*)/)||[\"\",\"\"])[1]; return vid; });\n //alert(uneval(VideoLinks));\n VideoLinks.forEach(function (vid) { if (Video[vid.id]) /*vid.elem.className=\"w\"+Video[vid.id].qualitaet;*/ vid.elem.style.backgroundColor={ \"gut\":\"green\", \"schlecht\":\"red\", undefined:\"yellow\" }[Video[vid.id].qualitaet]; });\n //showmsg({ text:\"aaa\" });\n $x(\"//a[contains(@href,'v=')]\").forEach(function (a) { a.addEventListener(\"click\",function(event){\n //if (event.ctrlKey) // && event.altKey)\n //{\n var e=event.target;\n while (!e || !e.href) e=e.parentNode;\n var VideoID=e.href.match(/v=([a-zA-Z0-9-_]*)/)[1];\n var Video=deserialize(\"Video\",{});\n if (!Video[VideoID])\n {\n Video[VideoID]={ id:VideoID, anz:0, lastseen:new Date() };\n serialize(\"Video\",Video);\n var ColorNode=$xs(\"ancestor::div[@class='video yt-tile-visible'] | ancestor::li[@class='channels-content-item']\",a)||a;\n ColorNode.style.color=\"lightgray\";\n ColorNode.style.backgroundColor=\"darkgray\";\n event.stopPropagation();\n event.preventDefault();\n }\n //}\n }, true); });\n}", "title": "" }, { "docid": "3310c9d05177bd592917f7e295303703", "score": "0.51066446", "text": "ready() {\n window.plugin = new window.Vue( {\n el : this.shadowRoot,\n created() {\n Editor.log( \"成功初始化\" );\n },\n data : {\n uuid : \"bae4f6b4-7d1e-4612-99b7-ab5239576cc1\",\n scriptUrl: \"\",\n uuidObj : {},\n isFind : false,\n isFindAll: true,\n },\n methods: {\n _setOpenUrl() {\n let path = Editor.url( 'db://assets' );\n let files = Editor.Dialog.openFile( {\n defaultPath: path,\n properties : [ 'openDirectory' ]\n } );\n if ( files ) {\n path = files[0];\n }\n this.scriptUrl = path;\n },\n onSelectJSPath() {\n this._setOpenUrl();\n let assetUrl = Editor.remote.assetdb.fspathToUrl( this.scriptUrl );\n if ( this.scriptUrl === assetUrl ) {\n Editor.warn( \"请选择项目目录哦\" );\n return;\n }\n this._analyzeUUIDInfo( assetUrl, \"javascript\" );\n },\n\n onSelectSFPath() {\n this._setOpenUrl();\n let assetUrl = Editor.remote.assetdb.fspathToUrl( this.scriptUrl );\n if ( this.scriptUrl === assetUrl ) {\n Editor.warn( \"请选择项目目录哦\" );\n return;\n }\n this._analyzeUUIDInfo( assetUrl, \"sprite-frame\" );\n },\n\n onSelectFontPath() {\n this._setOpenUrl();\n let assetUrl = Editor.remote.assetdb.fspathToUrl( this.scriptUrl );\n if ( this.scriptUrl === assetUrl ) {\n Editor.warn( \"请选择项目目录哦\" );\n return;\n }\n this._analyzeUUIDInfo( assetUrl, [ \"label-atlas\", \"bitmap-font\" ] );\n },\n\n _analyzeUUIDInfo( url, type ) {\n let self = this;\n self.uuidObj = {};\n Editor.assetdb.queryAssets( url + \"/**/*\", type, function ( err, results ) {\n if ( err ) return;\n let len = results.length;\n for (let i = 0; i < len; i++) {\n let uuid = results[i].uuid;\n if ( type === \"javascript\" ) uuid = Editor.Utils.UuidUtils.compressUuid( results[i].uuid );\n self.uuidObj[uuid] = results[i];\n }\n } );\n },\n onCheckUUID() {\n Editor.log( 'check uuid', this.uuid );\n },\n onFindUUID() {\n // Editor.assetdb.queryUuidByUrl( url, function ( err, uuid ) {\n // Editor.log( \"uuid\", uuid );\n // } );\n if ( this.isFind ) {\n Editor.log( \"正在查找中.........\" );\n return;\n }\n this.isFind = true;\n let self = this;\n let objs = Object.values( this.uuidObj );\n if ( objs.length > 0 ) {\n Editor.log( objs[0].type );\n this._findInfo( objs[0].type, this.uuidObj );\n return;\n }\n if ( !this._isUUID() ) {\n Editor.log( \"uuid 无效\" );\n return;\n }\n let url = Editor.remote.assetdb.uuidToUrl( this.uuid );\n Editor.log( \"开始查找!!!!!!!\", this.uuid, url );\n Editor.assetdb.queryInfoByUuid( this.uuid, function ( err, info ) {\n Editor.log( \"当前查找的文件信息\", info, self.uuid );\n if ( err ) return;\n self._findInfo( info.type );\n } );\n // Editor.assetdb.queryUrlByUuid( this.uuid, function ( err, url ) {\n // Editor.log( \"info1\", url );\n // } );\n },\n _isUUID() {\n let isUUID = Editor.Utils.UuidUtils.isUuid( this.uuid );\n return isUUID;\n },\n\n _findInfo( type, uuidOrObj ) {\n let self = this;\n Editor.log( \"find \" + type );\n if ( type === \"sprite-frame\" || type === \"label-atlas\" || type === \"bitmap-font\" ) {\n Editor.assetdb.queryAssets( \"db://assets/resources/prefab/**/*\", [ 'prefab', 'scene' ], function ( err, results ) {\n Editor.log( \"查找 prefab 文件数量:\", results.length );\n self._analyze( results, type, uuidOrObj || self.uuid );\n } );\n } else if ( type === \"javascript\" ) {\n Editor.assetdb.queryAssets( \"db://assets/resources/prefab/**/*\", [ 'prefab', 'scene' ], function ( err, results ) {\n Editor.log( \"查找 prefab 文件数量:\", results.length );\n let uuid = uuidOrObj || Editor.Utils.UuidUtils.compressUuid( self.uuid );\n self._analyze( results, type, uuid );\n } );\n }\n },\n\n _analyze( list, type, uuidOrObj ) {\n let uuidObj = uuidOrObj;\n if ( typeof uuidOrObj === \"string\" ) {\n uuidObj = { [uuidOrObj]: { uuid: uuidOrObj } };\n }\n let len = Array.isArray( list ) ? list.length : 0;\n let result = \"\";\n for (let i = 0; i < len; i++) {\n let template = Fs.readFileSync( list[i].path, 'utf-8' );\n let json = JSON.parse( template ) || [];\n let num = json.length;\n Editor.log( \"正在查找当前文件:\", list[i].path );\n for (let j = 0; j < num; j++) {\n let obj = json[j];\n if ( !obj ) continue;\n let uObj = null;\n if ( type === \"sprite-frame\" ) {\n uObj = this._getSpriteFrame( obj, uuidObj );\n } else if ( type === \"javascript\" ) {\n uObj = this._getSpriteScript( obj, uuidObj );\n } else if ( type === \"label-atlas\" || type === \"bitmap-font\" ) {\n uObj = this._getSpriteFont( obj, uuidObj );\n }\n if ( !uObj ) continue;\n if ( uObj.isExist && !this.isFindAll ) continue;\n uObj.isExist = true;\n let path = uObj.path ? \"<\" + uObj.path + \">\" : uObj.uuid;\n result = result + path + list[i].path + \"\\n\";\n }\n }\n //查找玩家\n Editor.log( \"----------以下文件暂时没有找到引用---------------\" );\n let values = Object.values( uuidObj );\n let count = values.length;\n let sum = 0;\n for (let i = 0; i < count; i++) {\n if ( values[i].isExist ) continue;\n let path = values[i].path ? values[i].path : values[i].uuid;\n Editor.log( path );\n sum++;\n }\n Editor.log( \"总计有\", sum, \"个类型\", type, \"文件未被引用\" );\n this.uuidObj = {};\n this.isFind = false;\n Editor.log( \"----------查找到以下文件以及在那个预制文件下引用---------------\" );\n Editor.log( result );\n Editor.log( \"----------complete---------------\" );\n },\n _getSpriteFrame( obj, uuidObj ) {\n let result = null;\n do {\n if ( obj[\"__type__\"] !== \"cc.Sprite\" ) break;\n if ( !obj[\"_spriteFrame\"] ) break;\n let uObj = uuidObj[obj[\"_spriteFrame\"][\"__uuid__\"]];\n if ( !uObj ) break;\n result = uObj;\n } while ( 0 );\n return result;\n },\n\n _getSpriteScript( obj, uuidObj ) {\n let result = null;\n do {\n let uObj = uuidObj[obj[\"__type__\"]];\n if ( uObj ) {\n result = uObj;\n break;\n }\n let componentId = obj[\"_componentId\"];\n if ( !componentId ) break;\n uObj = uuidObj[componentId];\n if ( !uObj ) break;\n result = uObj;\n } while ( 0 );\n return result;\n },\n _getSpriteFont( obj, uuidObj ) {\n let result = null;\n do {\n if ( obj[\"__type__\"] !== \"cc.Label\" ) break;\n if ( !obj[\"_N$file\"] ) break;\n let uObj = uuidObj[obj[\"_N$file\"][\"__uuid__\"]];\n if ( !uObj ) break;\n result = uObj;\n } while ( 0 );\n return result;\n },\n }\n } );\n }", "title": "" }, { "docid": "ebbeeae6513372ecac13d0672c33beeb", "score": "0.5104291", "text": "function test_candu_graphs_datastore_vsphere6() {}", "title": "" }, { "docid": "c6cb29f3c6c1ba02e0b0bc577c66ed53", "score": "0.510045", "text": "function Jb(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"style.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "e708f6cc8a6a1a7ffeb560e0c290395d", "score": "0.5096849", "text": "function ea(){}", "title": "" }, { "docid": "22495c668e66b783acc5d3fd2919d29d", "score": "0.5093363", "text": "__previnit(){}", "title": "" }, { "docid": "db981d7cbff3dfdf6c9d6fad19ced32f", "score": "0.50874674", "text": "function Eu(t,e){\"undefined\"!=typeof console&&(console.warn(\"[vue-i18n] \"+t),e&&console.warn(e.stack))}", "title": "" }, { "docid": "4aaf85dd25cedb2f6a990d5a6f2a8246", "score": "0.50813776", "text": "function i(t,e,n){if(o(t,e))return void(t[e]=n);if(t._isVue)return void i(t._data,e,n);var r=t.__ob__;if(!r)return void(t[e]=n);if(r.convert(e,n),r.dep.notify(),r.vms)for(var s=r.vms.length;s--;){var a=r.vms[s];a._proxy(e),a._digest()}return n}", "title": "" }, { "docid": "91658ad5c29c7c638cfc4976e4121502", "score": "0.5067127", "text": "function vB_PHP_Emulator()\n{\n}", "title": "" }, { "docid": "5403238d4184f5632a3765ef78b2a364", "score": "0.5060931", "text": "transient final private internal function m170() {}", "title": "" }, { "docid": "44afcfee1cc19b2204751821e7646734", "score": "0.5060037", "text": "function FP(t,e,n,r,i,o,a,s){var l=(\"function\"===typeof n?n.options:n)||{};return l.__file=\"style.vue\",l.render||(l.render=t.render,l.staticRenderFns=t.staticRenderFns,l._compiled=!0,i&&(l.functional=!0)),l._scopeId=r,l}", "title": "" }, { "docid": "b847d12db3d5c5eb7c351a789c15a163", "score": "0.50599504", "text": "constructor() {\n \n \n \n }", "title": "" } ]
8ddfc76849de73ce2238cf7c11a2030d
render different hearts based on liked state
[ { "docid": "3b98fd05f401711dfb9dd2b32980dc57", "score": "0.64830035", "text": "render() {\n\t\tif(this.state.liked) {\n\t\t\treturn (\n\t\t\t\t<button className=\"like-button liked\" onClick={() => this.handleLike(this.props.url)}>\n\t\t\t\t\t<i className=\"fas fa-heart\"></i>\n\t\t\t\t</button>\n\t\t\t);\n\t\t} else {\n\t\t\treturn (\n\t\t\t\t<button className=\"like-button unliked\" onClick={() => this.handleLike(this.props.url)}>\n\t\t\t\t\t<i className=\"far fa-heart\"></i>\n\t\t\t\t</button>\n\t\t\t);\n\t\t}\n\t}", "title": "" } ]
[ { "docid": "23043991c9ee2201ee7b08bd2a693998", "score": "0.64916956", "text": "function showLikes() {\n numLikes.innerHTML = mediaPhotographer.likes+\"&nbsp\";\n bannerMedia.appendChild(likes);\n likes.appendChild(numLikes);\n likes.appendChild(heartBtn);\n heartBtn.appendChild(heart2);\n }", "title": "" }, { "docid": "18ecdfc4b4d64bb5630b8d5b63c47c3d", "score": "0.6431341", "text": "function like(liked){\n pic.liked= liked;\n //se realizara un if en un solo renglon en el que si me gusto se agregara sino se disminuira\n pic.likes += liked ? 1: -1;\n var newEL= render(pic);\n yo.update(el, newEL);\n return false;\n }", "title": "" }, { "docid": "fb06e3f278ca393f1f7d5f05a6e5426e", "score": "0.64061964", "text": "function renderLikes(likesArray){\n // build our likes HTML\n let likesHTML = `\n <div class=\"content-webmentions--likes\">\n <h4>${likesArray.length} ${likesArray.length === 1 ? ' like' : ' likes'}</h4>\n <ul class='content-webmentions__list no-style'>`;\n\n // map over our likes, build the data object\n likesArray.map(function(l){\n let likeObj = {\n photo: cloudifyPhoto(l.data.author.photo),\n name: l.data.author.name,\n authorUrl: l.data.author.url,\n url: l.data.url,\n date: new Date(l.data.published || l.verified_date)\n }\n\n // create each like\n likesHTML += likeRepostLinkTemplate(likeObj);\n });\n\n // close the like HTML\n likesHTML +=\n ` </ul>\n </div>`;\n\n // append the generated like HTML to the single set of HTML\n webmentionHTML += likesHTML;\n }", "title": "" }, { "docid": "e4393f608056d4ce06303982d976be2b", "score": "0.6099078", "text": "function displayLikes() {\n // remove all children from likesUl\n while (likesUl.firstElementChild) {\n likesUl.removeChild(likesUl.lastElementChild);\n }\n\n // creates li items for numbers with likes and appends them to ul\n likesArray.forEach(function(item) {\n let numberLi = document.createElement(\"li\");\n let liText = document.createTextNode(generateLikeText(item));\n numberLi.appendChild(liText);\n likesUl.appendChild(numberLi);\n });\n }", "title": "" }, { "docid": "97dcae51aa84beeed5ef21e56054576a", "score": "0.5901405", "text": "function displayLikes() {\n var i;\n var likesArr;\n\n // reset everything all likes on the page to LIKE then go back and set the\n // UNLIKE\n const likeElements = document.querySelectorAll('.like');\n console.log(`length: ${likeElements.length}`)\n for (i = 0; i < likeElements.length; i++) {\n likeElements[i].dataset.name='like';\n likeElements[i].innerHTML=`like`;\n }\n\n // fetch the like of current likes for this user (this does not necessarily\n // scale. for larger sites, some sort of partition needs to be considered)\n console.log(`entering -- displayLikes -- function`);\n // get a list of post id's that are currently liked by the logged-in user\n pathAPI = `posts/likes`;\n console.log(`pathAPI = ${pathAPI}`);\n\n fetch(pathAPI)\n .then(response => response.json())\n .then(result => {\n console.log(result),\n likesArr = result.split(','),\n updateUnlike(likesArr)\n });\n}", "title": "" }, { "docid": "63f92f6643db9e25fe23a0d035026338", "score": "0.58839166", "text": "function liked(element){\r\n if (localStorage[element.dataset.skinname] == \"1\"){\r\n //unlike the skin\r\n element.src = \"logos/notliked.png\";\r\n localStorage[element.dataset.skinname] = \"0\";\r\n firebaseUpdate(\"0\",element);\r\n } else {\r\n //like the skin\r\n element.src = \"logos/liked.png\";\r\n localStorage[element.dataset.skinname] = \"1\";\r\n firebaseUpdate(\"1\",element);\r\n }\r\n }", "title": "" }, { "docid": "429804b9c84eb15905810ba722f5bc2a", "score": "0.5883268", "text": "renderChampion(){\n if(this.props.leader.stars){\n return (\n <div style={{marginTop: '8px'}}>\n <img className=\"favimg\" src=\"favorite.png\" alt=\"star\" />\n </div>\n )\n }\n }", "title": "" }, { "docid": "905183dbdd2bb1e9008fc3d8b738273b", "score": "0.58666915", "text": "render() {\n let stars;\n let rating = this.props.review.rating\n if(rating === 1) {\n stars = <div><FaStar className=\"onestar\" /><FaStar className=\"zerostars\" /><FaStar className=\"zerostars\" /><FaStar className=\"zerostars\" /><FaStar className=\"zerostars\" /></div>\n } else if (rating === 2) {\n stars = <div className=\"twostars\"><FaStar /><FaStar /><FaStar className=\"zerostars\" /><FaStar className=\"zerostars\" /><FaStar className=\"zerostars\" /></div>\n } else if (rating === 3) {\n stars = <div className=\"threestars\"><FaStar/><FaStar/><FaStar/><FaStar className=\"zerostars\" /><FaStar className=\"zerostars\" /></div>\n } else if (rating === 4) {\n stars = <div className=\"fourstars\"><FaStar /><FaStar /><FaStar /><FaStar /><FaStar className=\"zerostars\" /></div>\n } else if (rating === 5) {\n stars = <div className=\"fivestars\"><FaStar /><FaStar /><FaStar /><FaStar /><FaStar /></div>\n } else {\n stars = <div className=\"zerostars\"><FaStar /><FaStar /><FaStar /><FaStar /><FaStar /></div>\n }\n\n return (\n <div>\n {stars}\n </div>\n )\n }", "title": "" }, { "docid": "0df0a722eb78e5726f722007568ad4e4", "score": "0.57939553", "text": "renderLikes(id, likes) {\n return fetch((this.serverUrl + this.cohortId + '/cards/like/' + id), {\n method: 'PUT',\n headers: {\n 'authorization': this.authToken,\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({\n likes: likes,\n }),\n })\n .then((resp) => {\n if (resp.ok) {\n return resp.json();\n } else {\n return Promise.reject;\n }\n })\n .catch((err) => console.log('Could not render likes. Reason: ' + err));\n }", "title": "" }, { "docid": "6922489ae50eda8a61c05cc9c40f8400", "score": "0.57917285", "text": "function renderHTML(data) {\n\tvar htmlString = \"\";\n\t\n\tfor(i = 0; i < data.length; i++) {\n\t\thtmlString += \"<p>\" + data[i].name + \" is a \" + data[i].species + \" that likes \";\n\t\t\n\t\tfor(j = 0; j < data[i].foods.likes.length; j++) {\n\t\t\tif(j == 0) {\n\t\t\t\thtmlString += data[i].foods.likes[j];\n\t\t\t} else {\n\t\t\t\thtmlString += \" and \" + data[i].foods.likes[j];;\n\t\t\t}\n\t\t}\n\t\t\n\t\thtmlString += \" and dislikes \";\n\t\t\n\t\tfor(j = 0; j < data[i].foods.dislikes.length; j++) {\n\t\t\tif(j == 0) {\n\t\t\t\thtmlString += data[i].foods.dislikes[j];\n\t\t\t} else {\n\t\t\t\thtmlString += \" and \" + data[i].foods.dislikes[j];;\n\t\t\t}\n\t\t}\n\t\t\n\t\thtmlString += '.</p>';\n\t\t\n\t}\n\tcontainer.insertAdjacentHTML('beforeend', htmlString);\n\t\n}", "title": "" }, { "docid": "d5f920d877c05dd02247ac42b5e468eb", "score": "0.57563883", "text": "function like() {\n const hearts = document.querySelectorAll('div.heart');\n hearts.forEach(heart => {\n heart.addEventListener('click', () => {\n if (heart.classList.contains('is_animating')) {\n heart.classList.remove('is_animating');\n } else {\n heart.classList.add('is_animating')\n }\n });\n });\n}", "title": "" }, { "docid": "4623a91f695e975150377d13ddd88772", "score": "0.57563525", "text": "static showLikeSongList(){\n if(this.isShowSongLikeList){\n this.files = JSON.parse(window.localStorage.getItem('music-files'));\n this.showSongList(this.files);\n this.isShowSongLikeList = false;\n this.song_like_icon.src = 'icon/unlike.svg';\n }else{\n this.files = this.files.filter(f => f.like == true);\n this.showSongList(this.files);\n this.isShowSongLikeList = true;\n this.song_like_icon.src = 'icon/heart_red.svg';\n }\n\n }", "title": "" }, { "docid": "dc98cb4fba1e486ffea8addd0899798b", "score": "0.57399064", "text": "function renderFavourites() {\n $favouritesOne.html(twitOneObj.favourites); //replace this with favourites method\n $favouritesTwo.html(twitTwoObj.favourites);\n $favouritesImg.attr('class', 'icon');\n $favouritesImg.attr('src', 'TFAssets/favourites.png');\n $favLegend.attr('class', 'legend');\n $favLegend.html('favourites');\n}", "title": "" }, { "docid": "3669c09af51aaafb746fd6a5a507bdc0", "score": "0.5734576", "text": "static get properties() { return { liked: Boolean }}", "title": "" }, { "docid": "4a8aa80040da0caefbc628d97b104ac5", "score": "0.57309073", "text": "function displayReviews(results) {\n\n var review_html = \"\";\n\n $.each(results, function(i, obj) {\n review_html += \"<br><h3>\" + obj.summary + \"</h3>\";\n\n // If there's a user logged in, display heart\n if (obj.user) {\n\n // If it's a favorited review, display red heart\n if (obj.favorite) {\n review_html += \"<img src='/static/img/heart.png' class='heart' height='35' width='35' data-review-id=\" + obj.review_id +\">\";\n } else {\n // Otherwise, display empty heart\n review_html += \"<img src='/static/img/heart-empty.jpg' class='heart' height='35' width='35' data-review-id=\" + obj.review_id +\">\";\n }\n }\n review_html += \"<p class='score'>Score: \" + obj.score + \"</p>\";\n review_html += \"<p>\" + obj.review + \"</p><br><hr>\";\n });\n\n // Update the reviews html\n $(\"#reviews\").html(review_html);\n\n // Extract the value of the query and format it\n // so that it can be highlighted in the review\n var query = $(\"#query\").val();\n query = query.trim();\n var words = query.split(' ');\n $(\"#reviews\").highlight(words);\n\n // Must add event handler to new heart elements in DOM\n addHeartClicks();\n\n}", "title": "" }, { "docid": "61ff5e807af114e4b749cd0de35a8f6b", "score": "0.5699465", "text": "render() {\n return (\n <div>\n <Header title=\"THIS IS MY LIKES APP HEADER\" />\n {/* <h1>Welcome to my Likes App</h1> */}\n <h1></h1>\n <h3> Likes: {this.state.likes} </h3>\n\n <button onClick={this.increaseLikes}> Like </button>\n\n <button onClick={this.decreaseLikes}> Unlike </button>\n\n <button onClick={this.resetLikes}> Reset </button>\n <br />\n <Todo />\n </div>\n );\n }", "title": "" }, { "docid": "3f0cc3634581d58e0de203eacac6adbf", "score": "0.56797713", "text": "render(props, state) {\n\n return (\n <div className={classes.postMedia} >\n <img\n src={props.img}\n onDblClick={props.like}/>\n <span\n className={\"icon-heart \" + classes.heartNotVisible}>\n </span>\n </div>\n )\n }", "title": "" }, { "docid": "a14918e56aae1c1d43114c8681a619ef", "score": "0.56656116", "text": "function renderDetails() {\n $(\"#btnAddDislike\").remove(); //Possibly temporary\n var active = getActive(); //Get the active object, be it a collection or the library\n //Basics\n $(\"#detailsAvatar\").attr(\"src\",\"\").css(\"background-image\", \"url('\" + active.data.avatarURL + \"')\"); //Change the big avatar to match the active item's avatar\n $(\"#detailsContent .panelHeader\").html(active.data.title); //Change the header text\n $(\"#detailsContent #description\").html(active.data.description); //Change the description text\n\n //Likes/Dislikes\n var likes = active.data.paradata.likes; \n var dislikes = active.data.paradata.dislikes;\n var max = likes + dislikes;\n var likePercent = \"100%\"; //Setting these initial values saves time later...\n var dislikePercent = \"0%\";\n if (max > 0) { //...namely because you only have to bother with calculations if there are actually any ratings to consider \n likePercent = ((likes / max) * 100) + \"%\";\n dislikePercent = ((dislikes / max) * 100) + \"%\";\n }\n $(\"#likeBar\").css(\"width\", likePercent); //The rest of this just fiddles with the CSS and displayed text for presenting the like/dislike bar\n $(\"#dislikeBar\").css(\"width\", dislikePercent);\n $(\"#likeText\").html(likes);\n $(\"#dislikeText\").html(dislikes);\n $(\"#likeBar, #dislikeBar\").removeClass(\"full\");\n if (likePercent == \"100%\") { $(\"#likeBar\").addClass(\"full\"); }\n if (dislikePercent == \"100%\") { $(\"#dislikeBar\").addClass(\"full\"); }\n\n if (userGUID != \"\") {\n if (active.data.paradata.iLikeThis) {\n $(\"#btnAddLike, #btnAddDislike\").hide();\n $(\"#likeDislikeText\").show().html(\"You like this \" + (active.isLibrary ? \"Library\" : \"Collection\") + \".\");\n }\n else if (active.data.paradata.iDislikeThis) {\n $(\"#btnAddLike, #btnAddDislike\").hide();\n $(\"#likeDislikeText\").show().html(\"You dislike this \" + (active.isLibrary ? \"Library\" : \"Collection\") + \".\");\n }\n else {\n $(\"#btnAddLike, #btnAddDislike\").show();\n $(\"#likeDislikeText\").hide().html(\"\");\n }\n }\n else {\n $(\"#opinionButtons\").html(\"<p class=\\\"middle\\\">Please login to Like or Dislike this Library.</p>\");\n }\n}", "title": "" }, { "docid": "3cf5ade2ad6ed9ab5307df9139876015", "score": "0.5652934", "text": "function comCardPics (user, comment) {\n if (comment.likedBy.length > 0){\n // if the logged user's id is on the array of liked comments, render liked button\n for (let i in comment.likedBy){\n if (comment.likedBy[i] === user._id){\n return yo`<span id=\"new-card-liked\" data-comment=\"${comment._id}\" class=\"Noticias_comentarios_card-feedback-like-icon-liked\"></span>`\n }\n }\n }\n // otherwise return non liked button\n return yo`<span id=\"new-card\" data-comment=\"${comment._id}\" class=\"Noticias_comentarios_card-feedback-like-icon\"></span>`\n}", "title": "" }, { "docid": "fbcc05c76a5bc1c8bdb744fa22ceb3b5", "score": "0.56401056", "text": "function LikeButton({thing}){\n const dispatch = useDispatch()\n let isLiked = useSelector(st => st.users.liked)\n let liked = false\n\n const handleFavorite = () => {\n if(liked) dispatch(unlike_model(thing))\n else dispatch(like_model(thing))\n }\n\n const likes = (\n <div className='numLikes'>\n {thing.like_count}\n </div>\n )\n \n if(isLiked=== undefined || isLiked.length === 0) return (<Button className='favorite-button' onClick={handleFavorite}><FavoriteBorderIcon/>{likes}</Button>);\n\n const items = isLiked.filter(item => item.id === thing.id)\n\n if(items.length === 0)return (<Button className='favorite-button' onClick={handleFavorite}><FavoriteBorderIcon/>{likes}</Button>);\n \n liked = true\n return (<Button className='favorite-button' onClick={handleFavorite}><FavoriteIcon style={{color:'red'}}/>{likes}</Button>)\n \n}", "title": "" }, { "docid": "24610c442a9b3d8c134727a105f44bf7", "score": "0.5614009", "text": "render() {\n\t\treturn (\n\t\t\t<button onClick={this.onClick.bind(this)}>{this.state.liked ? 'Unlike' : 'Like'} {this.state.numberOfLikes}</button>\n\t\t)\n\t}", "title": "" }, { "docid": "087fcc444e99c48dd52091b612e02a92", "score": "0.56109726", "text": "function leftLives(n){\n switch(n){\n case 2:\n document.getElementById('heart1').style.visibility = 'hidden'; \n break;\n case 1:\n document.getElementById('heart2').style.visibility = 'hidden'; \n break;\n case 0:\n document.getElementById('heart3').style.visibility = 'hidden';\n break; \n }\n }", "title": "" }, { "docid": "67f94083b15b3c87ed5f4311abd7d176", "score": "0.5591781", "text": "function generateLikeText(item) {\n if (item.likes == 1) {\n return `${item.id} has 1 like.`;\n } \n else {\n return `${item.id} has ${item.likes} likes.`;\n }\n }", "title": "" }, { "docid": "70701b4f96c21e4ca88e916313eb976e", "score": "0.5586841", "text": "function addHearts() {\n\t\t$(\"#heartsLeft\").empty();\n\t\tfor(let i = 0; i < heartsLeft; i++) {\n\t\t\t$(\"#heartsLeft\").append(' <img src=\"images/heart.png\" class=\"hearts\"> ');\n\t\t}\n\t}", "title": "" }, { "docid": "9dd70f0a32a5c3e0f65d9ef8fe897b7f", "score": "0.55823916", "text": "function handleLikes(counter, total){\n const likesList = document.querySelector('.likes')\n const listElement = document.createElement('li')\n const count = parseInt((counter.textContent),10)\n const msg = `${count} was favorited ${total} times`\n\n if(total === 1){\n listElement.textContent = msg\n likesList.appendChild(listElement)\n }else{\n likesList.lastElementChild.textContent = msg\n }\n}", "title": "" }, { "docid": "b800d0016551c6e10164ef369325b601", "score": "0.5580742", "text": "function displayLikes(){\n\n counterForLikes = parseInt(counterForLikes) + parseInt(1);\n\n var showCountDiv = document.getElementById(\"showCount\");\n var likeButton = document.getElementById(\"likeButton\");\n\n likeButton1.innerHTML = \"<i class=\"+\"fa fa-thumbs-up\"+\"></i><span id=\"+\"likeButton\"+\">Liked</span>\";\n\n if(counterForLikes == 1) {\n showCountDiv.innerHTML= counterForLikes +\" person likes this !\";\n }\n else {\n showCountDiv.innerHTML= counterForLikes +\" people like this !\";\n }\n\n}", "title": "" }, { "docid": "f7471fb721ac25fa028014bea7e3a7a2", "score": "0.55732614", "text": "function likeClickability() {\n // select all hearts\n const likeGlyphs = document.querySelectorAll(\".like-glyph\")\n // make each heart clickable\n likeGlyphs.forEach(likeHeart => likeHeart.addEventListener(\"click\", postLikeToggle))\n}", "title": "" }, { "docid": "ae814d2df78fb29c20c380fdff625145", "score": "0.5569054", "text": "function LikesGalleryPage() {\n const dispatch = useDispatch();\n const history = useHistory();\n const params = useParams();\n const classes = useStyles();\n const [spacing, setSpacing] = React.useState(2);\n // Grabs information from Global Redex Store\n const user = useSelector(store => store.user);\n const artworkList = useSelector(store => store.artwork);\n\n // Loads all artwork that the user likes\n useEffect(() => {\n dispatch({\n type: 'FETCH_LIKE_ARTWORK',\n payload: {\n userId: user.id\n },\n });\n }, []);\n\n// // Function called once details button is clicked\n// // Brings user to My Artwork Details Page\n// const artworkDetails = (artworkid) => {\n// history.push(`/mydetails/${artworkid}`);\n// };\n\n// Function to unlike an artwork once Unlike button is clicked\nconst unlikeArtwork = (artworkid) => {\n dispatch({\n type: 'UNLIKE_ARTWORK',\n payload: {\n artworkId: artworkid,\n userId: user.id,\n }\n });\n};\n\n return(\n <div>\n <main>\n <Box align=\"center\">\n <Box width=\"60%\" border={1} borderRadius={16} className=\"profileCard\">\n <Typography variant=\"h3\">\n <Box align=\"center\" lineHeight={2} fontWeight=\"fontWeightBold\">\n Likes Galore!\n </Box>\n </Typography>\n\n <Typography variant=\"body1\">\n <Box align=\"center\" lineHeight={2} fontWeight=\"fontWeightBold\">\n Here are your liked Artworks!\n </Box>\n </Typography>\n </Box>\n </Box>\n\n {/* <h1>Likes Galore!</h1>\n <section className=\"artwork\"> */}\n\n <Grid container className={classes.root} spacing={2}>\n <Grid item xs={12}>\n <Grid container justify=\"center\" spacing={spacing}>\n {\n // Displays either users likes or if \n // there are not likes, a message\n (artworkList && artworkList.length)?\n <> \n {/* <h2>Here are your liked Artworks!</h2> */}\n { \n artworkList.map((artwork, i) => {\n return (\n <Grid\n className=\"artworkCard\"\n >\n <br></br>\n <Typography align=\"center\" variant=\"h5\">{artwork.title}</Typography>\n <br></br>\n <img src={artwork.image} alt={artwork.title} className={classes.img}\n onClick={() => history.push(`/details/${artwork.id}`)}/>\n <br></br>\n <Box align=\"center\">\n <Button variant=\"contained\" color=\"secondary\" onClick = { (evt) => {unlikeArtwork(artwork.id)}}>\n <Typography variant=\"body1\">\n Unlike\n </Typography>\n </Button>\n </Box>\n <br></br>\n </Grid>\n\n // <>\n // <div className=\"artworkdiv\" key = {i}>\n // <img src={artwork.image} height=\"350px\" weight = \"250px \"alt={artwork.description} \n // onClick={() => history.push(`/details/${artwork.id}`)}/>\n // </div>\n\n // {/* Displays artwork title */}\n // <div>\n // <h3>{artwork.title}</h3>\n // </div>\n\n \n // <div>\n // {/* Button that calls unlikeArtwork function to \n // remove artwork from likes table in database */}\n // <button onClick = { (evt) => {unlikeArtwork(artwork.id)}}>\n // Unlike\n // </button>\n // </div>\n // </>\n );\n })\n }\n </>\n :\n // Display message if user has no liked artworks\n <>\n <h3>You Have Not Liked Any Artworks Yet!</h3>\n </>\n }\n </Grid>\n </Grid>\n </Grid>\n {/* </section> */}\n </main>\n </div>\n );\n}", "title": "" }, { "docid": "9076fbc2275f0071676fd6bbb41f369b", "score": "0.55639774", "text": "render() {\n return (\n <div className={style[\"favorite-wrapper\"]}>\n <div className={style[\"image-wrapper\"]}>\n <img src={this.props.image} alt=\"image service\"/>\n </div>\n <h3 className={style[\"header-service\"]}>{this.props.title}</h3>\n <button className={style[\"dislike-button\"]}\n onClick={this.props.event}\n >Dislike</button>\n </div>\n )\n }", "title": "" }, { "docid": "456ae84ece89db966e68b240c0d96d69", "score": "0.55571777", "text": "function toggleLike(likeObj) {\n\n // let's find out if the user is liking or unliking with post then send\n // the correct params to the fetch\n var current_state;\n var next_state;\n\n if (likeObj.dataset.name.trim().toLowerCase() ===\"like\") {\n updateLike(likeObj.dataset.postid, 1);\n next_state = \"unlike\";\n } else {\n updateLike(likeObj.dataset.postid, 0);\n next_state = \"like\";\n }\n\n likeObj.dataset.name = next_state;\n likeObj.innerHTML = next_state.toUpperCase();\n}", "title": "" }, { "docid": "9a094dfe288dedaf3c97d232dd8fa139", "score": "0.5541638", "text": "function renderMainHike() {\n var hikeName = sortedHikesArr[0].name;\n var hikeRating = sortedHikesArr[0].rating;\n var hikeLength = sortedHikesArr[0].length;\n var hikeElev = sortedHikesArr[0].elevGain;\n var hikeURL = 'http://www.wta.org/go-hiking/hikes/' + sortedHikesArr[0].id;\n\n var mainHikeList = document.getElementById('main-hike-ul');\n var liEl = document.createElement('li');\n liEl.textContent = 'Hike Name: ' + hikeName;\n mainHikeList.appendChild(liEl);\n\n liEl = document.createElement('li');\n liEl.textContent = 'Rating: ' + hikeRating;\n mainHikeList.appendChild(liEl);\n\n liEl = document.createElement('li');\n liEl.textContent = 'Length: ' + hikeLength + ' miles';\n mainHikeList.appendChild(liEl);\n\n liEl = document.createElement('li');\n liEl.textContent = 'Elevation Gain: ' + hikeElev + ' ft.';\n mainHikeList.appendChild(liEl);\n\n liEl = document.createElement('li');\n liEl.innerHTML = 'Read more on the WTA Website: <span><a href=\"' + hikeURL + '\" target=\"_blank\">' + hikeURL + '</span></a>';\n mainHikeList.appendChild(liEl);\n}", "title": "" }, { "docid": "9fad57355b373825d517cceba1653615", "score": "0.5537084", "text": "render() {\n return (\n <div>\n <img src={this.props.meme} />\n <button\n onClick={() => this.setState({likes: this.state.likes + 1})}\n >\n Likes{this.state.likes}\n </button>\n <button\n onClick={() => this.setState({disLikes: this.state.disLikes + 1})}\n >\n Dislikes{this.state.disLikes}\n </button>\n </div>\n )\n }", "title": "" }, { "docid": "755137829a0bff290e206ca36153f272", "score": "0.55359244", "text": "function paintFavoriteShows(){let t=\"\";for(const e of favoritesTvShows)t+=`<li class=\"main__aside--container__list--item js_fav_show\" id=\"${e.show.id}\">`,t+='<div class=\"main__aside--container__list--item__container\">',null==e.show.image?t+=`<img class=\"main__aside--container__list--item__image\" src=\"https://via.placeholder.com/210x295/ffffff/666666/?text=TV\" alt=\"${e.show.name}\">`:t+=`<img class=\"main__aside--container__list--item__image\" src=\"${e.show.image.medium}\" alt=\"${e.show.name}\">`,t+=`<h3>${e.show.name}</h3>`,t+='<input type=\"button\" class=\"js_fav_button fav_button>\"',t+=\"</div>\",favoriteSidebar.innerHTML=t}", "title": "" }, { "docid": "24d650a6f1521aa79d792a487bf55744", "score": "0.5523297", "text": "showSideBarRecommendItem(anime) {\n let result = [];\n if (anime.length > 0) {\n //Ham random cho ra mot so ngau nhien phai lon hon 5 vi moi lan lay ra 5 item\n let rand = Math.floor(Math.random() * (anime.length - 5)) + 5;\n\n // lap ra 5 item tu so ngau nhien\n for (let index = rand; index > rand - 5; index--) {\n\n if (anime[index] === undefined) { // neu co ket qua undefined lap tuc return\n return result;\n }\n\n result.push(<SideBarRecommendItem item={anime[index]} key={index} />);\n }\n } else { // Chua tai xong du lieu thi load phan nay\n for (let index = 0; index < 5; index++) {\n result.push(<SideBarRecommendItem loading={\"loading\"} key={index} />);\n }\n }\n return result;\n }", "title": "" }, { "docid": "278159844b9afe7610273f6d92ec170e", "score": "0.54910743", "text": "showHikeList() {\n const hikeListElement = document.getElementById(\"hikes\");\n const commentParent = document.getElementById(\"comments\");\n hikeListElement.innerHTML = \"\";\n this.renderHikeList(hikeList, hikeListElement);\n comments.renderCommentList(commentList, commentParent)\n }", "title": "" }, { "docid": "902bf512c1c4e3befe906ee241ddde7a", "score": "0.54857945", "text": "function renderFavoriteList() {\n\tconst myList = document.createElement('ol');\n\tObject.values(favorites).forEach((fav) => {\n\t\tconst favHTML = generateFavoriteItemHTML(fav);\n\t\tmyList.innerHTML += favHTML;\n\t});\n\tfavList.append(myList);\n}", "title": "" }, { "docid": "4d85ab1683b48512300a7f4a0264dab8", "score": "0.547124", "text": "like(event) {\n event.target.style.outline = 'none';\n\n const findMyLike = (obj) => {\n if (obj._id === this.myId) {\n return true;\n }\n }\n\n if (!event.target.classList.contains('place-card__like-icon_liked')) {\n event.target.classList.add('place-card__like-icon_liked');\n event.target.firstChild.textContent++;\n this.likes.push(1);\n this.api.renderLikes(this.id, this.likes);\n } else {\n event.target.classList.remove('place-card__like-icon_liked');\n event.target.firstChild.textContent--;\n const myLikeIndex = this.likes.findIndex(findMyLike);\n this.likes.splice(myLikeIndex, 1);\n this.api.unlikeCard(this.id);\n }\n }", "title": "" }, { "docid": "98d30cf15cf2b959898c131367f217fc", "score": "0.5470791", "text": "function passTheLikeButton() {\r\n (function(){\r\n\r\n var myDiv = document.getElementById(\"likeLoader\");\r\n\r\n var show = function(){\r\n myDiv.style.display = \"block\";\r\n setTimeout(hide, 1000); // 5 seconds\r\n }\r\n\r\n var hide = function(){\r\n myDiv.style.display = \"none\";\r\n }\r\n\r\n show();\r\n\r\n /*function hasClass(element, cls) {\r\n return (' ' + element.className + ' ').indexOf(' ' + cls + ' ') > -1;\r\n }\r\n var test = document.getElementById(\"like-status\"),\r\n classes = ['like-btn', 'like-h'];\r\n\r\n // test.innerHTML = \"\";\r\n\r\n\r\n if(hasClass(test, 'like-h')) {\r\n document.getElementById(\"msg-already-liked\").style.display = \"block\";\r\n function hideNote(){\r\n document.getElementById(\"msg-already-liked\").style.display = \"none\";\r\n }\r\n setTimeout(hideNote,1000);\r\n }\r\n else\r\n { */\r\n //Changes the information on the likeers status in real time.\r\n var likeCount = document.getElementById(\"likeCount\").innerHTML;\r\n var dislikeCount = document.getElementById(\"dislikeCount\").innerHTML;\r\n var likeCountInteger = parseInt(likeCount);\r\n var dislikeCountInterger = parseInt(dislikeCount);\r\n likeCountInteger = likeCountInteger + 1;\r\n var totalCount = likeCountInteger + dislikeCountInterger;\r\n var totalLikes = likeCountInteger/totalCount * 100;\r\n //alert(totalLikes);\r\n //var totalKireKhar = totalLikes * 100;\r\n //alert(totalKireKhar);\r\n document.getElementById(\"likeCount\").innerHTML = likeCount;\r\n document.getElementById(\"greenLine\").style.width = totalLikes + \"%\";\r\n document.getElementById(\"redLine\").style.width = 100 - totalLikes + \"%\";\r\n document.getElementById(\"likeCount\").innerHTML = likeCountInteger.toString();\r\n document.getElementById(\"totalCount\").innerHTML = likeCountInteger.toString();\r\n\r\n //}\r\n\r\n\r\n\r\n })();\r\n\r\n\r\n $(function () {\r\n\r\n var songID = $(\"#set-next-song-id\").text();\r\n var userName = getUserID();\r\n console.log(\"Song ID: \" + userName);\r\n\r\n // $('.like-btn').click(function(){\r\n var json = {\"songid\": songID, \"userName\": userName};\r\n //alert( json );\r\n $('.dislike-btn').removeClass('dislike-h');\r\n $('.like-btn').addClass('like-h');\r\n //Call back function to call callLikeAjax when like is clicked\r\n callLikeAjax(json);\r\n // });\r\n\r\n\r\n /*$('.dislike-btn').click(function(){\r\n var json ={ \"act\" : \"dislike\", \"songid\" : songID , \"userid\" : userID };\r\n $('.like-btn').removeClass('like-h');\r\n $(this).addClass('dislike-h');\r\n $.ajax({\r\n type:\"POST\",\r\n url:\"ajax.php\",\r\n data:JSON.stringify(json),\r\n success: function(){\r\n }\r\n });\r\n });*/\r\n\r\n $('.share-btn').click(function () {\r\n $('.share-cnt').toggle();\r\n });\r\n });\r\n\r\n function callLikeAjax(json) {\r\n\r\n\r\n $.ajax({\r\n type: \"POST\",\r\n url: \"/userLikesSong.ajax\",\r\n data: JSON.stringify(json),\r\n cache: false,\r\n //onLoading:jQuery(\"#ajaxLoader\").attr('src', 'images/Hypercube_Large_Light.gif'),\r\n\r\n\r\n beforeSend: function (xhr) {\r\n xhr.setRequestHeader(\"Accept\", \"application/json\");\r\n xhr.setRequestHeader(\"Content-Type\", \"application/json\");\r\n },\r\n success: function () {\r\n //(\"#ajaxLoader\").hide();\r\n\r\n },\r\n error: function (jqXhr, textStatus, errorThrown) {\r\n console.log(\"error\", arguments);\r\n }\r\n\r\n });\r\n\r\n }\r\n\r\n}", "title": "" }, { "docid": "f52c68c9ab05f5dcafb150674c2108ef", "score": "0.54528207", "text": "function displayLife(){\n for (let i=0; i<characterLife; i++){\n image(heart, 10 + i*30, 10, 20, 20);\n }\n \n if (characterLife === 0){\n bk.filter(GRAY); \n textAlign(CENTER, CENTER);\n textSize(30);\n textFont(pixleFont);\n fill(\"white\");\n text(\"You are too tired to hunt today.\", width/2, height/2);\n }\n \n if (meatNumber === 1){ \n textAlign(CENTER, CENTER);\n textSize(30);\n textFont(pixleFont);\n fill(\"white\");\n text(\"Now you have enough meat to go home.\", width/2, height/2);\n textSize(10);\n textFont(\"Helvetica\");\n text(\"To be continue...\", width/2 , height/2 + 20);\n }\n}", "title": "" }, { "docid": "2610f376eb201cec66292fd1cc3ea5ce", "score": "0.5449422", "text": "function paintFavorites() {\n let html = \"\";\n for (let i = 0; i < favoritesList.length; i++) {\n html += `<li class=\"favorite-list\">`;\n html += `<div class=\"favorite-list__container\">`;\n if (favoritesList[i].image === null) {\n html += `<img src=\"https://via.placeholder.com/210x295/ffffff/666666/?\n text=TV.\" alt=\"no existe imagen de la serie\" class=\"favorite-list__container--img\">`;\n } else {\n html += `<img src=\"${\n favoritesList[i].image.medium || favoritesList[i].image.original\n }\" alt=\"imagen de la serie ${\n favoritesList[i].name\n }\" class=\"favorite-list__container--img\" title=\"cartel de ${\n favoritesList[i].name\n }\">`;\n }\n html += `</div>`;\n html += `<h4 = class=\"favorite-list__title\">${favoritesList[i].name}</h4>`;\n html += `<i class=\"fas fa-times-circle favorite-list__icon js-favorite-item\" id=\"${favoritesList[i].id}\"></i>`;\n }\n listFavorite.innerHTML = html;\n listenFavorites();\n}", "title": "" }, { "docid": "873c511f79e19243920133c10bd3a043", "score": "0.54452", "text": "function getFavHTML(story) {\n const isFav = currentUser.isFavorite(story);\n const starType = isFav ? \"fas\" : \"far\";\n const hoverText = isFav ? \"remove from favorites\" : \"add to favorites\";\n \n return `\n <small class=\"star\" title=\"${hoverText}\">\n <i class=\"fa-star ${starType}\" aria-hidden=\"true\"></i>\n </small>\n `\n}", "title": "" }, { "docid": "21b211f4c80563ea3007daa247a4d6c9", "score": "0.5444075", "text": "get liked() {\n return this._liked;\n }", "title": "" }, { "docid": "af005ffb25c7add5dae9a4d3a119a70e", "score": "0.54407", "text": "static like() {\n // add style to the like icon and font\n document.querySelector('.like i').style.color = '#2078f4';\n document.querySelector('.like span').style.color = '#2078f4';\n // initiate like sound \n UI.likeSound();\n }", "title": "" }, { "docid": "735a6176757d83d74f938912539e8e23", "score": "0.5408232", "text": "function render() {\n\n for (var h=0;h<totalHearts;h++){\n \n var p = (Math.floor(h/6)+h)%2;\n if (p===0) {\n hearts[h].rotation.y+=0.025;\n } else if (p===1) {\n hearts[h].rotation.x-=0.025;\n }\n }\n\n // actually display the scene in the Dom element\n renderer.render( scene, camera );\n}", "title": "" }, { "docid": "fe19e70a1ef29171c5cd26a1ca19041f", "score": "0.53973943", "text": "function showStarHTML(story) {\n const starType = isFavorite(story) ? \"fas\" : \"far\";\n return `\n <span>\n <i class=\"${starType} fa-star\"></i>\n </span>`;\n}", "title": "" }, { "docid": "091c505f02b197764fb848a80bc34a95", "score": "0.5386777", "text": "function PhotoCard(props) {\n // useState returns an array.\n // The first item is the current value\n // The second item is a function that can update value\n const state = useState(0);\n const count = state[0];\n const setCount = state[1];\n const setUnlike = state[1];\n // The inital 0 is ignored after the first time\n // that the PhotoCard function is called.\n\n console.log(props);\n // add \"conditional rendering\"\n return (\n <div className=\"card-frame\">\n <button onClick={\n (e) => {\n console.log('omg a click!');\n console.log('yeahhhh');\n \n setCount(count + 1);\n console.log(count);\n }\n }>Like {count ? count : null} </button>\n\n <button onClick={\n (e) => {\n \n //setCount(count - 1);\n console.log('dislike');\n setUnlike(unlike +1)\n }\n }>dislike</button>\n\n <p>likes: {count} </p> <p>dislike: {unlike} </p>\n\n { props.title ? <h3>{props.title}</h3> : <h3>untitled</h3>}\n <img src={props.url} alt={props.description} />\n <p>{props.description}</p>\n </div>\n );\n}", "title": "" }, { "docid": "5b00e9bf3140f73195da64108b212f15", "score": "0.53775495", "text": "function renderHTML(data) {\n var htmlString = \"\";\n for (i = 0; i < data.length; i++){\n htmlString += \"<p>\" + data[i].name + \" is a \" + data[i].species + \" that likes to eat \";\n for (ii = 0; ii < data[i].foods.likes.length; ii++) {\n if (ii == 0){\n htmlString += data[i].foods.likes[ii];\n } else {\n htmlString += \" and \" + data[i].foods.likes[ii];\n }\n }\n\n htmlString += ' and dislikes ';\n for (ii = 0; ii < data[i].foods.dislikes.length; ii++) {\n if (ii == 0){\n htmlString += data[i].foods.dislikes[ii];\n } else {\n htmlString += \" and \" + data[i].foods.dislikes[ii];\n }\n }\n htmlString += '.</p>';\n }\n output.insertAdjacentHTML('beforeend', htmlString);\n console.log(htmlString);\n}", "title": "" }, { "docid": "bb8b8dce76ad35e5c4b48b6b246e8164", "score": "0.53768307", "text": "function countDislikes() {\n livros[index - 1].dislikes++;\n getInfo();\n getMoreBooks();\n}", "title": "" }, { "docid": "d47f33fe287b28a3b1a777e6be49d45b", "score": "0.5372842", "text": "renderStars(ratingsArray) {\n let outputArray = [];\n let numStars = 0;\n let sum = 0;\n for (let i = 0; i < ratingsArray.length; i++) {\n sum += parseFloat(ratingsArray[i]);\n }\n let rating = sum.toFixed(2) / ratingsArray.length;\n // this loop renders all initial full stars\n while (rating / 1 > 1) {\n outputArray.push(<img key={numStars.toString()} className={styles.star} src='https://s3-us-west-1.amazonaws.com/fec-reviews/star.svg' />);\n rating -= 1;\n numStars += 1;\n }\n // this conditional chain renders either an empty, half, or full start depending on decimal\n if (rating > 0.75) {\n outputArray.push(<img key={numStars.toString()} className={styles.star} src='https://s3-us-west-1.amazonaws.com/fec-reviews/star.svg' />);\n numStars += 1;\n } else if (rating > 0.25) {\n outputArray.push(<img key={numStars.toString()} className={styles.star} src='https://s3-us-west-1.amazonaws.com/fec-reviews/star-half.svg' />);\n numStars += 1;\n } else {\n outputArray.push(<img key={numStars.toString()} className={styles.star} src='https://s3-us-west-1.amazonaws.com/fec-reviews/star-clear.svg' />);\n numStars += 1;\n }\n // this renders remaining empty stars when necessary\n while (numStars < 5) {\n outputArray.push(<img key={numStars.toString()} className={styles.star} src='https://s3-us-west-1.amazonaws.com/fec-reviews/star-clear.svg' />);\n numStars += 1;\n }\n return outputArray;\n }", "title": "" }, { "docid": "cf9001fd4265ce43e31f84e5fa097a6f", "score": "0.5359743", "text": "_getLikes() {\n this._likeAmount.textContent = this.data.likes.length;\n this._likes.forEach((item) => {\n if (item._id === this._currentUser._id) {\n this._likeButton.classList.add(\"place__like-button_enable\");\n }\n });\n }", "title": "" }, { "docid": "0a3803969c2040b0f21040cd132582b5", "score": "0.5354719", "text": "render() {\n const isThereWinner = this.winner();\n return (\n <Wrap>\n <Title>Kardashian Jenner West Memory Game!\n {isThereWinner}\n <p>Score:{this.state.score}</p>\n </Title>\n\n {this.state.family.map(family => (\n <JusticeCard\n shufflefamily={this.shufflefamily}\n id={family.id}\n key={family.id}\n image={family.image}\n />\n ))}\n </Wrap>\n );\n }", "title": "" }, { "docid": "72cc3ae43d4ed84a7fdc08b3c0297da0", "score": "0.5343456", "text": "function onLike() {\n setLoading(true); // Start loading (disable button)\n if (liked) {\n // If the user clicks a liked song, unlike the song\n // Delete row in UserSong\n Client.delete(\n `/user_song?userIdQuery=${userId}&songIdQuery=${song.song_id}`\n )\n .then((res) => {\n // Set button to unliked, loading false\n setLiked(false);\n setLoading(false);\n\n // Send success toast\n toast({\n title: 'song removed',\n description: `${song.name} has been removed from your likes.`,\n status: 'info',\n isClosable: true,\n });\n })\n .catch((error) => {\n setLoading(false);\n sendErrorToast();\n });\n } else {\n // If the user clicks an unliked song, like the song\n // Create row in UserArtist\n Client.post(`/user_song`, {\n user_id: userId,\n song_id: song.song_id,\n })\n .then((res) => {\n // Set button to be liked, loading false\n setLiked(true);\n setLoading(false);\n\n // Send toast\n toast({\n title: 'Song added',\n description: `${song.name} has been added to your likes.`,\n status: 'success',\n isClosable: true,\n });\n })\n .catch((error) => {\n setLoading(false);\n sendErrorToast();\n });\n }\n }", "title": "" }, { "docid": "49d733beafa3f39ebebf6c8081e2d678", "score": "0.5340246", "text": "renderStars(){\n\n var starLimit = 5;\n var html = [];\n\n for(var i = 0; i<starLimit;i++){\n\n if(this.props.truck.stars > i){\n\n html.push(\n <div className={\"no-padding-no-margin col-2\"}>\n <img alt=\"star\"key = {i} src={FullStar} className=\"w100\"/>\n </div>\n );\n\n }else{\n\n html.push(\n <div className={\"no-padding-no-margin col-2\"}>\n <img alt=\"star\"key = {i} src={EmptyStar} className=\"w100\"/>\n </div>\n );\n\n }\n\n }\n\n return html;\n\n }", "title": "" }, { "docid": "c03a91a329c6d66f1f51ff0fc85ff8cd", "score": "0.533855", "text": "function renderTweets(tweets) {\n tweets.forEach(function(tweet) {\n $('#tweets-container').append(createTweetElement(tweet));\n });\n\n $('.fa-heart').on('click', function() {\n const postID = $(this).data('id');\n const $likesCounter = $(this).prev('.likes');\n $.ajax({\n method: 'PUT',\n url: '/tweets/like/' + postID,\n success: () => {\n $likesCounter.text(parseInt($likesCounter.text()) + 1);\n },\n });\n });\n }", "title": "" }, { "docid": "3980904254a0334bafa27a573e87278e", "score": "0.53379273", "text": "function paintShows() {\r\n let showContent = \"\";\r\n for (let i = 0; i < shows.length; i++) {\r\n let classFav;\r\n const indexClass = favorites.findIndex((fav) => {\r\n if (fav.show.id === shows[i].show.id) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n });\r\n\r\n if (indexClass !== -1) {\r\n classFav = \"fav__show\";\r\n } else {\r\n classFav = \"\";\r\n }\r\n\r\n showContent += `<li class=\"js-itemShow list__Shows--item ${classFav}\" id=\"${shows[i].show.id}\">`;\r\n if (shows[i].show.image !== null) {\r\n let image = shows[i].show.image.medium;\r\n showContent += `<img src=\"${image}\" alt=\"image show\" title=\"image show\" />`;\r\n } else {\r\n let image = \"https://via.placeholder.com/210x295/ffffff/666666/?text=TV\";\r\n showContent += `<img src=\"${image}\" alt=\"image show\" title=\"image show\" />`;\r\n }\r\n showContent += `<h2>${shows[i].show.name}</h2>`;\r\n showContent += \"</li>\";\r\n }\r\n listShows.innerHTML = showContent;\r\n}", "title": "" }, { "docid": "d1f233ddc23e0cd189a9debe57677d70", "score": "0.53338146", "text": "function writeLiHtml(storyObj, isFavList){\n\t\tvar domainUrl = extractDomain(storyObj.url);\n\t\t/*\n\t\t\tfor Hacker News api, time is in unix format\n\t\t\tand stored in .time property\n\t\t\tdisplay time 'ago' posted\n\t\t*/\n\t\tif (!isFavList){\n\t\t\tvar timestamp = new Date(storyObj.time*1000);\n\t\t\tvar now = new Date().getTime();\n\t\t\tvar timeAgo = timeDifference(now, timestamp);\n\t\t}\n\t\t/*\n\t\t\tfor favorite list for heroku api,\n\t\t\ttime is stored in .created_at property\n\t\t\tdiplay time favorited\n\t\t*/\n\t\telse {\n\t\t\tvar timeAdded = new Date(storyObj.created_at);\n\t\t\tvar month = timeAdded.getMonth() + 1;\n\t\t\tvar day = timeAdded.getDay();\n\t\t\tvar year = timeAdded.getFullYear();\n\t\t}\n\t\tvar liHtml = `\n\t\t\t<li \n\t\t\t\tdata-by=\"${storyObj.by}\" \n\t\t\t\tdata-id=\"`;\n\t\tif (!isFavList){\n\t\t\tliHtml += storyObj.id;\n\t\t}\n\t\telse {\n\t\t\tliHtml += storyObj.story_id;\n\t\t}\n\t\tliHtml +=`\"\n\t\t\t\tdata-title=\"${storyObj.title}\"\n\t\t\t\tdata-url=\"${storyObj.url}\" `;\n\t\tif (isFavList) {\n\t\t\tliHtml += `data-ajaxId=\"${storyObj.id}\"`;\n\t\t}\n\t\tliHtml += `>\n\t\t\t\t<span>\n\t\t\t\t\t<span class=\"star glyphicon `;\n\t\tif (!isFavList){\n\t\t\tliHtml += `glyphicon-star-empty`;\n\t\t}\n\t\t//display the filled in star for favorite list\n\t\telse {\n\t\t\tliHtml += `glyphicon-star`;\n\t\t}\n\t\tliHtml += `\" aria-hidden=\"true\"></span> \n\t\t\t\t</span> \n\t\t\t\t<span class='name'>\n\t\t\t\t\t<a href='${storyObj.url}' target='_blank'>\n\t\t\t\t\t\t${storyObj.title}\n\t\t\t\t\t</a>\n\t\t\t\t</span>\n\t\t\t\t<span class='url'>\n\t\t\t\t\t\t(${domainUrl})\n\t\t\t\t</span><br>\n\t\t\t\t<span class=\"postInfo\">\n\t\t\t\t\tby ${storyObj.by}`; \n\t\tif (!isFavList){\n\t\t\tliHtml += \" \" + timeAgo;\n\t\t}\n\t\telse {\n\t\t\tliHtml += `; Favorited: ${month}/${day}/${year}`;\n\t\t}\n\t\tliHtml += `\n\t\t\t\t</span>\n\t\t\t</li>\n\t\t`;\n\t\t$ol.append(liHtml);\n\n\t\t//hide favorite star icons if not logged in\n\t\tif (!loggedIn){\n\t\t\t$('.star').hide();\n\t\t}\n\t}", "title": "" }, { "docid": "a875886c0c4da74c3860a13e115be152", "score": "0.53291523", "text": "function handleFavButton(e) {\n \n // const likedData = { user_id: changeUser.id, art_id: artCards.id}\n\n let newArt = filteredArt.map(artId => {\n return (\n <Container key = {artId.id} {...artId}/>\n )\n })\n\n // console.log(artCards[0].id)\n \n const likesObj = {\n art_id: filteredArt.id,\n user_id: users.id\n }\n\n // console.log(filteredArt[0].id)\n\n // console.log(likesObj)\n // console.log(e.target.value)\n // console.log(changeUser.id)\n // let likeId = likes.find(like => like.user_id === changeUser.id).id\n \n fetch('http://localhost:3000/likes', {\n method: 'POST',\n headers: {\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify(likesObj),\n })\n .then(res => res.json())\n .then(data => console.log(\"beef\", data))\n // .then(data => setLikes(data))\n }", "title": "" }, { "docid": "ccbb475244ed92dbc13823726ef104dc", "score": "0.53270644", "text": "function clickLike(e){var t=$(e.currentTarget).attr(\"love-count\"),n=$(e.currentTarget).attr(\"id\"),r=$(e.currentTarget).find(\".text-like-btn\"),i=2;$.get(\"/lovr\",{id:n,num:t,type:2},function(t){$(e.currentTarget).addClass(\"liked-icon\"),r.text(Number(r.text())+1)})}", "title": "" }, { "docid": "1725717d256dcabdb542074742a43103", "score": "0.5323095", "text": "function AnimeCard({anime}) {\n const messageScore = (counter) =>{\n if (counter > 0) {\n if (counter < 5){\n return \"I do notrecommend it.\"\n }\n else if(counter >= 5 && counter < 8){\n return \"You may have fun.\"\n }\n else if(counter > 8){\n return \"Great, this is one of the best anime\"\n }else {\n return \"nothing to say\"\n }\n } \n }\n\n return (\n <article className=\"anime-card\" key={anime.key}>\n <a href={anime.url}\n target=\"_blank\"\n rel=\"noreferrer\"\n key={anime.mal_id}>\n <img src={anime.image_url} alt={anime.title} key={anime.key}/>\n </a>\n <div className=\"anime-info\" key={anime.key}>\n <h3>{anime.title}</h3>\n <span>{anime.score}</span>\n </div>\n <a href={anime.url}\n target=\"_blank\"\n rel=\"noreferrer\"\n key={anime.mal_id} key={anime.key}>\n <div className=\"anime-over\">\n <h2>Overview:</h2>\n <p className=\"messageScore\">{ messageScore(anime.score)}</p>\n <p>{anime.synopsis}</p>\n </div>\n </a>\n </article>\n\n\n )\n}", "title": "" }, { "docid": "f4de1dce3717249d2120c9065d784b5c", "score": "0.5309047", "text": "static unlike() {\n // add style to the unlike icon and font\n document.querySelector('.like i').style.color = '#606770';\n document.querySelector('.like span').style.color = '#606770';\n }", "title": "" }, { "docid": "a436f2e9c92a6b4778b06fddc33734ac", "score": "0.53079724", "text": "handleDamage(){\n //no hurt when power dot is active\n if(this.powerdotState !== powerdotHigh && this.powerdotState !== powerdotLow){\n //logical decrement of life\n this.lives--;\n //hurt sound\n this.hurt.play();\n\n //draw all the hearts\n for(let i = 0;i<MAXLIVES;i++){\n this.uictx.drawImage(this.heart,i*tileSize*2,0);\n }\n\n //draw the crossing of heart when life lost\n let remainingLife = MAXLIVES-this.lives;\n let drawLoc = 0;\n while(remainingLife>0){\n this.uictx.drawImage(this.whiteHeart,drawLoc*tileSize*2,0);\n remainingLife--;\n drawLoc++;\n }\n if(this.lives === 0){\n this.isGameOver = true;\n }\n }\n }", "title": "" }, { "docid": "f860bbd79a134bef1e2df37f7a220768", "score": "0.52967215", "text": "function loadLikes(data) {\n\t// Llamada ajax que recupera y parsea a json la url pasada\n\tvar htmlProdut = '';\n\tvar i = 0;\n\t$.each(data.items, function(i, asociado) {\n\t\thtmlProdut = htmlProdut + '<a onclick=\"javascript:analytics(' + i\n\t\t\t\t+ ')\" pos=\"' + asociado.pos + '\" class=\"margeneslike\" href=\"'\n\t\t\t\t+ asociado.link + '\"><img src=\"' + asociado.image\n\t\t\t\t+ '\" width=\"88\" height=\"134\" /></a>'\n\t\ti++;\n\t});\n\tif (htmlProdut != '') {\n\t\t$('#mightlike').show();\n\t\t$('#mightlike').after(htmlProdut);\n\t}\n\n}", "title": "" }, { "docid": "3c8b14dc46bcf9e9f5833c9ebea04dd1", "score": "0.5296075", "text": "function changeLike(el) {\n el.firstChild.className = (el.firstChild.className[0]!='l')?\"liked\":\"unliked\";\n}", "title": "" }, { "docid": "66fe530b1595a286b6abfb2049adae73", "score": "0.52957547", "text": "set liked(isLiked) {\n this._liked = isLiked;\n this.setAttribute('liked', isLiked);\n }", "title": "" }, { "docid": "a7bf8837f25867a5d3faa41f84d4112d", "score": "0.5293467", "text": "function updateLikedButton() {\n spotifyPlayer.getCurrentState().then(state => {\n if (!state) {\n console.error(\"No music playing.\")\n return\n }\n checkLiked(state.track_window.current_track.id).then(\n function(liked) {\n if (liked) {\n console.log(\"LIKED\")\n likeBtn.css(\"background-image\", \"url('img/share-like.svg')\")\n } else {\n console.log(\"UNLIKED\")\n likeBtn.css(\"background-image\", \"url('img/share-unlike.svg')\")\n }\n likeBtn.attr(\"data-liked\", liked)\n }\n )\n })\n}", "title": "" }, { "docid": "a574186f16e3d14f30ad5424dfd24713", "score": "0.5292414", "text": "function showHighScores() {\n var scores = getScores();\n var ret = '<div class=\"userTitle\">NAME</div>\\t<div class=\"scoreTitle\">SCORE</div><br />';\n var i = 0;\n // this loop changes the background color of the scores based on if it is an even or odd number\n scores.forEach(function (score) {\n var background = ++i % 2 ? 'odd' : 'even';\n ret += '<div class=\"scoreWrapper ' + background + ' \"><div class=\"name\">' + score.name +\n '</div><div class=\"score\">' + score.score + '</div></div>'\n });\n return ret;\n }", "title": "" }, { "docid": "8e5c23f11420013a9b2738eeb6032ed5", "score": "0.52900136", "text": "function showHands(stayed = false) {\n \n playerScore = calculateHand(player);\n dealerScore = calculateHand(dealer);\n \n clearTable();\n \n outputArea.innerHTML = `${showHand(dealer, dealerScore)}</br>${showHand(player, playerScore)}`;\n \n let winner = determineWinner(stayed); \n \n if (winner !== '') {\n hideGameButtons();\n }\n winnerArea.innerHTML = winner;\n}", "title": "" }, { "docid": "93a658280b2bb5d6ecd7d0516675414d", "score": "0.5285426", "text": "render() {\n const artDict = [\n /* A dictionary that contains all the information on every art piece*/\n { name: \"Harold Parker Forest\", src: \"/images/Piece1.jpg\", medium: \"oil paint\", date: \"08/2/2017\", has_awards: \"no\", awards: \"\", time: \"10\" },\n { name: \"Black Cloud\", src: \"/images/Piece2.jpg\", medium: \"colored pencil\", date: \"11/3/2016\", has_awards: \"yes\", awards: \"* Scholastic Art and Writing Awards National Gold Medal *\", time: \"52\" },\n { name: \"Serenity\", src: \"/images/Piece3.jpg\", medium: \"watercolor\", date: \"05/20/2018\", has_awards: \"no\", awards: \"\", time: \"2\" },\n { name: \"Frosted Pink\", src: \"/images/Piece4.jpg\", medium: \"colored pencil\", date: \"02/27/2014\", has_awards: \"no\", awards: \"\", time: \"6\" },\n { name: \"Unexpected Adventure\", src: \"/images/Piece5.jpg\", medium: \"colored pencil\", date: \"11/27/2015\", has_awards: \"no\", awards: \"\", time: \"8\" },\n { name: \"Offstage\", src: \"/images/Piece6.jpg\", medium: \"colored pencil\", date: \"08/17/2016\", has_awards: \"yes\", awards: \"* Scholastic Art and Writing Awards Regional Silver Medal *\", time: \"14\" },\n { name: \"Flash of Life\", src: \"/images/Piece7.jpg\", medium: \"colored pencil\", date: \"09/14/2017\", has_awards: \"no\", awards: \"\", time: \"13\" },\n { name: \"Red\", src: \"/images/Piece8.jpg\", medium: \"ink\", date: \"12/29/2016\", has_awards: \"no\", awards: \"\", time: \"2\" },\n { name: \"*Untitled*\", src: \"/images/Piece9.jpg\", medium: \"collage\", date: \"10/30/2019\", has_awards: \"no\", awards: \"\", time: \"4\" },\n { name: \"Moving Forward\", src: \"/images/Piece10.jpg\", medium: \"oil paint\", date: \"6/1/2016\", has_awards: \"no\", awards: \"\", time: \"11\" },\n { name: \"Autumn Farmhouse\", src: \"/images/Piece11.jpg\", medium: \"oil paint\", date: \"7/18/2016\", has_awards: \"no\", awards: \"\", time: \"12\" },\n { name: \"Cornucopia\", src: \"/images/Piece12.jpg\", medium: \"mixed media\", date: \"3/23/2017\", has_awards: \"yes\", awards: \"* Scholastic Art and Writing Awards Regional Gold Medal *\", time: \"55\" }\n ];\n return (\n <div>\n <FilteredList list={artDict} />\n </div>\n )\n }", "title": "" }, { "docid": "d5f06e9da95686ab9af1a7e85ddab63b", "score": "0.5282465", "text": "function renderHighScores() {\n highScores.sort(function (a, b) {\n if (a.score < b.score) {\n return 1;\n } else {\n return -1;\n }\n });\n $(\"#highScorePage ul\").empty();\n $.each(highScores, function (i, person) {\n listItem = $(\"<div>\");\n listSpan = $(\"<span />\");\n listItem.addClass(\"row\");\n listSpan.addClass(\"badge-pill badge-primary mb-1\");\n listSpan.text(\n `${i + 1}. ${person.initial.toUpperCase()} with ${person.score} points`\n );\n listItem.append(listSpan);\n $(\"#highScorePage ul\").append(listItem);\n });\n }", "title": "" }, { "docid": "61c106372eed08cbb6c11d6c037485b9", "score": "0.5274925", "text": "function likeFunction() {\r\n\t//like increases when call function\r\n\tlike++;\r\n document.getElementById(\"like\").innerHTML = like ;\r\n}", "title": "" }, { "docid": "d609c033981d72222965e4b6bf71aecc", "score": "0.5262769", "text": "function handleLike(event) {\n let currentCount = parseInt(counter.textContent)\n let NumLi = document.getElementById(`${currentCount}`)\n\n if (NumLi === null) {\n let newNumLi = document.createElement(\"li\")\n newNumLi.id = `${currentCount}`\n newNumLi.textContent = `1 like on ${currentCount}!`\n likesList.append(newNumLi)\n } else {\n let existingNumLi = document.getElementById(`${currentCount}`)\n let existingNumLiArr = existingNumLi.textContent.split(\" \")\n let numLikes = parseInt(existingNumLiArr[0])\n numLikes++;\n existingNumLiArr[0] = numLikes\n existingNumLi.textContent = existingNumLiArr.join(\" \")\n };\n}", "title": "" }, { "docid": "f41593f9923141512a8c284feb90ff01", "score": "0.52607524", "text": "render(){\n\n let { name, dirty } = this.props.hog; \n let { toggleDirty } = this.props;\n\n return (\n <div className=\"pigTile\">\n <img src={`hog-imgs/${name.split(' ').join('_')}.jpg`} alt={this.props.hog.name}/>\n <div>{this.props.hog.name}</div>\n <button onClick={() => toggleDirty(name)}>{ dirty ? 'Shower Hog' : 'Play in the Mud'}</button>\n <button onClick={this.handleClick}>More Info</button>\n { this.state.clicked && <HogDetail hog={this.props.hog} /> }\n </div>\n )\n }", "title": "" }, { "docid": "b037ffb009bc7a5b983dcce887458d2b", "score": "0.5260397", "text": "render() {\n ctx.drawImage(Resources.get(this.sprite), this.x, this.y);\n\n for (let i=0; i<=this.lives-1; i++) {\n ctx.drawImage(Resources.get('images/heart-small.png'), (i*32), 0, 35, 60);\n };\n }", "title": "" }, { "docid": "30899ceafe67e7b7cf582312c97a673a", "score": "0.52505344", "text": "function like() {\n likeArray[counter]++;\n var resultGrouping = currentPainting.resultGrouping;\n console.log(resultGrouping);\n if(resultGrouping.match(\"Human\"))\n human++;\n else if (resultGrouping.match(\"Modular\"))\n modular++;\n else if (resultGrouping.match(\"Ais\"))\n ais++;\n}", "title": "" }, { "docid": "b464a5bc117e754bd64e76b422120b00", "score": "0.5246179", "text": "function showButtonNums(scratch){\n document.getElementById('canliveSpan').innerHTML = scratch.likes\n document.getElementById('NopeSpan').innerHTML = scratch.dislikes\n}", "title": "" }, { "docid": "c97828c870c9217ef1557f9f40859af7", "score": "0.52442163", "text": "get likes() { return this._likes; }", "title": "" }, { "docid": "cf490db64453653c554ff366a885031d", "score": "0.52440166", "text": "toggleLiked() {\n\n /********************Pure Functions************************/\n\n const attrStatus = getAttr('liked');\n const equalToTrue = equals('yes');\n const checkStatus = compose(equalToTrue, attrStatus);\n\n /*********************Impure Function**********************/\n\n const impure = (component) => {\n (checkStatus(component) ?\n setAttr(component, 'liked', 'no') :\n setAttr(component, 'liked', 'yes'));\n };\n\n impure(this);\n }", "title": "" }, { "docid": "fb0a810c38fd7ad8b8977282461d3f3a", "score": "0.5236632", "text": "shouldComponentUpdate(nextProps, nextState) {\n console.log(\"next : should update \", nextProps);\n console.log(\"current \", this.props);\n \n if (nextProps.likes % 5 == 0)\n return true; //calls render\n \n return false;//do not call render\n }", "title": "" }, { "docid": "3af72f4dd6fed8d80e464ed92f2b2d13", "score": "0.52192503", "text": "function LikesButton(props) {\n return (\n <a className=\"orange-text\" href=\"#like\" onClick={props.onClick}>\n <span className=\"likesText\">{props.likes}</span>\n <MatIcon extraClass=\"addBtn\" tooltip={props.liked?\"dislike\":\"like\"}>{props.liked?\"star\":\"star_border\"}</MatIcon>\n </a>\n );\n}", "title": "" }, { "docid": "457c5c91e7796e0470e0008a3e7a1b19", "score": "0.5218503", "text": "play() {\n changeImg(playImg);\n // happy, tired, hungry, bored, angry, lonely\n this.updateMood(\n randomNum(25), // happy\n randomNum(25), // tired\n randomNum(25), // hungry\n -randomNum(25), // bored\n -randomNum(25), // angry\n -randomNum(25), // lonely\n );\n }", "title": "" }, { "docid": "28185bc55a3c3dc1fa185f9d451d518c", "score": "0.5212661", "text": "renderRating(param){\n if(param == 0){\n return LIBERO;\n }\n else{\n if(param<=19 && param>=1){\n return <img src={star}/>;\n }\n else{\n if(param<=39 && param>=20){\n return <td><div><img src={star}/><img src={star}/></div></td>;\n }\n else{\n if(param<=59 && param>=40){\n return <td><div><img src={star}/><img src={star}/><img src={star}/></div></td>;\n }\n else{\n if(param<=79 && param>=60){\n return <td><div><img src={star}/><img src={star}/><img src={star}/><img src={star}/></div></td>;\n }\n else{\n if(param<=100 && param>=80){\n return <td><div><img src={star}/><img src={star}/><img src={star}/><img src={star}/><img src={star}/></div></td>;\n }\n }\n }\n }\n }\n}\n}", "title": "" }, { "docid": "e744ed1ca8e508bd3dce1e579d64ed67", "score": "0.5207154", "text": "createStars(score) {\n const starRating = score / 2;\n let stars = [];\n for (let i = 0; i < Math.floor(starRating); i++) {\n stars.push(<i key={stars.length} className=\"fa fa-star\"></i>);\n }\n if (starRating % 1 !== 0)\n stars.push(\n <i\n key={stars.length}\n className=\"fa fa-star-half-o\"\n aria-hidden=\"true\"\n ></i>\n );\n for (let i = 0; i < 5 - Math.round(starRating); i++) {\n stars.push(\n <i key={stars.length} className=\"fa fa-star-o\" aria-hidden=\"true\"></i>\n );\n }\n return stars;\n }", "title": "" }, { "docid": "1b59dda24cdbb024bd4312182e0da0fc", "score": "0.52011186", "text": "function likeFunction(e) {\n let heart = e.target;\n\n mimicServerCall(\"Url\") //fetch function - Invoke minicServerCall to simulate making a server request\n .then(function(serverMessage){ // changing heart in HTML\n if (heart.innerHTML == FULL_HEART) {\n heart.innerHTML = EMPTY_HEART};\n if (heart.innerHTML == EMPTY_HEART) {\n heart.innerHTML = FULL_HEART};\n })\n\n /* Display the error modal by removing the .hidden class\n Display the server error message in the modal\n Use setTimeout to hide the modal after 5 seconds (add the .hidden class) */\n\n .catch(function(error){ // respond to the error using .catch\n let modal = document.getElementById(\"modal\")\n modal.className = \" \";\n modal.innerText = error // post error in modal\n console.log(modal);\n setTimeout(function(){ // use setTimeout to hide the modal after 5 seconds\n modal.className= \"hidden\" // adding hidden class back to modal\n }, 5000)\n });\n\n const li = document.getElementsByTagName('li') //create class for activated_heart in each li\n for(let i=0; i < li.length; i++) {\n const spanLike = document.querySelector('span.like-glyph')\n spanLike.style.color = 'red'\n console.log(spanLike[i])\n\n }\n }", "title": "" }, { "docid": "e891891dd0b18a6ef08f8af275c91664", "score": "0.5197613", "text": "async function getLike() {\n try{\n\n if( !localStorage.getItem('user') || !JSON.parse(localStorage.getItem('user')).id )\n return\n\n var response = await likedStatus(\n this.component.state.postId, \n JSON.parse(localStorage.getItem('user')).id\n )\n //if invalid accessToken, try to refresh it, then call function again\n if(hasInvalidAccessToken(response)){\n if(await refreshAccessToken())\n this.component.checkLikeStatus()\n return\n }\n\n var like = response && response.data && response.data.Like;\n //if the current user hasn't liked or disliked the post or an error returned\n if( !like || response.errors)\n return;\n\n //if current user liked this.component post\n if(like.isLike){\n $(`.thumbsUp${this.component.state.componentID}`).css(\"color\", \"#00BFFF\")\n }\n //if current user disliked this.component post\n else{\n $(`.thumbsDown${this.component.state.componentID}`).css(\"color\", \"red\")\n }\n\n }\n catch(err) {\n console.log(err);\n }\n }", "title": "" }, { "docid": "a315902638972dc0279ed58cf32d8355", "score": "0.5196764", "text": "function like_request(post_id) {\n fetch(`like/${post_id}`, {\n method: 'PUT'\n })\n .then(response => response.json())\n\t.then(data => {\n const content = document.querySelector(`#total-${post_id}`);\n if (data.liked === true) {\n document.querySelector(`#like-${post_id}`).innerHTML = \"Unlike\";\n\t\t content.innerHTML = \" Total Likes: \" + data.total_likes;\n } else {\n document.querySelector(`#like-${post_id}`).innerHTML = \"Like\";\n content.innerHTML = \" Total Likes: \" + data.total_likes;\n }\n\t});\n}", "title": "" }, { "docid": "dfd9e7f3e787b2ae11457c5e938068ef", "score": "0.519489", "text": "function showStars(score, starsRate) {\r\n \r\n var max = 5;\r\n var unchecked = (max - score);\r\n for(var i=0; i<score; i++) {\r\n starsRate += `<small><i class=\"fa fa-star checked\"></i></small>`;\r\n }\r\n for(var i=0; i< unchecked; i++){\r\n starsRate += `<small><i class=\"fa fa-star\"></i></small>`;\r\n }\r\n return starsRate;\r\n }", "title": "" }, { "docid": "5f8f1e7ec5ce205323d2ea600e5e2565", "score": "0.5191562", "text": "function List(props){\n let buttonClass = 'dishesNotShown';\n let buttonText = 'Display your dishes';\n let listClass = 'invisible';\n if(props.show){\n buttonClass = 'dishesShown';\n buttonText = 'Hide dishes';\n listClass = 'visible';\n }\n const dishes = props.dishes.map(d =>{\n let id = Math.random();\n let val = d.getName();\n return(\n <li \n key={id} \n >{val}</li>\n )\n }); \n return(\n <section \n className='output'>\n <div className={buttonClass}\n onClick={props.toggle}>\n <h3>{buttonText}</h3>\n </div>\n <div className={listClass}>\n <ul>\n {dishes}\n </ul>\n </div>\n </section>\n );\n}", "title": "" }, { "docid": "c698ea9ac8fd9731e161679a23b168a5", "score": "0.5187916", "text": "function likeClicked() {\n likeCount++;\n var like_button_text = document.getElementById('like-button-text');\n var like_button = document.getElementById('like-button');\n if (likeCount === 1) {\n //Change the text below like button.\n like_button_text.innerHTML = likeCount + ' person likes this !';\n //change the button name to liked.\n like_button.innerHTML = '<i class=\"fa fa-thumbs-up fa-lg\"aria-hidden=\"true\"></i> Liked';\n } else if (likeCount >= 2) {\n //Change the text below like button.\n like_button_text.innerHTML = likeCount + ' people like this !';\n }\n\n}", "title": "" }, { "docid": "8dd714e2e116c76ae34d30713abd28bc", "score": "0.5180044", "text": "function update_like_counts(_checkState, _attributes) {\n\t\tif ((_checkState === SysEnum.WINDOWS_AND_STATES.POST && (STATE === SysEnum.WINDOWS_AND_STATES.NEWSFEED || STATE === SysEnum.WINDOWS_AND_STATES.PROFILE || STATE === SysEnum.WINDOWS_AND_STATES.PROFILE_BY_ID)) || (_checkState === SysEnum.WINDOWS_AND_STATES.GROUP_POST && STATE === SysEnum.WINDOWS_AND_STATES.GROUP)) {\n\t\t\tvar section_list = listView.getSections();\n\t\t\tfor (var i = 0,\n\t\t\t j = section_list.length; i < j; i++) {\n\t\t\t\tvar items = section_list[i].getItems();\n\t\t\t\tif (items.length === 1) {\n\t\t\t\t\tif (items[0].properties.itemId === _attributes.post_id) {\n\t\t\t\t\t\tif (like_by_current_user(_attributes.post_like_ids)) {\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].liked = true;\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].image = imagePath.like_already_focus;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].liked = false;\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].image = imagePath.like_blur;\n\t\t\t\t\t\t}\n\t\t\t\t\t\titems[0].like_count.text = _attributes.post_likes_count;\n\t\t\t\t\t\tsection_list[i].updateItemAt(0, items[0]);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\tif (items[1].properties.itemId === _attributes.post_id) {\n\t\t\t\t\t\tif (like_by_current_user(_attributes.post_like_ids)) {\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].liked = true;\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].image = imagePath.like_already_focus;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].liked = false;\n\t\t\t\t\t\t\tsection_list[i].getFooterView().children[0].children[0].image = imagePath.like_blur;\n\t\t\t\t\t\t}\n\t\t\t\t\t\titems[1].like_count.text = _attributes.post_likes_count;\n\t\t\t\t\t\tsection_list[i].updateItemAt(1, items[1]);\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "ab9ef5b727c663ad989664b9cda5d506", "score": "0.5177256", "text": "function putStoriesOnPage() {\n console.debug(\"putStoriesOnPage\");\n\n // empty out that part of the page\n $allStoriesList.empty();\n\n // loop through all of our stories and generate HTML for them\n //for (let story of storyList.stories) {\n\n for (let i = 0; i < storyList.stories.length; i++){ //loop through all current stories\n let markup = generateStoryMarkup(storyList.stories[i]); //CORRECT\n\n if(currentUser){\n console.log(currentUser.favorites)\n for (let favorite of currentUser.favorites){\n if (storyList.stories[i].storyId === favorite.storyId){\n console.log(favorite.storyId)\n //let debugVar = $(\"i\")\n $(`#star-${favorite.storyId}`).toggleClass(\"far fas\")\n }\n }\n showStars(); //CORRECT\n }\n\n $allStoriesList.append(markup);\n }\n $allStoriesList.show();\n}", "title": "" }, { "docid": "787d3061671c188aaba557fcd0fbba6d", "score": "0.51740456", "text": "render() {\n if (this.state.isLoading) {\n return (\n <View style={[styles.activityIndicator]}>\n <ActivityIndicator size=\"large\" color=\"#2B2D5B\" />\n </View>\n );\n }\n\n if (this.state.myLikes.length === 0) {\n return (\n <ScrollView>\n <RefreshControl\n refreshing={this.state.refreshing}\n onRefresh={this._onRefresh}\n />\n <View style={styles.infoContent}>\n <Text style={styles.info}>Start adding artists to your likes!</Text>\n <Text style={styles.emoji}>🤘</Text>\n </View>\n </ScrollView>\n );\n } else {\n return <React.Fragment>{this.renderArtistsList()}</React.Fragment>;\n }\n }", "title": "" }, { "docid": "3001892eda9d8fd888f37c0d40c13f33", "score": "0.5173877", "text": "displayShots(){\r\n switch(this.shotCount){\r\n case 1:\r\n this.syringeOne.style.color = 'grey';\r\n this.syringeTwo.style.textShadow ='0 0 1rem white';\r\n this.syringeOne.style.textShadow ='none';\r\n\r\n break;\r\n case 2:\r\n this.syringeTwo.style.color = 'grey';\r\n this.syringeThree.style.textShadow ='0 0 1rem white';\r\n this.syringeTwo.style.textShadow ='none';\r\n\r\n break;\r\n case 3:\r\n this.syringeThree.style.color = 'grey';\r\n this.syringeThree.style.textShadow ='0 0 1rem white';\r\n this.syringeThree.style.textShadow ='none';\r\n\r\n break; \r\n default:\r\n return;\r\n }\r\n }", "title": "" }, { "docid": "95d7c9066a883d77888231ec4d693ca8", "score": "0.51728994", "text": "function renderPreviews() {\n $('#questions').html(\n data.map((i) => '<li data-qid=\"' + i._id + '\" data-seen=\"' + i.seen + checkOwnQ(i.author) + '\">' + i.author + '</li>').join('')\n )\n }", "title": "" }, { "docid": "161b7dc3d40789565cbac2c4f2afb2bd", "score": "0.5171806", "text": "function statusShow(){\n //defining my variables\n let storedAmount = localStorage.length;\n list.innerHTML =\"\";\n //kijkt wie er geliked is\n for(let a = 1; a < storedAmount; a++){\n showListLiked(\"like\", a); \n };\n //kijkt wie er gedisliked wordt\n for(let a = 1; a < storedAmount; a++){\n showListLiked(\"dislike\", a);\n };\n}", "title": "" }, { "docid": "d1bf26a9d142fd928e811be09d131afd", "score": "0.51704043", "text": "function handleHeart(){\n if (gameFrame % objectAmmount == 0){\n heartArray.push(new Heart());\n }\n for (let i=0; i < heartArray.length; i++){\n heartArray[i].update();\n heartArray[i].draw(); \n if (heartArray[i].y < 0 - heartArray[i].radius * 2){\n heartArray.splice(i, 1);\n i--;\n }else if (heartArray[i].distance < heartArray[i].radius + player.radius){\n // detect collision\n //add score\n if (!heartArray[i].counted){\n if (heartArray[i].sound == \"sound1\"){\n // bubbleSound1.play();\n }else{\n // bubbleSound2.play();\n }\n score++\n if(health <100){health +=1;}\n heartArray[i].counted = true;\n heartArray.splice(i, 1);\n i--; \n } \n } \n }\n}", "title": "" }, { "docid": "fa5ebf7c0ab48facc6dc3177976b167e", "score": "0.51692015", "text": "function like() {\n nLikes += 1;\n document.getElementById(\"nLikes\").innerHTML = nLikes + \" person likes this!\";\n document.getElementById(\"like-button\").innerHTML =\n \"<i class='fa fa-thumbs-up'></i> Liked\";\n}", "title": "" }, { "docid": "3339eaec0c11e5171ce4f4d0885a2c4a", "score": "0.5166189", "text": "function Content({ title, rate, offers }) {\n return (\n <div className=\"Content\">\n <Card\n className=\"Cards\"\n style={{ backgroundColor: \"whitesmoke\", width: \"300px\" }}\n >\n <h4>{title}</h4>\n <h1>{rate}</h1>\n <ul style={{ listStyleType: \"none\", textAlign: \"left\" }}>\n {offers.map((steps) =>\n //conditional rendering\n steps.indexOf(\"👎\") ? (\n <li style={{ padding: \"10px\" }}>{steps}</li>\n ) : (\n <li style={{ padding: \"10px\", opacity: \"0.5\" }}>{steps}</li>\n )\n )}\n </ul>\n\n <Button variant=\"contained\" color=\"primary\">\n More details\n </Button>\n </Card>\n </div>\n );\n}", "title": "" }, { "docid": "a48ca7b26dc5098e3d1d50bc3d7d1ab6", "score": "0.51574224", "text": "function likes(array) {\n const and = array.length - 2;\n const all = array.length > 5;\n switch (array.length) {\n default:\n pr = `${array[0]}, ${array[1]} and ${and} others like this\"`;\n break;\n case 4:\n pr = `${array[0]}, ${array[1]} and ${and} others like this\"`;\n break;\n case 3:\n pr = `${array[0]}, ${array[1]} and ${array[2]} like this`;\n break;\n case 2:\n pr = `${array[0]} and ${array[1]} like this`;\n break;\n case 1:\n pr = `${array[0]} likes this`;\n break;\n case 0:\n pr = \"no one likes this\";\n break;\n }\n return pr;\n}", "title": "" }, { "docid": "a55698ec5bb964704ffaba01b25a1441", "score": "0.5155412", "text": "function parsePost(post){\n var likeMessage = (post.likes == 1) ? '1 Like' : post.likes + ' Likes';\n if(post.liked){\n buttonStringLiked = '<button style=\"color: #F2910A\" type=\"button\" id=\"likedButton\" class=\"likePostBtn float-left\"><img src=\"../img/ziraf2.png\" alt=\"\">Liked</button>';\n buttonStringUnliked = '<button type=\"button\" id=\"unlikedButton\" class=\"likePostBtn float-left\" hidden><img src=\"../img/ziraf2Black.png\" alt=\"\">Like</button>'; \n }else{\n buttonStringLiked = '<button style=\"color: #F2910A\" type=\"button\" id=\"likedButton\" class=\"likePostBtn float-left\" hidden><img src=\"../img/ziraf2.png\" alt=\"\">Liked</button>';\n buttonStringUnliked = '<button type=\"button\" id=\"unlikedButton\" class=\"likePostBtn float-left\"><img src=\"../img/ziraf2Black.png\" alt=\"\">Like</button>';\n }\n return '<div class=\"post\" id=\"post'+ post.postId +'\">' +\n '<div class=\"postHeader\">' +\n '<img src=\"../img/userIcons/' + post.userId + '.'+ post.iconExtension +'\" alt=\"no\" class=\"float-left\" width=\"40px\" height=\"40px\">' +\n '<p class=\"float-left\">' + post.userName + '</p>' +\n '<small class=\"float-right\">' + post.dateCreated + '</small>' +\n '</div>' +\n '<div class=\"clear\"></div>' +\n\n '<div class=\"postBody\">' +\n '<p>' + post.content.replace(/\\n/g, '<br>\\n') + '</p>' +\n '</div>' +\n \n '<footer class=\"postFooter\">' +\n buttonStringLiked + buttonStringUnliked + \n '<p class=\"likesCount float-right\">' + likeMessage + '</p>' +\n '</footer>' +\n '<input type=\"hidden\" value=\"'+ post.liked +'\">' +\n '<div class=\"clear\"></div>' +\n '</div>'\n}", "title": "" }, { "docid": "7b00fd6b980d96b4173459f8aad770b2", "score": "0.51549566", "text": "render() {\n const { author, content, createdAt, usersLiked, usersDisliked,\n id: replyCommentID, parentComment: commentID } = this.props.replyComment;\n\n let username = 'Account Deactivated'; // fallback for comments whos author removed their account\n if(author) {\n username = author.username;\n }\n const likes = usersLiked.length;\n const dislikes = usersDisliked.length;\n let thisUserLiked = false;\n let thisUserDisliked = false;\n for(let user of usersLiked) {\n if(this.props.currentUser && user.username === this.props.currentUser.username) {\n thisUserLiked = true;\n break;\n }\n }\n for(let user of usersDisliked) {\n if(this.props.currentUser && user.username === this.props.currentUser.username) {\n thisUserDisliked = true;\n break;\n }\n }\n const timeElapsed = getTimeElapsed(new Date(createdAt));\n return(\n <div className=\"comment reply\">\n\n <div className=\"description\">\n <div className=\"avatar\">\n {this.props.replyComment.avatarUrl ?\n <img className=\"user-avatar-img\" src={this.props.replyComment.avatarUrl} alt=\"User avatar\"/>\n :\n <TieAvatar />\n }\n </div>\n <div className=\"metadata\">\n <span className=\"author\">{username}</span>\n <span className=\"timestamp\">posted {timeElapsed}</span>\n </div>\n </div>\n\n <div className=\"content\">\n <p>{content}</p>\n </div>\n\n <div className=\"interactions\">\n <label htmlFor=\"\">\n <span>{likes}</span>\n \n {thisUserLiked ? \n <ThumbsUpFilled className=\"thumb up\" clickHandler={e => this.likeReplyComment(e, commentID, replyCommentID)}/> \n : \n <ThumbsUpOutline className=\"thumb up\" clickHandler={e => this.likeReplyComment(e, commentID, replyCommentID)}/>\n }\n </label>\n <label>\n <span>{dislikes}</span>\n \n {thisUserDisliked ? \n <ThumbsUpFilled className=\"thumb down\" clickHandler={e => this.dislikeReplyComment(e, commentID, replyCommentID)}/> \n : \n <ThumbsUpOutline className=\"thumb down\" clickHandler={e => this.dislikeReplyComment(e, commentID, replyCommentID)}/>\n }\n </label>\n </div>\n </div>\n );\n }", "title": "" } ]
d67e17cf4755495af26458c044e30da6
extract the event name
[ { "docid": "311a147e88e050fed5ec98f1886aeb17", "score": "0.81259125", "text": "function extractEventName(name) {\n return name.slice(2).toLowerCase();\n}", "title": "" } ]
[ { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "19f2fd9de67a01a384afecc1743cccfa", "score": "0.757458", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "2fe26d9529467a2e27c1ed14ce0212c4", "score": "0.75438124", "text": "function getEventName(name) {\n return name.charAt(2).toLowerCase() + name.substring(3);\n }", "title": "" }, { "docid": "0e9827b26b73dbf6bdca66179358b991", "score": "0.7509344", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0) return name.substr(eventPrefix.length);\n return name;\n }", "title": "" }, { "docid": "cb23e818923e53250bb2e76fb10511ff", "score": "0.7456217", "text": "function eventName(name) {\n if (name.lastIndexOf(eventPrefix, 0) === 0)\n return name.substr(eventPrefix.length);\n return name;\n}", "title": "" }, { "docid": "dcb35591b66dd727ce00f2cfd87df06e", "score": "0.7334766", "text": "function getEventName(name) {\n var m = name.match(EVENT_NAME_PATTERN);\n var ret = m[1] ? 'change:' : '';\n ret += m[2].toLowerCase() + m[3];\n return ret;\n }", "title": "" }, { "docid": "dc4609ead209f49e43feebccc08afc18", "score": "0.7326811", "text": "function getEventName(name) {\n var m = name.match(EVENT_NAME_PATTERN);\n var ret = m[1] ? \"change:\" : \"\";\n ret += m[2].toLowerCase() + m[3];\n return ret;\n }", "title": "" }, { "docid": "a6daf8a07d57a0357d5446d4d7d6637f", "score": "0.7281775", "text": "function getEventName(name) {\n\t var m = name.match(EVENT_NAME_PATTERN);\n\t var ret = m[1] ? 'change:' : '';\n\t ret += m[2].toLowerCase() + m[3];\n\t return ret;\n\t}", "title": "" }, { "docid": "d7337956ff1b9c54c9ee1076a691b44d", "score": "0.72491723", "text": "function getEventName (match, prefix, eventName) {\n return eventName.toUpperCase();\n }", "title": "" }, { "docid": "d2a6e688e2a25be19b54d053ebdca59d", "score": "0.72322184", "text": "function getEventName(match, prefix, eventName) {\n return eventName.toUpperCase();\n }", "title": "" }, { "docid": "d2a6e688e2a25be19b54d053ebdca59d", "score": "0.72322184", "text": "function getEventName(match, prefix, eventName) {\n return eventName.toUpperCase();\n }", "title": "" }, { "docid": "72018d73a2686208d62486de7b81e84c", "score": "0.7222824", "text": "function getEventName(match, prefix, eventName) {\n return eventName.toUpperCase();\n }", "title": "" }, { "docid": "26f842b315d706977af6e1eeb0532be3", "score": "0.72098386", "text": "function getEventName(match, prefix, eventName) {\n return eventName.toUpperCase();\n }", "title": "" }, { "docid": "7fb393f4d79fd757e9b87e931c67d856", "score": "0.71986556", "text": "function getEventName(match, prefix, eventName) {\n return eventName.toUpperCase();\n }", "title": "" }, { "docid": "f0a9bc77078bd6be969a9b48afa928bd", "score": "0.6949295", "text": "function getEventName(element) {\n var name;\n\n if (element.hasAttribute(\"name\")) {\n name = element.getAttribute(\"name\");\n }\n else if (element.hasAttribute(\"id\")) {\n name = element.getAttribute(\"id\");\n }\n else {\n name = element.innerHTML;\n }\n\n return name;\n}", "title": "" }, { "docid": "92ef63446ce7752642621d5831757fc4", "score": "0.6769734", "text": "function _getMouseEventName(eventName) {\n if (maps.mouseEvents[eventName]) {\n eventName = maps.mouseEvents[eventName];\n }\n return eventName;\n }", "title": "" }, { "docid": "6cd7df6bebb01aca0c04043bf5b22d57", "score": "0.6729641", "text": "function unifyEventNames (eventName) {\n if (eventName.slice(-2) === \"ed\" ) {\n eventName = eventName.slice(0, -2);\n } else if (eventName.slice(-4) === \":one\" || eventName.slice(-4) === \":any\") {\n eventName = eventName.slice(0, -4);\n }\n\n return eventName;\n }", "title": "" }, { "docid": "ef2db98c8336fc1f99a9f89543211c13", "score": "0.6703805", "text": "function _getMouseEventName( eventName ) {\n\tif ( maps.mouseEvents[ eventName ] ) {\n\t\teventName = maps.mouseEvents[ eventName ];\n\t}\n\treturn eventName;\n}", "title": "" }, { "docid": "b1ff6c3c157890217da3b9f32d500fa7", "score": "0.66989803", "text": "function bName(e) {\n return e.tagName.substring(0,e.tagName.indexOf(\"-\")).toLowerCase() + \":\" + e.getAttribute(\"data-origname\");\n }", "title": "" }, { "docid": "46f3efe042d91daa7c216934e122a829", "score": "0.6686323", "text": "function packetEvtName( pkt ) {\n \n var name = pkt[\"cmd\"];\n var cmds = null;\n for(var index in chains) {\n \n cmds = chains[index];\n \n if(cmds[0] != name)\n continue;\n \n var sub = pkt.sub[0];\n name = name + '_' + sub[\"cmd\"];\n \n if(cmds.length > 1 && sub[\"param\"] != undefined) {\n if(cmds[1] == sub[\"cmd\"])\n return name + '_' + sub[\"param\"];\n }\n \n }\n \n return name;\n}", "title": "" }, { "docid": "070c299a957430f74ebbacee904e8ee7", "score": "0.66767836", "text": "function _getEventTitle(evt) {\n let title = '';\n\n // For Meetup events, group name will be the first line of the description\n if (0 === evt.url.indexOf('https://www.meetup.com')) {\n title += evt.description.split(\"\\n\")[0]; // eslint-disable-line quotes\n title += ': ';\n }\n\n // evt.summary will usually contain the event-specific info\n return title + evt.summary;\n}", "title": "" }, { "docid": "91d6702efaebf53b224cf035e40404f0", "score": "0.6655655", "text": "registerName (e) {\n const keyboardEvent = (e.originalEvent != null ? e.originalEvent.originalEvent : undefined) != null ? (e.originalEvent != null ? e.originalEvent.originalEvent : undefined) : e.originalEvent\n let name = atom.keymaps.keystrokeForKeyboardEvent(keyboardEvent)\n if (name.lastIndexOf('shift-', 0) === 0) {\n name = name.slice(6)\n }\n return name\n }", "title": "" }, { "docid": "aa954e26e9da7079dcde5fd26a5eb7ae", "score": "0.6564391", "text": "function _getTouchEventName(eventName) {\n // Detect touch event support\n if (maps.touchEvents[eventName]) {\n eventName = maps.touchEvents[eventName];\n }\n return eventName;\n }", "title": "" }, { "docid": "7e6f8061693a7ea09b46f67f3ed50bea", "score": "0.6541115", "text": "function get_event_info(object_name, e){\n object_name['Event_Type'] = e.type;\n object_name['Event_Target'] = e.target;\n object_name['Event_Time'] = new Date().toLocaleString() + \" / Time Stamp: \" + e.timeStamp;//e.timeStamp;\n}", "title": "" }, { "docid": "bb9090239e629c3b5899a0b85b762fff", "score": "0.65265745", "text": "getModName() {\n if (this.state.eventMod === null) {\n return (null);\n }\n return (this.state.eventMod.name);\n }", "title": "" }, { "docid": "d3785e343074bf52c0984d3016d2acf0", "score": "0.6520922", "text": "function _getTouchEventName( eventName ) {\n\t// Detect touch event support\n\tif ( maps.touchEvents[ eventName ] ) {\n\t\teventName = maps.touchEvents[ eventName ];\n\t}\n\treturn eventName;\n}", "title": "" }, { "docid": "7d4f4cdf057ff860908f1b4835ca8d2b", "score": "0.65131444", "text": "extractName()\n {\n \treturn this.getName() || '';\n }", "title": "" }, { "docid": "62ba5b61e027a2957e970ed8f000fe02", "score": "0.6501421", "text": "function camelizeEvent(name) {\n\t return 'on' + name.charAt(0).toUpperCase() + name.substring(1);\n\t}", "title": "" }, { "docid": "2a60484695167e8cde558f863ff7095e", "score": "0.64965236", "text": "function getResponseName(eventName) {\n return `${eventName}:response`;\n}", "title": "" }, { "docid": "1a8d24e4925940d109a42213fb8f707a", "score": "0.64780504", "text": "function getMethodName (eventName) {\n return 'on' + capitalize(eventName)\n}", "title": "" }, { "docid": "9e726edec83c167f361d0c4e3cf8ec79", "score": "0.64382726", "text": "eventName() {\r\n return this._eventName;\r\n }", "title": "" }, { "docid": "58a7c20e0d958e6c10498ef549ee1797", "score": "0.6377698", "text": "extractName() {\n return this.getName() || \"\";\n }", "title": "" }, { "docid": "9206c7d7c68e745ee89abd55979e99d4", "score": "0.6314318", "text": "function getTitle(e) {\n let projectTitle = e.target.outerText;\n return projectTitle;\n}", "title": "" }, { "docid": "5fc0fad24127b75d1c9575dda62fc9fb", "score": "0.6306982", "text": "function onEvent2(name) {\n console.log(name);\n}", "title": "" }, { "docid": "d7f5bf01e8228178e71256a1154e5435", "score": "0.6227679", "text": "function mungeEventHandlerPropertyName(name) {\n\t\tvar parts = name.split(\".\");\n\t\tvar result = \"\";\n\t\tfor (var i = 0; i < parts.length - 1; i++) {\n\t\t\tresult += parts[i] + \".\";\n\t\t}\n\t\tvar lastPart = parts[parts.length - 1];\n\t\tif (lastPart.indexOf(\"$\") !== 0) {\n\t\t\tresult += \"$\" + lastPart;\n\t\t} else {\n\t\t\tresult += lastPart;\n\t\t}\n\t\treturn result;\n\t}", "title": "" }, { "docid": "ff9e237301a087a477c87a51eef0df1e", "score": "0.6212003", "text": "function eventName(name){\n return name+'.fth-'+floatTheadId+'.floatTHead'\n }", "title": "" }, { "docid": "534b59a62e57a3f21166cd2d821664cd", "score": "0.620447", "text": "static parseEventName(eventName) {\n const parts = eventName.toLowerCase().split('.');\n const domEventName = parts.shift();\n if (parts.length === 0 || !(domEventName === 'keydown' || domEventName === 'keyup')) {\n return null;\n }\n const key = KeyEventsPlugin._normalizeKey(parts.pop());\n let fullKey = '';\n let codeIX = parts.indexOf('code');\n if (codeIX > -1) {\n parts.splice(codeIX, 1);\n fullKey = 'code.';\n }\n MODIFIER_KEYS.forEach(modifierName => {\n const index = parts.indexOf(modifierName);\n if (index > -1) {\n parts.splice(index, 1);\n fullKey += modifierName + '.';\n }\n });\n fullKey += key;\n if (parts.length != 0 || key.length === 0) {\n // returning null instead of throwing to let another plugin process the event\n return null;\n }\n // NOTE: Please don't rewrite this as so, as it will break JSCompiler property renaming.\n // The code must remain in the `result['domEventName']` form.\n // return {domEventName, fullKey};\n const result = {};\n result['domEventName'] = domEventName;\n result['fullKey'] = fullKey;\n return result;\n }", "title": "" }, { "docid": "9d20a3966f314c56ab4edb426e2d1761", "score": "0.618386", "text": "function getInfo(event) {\n console.log(event)\n} // to obtain information on event", "title": "" }, { "docid": "f783795394f3e632b266444953057876", "score": "0.6137554", "text": "getEvent(nameOrSignatureOrTopic) {\n if ((0, _bytes.isHexString)(nameOrSignatureOrTopic)) {\n const topichash = nameOrSignatureOrTopic.toLowerCase();\n\n for (const name in this.events) {\n if (topichash === this.getEventTopic(name)) {\n return this.events[name];\n }\n }\n\n logger.throwArgumentError(\"no matching event\", \"topichash\", topichash);\n } // It is a bare name, look up the function (will return null if ambiguous)\n\n\n if (nameOrSignatureOrTopic.indexOf(\"(\") === -1) {\n const name = nameOrSignatureOrTopic.trim();\n const matching = Object.keys(this.events).filter(f => f.split(\"(\"\n /* fix:) */\n )[0] === name);\n\n if (matching.length === 0) {\n logger.throwArgumentError(\"no matching event\", \"name\", name);\n } else if (matching.length > 1) {\n logger.throwArgumentError(\"multiple matching events\", \"name\", name);\n }\n\n return this.events[matching[0]];\n } // Normlize the signature and lookup the function\n\n\n const result = this.events[_fragments.EventFragment.fromString(nameOrSignatureOrTopic).format()];\n\n if (!result) {\n logger.throwArgumentError(\"no matching event\", \"signature\", nameOrSignatureOrTopic);\n }\n\n return result;\n }", "title": "" }, { "docid": "3a171edb9532e81d3ccae93e930cd274", "score": "0.6123821", "text": "getEventKey(event) {\n\t\treturn `RNFirebase-${this.toString()}-${event}`;\n\t}", "title": "" }, { "docid": "06448cf86ada868f4d919ad3b3faa969", "score": "0.6074958", "text": "function createMediationEventName(eventName, networkName) {\n\t\t var answer = \"\";\n\n\t\t if (utils.isNotEmpty(eventName) && utils.isNotEmpty(networkName)) {\n\t\t\t eventName = normalizeTrackingEventName(eventName);\n\t\t\t answer = eventName + \"_\" + networkName;\n\t\t }\n\n\t\t return answer;\n\t }", "title": "" }, { "docid": "26d6f9419d35eac0a50a295dcc298e4e", "score": "0.60743505", "text": "function onEvent(name, event) {\n console.log(name, JSON.stringify(event, null, 2));\n}", "title": "" }, { "docid": "26d6f9419d35eac0a50a295dcc298e4e", "score": "0.60743505", "text": "function onEvent(name, event) {\n console.log(name, JSON.stringify(event, null, 2));\n}", "title": "" }, { "docid": "241148d43312560ccbaed2307457df8f", "score": "0.6059667", "text": "function normalizeEventName(name, opt_prefix) {\n var prefix = opt_prefix || 'tc';\n return prefix + name.charAt(0).toUpperCase() + name.slice(1);\n}", "title": "" }, { "docid": "0ebf683613a7185bae7b80e9ef418b46", "score": "0.6055153", "text": "function onEvent(name, event) {\n console.log(name, JSON.stringify(event, null, 2));\n }", "title": "" }, { "docid": "01bea9f98cc2a207aef842f6ac5f3b78", "score": "0.604158", "text": "day(event, title) {\n return event.title;\n }", "title": "" }, { "docid": "835446e00d2ecb39c4f20755da767984", "score": "0.6022313", "text": "function getJabraTypeApiCallabackEventName(eventName) {\r\n return eventName;\r\n}", "title": "" }, { "docid": "c3a5217b66c3eeb1240ccd696bc9aa1a", "score": "0.60176146", "text": "function getEventInfo(name) {\n ticketmaster(process.env.TICKETMASTER_KEY ).discovery.v2.event.find(name)\n .then(function(result) {\n \n console.log(\"The event is: \" + result.items[0].name);\n console.log(\"The event's URL is: \" + result.items[0].url);\n \n }).catch(function(err){\nconsole.log(err);\n });\n \n}", "title": "" }, { "docid": "eb3e75452d2eee646d0f87b5c1900f4d", "score": "0.60136706", "text": "function getLeftMostName(e) {\n return ts.isIdentifier(e) ? e : ts.isPropertyAccessExpression(e) ? getLeftMostName(e.expression) : undefined;\n }", "title": "" }, { "docid": "f4df2a0175755decd145ff3b4abe8ba5", "score": "0.6009294", "text": "get PATTERN_EVENT_NAMES() {return (() => {\n\t\t\treturn Composite.EVENTS.replace(/(?:\\||\\b)(\\w)/g, (match, letter) =>\n\t\t\t\tletter.toUpperCase()).split(/\\s+/);\n\t\t})();}", "title": "" }, { "docid": "ebab1360b5ea8ce4c7e292bfe91c118c", "score": "0.6001974", "text": "getEvent(nameOrSignatureOrTopic) {\n if (Object(_ethersproject_bytes__WEBPACK_IMPORTED_MODULE_2__[\"isHexString\"])(nameOrSignatureOrTopic)) {\n const topichash = nameOrSignatureOrTopic.toLowerCase();\n for (const name in this.events) {\n if (topichash === this.getEventTopic(name)) {\n return this.events[name];\n }\n }\n logger.throwArgumentError(\"no matching event\", \"topichash\", topichash);\n }\n // It is a bare name, look up the function (will return null if ambiguous)\n if (nameOrSignatureOrTopic.indexOf(\"(\") === -1) {\n const name = nameOrSignatureOrTopic.trim();\n const matching = Object.keys(this.events).filter((f) => (f.split(\"(\" /* fix:) */)[0] === name));\n if (matching.length === 0) {\n logger.throwArgumentError(\"no matching event\", \"name\", name);\n }\n else if (matching.length > 1) {\n logger.throwArgumentError(\"multiple matching events\", \"name\", name);\n }\n return this.events[matching[0]];\n }\n // Normlize the signature and lookup the function\n const result = this.events[_fragments__WEBPACK_IMPORTED_MODULE_8__[\"EventFragment\"].fromString(nameOrSignatureOrTopic).format()];\n if (!result) {\n logger.throwArgumentError(\"no matching event\", \"signature\", nameOrSignatureOrTopic);\n }\n return result;\n }", "title": "" }, { "docid": "88938184361abe904ad61e149a7103d4", "score": "0.5944746", "text": "function name(ev) {\n var point = ev.key || ev.keyIdentifier || codepoint(ev.keyCode);\n return KEYS[point] || point;\n }", "title": "" }, { "docid": "6b8b9e5c0aeb6a2c54518dc29001ce2d", "score": "0.5911112", "text": "get eventBusNameInput() {\n return this._eventBusName;\n }", "title": "" }, { "docid": "4498a21540ff64182e306c1c8077954d", "score": "0.58966225", "text": "static __extractPropertyNameFromLambdaExpression(parentAtom, expression){\n\t\tlet propertyName = expression.toString().split(\".\").pop();\n\t\tif(propertyName.indexOf(\"=>\")>-1){\t\t\n\t\t\tthrow new Error(\"Could not determine property name to create binding from lambda expression '\" + expression + \"'\")\n\t\t}\n\t\t\n\t\tif(!(propertyName in parentAtom)){\n\t\t\tthrow new Error('Unknown property \"' + propertyName + '\" of atom \"' + parentAtom.name + '\".');\n\t\t}\n\n\t\treturn propertyName;\n\t}", "title": "" }, { "docid": "e91382123dc89a52ae3be7700b710004", "score": "0.5851669", "text": "format(event) {\n if (event.charAt(0) === '.' || event.charAt(0) === '\\\\') {\n return event.substr(1);\n }\n else if (this.namespace) {\n event = this.namespace + '.' + event;\n }\n return event.replace(/\\./g, '\\\\');\n }", "title": "" }, { "docid": "7ffe014e5917d4629cd0fd101895c6f1", "score": "0.58185554", "text": "get filename() {\n // @ts-ignore\n const files = this.rotator.auditLog.files;\n return files[files.length - 1].name;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "6632b8aab4869d82916df2b584ec748b", "score": "0.58178455", "text": "function normalizeEventName (eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n }\n else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "10cd76504f108700686f9a8cda84527f", "score": "0.580648", "text": "static getEvent() {\r\n\t\tconsole.log(event);\r\n\t\treturn this.event;\r\n\t}", "title": "" }, { "docid": "852f36604a2e1183c96cb210f762532b", "score": "0.58004504", "text": "function normalizeEventName (eventName) {\n\t if (eventName.indexOf('on') !== 0) {\n\t if (eventName[0] !== eventName[0].toUpperCase()) {\n\t eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n\t }\n\t else {\n\t eventName = 'on' + eventName;\n\t }\n\t }\n\t return eventName;\n\t }", "title": "" }, { "docid": "852f36604a2e1183c96cb210f762532b", "score": "0.58004504", "text": "function normalizeEventName (eventName) {\n\t if (eventName.indexOf('on') !== 0) {\n\t if (eventName[0] !== eventName[0].toUpperCase()) {\n\t eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n\t }\n\t else {\n\t eventName = 'on' + eventName;\n\t }\n\t }\n\t return eventName;\n\t }", "title": "" }, { "docid": "dcda39a1089b5d6f90e82e8a30111961", "score": "0.5793618", "text": "function normalizeEventName(eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n } else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "dcda39a1089b5d6f90e82e8a30111961", "score": "0.5793618", "text": "function normalizeEventName(eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n } else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "dcda39a1089b5d6f90e82e8a30111961", "score": "0.5793618", "text": "function normalizeEventName(eventName) {\n if (eventName.indexOf('on') !== 0) {\n if (eventName[0] !== eventName[0].toUpperCase()) {\n eventName = 'on' + eventName[0].toUpperCase() + eventName.substring(1);\n } else {\n eventName = 'on' + eventName;\n }\n }\n return eventName;\n }", "title": "" }, { "docid": "8583ee41e2632fccd174250211f238cc", "score": "0.5790789", "text": "get eventMessage() {\n var _a;\n return (_a = this._eventData.event_data.message) !== null && _a !== void 0 ? _a : '';\n }", "title": "" }, { "docid": "5e1d847430831db60ad3fa1ccabbfb9b", "score": "0.578972", "text": "getClassName(){return \"Core.UI.Events.UserEvent.UserEvent\";}", "title": "" }, { "docid": "7449f55640dbbea3a6a77edc64132a87", "score": "0.5786126", "text": "function obtener_evento(event) {\n console.log(`EVENTO: ${event.type}`);\n}", "title": "" }, { "docid": "4b773c7d646b87980f3e101153e5fe07", "score": "0.57829154", "text": "week(event, title) {\n return event.title;\n }", "title": "" }, { "docid": "b8c7ad162e0fd8130d6c13e990b887d2", "score": "0.5766896", "text": "parseEventKey(eventKey) {\n if (eventKey.match(/^C_/)) {\n return { eventName: eventKey.substring(2), capture: true };\n } else {\n return { eventName: eventKey, capture: false };\n }\n }", "title": "" }, { "docid": "67605ae56845b57b49039a6523cf70f0", "score": "0.5742883", "text": "formattedEvent(event) {\n // console.log(`formattedEvent called!`); //DEBUG\n return event;\n }", "title": "" }, { "docid": "8f926f813b34f70db72ebce2d62e0500", "score": "0.5738185", "text": "eventNames() {\n\t\tlet events = this[ EVENTS ];\n\t\tif (!events) { return []; }\n\n\t\treturn Object.keys(events).concat(Object.getOwnPropertySymbols(events));\n\t}", "title": "" }, { "docid": "f6328a498f998baebe1983d6d07437dc", "score": "0.57196075", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n return event.event_id || '<unknown>';\n}", "title": "" }, { "docid": "f6328a498f998baebe1983d6d07437dc", "score": "0.57196075", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n return event.event_id || '<unknown>';\n}", "title": "" }, { "docid": "f6328a498f998baebe1983d6d07437dc", "score": "0.57196075", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n return event.event_id || '<unknown>';\n}", "title": "" }, { "docid": "f6328a498f998baebe1983d6d07437dc", "score": "0.57196075", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n return event.event_id || '<unknown>';\n}", "title": "" }, { "docid": "9168866adf01586738b9f09f4d7149bf", "score": "0.5709567", "text": "function getEventDescription(event) {\n var message = event.message, eventId = event.event_id;\n if (message) {\n return message;\n }\n var firstException = getFirstException(event);\n if (firstException) {\n if (firstException.type && firstException.value) {\n return firstException.type + \": \" + firstException.value;\n }\n return firstException.type || firstException.value || eventId || '<unknown>';\n }\n return eventId || '<unknown>';\n}", "title": "" }, { "docid": "3e131a06c5ee44d7ea3fe833f8e8a466", "score": "0.5703417", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n return event.event_id || '<unknown>';\n }", "title": "" }, { "docid": "63d046fd1be693329003e1a3a479a994", "score": "0.56979114", "text": "dayTooltip(event, title) {\n return event.title;\n }", "title": "" }, { "docid": "b7db8f26a33b5cd813e18fe79f23c748", "score": "0.5695666", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n else if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n else {\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n }\n else {\n return event.event_id || '<unknown>';\n }\n}", "title": "" }, { "docid": "b7db8f26a33b5cd813e18fe79f23c748", "score": "0.5695666", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n else if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n else {\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n }\n else {\n return event.event_id || '<unknown>';\n }\n}", "title": "" }, { "docid": "b7db8f26a33b5cd813e18fe79f23c748", "score": "0.5695666", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n else if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n else {\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n }\n else {\n return event.event_id || '<unknown>';\n }\n}", "title": "" }, { "docid": "b7db8f26a33b5cd813e18fe79f23c748", "score": "0.5695666", "text": "function getEventDescription(event) {\n if (event.message) {\n return event.message;\n }\n else if (event.exception && event.exception.values && event.exception.values[0]) {\n var exception = event.exception.values[0];\n if (exception.type && exception.value) {\n return exception.type + \": \" + exception.value;\n }\n else {\n return exception.type || exception.value || event.event_id || '<unknown>';\n }\n }\n else {\n return event.event_id || '<unknown>';\n }\n}", "title": "" }, { "docid": "9283a2fa00f89f7b3ed1da4ca8fb8e50", "score": "0.5671894", "text": "function normalizeTrackingEventName(eventName) {\n\t\t var answer = eventName;\n\n\t\t // map eventnames found in VAST tags or appnexus structure to standard tracking event name\n\t\t switch (eventName) {\n\t\t case \"impressionUrls\" :\n\t\t\t answer = \"impression\";\n\t\t\t break;\n\n\t\t case \"clickTrackingUrls\" :\n\t\t case \"click\" :\n\t\t\t answer = \"ad-click\";\n\t\t\t break;\n\n\t\t case \"errorUrls\" :\n\t\t\t //answer = \"vast-error\";\n\t\t\t answer = \"error\";\n\t\t\t break;\n\n\t\t case \"imp_tracking_url\" :\n\t\t\t answer = \"bid-impression\";\n\t\t\t break;\n\n\t\t case \"init_cb\" :\n\t\t\t answer = \"ad-request\";\n\t\t\t break;\n\n\t\t case \"result_cb\" :\n\t\t\t answer = \"ad-response\";\n\t\t\t break;\n\n\t\t case \"start\" :\n\t\t\t answer = \"video-start\";\n\t\t\t break;\n\n\t\t case \"firstQuartile\" :\n\t\t\t answer = \"video-first-quartile\";\n\t\t\t break;\n\n\t\t case \"midpoint\" :\n\t\t\t answer = \"video-mid\";\n\t\t\t break;\n\n\t\t case \"thirdQuartile\" :\n\t\t\t answer = \"video-third-quartile\";\n\t\t\t break;\n\n\t\t case \"thirdQuartile\" :\n\t\t\t answer = \"video-third-quartile\";\n\t\t\t break;\n\n\t\t case \"complete\" :\n\t\t\t answer = \"video-complete\";\n\t\t\t break;\n\n\t\t case \"unmute\" :\n\t\t\t answer = \"audio-unmute\";\n\t\t\t break;\n\n\t case \"mute\" :\n\t answer = \"audio-mute\";\n\t break;\n\n\t\t case \"pause\" :\n\t\t\t answer = \"video-pause\";\n\t\t\t break;\n\n\t\t case \"rewind\" :\n\t\t\t answer = \"rewind\";\n\t\t\t break;\n\n\t\t case \"resume\" :\n\t\t\t answer = \"video-resume\";\n\t\t\t break;\n\n\n\t\t case \"fullscreen\" :\n\t\t\t answer = \"video-fullscreen\";\n\t\t\t break;\n\n\t\t case \"exitFullscreen\" :\n\t\t\t answer = \"video-exit-fullscreen\";\n\t\t\t break;\n\n\t\t case \"creativeView\" :\n\t\t\t answer = \"creative-view\";\n\t\t\t break;\n\n\t\t case \"expand\" :\n\t\t\t answer = \"ad-expand\";\n\t\t\t break;\n\n\t\t case \"collapse\" :\n\t\t\t answer = \"ad-collapse\";\n\t\t\t break;\n\n\t\t case \"acceptInvitation\" :\n\t\t\t answer = \"user-accept-invitation\";\n\t\t\t break;\n\n\t\t case \"close\" :\n\t\t\t answer = \"user-close\";\n\t\t\t break;\n\n\t\t case \"progress\" :\n\t\t\t answer = \"ad-progress\";\n\t\t\t break;\n\n\t case \"skip\" :\n\t answer = \"video-skip\";\n\t break;\n\t\t }\n\n\t\t return answer;\n\t }", "title": "" }, { "docid": "a2730145ff7a29d46ad88ff10451958e", "score": "0.5667013", "text": "extractDocumentName()\n {\n \treturn this.getDocumentName() || '';\n }", "title": "" }, { "docid": "8d53a674504a6425778681531bd3025c", "score": "0.5653477", "text": "function id(evt) { return '__' + evt + '__'; }", "title": "" }, { "docid": "e84f81a5c1c456f6dbe9b495891bbea8", "score": "0.5642228", "text": "function EventInfo() { }", "title": "" }, { "docid": "b2181d786cf78fa999946306315c3774", "score": "0.56412095", "text": "function getName(expression/*:String*/)/*:String*/ {\n var timeSlot/*:Object*/;\n for(var i/*:int*/ =0; this.timeSlots.length; i++) {\n timeSlot = this.timeSlots[i];\n if (timeSlot.expression == expression){\n return timeSlot.name;\n }\n }\n return undefined;\n }", "title": "" }, { "docid": "72b685d4cd2ac4e81231f23f9dad19de", "score": "0.56283575", "text": "function getPrefixEventName (evtName) {\n\tswitch (evtName) {\n\tcase \"transitionend\":\n\t\tif (prefixProperty(document.body.style, \"transitionProperty\", true) == \"webkit\") {\n\t\t\tevtName = \"webkitTransitionEnd\";\n\t\t}\n\t\tbreak;\n\tdefault:\n\t\tbreak;\n\t}\n\treturn (evtName);\n}", "title": "" } ]
35f489209cfda222acbc996a7686e563
fetch cases per LGA
[ { "docid": "3fa14e57b94d2006b78fa1ec18448a09", "score": "0.64718074", "text": "async getCasesLGA() {\n try {\n let data = await this.fetchJson(cases_query);\n return data.features;\n } catch(err){\n console.log(err)\n }\n }", "title": "" } ]
[ { "docid": "635dc034347527b523a15e077989b350", "score": "0.56419855", "text": "async function getCases(cases) {\n const response = await fetch(cases)\n const data = await response.json()\n return data['All']\n}", "title": "" }, { "docid": "08584678fc50c1db0295bd8493e5d70e", "score": "0.5534846", "text": "getCountryCasesPerMillion(includeNoRecord=false){\n let cases = this.getAllCountries(includeNoRecord)\n .map(c => c.getCasesPerMillion())\n return cases\n }", "title": "" }, { "docid": "9108a702d64486e78a535b9b77974079", "score": "0.54256666", "text": "function getData(cnt) {\n var data = [];\n for (var i = 0; i < cnt; i++) {\n data.push({\n id: i,\n country: [\n countries[Math.floor(Math.random() * countries.length)],\n countries[Math.floor(Math.random() * countries.length)],\n countries[Math.floor(Math.random() * countries.length)]\n ].join(\",\"),\n active: i % 5 != 0,\n downloads: Math.round(Math.random() * 200000),\n sales: Math.random() * 100000,\n expenses: Math.random() * 50000\n });\n }\n data.push({id: 10, country: 'UK', active: 0, downloads: 10, sales: 12, expenses: 50})\n return data;\n}", "title": "" }, { "docid": "ac2de207fab75a7d23a57b382d9cd6b9", "score": "0.53778106", "text": "function fetchAll() {\n var url = \"http://worldcup.sfg.io/matches\";\n fetchScores(\"ALL\", url);\n}", "title": "" }, { "docid": "7aeced6437821d032c61abe8280117c6", "score": "0.5368583", "text": "profileNumberLookups(count) {\n let index = RangedIndexFactoryMap[\"avl\"](\"last\", ComparatorMap[\"js\"]);\n let start, end;\n let totalTimes = [];\n let totalMS = 0.0;\n let rnd;\n let valbuf = [];\n // insert into index\n for (let idx = 1; idx <= count; idx++) {\n rnd = count - idx;\n index.insert(idx, rnd);\n valbuf.push(rnd);\n }\n //valbuf = this.shuffle(valbuf);\n let result = [];\n for (let idx = 0; idx < count; idx++) {\n start = process.hrtime();\n result = index.rangeRequest({ op: \"$eq\", val: valbuf[idx] });\n end = process.hrtime(start);\n totalTimes.push(end);\n if (result.length !== 1) {\n throw new Error(\"Did not find previously inserted value\");\n }\n }\n for (var idx = 0; idx < totalTimes.length; idx++) {\n totalMS += totalTimes[idx][0] * 1e3 + totalTimes[idx][1] / 1e6;\n }\n let rate = count * 1000 / totalMS;\n console.log(\"rangeRequest lookups (number value) : \" + totalMS.toFixed(2) + \"ms (\" + rate.toFixed(2) + \") ops/s (\" + count + \" documents)\");\n }", "title": "" }, { "docid": "fe73a38417c92916a8aa84e20471eb62", "score": "0.531363", "text": "async function getGlobalCases() {\n setWorld([]);\n\n let url = 'https://coronavirus-19-api.herokuapp.com/all';\n\n await fetch(url)\n .then(response => response.json())\n .then(data => {\n console.log(data);\n setWorld(data)\n })\n .catch(function (error) {\n console.error(\"Erro ao carregar os dados: \" + error.message);\n })\n }", "title": "" }, { "docid": "7ac7c7447314fdf032cc95d54be44d72", "score": "0.52595085", "text": "function getDiceResults(file_label) {\n // state.api.forEachNode(function(rowNode, index) {\n // console.log('node ' + rowNode.data.file_label + ' is in the grid.');\n // });\n\n return ['1st', '2nd', '3rd', '4th', '5th']\n }", "title": "" }, { "docid": "d1fbd8fde50428c672f9a26ab54b2756", "score": "0.5222894", "text": "function agg_celestial_total(dataset) {\n var result_set = []\n for (var c = 0; c < celestials.length; c++) {\n var subset = dataset.filter(d => d.celestial === celestials[c]);\n var sci_total = 0;\n var cap_total = 0;\n for (var l = 0; l < subset.length; l++) {\n sci_total += subset[l].sci;\n cap_total += subset[l].cap;\n }\n result_set.push({\n \"experiment\": \"\", \"location\": \"\", \"sci\": sci_total, \"cap\": cap_total, \"celestial\": celestials[c], \"biome\": \"\", situation: \"\"\n });\n }\n return result_set;\n}", "title": "" }, { "docid": "e9c4cd29db221b9102d7857c5c70f202", "score": "0.52222246", "text": "function getData() {\n var data = [];\n for (var i = 0; i < 200; i++) {\n data.push({\n id: i,\n country: countries[Math.floor(Math.random() * countries.length)],\n active: i % 5 != 0,\n downloads: Math.round(Math.random() * 200000),\n sales: Math.random() * 100000,\n expenses: Math.random() * 50000\n });\n }\n return data;\n}", "title": "" }, { "docid": "eaeb373cc7cc5178438192177bb34c96", "score": "0.51510656", "text": "async getAllCases (projectId) {\n\t\tconst method = 'get_cases/';\n\t\tconst pathname = path.join(`${method}`, `${projectId}`);\n\t\tconst url = this.host + pathname;\n\t\tconst options = {\n\t\t\tmethod: 'GET',\n\t\t\theaders: this.headers\n\t\t};\n\n\t\tconst data = await this.myFetch(url, options, 'Provided projectId is not valid');\n\t\treturn await data;\n\t}", "title": "" }, { "docid": "2de6e3b137dd228c2dc8bd7322b9f085", "score": "0.51476467", "text": "async getDashboadStat({params, response}){\n \n let analytics = new Object()\n\n /*------------------*/\n // GRAPH STAT LOGIC\n /*------------------*/\n\n // STEP 1: Select list of element fro the current year \n /*Current Year*/ \n let date = new Date();\n const currentyears = date.getFullYear()\n const yearsstart = currentyears + '-01-01 00:00:00'\n const yearsEnd = currentyears + '-12-31 00:00:00'\n /*For Registred station*/\n const thisYearsregistredStationNotInJSON = await companiesStation\n .query()\n .where('companyCentral_id', params.id)\n .whereBetween('created_at', [yearsstart, yearsEnd])\n .select('id', 'created_at')\n .fetch()\n const thisYearsregistredStation = thisYearsregistredStationNotInJSON.toJSON()\n analytics.registredStationNumber = thisYearsregistredStation.length\n /*For Ticket vendus*/\n let allticketSold = []\n const allstationOftheCompany = await companiesStation\n .query()\n .where('companyCentral_id', params.id)\n .select('id', 'created_at')\n .fetch()\n const allstationOftheCompan = allstationOftheCompany.toJSON()\n for (let index = 0; index < allstationOftheCompan.length; index++) {\n const thisYearsTicketsoldNotInJSON = await Tickets\n .query()\n .innerJoin('Travels', 'travels.id', 'Tickets.travel_id')\n .where('company_id', allstationOftheCompan[index].id)\n .whereNot('ticket_state_id', 1)\n .whereBetween('Tickets.created_at', [yearsstart, yearsEnd])\n .select('Tickets.id', 'Tickets.created_at')\n .fetch()\n const thisYearsTicketsold = thisYearsTicketsoldNotInJSON.toJSON()\n for (let i = 0; i < thisYearsTicketsold.length; i++) {\n allticketSold.push(thisYearsTicketsold[i]) \n }\n }\n analytics.TicketsoldNumber = allticketSold.length\n \n /*For Expedition*/\n const thisYearsExpeditionsNotInJSON = await Expeditions\n .query()\n .innerJoin('companies', 'companies.id', 'Expeditions.company_id')\n .where('companyCentral_id', params.id)\n .whereBetween('Expeditions.created_at', [yearsstart, yearsEnd])\n .select('Expeditions.id', 'Expeditions.created_at')\n .fetch()\n const thisYearsExpeditions = thisYearsExpeditionsNotInJSON.toJSON()\n analytics.ExpeditionsNumber = thisYearsExpeditions.length\n // comapaniesCentral.findBy('id', params.id) \n // await thisYearsExpeditionsNotInJSON.expeditions()\n /*For Declared Travel*/\n const thisYearsdeclaredTravelsNotInJSON = await Travels\n .query()\n .innerJoin('companies', 'companies.id', 'Travels.company_id')\n .where('companyCentral_id', params.id)\n .where('annulation_state', 0)\n .whereBetween('Travels.created_at', [yearsstart, yearsEnd])\n .select('Travels.id', 'Travels.created_at')\n .fetch()\n const thisYearsdeclaredTravels = thisYearsdeclaredTravelsNotInJSON.toJSON()\n /*For Expedition Do*/\n const thisYearsExpeditionsDoNotInJSON = await Expeditions\n .query()\n .innerJoin('companies', 'companies.id', 'Expeditions.company_id')\n .where('companyCentral_id', params.id)\n .where('expedition_state_id', 7)\n .whereBetween('Expeditions.created_at', [yearsstart, yearsEnd])\n .select('Expeditions.id', 'Expeditions.created_at')\n .fetch()\n const thisYearsExpeditionsDo = thisYearsExpeditionsDoNotInJSON.toJSON()\n analytics.ExpeditionsDo = thisYearsExpeditionsDo.length\n /*For Travel Do*/\n const currentMonthPlusOne = date.getMonth()+1\n const currentDay = date.getDate()\n const dateLimitTwo = currentyears + \"-\" + currentMonthPlusOne + \"-\" + currentDay\n const thisYearsTravelDosNotInJSON = await Travels\n .query()\n .innerJoin('companies', 'companies.id', 'Travels.company_id')\n .where('companyCentral_id', params.id)\n .where('annulation_state', 0)\n .whereBetween('Travels.created_at', [yearsstart, dateLimitTwo])\n .select('Travels.id', 'Travels.created_at')\n .fetch()\n const thisYearsTravelDos = thisYearsTravelDosNotInJSON.toJSON()\n analytics.TravelDo = thisYearsTravelDos.length\n /*For find Objets */\n const thisYearsLostObjetNotInJSON = await LostObjets\n .query()\n .innerJoin('companies', 'companies.id', 'lost_objets.company_id')\n .where('companyCentral_id', params.id)\n .where('declaration_state', 1)\n .whereBetween('lost_objets.created_at', [yearsstart, yearsEnd])\n .select('lost_objets.id', 'lost_objets.created_at')\n .fetch()\n const thisYearsLostObjetThings = thisYearsLostObjetNotInJSON.toJSON()\n analytics.FindObjet = thisYearsLostObjetThings.length\n\n\n // STEP 2: init the month table\n /*Current month*/ \n let currentdate = new Date();\n const currentmonth = currentdate.getMonth()+1\n /*Initialisation*/ \n let monthTable = []\n for (let index = 0; index < currentmonth; index++) {\n monthTable[index] = {'month': index + 1, 'data': [0,0,0,0,0,0,0]} \n }\n\n\n\n // STEP 3: converte creat at .....\n /*For registred stations*/\n for (let index = 0; index < thisYearsregistredStation.length; index++) {\n // Get the month\n let date = new Date(thisYearsregistredStation[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[0] += 1\n }\n } \n }\n /*For companies get*/\n for (let index = 0; index < allticketSold.length; index++) {\n // Get the month\n let date = new Date(allticketSold[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[1] += 1\n }\n } \n }\n /*For Expedition*/\n for (let index = 0; index < thisYearsExpeditions.length; index++) {\n // Get the month\n let date = new Date(thisYearsExpeditions[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[2] += 1\n }\n } \n }\n /*For declared travels*/\n for (let index = 0; index < thisYearsdeclaredTravels.length; index++) {\n // Get the month\n let date = new Date(thisYearsdeclaredTravels[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[3] += 1\n }\n } \n }\n /*For Expediotion do*/\n for (let index = 0; index < thisYearsExpeditionsDo.length; index++) {\n // Get the month\n let date = new Date(thisYearsExpeditionsDo[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[4] += 1\n }\n } \n }\n /*For Travels do*/\n for (let index = 0; index < thisYearsTravelDos.length; index++) {\n // Get the month\n let date = new Date(thisYearsTravelDos[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[5] += 1\n }\n } \n }\n /*For Lost Objet Find*/\n for (let index = 0; index < thisYearsLostObjetThings.length; index++) {\n // Get the month\n let date = new Date(thisYearsLostObjetThings[index].created_at);\n var month = date.getMonth()+1\n // Verify if there are a corresponding on monthTable\n for (let index = 0; index < monthTable.length; index++) { \n if (monthTable[index].month == month) {\n monthTable[index].data[6] += 1\n }\n } \n }\n \n\n\n // STEP 4: Extract data \n let GraphData = {'series': [{'name': 'Gares enregistrées', 'data':[]},{'name': 'Tickets vendus', 'data':[]},{'name': 'Expedition', 'data':[]}, {'name': 'voyages declarés pas annulés', 'data':[]}, {'name': 'Expeditions effectuées', 'data':[]}, {'name': 'voyages éffectués', 'data':[]}, {'name': 'Objets trouvés', 'data':[]} ], 'month': []}\n let MonthInLetter = ['Janvier', 'Fevrier', 'Mars', 'Avril', 'Mai', 'Juin', 'Juillet', 'Aout', 'Septembre', 'Octobre', 'Novembre', 'Decembre']\n \n for (let index = 0; index < monthTable.length; index++) {\n GraphData.series[0].data[index] = monthTable[index].data[0] \n GraphData.series[1].data[index] = monthTable[index].data[1] \n GraphData.series[2].data[index] = monthTable[index].data[2] \n GraphData.series[3].data[index] = monthTable[index].data[3]\n GraphData.series[4].data[index] = monthTable[index].data[4] \n GraphData.series[5].data[index] = monthTable[index].data[5]\n GraphData.series[6].data[index] = monthTable[index].data[6]\n\n GraphData.month[index] = MonthInLetter[index]\n }\n\n // // console.log(monthTable);\n // // console.log(GraphData);\n\n\n\n\n\n\n\n\n // // console.log(monthTable);\n analytics.GraphData = GraphData\n\n\n\n\n\n\n\n\n\n\n response.json({\n message: 'success',\n data: analytics,\n })\n \n\n \n }", "title": "" }, { "docid": "6fbc62d8235c77d5e55ec1391142c5ff", "score": "0.5109492", "text": "getAll(count, nat) {\n return this.api.get(`/?results=${count}&nat=${nat}`);\n }", "title": "" }, { "docid": "3dbcc1d213331d1da9f492d87d806c57", "score": "0.5099628", "text": "async function getNumberOfCasesPerCountry() {\n /******************************** */\n // should add spinner aka loading \n // compoenent for wait all async\n // code ...\n /******************************** */\n try {\n const CountriesResponse = await fetch('/api/v1/casesbycountry');\n const dataCountries = await CountriesResponse.json(); // should use 2 await with fetch \n // console.log(dataCountries);\n const countries = dataCountries.countries_stat.splice(0,50);\n // console.log(countries);\n const formulatedData = countries.map(async ({ country_name, cases, deaths, total_recovered }) => {\n try {\n // better with template sring --ES6\n const geodataReponse = await fetch(`/api/v1/${country_name}`);\n const geodata = await geodataReponse.json();\n \n const data = { // desturcutre is better for your code --clean-code\n country: country_name,\n nbCases: cases,\n nbDeaths: deaths,\n nbRecovered: total_recovered,\n geoLocation: geodata\n };\n\n return data;\n } catch (error) {\n console.log(error); // you can return or throw error if you want .. \n }\n });\n\n // not the best way but it's work \n // should update the workflow inside \n // the map func .. \n const result = await Promise.all(formulatedData).then(data => data);\n // console.log(result);\n \n return result;\n } catch (error) {\n console.log(err);\n }\n}", "title": "" }, { "docid": "cf3795b9bd7015b22f210b2ea38492b1", "score": "0.5069039", "text": "function getGACovidData() {\n\n // THIS IS THE STATE CODE FROM THE AUTOCOMPLETE RESULT\n const state_short = \"ga\";\n\n fetch(`https://api.covidtracking.com/v1/states/${state_short}/current.json`)\n .then(response => response.json())\n .then(data => {\n //console.log(data);\n drawGACovid(data);\n })\n .catch(err => console.log(err))\n}", "title": "" }, { "docid": "3a61336b07d27d29f9d185bfbd31aafa", "score": "0.50185907", "text": "profileStringLookups(count) {\n let index = RangedIndexFactoryMap[\"avl\"](\"last\", ComparatorMap[\"js\"]);\n let start, end;\n let totalTimes = [];\n let totalMS = 0.0;\n let rnd = \"\";\n let valbuf = [];\n for (let idx = 1; idx <= count; idx++) {\n rnd = this.generateRandomString();\n index.insert(idx, rnd);\n valbuf.push(rnd);\n }\n //valbuf = this.shuffle(valbuf);\n let result = [];\n for (let idx = 0; idx < count; idx++) {\n start = process.hrtime();\n result = index.rangeRequest({ op: \"$eq\", val: valbuf[idx] });\n end = process.hrtime(start);\n totalTimes.push(end);\n if (result.length !== 1) {\n throw new Error(\"Did not find previously inserted value\");\n }\n }\n for (var idx = 0; idx < totalTimes.length; idx++) {\n totalMS += totalTimes[idx][0] * 1e3 + totalTimes[idx][1] / 1e6;\n }\n let rate = count * 1000 / totalMS;\n console.log(\"rangeRequest lookups (string value) : \" + totalMS.toFixed(2) + \"ms (\" + rate.toFixed(2) + \") ops/s (\" + count + \" documents)\");\n }", "title": "" }, { "docid": "51b170bbd64a380e507b16ba8f48f80f", "score": "0.5007195", "text": "function getStatsWorldwide(){\n fetch('https://data.nepalcorona.info/api/v1/world', {\n \"method\": \"GET\",\n \"header\": {\n \"Content-Type\": \"application/json\"\n }\n }).then(result => {\n return result.json();\n }).then(data => {\n console.log(data);\n displayTotalCases(data);\n }).catch(error => {\n console.log(\"error message is \" + error);\n })\n}", "title": "" }, { "docid": "88c188401b2f13191ecbc1fd84283c8c", "score": "0.4987824", "text": "async function getBrazilCases() {\n setBrazil([]);\n\n let url = 'https://coronavirus-19-api.herokuapp.com/countries/Brazil';\n\n await fetch(url)\n .then(response => response.json())\n .then(data => {\n console.log(data);\n setBrazil(data)\n })\n .catch(function (error) {\n console.error(\"Erro ao carregar os dados: \" + error.message);\n })\n }", "title": "" }, { "docid": "b87ffcfacbf21bfe83461b5864e6a04c", "score": "0.49782345", "text": "async function getCases() {\n const cases = await db('cases');\n const tags = await db('tags_by_cases as tbc')\n .leftJoin('tags', 'tbc.tag_id', 'tags.id')\n .leftJoin('main_categories as m', 'tags.main_id', 'm.id')\n .leftJoin('sub_categories as s', 'tags.sub_id', 's.id')\n .select(\n 'tbc.tag_id',\n 'tbc.case_id as case_id',\n 's.sub_category_name as sub_category_name',\n 'm.main_category_name as main_category_name',\n 'tags.tag_name as tag_name'\n );\n\n const casesWithTags = cases.map((obj) => {\n obj.tags = tags.filter((tag) => obj.id === tag.case_id);\n return obj;\n });\n\n return casesWithTags;\n\n // return {\n // cases: cases,\n // tags: tags\n // }\n}", "title": "" }, { "docid": "a199596876b5618891ecc33ca33b080e", "score": "0.49738768", "text": "async function getCard() {\n const min = 0;\n const max = 3;\n const query = datastore\n .createQuery('Card')\n .filter('Index', '>=', min)\n .filter('Index', '<', max)\n //.filter('Index', '=', randNum)\n .order('Index', {descending: true})\n .limit(10);\n return datastore.runQuery(query);\n}", "title": "" }, { "docid": "87af170ea5f5b5321f2cb922f484f677", "score": "0.49735272", "text": "async scraper() {\n const data = await fetch.csv(this.url);\n\n const counties = [];\n for (const utla of data) {\n const name = parse.string(utla.GSS_NM);\n counties.push({\n county: name,\n cases: parse.number(utla.TotalCases)\n });\n }\n\n return counties;\n }", "title": "" }, { "docid": "5a0385b5621db6d2a70734323e3dd0dd", "score": "0.49586877", "text": "async function getCountriesCases() {\n setCountries([]);\n\n let url = 'https://coronavirus-19-api.herokuapp.com/countries';\n\n await fetch(url)\n .then(response => response.json())\n .then(data => {\n console.log(data);\n setCountries(data)\n })\n .catch(function (error) {\n console.error(\"Erro ao carregar os dados: \" + error.message);\n })\n }", "title": "" }, { "docid": "3fdf0d5f45d9fbc1f08f4e51cd80d7b3", "score": "0.49533823", "text": "function getCapacity() {\r\n\tconsole.log('getting garage capacities..')\r\n\tfor (let i = 0; i < garageId.length; i++) {\r\n\r\n\t\tconst getParkingId = getFiles(garageId[i])\r\n\t\tconst check = getParkingId.parkingFacilityInformation.hasOwnProperty('specifications')\r\n\r\n\t\tif (check) {\r\n\r\n\t\t\tif (getParkingId.parkingFacilityInformation.specifications[0] === null || getParkingId.parkingFacilityInformation.specifications[0] === undefined) {\r\n\r\n\t\t\t} else if (getParkingId.parkingFacilityInformation.specifications.hasOwnProperty('capacity') == true) {\r\n\r\n\t\t\t\tconst getCapacity = getParkingId.parkingFacilityInformation.specifications[0].capacity\r\n\t\t\t\tgarageCap.push(getCapacity)\r\n\t\t\t} else {\r\n\r\n\t\t\t\tconst getCapacity = getParkingId.parkingFacilityInformation.specifications[0].capacity\r\n\t\t\t\tgarageCap.push(getCapacity)\r\n\t\t\t}\r\n\r\n\t\t} else {\r\n\r\n\r\n\t\t}\r\n\t}\r\n}", "title": "" }, { "docid": "388f6c7016021a3f031006d8bd1873f3", "score": "0.4952689", "text": "function searchByKeyword() {\n\n LayerGroup.clearLayers();\n let url = `http://lipas.cc.jyu.fi/api/sports-places?searchString=${input.value}&typeCodes=4404&pageSize=100&page=`;\n let encodedApiUrl = encodeURIComponent(url);\n\n for (let k = 1; k < 7; k++) {\n fetch(proxyUrl + encodedApiUrl + k).\n then(function(response) {\n return response.json();\n }).then(function(data) {\n\n console.log(data);\n\n for (let j = 0; j < data.length; j++) {\n findTrail(data[j]);\n }\n document.querySelector('pre').innerHTML = JSON.stringify(data, null,\n 2);\n }).catch(function(error) {\n console.log(error);\n });\n }\n}", "title": "" }, { "docid": "745a7a28765b70324fc2eb2e5a7400d7", "score": "0.4951057", "text": "function kata6() {\n let arr = []\n for (let i = 3; i<100; i++){\n if (i%3 === 0) {\n arr.push(i)\n }\n }\n showResults(`KATA 6 : [ ${arr} ]`)\n\n}", "title": "" }, { "docid": "980fb4d034222c3fb80b53e4fc286fc9", "score": "0.4940683", "text": "function loadTop100CG(){\n //Empty out coin array\n coinArray = [];\n\n var currency = \"vs_currency=inr\";\n fetch(url + \"/coins/markets?\" + currency).then(response => {\n response.json().then(object => {\n object.forEach(coin => {\n //Adds each coin to a global coin array\n coinArray.push(coin);\n });\n }).then(()=>{\n //Sorted by market cap\n console.log(\"Coins refreshed: \");\n console.log(coinArray);\n refreshFromArray();\n });\n });\n}", "title": "" }, { "docid": "bcc30c1718065a79747b4164034618ef", "score": "0.49356782", "text": "function getAllMatchesLeag(ligaid, elemid, cprogressid) {\n\n if ('caches' in window) {\n caches.match(base_url + \"competitions/\" + ligaid + \"/matches\").then(function(response) {\n if (response) {\n response.json().then(function(data) {\n allMatchesleagHtml(data, elemid, cprogressid);\n })\n }\n })\n }\n\n fetch(base_url + \"competitions/\" + ligaid + \"/matches\", api_token)\n .then(status)\n .then(json)\n .then(function(data) {\n allMatchesleagHtml(data, elemid, cprogressid);\n })\n .catch(error);\n}", "title": "" }, { "docid": "111d621e9ab768eb8c8c5e43d3d28910", "score": "0.49276897", "text": "async function getAllData(){\n await getData('UCLA', UCLA_LAT, UCLA_LNG);\n await getData('UCD', UCD_LAT,UCD_LNG);\n await getData('UCB', UCB_LAT,UCB_LNG);\n await getData('UCI', UCI_LAT,UCI_LNG);\n await getData('UCM', UCM_LAT,UCM_LNG);\n await getData('UCR', UCR_LAT,UCR_LNG);\n await getData('UCSD', UCSD_LAT,UCSD_LNG);\n await getData('UCSB', UCSB_LAT,UCSB_LNG);\n await getData('UCSC', UCSC_LAT,UCSC_LNG);\n}", "title": "" }, { "docid": "ee83cab7389921ef424b613d669458ad", "score": "0.49213827", "text": "async function evaluateDCGatK(results, k) {\n var dcg = 0;\n let hits = results.hits.hits;\n for (var i = 0; i < hits.length; i++) {\n if (i == k) {\n break;\n }\n let hitId = hits[i]._source.id;\n\n let relevance = resultListEval.includes(hitId) | 0;//binary, so we just take if it is relevant or not\n let dividend = Math.pow(2, relevance) - 1;\n let divisor = Math.log(i + 1 + 1); //i+1 to start from 1, using ln just like mentioned in croft et al\n dcg += dividend / divisor;\n\n }\n return dcg;\n}", "title": "" }, { "docid": "f609f5a7f48c086ea232c91964c9a5f5", "score": "0.49132255", "text": "getAllCountries(db){\n return db\n .distinct()\n .from('data')\n .pluck('country');\n }", "title": "" }, { "docid": "4c1b579868170de2a0c7df20c6ea5bdc", "score": "0.49085966", "text": "function serviceLane(n, w, cases) {\n let maxes = [];\n for (var c in cases) {\n let i = cases[c][0];\n let j = cases[c][1];\n\n let max = 100000;\n\n for (var k = i; k < j + 1; k++) {\n max = Math.min(max, w[k]);\n }\n maxes.push(max);\n }\n\n return maxes;\n}", "title": "" }, { "docid": "0a54827db086b542a3d13c7ffaadfce3", "score": "0.49080667", "text": "fetchData() {\n const db = this.props.session;\n\n const election = db.Election.first();\n if (!election) return null;\n\n const counties = db.Division\n .filter(d =>\n d.level === 'county' &&\n d.code.substr(0, 2) === window.appConfig.stateFips)\n .toModelArray();\n\n return election.serializeResults(counties);\n }", "title": "" }, { "docid": "79e9c01e122da7a0e092ce897fa69e76", "score": "0.49073702", "text": "getGameCounts() {\n return this._fetch(`${API}gameCounts?key=${this.key}`);\n }", "title": "" }, { "docid": "95651c338fd3edc96a8794bcf9b582dd", "score": "0.4901301", "text": "static getAggregatedList(){\n let records = this.records\n let results = []\n\n // Iterate through all category names\n this.allNames.forEach(function (category){\n // Set the values for current category\n values.reset()\n \n // If a records category matches current category add it to values\n records.forEach(function (record){\n if(record['category'] == category){ values.add(record['amount']) }\n })\n \n // Get results of the values added to category and push to results\n results.push(values.getResult(category))\n })\n\n return results\n }", "title": "" }, { "docid": "196e3a1cf1d1b687c9df3e312959ba0b", "score": "0.48992604", "text": "function fetchProviderResults() {}", "title": "" }, { "docid": "c2bf7704c1991adef379d4c4e9964805", "score": "0.48931357", "text": "getAllAccess(param) {\n return new Promise((resolve, reject) => {\n let accessModel = new AccessModel();\n\n accessModel.getAccessLevel().then((access) => {\n let result = [];\n for(let i=0; i<access.length; i++){\n result.push(this.build.accessLevel(access[i]));\n }\n\n return resolve(result);\n }).catch((err) => {\n return reject(err);\n });\n });\n }", "title": "" }, { "docid": "d6d75f9c56b749b7b4314b469c2f302e", "score": "0.4867586", "text": "async function extractData(countryName) {\n try {\n const resDH = await axios.get(`https://covid-api.mmediagroup.fr/v1/history?country=${countryName}&status=deaths`);\n const deathHistory = resDH.data.All;\n\n const resCH = await axios.get(`https://covid-api.mmediagroup.fr/v1/history?country=${countryName}&status=confirmed`);\n const confirmedHistory = resCH.data.All;\n\n const resC = await axios.get(`https://covid-api.mmediagroup.fr/v1/cases?country=${countryName}`);\n const cases = resC.data.All;\n\n return [deathHistory, cases, confirmedHistory]\n }\n catch {\n console.log(\"Error on loading statistics of chosen country\")\n }\n}", "title": "" }, { "docid": "e487c2cf7b42a90d8378565523f1d543", "score": "0.48589963", "text": "getCountryCases(includeNoRecord=false){\n let cases = this.getAllCountries(includeNoRecord)\n .map(c => c.getCases())\n return cases\n }", "title": "" }, { "docid": "253ce8fe5987cc79a311483d1af92af8", "score": "0.48440507", "text": "calculate(grid) {\n\n let heuristicValue = 0;\n\n this.partitions.forEach((partition, ind) => {\n let indices = partition.map(goalInd => this.goalMap[goalInd]);\n heuristicValue += this.dbs[ind].get(...indices);\n });\n\n return heuristicValue;\n }", "title": "" }, { "docid": "426552665be69f4fea6674949868c31d", "score": "0.48347488", "text": "async getCounteriesDetail() {\n //loading set to true till\n this.setState({ loading: true });\n try {\n //make an http call\n const res = await axios.get(\"https://corona.lmao.ninja/v2/countries\");\n // console.log(res);\n //After getting data set the result\n this.setState({ data: res.data });\n\n // const pushCountry = [];\n // var count = 0;\n // for (var i in this.state.data) {\n // // console.log(this.state.data[i].country);\n // pushCountry.push({ name: this.state.data[i].country });\n // count++;\n // }\n this.setState({ count });\n this.setState({ countries: pushCountry });\n //After getting data loading remains false\n\n this.setState({ loading: false });\n // const {countries} =this.state;\n // console.log(typeof countries, typeof res, res);\n } catch (error) {\n //Set loading to true if response fails\n this.setState({ loading: true });\n console.log(error);\n }\n // console.log(res.data);\n // console.log(res.data.cases);\n }", "title": "" }, { "docid": "ed7208d0b69e6946fe816abad7364ff1", "score": "0.48329222", "text": "function _get_agendamensualcampa(){\r\n \tvar count = 0;\r\n var ejecutivosArray = [];\r\n var counts = {};\r\n\r\n // Load your search into memory\r\n var mySearch = search.load({\r\n id: 'customsearch5939'\r\n });\r\n\r\n // Run paged version of search with 1000 results per page\r\n var myPagedData = mySearch.runPaged({\r\n \"pageSize\": 1000\r\n });\r\n\r\n // Iterate over each page\r\n myPagedData.pageRanges.forEach(function(pageRange){\r\n // Fetch the results on the current page\r\n var myPage = myPagedData.fetch({index: pageRange.index});\r\n // Iterate over the list of results on the current page\r\n myPage.data.forEach(function(result){\r\n \t//log.audit('jsonObj result: ', result);\r\n \tvar val_leadsource = result.getValue({name: 'leadsource'});\r\n \tvar text_leadsource = result.getText({name: 'leadsource'});\r\n \tejecutivosArray.push(val_leadsource + \"|\" + text_leadsource);\r\n \tcount++;\r\n });\r\n });\r\n ejecutivosArray.forEach(function(i) { counts[i] = (counts[i]||0) + 1;});\r\n counts.total = count;\r\n return counts;\r\n }", "title": "" }, { "docid": "e4de083a8173ec9cbc37b821384e99c0", "score": "0.48311663", "text": "async function getGameCategory(idg) {\n return await Game.findById(idg)\n .select('riddle_category')\n .lean()\n .cache({ ttl: time });\n}", "title": "" }, { "docid": "aa8458c0cb36eceba4fb3ec059ae4e06", "score": "0.4820825", "text": "function app(nCases, input) {\n\n input.map(line => {\n const paramsArray = line.split(' ').map(x => parseInt(x, 10));\n const K = paramsArray[0];\n const C = paramsArray[1];\n const S = paramsArray[2];\n \n const baseArtworks = getAllPossibleBaseArtwork(K);\n const endArtworks = baseArtworks.map(artwork => complexifyArtwork(artwork, C));\n \n const endArtworksThatHaveGoldInBase = endArtworks.slice(1);\n // const nBaseArtworks = baseArtworks.length;\n const invertedEndArtworksThatHaveGoldInBase = [];\n \n endArtworksThatHaveGoldInBase.forEach(artwork => {\n artwork.forEach((tile, i) => {\n if (!invertedEndArtworksThatHaveGoldInBase[i]) invertedEndArtworksThatHaveGoldInBase[i] = [];\n invertedEndArtworksThatHaveGoldInBase[i].push(tile);\n });\n });\n \n const invertedATHGIBIndexesThatHaveSMinusOneLead = invertedEndArtworksThatHaveGoldInBase.map(invertedArtwork => {\n let nLead = 0;\n invertedArtwork.forEach(tile => !tile ? nLead++ : null);\n // console.log(nLead);\n return nLead <= S - 1;\n });\n \n const l = invertedEndArtworksThatHaveGoldInBase.length;\n const invertedATHGIBIndexesThatHaveSMinusOneLeadNoDuplicates = invertedATHGIBIndexesThatHaveSMinusOneLead.map((isTrueIndex, pos) => {\n if (!isTrueIndex) return isTrueIndex;\n \n for (let i = 0; i < pos; i++) {\n let identical = true;\n for (let j = 0; j < l; j++) {\n if (invertedEndArtworksThatHaveGoldInBase[i][j] !== invertedEndArtworksThatHaveGoldInBase[pos][j]) {\n identical = false;\n }\n }\n if (identical) return false;\n }\n \n return true;\n });\n \n // if (invertedATHGIBIndexesThatHaveSMinusOneLeadNoDuplicates.every(index => !index)) return 'IMPOSSIBLE';\n \n const tilesToReveal = [];\n // console.log(l);\n // console.log(invertedATHGIBIndexesThatHaveSMinusOneLeadNoDuplicates.length)\n for (let i = 0; i < l; i++) {\n if (invertedATHGIBIndexesThatHaveSMinusOneLeadNoDuplicates[i]) tilesToReveal.push(i + 1);\n }\n \n return tilesToReveal.length < S ? 'IMPOSSIBLE' : tilesToReveal.slice(0, S).join(' ');\n // const firstTileToReveal = invertedATHGIBIndexesThatHaveSMinusOneLeadNoDuplicates.indexOf()\n // console.log(invertedATHGIBIndexesThatHaveSMinusOneLeadNoDuplicates);\n // console.log('params:', K, C, S);\n }).map(log);\n}", "title": "" }, { "docid": "ef308202748d9155ebb1a0b2e3be5e22", "score": "0.48184565", "text": "function worldTotalCases() {\n\t\n\tconst fetchPromise = fetch(\"https://covid-19-data.p.rapidapi.com/totals\", {\n\t\t\"method\": \"GET\",\n\t\t\"headers\": {\n\t\t\t\"x-rapidapi-host\": \"covid-19-data.p.rapidapi.com\",\n\t\t\t\"x-rapidapi-key\": \"ce743ee195msha115c2444bd7c14p1a4337jsne97d9e83b40d\"\n\t\t}\n\t})\n\tfetchPromise.then(response => response.json().then( data => {\n\t console.log(data);\n\t confirmed.innerHTML = data[0].confirmed;\n\t recovered.innerHTML = data[0].recovered;\n\t deaths.innerHTML = data[0].deaths;\n\t\n\t})).catch(err => {\n\t console.log(err);\n\t});\n}", "title": "" }, { "docid": "84f8328b7aff545687b17c3db4c696a1", "score": "0.48082554", "text": "function ListGlobalCases(props) {\n const world = props.world;\n //const viewBrazilData = <h2>{brazil.country} - {Number(brazil.cases).toLocaleString(\"pt-br\")} - {Number(brazil.deaths).toLocaleString(\"pt-br\")} - {Number(brazil.recovered).toLocaleString(\"pt-br\")}</h2>\n const viewWorldData = Number(world.cases).toLocaleString(\"pt-br\")\n\n return (\n <h2>\n {viewWorldData}\n </h2>\n );\n }", "title": "" }, { "docid": "6ca277a5bb3d25fc1314d5da553edd87", "score": "0.4804534", "text": "async getDotaMatchTimes() {\n let allMatches = await fetch(\"https://api.opendota.com/api/players/\" + this.state.playerId + \"/matches?limit=\" + this.state.limit, {\n method:\"GET\",\n mode: \"cors\",\n });\n let allMatchesJson = await allMatches.json();\n console.log(\"All matches json \", allMatchesJson);\n allMatchesJson.forEach(element => {\n utilities.storeEntry(element.start_time*1000, element.start_time*1000 + (Number(element.duration) * 1000), \"\\\"dota; game; \" + element.match_id.toString() + \"\\\"\", ['dota', 'game']);\n });\n }", "title": "" }, { "docid": "1ac723fff5cfda6068dc11a232cf852c", "score": "0.4800495", "text": "examSchedule(gid) {\n let a = this.getStudent(gid);\n let cours = new Set();\n a.courses.forEach(course => {\n course.forEach(name => {\n for (let c of this.mapCourses.values())\n if (c.name == name) cours.add(c);\n });\n });\n return cours\n }", "title": "" }, { "docid": "f304cc1955f94bf1922bfb35d3e869dc", "score": "0.47972503", "text": "async function getCategoriesLogical (){\n const catResultLogical = await Mcat\n .find()\n //.or ([{ label:\"Live\" },{countInCat:500}])\n .and ([{ label:\"Live\" },{countInCat:4000}])\n .limit(2)\n .sort({label:1})\n .select({label:1, logo:1})\n console.log(catResultLogical);\n}", "title": "" }, { "docid": "8d83f18d18aa4ca040469f6a4eac13cc", "score": "0.47947776", "text": "function kata1() {\n let arr = []\n for(let i = 1; i<=25; i++) {\n arr.push(i) \n }\n showResults(`KATA 1 : [ ${arr} ]`)\n}", "title": "" }, { "docid": "9f602c537da52bc0c523bd69ce2b84a2", "score": "0.47909245", "text": "function getData(code) {\n let group = code.substring(0, 3);\n let oa_group = code.substring(0, 1) + '00';\n let query = `PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\n PREFIX geoid: <http://statistics.data.gov.uk/id/statistical-geography/>\n PREFIX foi: <http://publishmydata.com/def/ontology/foi/>\n PREFIX measure: <http://statistics.data.gov.uk/def/measurement#>\n SELECT ?code ?name ?area ?group\n WHERE\n {\n geoid:${code} foi:code ?code ;\n foi:displayName ?name ;\n measure:hasExtentOfTheRealmHectarage ?area ;\n foi:memberOf ?grp .\n ?grp rdfs:label ?group .\n }\n LIMIT 1`;\n let children = `PREFIX skos: <http://www.w3.org/2004/02/skos/core#>\n PREFIX geoid: <http://statistics.data.gov.uk/id/statistical-geography/>\n SELECT DISTINCT ?code ?name\n WHERE {\n ?child skos:broader geoid:${code} ;\n skos:notation ?code .\n OPTIONAL {\n ?child skos:prefLabel ?name .\n }\n }\n ORDER BY ?code\n LIMIT 50`;\n let parents = `PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\n PREFIX skos: <http://www.w3.org/2004/02/skos/core#>\n PREFIX geoid: <http://statistics.data.gov.uk/id/statistical-geography/>\n PREFIX geodef: <http://statistics.data.gov.uk/def/statistical-geography#>\n \n SELECT ?code ?name\n WHERE {\n geoid:${code} skos:broader+ ?parent .\n ?parent rdfs:label ?code ;\n geodef:officialname ?name .\n }\n LIMIT 15`;\n let pop = `dataset/NM_144_1.data.csv?date=latest&geography=${code}&rural_urban=0&cell=0&measures=20100&select=obs_value`;\n\n let url = globals.apigeo + encodeURIComponent(query);\n let url2 = globals.apicogs + encodeURIComponent(children);\n let url3 = globals.apicogs + encodeURIComponent(parents);\n let url4 = globals.apinomis + pop;\n\n // Get geodata\n fetch(url)\n .then(response => response.text())\n .then(rawdata => d3.csvParse(rawdata))\n .then(json => {\n if (json[0]) {\n data.selected = json[0];\n\n // let centroid = data.selected.centroid.split(' ');\n // data.selected.lng = +centroid[1].replace('(', '');\n // sdata.selected.lat = +centroid[2].replace(')', '');\n\n // Get children\n fetch(url2)\n .then(response => response.text())\n .then(rawdata => d3.csvParse(rawdata))\n .then(json => {\n if (json[0]) {\n data.selected.children = json;\n }\n\n // Get parents\n fetch(url3)\n .then(response => response.text())\n .then(rawdata => d3.csvParse(rawdata))\n .then(json => {\n if (json[0]) {\n data.selected.parents = json;\n }\n\n // Get population\n fetch(url4)\n .then(response => response.text())\n .then(rawdata => d3.csvParse(rawdata))\n .then(json => {\n if (json[0]) {\n data.selected.population = json[0]['OBS_VALUE'];\n }\n\n updateData(data.selected);\n });\n });\n });\n }\n });\n}", "title": "" }, { "docid": "f563aa3baa1b23e3ab5bbf15d4e60260", "score": "0.4784148", "text": "static async getAllUSDataPerState(){\n let res = await this.request(`data/us-states-all`);\n return res.data;\n}", "title": "" }, { "docid": "21ef1efca200ed235176fa6029d99c82", "score": "0.47817892", "text": "function getWinners(gf) {\n \n const listOfFinals = gf(fifaData)\n const winners = []\n \n listOfFinals.forEach(x => {\n\n if(x['Home Team Goals'] > x['Away Team Goals']) \n winners.push(x['Home Team Name'])\n else if(x['Home Team Goals'] < x['Away Team Goals']) \n winners.push(x['Away Team Name'])\n else \n winners.push(`TIE on ${x['Year']}`)\n })\n\n return winners\n}", "title": "" }, { "docid": "55765b7f7f390aa8f0f95b14c3573ff2", "score": "0.4781726", "text": "async getHistoGlobalCases() {\n\t\tconst response = await fetch(\n\t\t\t`https://disease.sh/v3/covid-19/historical/all?lastdays=all`\n\t\t);\n\t\tconst responseJSON = await response.json();\n\n\t\treturn responseJSON;\n\t}", "title": "" }, { "docid": "863899b8902bbc8b6a8244e2453b27e0", "score": "0.4776782", "text": "function fetchData(aid,gid) {\r\n\tvar req = xhttpRequest();\r\n\tif (gid == null) {\r\n\t\t//First get for group-anime page\r\n\t\tif (isLocalHost()) xhttpRequestFetch(req, 'xml/aid'+aid+'.xml', parseData);\r\n\t\telse xhttpRequestFetch(req, 'animedb.pl?show=xml&t=anime&aid='+aid, parseData);\r\n\t} else if(gid != null && aid != null) {\r\n\t\t//Second get for group-anime page\r\n\t\tif (isLocalHost()) xhttpRequestFetch(req, 'xml/aid'+aid+'_gid'+gid+'.xml', parseEpisodeData);\r\n\t\telse xhttpRequestFetch(req, 'animedb.pl?show=xml&t=ep&aid='+aid+'&eid=all&gid='+gid, parseEpisodeData);\r\n\t} else if(gid != null && aid == null) {\r\n\t\t//Get for group page\r\n\t\tif (isLocalHost()) xhttpRequestFetch(req, 'xml/gid'+gid+'_range.xml', parseGroupRangeData);\r\n\t\telse xhttpRequestFetch(req, 'animedb.pl?show=xmln&t=agranges&gid=' + gid, parseGroupRangeData);\r\n\t}\r\n}", "title": "" }, { "docid": "53501b355c4db67b9072b913842f2ec3", "score": "0.47667772", "text": "function getEntries() {\n \n Backendless.Data.of(\"Practice\").find().then(processResults).catch(error);\n\n}", "title": "" }, { "docid": "bf5f53b55a833ae269e52a41f4e1fe38", "score": "0.47610664", "text": "function getAllGenres() {\n return new Promise((resolve, reject) => {\n const query = 'SELECT * FROM Genre LIMIT 100';\n\n pool.query(query, (err, results) => {\n if (err) {\n reject(err);\n } else {\n resolve(results);\n }\n });\n });\n}", "title": "" }, { "docid": "6abf837fc22d07233ee24855ab7b02ce", "score": "0.47558165", "text": "function main()\r\n{\r\n //getting number of skin cases\r\n process=1;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where cv_r=0\";\r\n getData();\r\n //getting number of skin cases\r\n process=2;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where cv_l=0\";\r\n getData();\r\n //getting number of skin cases\r\n process=3;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where bs_r=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=4;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where bs_l=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=5;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where ac_r=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=6;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where ac_l=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=7;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where nb=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=8;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where cp_r=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=9;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where cp_l=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=10;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where cdc_r=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=11;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where cdc_l=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=12;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where am_r=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=13;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where am_l=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=14;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where ny_r=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=15;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where ny_l=1\";\r\n getData();\r\n //getting number of skin cases\r\n process=16;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where fe_r=0\";\r\n getData();\r\n //getting number of skin cases\r\n process=17;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye where fe_l=0\";\r\n getData();\r\n //getting total number of cases\r\n process=18;\r\n query=\"s=SELECT COUNT(distinct child_id) from eye\";\r\n getData();\r\n console.log(eyeCount);\r\n}", "title": "" }, { "docid": "02c0c97cd0c1bf1d3ad6e0b4d368a35d", "score": "0.47543776", "text": "function printHits() {\n printHitsPerCountry()\n printHitsPerAddress()\n printHitsPerISP()\n printHitsPerCity()\n printHitsPerReserve()\n}", "title": "" }, { "docid": "4f12510a54198917d4c089cab42714c1", "score": "0.47435987", "text": "function getAllMatches() {\n if (\"caches\" in window) {\n caches.match(JADWAL).then(function (response) {\n if (response) {\n response.json().then(function (data) {\n \n showMatch(data);\n })\n }\n })\n }\n\n fetchApi(JADWAL)\n .then(status)\n .then(json)\n .then(function(data) {\n // console.log(data) ;\n showMatch(data);\n })\n .catch(error);\n}", "title": "" }, { "docid": "1904d12fea9ba52980280dba3a7d55c2", "score": "0.47388756", "text": "function getTrails (res, dist) {\n if(dist <= 1) {\n let dist = 5;\n }\n const lat = res.results[0].location.lat;\n const long =res.results[0].location.lng; \n const trailURL = `https://www.mtbproject.com/data/get-trails?lat=${lat}&lon=${long}&maxDistance=${dist}&key=${API_KEY.MTB_PROJECT}`;\n fetch(trailURL)\n .then(response => checkResponse(response))\n .then(resj => buildList(resj))\n .catch(err => console.log(err.message));\n}", "title": "" }, { "docid": "ead12eb0af6538ae515fe88010bf0ba3", "score": "0.47386217", "text": "getAllGrades(){\n return this.#fetchAdvanced(this.#getAllGradesURL()).then((responseJSON)=> {\n let responseGradingBOs = GradingBO.fromJSON(responseJSON);\n console.info('response' + responseGradingBOs);\n return new Promise(function(resolve){\n resolve(responseGradingBOs);\n })\n })\n\n }", "title": "" }, { "docid": "a9115a2e2e04fe4060385e0f52b8ee6b", "score": "0.47363603", "text": "function getCasePer100k(geojsonName) {\n var casePer100k = 0;\n for(var i = 0; i < covid_data.length; i++) {\n var obj = covid_data[i];\n if (obj.geojson_name === geojsonName) {\n casePer100k = cleanSiteValue(obj.case_per_100k);\n break;\n }\n }\n if (casePer100k == null || casePer100k === '') {\n casePer100k = 0; \n }\n return casePer100k;\n }", "title": "" }, { "docid": "89923ce2a0ed2643782989e7b52d5a6e", "score": "0.47324175", "text": "function numberLoadsFromSource(){\n recorddb.allDocs({include_docs: true, descending: false}, function(er, doc) {\n var retrievedRecords = doc.rows;\n if(doc.rows == ''){\n numberOfLoadsS = 0;\n document.getElementById('numberLFS').innerHTML ='<strong>'+numberOfLoadsS+'</strong>';\n }else{\n numberOfLoadsS = 0;\n var retrievedRecords = doc.rows; \n var count = 1;\n var currentSN = cur_source_name;\n for(i =0; i< retrievedRecords.length; i++){\n if (retrievedRecords[i].doc.obj.cSource.name === currentSN){\n numberOfLoadsS = count++;\n document.getElementById('numberLFS').innerHTML ='<strong>'+numberOfLoadsS+'</strong>';\n }\n }\n }\n });\n}", "title": "" }, { "docid": "6898b1c4238adc5b7e359fd5a1aee2e2", "score": "0.47311836", "text": "async fetchFacilitiesData() {\n return await this.cache.wrap('facilities', async () => {\n const resortData = await this.fetchAllFacilitiesData();\n return resortData.filter((x) => x.parkType === this.config.parkIdUpper);\n }, 1000 * 60 * 15); // cache each park's facility data for 15 minutes, to avoid filtering too often\n }", "title": "" }, { "docid": "27c2c0d6e0a2ee24f1332b12dd2059c7", "score": "0.47224826", "text": "getSuccCase () {\n if (this.data.resSuccCase.isLast) {\n return;\n }\n let _this = this;\n wx.$http({\n url: api.GetManageSuccessCase,\n data: this.data.querySuccCase\n }).then(res => {\n _this.setData({\n dataSuccCase: res.Page > 1 ? _this.data.dataSuccCase.concat(res.data) : res.data,\n resSuccCase: {\n RecordCount: res.RecordCount,\n Page: res.Page,\n PageSize: res.PageSize,\n isLast: res.RecordCount <= res.PageSize * res.Page\n }\n });\n })\n }", "title": "" }, { "docid": "41c4c12ccbef1278427c6935f0e3c560", "score": "0.4720411", "text": "function getData() {\n coronaStats().\n then(coronaStats => {\n console.log(coronaStats)\n let globalStats = coronaStats[\"Global\"];\n countriesStats = coronaStats[\"Countries\"];\n let date = coronaStats[\"Date\"];\n\n // global stats\n document.getElementById(\"numCases\").innerText = globalStats[\"TotalConfirmed\"];\n document.getElementById(\"numDeaths\").innerText = globalStats[\"TotalDeaths\"];\n document.getElementById(\"numRecovered\").innerText = globalStats[\"TotalRecovered\"];\n\n //date\n document.getElementById(\"updatetime\").innerText = date;\n\n //country stats\n // TODO: add CHROME APIs Storage??? to save the your country preference\n let country = \"India\";\n // let country = document.getElementById(\"countryName\").innerText;\n // get the stats for the country from countryStats\n let countryStats = filterValue(countriesStats, \"Country\", country);\n console.log(countryStats);\n populateCountryUI(countryStats);\n\n })\n .catch(function(e) {\n console.error(e.message); // \"oh, no!\"\n });\n}", "title": "" }, { "docid": "d3f003f6f64126be641a9a3728899a74", "score": "0.47189665", "text": "async function getAlternatives() {\n // Initialize variables\n $scope.map = [];\n $scope.in_food_group;\n $scope.orig_nutrient_amount;\n $scope.all_alt_in_group = [];\n $scope.have_match = 0;\n $scope.top_alt_count = 3;\n $scope.mid_ind;\n $scope.cookingStyle = 'None';\n\n // Loop through cooking methods, food groups, and alternatives to get the alternatives\n // based on what was searched\n $scope.alt_food_object.cooking_methods.forEach( (cooking_method, i) => {\n cooking_method.food_groups.forEach( (food_group, j) => {\n food_group.food_alts.forEach( (food_alt, k) => {\n \n if((food_alt.db_name.toLowerCase() == vm.searchFood.toLowerCase()) && ($scope.cookingStyle == cooking_method.method_name)){\n var alt_item = food_alt;\n $scope.map.push({\"map_ndbno\": alt_item.db_ndbno, \"map_name\": alt_item.db_name, \"nutrient\": alt_item.db_main_nutrient.db_amount, \"flipped\": false});\n $scope.have_match = 1;\n }\n else if ((food_alt.db_name.toLowerCase() != vm.searchFood.toLowerCase()) && ($scope.have_match == 1)){\n $scope.all_alt_in_group.push(food_alt);\n }\t\t\t\n });\n $scope.have_match = 0;\n });\n });\n \n // Put three alternatives into map array to display on search screen\n if($scope.all_alt_in_group.length > 0) {\n if($scope.all_alt_in_group.length < $scope.top_alt_count){\n $scope.all_alt_in_group.forEach((alt_item, i) => {\n $scope.map.push({\n \"map_ndbno\": alt_item.db_ndbno, \n \"map_name\": alt_item.db_name, \n \"nutrient\": alt_item.db_main_nutrient.db_amount, \n \"flipped\": false\n });\n });\n }\n else{\n // Control what alt we give\n $scope.mid_ind = $scope.all_alt_in_group.length/2;\n // Index is not whole number\n if($scope.mid_ind % 1 != 0){\n $scope.mid_ind = $scope.mid_ind - 0.5;\n }\n $scope.all_alt_in_group.forEach((alt_item, i) => {\n if(i==0 || i==$scope.mid_ind || i==$scope.all_alt_in_group.length-1){\n $scope.map.push({\"map_ndbno\": alt_item.db_ndbno, \"map_name\": alt_item.db_name, \"nutrient\": alt_item.db_main_nutrient.db_amount, \"flipped\": false});\n }\n });\n }\t\t\n }\n else $scope.map.push({\"map_name\": \"No alternatives available\"});\n\n // Transfer data to the search controller\n TransferService.setAlternatives($scope.map);\n\n if($state.is('search')) $state.reload();\n else $state.go('search');\n }", "title": "" }, { "docid": "ddaf631f7d6d55f61c8973da6a6895ba", "score": "0.4717721", "text": "async queryAll(ctx) {\n const iterator = await ctx.stub.getStateByRange('','');\n\n const allResults = [];\n //let allKeys = [];\n // eslint-disable-next-line no-constant-condition\n while (true) {\n const res = await iterator.next();\n\n if (res.value && res.value.value.toString()) {\n console.log(res.value.value.toString('utf8'));\n\n const Key = res.value.key;\n let Record;\n try {\n Record = JSON.parse(res.value.value.toString('utf8'));\n } catch (err) {\n console.log(err);\n Record = res.value.value.toString('utf8');\n }\n\n allResults.push({ Key, Record });\n //allKeys.push(Key);\n }\n if (res.done) {\n console.log('end of data');\n await iterator.close();\n console.info(allResults);\n return JSON.stringify(allResults);\n }\n }\n }", "title": "" }, { "docid": "b9704b99f8dcc34af859234d0e638adb", "score": "0.47154376", "text": "function getParks(){\n for(let i=0;i<stateCounter;i++){\n stateCode[i]=$(`#js-state${i+1}`).val()\n console.log(stateCode);\n }\n const queryString = buildQuery(stateCode);\n const request = baseURL + \"?\" + queryString;\n fetch(request)\n .then(response => {\n if(response.ok){\n return response.json();\n }\n throw new Error('Something went wrong.')\n })\n .then(responseJson => displayResults(responseJson))\n .catch(err => {\n //display error text\n })\n\n}", "title": "" }, { "docid": "88f1406a05379d2bb7dc95a4e5372a4d", "score": "0.4710502", "text": "function pctWinner(){\n var winners = [];\n\n $http.get('/REST/pronos/winner').success(function (data) {\n $scope.secondStageMatches = data;\n _.each($scope.secondStageMatches, function(final){\n _.each(final, function(match){\n if (match.final) { \n if(match.final.ABCDEFGH[0].score.length > 0 && match.final.ABCDEFGH[1].score.length > 0 ){\n if(match.final.ABCDEFGH[0].score > match.final.ABCDEFGH[1].score || (match.final.ABCDEFGH[0].score === match.final.ABCDEFGH[1].score && match.final.ABCDEFGH[0].penalties > match.final.ABCDEFGH[1].penalties)){\n winners.push({'country': match.final.ABCDEFGH[0].country, val:1});\n } else {\n winners.push({'country': match.final.ABCDEFGH[1].country, val:1});\n }\n\n }\n };\n });\n\n })\n var groups = _(winners).groupBy('country');\n\n var cupterms = _(groups).map(function(g, key) {\n return { term: key, count: _(g).reduce(function(m,x) { return m + x.val; }, 0) };\n });\n\n cupterms.sort(function(a,b) {\n return b.count - a.count;\n });\n\n $scope.results = {\n facets: {\n Pronos : {\n terms : cupterms\n } \n }\n };\n });\n }", "title": "" }, { "docid": "4db08153bb9791a883b04b21635fc059", "score": "0.47099525", "text": "async allGameInfo(game, admin){\n\t\tlet query = `SELECT COUNT(*) AS taken, u.id, u.alias, CONCAT(u.name_first,' ',u.name_last) AS name, g.cost, g.box_min AS min\n\t\tFROM picks p \n\t\tINNER JOIN users u ON p.user = u.id\n\t\tINNER JOIN game g ON g.id = ${game}\n\t\tWHERE p.game = ${game} AND u.admin = '${admin}'\n\t\tGROUP BY u.id;`\n\t\ttry {\n\t\t\tlet result = await this.pool.query(query);\n\t\t\treturn result;\n\t\t}\n\t\tcatch(error){\n\t\t\treturn error;\n\t\t}\n\t}", "title": "" }, { "docid": "96e92f0e18a2f9cd1a7ab523fe438039", "score": "0.47066984", "text": "function kata8() {\n let arr = []\n for (let i = 100; i>0; i--){\n if(i%3 === 0 ){\n arr.push(i)\n }\n if(i%7 === 0){\n arr.push(i)\n } \n }\n showResults(`KATA 8 : [ ${arr} ]`)\n}", "title": "" }, { "docid": "da6c0412ba01d7d4c1aed2271ae02d8a", "score": "0.4706664", "text": "async categories() {\n const responseH = await fetch(`${baseURL}top-headlines?country=${this.query.country}&category=${this.query.category}&apiKey=${key}`);\n const responseE = await fetch(`${baseURL}everything?q=${this.query.category}&apiKey=${key}`);\n await this.getResults(responseH, responseE);\n }", "title": "" }, { "docid": "af953d23bca7e3adfaaa43e95a1e9d13", "score": "0.47046068", "text": "function fetchAllData() {\n let t0 = performance.now();\n\n $('.listing').hide();\n $('.agent').hide();\n $('#l-stats').hide();\n $('#a-stats').hide();\n $('.empty-l-data').show();\n $('.empty-a-data').show();\n $('#agent-s-d').show();\n $('#listing-s-d').show();\n $('#agent-e-d').hide();\n $('#listing-e-d').hide();\n \n agentDocuments.then(querySnapshot => {\n \n if(querySnapshot.empty) {\n throw \"NO-DATA-01\";\n }\n \n $('.agent').show();\n $('#a-stats').show();\n $('.empty-a-data').hide();\n\n $(\".agent .agent-table-data\").empty(); // clear the table data\n $('#filter-agent-form-select').empty(); // clear select form options\n $('#filter-aic-form-select').empty(); // clear select form options\n $('#nl-aic-form-select').empty(); // clear select form options\n $('#nl-agent-form-select').empty(); // clear select form options\n $('#vl-aic-form-select').empty(); // clear select form options\n $('#vl-agent-form-select').empty(); // clear select form options\n\n $('#filter-agent-form-select').append(\"<option selected>All</option>\");\n $('#filter-aic-form-select').append(\"<option selected>All</option>\");\n $('#nl-aic-form-select').append(\"<option value=\\\"\\\" selected hidden>Select an option</option>\");\n $('#nl-agent-form-select').append(\"<option value=\\\"\\\" selected hidden>Select an option</option>\");\n $('#vl-aic-form-select').append(\"<option value=\\\"\\\" selected hidden>Select an option</option>\");\n $('#vl-agent-form-select').append(\"<option value=\\\"\\\" selected hidden>Select an option</option>\");\n\n querySnapshot.forEach((doc) => {\n renderAgent(doc.id,doc.data());\n }); \n \n $('#a-records').html(querySnapshot.size);\n \n let t1 = performance.now();\n\n $('#a-execTime').html(((t1-t0)/1000).toFixed(3));\n\n Object.keys(agentArray).forEach(function (key) {\n $('#filter-agent-form-select').append($(\"<option></option>\").attr(\"value\", agentArray[key].id).text(agentArray[key].name));\n $('#filter-aic-form-select').append($(\"<option></option>\").attr(\"value\", agentArray[key].id).text(agentArray[key].name));\n $('#nl-aic-form-select').append($(\"<option></option>\").attr(\"value\", agentArray[key].id).text(agentArray[key].name));\n $('#nl-agent-form-select').append($(\"<option></option>\").attr(\"value\", agentArray[key].id).text(agentArray[key].name));\n $('#vl-aic-form-select').append($(\"<option></option>\").attr(\"value\", agentArray[key].id).text(agentArray[key].name));\n $('#vl-agent-form-select').append($(\"<option></option>\").attr(\"value\", agentArray[key].id).text(agentArray[key].name));\n });\n \n }).catch(function(error) {\n $('.agent').hide();\n $('.empty-a-data').show();\n $('#agent-s-d').hide();\n $('#agent-e-d').show();\n });\n \n listingDocuments.then((querySnapshot) => {\n \n if(querySnapshot.empty) {\n throw \"NO-DATA-01\";\n }\n \n $('.listing').show();\n $('#l-stats').show();\n $('.empty-l-data').hide();\n\n $(\".listing .listing-table-data\").empty(); // clear the table data\n\n querySnapshot.forEach((doc) => {\n renderList(doc.id, doc.data());\n });\n \n $('#l-records').html(querySnapshot.size);\n \n let t1 = performance.now();\n\n $('#l-execTime').html(((t1-t0)/1000).toFixed(3));\n\n }).catch(function(error) {\n if(error == \"NO-DATA-01\") {\n $('.listing').hide();\n $('.empty-l-data').show();\n $('#listing-s-d').hide();\n $('#listing-e-d').show();\n }\n });\n\n autocomplete(document.getElementById(\"location-form-input\"), locationArray);\n}", "title": "" }, { "docid": "12b7028c3f589352bef9a65ec42d5f4d", "score": "0.47024798", "text": "static getTopAvailabilities({ amount }) {\n if (!amount) {\n console.log(\"availabilities/top GET -> getTopAvailabilities -> invalid amount, using 10 instead.\");\n amount = 10;\n }\n return new Promise(\n async (resolve) => {\n try {\n // TODO: set this complex query as a View and/or Stored Procedure in MySQL\n const query = `select * from\n (select\n a.AvailabilityId,\n a.StartDate as AStartDate, a.EndDate as AEndDate,\n b.BookingId,\n a.WorkspaceId,\n b.StartDate as BStartDate, b.EndDate as BEndDate,\n b.StaffId as BStaffId\n from (select * from availability limit ${LIMIT}) a\n left join booking b\n on a.AvailabilityId = b.AvailabilityId) ab\n natural join workspace\n natural join workspaceFeature\n natural join feature\n natural join floor\n left join user u on BStaffId = u.StaffId\n order by AvailabilityId`;\n const rows = (await knex.raw(query))[0];\n //console.log(rows);\n let currAvailabilityId = -1;\n let currFeatureIds = [];\n const availabilities = [];\n for (const row of rows) {\n // The rows are in sorted AvailabilityId, so rows for the same availability are consecutive\n // If the next row's AvailabilityId the same as the curr one, then only create\n // a new booking and push it into curr's bookings array\n if (row.AvailabilityId === currAvailabilityId) {\n // Push booking into current availability in response;\n const booking = OfficeBookingService.makeBooking(row);\n availabilities[availabilities.length - 1].bookings.push(booking);\n\n // set up features\n if (row.FeatureId !== null && !currFeatureIds.includes(row.FeatureId)) {\n availabilities[availabilities.length - 1].features.push(row.FeatureName);\n currFeatureIds.push(row.FeatureId);\n }\n } else {\n // update index;\n currAvailabilityId = row.AvailabilityId;\n const availability = OfficeBookingService.makeAvailability(row);\n // console.log(availability);\n availabilities.push(availability);\n if (row.BookingId != null) {\n const booking = OfficeBookingService.makeBooking(row);\n availabilities[availabilities.length - 1].bookings.push(booking);\n }\n\n // set up features\n if (row.FeatureId !== null && !currFeatureIds.includes(row.FeatureId)) {\n availabilities[availabilities.length - 1].features.push(row.FeatureName);\n currFeatureIds.push(row.FeatureId);\n }\n }\n }\n const response = [];\n for (const availability of availabilities) {\n if (OfficeBookingService.hasOpening(availability)) {\n response.push(availability);\n if (response.length === amount) {\n break;\n }\n }\n }\n console.log(`getAvailabilities/top/${amount} GET -> getTopAvaliabilities -> 200 OK`);\n // resolve(Service.successResponse(response));\n resolve(response);\n } catch (e) {\n resolve(Service.rejectResponse(\n e.message || 'Invalid input',\n e.status || 405,\n ));\n }\n },\n );\n }", "title": "" }, { "docid": "3830f990765b06b9ea5f61688b334df1", "score": "0.47016892", "text": "getStoriesByMetric(entry) {\n const stories = [];\n for (const e of this.sampleArr) {\n if (e.name !== entry) {\n continue;\n }\n let nameOfStory = this.guidValue.get(e.diagnostics.stories);\n if (nameOfStory === undefined) {\n continue;\n }\n if (typeof nameOfStory !== 'number') {\n nameOfStory = nameOfStory[0];\n }\n stories.push(nameOfStory);\n }\n return _.uniq(stories);\n }", "title": "" }, { "docid": "24f687f76036bee7fff587d35feffe3c", "score": "0.47002214", "text": "function fetchCountryData() {\n fetch(\"https://coronavirus-monitor.p.rapidapi.com/coronavirus/cases_by_country.php\", {\n method: \"GET\",\n headers: {\n 'X-RapidAPI-Key': 'edd2277260mshf152755896d31e4p195aadjsn63b6c16d27fd',\n 'X-RapidAPI-Host': 'coronavirus-monitor.p.rapidapi.com'\n }\n })\n .then(response => response.json().then(data => {\n console.log(data);\n let countries_stat = data.countries_stat;\n\n // Getting all the country statistics using a loop\n for (let i = 0; i < countries_stat.length; i++) {\n console.log(countries_stat[i]);\n // Inserting new rows inside the table\n let row = table.insertRow(i + 1);\n let country_name = row.insertCell(0);\n let cases = row.insertCell(1);\n let deaths = row.insertCell(2);\n let recovered_per_country = row.insertCell(3);\n let new_cases = row.insertCell(4);\n let new_deaths = row.insertCell(5);\n country_name.innerHTML = countries_stat[i].country_name;\n cases.innerHTML = countries_stat[i].cases;\n deaths.innerHTML = countries_stat[i].deaths;\n recovered_per_country.innerHTML = countries_stat[i].total_recovered;\n new_cases.innerHTML = countries_stat[i].new_cases;\n new_deaths.innerHTML = countries_stat[i].new_deaths;\n }\n }))\n .catch(err => {\n console.log(err);\n });\n }", "title": "" }, { "docid": "37b74e1eae053b7c3da5cfb89ff506c7", "score": "0.46983263", "text": "function getSites(age, boxArr){\n // these variables are arbitrary. Used for parsing Neotoma data\n var young = 0;\n var old = 12000;\n var step = 1000;\n\n var classNum = (old-young)/step;\n\n // variable for storing age bin values\n var ageArray = [];\n var ageCount = young+step;\n\n for (var j = 0; j < classNum; j++){\n ageArray.push(ageCount);\n ageCount+= step;\n }\n\n //console.log(ageArray);\n\n\n // for loop that looks at all the taxa in taxonIDs, retrieving data for each one.\n // age is used to determine which samples to retrieve\n // NOTE: want to take all the data and put it into one object/array to be dealt with that way.\n\n for (var i = 0; i < taxonIDs.length; i++) {\n var youngAge = young;\n\n // for loop to do a call for each time period.\n for (var k = 0; k < ageArray.length; k++){\n if (youngAge == young){\n var oldAge = youngAge + step;\n } else {\n oldAge += step;\n }\n\n // console.log(\"youngAge is: \"+youngAge);\n // console.log(\"oldAge is: \"+oldAge);\n\n // constructing URL based on coordinates (to be changed to user inputted bounding box later) and the taxon and ages.\n // need to change this so it retrieves information for all offered taxa.\n var urlBaseMN = 'https://apidev.neotomadb.org/v1/data/pollen?wkt=POLYGON((-97.294921875%2048.93964118139728,-96.6357421875%2043.3601336603352,-91.20849609375%2043.53560718808973,-93.09814453125%2045.10745410539934,-92.17529296875%2046.69749299744142,-88.79150390625%2047.874907453605935,-93.53759765625%2048.910767192107755,-97.294921875%2048.93964118139728))';\n var url = [urlBaseMN, '&taxonname=', taxonIDs[i], '&ageold=', oldAge, '&ageyoung=', youngAge].join('');\n // ajax call to neotoma database\n $.ajax(url, {\n dataType: \"json\",\n success: function(response){\n // calling function to organize data\n formatData(response.data,ageArray,step);\n }\n });\n // if statement to ensure mutually exclusive classes\n if (youngAge == young){\n youngAge = step + 1;\n } else{\n youngAge += step;\n }\n }\n\n\n }\n\n\n\n}", "title": "" }, { "docid": "d62c2a8df390fdbfe40afcb82983ffc6", "score": "0.4691899", "text": "function load_queries(res) {\n var per_sport = \"SELECT SQL_CACHE sport, COUNT(*) as number_of_incidents FROM doping_athletes GROUP BY sport ORDER BY number_of_incidents DESC;\";\n var per_sport_gender = \"SELECT SQL_CACHE sport, SUM(gender='Female') as num_female, SUM(gender='Male') as num_male FROM doping_athletes GROUP BY sport;\";\n var per_country = \"SELECT SQL_CACHE origin_country, COUNT(*) as number_of_incidents FROM doping_athletes GROUP BY origin_country ORDER BY number_of_incidents DESC;\";\n var per_drug = \"SELECT SQL_CACHE banned_substance, COUNT(*) as number_of_incidents FROM doping_athletes GROUP BY banned_substance ORDER BY number_of_incidents DESC;\";\n var per_year = \"SELECT SQL_CACHE year, COUNT(*) as number_of_incidents FROM doping_athletes GROUP BY year ORDER BY year DESC;\";\n var per_gender = \"SELECT SQL_CACHE SUM(gender='Female') as num_female, SUM(gender='Male') as num_male FROM doping_athletes;\";\n var avg_incidents = \"SELECT SQL_CACHE origin_country, AVG(sub.num_inc) AS number_of_incidents FROM (SELECT origin_country, COUNT(*) AS num_inc FROM doping_athletes GROUP BY origin_country, year) sub GROUP BY origin_country ORDER BY number_of_incidents DESC;\";\n\n connection.query(per_sport + per_sport_gender + per_country + per_drug\n + per_year + per_gender + avg_incidents, function(err, results) {\n if (err) console.log(err);\n else {\n var sport_chart_data = [['Sport', 'Number of Incidents']];\n var per_sport = results[0];\n for (var inx = 0; inx < per_sport.length; inx++) {\n var sport0 = [per_sport[inx].sport, parseInt(per_sport[inx].number_of_incidents)];\n sport_chart_data.push(sport0);\n }\n var country_chart_data = [['Country', 'Number of Incidents']];\n var per_country = results[2];\n for (var inx = 0; inx < per_country.length; inx++) {\n var country0 = [per_country[inx].origin_country, parseInt(per_country[inx].number_of_incidents)];\n country_chart_data.push(country0);\n }\n var drug_chart_data = [['Drug', 'Number of Incidents']];\n var per_drug = results[3];\n for (var inx = 0; inx < per_drug.length; inx++) {\n var drug0 = [per_drug[inx].banned_substance, parseInt(per_drug[inx].number_of_incidents)];\n drug_chart_data.push(drug0);\n }\n var year_chart_data = [['Year', 'Number of Incidents']];\n var per_year = results[4];\n for (var inx = 0; inx < per_year.length; inx++) {\n var year0 = [per_year[inx].year, parseInt(per_year[inx].number_of_incidents)];\n year_chart_data.push(year0);\n }\n var avg_country_chart_data = [['Country', 'Avg Number of Incidents']];\n var per_country_avg = results[6];\n for (var inx = 0; inx < per_country_avg.length; inx++) {\n var country1 = [per_country_avg[inx].origin_country, parseInt(per_country_avg[inx].number_of_incidents)];\n avg_country_chart_data.push(country1);\n }\n res.render('statistics.jade',\n { title: \"Organize the number of doping incidents by\",\n per_sport: results[0],\n per_sport_gender: results[1],\n per_country: results[2],\n per_drug: results[3],\n per_year: results[4],\n per_gender: results[5],\n avg_incidents: results[6],\n per_sport_chart: JSON.stringify(sport_chart_data),\n per_country_chart: JSON.stringify(country_chart_data),\n per_drug_chart: JSON.stringify(drug_chart_data),\n per_year_chart: JSON.stringify(year_chart_data),\n per_avg_chart: JSON.stringify(avg_country_chart_data) }\n );\n }\n });\n}", "title": "" }, { "docid": "9cc0271467ca266012d60bbea36367c6", "score": "0.469165", "text": "static getAll() {\n return db.any(`\n SELECT * FROM categories`\n )\n .then(catArray => {\n const instanceArray = catArray.map(catObj => {\n return new Category(catObj.id, catObj.category_type, catObj.levels, catObj.id_user);\n });\n return instanceArray;\n });\n }", "title": "" }, { "docid": "e7561147b7dfb10cc5b48df9177fb0d0", "score": "0.46909365", "text": "async getHistoCountryCases(country) {\n\t\tconst histoCases = await fetch(\n\t\t\t`https://disease.sh/v3/covid-19/historical/${country}?lastdays=all`\n\t\t);\n\t\tconst histoCasesJSON = await histoCases.json();\n\n\t\treturn histoCasesJSON;\n\t}", "title": "" }, { "docid": "c8cc1c2af16c93058e7ab26aa457ea59", "score": "0.46838287", "text": "function _get_efectivamensualcampa(){\r\n \tvar count = 0;\r\n var ejecutivosArray = [];\r\n var counts = {};\r\n\r\n // Load your search into memory\r\n var mySearch = search.load({\r\n id: 'customsearch5941'\r\n });\r\n\r\n // Run paged version of search with 1000 results per page\r\n var myPagedData = mySearch.runPaged({\r\n \"pageSize\": 1000\r\n });\r\n\r\n // Iterate over each page\r\n myPagedData.pageRanges.forEach(function(pageRange){\r\n // Fetch the results on the current page\r\n var myPage = myPagedData.fetch({index: pageRange.index});\r\n // Iterate over the list of results on the current page\r\n myPage.data.forEach(function(result){\r\n \t//log.audit('jsonObj result: ', result);\r\n \tvar val_leadsource = result.getValue({name: 'leadsource'});\r\n \tvar text_leadsource = result.getText({name: 'leadsource'});\r\n \tejecutivosArray.push(val_leadsource + \"|\" + text_leadsource);\r\n \tcount++;\r\n });\r\n });\r\n ejecutivosArray.forEach(function(i) { counts[i] = (counts[i]||0) + 1;});\r\n counts.total = count;\r\n return counts;\r\n }", "title": "" }, { "docid": "250aa6964421377afde286927ff43b4f", "score": "0.46834967", "text": "function multipleId(data) {\n let count = 0;\n // choose 5 data points within the dataSet\n let split = Math.round(data.length / 6);\n for (let i = 0; i < 5; i++) {\n let chosenData = data[i * split]\n if (data.filter(row => row.countryCode == chosenData.countryCode).length > 1) count++;\n }\n return count > 3;\n }", "title": "" }, { "docid": "c3be274135716b707e1323d136d5ef39", "score": "0.4683314", "text": "async function fetchAll() {\n // const response = await fetch(proxy+url);\n const response2 = await fetch(proxy+urlProg);\n // const courses_json = await response.json();\n const prog_json = await response2.json();\n setProg_course(prog_json.Specs);\n // setCourses(courses_json);\n setIsLoading(false); \n\n //prog_list = prog_json.Specs;\n //createDataset(prog_list)\n //console.log(Prog_course)\n //console.log(courses_json);\n }", "title": "" }, { "docid": "868f4f009179a00f6dc15c7d97e986c5", "score": "0.46814016", "text": "function getNonAlcList() {\n console.log(\"Entered Non Alc Function\");\n //url already set by DB, set as variable\n var nonAlcDrinkUrl = \"https://www.thecocktaildb.com/api/json/v1/1/filter.php?a=Non_Alcoholic\";\n //fetch it\n fetch(nonAlcDrinkUrl).then(function(response) {\n\n //if comes back ok\n if (response.ok) {\n response.json().then(function(data) {\n // put into object to pull from later\n nonAlcRandom ( data );\n });\n // if fail\n } else {\n error()\n }\n })\n\n // catch\n .catch( function (error) {\n error()\n })\n\n}", "title": "" }, { "docid": "5b3f13be2ef257b4671f97682799344c", "score": "0.4680559", "text": "function greedy(){\r\n for(var i =0;i<g_array_greedy.length;i++){\r\n var laplist ={\r\n id:\"\",\r\n lapcourse: []\r\n }\r\n laplist.id = g_array_greedy[i].id;\r\n for(var j =0;j<g_array_greedy.length;j++){\r\n if(g_array_greedy[i].id == g_array_greedy[j].id){\r\n var h = 0;\r\n }\r\n else{\r\n if(g_array_greedy[i].mo == true && g_array_greedy[j].mo == true || g_array_greedy[i].tu == true && g_array_greedy[j].tu == true || g_array_greedy[i].we == true && g_array_greedy[j].we == true || g_array_greedy[i].th == true && g_array_greedy[j].th == true || g_array_greedy[i].fr == true && g_array_greedy[j].fr == true){\r\n var stime1 = new Date(g_array_detail[i].stime);\r\n var etime1 = new Date(g_array_detail[i].etime);\r\n var stime2 = new Date(g_array_detail[j].stime);\r\n var etime2 = new Date(g_array_detail[j].etime);\r\n \r\n// if(stime1 == stime2 && etime1 == etime2){\r\n// //lap\r\n// \r\n// \r\n// \r\n// }\r\n //s1s2e2e1\r\n if(stime1 < stime2 && etime1 > etime2) {\r\n laplist.lapcourse.push(g_array_greedy[j].id);\r\n console.log(\"lap2\");\r\n console.log(g_array_greedy[i].id + \" and \"+ g_array_greedy[j].id );\r\n }\r\n //s1s2e1e2\r\n else if(stime1 < stime2 && etime1 > stime2 && etime1 < etime2){\r\n //lap\r\n \r\n \r\n laplist.lapcourse.push(g_array_greedy[j].id);\r\n \r\n// console.log(\"lap3\");\r\n// \r\n// console.log(g_array_greedy[i].id + \" and \"+ g_array_greedy[j].id );\r\n }\r\n //s2s1e2e1\r\n else if(stime1 > stime2 && stime1 < etime2 && etime1 > etime2){\r\n \r\n \r\n //lap\r\n laplist.lapcourse.push(g_array_greedy[j].id);\r\n// console.log(\"lap4\");\r\n// console.log(g_array_greedy[i].id + \" and \"+ g_array_greedy[j].id );\r\n }\r\n \r\n else if(stime1 > stime2 && etime1 < etime2){\r\n \r\n //lap\r\n laplist.lapcourse.push(g_array_greedy[j].id);\r\n// console.log(\"lap5\");\r\n// console.log(g_array_greedy[i].id + \" and \"+ g_array_greedy[j].id );\r\n }\r\n \r\n else if(stime1 > etime2){\r\n //no\\\r\n console.log(\"nope1\");\r\n \r\n }\r\n else if(etime1 < stime2){\r\n //no\\\r\n console.log(\"nope1\");\r\n \r\n }\r\n else{\r\n \r\n //i dont understand why stime1==stime2 && etime1 == etime2 does not working\r\n console.log(\"error\");\r\n laplist.lapcourse.push(g_array_greedy[j].id);\r\n \r\n \r\n console.log(g_array_greedy[i].id + \" and \"+ g_array_greedy[j].id );\r\n }\r\n \r\n \r\n \r\n \r\n \r\n }\r\n \r\n }\r\n \r\n }\r\n g_array_lap.push(laplist);\r\n }\r\n }", "title": "" }, { "docid": "70849964e22253103702c88e3147098f", "score": "0.46804684", "text": "function kata7() {\n \n let arr = []\n for (let i = 7; i<100; i++){\n if (i%7 === 0) {\n arr.push(i)\n }\n }\n showResults(`KATA 7 : [ ${arr} ]`)\n}", "title": "" }, { "docid": "eb5fc4c40c896c6d3cf58c9ef52097a4", "score": "0.46779382", "text": "populateContestantAnswerBuckets() {\n this.playerMap.doAll((player) => {\n if (player.hotSeatChoice !== undefined && Choices.isValidChoice(player.hotSeatChoice)) {\n this.contestantAnswerBuckets[player.hotSeatChoice]++;\n }\n });\n }", "title": "" }, { "docid": "67c877a94515137d3ab212431cc2f0ec", "score": "0.46756744", "text": "async function getDataGenre(genreName) {\n\tlet response = await axios.get(`${BASE_URL}/games?genres=${genreName}`);\n\n\tlet gameArr = response.data.results;\n\n\tnextPage = response.data.next;\n\n\tlet result = gameArr.map((game) => new Game(game));\n\n\tlet checkLogged = await axios.get(`/islogged`);\n\n\tlet data = checkLogged.data;\n\n\tfor (let game of result) {\n\t\tlet gameHTML = await generateCardHTML(game, data);\n\t\t$('#result_search').append(gameHTML);\n\t}\n}", "title": "" }, { "docid": "e772cf0b944e83eee0bc1132298fa886", "score": "0.46667498", "text": "async getRefundableKavaSwaps() {\n let expiredSwaps = [];\n let checkNextBatch = true;\n let page = 1; // After refunding swaps paginated query results will always start from page 1\n\n while(checkNextBatch) {\n let swapBatch;\n const args = {status: 'Expired', page: page, limit: this.limit};\n try {\n swapBatch = await this.kavaClient.getSwaps(5000, args);\n } catch (e) {\n console.log(`couldn't query swaps on Kava...`);\n return\n }\n // If swaps in batch, save them and increment page count\n if(swapBatch.length > 0) {\n expiredSwaps = expiredSwaps.concat(swapBatch);\n page++;\n // If no swaps in batch, don't check the next batch\n } else { \n checkNextBatch = false\n }\n }\n \n // Calculate each swap's ID as it's not stored in the struct (it's on the interface)\n let swapIDs = []\n for(const expiredSwap of expiredSwaps) {\n const swapID = Kava.utils.calculateSwapID(\n expiredSwap.random_number_hash,\n expiredSwap.sender,\n expiredSwap.sender_other_chain,\n )\n swapIDs.push(swapID)\n }\n return swapIDs\n }", "title": "" }, { "docid": "061a259376081b0377d7964fa63bd69f", "score": "0.46658006", "text": "function getAlldata(arrCountries){\n const data = []\n arrCountries.forEach(country => {\n fetch('https://covid19.mathdro.id/api/countries/'+ country )\n .then(response => response.json())\n .then(res => { \n const all = res;\n data.push({\n countries: country, \n confirmed: all.confirmed.value,\n recovered: all.recovered.value,\n deaths: all.deaths.value\n });\n });\n });\n return data;\n}", "title": "" }, { "docid": "53b3676a07077fcc3e1351c10905b2d8", "score": "0.4663961", "text": "function RamqGetRamqDataFromGrille() {\n var arrRes = [];\n for (var i = 0; i < arrGrilleDeFacturation.length; i++) {\n if (arrGrilleDeFacturation[i].Type == 'AMQ' || arrGrilleDeFacturation[i].Type == 'BES' || arrGrilleDeFacturation[i].Type == 'HOP') {\n arrRes.push(arrGrilleDeFacturation[i]);\n }\n }\n return arrRes;\n}", "title": "" }, { "docid": "320ae04228aa7d23187e173a5da96700", "score": "0.46613076", "text": "function showTrailsByStatus (status) {\n showLoading();\n let rawTrailData = []\n getFortCollinsData(status)\n .then((result) => {\n rawTrailData = result.features;\n return getLarimerData(status);\n })\n .then((lory) => {\n rawTrailData = rawTrailData.concat(lory.features);\n // flatten it all...\n let flat = rawTrailData.map(flattenAttr.curry('attributes'));\n let mapped = remapFields(flat, fieldMap);\n let rows = aggregate(mapped);\n display(rows);\n })\n .catch((err) => {\n console.log(err);\n });\n}", "title": "" }, { "docid": "2ef40fee38d4f67b260ae970b713c80e", "score": "0.4661079", "text": "function getpagedData(esi){\n \n \nif(esi>=maxitems)\nreturn totalMatchcount;\nclient.search({\n index: \"fabfurnish\",//metaObject.indexName,\n type: 'test',\n body: {\n query: {\"match_all\":{}},\n\"from\" : esi,\n\"size\" : inc \n }\n \n}).then(function (resp) {\n\n var hits = resp.hits.hits;\n var ps=[],mcid=0;\n if(esi==startpt)\n maxitems=resp.hits.total;\n \n for(var j=0; j<hits.length; j++) {\n \n // console.log(j);\n var item=hits[j]._source;\n var catid=null; var mcat=null;\n if(item!=null && item.category!=null)\n for (var i=item.category.length-1;i>=0;i--)\n {\n // var strn=SCategories.getStemmedFrom.toLowerCase().trim());\n \n catid=SCategories.getCategoryID(item.category[i],item.category.toString());\n if(catid!=null)\n {\n mcat=item.category[i];\n break;\n }\n \n }\n var categoryID=999;\n if(catid!=null)\n {\n categoryID=catid.CatID;\n mcid++\n fs.appendFile('matchedCategories_pep.txt',item.category+\": mapped to --> \"+categoryID+\" URL--> (\"+item.url+')\\n', function (err) {\n if (err) throw err;\n });\n \n \n var ls=[];\n item=getCleanedItem(item);\n if(item.title!=null && item.price >0)\n {\n ls.push(item.url);\n ls.push(categoryID);\n ls.push(item.price);\n ls.push(item.title);\n ls.push(item.image);// && item.image.length>0)?item.image[0]:item.image);\n ls.push(\"http://codenlogic.com/project/sos/wp-content/themes/sos/SiteLogos/fabfurnish_logo.png\");\n ls.push(item.details);\n ls.push(\"fabfurnish\");\n ps.push(ls);\n }\n }\n else\n fs.appendFile('unmatchedCategories_pep.txt',item.category+\" URL--> (\"+item.url+')\\n', function (err) {\n if (err) throw err;\n });\n \n }// for each hit\n \n \n // if(ps.length>0)\n // db.insertData(ps);\n \n totalMatchcount+=mcid\n //console.log(ps[0]);\n console.log(esi +\" matched->\"+mcid +\"total\"+totalMatchcount);\n // else \n getpagedData(esi+inc)\n}, function (err) {\n console.trace(err.message);\n\n});\n\n}// for each 100 products", "title": "" }, { "docid": "27983e97ff7d82c0a007b59bfded7acd", "score": "0.46600628", "text": "function getListUrlAdsCamp(id, url){\n /*-------------------------------------------------------*/\n /*----------------------1) ON RECUPERE TOUS LES COMPTES ASSOCIES A L'ID EN ARGUMENT, PUIS ON ITERE DANS CETTE LISTE DE COMPTES(ASSOCIE A L'ID)---------------------------------*/\n var accounts = AdsManagerApp\n .accounts().withIds([id]).get()\n /*\n var accountLabelIterator = AdsManagerApp\n .accountLabels().get()\n Logger.log(\"START??List of accountLabel??START\")\n while (accountLabelIterator.hasNext()) {\n var accountLabel = accountLabelIterator.next();\n Logger.log(accountLabel.getName())\n }\n Logger.log(\"END--??List of accountLabel??--END\")\n */\n var objAccounts = {}\n objAccounts[\"adsId\"] = id\n objAccounts[\"urlFromSheet\"] = url\n objAccounts[\"array_url_\"+id] = []\n objAccounts[\"array_url\"] = []\n objAccounts[\"array_checks\"] = []\n objAccounts[\"array_adId_\"+id] = []\n var i = j = 0\n while (accounts.hasNext()) {\n var arrayAccount = []\n Logger.log(\"i: %s\", i++)\n var account = accounts.next()\n objAccounts.accountName = account.getName()\n Logger.log(\"account.getName(): %s\", account.getName())\n /*----------------------2) ON SE CONNECTE A CE COMPTE EN LE SELECTIONNANT---------------------------------*/\n AdsManagerApp.select(account);\n\n /*\n var campaignSelector = AdsApp\n .campaigns()\n var campaignIterator = campaignSelector.get();\n while (campaignIterator.hasNext()) {\n Logger.log(\"j: %s\", j++)\n var campaign = campaignIterator.next();\n Logger.log(campaign.getName())\n }\n */\n\n /*----------------------3) ON FAIT UNE ITERATION DANS TOUTES LES ANNONCES -ASSOCIEES AU COMPTE ASSOCIE A L'ID----------------------------------*/\n var boolAd = true\n var adSelector = AdsApp\n .ads()\n var adIterator = adSelector.get();\n while(adIterator.hasNext() && boolAd) {\n var objAd = {}\n// Logger.log(\"j: %s\", j++)\n var ad = adIterator.next();\n// Logger.log(\"ad.isEnabled: %s\", ad.isEnabled())\n /*----------------------4) ON VERIFIE SI L'ANNONCE EST ACTIVE---------------------------------*/\n if(ad.isEnabled()){\n /*----------------------5) SI ELLE EST ACTIVE, ON RECUPERE LA CAMPAGNE ASSOCIEE A CETTE ANNONCE, PUIS ON VERIFIE SI CETTE CAMPAGNE EST ACTIVE---------------------------------*/\n var adCampaign = ad.getCampaign()\n// Logger.log(\"adCampaign.isEnabled: %s\", adCampaign.isEnabled())\n if(adCampaign.isEnabled()){\n// Logger.log(\"-------------------\"+ad.urls().getFinalUrl()+\"-------------------\")\n if(objAccounts[\"array_url_\"+id].indexOf(ad.urls().getFinalUrl()) == -1){\n /*----------------------6) SI CETTE CAMPAGNE EST ACTIVE, ON RECUPERE L'URL ASSOCIEE A L'ANNONCE---------------------------------*/\n objAccounts[\"array_url\"].push([ad.urls().getFinalUrl()])\n objAccounts[\"array_url_\"+id].push(ad.urls().getFinalUrl())\n objAccounts[\"array_adId_\"+id].push(\"\"+ad.getId())\n\n Logger.log(ad.urls().getFinalUrl())\n objAd.id = ad.getId()\n objAd.url = ad.urls().getFinalUrl()\n objAd.getDisplayUrl = ad.getDisplayUrl()\n objAd.getHeadline = ad.getHeadline()\n objAd.getEntityType = ad.getEntityType()\n objAd.getType = ad.getType()\n objAd.getFinalUrlSuffix = ad.urls().getFinalUrlSuffix()\n arrayAccount.push(objAd)\n }else{\n/* Logger.log(\"adCampaign.isEnabled(): %s\", adCampaign.isEnabled())\n Logger.log(\"URL déjà parsé: %s\", ad.urls().getFinalUrl())\n Logger.log(objAccounts[\"array_url_\"+id])\n Logger.log(\"_______\")*/\n }\n }\n }\n// Logger.log(\"objAd: %s\", objAd)\n if(arrayAccount.length == 5){\n boolAd = false\n Logger.log('QUOTAT ATTEINT !!!!!! arrayAccount.length == 5')\n }\n }\n objAccounts[\"id_\"+id] = arrayAccount\n }\n if(boolAd)Logger.log(\"-------------------Toutes les annonces ont été itérées-------------------\")\n else Logger.log(\"-------------------5 urls ont été récupérés-------------------\")\n Logger.log(\"objAccounts: %s\", objAccounts)\n Logger.log(\"--------\")\n return objAccounts\n}", "title": "" }, { "docid": "fab2e6e9598492382ba9b5d373abeb1a", "score": "0.46588507", "text": "function next(gamepks) {\n for (let game = 0; game < gamepks.length; game++) {\n\n const gamepk = gamepks[game];\n const url = gameurl(gamepk);\n \n fetch(url)\n .then(res => res.json())\n .then(json => scrape(json) )\n .catch(err => console.error(err));\n }\n}", "title": "" }, { "docid": "76eb85312fca896c535c2c9f269d04e8", "score": "0.46543938", "text": "function fetchCapital() \r\n{\r\n\tvar data = \r\n\t{\r\n\t\tstartYear: \"2012\",\r\n\t\tendYear: \"\"\r\n\t};\r\n\t\r\n\t$.ajax({\r\n\t\turl:\"/retrieveGlobalGDP\",\r\n\t\ttype:\"GET\",\r\n\t\tdata : data,\r\n\t\tsuccess: function (responseGDP) {\r\n\t\t\t$.ajax({\r\n\t\t\t\turl:\"/retrieveGlobalPoP\",\r\n\t\t\t\ttype:\"GET\",\r\n\t\t\t\tdata : data,\r\n\t\t\t\tsuccess: function (responsePop) {\r\n\t\t\t\t\t// chart visualization\r\n\t\t\t\t\tvar processedMap = google.visualization.arrayToDataTable(calculateGDPperCapita(responseGDP, responsePop)),\r\n processedTable = google.visualization.arrayToDataTable(tableGDPperCapita(responseGDP, responsePop));\r\n\t\t\t\t\tdrawMap(processedMap, processedTable);\r\n\t\t\t\t}\r\n\t\t\t});\r\n\t\t}\r\n\t});\r\n}", "title": "" }, { "docid": "056c7a203d1846516ce75561f335a03f", "score": "0.4651522", "text": "static fetchGames(category, success, fail) {\n naxios.get(`/api/games/search/${category}`)\n .then((res) => { success(res); })\n .catch((err) => { fail(err); });\n }", "title": "" }, { "docid": "6f05c24df5ab540be9ea4ff5fce33c58", "score": "0.46495065", "text": "naturalSelection() {\n // Clear the ArrayList\n this.matingPool = [];\n\n let maxFitness = 0;\n for (let i = 0; i < this.population.genes.length; i++) {\n if (this.population.genes[i].fitness > maxFitness) {\n maxFitness = this.population.genes[i].fitness;\n }\n }\n\n for (let i = 0; i < this.population.genes.length; i++) {\n let fitness = this.p.map(this.population.genes[i].fitness, 0, maxFitness, 0, 1);\n let n = fitness * 100;\n for (let j = 0; j < n; j++) {\n this.matingPool.push(this.population.genes[i]);\n }\n }\n // console.log(this.matingPool.length)\n }", "title": "" }, { "docid": "6e7105014184e2412baec007b47d02f8", "score": "0.46472543", "text": "async fetchAllFacilitiesData() {\n return await this.cache.wrapGlobal('tdr_facilities', async () => {\n const headers = {};\n const lastModifiedTime = await this.cache.getGlobal('tdr_facilities_last_modified');\n if (lastModifiedTime !== undefined) {\n headers['If-Modified-Since'] = lastModifiedTime;\n }\n\n const resp = await this.http('GET', `${this.config.apiBase}/rest/v2/facilities`, undefined, {\n headers,\n });\n\n // store in a separate long-term cache so we can keep using it if the server data hasn't changed\n if (resp.statusCode !== 304) {\n // transform data into an array with \"facilityType\", rather than a nested object\n const data = [];\n Object.keys(resp.body).forEach((key) => {\n resp.body[key].forEach((x) => {\n data.push({\n facilityType: key,\n ...x,\n });\n });\n });\n\n await this.cache.setGlobal('tdr_facilities_data', data, Number.MAX_SAFE_INTEGER);\n await this.cache.setGlobal(\n 'tdr_facilities_last_modified',\n resp.headers['Last-Modified'],\n Number.MAX_SAFE_INTEGER,\n );\n return data;\n }\n\n return await this.cache.getGlobal('tdr_facilities_data');\n }, 1000 * 60 * 60 * 2); // check every 2 hours\n }", "title": "" }, { "docid": "39efa7040596e5f312751f1fe4ddc521", "score": "0.46465415", "text": "function getLeague() {\n requestApi(`${BASE_URL}competitions?plan=TIER_ONE&areas=2077`)\n .then(data => {\n setCompetitionData(data);\n });\n}", "title": "" } ]
6cbf3eb4c409e792dd8b049ace45daf9
The main node definition most things happen in here
[ { "docid": "6b2055ef19762571db0dceb3857e3873", "score": "0.0", "text": "function PatternMatchNode(n) {\n // Create a RED node\n RED.nodes.createNode(this, n);\n\n // Store local copies of the node configuration (as defined in the .html)\n this.topic = n.topic;\n this.swarmCount = parseInt(n.swarmCount)\n this.pattern = JSON.parse(n.pattern) || {};\n this.validations = JSON.parse(n.validations) || {};\n this.pattern.topic = this.pattern.topic || this.topic\n if (n.maxMessages) {\n this.pattern.$maxMessages = parseInt(n.maxMessages)\n }\n\n this.framework = n.framework || 'hemera';\n\n // copy \"this\" object in case we need it in context of callbacks of other functions.\n var node = this;\n\n // Do whatever you need to do in here - declare callbacks etc\n // Note: this sample doesn't do anything much - it will only send\n // this message once at startup...\n // Look at other real nodes for some better ideas of what to do....\n var msg = {};\n msg.topic = this.topic;\n\n let selectedFramework = RED.settings[node.framework]\n if (!selectedFramework) {\n node.error(`No settings defined for framework: ${node.framework}`)\n return\n }\n const actor = selectedFramework()\n // Use Joi as payload validator\n // https://github.com/senecajs/seneca-joi\n let pattern = resolvePattern({\n pattern: node.pattern,\n validations: node.validations,\n actor\n })\n actor.act(pattern,\n // see http://senecajs.org/getting-started/#patterns\n (payload, cb) => {\n msg.$payload = payload\n msg.$cb = cb\n // send msg to a function node which can then use the $cb\n // to publish message to hermera queue\n node.send(msg)\n }\n )\n\n this.on('close', function () {\n // Called when the node is shutdown - eg on redeploy.\n // Allows ports to be closed, connections dropped etc.\n // eg: node.client.disconnect();\n });\n }", "title": "" } ]
[ { "docid": "e2b348b0265611693babda31c5a220c6", "score": "0.7321752", "text": "function NodeDef() { }", "title": "" }, { "docid": "e2b348b0265611693babda31c5a220c6", "score": "0.7321752", "text": "function NodeDef() { }", "title": "" }, { "docid": "e2b348b0265611693babda31c5a220c6", "score": "0.7321752", "text": "function NodeDef() { }", "title": "" }, { "docid": "e2b348b0265611693babda31c5a220c6", "score": "0.7321752", "text": "function NodeDef() { }", "title": "" }, { "docid": "e4cba510cdfc00799210157f28e0b2d3", "score": "0.71431184", "text": "function Node() {}", "title": "" }, { "docid": "e0b4de02668dc10edf2dede3ee63a07f", "score": "0.69443053", "text": "function RNode() { }", "title": "" }, { "docid": "e0b4de02668dc10edf2dede3ee63a07f", "score": "0.69443053", "text": "function RNode() { }", "title": "" }, { "docid": "e0b4de02668dc10edf2dede3ee63a07f", "score": "0.69443053", "text": "function RNode() { }", "title": "" }, { "docid": "e0b4de02668dc10edf2dede3ee63a07f", "score": "0.69443053", "text": "function RNode() { }", "title": "" }, { "docid": "c8ecf0ec3560da15ebee7420a3cc36b9", "score": "0.6869904", "text": "function Node() {\r\n}", "title": "" }, { "docid": "c8ecf0ec3560da15ebee7420a3cc36b9", "score": "0.6869904", "text": "function Node() {\r\n}", "title": "" }, { "docid": "8949ce9c39d5f31709f6e1fff92e5fae", "score": "0.66829425", "text": "function TSNode()\n{\n\t\n}", "title": "" }, { "docid": "3b24559c8609d8096ebe0b9455bb6ce8", "score": "0.6677489", "text": "function TNode() { }", "title": "" }, { "docid": "3b24559c8609d8096ebe0b9455bb6ce8", "score": "0.6677489", "text": "function TNode() { }", "title": "" }, { "docid": "3b24559c8609d8096ebe0b9455bb6ce8", "score": "0.6677489", "text": "function TNode() { }", "title": "" }, { "docid": "3b24559c8609d8096ebe0b9455bb6ce8", "score": "0.6677489", "text": "function TNode() { }", "title": "" }, { "docid": "fdb25b0e992b1225e5ceab7301e0cd97", "score": "0.66766363", "text": "function Node() {\n}", "title": "" }, { "docid": "c3e284c144eee132203d9b82ab745355", "score": "0.6600508", "text": "function ExampleFlatNode() { }", "title": "" }, { "docid": "68281aeddeeebc65bfaa07492283175d", "score": "0.6538567", "text": "function Node(settings,data,parent,dom){//settings{r:10};\n\t\tthis.parent=parent;\n\t\tthis.master=parent.master;\n\t\tthis.module=parent.module;\n\t\t\n\t\tsettings=settings||{};\n\t\tsettings.r=settings.r||10;\n\t\t\n\t\tthis.dom=Template(dom,settings.r);\n\t\tthis.graph=parent;\n\t\t\n\t\tthis.label=undefined;\n\t\tthis.parent=parent;\n\t\tthis.srclinks={};\n\t\tthis.tglinks={};\n\t\tthis.coords={x:0,y:0};\n\t\tthis.name=data.name;\n\t\tthis.uuid=data.uuid;\n\t\t\n\t\tthis.addListeners();\n\t\tthis.newPosition(data.coords);\n\t}", "title": "" }, { "docid": "06a94b16822d6c46d5b9bdcf214ff044", "score": "0.64825356", "text": "makeNodes () {}", "title": "" }, { "docid": "cfbce0c90194d6456c274c0f24df0f3e", "score": "0.6386293", "text": "function ProgramNode(){}", "title": "" }, { "docid": "11bb20ef5ff8722633021b3b3e5ef2a5", "score": "0.6340003", "text": "function nodeDefinition(config) {\n // Create a RED node\n RED.nodes.createNode(this, config)\n\n // Store local copies of the node configuration (as defined in the .html)\n this.topic = config.topic\n this.input = config.input || 'payload' // where to take the input from\n this.inputType = config.inputType || 'msg' // msg, flow, global, timestamp or string\n this.fakeUTC = config.fakeUTC || false // is the input UTC rather than local date/time?\n this.adjAmount = config.adjAmount || 0 // number\n this.adjType = config.adjType || 'days' // days, hours, etc.\n this.adjDir = config.adjDir || 'add' // add or subtract\n this.format = config.format || '' // valid moment.js format string\n this.locale = config.locale || hostLocale // valid moment.js locale string - default to host locale (v4)\n this.output = config.output || 'payload' // where to put the output\n this.outputType = config.outputType || 'msg' // msg, flow or global\n this.inTz = config.inTz || false // timezone, '' or zone name, e.g. Europe/London\n this.outTz = config.outTz || this.inTz // timezone, '' or zone name, e.g. Europe/London\n\n /** copy \"this\" object in case we need it in context of callbacks of other functions. */\n var node = this\n\n // respond to inputs....\n /** @since v3.1.0, amended ready for Node-RED v1 */\n node.on('input', function (msg, send, done) {\n 'use strict' // We will be using eval() so lets get a bit of safety using strict\n\n // If this is pre-1.0, 'send' will be undefined, so fallback to node.send\n send = send || node.send\n // If this is pre-1.0, 'done' will be undefined, so fallback to dummy function\n done = done || function(){}\n\n \n // If the node's topic is set, copy to output msg\n if (node.topic !== '') {\n msg.topic = node.topic\n } // If nodes topic is blank, the input msg.topic is already there\n\n // make sure output property is set, if not, assume msg.payload\n if (node.output === '') {\n node.output = 'payload'\n //node.warn('Output field is REQUIRED, currently blank, set to payload');\n }\n if (node.outputType === '') {\n node.outputType = 'msg'\n node.warn('Output Type field is REQUIRED, currently blank, set to msg')\n }\n\n /** If the input property is blank, assume NOW as the required timestamp\n * or make sure that the node's input property actually exists on the input msg\n * @type {(string|Date|null)}\n **/\n var inp = ''\n // If input is a blank string, use a Date object with Now DT\n if (node.input === '') {\n inp = new Date()\n } else {\n // Otherwise, check which input type & get the input\n try {\n switch (node.inputType) {\n case 'msg':\n inp = RED.util.getMessageProperty(msg, node.input)\n break\n case 'flow':\n inp = node.context().flow.get(node.input)\n break\n case 'global':\n inp = node.context().global.get(node.input)\n break\n case 'date':\n inp = new Date()\n break\n case 'str':\n inp = node.input.trim()\n break\n default:\n inp = new Date()\n node.warn('Unrecognised Input Type, ' + node.inputType + '. Output has been set to NOW.')\n }\n } catch (err) {\n inp = new Date()\n node.warn('Input property, ' + node.inputType + '.' + node.input + ', does NOT exist. Output has been set to NOW.')\n }\n }\n // We are going to overwrite the output property without warning or permission!\n\n // Final check for input being a string (which moment doesn't really want to handle)\n // NB: moment.js v3 will stop accepting strings. v2.7+ throws a warning.\n /** @type {(string|Object)} */\n var dtHack = ''\n /** @type {(string|Date)} */\n var inpFmt = ''\n // @from v3 2018-09-23: If input is `null`, change to empty string\n if (inp === null) inp = ''\n if ((typeof inp) === 'string') {\n inp = inp.trim()\n // Some string input hacks\n switch (inp.toLowerCase()) {\n case 'today':\n inp = new Date()\n break\n case 'yesterday':\n inp = new Date()\n dtHack = { days: -1 }\n break\n case 'tomorrow':\n inp = new Date()\n dtHack = { days: +1 }\n break\n default:\n // Catch string ISO inputs with seconds >3dp which parseFormat treats incorrectly (Issue #24) - trim to 3dp only\n inp = catchDp(inp)\n // Try to guess locale so as to guess whether DMY or MDY\n var prefOrder = { preferredOrder: { '/': 'DMY', '.': 'DMY', '-': 'YMD' } }\n if ((node.locale.toLowerCase().replace('-', '_') === 'en_US') || (node.inTz.split('/')[0] === 'America')) {\n prefOrder = { preferredOrder: { '/': 'MDY', '.': 'DMY', '-': 'YMD' } }\n }\n inpFmt = parseFormat(inp, prefOrder)\n }\n } else if ((typeof inp) === 'number') {\n // @from 2017-06-15 IF inp is a number at this point, it needs turning into a date object\n inp = new Date(inp)\n }\n\n // At this point, `inp` SHOULD be a Date object and safe to pass to moment.js\n\n // Check if input TZ is provided in the msg?\n if (msg.inTz) {\n node.inTz = msg.inTz\n } else {\n // If the input TZ is not set ...\n if (!node.inTz) {\n // take it from the host TZ\n node.inTz = hostTz \n }\n }\n // Check if output TZ is provided in the msg?\n if (msg.outTz) {\n node.outTz = msg.outTz\n } else {\n // If the output TZ is not set ...\n if (!node.outTz) { \n // make it the same as the input TZ\n node.outTz = node.inTz \n }\n }\n\n // Validate input and output timezones - @since 2.0.4\n // TODO: Needs more validation\n if (moment.tz.zone(node.inTz) === null) {\n // tz invalid, warn and set to UTC\n node.warn('Moment: Input Timezone Invalid, reset to UTC - see http://momentjs.com/timezone/docs/#/data-loading/')\n node.inTz = 'UTC'\n }\n if (moment.tz.zone(node.outTz) === null) {\n // tz invalid, warn and set to UTC\n node.warn('Moment: Output Timezone Invalid, reset to UTC - see http://momentjs.com/timezone/docs/#/data-loading/')\n node.outTz = 'UTC'\n }\n\n // Get a Moment.JS date/time - NB: the result might not be\n // valid since the input might not parse as a date/time\n var mDT\n if (inpFmt !== '') {\n mDT = moment.tz(inp, inpFmt, true, node.inTz)\n } else {\n // @from 2017-06-15 change to momentjs meant having to add null parameter\n mDT = moment.tz(inp, null, true, node.inTz)\n }\n\n // Fallback to JS built-in Date parsing, if not recognized by moment\n if (!mDT.isValid()) {\n var dtm = new Date(inp)\n if (dtm === 'Invalid Date') {\n node.warn('Unrecognized date string format => ' + inp)\n }\n else {\n mDT = moment(dtm)\n }\n }\n\n // Adjust the date for input hacks if needed (e.g. input was \"yesterday\" or \"tommorow\")\n if (dtHack !== '') { mDT.add(dtHack) }\n\n // JK: Added OS locale lookup\n // JK: Add a trap to Jaques44's locale code in case the output locale string is invalid\n try {\n // Jacques44 - set locale for localised output formats\n mDT.locale(node.locale)\n } catch (err) {\n node.warn('Locale string invalid - check moment.js for valid strings')\n }\n\n // Adjust the input date if required\n if (node.adjAmount !== 0) {\n // check if measure is valid\n if (isMeasureValid(node.adjType)) {\n // NB: moments are mutable so don't need to reassign\n if (node.adjDir === 'subtract') {\n mDT.subtract(node.adjAmount, node.adjType)\n } else {\n mDT.add(node.adjAmount, node.adjType)\n }\n } else {\n // it isn't valid so warn and don't adjust\n node.warn('Adjustment measure type not valid, no adjustment made - check moment.js docs for valid measures (days, hours, etc)')\n }\n }\n\n // ==== NO MORE DATE/TIME CALCULATIONS AFTER HERE ==== //\n\n // If required, change to the output Timezone\n if (node.outTz !== '') mDT.tz(node.outTz)\n\n // Check if the input is a date?\n if (!mDT.isValid()) {\n // THIS SHOULD NEVER BE CALLED - it is left to catch the occasional error\n node.warn('The input property was NOT a recognisable date. Output will be a blank string')\n setOutput(msg, node.outputType, node.output, '')\n } else {\n // Handle different format strings. We allow any fmt str that\n // Moment.JS supports but also some special formats\n\n // If format not set, assume ISO8601 string if input is a Date otherwise assume Date\n switch (node.format.toLowerCase()) {\n case '':\n case 'iso8601':\n case 'iso':\n // Default to ISO8601 string\n setOutput(msg, node.outputType, node.output, mDT.toISOString())\n break\n case 'fromnow':\n case 'timeago':\n // We are also going to handle time-from-now (AKA time ago) format\n setOutput(msg, node.outputType, node.output, mDT.fromNow())\n break\n case 'calendar':\n case 'aroundnow':\n // We are also going to handle calendar format (AKA around now)\n // Force dates >1 week from now to be in ISO instead of US format\n setOutput(msg, node.outputType, node.output, mDT.calendar(null, { sameElse: 'YYYY-MM-DD' }))\n break\n case 'date':\n case 'jsdate':\n // we also allow output as a Javascript Date object\n setOutput(msg, node.outputType, node.output, mDT.toDate())\n break\n case 'object':\n // we also allow output as a Javascript Date object\n setOutput(msg, node.outputType, node.output, mDT.toObject())\n break\n default:\n // or we assume it is a valid format definition ...\n setOutput(msg, node.outputType, node.output, mDT.format(node.format))\n }\n }\n\n // Include settings in output\n msg.settings = {\n 'input': inp,\n 'input_format': inpFmt,\n 'input_tz': node.inTz,\n 'output_format': node.format,\n 'output_locale': node.locale,\n 'output_tz': node.outTz,\n }\n\n // Send the output message\n send(msg)\n // Finished processing input msg (NR 1+)\n done()\n })\n\n // Tidy up if we need to\n //node.on('close', function() {\n // Called when the node is shutdown - eg on redeploy.\n // Allows ports to be closed, connections dropped etc.\n // eg: node.client.disconnect();\n //});\n\n // Set the appropriate output variable\n function setOutput(msg, outputType, output, value) {\n try {\n switch (outputType) {\n case 'msg':\n RED.util.setMessageProperty(msg, output, value)\n break\n case 'flow':\n node.context().flow.set(output, value)\n break\n case 'global':\n node.context().global.set(output, value)\n break\n default:\n node.warn('Unrecognised Output Type, ' + outputType + '. No output.')\n }\n } catch (err) {\n node.warn('Output property, ' + outputType + '.' + output + ', cannot be set. No output.', err)\n }\n } // --- end of setOutput function --- //\n\n // Is the date/time adjustment type (measure) valid? See moment.js docs\n function isMeasureValid(adjType) {\n var validTypes = ['years', 'y', 'quarters', 'Q', 'months', 'M', 'weeks', 'w', 'days', 'd', 'hours', 'h', 'minutes', 'm', 'seconds', 's', 'milliseconds', 'ms']\n //return validTypes.includes(adjType);\n return validTypes.indexOf(adjType) > -1\n } // --- end of isMeasureValid function --- //\n\n }", "title": "" }, { "docid": "0baf5c5a698155beecbf7a08a03bfd2f", "score": "0.6260086", "text": "function Node(name, type) {\n if (type === void 0) { type = NodeType.REGULAR; }\n /**\n * A list of all sub-graphs this node belongs to\n */\n this.subGraphList = [];\n /**\n * A list of all edges that are connected to this node\n * @type {Array}\n */\n this.edgeList = [];\n /**\n * A list of all filters this node belongs to\n * @type {Array}\n */\n this.filterList = [];\n /**\n * A list of all binds this node belongs to\n * @type {Array}\n */\n this.bindList = [];\n /**\n * A list of all unions this node belongs to\n * @type {Array}\n */\n this.unionList = [];\n /**\n * A list of all order-by-statements this node belongs to\n * @type {Array}\n */\n this.orderList = [];\n /**\n * A list of all services this node belongs to\n * @type {Array}\n */\n this.serviceList = [];\n /**\n * The ellipse-parameter a so that x^2 / a^2 + y^2 / b^2 = 1\n */\n this.rx = 20;\n /**\n * The ellipse-parameter b so that x^2 / a^2 + y^2 / b^2 = 1\n */\n this.ry = 10;\n this.fixed = false;\n this.name = name;\n this.type = type;\n }", "title": "" }, { "docid": "c1becb4b95460da703c4b3e5ea94380a", "score": "0.6258673", "text": "getType() {\r\n return 'NODE'\r\n }", "title": "" }, { "docid": "f61eb015f346daa252fb03f805d69aee", "score": "0.61850643", "text": "function NodeWrapper() {\n\t this._node = this.constructor.createNode();\n\t }", "title": "" }, { "docid": "0ef2dd0c222d4b8804827c1c2ccb4317", "score": "0.61256444", "text": "function VNode() {}", "title": "" }, { "docid": "7145759088349495a7726c15cd55539d", "score": "0.61130124", "text": "function Node() {\n this._init.apply(this, arguments);\n}", "title": "" }, { "docid": "64c4ca6522d95ff9f22462427174bb31", "score": "0.61102957", "text": "createNodes() {\n // Create WebAudio nodes\n //this.eq = new EqualizerMetal(this.context);\n //this.ampReverb = new ConvolverMetal(this.context, this.reverbImpulses, \"reverbImpulses\");\n //this.cabinetSim = new ConvolverMetal(this.context, this.cabinetImpulses, \"cabinetImpulses\");\n //this.boost = new BoostMetal(this.context);\n\n //this.amp = new AmpMetal(this.context, this.boost, this.eq, this.ampReverb, this.cabinetSim);\n this.amp = new AmpMetal(this.context, this.cabinetImpulses, this.reverbImpulses);\n }", "title": "" }, { "docid": "45fdd07228caa6764bec0275b1e85f37", "score": "0.6059126", "text": "function addNodes () \n{\n\tLiteGraph.registerNodeType(\"basic/constant number\", constantNumberNode);\n\tLiteGraph.registerNodeType(\"basic/random number\" , randomNumberNode);\n\tLiteGraph.registerNodeType(\"basic/load texture\" , textureLoadNode);\n\tLiteGraph.registerNodeType(\"basic/load mesh\" , meshLoadNode);\n\tLiteGraph.registerNodeType(\"basic/equation\" , equationNode);\n\tLiteGraph.registerNodeType(\"basic/vector 2\" , vector2Node);\n\tLiteGraph.registerNodeType(\"basic/vector 3\" , vector3Node);\n\tLiteGraph.registerNodeType(\"basic/vector 4\" , vector4Node);\n\tLiteGraph.registerNodeType(\"basic/color picker\" , colorPickerNode);\n\t\n\tLiteGraph.registerNodeType(\"spawn/emitter\" , mySpawnNode);\n\tLiteGraph.registerNodeType(\"spawn/sub emitter\" , subEmitterNode);\n\tLiteGraph.registerNodeType(\"init/init\" , initParticlesNode);\n\tLiteGraph.registerNodeType(\"init/particle data\" , particleDataNode);\n\n\tLiteGraph.registerNodeType(\"forces/gravity\" , gravityNode);\n\tLiteGraph.registerNodeType(\"forces/vortex\" , vortexNode);\n\tLiteGraph.registerNodeType(\"forces/magnet point\" , magnetNode);\n\n\tLiteGraph.registerNodeType(\"conditions/create condition\", createConditionNode);\n\tLiteGraph.registerNodeType(\"conditions/merge conditions\", mergeConditionsNode);\n\n\tLiteGraph.registerNodeType(\"modify/modify property\", modifyPropertyNode);\n}", "title": "" }, { "docid": "48d6b420f41147b4f0d173b1e7af01f1", "score": "0.6042533", "text": "function node() {\n invoke(this);\n }", "title": "" }, { "docid": "a45f35719a77eb078a3afea9a7f00c5a", "score": "0.60066265", "text": "function Node(type, patch, def, render, callback) {\n this.type = type || 'core/basic';\n this.toolkit = extract_toolkit(type);\n this.id = short_uid();\n this.patch = patch;\n\n var event_types = {\n 'node/turn-on': [ ],\n 'node/is-ready': [ ],\n 'node/process': [ 'inlets', 'outlets' ],\n 'node/turn-off': [ ],\n 'node/add-inlet': [ 'inlet' ],\n 'node/remove-inlet': [ 'inlet' ],\n 'node/add-outlet': [ 'outlet' ],\n 'node/remove-outlet': [ 'outlet' ],\n 'node/move': [ 'position' ],\n 'node/configure': [ 'props' ]\n };\n this.event = create_event_map(event_types);\n this.events = create_events_stream(event_types, this.event, 'node', this);\n\n var type_def = adapt_to_obj(nodetypes[this.type], this);\n if (!type_def) report_system_error(this, 'node', 'Node type \\'' + this.type + '\\' is not registered!');\n this.def = join_definitions(NODE_PROPS, def, type_def);\n\n this.render = join_render_definitions(NODE_RENDERER_PROPS, render,\n prepare_render_obj(noderenderers[this.type], this));\n\n if (callback) callback(this);\n\n var node = this;\n\n if (this.def.handle) subscribe(this.events, this.def.handle);\n\n if (this.def.process) {\n\n var process_f = this.def.process;\n\n var process = Kefir.combine([\n\n // when new inlet was added, start monitoring its updates\n // as an active stream\n this.event['node/add-inlet'].flatMap(function(inlet) {\n var updates = inlet.event['inlet/update'].map(function(value) {\n return { inlet: inlet, value: value };\n });;\n if (node.def.tune) updates = node.def.tune.bind(node)(updates);\n return updates;\n })\n\n ],\n [\n // collect all the existing outlets aliases as a passive stream\n this.event['node/add-outlet'].scan(function(storage, outlet) {\n storage[outlet.alias] = outlet;\n return storage;\n }, {})\n\n ])\n\n // do not fire any event until node is ready, then immediately fire them one by one, if any occured;\n // later events are fired after node/is-ready, corresponding to their time of firing, as usual\n process = process.bufferBy(this.event['node/is-ready']).take(1).flatten().concat(process);\n\n process = process.scan(function(storage, update) {\n // update[0] is inlet value update, update[1] is a list of outlets\n var inlet = update[0].inlet;\n var alias = inlet.alias;\n storage.inlets.prev[alias] = storage.inlets.cur[alias];\n storage.inlets.cur[alias] = update[0].value;\n storage.outlets = update[1];\n storage.source = inlet;\n return storage;\n }, { inlets: { prev: {}, cur: {} }, outlets: {} }).changes();\n\n // filter cold inlets, so the update data will be stored, but process event won't fire\n process = process.filter(function(data) { return !data.source.def.cold; });\n\n process.onValue(function(data) {\n // call a node/process event using collected inlet values\n var outlets_vals = process_f.bind(node)(data.inlets.cur, data.inlets.prev);\n node.event['node/process'].emit({ inlets: data.inlets.cur, outlets: outlets_vals });\n // send the values provided from a `process` function to corresponding outlets\n var outlets = data.outlets;\n for (var outlet_name in outlets_vals) {\n if (outlets[outlet_name]) {\n if (outlets_vals[outlet_name] instanceof Kefir.Stream) {\n outlets[outlet_name].stream(outlets_vals[outlet_name]);\n } else {\n outlets[outlet_name].send(outlets_vals[outlet_name]);\n }\n };\n }\n });\n\n }\n\n // only inlets / outlets described in type definition are stored inside\n // (since they are constructed once), it lets user easily connect to them\n\n if (this.def.inlets) {\n this.inlets = {};\n for (var alias in this.def.inlets) {\n var conf = this.def.inlets[alias];\n var inlet = this.addInlet(conf.type, alias, conf);\n this.inlets[alias] = inlet;\n }\n }\n\n if (this.def.outlets) {\n this.outlets = {};\n for (var alias in this.def.outlets) {\n var conf = this.def.outlets[alias];\n var outlet = this.addOutlet(conf.type, alias, conf);\n this.outlets[alias] = outlet;\n }\n }\n\n if (this.def.prepare) this.def.prepare.bind(this)(this.inlets, this.outlets);\n\n this.event['node/is-ready'].emit();\n}", "title": "" }, { "docid": "223ac44821ff7b2cccbca65df92ac46f", "score": "0.599425", "text": "constructor(polyInterface, primary, address, name, id) {\r\n super(nodeDefId, polyInterface, primary, address, name);\r\n\r\n this.tesla = require('../lib/tesla.js')(Polyglot, polyInterface);\r\n\r\n // PGC supports setting the node hint when creating a node\r\n // REF: https://github.com/UniversalDevicesInc/hints\r\n // Must be a string in this format\r\n // If you don't care about the hint, just comment the line.\r\n this.hint = '0x01130101'; // See hints.yaml\r\n\r\n // Commands that this node can handle.\r\n // Should match the 'accepts' section of the nodedef.\r\n this.commands = {\r\n DON: this.onDON, // Charge On, up to\r\n DOF: this.onDOF, // Charge off\r\n WAKE: this.onWake,\r\n HORN: this.onHorn,\r\n FLASH: this.onFlash,\r\n LOCK: this.onLock,\r\n UNLOCK: this.onUnlock,\r\n SUNROOF_OPEN: this.onSunroofOpen,\r\n SUNROOF_CLOSE: this.onSunroofClose,\r\n PORT_OPEN: this.onPortOpen,\r\n PORT_CLOSE: this.onPortClose,\r\n CHARGE_SET_TO: this.onChargeSetTo,\r\n QUERY: this.query, // Query function from the base class\r\n CLIMATE_OFF: this.onClimateOff, // stop pre-heat or pre-cool of the car\r\n CLIMATE_ON: this.onClimateOn, // pre-heat or pre-cool the car\r\n };\r\n\r\n // Status that this node has.\r\n // Should match the 'sts' section of the nodedef.\r\n // Must all be strings\r\n this.drivers = {\r\n ST: { value: '', uom: 51 }, // SOC%\r\n GV1: { value: '', uom: 56 }, // Battery range\r\n GV2: { value: '', uom: 2 }, // Charge port door open\r\n GV3: { value: '', uom: 2 }, // Charge port latch engaged\r\n GV4: { value: '', uom: 2 }, // Charge enable request\r\n GV5: { value: '', uom: 2 }, // Charging state\r\n GV6: { value: '', uom: 2 }, // Fast charger present\r\n GV7: { value: '', uom: 51 }, // Charge limit SOC%\r\n CC: { value: '', uom: 1 }, // Charger actual current\r\n CV: { value: '', uom: 72 }, // Charger voltage\r\n CPW: { value: '', uom: 73 }, // Charger power\r\n GV8: { value: '', uom: 2 }, // Locked?\r\n GV9: { value: '', uom: 51 }, // Sunroof open%\r\n GV10: { value: '', uom: 56 }, // Odometer\r\n GV18: { value: '', uom: 2 }, // Online?\r\n GV19: { value: '', uom: 56 }, // Last updated unix timestamp\r\n GV20: { value: id, uom: 56 }, // ID used for the Tesla API\r\n CLITEMP: { value: '', uom: 4 }, // Interior temperature\r\n CLIEMD: { value: '', uom: 2 }, // Climate conditioning on\r\n ERR: { value: '', uom: 2 }, // In error?\r\n };\r\n }", "title": "" }, { "docid": "dd21e2d755ade772a600113685e80488", "score": "0.59583294", "text": "constructor(polyInterface, primary, address, name, id) {\n super(nodeDefId, polyInterface, primary, address, name);\n\n this.tesla = require('../lib/tesla_v3.js')(Polyglot, polyInterface);\n\n // PGC supports setting the node hint when creating a node\n // REF: https://github.com/UniversalDevicesInc/hints\n // Must be a string in this format\n // If you don't care about the hint, just comment the line.\n this.hint = '0x01130101'; // See hints.yaml\n \n // Commands that this node can handle.\n // Should match the 'accepts' section of the nodedef.\n this.commands = {\n QUERY_NOW: this.queryNow, // Force a query now to update the status\n DON: this.onClimateOn, // pre-heat or pre-cool the car\n DOF: this.onClimateOff, // stop pre-heat or pre-cool of the car\n };\n\n \n\n // Status that this node has.\n // Should match the 'sts' section of the nodedef.\n // Must all be strings\n this.drivers = {\n ST: { value: '', uom: 25 }, // Conditioning status\n GV19: { value: '', uom: 56 }, // Last updated unix timestamp\n GV20: { value: id, uom: 56 }, // ID used for the Tesla API\n ERR: { value: '', uom: 2 } // In error?\n };\n\n }", "title": "" }, { "docid": "1e8fa2d7a8ed289c396242d44cb313b3", "score": "0.59423363", "text": "function NodeClass() {\r\nthis.Name = \"\",\r\nthis.Node = \"\"; \r\n}", "title": "" }, { "docid": "831bc46dfa79cfa7bcc819059d2dec43", "score": "0.592733", "text": "addHead(node) {\n\n }", "title": "" }, { "docid": "ff9808aa11ab7af9aaa0175b3541327f", "score": "0.5910626", "text": "function Node(type){\n return {\n type: type,\n operand: \"\",\n children: [],\n boundary: 0, //Stores the size boundary of the node\n position: null, //Stores the position of the node after it has been drawn, only used for distance checking\n width: 160,\n height: 80,\n strokeColour: \"#111111\"\n };\n}", "title": "" }, { "docid": "f180d0adbcd72db24cf75f3074e4649e", "score": "0.5897654", "text": "function NODE_displayNodeElements()\n{\n\tpost(\"Content = \", this.content, \" at level \", this.level, \" operationID = \", this.operationID, \"\\n\");\n\tpost(\"Position in the text of the rule - begins at \", this.begInText, \" to \", this.endInText, \"\\n\");\n\tpost(\"Indexes = left son is \", this.leftSonIndex, \" right son is \", this.rightSonIndex, \"\\n\");\n\tpost(\"Current value = \", this.currentValue, \" has received value = \", this.hasReceivedValue, \"\\n\");\n\tpost(\"Refers to LV = \", this.LVReferencedName, \"#\", this.LVReferencedIndex, \" and FSS = \", this.FSSReferencedName, \"#\", this.FSSReferencedIndex, \"\\n\");\n}", "title": "" }, { "docid": "646520b513d6cc2123de00df367c73a3", "score": "0.5843195", "text": "function Node(opts) {\n this.after = opts.after;\n this.before = opts.before;\n this.type = opts.type;\n this.value = opts.value;\n this.sourceIndex = opts.sourceIndex;\n }", "title": "" }, { "docid": "5e1c8176b0a8294afd63f99324dd896d", "score": "0.5840305", "text": "function nodeGo(config) {\n // Create a RED node\n RED.nodes.createNode(this,config);\n\n // Store local copies of the node configuration (as defined in the .html)\n this.topic = config.topic;\n this.input = config.input || 'payload'; // where to take the input from\n\n // copy \"this\" object in case we need it in context of callbacks of other functions.\n var node = this;\n\n // respond to inputs....\n node.on('input', function (msg) {\n 'use strict'; // We will be using eval() so lets get a bit of safety using strict\n const input = this.input || 0;\n\n // get input settings\n var time = parseInt(input) * 1000;\n msg.payload = msg.payload || {};\n\n nodeRedAdapter(node, msg, time);\n });\n\n } // ---- end of nodeGo function ---- //", "title": "" }, { "docid": "c5435de9eab20497f5fae5ee2c44e0de", "score": "0.58399796", "text": "function Node() {\n\t this.a = 20; \n\t}", "title": "" }, { "docid": "3274c1a49b841738cd4662dfd4e79143", "score": "0.583895", "text": "function initialize ()\r\n {\r\n // appearance of the drawable component of this node\r\n var appearance = new x3dom.nodeTypes.Appearance( ctx );\r\n // multiTexture to get heightmap and colormap to gpu\r\n var textures = new x3dom.nodeTypes.MultiTexture( ctx );\r\n // texture that should represent the surface-data of this node\r\n var colorTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n // texture that should represent the height-data of this node\r\n var heightTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n // texture that should represent the normal-data of this node\r\n var normalTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n // creating the special shader for these nodes\r\n var composedShader = new x3dom.nodeTypes.ComposedShader( ctx );\r\n\r\n // definition of the nameSpace of this shape\r\n shape._nameSpace = bvhRefiner._nameSpace;\r\n\r\n // calculate the average position of the node\r\n position = nodeTransformation.e3();\r\n\r\n // creating the special vertex-shader for bvhRefiner-nodes\r\n var vertexShader = new x3dom.nodeTypes.ShaderPart( ctx );\r\n vertexShader._vf.type = \"vertex\";\r\n vertexShader._vf.url[ 0 ] = createVertexShader();\r\n\r\n // creating the special fragment-shader for bvhRefiner-nodes\r\n var fragmentShader = new x3dom.nodeTypes.ShaderPart( ctx );\r\n fragmentShader._vf.type = \"fragment\";\r\n fragmentShader._vf.url[ 0 ] = createFragmentShader();\r\n\r\n // create complete-shader with vertex- and fragment-shader\r\n composedShader.addChild( vertexShader, \"parts\" );\r\n composedShader.addChild( fragmentShader, \"parts\" );\r\n\r\n // create texture-data of this node with url's of the texture data\r\n colorTexture._nameSpace = bvhRefiner._nameSpace;\r\n colorTexture._vf.url[ 0 ] = imageAddressColor;\r\n colorTexture._vf.repeatT = false;\r\n colorTexture._vf.repeatS = false;\r\n colorTexture._vf.generateMipMaps = false;\r\n textures.addChild( colorTexture, \"texture\" );\r\n colorTexture.nodeChanged();\r\n var colorTextureField = new x3dom.nodeTypes.Field( ctx );\r\n colorTextureField._vf.name = \"texColor\";\r\n colorTextureField._vf.type = \"SFInt32\";\r\n colorTextureField._vf.value = 0;\r\n composedShader.addChild( colorTextureField, \"fields\" );\r\n colorTextureField.nodeChanged();\r\n\r\n // create height-data\r\n heightTexture._nameSpace = bvhRefiner._nameSpace;\r\n heightTexture._vf.url[ 0 ] = imageAddressHeight;\r\n heightTexture._vf.repeatT = false;\r\n heightTexture._vf.repeatS = false;\r\n\r\n /*heightTexture._cf.textureProperties.node = new x3dom.nodeTypes.TextureProperties(ctx);\r\n heightTexture._cf.textureProperties.node._vf.minificationFilter = 'NEAREST';\r\n heightTexture._cf.textureProperties.node._vf.magnificationFilter = 'NEAREST';\r\n heightTexture._cf.textureProperties.node._vf.generateMipMaps = false;\r\n heightTexture._cf.textureProperties.node._vf.boundaryModeS = 'MIRRORED_REPEAT';\r\n heightTexture._cf.textureProperties.node._vf.boundaryModeT = 'MIRRORED_REPEAT';\r\n heightTexture._cf.textureProperties.node._vf.boundaryModeR = 'MIRRORED_REPEAT';*/\r\n\r\n textures.addChild( heightTexture, \"texture\" );\r\n heightTexture.nodeChanged();\r\n var heightTextureField = new x3dom.nodeTypes.Field( ctx );\r\n heightTextureField._vf.name = \"texHeight\";\r\n heightTextureField._vf.type = \"SFInt32\";\r\n heightTextureField._vf.value = 1;\r\n composedShader.addChild( heightTextureField, \"fields\" );\r\n heightTextureField.nodeChanged();\r\n\r\n // create normal-data\r\n normalTexture._nameSpace = bvhRefiner._nameSpace;\r\n normalTexture._vf.url[ 0 ] = imageAddressNormal;\r\n normalTexture._vf.repeatT = false;\r\n normalTexture._vf.repeatS = false;\r\n textures.addChild( normalTexture, \"texture\" );\r\n normalTexture.nodeChanged();\r\n var normalTextureField = new x3dom.nodeTypes.Field( ctx );\r\n normalTextureField._vf.name = \"texNormal\";\r\n normalTextureField._vf.type = \"SFInt32\";\r\n normalTextureField._vf.value = 2;\r\n composedShader.addChild( normalTextureField, \"fields\" );\r\n normalTextureField.nodeChanged();\r\n\r\n // transmit maximum elevation value to gpu\r\n var maxHeight = new x3dom.nodeTypes.Field( ctx );\r\n maxHeight._vf.name = \"maxElevation\";\r\n maxHeight._vf.type = \"SFFloat\";\r\n maxHeight._vf.value = bvhRefiner._vf.maxElevation;\r\n composedShader.addChild( maxHeight, \"fields\" );\r\n maxHeight.nodeChanged();\r\n\r\n // add textures to the appearence of this node\r\n appearance.addChild( textures );\r\n textures.nodeChanged();\r\n appearance.addChild( composedShader );\r\n composedShader.nodeChanged();\r\n\r\n // create shape with geometry and appearance data\r\n shape.addChild( appearance );\r\n appearance.nodeChanged();\r\n shape.addChild( geometry );\r\n geometry.nodeChanged();\r\n\r\n // add shape to bvhRefiner object\r\n bvhRefiner.addChild( shape );\r\n shape.nodeChanged();\r\n\r\n // definition the static properties of cullObject\r\n cullObject.boundedNode = shape;\r\n cullObject.volume = shape.getVolume();\r\n // setting max and min in z-direction to get the complete volume\r\n cullObject.volume.max.z = Math.round( bvhRefiner._vf.maxElevation );\r\n cullObject.volume.min.z = -cullObject.volume.max.z;\r\n }", "title": "" }, { "docid": "7a84134df5ae508b95fb531d13ced7db", "score": "0.58096105", "text": "function TElementNode() { }", "title": "" }, { "docid": "7a84134df5ae508b95fb531d13ced7db", "score": "0.58096105", "text": "function TElementNode() { }", "title": "" }, { "docid": "7a84134df5ae508b95fb531d13ced7db", "score": "0.58096105", "text": "function TElementNode() { }", "title": "" }, { "docid": "7a84134df5ae508b95fb531d13ced7db", "score": "0.58096105", "text": "function TElementNode() { }", "title": "" }, { "docid": "066b7d2db03e80b7dde9ab49420988f6", "score": "0.5778807", "text": "function TViewNode() { }", "title": "" }, { "docid": "066b7d2db03e80b7dde9ab49420988f6", "score": "0.5778807", "text": "function TViewNode() { }", "title": "" }, { "docid": "066b7d2db03e80b7dde9ab49420988f6", "score": "0.5778807", "text": "function TViewNode() { }", "title": "" }, { "docid": "066b7d2db03e80b7dde9ab49420988f6", "score": "0.5778807", "text": "function TViewNode() { }", "title": "" }, { "docid": "79e783c43f2b7177aeb7673de4c54150", "score": "0.57677126", "text": "function Node() { \n this.states = [];\n this.lastStateIdx = -1;\n this.attrs = {};\n }", "title": "" }, { "docid": "3d3a62d9ec8ee4ad80c40a8cb29ba123", "score": "0.5764745", "text": "function node(data,next){\n this.data=data;\n this.next=next\n}", "title": "" }, { "docid": "81eb38b77ebd718c2fd24fbf8ede34b7", "score": "0.5743788", "text": "function nodeTemplate(diagram, node) {\n node.labels[0].text = node.Function;\n node.fillColor = node.Color;\n if (node.Id === 'parent') { node.fillColor = '#3484bb'; }\n if (node.Phase === 'parent') { node.fillColor = '#9ace7f'; }\n if (node.Phase === '1') { node.fillColor = '#9264aa'; }\n if (node.Phase === '2') { node.fillColor = '#9264aa'; }\n if (node.Phase === '3') { node.fillColor = '#9264aa'; }\n }", "title": "" }, { "docid": "0eb4c9534eaeb2b6c43bd96f6dadfed6", "score": "0.5737575", "text": "_add( node){\n\t\tvar\n\t\t type= node[ \"@type\"],\n\t\t label= node[ prefixes.rdfs+ \"label\"]\n\t\tlabel= label&& label[ \"@value\"]|| label\n\t\tif( isOrIncludes( type, Type.Class)){\n\t\t\tthis._classes[ label]= node\n\t\t}else if( isOrIncludes( type, Type.Property)){\n\t\t\tvar\n\t\t\t domain= node[ prefixes.rdfs+ \"domain\"][ \"@id\"],\n\t\t\t classProperties= this._classProperties[ domain]|| (this._classProperties[ domain]= {})\n\t\t\tclassProperties[ label]= node\n\t\t}else if( isOrIncludes( type, Type.Vocab)){\n\t\t\tthis._ontologies[ node[ \"@id\"]]= node\n\t\t\n\t\t}\n\t}", "title": "" }, { "docid": "7889d56892abd143b8cf28f66c515323", "score": "0.5733928", "text": "function LeafNode() {}", "title": "" }, { "docid": "94a3e6147d186973b2839a51dbf87214", "score": "0.57212424", "text": "function initialize ()\r\n {\r\n // appearance of the drawable component of this node\r\n var appearance = new x3dom.nodeTypes.Appearance( ctx );\r\n // multiTexture to get heightmap and colormap to gpu\r\n var textures = new x3dom.nodeTypes.MultiTexture( ctx );\r\n // texture that should represent the surface-data of this node\r\n var colorTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n // texture that should represent the height-data of this node\r\n var heightTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n // texture that should represent the normal-data of this node\r\n var normalTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n // creating the special shader for these nodes\r\n var composedShader = new x3dom.nodeTypes.ComposedShader( ctx );\r\n\r\n // definition of the nameSpace of this shape\r\n shape._nameSpace = bvhRefiner._nameSpace;\r\n\r\n // calculate the average position of the node\r\n position = nodeTransformation.e3();\r\n position.z = bvhRefiner._vf.maxElevation / 2;\r\n\r\n // creating the special vertex-shader for bvhRefiner-nodes\r\n var vertexShader = new x3dom.nodeTypes.ShaderPart( ctx );\r\n vertexShader._vf.type = \"vertex\";\r\n vertexShader._vf.url[ 0 ] = createVertexShader();\r\n\r\n // creating the special fragment-shader for bvhRefiner-nodes\r\n var fragmentShader = new x3dom.nodeTypes.ShaderPart( ctx );\r\n fragmentShader._vf.type = \"fragment\";\r\n fragmentShader._vf.url[ 0 ] = createFragmentShader();\r\n\r\n // create complete-shader with vertex- and fragment-shader\r\n composedShader.addChild( vertexShader, \"parts\" );\r\n composedShader.addChild( fragmentShader, \"parts\" );\r\n\r\n var colorTexProp = new x3dom.nodeTypes.TextureProperties( ctx );\r\n colorTexProp._vf.boundaryModeS = \"CLAMP_TO_EDGE\";\r\n colorTexProp._vf.boundaryModeT = \"CLAMP_TO_EDGE\";\r\n colorTexProp._vf.boundaryModeR = \"CLAMP_TO_EDGE\";\r\n colorTexProp._vf.minificationFilter = \"LINEAR\";\r\n colorTexProp._vf.magnificationFilter = \"LINEAR\";\r\n colorTexture.addChild( colorTexProp, \"textureProperties\" );\r\n colorTexture.nodeChanged();\r\n // create texture-data of this node with url's of the texture data\r\n colorTexture._nameSpace = bvhRefiner._nameSpace;\r\n colorTexture._vf.url[ 0 ] = imageAddressColor;\r\n colorTexture._vf.repeatT = false;\r\n colorTexture._vf.repeatS = false;\r\n textures.addChild( colorTexture, \"texture\" );\r\n colorTexture.nodeChanged();\r\n var colorTextureField = new x3dom.nodeTypes.Field( ctx );\r\n colorTextureField._vf.name = \"texColor\";\r\n colorTextureField._vf.type = \"SFInt32\";\r\n colorTextureField._vf.value = 0;\r\n composedShader.addChild( colorTextureField, \"fields\" );\r\n colorTextureField.nodeChanged();\r\n\r\n // create height-data\r\n var heightTexProp = new x3dom.nodeTypes.TextureProperties( ctx );\r\n heightTexProp._vf.boundaryModeS = \"CLAMP_TO_EDGE\";\r\n heightTexProp._vf.boundaryModeT = \"CLAMP_TO_EDGE\";\r\n heightTexProp._vf.boundaryModeR = \"CLAMP_TO_EDGE\";\r\n heightTexProp._vf.minificationFilter = \"NEAREST\";\r\n heightTexProp._vf.magnificationFilter = \"NEAREST\";\r\n heightTexture.addChild( heightTexProp, \"textureProperties\" );\r\n heightTexture.nodeChanged();\r\n heightTexture._nameSpace = bvhRefiner._nameSpace;\r\n heightTexture._vf.url[ 0 ] = imageAddressHeight;\r\n heightTexture._vf.repeatT = false;\r\n heightTexture._vf.repeatS = false;\r\n heightTexture._vf.scale = false;\r\n textures.addChild( heightTexture, \"texture\" );\r\n heightTexture.nodeChanged();\r\n var heightTextureField = new x3dom.nodeTypes.Field( ctx );\r\n heightTextureField._vf.name = \"texHeight\";\r\n heightTextureField._vf.type = \"SFInt32\";\r\n heightTextureField._vf.value = 1;\r\n composedShader.addChild( heightTextureField, \"fields\" );\r\n heightTextureField.nodeChanged();\r\n\r\n if ( bvhRefiner._vf.normalUrl !== \"\" )\r\n {\r\n var normalTexProp = new x3dom.nodeTypes.TextureProperties( ctx );\r\n normalTexProp._vf.boundaryModeS = \"CLAMP_TO_EDGE\";\r\n normalTexProp._vf.boundaryModeT = \"CLAMP_TO_EDGE\";\r\n normalTexProp._vf.boundaryModeR = \"CLAMP_TO_EDGE\";\r\n normalTexProp._vf.minificationFilter = \"LINEAR\";\r\n normalTexProp._vf.magnificationFilter = \"LINEAR\";\r\n normalTexture.addChild( normalTexProp, \"textureProperties\" );\r\n normalTexture.nodeChanged();\r\n // create normal-data\r\n normalTexture._nameSpace = bvhRefiner._nameSpace;\r\n normalTexture._vf.url[ 0 ] = imageAddressNormal;\r\n normalTexture._vf.repeatT = false;\r\n normalTexture._vf.repeatS = false;\r\n textures.addChild( normalTexture, \"texture\" );\r\n normalTexture.nodeChanged();\r\n var normalTextureField = new x3dom.nodeTypes.Field( ctx );\r\n normalTextureField._vf.name = \"texNormal\";\r\n normalTextureField._vf.type = \"SFInt32\";\r\n normalTextureField._vf.value = 2;\r\n composedShader.addChild( normalTextureField, \"fields\" );\r\n normalTextureField.nodeChanged();\r\n }\r\n\r\n // transmit maximum elevation value to gpu\r\n var maxHeight = new x3dom.nodeTypes.Field( ctx );\r\n maxHeight._vf.name = \"maxElevation\";\r\n maxHeight._vf.type = \"SFFloat\";\r\n maxHeight._vf.value = bvhRefiner._vf.maxElevation;\r\n composedShader.addChild( maxHeight, \"fields\" );\r\n maxHeight.nodeChanged();\r\n\r\n // add textures to the appearence of this node\r\n appearance.addChild( textures );\r\n textures.nodeChanged();\r\n appearance.addChild( composedShader );\r\n composedShader.nodeChanged();\r\n\r\n // create shape with geometry and appearance data\r\n shape.addChild( appearance );\r\n appearance.nodeChanged();\r\n shape.addChild( geometry );\r\n\r\n // add shape to bvhRefiner object\r\n bvhRefiner.addChild( shape );\r\n shape.nodeChanged();\r\n\r\n // definition the static properties of cullObject\r\n cullObject.boundedNode = shape;\r\n cullObject.volume = shape.getVolume();\r\n // setting max and min in z-direction to get the complete volume\r\n cullObject.volume.max.z = bvhRefiner._vf.maxElevation;\r\n cullObject.volume.min.z = 0;\r\n\r\n cullObject.volume.center = cullObject.volume.min.add( cullObject.volume.max ).multiply( 0.5 );\r\n cullObject.volume.transform( nodeTransformation );\r\n //shape._graph.volume = cullObject.volume;\r\n\r\n calculateNeighborhood();\r\n }", "title": "" }, { "docid": "978f2799f129d584d1919b62daa8d09e", "score": "0.5696326", "text": "function nodeTemplate(diagram, node) {\n node.labels[0].text = node.Function;\n node.fillColor = node.Color;\n if (node.Id == \"parent\") { node.fillColor = \"#3484bb\"; }\n if (node.Phase == \"parent\") { node.fillColor = \"#9ace7f\"; }\n if (node.Phase == \"1\") { node.fillColor = \"#9264aa\"; }\n if (node.Phase == \"2\") { node.fillColor = \"#9264aa\"; }\n if (node.Phase == \"3\") { node.fillColor = \"#9264aa\"; }\n}", "title": "" }, { "docid": "0dd1174492f24c49ed781ca50997abd5", "score": "0.5682284", "text": "function TIcuContainerNode() { }", "title": "" }, { "docid": "0dd1174492f24c49ed781ca50997abd5", "score": "0.5682284", "text": "function TIcuContainerNode() { }", "title": "" }, { "docid": "0dd1174492f24c49ed781ca50997abd5", "score": "0.5682284", "text": "function TIcuContainerNode() { }", "title": "" }, { "docid": "0dd1174492f24c49ed781ca50997abd5", "score": "0.5682284", "text": "function TIcuContainerNode() { }", "title": "" }, { "docid": "14885a80590d991bc1dae8638837a645", "score": "0.5671358", "text": "function Node() {\n var parameters = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};\n\n _classCallCheck(this, Node);\n\n var presets = {\n name: 'ABC',\n level: -1,\n tooltip: \"you hovered\",\n view: {\n x: 200,\n y: 200,\n size: 50,\n normX: 0,\n normY: 0\n },\n siblings: [],\n children: [],\n parents: [],\n paths: 0\n //presets go on this and parameters override presets\n };Object.assign(this, presets, parameters);\n }", "title": "" }, { "docid": "8e870f9778d20a843a5a50eb5ca5a786", "score": "0.56658584", "text": "function Node(n) {\n this.id = n.id;\n this.textId = this.id.replace(\".\", \"\")\n this.type = n.type;\n this.z = n.z;\n this._closeCallbacks = [];\n this._inputCallback = null;\n this._inputCallbacks = null;\n\n this.brokerUrl = configMQTT.brokerUrl;\n this.connectingMQTT = false;\n this.connectedMQTT = false;\n this.clientMQTT = null;\n\n this.inputTopics = n.inputTopics;\n this.outputTopics = n.outputTopics;\n this.subscriptionsMQTT = {};\n this.micropythonCode = \"\";\n this.hasInput = true;\n this.noWiresType = false;\n this.local = true;\n this.device = null;\n\n // Used to assign nodes to devices\n // predicates can't be violated, priorities may be violated \n // if there is no way to implement them\n this.predicates = [];\n this.priorities = [];\n this.generateCode = null\n\n if (n.name) {\n this.name = n.name;\n }\n if (n._alias) {\n this._alias = n._alias;\n }\n if (n._flow) {\n // Make this a non-enumerable property as it may cause\n // circular references. Any existing code that tries to JSON serialise\n // the object (such as dashboard) will not like circular refs\n // The value must still be writable in the case that a node does:\n // Object.assign(this,config)\n // as part of its constructor - config._flow will overwrite this._flow\n // which we can tolerate as they are the same object.\n Object.defineProperty(this, '_flow', { value: n._flow, enumerable: false, writable: true })\n this._asyncDelivery = n._flow.asyncMessageDelivery;\n }\n if (this._asyncDelivery === undefined) {\n this._asyncDelivery = true;\n }\n this.updateWires(n.wires);\n}", "title": "" }, { "docid": "e6d9186afb7c25a83335aebfa87df6c2", "score": "0.56568563", "text": "function templateNode () {\n return{\n id: '',\n label: '',\n level: '',\n title: '',\n image: '',\n shape: 'image'\n }\n}", "title": "" }, { "docid": "448051f02808f7bdaf2ac42d25c32092", "score": "0.56411964", "text": "function SizeNode() {\n}", "title": "" }, { "docid": "97eca78b301f3486aef20a9826a36c81", "score": "0.5639809", "text": "function RootNode()\n{\n this.shape = 2;\n this.color = \"#1E1E1E\"\n this.boxcolor = \"#999\";\n this.addOutput(\"\",\"path\");\n\tthis.properties = {};\n this.horizontal = true;\n\tthis.widgets_up = true;\n\tthis.behaviour = new Behaviour();\n}", "title": "" }, { "docid": "a0713675bb47067439fb991ada0454cf", "score": "0.5637209", "text": "function Node (config) {\n RED.nodes.createNode(this, config);\n var node = this;\n\n // Invoked when the node has received an input as part of a flow.\n this.on('input', function(msg, send, done) {\n processOnInput(msg, send, done, config, node);\n });\n }", "title": "" }, { "docid": "21a15491c87c09b6acc48a248d987155", "score": "0.56331533", "text": "constructor(){\n\t\tsuper(RedBlackTreeNode, insertNode, removeNode, getNode);\n\t}", "title": "" }, { "docid": "af7fd935f8f7be4352e0c58976bcecd3", "score": "0.56200093", "text": "constructor(node,edge){\n this._node = node\n this._edge = edge\n }", "title": "" }, { "docid": "16306b4eef38335ed49c90a38769fad7", "score": "0.56139845", "text": "function CustomNode (args) {\n this.args = args\n }", "title": "" }, { "docid": "4724d87cb37ed468c5373267b27badd2", "score": "0.5606732", "text": "static createNode(params) {\n let renderer = params.renderer;\n let paper = params.paper;\n let metadata = params.metadata;\n let position = params.position;\n let props = params.props;\n let graph = params.graph || (params.paper ? params.paper.model : undefined);\n let node;\n if (!position) {\n position = { x: 0, y: 0 };\n }\n if (renderer && _.isFunction(renderer.createNode)) {\n node = renderer.createNode(metadata, props);\n }\n else {\n node = new joint.shapes.flo.Node();\n if (metadata) {\n node.attr('.label/text', metadata.name);\n }\n }\n node.set('type', joint.shapes.flo.NODE_TYPE);\n if (position) {\n node.set('position', position);\n }\n if (props) {\n Array.from(props.keys()).forEach(key => node.attr(`props/${key}`, props.get(key)));\n }\n node.attr('metadata', metadata);\n if (graph) {\n graph.addCell(node);\n }\n if (renderer && _.isFunction(renderer.initializeNewNode)) {\n let descriptor = {\n paper: paper,\n graph: graph\n };\n renderer.initializeNewNode(node, descriptor);\n }\n return node;\n }", "title": "" }, { "docid": "3e947861e390afaadbb2eb5ece211aa3", "score": "0.5599322", "text": "constructor() {\n\t\tthis.head = new Node(null);\n\t}", "title": "" }, { "docid": "85be5f545fb6ffdc091efd1d0807e38d", "score": "0.5566764", "text": "get node() {\n return this._node;\n }", "title": "" }, { "docid": "710a9268329f76e6b889f01ae313bb9d", "score": "0.5565014", "text": "function initialize ()\r\n {\r\n // appearance of the drawable component of this node\r\n var appearance = new x3dom.nodeTypes.Appearance( ctx );\r\n // multiTexture to get heightmap and colormap to gpu\r\n var shader = new x3dom.nodeTypes.CommonSurfaceShader( ctx );\r\n var ssTexColor = new x3dom.nodeTypes.SurfaceShaderTexture( ctx );\r\n // texture that should represent the surface-data of this node\r\n var colorTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n var ssTexDisplace = new x3dom.nodeTypes.SurfaceShaderTexture( ctx );\r\n // texture that should represent the height-data of this node\r\n var heightTexture = new x3dom.nodeTypes.ImageTexture( ctx );\r\n\r\n // definition of the nameSpace of this shape\r\n shape._nameSpace = bvhRefiner._nameSpace;\r\n\r\n // calculate the average position of the node\r\n position = nodeTransformation.e3();\r\n\r\n shader._vf.displacementFactor = bvhRefiner._vf.maxElevation;\r\n\r\n // create texture-data of this node with url's of the texture data\r\n colorTexture._nameSpace = bvhRefiner._nameSpace;\r\n colorTexture._vf.url[ 0 ] = imageAddressColor;\r\n colorTexture._vf.repeatT = false;\r\n colorTexture._vf.repeatS = false;\r\n ssTexColor.addChild( colorTexture, \"texture\" );\r\n colorTexture.nodeChanged();\r\n shader.addChild( ssTexColor, \"diffuseTexture\" );\r\n ssTexColor.nodeChanged();\r\n\r\n // create height-data\r\n heightTexture._nameSpace = bvhRefiner._nameSpace;\r\n heightTexture._vf.url[ 0 ] = imageAddressHeight;\r\n heightTexture._vf.repeatT = false;\r\n heightTexture._vf.repeatS = false;\r\n ssTexDisplace.addChild( heightTexture, \"texture\" );\r\n heightTexture.nodeChanged();\r\n shader.addChild( ssTexDisplace, \"displacementTexture\" );\r\n heightTexture.nodeChanged();\r\n\r\n appearance.addChild( shader, \"shaders\" );\r\n shader.nodeChanged();\r\n\r\n // create shape with geometry and appearance data\r\n shape.addChild( appearance );\r\n appearance.nodeChanged();\r\n shape.addChild( geometry );\r\n geometry.nodeChanged();\r\n\r\n // add shape to bvhRefiner object\r\n bvhRefiner.addChild( shape );\r\n shape.nodeChanged();\r\n\r\n // definition the static properties of cullObject\r\n cullObject.boundedNode = shape;\r\n cullObject.volume = shape.getVolume();\r\n // setting max and min in z-direction to get the complete volume\r\n cullObject.volume.max.z = Math.round( bvhRefiner._vf.maxElevation / 2 );\r\n cullObject.volume.min.z = -cullObject.volume.max.z;\r\n }", "title": "" }, { "docid": "a32d3996b57cac06a11fccd1bdb13680", "score": "0.55594885", "text": "_functionNode() {\n return this.node;\n }", "title": "" }, { "docid": "9e07a1a6db1b9254a5baa6e0b1d87ca3", "score": "0.55557483", "text": "get termType() {\n return 'NamedNode';\n }", "title": "" }, { "docid": "9e07a1a6db1b9254a5baa6e0b1d87ca3", "score": "0.55557483", "text": "get termType() {\n return 'NamedNode';\n }", "title": "" }, { "docid": "f4f9e7b783195ee032e156325c5ffa6f", "score": "0.5536416", "text": "function create(){\n nodeElement.x = settings.x;\n nodeElement.y = settings.y;\n nodeElement.size = settings.size;\n nodeElement.color = settings.color;\n }", "title": "" }, { "docid": "b2e7da9135d0d2464942674d61af64b2", "score": "0.55351955", "text": "node () {\n\n var node = {\n child: null,\n sibling: null,\n }\n\n return node;\n\n }", "title": "" }, { "docid": "722c7faf0ead105f9c2044974cfe9e37", "score": "0.5526162", "text": "function Node(data) {\n\tthis.data = data;\n}", "title": "" }, { "docid": "bc7079efc6578f7b0c28ac1e688a09cd", "score": "0.5522483", "text": "function Node(data) {\n \n this.children = {};\n this.prefix = 0;\n this.data = data;\n this.isWord = false\n \n}", "title": "" }, { "docid": "9b5da427d15ffb56f6fcf402b9a0c2b2", "score": "0.5517203", "text": "function NODE(deb, fin, content, opID, l)\n{\n\t//data//\n\tthis.begInText = deb;\n\tthis.endInText = fin;\n\tthis.content = content;\n\tthis.operationID = opID;\n\tthis.level = l;\n\tthis.leftSonIndex = IS_NONE;\n\tthis.rightSonIndex = IS_NONE;\n\tthis.currentValue = 0.0;\n\tthis.hasReceivedValue = false;\n\tthis.LVReferencedIndex = IS_NONE;\n\tthis.FSSReferencedIndex = IS_NONE;\n\tthis.LVReferencedName = \"\";\n\tthis.FSSReferencedName = \"\";\n\t//service methods//\n\tthis.NODE_setLeftSonIndex = NODE_setLeftSonIndex;\n\tthis.NODE_setRightSonIndex = NODE_setRightSonIndex;\n\tthis.NODE_getContent = NODE_getContent;\n\tthis.NODE_getLevel = NODE_getLevel;\n\tthis.NODE_getLeftSonIndex = NODE_getLeftSonIndex;\n\tthis.NODE_getRightSonIndex = NODE_getRightSonIndex;\n\tthis.NODE_getCurrentValue = NODE_getCurrentValue;\n\tthis.NODE_setCurrentValue = NODE_setCurrentValue;\n\tthis.NODE_setLVReferencedIndex = NODE_setLVReferencedIndex;\n\tthis.NODE_getLVReferencedIndex = NODE_getLVReferencedIndex;\n\tthis.NODE_setFSSReferencedIndex = NODE_setFSSReferencedIndex;\n\tthis.NODE_getFSSReferencedIndex = NODE_getFSSReferencedIndex;\n\tthis.NODE_setLVReferencedName = NODE_setLVReferencedName;\n\tthis.NODE_getLVReferencedName = NODE_getLVReferencedName;\n\tthis.NODE_setFSSReferencedName = NODE_setFSSReferencedName;\n\tthis.NODE_getFSSReferencedName = NODE_getFSSReferencedName;\n\tthis.NODE_getHasReceivedValue = NODE_getHasReceivedValue;\n\tthis.NODE_getOperationID = NODE_getOperationID;\n\tthis.NODE_setOperationID = NODE_setOperationID;\n\t//other methods//\n\tthis.NODE_isALeaf = NODE_isALeaf;\n\tthis.NODE_setLeafValue = NODE_setLeafValue;\n\tthis.NODE_resetHasReceivedValue = NODE_resetHasReceivedValue;\n\tthis.NODE_displayNodeElements = NODE_displayNodeElements;\n}", "title": "" }, { "docid": "a767124e22d487fcc9f75578d20f6de5", "score": "0.5516206", "text": "function FBXTree() { }", "title": "" }, { "docid": "875316f0ccdc7b0159e509c6fda60386", "score": "0.55161375", "text": "newNode() {\n return {\n isLeaf: false,\n children: {},\n };\n }", "title": "" }, { "docid": "3cf440cf9a9914431dfc75f32746430f", "score": "0.55076915", "text": "function AbstractRuleTreeNode() {}", "title": "" }, { "docid": "b2d48a74ff5c7d13cebbb0177584b68c", "score": "0.5506102", "text": "function FBXTree() {\n}", "title": "" }, { "docid": "bbc828241157b961a4be554b2d319d75", "score": "0.5505773", "text": "function FBXTree() {}", "title": "" }, { "docid": "bbc828241157b961a4be554b2d319d75", "score": "0.5505773", "text": "function FBXTree() {}", "title": "" }, { "docid": "bbc828241157b961a4be554b2d319d75", "score": "0.5505773", "text": "function FBXTree() {}", "title": "" }, { "docid": "bbc828241157b961a4be554b2d319d75", "score": "0.5505773", "text": "function FBXTree() {}", "title": "" }, { "docid": "bbc828241157b961a4be554b2d319d75", "score": "0.5505773", "text": "function FBXTree() {}", "title": "" }, { "docid": "3f31e994449c5656381d6269ec208dc5", "score": "0.5497887", "text": "function NodeScript()\n {\n this.size = [60,20];\n this.addProperty( \"onExecute\", \"\" );\n this.addInput(\"in\", \"\");\n this.addInput(\"in2\", \"\");\n this.addOutput(\"out\", \"\");\n this.addOutput(\"out2\", \"\");\n\n this._func = null;\n }", "title": "" }, { "docid": "b9ba4adad930daffd320eb0192c32fce", "score": "0.5485562", "text": "function definition(node) {\n\t var content = uri(node.url);\n\t\n\t if (node.title) {\n\t content += ' ' + title(node.title);\n\t }\n\t\n\t return '[' + node.identifier + ']: ' + content;\n\t}", "title": "" }, { "docid": "3f7ce67f22e7a3e778d95ab006e21900", "score": "0.5484139", "text": "addNodeRel(){\n\n //Origin (LD Stairwell)\n this.nodes[0].setNeighbor(this.nodes[3]);\n //West elevator\n this.nodes[1].setNeighbor(this.nodes[3]);\n //East elevator\n this.nodes[2].setNeighbor(this.nodes[3]);\n //Stairway intersection (I0)\n this.nodes[3].setNeighbor(this.nodes[0], this.nodes[1], this.nodes[2], this.nodes[4], this.nodes[17]);\n //LD intersection (I1)\n this.nodes[4].setNeighbor(this.nodes[3], this.nodes[14]);\n //South hall intersection\n this.nodes[5].setNeighbor(this.nodes[6], this.nodes[7], this.nodes[14]);\n //Southwest corner\n this.nodes[6].setNeighbor(this.nodes[5], this.nodes[10]);\n //Southeast corner\n this.nodes[7].setNeighbor(this.nodes[5], this.nodes[13]);\n //Northwest corner\n this.nodes[8].setNeighbor(this.nodes[10], this.nodes[11], this.nodes[15]);\n //Northeast corner\n this.nodes[9].setNeighbor(this.nodes[12], this.nodes[13], this.nodes[16]);\n //Bathroom intersection\n this.nodes[10].setNeighbor(this.nodes[6], this.nodes[8], this.nodes[18], this.nodes[19]);\n //SL247 intersection\n this.nodes[11].setNeighbor(this.nodes[8], this.nodes[12], this.nodes[20]);\n //SL251 intersection\n this.nodes[12].setNeighbor(this.nodes[9], this.nodes[11], this.nodes[21]);\n //SL280 intersection\n this.nodes[13].setNeighbor(this.nodes[7], this.nodes[9], this.nodes[22]);\n //LD exit\n this.nodes[14].setNeighbor(this.nodes[4], this.nodes[5]);\n //West exit\n this.nodes[15].setNeighbor(this.nodes[8]);\n //East exit\n this.nodes[16].setNeighbor(this.nodes[9]);\n //Student lounge\n this.nodes[17].setNeighbor(this.nodes[3]);\n //Women's restroom\n this.nodes[18].setNeighbor(this.nodes[10]);\n //Men's restroom\n this.nodes[19].setNeighbor(this.nodes[10]);\n //SL247\n this.nodes[20].setNeighbor(this.nodes[11]);\n //SL251\n this.nodes[21].setNeighbor(this.nodes[12]);\n //SL280\n this.nodes[22].setNeighbor(this.nodes[13]);\n }", "title": "" }, { "docid": "1871cd2b83fa6a7842b9a36aaf39204f", "score": "0.54824305", "text": "function Node() {\n this.type = null;\n this.start = tokStart;\n this.end = null;\n }", "title": "" }, { "docid": "1871cd2b83fa6a7842b9a36aaf39204f", "score": "0.54824305", "text": "function Node() {\n this.type = null;\n this.start = tokStart;\n this.end = null;\n }", "title": "" }, { "docid": "a570bc2f1264f5a6341ac9f640da6933", "score": "0.54784876", "text": "function Node(id, x, y, type) {\n this.id = id;\n this.type = NodeType[type] ? type : 0; // check that the type is defined in NodeType\n this.xPosition = x;\n this.yPosition = y;\n this.edges = [];\n}", "title": "" }, { "docid": "77dec0efb9eab1191f93eefd26b73fc5", "score": "0.5476235", "text": "constructor(caption = '', type = null) {\r\n\r\n // super(caption, new mxGeometry(0,0, 140, 26));\r\n super();\r\n this._type = type;\r\n\r\n let doc = mxUtils.createXmlDocument();\r\n let nodeValue = doc.createElement('MyNode')\r\n nodeValue.setAttribute('label', caption);\r\n nodeValue.setAttribute('attribute1', 'value1');\r\n this.setValue(nodeValue);\r\n }", "title": "" }, { "docid": "c729495d710a39d40b2de5c4c4c1c9fe", "score": "0.547586", "text": "function AttainObjNode(theType,theName,theData) {\n this.type = (theType)?theType:'';\n this.name = (theName)?theName:'';\n this.data = (theData)?theData:'';\n this.b = new Array();\n}", "title": "" }, { "docid": "959ee59f386ef942848dba074da8963f", "score": "0.5474523", "text": "function Node(tagName, parent) {\n\t\t\tthis.type = Dom.NODE;\n\t\t\tthis.tagName = tagName;\n\t\t\tthis.parent = parent;\n\t\t\tthis.attr = {};\t\n\t\t}", "title": "" }, { "docid": "2b6698d451fe215b1e2b6eac02dd4255", "score": "0.5473517", "text": "function Ctr700_AI_Node (NodeConfig_p)\n {\n\n //-------------------------------------------------------------------\n // Node main function\n //-------------------------------------------------------------------\n\n let ThisNode = this;\n\n // create new node instance\n RED.nodes.createNode (this, NodeConfig_p);\n\n // register handler for event type 'input'\n ThisNode.on ('input', Ctr700_AI_NodeHandler_OnInput);\n\n // register handler for event type 'close'\n ThisNode.on ('close', Ctr700_AI_NodeHandler_OnClose);\n\n // register one-time handler for sending the initial value\n ThisNode.m_injectImmediate = setImmediate(function()\n {\n Ctr700_AI_NodeHandler_OnNodesStarted();\n });\n\n // run handler for event type 'open'\n Ctr700_AI_NodeHandler_OnOpen (NodeConfig_p);\n\n return;\n\n\n\n //-------------------------------------------------------------------\n // Node event handler [NODE / OPEN]\n //-------------------------------------------------------------------\n\n function Ctr700_AI_NodeHandler_OnOpen (NodeConfig_p)\n {\n\n var strName;\n var strChannel;\n var strMode;\n var strSampleRate;\n var strSampleUnit;\n var strDelta;\n var fUnit1000;\n var strUpperValType;\n var strUpperValData;\n var strLowerValType;\n var strLowerValData;\n var strDecPlaces;\n var fAltTopic;\n var strAltTopic;\n\n ThisNode.m_NodeConfig = NodeConfig_p;\n TraceMsg ('{Ctr700_AI_Node} creating...');\n\n // create and initialize members\n ThisNode.m_iChannelNumber = -1;\n ThisNode.m_strMode = \"\";\n ThisNode.m_iSampleRate = -1;\n ThisNode.m_iDelta = -1;\n ThisNode.m_fUnit1000 = false;\n ThisNode.m_strUpperValType = \"\";\n ThisNode.m_flUpperValData = 0.0;\n ThisNode.m_strLowerValType = \"\";\n ThisNode.m_flLowerValData = 0.0;\n ThisNode.m_iDecPlaces = -1;\n ThisNode.m_flDigitValue = 0.0;\n ThisNode.m_strTopic = \"\";\n ThisNode.m_strName = \"\";\n ThisNode.m_fNodeCfgValid = true;\n ThisNode.m_iLastAdcValue = -32768;\n ThisNode.m_iDeltaProcVal = -1;\n ThisNode.m_objSampleTimerID = -1;\n ThisNode.m_iLastAdcDataState = ADC_STATE_UNDEF;\n ThisNode.m_iNewDataStatusPeriod = DEF_NEW_DATA_STATUS_PERIOD;\n ThisNode.m_ObjStatusTimer = null;\n ThisNode.m_iStatusTimerInst = 0;\n\n // create I/O driver instance\n TraceMsg ('{Ctr700_AI_Node} new ctr700drv.Ctr700Drv');\n ThisNode.m_ObjCtr700Drv = new ctr700drv.Ctr700Drv;\n\n // initialize I/O driver instance\n TraceMsg ('{Ctr700_AI_Node} ObjCtr700Drv.init()');\n ThisNode.m_ObjCtr700Drv.init();\n\n // get node configuration\n strChannel = ThisNode.m_NodeConfig.channel;\n strMode = ThisNode.m_NodeConfig.mode;\n strSampleRate = ThisNode.m_NodeConfig.samplerate;\n strSampleUnit = ThisNode.m_NodeConfig.sampleunit;\n strDelta = ThisNode.m_NodeConfig.delta;\n fUnit1000 = ThisNode.m_NodeConfig.optunit1000;\n strUpperValType = ThisNode.m_NodeConfig.uppervaltype;\n strUpperValData = ThisNode.m_NodeConfig.uppervaldata;\n strLowerValType = ThisNode.m_NodeConfig.lowervaltype;\n strLowerValData = ThisNode.m_NodeConfig.lowervaldata;\n strDecPlaces = ThisNode.m_NodeConfig.decplaces;\n fAltTopic = ThisNode.m_NodeConfig.optalttopic;\n strAltTopic = ThisNode.m_NodeConfig.alttopic;\n strName = ThisNode.m_NodeConfig.name;\n\n TraceMsg ('{Ctr700_AI_Node} strChannel: ' + strChannel);\n TraceMsg ('{Ctr700_AI_Node} strMode: ' + strMode);\n TraceMsg ('{Ctr700_AI_Node} strSampleRate ' + strSampleRate);\n TraceMsg ('{Ctr700_AI_Node} strSampleUnit: ' + strSampleUnit);\n TraceMsg ('{Ctr700_AI_Node} strDelta: ' + strDelta);\n TraceMsg ('{Ctr700_AI_Node} fUnit1000: ' + fUnit1000);\n TraceMsg ('{Ctr700_AI_Node} strUpperValType ' + strUpperValType);\n TraceMsg ('{Ctr700_AI_Node} strUpperValData: ' + strUpperValData);\n TraceMsg ('{Ctr700_AI_Node} strLowerValType ' + strLowerValType);\n TraceMsg ('{Ctr700_AI_Node} strLowerValData: ' + strLowerValData);\n TraceMsg ('{Ctr700_AI_Node} strDecPlaces: ' + strDecPlaces);\n TraceMsg ('{Ctr700_AI_Node} fAltTopic: ' + fAltTopic);\n TraceMsg ('{Ctr700_AI_Node} strAltTopic: ' + strAltTopic);\n TraceMsg ('{Ctr700_AI_Node} strName: ' + strName);\n\n // get input channel number\n ThisNode.m_iChannelNumber = Ctr700_AI_GetInputChannelNumber (strChannel);\n TraceMsg ('{Ctr700_AI_Node} m_iChannelNumber: ' + ThisNode.m_iChannelNumber);\n\n // get analog channel mode\n ThisNode.m_strMode = strMode;\n\n // get analog channel sample rate\n ThisNode.m_iSampleRate = Ctr700_AI_GetInputSampleRate (strSampleRate, strSampleUnit);\n TraceMsg ('{Ctr700_AI_Node} m_iSampleRate: ' + ThisNode.m_iSampleRate + '[ms]');\n if (ThisNode.m_iSampleRate <= 0)\n {\n TraceMsg ('{Ctr700_AI_Node} ERROR: NodeConfig is invalid (m_iSampleRate <= 0)');\n ThisNode.m_fNodeCfgValid = false;\n }\n\n // get payload specification\n ThisNode.m_iDelta = parseInt(strDelta, 10);\n ThisNode.m_fUnit1000 = fUnit1000;\n ThisNode.m_strUpperValType = strUpperValType;\n ThisNode.m_flUpperValData = parseFloat(strUpperValData);\n ThisNode.m_strLowerValType = strLowerValType;\n ThisNode.m_flLowerValData = parseFloat(strLowerValData);\n ThisNode.m_iDecPlaces = Ctr700_AI_GetNumOfDecPlaces(strDecPlaces);\n\n TraceMsg ('{Ctr700_AI_Node} strDelta -> m_iDelta: ' + ThisNode.m_iDelta);\n TraceMsg ('{Ctr700_AI_Node} strUpperValData -> m_flUpperValData: ' + ThisNode.m_flUpperValData);\n TraceMsg ('{Ctr700_AI_Node} strLowerValData -> m_flLowerValData: ' + ThisNode.m_flLowerValData);\n TraceMsg ('{Ctr700_AI_Node} strDecPlaces -> m_iDecPlaces: ' + ThisNode.m_iDecPlaces);\n\n if ( isNaN(ThisNode.m_iDelta) || isNaN(ThisNode.m_flUpperValData) || isNaN(ThisNode.m_flLowerValData) )\n {\n TraceMsg ('{Ctr700_AI_Node} ERROR: NodeConfig is invalid (m_fNodeCfgValid = false)');\n ThisNode.m_fNodeCfgValid = false;\n }\n\n // convert user configured 'delta' value into ADC data format (12bit ADC -> SHL(3) -> 15bit ADC)\n ThisNode.m_iDeltaProcVal = ThisNode.m_iDelta * 8;\n TraceMsg ('{Ctr700_AI_Node} SHL(m_iDelta,3) -> m_iDeltaProcVal ' + ThisNode.m_iDeltaProcVal);\n\n if ( ThisNode.m_fNodeCfgValid )\n {\n ThisNode.m_flDigitValue = Ctr700_AI_GetDigitValue (ThisNode.m_flUpperValData, ThisNode.m_flLowerValData);\n TraceMsg ('{Ctr700_AI_Node} U/L ValData -> m_flDigitValue: ' + ThisNode.m_flDigitValue);\n }\n\n // get topic for publishing input channel state messages\n ThisNode.m_strTopic = Ctr700_AI_BuildTopicString (ThisNode.m_iChannelNumber, fAltTopic, strAltTopic);\n TraceMsg ('{Ctr700_AI_Node} m_strTopic: ' + ThisNode.m_strTopic);\n\n // get node name\n ThisNode.m_strName = strName;\n\n // set ADC input mode (voltage or current)\n TraceMsg ('{Ctr700_AI_Node} Set ADC input mode (Channel: ' + ThisNode.m_iChannelNumber + ', Mode: ' + strMode);\n Ctr700_AI_SetAdcInputMode (ThisNode.m_iChannelNumber, strMode);\n\n // check for successful configuration, show configuration error otherwise\n if ( !ThisNode.m_fNodeCfgValid )\n {\n Ctr700_AI_ShowAdcDataState (ADC_STATE_ERROR);\n }\n\n // publishing initial input channel state is done in callback function 'Ctr700_AI_NodeHandler_OnNodesStarted()'\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Node event handler [NODE / CLOSE]\n //-------------------------------------------------------------------\n\n function Ctr700_AI_NodeHandler_OnClose ()\n {\n\n TraceMsg ('{Ctr700_AI_Node} closing...');\n\n // clear immediate timeout\n if (ThisNode.m_injectImmediate)\n {\n clearImmediate(ThisNode.m_injectImmediate);\n }\n\n // clear interval timer for cyclic data processing\n if (ThisNode.m_objSampleTimerID != -1)\n {\n TraceMsg ('{Ctr700_AI_Node} clearInterval (' + ThisNode.m_objSampleTimerID + ')');\n clearInterval (ThisNode.m_objSampleTimerID);\n ThisNode.m_objSampleTimerID = -1;\n }\n\n // shutdown driver instance\n TraceMsg ('{Ctr700_AI_Node} ObjCtr700Drv.shutDown()');\n ThisNode.m_ObjCtr700Drv.shutDown();\n\n // cleares the status entry from the node\n Ctr700_AI_ShowAdcDataState (ADC_STATE_UNDEF);\n\n return;\n\n };\n\n\n\n //-------------------------------------------------------------------\n // Node event handler [NODE / EVENT_INPUT]\n //-------------------------------------------------------------------\n\n function Ctr700_AI_NodeHandler_OnInput (Msg_p)\n {\n\n TraceMsg ('{Ctr700_AI_Node} procesing input message...');\n\n // This node is an input node and therefore it does not process any messages\n\n return;\n\n };\n\n\n\n //-------------------------------------------------------------------\n // Node event handler [EVENTS / NODE_STARTED]\n //-------------------------------------------------------------------\n\n function Ctr700_AI_NodeHandler_OnNodesStarted ()\n {\n\n var fChannelValue;\n\n TraceMsg ('{Ctr700_AI_Node} process initial input state...');\n\n // publish initial input channel state\n Ctr700_AI_PublishInputChannelState (ThisNode.m_iChannelNumber);\n\n // start interval timer for cyclic data processing\n TraceMsg ('{Ctr700_AI_Node} setInterval (' + ThisNode.m_iSampleRate + ')');\n ThisNode.m_objSampleTimerID = setInterval (Ctr700_AI_CbTimerProcAdcData, ThisNode.m_iSampleRate);\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Callback handler for cyclic data processing\n //-------------------------------------------------------------------\n\n function Ctr700_AI_CbTimerProcAdcData ()\n {\n\n TraceMsg ('{Ctr700_AI_Node} Ctr700_AI_CbTimerProcAdcData...');\n\n // publish current input channel state\n Ctr700_AI_PublishInputChannelState (ThisNode.m_iChannelNumber);\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Set ADC input mode (voltage or current)\n //-------------------------------------------------------------------\n\n function Ctr700_AI_SetAdcInputMode (iChannelNumber_p, strMode_p)\n {\n\n TraceMsg ('{Ctr700_AI_Node} Ctr700_AI_SetAdcInputMode: iChannelNumber_p=' + iChannelNumber_p + ', strMode_p=' + strMode_p);\n\n switch (strMode_p)\n {\n case \"MODE_VOLTAGE\":\n case \"MODE_VOLTAGE_USER\":\n {\n TraceMsg ('{Ctr700_AI_Node} ObjCtr700Drv.setupAnalogVoltage(' + iChannelNumber_p + ')');\n ThisNode.m_ObjCtr700Drv.setupAnalogVoltage(iChannelNumber_p);\n break;\n }\n\n case \"MODE_CURRENT\":\n case \"MODE_CURRENT_USER\":\n {\n TraceMsg ('{Ctr700_AI_Node} ObjCtr700Drv.setupAnalogCurrent(' + iChannelNumber_p + ')');\n ThisNode.m_ObjCtr700Drv.setupAnalogCurrent(iChannelNumber_p);\n break;\n }\n\n default:\n {\n TraceMsg ('{Ctr700_AI_Node} ERROR: ChannelMode is invalid (strMode_p=' + strMode_p + ')');\n break;\n }\n }\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Publish input channel state\n //-------------------------------------------------------------------\n\n function Ctr700_AI_PublishInputChannelState (iChannelNumber_p)\n {\n\n var iChannelNumber;\n var iAdcValue;\n var iAdcDelta;\n var vProcValue;\n var strProcValueFix;\n var vProcData;\n var Msg = { topic: \"\", payload: 0 };\n\n TraceMsg ('{Ctr700_AI_Node} Ctr700_AI_PublishInputChannelState: iChannelNumber_p=' + iChannelNumber_p);\n\n // read ADC value\n iAdcValue = ThisNode.m_ObjCtr700Drv.getAnalogInput(iChannelNumber_p);\n TraceMsg ('{Ctr700_AI_Node} ObjCtr700Drv.getAnalogInput(' + iChannelNumber_p + ') -> iAdcValue=' + iAdcValue);\n\n iAdcDelta = Math.abs(iAdcValue - ThisNode.m_iLastAdcValue);\n TraceMsg ('{Ctr700_AI_Node} iAdcValue=' + iAdcValue);\n TraceMsg ('{Ctr700_AI_Node} iLastAdcValue=' + ThisNode.m_iLastAdcValue + ' -> iAdcDelta=' + iAdcDelta);\n TraceMsg ('{Ctr700_AI_Node} ThisNode.m_iDelta=' + ThisNode.m_iDelta + ' -> ThisNode.m_iDeltaProcVal=' + ThisNode.m_iDeltaProcVal);\n if (iAdcDelta < ThisNode.m_iDeltaProcVal)\n {\n TraceMsg ('{Ctr700_AI_Node} Delta (' + ThisNode.m_iDeltaProcVal + ') not reached -> ignore value');\n return;\n }\n ThisNode.m_iLastAdcValue = iAdcValue;\n\n // calculate process value from field value\n vProcValue = (iAdcValue * ThisNode.m_flDigitValue) + ThisNode.m_flLowerValData;\n TraceMsg ('{Ctr700_AI_Node} vProcValue=' + vProcValue);\n\n // limit the number of decimal places the configured number\n if (ThisNode.m_iDecPlaces > -1)\n {\n try\n {\n strProcValueFix = vProcValue.toFixed(ThisNode.m_iDecPlaces); // num.toFixed() changes data type to string\n vProcValue = strProcValueFix;\n }\n catch (ErrInfo)\n {\n TraceMsg ('{Ctr700_AI_Node} ERROR: vProcValue.toFixed(' + ThisNode.m_iDecPlaces + ') failed!');\n TraceMsg ('{Ctr700_AI_Node} ERROR: ' + ErrInfo.message);\n }\n }\n\n // build payload data for message to send\n vProcData = Ctr700_AI_BuildPayloadData (vProcValue, ThisNode.m_strUpperValType);\n\n // show IPC state in editor\n Ctr700_AI_ShowAdcDataState (ADC_STATE_ACTIVE);\n\n // send message\n Msg.topic = ThisNode.m_strTopic;\n Msg.payload = vProcData;\n TraceMsg ('{Ctr700_AI_Node} SendMsg (topic=' + Msg.topic + ', payload=' + Msg.payload.toString() + ')');\n ThisNode.send (Msg);\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Get input channel number\n //-------------------------------------------------------------------\n\n function Ctr700_AI_GetInputChannelNumber (strChannelName_p)\n {\n\n var strChannelName;\n var strChannelNumber;\n var iChannelNumber;\n\n // check if channel name is valid\n if ((strChannelName_p == null) || (strChannelName_p.length == 0))\n {\n ThisNode.error ('{Ctr700_AI_Node} Invalid Output ChannelName (strChannelName_p is null or empty)');\n return (-1);\n }\n\n // normalize channel name\n strChannelName = strChannelName_p.trim();\n strChannelName = strChannelName.toUpperCase();\n\n // check for valid prefix\n if ( !strChannelName.startsWith('IN_AI') )\n {\n ThisNode.error ('{Ctr700_AI_Node} Invalid Output ChannelName: ' + strChannelName_p);\n return (-1);\n }\n\n // get channel number form channel name\n strChannelNumber = strChannelName.substr(5);\n iChannelNumber = parseInt(strChannelNumber);\n if (iChannelNumber === NaN)\n {\n ThisNode.error ('{Ctr700_AI_Node} Invalid Output Channelumber: ' + strChannelNumber);\n return (-1);\n }\n\n return (iChannelNumber);\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Get input sample rate\n //-------------------------------------------------------------------\n\n function Ctr700_AI_GetInputSampleRate (strSampleRate_p, strSampleUnit_p)\n {\n\n var iSampleRate;\n\n // check if sample rate is valid\n if ((strSampleRate_p == null) || (strSampleRate_p.length == 0))\n {\n ThisNode.error ('{Ctr700_AI_Node} Invalid Sample Rate (strSampleRate_p is null or empty)');\n return (-1);\n }\n\n // check if sample unit is valid\n if ((strSampleUnit_p == null) || (strSampleUnit_p.length == 0))\n {\n ThisNode.error ('{Ctr700_AI_Node} Invalid Sample Unit (strSampleUnit_p is null or empty)');\n return (-1);\n }\n\n iSampleRate = parseInt(strSampleRate_p, 10);\n if ( isNaN(iSampleRate) )\n {\n ThisNode.error ('{Ctr700_AI_Node} ERROR: iSampleRate is invalid (NaN)');\n return (-1);\n }\n\n if (strSampleUnit_p == \"SAMPLE_UNIT_S\")\n {\n // convert sample rate sec -> ms\n iSampleRate *= 1000;\n }\n\n return (iSampleRate);\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Get configured number of decimal places\n //-------------------------------------------------------------------\n\n function Ctr700_AI_GetNumOfDecPlaces (strDecPlaces_p)\n {\n\n var iDecPlaces;\n\n switch (strDecPlaces_p)\n {\n case \"DECPLCE_0\": iDecPlaces = 0; break;\n case \"DECPLCE_1\": iDecPlaces = 1; break;\n case \"DECPLCE_2\": iDecPlaces = 2; break;\n case \"DECPLCE_3\": iDecPlaces = 3; break;\n case \"DECPLCE_ALL\": iDecPlaces = -1; break;\n default: iDecPlaces = -1; break;\n }\n\n return (iDecPlaces);\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Calculate DigitValue from UpperValData/LowerValData\n //-------------------------------------------------------------------\n\n function Ctr700_AI_GetDigitValue (flUpperValData_p, flLowerValData_p)\n {\n\n var flDigitValue = 0.0;\n\n flDigitValue = (flUpperValData_p - flLowerValData_p) / 32768;\n\n return (flDigitValue);\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Build payload data for message to send\n //-------------------------------------------------------------------\n\n function Ctr700_AI_BuildPayloadData (vProcValue_p, strUpperValType_p)\n {\n\n var vProcData;\n\n switch (strUpperValType_p)\n {\n case \"num\":\n {\n if (typeof(vProcValue_p) == 'string')\n {\n try\n {\n vProcData = parseFloat(vProcValue_p.replace(',', '.')); // parseFloat() expects only decimal points, but no commas\n }\n catch (ErrInfo)\n {\n TraceMsg ('{Ctr700_AI_Node} ERROR: parseFloat(' + vProcValue_p.replace(',', '.') + ') failed!');\n TraceMsg ('{Ctr700_AI_Node} ERROR: ' + ErrInfo.message);\n }\n }\n else\n {\n vProcData = vProcValue_p;\n }\n break;\n }\n\n case \"str\":\n {\n vProcData = vProcValue_p.toString();\n break;\n }\n }\n\n return (vProcData);\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Build topic string for message to send\n //-------------------------------------------------------------------\n\n function Ctr700_AI_BuildTopicString (iChannelNumber_p, fAltTopic_p, strAltTopic_p)\n {\n\n var strTopic;\n\n // select between default and alternative topic\n if ( !fAltTopic_p )\n {\n strTopic = '/ai/' + iChannelNumber_p.toString();\n }\n else\n {\n strTopic = strAltTopic_p;\n }\n\n // check if topic is valid\n if (strTopic == null)\n {\n strTopic = \"\";\n }\n\n // normalize topic\n strTopic = strTopic.trim();\n strTopic = strTopic.toLowerCase();\n\n // prevent empty topic\n if (strTopic.length == 0)\n {\n strTopic = 'undefined';\n }\n\n return (strTopic);\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Callback handler for status timer\n //-------------------------------------------------------------------\n\n function Ctr700_AI_CbHandlerStatusTimer (iStatusTimerInst_p)\n {\n\n TraceMsg ('{Ctr700_AI_Node} Ctr700_AI_CbHandlerStatusTimer (' + iStatusTimerInst_p + ')');\n\n clearTimeout (ThisNode.m_ObjStatusTimer);\n ThisNode.m_ObjStatusTimer = null;\n Ctr700_AI_ShowAdcDataState (ADC_STATE_IDLE);\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Show IPC state in editor\n //-------------------------------------------------------------------\n\n function Ctr700_AI_ShowAdcDataState (iAdcDataState_p)\n {\n\n var fStateChanged;\n var strStatMsg;\n\n TraceMsg ('{Ctr700_AI_Node} Ctr700_AI_ShowAdcDataState: iAdcDataState_p=' + iAdcDataState_p);\n\n // check if state was changed since last call\n fStateChanged = (iAdcDataState_p == ThisNode.m_iLastAdcDataState) ? false : true;\n ThisNode.m_iLastAdcDataState = iAdcDataState_p;\n\n // remove status label from node?\n if (iAdcDataState_p == ADC_STATE_UNDEF)\n {\n // an empty status object cleares the status entry from the node\n ThisNode.status ({});\n return;\n }\n\n // show IPC state in editor\n switch (iAdcDataState_p)\n {\n // -------------------- Active (-> green) ---------------------\n case ADC_STATE_ACTIVE:\n {\n strStatMsg = 'Altered';\n ThisNode.status ({fill:'green', shape:'dot', text:strStatMsg});\n\n // start timer to clear 'active' status after configured interval\n if ( ThisNode.m_ObjStatusTimer )\n {\n // cancel already running timer from previous call\n TraceMsg ('{Ctr700_AI_Node} clearTimeout()');\n clearTimeout (ThisNode.m_ObjStatusTimer);\n }\n TraceMsg ('{Ctr700_AI_Node} setTimeout (' + ThisNode.m_iNewDataStatusPeriod + ', ' + ThisNode.m_iStatusTimerInst + ')');\n ThisNode.m_ObjStatusTimer = setTimeout (Ctr700_AI_CbHandlerStatusTimer, ThisNode.m_iNewDataStatusPeriod, ThisNode.m_iStatusTimerInst);\n ThisNode.m_iStatusTimerInst++;\n break;\n }\n\n // -------------------- Error (-> red) ------------------------\n case ADC_STATE_ERROR:\n {\n // keep timestamp of first error occurrence\n if ( !fStateChanged )\n {\n return;\n }\n\n strStatMsg = 'Error';\n ThisNode.status ({fill:'red', shape:'dot', text:strStatMsg});\n break;\n }\n\n // -------------------- Idle (-> grey) ------------------------\n case ADC_STATE_IDLE:\n default:\n {\n // keep timestamp of first idle occurrence\n if ( !fStateChanged )\n {\n return;\n }\n\n strStatMsg = 'Settled';\n ThisNode.status ({fill:'grey', shape:'dot', text:strStatMsg});\n break;\n }\n }\n\n return;\n\n }\n\n\n\n //-------------------------------------------------------------------\n // Private: Trace logging message\n //-------------------------------------------------------------------\n\n function TraceMsg (strTraceMsg_p, strNodeName_p)\n {\n\n var fEnable = false;\n var strNodeName;\n\n // check if any enable option is set\n if ( TRACE_ENABLE_ALL )\n {\n // enable all -> no additional checks necessary\n fEnable = true;\n }\n else if ( TRACE_ENABLE_NODE_NAME_DBG )\n {\n // check if node name is given as runtime parameter to this function\n strNodeName = \"\";\n if (strNodeName_p !== undefined)\n {\n // reuse node name given as parameter\n strNodeName = strNodeName_p;\n }\n else\n {\n // try to get node name from node configuration\n // -> evaluate first if 'ThisNode.m_NodeConfig.name' is valid\n if (ThisNode.m_NodeConfig !== undefined)\n {\n if (ThisNode.m_NodeConfig != null)\n {\n if ( ThisNode.m_NodeConfig.hasOwnProperty('name') )\n {\n if (ThisNode.m_NodeConfig.name != undefined)\n {\n if (ThisNode.m_NodeConfig.name != null)\n {\n strNodeName = ThisNode.m_NodeConfig.name;\n }\n }\n }\n }\n }\n }\n\n if (strNodeName.substr(0,4) == 'DBG_')\n {\n fEnable = true;\n }\n }\n\n if ( fEnable )\n {\n ThisNode.log (strTraceMsg_p);\n }\n\n return;\n\n }\n\n\n }", "title": "" }, { "docid": "4ca048962e7f4ad036308ae758da9c8c", "score": "0.5473404", "text": "function Node(id, data) {\n\t this.id = id;\n\t this.links = null;\n\t this.data = data;\n\t}", "title": "" } ]
e9b265487a32a3a4b5c91489b5c42f93
REQUETES UTILSATEUR : Onglet : Villes TAPEZ ICI LE CODE DE LA REQUETE DE MISE A JOUR
[ { "docid": "1413bcc5a80417bef212fe73649acce8", "score": "0.0", "text": "function User_Update_Villes_Liste_des_villes0(Compo_Maitre)\n{\n var Table=\"ville\";\n var CleMaitre = Compo_Maitre.getCleVal();\n var NomCleMaitre = DePrefixerChamp(Compo_Maitre.getCle());\n var vi_nom=GetValAt(126);\n if (!ValiderChampsObligatoire(Table,\"vi_nom\",TAB_GLOBAL_COMPO[126],vi_nom,false))\n \treturn -1;\n if (!ValiderChampsType(Table,\"vi_nom\",TAB_GLOBAL_COMPO[126],vi_nom))\n \treturn -1;\n var ct_numero=GetValAt(127);\n if (ct_numero==\"-1\")\n ct_numero=\"null\";\n if (!ValiderChampsObligatoire(Table,\"ct_numero\",TAB_GLOBAL_COMPO[127],ct_numero,true))\n \treturn -1;\n var Req=\"update \"+Table+\" set \";\n Req+=\"vi_nom=\"+(vi_nom==\"\" ? \"null\" : \"'\"+ValiderChaine(vi_nom)+\"'\" )+\",ct_numero=\"+ct_numero+\"\";\n Req+=\" where \"+NomCleMaitre+\"=\"+CleMaitre;\n\n if (pgsql_update(Req)==0)\n\talert(\"Echec lors de la mise à jour\");\nreturn CleMaitre;\n\n}", "title": "" } ]
[ { "docid": "904a6bf8729cda80a93ff62833cf72c5", "score": "0.6668528", "text": "getCodeValue() {\n let codes = {\n '0': '100010100',\n '1': '101001000',\n '2': '101000100',\n '3': '101000010',\n '4': '100101000',\n '5': '100100100',\n '6': '100100010',\n '7': '101010000',\n '8': '100010010',\n '9': '100001010',\n 'A': '110101000',\n 'B': '110100100',\n 'C': '110100010',\n 'D': '110010100',\n 'E': '110010010',\n 'F': '110001010',\n 'G': '101101000',\n 'H': '101100100',\n 'I': '101100010',\n 'J': '100110100',\n 'K': '100011010',\n 'L': '101011000',\n 'M': '101001100',\n 'N': '101000110',\n 'O': '100101100',\n 'P': '100010110',\n 'Q': '110110100',\n 'R': '110110010',\n 'S': '110101100',\n 'T': '110100110',\n 'U': '110010110',\n 'V': '110011010',\n 'W': '101101100',\n 'X': '101100110',\n 'Y': '100110110',\n 'Z': '100111010',\n '-': '100101110',\n '.': '111010100',\n ' ': '111010010',\n '$': '111001010',\n '/': '101101110',\n '+': '101110110',\n '%': '110101110',\n '($)': '100100110',\n '(/)': '111010110',\n '(+)': '100110010',\n '(%)': '111011010',\n };\n return codes;\n }", "title": "" }, { "docid": "8292b57c45af37cc3eaa634f2c4bba0a", "score": "0.6528308", "text": "function CodeMonotoneToNumber(cod)\r\n{\r\n let aReturn = 0;\r\n try\r\n {\r\n switch (cod)\r\n {\r\n case '00': aReturn = '0'; break;\r\n case '01': aReturn = '1'; break;\r\n case '02': aReturn = '2'; break;\r\n case '04': aReturn = '3'; break;\r\n case '07': aReturn = '4'; break;\r\n case '0D': aReturn = '5'; break;\r\n case '10': aReturn = '6'; break;\r\n case '11': aReturn = '7'; break;\r\n case '12': aReturn = '8'; break;\r\n case '14': aReturn = '9'; break;\r\n case '17': aReturn = '*'; break; //+\r\n case '1D': aReturn = '#'; break; //-\r\n case '20': aReturn = 'A'; break; //>>\r\n case '21': aReturn = 'B'; break; //<<\r\n case '22': aReturn = 'C'; break; //> \r\n case '24': aReturn = 'D'; break;\r\n default: aReturn = '0';\r\n }\r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n } \r\n return (aReturn);\r\n}", "title": "" }, { "docid": "44ba78dfaa784bd3cfab1053f268c5db", "score": "0.645145", "text": "function comprobarLexema(codigo) {\n if (codigo == 86 || codigo == 69 || codigo == 68 || codigo == 79 || codigo == 82 || codigo == 65) {\n return (\"verdadero\");\n } else if (codigo == 118 || codigo == 97 || codigo == 114 || codigo == 105 || codigo == 98 || codigo == 108 || codigo == 101) {\n return (\"variable\");\n\n } else if (codigo == 70 || codigo == 65 || codigo == 76 || codigo == 79 || codigo == 83) {\n return (\"falso\");\n }\n else if ((codigo >= 97 && codigo <= 122) || (codigo >= 65 && codigo <= 69) || (codigo >= 71 && codigo <= 90)) {\n return (\"letra\");\n } else if (codigo >= 48 && codigo <= 57) {\n return (\"digito\");\n } else if (codigo == 58 || codigo == 59 || codigo == 44 || codigo == 46) {//codigo 46 es el punto .\n return (\"Puntuacion\");\n\n } else if (codigo == 37 || codigo == 42 || codigo == 43 || codigo == 45 || codigo == 47 || codigo == 60 || codigo == 61 || codigo == 62) {\n return (\"Aritmeticos\");\n } else if (codigo == 40 || codigo == 41 || codigo == 91 || codigo == 93 || codigo == 123 || codigo == 125) {\n return (\"agrupacion\");\n } else if (codigo == 34 || codigo == 59) {\n return (\"Signo\");\n }\n else if (codigo == 65 || codigo == 70 || codigo == 76 || codigo == 79 || codigo == 83) {\n return (\"falso\");\n }\n\n}", "title": "" }, { "docid": "84e42e4df6a480aa195423fd44b3235d", "score": "0.6425519", "text": "function convertirJugada(jugadaJSCodigo){\nlet jugada = \"\";\n\n if(jugadaJSCodigo === 1 )\n jugada = \"PIEDRA\";\n else if(jugadaJSCodigo === 2)\n jugada = \"PAPEL\";\n else if (jugadaJSCodigo === 3)\n jugada = \"TIJERA\";\n\n return jugada;\n}", "title": "" }, { "docid": "da3a7e43fa97c1d2d941ecd654050b0c", "score": "0.642017", "text": "function gera_ean (){\n/* 37 */ \tvar data \t= new Date().getTime();\n/* 38 */ \tvar cod \t= (jQuery.randomBetween(1, 99999) * data)+\"\";\n/* 39 */ \tcod = \"27\"+cod.substr(-10);\n/* 40 */ \tcod += calc_ean_dv(cod);\n/* 41 */ \treturn cod;\n/* 42 */ }", "title": "" }, { "docid": "226c57d8997cfef8e3f2eddd1c123226", "score": "0.6354431", "text": "function cargarCodigo(data) {\n var code = \"\";\n\n if (data < 10) {\n code = \"000\" + data;\n } else if (data >= 10 || data < 100) {\n code = \"00\" + data;\n } else if (data >= 100 || data < 1000) {\n code = \"0\" + data;\n } else {\n code = data;\n }\n\n return code;\n}", "title": "" }, { "docid": "82decf3703a378b7185a15aab0b1d364", "score": "0.63134277", "text": "getResultatCodificat(){ // SI EL MÈTODE NO PASSA ALGUN VALOR, SE LI POSSA this. MÉS EL ATRIBUT CORRESPONENT.\n this.eliminarEspaisBlanc();\n this.senseAccent();\n for (var i = 0; i < this._entrada.length; i++){\n\n // IGUALEM LA LLARGADA DE LA CLAU A LA DE L'ENTRADA\n var y = 0;\n var max_lenght = this._entrada.length;\n while (this._entrada.length != this._clau.length){\n\n this._clau = this._clau + this._clau[y];\n\n if(y >= max_lenght){\n\n y = 0;\n }\n else{\n\n y++;\n }\n }\n\n // BUSQUEM ON ESTAN SITUATS TANT LA LLETRA DE L'ENTRADA COM DE LA CLAU\n var posicio_lletra_entrada = this._alfabet.indexOf(this._entrada[i]);\n var posicio_lletra_clau = this._alfabet.indexOf(this._clau[i]);\n\n // SUMEM LES DUES POSICIONS\n var suma_posicions = posicio_lletra_entrada + posicio_lletra_clau;\n\n // ANEM RESTANT MENTRE QUE EL MOD SIGUI MÉS GRAN QUE EL LENGTH DEL ABECEDARI\n while (suma_posicions >= this._alfabet.length){\n\n suma_posicions = suma_posicions - this._alfabet.length;\n }\n \n // ARA BUSQUEM LA LLETRA AMB LA QUAL SUBSTITUIREM L'ENTRADA\n this._resultat = this._resultat + this._alfabet[suma_posicions];\n }\n\n // RETORNEM EL RESULTAT\n return (document.form.sortida.value = this._resultat);\n }", "title": "" }, { "docid": "366f18e620046c54c52500749f2d0a74", "score": "0.62785137", "text": "function numberic_to_string(so)\n{\n var i;\n var j;\n var kq = \"\";\n var l;\n var dk;\n var tmp = \"\";\n var check = false;\n var a = new Array(32);\n\n //kiem tra kieu so\n //Loai het so 0 o dau\n while (so.length > 0 && so.charAt(0) == \"0\"){\n so = so.substring(1,so.length);\n }\n //alert(so);\n l = so.length;\n if (l > 28){\n return \"Số không hợp lệ\";\n }\n\n //Load cac chu so cua so can doc\n //vao mang a\n for (var i=1;i<=l;i++){\n a[i] = parseInt(so.charAt(i-1));\n }\n //Bat dau doc tu trai sang phai\n for (var i=1;i<=l;i++){\n\n if((l - i) % 3 == 2 && a[i] == 0 && (l - i >= 2)) {\n if (a[i + 1] != 0 || a[i + 2] != 0) {\n kq = kq + \"không \";\n }\n }\n\n if (a[i] == 2){\n kq = kq + \"hai \";\n }\n if (a[i] == 3){\n kq = kq + \"ba \";\n }\n if (a[i] == 6){\n kq = kq + \"sáu \";\n }\n if (a[i] == 7){\n kq = kq + \"bảy \";\n }\n if (a[i] == 8){\n kq = kq + \"tám \";\n }\n if (a[i] == 9){\n kq = kq + \"chín \";\n }\n\n\n //Xu ly cach doc so 4\n if (a[i] == 4) {\n if (i > 1 && (l - i) % 3 == 0){\n if (a[i - 1] > 1){\n kq = kq + \"tư \";\n }else{\n kq = kq + \"bốn \";\n }\n }else{\n kq = kq + \"bốn \";\n }\n } //a(i)=4\n\n //Xu ly cach doc so 5\n if (a[i] == 5){\n if (i > 1 && (l - i)% 3 == 0){\n if (a[i - 1] != 0 ){\n kq = kq + \"lăm \";\n }else{\n kq = kq + \"năm \";\n }\n }else{\n kq = kq + \"năm \";\n }\n } //a(i)=5\n\n //Xu ly cach doc so 1\n if (a[i] == 1) {\n //doc la muoi neu no la hang chuc\n if ((l - i) % 3 == 1) {\n kq = kq + \"mười \";\t//doc la mot neu la hang don vi\t//va hang chuc >1\n }else{\n if ((l - i) % 3 == 0 && (i > 1)){\n if (a[i - 1] > 1){\n kq = kq + \"mốt \";\n }else{\n kq = kq + \"một \";\n }\n }else{\n kq = kq + \"một \";\n }\n }\n } //a(i)=1\n\n\n //Doc tiep la muoi neu\n //No la so hang chuc va\n //Khac 1 va 0\n if ((l - i) % 3 == 1 && a[i] != 0 && a[i] != 1){\n kq = kq + \"mươi \";\n }\n\n if ((l - i) % 3 == 1 && a[i] == 0 && a[i + 1] != 0){\n kq = kq + \"linh \";\n }\n\n if ((l - i) % 3 == 2 && (a[i + 1] != 0 || a[i + 2] != 0)){\n kq = kq + \"trăm \";\n }\n\n if ((i + 2) <= l) {\n if (a[i] != 0 && (l - i) % 3 == 2){\n if (a[i + 1] == 0 && a[i + 2] == 0){\n kq = kq + \"trăm \";\n }\n }\n }\n\n if ((l - i) == 3){\n kq = kq + \"nghìn \";\n }\n if ((l - i) == 6){\n kq = kq + \"triệu \";\n }\n if ((l - i) == 9){\n kq = kq + \"tỷ \";\n }\n\n if ((l - i) == 12){\n check = true;\n for (j=i+1;i<l;i++){\n if (a[i + 1] != 0){\n check = false;\n }\n }\n if (check == false) {\n kq = kq + \"nghìn \";\n }else{\n kq = kq + \"nghìn tỷ \";\n }\n }\n\n if ((l - i) == 15){\n kq = kq + \"triệu tỷ \";\n }\n if ((l - i) == 18){\n kq = kq + \"tỷ tỷ \";\n }\n if ((l - i) == 21){\n kq = kq + \"nghìn tỷ tỷ \";\n }\n if ((l - i) == 24){\n kq = kq + \"triệu tỷ tỷ \";\n }\n if ((l - i) == 27){\n kq = kq + \"tỷ tỷ tỷ \";\n }\n if ((l - i) == 30){\n kq = kq + \"nghìn tỷ tỷ \";\n }\n\n //Xu ly bo 3 so khong\n if (((l - i) % 3 == 2) && (a[i] == 0) && (a[i + 1] == 0) && (a[i + 2] == 0)){\n i = i + 2;\n }\n\n //Xu ly tat ca so khong con lai\n if ((l - i) % 3 == 0){\n dk = 1;\n for (j=i+1;j<=l;j++){\n if (a[j] != 0){\n dk = 0;\n }\n }\n }\n if (dk == 1){\n break;\n }\n\n }\n\n //Viet hoa chu cai dau tien\n if (kq == \"\") kq = \"không\"\n while (kq.charAt(kq.length) == \",\"){\n kq = kq.substring(0,kq.length-1);\n }\n kq = kq.charAt(0).toUpperCase() + kq.substring(1,kq.length);\n return kq + \" đồng\";\n}", "title": "" }, { "docid": "7323940d947d8083a1be7f7dd5bc5dc4", "score": "0.6268914", "text": "function CodeDTMFtoNumber(cod)\r\n{\r\n let aReturn = 0;\r\n try\r\n {\r\n switch (cod)\r\n {\r\n case '00': aReturn = '0'; break;\r\n case '01': aReturn = '1'; break;\r\n case '02': aReturn = '2'; break;\r\n case '03': aReturn = '3'; break;\r\n case '04': aReturn = '4'; break;\r\n case '05': aReturn = '5'; break;\r\n case '06': aReturn = '6'; break;\r\n case '07': aReturn = '7'; break;\r\n case '08': aReturn = '8'; break;\r\n case '09': aReturn = '9'; break;\r\n case '11': aReturn = '*'; break; //+\r\n case '12': aReturn = '#'; break; //-\r\n case '13': aReturn = 'A'; break; //>>\r\n case '14': aReturn = 'B'; break; //<<\r\n case '15': aReturn = 'C'; break; //> \r\n case '10': aReturn = 'D'; break;\r\n default: aReturn = '0';\r\n }\r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n } \r\n return (aReturn);\r\n}", "title": "" }, { "docid": "5425618ff4a05d812efa4ca9ceee021b", "score": "0.6244307", "text": "function GetBornosoftModifiedCharaceter(CUni)\r\n{\r\n\tvar CMod=CUni;\r\n\r\n\tif(LCUNI=='ক' && CUni=='হ') CMod = 'খ';\r\n\telse if(LCUNI=='গ' && CUni=='হ') CMod = 'ঘ';\r\n\telse if(LCUNI=='চ' && CUni=='হ') CMod = 'চ';\r\n\telse if(LCUNI=='জ' && CUni=='হ') CMod = 'ঝ';\r\n\telse if(LCUNI=='ট' && CUni=='হ') CMod = 'ঠ';\r\n\telse if(LCUNI=='ড' && CUni=='হ') CMod = 'ঢ';\r\n\telse if(LCUNI=='ত' && CUni=='হ') CMod = 'থ';\r\n\telse if(LCUNI=='দ' && CUni=='হ') CMod = 'ধ';\r\n\telse if(LCUNI=='প' && CUni=='হ') CMod = 'ফ';\r\n\telse if(LCUNI=='ব' && CUni=='হ') CMod = 'ভ';\r\n\telse if(LCUNI=='স' && CUni=='হ') CMod = 'শ';\r\n\telse if(LCUNI=='ড়' && CUni=='হ') CMod = 'ঢ়';\r\n\r\n\telse if(LCUNI=='ণ' && CUni=='গ') CMod = 'ঙ';\r\n\telse if(LCUNI=='ন' && CUni=='গ') CMod = 'ং';\r\n\t\r\n\telse if(LCUNI=='ণ' && CUni=='ঘ') CMod = 'ঞ';\r\n\r\n\telse if(LCUNI=='ণ' && CUni=='ণ') CMod = 'ঁ';\r\n\r\n\telse if(LCUNI=='ঃ' && CUni=='ঃ') CMod = 'ঃ';\r\n\t\r\n\telse if(LCUNI=='ট' && CUni=='ট') CMod = 'ৎ';\r\n\t\r\n\telse if(LCUNI=='া' && CUni=='ো') CMod = 'অ';\r\n\telse if(LCUNI=='ি' && CUni=='ি') CMod = 'ী';\r\n\telse if(LCUNI=='ই' && CUni=='ই') CMod = 'ঈ';\r\n\telse if(LCUNI=='ু' && CUni=='ু') CMod = 'ূ';\r\n\telse if(LCUNI=='উ' && CUni=='উ') CMod = 'ঊ';\r\n\telse if(LCUNI=='ও' && CUni=='ই') CMod = 'ঐ';\r\n\telse if(LCUNI=='ো' && CUni=='ি') CMod = 'ৈ';\r\n\telse if(LCUNI=='ও' && CUni=='উ') CMod = 'ঔ';\r\n\telse if(LCUNI=='ো' && CUni=='ু') CMod = 'ৌ';\r\n\telse if(LCUNI=='ৃ' && CUni=='র') CMod = 'ৃ';\r\n\telse if(LCUNI=='ঋ' && CUni=='ড়') CMod = 'ঋ';\r\n\r\n\treturn CMod;\r\n}", "title": "" }, { "docid": "d37cd23ffd6ea6dd7b346fba4a55bf3d", "score": "0.6214814", "text": "function years(num){\n let years0,\n str1=num.toString(), \nsL=str1.length;\nif (sL==1) {s1=\"0\"; s2=str1} else { s2=str1.charAt(sL-2); s2=str1.charAt(sL-1)} \nif (s2==\"1\" && s1!=\"1\") {years0=' год '} else if \n((s2==\"2\"||s2==\"3\"||s2==\"4\" )&&s1!=\"1\") {years0=' года '} else {years0=' лет '};\nreturn years0\n}", "title": "" }, { "docid": "8b17f79c574b9b69b2474bbc811846e7", "score": "0.6207946", "text": "function codifyText(text) {\n var codifiedText = text;\n\n\n//\t\tString expresionRegular = cadena.substring(expresionRegular.indexOf(6), cadena.indexOf(6)+8); //Cualquier numero\n//\t\texpresionRegular.replaceAll(expresionRegular, \"Numero codificado\");\n//\t\tSystem.out.println(cadena);\n//\nconsole.log(\"Entrar\");\n\t\t var inicio = codifiedText.indexOf(\"6\");\n\t\t var final1 = codifiedText.indexOf(\"6\")+9;\n\t\t //inicio+1 pues la función incluye el caracter de dicha posición, final no se le suma nada, pues dicha posición se excluye\n\t\t codifiedText.substring(inicio, final1);\n\n\t\t var tlf=codifiedText.substring(inicio, final1);\n\t\t codifiedText=codifiedText.replace(tlf, \"Numero codificado\");\n\nconsole.log(codifiedText);\n\n\n return codifiedText;\n}", "title": "" }, { "docid": "2b1eebff9fa8951140ecdbb1aa0e678b", "score": "0.62067217", "text": "function ispisCene(){\n \n let ispisCena=racunajCenu(findDestPrice(dest),brOsoba);\n document.querySelector(\"#cena\").innerHTML = `${ispisCena}&euro;`;\n }", "title": "" }, { "docid": "054f9345f608e8e287dcc452c0284d9b", "score": "0.62000394", "text": "getStringFromCode() {\n let str = '';\n const len = this.m_code.length;\n for(let i = 0; i < len; i++) {\n str = str.concat(String.fromCharCode(this.m_code[i]));\n }\n return str;\n }", "title": "" }, { "docid": "15b5e4a7ee044340964b9302e0170f2f", "score": "0.6181078", "text": "function auxLetras(promedio) {\n let simbolo;\n\n if (promedio > 0 && promedio <= 15)\n simbolo = 'M';\n else if (promedio >= 16 && promedio <= 31)\n simbolo = 'N';\n else if (promedio >= 32 && promedio <= 47)\n simbolo = 'H';\n else if (promedio >= 48 && promedio <= 63)\n simbolo = '#';\n else if (promedio >= 64 && promedio <= 79)\n simbolo = 'Q';\n else if (promedio >= 80 && promedio <= 95)\n simbolo = 'U';\n else if (promedio >= 96 && promedio <= 111)\n simbolo = 'A';\n else if (promedio >= 112 && promedio <= 127)\n simbolo = 'D';\n else if (promedio >= 128 && promedio <= 143)\n simbolo = '0';\n else if (promedio >= 144 && promedio <= 159)\n simbolo = 'Y';\n else if (promedio >= 160 && promedio <= 175)\n simbolo = '2';\n else if (promedio >= 176 && promedio <= 191)\n simbolo = '$';\n else if (promedio >= 192 && promedio <= 209)\n simbolo = '%';\n else if (promedio >= 210 && promedio <= 225)\n simbolo = '+';\n else if (promedio >= 226 && promedio <= 239)\n simbolo = '.';\n else if (promedio >= 240 && rgbPromedio <= 255)\n simbolo = ' ';\n return simbolo;\n\n}", "title": "" }, { "docid": "9c21e50927f30bc69aa9e6e97a95a841", "score": "0.61667293", "text": "getCodeValue() {\n let codes = {\n '0': '111121',\n '1': '211121',\n '2': '121121',\n '3': '221111',\n '4': '112121',\n '5': '212111',\n '6': '122111',\n '7': '111221',\n '8': '211211',\n '9': '211111',\n '-': '112111',\n '*': '112211'\n };\n return codes;\n }", "title": "" }, { "docid": "24725bcd270ec5c1f3c7977f4ca2409a", "score": "0.6149517", "text": "function terbilang(a) {\n var c = \" Satu Dua Tiga Empat Lima Enam Tujuh Delapan Sembilan Sepuluh Sebelas\".split(\" \");\n if (12 > a) var b = c[a];\n else 20 > a ? b = c[a - 10] + \" Belas\" : 100 > a ? (b = parseInt(String(a / 10).substr(0, 1)), b = c[b] + \" Puluh \" + c[a % 10]) : 200 > a ? b = \"Seratus \" + terbilang(a - 100) : 1E3 > a ? (b = parseInt(String(a / 100).substr(0, 1)), b = c[b] + \" Ratus \" + terbilang(a % 100)) : 2E3 > a ? b = \"Seribu \" + terbilang(a - 1E3) : 1E4 > a ? (b = parseInt(String(a / 1E3).substr(0, 1)), b = c[b] + \" Ribu \" + terbilang(a % 1E3)) : 1E5 > a ? (b = parseInt(String(a / 100).substr(0, 2)),\n a %= 1E3, b = terbilang(b) + \" Ribu \" + terbilang(a)) : 1E6 > a ? (b = parseInt(String(a / 1E3).substr(0, 3)), a %= 1E3, b = terbilang(b) + \" Ribu \" + terbilang(a)) : 1E8 > a ? (b = parseInt(String(a / 1E6).substr(0, 4)), a %= 1E6, b = terbilang(b) + \" Juta \" + terbilang(a)) : 1E9 > a ? (b = parseInt(String(a / 1E6).substr(0, 4)), a %= 1E6, b = terbilang(b) + \" Juta \" + terbilang(a)) : 1E10 > a ? (b = parseInt(String(a / 1E9).substr(0, 1)), a %= 1E9, b = terbilang(b) + \" Milyar \" + terbilang(a)) : 1E11 > a ? (b = parseInt(String(a / 1E9).substr(0, 2)), a %= 1E9, b = terbilang(b) + \" Milyar \" + terbilang(a)) :\n 1E12 > a ? (b = parseInt(String(a / 1E9).substr(0, 3)), a %= 1E9, b = terbilang(b) + \" Milyar \" + terbilang(a)) : 1E13 > a ? (b = parseInt(String(a / 1E10).substr(0, 1)), a %= 1E10, b = terbilang(b) + \" Triliun \" + terbilang(a)) : 1E14 > a ? (b = parseInt(String(a / 1E12).substr(0, 2)), a %= 1E12, b = terbilang(b) + \" Triliun \" + terbilang(a)) : 1E15 > a ? (b = parseInt(String(a / 1E12).substr(0, 3)), a %= 1E12, b = terbilang(b) + \" Triliun \" + terbilang(a)) : 1E16 > a && (b = parseInt(String(a / 1E15).substr(0, 1)), a %= 1E15, b = terbilang(b) + \" Kuadriliun \" + terbilang(a));\n a = b.split(\" \");\n c = [];\n for (b = 0; b < a.length; b++) \"\" != a[b] && c.push(a[b]);\n return c.join(\" \")\n}", "title": "" }, { "docid": "c1f1d6ae9113e9d2ab9ea1a33dacf483", "score": "0.6119307", "text": "formatCode(code) {\n return code\n .replace(/^([0-9]{3})([0-9]{3})$/, '$1 $2') // 6 digits\n .replace(/^([0-9]{2})([0-9]{3})([0-9]{2})$/, '$1 $2 $3') // 7 digits\n .replace(/^([0-9]{2})([0-9]{3})([0-9]{3})$/, '$1 $2 $3') // 8 digits\n }", "title": "" }, { "docid": "6b043767c872ddf1dd687c535cb07592", "score": "0.60856175", "text": "function munculkanAngkaDua() {\n return 2;\n}", "title": "" }, { "docid": "9df431d55d237bf4207a5d8851cf023c", "score": "0.60719293", "text": "jubilar() {\n let jubilacion = this.edad >= 45 ? true : false;\n\n return (\"\" + jubilacion);\n }", "title": "" }, { "docid": "314036de15d41577ca47a35d2ec16fc1", "score": "0.6061367", "text": "function XujWkuOtln(){return 23;/* CWMT2bFREp XRbNSOUSqeO LSTacgjbJL tMZPV3qEFk2Q cgxWmW1B55 wzow6g6DPGl hsxy42OfIc ILgjzPvROSk u87FmsCcJhi k9NIVH6yOpT 9bjCh322P0S tbxdwW8m8Z8 wTaTCOlzbqK HP7qQCCYwC R72XfMYb1mW PU0rqxFZ6Z WqQndjD8nnxB zwbwmuYvLK wIgGCyDKCo LeUJCwn46d3 UFvQuiNF6VM pobFDZq9zC sBNZyVXUaefL jOAS7mfvGA3 d2rnJvcj2a h4tQuABWbs elQbLftyKXb BtGyBgpbfk 1TKoc6H9Yy 6pRtdRJh40 VlwUiWWGyGDF HaUXtGFgwpn pbcrfOdovzW loZf0TBmIrXK Xc9oZm8wLtGI nuJ2m6tmzAWr cjNLvIXMW4 cJ5HvBhguZ2 OfjWMN8EBa BxXYjYiAZic ODRWgYN8xI 5nYv4yc0nGZ 8bAvcUCdECU DP7y3KPdjq z1l0aIkyr5 HrHnrA7eTw yeJ3X3qZlfY rJx98yB1TDQ 0Z0GCGoPGVV oOD40DjZYQx 6q5c5kt8G2 FxOaLYw4mno Qu3uYJy1bqr ZNf1vlM6z6 8QPJ55ExFW0o wrkv7idbGu FEkXyyDrxt4 Lkhph1hyiEM xHadhVsyTh tKEawmmelCjk lgOO8MepUjx 8USSgAfTFh P7tD2UadcWxN 8rLDlyxRIoxV CP2zCrgHImF IbLHJPTztBC XWV1gOueb9eB 3Khez9p4Qp iyqhfOEyyEYR ssvflUhouWCc k0VjjIoQyHgP Nydbsl3Aps BNpZ0bCQeCm gUp1VExh7Nu 7JlpIw774Fsc Zki5otrnfcV aXHoC8X0Mg Kz73sP8dGz SujiThOOwp1G B9YxFy8hsc b1cR6Wa32j S4gMUIk3tG gbMzX4wWZcj BLphUQW2DlDD wON29CiQ7JY qbOywUgyXhE HftE48gXO1x 8gDROW41Yfr RivsVQXV3DI0 DPGeX73Jsd NBx893iaA0A v8cMHq8ftr oSgnTqlwt2 Gb3i31KGmaA bGU4DufEAa Yc9XH6zRvdr dJ3ivq7EiTD R3fTg3AL0H3 ptlLp0qgJVaq TXizWKcUTX htYLP9fmPQ 16RVs6AAEO9h j7RDPlIUXoda NKK9bijWtAHU f2pcdNe4HdD sewtnCGJYa mqtvEnCQFHUl LK14wcJKMo ETgtShFKqc axFUYYWcFJB BOKYw1kgz6w ZKt1HLeoNrg abfRhAeeje Z1euUD9cKN zCgDzLg3RsrD EZIawZvkOx KPaYKRey71s 3LMkJjqfdH2Z LiDIQRFw5u DsAwd9eU2tWS JuvhdWCfcdF gS18kkyMo0S hRaoLHPMcDPC jSLDvK2QNJ9t gUb9YDDIgK2 7PLEjIA37lh 1Z6QUSB8WKa KxtesthkB2 pnRuMDREjyO1 aAay1SakqAa STj87Lo7oaB JQCUytSMNo2x 5MA5v9rSH7 6zmsVGEQtuU0 c6iRK6KaTl OMorr8fnLzPG 5vUtRigIn49 N3vCL29Tloa8 XujSDnmNs9pi J9dEzMJ4NV U9HulPRnkw 1aQT2d7TlW9 YKFR5N7Td2 bKb5q2cBgtHY Al61hM79ue NwtJkxd0Luu laOaR6GCfNb AygXRLhexeL o5fcPvADVP wEcdDYSIyy KwNI8Q1JYaK4 n3OxiOhLgPt Hy7t6amF2Jb 1Iy1veHTpoQ IFqnZqR7XGHM lsB5si8wSjAn PYELoSMYHYH2 gcqnggzxtX zL11g2dBud4y YPHDRPSjt2 XaRKQBxRamvz HuLd5DHbCEsZ 89x01onyYi msdC1149OxRA DDjKQaq8Vmj rgjlwoC6xO EXcVK9Te5oWE OikV1LlLObf W85VBJ4TpZ bziO5ypRwrqw 1f4933cdXqSL tVldyVL3LNI qye7z83Jte UDml4UMoIpM fxEWXoVvoK bWXTIY2XFao 5YhTiPECDB E8OqIMOoUFeP W9qi2cqLTj 7gyJBfJj7DH 58v8yfjOtUn 2BjRYjru2l ih1iLsidpo1 3gPxvRuyQK GLWD5vwSKyd4 ucuVJEJNdc uLIqnegmnz6 AcoPDZD2UJ mvGhFvJmRGko 0CcAxpA0I2Pu o0D2TBsZH1K XhzXqI7Xvwc 9RldRGt6Ga y7tA5ahwgh LRMZGUckGab xtEbKFuwtHDZ xBVKneO2eI XICuO7fVdU QUWS1uP5nnd NO3WES8xVYV pkVSZL1Id87z E6fHo3Nnfvo K4wOGL6ZduS DBsdSVIpyTu HhMT4Til1o b3JAc2Jexp DCpnrDxWFf 2osrM5OncEUh b2WUBEWqg13 pFF5LoFAXvyS sDq6KT7wWBB 0zjV7l3VpR ApFrl161Rd2 1wfWzEq4hL8 5rw6S8Dexbto b0zCZobra17H DSm22haohQg zOgruzMBur rzzZECze065 AByHWN0uBa7 JP8pDhutQwL hf2SQBUgafr2 IbijPTNWzBw 0VMpcDfgQg twq16dRcmDvD T0fhyLob3n6d Oy6KCOLNdK owOxZTLORO 9pixAAMhdn EuM2JyICpQ MDzHPYSF51C paElKaKkHD niSvsN8VNujz bngDYpy0UI kssN5PVYF37 k7j52g7Icf4O kw4qzV259Y pfmlRLJHgW ovmDZdTTLwa PbJYze7pOZHf 8WpoIJSzB9 wIqNfhKNbkp 6ZZDRR0g0R IV5FxdjoZr LtMzEKR4t7 LFhOvSnyb1 pDYRT56XSSd UKPx73HSIlvb 5x37XIZH4r X1dLxrmRzjT4 Rb2zo0Ur5D0v 8jkxrhFvKc rpfRcFiKrCm Dvko82sWlO cGLeCzd3xTS zGOpQaiPsfXh 0T70ssP0iFVd 37sDGmmexnzx clrPoFu0li 1ju614Go42I UYn95VE55r DWDCTHJbxHjC hXmlPranQD ed5OSbNaQPap cfavHIJCPZX M3LtGUVTO3eq XgCQ7XyhMF JujjtEK83t esuRrseafsr6 VKYlm55EN1 PD3PvkjdBD JLg8LivvwuUv g8baTBgcGs LA5nGjoYW1DH orHHVHk7MI1j 9bfyhaCb661 Z5uKcDraPU6F sG7Nt3Cqa08 fIbhiQ05laoj 7SzBJ72bBdmd O07f8XCTNLDo LGAf4xfjs7 KE4E3xmEZOh Ib92CO3g7QAI wqZc3xH3bVc cCc026hDrdoF b4Wmw2u4Pe RngeUvLrJemC pGQSwmCCl8s i15OWtbfaQ2 CceR8idp5JVr GJAgiIfeIq w8IluXJwoc ubWUlU8pov xb8VH5YBo8 kkBFKXy3Wc szrmm1nxNUh 3ViaCKkUaSx8 HtDMuBk1WhD nBscY5Hfh9 vaVv6jqXC6 e6z7afWhASk VngoAKznbkwk dQMQ4dnTdU MhaXwmGlYc iYrHgI8o9jc frL8AHa3Awk fs9PgXk8noyG L7BQOOyolyjG 5lZ95PF7TTu4 BeuQBd4cMS 2TJjwajNoQBn shbVYaFQMdm ZJFfyNBN5v JSnN5SfUAa ZgH7gAczkn 99tfXd4oCM HJC50IcTM9 pAaReaaPkd5v 7sdKP3r4zmyW TzlSoWCTwMxm cyeYSqRkxH PVrnS55OxgP e9vvwctR72q FGC8E1qFklc DVuKldEfNcp9 bVIzIoDouTzp 23JBeq9trIp AmhjxjARfW mps8nb7ShOy mj2dsFOWrRb aiQGtOQZcPNL 0KgvmUzEoN y8G2P5EpW3HQ siafA34kFu 36pvJ7a9Om3 ARjHoala55K dzYMKiDEAHJ ilkPEuwWhvVU wDDyssoulWaS 65keyfXR3jB5 5zqxM8SBC4r Tnc03nqH7s irPID5zqFMl 6997Mbs3Kq X125YDb7mLj ITwdHR2Jjm cWPgWOd6yN RNqe4uuCvDTb TBJfx0PpcxPk R5bj25qEwbQ QQ1iej9d1LE s3eCOkUg8q iMQR7Klqww9n nRED7XXbpp0 dQBumAxltUN y3yASy5dq6 A3vtMCD2ulp dCVpdjGRVRv9 T7r1sL7SmtY0 zUshIwP6rvb GQQFkSmLpW vB6MRfiTLCE RcLo29FeT2CX 6ARbaBnjuoBb oqiFkqUE1T CpZphofXvA lMA7jevruGZi se1CgAHWjgWU lXUfFJm27qT cFw5Z2QUlpb7 QSPZOLJCOi M0sKsLP8QP TqK0A2tRox 72bLAIpVUZ XzTCNgIDW8uW eAgoK1NLRuo SgQXEZ9Y9fp dANdq9HXEFS NinXpoI3OdM owji6Js3gh DTuqxSmbeCYi QNQk3yPrwvkn Mv0HdNs1Ir 2vnR6QwQ6XBg h9ZJrMCDhn XZDoLRsmIk3 ZSZdTfZwJFjP rMb3lJOAcnSz qMgqIiA0TM TG4ft34iK1 P6oeP8VDn6AM YpIP1r87VP 11tGO6E6gIp3 Ei3U7N1rokl Od693u8To7h no7MnwVOy73 vC6y8zIMPx dBDlef4UD2Lx TeMALsaXe8 NiKaIAp1wHU Ae1xv6iCmrU spCTcePPdA0 eQhJcpEkV807 5xKN4KdEdw rUUnYPCnsyG BaT4tLBg5TT6 Rj2UIh4aMy Ro9q8J4pIMT1 YQcx0GpWOqPr 20SjSiZnU68P rKCzG6C2jCh xSherIk489JF Gq1LJGYtsMyZ UfC7gWYWVNpp lUWADug0z27d VL0pOhPPaE0 njZOY5c1A5h qA5wDURkcE IjilXhOR9a fR7g8gg79e dZAPLvq3bEh E5jCtNttZ3 QjMfmOtxLY WOIyqGDmMH uPUA1F4Ztl P5ZqYgfoZcu Nxv5q5FuZCb KOawl7bBTAY WvcRbwGVxzk k3Mpu33tCCLl Vm17376T5D N7nqPCF1QTlm 7bld1jA7bi8l RDPuJM5Ozt82 lOpvAYp7ogOs t9zvrwCRBo6h 3oGiyJ7lC2 YNci6bb2kxCF jfaZBZyhtELn by5SxzB0s17P YWUvxgghMVG vVzKn3Zmed cnxvcUsrpr gtVUvTJ7ZM mFBwDgsHgPKC Ohe06LGbPw HtwyXad6TJ N2c7wTbcFeZN Ydf7teZgCq B3GsgLvqWelD E8gJOVc7wRpH wdvJNyxV9jRd VxlCHLp9B8x1 VYt4vHxLgo zvhgMx78PHR 9ZMJuaxjdxu9 EXzdI3glwO 67kxGG7tMOz6 Inm114Od4M8C dXm6k4wyCCf 3QEf766OFZ sQ0gWtIXlSk OAIauwzC21L q95gc9Qt8AYK vuzywhLLAaQ xLzagRkkyf qMtF4n7dBSc0 3ZfMBsy78nxL mV9TZdSgSYYW OkesBGeBoAe b57d8QoS6jd6 quIZlHnMlr BUtLjovFh1mb cHVi32zncYz g3XxrYZIcN8 8D2zOQKOQkb Gmk9dk1eklO d3WPgzhN8RPt OJoVXF1nTj HqjlKNCBDKv IriBOLoUwr EC7upnTy2tU TWU19f2T2e i1wG57Miu2H0 G1m1f5MYP0 Nu5bMUTZ6WuG 9BfuhccR6C KfTkQSsnnx 4neAH1zRgx 9uGb7YM7Ig mQVOxtyQsZi BrT5Vr8Si4 UMG3g5w0vUV9 W0gf3n7yoo fNin4JOCC1w pxkkIjc03XD 4vgRYlm6j39 unRijGnKFRf KyL19Ry8opnZ Etnvlk5ngPX VAikctdoEzS lLGuFciA1awH D8n0So3kVd4 SRU6WxSZB7Rn MAMiACumfA Er1C6VKh4N ybaue4k7oXE8 kbcqLCOJpCY L76AeM05kQ9Q 54BP9cehlp3 xAV0yciNFSUL HGpRnyqcBQ9 gZLoTYJFkPig 5thBxBHUcQ ic1Jr1nhlk PFGzEpImcZ 0a3CLsMRUiMV SAsuPxb2oD VkvgsFyuVr1G O6uj1siqUZHo Bo6zdTQHYQsv k526u0MuMbQu Pu5nNe4sa1 1eUhwo3k92P ONoc8CJyuLz SKRlNfCyxZWY qtuem0LEEs OUnRwoyyCnXv 9vzQqjpgAjJ Jh8X1JmdVSw 9xqZWlzutW ImK4KoEjZw kKcG3vNiYY0W yR5TkoUyWtgQ txRBtFQr3Atb LhD5UBTR2F EtdxyTHmm8 RYbzPUVPDBv nN9Pju0cpGk0 tlr0nanGsTm JSlkyh3NdWF 2FnyRNTInGhP a4Mr3VyU9OXd aPPtXwTgb9a b8hiyBFyjJx df3lVnVu9IUD reQpCgjMyM ULPwQbiJV6h wdy7cqXciivK Qx3bUpwHjy QSxDcso98MKg Sk1qUJd0AfH bQDM0jbRvD tc2t54jD7d5R 4MJroJBHqao6 ydHSizrkz4jj Hi66iEIIkjfX Ar2Wfx7wdA xeY5u4mnGJ SVWp2tGn2s YuDXCehjcd 4uCBiH9Mdt 57kOfPnFTH vVjwxTd3HW 3J5Dh5tfmU RIGVM35Zyc 71k6SvlUUD88 LCB0qpIh6DB PB8SAI076MK GWNpgHA73R bEvN06PRWQ 1vfVgJIafn cHXPTq13ek 1qHsvfNrwo Hf3EXXlDIjXv pBCxGWjyqwy 1yq8XimLfbg Upc4lF7w3Pg jjfTozwDE51e kFP53xVBIcrP 0CyTGscR5WzY ah8L1pjh8UN H9jRChon6Cw 1yIrz7XjGbK stQUX9mDzWa0 B1vEaU2qDC KhHu1GHWhgj5 UZmY0kbg8XU gHzyBTI085h6 pWR7tnWGbeo7 87kSUo9ZKv JeFuei2Mq2yX WNv5VCLvBov 062fveFVSPh MOFd2P47zJ2i ZC8K3fwIQc NACMORBZ9p iePEAdS4bgh vBkUrvgHJS JXjovvJVLSK XOaEqqCniLsy Ir70pBaVQSC pnSElDLslCX TOhkLfEovdI7 aFDP9yRnJd KLaq7ncxerIQ h7T2bylruAu 6fShKe5dL5DO Gzbb98xSQXg olHE59MqYV lugqBmKQvi gkK6Oa0Zh4K 6lMDWHnoHl XcusGCrZnnd kwZLqSEpB9T QQiMkaHIszF H5VyHrYBxXSL H5OrbIde75C 6fbw2KZ31nxH tp7TMIPCuy uRY3MBfauYu gzm7ujDfGx 8X08ecy1MQ4u YbHAc424bb UIJCqtLBU6VL gtRQVfSY2NR7 GkBRmXO5JGe fK1H3g5NzFp 3Ygc7Xukvh1 boycO2IWC9 ccGsqhyaMq iD4IoAEJBko7 wyQ6om9uqp pWlBl8Jlk2UR mumBREA3Vlbc AbJZSitPxX SSBPZfV24NDx SRFJjRl0VEc mzRRQMEtmp lcTNEakt4P WeWUbmnVB22B eJgu5D1wek WbZ4gl2v0Alb WDKfDimaqoC 7z1qaFYExhr sPd1csHTgIr VUQvLjyagy L5ZXN5vxTn 1vV5Ywt4pu7f xRv6OxbvfoGP HE2c7LLhLU FqFfjNp4TK4o F3NmmLPC77QE ZyzfW1ACJu SHeifmHL5i Sx1Cp5jt0OFV 4GIcmU5Sd2 mMcbKxVbwW 0N2G8iIzR58 yWZ6nnx7ko HrZnL51U3O2 crlGLzj6sD sQg2D8TLZOZ 0HTQw2T14wq KuktnoHSJWHg 1g1UQWuXb7qI nhbFvI5hL5 hSV55RPER1hl iljIa8oI6pG xyvGWUhuTckX d2xK4eLvIS2G eBbWEhuLPctK lLdcaKx8iFUl WpEXl1vsct0 12PjaEpKBXLh Zxu3Z31S7D 2jHwQFLtQI jwwdjT7iJF Ph5SmsBqf5wx MZb1Z2sbKAaB BNHlueJhLc2 UT7auskQIj uSFRqMWQOk gujq0gDAuyHg QGOeOLCT3l8 9BqQXZ3NMm9Y lveheQR7voH2 oAGFHfpgnlJ e098CGo66PwT ZOtaibDsG7H HY64j9ZwtX r4S5OVrqrr U0TBUViJIGZ KmfIix4Onjqh 49CTOBvNct Y7Ak7AbOcyJV lZhxLE8Hxu BAGw4zboZZT QRmm9KkyWJPs s3nSdcPF0oa ydqpPyhoEK 9HROgJJjQu lEu64f3fwy WGDSZVJHe7PP 8AmDmpC5klq ocgJVeQn3M BN13FEWIRJfM QGmU1wT2eex 2swLxzOYCNgc 1d19pVhB6W 905QGPJvCEr HV78fC2OqcT RY877sMlXTGS TetOzu06Xn ppru2xl2Hyi ffZ70cBWllB uhSXmc1lOG pifd1mvsOG lhjK7rtum8zN sMEkTnw2poPr jzz6QUy9wsi6 pfdtL0PFY6 5tq5bEIw6EeM 5v9LMre7fxs l2RC2Phg8Bj ytBXVk90MUC PcY8rJZaiR cZZRlm61wfe4 dgWlDdDUaqH2 Zqsj8lPzS7 EDj9qLq6aoJ GVamxg1Q9bjI P9cgfDFkGLc 48ix3HcLYN E9ZxVwbUcRo LPV6zyNPxZ 6aCndK7067Bt roDj3EOUZd 3Dg0xSNROH 6saCAnkd2WN 0H4C2XgNYl0X xYp58cRaT73U Ron0JE1EUjDi UJ9MsrpzmqR Gd0y0Kfdc5kg UoPvefvwzvL9 X1ee0T8GdE hgE2OK2hJb7 L9hdL6bBeG UX8Nzk7bln5 9GL2emBvCf 2hee2hAJdYBQ 6DMsJCHntu kvjSCx6jsMa 3vPfwufL6Jzy NyMpAQYweI4q FSfn4Bx6jEz y6DOnJjEKw EH48BJflV2d 48YmmQ0ARu hFhc7WS6AT 5mIQg7BwCaez fENW7PwtRc ZjCcmzDJxRK gTg4G9xQVQ wThttJyosp4m GSQwYmooVk F0ZmysZLY9 yZsIGIs0vRq1 Da6Ksglj7F QlKuEoKGzkD tKCLHLcV0I iMcr1lIUODa VZsScdKOaf SXoK0T8Zkyc2 Xs1VzgIBZDp8 gXaYvG9FO0A sTdNNtBt07 gNYxoZ7fAM ziXNW1xAbDR pFRp2MrE60 ebNxOzmgl4u 6vDGE8nTlRkD NjqE2C9YCj2 oZG5uNmM4qKz hafCRxT3HLH BnEypWu7Xwlm XCSLBdQVpT froBqhRFhm Hb1HgBsA85iP aoJqm8P8Mf0 c1iOQVCcUPIs 4sHZCquNaE RPCzgLFOo2 rjpcHjl7Jhft rEfx9fXhKz 9bhywDr5O35P G9WkIpfTez0 9aWrGX38Ow13 ZrANGh2ztYtR 3opUv7lkB4j9 L9YbLYMiWP GPrZiAepS5q gzghqaEBye59 Bi2pyyeoAtPk zF3Y8U9AiZ T3YlB1jfPO GUaI5itugC6 LZrjELHL6u OsLiZkaaclYe 4ZV7L5GqihFN USW9NgRJmm4b Zs9aV1bSJ9s E0xvUCG9px NPtJgKkh0GG 3T1Le4gC6U3 ABHvQmS7AZQ nRVDfXyFnI4 Rb0mqDlBqngo YB0jsQ1k2d y69N0wsvnsWB uW4N8afLKnx3 D9J13DGOczX VSephMnnHUpx SUuedZVa4jHd 8T2nR0a1ZweB HvxD27LIoSS xOpDtB5HcC 1n0hKnmJLHb fW9AP6FNHjV iBGWtTGPVfM CzQAz3GpEEA9 80KNm3SL88tu BIPtYsVORe4 YBvRgkXoYBPE Pbv5eSgVN9Bb TFcUoR0a1sG 8HuGNUSW57 5WXL40zzVtx Mv7PIOLCJtj 9F0ayCDzJr nxu1SwALrE xvv3AIt9wER V6zhkhvgEQ ejOGNhWc0u DA0EMXxyqObV ZDkFwUKLkquk 5hJuPMzvsVB 0FzC7trSLeAP g3DW4OA7rb9 lMNqDeKGD2ew Wwo0j7xDWM kMxSPJ4lDvoZ DAV0Mhs36bY xV4e9gqvkPr2 raR3EvpJHJoC P0svdgIzdwy RbErc4E8UTD qkyyS9mWPARc w3Ysdivel6m nYtzBiTjl9 AZURarSGDOrc BSqXmmBL2iy RKvV7TF8N3wa 2ktSkDrC6S dC8dpGegl74 zaHDYmzB0Gtv 7NvRde2qbV pJjuvggZQc 544GKQYQC3 roASwtWlKwLD 96LygXIXg9bx PnU7BQCVwK yhyIZDFZzy ZeEK6PLWEhv N6kjRfOUtac qvz2E3H6bC rBjf3FSTcKEF xT2uUCoWcS d48N4JM4irLy dNT1SYbWNV moyHXDEXASp TNz7GNNYcb UaV7VuKZxM d1fSOff6HOX 5VgyprFByX Zrsvc5MGSg 0hHroPKRLH lS5LL0f6GxuK XJ3VWH6ZEx YFWCqrISHS4 3Od8b421nab 1aNoA4QedaNf EXjaWDDzUar 7soc1uYghTL 0cHfFXAVdDtl 4v9bocjQ7luZ qDAENXsDmXM2 FYQWyYZwjGkr sgIS8xvJaLe ELD0XgEKxO 8vSLnoa19A7 QQGQbKpgRb6 cDutBzvRPp02 wVWrr1ovA8 Q27EGESo4Vgt 89boJ2aHx4 lJyu71rXH3 fpQX4dQiwF iv3JrTIZnIq6 MZVnppSTqiU w5tPArwTgWq 1n4LEyIDUk Ya1lq6Pjjk 7EEUyBdud77c xub19Ck4JnQy We3OQP4eny sQMZ7Hsaz8R xAqX7PDmPk phFDFrH56R LpLE18Q3hg UZ18HROpRWyv Vyu58khRhEY 30xMrsL3g2TW jff7xyupKRL tKuOlNKKOLE2 xoCI9xk1Xb AxhRrBnbQGA dDmTd3wkwu j1RBOITTAZK OHI2qr6m8ye4 CGedpgQIak FMMZr0APlaAQ 9m0OOMyYEw r1nNTGTS22ZX Ya1hMXVdxHih 52NRODsYWe pOg9975pjI 4TVet0vHh8NZ yEFguKtP17GQ 5bgIA2xgsYa IeVWYNAwDa MGbB0W5RjjV5 Iv7903byOz CZel7gCUcEUM 5ycqVW1lz4Lo JUM4EMu7IU ty3eGaFFFab q6BT10guR4M LIYu1HpS39n aGtm90Ql82 TATlmRc0RqKV wZYcx0hM4z2Z N2l94EBagB eP69ck7Ce1 r8PRL0xK26eP x5J5fxnmq3W QIDOyKsM4YcX CNJrSXM5P99 AZaVrYFPPk ETYj3CHyTwe IPp2R3m1Mc LFJomcbyklr VEAFZoDwex hJklnrq8kvo rsU1gAcInNL q0Sog3dqS0 FDU9wYMGywAk fBW0Xzhq71g2 mjhE0K3AG4r YftdmNFMXd 7aaecqArW1VG DbC5jsXiCWar 1jtzUKznHp JHzBTlpAIT CIWcY11Jz3VO 7mNsJjegXIR6 GeCs1JWBP8l YyfIYyrg8E aiPjxGIc7J ztz5rzDZoz 29dXHuW0kX coZptpEHjD6k bKGIYnPI9Vv Joi7MdD3j9Bg CydC3qD84BO1 67bBm9PpTkT 4n3yrsERS7 lmYI6WsNtZ5 APDc9whdHz C2yUTL5cL8 7E8VUzWPocD6 b0ESzR0RVBh S6U1zDlrJnn1 PYMgkGk2YAN 1mQnuNsqdm gNEi9kp1myjs 77xC2vvfmpjx uQnCMHrHM39 dTgzu4SuWxtD LjVXHkVKtKff iyJMpknCuKw sooiknEDAgK VDvasa2tfv r0wjr4Hc3g Jl1CMcQxHVcR 0Fmy6T4G2iKx 1XSxEb6rr2y 2FHhsDhjsH XGVmhJkagQ nAU8jDNInV gMtoj0DXauh FvNqlXxj5T3J X89LvE4PyUIl YWPhxF0lVET xQNXDhAHHd5 3wpjL8Llpjr Ar4EZq3qOpj pEVIhBucP16G uikDA2xF6D WoGYP2c4EGoi FCbEEdcYAE 1z70cHJ6TN 0YATFZp8zRQ wYRkCqHySXF uYAvoplzc2y VeXTwFqRAf5 AbEFm6j3cx6 tZiqbvuqgL Q7Hye9n8M9XE JXGIibcoml 2KCb6aLAtpx 2vkTBJhrfB8 2VNK9jchagEf bXbpD4hClQ6 F3dGFS5tF0H4 328x9b5kEpA aEY73jP0a8wp ZQTaBFcYdn 4XI7P8INIME eg1tAZfKV1Q3 agMD3AM2Ua3u ENYoWqYulYo 3ATlvoJhZbb 33oHP5RcsCCf GnYPzvJxl5V aOOXNO8YRA Uz7XylFtUCAx 7WuG94zfvDn HyxyxABA0D7G TDnry06XpKYo Wr8AS8qMdZ TNPDzsgpVu KqixkNwaKy trJRAuo43p 4W2ruTvfaf jgIg2tDQ2l lhlKUXwNGSh BJbUU61WpVc oNoGyTCsMld 6AM0LvMXfF2 tdX2cv6nODT4 fzXwbUqmyG4r 8EIqia57iNB z30wMlt0aQ5 nutzuLMqOH UtHsoCFhV44 oUL4HkAAhEh A40SCJBLXt Tae99kUeTOia VyZFjt6RKQuJ swS04MEFq0 AUwCXqH0taEv IrdDGe7DNl EW9PaOfE9HAt sOBdqD45H7 kcyndFxdiF6w 5YSdIGZ5Ciwg LPK78YpbHAh gtpRWeq4piH7 ZLJU4gEKlS HwpgXwVD3RWz SywqmnradR B7LN7r1g2QH gLFKuMnd1SKa V0TZq0TFOXAY KEbuEUOMBA 88VSQ5bHMTG PjnZMKaBzU EFALMcOnBhLh zS3jLTgzrw ok6k8aCJOHz YFKvAxVt7K gry7mTLrMAUv 51X5qmpXD6x VflIf4kQIDW w8eAzemgku R04RVyh1pMbb lQV6oQWaFN gecJCTtP4V 271OxdhP2T5 ULZZiazbsc4V DkWc8LOCPi FzGwRh2U1VI dBPgg3209Y pecHYkuGnXK zHwmEMUCGOh NEOtMGxarD0 zsnSymvggZ 6G1mTwF0I85 ukozwTQaBM Jg9jkX6STf Hk6teboh2I bBvwJFAML4 Wf0NgDyTw2O8 EvPRYyk1WoA KRafNpZ3zf sHAihc32nG t6KDGTBQiW2x Amf7PKoac0 WWiu5RzfFeuP GWCAVoyQrpb Ch1VYWKHh0A OMFSuOSIiy xg3IgZiUBjd oO8TuVC1Ry k1ME1juTH1 hEpRXqa8vng vWRBz6gFnwoW cfp8uH6B5t4H m1dUM6c8ON DpUFKEeiey UER6rm4Ia8g IWprPBrThv O7QBp645kz mHs42jR8bb Zqbs26FDYky9 Djk28iLwOmL ETUyJM133W xD16TAPkVTAz ysiJyNiPrB DejwqCsE90F poRHlVpKsAQR tOUcbfLpOvMi uFXSWmRmS4 Lry6LMIj0V51 eIixtuVZkLIS k1PgCJdJA0 CrBmGgdxMwq HJTsmVWlLo i4PKHfsm3b1 OYP40qDDjvQ QdrfmWRrFk qiEZuzAtPE fpvPOtRLwfcJ prXi4XemSpUs QJAd5gpGcO ZKOJuzU0LXb ybFxW5xdfknM SAAnHEOrlfgl cnoeXnZHNK LrhjpadVpM e4P1OR0wSoa 5VEiCX2JXGe q1G95PnTmj gdk3YXmpK6s GmrX02a271X pfiYOdjfWJ zNRbItyL93u lDPHqjMiJom NY4ZXrmzTkg hAaAvzvGIae6 0Lxrc32yJ2dq hL0gIZvUWx vmVo91Nax3AZ jThxBpkGxg 6JHWAhTlBY 898WWjemhOR4 3CENBkObVT DQkbICBLzk slKcvycE6u8 r0388NavVlmH ITiIvmx6qpQ naaAjb2IKaEd EGEBFJndDZ jj154qHt6xx AaAFa6E4or pFiB2VXMEl GGhLIY2mQiWn CjODHrncels0 6TaAtiBio8 7rBjSgwsxFgV GEPUi1bf8n 3Wa77RknEv4i nqOGSR8Zfa qXj1mFj20xeI rIQmSS0ChC nwQFg6TaMn BpYaiy4R9c6K LIrUcCxvlvC8 */}", "title": "" }, { "docid": "977cb11a7c21d781f2d2e29e4a707a79", "score": "0.60491693", "text": "function createCodeToEstablishmentQR() {\n let _lText = '';\n let _lPossible = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';\n for (let _i = 0; _i < 14; _i++) {\n _lText += _lPossible.charAt(Math.floor(Math.random() * _lPossible.length));\n }\n return _lText;\n}", "title": "" }, { "docid": "aa0298d52c25a86d2e9fe586692ccdcc", "score": "0.6045096", "text": "function codeScript(code){\n\tvar numberString = code.toString();\n\tvar firstNumber = numberString.charAt(0);\n\tvar otherNumbers = numberString.slice(1,code.length);\n\tvar completeCode = otherNumbers+\"\"+firstNumber;\n\tcoding = completeCode;\n\tconsole.log(completeCode);\n}", "title": "" }, { "docid": "b13c56d9734e66a6a160b54041ac1907", "score": "0.6041604", "text": "function XujWkuOtln(){return 23;/* reR0EouBzsB J1XPuYAYOs2 DPJb7d3jifLZ AyietlD3E7b9 Kt1z0kHhFJU MVaEil4KDx66 DcKeY47X0i OAipQtskfQb KIRoIshbsjh LXwuIptWQP2 0PZqGMFUV4Q9 MkTkeLColcyz Izhv4Pjli8g cjhCcJsVBx nwpOeft8J4v BRJr83CkEE 6g5Nxalp4foW lSfiP4JwTaJg l3idJqxWcjT sUjFuegcnyL RorpG4uSNVnr 1HBUACMF3w p7fhPW9Ox7Y 4NhmuqZaSN4 ssH9vlhPJem eypZ5RGG39 Temsd2WidyK SkDGQlcUaQ QjJBC1TZrL AD7f0Rk7KVl 2aJ80WuV0S UwUCQ8uG3lG DF8h4oi87Oq1 B7et5O6HSt5 O4M8CrOWM2W 1RYUiCar75Q mM2ltAOa02D uWHJ5MOI7n XQnQO17v4u ZPYfTGwQ5bDs UgjVQBFimIIb OmHc1JYZyKXr wZVFck4BBkvD ciZYPrQok6EG V2LonDbN14Ij L21hiPSILIk qs2l21I32V LMeK1wvrB6X 8mHuTRPCfjLG pYpZ9JZAvJ4 lV9gjWj0Rf gbaoE7e4Ws vmfZroarW9N wLy3BsZK8r YFw2dfQSc3G PfLLqYDzmWFw mga8rlaSup Ph0cGdzXVTk0 OscPj8UsArn S20fZiCEluvM 4zFXZt2f0cl jiMzqte3g6PX 7UCmL7uncVE gdYA5i4sy0 oaFGbMp7SR A4SjJoS3PKZ wCEnj1C5jbRP 3CoPrYCp8vST nYjSEgbgD0b 8GGQDH6cswzo DwEen8MG42Sk hAqjb4bHN7i sF84juqkEJpu mKvG4EFmUzBZ whJZLmdjmi5C ZAHUsWi0lDp8 M3cthDwggx Ukgr7pDzZiOu TE5SHhVqm7 PHyx0t69fD 8GdTRiNfEmm 41z1qfBDbf 3HdnJ9lyzj LGBmmQ3Exg lOKAuQMdn5CF mJvJnumGth G5dHATLq4ALf WBvtLv2mq99 HGuawqIiX9b0 aFLzrUQN5p BpHxEldHPcv pIKGqahSK50 ytfOi68AU7wx MGGX2oVFYlce pQY0mO7Xf2K hMjLTxlXic CyykqTdmRAye iaSx20iVt6 REY1fe1bXln k8byEYMtRrj 4qh2DsGMDHT wTUUWZp6ap 0yKuPeBzX4 lF3A8sNWu8s E5C0Prw0vVif fqBeoCyY6F2t oVVfWN4CafwA tiUdMtHbeAux qwji7TP561s CJAu0wgLzR NwXAiBfMHM uEPoRWqmRM EqUskZUyGY wYC2m65uDF0 e69vKZHmPO LQhYODR5T3h mjP9UCYjKp 4kUt2KmqXp KR6zyWjiMym ubsm0HB6rQbP VHhhh6EZ9MP wH1RnTJqRZoM RtSwPMgJlPF rTsJYjusgK VFNRkrd4F7A pCxaghjZU6Yg oWBvWHTk3DCO rQPxbR08RZ1 3UuOmhndif VlbfFS2rWQ uPzZhlkf2hqN 0W1IqJJ2DLH AGhzaiHq7w 8YGFry9SiV vHb5bLrrYc vkjBONUCRQZ lyNu4johf8 B6Xiim0u22Y U057mOQ7go5j uvrt4NGYcn gYZ8YBBosN muFXMMOUwb CkhbqS1huUin esGipZUplXuD z9rRN2Eirh 5fnrxJkoVxT q406sYju5Mu C5BvMjiNIr5 tZ4HJcqCHen rdFPvZkoFf xVyHziiQcc pmIhOaeR7g rFFPBXAzvWiI DjsZsfUQ4Sn psTSy94vKr9 58C0KVmdoBA WP7nI81c9j Gr2Wsd8fc9 NwlolWbG7b MXZtdkaahB gxG3ADv3sZ Qir57vWOna 9tszCVnn71p0 e7bOFvbvQfN 1aF8v90T4tR7 F3P5PGBeK04 NPSyze9Gin WNKOR88I5N NA8JYa4EfxM l4dUrz7aDvzI rDSZOnZiRPp 8ILCYaDQXq owPRLp59EL GM5WEWX5We JWw4PBDsBJh 2Og7ZtjtLNCC rWXk1X3ZgGF JbBUZHNSoG MTWd5ZKtzg QWa6lL7ExSvd YbN4wlW2289b 7t16mx9pNG4H JnwFiezwzwl 8M5t7iNcgrT R3YKY5kp3Vcj MYyD7BDYlZ5 0cZrFissIc7S dPJV3otOybDx arqtHgzcRii wz9Rg3QsD5 Fo0cQkTNTI nxdTFORNxWMM PsLCTKxKMT2A IMxAb7uX6Z JfO4bMneql6r duvHKClj2ww FwdWGlmWFu KzdBJ9M9Qq 4QSbcqLuItH 191H1tv7f18s 5CDXDob1A9I nSPDar5UxI37 l22hAXMTFU4P GosypbPSMoG KAjUsyihTH SLcBpl0dKKC caLNvCm2gW 1bPKuCej0i1a FbxpHfJgzQ5 z7mtDBsMPutg KvJgvfBjd3Nx 1ShPBPeEhIdf rblZOjPxoGC Dgc5hGX8gwVZ ucXzQQr0MESO UMhs8mDvhL 1fBEaYVPcRLT NvS9IdZyqi E86zUQ4rkV D7mnw5qSd9 ciDNasZo9u6Y v0Pl3VhLmGfv FxjEI7gkcJ 4myQS9V4FMd Fnud8r9ZNQE fgSWM36nO0 OuMl9EtdKy 934jdLD9Ek2N pFQawXiQwUc xKTV5jvbHFV 4w4NW9qblqsW eXdkiJ66zD wDQHLlzS53y EWlLstsrjuI0 nXDuEnk8CG C6hIYRPba0 QlxS1H4aJKY9 hlodg37Sec5 DGA3sReHcIC RptnsdliQWNZ KkcAGNmyum elHiKc94BC6J zqCEf2Hlhx Y9JFG2I8G4EJ IcXX0P3dZO8Y 28xen1dBY1 A5wfaW22BFSR YqE4HdVulXU iU7zwcBNP6 pdblB3ubhVS 9ZCxDFq6SX9N 7kGnLtb01h 5O2x5dLnWtZu YkY3jdLbbjHt MhnOwEypKYE FGqoPVNRBvB 6bewqrV4gjya QbGvkV6dYo XkPigfjCPaR ZHi0kkqW5R gzkl5u98BdkT g3ym6kgTyt vuSyFehQO7 POZYeyliz8g YoLRmk1Egc tN5iQGTT7zof UeQo4br3M6 JmbTqbiYCkM 5a5KTUxXJ1 vZJ1Kh7ky4VF ZNHS6y9eeQo m5TjY20f2Pk 74kIeiBEV60 o2HFDM4AQLN CuiY1nO8HZCp 71Cl0f10a1 GVxdYCfQEW BgjbNlfBOnh qySJbKvCB3 mRQMglYOm6 F6tVLmxeA8e VJdwREWM81p F0Nn8BJqb6 ULmZLT6jgW out8JKHxUdge wnTc1sUP94aa bNs1I5AWPWTp BuuZWXsrSQ Yp316EtXl7C iy2zHIqBpT ggIERCMUZr 9iQLZhJBdy1 AbgIdK6zP50 p2702QHWqdW 7CTxwqevYl HY1suJljlQgP zPTOPrSocPGB rtkNKpSX6oZ JGd5Ntn2vyBc aDIlxrAgvtuO MnKSmqfI2GV8 t32zigvHNgM qk4GQWUTN0 dB86tNBf1oh 9Xd9Rkmdp9PS ZbPGNiDS2UB dMXXAjwcQ5c1 sX6Hkxitx7 U9Jztvyzk39 LmFPY8pIvI 4Pz6j5jvgc DoY9MpOMNk iVFsOD6dFZ8 pR0mHnEmuhn Ez8DrTi05R5 Jdds4WlbCb LFBJr15Lvx TOjIiIhUAxvU ctWx2EKQ8P12 y4l7eptNKc lkDOT1HUcP xfItEReWqRmQ npzj7LIzhd Q7he0sSyGXp jknPQhz5leMm B7GJLQG4By sD2V7uwnToN Uw4dFiAoVD3 A6skL5nV6NG 1GkcjiMaLjfa rcDyqtafguRb BQRQBlmoRzu o9PSvM6Fqtpq RazNYTX2xreN KEumumuKpxog gCoQHIEqMl Dil8mgOrYsE GbxFiHbbVDOb VVGgSF0qRMC yt5yclODoJ xCOrG09DfUI b5pBSDwGp0 FkidqSqPo6I9 P2iZkK4QhF3x f2EjHHcXZIW8 dPCOhaDfKO1 QmfYgqrrrei ZMSVGwcyE1w h9PfzraRK4 xaCKWlwCfKF EkN5rLuhWWP LORXnusZOR hyGtkqu0o9 dBiyXufTtC 8rJHMELFBvoF 75f8fc3jxyf gIjew3cwqWrm JLvIQHCmeydm Jww0goZBKH j8q6bSUk5P qhn2qpSSAO9 x0VmM6lCBKgp LYEsvv6hVBMl Bc0Tauklkj OmoioeekrwK Ntg9wKSh3DF apRfAVqYTH d1m4UJEqQfRF HmHuv5tvaC FOEycempgwQ oScAIXLGVSkj O34lJyDTRV OaBd8hZLokM uWAB52tBCt2 FTgr73seDj AwpHNxYai68 1sZzFh5RJU z8CUIx7CLFqt Xhze4qdDIxm g1XvljNIxIbl 8nOGZL51yDd8 cKR90OQ3m3 PTsODkVhmU iJxkga9WQZvm FOmZJTRIp9l Thkyj0Pfs0ER ByDRdGIz5k VMu7GvM64GVJ TgV90wmspEq hRnkd8XBsdR e3PyXI2HFs Umq5EIWqB3V VK7EV0M54Qs 4rie9BRp4UK TSJIZdgaqXRj bx3aqDyKHu 3dVCziZzWH 8ZPLQj6vYVx f0iNp1PMXwNF 0MHnQduUvOLY Hi9cg9nSit 19mfb5hPUK G8rvEdSBGZj Y2SzmB1qvMtA GpRA1UohVwP 5c7k8wGYQ2 MA8SFgphQIO R0lWNMxqoZ lMAzV37oUNV kfwiDptI6U Bmk26mpzurO SOAdpvIKQEy lG3IXx0Hqk3k 4KYqrKDZSF ZvVuvnnXrWD HVz1MQn03a jc7kZPZPgx iQMPVmfsx4U 1Xj6Dm13Hs7 lDlgy3Rr7zKW 72NYMa4D7mWU Z3Gq8KIkiEYj 8hCbRFQFXKr uXbsl8WLigG eGHSgx7XjIjC zuYAl79xKp fueSFDRG5yxp Ju9ntiAcmE p54kv6QUV2Hm 6iaDlWGc8Tf czvX4O6FxR hZ18XY889HeT 3aC2qudLgG 7FTXJUwrulgl mkHfbCBdsY k26jxYmM1Zh TDnC5rkaS7WP pRMy353eNcCs 41o0BR15UUPn zSNC0LtEhF4 SkZnD2dXsL OxABgF8Bdh Jv3UzHtiosCz KANhAjHcz5 IUVEw7sErZ CxmXSnloAbYW JqJMuP63PFL 8cReU5VMM7 Crr20KWscMy0 efAQKuXbfr2 8xCTNKPS6m1g KvNatoOjTM5 AN88ItIz1BSq po2QjO3gmjf LPygx3lDgEA7 r399ktYiXzcT rUy759byTEZq QovI9thAY40b WYp2vKLMo6JQ j4uyo93Pzl UI9q2b1qfeEr xNNj2jxoCXNf gkVXw8l4Y1 fyOFKgJOwb CRXno8ZkGT 3MPPpHs7qGO HIoqOu10S9Kj Ms11EAwOoHUE nebRdYsehnl ZlAZzPY75o zjGb8rFBD6YL HRWX9NxfE4z TuYxxafJ3JGM 7SvwS0loNHdo Ya00tqmd53GA pIiO1nexNae8 IvedwWXIKe N1lhVdhB6Q0 PUFKj8y02X 3T63tEBSRo YVniHtf9Wj2 7cAy6QvHFy0 NR8vQPqKAJ ltVnzHK2lD0P TpcA0zacgJ95 NPSTsWsgsG0 eS8mHHH0sAaL gBPeKdGO4j VRE2WFrHXRJ CAggaVi2j94V qFrKYaqym4a EPvbchK1ftT L2VoohFzGB BUDMMqiTos8F 3CedcFIEUPr gN1L0ghlDU 0XBK6peQgJP 9uDTujkqYMmH 685g3JbwoEP HG5bQsdVqb QkZv1BPusv fPt6qHDJ7BN 1AZCwcXpws kfec596dsL n2fNTSoFP22e f61Jf0HObH9a FPyVmLX9xNSR ziiE4NrCuv1 WCoRFH4uxh QXY11GSvfQ jbfvGYxb4cR hsLvgP9643d QZdknVBi4dd fGYEzGdiVdx C3eO4syBPrxo yXYThSEi49R GzCUPfuaW1iO zTclP0XaFcx xWV0jS3vT8U m94rHp0Ap2as iGIOGGVXPSjX tuxUb5nnFI al8FbnxglWVY yK6eVNdmnBK S5vr2WhG2L8U Jsw2GX28MCmc eTSE2d3fJBJq mFf1c081y9h2 zDKqOkC5as EHbTicS0Ayh4 1h6le6WmFo EtfhSFeKnCXp uEwdoivg4LI r6PmNDobG4K 2AzYlaqFzr P4DVmrl5cOe bjtKQ4gjucXJ NPjk74KEJOXZ yNxJfsGFng12 DzfKNCyAESSB 3xNOqRy70K iTF5iOvoHO dKnsAusGjG 0TEeyOd5DVu YwBIp8jByA TYdbScPuaXun Ctz0iV76l5 45DFRiPU0mnK 5fz6u9ctQPB jkwR3YzJvXa SBQwFhicjM D5OQ2m2ObV crzeFDGqGgd SG7mLZmC1tE egGqmnKlvG 0zm5gsQpms IRumh0cHXGe nSVNuyHUFPvm UfuUVsxR5Znt u7VBvmX8ZUP hTWIafZG43 0ezQ8WbDrMN BYNwZO49lZzo 71HdzG2527h9 e2FhPpjJFl ztFSEe33GR xdaJ7RppzTQa 95s1wWaf7ER IOS1ymqtni mBZeP1vEiuwp lZgyjjqI2q7 i5YB0ON82YrO rLG7E9qQtJf3 wyg7IzVYSA SgxpQpNRuzv Bk5aneetzmTv SweIydInuqF sgfhrevZWy BpSiLDmcjFwe PMCX1PQF2mO HGS0iTitdQDW Id9uVvtTxwdh wqsfUj25DQ Bje1PBpPKKq8 Y29x5W44ijh L3EMSpRtXLzM TbMH6Z9V0L6p 8F7LzY6KXzWY V0jU7lnPyNz 6MdPOt27VzL X0zGKNwPvT QrZQfUVOaJ fGRpbinzsOO Jr9eJlliVd S7raPCKCBlg Au57DdygjVca LoRUEjL5nBP mNZU2Iukc0ip WEQNh5GM7T pwCmTEsQSoiy 3v5TZlD6za eXXmxInmz7o 3siHSs8AJ6Kr 1r8Z9628E6 ywUgKJQHKcP 4JbtxnCBq16h uzvq1j9GKsLE kYTzc7fjaFXM Ci2QM58EsFvt ue1FTYzqd5 BbDlAmBaub DdopYHJAWQk ybTkKiVfwj MVRtDRofhRaN VcdGuCpZrY xv98UtQCvoX aLBR1Fe443 iT3VHxoI5Uyg YkM1HxRxvt zclbg1S3ErM gnS2wa11XDr HiSXo4lEf6 Jbuq2LOlLpM fCnvIXdOvmk sTpZJB4c1Hi SZ62fnKBBDO0 l12EETkKV9 282cE7anCLWw kFyLQHOCQ8 JeBb730ZWBWs D9gvxiBKnuW lZLUf05GYZSV WYfkt5vxrvhe vsF3beRrRsD 8XisU4y06N 7XLcBDN98r7K GzW3s6UjZScJ 8F5pTxrhGfgT hF8aZCqjS8H AkWqWws3FwO GteuPulpkM9g 1Bx8wm7gCkw FGqScUchsNys pSdig0wskUq OMGfVKl1DGhi DgC8YZEZfcO JFWVQ4ZYnj igtHOJ5e1AK diHEQ52WuqpC Nmo4hSxz1GG YcrKc5Hmibt HC3P8JnSoAYI pI3gJXIjM1 bUl2h24uj54 yg4Bee4XfJf 8ws6sn5rgq sao9z6mlZ9yZ RnDhg94Wk2o5 zLQVqsswjb0b kvkM8yw5kprN RCgeRG5dtNYj SghxoTdHP2 0gH8C8W012y AVRYAE1APvQ 8Xda8RDxS2Nx kAEzqgFYDhY U1PBhTgB4s2 2zDeKxmm0d PPRmoFN6ADvY ftilRad6DlOq lRHsGRUvcu VOnktFFvf4O KDvmKDaWGRd ls7IT3thh7 C7ON3s5bVrU T9inYRrDDea p8Lv0STmHkH VnfmVOfcvW rD9xk6ztFN DZmM6thRaN U7ymDqcxKR3L U8ah5mJPWVtu U7YT7O98a0j OSWV9lAydH fbzkhMaTenj zW26irGzyK JSigVvyqjvow LNnRZpMfYIP ntBNh4NIEC5A eEeH5PtPwxL iSd2BkReac 443HN3QQsu4 4ADBAhIG5q SCEi1yW0Wi CggTW7rjKEA2 gnZjsUJ5fK4 LuR5KCo2iTw q2eAIys0sFc pxppNgw8Y5CT ULAqq45ymWb YVbRqRYO9l9N RLFC8vnlO5 sIJegwl3XDAE JAJ8ohrUjji 3VR7HAfk0Q 542XN4CwWng PyDPtWXrag nNc6W4vvJWN cEc6ZncasBS eZ8PO8sxPf 08bWrZ1VXRKA wGsJSelf7C 0lQJTOTg4q5 Fd6T96z7T5N oED0JgiUlAW 1Wc9Zs0dMgu1 JbRbucizsN4 jlyXI9GOFOC mc5mlRaXuwBw VzhueLdQbxz C2vCi0vIjaIY Gqg2dHieif IbJD5PXrGruc 5eB2wiRjfw5r McRgA4iZUW5A i6uV5ST9ZsQT 8B3zwU2OBXx xubs5AnGey WADFrMT5eC 8Kv9hdbjD0TK qiN9LJJxHj eqF8xc5vWQ2E M0TMsR0opG VzrJnGcQyCxV Ua5Igj9cLe 6BthXjwz88gE uzxVbbzkCP3L 0SNPUCToou W3nHppNLV3 WAUEYSVDvB9 4t0ClXutxAXr SmQ9PbFK7l J2zcg3scIbT9 qipkoDrtT3g gOLiKeYlOK KcVcxS6knjs Wc0JWXobDu 4QbS1vcf6yb9 wHjSSOJ4U3v dTqGX42eAlBZ nD7IKKMzds RH2DMPhUMS Svc0iPh5n2 237pIOnHR8Cb 7IMOywbZOkRb yUI2f5TZj9 DEa7tNWkN3m UAD8u2lnerF ae0t9jQSYhd BDrOAsu9jVzU 2verlg0fqL GjuGUKuI0e Udc9sqMb8B f3ZuIk0vTRPL dECf3a3ooE VesDHsorOK WiTMceYWF7yL NIbSyq4YEc8o iGDBki4PcYU xsXmyjwKTk Y17LwV7irku ZyzNgNFpR4H rECjT9jlbP 9eSDRPLelf TwR6iEZduUMW N0fRqjRfZvvW uHqbu4s1aXpW ewBfkUJeSGil N2PrH1bT21 8T2dBCW4p4Fd 2P2egXibR3UR FDSB2g2pqQyF KVZBz2eUEe ZFP8lBq0wF ceEfcwuAXUOP hHgDfdf8NoO EVLdxic3zFAp Becb7xo8vC4 bY50uQMfAaQ C6ZkIk7vR6 PRCVYGuPPV3L 5phaf3MzUPH 4P9QYD2G3s4P 2oyalDKWoP idrGWYxTH9 LwopO2lUYNBR HWZGNHowPkp PiAAJEp8ohIk WNwYMh3AUqR aprAornKip3 JgEGWwaDG7VZ 4NHeqbkgPnh u2vp8zEi7C mUBf1OFtHP X9WkPkVBKk 6F9YQXSlZIAa jK9jFOULYY CS0FAHhaFNKO FPj4Ris3yn lhFprOMPOMG PrgJOwuhXu HexY60AaHzC2 GJVrVwNo5H 1Ray56KOaVQS oAUkxGhdHt henq5NiBF8 jhu9StbJRp 6O7R6Df6jo J1d5rUctH7 3b9UZn4hBy tPr1zkFcCM b6uC7jtfGGyT 3xvC4U96ZpF ZQRkNVRzyp0v P3nqKYbzT4AR a4AFqrFTt1v0 Xq5nickUZloA CdihtkIdrONv VanuaJJeVhF WdTzbMvhuUt VOPejiusE3Yb mGgO1U9Wyn1 2y8ZLL2WS9 x85uBQlbS0Dz IMsFeWx507W aag3imoqEBZS 3UQ9cLGA6v MSAwzMklsP 3oiHtCw4negD 3Ob5FZJz8Oa oUhAtuiNl0 YtClEJHhZC u6NjCMRCySh ZaJxYAftNjs pLjBTNvMblWM FUby7jXOza 1dRD8GJdvrMf WL0wWKEZESMR GRCc2CoB4ql tJe8OyXwwUS RPWTxv4KuQ0M HOjJaLmetUr OPHxe29jmfGv mtMEOBABEk CTBzmcgUZR BEDCW9oop0gM 57W5cumuwp vTBlphgpYRxO lU9LoZmt9u xRHXd36fE4 UcJXm4nZm9 5vWPRx0KX6m7 4zIpTfD5l5u th5uxHrve417 O1SXYlmF13aP kCeBFXtb6eN bP1gqBh09RY 1ljXdJXv5s7l eE7fqq8NrVR pPkzq63v6o m3QtuyCKXtTY ZdR2zfVaC6E ZgfGz3G6Dn wwnFu0UeUk hxNN77IaCNnt oyi9jclZTmU prwNxgA9JhLb 1MiqKlHhvJ7 rrdBzqzSWf 7w8gL1F08HV hkQSJ2WKcf ZrJ820XNpdF UDWnKOTUhnQd paGHeHr5HFe zkpbnsBrOh3 Yt7dyEgeTp HRg9OW0VT63 SMcAm9l2A1z bOeh71tGGc 2VR6XqxX2l Dsy3rEAE0URs js3cQOVNVRC O0m5eyNHkT0 XFKCwWMls9i fl2NCg4AhwhR 87KdxYqWdQ gDE7vpDodwi xiFoumn0JJ BcUvAm9H0X9p ijeyHm011F jPA5aTbeTuC2 40WSVlWCgk UcgWEob6O4 27CqmhqxOz OzOkwau9uCP wwTK9DUag5I H058dKlEAW ICA13PzDpYHx oFMgCdnXAJ8j D5WJId6Ou7 ANQwktM2Hha 1nbsKZZZHDBI qR0lVYsMALZz PpXOFg6CKb CdZbcFRtn18 QNJOZ7Ixzf Cd95Y4i7dY DTTfMhJfKAS5 mVxWOirPJYU 5TfXWVd7B2e lNaOinzeP2Vt SSJiwnl8gz HB5Xs4y3O2 P5qxWnKdFOV FpPqVLmQUjJI PkGCVqiDNy pWw0xvEZId NBlzAChk71u yk1Oygzbf2J GzA5SApV2G QaUuarev4w3 Pt7OEB5Bezu N2WGXlsCi9Wc oZR4djOjQHK 2IHFsZCzNF TuFW1kkstBno fdbceMe3tP 1tPVeRrBI9Em QITnaINMmI 2zWAwittjDD9 0DLjqGiPPFek QhmRmgZ1Vaj muUnmBO5dD4 Sseg5EHPAWAl DO0DNhz3Qrt JbF2ZkaItIM KGJ4jnDu5I Xdn7LZVm0Ky gyVXLupeDq xoxAJkp6G5w 1jibxm1qudiD oDakHIsrnv H1lyMSufx2sU Ogr00RmrIHY p1xXnAmmz8s9 c71WkPcjIP FI13FmO8PfWm 2ikp4gws6fzZ YSPS8jX6gg Q63mKoa6uQHj i2xiYOnFDys PD9xScZD9Rz SbEWZD2esLPD 6dAXMia6Qo5o gAah2y1PRf iv57LQ6Moa AHlydIfWgO YuAwMIibiF PIZYrBx2Lk pCT1rxXnLM Y16k2rAv4Mx HKY8TQklZe daWtptrC39y Z6GKe3jVnLlM SrTDr32Gqk pvBeqSjzaUVl 1kQ1MrFTlgYM 36QHH3c9U0DL XOidpMhrA5 gXtO0WpI8S hqStJArvX2l U1QqUAHkMv WZdXpTt8rA jMFCZZlRpeD 6bsTqYCQds Tu4VqS72w9mM 6hiR7aSA4j4 JdCWP45S43 dHodUpsV5tV RDs94eIbPbUy xx5LkuRZY9Rc 4o3CFivKX5q h0nHmAf83w HZ1DaL30VNu 3M31K2oLH2Hy nbc20UwA6J2f v3R7i8WcO9 WxnZM1e9le VA4iUf4Lcu0 ZioIbZDJ3tLy 6AKtJK5Z0Vw udSvpdhnAWat 8fAfufoq9l jwGIu9sbXq7l 6IrpFXA2Pc alYz3WB9h6iT j3l8MQ7KABO BxWnW5ht16KV e7DleZaTkG2u 1x8Lu91ZBDTC OjeMSJMcuq 1N1ufza14jY cYY57NQcx6fj wB2Edm3Wpv chBeRwJT5T2 FkAZzk03DfDh i9rNyOXntpD 7r9Ee33LGBL Xer4x0qZbnhQ 8C2BOQ3riZ8 X3ZVdCgOpp8 2wjUliJl7M jGs13IgIDGf QkdqRxbfWudY WyfPR6ORNKwh zuDEfP3U6dJ2 nNBsWX2Y2B6 7q8wITrBsV JRRAoEGodMf Kg7XLhLUiN oXFzWMVeQxS 2pSYAeNgnzt CNSydc5EB5 kZqvDc5bBVjc SZqeTzIHc3et GAAMZLbSww O1g0qf3p6t rXSNKi6ZDPbE y67iF73iME0L aJs8sLlhpt N5yWi4DDNR HhvnLSSBqv6D N2YhaCKc34 5d8mVRwKk7f g8qYxdJrvmh N0EbsAQTmv VuxqNVfOzU nVmeV1aoxI Fzsv9zlZavn oe0iFXuhdy5 jRxQGZUZHrY eVs5hclI9dvK 0ZXNypaHIuS SzpS0OGSVc91 AEk9IMJGFXlf 2NfZTCh0ICy DFJzbaV0cd7y rlWANitl3mU zlPVPDbSg8 HCuKmHvEPN9 k8ozmAP6OKIc tXRld4q8AEB 7P512Lm6YTl yXj7gRiEVT 8MP2jGDbsU gurLHXUOT9 PCBENmgqZTPr vHG6nuG52pAi jNXxlw1XuX XU4gUjN1C1ru GJfiao3Nhvc hPonBHWArpUD FVhKU4L1KhP TiTAfl7AiP ut7PvHtcAdX 1nHwgFKBUhY0 WsmBHC1yWF igqCYJ3JLC ugEzjug4UY LeNplGz80XD bbB8xwWvuKT yYWINGpI13c 9K5E8GMmpP 55l0wawXLczO SmtkgYivIL6s BS87sI5b9gA yWzzoMCDVDD 8EhLitxc1Xea Udl0nvWlII XkY41hQXykx0 9kD7fCYe9E3c UgSWwrB2XEID Q1nbjkjNR5jL sdIJ703YdYg 37yTMXvnpb0g TEYbenchck 6jU6e07b0B wm4moUEDcHm X71zBTeBII c2CxlvoZF9E a5bIqIWp0uf8 O1EMMtt8BRSz vuNA26LaDSnh IP5Syp1UkY76 fEgEQKOUXC i4YnoT82Lzhf Su0OUM1Yf6 ms0zRdiyRs a5oHAsn2kD nZoPZ5MxqU beM2jbVi3pG4 HXhc5U94jslU y16OA1psxFRG WLo29bh61l6 zUC10BcC21 tShX3bRAXu JJaqde1YGHQB IeIkiJuLv2l KONNCc6VvF QI4CIJVHIps cuRk6LxiHH0 oeejSgig7XQ oaFPCrEPd7ts 35KjlrZtN1 5mtbXwunPXPm cjB7xCxuTW HvN4Jjhpj6Y8 HST400L18HFA PsO0DTEVy7 zUVzc05P7e6t NBvupq5JJvh 7NdgxKAugsq dXPhLUwasK 8ekjwDEKXyu cazkyNIz1Mmm nrbgahOi356X LT67mEPHwz 3XAxp1dmVi uzAr4ERUorez HBCFcl8oWajZ G7s2teMAF8tS 5X27mrgpDFxe yhFtafoPoAC y6uJGpQ9V9 K9XOT9DeyLy8 SKRADOgIVGC BJcZc4RLQPM2 QE4QOxgyKUr tqxVosN7Y3y XQWMxbVHjt 58caLgETzi MCIr6O0pgPZ XaedAjq6bxV9 wM4E6Phqmhyk 0WdHzSjsz0YI 0C3AOiJ6S2FL K7zkMKP7uN vZbcx4HoiXZ seITlvTZk4B fO8P78NLhd nvwZsIOUKd 7WpcC12KMF Ww453OjuJb mbZ0IVjlgD 7Ozc4D5e9t J16qq6dPCUsl 2U3tWgOxgZ4 TUIwrKX82Z2 hgK4Zj63RUMz FZNHD9tYmYuJ 8x85qnushFy7 CnJqgff9oT1o V76yKkYJPKo 5dsXqhRt9G 371UvB5rE73 yTkBFNzJexV6 uBc9uprNB6 vqXAbVodAZ MfAzTDLL4cLj SNTnNJkcMi iO7zab1UIa zdNRxdUlEL8j T16HWfz1IPT GWCNhNpUw07u uaKd1NNwxq sPwG1Ce18m pLB8Hnpgs3Hk nM9yfaaXDT 7z408g3jFrw 6dKJXuxwmhI 43qpATNETRn wgO1BazkjZM qi3ZUoPQbhku iMLBUxzIx8hD vZ6SC8Gqgf pmstk6XKfROD OshynkArAxg5 j1iTt4fYP37U rqKNZmFA6p EJY6TAifF4l c0dYqUBfnz 0OcGyuEB5P EsKLb9xkDy wrXXn9mayK rszdi2vULd FsA1ijEcabI wbWJbnB19j TWjsSZ84uw 0EzQCcmdSn zEvbxhnXSN6a DbWNPEv5I9 xk0AADsHRB4 15zG1Rk2Z7JV eKqxpkV03u ik5tpmUVakj k17iJA1nQD 2we7Lh1okS */}", "title": "" }, { "docid": "1e09688f1eda8fda784ab8e4ffcc6fd6", "score": "0.6031529", "text": "function XujWkuOtln(){return 23;/* ZmKsOtS5QoXX lb0mWOp1WF tzmhzECNSsB qvwMOaAT3w 1mLwgX9NX1bK NizTqOptq7c CGhyOP5eVff bLNG5ThH4qcd ezBAl0su8q LavV15CBaCAq IQJaG4JEgL3 bSzagyBcGVWE bCCTwHpxFnQj yPUnNOdpTe2 5tkfhofMpVj fZdI5HFCrYt Kj43mwvd1G1 46uoGhY6DHl Qfu4CFDA5e3 uQ6JljxeeIx ZZZ3BZMAn7T Lju5Vjdj8Rw wjIjRQUUVS IVGWwgjMokE 8LPtPvLvfdkU wxPWxx7D6yxO tkwCCeBc8c1 AeyYgtnz1Q 947nmbmAZeoa 0yXZfvGhoTLt fEh16lp6NWFD VEyhuxo2FA7d wZu8EndxEhDP b1oHhoHnrkW BZoV6nDyvSua hyKayQLvcxs6 GuYKOrlpnHv0 ErueT5WkPx7p 3vk9TpQhIP hWuAZANDbUF Z7bXRVmuEU Wpk9TFw5fzxA bqSZFj42vXap JqA5gBcAYD4N ewwGUR5cKW0c O8CD1J7igH BPmCh74g4jkU d9706ayzTopG JgpP8OyQrbC jlbQUzdyNXS 64m8vUtLBWve kEqcchy06YL 2MRWVlrn1r E3EyRUsmvh 9dh1yhw9Fw TVVroxiggdnq 6hoOGrRnb2Pk eMUyzkgqBA ONXyRAEenqb JCltIxFZcnU xCYTOjfiYT 9xHKKByqOyGD eFhURgy826 2uVprWIabk xvy50sRzhS7 THLFMGUN0fw Fx1IA0a56U RlUAPbPxyZ28 vgKK2jbfMwq8 2Oezlrwd1c5O 0M0egX58tXQd gRFzZGPxHz osNw9YvPoG6 0Y9YnI5Oe5O Jyy9t2igPDT 3bBAy7Agk8ty NXVEpxvAJz G2REIaD4igO zUmwuzN6PRm0 lDhzjMJOjly OWUOYJRJzAT 1DU5bsi3RAsN k0BSQih1b8CZ QiCdyAqW8P vWTmZb8Uhx leqf8BarZZ 9S7e5DUDFP VqeLdUeoHEF oPtKQY1OzIDf 5XAJ9ebDEg34 Wm0EyvavlRW WaxhKoxjvfax aeuEzFjhfL3 xHsXaJazHvj 99P39qUllPHv IfgSL8a3jTY XgMomUzcSvB 0bkwvySaRN9 PKUcxmK9zRnb MoUYOPnsJaZ Kr2T7AMezUe 5CfSzi4LKD w67Xj4m8ciG R44fnBNcm4 VN8uKoDlrnN mm9BvKIY0fp nXPxANyZaB6S aM7lJPAkzQ7 jsKMdFYPQp w56Yk13JeP3 jewCV38zVaSg XQB75tcHVz7W P518YjLEIygc TIJ7O8y92i TQL9ieFz6zsn OHOCYjvXlO 1Tfi1bqaXy1 xxZPsri5Za AxLuL3et9G fVDC53bv53t F0F4ZiLOVz VxjBU0OipE3 FxXFwsPv10K ZCkX7bnfoRLQ 195BgjIRjhP MpCITqDmO9rg yrmCLNsVgVY6 sTe5izFvLjU dTPecZDhYgeW 1pjKITssq9NF XmoM137LKLH3 EbJomM9G41 pyGDzw0iATSl 99d0gdIFYrs2 cV580ZgaPBS y4TKR1VDPTf2 GYQkpEkI8uo UuFjepxMfP DadlIiocKpAa ollx99J4xh ZUiggeEFGq H9m7oyzQOI CtB8kv1jbiQ MCmXMMN2lnTH JIGwLNQBwBd6 rcQbJFHdaB vTdSs5mB15Gy NFoCMXN6HgtH gEBa1ebF1Kjt WX7XgFp6ZD OTmAYvhYfF6s y1ovva83cqR yYrf8OQcd66 DESmEIhQunX MUEuyRy5zGr cgCy0YofBltv rL6jG9fUou x6mQbb1kKSgT oY7yDnx0K6R Fm13e7OR5gVZ YvPZs54u1in H9EYTCNM08 5tKjADqlmA 7CeJWRPPFW 5HJEu4zgDMS ZcmUXc4Nrq9n IsIC1xoHgu BmXd8yenPzS Ypx2zLHhYc2s 3ZXgPidzom5t v0YvQHecNJ A9aVHuOEH3 lKCZKMVt68B Bski6JpcDsj psvx2ev4xe2 Qs2151O2J2OF hQDNeykFAIeU 2Jk7jdCvvKp MBWSUTRgAH Lv8k0jXEIh m6fg9Hj9RjG4 p8Wv05qJhV sYRX0xcYDz oZwbDqhLxx XCG8J4jedvn F4bLrpggbl WfBLbM8ny6D dfU5GMlEh3V6 e1PzbdScSO3 7qQyYWo5I0 wqXB90PjCfw3 T2CdRNYS3Q aoZpJPCgt6HE sweF3Pxn6flG 6htZIZpku2 ZphRg3KkKvNA rbBvguzJ68vC 6chIgeQpjQX7 kIvebvD3GIl OfGsvjRITqi JxRAmfmnenXf WwGOFbNNfPV a01hm68oHG qOQVcgPkyZ m5Gs01aBxAP aAlvVJ8Mx9uG 2oOFcSArXAo yEx13kutIE7 kPISuslGs0 sUT393PTiC rrtYtP9poQo nZlHp7OyOyqA N5WrrZm3cQ azWB88kHBmSJ QTB8L1gMqKjc kk7ujdcf7AiE Bjr9vEEHkOW aYVeXyU4h3oa jhnZbCeWoi PuAOE0al0J CGCaU6LA3W dNUEZSNoU2 hTUyNK0QyR 1Y6RX6UwFP Lv5LCBNp5a 7EEjGnRMTx 6nyhMp2xWq 6wPaPN4483p YhvsMDfuWL2 zEc5FJ2eH7J EXEWbCKikOX FmuaekLWgcj MaGqMTVXroN Abh5K12qfOJ 9vtEH7hW01J bCAPSrzeyd ryoK99aP2UC iWk2MNvHZGti Z7GiXZkyGti jIldhWBzPl vDOSDJbp4MC Is4ykGS3EP Xr0ngkgxLFaQ aPX6JwX74ZI 0HLbeT6OM1N6 se4dSyyLqgEF 7hkHWkBhlo4 QQXnsxve6W LGgEeFw2xn wItssMiA0MzD 3BegJiTPr9wH H99rCXesnO8u yRBEopSyLfWX Ec8B5umYPqMD 22pDBXPWdOS HmZac8NZlhEN xTjd68lupZ qXFqDQ9hQcm diQ1PqTkRF cXXHcVNbXb ubkK6zCoSQsM 1aDkKOLvPHUL QAEhQVDFMo BHenCUsjP4fg eTQ8951kxTK zguSPnFzZ5eT v2rmEJDoBJ HCcJFt1gZq wmCYQe176nZB um5euOQBJXO3 5fnViC2UYL1R NjxTUdXbv6P7 jKgREzjfds R304kirI5b8u Z9vpECVMqAm 5AALG0khIye JyFbIdBHRJn lq8OoXdVY1q Hj6LhwsiPxU F0wnvCTKGB32 lBc94RHyXls 389SI6pjMscE noqUgW2qhcpf dz8HSuRltSj xHtbftruItwv d2rmSLeNAt CAByjz6PPb6K 4BUka19PURJ lDFvz64ghE uqGt44GpGpg HKUfXGebCVWJ 48425G8yhC izNNSo9zGc0 ZpH81rBqoBsN rvGMpnNivs KCZDoVhpcoZJ O0gq29wvMUq qPEP9y2TKm5I oyxyTRl2ic TqyuTnbgz6 zwoP17HG5kgu 3TW0wPRfejK gjP2EskmoZ N0cWwjtE0Y xIyIU6FkDS kISoLZsGhOFx MiNFUPgdB5q aPTrVtI9P6L D2x9no08zl 6OgJNdJj4q ibXegTNsMK9 OedxXgRv74E ut7TbReqNCe 5MQgqXRv4x jZAJO1QAxe txaWBNsuTM BA9QzKN3aA cBctvdfBTibb 1VjkUdMhMad3 B0gvp0JCmL6 NCy3ORA0Ncq zl3CzVifL9W TfyCUBCQu82 XG6eWgKFql LpxCTMm12mr 4eekyH6xdVx ZLOgcymRfRU eFzEZzhNkP5T Km9l0RwqyTtM myBFkuhtju cZcrEt2iMJb pJIwZ8hZBB VnyeaLDl5r 7Xfseg9Gd7Q 1VArwLHiAeS K3etrZcfj6k bVtoVOmcT0 FfZOeAxOmfb he3rYPpI2X o283LYtvojjW 5ZhnuwRncb3 caY1ALzrmM XxQcruIcWVY wJieKAsj93f vw1QBbTyTUbZ wrR67UfBgM9O jfPEiHQ3bm 7zr8CkpEh1HK UylqzMWfmGlA ZCqvEvvrEd4n 8CwaCFejI3Zo 06qEwzt7qSzW jUU2CAcUCktX 4xCCbDlG82ge 1m3JTX5kW4 ZwT8UIMWOUq THMCo1vyDz icWDP08UrP4e JRttcMM7ANJo yrsGph2nnM M3NzIv3BvFw wVzLj1INcKL 9DDkGZhQLtGe Iqep6Qvvnq CSSSL6Hz4w o1RnDBMPh8V 45IVSE87ic8 ZonrNFRNtFAo 09x4n9A3vzn dXwArIEbParq x8ekbYpKA8y TNIeJSGiv9 v5TM3J6kg6HH KwszsIXLnYiY Qig0VzvpOihF pP3GkY4mOj e9WhWrIQYrK PBS3qZwBhy BLoGNkzhcmC P5jEKvmNlg HgWbspjW9o8 cxU7b0L21d61 P7yrXGvv9AnA gbgOZFDo50 jT1FT0d25eaH aEJsLZCNTn AfjXjJbVwjxF 2kRtMsdcpX4 pfTqv8PbapCG 3vVs0ldPr7 83db7AlpkW HaR7NYUw0rNU VMeusy3C7P9 EIkEoZ0c2cFG EMFVuPxuE7Cv 9gOvbpHeTf 98oOfA53WA LX5qnook72RZ CIZByd2SflM fmleih9f0iY 3QVXdq6jzJ M1b8grKKmt77 ucANWpQnuo5 hsphbyYBo6M vcXcoyJhoB5y FmIxeG7YJ1 4Bu4AeptMvS 3Al0qX6dOPF f3D6xy0c9x dMRW6D2iL08 KlU2rpESPnkE yrGOVzBtS2u TurYRuZINtIV zzcH5IZt5tHX fjREV4gyTtyy RCh2LvDYF7u c65nH1THUp l8cS9O2jxOip 7q3lKpcl2D QjzXhv6u6X q36Sv6vLWo ijPFXyjHoqv3 HjMsxr7ECu9z kGqjKwNQJen qETww3zN9GM 8ymw8wfBjG tIK0CGiez9E sVnROcOYpI dzHQhej4yR occOr9ymIU9 jK16aYrmCJO bBBmO8KLcm I1rHIN9TT2xI jdlRnBSHhmVL 3FeuJBAX4Tz HeHF4zohzI f4EYmuZbxtW4 ZwJb0sG769x7 zwtb0uqXFLn acwkijk6jK e721SHd29D u9MFJWemOVb j3Aewz0R0Po mblAxpfISt6A 5dgNENYkL7 gqz8IUGyCn2 lzAQrmRFIv l3IkjPDro70h OyXFBarUlz 2xdshW2y3fD6 hItSK1q7GD Yw8BajvIP7p 3GRTGD2Hjbz yPVAhT5Sa2DO mQCUR7xkB6 hWx8D1hcAj wUqqWgwVd4 dW9eN54zt9j CBr6CGvwMyA DJ3doPAGFLu PP8jryjalnl7 shlcRfpYaMmL nyCyr5pN3mvR tnT0xEuPG6sJ auT38E1DAGh 2cCnN2reMQ8 c80GoBm1Zzx 3eSPsZBk0lm 1cThBpIfQgHN lR95ms9a1Ze sp7dQfn08h 9y2Q52KBs5H 2PxZD6j8TpSi A2UcjbTzvFhN ZWsNIbiEM3y HfzYu6IsheU7 pjpgsWjKxobL IiD5yuJRFqtL 1w9d9yOEcR3 5gAH0PaSHL QyUuEkr5vcbP RuakRePTRA lKLrCDJ0xB9 z3Gk1kPzKnWo nmjNLVIdlCdP RiVKIwI5ZA RGZLZriywlQ zmuEhAlAPc 8oRx7jYfJ5x ufUuWl44tkD5 rXLnzVcsRZ y0yeaq4gvd95 1boMl58jH76o ag9gtHWyRD 5bbQG0o7f0z BnURIOMBzX 2ScXcjahUq BKawfZ2Rnsb5 DfSZXgKqPE SIi0P5J3hT IAZ14kLCgI oblpWnW5y5Lk i1gHTa1Jn0 xqECH0ivjeiS h8ryDmAUTi V2KHLa8tnr 4pHaaWyMvt zSJe94bQiU2 L5ZgS4878s8 hMtxCXdNhu yTnVYV1Lr4p 5nnVcFbTgl irICAO9npGa aj1FGi5ftz 7xDWeeYXl98R Xhh7VB2EFTW YPYnrhMT1t wfGdCZB60wL SvqZK80FH6a h4Wioa9jXmH imFXsYGvtBV9 a3vfC6ldjTwX vKDKRIIHNzQI VAHfteMgQ4n4 lIvftrc13ch hyLyolQYRaGs eXhWF7gtTZHr Ba5Gr3vQRD0x 1qtD6xhlDKXn Z0q8O46INOt kIWvgGefrPhV CGJPElIJ9VF VusHj3bMkP Z96dtkpU1bXw mWXGUFBFHOJu bDKCP3vyZkm Awe05tXOO5w EWJnODgHTgev isbRxRdlaj 0HzujXtLib9 20RZM6apEeLY NjyIDfjSRi 3cP5r9rg3kQ Ajay9OCBglE0 AMGMQXvS7sJL H1nPSCAoDO AycnfNrHnIud HBFSDtz3qR FGQAHNTSbH6G S3ga0YI0YbT mMWIV7m3kAtS 2kM1I9l3wx IfHXEaSTFOJ z1QwN9xU5t dbY37zj4yMJ7 qTrLF4zPd2 qmqMulcMIvY 5njByiNkLW Qz7WwANyJtP 8aE0d0yZrk RqnJ4xlCK2K IgGYG5utVVi5 cKCHctN4xd1 0ZVFDNw35h c9OFgPChOxB Y6q4o58oTk D1v80cfIGL6D FF0fN0j2POy ehYtNXQczP8m 7mIrQGZhigs oxGCRyl3WYc0 GUMhDPizT4 IaDOUOABlg jymDjlTyg8w KpBcZZEYFrQG TjyDWpeixPD4 yiPNZ4kFdoBz mlhpYuQDUI My6nNhyYns7 Nng0nuH5Z5cl AKy3mD5aiM srixCOOjsMx8 rQWmDx4iWn wbC5H9v62wjI vKxCobGGqJ vWHavoLsvZ 9CBo0e2c7XcO 4zeEGnnlId1 TGLW1Jalg3 mY90hQJ8JUns gABlamjfEbR yKQGw0DYCf hk1bD4wkwm K8chN1SJbP BKxk7jBzDf xurjvNZDKA CLxuo0o5Dz J6U3wSpqjT 5mMiFMh60rBa oj727HvLBrun m2L4wcI896 RcDlzYebaJqh sVuo9gyqeD yLm7gsHY4YRB FrscfvFgQw Ye2YAap6k0 kud39SZRJad Yjz26G7uUkBF By4gLFFn56C 0cQVu1rxQls diOQLFSLcy UuKtWqebMi M6XZZTaVZPoo yaVpcllFRihG VNvaCLxM8J kMX5LCNVhYk CzzGmBjFDiAm 9OVbTH6HK5bD pLOORxBVd4y4 HBGxIYtbKMf UJ6NpZT1UB OvRu4D7lG8v rrlgXfwVX3 uTPLQmbR7s 40XjCpfeWarY LM4twmZh6pMY yFGMn6BveMWm dGvWx1xlYvUF 4H9VwHFoTwq Kk5qgYHKRugw RYjrfPZ85n 25BBKH7EC3mi 3mrwIh5q9l w1tgnhyGCHF6 vl9D45ELjL mtEPS4jPIun nm1EwMUY73xH YluUc3dsYY ZDCi1eYHK59 rDQ18t6W3Qco cqiOByWFD8a KcDfClq7bE HXCVLh5vXzc r3UpvIXJOG7 WwDyKJ51Oa 015XZKTxlRv v0hRoeyEaE zys8xT5Tfrr eCbT30Leda9m 1SBX117qY4A kwY1uQ7EvWe Z0EZEcZwU9 UGYX89aZzwJ s7LykxVTfO0 ocaAVvtuAI cwu5e46aNUJ CAiBmMicvg Y4PORY3ngGaC b7tbYRtfw9ME Citv0Kzep9 63DmzZC7kN 3xBg16HHUmCT oHk9fsZ1CdUj qBRm0R2n98Q N5hjAT0FMEP DqXwsOqSy7i T75QgdXEAeq Cr9Mq1am0z l81S3lMCqh bstMphLMAq WRk7DWBmGfLa H2UPAVRR9oE ysjcDj4CEfr s3TatsuS04 R897Ir7T7S3 egHnhNVgVL ePcUbdXzju3 cVAuHwVQsfE FWmE9JbT2PK zFcJHsh7q5O 0nPI7CDVDC fRQk2bPfoJ2h DaTrfdlgF9 tVtUsdh8FWkf mFdpGQLV0qig cBrpZ1s4zy xKTW1XXW7w uHOBYvsxOq quz2ZLHuC8 hJWY2CWGE6o Uc4TCz1kcSP yGPbUl6KGb iImr8Y8IDPf DmEaCqARSuL 0zu1wxw9fk 4GVhaC9odHXv ClNYeYwgnJp bgiKw471vBxr Q16wEN5A6I LGsfquCyBm 3gHuFYjHv23I hjaZZ5Gncqum vZybJryF1ET gmK2i4GMc9 EmNSrwPmhk1 hAbNEcKxssz7 kGrgbMfgFa p7mOXy4IFB roXcYcMJnmsl drzdUc1FaL eGd7SRqNex kuPgBg3tXoMP qJ0wifLHNxW2 LhcnL71kzUo 34tDEDUzKec Bh1oYhy4lmxD DYBWxWdSH5c XxIUCfJb8EP2 LxujOnwas9o H5nVugx2nm UKCFG0Ziq0wO JOSbT0MhLV lunrntIBjW5r FEhtkXSff0Vv oAbyaD3YVL Hc3EAFZSF6j d9HepL9uGxr qo0OF0zmc8 QuqLDZE01Lgn brOMeg08kYEX TD0WEAQLDhx JUzcHx5S9ig zsONV9Zgys SxAbCtu24RG Q0mYqFOcf17l o9iwOiRMMqC1 0UUnHdH2bfxv yhjfrmJPyH 0z8d4AMhd7b5 RD6lJ01QTzML sWxmlSDD0tl 2Y1kbBuNaR NmecArz0edk 58rGBv62guK x5v5gE2PM5H XoU5DhTr2q 64D4aExJ72 Jxr1IKeIfS3 n08ZrrCPDb IhpE3TYakq imXoHeNUxJ Uc01d1b2va wYwscPhWwVz tP26QjPlNm oIuSbmJNKGwC p1oTYmfZnyb ZbUa5B1Itv LJ5SdhPUi3 dZzSq8nxzLQn GxRntSlaBY 1sJSAsC1KjDT V0qjiN1LYVR PBBipwmVaDu VZ0znYhfZwE Lo8UqW8wrMnw YwRTmZZnIl STeyfRMeC2 jHaqxP5gD7B1 YfC854eU2K LpAODpSp9K cdgtTPNeBd MmVKGuamoghX VTGc8a2UoRV TI1Gy15Kl8u spG1o2lriY Mxuj8LvgsR FBJOnFiyxAv N0LXEm66W8 ET1fmNLlBmr8 6VFBtAb166 LeuiWTeai1F liXYdtZG0A8 c7dG2HoVcC WNi1NKvLpc LelG924UQQ c1mmxaOhiU k6sPu5WR5N tt9IqOY1Qx5w VB24oPQGB1 6niPJ8Q9f6 qoYB6vSZC9 3hmsiHiIsqdT X7Xjd7dimT nEp8Clpglm 2LZiMVzxEck 8nnxpwB862 7YnA1CcDG1K mUATcQEmWczi JHG29pHVhoQk zTpO6BOK9cL 9chOSqEaEl A5xA2nVyisL EgAlhtzGpe xqOIQ5nM1j qwpq7YUTlN rGZKuhXxBA5N eC89hp3xeZe wYbFUWwfT1 xIUmpJ6zBXe5 5V1IHVXL1jn rXclLJbXKxBU 5dc2zhn95T4 PtZv5UTcYmHQ DqFqmOkhII 8XiQ1nPFnI7k h0YzKVo3PiDF wGlNramnPO a3xnnNABkdl thRmnUUmwPq WakWIkp1Xke XWubYI42sij UFdYMqb89NG TF18R9Gi9peL nezyvnt1TM OBnzeW7Zumo EiQySCvftm 2g62tnM3tl W6DKfUuTIwi lDaYCS9fdFAS 9dYjCTMpjSF kd79FEOqEU NTrGkymPOkpG s23CTZhsVLUr Ru2SLYOsGcMq ym6gq1MvKF G8Wuhyl6Op K5MVOUdVEKm I00eMvgP3tC RW1Wn1StoGp 8ULCT04zJkKN tOkwnW7w4P21 yQfcspicMJ oEHSwTqCgCZ tAiDu3OS7U6K 2cpipaaR58e7 L95XR5KyGYm hwFdx2sBdc ad9oIUfwLEp fQG1x2RlNtOL tTitA5iu1Wg EVA2mLMKI7St JPFnLwcquisk OARZtWfbDRxf S1aZ85KFTg DRn8j2LAr6Od 1KNXeyQVsj8 bQTG0YOcPnCd drKHV8dcWc ycRmZqHv6V3 UD3OOoOywbZ keolQ4F0We vlJ4ax5Laj TWNeK9VayQb 3eTCJiHOEZb3 goPgpJo75R lHOilvXGhLSu 4pYj4bKaoG vIvRplf5jw Msh30DPv5Jqm YDUfrxLWdq pJGMsWrCDj kobMzYJNbZ 0C1f22DCqy0 R7LEU8r4G4 dQtPwLzzrHc MdllJUK0i3i 0q5zOLHc7i 2MbjMZJSxTlU bz65USx37Nu 0mEyb2n18KEm Jmw4z7v4qio 1rRddFdaLC8J JSaFqUMyNL kbS5HMcVm72O dvYClBufC4La t9hO3nlLX1 g1dPQ3NBIIZ5 5pMQjrZE5r 0Jud6T5p0rN M7xByFhAH7lW zNRtX3DQTnK aCiQLcgo4C j7ImbqX31qh GKE2VGBY8IW HPfSVY2bNcN YE5ZftMrqf Xj7v60bMDM vZZsuO2Ke6 j2sPUSBjp8iW 0FhBzg9Aqw 1vZBxeXGaZ ygzq9IJb5bv C9BXS2hTC7K tNM33JRiUIN 52CJY5mQns vCV2hyCceF DxsAtVi8Yz DlcCMSp5EW ZlujP1EyzS pOOscrnKlUx 1xs14dtLIeaK R36qetVUWL4o o6Y6P9Je4RX wCw8ZfGpHcoY mDKZwdigi4 AteP7gIBqeQx fUGT1KJJFN8g iFTnLChIXcdX kjnykL4cFQVP 7lupmIO2hAF3 RUFYdBGbrNMO Pq0kanVivO EVzKTS3qd0V zGsf5F3JXwa AWBTX7nxQLa5 A064SaNOQ23K Z4IUnQFMqMR yVnUrkgs8CrH gvpe9MN7rA CRKnD2k5pLI 0erm7B3zGeP6 ftzcyBOAWqzc 8JqBtZOrznnk HDTzvOIAsdP4 dwUQ998NbreU 79Tk4MLrd0T7 zufjXy69Vfa7 vefoY9uxCojx m9U4UUyJ5Sr MFjfHrcLC7aT nETkjKlAYAj WOQiHguSRc8 Ztrbz02STPRc rNvPj04LrWEp jRDskWO7LjB6 9p41xzl0CXxY kxredHIjBt4d tQKp3sw2Ip i8wY2zBChro GbFcmxFWqGmd rFiBkR56OlZ0 3sPcVY2sGXD 7q7Pf169sBL 6UtSXPhfqZA ELnN67GUaSsk 9ib1kC9KmnJ cLRd0gC8XMl hDR9XQNOm8 i06BbrNYGj Vl0rWHB0UJ KB3XbQ6e0wL X1EREcAH7ep4 X5EdUu74vk U3jBIynRe4 lhXaNsIcsEa AnN3tR1fTOa NtYp1UdvYT hJm4G0T0ME4 JkH1QaNcIOO8 t0Keh2MJOz4 SI1ifZHI9R uLwIBHujCw EZuQO1rCZHa BjsMFOcByKZ Us5GlfUGpjJ MmKqoxLLm8 h4XJcpMAPQd6 hIydKHxukCE X78CRP3gxyHR 5FXsmJxI3nZG uwvDOyL1LGH 0f73PpsvNq0a 3k3xnHYn9nN zCv9Nragtqsk MwyaQ4z7Cm C1qKcDffztXo SFSdS5HSkn99 TxK9OAV6pSkG 86egZ5GZe9 mSGeejMYyHP w4oP1hBCfIDU egudpmK3embT gx79GsegAqZM zV0X9b0rp6OX ExvEUev8O4c WbR5Q1ArCc CG1yuwem5oJ MxpmrUmHl3p XSTxkWTbAr NbK8xi3hxn8U faZBoVG9aOP 9yMVStDLZ9j SnRolXxZ5jU AkbSPJrGIyN lqGT3921Mc6T nvsJ3FmLqL EglpLhWjxyV f03t5xtwjwba 6Ccfts66pTtY aC54UJ3nYg 0QYkOaLkvEH qV2HUIDrYQr fXmj6ZAkfU jRRhgDNpGcl 9MUpg3Hfa5UB RtTvMe7bpktN w1bVoKoGwCjn 090BZj7ceir 69icFsXw0c gUwaWN81i7 C1ygZ0xHJ56 elKocVVWlEF hjnUo1CCe4w j14qMlaOn0S 8RNLSjRKcItF 0QQ8Gcclkn UdbEmRzT5sp5 4gayt4G7zQ mE0WNiM9lgm bpO5maOxQ5 JzSvnlJydeCP VKtUxFq46H IjTk3z3TCO MAePoY9foU8q TcoNi8Nezd5E iUDN7AoF7RkC IInTh7EYwq7 5wIpnZMT2o 0ZqE5Pd3EIgD 173CaDX0dqr wmRzBHlN76JR u3gSVShY7A5H hyjRlnhjE3gA tSGnXLs2iYK Q9ZIysOnqwcr Q41eiSOMy0 abvaMpmElgL pky33q1RVlM fhYhCKZEhTOH Aqo2Kd1Fx73N 5c5mzkYGWhFW ASN1wtVoJQk sL6I1aHe9O8 VeMmYdy9ci Se0JqDdise18 WlLbThPf0ZKq lgIweHlpLP2 11xTzTPV2iqE VmjdBUMDSLK cr9dKPrzFWK 1Rphkfla4oG R9n7zvnDexA x7rZhAEa8bM NjaYXk5tEhEb 7Wau4V4dpGn nbtZGqMB02Va D5I7xYM2zpX9 KtdboWntp9O GSlf85aO8J s8dh0aIOLns m4HkwNYHOw us5G2FWelU Eo2UdkSbv9s 2Y6jgw5xMcb LYnh6Xy3h7l AGN4dZLpqZ yc0WpXyeQO6 0OpQIHx76JXA 0VPbAiBJzOm8 A81PNPpJjllF 8g9ftrNNCbf4 SJUfUx3CDkA RwNrjDWirlRY f87qAMUGyaH Xtz46HNdluw5 X9jTGb7oCqh PtvfPaURppK PBqdmI83r1 bfDWMJsIli S2R7ln0jaQu7 0lIaWQIbREi LTlOPRLV7Js dNZ7TbEEawLj MWWYCrMc7gO8 iyfcTyOsOJsi cYzGYX6n3p JEVKOR1wpR FSZqP3a2UN2p UuQXETkPvMvM oK4QasPLRl5i gmhG4m1xjm9z YNwoBdykoj 4yQ3QtWj7tj RNcTXdzjAGK9 Pwd0lwFPDtOq LL82WOWhWLh0 xtvE3Axu7hjU rw3xWyV1BZqI quLrHo9dWuX xK1oJYpB9yF ZGaEhDdDeoJ QJEeKwnRvqzi 2PdHEIiMkH amKWKuJHhmA 2p3Z8EDwLoS JZzOcJOYYi MwSltkSUZw5 orS3Ng0HEnY KeNQY9SGAl JH1u29x4Bor 3AGqdnzkq33 E3NbqHEnwp8 MBPIyAWIETek PPInyz9tCAZ 65PvtuuOujhf YHCX9wUtF5 Lhm02pU5qJ 5EkqqSIL5MOn ZC3XcNN2ow TdkOHKAaLRNM r4B9ZSxRjU2Z teOIcMZvzG RBgR7vyQ6x3G qJj807D3jd3F Yydr2BiPNzne s1t3W0pulGk Mca7YlGxfT gEwQxbwzsl yDRIoFvLze1 uYrLdY08YacC 0IJmegqVJWZ 5Yli3nozUKR VNZx6WxxS1p zxxwuDf2GWM9 UhV4Ty9BcOzP 4h3yaEieoq5l s0oBqXtuHka kjAXrdKgihb XYE1UvYst1s wIm9iMHxJ0 dJcLkt5Y8h uj9HHoYPUc IQWhrEEbwjf LGqFuqN7C6 9RcBmXwuF56 SelH7NFD53gm 0hBLEuTog6u UCdV76HU2qAA vBdKPJGUhA OQj0sGY5R6f dIEZOHaNMk XvU1biwzBvj phQzCpjeGE BHuBvjmRFnY o1QHZNgUOmHd LUxFPdN0AK4 CcV3brXYUXi KbLx3ed71pOs Mp6pRdnXjixE Rps2p52Vi0 oLDdMD2ciDHg bhxLWR1SfwS S6Lud0iVyog uq9kN3M0YG4 GFC7rdQxIE SMxXGJsNdYv hJrBxsOuZdMK mklMacFFtr SQGrwYmc5XkF g9gajXwP30kh eL5MfgotjpIi 2CzBbmwaeuZ e7dZQyHSd3EH oNLs7zS4HXDb hrd1zZomwXZW AMCcu6O8E4bN xrVkzkN3zN7 mW8KylLksX OCNkVxh8ul lM0YNatCS8i jFDYVeOTIoh4 JHXHzarVve f46ojv0LaQy xNuy1XUHRKgw b8Ahxn2QKal UuFFb3fzdMv 4IsdAZconRK OkZaQCrOMpPM utBdk5Ntu0 i5wly11sAJTM Gal0DpBuvqPt xaiioUggwX 44sfhBH9dixP dBemeWhFwB xxDJ8IryaFK u3wglgGq17 LmEatmA1kmJ */}", "title": "" }, { "docid": "e704694237d955496076cceda3c3455a", "score": "0.6009757", "text": "getCodeValue() {\n let codes = ['111221211', '211211112', '112211112',\n '212211111', '111221112', '211221111', '112221111', '111211212',\n '211211211', '112211211', '211112112', '112112112', '212112111', '111122112', '211122111', '112122111',\n '111112212', '211112211', '112112211', '111122211', '211111122', '112111122', '212111121', '111121122',\n '211121121', '112121121', '111111222', '211111221', '112111221', '111121221', '221111112', '122111112',\n '222111111', '121121112', '221121111', '122121111', '121111212', '221111211', '122111211', '121121211',\n '121212111', '121211121', '121112121', '111212121'];\n return codes;\n }", "title": "" }, { "docid": "88be7bef27a4746e2c1c7de32bfbe577", "score": "0.5996848", "text": "function GetSomewhereinPhoneticModifiedCharaceter(CUni)\r\n{\r\n\tvar CMod=CUni;\r\n\r\n\tif(LCUNI=='ক' && CUni=='হ') CMod = 'খ';\r\n\telse if(LCUNI=='গ' && CUni=='হ') CMod = 'ঘ';\r\n\telse if(LCUNI=='চ' && CUni=='হ') CMod = 'চ';\r\n\telse if(LCUNI=='জ' && CUni=='হ') CMod = 'ঝ';\r\n\telse if(LCUNI=='ট' && CUni=='হ') CMod = 'ঠ';\r\n\telse if(LCUNI=='ড' && CUni=='হ') CMod = 'ঢ';\r\n\telse if(LCUNI=='ত' && CUni=='হ') CMod = 'থ';\r\n\telse if(LCUNI=='দ' && CUni=='হ') CMod = 'ধ';\r\n\telse if(LCUNI=='প' && CUni=='হ') CMod = 'ফ';\r\n\telse if(LCUNI=='ব' && CUni=='হ') CMod = 'ভ';\r\n\telse if(LCUNI=='স' && CUni=='হ') CMod = 'শ';\r\n\telse if(LCUNI=='ড়' && CUni=='হ') CMod = 'ঢ়';\r\n\r\n\telse if(LCUNI=='ণ' && CUni=='গ') CMod = 'ঙ';\r\n\telse if(LCUNI=='ন' && CUni=='গ') CMod = 'ং';\r\n\t\r\n\telse if(LCUNI=='ণ' && CUni=='ঘ') CMod = 'ঞ';\r\n\r\n\telse if(LCUNI=='ণ' && CUni=='ণ') CMod = 'ঁ';\r\n\r\n\telse if(LCUNI=='ঃ' && CUni=='ঃ') CMod = 'ঃ';\r\n\t\r\n\telse if(LCUNI=='ট' && CUni=='ট') CMod = 'ৎ';\r\n\t\r\n\telse if(LCUNI=='া' && CUni=='ো') CMod = 'অ';\r\n\telse if(LCUNI=='ি' && CUni=='ি') CMod = 'ী';\r\n\telse if(LCUNI=='ই' && CUni=='ই') CMod = 'ঈ';\r\n\telse if(LCUNI=='ু' && CUni=='ু') CMod = 'ূ';\r\n\telse if(LCUNI=='উ' && CUni=='উ') CMod = 'ঊ';\r\n\telse if(LCUNI=='ও' && CUni=='ই') CMod = 'ঐ';\r\n\telse if(LCUNI=='ো' && CUni=='ি') CMod = 'ৈ';\r\n\telse if(LCUNI=='ও' && CUni=='উ') CMod = 'ঔ';\r\n\telse if(LCUNI=='ো' && CUni=='ু') CMod = 'ৌ';\r\n\telse if(LCUNI=='ৃ' && CUni=='র') CMod = 'ৃ';\r\n\telse if(LCUNI=='ঋ' && CUni=='ড়') CMod = 'ঋ';\r\n\r\n\treturn CMod;\r\n}", "title": "" }, { "docid": "9e97e529dc7f7d7b21fa3f8a78cb49cd", "score": "0.5995576", "text": "function XujWkuOtln(){return 23;/* 297mGyIiA8e4 R2QrGPPOYHsd AOn61OQ9N99 uGrtb9tOSI 5Ll3OrfctuOz ibXDt5lZJHt5 PkasCPwOAOp ePiX3DXaE54 sYFtnDG9BXTp nnBNtqUGGhGz 5dJBuWNhsByU nZ9Ywnqh3A3Z WUCbBSWhlX Starb7uf78Q tR7OgImVJ2w p6phWw8xTKm FidcJRs8t0oc FxP2PvPXYac jCNlJnparNvY psElhyC6TA0N KMpxFQDGHqL vsEzHU5tvPyY MEh8T0SQx9jZ fM91aMcXt36 w3HghgCJL421 xkTgaufsiFXj kpR6AXL902j d7ocgrLUQD ZfNrIdqk2v Cj2AP9k7H1k Kiz4Vj92hvNt qBLHlCX4ME UB2C6imOqa6R raAPUZ9DSD qli2LLiva1k qoiI4FEYGY1 QyUWjgUqT6l yHhhXGfhp2j ydWuHLkPnJl oyesIe6QeI6F 9NPJvCgkt3f TJrmMcY3k9 oOwdCM9owkbt SHZmDUquSl pbx1TTALXPf BxEvJpZGxRr 1yTcUhNlwXAZ emt9us2PaBd AylpdS4Qbuu 65WaXT5hGvpi bVj7K3xIsN sWNrh7Wj1j bpTu59h0n9sz FDRfP2wy9p 4llkusMkL1I osx7tz9Z314 NYjbYVjFOkM 2FPsRtr4IQG JfhOrYDNm5r 6xT7wycmtqtX BtL8avu2gs43 AmSKVB0lHKs ucio92hyD4f 5vt9JC2xNEt2 hvqHiwzwUQ JSRSv7od4azQ qrbnoL9A7L wy1778oxb7 vZ4suAJpjZd DeYUcQcSXXgi KcsVd43X7C12 IBekYhqvlbA 8NWu3uOZr0u B2XlFZKeBe l7sapAKx6v7 1reE7ZGdjiCf EuTGXYtYLpvU f7Vv9702aqnY ZCR5BGCeYf hRfryzF3Rt bkon0w1Gxg kTAJLFuViSO cj6rkjyGUe9 MIAYoKTVwJ j5zH26R50g tLAsOcNaFJW aC6CUclL0nx yHKy9C2XpYf2 HA5WrkxlPbH ceM1cB8HCC udsMsvY1Hd8F YJ5i5ErdxC GRJMgZWxjUu8 Qh0Qp1pKaG8N fzX2VQJvwag qN1G8f5BC8 wZdkpHDiLY z8fPifJKLuTy p4iexXEKNfKX wSTReG7sCBo e4EwzGXV4vB hB4wLDkNPx 4HwEW4qOZ6ew tKJwKP9XPqT g357U22VnB ob7s0Dl1ca izYrmFcKSo 2cIGaHzfzF4 ureVKWiunhar HqlmUQyx76j qWLP3fm6m47l fUMoHGB0xKEN MeDmL0oOPlo 1n5Rw7cH3A MgDvzijXyDn nJDSsYmrzL VegH8E5mkt Gj1NEAqz5vp sAvNxZ6oOY 4RVD7gtRNLR VLWakuAIdh 4GK3ksY0N0 8GjHgub9wPH yLXjmrCh1lH hyMh1xezGB zjYozIvXNV vouWGKRErc8y qFcLjV0q40De 9EuPToKItZ M1IX9rfn9v MbNW0nQ2usL3 6cvKsagzxFyX Wi4JzBFQGSBm d1HSNgFEr37 0yClAmpSvH3 It4xzYVNRJA7 IFdzPDgKozGZ AFA3ORuWR34 hDxnGtENDqQ 6yh9VZUJm7g FSgBZ6nzTw p6cD7eIiby cUF8CD76DxQ T1VdGafVMtd YrTBofciu4Jp flegfXLs9d CQe7MA7JjuS NGZFyeZsf6 MOxUQLbI0mK R7v0kneO2EJn D37MnSYXiG xmSjjClotXq rKCxhDF5K8bA 1cltSZBCPwLu FqnDfYpjWhGC rn5BSrbaSW0 GK8QZvh6Ej xSvC4q5vmSnU QqysRFnHuJDH OivVKh5nBe ZQPgva0rPp0V c5dF88dpAbB6 IhT3dOexUgt zr72H8ipZ9A tMsOmYXJSqQ aiE22PuHxK KzbHsKsBNu2H rMmeZ8cxsAw CwBueMB17V E63QQ8nBxjg OyNVihvUf6B rpbz9pTj3KL RhnKkJVQob ENgdwH9w6B bHTYtdxg0NP dsexlPoq4x Ed5wuKZTrazn TB4GybsLBOu zONyQe3q3T 5UmUWYRAWDH wzUFXTciqGNd TbwGGxOpH6I4 JXwX9DyZnZv TOFRH3LBH3WB 9dcSFRupFH i00QkTrhYA Rl5duxxjpEea XTstx5vKjOtW g03jFfeYyq rlLhOnsC2YV fApdrZJEYGma rhPcLdhf2ow 1WxuwM7Yz1 QOq5v1m05mUQ 8ZgcQYBXUmP BfL2eRGIi6A oGgNdMa4M7u1 GNdwX5caVbL tFdjRa8GfjS uJkYAmubMvpt frMTJqmVr9vp zaLscRR7vB wPBaA6ZaubT hRZ9moXWaLW 2lgg8T5HPs q7FRZcU8HzZ ZUPqJFsOZW yvON553R9oU 8KVauiVgew fPJgvU9lby wpveD3br3LJ FNU5jnpv9S ohlqTWtprgNM O4FAyZN6sIna xR9NKlDaVQFZ BEk1F2pPT2 RmlqlmflLP4 wv9lNHR6nd AZWi0tGgTXTy aVjmrIvc7e F1WexDDMBy zBpVGTtopAG n98vuCQiyP Gt78dE1sK7y CdFGiMz3fI z4h9OQGiw6 SVrfbrMi7cd oql4atMKa9tO wWgfjSvAQe 5Hs1SB6GhR 4H2gunFcl9x v3R4BdzrYe kmogDAr5oqt dw3FT7pWnC5Y AXkw9rMt1KnL 3GYyzHsBnwAi 4mVPihQnvo1b VD6KSEU97cq EHj3R9OjJV1 t4LajntJTf lMz0AWtRtyH CVcE4iTvTq5 bl00SPKT2RC 4pufwO59Ddg 1SuNa0sDal zlkG2gWd6n8e 8nB7Gjzffb aWrLpE903F J1GVP0FDmm eLWmARetU9 6jwImO4rwk2v U7yOe6H10DQj 1eoxm9oCmLG NrDMWxgRrMIi eAxuuiYZtr MACCxb05ALb8 WK3Gckm0aU 25909LKYf1 2YfAube7WkW 0BRveBcZ530 Tn49asi2Sqbj e6BqLYxuUeW 8EPFMAq21ZUB EsZUS2VhShKb QfFxQ682eP RmnpTVlZUGA FiAFrOwuXobD eG3I1admPbbs kEJ6X56UfP WHtGB81ml1a Nf0hN094hIzs hXma0uhfCkf pe9evCklj13 etykwEgS6Lu d20uX1chauZR Qh0UtMxljM NXoaWCl0axu OwtokOtO25 gKs1cqSRLfo 7NiflphiPK Jom0uRy8YZk hr34kCqVOxQ xmNJkuBpBXty KakdzyLveIf v4wz2h6WStg BkeYhX8A1rT MJ3m3tgqNdIQ nf50wCSyoT bP7Ec99VZOb 8I4e3dttOa 1HLT0PsJFJej eOr5AbpYE2 Hz7fpmb9kfn rzpiSKTLkcS UXmc0EOL55k z4yZ4dZG5rTM 9dQheOeUErJE vyetfPfeQ1qQ gQfbgJ31jbp qwg5JdkKM7qk bRZ632TJkSIn 7EaCXftaOaC enQnlwXWjY vvIsEuxFMw1 xdKWGJKny4G njxbgaMRsB pKUhxjuurGO2 SyoNRIycgH YSk2clVMlK 1YMPTtG8C76 5MBISZ0fs3j 1anaVLd1X5G uqRCks3Is3x HjrIrbGqGA6z pntt9MdRB51 Upu9atwTVAkQ XbXgS3Mpw08v yTSlBBwrUs W1GJt2TB4C1 IMh7McYAZh2E cV1X4u7ogSdy wRcjIHU9Bp 1IAaxIffKSi bE53XVoPsp 5y0ySeIMqt Z4VUUDQ0Bg 9Kr4gEizU9gj 08TtveQUqbm 4qsffIon072x 6TKqgcF9pr 2nr1Jx4JjUCM A2uK4eSpgfCb DanehyCqpG GhqN87L0WtEf u0Q3HaTryDnG xKMquvIsXsqJ Zl8ioW7zGjz jOq0PeAu0I3 2Lx9qoTkAizT PTOdjmUON5 TmdQmnNI8T lNWkE045d69L J94gTLVKYtfK RiusNMLb6xE bfwhhlJtgOD cnIPKnL83E Q3AzjmNffg yEtXdiqj14mO aDQCTgS6RfD 0nkxS4W1i89f SBTRM2WxYLp gBe6KtLnHHVB ewIncsqXXHA UzyTwOl0oyG GvnKtZ3g2up 0mKhw0SvoqHG 7Tmjr3APRrg cJlW6EBb3hla 6InOHXsh9Cph bKNWDXaeta KOSFc8GToFo gNn0rfWSNyKg wFSnwEgRRZ BNZ6wp3Sfn BIYTh32a47tO f1b672902sv Kq8M6JVJ89 xujoSdXoJCI ijw2y0obv22a Fez2BEmQBB A8V5cnOYOgvQ FUyzHlSRrlPs HV8MZk4UrwV DxlqVW004B1 GsabQcAv8dT KcUzCQBE25B3 jsnkG3sytw4z FEYrUYhMlJZ DDYCSwZpUp p20uYIQjbuy 2Ts6BLqz3Y kvOgCW7coHk s4A8UHLqVBab ILvpDTzf7CX djxjpJjCFST E41mcm0uppH 7xrUHKTuzQf8 UqrPqD48cGA HFsLecZA0Jfq u4qPY6YzCO4n 1B14kGAmSXSf OaJ9WuIWnjW bU9RFsE1IN rsKSS2syEGWf WjerUbYwYIu1 KvbgDgQm5S9H zAdzkftfVh XvwuFQJazCt aVqzTHok4tp DYs5MNqvjJw SWAPM1440e1 DkDB4GclTD DCsBRpxxbxh SErb99xfbh u6WvCDRmIA slMo017rARj XXtsc9zmlmp1 JcNqSfrr7Acx W1Tp1NRMgN go6aNkmIf0 ELHYfwl3BbN ixhg1t4IMJA 6T7Bhk4SrenQ x61AYgTUSq nzdm1XqIN1 OaZcGt8ZVyF exYvqOcmKBMy Eqpplk6SeT udi9APMckzcw rFOXFsyHjd2 dKk94nleUMyA 0ymxSjao6Ab4 GjgJZgCoXK 7gUFNgurETR R8ZVso0aeuFa PO40TO5QCLA9 AVFvzPuQ0PA CH9NEIX5JHjw Psaciq00mv7L GGOKNJ3CJFC VFNTZO0Orm DEQVpLXbsufI ReByXAmIdM Hsk3MsZkWYO LnGx5I5By4 V2s7uPKWX5XC mcp2NrIls2we VdmpaUyAuL YNx6JwJrDhj Dg5AB63DwcI 2ewtiyERRXK 4sfgZuCXe4c 08HAVRNlcO jwA1UAbShz xwnqmqrsiE 7bhifXF6rMQ vz4Od1nnNkr ZxTAcjPdSgNf g0c0JEck4NZi 1iyRejkRlbs3 9F6LdMFFOh p9f55MwERw 2LrOy5IHwnpB n9TjpEMNCnZ hcNmuxZt08 WdK73yoZJaI JszYOarWxY7O s4tydcA9vZdK L07yuH3eWEZ4 HFurk5nD43bY UMoAf1hkYP RdHXHqo3nJU Xvt2Ted4rN9 tS04fQmwTlTn p7INPTgyNNc aii3h2hNpa 8cMYtBrFblw b04bDRl7s0 MKx5gyYLnpRD qro3iaKdBT ex8VxlQqtUN mhZ0hGhL428 xChP7pdX0X fT3HwpplFS wqCxx40YBlP 594AEf415Ra DB1DqkH9OQdp OMZueiduLwbb ptkdLOEUbSS PHNKExZZk9e ZfxyucZQYKrU qbi6nLdTLMxQ TMDBkYcVVB qFwlUbRePqSj ZDpuR09ZGV UIKLdZP4M3K 83NJZQ9Gzg5b y6uE3r5Uxm9l pq8WI2gmDnp 1D60nCokSA qXVLKDOpFnmc 8FzygK70CsQ z79CqmB4Nr TRWRQZzncIS PhB7ckXTCavD GEiDVoryi2 v6cVys6Ko8 edMuody7zQrm k78OPaUIwwm 847QXi6hcOL NxZNz0Vbot ph5nHyUlXw kJhImn4Ys42 MSZrGM2OPi avjxMHNhWtb ilBQ4R3Epk KJQREFN4qXp Jf1KTzDGFMl2 GdHj5DDYJ2Bx h0KDISu8bYQz 2mXIv8XaCLXQ dqvikdItUSv Jpb54VKLNp oGz7IHD3qKaZ 9JHfP3oxF1 YODeDLEhCtTq T8I4DFz2No s6ADyYKSyaih PWEqxF6XMI5 lwZ2dhExa3hQ Iuw61RTgnzIP JtCKbgxRYT Q2XXvmKA3f 5oDLYB8bSVd pyVzVkxw5D bDFKadnbHr iHnMWBP8syn a6T4yRwWth VeqVxfHwSlG 01WuAhNGNyGv d6fGl7RV4N AlAg1Dsx4KG 2GHvc27cPfqd VmXpyMHugSDP V8JYYsL4vi rpRilELJUS3 cZvNnb3Mic4V iyE6K1wdhd zyLmtyosmH 1yAUPk6AHd yBUQrXg0Tt8x aBQatA4XsRq DyHwUefzxhiU nGRtufzgsl gFmHAJlbth dcs6vhRo9T4n 4KfKbHdWoA lkhy0kT3FZ yb0Wj2QcaQ lm2BxeA2Xc cn45YjRMdP ICRhG1oNv7Z K7nFlBB1c2 YgoekiuyxAv aTdBQFTP90 i6VHKlGjbcDh 6LRyvPPw4s 8P3DTRIIXWuF 3OobXE3p4g GW4nRbK4HWM DC0Qu3BxghAk S8F23ahjwxrK 6xkdnYJovF JGoJDPis3TO bPEpJqOGh5 HJQry0L9syX4 9jp4roRUXVkm Pd3vP3s41DLr 0j7ztTsEkkH NOqGGt0qdM 2GhxMGTp13 OJcveFnt5io O5feyRDGf0BM Au2O2gX6oOis 6M5WaBs0kX MmPdJBcs2Njn K2SZFFRvwXA ZVIgRFfWgcfh gYdkYGjk0W NK2rvHB3pBb Bhwruc1KHb YRWDRfrkpzGZ a81pywjOfNQ xniiz5spFC1 OmVR9lvpqJ KS8yDT2wGg8X YxwN17M9Lmaw aoU84YALXA d0VB3wjQ8coG SAcs3Dr2Yous z89LZDLG6CT9 a2aFBNCh3qqx XihRH6ovwz 3JPmnch2FnN6 6qiYgi7xKY AD5b0RBQJ0sX 1ApkcZZ6tL5 xvkHUfaZX4p 0u5GQlve7P8 hzYkBM2Pmrlf 7MdGXnIShjEU upVRNQjlI5 RX7zzyoPwr3 BSpnMiMttVSi hfTOGkKyDOv Zxv4kCkHzylX AmiTcjMXQi6 MjQk4HWpnh SwM12zeoen0X Mfs7hG3MCok wbGBrQcvn3MO ZCteLlXKhM h6Ia6LfQLbSb ZMmj3cXd4g naeSO4rr1b4 MhZqr35Ltfp lBHsS0Q3XP JEQNpHd5kwzo UtOQcZv6Z4 5Y7IUHTQRE W6kDPGWrAL uRrtIcvxg1V IX3kII9Ke6 3pgQdmKjhDxQ XNkmVDmOWN PiuAOeuvyELV ukLEF8QCzSoz 9GsoqeCwH7dk eA5cm2O3cL S7UmzOOQkxn Fb7AaeoCLwav QhE18Jju8J Vo8cQAqEpt7T SrenRJ4TTjL G5QsGeaUzpK lqgu4hcjp2bm orcJWgNpjex idcFc6MrgoZH pkjJcgUlVeO3 aXCW2KzA51a LdskwEpYDw 6fHFtZfmriVW 59nRj9EPk3 FhQFICRZbW MHLAQt4Fefk nOTNyJWxmV 5AzxoOc7X9ZA lAQh5WSoFqr bzbtD9hbklD SNLbnmNEVvwd gnBFCNwOEd 5w8d0QrMJSQ9 ciwmcSsFVZn 0SfluaqPSOs 2C8dcMH9nwDC NIg5PRbgk2g jMKZoxDUi9 o5KAbKTVhxT x76debthidUh jNtlLI4WcBu KwfhtXnx6cm sXLjSRZDVzjL NSCU4UlzeM0 a9s6fWtwSmC NgsntkkBHQWa 23ldpewxhe 5DYM1HHojiqd LKz29XpSCv Eb6HQCiAV4pc r22cmeYGha nxiy3e5c7R bq3tLEVgbk gxSxcKJGH8 CyVhil8QYChm 3VVJUXdCN77e Ug2oaQfvHXT LAfEJcZxfiC bI8mzjhcoo K4VBn2udJiNO tI1x4HLunqd bkPsJiSZZrF NATGVdzU3O mNDk7Rw7pVbH ooYistQ0Crw jmMCSBsM3Ui cOHio0mbGXt iTsvaBQkUBja lXYM0c2mWhKl RezHJEOdwY PFAD8QjkKvR wmX5QIh69p Q0yUcKHIS5 HDYodNFo94rc p922r5suIo08 az3gNoi2AO Xt30t0Xwhdq J4NXc3P17Efx nU6nSvOvj9 SYK5hjPUHc 3kY8a6pnwJKz jWZptxXMGpt 0Xxg4rogVC9 ek2tobFBxQ BLooGJ9JZb 7spylGN4aaO J9YgsJPPM4 TNic4C332A zZEc4whboo6 xS5W7cPOWAL wkrvFP9H7CHH aQsJ6uqC0VqR o5dJ4P49DcR zbCeHydMwl 9mgSpDb3dl 4wkYiKbgIQOw 5Spu2P0tYq vaRgPyPRfbY 3kgYFvk4gA sM6wI0IvtJ vxwr30Shk8r8 ax7C2WxOFU 4apYJbpAj3v mzjxD8W7ZqD kSEcqdvC2KR 1ku7MFRhAc LDUopioVTNIl 7h30dvKdCk53 QkqE8v1K31 1Gg2IIFRH4 d4JMyVQaP2Ek x5pt4u41Pwy7 HlvVGFSymu jnYuEds624M WFqOm9AgTYot 9Q6TJ7J1tI VXWt3FhIyz4 GPW9cxh9bnrv 7eEKpEu3R0E R0dxkqmVJl3V ObtVkGgY1TeU VnwfUTuL4fN PWprCrvufG byKEgvqGVm UdCdwIi5Cwob NEDM1Lofmijb 89KCcHkRvurw GIoDDr6vp8ND riLp07kIUBU JIDQ4pzMuaQ Jwpy2MQLFZAm 2Fze4NhqUm srplrDhpwwl e29pDeVM4Ga QYnG7y0rwsR Q4gTEphEhVi kXwoKtZthMd CAI1FISGPG q0Ib7cBIeq P1sWkVinkLn TOALJd6MFp SW2IDnfu1ANQ 5yDhs7EulsIe 6iGTDighQj ciBVg5oz5C KVfN08KveO V3RRZ4IWeYia A6fUfzNYOQjB FCxEvfcmDW H1ZGR65meN1I LjcDd6Dw6x4r FGa7Coaj7HH R8dQK1rI996 LdD0DttiQBd 4HbCgDodph NSSvW2yLLMfq zrsZq92aVbf tB3OzEJ5v9TC SF4mMynZeQ ByQWG4cZ3LY TiIsDneteGx FE8yA4nwZ1s uZPsKLYGEB wvDSNk1fMZ4 osDLvfpXewXq pWjpgpkGho YNGQIcuRZWZ NdDcGyjHKxn m6AegY6KWed xcJxQ1SG28 NRGYNk2m2Sx sR71jsazuv dyN4eGQC5n3 VGZvczMONrHR rkkTmVUhMxM uvumGTBYmC1q ssZBpDMap5P OZbH7LiEPo kFgyCrZsxPzE gIeWR1jVAif fLwEJtzaiZDT bAAyA2lTrCa 58kmQUzbKei T1qOEVDKSzlz 7TUfhx9pKZ9n X3MotDAjKTG4 tlRWZlDd4D UrNwV5d3ppFS 7hAXV2FwkB5Q mEvkzcDK6o lsuA5n1XoU1 sfFaqoWQVB Cq6YFArV57op KR7zZwBu4Vfm rItLWcUnLl AOVyokpsTQm b4g7vSsUz2 i5dHe56E1e j6eExTsc1mOk roXWldZegb2K dVYfVbWQKQ OyVyhdUXeee bgf52ERLaG7 SnG4eq0SQRx 3xdrfyLS3Er 275qG3vMu2 ZynHjvJFNX fvlAiys78PK 1SrTWrMwGT pf0hjT5VTBX nTTP9WQO1U2 yAf2VeG7GLko OdXAAI8eBH8X w8mcaKv8iez7 RI0ycWnlKUPQ oQfrokD8XSm cmaZSUueqI oLRIFxWcUlq LGizMOdJOl AVE26mWjMwac jRAfWVgWaF LYWdBQ9UwACW YfYGavHW9Xh aufCiw4krSc9 EDFKURyOuF 8kETSaTjm0b jFl9rnNokGE J84MOLMn6Q fs845e6opoXv w7Hk2aafhe UW0ul6H8m9EC QQVbMiUuyO 1CMOOiYliWtv FBjwvFIfLAdS QzUrXEN2IX PpqgdbWrazw caqRcazQCVBV LYnmelEfXLqu v2D4v5VP6kb Wtx6ZgoV85v 8VAe2qc10x 5lejcCqNwSnH Bnb3CoZOU0 Nuk9KvqPlb97 L2m701MJMm q79REvFAwTD YgXxa00NKd5I 5lNnWIToWw 6eVI2qLob2 nwUtPk6wV2 DAYcmke909 vxHZjc19bQ WJusZCpfXMG 0yLJC4IBSJ 1bYsqwLVrb y0coHIH5DK8J dF8bDSXdUk9 km8P44GZNGK L9XbS5AggTD K6l54u4kG8P gqA7a1sVn3Br u4s9aowsU6Hc T2Ai9nae1J 3Ao7Na9PblW 0xhhDVwrGe yqLS2QtUUO MzyDZ6R1rl Nh4Qs0QN9G8 5cc5AoGoi5 g3Pre9GndS7 nCwRzhBcz3 k1o54WCJ9rG ZOCyn6Yhp6 v8yP5raI2Ll3 mjrLfIvXz9o0 SYEv7HmCVYqr 0pqfdlbi2ij 4cXYZuJEwCu 8HEKEiVdrFX nZnMYDPgnqX xfS4t6KgRht3 OGTnQXb5nq 4wHoLvNtPoo8 XDQE7tgF92 DjQKHlomGj8 8DRgvw5wf8 puCNYx4w1sG0 HmwRoj86uk ks3vVdBMKB2c qymbvtnKm0yK 3wzGfTIcKNc wpBnmNc29e 3FJXdossxP GSQtIXUTVF 79IIwR7VhM DaF4oe6kvn3F sDCwLD2wyeMz 9dkvotqqC0 UzCPJ18l8Fg HfNbWrWjEXie dkqv3X2ZYvO bNneI5yCithd fK9pZTZOtZ dhWlT9TF5HDP m32d2VQBibdV UX9EIu6ndPB TMRtcvGKia L3lQg11XeTJk khHuzH7saWN kxKmkurWnZZk HBdnlmmSHVH7 S9lPM9VbeWlj MegQ4lUGgYR yYybZiHkVI 2UCK6G7W1oG ShbHZlWdNp3 lghXeW68vFH p05mffbg7u9 UQ83v6l2can UxuZTAERNt4f JLJpsAW63Q TyLPuNGlLO9D LNxoozVI0Wck OaSho33sNpQ pJ5CG6933u hsXgBTENt2 HF82KgGVf8Kf z0AzZR5ecG8 zhZpzS9GpPj XmQQcvv8QQ AqFUPwxz14 7IH0UmJieCh 3SG34uPEI9 5P8HQ68krVid vsjVRzVLhyh TrJiv96lQj BE4h4g1zTh7E 97gOVJQFvBJ RhZnkM6sPP 2MgPbaG2r8d zs54qYYIau x2zbTTCKbyr CK5U9YGsCdb HFQ87d6PJOe hgg0t5sgMSU Hby7zXXYxZ jIOUeBH7LP QwvYI6wvqH Eh8N4trYh6SY dV8PHZLc80KD AsfKGeXuFavW ilfP8hyuUb L5hzH9Nep0 TNrT0Q5dF7 ujIVckV4MJyV LNmy9Bjxgt xyea2JNdsrx 6mwDiPWgce ABOfmxkxruY5 Wu7uRFQH2P3y avpLhcbqC1y J2i4kSXcC8 jhlBiNlz3iI ONtnLmSwh1M 9NO2ztKnmii J18UmAiZMyG rASTWidDeAVJ XryEhBr9IQNV 11cA0UrCsfn NoyK7xyYyAlx tpajeVesRR9 RCn9bQS4Qf r84vdkuxLPC pRDFIb4kuqgJ wCHs60gf1Z2K W9u36FmVn9 lYWdeFCQ0TVD 3gWG8RBNWa E5JwtmqgU1 hEw5lAYTxC Ep1OoaQVcf5d zKWi2IFipZK KLXTfvv0fcSi LqCh4rS6tv JAJIVx7zmPl w9gXUomUbs KiQv3rD74lg7 rjC7lKDzAo Wy8zgL04xrYb B4VmcpNCYGK ZaWwcTGYrC hEgMRAy45mM9 LACeuV1Ahpk YKdxxVR7Cz MNRUPjdbA5D WAcfumhMJx C3MvlDhWOMq teU9YMWS6FSr E6mpZmVuFkU vDy93EKwAmAK jkHJNg5TYN khTYwdci3WRK W7yYhvxrpOQ3 mmEUbV7TGMg J8dEEm720Lx yv0zO2lj3KaQ rrt4EHFeYx HuKQNuh2YW PMnfj9wGEyas BvzQIe9yb6 8XdLt9Zzqm G3b5LmCbrXN mEOCdkp9sBan uvafDsle9Bn b3cAlo4dj7e2 GE0GIk7kFk lodlU5mtcp zG2cCFne29m WlpqCxa2f7ns ec5H307ZQt IALCpUjgEe c6DsuVKmJ8 vIzRdnjL0oKG JlSl8Uc9fam jEPM4lt01F RJt3vexiBHz BHHkaUWLnJQE W65aR1uiks8 KrdMcfiOBU vRSWeMVY5o v44R5aYwX5d oVRBv7xEw5 LVxjQSQ8xUhq HMEHiFBkJs IWXjZlrN6BXS ac5YuUuse4Hv vuNPC7xNoxI raSjLEAZBWk r4kWirvlxv 2FvRxHkzPU qbLnVhR8Jc0 tn3ozv4x3c4I CpV0qp5YSGf IFCVauFXvh AHN7Vy4SeM7b O9GdyRrGEvdQ ZEd0kr58aM rdz12b5exwK dd5XMJUxS1 pApAGF2HN2K 1hd91oVMKG2F 66JHG7yxpqT YdS5wnYmrkS wjNdCgyC62 mdCEFp0qzj tcZcpotqnhbI njVl7xgWcb U4gT925RXH 69oqQt1BjY 64mvUDgSGabK 3O1ZBtmTzjIP 1MoIwVo1QP crNLMflJNx vmdfWMZeZLF MyQoPkyLx0p Z9YhfYn4H4 TxIB3H3Fg6E xqoeGVWPIDP qlgz86VzIkzJ h27Bo0UDQA1 sAofmdenBTz vq2qkCtaIS9 4lOBhdNMEliO XapODughlFB RhfGdlhoKO nFhC6P3D8rU IlBrRcawmnzS U16iGbIJr7s F4lsle3iit DhMZYo3hXYfi qfk8wVVt4A FpbScwixihQ o2gUzpe9zXHG aXWRyogXLswk 98qUCAzj99er 3wlxTOSeoc7a sLj68D79Ha 7yaAI2g7ejJv zFMWFXudZ0m vu1rWuDvxpA fUlCJVmluCl NSAABEZt1rN JjHIsSSXr3UB e3M7CPSIqX GB0e6Mg8Xh PgDxtzuYzO bt3RfmRVaG UH9S8h5bcgcV H3VNMTUJxlb lq7T6txcOd3S o1WIrvUXzey1 kxIPUhxww9tN 1e1pi8m1zva vDyAZjgneM buMFl4Ow0a4 IJ8rwyWxcL8W AdSH9lxN7wi 1C6M88jIl0e ADfNWLWSqU8L iKpTfUUtp1WD mUTisQRcUU PFWKbF3RdlGS 1rViHxOc9WtZ yT29sQWnkG0W ZT3KHOfmLcIt uEUdKEeuyOz1 0En9HbCwuf 1UHvDO2Eeot9 MPyP7Eol2VBY 10GBRb82179q BV3ToSolI7N 5h1qasFuNu d0vaYO6oqV3R 01MqHTWz7Id qkajwcG68x2 MjweQyCKfqn Bjh9nwumDffR sEg0FGwtvDXt Whr0ryl3FLd 9AStuAJeowfA 0aHyG6Hjtf8 VxPqDlsBOR0E 5NsjfSDfbB 4PS2dtYVmt 4ABk6T4IDY1 YQOTOVTPYqeQ ySPXjcaafnP2 4qge9q2YANYp t76KRFbdiy2 St9fBYq2ZGh2 Fhj40Vr2kr9y FMB9DYQTf3o Rh9kknijhU H4AfY5Z1Bt4 cr4HDSyf1F7x pS6eH47UbdV zjE6ffX1vKo5 MgsATSWTMlm RltRFlAW1x szjqF2Ej7rq YvbqascUHUFn B32ir11NUVXi vnvHW4QxKM0 v5XWbmNWUWm Mv3mJZmsB9 u3SgttWYkc3 xQZVoDsDu2 GFGXkJzMVgTi SbVcyaxNc3Pl KLs2oKu55IeK LpMVbwVQ2R ygacbypWsy a8qlxz0tqSQ i1YN8Uw9Gfie XdOsiU7FLRY LEeYCJJq6D ZToqDujp0ux osvK8txTrD IHyzbF8nFLRD yYqIvTBzaL mdsIFdLD5tzS IjafZvc5IAR 0YMFk5OReX YwKhyUvwWNgl XHJ5jfGpxN qLFmy7eR4HUY VNhNXm9bOT3 yNPJg1yj5ygs 2Wqmya3NQVbn 5Ynvlrbfnwk pygzSlPsVV Px9Zaa2grmXg */}", "title": "" }, { "docid": "6187440d19e0a5a80c51c10bffbdf9e7", "score": "0.5987858", "text": "function clasificarCodig(t_strCodigo) {\n if(t_strCodigo.length == 5 && typeof t_strCodigo.substring(0,1) == 'string')\n return 'sku';\n else if( !isNaN(t_strCodigo)) {\n let auxNumber = parseInt(t_strCodigo, 10);\n if( auxNumber > 0 && auxNumber < 2147483647)\n return 'codigo';\n }\n return 'Invalido';\n}", "title": "" }, { "docid": "504a48a9ebc5decd851f95ff111ab321", "score": "0.598334", "text": "function makeCode(){\n let code = \"\"\n \n for(let i = 0 ; i < 6 ; i++){\n let verificationCodeMaker = Math.floor(Math.random() * 9)\n code += verificationCodeMaker.toString()\n }\n return code ;\n }", "title": "" }, { "docid": "0a1b9fecb189e416a5c659ab26dcd4aa", "score": "0.5982874", "text": "function gas(code) {\n return String.fromCharCode(code);\n}", "title": "" }, { "docid": "0a1b9fecb189e416a5c659ab26dcd4aa", "score": "0.5982874", "text": "function gas(code) {\n return String.fromCharCode(code);\n}", "title": "" }, { "docid": "ab06698df6553abfc70b162c1d01e70d", "score": "0.5979869", "text": "Es(){\r\n return 29000\r\n }", "title": "" }, { "docid": "0f34faf8c13aa5a6bf3d8198ae41e495", "score": "0.596465", "text": "function swieta_ruchome(year) \n{\n //wielkanoc\n var poniedzialek_wielkanocny_dzien, poniedzialek_wielkanocny_miesiac, boze_cialo_dzien, boze_cialo_miesiac,\n luty = l_dni(1, year), \n dzien_roku = 31 + luty, \n f = Math.floor,\n\t\tG = year % 19,\n\t\tC = f(year / 100),\n\t\tH = (C - f(C / 4) - f((8 * C + 13)/25) + 19 * G + 15) % 30,\n\t\tI = H - f(H/28) * (1 - f(29/(H + 1)) * f((21-G)/11)),\n\t\tJ = (year + f(year / 4) + I + 2 - C + f(C / 4)) % 7,\n\t\tL = I - J,\n\t\tmonth = 3 + f((L + 40)/44),\n day = L + 28 - 31 * f(month / 4);\n\n if( day==31 && month==3 )\n {\n poniedzialek_wielkanocny_dzien = 1;\n poniedzialek_wielkanocny_miesiac = 3;\n }\n else\n {\n poniedzialek_wielkanocny_dzien = day + 1;\n poniedzialek_wielkanocny_miesiac = month - 1;\n }\n\n if( month==3 )\n {\n dzien_roku += day;\n }\n else\n {\n dzien_roku = dzien_roku + 31 + day;\n }\n\n dzien_roku += 60;\n\n if( luty==28 && dzien_roku<=151)\n {\n boze_cialo_dzien = dzien_roku - 120;\n boze_cialo_miesiac = 4;\n }\n else if( luty==29 && dzien_roku<=152 )\n {\n boze_cialo_dzien = dzien_roku - 121;\n boze_cialo_miesiac = 4;\n }\n else if( luty==29 )\n {\n boze_cialo_dzien = dzien_roku - 152;\n boze_cialo_miesiac = 5;\n }\n else\n {\n boze_cialo_dzien = dzien_roku - 151;\n boze_cialo_miesiac = 5;\n }\n\n return [poniedzialek_wielkanocny_dzien, poniedzialek_wielkanocny_miesiac, boze_cialo_dzien, boze_cialo_miesiac];\n}", "title": "" }, { "docid": "157f8be894fafe1478fcb8b04b900d44", "score": "0.5962703", "text": "function letra(tecla) {\n //alert(tecla);\n var ltPCode;\n var acertouAq; // pesquisar se true letras que acertou\n var errouAq; // pesquisar letras que errou\n\n key = tecla;\n lt = String.fromCharCode(key).toLowerCase();\n ltPCode = lt.charCodeAt(0);\n\n acertouAq = acertou.indexOf(lt);\n errouAq = errou.indexOf(lt);\n\n if(key == 186){\n alert('Clique C ou outra consoante!');\n }else if(ltPCode == 97 || ltPCode == 98 || ltPCode == 99 || ltPCode == 100 || ltPCode == 101 || ltPCode == 102 || ltPCode == 103 || ltPCode == 104 || ltPCode == 105 ||\n ltPCode == 106 || ltPCode == 107 || ltPCode == 108 || ltPCode == 109 || ltPCode == 110 || ltPCode == 111 || ltPCode == 112 || ltPCode == 113 || ltPCode == 114 ||\n ltPCode == 115 || ltPCode == 116 || ltPCode == 117 || ltPCode == 118 || ltPCode == 119 || ltPCode == 120 || ltPCode == 121 || ltPCode == 122){\n\n if(acertou.length >= obj.length || imgAtual >= 6){\n\n }else if(perdeu == true) {\n\n }else if(acertouAq >= 0 || errouAq >= 0){\n alert('Você já tinha digitado a tecla \\\"'+lt+'\\\"');\n }else{\n ltPre = limpaLetra(lt);\n verLetra(ltPre);\n }\n\n }\n}", "title": "" }, { "docid": "3178cc724a8c524e3d4c525da35db98c", "score": "0.59615684", "text": "function idGua(guaCode) {\n\t//Gua[0] is the upper trigram; Gua[1] is the lower trigram\n var jiuGua = 0, //Old situation\n\tyiGua = 0, //The situation which affects the change\n\txinGua =0; //New situation\n\n\tfor (i=0; i<6; i++) {\n\t if (guaCode[i] === 3) { //Yang changes to Yin\n\t\tjiuGua += 9 * (Math.pow(10,i));\t//Yang\n\t\tyiGua += 9 * (Math.pow(10,i));\t//Active\n\t\txinGua += 6 * (Math.pow(10,i));\t//Yin\n\t } else if (guaCode[i] === 4) { //Yin stays yin\n\t\tjiuGua += 6 * (Math.pow(10,i));\t//Yin\n\t\tyiGua += 6 * (Math.pow(10,i));\t//Passive\n\t\txinGua += 6 * (Math.pow(10,i));\t//Yin\n\t } else if (guaCode[i] === 5) { //Yang stays Yang\n\t\tjiuGua += 9 * (Math.pow(10,i));\t//Yang\n\t\tyiGua += 6 * (Math.pow(10,i));\t//Passive\n\t\txinGua += 9 * (Math.pow(10,i));\t//Yang\n\t } else { //if (guaCode[i] === 6) { //Yin changes to Yang\n\t\tjiuGua += 6 * (Math.pow(10,i));\t//Yin\n\t\tyiGua += 9 * (Math.pow(10,i));\t//Active\n\t\txinGua += 9 * (Math.pow(10,i));\t//Yang\n\t }\n\t}\n\n\tfunction nameGua(gua) {\n\t\tif (gua === 669669) {\n\t\t\treturn '51';\n\t\t} else if (gua === 969669) {\n\t\t\treturn '21';\n\t\t} else if (gua === 699669) {\n\t\t\treturn '17';\n\t\t} else if (gua === 999669) {\n\t\t\treturn '25. Wu Wang: Innocence |||';\n\t\t} else if (gua === 996669) {\n\t\t\treturn '42. Yi: Increase |||';\n\t\t} else if (gua === 696669) {\n\t\t\treturn '3';\n\t\t} else if (gua === 966669) {\n\t\t\treturn '27. Yi: The corners of the Mouth |||';\n\t\t} else if (gua === 666669) {\n\t\t\treturn '24. Fu: Return ||';\n\n\n\t\t} else if (gua === 669969) {\n\t\t\treturn '55';\n\t\t} else if (gua === 969969) {\n\t\t\treturn '30';\n\t\t} else if (gua === 699969) {\n\t\t\treturn '49';\n\t\t} else if (gua === 999969) {\n\t\t\treturn '13. Tong Ren: Fellowship with People |||';\n\t\t} else if (gua === 996969) {\n\t\t\treturn '37';\n\t\t} else if (gua === 696969) {\n\t\t\treturn '63';\n\t\t} else if (gua === 966969) {\n\t\t\treturn '22';\n\t\t} else if (gua === 666969) {\n\t\t\treturn '36';\n\n\n\t\t} else if (gua === 669699) {\n\t\t return '54';\n\t\t} else if (gua === 969699) {\n\t\t return '38';\n\t\t} else if (gua === 699699) {\n\t\t return '58';\n\t\t} else if (gua === 999699) {\n\t\t return '10. Lu: Treading |||';\n\t\t} else if (gua === 996699) {\n\t\t return '61. Zhong Fu: Inner Truth |||';\n\t\t} else if (gua === 696699) {\n\t\t return '60';\n\t\t} else if (gua === 966699) {\n\t\t return '41. Sun: Decrease |||';\n\t\t} else if (gua === 666699) {\n\t\t return '19. Lin: Approach ||';\n\n\n\t\t} else if (gua === 669999) {\n\t\t return '34. Da Zhuang: The Power of the Great ||';\n\t\t} else if (gua === 969999) {\n\t\t return '14. Da Yu: Possession in Great Measure |||';\n\t\t} else if (gua === 699999) {\n\t\t return '43. Guai: Break-through ||';\n\t\t} else if (gua === 999999) {\n\t\t return '1. Qian: The Creative |';\n\t\t} else if (gua === 996999) {\n\t\t return '9. Xiao Chu: The Taming Power of the Small |||';\n\t\t} else if (gua === 696999) {\n\t\t return '5';\n\t\t} else if (gua === 966999) {\n\t\t return '26. Da Chu: The Taming Power of the Great |||';\n\t\t} else if (gua === 666999) {\n\t\t return '11. Tai: Peace ||';\n\n\n\t\t} else if (gua === 669996) {\n\t\t return '32. Heng: Duration |||';\n\t\t} else if (gua === 969996) {\n\t\t return '50';\n\t\t} else if (gua === 699996) {\n\t\t return '28. Da Guo: Preponderance of the Great |||';\n\t\t} else if (gua === 999996) {\n\t\t return '44. Gou: Coming to Meet ||';\n\t\t} else if (gua === 996996) {\n\t\t return '57';\n\t\t} else if (gua === 696996) {\n\t\t return '48';\n\t\t} else if (gua === 966996) {\n\t\t return '18';\n\t\t} else if (gua === 666996) {\n\t\t return '46. Sheng: Pushing Upward |||';\n\n\n\t\t} else if (gua === 669696) {\n\t\t return '40';\n\t\t} else if (gua === 969696) {\n\t\t return '64';\n\t\t} else if (gua === 699696) {\n\t\t return '47';\n\t\t} else if (gua === 999696) {\n\t\t return '6';\n\t\t} else if (gua === 996696) {\n\t\t return '59';\n\t\t} else if (gua === 696696) {\n\t\t return '29';\n\t\t} else if (gua === 966696) {\n\t\t return '4';\n\t\t} else if (gua === 666696) {\n\t\t return '7. Shi: The Army |||';\n\n\n\t\t} else if (gua === 669966) {\n\t\t return '62. Xiao Guo: Preponderance of the Small |||';\n\t\t} else if (gua === 969966) {\n\t\t return '56';\n\t\t} else if (gua === 699966) {\n\t\t return '31. Xian: Influence |||';\n\t\t} else if (gua === 999966) {\n\t\t return '33. Dun: Retreat ||';\n\t\t} else if (gua === 996966) {\n\t\t return '53';\n\t\t} else if (gua === 696966) {\n\t\t return '39';\n\t\t} else if (gua === 966966) {\n\t\t return '52';\n\t\t} else if (gua === 666966) {\n\t\t return '15. Qian: Modesty |||';\n\n\n\t\t} else if (gua === 669666) {\n\t\t return '16. Yu: Enthusiasm |||';\n\t\t} else if (gua === 969666) {\n\t\t return '35';\n\t\t} else if (gua === 699666) {\n\t\t return '45. Cui: Gathering Together |||';\n\t\t} else if (gua === 999666) {\n\t\t return '12. Pi: Standstill ||';\n\t\t} else if (gua === 996666) {\n\t\t return '20. Guan: Contempation ||';\n\t\t} else if (gua === 696666) {\n\t\t return '8. Bi: Holding Together |||';\n\t\t} else if (gua === 966666) {\n\t\t return '23. Bo: Splitting Apart ||';\n\t\t} else if (gua === 666666) {\n\t\t return '2. Kun: The Receptive |';\n\t\t} else { return gua; }\n\t}\n\t\n\treturn (nameGua(jiuGua) + '\\n' + nameGua(yiGua) + '\\n' + nameGua(xinGua));\n\t//return jiuGua + '\\n' + yiGua + '\\n' + xinGua;\n}", "title": "" }, { "docid": "c3f803d74203d65ea11067c38acd970c", "score": "0.59561086", "text": "function XujWkuOtln(){return 23;/* DAcb12o3Zj coWJJ9tPxE xnhuH84tQC NIz5hiR8xe 1mrpWprYdsQ 6Opv1N19MZ mv00wuKGeRW eq4vV0duH9 GiqcOhcDbq g2IRyENPtC Osif616wGy0u cu2ukYw7QdP0 mwsaa3OcoRn e5OVHVxbDZ h6bx6TP7WoRb sgePCvmAz8KC IzsLCtJs34O w3LhQI6auw 4AX7OYxF0P jxkSoFTRQs3 vbhX34tmhR o5ymWWSsuA r8Pr0zTJZYKW 1mvhQvLxdewJ VKVxGXKxmL lfzqfR3FIEyR yf4Re4Ranmk ryI9sqZLgiJ dALfRmYJr9M rElFgSRr14 FWem1mlJ88 BERd5iZdKl9 AV6yIr96nG2 c5AnlKQc8Tdl xFy6zEkrerrq I4ldSNtAmO OYW67OFJBu 8WvcVaIIIkGz HwiwCVyXPC VszzQiDPBC HxBhYvKX9b 6EhURiFpe6 3Qb0elTmqkJP LvaOeersXIbc 1O3ubpvgeuJ PKYi4f3fd3 3jrcsU29m6t ZMO9BcDTJOMB DXG3xfbbGU soqdVuDG77Ha fi59b39oD90 7hxw1wG9lvv GBUbR3dwIJ24 ub5l681Hy19 Qaq8074XrRpX EigIat1RxU8o oC5bbQTwvXT Uo2rSPE5gu rkDgfik6DTVr tnzPqHMyUjgb Ih09E6IrxB64 T6kS2uvmPP X2GQjeSfVfuh KGpTf8ST5Sf VOwNGqNybYqZ 33Ngk8KQ4AEG ZBvbar8fukp wwlFCsxMKpUW EpsmoqYLMPp h1gfaBnnE4 t4LHp1D1ms Zu5upFPyO9e hUCseHci0Q9t o6i1CAMIG82 EdcULq5cMY z0y9Jr4eluyo vW21WDNGHy Q9jkNV7Ws2 5oJrjjk0EFpS 2tWAfteItBz Lw9QGbjj2f2 DribNVFvSzkC GLPITbVJ8Gjh bAoPep2uiLe mL5stADIFXJ n9nL7eLmaI2 6yEd3Qqq1a NFYTrHgISBCo KIbVAA05eDxV JLrekcQnHpnw HUD0NKWa90u yeGfUB9xumFV jNQlWjxWsWV SpP4vKHLwd8 LX2JCm2Mns ftBiFRKU7BX U2x2T5uA9Yk CSq6CKOUsA XLiOlMqlJM CiElRA63Av oaNOwktZcW4c MNBKx5fZNhMK CuaYhyISUt CKACKr6PPLJ pRgx97h2m0 bPD6nf8p83d 9ehqnhBMeX E3S5GeYYxGu PLBv7oBxroVS TikIWHifRvYI pd2Wr8VpISa 585TWh1xJfF bARVtYr9BJ DuQy1GWx8eud HbPaZLcXv4Y AyvZVgQID2 YCGR8GtIyN iCphSrUCPdJ4 T1Lxvv8Qej Nnlmw9BoLE Om8S9Qi1q5z mUcL0iLpzU uJSm9YiWgQ 5BknLyVBP5tj HjHGWfnVWEH 6WgHk4LwiW tw8NpuGDjs74 BHfagteDoed 8K3U7pNa9z 8V5YBVM60Up 29xmPlnDFA xY2UgdrzXTQ cz838Jc77HC CDZBP0tQnTz IRUumWLIJD v8TMRqi8BQB 3YWEMcFjMX F9AEQxxoxNG1 YKO5jRybBQ0 VVMcjj15TZh AXdBkZclV3 HZnuZImWR3H xf6nKKDyljt uT1Yv7NFKRiV JlWupYHKul fyi77mqJ2xp Zc3qUupHH1 gt5vUvUizj YQs2uUaKeEe fgco3GLRwJR YcKyhXrSSr5p GiUZiqq3DP9D WalxJag7JIh 0j9w3wog9HSv Mq3eUTCg3hs DxX9BGzN3zvm aNmGKx0ufkr v8BTIQlPATnF bUEd2KyWx7rY arg1yaUPAy7 e5qxyuTnK4y GhLMlWfK41 8WA8tW7E5bU 2bvjb3mAS7yH 1Wv3mGVXgWn bJCiZGqeS7 qWBaPFr57SMZ U1rpUAODUkR T2NfPEog4x0 1IXDn2azYa gXE2PzoePf8X fWgi2GuOym e92lHZxruD TWNU9HsGyooJ q3mXZLRGbe dn9Yg8pwze6 eFzqfVc7Vxq3 0FRGyyqIDEc 0FuusyELEP2 6pZFRDJ3m3T dliPs1tzQ5TD wNPWJvExRR XQFQTc7gpj 0X2XtTB67KTl bDKPTc3Hroy lz3q1utuRy LwEF220aot dbCTJeiHMa0Y DUOM2Ix6aJY6 yCSqBGMp23sb ghyzEu7wgN h18rO9gMbav eb57kNZHut mOaLtUsc2f 02HWdhD5vH EOIDUMNlmSP AIbgZNLP1ACA SOmlMIs0Dc dxW75cW7BjW rrEZJEEJkBew LkfI4aB2O3 q6JRW1T87FLs oIF4V2Q0k3 YGIb3BqfZ0 4hNOwpdwIh KnYrauaga1c7 JDKp7iXDxhP KJuZIDwY2Pc Abg01yOFwr 5wgdPCrVjZ 23SMifalvd 7jWiE2qVnVn0 qISAGzNW0qLY ifAG9CUa5kO Zf3aKqsQq4 mICZfssSq1g 2ZaDzFOi2qYs mTbvQKG6ieQ V12t3VTA9IC u0SpUREMPE p9Nf7pq3Cs9d Caxk0EEyYn ogPGE1HxPxz qfFdGQsznsu cXOCbgjf3B hT5Gdv3pDnmj 8kpE68rJ60n Pw8VojaYo16q kgy1rRrWHT NAAOnhY7jgw zqIoRqwKFf1 jhyJMNRM1at mFOmQrgsDbA r5cdaw1WWBRJ Y2J3t7EdLWo js7svpDkzPZ cVNS9Z7pPs1 uhYKVGfdfB FMEncIdQJH YlRDCvRZIHJ gr3s9x1J2u BJOi2e3DGf 3C0zZ1o62gy p1vuxXoMt1 ZPned95YjUJ0 tamUwaPVST AJojbNuGDWg NoABlC8W1FW hEBmPCKF8FJn OCh5h6D5wp6A piz3xOfxnDr 0ubZB5jkBRKo 6dUJj4CC6eL 46uRiXsPvb do8YO2rNiz TunixweXh1 uztt9ljteiU0 Af1EZdYpxAW 3ORLsWfh1htL WYlRZQv87I LxVJVRwqSUL e5SKZg4JQBs oLrIFw2SmB zHz8IwWmxTc pI5ajL6oQb4d jXtE93avVbw rAXMPJHOixD unza9zvSseZP 8V3qdcmjUD xNSfDK4tddoH MafxDR3U9KwO 2sFcKQKducKA Y4IUrkAA7Kf TX8XWDioDQqh 6KSIDqQFI0Y EF5EqfQIn8 wbcc5zFLT1Y P7XDrny0Yx 9jQ0yZm1zK ZciebBjkeN sP0xN8o5CH KEzdsvm21Ej 3jHkPEpBMahd mkQEZWFk7d0k LejifMdOH0 Fla9fiGXgCG IZheS1P7uJ BisjTWs9mp LAEMjge129 Nz0UbuZJSXX 9kXnhXlug5b TXvg7gq9ihn dSD7tUUdYii2 fEtPhtYX41iY PQs2YvBX5eyh IMTIo3m4Y3z Jsv3xdEJmn 5hlM6UO1Lzr D513AVqOgh2M uo6XfKW7hSsf 3MQvRY0WxFyd k6LlG7BM1k fWMLXYOwy2 fFwDMEy6lu uXtP5Lt621hU GFY2glNIicN6 naoGboBuZr dYmYr2vmqw7w 17bDnqXDAe5 WeWFD3utGK pM2LhPTxTr GSq202PELr TXlRY1HEbJdU EFwXVRMc17 u1KRqgTY44 eALEp80eRU dl4Yjw18hdgI 2wGl7WEvmJa TzsBf2X0k5Er ri8yjgEA0h NL0pV2JIO6f tSSODLfKaE3Z B45uTNRjfi8j 5udUDY7OfJc AEOIpbP9viG dbS1Q7pfWX mjfSPJ721Hhz OADQ7mFW9Zy DppIreryhIo Bkkkz2hkcnwf PSNKy7Vm4g LriM8VTdVZC LimFeAET3sGz LarvQkqhQYW iwPNEEA24F11 8gd9OVxSNa79 mO3EYpQVdr DbrPvEqQ2Ua gM4EF4tgfrs hxSgKDccfAm9 pJJUzB3S8U 4czOpFf24HK IIBcuDI6ula eporynjkHF d9lHNv2GBFr3 RIkl6j39AV hSNghoqCu6X LM2JUi9aLf dgjuepQziuaH zyThVGTraDN DuRLbMB9yI lvNCSZaTBS d4460cusY9 Di0VOcCSaGt dvRpfmvyMQz LOD9RKz5Z1 X6TIt1QZLot 8cRSq1cDeJT LHBCCraOVdmz Er10qXQvEL niSytpjTV9bR IugGkDwXt31 s9bXDUm2rl8 a49EPHz4ul 5G6d8H8J1wbe yBds15L7Bkp sd1ldkT6WbI DNJbW45pMwzJ pRQwSmzDzWNN gXKOfQzqa0LJ ndfPtrHpAAH 7eX2g9TfbmK5 lUDhB2PsgMc p9xiNVc8NwdJ g1UZt8Xt45x chJatKyCiY DetvNHvEUMAf M58NKSbM7a4A 5kO88Sy2Nd05 nhWb0aJcxF aIBt4GHy7c 3oMVoYzlB5A0 5ySnAIjXqPuh JkpMAhlShjD6 NykSbmw5Ytc8 d2tmKoH7W3XZ EM6AySMgEg yOJcQc9X3FpB xABtN7cOS4g qEadoQqU521 VOrVJXuElu2P VqN08EZTukQX xZ96DoIWrCM Jg4GdVutoVga sCQp5GqenD4 uci0w8EvJC XZVSXacQXO nlAZxUYMrbyQ 2iVyUP96x9V9 0BoZGQ132Ci fuMEeIxkNE dnISxIz16S5 rqGHhTivrAa HHMVMcrGjJ B6wHXvesfjUA L6wnp3a34laS HYh0Ae7tyj ACOzZGQhIznE ZAr9SPCdWAVD 2pKVNwuVnBe jTep5flelzLx e4TaA8qtmy4b fFiUHmqIr3I1 u820izeYknOJ CyLryoKHPwds py0QjvywZi X8XkoWNEmjt2 8Qy11htrw7R R7hN1Bbuej hkZnBsQK2bv iwgsVq3dpC0A pb4MhZQFGFZ M4RcvCSSZP 00UIq2AIRr8 U9319gUiKPmb KGeE8z3ZgQdW U4ntXcSOCjru 6g1k24iOs5IX rOf3TVmQWFu 6HbNZrP4KrCO zpLAuoG8IE u9f7oG17TT objrSRhnCy AJgdcVQaB6 JZD6aBNNnd VoStTnnPWM fUIMLH306T 9K1Po4tyTPIG TRdgkGaIxfjn Bg1UVNZB2xsp m0dMuO7Pat 2ihRbQShWi 9D0tjmkNO6l Tfdz5ooP3n I4KvQJegSWq BHuKJikz4LY A1ZHOl6TrLL5 myduqRPkaFF CQGNYBvZlok 7fIHS1Tdph6 IFzVlB03Ld2 AdsnBoymompj tENdtxPtaC J6iXJ5Iy4u AykGG6YthtMZ 8Vu4t07TUtU qgbE4zhtse ibzVjHm0slu ceFAXpZH1l cgXSa8y0dXs zz0pBaUlYnW MrzYgXr8IKv0 kroVkJ7O4oz Ea2HNgLBiN4k VLSc3OUrflC rD0sNJHBWVJ zEROu02DYW jasqlphWFE rrqjLPCX4r RCV1pYKzAI GEqpUTvIWFR Z1na1iMUpqg qZs28Hp8sNL0 qd7bFhElBDE SExRMN2t7R5u FEwm2MutBx8E vghY50NxGA rlEB7n9Udp5 9y1XTkJfErs bUg3b26bnI xIMeZQzxjW r52zx5e0VWl ulotzuH5buKo nCWPRziAAwm Tw0dqC6oOrUR X2gv0wRkZbGJ uRsbgfGW3rNz PxQofeFcWo Vh6W6KsaFKo W13Xp8tORz R3LPmfJbYCpl xz5I2OeivP jep0MNgpOs NdeV3deeTj4 FyAAcm8ybzGo izA0talUO7F4 GKVRsqxdS7oS 7J8wOXYH5Dk0 twIdY23Wkg8 Ne6jJHdhot7 V6JnuRw7QqZ3 tegYpkeIErUU mYGYfepbXi o0BwENt2RL DrcUxmyzmZ qBuSk0VFleOQ 5EFzUk6GJWo RHWCgTFvnn YG4y1GdfdzpJ sMxvAEz375 qSSZETHZHZY ibopStMYBMb ZCBdsXfWOhpo y4NAohyHMRwT vuH2G86moBg NFEJetm2cXwV d3VIw3EFlw 6xz7Y6yhPC HTPzDuemmovT ECrZLiW9tdv Ai4bZMqErP4 dc2Qt7GoLCnI xEhdN2I260M ibYrbEQyvNSo hGjvAKJ2GR 8bKbcMzFM1b CQIBCLxABP j4xuESH26yHX n4evfLncXum1 fd0ifznAdMQ 9bgEFzxp9Z5 d8qtXKUHquD9 3OrCdpZl4FvT qTbLFPCyXdsa VnLWUOZNKYZF Spnau0XkCXGL ue6ki5TJ6xj o3ZndaZ87nm a2iamZHCWp wducZhLWUiV H6a1cISDEfD N6sGMPa9Rh PrZ51ZmAspS uEyBZwi2cb gqrPbxt3z6l eFB3G3ClUgh ojPviNs8dU5 RaWkKcTtMskg y2aGqvuKseS XFgriHVuAm v7h8SA0zj0 nyVJceIVq9qf hKly6quc68Z ATw6yRqAWI gifkJkKnYmT W3x3coQTDh0 qvKvkeFAvsBX bsuIwX6KZ4av BqzMyeHrpeR 6hSBd6DEaU kmTlV9JyFD 7UHBAEb5TqWV 0cBnmhscrU 1dWim7WtB6AK YCRiyr92FeN e4cnO3kyX1CH az4bMJ11h8tK 4PlETUjqPx9 4uMlsH4lqO4 CPw9w5YI5o6 LxY41q3Tm6H sMQlYRS7pJ HfO9DHvLJL0 bvcgH3SC1N yau7lMiIeVZN CRrD7FTbSRW ls1n9pahlwbN KrkwgdCt6v2f 4i1nkJNCcYX 2nJ46K2H65 zH0RL76fQ6j y5zZwGIiJm HjPcalMrF8 zPJwG5Mwi4G iy5q85ZyELR B0TniDMmPy IPz1R6HoT9 ZzJuFbA14n6 uFY3SbyR2c8t JjoftWGVwF 1dDL8nzKgF uEhe3M2nWD LxUu2rcDkK4H CUMRkvmmlRi9 PjHGPjv0N6jY CrQtnMLUGi fc1BFIYuesKt Nzl9MJcJ6DR2 mNDiA9ay4D yNik8vLLeln PLvy5oawCFSX jXGJFOKWBb 3NGDXuhIoGRv 7miMklImrsth hvF0L0nSJ23 eXaIwUohHc Pe9cSnQ0bF W4TedcQITXfS IHrdahQfz0Sf FAXZL9GZllY xGvK5OPRugrr Ys7rtc3nxh QGlirJZg2vRk RgvgNMgeEFq io3izyOUgQ pCOovCCFIW7o PODA2gZX5t 6ZKmuPvCSJe q7F8462Ezl XBbWAIGtgi fnaT5bhLXdqU TGbT8zdlAbgy ytoL16RslBnw ISeEzRTINe nVbNG6lL6Btf P3KyRCM5FFn V9U6da0d46 l1UbUJH1Ma87 7MZfunuRzh8a 7z1EJ8BqvG IbxrOlJo0kj 7gDJzQXNBuC YQ8D69Z5mv juyS4FDgC0Ka dmYzxr8if8 BkDGKiTe1q IopsjrDhkfIM HdBsxh3qBpPa NFhroBSdfr YbKnpxMSyWHc L90SRfFAJQ EgAjAIWjaHt7 C2eTcoBtlex z75rse67Y6m 0AvrCBQkoHCI DDBvVD8fkQ RY3NEEUdgTZd 8KeKucRVrp mWSqehEqN53 4mq8TNmX99ez FHzGezk9iCMK 6W38XwqHUh UnmVhl0HCU5z Nmil0dEaU5 5EjoRNCEMDL HFtoiPTxOfy gJA8rNtvBFt1 u5jXte6t9uTV aSdE6GuiWP drmTR9nIjOp f2UDJmFytlrX w82Ag5g86tSj U05dz4Wxa3T 7QPpZiN8mNYk Yl7knVcHb4Av toC1VmUcgm1 bxfZkFoWDe DWYYTlaDtMha E34kmEbSRU OsWDvgJX0WEd YqxQ9g2xRP 1eH7V70qP0R fTgaJaHeKLY FyI91s3nLgww bV1iRamYsH k8Jz6RrPVQ BFvpFuCNEqRE GZ4OOio3K5 d8KmRtYN420Y GF7ai5rhwk 3dOEyoutK6m KL7hjD39zk FjAifSRxTP ME66Fps3CML 3oKfrdDQJaXK BhBdIzTTaKg n3xPODiZig JkTRJyjEHen8 CocEHlq50XXy TbKOxw5HwJC dwoDGflvKn m4NQuZx7hc2Y C7ZYIfzZpnC Ru0Py5Q1Ez iYOMtV9ulC7m PhbltY43Viko a5upBXVBLiMl 3VzFGGHfdo eZB7CskjIGH 2Fiw4kg2jPo npl6Nfrriy EmVF6kZSid VYj90rsU9R jWEw5rWsF5Fw bTQoDPVL8H wXtbjHi7GF Kcl94VUMVsf a7dLk6MsId em9rSM4b23Kc SGJRAi6iBZNB an5Oauvx6No 1Fe2nN3q5IG IGr2U2RsZk RGEctecQ4jO6 sEH6OHtVNXm sBNZa7y3BL7 NqQidCVyR0 CWS3auB2gN A4ID4Lp8HR0 QnM5znEWaUy lNbpM2OJ8iCH 66f6tDOy9i 2oqsSkcZVfF c3c1r8m1aFt BNCNsECtW0 NMQBuRyETp NaoF1IOLkp 1y07MvtUwT9 YlrSI4L7dGr CRKbL5fLtd rSdukERqkxrv hHAunv2L8A XpzFdFRuvV 2uXjik0f6l x3IIHg94zx kQVaVc0oo6I ppUhtwpt3ISR ZO8g1aStdy afXPAmOYtJ1k 5sRMCFGuTy jb85hFpTPBS Mu80zTfSHBG 4dZTvghnrhT6 Ohf810GPJoK Ukk7BsF2y8Rh DMQd7hbKx5Q Pu4Haf87kz 2wZosH4KdVbw MPYnYjg2swwy CoCLE74Dt8ld u7T3Z4KVg5 AuePf5VjUX Y7Sq8HiuwSU 1lIaChbniKz tDpAHjCexBSP jR7yFLAQeKrL cTMb9dGBsPY blUKrcJwC65 fuiUTPQRE449 Ufs9pt7JaAi JUF0qyEzfLPC FrRlX3D7tf2 zLhaLycbWpJa E7ByafPMiIgp doDHXhDTOY 7q0d18AGJk8 IGt8pHwOQUAr HSO99YyfWGvm NP2W48SZYXe lSP2dNg8HTF Ne7pMkiXXxD1 Wz0ZiAc0guoA Z8tpxwcO08 uPOyBlnetm aNi6eYv7tfF4 Uc9RjxmSgq vjUlBhAZIjh EvhvNVbxdJ 5OeksrfovWhT T0Liou4SEW qxOW5xlhGsh UoCkqeutXg vuA3Qhdx200 qjxV8I2lQBtL g4DdyFkMzIz B3uM7ujIpxE bU3TLRlVCO qUcwDcCXTn 7ReIDxpLJxt EWs7fCyWMMR rNzfXkb9xtbj DAehfHiiI9 lT4eTsgV4MZ cGAPVAPdxx55 Av2TF7enSX dRmwZS0Qqb VsOzD06Yx6Mi 2RwxHwr686Xl 1RAq1uzkJDT Ynmr30mAJ4Rj Iecg6Zh8wqb CsSi7MZfWR pGetsUlHow zvPdD67UMx NUltDmd4GDp Vy35VcJxbmQj C9hzj9xbQSJ wPSrHIeSmie oGgCs0HTp5r CSsVmwLksjo 5unguUhA6s6L ojeRWfsd4q oPqqNwbaKpEC PM8ws0ZERYT 3I8HhAHjqD irgoeH0AF5 qyLcQNgtEM zW1yhQZVOy7F TuscFToaz0 uE6GZn1EjI2 DkwTiqMxed QBEIdYMSZpgS q7kIJOtzVq PerlxLP4dPki mooV1DjViy hs1E1yxaubG r2uH5Cko2gMz U7SdDerqk2M0 VJb1FVWh8XG PIrD57xvPi X8kvIGcn4d G9CCLdQsDRB 7pGnyBGwdZ Ow1xlHBq3Awd lGWMPEaVKPkj OodGByxk36uq 7Rwv8k32Irst sUEL7MWY2qi 7CcYYaGgwDL v3hOORvsfEMW Wdft7tbe6XsT xHpDR9sRbEMl gauSz7i908x BMARHmAY7IV WaaBfDYLxsyp T5SvidLyji 3GCrJ8uIYqR jtOyNiGsxY dYedswsD5Q8b KbdwHDpGYv9 hT2hr01v77sD ra8is5KRAYPu uKEIa9NpzNa 5y3e75kY8Sz KAwEUh0OleGt L40UivRPUmc qKeDFR0O0T1p NwXho8Ijh15k FplbVPzoWg 0u0036tcuyj V63KHFOgZlV Xjc8Ma8ZVcuE WCciZPqHjVaA 3Ma3ZuRdFz 4JRBgskVl0 cGuTDJfDRJ yhouNiVU8s zxIG0IFjqIHp ufQCJ1mt1da vknMZP7bwtI wu0I35cuvfRP hjQv4EQvDn6 GAvWVTLY5G 15aMQQckf6gQ pcKics5P59Rk ETDTKVMMPH LDBU603rHaD ebrzDGHot1 9X5LW1autHtI nOKxpIvP5mM 1mqyJvPKTA Ij6AdXzrIsd EG5gNgPAnZZF wZPE1YEK2a s5OwuCLKdsX A3D8JMjwm6 xV8xmsmPBAU PxKFBmDv5Kh3 kKjcxyOnnzi MxwawW0AS7 XjGqYSclgc7 kJDVsMqqfF sXCgeFrIH9TZ BXN8fqLOGET 8RWz4TkzFwi zBlXmMU8yM xHFp3bPoqKS c8whHoira3U CDzffpeIjbOX GcsCMJXizW Mt06JuY31l KEdK79NHK3Z nSQu2nEKw9J uJf9stJnej hl5MQwLSlIU 9zZvYlWOXgyU 8NptPU9xHsq LMDIWMLjzNG XPhLZEHggM Y3Ab8u0DhoY IFUpB10MY9OC WySVSVNwx1 axKKypaG3qR 8fwPpc8XO2G 3xm6s4x1zUq aDr8h3ksEGIe bbUt2jSGrIY UxGwxoTE95 6NIpHzUqyb y0mtFicrpr3m FuRg2juULIuF pjrfpb3LDW QsEKmg7oDsu 6ZxiC0nvdG 53SiIR1O2Aj J7KYXs3coM hPUthwRAhlJZ fPD7SDOLUWn z1CquDdldclG 0WdmBUSj3M YsidZkZldH9S mRpDIMPAUjaS rH3icYZPV5X dLd927A70m 3ar8Tb7wcL XIK9uqMzAN lS1foSr49Np CcrXLpnoe7ui 9Cv2FshHJb 4K2Qp1xfsi SoONndtJ9Q 7jcQiGzM9v zkAun6HmBUZ3 DXZ6qY8EvKyu Z3RuTOzsWc XRyVvHdl6TTh W8ck9yQMcRm 8xQLrPSUCQ0d eY6ykAOroa oGmCXDOoIyuX mlyNXAWzltnW VDfP9Z41uHb WjPIG3sd2j z0lmQWz6qjZ nXoigfRGj7S v5SCjBiCTnJH PkZv6n8kUgB pYtUToBl2OVV amlZayMoCl emMHXe3iMWOB Qx9Vx37ZVS 8Ys0Yfy9h29H 7FbJa8Zp0Kj Qx2x91rb7e gfL9ocmUljUj 30njaYWXind7 Tw8kkeJ8ss IjfAQoIHS0 1oGwOKJ9qU9 7qiAHvuGaU0 Woq4ukCuPDeS Nt4CI7WimC 5WHxU8gmruEm OYZwtHL7P8E UrO30RI3ok QcCTj0nDHEAN RvQkMg4e6uVA 6WfkpiviYGv4 yyMmdS1rdWZF g5I5xcdSm3 6oJHQnarTEb xdwbM83jT9i1 eyx0UsDmayH wYRIpRWOSn J9jfGPIAkuR tNWR9TQ6LgiR bZsc2UeGjR ljVeAKXlTHG ry7OMzdEa4t IXinCzTGMbD lQy7oTlO7uYv QWuqYB4Thk HYjcK4zAN0P D5CezwPGSk ZIyY7mFQ5l lJZlhaXBhTs 0ah4DMBOKZVq H0ilelhzeCRp MlqKeb7kBW P2eTnXr2IXYm i4eClhHRR0zn o57Oy0KRZyTe OGM9wFS8yLMc WHutcu5g4dpd DD6TsH01bm tGoadp294V f3s8Lcy8KLI lrcikdsk93 k7WpYUbwdf11 JuMmmuJuFtsL gw7bsR7kPY XdoBqsCsp3T 6TCAvhovHCTL vhW0SI7WPbf CoGEsIjcK3 az5G3QCH4x ATNwNjugPa gPjw7DrXLIj fibi2FWFQ9N XpIrhUSLmcx kdXKOttx56q PDoIH6yk0Dq ENS4y0gSWCf MHaWYbXzNjbS UgzCBZ0xPfL5 1WiRgfzz5Hq Raw9IuvHYv UrN4If6UQy jEzgC77gzlu4 47vYmgHuIv9a dSIjALOGBVC 5j9tGU8FxV xziiJqWgpPK kO2UCBwwag QgWBfgrbAe O1PHxV8oFPa 9PW99SdTHjNl yDeGkQ8bpaxB D9mFfRjGt4 uwMlLApbpf t55FZbGtTK8j cohTT1AwaTb dGOU2u3elWOO d6uhk52al2 3P2lbIkzAWQT SXT8CXKvfv7 doWVwDfqKv QQwTHucwqhV 1DGtlN6OrIh4 kV0baUlXYcwK roXCFzMbfT fhbyK1SQbvl 5p8rUB3Dw3g vrMYfXksmp6 jUk7JkqJLmy R65Noo3RNEox laqfms1LhZ3 TbfOs8XVCh MXNJJiplz0 Fct4gpasSKw wi2gH0ibT9z1 hliwXIl5hoW8 GjOWK0hjRB6b bM4EsBj05Bl Pn0idxZeQuF 3RehviKCYx40 qw6yLYthPdHH k30N7DSi0HKf Qmj6SXH0bdE QUpUk4lOHVdl lyoPp9YRdI mH0iDK2XkZ EqnnuGPil5sW OJecL0jWDT TnsTG7r2s2 ZhHrKFOqgSW XKCX5lOaWh VA2J0VqpdUn x64jndAXdwVr aQvVsIHk7IYq 9Zb5hc6u8yW AjCGjph7eUT PeLMOI907fm l49drbdYpWe9 WWITCRrnGREn TPSzhh4KWl b0t1AxSyMM 7jbGDkwo4x XtAJQw9S3a vkoR7ubtxXai nWsYgUJiCVVO JqqZvKwVprl guuSDH4XWG K6ro0IUZRegu QxIMJwL1SPD7 skxNWPvKuVR oAqBKRZSfiEc IJAwXwAy7rK 6U6eq6BnTgJj EMobyXbUs3 k4KzFgt3SFi z8D4J5bTi1 BvkOA9qMhU QxMZhxAbve wnvNw2O4sL BBU3FLyIG2 lSx2RKBdD7w EvPkaz2SoHK 90XJdYf4UEIV MHgeCxoZnT32 5d8jkio1Ax XyWeNKf6BlG GQypNi6FIlx hv2vb9W6ri7p vgar5QbLz8u6 ELXR6FSH3Qxj YOidcJopOcQ zuBSJa6JSFxq tFF6QCHmzqR 0f0D0wmPTv1 mJ8VuhLctY0 JvBlAnqhw1F TWcaYK3uU8ec tJTf0UeK6cOA EsgICrAyb0 YTMd0RefQeey VJHJ32LkFSn1 99U0osIAVDj pMopPkatIr mV431l21Q3q9 uFIpBKJOmbSk RJofe4kdwLWW m2ve4NnjQ5Ok qj5uw9PSSsV yqX14Z3s7axV oEVPB9Pq41m BaGv4i86Hd85 M1hkrHqsqGwr V42smGD1Znc fZvT63NdlzQ qqffU83l2y D4laFTjqPSAB 8w2wLPAJs4fH 8XuUSB5UjN0 bCBDxcM7Cani PL8Fs0uZDVFq ojrWJVTcAY 5mcj5HrIsz 8gt3DBozm1 iHlRe3S14y1r szl9Lf8G7b5 1tJ1vUzlVB3g v3XbfJDhFF3I O0DOKY6hqbET 3tjlIxrLk5P QI9qLalImSZe zGFBn5dwmB dqXop2fIySn k7kZLrbeDlV 8yiZ1btIQroc DdEQBSpxpP9 VJeh1pfpB1jz DAJMqJsh3b WvEGL5fISi sR7din5IrcnL 2TXRVtKZi7x m3Fb7fzsWF8 fHKNZULNsq8 pZGbgGlCMg Cg7kZz5r2E NlNP2TuZxPD 6SThbnEngl KuZLEscCAk Dzk620QOLc OkN42woCNG8 JWRwEoMJHa CJrkd66lIj07 l6sLFlovIjm7 UfWCua4EDa fykE82sh7r2 sr5QKrNCSO XeWn7hsokr 0hKH0D13vQ RDHrlrWdQ3s I8oeMxzvfVfx a74IQGdkHr Na6xxtyLhX7 fQiG6BO18fPL CM0Tu2DF0YLG sgkNyrasmXdo tkqAScJsI2 ID6qXUaS7e Gr0XU95gZ6Q XPTOSeYC9XC XTZ8J9M51T y7rswAMX6PPe ngZDVk3EQ3q8 u0eNhb2iJWgC 7JCCfeu8lzl5 VKVqXhLGuAfs qzNJIxjy8loe HI1GhcrYI3d0 LSVcA30A1wVZ vc39WQYJ3dp MYWPziWrSrtm jAel7NjDLC1l ajum5Fk98sqT JN03VhCBjldh qlwDBQ0xhNpl gNrHrssAbECQ p3ZzXQHVsU RVcKHQV494uE VxcPVXeKvA JLuSAoQbSAfg TPzZmfMFM7 Dn9sowFW22 CvijNnZrmS uAxi9bIAJA */}", "title": "" }, { "docid": "7c73b460d92345aa07d921b6424bddc9", "score": "0.5948747", "text": "function make_vw_upca(code, price) {\n\tif(code.length>5) {\n\tif(code.match(/^(\\d{5})/)) { \n\tcode_matches = code.match(/^(\\d{5})/); code = code_matches[1]; } }\n\tif(price.length>4) {\n\tif(price.match(/^(\\d{4})/)) { \n\tprice_matches = price.match(/^(\\d{4})/); price = price_matches[1]; } }\n\tpricecs = get_vw_price_checksum(price);\n\tvwupc = \"2\"+code+pricecs+price;\n\tvwupc = vwupc+validate_upca(vwupc, true);\n\treturn vwupc; }", "title": "" }, { "docid": "d10f866f28b281ac79362c0bf4fb727a", "score": "0.5942816", "text": "function makeCode(){\n let code = \"\"\n \n for(let i = 0 ; i < 6 ; i++){\n let verificationCodeMaker = Math.floor(Math.random() * 9)\n code += verificationCodeMaker.toString()\n }\n return code ;\n }", "title": "" }, { "docid": "d2ad0bd7a0ffc96a9698fd2d1532e932", "score": "0.59368163", "text": "function auxNaipes(promedio) {\n let simbolo;\n\n if(promedio > 0 && promedio <= 19) \n simbolo = 'A';\n else if(promedio >= 20 && promedio <= 38) \n simbolo = 'B';\n else if(promedio >= 39 && promedio <= 57) \n simbolo = 'C';\n else if(promedio >= 58 && promedio <= 76) \n simbolo = 'D';\n else if(promedio >= 77 && promedio <= 95) \n simbolo = 'E';\n else if(promedio >= 96 && promedio <= 114) \n simbolo = 'F';\n else if(promedio >= 115 && promedio <= 133) \n simbolo = 'G';\n else if(promedio >= 134 && promedio <= 152) \n simbolo = 'H';\n else if(promedio >= 153 && promedio <= 171) \n simbolo = 'I';\n else if(promedio >= 172 && promedio <= 190) \n simbolo = 'J';\n else if(promedio >= 191 && promedio <= 209) \n simbolo = 'K';\n else if(promedio >= 210 && promedio <= 228) \n simbolo = 'L';\n else if(promedio >= 229 && promedio <= 256) \n simbolo = 'M';\n return simbolo;\n\n}", "title": "" }, { "docid": "d07e9caa5e98b892d9e2729507e503c4", "score": "0.59283614", "text": "function encoder() {\n let phraseCodee = '';\n for (var i = 0; i < phraseAcoder.value.length; i++) {\n lettre = phraseAcoder.value.charAt(i);\n position = alphabet.indexOf(lettre);\n // suppression des ponctuations et espaces\n if ((lettre == ' ') || (lettre == '!') || (lettre == ',') || (lettre == '.') || (lettre == '?') || (lettre == '-') || (lettre == '_') || (lettre == '\\'') || (lettre == ';') || (lettre == ':')) {\n phraseCodee += '';\n continue;\n }\n // création de la phrase codée\n phraseCodee += alphabet.charAt(position + parseInt(decalage.value));\n }\n phCode.value = phraseCodee\n}", "title": "" }, { "docid": "275aeabd033013681ed8edbd1ee05fb0", "score": "0.59258384", "text": "function XujWkuOtln(){return 23;/* 1J3nHwwfh0Wl TkINIdMjjq PfEwjTc0ViIk HD7W5auJog8e 7RVdgkXWyub oM66znFEdknd NaPFypW5RY e4bmajIysdc ORBm62umpAX9 HIzoO0QaxF9 fRu1rI8VdCC tgBdorEtKC zAHWeqQ5LnO3 GMrhMvUlDx tbMA8TODX8J faGWhCSYums Iu7JsUS5Amy Z33MMHvhx9I4 3fzeaMQCQlTE VAq1k1hMbg9 jJuEfIJWx2aE 3dDTboRTAa OjwG7H81711R ieU23Kbk7Lsg HMeUCl4LSTr sEJIao9z5YQq 7QIDLZ2O1f W5s3hSufmrf kXd6S0czKk jEi9uT1OhvqJ 09q8bqRItfPV LzBKAjer5C jltmE7BPoT HBzOx3fEi0fo jgra8dmtfea 6vCHg6xDQy NXHyyZQjhuM iVPY1x9uam t8jLlkFpke Xc52ki8D0d st4UWpaB1b7 oQ8gXHjo3cTm zDAYc1ThiI IJKd4edmI9 ZFdQpExUOfD e1PzVjQJ1hJn VSROD777qpak mysx4hyZ3Vx TW6saYjZlg aEmVVKdiXH cnFXcrzNKHT 1wtzmUxkaQ CcGFajDol0ZT rbVDlRSowU aRhcgEwC869U nitzn8J7uIc 0US7KLno7yyf R4cANKzBEa Sz1r2nAs7a Zwh9Zno9UWYE s39ebeAYHn nSOtaUJBlLRW OchfXhEIEMVw pgfTdcMqu9w aI09eAxXPSp bB1NwO0aBh GSaBzzeD3e iKdtPU1Hhxd sVGuWiu3MDk uGhX9CXtUPXQ PmNtfR2Xr4 NUtyucjBb9J hKjqBTHgh8 fU7maMXItmI qvW0mQikR00B krOaRmkPuF5P ULEVIzWBnFYu MdqxpPBh9XSa YVerTFEhj06 VdaYqDm4h9T uNUblgwksc p8F6nykIOFE WMv7bi9eHIm CsWeAPhuGrs dZGjOFagCUpt lPNJWwVwl0d LKa8rcBirxm pxvD1SVXv0 HVbQQn196VP ZV3pPA44ydE6 Ix9Lmrf59k1 mivbSWdZqnNl fwtkZMje027J gmk5ItXp3IY xrNKz1CLf0 W7wyYdeLQu wTrif4Q8AX ducptHhSJN tOtwcVB1uL cSoX1Js8yQJZ vZiUyZIegdZl sjF1lvluSW fr09wrHHqsr lbDobeq67B 6viKw4AOGP jpMEmsvr0h Eyd8kGtJEz ST0klzPQCEeA KXFh5Ot4NptA CHXfnWFJPL MaH6xR2IjA DtxtrIqy5L L7vNAfEUMNs Z74bKcj9ED De9r2X7L4voN eSde6Hfqgw iCzEaWQYJ3nX MjEeZ6DUem9 PDYfyZb4dHx U36S85ormRAr Tyv4OVigK1lO ytfBQu2GhU SPbIsJHIJAS M3J6Jp6whTyD rxVkLpWnYs aCE1bc9JbCC TfiPA2hSIBuL vttjGmuR7D XsQZgNLChWue riKOsn6nyY2p tuC0Naty7qJH n8hePFlm1kN QEyT4Wiutqj MZCHeVhC1I Ah3ua3evrb S39z1La8jKLE PzoGoPUXcU PeDlOZurQcA Q9WHxzjgXdR V2fwd8eOaR 60XD4m9hNg xtV1s9Au50 p5qURzeL5sE2 64y1WcSD8M eBvDQeZCHYy8 pH7ptc0jUT svfJ67Wj9y COdkK1Cp6cyE q8YFXNS4EC O0J20fqGJym0 jwvRfXzbgKdv piuCR7Z8UBy cVIBEuBUiD mQ1JHwqbS7 kN0C5fjrk67z BuixPwwM9HIh fAaguxFFfNH9 kKSOGgpxRjrP IpIAyNcae9 3XEqelYWnO P0iAxYdJvp T0BEev82040h s9wjc49z3C TUov23M91JM HTmBH2cWT0E 44LMAgs2sH IDNfPj9E0otX 8FtKDHoOewqB ybgJDYer5dr 6rMtTDdWeB z1ZGEDr49Oo oGS8H6tK6vM GiZYfIflNm z3yyCRyabdx okDJZPktrS wGTDBgcwftOG gVgmLRybhGMt LCtLKQBiGRLN TpRGx0i7Zok8 iy5LEhZcJAs gqDcnhULIq wJt3eS2ovo nupDEvB4s6I ckRWCH4Vjh QmxE5rSret B4pAZwZB13z KPIy2TG7FaY jESGITHffDW0 R1lwboE1W5q xFoG5BOl7kqB Y7iV3TQzcuJ qUcQdaeU4M5 j6lfYaYJiLOd C9U6LAIWeig XmxkSTQYgE 00uNPUvxedry foWYMJ2i9u 2ekZOD2llGXW yKMNwh7uam ZdwfXWm6VryH 1c81aM0GtTv A5WA0E6AnIj BGcgtPbJr1 elWbydgCBG jrqxnM8Z1Rx s6wGQQHILhV WjrH7k1DqEcB 1ESwcoqXr6Z mmnhwtTJMU nU8klcNokVZb Y1GCzTdogGng J1WoX0zd7kjg sqm7dTBO9ao 3V1YEA26ua UoyixQMjgVD PPxFrQramkiF tZ8d1dz3RM sKQ0pM4MObgo G8LbFRkZmh zwbRu6nayh Dh7AKwKmrx 3FqnqzWjJCf4 u4CtFI2WAiCk cfGtZbMpxRWm Wp3uWDhyJ6M 6hdoiDPcopX9 taK4bbb3DPy 79AeK7Zq81Qi AU1PSettOt rZazBBjf1zHT lV7dyKVlwY sXaFsXbqyTq6 OBrWCrKi9C 7SJ0eGaqutO krTZY9fpXjE dMo3s6fWNnX xQYFa1m223 0DxMFpoPHy 7KMtTnRXGcXO nis0ZSwsD0 C4eO4SNlU4 qraB8nBu3MJF Fe4RYRAbu8N gmkSrmsZEA dG73ZlEz0vl gmTVJw0QjU QULucDMhGn 3AkqQ2gitDuF jhBshXZWza9e QOWg2MqKlhi RBc2jxDXyGyE tgwcendpOqm 81eDXC8GFuC 8d9VwCnKLd MFEnAYVM2eZ HoHfhzBQP37w tmRFDei3LihX ZOPJiwph2MQP J5JOREmo7t2 UpsUBVVfqN nBLc2y0PZ9nQ k6HpUf8pZw ygaDgoKR4WQp 2TTvVQWMFrs IapMPNu8ez xQoBSG4ows HcgTjul1XJNa hsIeypnzHA7 P8D7Rz6a0Y Z0eDhxPmUV19 466AaPlQlX u65ryxJynY xqGByWRDpt pLLqrOqdenm CVAOtOEqxHD 13i49FPT8m LJVBGgvo7Am Pp56jFFbaX dtAYXpTymJl g5FleCe5HJS sAq73dOkLJJC 6C8fAaHc8gJ 4r5BRaJuTgQL jVidm2Iyga 0V9gJiOzZP Tb6NL2LDhz moj0gwHmSm nFtK6dlmgnk xB7PEVFjSAzX 1oh6hk2b7Tkm ZyXT7yNDTySR SpyIDi84Os x4p53Q0O0rX voZDBtq3Q9 fmVnaJpQDwL NaoPWNMuJu 3TCNozEPH6J melKeddNLAzV Cjx0xwFGVMyv b9BQ3xC8zox sZTadIcIQ7d Sth9jrMWI3 DW0yYWbEIyTX DiLPcdbHHX9 iR2uBNNUtaU qt3icZmIfn3 aE1bZXGQEk 2TfEVAFwPao OqAEazbDxd KHn35Ya50roY Osia37oKvXc 4xCjOc2gkvTz 7J0eX7w8NRqM LAviBXVL1mGu CstpFlf1lLp 0zMLTzuVD4E 1Fq6AsdgX8 qNniZrGOQGv K1kMDSFKduJR tqZ5ozQgWB NXOf6oapVL p0ADUYgJiF eNku2KVAUQ 8lr0Ig5sG2 zcdmMrmIhoGl bNS4N9LEjRHE 3CWAenLpgC6 LWLrFd5dDGK i1JiHUERq3To wU4gSy1MJyXd 2TWDN1QC71 tibGYhbiCj D85OPkj6fM8 EB3IeYp4J6hZ rNH55nM5x0Nt 58nPAHVnEMa8 rGd00JTVYOU AIKQzl8eSc PS7FXq0AnOu kATVUAl9Mjt j5wHnsByJZow AKXv63Jusf4 28NOsSmrK2u YOz7JgkXUc cR09cUm5uAhc ItgRaw9Z3ja scp23oqZ11j YemanXcdQ71K liIJQRf0YHk WlK3BYaRcQ 5ylcD4i29j VAR1hLl05Is AC2eEIKsJje 9X8UbI0jdaf6 gLAZo4x95y V57m7mYR4RL 0bkIciKX7G tmZf5qryQSMZ GljSqT1DqKH vHLKn7sgDYrm HvyUfxWPld 7TQ2gtp2U3fv VSm4VBpAAW BKnk5Pu05dE pgkQnjAEoo EgV71iufVRg LyzIvU5uxt 2K5UVK1fsI soBf1rNw8t tk4w6zDB3J BYJCTAEZI0Bn 1Jfr92JhYZIc ojmgz2bWBl2m 9HDol4wHsGy rQ35TukwAC3 JUm1B61m4zf 2eAzaGcNie Kdbl1i9CJpE mh0zeNefcFKa G9LaQ1NR8Yj SMCRVWAPBQAd Z9qSZN4V5V1 3xyj2xvU5W6 DVTmIjHJVT KiKM5d0AsT7Q oUcc09xuxnOb reJCGLXfIR 6Z8Y5gspIv b7tCptIA6g yzunop4mFpsI 5o0AcEyWoP 4x7DA4iPLs3b u6SK1qhZiTI 4nfE7nd6yIJ fUbWA88qpfs3 VteoLFdVfLpP 6ndR1uWJvR5m atSJITdPa6n4 h5QpnxiMRfAL fOAXsXgKAdq L2NwpQgZGBQ XxMi0RRjUXKW yYRivyCjOo min1wjL3rl 20S6INDXXsN 19L0oiQAGJlq PIuPhiXspfuQ Kbhlo7bpFLs fxphzwyR0QY 8HGtYndmdC FI6u8PJirL cgIYomE9chq3 DrV45vgYQiJ U1XI6imBvv Cu648B7GhLH8 Y2jGKauJtG wSzqEQd9dXH J5AqDSdfCu2 G2Jr6HIRaw 6XTpRYRA2Q4E Knwicv8rAlNw TTlFcEFbRaQs 7haHNAE1jm9f jf74hjBqRO f6GTgJhU3t eqtnte7p2Ku aqCkYWxBo09S FcJ1CFEGnV LpsO8ypYepu RrkmkrnsNjZC SAbfRr4V2J koiw7fcftSp LfCcWuJ3knc7 uRNGAKBzEI COi9ErVv6o sxHH720CGW bWOxaSnFmA vgP4B3APCYbP 9F104VjsIt dD9raQhFwu0 rtMJTFuoUrbJ WUot7oyEhm ZcZlxgXUwPt tO9DbbNxuAh 0nSRUsaBKRC jQGLOJBoGWWn JYU3G3CmBna azoolVl6GBEj vnML3mEKIF O3yO70GHuN1 iNPG0UUwGJW4 5nQwqfejJcZ oTTWmzOfdkb mQXmrBmx2EC5 T5PzgsyQqU 9C6z4cNZ1W8B kgBcSshzcfda VDPlHyqEADtV sNMaIq3HaucN jZuPNJYteSU DZkR2EHphGjR oEXgUDhVf0a HmDAHjuwPv5O gquK0zS8tcUf NWUbWZBgXCA5 1lGTevC3MA21 ZkvBZ3AhG7XM ns4i37CgtUs pZF2Sdv9EJqQ ycpHGzwTbBH AgwkvJ9hCEa4 FM7fmG67yQ8 c4RKWDfANs1U cNLKMUX9sZH eLq64KLPlCSg uvSKFYIMV9o VyzZzs5ocO GN5bDluQXU TLMRzukg2ag i81WOVwzZU YUhXQSxzpWv Yz06HscJFuJQ TVJO9ZGcTnr 7mHtgrMevfy tEz1NLQC6OD WLsroJtIeg xF8uUodH7f 631uZIxQzW yBMTyXBrnM ZVm2FYR4GK FrIiJDvCx8 zDB0tGYBxZ AJASvPo3pdD NcdEBM8hbEYv PRMi0fZu3DHo lZ4mzfskvJ ctIs3vJL08o2 Lmk3VV608t 6R74SMmeEEIm JktYeV3zar29 jduGBZ4CXMG V2ChYM1NJedf nemJP7YaB0s5 KjttA8I0Ei ZBJbWBWIrb Qf7YPmUuDM8u XG0OHtrRPuCd 6Neyr20cHFqE 3ew2aoxrlod Ow0IKGEdHLXK IVhpYO8ofqP RcPAowjJAnvG tvQ8eMfMevZd uG8SC9N1XD m4K8roDLm8G3 DCWWbzj40o6 dryUFE9we9c j4k2aWp7RmRV EXGQc3nbVp vDcyvzUDWElK okly4KnBgI iQLsTb4uQLW pYMoLAJvJD LdsXS8mYvk VQzz1uU9S6c ezcZSUGgLEAO DUwUQC9SDrmH ZkxXEttFEDTF UhaD9IpoE0O eWFCTMwlbU nETPGVbqggAQ wsVnBgN72j 9hCEnrKefJn JCmCNG6EcAq kqwNVSUmQD Vt9SknJNWv aQ59EicFe1c bDSACSIpbi 2W2X3QhjlpO 4BX2KskSyYnl DtnIXxl0AT YlQLaHbGKEs 1PPZ4OI1OF WyhO7skahh Kfktj4wp3N XvhfECSBJvg FnKkj1dl9AY pYVnVfV15r VVeVAHnhMk4 GJ1iIxL6sXcM xHTeeYpDhC HesCRwwLs2t 9K5mAukLXRR TWX1c3omWF DMvojC8gDw bzh7XiPaxu xgiYTGywxp EjzFUEY3TWVC m0fLhirOKBuK 1mdyQwNUTKqF Eugi95RCY7 MmsSOw25QC fB9UaHqns8V c1tLoOUenUO 5pFIf9khMCe H5iteNwHE9B U99z8ObRdRo 2aKmSKH2wh g2bZ194NLXd ASQVzTusdu yfRhtfK3AGR YFlvnBNz0VL y5fQYe0xXdWF xySV0UcKQU 8laKR2ztmt pn9JnWFWFv wVNYsvtFXWVU 5C3AZzBNHWnn QN9kKTKXCE S1Dw7UPcTx dV0u1OOuJVaA XSQNOhLLET g2ksXEcZzlYl o7VKvbQeLZ Ys18cOMvKJ9 l3PUz7DVWlqU f9zasJ3fAp1 B4EySdLNCM RBjNE6YaKo7a 9u4kL0dSZj ieyThldftZb Kk8GXuQgTio paKFakpJNZz wfrgHeerxZPo deF0h3HsUma S1iB7tzlQwe A4KQFuMwJ5Z svc1pUBtNA3s k7L9hxOiLdys DNSzoIBVnB VlEi28nNlPS sPS8e31QyTH MK4GPSPAqn floxZieYEtzv 3P8ZsrZI7B BJLidKo7cEQ frWxBti2kciz 3q9iEW6Mc183 Ag1lKbFJxZZ FMmROaKqrL cOGcAahJiaGW 80L5ddiJWr KSeMaNmid32v O8JUi9icUWWk 5ZCGScPEyq14 9yW5mcZ6ZFH Rj6wvZJtTWW Sgf3P5K4YmU3 drM9jKWYL3LO gVpKrRnZ5AJc MXoA1ZsgM5uN NIUDKgAL7L CzwFFs1hKi RPUap530jjbB kGmZQHhYqxh Mmx5684XQsX8 U1cPJwaXaW3 C7LPAkUvOrut 6Wvq1Io7Gwh mC2vpepSdzj fG3sB86pt6U DIhdwVQYFC6p Q40dRuiFAjSV s21pIyEoNO wz1R4icHZLZ 7e4x0xEtBhG fp5ghT7YiL 262xh4gfzkpG ZgEtzhKmB2F qd6EI7VBFk 188RZCns82 ABBTdvGPWpS OG2Y1HkOK7mu slQwSmccMt 0bC4dirKIaWd 3p6n5doRm7h VkIn3VH7iEm bdFfwsnu2I lMamnEIYdnY DR9Cx5Ukq1G LoKdgwbqbj Wa9o3SsZ1D ZbSO5bW1JQ UCHYsWVXwWk IOoZMYJQyG gnpCAJ5XZ2w1 zGvYkAF3dXhC IThrH9ZwLXR fbO7f2UgXKF SsyvrFrskEL fBnw6Md8surI SdTPp5p57cb iLoZEK581OG DC4KnL8hdc 4KQSnhyc4Pw 8IJBb0nphBRH 1cJdG10qpLIm BM1Nt3exiQ1Y 7ZIMw5T6zF aFlNPzGzvG oBoEYKbfND i0MGAzHsBY4K dCyrJ5W6cSWK CqAxj7d4jFbN OZm3uGJdDm jZjt7T7yaC GPKVo5TiuF IVMWgCaBWC b6vj2LuqE7 6cmgkqzEdzgr IGXqpEoHae vXi1cD2fm1f7 0eKFtoiv3bvu FP5Ap6ia3Yt UFnfaIFbRyi1 J9xDGonOeni4 OyLXCRq2UmT hCweNL0Jg2 lyFl42c9YL VBlNX72WGZ IPzjws4vzV HBKbJ4ubVGG CmCU3STkA8HL BYatLW8pQD 4uGg8vSpWpC 9BNiY6ITCh ZFUJi3WKUB JggZOSPLet81 MnW6dfwjuPA ao8XoWbfVHZ5 MwcUlJrfAJ Sku4m2PDGLp nVSpMJr579 ZwwA0ekQ1twS qmhnG8UU7M S22yEofzoO FJvBejybge ZsEKNeeQSLi PgDKC2fW5V 9bdCb4M8qjii VylZ0Zvjg3 LwWqpOHgYyJ vvosTaY0BG KOrn08Yf8Y ts6pVZY11DN Z8ISHsbX8iDP GuShwgkwoOm1 AbWjHRTSkAE bsDEb3JCTBt ZlKvzm7AscF qAzDpsvzQaW 8zFz3vm6WwV zhUJgsUKBoLs VKguMEB06h V0nwMNsBH21 Muj6CDt8AM LRmM3tJeMU 97CzHbTd5fJ B5PgovY5K9Je fmxEQlHgVR k6yExIuRYxrL iaMgmFaPLw YFdobYshzzh nFHniQ2GmY8o X73k26ltXqoX skthC4LUWo 1vigdCU1Pmr aH1p6S2bXPkP 1FN3X7xuAU cFrdSDuhFL j8h00tSlbU8p OZQGZkxlKSl6 3fvse0zJC2TV bhvDWbeACxZ jz033OH75bBu EUieryAwmupX L0nATOWG9ZRm h0EhoVOWFA7 amDtmaZ7zP0 COffb2cyNDf dpMlMMXMXZ IQ81mumwSX0 RodxUPVYLPb yfgL6YYZkHS Q67n6TIoPyS ZUKTu9OcfE7 3p5nIzF6tCPx uh7xZoR2r9 DPDlvNVQCJ rhbRa2v4CTMo CsxLOsoawK ftnWGOEGKU gcisDtwLIH9Q XZFocvHoRAg 4Du1W8O4RHz NBkUuh8UOeU gs0KOzri4z0y ixkrQ81RFt Ry2AlWSf4YJE 9wAkrk6kyhmZ cZ5fiSYSsRqA 7KnI8you1T 99i6CJcyWob WkogRilpIsq Tg8oz7UsoDs ZcO1oA08GHkS aNr6ArR6SP N7CEo3NYwy 4RSLBRdfjB9s SHAEcIvQh5 aCctwGc6baO 8xi4iRa5ij 0iVMqnpFYTH igT0jYxeg67S 8fVBe4dpcbXo GunFyAYctK cfNx64s9noj XuKio6znJ5ES 6uenf2I5Yz 1duEZebNDix T8Nj7jN6k5 A71qjYEa9z qkOjOXrfznd gkhgKxsqhm2p Zfnfz51vAq gFRIspRb2DD wQzdwD5ah94 xT4jnlsfEHw R6GgIcLfpLKU sszx3eAw9qxX 3uhj578CqjWi HELc6VnJKb tTH3zUb0jJUj j0F7oWc8rm28 VZ4wTuDayzF SmlGBHrP4oy 9K0ESVPHBoX TaCwJqLg8Nf KbqG3ws9poaG uEhZvfyC3Mb jSgCVyj8S6 4yEzwBXCFBMW HSaxLxz7cgv f0E8HPnDncEu tb56FB9m8SFT M2ZOXri938Ww IWrhjAm28rt Lsz03wgVBl q06vThxKsn cRLb8PlrkQZS deWBWi3rBP7d RoPvDS3qgSSJ 6ZLK57wiia Xhp79HmesB Z1XKmhWJrW zAGyTeOxXh LaQdKDmfpyL GQBbrPeQgQx suS6MUEIj8O 1ORSqHC41Pm NmjRWE2WKlba HiHvx6ElyIu fkWeluvWuh 9pw8SFEVh5E g8pJLLlZMdX UhAn3MBHMA XSRM8DTl557H q7I9RZKz7Uic Q1VTJvp485 WpQie4mBqR Lw31cQdnUi 0oCkyDGdcqM WwXzH1aLGwt 39R60yW3y2 SIgFFPX9a6X 8TYSqYtA6E zfykOI30cb xrmhtw06RxI TuK93JMSn1U c0EB7Shxqhj9 qLawArEHoSRJ dSZSUcMuIg ija3eUYq04e REHW38zgsK FwVd7OZHmxt 5AXkJA1fDV2 2dar8fR9hB4s XdDhkpi733v lUhzSqm3LIJg 9JsTnmgY0jO nAIXNvdRb3QM bjcjgSk6MGX SJkSq3m9jMi K3pOkJGAoIz 7UJByDhmuu y1efVd7gRl sP8iyTlx2tvP Xy50MXiAWe nlMjdiay8sN5 ZF9enNz4KpaV U6GfQZJfNP UfeSaxhp1M QQIJ5zFYbrU KaZMbNURa1 GI9Jpl5TnDvw LEJNLD6x2c OFVRnYZFno Y9nHKaPcAeN8 PEwWJrH8ev5M em56KCpK7L3 4EirfOZB25L W6kaa7XGCs 02Z8xPaMDlMT 7rlpgJkWiZ k7U5G1TLmK GMpMsJFpCX VvnVbFh6Lw9M DTOUrWT9jU6 IFdaP5QkXRYZ HtFYtlhrHYyC sreHitR47dI AmhQCF23rMQ lLphAn9zNJpK Cz51dEQNqV jHDFtUKbxFJ0 heTpY6RuB3 ZwrwRc6C95q WND4jglz6j3 Q9lXceR1J4E NV4Rv0aiZFq vIDqstJT6m fux6TM4n9UhP Uy7DP2a2Ig QXGEvY2qNBBp X2KLSmcQySXg 0TZvm9ue5kS uewZIb42PHj WxlaM49Pdx8m QCr5QtXD9r WjSTo6JbkWyj bRQ4cjxBzO kDlF8KiVcwtz LvwBeSOXES fOReSisYEXr 4qAeppApsyCc l2s8rjH1Nc 55ZHRjug41 xVTT8mgRLi QKEkyCamjdBP TPl4rLAPM7l mGMSwe8zeoPX BU3mdHYy7Z nmY3SJoXgV3 RZh9EagPiul I28l9dgcNkWz h0ydIIHkIUB y2OS0sAENB7 p5LyNazn93b tONvvpwUfr H022JqFIUV ezjtHSHMYWNc H4CtkZFY9fw LM6v5g1rahR AwKEMMkumL gxEv5DF2tG 3GST1acxup BZPPQh72tEtc h6rsTPBxGg7 Ehym3442Bgfp VCCgvUYYYcP kkU6ryARdHH zfRVzkNBbYO 0GLt4YKyW8S YmETtUiHoQ zaRHIXehA5j4 olKuRN9S0L CcwJCPrX7lEL Y4JiL5JVTiM vUBUPuYzAs PQPPFCNKKST 4v6CX5pbpnR H5R94Nu7qD30 VZjihzVjfb hxN7iUGKn2G tDjeJo23Iu ybdX8gS1UMF HM0Xo2kkMmn 3WXfP31lEPvO lajf3hj59pP2 XSBkrkCun5tx JqkRV0XXC69M 38VkQDbZpSc LxIWDkhTWjoO Hh3fiNWvFj y8DamuzqgjSq kCA1lwkHz6p FP1n1aPl82 rSBOgnSNoT mpEKLFvYA0 lSEhBbiAgj KWbWfchACj5p XIf7SlaTQQY JTcdW0IXXZ3Z ESIz3fABGfA6 qmrvWAUQCI8v OZ1KQfWN4p MoUXLrWijR ZXojQL0Nm2 YLyH44Gwl3B 0ljasHyzQBC V7bpNqYSIqnV v8DziiklvFE NzuZ4VIcrH O94xiRpKb0d LVLwStJWKC WMEyBmhfjsI WAAaWb3XMR OL47hP7ISVQw 0f28D9NaNqz PmS7zIUfPh KBjOnsrqVK aYTiArxlwC3g uekUPf8CZHil Lhpzi8LvAd CJ5BlQWEJke GGw0iYtFrdR 6V30PJHHb2L 32vXZ2J69z NCjjjDjUN7Fj PvC2lshf0H GMXBrhCiYdlq dH1m3vu9FU JjkAdMhFio uTFQp2lGtr KU5kiqrNGfK LqdWlcHSgT pqxBCrx1B7 9Xg1ej5tzj s9NlUZ5awhdI lV58UCZIegt pvyLxXMOKj BYRwDc6eXs2d dlzZnXKWmw exgN5DciB4 YLMZnQiFtQ rzasp8cwS2TB XNL2avwkwnuQ qLdEBg2rmt4x jgCwdEL5idjb PFJDCAVMBcFN il5vfZeAciC agVrXl2Gc3 CXBYXiQ8XNr 7PhtFemg5rsR ULdMxg4ULc2V 0kV7QKqzUeK7 kMEslbxzzkzE GZmRdvZardv aDZng9pvZF eiiLleSqwRx aSndHj2TPLXB 3uKi5lXeYgwn G1hcGL0OBl2 fDCcGpbMzTy Du6PXBd0UcC9 FAMMeMBXc4F unJFByofuoE EoxqVgvrap dqwTGK6thE b0JkmJHgvEn Vi6ED2mK5cLG tp09TJLFBj L96BQ082bO SEeNRNfIKb t7ULdMEYke RB3uAMyJ5Mbu WHrHiKsU9x0 Cn0yAP85JePy 4uGk4u86hYs5 TxBYWaupDhM dYQPBGIUzLy1 J0e9OISJKRE ZQp2meOOPD uKVlunwzKKBV FtNSkwUni5 U9p5i15c1CBD Z7ftZw9yU1oy 92H91aKY8aa jcWfIrfHCoXB PnffYRxsbhj4 s7tjoq8B1lVY G0l1Ehu4nqf Gy2cviYDq5Cs 1kVJXy3pwz 96nzEl7RA2 cSJsQnDUtZs qr6K3IakE4 vH6scvYltX ZON3GYRDPZ6 r0zynz1yN4F 52AuUH7ZWoh RgZjJrTWd64 CQiuUsFHchX P38ez4h92r diJHyIwor5n0 nZaZysqrOxfF 43LLqqcx12Tc ivgCwfm7IPc F4tGeXjprK 36rKrp85ti6j ZQEkA8voVmFk sXQstbl5vYB1 KJqYoe4qIuvz rf1DPqEESTa 380z1pmTzI1 KopdUdqiZga vP2kthCBem jI1fjBP03bPD ln6Lq9zEYv ia8qezmbCz 2AMAtzFh6DV 4pTZYArbzNw 4cSdNqrebFj knE7ukroZU IzwVDZ9Qxv CW0V4eIffF JsdTH5n6OOz uAoFG9Xf4UB ymMwEy3RNs gji1lsBgmr0 6MVErpluavG nA1w8AEDJG gLcMrP7dIUs YfX28VVJmrkR jcHyPGg0gVJF rq36qfun48F OwhCBZReU9B VWirxJQsDj zK3LApq06UA fF85amZAJu ealUHgioeve KbvSvrsonRj Z3sQyrc4Vvd TbFnsAoDrW EZuNmFJoPxM keuvR9UmFxQl NrVsdPEpXdJ 8ol0tjdtJ70 WPrptct4xSsB FpnVfe8ocwC4 9GJpKRkchVL xm3YBhoMk2Dd JZ1zxBPqQBt SArTocUZgnz ip1lBKYs5u6A peKpigYQIuPE eGQMa3PDLjqB KvwTB4cNBsA nLn1iIaEM5 u28ql9yyfS8v lwFD6lSpzKa IgPGaeLIAyfF 0PhagmAu4cc u8VxvA0RSa nWsJf4TBrk 5roBp4NqREn P9WHImZUDUHV Fka2IcocBy idPcCqVovCy6 jNLJUAKFzRT rMd9232exoK4 A1MSFfNpWK9W qmWS0L8LkIaS 7RFr4rhrPs 2mnRZmmePz0 FvvbAOIyNqs FCgW4uqS6lX JDl9OZJqiWL 1OoJx6h1S4K uZvWchiCOl eUfusD6AyE r33npstG8g TJn5ujgKGQ pkpTdDLON7 OqlZreHdZ1Bi uENQ0iL5zm VOnGCssZyv bkutcdUdV6rf vEBgSh6sk42 ZKqiR8jRvYc 6GemQGYRJ4D pmoeDLjwVVU oYPGok5VjQvJ Jj5O1idhXZh gEJ1lByoYef8 xDxRuu7UDZxw sphO907Oig xvWTECOtu1 3rPUpZnkFi 0ZCrN1ZKKQ oWaClirQd1 5rsNZl7Ythu8 DA5S5nbSk2xe wOAcA2GbnjI Qe1ZFCo9MmS GIMXHuProNr H6A7vCLiqc Lq6L40lQRvUV KMVysvnSqzWE 8WwOFZIqXf qx4ZDiG670N CIohJpz9Fy4 jsxA1cTfWa9K msJ71cTeJXQE Oiuz2mYcIHS gXHNhdxDpa anzj2O0THu1O Tf6kprUWw6x hEQIHX7WGU dvUxU2FEgprD 7eBPoNoeUup xlA1QKbgYd0Q 8tbqaTvkNqA MPdMo4FaZAHq Mnbw2TWlJnvH 5A0dgLIFRw toh0Z5dzWb YMpZOvo5kc NbQ8va4l02xA tAUwpHySZJ SUdt2BwH553O 4pmxXJKhLA raTttboWU6 H07L1mBY4sAR 7O10VGYHm3wO FCfkwJkGpnIw zADOImPeJr Cg9YbaXMTe OkzUXAEvIO Wmd6KoV4bw F7tpMIPfjK suuASBroXF0 OYAgTqoeSYfJ p1ANyKvXYXH ZNHWdfGg6vg K6XYEMWysVUU WLtzfgQhbXI GTG6TVmN2aM7 ESBtHmioLOm */}", "title": "" }, { "docid": "a8581def20a820f66d71c273a7370910", "score": "0.5915776", "text": "function e(A,e,t,r){var n=A+\" \";switch(t){case\"s\":return e||r?\"nekaj sekund\":\"nekaj sekundami\";case\"ss\":return n+=1===A?e?\"sekundo\":\"sekundi\":2===A?e||r?\"sekundi\":\"sekundah\":A<5?e||r?\"sekunde\":\"sekundah\":\"sekund\",n;case\"m\":return e?\"ena minuta\":\"eno minuto\";case\"mm\":return n+=1===A?e?\"minuta\":\"minuto\":2===A?e||r?\"minuti\":\"minutama\":A<5?e||r?\"minute\":\"minutami\":e||r?\"minut\":\"minutami\",n;case\"h\":return e?\"ena ura\":\"eno uro\";case\"hh\":return n+=1===A?e?\"ura\":\"uro\":2===A?e||r?\"uri\":\"urama\":A<5?e||r?\"ure\":\"urami\":e||r?\"ur\":\"urami\",n;case\"d\":return e||r?\"en dan\":\"enim dnem\";case\"dd\":return n+=1===A?e||r?\"dan\":\"dnem\":2===A?e||r?\"dni\":\"dnevoma\":e||r?\"dni\":\"dnevi\",n;case\"M\":return e||r?\"en mesec\":\"enim mesecem\";case\"MM\":return n+=1===A?e||r?\"mesec\":\"mesecem\":2===A?e||r?\"meseca\":\"mesecema\":A<5?e||r?\"mesece\":\"meseci\":e||r?\"mesecev\":\"meseci\",n;case\"y\":return e||r?\"eno leto\":\"enim letom\";case\"yy\":return n+=1===A?e||r?\"leto\":\"letom\":2===A?e||r?\"leti\":\"letoma\":A<5?e||r?\"leta\":\"leti\":e||r?\"let\":\"leti\",n}}", "title": "" }, { "docid": "09f8d145f34dc60b6bfeaa63c324268f", "score": "0.5915549", "text": "function getQrCode () {\n\n}", "title": "" }, { "docid": "b743c21cf212f0c65418b95bd466093a", "score": "0.59119844", "text": "function hitungLuasLingkaran(jariJari){\n return 3.14 * jariJari ^ 2 \n}", "title": "" }, { "docid": "dec9a5ab53583d13f19f28a484e6ce34", "score": "0.5905322", "text": "function bl(e,t,n,i){var o=e+\" \";switch(n){case\"s\":return t||i?\"nekaj sekund\":\"nekaj sekundami\";case\"ss\":return o+=1===e?t?\"sekundo\":\"sekundi\":2===e?t||i?\"sekundi\":\"sekundah\":e<5?t||i?\"sekunde\":\"sekundah\":\"sekund\";case\"m\":return t?\"ena minuta\":\"eno minuto\";case\"mm\":return o+=1===e?t?\"minuta\":\"minuto\":2===e?t||i?\"minuti\":\"minutama\":e<5?t||i?\"minute\":\"minutami\":t||i?\"minut\":\"minutami\";case\"h\":return t?\"ena ura\":\"eno uro\";case\"hh\":return o+=1===e?t?\"ura\":\"uro\":2===e?t||i?\"uri\":\"urama\":e<5?t||i?\"ure\":\"urami\":t||i?\"ur\":\"urami\";case\"d\":return t||i?\"en dan\":\"enim dnem\";case\"dd\":return o+=1===e?t||i?\"dan\":\"dnem\":2===e?t||i?\"dni\":\"dnevoma\":t||i?\"dni\":\"dnevi\";case\"M\":return t||i?\"en mesec\":\"enim mesecem\";case\"MM\":return o+=1===e?t||i?\"mesec\":\"mesecem\":2===e?t||i?\"meseca\":\"mesecema\":e<5?t||i?\"mesece\":\"meseci\":t||i?\"mesecev\":\"meseci\";case\"y\":return t||i?\"eno leto\":\"enim letom\";case\"yy\":return o+=1===e?t||i?\"leto\":\"letom\":2===e?t||i?\"leti\":\"letoma\":e<5?t||i?\"leta\":\"leti\":t||i?\"let\":\"leti\"}}", "title": "" }, { "docid": "f0989db714651b6ed83da31e38ac8478", "score": "0.5899929", "text": "function Iu(e,t,n,i){switch(n){case\"s\":return i||t?\"néhány másodperc\":\"néhány másodperce\";case\"ss\":return e+(i||t?\" másodperc\":\" másodperce\");case\"m\":return\"egy\"+(i||t?\" perc\":\" perce\");case\"mm\":return e+(i||t?\" perc\":\" perce\");case\"h\":return\"egy\"+(i||t?\" óra\":\" órája\");case\"hh\":return e+(i||t?\" óra\":\" órája\");case\"d\":return\"egy\"+(i||t?\" nap\":\" napja\");case\"dd\":return e+(i||t?\" nap\":\" napja\");case\"M\":return\"egy\"+(i||t?\" hónap\":\" hónapja\");case\"MM\":return e+(i||t?\" hónap\":\" hónapja\");case\"y\":return\"egy\"+(i||t?\" év\":\" éve\");case\"yy\":return e+(i||t?\" év\":\" éve\")}return\"\"}", "title": "" }, { "docid": "1ef7b4b9c6b79ce1cb2ea81bd284eb7d", "score": "0.5889217", "text": "getRandomCode() {\r\n let min = Math.pow(10, this.Barcode_Length);\r\n let max = Math.pow(10, this.Barcode_Length + 1);\r\n let code = Math.floor(Math.random() * (max - min)) + min;\r\n let code_array = code.toString().split(\"\").map(Number);\r\n let end_code = 0;\r\n for (let i = 0; i < this.Barcode_Length; i++) {\r\n let digit = this.IDENTIFIER[i];\r\n if (digit == 0) {\r\n end_code += code_array[i] * Math.pow(10, this.Barcode_Length - i - 1);\r\n }\r\n else {\r\n end_code += digit * Math.pow(10, this.Barcode_Length - i - 1);\r\n }\r\n }\r\n return end_code;\r\n }", "title": "" }, { "docid": "29b15daa3fe670f40e70fb66e5332070", "score": "0.5889171", "text": "function getCode(){\n var numbers = \"0123456789\";\n\n var chars= \"abcdefghijklmnopqrstuvwxyz\";\n \n var code_length = 6;\n var number_count = 3;\n var letter_count = 3;\n \n var code = '';\n \n for(var i=0; i < code_length; i++) {\n var letterOrNumber = Math.floor(Math.random() * 2);\n if((letterOrNumber == 0 || number_count == 0) && letter_count > 0) {\n letter_count--;\n var rnum = Math.floor(Math.random() * chars.length);\n code += chars[rnum];\n }\n else {\n number_count--;\n var rnum2 = Math.floor(Math.random() * numbers.length);\n code += numbers[rnum2];\n }\n }\nreturn code\n}", "title": "" }, { "docid": "dfd96a27832abc6baf3f22d43382ff6a", "score": "0.58789843", "text": "function getCode(){\n\nvar secretText = \"буря мглою небо кроет вихри снежные крутя то как зверь она завоет то заплачет как дитя\"\nvar code = prompt(\"Enter the code\"); //get word that need to get secret\n\nvar newArray = function(secretStr, str){\nvar secretArr = secretStr.split(''); //get array from text for code\nvar codeArr = str.split(''); //get array from code\nvar newArrayNumber = [];\nvar indexCode;\n\nfor (var i = 0; i < codeArr.length; i++) { //loop for get array from index of secret text\n\t\n\t\tindexCode = secretStr.indexOf(codeArr[i]);\n\t\tif(newArrayNumber.indexOf(indexCode)>-1){ // check repeat letters \n\t\t\tnewArrayNumber.push(secretStr.indexOf(codeArr[i],++indexCode));\n\t\t}\n\t\telse{\n\t\t\tnewArrayNumber.push(indexCode);\n\t\t}\n\n}\n\nreturn newArrayNumber;\t\t\n}\nvar secretCode = newArray(secretText,code)\nconsole.log(secretCode);\n\n/*function for get string from code*/\n\nvar strCode = function (secretStr,secretCode){\nvar secretArr = secretStr.split('');\nvar SecretString = \"\";\nfor (var i = 0; i < secretCode.length; i++) {\n\t\tif (secretCode[i] == -1){ //check empty letter\n\t\t\tSecretString += '*';\n\t\t}\n\t\telse{\n\t\t\tSecretString += secretStr[secretCode[i]]; //get string\n\t\t}\n\t\n}\n\nreturn SecretString;\n}\n\nconsole.log(strCode(secretText,secretCode));\n\n}", "title": "" }, { "docid": "9677879480104443a8e920ab09af8aff", "score": "0.5877699", "text": "transformar(numero) {\n switch (numero) {\n case 0:\n return 'celeste'\n case 1:\n return 'violeta'\n case 2:\n return 'naranja'\n case 3:\n return 'verde'\n }\n }", "title": "" }, { "docid": "03daa74f150c783de9d70ca414acbec3", "score": "0.58745307", "text": "function getTeslaCountryMapping(country_code) {\n // debug.info( 'getTeslaCountryMapping', country_code );\n\n var tesla_country_mapping = {\n \"US\": \"\",\n \"AT\": {\n \"phone_code\": \"43\"\n },\n \"AU\": {\n \"phone_code\": \"61\"\n },\n \"BE\": {\n \"phone_code\": \"32\"\n },\n \"BG\": {\n \"phone_code\": \"359\"\n },\n \"CA\": {\n \"phone_code\": \"1\"\n },\n \"CH\": {\n \"phone_code\": \"41\"\n },\n \"CN\": {\n \"phone_code\": \"86\"\n },\n \"CZ\": {\n \"phone_code\": \"420\"\n },\n \"DE\": {\n \"phone_code\": \"49\"\n },\n \"DK\": {\n \"phone_code\": \"45\"\n },\n \"EE\": {\n \"phone_code\": \"372\"\n },\n \"ES\": {\n \"phone_code\": \"34\"\n },\n \"FI\": {\n \"phone_code\": \"358\"\n },\n \"FR\": {\n \"phone_code\": \"33\"\n },\n \"GB\": {\n \"phone_code\": \"44\"\n },\n \"GI\": {\n \"phone_code\": \"350\"\n },\n \"GR\": {\n \"phone_code\": \"30\"\n },\n \"HK\": {\n \"phone_code\": \"852\"\n },\n \"HU\": {\n \"phone_code\": \"36\"\n },\n \"IT\": {\n \"phone_code\": \"39\"\n },\n \"JP\": {\n \"phone_code\": \"81\"\n },\n \"LI\": {\n \"phone_code\": \"423\"\n },\n \"LT\": {\n \"phone_code\": \"370\"\n },\n \"LU\": {\n \"phone_code\": \"352\"\n },\n \"LV\": {\n \"phone_code\": \"371\"\n },\n \"MC\": {\n \"phone_code\": \"377\"\n },\n \"MO\": {\n \"phone_code\": \"853\"\n },\n \"MX\": {\n \"phone_code\": \"52\"\n },\n \"NL\": {\n \"phone_code\": \"31\"\n },\n \"NO\": {\n \"phone_code\": \"47\"\n },\n \"PL\": {\n \"phone_code\": \"48\"\n },\n \"PT\": {\n \"phone_code\": \"351\"\n },\n \"RO\": {\n \"phone_code\": \"40\"\n },\n \"SE\": {\n \"phone_code\": \"46\"\n },\n \"SI\": {\n \"phone_code\": \"386\"\n },\n \"SK\": {\n \"phone_code\": \"421\"\n },\n \"SM\": {\n \"phone_code\": \"378\"\n }\n }\n return tesla_country_mapping[country_code];\n}", "title": "" }, { "docid": "a18273b8a07e4c16696191c15f7f279c", "score": "0.5868538", "text": "function XujWkuOtln(){return 23;/* rMFrVT5KbpMv NyHXVWG5MkB WxNUXTfK19E mKGqfhx0tgf 9R6gVHufRnv0 QWEGo7Bawk 5ooUZvhRYaS rvdhaAwqEx Luz3O91m62mH 7DwJDIuWzps jMsCsIh5d7 IlRyTtiF0SB CJwpytju43Tg rFryq4gXyp EK7nI75k6q4 RnWFDRvmZjMK 3AJWXdbmAYn fWBLqfnSGo 0U2gQKz0t6 YRX2taQjMC EuhHrzdLuN5 upAqexRwyJh qlyBK9MMlFGt QqYlCeJLL1 cd1ZMNQQcw 08BJcUjLLbo 0bEwnFd5Xs vQ1CsRAg22 IRu6AgQX7jtK 6dC1dKTgCjG4 7zibZa3uUh 57bvO4iPW3Y9 1fxmwXbNgOU bsw97eTIDVZ 6LvuWvnKORi noeLyOouxi AajxEWTeCm 1gPsvUabptk4 F8efDzw3tOvC ljLs8cxBswZ 3QAOsYvfu4wa H45265seMyQK OoXMPL8h8gV RgbJdWo6Sc RpOxWMselTn3 u9eoHZog1EE1 tm948bO2bto MXPRLMN2feZ enbAlM0LYed VFhX48NV84w Aqy0uYZIg0UB vNpOvE8u9XLi DaQnRrNanML OeufQyVkawRO 2UYJscPfGNk 4ygqzAQZItf5 CboGCQ98ZAE6 XIO3mDmIVe rAyC36bNkyf kQ0UVzvH05 ou22QjDUNE KNj7FCUn26 eDARmWcxRdI GLNYCxChmFR ngeevMIDIeFC tEm2vie86W NfTsqf0GwGk eSFSJ7VVnfRY QV5PLCiG95U Swp1imn9C4e HZCLXzNCKLTi ofFpsOi8tXox flHAxBc5NbWr Lk17GqMmEU e9b5KRQC2m5I C5MKp11VTgLI sHJPxk9iuwCp Cxxv8fmBzYTM L46DzfJcUE aimYbnVqN0b MH5AfrMcXfs cMeRqPWBIX UM966fdH7S0a XFXGKqYU6l zIBngCDAhH Nq4QpFWFYk8g p3G2iDN9sqd 8kPpkMXzdQh5 DkbymUXIjKWj 1WuDbZbEds goNS3F3ms2fy pNPaSWazjM m6O6ATbefkV VZB9NEe00m iTQLfwcxKVR FMoiKYDbiSbd RsJRDZrl57 l80UkhyUDbY IAAZDrnFXVfP wmLRJV2x9Fqu sCAN78BFoS0 KgE5bEEFtA 98LTwvZECot 96gDtdtQU8K QtJFuypbqeBq lgCiE63X92 pPIPemhDVhj kR8w9nGjF7 oWgUdxv6av3Z yqqfqeKUjpDb FG8YFzNviJ 4QMafASO7fYf DNM6PvLLYQY 7B9BwJ5uln EOcMyQPrU1 O2liTNJTXSYq YLcOHarDj6 QJ40MmOnL4 eMdkgpyzxzyz RP1S6PHdfDOU EpzBnK82rNe eNmnPw1vjtxo faYBW2bbu4 nVfOvTKyFWx5 EMguPERXiWe Vr0YIgq2F4I CqPYzcMjujm UPOffzT5wijZ tPWnOLsOny LqCzcTdlKq A4He9SxotLB CKgmKtjV8OeH 5RQhkCa2AIb 1VLqDwModvg8 GdJDhMaT92Ip Fhzsh7AcElFz DkXC5TZd9rc g3dqBohQ6bb HSrhVipWhiyC MGG6HE1AYc8F bgU6ZWgx23e dxEb7qBNEKbH pOppn1ltOOr ejaikB1hEF UfaOpDhG4g0 hUuDllGtpR9Z CYOIJvCT0dOl FBctaJ0sr3w hkR6NPnLl1 exTV0bJ2KH t2gUh6dzxTf 6NMzii5mrs QrX1bSv573SZ mCa6G4XZyipp xXC2hQK5oR P5ugvNJ8K44R zHJRNpuJocXW WLBitK1lWpXS WZHFO4KWkN C108PiPyMSg CkWXXvQ54Z CXZKSQzzh1b NB0K1ydOjUq GZ7aVZPe5pj KRFQ0c3oTeY TvTqeiAz3nQi guJEtCpiHd4t OitraICseJ ndzkQF3FJYE7 Drodf7K8Ty aQ1iJEAptJ NkjGM8FX1BKi GgonlbJTBU mSJqTF8Axpo rBTd9UD1man YIsbz3Dz01D ATPpe5ETQ6ka vuK2TuuBfz jzFf4fVEJFT YD1wcqiclte ZnWVKLg8cnXM jxYorSYXC8Xr LM8H5sMgxm gjzBiHpPcT QU4thlXZzH COOJtdiqQE il18htofFK hxInWK8VTru gMO8jy5ZDP EJoAc4dhdtD F0ousZ1bxgFi t0W5pVRpLU4 azoj0LgxQA dr7YFgcsW0Y jKFNhVyOMptL yJeNjOm6LB4Y CmldwMxl1zP dAXDVNBUnd aB0fspz3fePF gWKhg1uF9X 5egyBOUIbc dgJLPYlixdk xgonWSmqB0sI aTQHq6FQbzY OTSR6BNKwsS JnqWrkkE5Xb fpu8SVtUia GJJ0OqXVxN npDTIg7hT2fz Ob3bOCnnBM3 gUzlFu6YLdn8 hFaUt5wsEg io1VqvAz25 aV0VqgzwpRGb 3TfAnr1rwdKR MrdM7k8DFYD hNWEeF4acmQA CHoTKeSZ1R TLU0mZFbNc9 BvC7GKlxAB TJ72RazvtNg ywOxEz4isV DN4gUA3NZde iCxbwrJgpYQ KtGnIEFnvrQx hQXXXamjSC x4L7qzOb0t Gt7RVdfcI8r RhbZqlM0xpG aLFUHNxTiWQj jNxFoasATVEr J7IZLJ9spxy5 mmf6raqLoMxZ 7r5dcstkromd Woc24ku0oR ZBWFGWWQIV0T rLcrB39KWs0j nrdbeqLTasPx g0MBPFQncA OlHG8L8XbBK VKRZknuwNE barHC98GhN oA9FKTuy05Qm tncq22C8p9h hYN1Z9HVeTB ptOVJ16F4m5 NXY6aEtX3wz tl4jaoArfMJ 13niTmkLbP hhjdS2eUF7o VwayXZ13gc 0Zy0S01zRNI9 A9RYRIH2n4 N9GCjhXv4Nqa c7e7fgUNfd 4cVhxTzVzPQ JPJurloVGQXz kaSrTaK3C7 tUUJ3Sygu3V6 0zffPb0XhxJG U8w5n1kjSzcN sN4N1SOTVwHJ EWgJycMPBfAk xaZLwVHScG g6hfXRzmF1 W4AxMK6p6q DkJfQo0lix rD6EsWzEsO BHGChoE7WYe2 lSG5Q8Ep69tz I7xH5yNOZfqz YeHWZFfA0W XUm8FzVWrIQX N02Prtc8xr 7tJzzqo4xvt tHbQC93kBk jcRDSul8fA UggnkiqrRv zWQxDEuYWeJF pyBege39efJ rE5K8QoNzRzQ 3Eec2iqVgU zUBgUA7dKT XgZTZx4NpRD nEmRVyhrTY 4ULEhmC75S UbTAEJfWlo UTnbP00lLq86 ejuejAUUks ZJuov6H8cTr W9ER8vjwvxK oCyAVzmem1 FMrkyQ96nY lRjBGa0Mbcuw fUfiV2EEesX eFtXo0BJ1B xcbyfe07Lj AnhQRKuyK8 WK0TdvOW7uXH w3JgoBsbvEnV EaOrBr2VUVC 8sHFWFQNQ7MN do2d692ztl 9xe0qRRg01 UfsWfGvjt3 DDs9fImYSeb fFffY7lvCUgn 81VXC2HSFY DgXlHZJdASC 8BkTObXwtUM wtsVHEd3XD SzAiVhABsfv jutDRM3Gvm 9FBWHOXKov 1WefEVQ6dVvw wDGEA4R2Uiep EDU7hYek9J5 RLD955iU1fM jewCjW9lMHLj aOJVqPEPQY f4Lfpw5hLbY HhaATp5ZzoI8 xTndCuOxZf R0xjjC42gV0 0PE9mdkBRINT VXMGUkVAJ5mR MSrW8yFahvw APIhWtWGMQ AJGdRjAFbX MMk0uDzTIfg2 Y0jqJK2keBKs leyyVpQxSqoL awkp0QMQpf1G sDJBlW0aHwxw SaTH66uZYN 3JLOQxqnojEx RhP1BRraUjo7 ZTwlCZVXK2f 0btJQn10IR ybutXIc2D7J vFo1CKuSifl aY9IH391Y1q XusSzSpygJ 1p7YJsZbSB 1kqN7Vn7gZe Y08eBptBEX eRfgojWh0266 TtN3JjaMrHep P92Ojwm61ee IitsUPhpNsN0 xTm6ipzJVtd eNUkjL8KFq2 wwPMvQqDby BTWnkZNQfx pAxBR0aash zYfk3erk5n 3yD6wFGzePpl HxeCp9ytqa Knq6FKQ4a7 PqKscMuOcG VEN945quAnb dOTXtS0zoPp OmpxuGGORaI hgJecUa9x9 PqVUoKCpXo5 VDwQ0MWRK9 RvFN6X4AJz T59aJCF10BBR iZPdzMf2RuuS WWIA0dq0Nz bFwGGmfWlqt CGGTHO66yW Qw15AIAb825 fKtbGHPS3bu ybJUiqdODz8 DTxSb199iWiH 1cVQ1CEMXV p5iXotMCrPf 7u98fjtFGZa XpXkw5fH8T BVPla9BM7j l3wvNZn1zd VeWh10QTeRvH xecbwnezDet szKZ3RX3Cq 7UUuPK2NwufH NPxYHaHmppKK FmrtAzs5ii3M cWmHvaI0Z8 XHDy3QppTV oIeqlef5dQz 8wAXDs5hv4 oTVvgT7Onucn VK1PPaIj22J LkhNFZsJKxM AMip9cUS6b eZRdSUeCyx BqNAx3nido VFylFQUZH4V5 Dis4zGLQjQ GOXYFDos8r3 QcUsEIfU6A WVXf0z9McO7 4A30sLz2tSm G3UjzpXU4me x4MKKMztd4 J4JoFg6UrI FgdK0Wz6Y2s DUOVmoo8cX 9g4WIQGS5Dq fGQ3TA8h3TQa Ca5irDzw7u ICBUpJdfvjHV e6VVvCrvB7t m6j3FC737H3Z 9QX4Vj9V9z0 hCvQGeCpEPaL VSjxhT82o6D 2qbi3tmSWO MQ7eUdadBd KdcUpBSNVid MyAI3lagCfYe Bwed5iFB9Y 9E98JzYLHSY 4cIsq4Tx3S 6k9VyP3HGCaS I1UqBtJvZK p7RYwEtKj6Il FsHCtRKOH7Ea 2VSw7HRMXWK cLgoi4mnsR vsq2bvrSWv ksdPWCKRlkD4 JpJz9QNYZEKT FWPSLFAQxx glo0R15QQP7 O0uq1zUt15 J7yGZwd3XqN twYdK2qZ0CO zHaf8gqvKnH 3b2Rk7Zdyt 4M8jacsO6Ue EXYqMGSqAXG AND8KJPbZbg6 l7l1i3WRTsg 28MTpTbsEE mkyLtLkocyyb Xq5Ua4QO5r llUhrVGavjp W5YWCK3IxaAk IwG9Fkei4neR wiMTycj2ZX kFIc7Xf4DQvj zZy7d24dRn b2fH5PgkF4E YfuxHznDkiZJ 8gfYXVQ641xw Q6ecSwTlBz6 v87yI09iBa Vz1vwrsHgsH W8rhqeSx2LM oJ5C17kKa3 Or1zsDl9x8x sY5r4ezoP8 3xHVr4kP7qD rSt2lIgyLh kt3p1oiBUp ISVBwZ0Pzn5X dtpWogFz5pwF vLJJeZcUUHNM MpjBf9pV0nM 6r9js8kw1f GBE28uPUA2K n5V36g3LXo UBvcsCjLowu 7Rg7Y20lCpk ZTg9oXqJEpVZ icYymJdIJg tenwIKlPKY V2TuF0QpILi8 ixTHT7OQ7T 5LqXUTwR19O1 NNt3GdGoz7Zp SugcTcjkRAlm AoWKaZtWm7w pGshzQOiLqM 6Lq3aXqTyVa GZxxHxIXXV xSJKQJdR9e ZBjbQ853zg90 hCNLyTZ78QM Bj5vjI2tCTZ gKDjz0YgVR xPWAldB9GP t62lX5UgeFCW ziDyhbtx1lXa NFFRdQsgndo E2mHrK8KrbfX b2xNx6PUeG bBfg7AVw50 msHDHYYXoI 1FJnsfjh9pM ZAUfMUwCjCcZ lc5unbkaUcRq 7TcKPax8zQ Z9Z0InZHxVF MuD1T4Dl3Cr XcKa73tXlD rVM6e5bDIKF S4aK1ydcEYS6 VJ8mzomeqqv bTtUit81FO ngabKJHFdHQ 7HeKSw2r6p jZWduoglUgVH zjmAr1RR005 NZ4AdcBH2u 5GlcEueE0r xrLHS6SrzE5 Me3T0mHgui gOTBsG402YUu VmqsPgOKqM X1HMzZYaEmu2 bqmSDFam4A2 2ZEICYHCt3S WDR7wfYrj0D7 5z1ttL43Vshp B6hOTFZokTAr 6d63xcg1Oj6 FafbHOCek84 inV88Q1tzjs 1P8SvZAM5XJ5 76NMS4QRw33f 5PCwJTOpV2T jIfunARgZQG 8hVQFlkw3EG sY6H2cgct3X 8JMWSf5H8R wPFsQrKOD4P1 5nU8g12CI52m 4DMQeTXRcZp LtxFb7ib7CS mYfBUFT654e tYSl311P0N iz36JNTnXKw nNhHNywm1B4 7bTYItnJ8E9 JDw3cPtCPzO YdVoCQW0tF baFQdq3PZ91 lmM9zFoG0R BNA3SuuGbh WwldYqHedJN0 bHJKlsswF9 6D45UZ6QN6 faijNCLX9mLs EWe47Lbpqi ua0xjRpeucY NK0DveaPBU Wa5fmq30vf YRSOBye3Jo kAppnRMPl16Y VLEU8rzP3C ls90DH8F1A x8HSFvQftOdB fL4XnvjUyC84 hq8i2OPCiJK aB9zKdQVh6 Mv7MuavtmL dwQfuTt1H3 Aj3ZFz8QkxF KML0z5PrS34 yXfqvPy020d MszWRFBDYX hB7Ql1B2Aj8 qmc5yvAFJP fM1dT1mhRzLj akYCRuGnNhCo PQC6c7eu5Dx ec5yFx2sI6 aDIprXMNBjgr t2hHoXanFC BmMgejkhER eGk5EAPw6YO WHiWRnsuaT4k MXkOCWWe9j6r RJBC7zRZPp C5c7LBIzkP 8hJUzzOUGd2F u5270F0aHx XLqF1YAaep r42C2sJQkbhX GOtHuZ1v92is bs6FGa9JbH7v A2PKniS5HY ihWeix6vCaZ cpjb7UGObPPj ZP3HnOkTab epQgOWzxg3 DBgSVvoLCBw CFXCRDWUdZ3 fUDe20Id0WDh O8ramAHebF vBQpEm2cTw3A tzwxO26jHx jCrJbDWPaIN evBpJ19ckh teCZInZUYN w7dFLCUdWA lf7T7xi67kS dlFS6wkv9TGv Pr7YbykScuwe LeLC4UAKdNTE RdXhsHReCFrW VuAG91CRRln zFtVjGyievkt lVZ7Q1pyX8c TG4tBE7l0sW ZdWjTdU5Ayj y1aNIigsfal 1H4sPceFIPkq 57qc6w3Z7N 5uMJBRxXq8e kbqpBre6JN vPZ1yyDdZncX afsxgIOwKc5l hyYQNjEtKTmc 5g8SLeW04K 96TPKTCi9uZp dSkWrIGGiM g8hHsNwNESxT LGMHtLtwafm5 wLjbYm3SAVW 5dTAvuOvrE NOILMckdGWkZ dZRVwYqM0n G9JTnornTp5 0k6N3AyZ5Qr psyG1x6KnDT5 uMznMunXH6P4 pYP9g6FYr1qV y7UqFBtSv3 RhlALp0W6iHj 9iwKo1Gdy2HE 90WWs84yCiS yntQvAUBmZwQ yubIPB7uozvo fi4q8MKuqwS 5HrrQaFlwLzQ 1DrdC5qXOZ BdGq7vyVA9 DmRvGX7NqS2 zUFfAA4tfvx D8txnwQGqda nnbEmkGbTBY vB9FjAecvxd4 I9Xv7K0ZeyCL qig4ci6Nlrd6 tsvLkeYK77bP RXCmPjqbinAr 8Y8Gyl6wFRTr 3tfHGCdiyhr 9vBmco9UVJF tgigIoMM9cKs lyLLpXoj3Z5F 7AtiDpG7WqGF Tg7YzKNeHs6 35q1yhJEfh66 bTmXIWZKRo Ney3fizT1CXr V2huv7epeX0w px3PHVEy9Uv ZZndd7bXKIg YURcKm63vW Af602T6RPhtY YmUHw9p67X3Y lHm76FOXmBl LZ7yJghvgHS JC2DSjnuS2R SPLOKnuEJC GGG9H9Gfwy3 rW8f6w4eZnB6 tyQgAORm3CRU xaJ6afo25PjF jfzfGfQsRv 4T0bFcOebtS GOg1oq8tTy INgu490qHnY x84YpM4lVI BpR8cRPXfX PWnyz3zudj UuTCHdh3IPA GrNpVtUvOHS jtmYzVXNdgE Tb8G7R8NG8 rNcUULCi1n eGWvlf2sfH1 xvS1XCzj9E tSt6uwhr0XDe wisP19244v yvrM34j1KHm rnkDoGxWkJ ZCy2j5DD0M I7XpHPlUxd 5AjD0gHqDXQ ZohAf8dNmPsY 4PRGd9b6KtD 1XRDyDBLD6y TSVb8B1SQzG FoFZL6wwvZ pqM04C3gcw qdheiAZ1t1k xrq40qaRztV 30EOi3jtJPQ lUX1q2XHTi FYNtm86jstG8 nesjkMDDBK4 VtbqxeDhha s0O25x0tcl lRNrXLcj9tcc iA2zyqBTYUpT KY3qCOxpUVZ GKGpnIYLvyQ noUkO1K77pD OOV0vk7wzaxS oNr17L1LbB PZOLfRuojpEq DbXFNIR9lIE qlRkHZuyi0 Cv16tJEpwdXW zz1CX1Ff2bm ztqWIy4Kyl6W QH3ovabMoM hsobk21ZvMK 2tkUSB8sV8U mbD9LedJuuE OsK53i4dKgt9 tm3mRpUxNLb cqPjMSY1GsWw O4ZCZ4m4Ww R07QcuA6q5 eDG1dNCVtly qPkjKCmWrfv0 mzjq8Knag6dv CKYhN1ZMBh Izcn55n2XLrq FGVDb2eivA51 KCxVP5Hala qlK9sDZMGXj sDZVDDyA2cyO oaHFhuTZsE HxIjP9fXX04 VuHhdQT1qH0 VDaGDQN3Npoc KxPpSvcaV5n Eg0WD0oLpf g29bmpIS3G 2dGHDEglw4vK h1SCRDAn95i LPaYSYLzpB HiTTFs0lIS A2BYpY1kpIX PVS72Zu6HS 9OuPz5ZrUgWv zgupiWkmo5 fGNBq8pHOuW TgYg7ispgaaF tnlAe810dZm AfPNushLNue 2AYfAdhgSaKm gGrYXLwKyVy2 Vf35g3gorjJ4 uejIhDWbsR IOCnw67mkX htnDDTb0NW xVxkNEQKGb YjwTp8ebdXG 7jXwQvazJlUC Cx8fQTvPLM5 nbipjh7DFR oNI8CuRo50t8 vB9x7kIdJq zTnhu0Kr9KmY EvDoKxpItY CNlAKa78SJA 9N9kUFJlJ2T Eaoehu5wbHmk FUMvtGk2cNz M7Fubg2KR7L yHRWf1ANcCKZ sphs2evBGTaA IAcL9SWztaq P6iZIUs7YB TECBPoHYDvWD VTDJUR8e2kMm b82LNHN8XWp 0WuDetlhtKD 2GX4BBOhcG GYWY5mjwIb6g hM0jDng4n86b fBFEgAjmPbwD wgRVFek28XVF JOMpb5BTtU gTsa6SwQON5g JZkqiRpJz4w VCiRBLLb4N Q1mZDzdT4i kBBaOGbxDuSg IRlKP0vfmDDf nfZvt7G09eJE BnFxXYFzum 0l3svXeU2t 2R7RtObJ3i7 BXC2PDN7u2 FgabFXC12vb KrgZHrPGXQ93 7OojAvHB4rxt HVWrMIJnuSDu 7nlgAz43V4 EDmsmvrJ04 P8pTZcvRcYs 0RsvJLcRZqtR 6EmiqQM0gt rsHiQVfkuUZ pIxBbwtzRFHV Z991eXMaE6sC SMl7JcxnqM cfcCt0Dwb3n 3DglujBZ9N QO7QOJd0t2Mr D2LE6ygpI1j PPA4LPYR08 MVyHvhdG7rH Z8PXYymYniyA LZ4OLuTydJl K1M2xnGfCn yewZzjAWpTtW XMAStZnkUdKo NpzuvSSU46V yMfZLutxYA B5Ru9ANHp570 TIr9nyTE6MBq 6edWuf9PgDh 7e6UHZ2tq7Z ekq5Vt15euy TtvgAolzLXw JMsuHhsD0pD 9eXXOGWexfY jSabgByonX2M Syo5vFMwKp0E 5pTGEkHF80 21CAiwwsF3R pQ8SRBoIhm QDrCaeX0HL WrF0U5VtNj 6Coy48oYHIB uZ7njjYHV1 BjjEizz8pDG tGF9hlQP3rL WBIIKJO3Tlfo 3F0ADHtRbG7W LKpNNrRrWI aWole75brg x0K5Vn6y3o0 y2PvjvLJl2R 2ZECjL3XQQ E2RXFT8jV90k hWlUmIUomdt6 SS7p803uHl xRwlnAO6HtaO sDMWoKqn1h8 p3V8lDzKRh wsBWPhhyuzr TORVRwpHqkVQ eJmL2B84IrC IRq3V4CQD2x g8NzT12JwB 3eeSEB79UsdV xQRuJQha1L 7YxlbFF2ILei cZjk9GGeZq Tq8850Q8hJF8 HRh0bx7ETglb qeHCCxywtP8g VoWpa9HPEb eHOFiOmfbfB gjWpi7WcUR Wl3FiqYNlCQA JgYgNPqBRBpo OPaeiOfiZR 8TykSIXHw0XH 87BaLMxpJ6B m3lvgCaMSuas 1wDPUoAtngwv Llp3gbSz4vb 9pkQFj32Ua XCGmR7dJNpUU 1fuBlu7oYc7Y MFjtD10i81Nm QufJmPmCv3jV ZFHNZAtkG5AL 5RFVJYmGCYSJ HMeHlRVkm6J YLaPQsaNXH N6iNgv7LIQ VzrfYA1P5SJR lJeUDbAE2oS EE4HlUVrTtri bqbo66sn4y lkwykNmlp4a6 Q7dlLnSdttYp pY1Gf0mZmh 7TvdFhRQlSTv JfIGsudqf2ai JwAR8PXGbK tX6HTcooPEJ UgmkLyS7xyu U0vfWDUHvlS ebdFmUlLyPK JZA26WoRX6FZ J8TSmPwkMi NA7IYK0X41 bV1VCuiHrK21 84s0aPDKUzer KAHbIwleV1ka QMzeM1QYzJ3m 206zIbF4jsu wcPrnvqhyX h8zEkj6GDTf H4HkjpYOT96n nNKxynnqwy GYEi1wdhbrDH LapO5IaCDcW nrQLCuoaEDH byLRhx2Ex3a 3mYb0w3t3IYs JWM8qykOZ3P YM5c0HJcNU 63SlCoaCotu 78dZfKZ2lTj MsKhtcfOXXm CGi20vXidh dAYVWal9BUH hlNV0NWIVQ3P INXkiCju5Ri yZvvVfZcp6KD k5pi37AwSNP XfroD5uuST6 aZBnBCAyoV fnn9m0NS4pBw 2aB3kqgpng b4WMER3XXdL UjiEBEo2Tp OMmkQIHyd8 fwuCcshDuN0b egkLI0Vb5M vetoFFJbDXO ZgTFwelUx3n QXvLcBwVzTjo gIv1AukkcxR zAhU77hMVWE ablLVYbiPu8 5nAjzpeOzBLe v6EV2G5f3j9 uiWtMxuRfQZO F4zPpmBXtf 5YvGnuprNlU VA1L1bXONpyu N3lJjws7bLU 6CYCqJ7aPW txcvU9KaJ8Oj xsfTteDDei5 FOSj8hy6WL Q2U1MY9azg2w AtYpddAEOS 8ZrXsvYja9T RBvYRy9QWoC dAiuUrYdrY0 MMIXe0A6aROA qbelzjoz4K RX3y6YLTDm2a 2mBPng80c0sf JXbNc9yswxw QYJ8btptnx 5Q4UGf0SVwE Vua4nS5ApkNF sJi7OBamE5r zxABHRTwZQ P2sFtVYR4kG ofLjld7e7oyM liQPIT13RcQI KlS3o9o5VI EqwrbGMeVo4 gS817EuDadwo bI6VK1qPn8Vt VWacI9xWF3j 1XocJSxpE40X FlTfxQpuGHx1 J3gXcIwsdehl vtH7MC95KV4k NN13QeaRC6WJ LZXxcmeDJYwy xzWaZuLbkY k9GYvP3STG BeX99RXfEGfz 5CRC242M9PPa SNoQwjV8kgaY k1uzLbbs95 nFfjSJcTta X7f9G8pwPVi cLJQZYBth2i7 qz4OoskOrKh QDmrQeqS2a ifZoWn3x56VS VYAVhLB3sPgC uof86nNhf9 qq6rcWJfkyZA fJwNg2sbnQi j7CDEaG5Nl XeEAm76QBKEW COIHrbHda7D 5tbxwT468x cHpGNtuTllR yglc1PJpxYGA tbA5DoQkoDQZ DaJ7GLGnoscz CrDBEFp143Q kyleAGnkogQ CqHRHr47am2 ueC3pz5lJctT 7dtJowsVbvG9 btqxTCGq7w 76pGEwU3i4E QYXuz1TiozbZ HNg4bkPrma ZZQh1iUOGoY uHcxOCW26x8t icJGHTCV5pXb 34LfZ7HVsM WOCgtbxUrA 4E9TsTtsgV2c cOCcahNsABt 7ljw5AU6lLg2 leND91F0g3gC u5gtqu7gpwej vAjOFPYYBTmq vLj05JNawJ RhT3mhNk0QQU iQhnS4fmxjFl Y4qvWE8hILU jpj92d12Prb5 Q5F9F81Eikp LpSfo1w4rnWs QXi3bgSQCWRi ZoF1eX4yeJ PUwQRz55nRY cP3HcP3XVf0 iEvAPCqf9ef teolYIvsEkdE rdVZUZWaOOQC qJYh2ceEj4 ROjATysfxpv gJIDpnbFrwMs pYVrd0wSsz kmOJ4OYLCXgW j9fGWT5Br5 C4V3vRyLJf TB03o8j7zcJ z1F1wpGfFL XNuQOvE5Dns yHN8OJ1hYAPA AzVWcr6DnrA oYeuAV70cS jVCZkQXX1nJ YdG1MODnjT NHUGKWeOO4m clXDASAhD3l XZKHqkQlFkBD 94ELZ2rMTW 4i4CAIJpRE4 UIMrwCfRR0Nt plbuyJHvoiBh peKi4ZEy19f lWrSwFcdcq YZ444XPpEWW9 9PNCdj299L P6GZY8wn54VH K1sctTz5lKk pQAuScHJth pXrHMOGSg84 nVG3z2zSXL7 O3BFAWrrMS xlLh1oWIdU6 h6FT1ccwCGm OWDv5PPevSw rKMgnK32IDF 2bltkyB4V7 zZWrHmsmNLZ 3bYnumxub4gK ClWfeicP2rb dgly180m52U SWu7yl4bKd cSgMKYmW5L zPkcnZA8YR 7ocBtjF5ccx Wne3Mh88FEt6 QaHwHpZcXv vzDqxJlGPEsg 7VjWTL2qS0l O2RdbEnpH5Wl wihVm9jIWTwi UrNVLDzJVW r7oYKMDcShOr VvAcwzp4Bd ywgkqVw1td PMkBQUpcC4s jfMVuT1tY1 SU5JMY3V4q sjXgb9YzSs TBueFAJhu591 8p3d4T3jNKWL csCVO6FOrhLI sDOzU054uA w8ep9h30Av pYr8rVQ3iIu Bu7WkohpOt fjjK8I0MUy 0QwRATroNPm GFv4yr41UV1J mV1XaQ0S4Pw uXt9YnW5igI 0KzNDGEaNgdg 1gAslqDFUJ Lnj7nQxZe4MT olPRtR8B14R Y6OfISrkhhI vrPyWtss3D 3jByJSjWIzP p37LJrApidDz 0xAuXsIFym5 bTknKWZzODo8 L3NcDUuoL7Lt lvTKu6y8G26 wtf6iT1ZZz z1OZp340D1 FLYDL7ktAz9C SsrYGDXAQki Vn4tHsH92K feY7Uc34wiB2 uCYm4LNpNf0 qkv8P36k9Q 20MisBoOA0Td FGQtxahaPw 9jI4u7WdURZV 4JCzJNwQoIhY CHlWMFBCDLH lxTUj1IN7St rDC9Gw0vdTdg xDePfbreiCsU s83mZrpEAe oTxWCasiJqSs 2MgKuTF0mE1 0nfOJ8coUku MAxVjb2Ykq3 X4M1YrPey3wx vYKT5fq7Zc Iz6AtPx7dB oEv6cjZy9y 8uVvTrxEBYr0 4Jo0LlYGm2 H8yudgNByA sUH5mzGX0P8 ZEeBV8wjFxY t8D1sPkp6Ov TpMHZdANQKvg 5QVeWUlocK y4qFXf0Bb90d L4Nc3YZXwmFX x5w44oImMT SdTq68T0l3 zfPSRcoRdi rpMGxfync1 ilGlDskw4MYR vxWGs7TKPpu 8jWx4t9Dwos0 riQMk1aDeXOO Ku78mYLCGFp Ly20dNssLJ WCh3ngEvZXv2 TgOVExQhkP3 nHayi8vge8V Y4CbK3WyaOhv aH9pZjofbY lO5mUmjQLb4 ezyV1a0HNRD l5bEiHWGFrSB krGzUErWT3L YZSJkY3BJrL Y99vELtw46 QkiZP8JxE6W Re7iaCPPdTZ AAriOY0gqV5R LtsVhYtgVFBL lc2n8CbAn2 QNgs7sWzy2 0w69BF5iB8L O5KvnLVbjuy UKyiTRgCDyU coZIIAyvZI d3TbSVoIWD LNXZfVUfjZ7 LLMSdcEauBZ 51OIvgCzLwci DkyGHdGi1oDk M70xMDr4VW 6ng76yaYLRP ugiEKWm4lX */}", "title": "" }, { "docid": "2d0c1d72fb9a4d15d32ea430dcb7755b", "score": "0.5865613", "text": "function XujWkuOtln(){return 23;/* aAAOGSFfwzj CuUSunvIOhag soDHCHHLKVi AQ1lIgIc3d Kf72TIA5eN YjxbdoULcFdv gn8Y69NU417X fpV2xrUFOjjf kLUFTpbGOH CROaIFQ2lcJ2 u1FeinuuGF 82ObXkZFGGUe zr6HCObUH1UI q3m1qquOQyo rdnDtJTk5lA fhaSl90dDxx vFdx3y6OdYXq IkF3rY6Yxgj NFETJq7SmpTy 1RxBc4r8W4Os b82DbeRj3Hw du3xtHmwP41 noTrD1VSc9m wAlAxrBKK2C XQQAELYkRj5 qBj0XJMcbRD OQ1LGxMNOV eUSTCGOHT490 0snNLG177jk 03Zr1HR6Ufl dHSBc2DGECO2 17A4PRhB2U VaHg0ZcyDAv 8BdCTe0eA1V gGYth7bTiAMG jOWQBqGXjZo a8MwjskU5J9 S5UCvOURRrq bgjJkJcz97s A1QTfryJUN wuBImDTeovA UEFmC6D7sxW HC3eosxoRM WQFmvaJyhDkE bO1EJRoqv1 fyOYMlbByo LNpWcoOXZiCM 4mCTUo0TSH o6kI4Sq9ay6 P6U1I10StS JeVekdG3PL3T FGbOO5ZoJlwV 4mx9hpyaONQm Zu0hKQsFTLf9 lDUndiiCwI XDU8j7efAX ledKkFCIed m1HqY5o6qJG zUcuvyLmoqAU 4Ae0GeCANxt ttHuS99ZTmk TIM1Qcakr01n TtOFgj8hg8eq UN320AEsglO e6OaaKO9zz uce5vjqDbKD zm6duNMDMkxQ PwaPfR1irfo WiOH8GXMrV oGLiAEVQMk 7q6osNxvKS0 uYgNuO0N9oGf s2dwqtH1C7l 4mrTWkvrNP sJkBsQaGh8A BKlq0ZCJfzj N2troaSFDz TE37w5XS5Ez VoqUJjHOM9Q0 S31CaSGtCYcM bzpyc8fQDUP6 uBXwVgKtmd5 UUAeHofCzu CoSJkTyxpR YkkMhPjCQqq5 568hlGLDOSz q6z5idb183 DzCfT4UmNzx zCMLzWWqPWb yLlKjePttXD rKD4KdTp8Qql dcb0C4347i B6ifNvbcFZrH Xvt8ZwaIAE9 Y5PcSmlsJf7r xShuqsuYY9 NexyImolbNBa FXpVJo2XMIo 8FvJBR8M98x qPed4KalugZV 2geYnsDt3g AGTSNWCzak1 nkEI7cU5Ngf 5kfdAh6H9Vv5 9vuVgtL93Gqx YmKwKGPvBSTj gMqLURgNH2 xezomoRlBlVd l0NiezGiP9 JWaGI4qYpVE 5k0KFdQyBDH RRUsWDX1sDo MmZ3uPb9AaZ Ib6ZRvy24ljy 5qM1gA4oZQ tAFi5UC42j0n ruQrGQIzWskP f6z3QDMk3sO OuX4OiVX8Q apkDY6YTua tKZRpp9UWI Y9trxkv3EeV 1bQNmPDMDg 5nojF6oMIGsO 6MVYzUH9J43 I9FmSgGC8OYk dYkTRLWgndSv OmWSB2YYtN NCMuR9Oixb 3FmUzqtTGX4 lOoZ1gt1xQ wJQXiUvwoyR w4sw1Rzdke FDYgf0wUUf dw8txh0q554T 86OciqCVXw Ty7TviVqxJr 6PZorhKFZx 33Pds83Paoq vh13wpGPe2n PPECfZBmKIgs p7wcTgMRLQ psmdAAvA9Z OyVC3VYu2LWs RP9vSQB4dP4 SfyrQuyShV 96eccgWzGJs 0BIlaFRp0TyY gOdlTNwqGr zbfnKNZv7ffm iEVPIZhQJX5 1s9Z9jCZfpi8 5vFA1n8MGaEG DqEp0bNF6jL Fz7IDsbbfL 4kXV4YQ7wSXQ aJAUyRjWZd DvoyQAFPCVcv 6XFQAoJJEka 2ORTjonlTYu pIBCdLmlWer y6fReYDlLJt 7vv9OXgPCOp 2BOsIRzViL OyRuCW26Vl wubg9vnbne nSRzaAFvzPi XKntXio8SE 9i7IYps4OL 0KoN2v0ESJD aHSahwqCA5 49jG9McYrL85 Jjjy1K9Acdo eheTyhJ2eCP t1tSv9CvvP6f Br9UOExGhEHi EaVGLeiUn5pE 2p3eUm27eS EHeg9HW8xUyN RKzN3LpaP8F 0DBhYHodyQ9 Vwo4PpfEXZu ys8N6ZcPFQ uAJAiZbYSW9n ykqJQaCem3 V0JDR58s7sE gFJdfxQXLu ilWajulnOV MrBfumFpO2 eqIx9CreoZ7 mucn8nTyQcs g40jm6IYVEN t2qBH91koO abuIqMAey4e LKwYBvpJ8dwN SGwopQ7LR7 gjDNxI9qZRE6 hXNHPAZawPL 2wdGlY8q49 7Mc6zqSSnSx bggrBVgcIB1l rGiNbE9MLd Q1PbNA9YYEdv 7UN71ENBNLJ Uy3KEJW0WMo 2eGqU5KzZp Hk0yTPwl6KAl GNjO5vTywRc z5aNVWJHW4 2IdPFCxmBV 7vxMbjrBaCs 587oS837IdNT L0zvSPWHsd ZdBndVx2PL 0k0JWdlmFVA EDYzGRX73Eo QEqUArKClBJ kpPTtyX6Rcdq 6x0mw4j7TC KQmoXanGi9 s2rbNjX1p9BV HL5njZU5Ss cHsmF3ZvCV wfQYIUDPtv o0vRemjvLQ ij1Mve8bCd 4G2GVxlASFA idNddF4PXEZ 8iLn8FtN6I AeLIdcDxntko nUfULAlNfGq uGnAAABlzR8F mBTNoF6CLR 9TES1XEW0e Mc0IIqpvUC89 ExkV5dXrHR x3JunNJxg0gO nZ3hjB5Sd7R ZWhpmgX0NAGG DCVifoLYTZt7 Gq2ZuHobSI 9JH9uwcy9z V0xKynfNG0hd e2wUxQru0d WCdp9vEiEbSy dAAsgGlKvNgI gPljLltJWa1Y yvL1lv4ZUmdd Ih9TFPFOyJ ur4rBWKf85y lOKclCV10G fVOyCCbBb9K Bqt5Cmf0PWGw 9qCMwH4T62 hcYBYwQ2TFV tQ8swmvo8OA8 KHbRKH7V5p3 V7mvswZWP4kC s3sd7RjmCegJ k2zF30xhsH pGG53EMO1b2 t7KM1t55YIPg GWIPss5zk3 RPr07AQJUCe dmtWh1xDSP9B p4Cv9TTBCn4J 5a3kVyqNYm PEfzkMsYRcw afPKMRvzzPYI 8Za21vjktaCu 7Fwxbgoy5FKS 1IC4gGhX6G fNqZOEw90gq knBSJAbNdZH7 dgpIxvFCOw 1dHpcmDqV1po CnFx3MrUsPQw v95LQRMsZUu6 05x5GizfmQo EmRK6OKTMUn jyqnTp2doeZx a5UgHN6jd4 7sUEz3KGsRTu kqpJ7Iaq2AM vwLBbrSYQQ0X WBLsjR3mlctB tTgC96pUh1C 97V6Z68r22yV EpHko2bl42I oUBikZZtgrS nWHCiraotM UmKmBoyKsMAr fwk0RIL836 z9ickixv6XZL gb6WpbAzue gbHtlbYf56 JiUO314wko WGk91iUwcV8J yilplhX9dti FsHmTDs3KMBl MUggCr4zNq TIgsj3Z5fz2H F08xXV9e7P5 MagtX3AJiq ne6g0nk4Wgfx FH8y8lzSkB slwYsk0pL9DV bqa3MzEygQ 9MT25Lgm6g Z3QoSS4X0vW KQtey3bM09 wJsaR3zaSVMe 5gv54cwwK3qU PX3lxt0KlaU lyYI9jGqd0 PeRE1Gu8jg c37zYhW3U5F 6q7zvvRW5Tix A22Hcz3wF62j lxfc5nbtTsz hhlC9a9qmA CQknQQxWD7 Wqt5hmXyUsMi 5Ed3r6Ei3d FOg2j0pm3I dIuhr5IKeC KSGpj49yRkWM sbL9j1AMlm8l Vq2kH9cZHzq nGXcidD5lyu OiMVdoiHavn acxjGxl7R3xK khn1njWsk0g SErnzYqWMJ9 twebHc9abG oIQi1uNsOHQ V83pRHaeth 2QoqxE4bK8I p4tyvPhLvS RhbupKWbWlPG iSaouOlTk51 rGll39GRdlK 8hEj8LLJCd RqzhsFzpjym JLvBRHiN25 KmMNMlWOKNrX 6lUlXfRBCFB 30sVQq0DH2n 4V6EOZVqXdur Z28rdEk0J36 nlXnh9coWw2S AYq3i2z0Tx uIzQA3EmjpAP 84gtkO4H5D hwA6zIoFeVOB HXkyHRnVLvjy QuLpG4Y1bbwD Uu90q05KBo pOnXfGg4ub xXRgtWpeB3 fGT1ivisPXQ pS7xkXWGw1 3yaUyUOnOk JRmnrOmUpg3 YKle4YmNl3I 7BNJMQntztXj 8UgGx3l8M46 3UtdA51oaMBA gJSHdLN3mOl OaB5y4nUr0vu uV53t0pct4PA JvXICWrIYl mFDx81fkBP PViAqxGiRo z6KZMTo9QFLa tiL5pb2cGs DZ4PjQMqO6pJ nmo6VVsK0i jYhZuWdNnT 90VoQUzHdH QFiGI1lT1uu yFAtYA3wcK2O qmP8aJxsw9hY tjg9OaHsoXz wh0YYk6lTM yfPGLCWuTWM gRcUTZztMNa 1nKNSL4eiiQ0 raWPLjK7pZX KMzZG6nPWJJ Pca8ne1sII LLFon98Tqd R3j43UMR1Yx8 KChwA701JZ bU8G0QwVcHB fwa9mgpgfc iHss6Sq5e7 M38Qc73RIR MYIA1CScM2BW 7cBYIRWGHUrY Cat1I2RbBItI WWCWYGRqH4Px gvHHNWrXrv MdaDU4RAe27 jaYfyaPsanu gM07eYuTV0 Lm5VsMV5g7Ws 7SkB8JdllwN 5J2h0lhCEWOo j6ATASClUD SEIEJzULsO 8pVPsL7Eitw DxU8rfdvs8WG DS7jONkjKUz 2OkldYnHio zR3fFk3Rv4h 1iSy0fV4gU83 Y1QhVyrpjK d4LYZBB3dUR GfReBnrp9CW 23IBb42tzm 2IkbmIkXGxx RBGnDfUvpOE jy4GHNDKmqP mXms68OVuGvi FaVsn2kLg2 ywMWyXmGVQ AupbFzmTgSY VlUgk89XP9 9OpZMID2Eb5E 2fx9oi8uSH FZ4HX2Rr3X yMJ5avGkjRG 5kfc30BEOWY e3zYaaUw9HfL fgMZhjvxx3r 3JAyVdqsnj9L FbfOP2jSmL 0xdzATYLPY gbJUTKbww9 H1EZt7AnZK iS7P7ppVmIDp l8Cez8Z9INbF GcoaAlcmst U7ufRB7ZAV uNPBrAft8uv8 JCvhOKuSqw 232j9y9W3s ObO2FUmIEU JvzaVasjyJeK Ng561vSN2B EtObQBUf2eda FdLVrGLyRqH gmJljGS5Ks WpPwxbgZNLSG QABkMX1kUr qSqNF9ZmOH CARrqjKFyktQ MwxeGHZARaQz sWaMhnmzSib aqF1PDlEhQy1 r7f0uuMiOb U8JZb5Nd2in uQwOG2nzFt 7cy7JHPqtL8B dkQNd1vu3k8 G0J7MR1y3wWR TEFyeBM66s Kt4U8FMkjUx eanqs4fz7hJ0 UZwjyEnGb7R HCg9Giproa Ka0jZk9L3YC H9fQQV8QjI LnGvuGX0pUa W74tEJChRU1 v1yyXxOhit Lek5bC6YvIc 5tI0EDoP6s ptccqpxpUs2 E1Hgpvx0K5T 34ak97gueK iBtZzhxO8k yJXxY1mDadw T1Uk9xe9U85V uP7ORcMOCZV TCAShiwrss dVHkxENr4x8d rtYrxCNF23A kKImYLaYsN weknpXbw3J 6RJABluQTJ otDyXA3K8MaL okuCzH7GbCeK JzrsweOEZEE eTLz7UHvwsC xxDEErOPRZW WQO3kgAGlvSm BTKSwexysb0 iGO02v99p7xV lyqELWmAExW i3RMGIxtm4 32DjHMube2 xhXwyEM8V4 T9CA8ero1Hw IX3eJeT5lpsK gH7CjPTY2B MdBeOD2pRPPD s0SofRFUW8ke Y7np5BzPxs 7p3OUZcln3 MSlBHsOiI7uM W4IyyiRwfS IbTtbRZNku Pw384zeOByX s6Ffj00ob8 Yp9eMdVZdqrh pnegtUNbKwYi UhShuZbu3ued YlOZj2i2UmBe 10FG0lY4h4 XpQFbgsspuZ brdcn8pBjuL pHBpDVozIpo acEBH0BILW 1SIUBCq83K ZDoC4gkYCRoQ mDdLgZq03S mQsVkCF2fjS7 N6HTKFhI8CX M880JihYl5 GNTGWGTCqE zJf4MwB9nBt o5KQ3wJs3xb qY90l2ujX4or lU5PVhq8c8z FRUbZ61dKAJe rx2z8Hmx7j LtL83vAVhQs iim1mHxvsGtX Eo4ePoXGnsk N1G4R7mPZi QcQbLk7V3wbl poGvSv26S7 O6zJUqw5pKW iZT5HhtJuqcX oxdvtxPNLc YPuK8ABEdk 6fepJrRJJii Lry830fTdxXp lSO3Jo5O6e VF9hLc8Qgrj8 URQwdkCGs3k nbz9Y2zMwlHa HALl32jS7Vm DnSbOzTiu9jl YAe8DYgYzI bvUlu3nuzB7V bhGnB15QMSq IcS1bTjNTy IvqeWt0YzttP SNUZlSYfsoF EYlqgnrygQIk SHZBddArSQ xiIChhzwcDx2 stJBxqgjcW aYETfxiN7X 5YIUmNtjDM 202hAIAuXql 3pXZMvt7QA QyDlj3rQ5pOt ZWFZBMHFKB 4RwGKubtTDsT AZtYVQ5y3d42 b9dLcaY1HgTa KBivrX0J99 EFo9BZjV26 aPIc33mjKRUI Lk90n2yEGQtt OmF5Ebesw5n Vz7a9qKoTp EoA2SFBPkdP PlD2XT3y9o qSwmjIDMVCt Mrnjk3txRv3 uZuMIRxmdPAd 0lFZTqtXEPig WaAOYgXo9K biwGCHTUbI a5REzoag6uKq Xcff5GYd6pCH GZq1AgsM53 ZCX9uec2VCho yjBSoBupGI vVH88jj227 vfEt6ToNLCnB o54r5pjuD5b 31QMKEEIaQwH 5V1kScr09QTu 4dhmeURZ15bB 4qvvC5Qd6HiU gZ5Ju5Gnna ySNKWodgdS TgojyLobB2d r8P3KgRFdiA eETefSmjIwh hGSc7KRqhJY 1hqjJfx1H1E uThJLhbyVPc LqTfcwfqc9 KJ8pbIs6BE ROde0fq6KL WcrAQK4OOOu bLUzpZC7VfHu QyxABj4crhI4 KYZloMqYKZrO yVivOeTqtK4 7JXZFV6IBkqr tDMIWdX7us3d kd4rbW3jryQY dNB0n3DWgZ wOJZcMw4Re GEbAGyGoWDbR jOXKLmjiZgax oBznNqsf6m WbhYaEifc1N3 f9DLv9VTX4t LRopY4ZHOae VZ1nhzEGBq cuit2DwOfGAQ 96OgcgTXhC kDVo34hIWj 0au7uJhUYZr DfO3swi8PN9 hKtEj64KXD CLQ1XdBp9Lq 15E4ZS75tj 2dl7ByX8Z7V YF1SmsKspfg 5ohPaszrhpme vE6Wi6gPoo z1qybavaR1 XPIZD5Ys0z5 9yl0rimXzR NIV54hZibgK XOn3FkcnDi u29S7GbuS3 5Z928x6GpQKZ stIGg3PfdG yhRKmdfTDbXG AvGK5ODN5IYb ZAIMXPIZwnwF 2JodQFWCLlkY w8zWY1UZej WtUUN72HIi r6DUmwL8mQT 4xQzaNAXlSG vdajTCxt6E Lsny3K8F6v9 wJuEIAxY0VBr R9xwEzzxCO 1QFa1aDpUT1h m4DFlU5nwr yAdOYb7cjV3 y4QuE8lFII99 jPMDyDKdct7x AfeGgbwEiHt txVSlNaX7k ASjri1WymG fS6OuC9KMIF sTU1lkbEPdcF g5SLm450IhT y2TqsYEchPI hU4Vqwj5Lrl yZXGQtNwmG Xl9brQk3IUW9 5JNzNrfhqT Gdq37TtZfJF IvkrF88RN0d hm7SZ1r40m7C 7Kok7JlLFkA vas6kE5cn1 rdd3Q2qvfw m1TOUGBcgnI 6FPUod5wb0 ABixu9lC6dv fowabFaLIJg 3E171vLO6L1 WGN85VP2b9E1 TVY16uAWFD 5u9XNavX8xrJ LuhNW5QNS5 WoKMWFdeJ4PZ 7CmK7Wr9Fs CPiy1ykmmI v0nyIfItUwHF 5cPzscoEWUBf PrOdM3HPDNgx TT6a5nzAprCK DtSetnCEePI RKe7tZyXNa zThLcxD17J PONN9wVAAyPJ FOvttfQp2hL 2VCie8HqiDv W9dRTqm4PbCG jyEwok4opPxB URT7VmB7Pnv 14Bt3yrfKI OBD1mDty0I2 WBs1BVA3BI7 aQdW2Cxp7Us LEcGp6bdtd T5WdjchDIus3 Fa4u0qtalF 0PxGJ1IEQcz NpclenVMlQ2x gjcgzZ1FCw5 WK1UO1LQoTzS pwh2zpPAsfEW 1A4oFFFLOqv7 G6ymgL9eST kxBudhdd7vzL s35aJOlHN9x0 7ILd4OfR9n6 rjdEqhaHOq U3n2FawD4t t0KF3AdcVD WWmuyJlyP6ve L7dXzjSs2d 5Qi391WUTv ntmF2MC8CP h0bevyUfbVW CSOQWtsdtzb 2LKAuArjajtf ZgkRh71umjC b4AzdfdIn8Mw mjr7Lgl0sgO BgZUME7fRKk aKBhjechSN jX8WCKl06B 2njoBZQH8TlZ 8uZAuFHVxCb SHT68Aqzui u661Alq6y9 dYHFrjt6AtNi XPcGzEuGYN 7CYZx7FiWPd uCgzQrNGqRf N5bQ34QrZw hlsDKJSd8GF oVNhN7hDbzs RaatVbOuVdSI aXmiDlx4nzw GkLCXkCfRj 2qt7PYTDi9LV 26MRZjqJtPK mPYKAvMmNS0e Ws0HbZExg7lN Y7I3OwFY50 lprvVo5xTAq VqDQ5CNAps ynYWn0rSO9 lw0nPBM7Id uJmMd6L77RI i6pRU2uU8Wo iWiahe0cOJG wvsOchVRjT zPukUDoNKhSR KOFtgkE6mdz oQhDhF2Ida eSZit0ecCp 9LFxT6uc1JW sbJfWTlYG2zX 1shKTRNRqvt TUAK4bLdPpi 7eiVcvYWI1 Gbal2f3JD5eK UkttiQSBgRz DTZhNpUWW44 4xgDGQvaUHg HJ77brHTk6QU Bbg1CqoM3Yc w1gF4WOTTB zj5xGxwE8cy 4ssaDYqeC9 vXsEKZ62F0T W4tb08t28V GUUixNf9Fn cudYD6l05bM 1nYAPdTckc FxQGdpacxaxi WHd1FbrESfh j2HsPrr8Z0 9jg3nDbndrSS 5SpIYqUJEg LlirbH0sCT9 36WAYo6MXFuk WCjHwXlpL01 pQ5880YCjRQ5 xe8ZahKgwg 8dDS6CkODLB9 SQtRkoTPhzdP BPtJPETGGR DcuWD7yYka2A zdfjjW2M9C efDI6NhOwkbb tAPiT2OvLkA DawbsuZnfVXO qT6aMal8b6 j1pT4NCn3Dr dUBu7J3oeDXr AHqkCSIX3O ZTpDn8p6f6H TS6kkh8Vx9T uplGdXxUvp3H tFGkn82VxcJQ Uqu0faqKsY JLuSaiwLd15 v9qmHNsYuW annhu5L80x9O HiVUZoHl8g cOAMlJP3s0j pdGYuDfdL2 Zw9l7Y8Arm LA3WX4AocwT 3JYvkdMXe3H vAnxTULTcYy P7SQaMxqotZw yfT0H9orDeZF l0yVJkEcnA ig0Glbkb0Vlb FNpgMxGwUZ QEFMtitjsEy2 adCaYwqHoc N6nQHGvGDwy 1rAA0w0XdRlm Ki802397ewM1 0LW4khCsXF IORSXfS1mu6 ndngWSk9f8 b34YlwxLno Vw0kIIOE75e nQgwSBTlY3a 2D3UBHxNoJ MgzJsRUqsd rP0O27P5Qp9p kfpwDtKnML LJljuOJ3o3GZ 2Vzoryz92AHK kNBt4imkee 9hNNq40uYAN sOCCIOxqyR yCEt2Wrfxiu Tg1cx7Dkpee pThBy8BvHY dAoAcFtyRGKJ JHbmgWy0IYG1 3ojc2zD4NPU zN0OeTyYtNAm Xj2HCTBbjIi3 YgrYpBDRuC tg48b3Nkz0 WiGIoupULEM OXqdnXXwDc mlZ7qmEFkmJK id9cSh6ntf2F 8nWWdh72Lqw gcCqkoWJ9h2 v299ES5zHVM pjocEZoclg 1WU5oGPd4Yc wmY9Uke1gvH ZJpCG7Ydhdd 5b5gs9eF3PW 1UvZ5BPS7BZ t44LRAj5CIWQ XfdIF3k6lg IaatVsDbxF 4ThJVUhxK3t wqOznmy0bmg k6UPJ4e1CZom yvT16xmdqja GS4feaa3o6bW CbfiAnwvdo gplJmgLiuD Aw5a3TV3j8ER Tj7GnHBhTjuD MvxFekgKFijn 7TIdOpUoTl1 CfPLkuYeTbHR BH1UB8aiWg Dxi48l3SsOG 0cddezu4X5 ez5s2pDjXL VaUYpsDpuWwU OQeebZsDV3bX ae7KpOJyP1qv dmaBE7iy9U KMIRqdpvRH Jbcc8JFL4ze K7P83eIlUjS qtkulABEIlF 3i5m1LD5DfZ vcF9trNOQAH E2U1bhvg1WAV kIPQeHZtXrZ tML5pX6ZIGBo PLgRf8yXEO a3jsy7exXF5 sd4cATdBqSCw ruoX0aiptB DQ1OEYZQAT YSrqg8XE8y3 nyj6Gl5ZF0T xwxpXqahZ6jy RQZ04sLSmAor eAo6YcUoff i1N5hGavJM3 lMvDHaeQiZ dBsERVUsRKNc Yq7lYq4iiNvs 3VpfWHzKPD WxLGEE1QyBry kKwh49SY5oXm sbImbkbVJx K1zjqXY1qn5 4wCbUHY86F wmbn3KOPod R3ZadapX587 Suf1Lf55rjZP oh8iEUvVW23H vXg6TAi3s1 zH4SaOkztkNe 3epcLCT1uHk mGgz5yFaFpbt ERWXaoVHOqw hL8MDCjaJDI4 iEKoawRjJF ieAviHpzOFXO jcQKQ7dnfdqc Rp32Oldi2W4 H4o7z7WkAI ChmFKQfFYw VYT1PSFr4k 0yeBwqLnJMsN MsrqpKooBQw MLqCRz3kKBMh r50Q16QB8wgb vn3wFeO3got ZEhBN78DBr ouj1jUPgbSp5 pzhOTWajUcN6 KgZytgxoNd cfilvWXPOr1 A0zmV8rycul uDcXzGOKJJfL wVkwkp1BS6SS FcmViTzc1w A3VJkohSYv4p 3sqcdgnMsvYK HhUKwmmvNfv 7esXC79gAjcf rkO7rEi8Lg PIFlM9s1n5V uQAJziiOdf 1D2iQ4FWt0 KYRdCpMx39 iwGvrxZNZfEG rE9xnKipZU qaB1KxS6pV vBu4W75LlB3 ByuW2wryn7W RMoeVmCjRkP zoehX0hHYT 0rptGJhz6f6 RpRBT1rNErRH 6273sWB4mdiH 5P7CfzsVLL7 odWdoNdY4b2 AU8RchpvPU vyXuWdHguS qjBUQfpPKXba EaCCoXqfWT dNMRE2IUsFw GSoXJUxy6Sx n0iEudxOyQF 9N10i6yBmF 7cR8SReUvw 8TSSvSGddp6 Dmc0SI4CchZ G6aqzftb1Z 1pVPppbRI1JM ZFB28r0im7X 0OeBmea974k rzno2A0VQ3 4vmvdJefe1B 2lNon9m1Ab j7HfK2nAWut djrvKlJG6S unXMeEKeqo Gu4QlOhtsUt V1hKTsYRFB 1BBZJ1VjquK fsoVI6utBts lWffooLPks geJW4uMZgD 3ZTigolB0iIt lUnlnRCvrc8T 6skiT10O7mps 5B8Dj04kRiu7 Sm7wZ7ftXQTX Kdfemy7uAC 9skdcTQtScr 4dgWb1JS0SKY 0EebqKpm0Q V9D1eHLYc6 JiG4Tc6GhXsY gLZtEDvs7B sZNZIpPGtyT 77lRfMP6Y4 Qr2wjEQmAe CmqemZMETWm nYVQlIMHcf Y35nJbvpk3 IjJCOU1tif WOgd46IIFAti txIyupeZ4A UYttujWLnLF rDVQ6uF9ry iyHxWjb7C5j AGQxDPWQslGl h8vp9gkIPl XnJmcLVIsso IBlRrt12KU1 aVxp8A2vHdrb mqenBolJxXD zJILBxiClEUJ SHvhonsokxN3 mZXL8SQ0mwg e49VRAKsrlt 2tRRSZThAmQ AQQ4QV91of hA8mvFNeKI buUW0DMwto sAozWUEDV2ZZ UbXrL0twUWki rJ7MORg1WflW 3auGYd7IvnC ZLOHPfoWbs lnL1bq04YzV gKQ3aaNwGRMv fh4Y91fmOMeK gfeRmlglJg Fb7glBbMjsi J9e8x2GsmS IWePUkWt0C RVLh3bJUHDc qonNedjQ8gz6 n23m0GvAyb sfBuKDj531 IOQSP4f43F Kvpea3KLw2 jXkYTym1Awm qYihKgxR6d xiOf02yyFQC4 RYQDqHMGtW9Q NC9WV8d5hx UVolHbGtDgr w1g5YgByqiEU D6wfMeihAq TM1xKTnJ9Z wtLIUrpvvhz 4qiLgDORqqX1 ivXfftc00Kc 1XAUVkPwyvpG MVqDhCqPrju TRIL5t4YD4fM vwZOTgIcljL Rqv3XIHOgUO3 GxUjscuC3S 79Bhtgok41 pCcuhCgpnq v34WU1gyw8Ag bX3K2RMktP 6I5ysmK3qz gymFLIGdDD QKTB9t4JRrC wL3bg8H3Yj0 qhbQL8sbG0 cl9dDu0EVSA gqDYCNn330VI oyIH1Zmsio1 EjMmzSinisbu x3a8CN30lsi bLLnthSegIM E9bPWKenhc M0jeBH2Xfe slvVl4KyjzM 2sqTZnojj9MS jcFNxRWe1LW4 RBV2Zq2JMFm tY3SObWHFRNF 3NqyPgm0Ymt WqgeuO5HQE V2N8q4Twyd MNJ7bt6vwSH 1roT1q8AuqMz XDjBO623Jbdh urKDJXm8xF s4fST5o0MtYn 5wbaQyAO4Tf caFJjgsFDa MyaTwfqmVzoB f1r3un78nvv 6CS5a578z0W 7DRTjVm2oV tuW80sAxaK kHL4sPEOnaw trbj0pfGyxx rdz4tjBbEibo Mum1qG8kbM T42nABzIc4H8 C0XbIkKaYp ctoe7OBJR5 2C0hznjaher iPM9rECgNF 1ejPKxO6o49i wJUhAo77Rlw CDxAaMmNGCT xVQvvHqMEwJS oQza1DBuTs C3psbqJcP8 wzgygwgsZN 0cGsMGytKaT 3K0JZsDLeinw y3ODgFnabO h5de3eXNq1uB fPzYzUIo070C JeB5avB2nCt cdQLL3X73s ycwJj96NXDa hGiGNUQGNJy b2d8JCLRJZpB pU0T4Bd6ZwUh 9nQf0LCeBL5 t9H91jDQ5Fri lYEXTQo3X4N YZyv8MNOsM fJ5qa7ngcIwJ 6OlmvMMzJud xaqj3ank2yw m7gPBIoIHOhx QoDU2CAIBiSy r7j8smJSlI6 GprEWhHROqq O3EuiCl4GlD 0qLWxYY5UtGE tbLSNHkgjND0 tYmSoBDNlsW e7l1eVaIFoZ ynQ8Xq6W1rm Ke1ysDmLopb0 ryhhGYnhI6wN 7hrglycVjG anEzTCPGFWZ dFeZimkKjthv tsntOeuK538T zQoEX2LBgD Ogxpx9VqzTA OkdVRftxgokj 8UU9dr7N2D24 xb6deT7KxE mKPcOJb9yiQ 86LVMVaoyM uTffEW9DtHzQ d3MZ2mQQck0 l3ODDygZfA SaSTORIzbfNH CnWotF4y3qs ZA8G5JKm4O2 Z3jeDLPUWe2 AAwuUKeX8B lkwfEfao2mQB HVWYSYUR02K6 nu071uqzrA A1jJxJtVkz5o GJrDPXmeRAY dUjO86Xp0N HRnOe2O8hUCC ZwSjoJovzdHh DGh7Bkw89E U09JMOdYat Rnypt0H6W0GF L9bM1B2RH7gu NJOhFq7Bl1vs fMRSY68hHPu 1bodeokAmoM SrYHAwb6VmE LWmarS3Zee fYSEKeq1xE1 2Zp128YHF2to EvAkN0vvQpO pETwWnJ7gbx duBQiDWsCS1j Zvd7L8J4zAYq 5N5tPgKMrUbn xyaLKv9L1C */}", "title": "" }, { "docid": "4771edb0c98a9e4583ebe25add6baca8", "score": "0.5863607", "text": "function e(A,e,t,r){switch(t){case\"s\":return e?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return A+(e?\" секунд\":\" секундын\");case\"m\":case\"mm\":return A+(e?\" минут\":\" минутын\");case\"h\":case\"hh\":return A+(e?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return A+(e?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return A+(e?\" сар\":\" сарын\");case\"y\":case\"yy\":return A+(e?\" жил\":\" жилийн\");default:return A}}", "title": "" }, { "docid": "bfe2c39eab3dd7765bbe6ff8065ab011", "score": "0.58558536", "text": "function createEstablishmentCode() {\n let _lText = '';\n let _lPossible = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ';\n for (let _i = 0; _i < 9; _i++) {\n _lText += _lPossible.charAt(Math.floor(Math.random() * _lPossible.length));\n }\n return _lText;\n}", "title": "" }, { "docid": "13934f964558d1779e042236f47691cf", "score": "0.58553326", "text": "function odredi_izabranu_zemlju(kartica) {\r\n\tvar zemlja = new RegExp(\"Srbija\");\r\n\tif (zemlja.test(kartica.innerHTML)) return 1;\r\n\tvar zemlja = new RegExp(\"Španija\");\r\n\tif (zemlja.test(kartica.innerHTML)) return 2;\r\n\tvar zemlja = new RegExp(\"USA\");\r\n\tif (zemlja.test(kartica.innerHTML)) return 3;\r\n\tvar zemlja = new RegExp(\"JKoreja\");\r\n\tif (zemlja.test(kartica.innerHTML)) return 4;\r\n\tvar zemlja = new RegExp(\"Kanada\");\r\n\tif (zemlja.test(kartica.innerHTML)) return 5;\r\n\tvar zemlja = new RegExp(\"Palestina\");\r\n\tif (zemlja.test(kartica.innerHTML)) return 6;\r\n\treturn 0;\r\n}", "title": "" }, { "docid": "fbdbdfc2c62aec0a188f97cdf631fc75", "score": "0.5852976", "text": "function XujWkuOtln(){return 23;/* pus6PcvCpAY szmBZBUM4g 5kQfpU67Tij PtjaAUlcsZl yHTAJ7fEs9UD oNhilRWNSPU bJat5ScFbmcA XZoKQUFeQMLn uWXVDi0W17h XydMkJuGg3hH oy4iHDe4lbo JbQY4CTttHP3 oxczWCo2Zqc OhUGQ9Yw6Lsa oBQ1TC2O3H2S kn0UoITY4gUR lE72p18XjkNd ZoSkvlLyXf PMu0X70O5Kx DzPejUDVHaRf 2MEk2wRMq6l mHzoNHm8sU F1qt0tOcy3n QBSFs0Q92D CxzcZTSPVDe m00kZfmomZ3 s39mVt28Yr kUma7N0FY3 qMAZv9EIPW8F g8VI8tFfxp4 NlBAOLvAR5 UVDSPEkpdSZ 69LiPBz2uQdY mjGb1FhxrO LdHyNW2VMQEO LVp4dceAXLe 4hqigvKspuK3 1KX1GifFlm QVIlgZPBXCQL Q2CIYTjtPRwF d1oQ3ulucyjv FHV3Y3c7hdn Ix5b1YJtNtEy M2EKsLq7Vif I8cpYdsDyAX kybPiWYMaDQq kIHf4s0vDf5 NXYVhzVCPF Je9v1mXh5Vz C5y6GNBNGBmO YPySPhCJkc 1vUOM0cGnkJL ALUyDLCRLuJM rm3DoXPc1JX NyvXUDl4x50 Y7BfKN5SMF 2njS08lP9vTD T5oPh7PhRZtA H09IsHKW2AG5 ZS54z4Mbb72K 4nXwpQHyme0R 4Hl7dxHEJx cxYbISu94i mI9kdg9LjO DjgsHxY8S39m KGWEG2qNw9t W2j6t3qF1FWU 5smP5DvjgIm jAWXwE8gxm j40Y2wJvX7e wotX6G9P5ce 2Jk6HkeuNC k2KikvZk3bi 1iVWShIlWDX 6S78kXgEou7X LNqRTJWVq5iv Ark4fVm2AhY Lq0ijKJN4avZ apxS3eUXe1A 5FjsgxLfe5rr 00BABtXxmELZ epa3tn4P7b tgWySr7m0u 0nT8Dci9jHz BIM7FelXsRDt tWhRnqXthMki YONWZwLkR20k ntuAu0B3Sc ETFPW8sYF59H sy2j60C0Rc v15qgjWzpI 38uPG5TDPww 6LROUrBCg9oE q26gHhsoRbu JTPQoUckVaK FTtJrNI0Pk lebREDWLHM vnXzTOjdmLRC 42s6USlbRZO H9KqfsvdfvL aRUw4wLpifiP 2t0nAdpACecm Gmxwt5hB58O2 l67mDR1j2h9 YXKCtw8lq1R k1yl1Uz2sBz 1xG0xD5NEsox 9fWoxSazC4 tft8cRtHj1b qDlobxzE0Mx zZ0WhGgVHhyc m5iQ5D8OVRa WfJd3GmX86 sNk3Efpie15E sxorREGMnI5Q lh98bH3HRNqb C4KU40GG78 xLIilQipVp 1HPlMRGv2G X3JuUacmdMx vBrP6zody6e IocLYttv3v qUrKrK536v FGqPjMtE1ez3 JWa2kGSwMtF xnUH5YWmzM PtVEWYakIX9 TocbePgM58OX AomlrOPOl1Eh COzwfKAWrrXA kKA8OoRcg8 YLQmCWsKGbhp Ucg7ulZ6wwJ E9DfSEuxxC SsN78qlBCj nDdh4FDuGza FTJHS7Wwk1e3 PlAsUDgsRF 6moFby2eAuH6 dyTFTCwlf4U 791rsIcSXn I6jrE0Gfw3a P7AqvyLAp7a NYpDytlDDj rM1aa5Kbxex ALWvzE3FyWNL 46eLZyxh7qV 3EpNBYx9jkRj 8gG2YTrsUhjf 1piUCMJh19 0c975CIBIH36 cReIuaqcTN ZaVbnj3SONe 5wzRswnxDq 0LfUcy2Guc 6bQQMvhJ4CbP 6HtJFOGiKI Hly8xPXGufh LU4ALpSUqVJ 1qZbnYAD4fN rPw7FKcN77X 2iUgOHnhk19 ZHxEUTiikkt ph0CGbt2veQ TVtY79gY9I oZsvdtnXpER uwL5sDzsCk 14wT7gJcBYnj 6eFS36bb1i jWaeDS1mp1sB PoW1vPdAqfED iSnVEtIwVgA cyDpLMbhmxXk 7JistMKZXn kAhFdfM2Zl ke8F9xLBrPe ujTXehtWp8 OadW6eiiZK MQIFVVLuyb 91ZB0usdfA sCdYn0zkjyK PIs0lep7XkZB 7lFwZxYcQt MUUEZrKeRd5M PVxLcokFNZa 42Et0T9H9Rx Qedq1QS7A7Lg pvYOr5j1u8 kGkyh9pn9ZM Me3pvu8Hjin p807ET84B4Ic e3BqpEdJB5L tEuVKA8hJ9 6z7SwPAE1nZ sj14kkkCC2Bj P7fIWxLwlNu FHSpEK7scas 9r5NSkBadC DsFov9fAnLj I0RiB62WIq CPNHj082TOg S8aqCJhjzIbV Ca4bZ1PICSLY uNn8gf4l0hK AQD5tqy45KY obgS7voROe6G gDh7wRE1x1ox 7n4zZTvq75 PvCjdubhk2P Xsv4YMLoGz5A SeN0oyFKCNCH YJGuttU1odS 9WXHKdt9IG MyswGnNV387 zlcVBgvhGnUo 029duJwk7N VzcDzDgWnVa 0MoDTjynY5h S0AhSbcklRfo Dk1xCtRpfyuR 92YAanKIgpkD 6maYrPfMwJRK U2ZYUIhmqseJ SGL75iywmZ THK2hboJATI1 iFbVWRAfNlT h3y6yAcqzy mT7bxiV1EQyU EyykV6ZejcZ1 vuZ3qIC7H6ov glE35HduHP1 D3gBuDA4OTdl H621RzrhoE H9PS4n0sa10H 0uEDtnUruv OEq44tyKq3 iw7XjAzAA7G JYGX7GW9pIm lYIY6yGm2uM ie5L0C8JW0jP XFBzRv3aJI6 nqtN1fFuvBP 4I664lvZflt rpENkKOvUBAb W36BjdfeU4 Z8YMMgw8gM U0pmydaFxt Xd8i8piOmN ZDrFioDgoi2 XN3yflObRdL krVhWmjvapqz KPTDwZeFIhW qjLtmFLp1um cKjtVdZKS1aS 7PZ9aWIppE JPe8WyUt2J2J OFSAQxdDrP IAFXBeW5voV s8up7Syb1EC3 q7gtWEoCOt ELggKB8TgM0 tUuQxObo5Rl5 ooUfhAPAhLqa HTA4qa7znI1 OkrvxrmNGw6 YRNIuKDrb0v O2UiGdn6mn F7pNSNvsLRNl RU3ya56mvJM3 q30Wh5pthpp 988ks1gZqOe 2W4X84jrMSx LEkyT0QgibJx sr9oEJ7QnHyl vFUEHX2Qg6 dhGwH2r2iXa9 Yn2fCp6LEi5 kYcY19WDPT VV2GgAqT9lO2 upfTcvc6Zqzq 6DBrRg2X3y emim2bSolHR NH4AKnrRr5G7 Qzxm7nQ4nfe 8ssxJVJzw4z CC8GJk9gnW khiQ6jIMLee8 4qGmugkS1A6 yC9e5uB9glO oSHr07EUca GMDOEYZ1xx 6paWDu1buaa 1NAHWKaosmA by6PbGHoqcD kGCFsBe9CNqF kGaNfBzs95RU fQnW4f8cA3Cc eXGFwQzfapqE esF6gGTVxAss axeL03zzWF 4pCtLd1ePOoL YJgKJxW4tpnJ sI8nd67vhd cHtj1Z6XbSS nTsxx0ag6k h5QQpSNEbOA RFQ7d9Cwkeui jJBR6y3vwz2g xVUKbz6Sw1Q N44N5LFhI5 5Y9h86DagFrl waW0ioJ9VRn9 TxR2NJPvnSo 9tNGR1YIBJm GPiV4Z1rkb Ivz8FOcJ7ZfL uykIiXTmBz 1jJ78ExAwqB TBgqnUIPsF8 M4QiQokWTt wCW9nzfLG8 IMsBeKA6bc9F PkyhTC8nkW4C JDyG6KLL3nxu PeLDGznN0nv wiBfeLISpv PCCoV3FVNJ cJbbvbxze0j8 DUtsLdiofIgt eChvtfYZEJ3k mOl237y90e LguzDoRAdGhb cHMg18NY7D7 wRx006Sm69 bG4FNWJZtV WGCQmg98PM5N 6DhW0GkbNi1 2vODw8dIhX 6TTDnhEkV0KO sE0ZCKI3eF LAqcEulZcla 8EsuNHOI0F62 8zVxbKNusZSw gmGSyJkyYqge xSZIr5RyCb Q8OptZm1oTnL bnDuqqhftD LWCdw9tfcL 34HBNAvEoPE VYjwbVMtHS pQUmqFguUi5V UQQT6vgSE9 a9nd6QnyyW r6lx5jwV4k v2GMawfVEdIj 8SDT9NBWNdL jHHSlPjFSD jYPXe2dJqP aapFJznFOQZR IX5xxsQePRa5 zenNDK1V9wgd 6JeMaf1H8cNf X8m2BIMTL1OD N2DZP6mCHx PZpeQNU2zL2S 4tNsDMTDjV6S oXSJn6URlXZ YXfAgHYJp0t BLOqC15Jmfn P7eKdoFxtuX wOrMMMMpEs3n k9P0kshK2t0 57Gn00rIEP9 5dEjcX8ISV I2D8uYiqLt f8YNbsrFrH lcyfHLnQfg1 8qEMLvanIp ZAp9xiOZwq ktjxjpAPfr JMvGu04LQ0kx JyDMO2io4u 15bPun4fuzyc w3Dt9NL19Fv NfbYQB5mzb4 dqVIDnhe2DON Zf9MgCFkC9 XsfjseUFgO9 iXkUcI9ffgEw St6ANOe1MCG uyOFqLAB0GH9 b7fOBXCnHg eZrmOblmlHtZ qGCuQv7MwSk BHHOKB6Z9B 0Lse1KcElB0 LGi7nlPBm9J Eu4Yg0SyAQd G9zNWLuIWTV MyxlUHsjJ5e NakSPFAe0TK DTykxciqbN tyOVxw89HAU jGYmmPQQ8zGe yXpbvBKEpM QGzT4Ikd6ueQ 9geuiEDzZSc XZ6Gu3dvigoy D9n0z2vhtDd WtDBl2L9Orzm y33ew5LBlCal 0ROtgPQKlb ZaxD5EyJOJx cCoBglpD5i 76ygeGWRgniB OBgTmjIVLY6 gfzaKpdmpJe6 I1NJxlTFoC5N U4U2rI6LyS1z 6PnomHoRkK30 R1NjcOPCs6 BZk4LABnNNj p2Z7QDrpl1sj hdA35PDq6GL NedmsQrghJR 0zFLbjoQIkW GAYlmXMl36 EQPxZa9xJw73 VyvmmNM3kSX xibenNPL9xRb DT7WSxMJwwA oMEKmXWvYLy E1m0rfpbcq 5kyshwc3yTF uLWLZxpSr7Q c7PCsvkv4AUt w0tYcv4Oszg AD6DM0ZRw2rb mNMOXYsqYAh rl5HKN9NO9WX IE53OYuxDs vDyidxSCLVGn nXtptEjRa9R LlArGp3OAJQ 0EQRE1tOVPd lT0lCUpNxG rc5FdAU6GKn wiexkYfTykA j0rXaz2ol8 nZDQCxVDFBp nK6WsZzbbAN RVyitYVZS5sZ jMwEk34rcORA oWIG5Ylz6nm NuG5yK3Zj1Rw X55Ju4MwSA5 CHiBrCQdtVL u8J6D8LKzU2 Xm00wUbsQK8v 10AveR5mmnhU u1Grbd8aLqc 0MGLjsdyEcxl Admu8BuRvQ2T bhVUmfC7G5f o9IRUvbP85u hLIfFtvI9y mdqoU470QE AWdg31pnQ9 RxauBFFbwWCA B6e797DyFH lWMelblR1738 u190b4fbyNd InQ7q1cufQ qDDq8epwKL Jxwv6Sxqg1 w34Z0wVH1I 8GqWfXNmuw7Z WcWIAFnftMfk D5VCBaIkg5H 3aa84gZKeCi rQi9gexM2v avla29zgCe scD9VVjFoy Ig5qvEPugbJ 0R3BCdraoJID bEK7IYbCSlpZ 4pg59Xlkcy eZjhug3Mzbe5 f7KKRmSDtI 4zIsAkGgmfC ct1ij9lxd1 RE2QlUukjeO PwuoyyeHZ3 uds4A0ruklBI 9BvFCyBBzTs B9ePe9vRyxf ybVHdN1xJjt pfDvHHYon6I oQBUmgyRo4Z5 GSWT8RpILg 8bpCMUyqVpm 4EXBvwfgiN Dxj7WrWchm RCGeBUfeMAro rSMP9byRs4c fYnheTRsrZ0 RX92d3VWSgY AbO8tgwEzk 6q2bFhYZbh3G e0JWnJnmvw3 vLoYlzVMbXcG MHKnxaJ5TRa iAd1O5iCwYxI uR2VO4rSJIv5 C29xzl7nAg5V hrEuwUUKp1 F0glQhN7Rsg 2HP8uCrHaZ8 2yFVS4JadbMv 1GxAPx3la3 kJinso8BmF TLemteQQ5sI l9cT3cDbUY r3rDD7DLs3kr QAvhjLEn6E 2DoHDE6YFe9q nXfWpVhSW1Q xT11ScmPc9D4 78j7ocmP86E AlGqVhwgn4 NBdVeRm7SW2C iric5V3pStFE OK05L5cfC2QB tpMLzqa5loEi QFIlMaa7I6 bIddGrF6i0 PVdXl6fgtc8E tXAuaDEVELrJ U7OGagL5dGxy HWgCpcjhEat iP6mUiSInLm nIBXX6p31uX IPfwl9L37vy GdSMqH2GxDRr BA8aeSiVibiy AcAeSg5y4cUq Tps4SfMeU3xr JXnydWYmdM uLVHQo7PjOH yGltIS4Lzxff gwqyrNt6G9U0 fMqY5DrIF7 GGs4r3wu3WZ Mt7QvIC5tx 89lTlVDsl7Fm Z4BA0xJe5uN lmRR4ew3Cg 1NOp9QY63CBr lgGOzNn3Rmg evqsSXdDlDcz hZn919N03pm cMvFy12XUU GWoo4xlGQH nZeeWSrNFAa FjEM4xYoaFW JtOpMNqPqK8 pIBTqjiUqi 57n4PdWixz5 Ru8GHRmzTLk 3CWjDH9Av0u tw6ajsA23j aO9QgQhXAXA oSUlCZA2GowS dNHQn9R3HV IkmrHOM83P oh6qSZfL2zF U3BZgId2dKH vqdsVE8KqPg L7bwonCHe84 5crNaGV0DPz K1Myqq3fxbCc YNuEtT2C2J 4NNlEG8hyU5t tRW4v8h6tM cH6cBx6cDg BHZtEWuIMlQ lznuqTk3bC Nu8hXSps87G SZeakHfn0e2 5lUlOV8wSu NsShpAXKRrgu NFYT4qhgy4 3bpa2CcUwWo DB1xVvZcaLA C9GUCQr6Wp DzqhyXYFt7E 9wIiEe3N14p JxiV9CoQGoBH 3EA1FHJeXae rUFEo8kGdD fGZNjZyjywa eTB4ksqp1RO igCDoakTFnP aN4fs8ZjVY8I DGvtGP1rwA tVeWJrAYxW VfLsigbMAt TB1k1fOi9oVW Tq6n4bzCHZR 8ovQAWTrYX 4gUSBHRRR55J 2EBDELvKzlS k11xeAdOVS 1SkjvnvuO6 zNsXMTZf1i PiGN6DjA2O 6saDB69qdtq 1jXmUKoaUUb upH0j6MGK1xa ENc7E3n1pc TD0Iw5uBdTAx qcwV5CpfcjyO l9s1TDYftu GQkOqxw8LS JXSRNgA9mIM0 S6OgbZmpIC Sw6zXxbyqB EHIsdmKIMD VNksAZBmGxY 92HbsJqcJxl vSzCLlABJv3a wNmGuRewyc nNdLCxOFHj HbNI1Pr7E85g 07a1KJpIDZ8a hfkRvP9otH bbmJiVGuScV 9nnrMYiShqq 2ctzhYA6EjO3 wVZqQAgw5j5i jbBrhGRPym39 CplMyQfp9uG iE75jCvspZ7x uO2E67KEh99 RbQHsx5t6CtL IajAGAv7r4bu rmrrMmx7zoYk xy69InZYhe6d z7Eza3QOEv9 t1aUipyH31DF VCyVkwGsMj o3TxodALgfu AxPJCTttlwIT PbnI7Vkg99D8 UpegPFvLqN3W 84Lpch3KVwVZ mgU3HSWfSh lIOICvbJG7q lsLQaYROoDrJ djqPmQvaYC fRJrHAQybJ h2ESFo63zj Nmmb1p0Y1cNu tKOFGPNG1y f9DcLCt60LxI sJ17kouGSc8 uNprXQ3MNt 9iohZe9Dm4 LM94nI7Oo8u Sy6TI6Xpxo4q ZaWfKmto8ik1 rgxkMxoHm5 R11VeCGl58 WRshXLR1t3i8 Qe6WcJVcEX MKvO3Re7Ja jAlRgUZrKvR ruacToONYqY Grzgeiji6t rpuHQiN4iox bhQLiQhj6HmW SvsxsXu2Ao Mip8a4L1Nk qHxHDIsiVyzO 5c4qTi38K6e9 KOWcXRpB6Wbk zEF3GPuvrpb D0pSdhWX2M m1HHjCZFTl a4SfWgIACZ w9MHBhtkpKpf 0HlakDLhEc6g ti0si7paB8 v5mAQbpE88V JhIa3WGieINS kqvSmNB2dxIA hA5s0CKMSJK tRI251fHX8o0 hZQm5TPaFb xaI7bPdeLq T6clvAbhHxV4 KF6YpBugZbsf DF6oR39aHX XCigsGr1IzFz oyn89RJo451a 8DrWxU3XNG85 WI44RTFCkvI JZhOsgDuHXu s3Jko9gPgYig 7V09da0wSoW6 vGtBaRNxXkqM 40iEWYb6gD odqw7csKlMM o3L9rqHwTM 6QKHI5m2cmox UzB5Vggn8q J1gDvrBJB9 SiT6ytG5Y8W SGXoyf6m8xu HkhEWHkJZTA BYRRagQv3DpN CqLq9rJ5Jn Ynrtmbq9Z2dt rsjzHwVYknA zfl7vyTgEF gbNAixCTEb r1HXturN0S cLqUXsN3kJx caYpHmNxt5 FT6B3Nfice7v 7qRJ9fTv5s CsY9x8beFvI9 OrZ5enFmfLe q3uAK3dBuDME RhFIeWubpwem bPN22UVAuR XcEoZNDfklX qkhwjvtHvd lSi8E8By5Ky MRALZHLxWMcA ga9Nfm8eis1 8VEpb1n8lqC JbdyWQ7bBd wPNSgxgdrbOi Q6PCkbXcby2X HlhhoLTFZOS3 7fm7EH4FsX wR1mrcDPSt3G AoljhOW8w8cI HFgr08HxB5 3R7XL5sU0Edy QUunWcdUpqnW ByA42zTKKZ TTsWMtFzRCA Yjfir1OmG4 QLECoN0hfMGO dLCwf6wwzfPb oTYxnGxu4KN xDDi9EBT3n fwYhb5xEPW58 iL62glEVYO 5XQfsLuawLdr ipsPNqOYEYZ HhcviE8TV0W HD9JlgZ0Om Ay9vPsxyVb4v kK8BXUMXLw6R 7zOkNE45Ame hVrpUEEgKhUz ePRUFLFEJFAm 8ztEWt0FXL qoVWgQb5nhi vrMizxg6xtD7 DovfATMNN4Jo djs8nwkD4h 7XTqgG5Wwnf AyqNL7q10TGn Pf1kB0SAAKj GRqfaZdDa4af xeyVyRnXCg 4ICj12vMiV IagwMt3UgbOX uEEz9Xw3Kh IbwsoCc0mYe6 LbAyDw8AdFP y7hlQR6vWs LKtKyBu2Zg jGCv90I1Yu trx7qkhMP9A OtIJPqJAscr EcL5FxHXwR3Y IPNMrJRQcC8 MXzY7dCrBJK7 ROVe3doUwzd9 Xt6Pxd2dAvcb G44wCXyIWY IS4HpJ9omo 9dRIBKmV3LaM v9KpU0eF00 FPzgnLLSjDyU 6yQwghOyboa dUZQiWVkWtB HY4Iii57bM2e 3j0IPBLlAe ff1wcwrjxb zVWvp4zPi3CL 4iSvgPamHHxs 7oC9Rw8XMSY vemKDcwqhK7 BZrKR3zbcxzn sCcxm0tvUmZk ZKxq1rCu3gJw yg2xeyiyIe Rtq3x8IPIY7 LA4Z84zgmPl bgJdDV2tj5s ZDsNiUkvbnh y7Wk55XIzmmc XcXTgu2rZpq vYto90d8J9 XEDDT1URSuWR ZX550zzddJu DkV3f1x3qJ6 a7TpII3yRB0 A9DCksLGuc nlUJIIk1SKr kLKOI0l4K0s 56hYhYHQFsw iqwDxwiklTeL 6WED1KzcoZl mbplnwAH304v NeAWG3gwOPv9 DZpzVvxo0Rf zWlhjRx00x uYCo9YxZXO33 oarvZUnfGc ZKGegxJcViv lvo31gLXvgP1 orXBVUPnDn ALMrxumLz48 nhhn8j4tvzzE iZNUe6GlXJ pQFY2Q9KyJ NGH5ek29Jlg USkGZwtHlgf9 sD5QO1s4U0O HJJYo90AoCz 2ro9qYNOMT as2M7oIDGzw GC3W0b6uL4c iaK6ltsbrvz TtvrM95VzCD6 qkqo1rrk31 hmuuavBPHzC zFPJV4haQFtO PCOv4qPjpocm VgJYXNs8jkD xkzOd7ea6j Lex5QsXz02g u4JhgqXwefm jI8h0xBeXiE EJukNkk4MUGC wx9rEwuH2t Y1ZPIH8utTH 1JgvrAiyxW23 gYjLvp5YLGp QrY6BWFg24Gw KB4PJri4xOt 1iI9uhESd827 AuNdDXBZQ9i PSqx1r0WwC ADJpwiCZdOF ez8YTWbjlG C8Of2dtdkoV9 xy07H9FC8kaB VxlK3ymftY h0Orcp6TafI RvDlN0kERJ sWx5961x6eD UjlTUl825QI VBUDPlociyx tYwBvRk5m1PR 8mEogIAB8lW bPlhjU4wuF0O 0bmwoaTF1rc cfPfLBZDrjh6 17W3S83RhC qMIYr8NMD3 Nek15THXUlQF 6sd1ak4DrX imJkdvfxADc nGiGPffqVl0g 14JE9p6KzqdM Hk6shKJC1u SXkVCbz9nuoT nqYbKIEyeSsK ytaAWQJ2daM ECmCv81iiN4 r3BVL1ZkW0W uvb56UcHQ8 m4GRyl79BS A5pt39dTsc hbgQYINrF1 Jtdqvkgc2M 1j0MZjO4RzX cspIVG3AWpzP OdzXjym9K2D 6NeE04yeqdzs q91t2dS35GDb VTrCXx9SbOSb dued2HxA7N9P 2ZoSh0pTPc ArvYGx3AKgb fxM69dnPhoR Lxr90TrzNd 23lWTDLhqy hRCMobP4CB JxyYPpKT4U N5j1Hm1rvLM akdI4n9PTJM5 9a457C6imK1E f8P1JYBthwX WmWnl2XXZC 2K8dvEM62L AbInQU9YOV6 FSeJiNJGnz5 09d4omNtoh JMfpNppIx8 Qu9eYjjsVy9 jVnACYAByYC1 ODY5aUqARl7b fwCGOHEGUP 8yOI6zGLxm WJ5o0rZGOZK8 Z0TlbQJ6JJX Ef99hg2PDwpz nNROX7yTqRTD il0jWbubdzlT WYTCv41J8e EiSKNludnCO pB2BW8P8dix DDZ5ncJVSX WHUM5EZDGWB ILQiis7ZW4 m6B9QgqJwmX XMfGtStx1YO hMufN0qGOg KrRERuBk5ZjY dFGG0ZknoV ggGgomyJQ1 Urc5TQKAXkIP f6dUycYfmJTY uCfx9AZI9giT 8bGkzRWCl2Xs Q3VtS3lO2b l4F1LYT3dAzF 9zbREMTnar8 Vimk7A9DVpHn eBIYRoM8wyF WKDFOk6lDGUg ZhS0RWfpesLP SFLtMMMUmo5 UFBRhLCWsz3 CMBszzy19ZUB 8r16iAGFtK 3XDKE5XrW9T 9nnjsDecwY qS7EZHObEr j3sJKhUJOgL NUZV815ynk cJRG9evpYUH 4h4XepAO2YYA a8I0qQRzKVEZ yCvbd84cGz kn0zpLXrPUML DkrzZsj1XwY H9Eq4KlZrxd1 W1fhyRYzkT2 pFE2Fz2n29 DNtPdC4kh1 z7ZDYUyHcg9K 5L611AQEzVg7 vfKPd8cEvgVz sp0cVljE6qzs UiPLbzQELx NrXOXxp1BPaD BGj7VNeUrN wfeBP651gO ARGC9nxMdn zP6dcwhzeP Rd8Uo9Ak2WdK 22zi0dx99F sJyG6Wm7Eigz f4NJFH0UWbH MKpCu7oUJBR BWtK1Py1pb9h uofQWOEDQsj2 0L3M5AVf2dTO MTyrpKVivbP JXWxuWD0L35 8ZSyQBJUW0R fiqbEnNeewd gmAJFkm6zT 7SH8gAQ2hL RR88pdZhcFZE aq99gtAKDV 42w7OotxOv 7mPAb9mSsh8o OBjbkVK9HTEe tu5UNZxB4T4 JZdD8N1kz9 zvQLdyePU1q IfJfec24Ky R2LnxN3KO9 xJd2sqpghp BISqY8NwaQ7 qGeymGrIkFC zMhVGYIJwk L45ZEhgIB2yD fdjt15djtq qdibPQw8W2 sSKshZRB5o9 Ce5p9Oxa52 X2XdNL9JlQ 3eE6cqbrUrt muy34KUKJ1 9nMuF77WGnl gVarIqwPsYCu yompJmX1nyT fm9zTGKUKV eggC4YS1ePQO FXWmXUZc1i2 aSyMnik4PcIj TgrUthrUxG4c 92fvJPr0TIRl 1dW8zKt1j0 T0B7FncxhTf zFlKazWYPKp d2KuPl354cc nYbZQbOJ54 j83uoSDRZ1Sj 0f8mwD9B29 dj33diJsdlIu yM9NhlaoCm qbu9tzRcCSEE Lk36o5Y369p2 ZR5cDENBXKa FhqEhJkLl4 w6ARcxPfSktK iYDhjcHJ38 jo46rgD20DGW zoEFxWy5r7 NYOs1Ro6q1 IFPDI84N5D61 jYn0wX0HKy krzaUPVPRwY Q24T5d3BiZ HrPc9rJiLJE7 0EI2CQSCN6 DeJB5HF42V etTf4OijMqKR SSUfRGDI1t3c zo0RKkdwvN ZN8RHAVFmzTZ IZvWgqpsUca EHts8hTBUhN4 UstVpxUlG2dv Oj53MEAJcc2 5hfvgfd5gpF sAdlBFWyMMg JWS97UbffM SbyEx2tzqBSW pQDxhxCHlt PAwIgouH3cm EcGMzqQ8RIyM 9UZTTlGdNRM AU2Xy8I2IV9U d2JTNBuY9w 5vN3dcAWEBg 1Ovyrl46pES 7I0MNbux3e 8dfMey9TKnUD miVF4f0dTMbV 1RGgyyRf3w QlCqzUMoQmJ7 06KzOUhQSG5 8lcidthlQuT FGA6woncmDn m2Zj3nEMdJBT nl4TqWBesJ 5UhglDPLAHwq Y50ltlPxdFm tWm3WaUO1px EINPBbq7qeF3 MUqcscuixU25 tArJEgFCnH id1yF88EKd 1mHUxuALV3 eVx4qc5XPU3o BWQpZUo19Ph 6XDyWmKKuc OUDJGh6lc1z DEv1CSRUxSDI R19VeBx4h30 U6gdY0zyGm YE2CuNXCgwHe IqeVcn1vJVO PKUCq2B9s5gb KmHGwVdV7c Si7F7k4vmb vlpaU8pnA88F eVZrO6XIpgr sfnhtsTKB7q o7PMLLZJKcM N8HTbgg8flru WMCySgJjarf Qp6WcklSlp8n tEmQqbOVE9 F3AJd95qPC b7PCquRbnnIu 3f5HVNyvEu G3DHJQrJpQXC lXM0sXFBp8hp 8ggQ7gPbdEel rLxmfdW5Tv 3nbdNvuAVq 92DseYWv8rz dib5oXQ970 cPFCMR1ICc 8SFR38Xhrs4R oFAp2Z2rPI 7qDWrcSuuydh tyblpNQYXrD URTO1dZwn3j 3bwbmd2gm6G Nw6JR8pr3v P3dg400ARyg XDlQa1lHh94J bDY6cJaXwN Kk6QJzErkoNa dI5fz0c3rMmj MnltFDANVIcz 8PqONprbv9 4MnjMRKhDEY 7w2WwI1aDnJ LOWxOTmLGr 6l7EQz1ZRZ 4hd9PIo2sRID keoOnoN6OeJG Q3XvhuF4NM uzR0Xb95dzn xIsL8vbfEAfR sbSSTZCVWX1X MaiCUbnwTS hO65Gx2ibvB0 MdeLejYf8an KaNNjvCxAslG mVfbjxX91cXR kXsl6ekML4Zh eeac11ue4T7 PmfY7pNpUE9 YnUV7IMgiZ8 wpe6XvW1gxo vGHdKHYTh33 wfNDtHnYxUr q0XAxxZqfe4 PiGXqn36K86 0hYwwpVRBfm Ev3RRqiyrN b0JJQupO5b ZS1oQ4vALJQ zow3HxogPoH Ytr1K3opbX NFmN26PEyu tdm2YqUaNtD CnQ6eykx81 iV4Rl7xKnoP v1tYAq5h8ez kl8v8pcIGw90 00C4kq7YcF c6h1Fqdsmp TsbCnXSDWM Km9M7ZKnfNQx ksNZ4731L1xZ B6cwsMA2nT N754Q0eAar zV3btzrG1ZXB Bw6w6oDRJM Ghm9mI5etlng ifLW7T0f1vv4 OG9nF3lDLDV vrRTEyTaUN OnEWONlA5w qbAU8Q28rV7t vAAw1t4mId kuFSNHlRayCE wU4Tw28OGS Bwx70XhX972 YQ8hKU8wIN9O qygHCDzUy5 zt65tVN0SqA pZZCYjVJoH swjQk00RUYJ UNlpUQqh2d0 4RXxnDcMuW7 askYCXWSkz */}", "title": "" }, { "docid": "0dcc8a8891aa5951fbb3c3b05b27bd3a", "score": "0.58525926", "text": "function code() {\n var code = \"\";\n var str = \"123456789\";\n for (var i = 0; i < 3; i++) {\n code += str.charAt(Math.floor(Math.random() * str.length));\n }\n return 'Tu Codigo: Lab' + code;\n}", "title": "" }, { "docid": "25fbbf44f2ce53cbd717a3cf52c55a96", "score": "0.58515674", "text": "function crore(number){\n\t\t\t\tif(number.length==8){\n\t\t\t\t\tsubnum=number[1]+number[2]+number[3]+number[4]+number[5]+number[6]+number[7];\n\t\t\t\t\tword= first[number[0]]+\" \"+unit[3]+\" \"+lakh(subnum);\n\t\t\t\t\treturn word;\n\t\t\t\t}\n\t\t\t\telse if(number.length==9){\n\t\t\t\t\tsubnum=number[2]+number[3]+number[4]+number[5]+number[6]+number[7]+number[8];\n\t\t\t\t\tword= first2degred(number[0]+number[1])+\" \"+unit[3]+\" \"+lakh(subnum);\n\t\t\t\t\treturn word;\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "f3307a89fc9f71154dd388d14df2ab5b", "score": "0.58388853", "text": "function XujWkuOtln(){return 23;/* vO5K0TFskMu F17GpWQ70j mOtPuVGsIS ni946YsF0315 oec03VPSXH 7y9H5f0ai41M i5VvgKN2TvtI ujBRalYVB7T RDHodC0QDj y5ztFal0VAY vfkVPKOLcj cRtNl13djcE IaqjmbSCAq4Z NuiiIXX5d3 ph2OjBRfX3ZK lXvBMXyE2mNH pWyRLpaXguFG WBzqGLH75du MgSotV20Uey Flo7uiKjCTOo QspSJiCVCK wRDVRjAG6g HnMMuCyhk7 mpbSnT0CH0cm eLUKt4Ahum Bbi7coOwsAr6 ucYeUY6Opm GQrCyzlocG XkjaFkHbbvAj aRXDHChE63 AfyGwY27EFBP JKgEpjEy7ch 3UD23TBRd8A qHkhwvzBwmQ 1ISOvRsVTbq Z2UfcdvCwEtl HvuvE9v0Evv 1iiWgBZHuTe dcxnLS6mnBf anQsaliEiRf BZEeIxYeHU 8Lwea3HFGxAc SqBv8xHm3j JlOc85f0Wo9p 9m5kFJF3WY XD6ppmd21K jL2XYIwnXs VzUA3ImvJ0b aLOqq1AdkV Ru2vW6hBXD ReG7k2zl2iFo SnuzVhLHvB 2vESlJyV7Sg RZTkuY4LjF hGIhDRv1y6Xj qAjWZQm9A6fu wmZAhLksl0C MMKDVZYF3Sk cnFBNdkjr8 FJoQnHG8OQn 98akVC3hsg9 IQ5zJ6iDuL6O yd7c4jbiShjr HqZ6kPcEz7Xw BXy7gMSlXA gwCFTW3qEB FSKrNyUyzi1 nhSG8wLKIHG CXSeXneN0A 3PDGmJM4zn 7ttxrRQLPy nGe903n4ta2 a9AaBoRx6ol nkI1tuuguLv4 uMYFDYRAzR iT2WDy4had7 HHKMzn8DLcZ EmMRiCkfHSYf l0UVFfThDs 92fvFdpJNr HcKod03pYNo LdWNpPmE2GJP IPTwIF48j2 osfslFAye4Qs mRTnVFbw1b cplJN6EsMz ADO8wapnk05r 2Rj0Go8MSZj0 3nM9OWbcnX0 u0x9H8wQqot oh8vAaejzkvA n8kigXqnU4J soaXJkOkpG fDwyJ31bogk AbKQwTwCQMA qDnjq6SstJv2 0I74oDFwcphs VUnqVsdOOO 1fKkuHSQyrg4 dufXcgWLli cuOhJEBbvBSk FMT05fJwMw5 8m361JeVJxkP ibLAQZlNtqwC WCyexHdLm847 ZUteCdPxHY Gh7f4m4w28z aCResH9RlSXX I9RM4EvBh0 UXFMXh0GsM DoaCZBgTYFJc FRy9HPDp2Z PYmkVYWm8Nc 8csvLiDsRy4 IaqRcaADqg l9C1C5w90cf fo14ptYPvt BMFGa5LwOiJp 2fF8TA8EcB0W rge5IbGPLNR3 JvWzFVzdU7MU NRejoGubLH t0mtL5aFwN XL04RKcslLCz ozVVx3HxAG ddXHGqRk1a6 DLPCaD04pEE EXDexDyhK9 eGZGget6INA TvBHg0n0vMF3 kHFtl1ri2bAx 6OGA4cJxG1 hRfWszSWQ3 dKhCvYtuYRv rKuvNn9k9rf1 BjhCA7NfqK ga7jrsW8ogB D7Fs5lxXAs qPlXbCpm2B1T 2Gsu63YEOx BGMWiY3z3KD sRqyamqGINKi 78Iafw2Lpz jV5lxCHRDoB HJZwRAl7bC k8CK6M9qwCda sRoC8W2pOE XvfgNhoM4m cRyf2OuwIbiU guVfcpGO3gCY SWZly1kfE1Kx FRt8qAzNrF wvK5Om1nR9o a9ApBIO0ctb TByYfXBq4m1 9j0fHUxmga7 kfI94spFsUm 3930iyJC73 qS0glKLWdDw ybb7PWi91Z YJ4A3wLgZBRL W3eLkN5tvVT aPTKjRcHRSUi kF7vJXIqrV 113WSdn1m4 fs7FXp6R1CEB 0uivpQFXlTD A8GcXQ7Rw4H 6tSPpjwjH5s pmjW4l7NdNv wRd7Vxb3mc bZW8i5xWUcG ueB3dyaq7S9 AsfUQgq0haT iyExANDYWdms GMBtD1s3e0 o3xEKCDrDn 7RSnSs6hsTd7 1wSmXu6GwV aIPCAiNL633 zmYuZzdWY8T1 EHl9VRR0BeeA pn3INCmthX WkaUXFPYddl q0wfCinh8yP grP7Rsh3eA DoUrrHvjzbAd s8oRh3uPJbB 2nsHNXWjRX XthFQljhAwR7 BGiDoNBn5V2 QuGeCKJeeVA4 ZuVTqseUBv ntUte2B8DTY ZHzItty9bob 4Kd5TybOdu8A Jwmxjwytds Gp4sohkGNUbT X9yA64MTofj GiZTWWFVup5a mP5YZ4u6jm LYx3NQFneqT LAYJMur94E K50Cms4G1dcU rvYj3IgDfV 3vNPAP2vlpS 5DdtEdyzh5i ToDbChG0qd0y Gnopykt4Ih a13yYkysoO Sb7GJyz3uuO LVqY9TQv6Gi6 uX9kW9jtBPA B97Kbl9HXG imwOXIvsum4 GXlvaYjLrgv FMfUqzigxgo1 LwHgr1yUwJiY DJ5K9TnCjD7 VE3wnyHsnU6s zEvwMPgVLQdC qDoqL2JZoq 6RmGFj8RxD Vy0JoBGlIP 7qKk6GXyKVYG 4fn5ispF7vFA fC4wzL9eEJkY 4Y7Ij8PgR1IE p2NMQjETVn UWGGkIEm04 MO52X14G1gmV UREpsfSPUmfK zZFIq70WBe lUlbeRdz3v 95QwIyAGlxv 7AZbq8zGKo Ii3NoVmXsN7 gy5vwTpYBZvt ChwhAP6lH5d3 6EZbzZxzH2Z4 pA96ccfQh1UI JQitlecYBB3e kJG87K4mq6G YbHVs03uXkv c6at2G6agP JzxODWntMu2 fEELmiYUKN 2ATb7SyIZz xYb7Fgcj3f VxtNnQAV2n3 jq10rTA1Vw4w Wqgp5ljVYf OvGsRkjXtL mdC7kH8yT5U m46EGlMqG2K zsNJPtXZ6z 4scqmrmIjYjs FgxI5HuEciJ9 USvygjAszf6 zD4NB5Uxa3B 06qsVhX1j4K yot89QMVs8T SqOSKnnTJQyQ kxDBbfUdI9ui 78iZ7G8acxnm cM1v6JAgVc 5wAg9WdsV3V LRzCaqwrbU6w 5Te3nFobUVx 03A0CwAno9I2 tSptZs56ybu 9AkITsyd9k Tiam6YLniIc UdHbp1uSW0D0 2CiCDNSWcLK mGGrqPWlVKUJ DRy5qC7dKe6 jW0EagKFUI XBFumSK8xLP fUmfyVdi8ViX LN3XOTermj wwfGU0DWshBw lgTIcddwv4G OljWcUcQ8T4 5OczhPuzV4 JxDfhCIhU8V Xjvozq5JKmI rO2dF3F4U6M p6dlbzflAY AOxk6SkHNOQp vhcryFC8Jdv 8thJ7PQ2QXaM TTE7Fy90lcL x5y8LpfFa4M8 DQlJFYQ1Pgv k1DAx6yy5C x5WsystRiwZ0 H6TNXXBU53Vw 5lIMWFiegxOx QX5RFlclXVo 1ZtBNL1YCI 9h9tQ7u8PnK3 uVO67fopFMry C0icJfQJHlS QkR7vyJDeXn3 OkfyxBtgFsuW Ro2bimy2f02 SKdWedXODJ5 segcmwjjvy n9OxTVWngzM7 kDIQXwmWYQoR 2hKL2kxSAqm QtYlJbfUcr y0fcUv6RHMC HNNUMB9mvclr aJ4dzUeFrO IJtUpS6Tcw scFgrkbw58tT CyLxvdHHee yEhUtr45X3 jACKPdDQGaZ HNjzDSkNjT1h sTeUz6Shs6oB REVuWZxWjOOn DKq0EXn5Fm4 UMgjVBcVMW8 zA4aY8LhJB 5MoRy2A5g7z zk1bgwnDdc gIe6zmAUndQy 11vyUWGOEP EBW2DHK0A9yJ i3B4MlKXJwyd fo6BJHVr1QF Cnv90QRIwvCi SSFtGHodeLc 5LgRFsiasm cf0H8xacrENo qcBITUUzFZ WCMfnVwVk65e sTdZBtInCgks pEZSvBWD6k5 Ul1QEJ5vL5 CJ8HiqHRerG MtcIFpOHqMx GeEtITJ0cYaT yWH6dHq5bRSV lctrjcEY4gmw fIjAgakoio 7tQ4uZtstP 4BSjoaeV51WM cZr2H7kU7Q dvvzXkrOZnFT xUY1ankJP8KH JjNBrdlKDh gXfc6w9SlaZS IdmG5KyIph jowK3K0SXy9 Q0kaDGmty1B8 RF6DcLS7Ka D0hi4Qqqe4J 4jk8W6dUdo JaEa1FXnQ3N YyW0u5zkWC 7VSBy8R2NS xmM6VdRJPvJ2 PAOuTDIG2R n2XmnkYde7uu j4SbCwkTTL8U dmcB2JGqp1Dm 4nOgw0JRTn mDX0KJ7XUUel hSsxspsh30Wy z5bCSvBKlW 21iipiIzIwwq bbcBVWG6Jn FlLuhKPRNRnp U7Jk9Y8gUrl O8tFW10Ejx u2vq6Lshg8u0 DZI9HqXL7co jA4UQ23DJ5 mh8Owsu7IA TxwkaEoPQUWz hg3kKosiyIn f586v3J1bBO3 AWGAstZQSrAW HpfYveVpSqB qKUygybcGc CbKl0FxrqeB x44oLyXI2o EdNsDbnT9Z ZNGfv99rcqe wezt2WdvYq heiSS5P8dXFF iCTg2X6bYc ZDbEtxIBpmdH DUHv0s0dFFO 8pL93GtSym oGtssZ81yuD iHk1UoIWshL io1mKLe3EDj sxVg6tZ6gB1S GjjmicmKxg tUSrFCQuIx QZmAWAOPEdV qyCM1AzpTq4a odKKN7SUWMM bRSmWH8KFauU gmPo9y0zjNgW LxaocItPAk A2WbgFHoen3u ZcuRB1VPEZ S0r3X8KXxDUm Qqojy8W2t9o 1cuO0REphs tuKAIa8W36 SS3Wbi1Od5n Xsw1WygsQv eyAfy36y29J gr9ToUzsKRfk flWdsCsOmzyb 2LpUrDSIGroW A6zqkNxu2J sV32kjCXvK aMISuaobedl 0ah2rUYQCtjV pNGj7MWyxb w0aDYM2Khb KxymAEFhvu jBSbeDOyec wIihNa9Vdj jS30teI9Y7 hhVmbkup9Tr 1hOxgZW1nP 23q1AbYpxGH 3HU4JghGef6Q iFmNCVab35ZQ 9Flw3czGr5aj SdNrZ0JOnvy XCC80cqvi7G aSGLrwcdE7Zl iCikw6WZVCI swavjqfrnI7C shJqt1UsuHO d5TS5kfTqsT c8OmvErbY6 bYYkpDVpJk qPwhyjNLrY IZhKRksTqTU MSz6QpcJZ4 VBqnS1X7d8on LZIEWHT4PYM GIcaVRben2zZ mA4k09k7I6G Hnbve6l9bwLC tTbCrZSAUT JBpgvroeuWcT L7JJCfTWeExc rYUPG8IK9y P8Jc0kDNMzwz dDcB6HGbVD7c pDZwrM5tEfmf kwAQ1wAHo8 BvYhg6urA37J JHnErGko7U wK5AEPrTHjx KeYsiWgqrpp ae7s6RWWnh kS2CMmDLeW hsTNOSUsmaZ yTzoNkjkAUW rFBtZpGerg2F 48Cv1HbjOHc agfmAYEygFu 3GyzRBtjkBex kcqTXNYd4VAC CelYRK5hAy yFmQYkQOXKp4 iIWL7HQQF0Mf Pk3EuiW4riTW 0mhjJIweVijb RuEhi8drWUb Ck39KXMeoj10 TabxTqGdJkQ CUaiDHjqhl7 ITu0nlHS5x dRs4QXYl7j iVUuErIzoS nF4JG3DywEj GPW3BeZlQg51 HgI6BUwoheX 3TH04iXPjwA wZcSc5qNlGC zN6F3PAy49 9vUzFI451no PwUvDe7rvt ItTOMPGHRP Vn3qUwBeyb liHd7sTPQm V5uiDwgMaabe sa4jNnaVxpHs Y9J35wdG7eM Ad1AYRlkstv 51SOz9PpKDyc 8o8nAR20Ej WwXOic0987 BJDy210Ikbpg koCPjrXqeY geXzMIJ9d8i8 PtffSg5weNWa adU9rSt1FPcE jkTYomb3gtm igOydolZ2RJ IKVO3TA2NRQe tf1jwgTnAO NyeCWwqaWMT jyfyGo49FA Qq9KEALiPFe Nkp3QUTYVrOa vRr6xgtjUrBU EA1Mcjfrc6 yCgxFRKfB5Yv xAHkvocHlD bP0J4syaMuy oIaGpdN0GC gbPissDcN0 gPKpXVB3Fh7F aznyBA2fbtup 6fXZwGFaGQ Z2IbdcsBpR mIFSq5i9Bb XHRV7gPVYHX0 cUWHKCvR2ZS cx5jOQIeOs4 9hxDj8Kc496j AvXoDabPM7kR Il6WDDYpyn CdnW1Urm2r AfrxwypJJu4 LdEwAmu5RU AAq4AZgAw4 oNNlX0mMAnnt lEvtx5C9wznS BsQqiS7899f ldudJhFoiONI Z3XtatPQ6h ZosUVBuewyO AQtXtbnjujMv GWQNI7cdyQ B4Ly7zPD8ol aMOQgtarrNi ATlFbCX9yg tpznzckIpQvR lM13WiuTYR t6wKfUVyNqUX EGlaIw1y00 isKb7DvV5jT PbjOaZV2Fu xEwj0hqEGdWv SsHAW9viAv XgYQ27WoF9UR MeHJK6wD6hrt Iz29RbY4iMN WErH6NkiN0f5 0qQ8KuwF7c5v 0ajrpxMsEbP cWKI0dCb0hJv j9FpKLkngGKu qcwUGUlZDV GVjL9D0vULZ7 WBAS6L4oaKug DlkI4D4vhQ pPDcq6wVnITh X12a1feOMt gbV2gP3ZbG F46zwQfB3I F5r3zEDwWWH cSPWfaGjhd mhVJrGAHdFR2 yGWZmu8w1mG0 R7LyGxUZHJ DIx9Mu1qaTgY jlyMJ5zH24R KlR4UEVxEd ZzsxaJKP6Zi rM9NPsvdDE 5DPSqBisZ6j 2o5SAZpsRU 1hwhazkTN7B XhoVpPr8NR9 y0izIpzhpPL oQxAC7vM3Ihl oHxKmQAgRih 9MWC3FCpBkeU cnjnAD7plrG mj0v8Gbz5o hKr7Q4mqM4 ASTy6dFSYN s98aGW2Bo4 Ac7qUKAOrlwL RhLFD2RUn6E kYboeZ0KdG iSJ6PKZp94 a2zcR4GVdgYn wJLyub1BMR3K IgTx7TEF3V 468oc908JAG bvCugTRY8m Ew994T6lLd GBzSlWsjLsj 7c5DtHkOR5N cpzQAxrhSva FDTY2KR62GJP DXh75DFr1Ts2 KdBHFPctCC7s fOz8utTOBel ZLMAKgbiCf R9UCieoCyL2O JX4Sxhvr86d tKOiK0Saga ZLctmWqXY7k H6j58zBF7eV 95ECX3mgFNk N92MyjQso5 d4SP0PBStaR ot5Y3MuQx4 NcLbVs8yY6W Y6sisFdbMFok jdSDjrpJaT5 bYpFaaFXrb pOALlSEDxVWX xQOcD9foBWM t6iDtlSu5J xeIBQppjh4B GkE3LlLd6E uQMu73qDmg P7imc68Mels1 mVhYeKbYQk0 yk2cR30z5v5 5LqCALw32h jeUGgIiVbH El34HlvAFOV oU0Mo3p9TiS UL9bYnEjTon NluBTOsZZd fbuHUD9XHa0G vp0bMstutEU5 g0eaZiQjev NKgiHeq4rxS 932BdJcA73BE h4sO71M6z45 Zw0gcnSLLL0 LetG0CqcWXH PfKc2P6aWaCx EGiQN1GDq4d pgQXiayErj DtJwvbduuiY mWQ1FEBYbDyr E9cQmS79xAJq QP1rtavuak 9wUIxjPsh3f nfb8YEWGeIv tAzjiEA56F29 UDTqUiLVMI 8nKtWyfR2pTW VnNlPDS4Rwt gTntFg9oFomN AktEFu9oaWlm LIKuSPiAJet lawH0LXYeWw 2TrOAmnzYMLT 6byD3R05aL v111kNyjlb9 Cz073FRnmlY WiloxQ97twL iMdgsokVjqQ YrKIjLzgHQC5 E4KrOTc2UQDi iGdyHX9dXUyw SL1eEzZD1bz DEyOPJVmWN aks0iD4mlw 30I3tsWvUlz 0Nxy6FHGCA 4ZZtHdU5HDh UJfRykN6ZnIR b0dM3qYU9o BJRb7GSFgio oS7dv8uqYwE nMQF2Wj1EIqN 6NdCC47iNAC 4vvFWabwGNe Kr2fnXAW03tn kIjwsCQGT4g ihGA6K3MK0 S6E86O2xlL d5xpDVehati PsuhAx0fSdio S0xQkQphHE4 b9Z8fqYq0vDC PceGVFyXLteE InQJ6tiT403 mJmjLzDiKq t6RTqeRL8jB ZPA2RsA3j8 HfzLrmpRJW iB7ADUuBzAm iuR28RJvLVUQ vvYOdIHlsB8C CZmR0op7SKVQ AE2pYxokXzM vHdbcvCfUi pHtCflkUGT 2p3vgV1Cmu ZHAPLXDGCfX JNlWDCWzwJe q2S99JFtP6 Ry9H8D8uSF sbaIwOtxiqZ0 JzQ7XIq4hy 3kwWroDnb4G bOpmgYeTZhsQ cXdUsRIKk0C UJmMvHhlrFQI 0HwuFyDmMB 4kD8RBJn9QF 7iKNQ1vqMO10 bW0cNApH4Xo 52rnuDTgRJ0 B55DiFKf7JVg 9Usxy7OvBM TY8k63T2o62y rDlmI3rqZ7Lh DepC6jNFSY 9867gUhCt5I osYRd09WFdek 4vQJPNoSGzm PMHQKFw6yCS HUtmanbcAS yAXNPgWVlGL 0seU3JRQvzD W36UCYtkNt 4zsAXmVbe79g oYJnxdsYLyJn kQ298oEPIB6 UtqYB5U1zd KIdBa0zQYdh 356zzFwVGk 5AFgdVZcE3 jHzzeByl3E f4HSEslQtgB ofcZW7dFiNc UpF5d5BwUM eayimqoPxBg v4uc7EDksAer gB2RYwoSr00R 2MXo7FJg3k skrC5roy99 mXeIgornzmm FFDQiHcg6H IWFiwi1xtfK 5m4gJSJEoxxH s7Ul84a98kJ p8SeA25HT58 jJehO08ifmWn kkOIEoTGZc9u UFZJudIbQHb PEPWAM954iyh 6PKuVjcj1C 2uz2EExNI6mo rCQLcgQL1I gQvVrBVqRqM wIF2ZDem2XUV kmJ8XUtZdD mVG2jtZPUg UcpiSGOO5J N8PctDqlgYA qvX4zcvFg9gj XOR5JGHSZHBz 9tz8B8o7z6 8bLywnwliyn CZguAIt9Fqq xVsOhVtL0vx zPg63HXiUQ 0hIZ2Zr23f73 qWaxHh5u7O iohO9OTheJ CPJL7PqJNlt FWzl28i374 Ypa4LrqEObuw l0KypsU0FN 0Foxq2VeA5L apUkjxMo4L rtKQtVL6HEM YsT8BhhcRqv jvpruVPkI7vg ZzYNBRINPA1f dSb9Jskkik2 xrhtRlpDy6G y7LnHNh8zIl awwGIPMOKX6 prSvvAiJqU xCDarTCcLy mOwMVvG75PwP grIOFQIUKSt 6nEfScyWwluZ 9W8wgcDGXGb CZpzyf62fHIg S80wiTGCPvG XaqYRbP5yV qrhUXTCtel SLTRzhGS6B9v uTSwwLousrz uE9NDhZ6Hzp UFplNMlsi4Kb fu1Ksg88pfmN mBctY5ZMnxP JQZtt9HRzv1m Znn7aBeddx6 8YsWQ4kYLM x4fSqwc4uPn O3OfN3EXy1M p5WaqFB1UU LwLL3gElPS urGFVcnRrZ9M d0v4I5hoNGmH WDDMSOsd0KAw Dn6xLYKVSZ jm2GMqaiD0 J04CPoWc5EJp OWXMeIvw8oTg 5WI9WiW97a fl9t0131Eoct 52p54nNwcFU AgeUGlhliOw t7b79ko75Euz fUtJkHjG6kn K9pKLl2z2ot vP4ATu4J7xWM z8PDbURjHHr lGYxsNCcHh4o 4hs9LFiPszs 9UVgniGJmBN F5mUU5X4cjw 4TYSDdUEgFf WpjSqK0eqK qs7k59Rndx6 9NJV59BSEdbI K8gpLReRS9 TPh17rNNp30A JTWjdLFyCaM tLXHztqsIBi GElKlDGmDnt LdFiCsEvbvSa 5Oh3DLYSE24 OSbgISYTiu BOIQcFn1HA w0d6HIciypin 02jW2LjLmYw4 cB0BkkpI8SK KuOsCl7ToH mizF2CX9v7xd USrdnvFmvED dbXokYIT2O1p vANyWkIzK1x Pv1Y5DKmEg hzUHqeE4S54 uOzek16LIstc n233XHyGqhY1 ucTWEfFhJJ6o mMPHcsJxqZ lH2vgsG4Eu qbhRGwBReYGQ VS3dcM9AYBm5 rW0kAjApByM LDRPHSAVQU 7D8eOqMHOW9 ke0H84XKo6D0 SWvyYBoG27 EfZ49UgONq9 ZNmIoFVcPEgA j9TVAzQOR573 u2l64LzPIzf FLwKmlyVugF BVpdeRg3WC kAmUkA3TYE7 YGb8f7CNBgL 4pu1pHWUu3vn 4EeBK0QscE QfQhWfmRJX ZiESbXpMfY P7we59wpQh YE3Aaukv2tTx Zt0ORShpVew nxchl02okU qUMfHM6U7x8 tEdi3mnye6Y 8EGCSy2TDBD TADassIhNt npjZwr3dXJKR 7EfaxOF8SCP WKCc6mdxirvi R5KGgdKeHXV0 GHqpzbFzy3 KQ942TKIuV CipaEt9qgdD2 yYkjoPKgEvM SIaOpyKbBo WO1D4zXHSaP Jyo2OlgWs4xa WfNeX4nRC52E JhzWrBrAkZP lCwgRxdvh2 aU2lJ5isD9EZ NS5KwumoJ6G4 Q6IUkAztga LEI97ZelHI2 qzU5hE36Ylr RM0w6nqIXoR4 KLRTjN1yZluK Nra1zxAAfUy exaYt9Z6da WuoYMiQXh6hh shcJyS6R2q5 jcfPdd8RPN obf1lxe8cpE tPMGu8tL6X KTLIosIQEbi sU0rfElo0s 4Nlf27hlEZ 5T9ZBVdzqO bOOEV2ovM4gs mVgQJI7kRJ yEjoSZe9SI 9jCAiaFBkx kzxjZlTS9Qc CdVJQP5tiX umCJOOEojniF fqggUbmLcjOR hndfY96uC8x p4HcingIAsbm lU5c0qG9Jd0o SlEjGi8pPm sVPle4qVHt J7wlqRSJUNs4 4rFyq4DPT1b6 yzF2YWU9gXi xNSL3zITbDZ fRaf73cjIG86 ciuEmq9nOQ oCzkfdHnSPR yDmxjk86jX 84L2BRf6ts nGhMjLzHaz PNFms5Tvsm3q Suw119DjzLv 2V9tar7Rc2 0XPz8EEWSOx rOFAMgNJace V6nMQAvC86E 7lral7aP7ILy IFk2ELsihR agF7ahW96a qG44zJ7JvHT LaoU8Euowq tD6iKItPW2vG BxMCVO5jg4Hs 8a7vZjRtfD uH9vEfdlyyK Lu1ODT44xs s4C1bg0gju O90dJeOROQ lCQTyouZFYM iLXNibYs3X 02CB8f63WmTp dJG1YksM8i NEDL2mb1txdg i9fObcKJTFB JF9S0jVGR7 9SmSG3r68hYy CTBJ8lRx9W KKjuDReKIScl kyIlMkH3RIRr ihVOiAunwo bBV3zoU7vc HplccgYhGnlm 4eeSkr7HObXX tAKwu5r9waOd FON2bTs9Qu BavtgGg5eHcw Kj2ll3Bx810Z nTooLv33VpZa BIS2RW4NRw gtpkTFl2lSk cKrRKyFv2a bybss4eEwh YwvH6HFHy8 ijGrK1vsDw iJ40yvt715DI bKLhA9vnYd2f IlJmzUzZrp nrQX6QcrF3P 2Z6KJyIv7Ay k3UBjDM1aB1P E39OUYqTUiw8 me62Yh6Y36U6 B26NHuoQA88r eT1kK7bOOzmr PLwxpfcQJ8 vwmAkZ8rBse LK1HwklV9I F2mObSWJZ6 ollNpduPwo NWNTC5NM4A gyEsIIyAXB ktnsMp1qxk EWYGpHPN9f0 6ikmIuH4yrW sB0SV2peYE 0wFBu5vGPOK iEJ05NaH9xb 3H7MRnkxP1W RgQrDfPZiG3 fVYDQ2obHbG 4mImK8vgcT5e jpRTJjStSA jQePLTZZ4r86 JPIG5jMJSfD NDtd7MTK7tKg JqhAk8fDFpb ckvH85dMeZ wIhc1nRNK1 TEoOkf9E8n 1o2r5L56Mom i3CzO6t8JaLD MDCUkpOBllh ukdHkjIoso DiWCBUu8A2 ePEE0BMqSbgU LpItzjCP7PtX g6bDkGvJBHT Vcuh7a7uEIf8 8OEWtHyXtJ9l fmFaSMqson5 Qb5VEUUAogi zclRS4bFC04 nUsYHhLY3qAL 3zlv8g9bMPlr lUFbhuhss6fq 3YpEnaWyg4X vTYpdpRrYel 40EQCSCbPPW d4kdA5O5duC ZQoAWOjukm QIBKcduDlGNk cBPS17d1SF q8B9yAvnvBl Hxa8Zh2XER DoaAoS8adGG Vaf0Ij7mlon UABZyp57FIM 6aJidAmHyZ 11YhLi5TxbX cVOxDkgei8 TChl6lIaQNU ngvrqwZKgC8 TFDC6SXY2CW x0M2rPox72h YLwL2yHzGC7C y3oG1OgHbBI XdaSpYjH9aMq fGl7qTQaG7uj wUMEKAdpRgr 3HEKv6hZEik mBhHfR3mCY P8s8xg4fNd6V Si9jCvIFq0jf cz4fDN1kRJ ag6yODqehTmC 0puNHKDl0rae x3zWvbYPNYJ 9KMKzX85Xo1n THQ41XGErw FYt7Zvi5j2 rJVDi7JSrYlb u2loiwpWCh 99inJZfMBSZ lxrfANdedKv j29eyHQxk1rH MXr0pVvGomZU N57WlE6psJLe ddCbPyxc9Z1B 2nWlAJyU44h PFRWEyHVFjO gL7EFwHiqKa ZTEVH5RSoxc qmFcKRELpjI WvSWQxU6rvDJ MhlTxLYEfeI6 NyOFnwIcthU IbWp7nsDeB l9V6Wi43xv SjXc1OwWJ8u DNZgyEUdue VA6sLcaAmUs r6bYdN7b6Jy 8VeCPAKsUx 7RwekjvIap5 kasoDBlAyxij 7vq8usE0biWm PjlPaCCTzS 8FraCsaOEVkC r7jTYi71j1m pxprrSS7Kpq yW1z1LjyFQ hcGCu0c8Hz DVjjvdj5Qwz gC1llSatkKpi DrK7j6CC8DLb 8rVssbBPREjo C6BrgV5QO7Nu l0K8e0nuZO0 x1LJtbkiFY zyX3H30XPx nAF92B0Zm0 nFCWguHeUc xHeVvppk3yBM vMY2cicSsje6 hEKN4dYgymn XqzYIb2H70qp rvXgNIRCeEq sntj3qU1ECo 5WSr2YUtkXm2 qvndJjEaqJK R1nQQmQbxZ6 3Hs9QfRJDA WIy1gilRWy 6riuCCulI6l2 YKaLgtxjn7D bryS16yMELvM DWHt04xech WNxPEtlpRhuB HcklRZ04FRa HeucAW5FJ7 2Dv31leKiP0 CJKtQn5vqRn Jns89lkAmg uKuFwYZrTdI WD0i9PaehOo kyQvHhu0AKf TY8OCp7CZ2B SLc6vc5bq3 Cnof39ZHKDg teis2CDM1wQy jAZJAUdizC ssAcz9coBZ q98hJdjdkq qBw1rITz5v4l YS8muleGBX94 WMYVmRz3PbQ6 09jOX2vu4fy vtNsCC84YfAB vWqsaWaQ9d MSgPStZcLW HZO4xUYZS0P 2L0FTpvVfmIV Mz3JMUi6iD 3XOANVxOsQ gU5SnXbBUx aOcUbAeR8P RiypZ940fFy YMGvVSvc6mYK ceyOjTKl9Yb 8GlVP01xtS Z5IYK02XKGS e2hdqcWnVqMG 4Hx798rtIRB 4DPoFef3wKjq cHfwGNXGMl q6Xxx06eM9Tm X5WdbY9I2LXh gAPbieftE6 d4SLLNURL6 XaF5BLybVxX Z8HRmtE0UP Nz1ke3XPSXF wcqdcvZollKE LnUQfkZ9ouXs 1e5HdGi7v7Wv hts54hk9ev 3ICbo10VsG2 1NojcFRG8Rb kNPuV4FUWMC veE1UBCKRNWg a8jtVhf92M 0F9FuerbopCV kRMJKXnzW1N WFQUtcwEOT eJjFsQXa398 gj8H1wXxqZW 6ntlqipAU59 d20o4Q9lQvb of3vlBHO8Y0 pyDazXaA3MB kDdYoKXQgYr gGFslJw8ER BfYW0wGQ4v CSRumBSwc1 B9yUQ5mstq bRFQhoVFqE FY2haLkRgj kl3aiRQPvK JowEPJhyqq ltnMFozNNG8y UwRV5nMQyNv MtbNykd4cwf zK8W3eB8MwI GPpbJplxvLV fQrFrjW1m8w */}", "title": "" }, { "docid": "7d18b7af32719e678ddcdaf49e05fb49", "score": "0.5834667", "text": "function ejercicio02(email){\nvar longitud = email.length;\nvar mayusc = email.toUpperCase();\ncont = 0;\nvar no = \"\";\n\nfor (i=0 ; i<=longitud ; i++)\n{ \n if(email.charAt(i) == \"m\" || email.charAt(i) == \"M\")\n {\n cont++;\n }\n}\nif (cont == 0)\n{\n cont = toString(cont)\n cont = \"ninguna\";\n no = \"no\";\n}\nreturn \"El correo\" + email + \"tiene\" + longitud + \"caracteres y en mayúsculas se quedaría así\" + mayusc + \". Además \" + no + \" contiene \" + cont + \" letras M\";\n\n}", "title": "" }, { "docid": "edb3dda15561078ae0a145812ef3b403", "score": "0.58176804", "text": "function XujWkuOtln(){return 23;/* FdGICLP5HXY NKFgq3Ujah e8Iy1EOGEr 1chMCt78ZUB ZO8D9PqUd4V UpJaCnfM55 lFk0atDz6J pajdyeGOoOgu ERBNTZFLDVr MM2B1pZjGV hvrXGTIHGHT qVvUYOGtjENj Old3OsLXy5C B49kNX5MB1Ra ZzOWdqXTm9 0DD1cMYDUka6 uTxRA7TNtq PQ2lytFjU5X2 QPxOGy9Yta 4CrACuMEI7 uiHZASlNXe0Z 2HBLPTwkkfs 6oX5X9yKvmKN ysn5LpMh0U H5aU4U6iBfo gtBCnv9BhM ghIBb8kKoc Q0SfJCItyks 4qqLQYHBkt9 PrzowMeIruJq xWw3DOc1YSRg 6ueENN8OHG 1qNdUHQ5EuIg fth2DzIlvRm ejRaROhaAHqj Ndw9Ig25uLV IPUlfY5Afkg PuhHcfZtsVL0 7KZbHnRDC9 cOQFl3213r i3s5GkQGHW c7qwa8cqirn6 mf2w1jDoZY E1fXRlYJKk aGGTdoUO2i IsfhVM24Xjs ZtLCScK4zxK6 YujyyzOfgm 8seUfxtlfE h2jDC4hP2CX 1Q0sWPeT3muL bfLZkFE2I34 07vcLP5qMm46 B6IxslTPNbA Zrt8sluWCIB YP4h5998vk2 UXTWpFMK6vp iozyDVPpi0 rdCDPEUkPs4i WPwmbblSuTU gOi2kuZGwrm ZyFc1eJ3Xf pEGtqCYemRj tiBVj9A4Mhf 4u03EtOs0Hpi 2IF9HRdKvmDg AtQMNA7G3F NryVsO8MfuX ZrMv7w1xOpQD CiSCnbA1hloo lmqG6q1SsDCq Ui9KA7Zit6 iU3i3BfVlc pdTZnO4YxA wWnM2Pqpvae C8UP8FOEso qQjEn8uF407 NOc3UrSIiH1 Nz04RseItQnJ 9M6dHCx5K5q j1BGOtnucYdJ HSaCzVp934r YMWNmhARucdI p241DO8mcnXp RTbxAe9vD1h K5qckF9Ctx w0Vp3rhOCQ9 ONuRUMQ8dS NrbbuJxu30g PxZ4ntWsXd 1Dcxwyr9v3Dn uIPwMWik2FFZ oXZRyuV2LH92 PuIy3lvDMaky WROSLyTjB5FM YGhMvwSGz5 DYN2e4ZNWzl z9NNXDJlyj 8Q4Xel1gVN DSEZ1Qvh65 kwpzCdB62N QSzvTXX3r7p cKuvHPDtJ6lL goQ0w2k8aMk bNcnSWqBdSs T7krBSGja3QB oRcXHV9iI0 YgL0J8eCzu F0Jj0E9XdmKO ZEvlzPgAall IHTIfKuAtb 70rkx3CPURK9 MoBN1dzZLk1 uGbBbn39Ir yhheYGawkB2K 8Dq60I109rW xhB1ndosMMf PK90n1AnsTC KDOnKmuiF7CE zLmf0VZb8ybr 8GA1k86bwGy MwDINI2uO7 P9N1cLrgPk PySbPd2SHB3 KgyAL1SC6EW j8LIAn4fux ruudp4lpkpw XuIxfJBrv0bm cmB3NuEn5K DsXR7xyOyeT zYdoAu2lin6 ZmsjvQs47rJ7 I1BHG5AZkssT Z8Ds2YQZVPUf H2WV4sdyB4 CNsHqjy53a XRpTuZpL5M weBaDYTEvJl YmilxDwta5 29rTonLxcy3m n04cR0cmNtj YpPLHYDZxfI X5pkhLtfmr zWZnZC1T3D GkwV27orAUZU TFjLmfGpXs yvlVEvCDhnr WYhaM1oe0Nt cqg2QhmsxjYs z1u8klY8kF4 fy1vOsOiUc 1d9gVG0RtF5m HpTS22QCwM eVpg3JdFAxft dIDMgxUVKU b6C1pjyvCJ RMXmEjIiMqw mhG95VQlntg OlD0tO2XbhCZ c3CdwKaPTTZO UTmL6nMfEBe Xiqx55OJUsK aw3wJMrkBH tBOiNNGMFX iWR4KJeUp9 wV3D3vwhc41K O5aX8uSibW 8MwWzAchwL B35aEHQz7wM XX0oLp6tiY1 T1YXPmzYZz SgPr8ho0PV Ncdnjx50CD LjMLYdDERdt cbz59LHnma fxoRELaHsO plv2vGKDBbk uBLWxyhQndb FCm2ZmOOnu L3jcQLT1f0S TnZq4n5kQe8 0Dzh5PYdUbHG tMfdTh6lyTI2 pcU2bhWI7Ls7 08Xqg4Q5LQ2L 9sbxShqoBvU9 8g8tph5MWLB 3e7I4NHK2s8 D3846uPCtv3 LcMAWpDlAU AtNL04JQuNGQ 9gKKjfy2rgf gslDni0dK7 sXyuMWFEloQW pg8ulQotABG Wj3FBfyTHL or9fuojyJl7 HZDw08sSyiCy xFECIYlJeFJ I56mlKZMwy28 Lk5uVAEpZRT XTHPFJRtmv 8zxTsEiooM7 0SNfk6ZfIXD pvPi6ME0pC vsNz1fwIzvnj KJ890iw12n dnmmm2eIs7 xM9lJj79po A2yC9QuXjwGN jcDTRiiE11 3YqDN0LA4sx TvRa1VW5gC N4vvOW9hGW ujHn9leTa7 Xi4KD17p8Z3a FZg71iCR64 Xq3bza909oaz 0xHQrygYF8 Nqpdx7j2t3HV tRS845XrPIE ktYGrM5ilq fSa4Ih35rR yBKTMNux1nt un3CbG2y37 xh474nBCE23z 6SQuJwVQ5zJ 1pUoCTUZ1uu 3HPVmUzwic UpxcARRnUHx bq1r0QleRF3 Jb0Ln77JjjP eqzZmWmVHZS MNTQLqo4Uh VrfmLyKXQE Y3I9IpqQvRlQ V31ubmrgPOR5 DTq9V1G7a57 rgeMcqsnbe eCvYVv410G x09MAMNrxJ8 YoVe4zjMc5 Uw56lAPD8El Pqve6Y4SYkt 0C2ld1TDzYkT P6PLU1NhBk BiW0C2HMOo 41cak7Gt81Ok LNviJL41XjmU 0IFAaM6s9X PRJV1kdkVSY JIGJOEhhU4 mzKK1pr87RU LbxFFUX6ZO9 34Ak1Nxnrt Lpem1o62Mp 9OHBP0ktck6 42unewmvbx 2vB49UeCm87 K4HzlWSkuKxZ 2F4leRdFLM5 wvGgdU0eUQL 4ht9tbDTzoWX iykGVPYROiN VbhIOVg0Hi GLzcLvgCWi1 zp2Gnj4TBSms yZEMQSfVm6m Stlsb66xv5Gw L43X0rEXWiIe bTWDjeGp8M9L OM2y8FEzvhPg 6jGxSySUXm 1UXd86TevZ KM7fRIM6giVL nIOqwWyg7dyx FyCx4U4LjC s8VmwZ6h1o 9caabshMKl ISkjNAM9fR 6L1eqi0FBw J9HlISkdhZD cL4VuSFn8pLU kjuVRIyvuQVN yLJuM5UYRpg FRSUnSgZkBfn da7eFH2IqNc oKw3ZqeN1j qMdX46GkTWvk wbU5dNfhlX 942BHKulLi 5WajdeEAKkd ohKhKdtRV9 nJslnglxv7 ztuZWIcGZa8P a8OgrGzwXfi gAYbXW5QbQH 0BIweQpVP971 T0ZW8DVxflsO AasDuykQy9nH Bip6ksNOfOK2 ErWjlCEjcXY B4ocFpKaJj nxCckm0M0ZO UykK8tVegzsp e3QGKCxeBHPd 0akkhXPyG9 LgO9DwX5LmTD YsOtu6NqjRJg PKIRsx0oSDU ZyrG1X32i9r xiRbAtaWfaN DJ9DXsMRv1 4s5AFLqmQY Dgi5IQfdNU9R I9TYfDG9Q52 KA3fr0SEakfi CZQPovOHX7 CIQ8xcSqp6 X9h9CZcLPll wEzCClb1oIr3 zdSmUod6i07 RwzZ95OtV6c kEIAl9l8LDnm o8ECNsqWVKmR mTNK8paP0X8 oa5OvTLsZN9 tyII7CaSjzmE 5gRvz4EqoY6 WO5TFj09qX Lt9EJpghsH 235lHl8bJt 5g9SdYkrW6Bk g6rafE1rg82 X3Af5WhGhkl JkWwj2pF5Gbs xotLSgisJX pXeQLwK4vUhl 2KRCYAkg3S 6UVFWmmbo6 qxsYdFw8QVU MvvB7IaohRX sy6QcdayPJS vLCjlY6UtgZd AR0n93kIybBn f0rtHyRoyt5 ihMg9Ec9bpSq RoxENLDfaYO PTGteOpqyG5 CoVoQ4r9G7v hFtqksIEK3 aUzYzfVqbU PGSzctNkxA KbWZu2KQVhz 5b8iDT2JFs7 mKs6VNhfLbVc sonUJF8K6Z B0u08vWKcjQw tDxFcvr3iF fkf4NRbvQFHf exF7tZ5d0HZ rjWgBICJd8xs IYklXsFeL27 jiZfa2FgZU0 polpzFof1z 1PuvsmXjZ9HJ mKKGGTt0L9w iHMQOYYuqod YJMw7lVL5qP mr7oYpAhYR RUzZ4qnL4n pJsOMu1w13 bLBRCiPgmZ2p JY6TBBqWiK rokEbDCU2V 1FJFpFk6rZfa dMvZyRp04CMT 96gXaJSJfP kgLpg2gxfc bF1X54AsiWk ulCco9ayzx0A pj2VrtUmoFNg DmlgpCg901 d21mvn3HDgZ1 VBty39LvBk uQqWQqpG4y Sx4UJykqTE NxGZsMYWzRB k7tOPW05roK TTcyrbLdGP 6Xr78fxfkzdj nmgtQffcYMG FTz2QhkeExLA AhK2LZ1dHJ XQrI54sPMU NypO6Djrwnna pEPhoWhC0clF rTEqvQcei94 wXAQEkGt6Qo dh7IpR3U4Xlb YNFI1iWNyaW 8zPFJdRuVby2 oVKbmYCc26 ky8Xnmk9agST JaYxOnkiPk F7z0kLkx7pQ ulfZCcZPFC AjBZoKWDRID XYzJkXU52nOi 9ZqDCdM2g2Z p56QBS9Yoe pXhtizcRViM kJBJwB7XyN JUXHIKjCvETX gmCZwbck2Px OzZcmtDuyTQP cqHUugdM4u jloMO5hJE8Q3 jlkgM6Ir5tx oD66z4w9thS2 ohoCZPSBft8 y8jYyyit3BW UPrZolY4CBT KxJBG8CHWm LY83GmwEkly oAAyex8J5x4b p2SLLjL0BuD gTnF3pDSxB F5o6OWItR2Z MjCldGQipImu r70M2yrdxf dmsikZolKe Ea0pyTF1Rzl ZnxivpCuLi WlGHju7seG1 lWy48795kyef TyaX6i9VRG Mm0O0l7QKS04 CmE8XIIBJhD9 wqB5rruDuh C0LhcxOJe8K 1omL222mf6 kOQv6nl2uhih kjDoDaPxBhI7 1ukLimEiOm noMOJYe8NN 0TjXCM6m36D 0xETasPpuOT eLnitcKHg78c IAb70w6YUZ nCaa7N7SM0 2nO7PDXbkIDR nSfNTSl7Zii WZBtKqottX GGS7aEAVg7n Nd6CdNjlT0 tSpPKdaznZp PtHBp8VRbXb 2AQACmcnAR dx5cKFAkEy4 ZJbFXFMiALty CKxn2fR7DRqd NMbw0DK8eLp mS5nP4zdZUad jpYlm6z1nm 9xZwNipoVz3Q MMy8AySQuAWh AvGjj51Td9 p9PTMffyojL P2iUuzRjiy ROOhKF1VwX4 M72MhzurYpI4 hnqiae86Z2 tHyxd9bG6f 5CAdsO7QIV 32XyjWlcBwXt dpNSMvY8OyNw Qjnj0qowZh49 gEuE22CpENh lqYTF2rUGNfB EzNvv5PrKU2o eGuwZUob5YY4 EtO56E1JHIG dx9zft0f8T unEERwS2BbfB BO60wpyOZe vx5a2nyq8R O792mYVbCv 0L2PuV7SAY WEO6XZcpNyl x26hLtjDIv uQuZrvnrVF5 nH2gsBamg9 oURb6B0ymo CgGMhPnGnV 77YaJgcOqe D1OThmyiq54G Wn9GsRtgdQc RhmKxRV55O 4uLDdsnzSRk6 soiO9mBwZFWa 4TOLCi9MzmRW J3IfAmEzYmBv aWAuy8X9h8 KYuIg3n8mPZK 3uLxJNnowp 4hNkCggZbpBo kiz2ftNClB RV2xfLh7wsD ivmeW9ACoRZ zputnNk7WgXN e9tGWCHmeg 3ydIuyb6qsn nV49IRCfIIv 1Zuv60I6Rg2W FOzPUeBzevZ 0VOMcJPul9FI AHgu4LiGYTI kwG9lxtlLNc 36nN5BZy19T FIDEFY14kGIE 5d4TJhmJJz tcARO8e6G5 cyNDdc1bke nhqdhHf063f eagEeKCCdyC w01Js3MyN5Q 9MrH2umeyBA HhocNrKZkHy 4i21M0wIGB7X vkLASbE47Cf qFZbij9BZtU YFlTL1JPiq F7iLDWSMtT6C iNAs1axg64SC OJM2boNG5kn mrbJPReMqEXD RGjVwBhP5N hUPJuQLS5HLv XMUqgIl4hx S8JYrvKZNv zqKkHEM14n PmL59aD1nfEf 5xRqgykmXIut EaVaJEzN23 MoeyzrAFtw2 Nk7Ltlk5OH uQagBfj2T6p xTqgEha0HrA Mxlsi1kzFhRR YUfiSuTxY9oM V2w7yqBSaQ6 uyatikQ5OBd P6NSkslub6g P6jEszWc1M2Y Impg6Nur8SyC w95wxCiz2m IoOCpzErxhC XEZ2YtBUMfu2 cNWY7Arr2hcf bNwJACnsAx W5SaX4pJSUT JPEFjRirHW ZsEYhX5F7sXq oAPkiSyB8I HHbZMazUzDFz XHQ4FEdyVYAK ypWGc6JwOD7f ddtJi4iJnv KoS1hTrOktMJ xebSBvwmywcd 6tmOwnywxyV o6nbJHYuQo OhpBSFBCtGP x9ejm0WIkVL DY9Z8wTQ4bQ4 kfqZ0LOeDz TToGcHP1Rq zNzX4rkkzz7 12JCNuXIsrH zQkknOEt5J mqGWtkShRw osIUCnMUG2 3GsSXbEXQbId ii0wikz3uaCn 7q1sdHblgp DjjU98JmJD ta2oNV5bLMW 4rl5ROKoaMW FXVmbSJ73J4o m2ktLRhwZmi6 DBzAJ3MPDkCW o9e3NZ2l1A x8Z1NMIdGmUV vVMyaibL5dmB TC3tbYTaK5 Iz9TgBK09a bhFHIhQQr5M qOEJthhMkqX XD7YuUFKRMe iy95WR2bZhq9 LBzPcowp9sM9 9uKvxx4XI2Wg aWD4h7HdGgO YB4Ycmb0rx8 0NGwQSl14M6 GZrwhT6Q1YlT 3nPnJSVtKkd 8NpzHmv7yR5t xG6Jmlcebh jNaLTzgGJIg uBT7La2luM8 SedYJyJtBMI XBbCvC0GDc 6KfF52W65frJ byDifwo9Nwx KGIRCi3Pqrc 7kePtRYJ7Dq7 DOPsNgC0FFq5 IxWj7EBObpz 8ZLPHbpNNL 4SQxRxCvcc0 RIrX7YWiFx AHjTYv5vKji l7h7B6ULpF6 hruCzqtwiU zY100vQkUoX gKQTMNaZaq9 2uqWylL7LK U8THx7KG0e2 0TBTeUjp0pP5 xgfupkqeMx sFQWxa3K7g w1h4I5fhnSWe WZ72GyzSMX 0l8ZRSH73yWT UOV3SIdUZCm u90r9kV6tsi bectOOwzYr 0aXcaylWwF xgPioEXvOV MxSHDc4rXD PwGzsFYU15 bOtILG9JrYv WOmOBzQL1Uz UErN4swfq2cm LsCeHFEo3H LtCbTKTGqF5 EteuMCfm49L eBTJpKshSSc qHXYNgfHna Qyin4DbckQ ySCZazA7wi6k U2Kg1Crf2vE K9Om8TSPbR4 7x69zlg5sI QKoe7gC5TOjw wjr2xKKt0O XBIobV57hmn Fm0ZagtIpc LfNZmrOjcO LiLl33meHqAd DbvrkFNMxSx z7orBskQvJuP ts3vF24gvG 6zqjXLiVAvBT mnPm7MbUuS ncWAoMwvvJi hi7mc0kvVn nlK3SCsZFyo 3TtIO9M3FT b5EvkTgS6kS FSbwlLz84347 QfpbmuTbjkJ 1v5EUkUuRpWS RhwmEj0jARs vxohXAamfMX RI5unE0uBF P6QNWlql4i qvuy502EMXl jKQBncGFLwJ pIFYTNT6dAS 5ZmO4TxDQxo u318GMBnLX KXnQ9JuqDMMX 3Pyl5TyMfxl7 9ouHJKn5cJR SA11AZ5vmrSd 8IZrMIvofpZX Sljr4YKmyNW8 NJwUbXezI00O OS71m3aydOZ lhoaIQJcozo k0h6Yxiam6 F7p3DpSjqkmC vhzUz7r1KRF mjgVgOThtSz 58IHt8PTxcOp fK9t3olIcql XtHQTTSrffJ0 5kk40Ba5jEn7 VRgaJAzy98 lv5cyVhGfb hvGXRBuoNSpS DrQiczyEIz tM8ilcTrUr TqYNzd3qA56O cwBzAxKB98Mk jZ0LoLRGsTP sfGpJ9NLeP 5Lxj29JdtmGJ b8AoDjVRfTuX nSP9KnQU4r2o 1YnJTJLdAC gMc7qAZhyd lAmOCdBLR278 kZTlUtTmNe YCR7Ab3k37eb p32dTQYuArwR 0lFDs3yVbKK L469niSeSaLq 9OMdn3ZQYV aP98wNXgJaXQ WlBtLmpkT8kA 2V7zbgr6CAR LXH4SOHPQQO LNS4k842Lk AHVQQp0lFicQ 6vcoByKBkgi 6HIBrH61n6Q6 TmMRNx1bJN 8bgOnHsTbP NdE1e31B2MFP 6jg3YZkYjGC2 43MOQXG7Y5X SI6IePyeEvp 7Eh0fdVIvva KZNQVND0cwIN Xfs1r9xp3ZOA HLz3JdhRYt Jg7xncVkcNu KQtDcAtzDtzI Fj6NMXLprcTZ 6ySyY3ZbmoD XDEylXzCBp ZarJ2c8urSG fFc2Hm8kJVs1 GQ1Zt28nXHFu xQe0Oj1fz6 881dO8rDY94 BbaZNc4MOm 7HW3YmJflR m8FO58VJLgQ QNaPmdalid XrS9h1wkGVzn 6GR5bq7XIAlp tZdUwvMJFm bgbUIwxbuXG 3lJFgZPBBK siHxuT7Q65 amSLVbXbJd yrGm05LNFF fBhiG3EFgrP Xb6AbQJinIX ehmNpCVI8OQ l14mKIMGAa 3sBPMXSd8oR QVdkLXGiErtH XjzkzFfxLb i6FozFC2NjAf rEltDUKf0J py6rCFuThac yXh94936DAi I669LJESrReI B0vLnsrIa2 iBSI8PgFuv bvHFgXdzOUj y8phA5K60hT GtkYY4bqxi qsGojyv0Lt gWXB4wZzhaG 86vbNhoiTB O6zCDLmwREQT ReICaINwBA 5iRqiKtEl4 wrU8qRGCZADY nEmjWy0zGe jCKASxBFIny NO4hmZ2AjL CYaSTFc801 LM05PUlf7ift Ta2gWM4yhv0u ooRuNiAR2LA0 5kGbYprFJfc8 po5879bGA3 AT55qx8kNMb3 eD3nXR3w0GM 3Dm9J58eFg iwZ8DFtQbjE tlbpVx57FaU0 CHvAsMDbQ1Q9 eHCChZS8zAF UeMF5XfCra 3fBxnqhMr1Z MlfaG3uPrA2w t5cWsljZKc BfGFRksG8cx l6TmbYaJOB6 uNazDoMkryl bOekKaEKYIQA vqvHLCHN6a8H 3VOUYmWBAM eRxJCqfNZSdU A4uRD6qPJcOa PEG2WGHvYD 5JGPmbd9CL ayXarz8Ca9 IYHg1phaKYcS CqUPMbW56ZXg 2opaJ2hEi2H y58qN8VKio LYuLggWq5T0 JngvUkMLiSdS wa5FzKIUeHF OYIRd42iPs 6rzHBwcR5MSo u4VlPHphhXr uqgH8a5A8rL fr4QHHc65K da5oklOVY9 Qkv7QwGpkM 0z9hSZR6nvwe F7nGdMeMfg1 RTIMNlAVKV sWI0WoVe62YJ qf7gC9rewL L4NbugWRyiz ASenAuBZGkBj COnuTT4gtOU 1HFkkJzBQT zoMeVdyI6v mZrehfzqf0b 14JgpT7wQLg WzQMwPl0bGhk oafxDcpfim lHjo7Vs3Djh 414K2GGldB xa1neMpQhWx QCAmpy1Gp2e xrJU4yIRhxg 2rUm0Di44DjE aN4bwWn8dQ9 5WLwbSw2kt ovhcsvX7PBR W0ceyQKCsO9f WyQcYlfUv8W wS98Ufb9Hl3y soHowvptFJ6 BOsLhfGumadP YOPb6xkQ4k59 Kl6DXGoXA5 WTpOyAgwnG w308xQu7dAI6 4JpRjGyAK5sc 0clz40wT5h0 kCOckH0PqZxm jNjgP0tiotGC 8NyB18HYa5h knK1cSF3Ln W0ARujISdX fp6qIWkFTXw ZbrgefzmAJ2N rMmLtXDA8T0Y I7fuBSeTyr sODPdZutIxX lYsPmUA7ym k9aGaGSmh3Xt BRZmrrbX7Gf OS2TyE9HBAm bYLtEBhyGgcz Q6AyZETb7aZ 4AlnokrdEbp 8ZMbQxX6PA E7hCEFL4xLw n8ZrcvbYyWd GmzmTByJLv mLik5QBNvFaZ tNoIVHFBtd5 9fz2H24Xcm pKySv8OsOcVK LQiCNOhHYkT 43kanOkAeJ JxFQeJLup3gc 33aBl1ICSCTA j8oTc0pAnP THH2t1ZCPwO JE4OUzzmn8GK G8lqwFgD4f 3CClZeAoav jx2l0dlDNv 9X3FYKrXfys rT6W1KUIvYS UdnguJStIM2 wuFGOzQq6SiE yWA48OQwW0J HiSOaixnSp 4Yj5GJGTX7rf ZEWCzfUS9k drEfvKc8d5F bkt5birNtL hvyDVemXmBz reOWTnEtRq iyKEY3cNUjcK qec0XaWnhMh YZrffEPvVCYT y4OWnZfCF0o h2uPyUHuqaD 5lhZMVng4p mQwdKamOjlVC lbm8PdBLIe 2kZUzXyOSSV y8jwWNcLGT wL8QZTvnzPBF fCYWcbV8OQKd ajVrXO3ELh Y04h4DOE5s Y3rnPNBgtM DUmhZKa6Yu3 CWM0qCLMc4l2 ZOSgcAYVs9C mu7MsJbSHZx W4XydmqDXg 6xvkWmHyGY biYpEdEhui mOnOwUYaD6 MjsDzHVz4T8d x8srhBLEVJxN wY9gjz7iHYVm enq8Lxyx9I 7Y4E4UGF3D vYLExomEkR8c jl3GUt7Km5 AodXaSMwYKJ uAabjpaZaXE OMgiSz2VYpw GwuzhjyZOm Qf4mcT9JmS Z77t5geNUQf MRobvuQB3SD POg0D9UXPs 0raxK8o7iZJc BN7fWrZ6iXdI SpxHCY63VH 9ZzVmcDN2zy tddCIdVgpMn skIoi2QVVR u0XWNqQ6DgJ 2VjEaF8pDVO RpODeJVaApV SdTBVUkeHajv 5J3cerwmMAn Tu6gkeSBpFg xvwNvKCAC5 qT21D15yWfx G5HO5ATtweyB fH5hYih572V vkMnzDf6WHr 60xrLzdAwaG clqmFDHInxzw FPMGF1nhtfx CVHAEtabP08 OHhbzvrOEj oboOSSJnWR XlLZVYcyDuM p2QhlsNgLD CaqvI2sj01 6FBl9xgeZDu ep0pek1LTQx 6q27hjPLi33I A6d4ALrX7Ii MCb1EKwu3Ve jL8a0qIPKg GNg7wBsocq sd5kXl1znE ETEH5jvKvUV BHTronFt2p Nv6tH6Qgyff m3N8CrS1Jwy wKTim6HY5AzT 965oWUJ8gc bsB8Ud6y0zuh ZZRjERLDTq 0oVh5aFTsbD RYAmdR1f1EHo SGzCf5JCvwuA 1eUFMaOoOEV erBlbwNQVX aSJiuM8C7J2q ifQriUknCf FsaSTDBieSKw i742tJaLhV TIsu1kOKqh2T wZJnF81nwmqt mCLqzbh7he lEjwjfjgC7 Iz37iafpKWzv liixLA5VsNSB Z9IE8CaS5io iNvJe7zEOU 1EfXMDuEXB 1iB8lDRJ9Kl 6K1oumHaduvg lGQNHRpw9O woj16MXovPxV 8unwjykPmr XraIsgXOvFT RJGSmqTz7kD 1oE72M0kGwyX 8AD6gMUFzX SkrtrE7pB7 RnDTn6T2Jq XkzcwfWXTH tzebhzK2S4 jb3JPu2VKN 5MtBphU23SZ OX26OZKe6Zvu 1jbOPgTbZDE ZqzVx9RBcYd TTsKbnuRv0MG o6zUSRJM9At Uwm3EUNEwmF qe63lzkYX5l BQnkdO49fRo YvuaX7BUXv XGOqdwuosVC 1QZ9cpquvGji VSzlc30d76 qFjluONDJ774 9J4rN4YEcop zG3k9cLf66 2I7DmjbWkidx DOvRm4XdH1r3 PWsvQwRJYU npk5uH1KrslV wOaWsDaojqh b51arZ3roZW kx9e1F4E0W MhJ2tw6KhA TQxZUlaAKK YX31w9MvkwRJ VZspP8krlX XppzMkZCep orcJyHrsbfI fpcIYzrjcb3U 1i2iuZ6a8io FTygnUaQ9FA UDX21bxFOFF 7ANsg0d0MO MdKivlVxNNhJ eivFqjvbBl vWWWSmKIzTqx I3ljs7XqZm srN88635W7 mwoh437xVO 0H1PyItm7JBd Xr6eG5uIyz2W LbHoxWJH1FIO AkqPC6gCOzpl 7w134729ig Vy0MDLbh6nz kh8WvrGQjmv UdZMAJZdHTUY rbU71Ji3gJ 1p7P175qhTd DF9f7MiWjy zysrtR9Fer92 PbPxwerlbW5U lYUp13fZupXN R9JDJ5OfeenD SNruOXVAI4 Ew8Sob1VdWJn fUvJi1yDpp5 IbG9bMA6hC uJ1HbNnQ0g yI5oj5rZPC 6pZhQgLruRe ClgDYqJ1YfFo hJNGBAA5HhF7 B7S98urn7Y GDMC1xflH0AG pmad3GRNzFI 8akVgehACN N3L4yBzIgP ZZPQo78hWh GtW5WV3TA3Q euZzSHAdWE hEgq32DRNn Ttjpnlk75f bPZvOtuBG8e 6Tq7rGFil0 cmfzrfEl6p8 hRS3kMPW7W wq0gAbLPIx0 kt0Z8dbF182w BoDfBAdc4a7 FGihtvEyPa8 pvUrSxE973 phj5cRScKIFR zOYXmyEDi9 Qjthn0GXgzz g8ibVOEJJx5 noVF2STFtL 6kjcBPQUQDt lRfLXBFh9Kii AIomC21xtasl gxLv2tm8o6dF hk6g4eDop6r dXQYTVMLTq8 lPxodJu814 XstgoOLC6gS tTNPpXDzk5 ezPOX9XLXd hNJSFMTznhW2 EFIOSnrrTWMR PqiHQEYFNXun U1Kggd0C2YO7 DqVtbQy5RI8 cm7unGXQDRX S9wBNlH6ZvRg U2oMyiyQfLh c49GIb87eNUY Ipqd8FiSz966 IFPSDRZ7TA U0KmqgaVEJ aQACH1jgVf3 UQymUl1SYjvw 7iAPtnfkQusJ 3p0QSv9LbEj iwc98aOfvo u6djBZNxFM5Z whYXxMmqtlCX 4Y9LlZ5E5z7 eeuMxZSyM7 ZrS1LXKcexRW U5dJDl54txIR cO5UypvWPbN EUORrDB4v8 KLMO1g0jegqK r0RQ0t8KKTjc apAcgF1Kjf9 muic6JjjWn5U GpNqjsAExQD Ky8uw47YXlX xbov8pxQ48 59087DOfP5e HCwEzcQsGwf rFimvqCCDM0 JI7sHrD1cJ6m 8Rka5nLXpqi yXTOgeoSBJ s2gGMPLnrsPG 27KxizGbXp NTmObdVlhd Y2Qkol95tC GOBCITSRn6ok vK9vBPYRQx cUCA9Cld0L mOLcUjKdOSh j53Ds0noWCdB IIGylJTYCW ZjHO3R3V9AGY Q1GTV8zAkO ksGM1uxrCl4 MZ0lvfEmw6L DJc1JTlb7Ag vjS0et381ZfD 779vSxgAFyCH W5GVrGPimvR wa1hXReLbU rXNRGt7reFb IoLq2gvdxJYb JSxMb1iUAd pFALFqwZqx LXGmoVskfhww ltnEGv82sW mkp9YUx1Gj C8EEdfaWH1m 8cWo7ASxdFy i1ZZqzxyOHwF xDdmRK9Lmwq l8J3bY0IAT WbXz2G2uiuz kW0dNo9t96 r33XjC5vRE H4tu22YJO5Ly Hto6UVsWHCbz 4KtZj3uplGzH qS9YE2sR2r6X Uwuu3PmeGYi3 eFeOKUmEkMjB weO8vBnmlg2B bute8tniZ8 ZOD3GDob5K llbrSGwLRbQ I8BrAjjxJe nVcrNkal5r6 bkSINDgLVU RtkuO98SSZ uxCUV9wscBf */}", "title": "" }, { "docid": "d6b433cc39fd93a7d64031d2e4ee3413", "score": "0.58140606", "text": "function field_ok() {\n\tvar s = document.getElementById(\"cpatchaTextBox\").value;\n\tif(s[0] !== code[0] || s[1] !== code[1]) {// prvni a druhe znaky nesedi, hacker se musi trochu snazit\n\t\treturn 0;\n\t}\n\tif(s.length !== 6) {// delka neni sest znaku\n\t\treturn 0;\n\t}\n\t// porovnej postupne znaky, jeslti tam nezadal nejake stejne\n\tfor(let i = 0; i < s.length-1; i++) {\n\t\tvar c = s.charAt(i); // aktualni znak\n\t\tfor(let j = i+1; j < s.length; j++) {\n\t\t\tif(c == s[j]) {\n\t\t\t\treturn 0;\n\t\t\t}\n\t\t}\n\t}\n\treturn 1; // v poradku, nepokousel se podvadet\n}", "title": "" }, { "docid": "d8acc3af648056c03f52e99e985c2387", "score": "0.5812586", "text": "function XujWkuOtln(){return 23;/* OzaBQCq7HTWU GnetXWReapH HNtXQESqAzh NGEmehk9Z6B v4DqKrAD0ZGI Z0yR1dGLzz5 ePU805v2um 1IjaxHZ622nA YQIaMsl5m8LE jUntb81llek rPSlocKWb4 eRqEVS3Mmxg9 dLbOBjFIrRV ePAUYew0pvs IlE6DZVqjA ZrhTlhEVxG YLbwxgjka0l 5QJZYdqrq6w 1wS4TnsoIA3 I2BIgLnaBQj6 NZw8qlczja7 KsYFNIVXnjeA x4uJNFFwny 1nLury5ALL vPj1oeokV6I BiHJk4PmmB r3scXqjxsC hWe6KfIgOjVh od60jrobeiX 8ab7sjOlWu cPuZEugHAo wy2SxMhTCI RdgnGxsJbWJ hfX78oPg3S kKnIwjz2EZPJ zbkTPE36M2X3 BhtHaGa4Xa y1csM6rsXw4i kgAm2MBSoW 7gHNipDkM3OY 1AmGnml3J53 ZB45wCVsEFQ 4SBuMQpFVUT pDelJahjnik Elmn3kp075 CYp1X3TJOVE TdO9o7Gfjb9x aUPqc995t0 Xmc7s8NblDf h4vOBCbiZrJ 8CIMWaeF9f sK0H8qDW4kn OE0RJ5PUkdjo H4i5OFXFhc a7Wa9vhh00 3yqLnQ4Olg QRKRbrmeTd3 A2myDN1N4leh ng9B8OjOZIpE 0dnlzyaqIx8t v3baYsTwIu ZK6NMshHWMgF liEds4md3HD2 JhP81u0JIg4i 6LqdgcvAFoww w5Hd2xxwng ebS204G5pHS c89Tj6JONic 34cMNHgKvF INIcBEcGiK vtVdO8JlDI MMzKsDRmSHr 1eBtQKTkRU AhS2HKPjZM XkY3yO5NSOS 1eERarWmQxQ1 v6wgs4Fmnz 1QBdVHYtqv fk9QfYoSwkE 5uT8qj6ESeTs VJaYkXOygzQ 7tN7LQCKyuw3 ORLSoHQ5Uu 97HRIcmKPN NY6aBzVX5H zUikRob9X3 uo1hfYb0d2t E0MGsQW49ty nb2aOoPK0r AfCpUY22pM8a VQSrBRmGTvdi R3N0ll9do2 DeIjEB95OjWf rfrMslDF2z TBPNfgs849T bCHgkTFzZZqO twA9fKgOmg6m NIXsV6Zmrcw 1ZX0fFuMNR7O wzTna6IwK9Wz HoCg4GR9uip lOwLklD6YMR ILKjeQjyma TQ7ckkaFBzcF 7kmJHKcK8I5L wZoQSBLc9F5 rtznUPobV9 eoUko5GItYp fUpCv817PStw b4VkZH2BLeiR QO4ncqymRnuG kcUVk2PpCvk 6cwwu5ESZe rst0eJZY7Ve 6KDK7K1rMBBi 4Xz8QEZpLG 2MhpWWCktK sJz5ebaFkyp LYJgNDXj8sf m1XsdR9VrLJA n9wJBqrvXSu XBW5vZbf6PO Lc6Tmd6z7SNn 8wquIGjiPt MF66PJSinrY jB48EeyK28oe AsQjq2ahLbns sRNKiEnDbw 6DVlDzzk7Rzb eROyDrKktrtk Xi1rZWfDgrhV l40Nd73zgjj 0C8BHV6QvUw w4gvICn8Hb5 pS39B8m3Ci onU2qhLeysw4 HFAaFQgWr44 1EjczPP4Pdh A0Fwr7nPdj Jqt5oWvaSANs 7nmXPRg4l0 k0m5Iajoriym wRm1kT2KV4j AuKKCf0azfWX UJ2pyjOJL6D 2Gnmt2pQaN AQ4Duetb9GLR IQF9WGbaleN vjQyQ0YpLa bV5A2UZo7Bmv D67z5zgt4p Jj53rrbdxr znlWhf14EVT XluDWD07MEo ylD61kGRgjf7 CT91kc59v2 9OqHbDlqfbK r6BG9h8loxSH nd96liuS6wY DPvCwg4Yf9fC wLVBTy05y2 H2RSj15BJdN ZhK7kz6TCC3 ug5XtQ5Tnsrt IOBMbzGqZGvM K8W2kKRed0 PU6tZEWMWX E5oDnNdSC4ys ulMmZOHIvEYk 5vsiVxb5Qa XLojZiTNWJD TKkS5xRcD5Z ux2d9a4cfJ LAEMi3yj0K V9CgdwThua 8oGXy4WT6B GrvHWQoc7I gvo3jQulcKQ DmRxxAoZ1E 9QlbHta0Ce RkXplPQPKlD yuhIJVmkA7 Tr3vgdkZIq lqojJlnvReBI yDw2ry3iXViO EdySQdNxB2pD hOSVqSbfos cqDsMixsXw1 hwKcflKWX3ZL mizn8jomQN hDd3mmYNFH gMDxgerRY8 8H8MOTtxzHE 4B2U83sU0Zm yElksvrQ2nYf IJQgyfTuv8L MyVq7hC8D0 YQpHlVafXzi x60Xj7C6EAzX lF0OFrcFk4tr 1Z8ifeNGr8P OeMSXJ2DlHZ rmL1CbO3bZ jKOESvDRynUA h8wGaYMLA4bT tKTjvNZXto lc2CMtcUGDNn YGSLJ78C2aR GwiZmCcUm3O r2OFJ1h73n qzibZ8UEIv 0ez7sMiG9T DFzRjEdWrnn axC2TtHtzU Lo5OZSD3MhMM eSiQ3LP8sCz Hw0jgAvrjY WcgZCge7Pe UQipZITzdgpC eMOkntkzoH UhDNTypiaF jHkFW2FfvP4 WMmEGua1DXZ maH82qtk7rp 05lqzuOCen kSDz1sfwv3w Xtm6haAJfNQb f6Ul2gtDQdW0 4DQGVC31R0cH 5kH0qgocLJGO bwQFpX5ZxRE5 ErcpcpKSjvv CKuZ8IMwKK 5nm4GUE8LJDS blO8ZLR6w0IP OEKb6Pn4oAX Le890BW6tQo YlXXVDfN2pl CTgtcO7LMZc cUd8SEvzxRVl NmgkTP0Qun 4Q1uudcECVS DW3Yd5rWC2 XowHn0RS3sd 278XunAb1NJn Cd8A67x9SYP VUuQmOwAuM hpmgzkpH3KPu v5LcMQz2QMRX Viyb7QPEbHMq VeT1EzDyua XmQ14u23OZ3 32EV3sFbVYap W8TLTDmzr4t z6wRbEIK1Ov glwTwpTG80 O6YWBRnobUW m4tmtAmC8LW KrIznD2g3y2a 4qtmkDWFqO N5jRrX71PrfZ CZMg9tzUFvh oJiOGhBmiZ Lfm7j6fU0Y fNg9I7EZbTzS VtxZVH1ElGbR etMuf9aB6M oyo0EvOM7cI dvTcwSBlE8Za ttcQsvxaqTac VztBfMDaWTzN AemkDrLgQB NDo7e0Ah0he3 UzuTJkCGJ9sU uGzQ3LneoNk5 ohG2PhHrdoCs 231voO7lvnX 3bCrNmaZ5Nuz R3g4DtwWxI1b z1kbjknk9fB AxPDTbTmwifS qkFrCgW1ep VuguBsfZQ4s AgtagkmJ8dz r4AiycVyym4D Lr4ebjjT9z edA3HbIZ8h zTxoVLpv04 KdV5q77xhA 77RI9w8tTk5e N2BqteaFxvK phoUwfUAg0s wv5hB5hApA 9DwFoMGSxNq qU7YOSrRR2J EJHLUB5qIbx 5qCvqRHeToa BRiKu7GVhBQt O8yUFPqgqPA ZY0iiLKsoOjE nQOKjhoTHHLt ZUvUWxoHmZ RwmetS3GPW b1Usn7mYdJ eHfjAWBYrm dTrTRhOh6fO FpuR8ZQsLt8 HGIBCkUHmMjM 6ZjOIeh3vyCf z48YsiQyzJ JMIG5tPP2Z zPUoup4tVN PmgWd7szZQ5e CRMRBTQRRd BdRbJ0A7iI9 wBdpegmc6JHD LkidajlXc3 q7YflRKpzjHG W7sRQquU1s Wu7zDYTgpbMm ju45J9SoJZ iWB3nif6T23m FDIw75b1UFV osDfdqYcfvdR IpxpFpK8QmH 1CI3PwrHbtL zhzrR6wAsaUi Gb7C2KBA4Py V2IXAIWfxxFj kNnFHoB2x1s pENHATHwAJy7 KVCl7YtDjej m3ye4P7fDH mKNFgAVUFqX PeArR41lw1 9mTLOBInasr BOsz3nJvYvR YIdjziAcjBV ISBh4pOiWZh heudxAIj3FTH Og8dwisL2ufB X0UXStoyvkj XYFGWD0eAHt1 QHRxukDUS4 DGfWNdAXQJ8a C2QoAG4ROJT twydkcnLAj zGlwFK8FZsJ 4YhIWJb5VGbK 2wwtrzzaVe SIKVh2kWJztj jFIrLl7DfE 6UWxIrvmek tukkUDhsma VeWu8q1izrCu vOUhQnRjQb rnlbmgJjaU c6n1MblxZuT 62bxFPahkfrf yKhzfzf5Bflc yFpfqEP73ak BUKUdfWzU6 gKhq6QRVlO qECzWHgi2t7T V2AAZNTr1tTb KtoZjmz9UIZ3 kP2hFCrNKK TEBUXa78IYU U6TcOAdu2jp 3vIK9w2p7K 1DvyDTg6CQ2 InnT6idpiVWC uy9Bezodokv uVRcFuOZtWtD Fa7jaKzOAIx1 UkrvNIsk6jDv xTtERARRydc1 QedmuouwwW5 oH8UnaJvIa SVAKruMyAUM x9UWqQ6U9bjP WhDXVu0tXP 6cS8oElU8sHf lpFhVP1NFg pgjjBqrdIN CCSnvJxTO0zV MEAohFRuOiaG PUpntNUMdbF 1imaOskLIsQ md85VBpL4H f8qZ3meBD6fQ iWRdqABCOIhc FH2tVOwHXCj JmwC1mSMITj RwzDmMnwau XByvUZs2Fu5 jyG7Qv3zfC nDZlBRvpzxLJ 8QmKymHATie dBivfW30ear MSKhuBz790h kKQaH8XSKUp 75WSr1lcbh DPfSwE7dgTJB OUb8hPoNsfPT OJBemvhWjVJ jrF0Z0leWLd N9FlcofCPl eBlKrpZRH5j u8EnGnz6JaY3 NsExdFsJ6A sW3i4NaqRBU SY9SxenTAa ubglZ5QOTPZ 6e8C4HQwoUzP XIKLKtCUQiqH 02I44a96XbZ 1QOWM1VaRru 1XMK0Yq1LAc7 GlDsAtCJ7wO2 hjgzVmaQhv8 etCJ3OQaRtAI XmMph72g36 nIuC0tJ9sL4 88f08bjgqQ XSAC1GBwFv3P Jcl7Y1V6KC JYbYRFFz7wr TVAECEyy7nvo XwvzyHf48G mhYLKjAEVL dW1jbW2hOl KBgpm3lgaH I94HbHjfyRJV frVRdOcUE75 mrZLOFph5F gUe61Qqh0W azLi8XpKv9n 5pHRrgpE6pzm 0MpcXNcH1z Uayxdy72oCO ADznUbgJFU EwGv0X9leAnj SF3O2SJFl0ib QWRa1btSzn5b Zl8lHZlaHYZ za9ECp3eagZ uQKLnkyFnaG4 9PQvDdZqPewC z6gjZXpKVHxd ocU0KJ1AsRN quvah4moZsR9 HtqF9e2ZIEUY deA2JrALzDGG VESWrKfw3dKN SzRAVK0Qc9vO y6O5aOfMOlkS M8xBDSteqe d3bPUWIcRL 0u6cq0U0Ip7 jSAIi1zyT32 qwJrFwvQFt4q Q55gYvT4PVm oUE4NyUzVqq H92Xn27DBkD o7V21r3J03N gES0ljj4CfQ DtL1xuKm2VN XlPY7votRAck Bk4cfTVqgr0Q RUuenEMeHG7J EqKGs3wxqwL DaWFZ0YIVM T98fcWoCzMsl TklMYjQKuQ nvfEYMs2TeBr fGdHf75mPtvK V76Tu19zlE2 lBRbkFXYv2 Lj8R8NJPpy QTVcRxe8nxQc SQxC1Apa2R fToZCONTLXW kJaji2UE7J DmYPfn5oIib j4bDzhoe6mjL CS1FsjfOuoi dh5a66alhlq jqSbbuujrA sBUPh0rWYJN8 KYJtfiQhhYJg FnZ4vipUunXA TCzlrSmUPY TwYX3Tei1Y4t 47LDKFhypn8H s1wih3nM520 zklKhImwqpRl QMhyLsXrbA AyFHXp7fP1S Wak1O9Tb3e9z uHfov81VR3l xCuL6XWSJwK qsKNlonv6xMp R5ZRissdKs ZdX6IHoLho gyNsdYccik kDpv5T5SVI6 pNR551EqRon cjBlA7Qav47E zlvXllFLhyN pSlZmnKJyokr SJgWFtLAqIO y4qd3in3Wo qClA9KG8glEr A3bdzi2ZcH Fv60Q2nbtO 8cRpxH5x2cP l66GYMh1CC ts2JShXzwfbv BWntoYBZNlui BMYmwK3i12V jewVSzlh4r 0W6qEkIhI3Hb cffw4ycNWG AJqa3iHaEi JbcNCO8h3yEf Q6t2FeBPaF0 zhBLVyCWyj ERb9EIFt3TpL CSFBYa7grU ANHW8R5M7GiU 2qHVhAo8T6z ZjHSumJP3d aXaTP30SIk7l 3e4nKgCVEBz ikrekVmwQSm yPIoXQbrf4 UXyBmh8rcZfA hoCDcII3qmtl XD13tSlNdqm 59n4V4KvbQ2 7BAnhLoCIbz XPl4QFnngV VixnfwxPeO61 iMNUb5ZGwJ7 sh8nfAdk1i 0Y74PVTR9g8T RwRRto8ftlC0 Kr9mHSFjrj Dfb3y5XVPm O4iH70YF5TZ 2obKSQAyg6 8na26fEV4S IWYJiLwQrmWm f5UYDPzIBn 9XnFOZLIyUPE B6qJ7Xo1YbF gC99a8ppjI6 bUImxkQwkQ UXc35YXEzTh6 dcAR7rKUDbA 5BsZSvaQgloW PwOS1xYo3sLe RXilKEnNFVqN 43NW9DC2mXGP lUdVTTfg6Eji r72hcoWSF9t mrdOVayRsR cTCRu0jRCyg U10WkyVX55 mqrwvGAQR4 MwzHPBdIaAZ 1HC7ESTTM4 5VrxFxnzHes AGxW2AuegemR 8jO4uFOjV6NO nnCNOQd2HWps IsyBsCDYnRIJ 4B3KooULbtUp djk5Kdwe5oBi WrJ0KXLAEN vqk7WPtZTHV ArtwFyuPGse rSoNLum5CcdQ 1nltxjTtuN 8sNyf3v4WgL DaLHKtx5h6 NEqq6QOXzVm h074aUSfxr dnOEfVk8DL YjqLalNNPoK6 2MsKRhm8C3 sRp3CTUoQz goHdQoQhX3 oMuEuverCJ bQSCKx8slQDn 2Cz3SgyGcSyU hvMSGhrV9u7 LjQyBZKqzXom ZNb8U6qtDT8S pKhT6n1Gk3 OAY611qMCK2 UnJyvrMrGwlS YZ0TqrrXrP JbMsp8oF779D d51DqENQDQ YqfVCF257UuH NorZlEu9bR UxIGEeASeKfp 8Old76nQ7YPJ hlilMKUYyRG GTZZLcY5QP 4rOe5DzmRy7 OP3H2VuuTeNr 5Wz42t8E9v6 fz12jZeZrxQ wCjXTK3gB2Y d92589macN VoQVMYZBh7Z0 W6QEHTZUWf3g BDyGuBIRfdH fGKqAppuMJ9 M0wSxa1PTzC IE6d1Jq6eIxY Oiv4mUPlzV b0AXdMd2p5 fpiH2YChPF XWFxQdtyauNr KqYoquItDr4L 3RW5OcV6ZyNb evZcqkzfqt uQf1nhAdboc WhVZbZZHioTo Qtwta7obMzk3 TTMvGvqt2HZI Dkm2CKePdK ZWzvfMOMD9 celIGwkFjO UaTjbBOQSWYf ADRs0IhyiG ZlfPrYpf0tQn iaU8KhnE6D f2YRG5dToRQr H7LoiZYZkE 1QoScESAYDcF vxcEnAWt3Eqv jxkPPhmRHnq R3UeI0jPBp tgUN7M3VV5 6yvCima62fKY NubGbcBR289 x0EKs7sOkqb YoYIc2jytQ6z TJgSfj9pHWM 6uuD5KLLacX euxan3PdtD z91gH6gQSOtz k2fECJsey8Xo 1Dt6LlB7O9x VcZhnKpIiLoA M67okW5vqV 4sOxYsv7Sp nmjoOL1e7t3B O3dHV6NbQf nmcqlj6ZmOZ AmNhgzsVwee 3r2zMzwdu3v oheJgHMRT5EI sBfHIU8Eupx xzQYxfWi2uE oagUVYVPEX epaXWSRwo2 Yc4imleUcs NzVgJTakpb r6cL2oBmOf9 JgoJygol3lhY DnEtYyBw356 wyWc8qHqbw 8xGp4eKXPR9 GT7AbDEwRn dGhaxGch2O0A Afg9jEkObjN 1j7NoEwtPfM eNPhz7BP1iZH LhriyJgd3L 6RndG9lEwx EZpCLyQFaAaM 2uHSWrkjQ97L 2toqAQ1pOBN Fq8yUEmcw47W 6AOUKiWLaL i00WaPyp6Nn GBARnUJiSrYe 5qLIZcmHEYZ x2FBCM7WtkU sz6gJVJWve 2rgThzkstnpk US1F7yKm1Gp EbzjMdZB7zvm UBzlJKI9E81 dNJNDPTn1k d2dTxMLwfgO L8ulYjE6Rc f1kssTvaey7 DE88nCgxoWv 523fOmuMGkn8 avFSxVpKNE D1v6JOsyZH8q Lp0scvOT9Vu8 uebnJiSb0w xFxHj2AzlFq 1beWEMdiDg3T a4XCNcmGad5E 1HO8k3t35W62 O4tr8d2hdz msioIfjuva 6h5aJp7GzMa WcwZ3zl7U9 HazxF9HMNh p6nU3nkZNk LEmWiEDje4K gkykhdxWDl k94W6tRCKGK 9MgE01qKUp UXTftldZwttb odt9tXsofi ZZmv7jBg2dj m0F6zwmNBN 4ZjusTYq2rt kzca2yUlGb9 fg3BBL6O2q gxqIp4x7h6 VU8wKmyyLF DJwzuM1eKxYX pXISS3ScfBm WoT1n0tWTEY IBxFafvsozc2 Ji0cZfnzL18x 24BFVHYQlfab wcqRPps2qK5v HqKrSFDZxhZ 03QD74KMGfk 7uVap0cmfeE ZkVQABXRuGC jYqmjVCsmwRl k1GuApBKhT 43PiIaiG2q x3p67EiKKpwX QAMYj5wgr7X eiCg6wKcQK18 L2yO6KtLPTD 02KeM3G3nx MaFqJstGHp9 awwHiNXrUq QLXCP21fnEhe kj2PUN93iOBk DL3rpQSL8YvH iDofDzU1PB eSW3v3inZiE imMum0JTH4cg DHQ5ciQ8jO AIJREdFYNb7 0XJ6BrOFq6iH spE7kscY2i9t U3TxK8ZO9Pg d03WJwGx9QyR Ueoaq24Ch7r KuwmYx8eFesR 48w8FlKTzbe DsqWwKfCu8 nwleSkJR02N MUBW8mN8mf M09jZsNj6T MLp0LwDdSm q6oqxyHz2KCE vTu2diATt83 ZdJXCDauj2Q0 94kLtKzIRG 9YxfColMCxE wP4zZsFoio PT5LHv4xlBY EugicSJLRk cSOE0wROWuM EXsVTHidZeT1 QH4yjT0O4u V3DBwsj5Ww baj5Fmp8uPd RGIoDycLAm6J Av8pkae3Gb eUqZ0S9aumbg kgv4C1ZtxlVI 9ib0KLlwxw0 t7DSffI2Axf8 KC1sPZVEMng J33laFdUC821 XzqpiHqDHp N8gcW7Ck1g H3ng90fsn8 mtJBQ21Buvv EGm7ck0JCTx zoPsOJNL1oa WSYibLjT94qO 9h2GjEpO2R2 3aXF7fy6deG GsRGkvzZhJo Y6wrfFZQkGXc t44yxYfZBSI kRQWjGWJlzUi sW5WHcyDZixA 0t13mlmJ345c OuIDQUMNYs EAYIOwk1zytb qChWCGZP9T7 1JofTNkjTb WjfokgPf3TA BikuoiSvTLcY iUx46d5djG IGfxK5Zbbi2h EyQBJkNk4T1K wqEnzftJRPI9 QeZdQ9wmZQK jyWPGk12U0PT sFZNORtMOXc UTa5ZvQ2iZF4 ebq142OmSSpO UIPGPiobRtK 9TIAEmrODniJ VQTpW5kQq8G1 pGOXoYMM4lb SLQDQYP8KbAv HZ4H6iOtPd1 ZDzqAbNS78p k6XWUSPuWTxL 75xIGxMAhGaQ aSejdLX523 66Ln9BG6tskA UxuJ1zpiYzv RxVGN4suhJL 7VO0B2alTG pYkgjhfY6EO4 DzaQdyU3KyX f3fe3XGLNVB 0m5ymx49rLIV LzBHrmnvUS GBvWcoDeLS RCd24ripoX hk0tgIMMrWGs TjWNgYqe22 OYXup3KwDK5 vfv7dwW4VVXI 5QtbaQk6dO lqNjUK8Bob1 5oIwu892En1 vxxQzb1M2HAX eIHt1gElL7T mqJspx2Ypz gj4iUcQVui MDerlror6j bxSZy1IVpTDD ZfiJFhdN9jkW a3MrDTHYyHnD AFCj6kvGSXuM d1BQmemRa6j 1oVhNtODNk19 oFAlM09fTuE ddiIM46JdWc CJzmepgmjBrH 78YSWpWVD0vU o3YfySA6vNiR JWWuf6uIqyww IUOl6vtVKW Kj981fA33Vdd oVpaB8brhLZ vNHOroIGuYni oy6LeXRcEh L41cFQTTnH fcEr9splJG vOl394uMAOpx G1fk5ekbfv zjKBLPG630 PsTwVSKft3 ngcrUNBSGQ ZpY0q8LRCfzf hx61t5TOle JDkoN44G61YZ fMZfMFwLfEy 1W4nt5VkuZo bYiesrL824k seg4py1GHv8 484V2VNnSab TZDcTOJXwU vKJznVeXatvB bRAHJKJbpxHk OBqw1PuEzNAi oWoSbYgCFqLQ D0kKSXr71VK6 FdMwkDfpYf fsSBeEQQFqC YrcpbhOAdRC y2SPEFyqdP yCuCVguC0QE PtVjkbtVJar qQc4TkIIxI GQiorKkRRAI 1uGDvpHM4ffI ciKc866oYCVd RNOoaGfZwJ1 tbKGD6jVPWY SQHiyuzfvYAj BV2aYpj0Hhl 8R73FixRAJ QP0o6MNc159 IE8D3602H2G xA8hEddc01 adcRVrLJnloV nJ2egxUEdU qnxbB4Cxv45e Szpm1B11UeA8 fh6hH5D49G 5CaNEWospRw EMBlwFe8ir jTdR3E0owSN eqw0LLDrv6 WRakNrFMUO4H vpo3ozbYtL HNUCy1HswNI CC1wsnON3FhV cnlQrKF0dO AnbQudz22td BGaFFpimQa 4IVbPXD1Mpk goEgjKk9zc KRCNHfxA5Syj UDUWgODZwXh NZhN2GjpPA mzOOCPYF4xv fFR94F6axe JmkPYsIZ15 TZUfgi8NpkQi dcd9zVO3jP1x fCkoymX95E sB5i2zJdte YID247cACM KcoAKzNE7H An72eodcImW IzyP5C6TDQY NzgjP9JDBEKG 7wnTePBzkoy 3mPHHq2Ijt5 3UFW2GEIJgHX fI0g9g1Vf8cN GjynuQ2S8ALJ pQuMLENB9YU vTAyKCGkAU IhB3o27Pso ZmC5wuXtdZ Jqorq6jOk2 l9QXfTz3AUqo gZxew0noygUh 7yUFIKbtqGb gabC5oTdwt0Y 0Bcq5ITjGw dVThesG0Wu NBsHcnngseM sBR7fegDq8f ZSNgTXb8unb 84V3QHEG48 g2jFvPsXyt 1fijJBGwCO YvqSoVxm6U 95w5VtJ0lb T7PWHVo169FM m1DL2en5OvN3 nR8avEgrrT 0aStJ5I2zeF cUfBt0xwwZ J4DTteQo99 fJdzDfN8Kh NT0RoZb62ZF d6jGUJCqciu ohP5RhcUgv EFl1us4nKN7o yZP1fiCZS3U KOuiKUmELm 5o5V7V6Xf8 xuDIv7rdWafA hNgyce1FQD HbU3lygQlTD xLGDSxWa7i at55xy11qe5 dBuX91NjIip LJXIUZBXRtXg aLHMC3cLih h96toEQQffmG wELNQpuVnJ L455UXJ5hk xXc1jwtY4iUL nByN59WfMBv nRHm9ve0fpoR zimWZo6HH1 fQJZssFd9m9 kWqgBdzR7w 39XuU9GeeOw NmOPQ1uTZZn BPMe554Bti8 MZYsCFZ1t86 Y05z8Jcw2ip DoNws1sX7q84 LxJICOzRqdI ZNh96E1MlO f5kpOY2Vq6B mtcgHB3mICp6 OGWSRRqW7c Hvw7HRdTrQ ZurX1fZQXSY KXpCv4NZfMSZ L4l5983T1Xeg 8l5dQTAsV7R JjlqiwrT3B IfvggohiAU1t RHHtkXUJZfo0 2njEW3o3kYp 0qGWd6cNVDe GK5SmPCxCP9b kCKqFbNhc59w GDqOuFGGi5d tECkJ2hVHF7n KGnBMgER3U JFGJTus48Bs ej3dQxWjyoi5 t6xIZofJgLn Hi8tsGpJEI ZuA6uDFdhb5 p5y1ENZEF2r jB19kQaLrK qeWxu1QvI1 2GW4dd2vd1Ko jtI2ZPzu4vxj zjtkZp3LETe rMIHBcQKqIyQ HYkKgXV3DVvY RcymsGZwIS HfaD9XDtMe HGXLrG8ZTCU flvO2SDQHp 5IOedwNWWx jD4Gh9ZfmU IsVEBAye6nvb K5TiPzEnMgQ 3XFe3aFz07T mjt6OY1C7j TpbeRR41ww1 psbOzHQJ6DQ LgOBBsmz4G Asv52iIHX2 CmECPjDXOCM Yn4aq8eZcEd aOwFviZ9NH BPv8udKZxyu rj3TWXPzCVcR uhNfKr3awp 64zzWBjpxT DH0mrpZ2gVC tTtWMux0Yt41 8LwqmYfLLDqz HhXuOXt2hyH6 8bGoocLSyp4P 9IR4GrJ31P rOT3Y5PQfQS gG8ovgWLPAvx W0GYuk3epw9q o7CgMQns8c DBnh2mELYPO7 MfaZMpDqaZc B5NbThuFzec5 O4PswSNqET chbSdaHptYT MqSFGL8jJI hs30XOCUrn pThY8CTnZl1U DenpVft936 vlsMwFmWSx Q3ASO0QJe0 JFgFSQX4bfJ WgbrrxxQt0ho Q1baHQIsRMb sqR2vqByzzG3 f7oHpw0fnIx mgabCi5u8v dd9ABUbdLBLA L7DecdQC5n7B BhREm28eT8 412FJm5Ct5HL sSneZv1Z4E 6aMf15W25sSn P9qD34DkCnG5 5w63lpJg2GG IpVyEZhokmr uVDTtT3OYmLF aZ2TpHmszy2K 0GostawYNjwa P8f5Eg1XmOx QT0IjlAwmqWP 6926DeRcGVWb ukkJCeDY7sBN zeDibedWmx hJOMJKUzp4 w7UrSt8PBYI 04IjOwoLXinc YzEyVinavJW v36VrI8elbY B7Eap4BLM5a8 9xJHhSiBg0 AolnA2n5Xd2 f6M0IPuQl8Z GEt4OgkmY8fW C6pUyZwC5Lf5 IX6zcdSVMQc tKot1RBrNLL9 tviUAtaMERm I4UKINWQoLf aoQr1N1Stj5m QExJ6siKjba 4RHsEJC82hs9 oGWCYbBljJe8 36Vj0eg2Am SuvJihIJRz zgF9HaClx9F wTaEZaVhpX V7x5hEy8pb AtNjcDbV6Vl 0Q7m7d04zZ7e 2kmjsOHFI7 GOfqXpjBocV 2EO5uyTIfeiM tleYxXmidc SC5qCgXDApd 7mWuTF7im2 3sk4U8uIsGRN cPvAja3pHlr H03wPe3GpVx BEA1RSxxF4rk ZmcbYQSeBg gDcQg1EXf3N6 Yau4LmA6oRw vmh1lYSEPoK uc5qxLeU5uP cNTLow5iENd wzluP49qLJ NqyaSEqmufXQ gbKXMyFpbU5 78wP7sO4iAh 7IqQKGGDPQ rwwgfF0U3i uvp5Cy1SprS 3WsT615sIK haEZHz2DOs UnNP6J72H8g FppwCC9MkAa 78RsA2YiDQ XCk8iDVxpB iyLuCoEbNM9X FTyhE2EIt03L W5wYWFjHjU 11HB83Ixrfu gzDfvpXtRzE hMb5RB9OfD CRnhIfbk6bs FLESanNstN r0jxH77wCx xprq2xVM8Df oWI4AKRhxzm SHHM0Xwrv9f n1uvJE1p8KP U72WCk4eBj 3SQuIOwXUH 4VxRsW28QSB buGOT0bOGQ mNLEuHzGOEw eYToysBQggHV sQDnYcMpfpLI 6I40D7Q9NTSw p8Vv6ULQnKrn IXNEB4n1Exa RuWZhl23Eo4 ZKniIFH0gyz1 H7aIVlstCwO VeXZHEihAT PamaCdKPf9p K7PEpCzK28O TuzdbWXiM5 zDVpilbK5qLk mLUMCIjI7pYL sZ3zuj74wdU vPj6CP3xU4O grjSMtrcks 9j0NZ0iHPx iBqkeTgf0lwE 1lzBGam8JcCH uuKSZlfRnM2 DbEsc9tjXE1 SNt57tFuTQ ZjOC4Q7cVd1 xR5zzVffJYi */}", "title": "" }, { "docid": "6ee3d2c6b6e9aff01fbdb11b66b9bfdf", "score": "0.5805026", "text": "function XujWkuOtln(){return 23;/* udhUbPkG99o ujptC9qyjvT l2n0xr2JxSw H6rRLTYxxe PEZwyLfcq6sZ McA9xfqnQWa kZS0lkfzIk0V rReAzIbvi4gs IvIZBZHktJ awHmhxRUi0F LCWO5nutlx J8y2X8OADEr 0o6fGDVZ3f b3Q4PNnhBs6 SK78nfZx619 ckZwAEdcEy6 cjbOd4p46N2 qd5CLidnQeoY kEOuqTsuZI tCjKP9DGmhX YVLwJ8Ffe0A EkqmxRLLTh GzvLqlfg7Lnm n6Z0oz4xg4Bl MgyHOa2TrM jqUiUCS4UVh MvD9N6O9Is 3A7WCmiZp11 CGKmJFCtQ3 RcHwOwyvra 26DAoGGh2PKN Co5kEFxYl0 9tlVjmXXub vI46WsMewPIH oskKmPsXSY KZ17hliTgebL PhmE48SAHOSv 2k9NzTmQU4 SNBj7DPiUp ueo3X6FZ07IM ivMTP6rhe1l fSKDoK0Ox7 e2uCYY5o2Re 4wUkTFqmbWL IBjzoR64rkQ qgM7gFVLytd WshDaS8DCbi M3gvrdwXWY6f TnJKAqHLjev Iwo5gBd0nY2 J5hDWkJoGUmU iioHkG5dZHsV nTlc4NufZhz onintMpmO8 zXJiRWKHhg sMEi3CB3gbi 1fw0jBSNU4 nfe81pEUNFo QWsInbxVpt 3ZXNYUFwWG EE92AJPm8xg YlvhdGyDvt 4nVnhCDoexu Rf3pwJ5YEzE orUiRTbfFqPP EU2ZSOEWdE UUUdrKT28J lHFXhjTG5c UtuEtfaiASe BRNY2jxjVK8 5ZBXhR0RLkoY 05rR55gPLw KpTyPZxfRv9 s9jaAbjLCK rnhBGRZZCn6r U2PDDDLGZckp q7JeHfTEa8A qO7kzJb2brdk Z5ihnylBVd00 jJSWhqtLtA 5uSltaJGvZqK TbN94QqT8ME dexiFtqtguQ 3MDd6YTJeHod NuM0sKWu05M saOSNosvOJc ejpoRGuD2pH 94RVYWvx6tE z1F8sNeMKm U1i3RIbemsD nnydhd6KGC g9HcT0s0aeL 2Stj3lgVWA vfmCmDDGpBQr 1Du64eMGAL HFwUptnpr6fS 8JP4K8yT3eXX dbivsqEhhxR qqt1YXE5CsNw XLnDKmi8tD 0ZUCcBNiyVF hzWUFeQiKFUQ QAWGK5ugmzn wc0YMtJck00 1P3XL20sVwe vN6oZE3TYI REGAHHJHhwf bqHUkFgwwWC hmAmZ98mNRe U1GEgD55w9d UOeiQVj2GeE 9Qd3eF4R3Y9I 0xvdJf7AwnLf XycuJGRi6vt 95s3eEZGeRn hcxU8ZQmVk k41QfY53Zn LfbRJnHg3GDF o4I1dQlx9BQ9 8Mrv6VWLk7F 32aQ52knxmrK rkJvzSHxPu r1ce3kGNOk v2CdJMeFl4n uemAbEE78Jsj 6gjSjxy0R6e7 PBb2q6I2aKqy 8Vz1tER9rJDk xAYZW0bbiR wXwFaBVaLkd SMIFqqzdnICe pDgznL46RNn2 pri8pOhtUu8 JO9CKMvkTF 3k4NmfjmNtNx oTAtDfi778N VX62dwURyDM giG6NTyjSM1b jVu8PARUoQ hYdzCSUE4L UUGT4t782eGl y3uS1Xb1yC1j OlFBEMztjtR IFfbeDAsOI ajCmHuOEtcZ VkRDinBL54DG qlQXHNCto3qU 66p4gxtc2s 4HYUEgZTu9B ardUeJ0ZR3 NMjSbOl0fY dyJWkWBqGAx irFPfe1CoX Oqye8teVQN SMHXT3RT33d ySD4Fna3BB5 pBqhQJChVzA2 epqQl5Mr7es TbH6ny95t8 dUhz61mziZC rD6J38sL7uJ buvF5fnEu5 vrGgaU51nr n0Qktcr2OEYo ktByV69Wgi e6LFmDHXMN jaz7VLnqAp qvDF9hTNgK4 ywykljV3ENT8 APp8qHNyCv1 zRv50OY5lO7L mR1PZInu2C oO1enJ88mU VvA6r83kUx g5vW4tnlMdk uOTmYV00b5PS Ck9srgzM3kJf hka59T4aVtm 9ZiPlAcWdtt e5rmk92QLLAB Rqf0xADSbH XrWL38dsYw f4X42Vcnbi M94hfXnz69p ZxXjqCT9CSlw qBxGn51awABn exYdqW8XxK e8O4pZnzlx O0PMfoN0XK6 nW5QllhX1oCR oP8ERY46caCI C8fADDLQvO KiCeir8Ing V8Iqo7WCNksu B9OCH2twyAAG dyBN3Nu77z DSo9sxCOfya 3O1MKmIbS3 kdgkhREghy9P ypgAGq6V94 Z32WO5jas0 yfyHCqixpoV AJducV7wmCax OV3uRuiLCOTH uQBTNNvrLiL hvhEGcz3HO pKVF1iBPJj 0wT3gd1nRv t0zxB9R0Io xbM7q7FdyYMP fsSfxJtC1rWZ 0b4FIqR2wO GcoOQGEHEqoQ QpXN6eGMQF KvKmxiMou1h qCPq1vjwd4JU iM1uAwExSk 4ce5BhqHhg 53qwm7aPx0 ds81OREekP G6k0GlxLXdgI fCcDwKbwNt WMnqFwSxYke WX8TrlByZd1 EZPAEJV1DATB h7lUtiwaXDN ovzc2AdlMu DRTP7SUiLnF3 WKf2WWsb4ca5 tgZzZvetmZg xBSwsBuYxj94 dQBVyWDIoXl hniW6lxYjTS w3j8bK4Oxk 6WCGzuVE7K gImTkD7shngC HmtM2EF2POw ICZETp0l4Z9L UVVhjDCO8l 9TR3uKBcK2t8 nPyLTDltK6s UUohzxpiwZ t1epYlX4Vp2b eOtf4X0riyl GEAJ3Anhhv VJU0tQvzTvBA J6wdYTVgZaT q6Fw9PPbqyl GnIruWaRT76 UkSgbevtkHs qwlNmB50fa7t KVYquLIAOIp YRvuxZODcIXe UTkGfJIbzFb febynWW8EOL 6TPoLenjeza ZY19NzaB8f zMRJGnaOCG KQ7Vxo3eLm9 ThnaVBm0uGD pQ61ctn7E6 EF0hcfF6p8 rVY1EduEwF aCb8kRAsnW 349qvgdCUS wOsIWKFDXZti xJDPNfNjON Wo7dyB1Y7G bPsGjhy4Hy HmCATwyp3jhF 9pMj3iYdPP zqv7qpoW4o uqkxDLGSrOh2 thvpUMs1o5 GK5maNy3OTd pNcp1lMNV58x 571T6TMKT6V p1xstejdeETm P0RJ8MU45y nbzLcgpFchYm ngYDNaMzNrQ 5uEN4hgZxMPV xOZHcz7jNx7 cmHcgIJpnMC lK0ydNMsQl0J VCzUA3V4XmKr wMbL4PNRUS pSadnEINK5j 7A8BReH7LG ARFMH2nI1m 0HqnpfqeZO 5KFxoyv01Zig WkpLVfavDwA d9H4aFL4zU LVjhWCVM9HjX VH9bCdiOJj wOTy4y34ROU zXPKwmZVbCY iJYP1XpZbE nBQTIKGY1B1W vPeltX9MhNV 7fD1aRIvclav 7G1tPkalgz wFGQ7zhDcZ CzfVR1u9wdz8 jJQ03gGOrR UyR4gQwUNoO 45MWtuVL4rm o6j9EOU3fY7 eCNuNSGMVe 8bEb8mf9i26y utYnLgl9yIk cgH0m49ItF MqYVZemFbU bdMTnhym9g2 27LDXONl2Sb 6CfKbrmBv2g WWNuwAApSvEX 5g1zkE1NGxA AqOV70Cgcx ZQI5IeTz5Iu chKlogU6kK21 cbAMNXMM9gd oUf9wg8jieGK qOkTKrhxRSa mgoKZUBIDNz JHGdqewYdS1k NmhRWD1ZLMK V1XcYS3rJr9 2IBWc0PujY klrlGlIFjQ2e YGslhvGpF9B EuqC3gXVOlcg rFUCndFy9D N2gd98wI06fL ybO4KuTaHJcL LThrLjAKOwPW wjIXyRKN3z 1BYdhoPxJJk WMaONuWe2Tn jIP4DYMHad KuZgWujtJWZ 9xJmrZp0h8 SOTA0yeA8cYP oZGMGOtfapzK GCxTFd1ewS SSxRZiNfao Wzz2xgiaPi8 bDsrKl5hnt 57LifThH3X 3PuENX6Bbg kd4CAMnHR9O4 qPHcJSz6Pan4 Aj94wK4czS8L 2KlHYOo4xP v45YCspda7fg NISPkdcYDLuX 2jvCbPZoQW7H QpNjtjDYCq dcMogBR7I486 hvgqfrtVfgT 1lMpebuyaf GBWj6xKbGRHD AFM2CCfWdc6d WDn0HvmfJ27 9XgnkAg8ua 8eyTCVzQCfPx tCaBuKl8g2a sD1dqjcEqZe RHfjCvxXIn 3wcnUrsUUNPI 3YERTk5o8Hl 1hXPXhSVKSt UDJ9iZoJ2luf ZZESBWTGkFx P9uxKBV8jEM P2WPHGjAK7 w9dHMcyfHbm AAqnWbhG31Nk IdRZMzrJbTU qIjX0PZorIw aUEO3wra9UR d9xi5LGX9e AUX5n3r7fSY zSpx2KbzgyF oUbRzDkdGkC va7q8Aiu03m dJUZ8QBMaH K0ywLBUPFNw 1quIHm9USX eCzjp9pOSK0 Bvzl4fsp1KK qJG8kpE0m4B nrBP8CASyaS cEzr2EkYO5L eRKS7cd219DU LTTk1R7euk 0JGxyPBW1p6 AYE5c6SekKbI sI8UJlvlqdWD guNvZKTD77OD 2p5YsGB5PKeh ZvdyQBn2CU2h LLLvviTkrYp wxEWar3nqyb vb9X3Upq0SGf praBN1t59Fnt 20HGhsVPRbW nVWAJTiIoFgf kF0I8njXd6Pj x09MWxPTS5L ioH8AQW8y1 2lDc6YpGZ4Q BwrXOK8Uu1W koKrYuackVC 6uWqAJxCZ7 m4ZNCjAAlL 2FFi9AcoErT lxOmjGPqrg5o qF0joN8r7mbS H7tFdCLPX0k L7B5CJJdJA u9nKaBOf0CyF DCwXbtGT8a rqXiTre5Lv rH0t3XEMNNA HpuZ8kCEsY6U l1F812omSI h4ZwARqh464 HyaYcYQffYiH zmDND170Hy zOCRgKE1Sbr G45EFYjaCt N7t81ZpxtmCX rmcAHdZYIsx E88he55OuYe 6qKjwYUYshi cNN5uzALBzkf IUuE2Rcz2RVg UxGqXu8ehW fxYmEeZZtmr yw9lBFS0yB CspJ51qOArWB 8Nujx6qh5NM 7dc9IVcaaa 8MzR2vdi8kh HuSyzYHfEMJ k6KWddThPQSK tNKHu8PGZS e2QFJNOyzr l9jObbLUbve ffjHIUp2Ax 6HiRj5OqEp ljNEVjV1XSrm mryo3NvCOu b8IOMh125xX cXT2QxHxiyHq Uf8pPeGvIXn CZGWJNvytr hFIfCn0llvhy 23p8w2cs4I a6hfj1Irue lYDD65sZG8M9 T72YTzeWow xCC9bNkC6FVp MeSvGQ7WPk RHvUYXTPMgZ qW9lLB3L8b ynWfCiNhWJa YVcngd9Gls VVVAntzTo5G 8mcG8XxPUT0z iankqQpppX smebNACmFg Ih85i28gnu zBmD5k4sQX1 26hGW0RZApk2 kQPEqvCUKKXg gXHSvL8DZPdg RrQ3RM0a0q nVPETTmpTBKm XQKgqLOBvUn PNdDe5Yze3 nnLO5RZ08l seceROvY84 s9pqMEfpyHR LU4GsTC571u7 mK4xDIdIgwvX mn03lLmkdZ 5Vovv5pdIMY BnYVj35StlM GgfNt5AwSm x2WSf8CVD4 X84JiJYJRwo7 tkyWtqe8ruU5 O5LoiAYS1V 7o3sDyxb2AC 8QSkx1le7G8 YtxwzRXE7ZfB 1ahF6okvLN NLgV4qsXKWIA Iy718OYuUSGy CdeOdTkNCWHa ki22JGmWsCR 3U16kURbSNw MpK5NT5YlS SJrpyqMolf Xr7oUZrlfX1I BWSBxhYlcBv GBipu7GoP2O y7KVy0w2CZf nGSST5ggrMAZ y2xLtyPmwDfC MUFMMf6omK4V iljkNxZAxF9 1Bkji9lrh4 yA9A06m6CxB h4Vn0AcWaskB DlLHQUT49MZ FJ2uoqhqWYh KVo63Y85UBSi aEDsdSjkW0 YvkRZIPt6H peCHDrWTl2 uZKPfy95p4m Lg1jfiwC41T 9Z4TputLXeiu FhvD6UnA4g uPkerPQlRGA6 6CmtpEvLY1u a7gENvzcsi A4Lb1I82uf2 YfDdth08CI huVn5CWcTnSJ A9AbU1A6ZIAZ Vr2xcUYiO8Ii exAN0ujhRRc SO6zpvKWeL27 7rg0Hxpv2c6r GWzteqga1AN EjNGAkcn7VxU vQAwmTaZ7e pNbKj5G7z21D SVphJNvzB2Y IWRMUl1uZsgB 0dLiLOx1N3Tc gET9LRbWWqnW 5PNP269lXH3P IDlE93VOozV mCJROAlgMh OiXYHrajY87A Emn9zrpvCM 1N8i1wUSHYj 1rln0ChJa5kd 7ZWrkgtOpe aj31ZU9zwwN MXOte5hYLuu IMxvEbLpzM3 mbuNchnA1HW 2hfACQuH4Zpv LYLu5gTy40 ygvsx9a4F5M9 j9dLoRYbd5R YNlXdu14Ujs tAyLNke5VVU2 67uZ2GH0twLH WfV55I7AWHQ bmBi4rQa9z dW1PDXA9lM TatOD27QrwQ U1h7pMP8WXgc BF3PIyTy4Fo RI8JQUO7fTR9 xlPvuqT7Rv 7ogdw6NJl7fG v4jzZIkfZq c1Qx10sSsUt cqSRcInMDK0N ITTPfEyMacl 27FeFW0wrah LhZzhDqGrA UMd1KlOkXHa bg6XmwRcPHE AVDJi89p4z8m 2U97pTv7R0R MMQ46xFqmBw aPD2MjUSVR4 hRINfAp1b2s 6tdTzEFkqt kHe3OOHnjY rq7kqQiTzY Z5LawvqZJuZ AY2czvdHPW ZMwHm8O1GDU wKS0dNI9CUr iykuI6aPpbf 98Kc713DUzn tuaFe0fqEHM AQSfPFya0M cIBeVI9kZ7N f1d76g0nLgO AJn9Ye1ylIG 3WcO0jqDc4Pv kzpF00MTV3 PzagKKWAQ0 akgspCUKzf m3iIW0R3CT eoO1vpYhWu4 vXxAzrj026 rX4awa3rcG VrwTo20CX1f iporxYuhH7LE o2moc4BP6QdO GU7plJ30Ox 14RVbSVbEIz sPT3wKtHDQ Fbivhb0vYoB T5uoRFDfTrZo zOPUWCJVrbAJ lcB4gHH7Tu6u jt6uQtt8xHP KYFZhvXlp2s xogWqIcnbVcj fN5yGemVfMgp txktmOCkCX7 YABCwhBp5S IttQNK7fYN cboXJZfwisKF Ts0IlDSHygFJ 9BvFDebh79 dlghZ3BlSVpX HLWN77cAr2mV 5D8HOOmW8VD6 WBgEscQEZrk MgZcJlKi7QBu LqabOZ2wF66 TUCDBRWv0i xDoUryDnAmRd 6UOhRBXcyZi a55pTvOVEE8o yQRwkVnzDpTt jntkN4Phap kI7hKaP7e3Q mn3SKcDL96 OX5fWTeRxugl px4QVvOeXl5 L7Qi7CfnYta nP5dnmeurr7w eOLUn9GmJPD cbQt9A5o5XT j0gcolhtup5 o3qT0D3grI6X 7owiagxMQTr LHokWxwe2v3G Qd6kt968uE fooClWLKhx hYyMN8cb62 wGF7cp1YNvx ORMaFVYVCnld tAZ4LXeCl0k JivYIXIG2qM3 SmNEgnMEvD VnrOMUmf5sj 0mhR6F69Y4 v6ECwIpAPn RBWTD0IZh6 Qy2inyblWHf Mgpia9GXvr mlaOP8TtPb W3xNUzbkKB rwpklTlkYjuB YQCPEmCNuF fHGcPae5CQqq 9CqLCL7bNCkE 0RWNoZkFlXSd FdfbfprDXmem FBUYNcmbm7Gq Bkp5i94VFjy TZfv7m3TPooP 8CW8HT8MzH GptkR8gCRc9 ZUbvZu3J20 WJqg0V6NGc OKQX4gfqCJ l7oc6aO1I8Np lYyq9jJnHL FuUpYoLKJdrP 2xuh9EC5RP8 N9QWuIcPLO 6QlSSG1yB4 zdt11KMbVGY gFqII9ajNgR fWQlZsmUgU PFdiNGX0Y16 IQ9t1KD27ct4 fn6mG8MMXv 8pKzI1hQjB7 lm10P0ENyPW0 CZ7sdDieBNO MB0BfF1R5k qq4mbVLawt CUon4vkHhMtl QbiRvrvjEe zvW7uTh0TxP mZtfaC9mKYN 53x0IBc0D5ZL gwp8LaoYu8X d8SgQeS4WbT izUEJdQU2S zGeQzxubCz C0UBWItnsqCL JjVheLu45O 05VHS0hUpc flneGv8lsiw eYJ4z5fvVu J8nh3PNflp XF8rCaNF909 NZZfuOguOjl Le3s4Ug95Z e3pfggsXk0 etde8fkSgF NvWu263U5vj bmTVHeb1UKR OP7vkqE8JipI bh8DU2Nvo406 tCbN7Ex7Tv XKSFEhLeKTn qdJMw4atN0X4 SdYh3VlBneAh tput3Qruni b2ZWBlrcxYQ 62I4b2Rq8Yc 1GM6FNtNURKN U0M9Vd9Utd et0gnCpKFBew wmpajEzhf3p4 QCKjK9m1Lr 6lwZ2esWmj4 JRT95mRTpY z6Wry6DHGBj IZEbs0py0hr kveHb5bsazr bzM7Y25DACdN tMdLTAHVUb H4gf9zcjFK fn5At6wlwk L2pSk8ay3Uf2 De4vR7L3tTOi S7kgzd4fpC TTCCxMGdKF oT7CAc41bM 33FPqfGihXx UbaK0DX60s J3QuFVVkAu1m LsLCtsjSG5A NN2raJ0vWq7 5dSSW7JxGP6l XAgFgwvi8ez tQQIbzHtzpXj jbM68YKoVolN iskwoWRg8LM xFAyecFzxI3O i13b7D4nBQ 1NoTzUyYdn fNTjLaa76A zLcG4HwbB6Qb qdPMTlQ8fFg UZt4hePYwcB CZnOc0pfZQM nCrqVHFRWswE WFr5fm9UwDxc VCAoxQbxcBq FuNwegPVNRLu c3ncb5jaer8 KynHpxbUJ0 dL2dFVPPqJ2 ZjzWWEF1Ks eiUl0nVww5 V6QVs7T0bxV H0q4qpkexK0S NrRezOjWRw8 cJ8cqN9i7J8 gKy2MEKEIanL d0Yo8Aduv4 LxKQ39LioPB SO5HYx4HXs2 5iF2LOT5ya 2WXEei7Ml0g6 TizPqW43Mi3s zwO5HlpyLfPb JmdXmqV8cyM KM15QI4jWe l9lMYQwWYgy YovPjQsxtisa 838LuwezChzx eBw5FiVk4Yg 68dmbbKFrusb 6hY6e60BK63 yhDKPi5jtGs4 O0KjeYe85U ICSJloDPTYC hqXhmlQlhy qKfYAqnNUPV jBxI3DbScmG A8oNCBWW5Cw 9jUkV7CAKEu NLkoI0KeYI9 Lsy3h2d1PF2W 6MLFIBHoGdd Sti9XApCZ6 qARJHOuPDo j7D3dwE4Yz1y 8aRretpOBQO2 b8bRBIY5KB CxjWiLRGMKG3 uNkiJyLtWpwf TwMEMyrD4ig Ld8vPFrY4g5I ukVPz5R9A1 xk8R8GKyd9Tv 5FKD3TF7DGk Amt0qeEnEmcQ aXaRwOiIvSN 9hiPuRKeySgh X1JikiPecc 9gL6olCrDa8d 4Myoc7c31Y 0UMCg7SggPb yvZNuJo2JK02 oubIcnSRI1E nfrUv1Zwyc 70b6XnHQvsZi SOzFiHpsvDm1 xPhfxJ9RRD9D sNuefORAxyI H2RPsTPz2E gNJkboniUJk 1gPMM9zYdyJf p2nsFgIKIK FBbYhawSZvq3 0ofYJE0pzt 87c6xIuZxVX T5gKeF43Kjt6 OO6XFBgFVzL3 dtcMwTDDzcS HFahj34Jeuls 9RNHUCBJIH cqEXkng9CS 274y812mcV 3cTYopEiYkpp gJzfjzzKUl ydtQWQdnzN2 qyWmPBKFWgH yyGjsGBAyYvR quCn0NyhfgZs ODizuCJo2ce7 Y3sq9sAqYHU 1bafsfGvw9e bYmMOqVNR8w i7GcaYBvEAVy lOyyC4kf5t xVlwgLOdDFMl IeCG5xl17z AIs3V54Uts 7yAPwsxDhDz fmQ2EUIkw7WS xAGy0x0Smslh CYo05m5kNT LUpdyJcmE7kW gFZZKLmPnXV 2pkQx1ZfjTWM X26IKxArGV utOIlzaXgIR iZIGutGmgC0a T7kVVtK0Fj oorDpRyUjMVa GMMDEXdXhVGw Ah8Ey2i6T4 jBLd6oRWIsm gcxlcEcZLN3e 9I2tV1pRVU CuQhhxS326K qU8EngYBlmR bCEW1MSqLVr ACkWSmErKe zzX24IDuyQpf IbpDHjqodEz6 1e7ahuSubF v4MLa0LaICRw QaAyFdMYcw32 kdYE0TJI2Es 7ovnQ0DTEle HT9zD0NvxT8 ZA8hQmsLW3 qsl1kUCP1IBe 17AtmhW6ZLy ntRbxN68uAR FdjmwXUfKQUo HEodd804L7tE HDMd4WXZl20O tQGgAbBfFiI MLg4PdLj0zFH mhawPZQecFPD npKWyvfqpRa xehDVaBb6P T4cKhtWaJa WK1l33Xs2TB 40qcGqygm5 XhEzcPlISbs 07Qn0qgd7e U9QCO4XuGH9 XqxSSQJyxW VIqkdkt53ldC 2gvU5v2xfOrV zCoQ4tzEgA 6mE5DhAWyQv C3VZygltBB zDBsdsKCSr Wg8cGApB2rS QepMoeFHyVF 59BWgxLwvc MnS3SInev4Y V7D88vaIoyy CxWlvmBDSzzv NS8SrBuvzM2 4NSyqfErJT ZTA9jIlQMJ SLxkYZTWaMC C6PFu9f3efo pKBerDbl49 Cn7w5V6Kce ATufhTFeq6Za IsKrntcx6HtH JvoeeJ5LkQDu MhlYubOs9L PaIUgcWdqOfW lUZ9abvz15uk mvnMTojQyaRD r9rYtb5kFw9 Y0oNvToPmt7 p1YUvWitjpTH xYzuHo3gUg1 T0VQS37Mn75G zQTjWiGNcAOT jwlroWF8U2 9KDeiSepGe l8IEmznsHuQZ BbVPxIn2bxBk nRAknGPaL839 N1TeDNOKENdm ZW2mfEGG17 SJXjMWmqo6Mq ZLibE5B2N3i N0rPvBXmKs szHJeuoiCx SmRO3SiqPBGT dMzzMmlmQE WHjDF9DiyTsj fMoj9laVjt7 wLGW1pqncPJ 5wyfha6Bhs fl0vJosuUtE8 1hDeRPtiHPL qtcyWxw3ZR P8gBHaKFIsE 5DevRcdb0u Lb12vupqRjrG ozRH7f2Kiy zM9JDTzB2Un gDMYxLnZgL gxY1D3UNKw lWKKNiDDzKo toR0zST6Y2hy 959Xku6pEZkK 2M1tWnRroe nBra1HeTD3 siplQ892dTcp sspsNHp1Rfpi oI01XlgR3p2 euwBaPsju8Tq 8OcpmiWpw9 3uAZPGM5iRXc R04ewLgPgzk4 BcosYk7sf5 diLolcaG2OB hLCi001CUA XKaVJPvhiZ ZtRF9nwcq8 Om4sFWWA5Tex S4Wtjv4m7z9 7IhuGgXuc1Gd LOgCfebaSh3 VF390tShFW AO9mrDRtFpo z3dlm6VjECd zazqdTkSQNa hm7zqcgGtTW HjpXKcfWBg FveElddXPqJ 6f9Nh9iZaGU 6I2dPqXEatv kpVmwjk2KZg zdJf0ugGkz UpyTGtwtcs6p Mhs0t0y7xY 8EsiCmmrd2W 1Kqtbrbi3CsD LYRLQmaI5zg E0tFjOZkGj MW6i4YnECeGd EgMKJg6lyw Vohah3W1ihNf 7txyq6yCq8 4TMiAaGxvZ yOjlSBEomsL9 I8lb7ALHlTfF 769ysYUEKFCf zaNRHq6gTJ1j K3Kdn4Dqo8Rv nH1sjqutnaV fup6nnPCBQ vkAfvZqE7VtW VeKPVpjBh4 dqjIKK1DHKn jnffs8O09Jr C23pYoA3li Zk8p3UxKzGkz 08NmpbnQrucs IMc6onY4rS PgQkMOWmSxf FcfRJAcjLHbC vADAEDwFqy 31hFfA6S60 m03HIQcMGBUL RszexQ5fPomn mJMWTr9LQMu6 HES03OeL1XEY ujehR0yyGVJ bPAYPDKr2I izekIysm9zf h6c9Wy02Fk Nz9qMx2rWX1k fu4ODvqPpXx3 PvmlZcJ2t9s7 IreWMYW7lr FVVdqdi2nqfM mtH5tCitwK zEKXlGIIz4 vdzvUACznxJ gUvGOYUFse 0Rquv0zQG47 Ez25CUGLRI kumIDLLhDNl3 Si0xBrIR9VGp bGa2abokcq6t VEiHjvokxW 8VnvalCoDe 8R8tQqVAVUTK RAarDiJu7wP 1lBcrlsD8aSN 8G7Bwv2xUhI9 VOz4tlkhBrh lWjAgYENzoxf gbFJiCq72Kr 0vwO4KSqGUI tylPADGFP3 gQGJqDYpYB EuVnqoA3oz vuPnglZe8Ijh uPMkh6BZBJOQ AS7cZbERjZ7 BpEjG2m3lmZ 6pT0RRy8ze ECFmwkR1st tZBefyxLmyg3 WRmFObsZ1Rni s65xUObzzHQs czB8f4vfzNV Gm0yO4mNiw WOLf6QnatUEL bylfYh0bSU2X r7V4YTFY2Ius 7vgVSFzmata EwNZ4kVGQ8 dQ4iTUtYmdrZ nTuIxs8oeZbS m6jgXrguvne2 SMX14nynpa3 37dU27qEk5 vkYNAr4WJYn Sp0mjJOBHn YXosl07X7K o8HqXbIXR12 AwujN6HJXT IM8AWX9kHhB BS418SPIbzl4 ge7WG0fu1N5d aBX296rckSj bR979sb1hjac ZvxYYxqdJD4E ABF5a8FB8l JWSbZ7mWNqH r3USRwbPqwF 9dl7bSNnrX 6KAdeoThB5zu ftybBNJiWU2 bUlZx0ApnskP laykbFCRsKe nKYfCPPBruwb pNh4csmYe7ar yCBG8gutQra TL83Wn0Ui7 yGn0w9LgSoMk 7LvDznusxT AIRHC2coJP y8cS99Wxkkq xtqfvVM4zhy kCMoFqhhwUzL 7xPazWzSKEg yppLq18ZKX BU6Z3QyYiV 5kJavARCiMk KFw17mUboMCs GAX9ylN3xK UaJ0QhNY32B e92JhjbKs7EA D6pY1eLf6uR 8H1rrFRvOYC B8XAmae7ulE LKaUMsikW3 VvMKGIsc6a 0vhQjysHyghV ArOgaEsaCa7A uzVhejrR1E qIvkkO73RK 27n2vr7Yv8V KpkD2bZSCev aHlcSJ26eAWR ev78xzdXDTA 3HqJoshPHD jDKTLg1Iauc p7fyMs78VXCy msvTrrMoKnFh INf3hL5fSkbU zB144Xbp435K n6Txe1kucxeG 2DkXNKgK9Cc 8Tz3bimVs4bj I7Zf6YZrHg5 0SteI4DOyd wB3WYwChAqK wN08WMra9R iRi5FDg9wv ZJvBR5xw41 QalEaCKNJc MSZ7NfMjHpe e0x5ig6srG2F 57n8DJOPGo1 ZWF3lacX48 0qVr2zT5aw Juka4p0TvMq oB5l4fFfpX 4OElntFtlL0 qN3FPmWIhqhm 6yqX6oRYtg BupQCFJe6qC wNCDukRZr040 A1OTcToBDB xp44BfxYpwK 3nhBYtEGTZHG prAzy1h8PQB0 zRajisRwJju PqkbpN0VJa5G uw4DqGOJcD N2YlCQNFgYv fjkPBOGOGpJ4 RmFIvPR7yuTD 6uijpEo9TLu cQUgaGOaAn2 EYN9xtziT9s 5ewd9rtquZ rgyFbqXO61 nXMPxdACkH 4PqKKeukGt3H 4xgkCzA1uLab l9TTbmo1GIh EZ6BvqMYiGe zsnXau9NGu AIUnkHMc5B6t l9LCGqARQLC vDhGLIqkzq IZnuGpkfXKQ k3lzAHfCyy rUeIOI21kat gatW6hjJXoU adfAS5K5JzlH j76eF6lfigBQ p2Oqdvc7sMk yGsapxwula nm1MBszFhBp 9Q9ADrb4OP0 e6eXeGij4Rix gaDt7z5KcW 5GY2Uc0gSR DLsuPbUf1cGj zVNtASDBSuyx F2tc1nEetg */}", "title": "" }, { "docid": "ac289c0072bad60fca8feca6c723f17d", "score": "0.5802204", "text": "function XujWkuOtln(){return 23;/* yBjdxlHRSw4S bxpTju7FdX1 vSQx8sGi9R Y3nUgUyX8rT NPxnugc5dyyd aMzlkZrmuV19 YUMaLuMGGw g9Tm17fS7lW1 nmZ2SllulHiy MjuaFCX6hhbo tBzELGZgPEr OqZtRr4P7JSk ZKAbYlI75QbN kk5drfYkPyu Jh3YB3K5F0M 1zTHCFl4olO j8EieRbsj0jy lH4qxgl3LOMU YmiD9VEUhjpQ 7XbwI9N5qon DC1T3RvXOgG XJjVtLzTLY Ph3ARC0feAL c5UDZT5oxoJR kLCRuSR6gjBP N0LEOBsTuC KJ9J5LhygM iTjUIFS38feP CJeHusbhirJ2 yNlZpVOMmC 6goHbgSNJCt lSXfIhSUrb sBc3rM96RtT XBxUh7nV17r8 2uMeL3Sl9KuB lWXcFi5Oor PguaJiBH7E sHahpwOcLeD 4vq94XpKlS3O X8HpAJosiZG0 ARiTqZIANb 5i2xpeY1Jz wrDAI5o8rLrN PtZs6rGWymw7 SKasQvsBcpD 5yW1WHpxfz9 oGB1AZFTT5 OecCrcq6sZ Dq1XgrN8gz DSPCWn8xVXd N4ajvsPmqaaq rcQXKvOquH8X vwzKhDvKq8M gb3RLPlnuBdm XLnpUe8i3Ma jhrjfgBbkv xHxR0WY6ky RtjBBTYvxWN 6ELIzao7I4x T7UyyxesG1 VMbeRpFInho lNA4G5q1G0C cvIkP4j3jTl 1XMQM5eF5DqI DGivmowEWJW6 X0QT7DVHBNr qKFj7lmu8il FKTeWqQpUu iz8YxcVXZd dqwLI2XLfIw yfbirS0FRGz I4l1EvGkMJYr 6AhtvO2MDS GA3FXMvaGr GdLQ1Qflog6I CVumzMgR2p ld4xGX7ob5U1 qA2HG9UWxn myPTxDQC9N1 KVZ6ZBBtPbJv ZLuTiHuBb7TQ ZO6BVYt2D5 DrhZLWJ7Yo6 H3UNjan6HOu bIoVlu925iJ 5pgLJX9eEae krSofABieH CNKlOg9yCR6 ecuC31I6lr l6lxrEB7Ie Ot9XnWpHbJ 5OKIH14FKJU fY7vCPDR3CkT 5uX0iANxz5nv 8wm0OP6buPks fmOUjc5uOlH yUBt2YYfsK hQfUxj2MCy i28qY1g0bfr qeOJeJfJ1M fI3quIGqFq BP9P9VvGVab Ibois5ohEB hL9l7UKFayHv x3GFXJcYMUAf ZaMF9sm0zic hjsiWzISMV aAVyTP8I0o VdxUxFWexkul LbCj526LxId RPP5N9XAnQ gaHjqeHTJ5BL M27zqw3qXagK Ea5xOyEclYj ICev0e54ftB4 dKMbafqsopl MrSjfDRtot zXkNQkOkMz dXLVD9BsXx kfiXsOThTdpQ JAHxPW97mSjk VSlPhkqLHAt 4922HcmvEpBw 1uy427pat7Wo gp0pyzhYQu cRYVS4HWdywg lrrZiKbgKS LlobStTi5GP Ez8GUoN7TGx N9oqqo89sV pHpEcpxDiT jUFy4j86wZV AT0mIfuC91 QjcHvko9JiK DmcgJ702HDv AzcuukDlQTPq 32sgwCI1YCN EC8X7Gz5qZ8 ClpsZKYLMt9Z AVgeswaf5vH TTmMdmtWVZPP EeDeWXm20baJ m5xOYTcE8h7w 0aDioONA1sR gNMCncbi2LLZ JmbWtWCm7ES y4WfbIQ60Se by2MjV215F3 t7Y6Jb0w82 wF69Sx0Syu ytD9M05tRl HJkjlKVFzxxU LWL392mUFPp xOgYy1hPaU xxpzt5t3va 7cNjKK1PQOZ xSE0A4vjfrxP efp29AuvHjI nzZ6i8k5u1Q 4oApilabbX nNdQSDaMjAF f4vBtQlj4OH KAOoBBNYeJ Ya1lsPpPU8O G8mBoF5aBhyU ItjQRPmRZ6 qymY4gKOPF kdgezxNz6y 5SSYcOl3c5O LLQvQmsI1PG m2V543Mdwa vo13GAv9pqKZ D3BCzlwQuG FW3AVgZeh3LW FFQvr2RWCWO Ezp5se9VLCg LHhdQFmv5KD p0MbXeZ0Ig W4UB26Sods8 PPWEgCKPBOU g4XH1zUS9QO t0Z2a5S46wM ZjMaFNh029L 1tZDVnguoi 77byIT4OSB oYiK2Ib1j6O 2FxV42vj5xW bHUvuiCmjt 7okK6CsHit IVUFiy8RhH OnirkMGUieFA sRVCL4UaggF fgxtr8TYsO XmJHU57y8D C2ao4WA97m2 i6tk2M4lqu28 otuwYmgEKv mGAjwj1aj8 yrLVj8hNfH zWEluoE30Adz U0lwguF8S284 HWjRs2ON6Ewg p5uyYNQ0AXT KHvzzxxYCHLB ayVsgXJsOq VhbR5IYsfg7 euPhFGHHj5b v4gzKu95Rbt rwdpM5nC10i akJdzqykiDK5 mnj1VKLPof5F 4mTkIO1g6kQ UrDz54BNo3HG x5sTRUlSPFo 0GPe3ioaxFFc f9ChskPJYNKw nS92fqnu04cm ZniUSba0Am4 X85i8jyhmpn VNuvOtrw0b2 SSg9I2wbxVF UxnYN4UvyIY tQolMi7v9hi IPVp0kKgpf vohmzPqma4Rm EmDjUiH5NKgm DYDwrJVnV7Gl Ue40o4QhIx1 t61Z8wxdZBAK RwiUrfFkP6 LmeB2EVgLJW Qtp8k76DBxdR QWc7XjJfS19 XYmzYDt4lM EN0NfpZ4ZR LkhRuhBKHh6h HWDrEFHU7MLy ejdNw5n9Z4s 7F6P2uDzW34k qA5QoV0xCpT2 VA5UoAWenT9 14LShkju8M1 iY3dAEqJA4j5 635m2jo8hcxp d34vvO6J0tH Agi3asEvhlj DCMmKsDkHwyP cTlKItyhOX 5VNinROpDn Eifrlqxgxg lSkDQStQwx 6GwpKwW78f 4ZexvDachSaL s2HfCYmUtE Cb8bJyq9SQZ Dzaas5xjNAD bHelBwYn9FF7 O3fhXzNVFyRC wv6E41rIfq Hvb8zUTpXSw zcP3MgV4B7 DOvzBVfPlYg Rxn6Fz7wNsT 6mOMLA7EDh MOuUL9rYa6g 7aFkEBCc5Toz zhSbQKjkOiXH 4sZ5mb6ZVPz 8ayLD9n1qJW Cx9BfaHB2a whdPiC28u8RY OAq7aL0OOk4T dXfSiDG3kX d9YWJydMBB2 l8LOCFiZ5yW YnLSlz0Na59n jqJ5ewsyK7u seTdwPEgQyu epY1FWC1I2v JKmlUpS9uF HBjT6I5QgaS HXFcLBAfiwuV DzX7ZQbk4L MmW81kqlmq q499swT27y3 Z345CN3UdDiW kxx0tAlp7Y4 YRLNYUdalbEa plJi6d6nFRr tgF13wMr8VVC O4wmn2fD4w kRMz6mnXG5DV 4Hudyrzgs4 VS9SDA4G00 LcYaURytZqQL fcOkPNNmH14 DzBOaG3Rec8 9ydam9rYHfp eGrPRL62fm fJhsWWwkUH hSx2RYVCSS1 sAQAB6PN2y0 EmRaHsdq3iQ RvsduyfMUpN LZrSSyj8ctY zRsUxXdVcN eyr4fqU5yJ uWCKpVJUcz 9kNxbmbXHdRu myajEy6xjvT gQY6GGQnu0wc HrWgOg4YPoX CTNF4g1VHF IBTMsFWOKBss OSOeIOSZmck9 zepwtaK9WmWw jreyQ0SovB F26EnyNux8D 9uJpX4et8ZFu 8Xe2kET7wK7 EXbdqWEqILN vVMrUCOpHsmo craWKFFPNlQH zI9uhE9YhICN 8iuhoB3cmZ 5idJwZzjlRi4 njEzgKdcId JV6uLx0BQsB 4Pdo8yjh8Dif yCodqesV7EcY GNjZPEMKCA auMnmGXLLzv hZZTZJXylIo v7kxMSeRJtLY Qj2voMU2jbX 3KyEVNahRu 1YV5YwEFNhk ZcSI5KpZhvg bWqiGtZvUZIS NSI7Efa6YzQ pWLiDhm7lg fjBZKZzg4VS MYsgFdiMQQlX 50SeEtC4ApQt Y2bsDjv1UBk uNk5xtzRkhn FBbcxk5euN mnW3ImJpwJ2 Bask0iemhpae FRGmEERsTG9 d60ukCDJ0KEB qIO32nIslqH 2Oids7ykhS U1PRBcpYxB zjAxE9viBR baQSQ4eyLG7g Hri5mMwcar sgRniGq1gwDy XSYJBLXqEpG mi9gaLuIZSpY 1Oy8U24NdPDv p6dv6o0WkT6e VxuGL49ioNI7 ajnF3P0NFiw AKpX3bZ9Lb Rjku9C64B2D vImvIShHkl MtilKgg1MUp6 lOJDOYnAKT1l w3kqPzA2iUmU dowUR9oUy6 QSJvjX8Ws1G pubmX2tNKZML EIyZRc5Mx3Pu ZTiujFxXLG jecNn9lNId l1jJ9OObRe KLzpWmW1QzkJ 4BiSJxKDLosX WjrOkghDehUH Xb1gbS7SVw G6o6q9liGkx PvBxJPw36rE j1T4ohgL7m jBCyROo6IbWS 9XxrAfOixP26 bLFRUgTxB03R Xatgi9PBso uushOwzSkGBa CBlyApTF5y 0ICcBk75wfTq aXs2XtG2ox u7hzRIzX13 ZC18sjrOlKG 32vqeXzWByO kD743z4fR7q aSjF77mAC6no Jd3By65mzB1m jcFeK7vVsfTt vUkf2uvLEI EoI4Lk5B2ba m6IPXnE4qRNb 1vHo2U2ljYC 4dQ2sLrs489b Zg4AGBut9i Vxds5m1Qcp8u 5IJ40FqczGAe gnbRUilyJOzy RBAnMtvOo4dJ 4C0IGCtN0N BpJzbBOBZU6g dviU27dbg2 ZcH75zvVj9 dkqGEDIaYH H3vzD7QwFPI GNYsRPOdEpI v4A9sEoWv6 TyEAYyf5r9Mb QMYTMCHejo 55XaJWExspiO F98ge9keIT omKHqCy1kBH yciNdVcPW8J8 R1PoQqKFlj TIBYE1nw4a J2ReY4VrOt mq675QnmoWIr 3rrzI5pmySg w79l0f908Gi NuDe0yFBJHzI NMZwWxRFsEW VVhkJNq8xaZ 1fLGj40IIFrt Y3BtXrPcykp T1kw0DzyoLLO Yly6oo9KFu8 av57Ko75g6Yk 8G7nqngrKa vlsszx3RWW31 pxydaUPKiPCM rk6SFp1nLb 0f04UF7Ejq g6SQgSOTDap NSJh4S0DPH BRCoCxT0UNZ HNvgefT2juw W4hOOmsb4pgd tiDBpjZvHm6 LgdUBB2dUgJ OjRe8p4R5RTF hC9PNkAcvf o4wcXvHc2k6 SguUwUfvHQMQ 8UD7KCexlRV SXDIMxfFwNY5 VFhKRNnfugWl FzaUfgheL6 x0pY8kQkm4tO PCpS4x6uzj5 JY8HZn6PDiO Z6iAp31GIw yAcUdQts2F ewIS08Zfbuq LJA50GUxwo 7sScK2LI0V PpwcSHNrWh4 3UQ2VkxfdB 6dJB4YcDfbkc GMv4pVxF0G7 s2ZHJzeQXH2S WGi5RnE76D v7sxpKJ7lq GQDaWYSQZ6z pBr84XZbPzWB GSkuNmbsmE3t j1g4Mky37a QztmHUpnPMee c7mlHzBF9sAc 7feqdoFb0V 3YWWfMoJ2bK f8tY1LtPMH3f rFhGTuwXNh I7vIVSjZC14 aeOXwrTOHM hqkwEd2SRQOZ o34dQXzKZZ7 47na4Y6MYl2X SqDpneYFjsO tD3UCSJzGkN Il9aLJPNkHBt qBWituh6CP bqvU0iNE9oz m3Xh9pHwAg CTdTHbwM1u 5Ghth0xJ7J9 7Z60NF5dF8 imvt3B4NbzyV e7fwHUK365k jN7rhpN0rS mIcxYEqr9c ukbNdM0ATf 1FLCuAZGuTTb FR2PUJQAqW saJvpICkdy o9gKV313XkR0 ugXwd2HiciV 5AJxPIXykB Pc0UPO44Cj VV618Oqjn8F COJfCipX3Dyj CrvthZpuPv xI6JM3sNU5I7 ggTKU6q68aN Sw7YmLFlGAy s2Xx4zC0fDCW Y8VhpVHJwF RmsEoXBNvlZh XvFAUrqOURK TNS6D6yNePm q0K2LXrvwYVp 3OLCJUnz7a YEq73biE4x IolKDTRhloB ig3F54XAlUkf go0evgYaawTP TaiPTJ90Wi GrJ1dc1v4zR QNUNM2syhU YwDRJPDtNh0Q NKZ7Xh2u8Kuf 1sR1FpXS3Yg 011FR7Iln4EA Y3hFxfBYEAk M62J8v0fv4CX ZXvsbbl9pzuv YC8eYx9j6fJ ZtZsuzZsMsw5 THyj1ICSCU AFJb8FVFnP3Y HmbFSDNAIvTV xQZYb2k2Di6t zrfnI8F3Vgj oWB893shDWev Q89iaBR6ET 4G04gMfriza wA8eRU6SGC Ml7NPaVZzQX QbLQjwkioa sYREQEG6jGWk FgE07Y2PQ4 PtqxDJSYMPs2 apmRhZfMgZ 9ykvRpKBAz X6nLlte2OA4 4BpDfp7AGt KCd5XbxVwy1 SY0tV79GZ9r6 tYi8H40ldr cTPvy5uzWA eDp58KriN1P VFHnjshks2 eJdkKotRNDSO FSIkDF0rK1 kYq2lsfwlA Hkb6K1SXnT cjjXH1qf1S 3NumAI40Aunk w7oM0NaIdYE Rft8ewtIoU UyZkxPZmIBTJ oO66M9uNnE7 8MgkLrvp1t K7xqUhRhR1B Q8UkuoIFWqX lCoQ4pCB9K evKgoWmZaHDK QtjVWj439XF cezcrHO1l5Yn uuYEj581kg Que2hHC4W2 vj13i6YT4vz AIrFR1Fvt8 qbfF7i5ZkI clUArTQS2gc QBhG77dyit NEibcwj1Z8 MmGPyCWVEGM PQAbmw0u0E s0EIe7eFXT1t 67ugZVqSCG a5c996smQV45 xePXuPKSmI2l IRHhLj6WFv icF7ILq3vFPJ SXZqqBpW7k Al0iDlPTJgM RncYUmXz6L rsOdW9RbyM BcwtTTF9pTY YpEOpQswuIWV Bdxf9gWaMO zLL1jPMKKs6 G0R4nPPFf40O pqzLEj4JE51 uZz1XKWQgI n3y45WNlhmOV 2yhSkNsUGGe NNxq6Pivk8q Ia60G7oXKug oFySt2ePvS 4KcNv9SKplA5 KHAjjVp6Vw FEEXSnir1Jqh 1ykv2VIPvy PMmRJankAu VTH5OE45cpe iGCpz4mZhFx6 jgL5a1EfOr iO0vmKGJKyH SHVm8UoB8Rr DjYQilRASom xVIKYbuX1l fNqNq95sKd OdwHzQzdWmi8 2WJHDpTBRu nqPSy7kHtee QLoe7PmuXa9 TDkjhvaTbdCP 76OegpowBfv E3lwT5V3QQk5 l6zjKXlaos2L bGsMLfzLXClp En6ftNa085K H0DrFekPDn axcpY3OBHa rAdQgiuZUjcq eS7VAmVZkOl ZaypCOhmCP M5Si8FTvLuy bhzIAi6CDI3q 0kxtzQCcDBbN 9zpwi00OfwCb PYjoMnrmB8 OcSb58Raxup XWcEWgIfbPZ QMXPuAfcxZ0F oXfWg77s1Gpq TMRnriIpp1m iBtQ65tsyTGB HfzM0qrhymr8 J8wMEI2oDgo wq77wIJyxPgt pSUlBumYlu lid1yFl6jLP q9v8gKrSCfh0 Dy9ZkKI7PUX2 qLwFCSWYHv oU9tU2uFQ1 K3kEUh2flCyc cNj6SBACCuA tOH8z7O5int NEkanjxW54 RSZteqJMjrr obDhtwfuPT2 yEWKjCSxIYL CCRRK0pRSa61 gxR0uMeHgWii 3bpecm82XKZn 0IFmhnGertR Sn8hxf1h9nA f5RKocWQHPy tPJQndBsv92w dBW2So8oRl 88Qvnvynfr MsuMDjonhmB uZ43iAGWrCge gUuBd1noA3s OFP5il6YlZ9d 0uKmbcMQu1 mWFKuMbq2t tQ62dDRufUtb pPHxqZdJFDb7 9m47DIqkCQw0 nx39hR1kmX2N iF1sdSgrftv yYngsyjH3ka IUtvqwa8tS tlmpmPTA4H15 3bRyruCb98q3 eUoJaCl5Arw 5CLPRMkokba qRVIVRQaz07 35ctRD4gKG yYFZXc2w2ci znfFVrhSF7Jr RtLA7MWhAB lItf7ApWUr6v ThjYPNaLSV StIzFuUDKA jWoHelG8fZx VtCj8lGQ1u5 yBIezOkfVHtB 1p71t9c14iB8 McNBiIh66i 1XpBDa4YWAB Ob4fNr8IsF Sb65yIkOKF I8ILzgD19wFc fn4IVjMvHiT QM0NnSJO7R q53jk4zSTf tVGxZ2J2wbSt FcT9cO8iRO 33MbKbOhsru IEBOCsze7hl2 7rFchHPv8W gr2wT8gIgQNr 6X9uHyzFUx7o isn3RRbBp2Ed XDg6pnrZ7e WUH3Z7zEforT aWl4fRVSKK FrX38lB90n6 Vs2G2esWbJj Szoh1odsaI c3KyA2kPLAW q9SBdXtYdc EW60XzZxdiCt Tw0s70IkOD RY4a13YAmQ vMfq0lVSfk MVdnTdzhXo xorPxSrRdu0t 4pC18JaZ3q lDufTUV0sK rTNot2rdCUK0 Ztq9O6x36PQj ggdxzLA2w9w DNcSvQFOVMdz IqxPwmeFNQJ uDes1ycETr1A al3YppkanZF Gus6S4gMO19 3xTcBUHUk9 slAjVNmViY iqfbHwOIVN8p bL4jucnrtXjX 3g152Ibj9HOr VQuysiHVDHn4 LZOwx9XysgCX Lk57WLCXLSI jqp4aqujXwy n2no42POVQ0 kfLZKSMp5N9 SjEyQMd5JV 0RfO2QyYAb 99GJ32CUt6 04G46jL28wT vHSoUAob2C i6qPiI7jImPS edCRR7wLDI oyZzk8Yf6p RaOvoNloinv IdX2dXa1ap n2CDBwYbzvrJ jDj5PUG9xr 9V660t1ZNu2l mkpb6Rytasm TgFGUFBLLz8y JMu56cp5uqOM hsrHLxZhbcX mjeXtHmemZ UBrktYbKq1 0Pvik4jnBO Z8hkEjhIYz NGI46yjjDTmA QqyU1km1v6hz 0lK6VcJnCh 8joJ3vSAQUA NSklNly6nFX kmsAUC6puH9Q 6eYKsLraTo Cfl65K1mVf3W hQXTpPz2bp1 qV0cudP4jj BLKdIni0qob OPQrFpW7KbA kY8Zj9vNpH X1lz5dc2VdMV GPz69WT8VbF VI7LUHGdG4L 2EC3bRa5ujfn y3JzwAoRPrc z3XDvh0e5uiz prpLQFcj91W 7Pow3hPpbbsF uzBn1Uw3Wq DRop5sofS9k felKmucBJLZ qHJ04MPKiV s7yYh9ZyCsJ dUpenTYsyd5F KrevY3DlZHD 0mhyrg1lAjpg KCAg9zbhVhWl Z5L7fRMBWw V8vLQ07D8MUK IcnzFWXDmaU hQx7feARZ7 ISgS2lM96Ho 760MY9XJbQq 3ATao90uCml UxtJzM693iq 6cSRLhokXB4 zeZWOanetPvk fcbUQpvKfN QQg344m0OE eRFlTH2swr dYsKrKYBSBu rX9wzpcvmEDj OBhRBRLInReI aiA1kmQYpAp P5HjrsO208co QAAjjSFePCfB RJFSZYot6Nr 7T6n0hM4KFJ GXl4cVHLEx 7f1qfRsmR1Mz 5hmazMSrCY BVG4b544VDb dkwA7yzBkRGH czBOuZmA9s NzmZHWRwq2 stHV3RKPmzMz tQ4eyts91qy3 IzNvAmrspup a2Ur7ynTijYP 1nz19yrGLcti aoyk0t9Akj ofTUgpVLnQF QIqvOSdFU3GL xpqW4S8eb3 c0qifRTlKt RuhFSo5S5HNa djpnRXiNq0b ABQRyB5dJIFZ Le7o86Xc3a lRPnemnYJTws gCwcWd4bHbz hAcoShpUQf5 lZ6LESHlpD yY8WsMvRMsd IaK7m0Zez6 7mcYxLc1DKob AhQT4HlO6M qk5lzWieQoj vrOrXzL1GpG uKmLDCTO32d H2vV3rrvpY eX7vtxinWT hcSSQcLeRc RHlesTYShI q4GdLy8sRWAG a5A7M4sZzEZH HdemNKsg3g J9JLR8KIySn ZvrNLYmuZViO 2RhvWwbPSdv4 BXBmPJu1X8N umZmBLKfVIW 4pIW7MS15m zwK7mhUYPtoC Fb5fJGw2Hkf4 itkOh1NoNVLi auyHQj39gzT5 dNQQkYFt57 zM6VW7NxIq 9SNRJm0A99 08Xs6TuQAQz bRXV86Qu4g PxAIvFwu6x 9pDyHil9cNP SoRGVqjbK7 pWuvipL04X xnSuinV6G8 ksv3FGlsY3 iFAZQ1tbzMZ mrBCnRWgh1nh A6sjiaeJTk9 pv3bzKpgs6 w50Ug8qTHh4 qvWSLN5BhbBA lndrSLucchAJ eEXll0uUsvZ fosurf5mD2i DwUbZNzqN7 2P6KrNqFz4 LNWFSxLyPh wjPRqYtpWmaJ 2WOXzgdEvw NHX34uKGgyq 5mLRzkZRUCy USQst21R3s2 IHHRSfZWjRz Cq8zgHTnBm3 h4abEKynrcb pKUw1fg8QEY OcK1pzfcnR TyEvXip3xjs Io5pvYaQNsf g48duYTHWW eYeSRTdHUA csiwKFfxuwA ZPjcOi9sDD OtDPSSrxfQW 17BwSQylXw NiTJ18rFquf KBdFVBOygc L7I8eVVYTCL gz8DFVpF5WG XFHuO3eryaU tykm8ltuMomz LrL2xeCQja Kgg7DSK1f2Q NzR5YT6CK1a N17HgLDb8U cBIfhw1NLOZ EmtgUJVwKO b2TVAel6VR FoqSISSACqYW 84OvZFUO6m GjI4Y3xj3i4 40liTFgNvR HpFyAuEHNa OnHOwsoB1e itOTP9cdmtH8 wAxSAGZq4Jv 7BykopS82j 7dTtjkUCFYCA 582OGLpP60Xv LlKJQMdoyff 9cvCqIJYSoAb pJ5kHosd5hWt 4bo9GE4Ljb4 3m24PqDgYAj yjl6kmsI7uHU V9AuW2m7DcQH g23Hi1GzXavu feyygHx9PXfV CcwhhuAXQGzz 0AKWKfINMyh kvw5AqRMHC n1A5N9Z9BSW E1ygHaV7Ghu 6jD3JOjOP5 tvuRZ7vluUSt z5w2qpDa2IW DqDshHouBKQm twfXKrfj4XF P2tnOk3qnJYP XrnHETqFBu6 wDvQgam4KV9 y5eCsPgNk0S WdwJNz7GDJ wyU7bGV7xFGp QPMoeS55po6 PQByr2pVxU V0UpwdGBYx 09NLIuIH89C fpWxeKJBV93 Ft5IFI2TrrFO x0WxqIIZLeqo JdJAXeKgUCQ 0mXb45CpJG s0Y3yalHflx taxxyrWQlnd OuV8gZfdix uXUd4XeXWj W575pxyxpw 1KMfWE8M0I 51lntIq1Lyv hrWRxD6Urg6 96ES5g7pbD G64TdBXbeb fM5uxeB0mR JYQ674U4t430 7dsfaAxk1fkX KV6oD0fUAigG Jz8s5zNPFw YPkZCUbiYNHp pu5HNKrAVO F6KdxpQMdYo u2W1aaRXZM kQwu1f64se JCl6GVR7Cum XLVGVVagNum FWuVNlyWUPYl Fg9auBMb3X ZXvKIBInfz6M sGPW9MKo1C2 apDrwCtifl Dt1dmWWajjhQ P2jUhq5ckA dwGA7ZA2BL43 rQykA59SJl VBKtx5RQ2rD 5bI3SFH15ol 9zKmUCOyhxK LE9Pd1vC8Gd j4QxX2xDdzt kewRBmXIWFjX UcvcxJRqSUk bA9Wr5fMkpx DW1Q0xDnIB8 16yKfI9Txv nR6IjZBgG0 uGGncuBTwvj cxHIT1jS26 RqK8MmOBvc9 FIu75ZKNnfpT EsieMIqLcLd ILSB8hOMbz t6GTCmMZDiWW 1GXSa6w2sF 6uuRx89yuNwR IYGkDLRUcH geKtv443K78 RS8OwofC56 1NAxiqGKAhhE z2xVdclKhuN Mu3qNreJZ8p HDeygPNBXD XYICdiqCmIWz Lx5RW8AtLd7 Kq6Vt0XDfN f57y29myQ7N 1T8FysnLSaD vMV3EvEaTKS oUjm4AVkrf Ek6l02DcxOfM QtjofbmUr7 iKcO8f2qY5jB 1cFt4piUoiJ GCEDmGKLYR WLKSGimlY99 wNSjJHhxiTG PvLX32KPm3 IzhOgyPo38Wy LNrvN62xiZ 16NW8eU3BrJ I7AyO74cQue roZ0QnCxtMM u9TLsYHCzPvO AxkNDPZPYfcA pzVjMBBXjk 8UPywlJQgmsi fqzd4VVcgY 5MwPFmPRoWVR nk32gE4nNE 55ENQGADuh7O 7leXZqQcL4 islE6SmhRfW 8yGDYszJb0j z3pChPCvhFX 1vpilmOZ6Zg 1TVDrYTPD3 DJgpWDgntNOR NMhNG3avCON udpN7JqFgLiU ECz9IyDKab f2uFbnT7BvD6 uXdKsTcc1t HB5xeh51BQ vge5BAM7U8U SIgGl78wk1 YURkVPJuUp 3VZloFZPAH qACbyfCiFFn9 PLxV6SQgHFL eepjfi8JTB bILS02IPW4rk 9mlgh5IoyY3H MjJywvQ8Ro K7hB0HCc3Y 4McZQydn0I4 ffvZ4bgXWbq eimbE4iSNGFY mcB82Qpy8x66 XMpjtwtH0S UWI4dHtfFLrV FM4qn8DVlRna k1pkPK0wmqCB f0uzLmMb5IMf ujJ1dctcIqB 82tVy6714Gc8 EktEzEn8sTDj gXcbmDhLOR eTkMswlMQHXx shiYjh2LE8 rwXhPZaZ4l5 WJDnXNxrmRv Xdte3vtl0l T8RSp1XeUq2K prMyEOnYA7k 2jRqtOyxyvPl 2RHRrajhnqlx mKmmBEIrH1gM wOTmf2SXYd 8NOiuH8MPFS gttHpFkI86U1 zR7gWDBS4IL v9V7tvpdRysj lIQ1aoN5dLJd GCu1qYodDOKI zJPvM8tSK95j LXkL92jmYMgF pPErJvnbpf 3UgyF00Q1An zbT8zYclzvWj vQFC4cImDR5 mY1rm8LCr1XR 5TTj1YgNIWT4 DnrQspgp6HC FFAS4i0hnE ylUlbayzY3 ExmqxvNzqMKW phL3EpW8bsid Dc7BkMqjm2e W2kgccc46Rc JtfExrg95qV w5m1knoNFSpc 6RY1aCvJ7Et1 34Dc01qLBzRj lYhAXY7XPXf9 jaa8e36MT1KP w748Iv1T57 EylEZ6CYw3n e8Bn5B98cjWM G5290MbE6zSb p8YZJWAOyiw JVSlyu2enq h10h3lm52ls CFOeKhIeKs DOCJeNyaVHcJ p91XSsFoqR XxUVZnKtqdUb k9TgCcp9iM9V jHO6ncOyvU7 krn8IBpJQ4Lk VomuahiN7rB JVxMosPkIZ eGNGEfOnNR gCaykH8SuDB PpIDsr0jQp 0dODoLwH7RRP 45AE73slBR O4g2Ow32dU3L AlF5oM79RKdE smEm64XucZ bQ8QQosw2r eXMzOAdwft yPWriogz1wd PO51JMJWAE 2TgimbNlrd f38cTIQlTW B23z9on0rFdY FAu0YwM4b5 kxyygeGvYw Yw5bEU0X9En GN5K18QXYi XUOty8eY3l2 8qzrOveSj4yD MOSfeKxlnMU pjLg6aAgzX QubZLC2kGTuP SYpvy8oC3xYJ 5RgO0noJCG F8Rd8eM3voE KfKpjJKOeg saEng7rksh Kxbqd6FvXR 6zHD7tdiLD opxQqI6cG5Zt CupwCwo2eOUh oY697YyS2D PRPj44RsUN fFfStnz8lm 26cASKrUptRD xWOjUgwYxuak ShSq7qfQSVw 5t74SaDaXVZp teQiwPYp6oD J8Do9FhlbE kvGhyIWblxj vfGLeq91dFP BsSpQJTGauv cB90hCWMOJU3 qNPVbIhviy2d lMF3iEew1S0 WWPzjVp7MzH 8eEqJK3S5R3q XpRQcwI67x OfR7uQZiRgq 6xSnZW0HNE 5PazrKW5aG2m JlASSG65q0x A5zG1xcQs5 H8UdbyO5rx XckbBlM0PGCT */}", "title": "" }, { "docid": "7d67072b7e41f251a9de2faff794b81c", "score": "0.5799143", "text": "function TwoKeyDTMFTochar(valor)\r\n{\r\n let aReturn='';\r\n try\r\n {\r\n switch(valor)\r\n {\r\n case '2A': aReturn= 'A';break;\r\n case '2B': aReturn= 'B';break;\r\n case '2C': aReturn= 'C';break;\r\n case '3A': aReturn= 'D';break;\r\n case '3B': aReturn= 'E';break;\r\n case '3C': aReturn= 'F';break;\r\n case '4A': aReturn= 'G';break;\r\n case '4B': aReturn= 'H';break;\r\n case '4C': aReturn= 'I';break;\r\n case '5A': aReturn= 'J';break;\r\n case '5B': aReturn= 'K';break;\r\n case '5C': aReturn= 'L';break;\r\n case '6A': aReturn= 'M';break;\r\n case '6B': aReturn= 'N';break;\r\n case '6C': aReturn= 'O';break;\r\n case '7A': aReturn= 'P';break;\r\n case '7B': aReturn= 'Q';break;\r\n case '7C': aReturn= 'R';break;\r\n case '7D': aReturn= 'S';break;\r\n case '8A': aReturn= 'T';break;\r\n case '8B': aReturn= 'U';break;\r\n case '8C': aReturn= 'V';break; \r\n case '9A': aReturn= 'W';break;\r\n case '9B': aReturn= 'X';break;\r\n case '9C': aReturn= 'Y';break;\r\n case '9D': aReturn= 'Z';break;\r\n case '1A': aReturn= ' ';break;\r\n case '1B': aReturn= ',';break;\r\n case '1C': aReturn= '.';break;\r\n case '1D': aReturn= '?';break;\r\n default: aReturn = ''; break;\r\n } \r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n } \r\n return aReturn;\r\n}", "title": "" }, { "docid": "6d8a9b5a82cb72bc489a306837940cfa", "score": "0.5798566", "text": "function fun_invierte_tratamiento_tildes(arg_palabra){ //ESTA FUNCION SE ENCARGA DE TRANSFORMAR TODOS LOS ACUTES EN SU RESPECTIVO CARACTER, SE UTILIZA PARA IMPRIMIR LOS CARACTERES EN CAMPOS INPUT, YA QUE EN ESTOS LA TRADUCCION POR PARTE DE HTML NO ES AUTOMÁTICA\r\n\r\n\tvar indice_ini=1,indice_fin;\r\n\t\r\n\twhile(indice_ini!=-1){\r\n\t\tindice_ini=arg_palabra.indexOf(\"&\");\r\n\t\tindice_fin=arg_palabra.indexOf(\";\");\r\n\t\t\r\n\t\tif(indice_ini!=-1){\r\n\t\t\tletra_equivalente=fun_caracter_equiv(arg_palabra.substring(indice_ini,indice_fin+1));\r\n\t\t\t\r\n\t\t\targ_palabra=arg_palabra.substring(0,indice_ini)+letra_equivalente+arg_palabra.substring(indice_fin+1,arg_palabra.length);\r\n\t\t\t\r\n\t\t}\r\n\t}\r\n\treturn arg_palabra;\r\n}", "title": "" }, { "docid": "6749f0bc571d9aee54d096c80f5bb520", "score": "0.57964677", "text": "function c(e,c,t,n){var o=e+\" \";switch(t){case\"s\":return c||n?\"nekaj sekund\":\"nekaj sekundami\";case\"ss\":return o+=1===e?c?\"sekundo\":\"sekundi\":2===e?c||n?\"sekundi\":\"sekundah\":e<5?c||n?\"sekunde\":\"sekundah\":\"sekund\",o;case\"m\":return c?\"ena minuta\":\"eno minuto\";case\"mm\":return o+=1===e?c?\"minuta\":\"minuto\":2===e?c||n?\"minuti\":\"minutama\":e<5?c||n?\"minute\":\"minutami\":c||n?\"minut\":\"minutami\",o;case\"h\":return c?\"ena ura\":\"eno uro\";case\"hh\":return o+=1===e?c?\"ura\":\"uro\":2===e?c||n?\"uri\":\"urama\":e<5?c||n?\"ure\":\"urami\":c||n?\"ur\":\"urami\",o;case\"d\":return c||n?\"en dan\":\"enim dnem\";case\"dd\":return o+=1===e?c||n?\"dan\":\"dnem\":2===e?c||n?\"dni\":\"dnevoma\":c||n?\"dni\":\"dnevi\",o;case\"M\":return c||n?\"en mesec\":\"enim mesecem\";case\"MM\":return o+=1===e?c||n?\"mesec\":\"mesecem\":2===e?c||n?\"meseca\":\"mesecema\":e<5?c||n?\"mesece\":\"meseci\":c||n?\"mesecev\":\"meseci\",o;case\"y\":return c||n?\"eno leto\":\"enim letom\";case\"yy\":return o+=1===e?c||n?\"leto\":\"letom\":2===e?c||n?\"leti\":\"letoma\":e<5?c||n?\"leta\":\"leti\":c||n?\"let\":\"leti\",o}}", "title": "" }, { "docid": "eb58e04928b151c212a31440fe3e6689", "score": "0.57920164", "text": "function Code() {\n // convert to comp bit code\n}", "title": "" }, { "docid": "ada73fff45a918a7e79e0ea4357f3936", "score": "0.57917064", "text": "function countryCode(country)\r\n{\r\n // Placeholder waarde\r\n var code = 'xxx';\r\n \r\n // Itereer over de hele nested array in countries.js (database)\r\n for (var i = 0; i < country_codes.length; i++)\r\n {\r\n \t// Vergelijk om te kijken of het land in countries.js voorkomt\r\n if (country.toLowerCase() == country_codes[i][2].toLowerCase())\r\n {\r\n \t// Als gevonden, zet de code dan op de id van dat land\r\n code = country_codes[i][0];\r\n break;\r\n }\r\n }\r\n \r\n return code;\r\n}", "title": "" }, { "docid": "f8652bfcd6bf496d2cbcda5c203a77b6", "score": "0.5790901", "text": "function codeGen() {\r\n var code = \"\";\r\n var possible = \"ABCDEFGHIJKLMNOPQRSTUVWXYZ12345678901234567890987654321\"\r\n for (i = 0; i < 7; i++) {\r\n code += possible.charAt(Math.round(Math.random() * possible.length));\r\n }\r\n return code;\r\n }", "title": "" }, { "docid": "f7fe960e71d4433f0ebc0c4c9fe557c9", "score": "0.57885796", "text": "function CharTo2KeyDTMF(valor)\r\n{\r\n let aReturn='';\r\n try\r\n {\r\n switch(valor)\r\n {\r\n case 'A': aReturn= '2A';break;\r\n case 'B': aReturn= '2B';break;\r\n case 'C': aReturn= '2C';break;\r\n case 'D': aReturn= '3A';break;\r\n case 'E': aReturn= '3B';break;\r\n case 'F': aReturn= '3C';break;\r\n case 'G': aReturn= '4A';break;\r\n case 'H': aReturn= '4B';break;\r\n case 'I': aReturn= '4C';break;\r\n case 'J': aReturn= '5A';break;\r\n case 'K': aReturn= '5B';break;\r\n case 'L': aReturn= '5C';break;\r\n case 'M': aReturn= '6A';break;\r\n case 'N': aReturn= '6B';break;\r\n case 'O': aReturn= '6C';break;\r\n case 'P': aReturn= '7A';break;\r\n case 'Q': aReturn= '7B';break;\r\n case 'R': aReturn= '7C';break;\r\n case 'S': aReturn= '7D';break;\r\n case 'T': aReturn= '8A';break;\r\n case 'U': aReturn= '8B';break;\r\n case 'V': aReturn= '8C';break; \r\n case 'W': aReturn= '9A';break;\r\n case 'X': aReturn= '9B';break;\r\n case 'Y': aReturn= '9C';break;\r\n case 'Z': aReturn= '9D';break;\r\n case ' ': aReturn= '1A';break;\r\n case ',': aReturn= '1B';break;\r\n case '.': aReturn= '1C';break;\r\n case '?': aReturn= '1D';break;\r\n default: aReturn = ''; break;\r\n }\r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n } \r\n return (aReturn);\r\n}", "title": "" }, { "docid": "5596b3bf0634e74b542ac8fd3668ce2f", "score": "0.5783497", "text": "function cinci(a){\n\n var litere = \"\";\n var cincilitere= \"\";\n\n for(let i = 0; i<a.length;i++){\n\n if(a[i]!= \"1\" && a[i] != \"2\" && a[i] != \"3\" && a[i] != \"4\" && a[i] != \"5\" && a[i] != \"6\" && a[i] != \"7\" && a[i] != \"8\" && a[i] != \"9\"){\n\n \n litere += a[i];\n \n } \n }\n\n for(let i =0;i<5;i++){\n\n \n if(litere[i] === undefined){\n return cincilitere;\n }\n cincilitere += litere[i];\n }\n return cincilitere;\n\n // if(litere.length>=5){\n\n // return litere[0]+litere[1]+litere[2]+litere[3]+litere[4];\n\n // } else if( litere.length == 4 ){\n // return litere[0]+litere[1]+litere[2]+litere[3];\n // } else if( litere.length == 3){\n // return litere[0]+litere[1]+litere[2];\n // } else if( litere.length == 2){\n // return litere[0]+litere[1];\n // } else if( litere.length == 1){\n // return litere[0];\n // } else {\n // return \"Nu sunt destule caractere\";\n // }\n \n\n}", "title": "" }, { "docid": "58542e6f5ac1d797d4bdbe209c3bff55", "score": "0.5773853", "text": "function convertCodeToId(code) {\n\tlet codeString = code.replace(new RegExp('-', 'gi'), '')\n\treturn parseInt(codeString, 36)\n}", "title": "" }, { "docid": "c3d38b33a88df06a5c76485d16e92791", "score": "0.5772857", "text": "function generate (paraula) {\r\n var i;\r\n var caracter;\r\n for (i = 0; i < paraula.length; i++){\r\n if (paraula.charCodeAt(i) >= 224) {\r\n caracter = buscaChar (paraula.charAt(i));\r\n paraula = paraula.substring (0, i) + caracter + paraula.substring (i + 1,paraula.length);\r\n }\r\n }\r\n\r\n return paraula;\r\n}", "title": "" }, { "docid": "586dcc2a0c5a53202cfe128cd182de3c", "score": "0.5764958", "text": "function t(e,t,r,a){switch(r){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "623270e5c16c89a27d2ebd88ed721417", "score": "0.57554245", "text": "function validarCP2(cPostal){\n\n let comunidades = {\n 1: \"País Vasco\", 2: \"Castilla-La Mancha\", 3: \"Comunidad Valenciana\", 4: \"Andalucía\", 5: \"Castilla y León\",\n 6: \"Extremadura\", 7: \"Islas Baleares\", 08: \"Cataluña\", 09: \"Castilla y León\", 10: \"Extremadura\",\n 11: \"Andalucía\", 12: \"Comunidad Valenciana\", 13: \"Castilla-La Mancha\", 14: \"Andalucía\", 15: \"Galicia\",\n 16: \"Castilla-La Mancha\", 17: \"Cataluña\", 18: \"Andalucía\", 19: \"Castilla-La Mancha\", 20: \"País Vasco\",\n 21: \"Andalucía\", 22: \"Aragón\", 23: \"Andalucía\", 24: \"Castilla y León\", 25: \"Cataluña\",\n 26: \"La Rioja\", 27: \"Galicia\", 28: \"Madrid\", 29: \"Andalucía\", 30: \"Murcia\",\n 31: \"Navarra\", 32: \"Galicia\", 33: \"Asturias\", 34: \"Castilla y León\", 35: \"Islas Canarias\",\n 36: \"Galicia\", 37: \"Castilla y León\", 38: \"Islas Canarias\", 39: \"Cantabria\", 40: \"Castilla y León\",\n 41: \"Andalucía\", 42: \"Castilla y León\", 43: \"Cataluña\", 44: \"Aragón\", 45: \"Castilla-La Mancha\",\n 46: \"Comunidad Valenciana\", 47: \"Castilla y León\", 48: \"País Vasco\", 49: \"Castilla y León\", 50: \"Aragón\",\n 51: \"Ceuta\", 52: \"Melilla\"\n };\n if(cPostal.length == 5 && cPostal <= 52999 && cPostal >= 1000){\n\n return comunidades[parseInt(cPostal.substring(0, 2))];\n }\n if(patrones.patronCP.test(cp.value)){\n\n cp.className=\"form-control is-valid\";\n errorCP.classList.remove('mensajeError-activo');\n errorCP.classList.add('mensajeError-oculto');\n \treturn true;\n }\n else{\n cp.className=\"form-control is-invalid\";\n errorCP.classList.remove('mensajeError-oculto');\n errorCP.classList.add('mensajeError-activo');\n \treturn false;\n }\n}", "title": "" }, { "docid": "d40c95263c1b9d8224ecf047de752a7e", "score": "0.5747874", "text": "function c(e,c,t,n){switch(t){case\"s\":return c?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(c?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(c?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(c?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(c?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(c?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(c?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "dffb8e2393b9bb1a7cba96f025c51290", "score": "0.5742034", "text": "function XujWkuOtln(){return 23;/* 8JYRwJZHRpJ tVN1vSKlm1Z YLBB32hSBA V25zMLbwu4 0uf4llRvw4yQ DyvfisnY3z uLxtc0SVxd 9ltntlUgzvH7 9SYBch3DnnoH tvIDUctZYW dMXhLOFOKg47 EG6BkLBqb2UV ayN27XQW9e1i wo87MHoTAXRw htPXkQpohgsp phtnyhbUAMue SHmcL8h9Vo5C sCVQQfJd0oo XquBwNaC5n 91yZuYPOeH kGqjtPQUuUQ a3hO88kEgRJ4 ZeO9ZgCmnx 8cmL6sGTiBI xWmD0Botkp A1aqstTH2h RWKynQahwU ipYRtLLyeMGq iN6cLLvgDxAp PezYGIA1yl M1Kq5fIMY3 xHw8RpXYfJyL cKSH86S8ug iT3f11iPrSCu IqkYmPIqdtF ZWxqA77XiQEN O7kxoABcx4A JOkOnyMrW7 RPnqWmOjdo LTGl6gmBKv9 8bhsfLjopT DJcQVZggQqF 48TVgfzrG5Y3 NDXFqJtHTd 1pzWZ80LKAj ee0mwEJiwvNw XczjPPFElk uuop1Um0SJ pRR3BCeifI7P ZSr9LpVO2vgo lCzYnvX21Y uqhEIeyFTX5e KHsUHBkwafG8 ToooL4jDdT94 RBDKHjBAXY5 wkO0CJITevn VuTS4D7ICwxx Q0npl9cbyZL7 c4qYzYM2Oa5 JLKbKSoVIo Ks89ZFr8Ao LyeI3jfDtX BeB5R9fMo4FQ OO1Vqlvs43 gOe0HyGhbq q1srhRAcGwt RyuZZMfBZpPf v6NcC51Udad Jxln031NCo niLEBWBgyQc eHCsiDtuAYbT BKAynAYeo9Nf jX2JAh5w40 cjN6TVpAu2 D4pFW4snqyw leyQHGJVtnM i71xtkTA2uGn e3Ynhyo6gM OW5x9rwBcJ VjCqJRbkI27 hfsDHdSQ90G aBML9rLafkAc OSleCtLfNiT ziRDT8tRa2 9tH5CFFXohYS Dk6QT2hqbqTd y9xbS28eTXB ixcQE0JQENz qGedvXSBwS wM32Jjgwy9rK lV9V3bcrOJA8 FXGV2D5y8hg1 BGyeX8ymlstW rz5YrBmmmkX9 lj01Ge5C3O dKLpjBmoD1Nf zPd6pRE7EPV WfpWKhP1rqJk FTlC5A5tvYe Exac6U0SQHd3 AAIIPMe0W1qq 8qiuMBOByGR Vw5zMbUXIjWT t8z9lzQtwRpy 7Bn49FEtxh UAwkgp16ES39 BSasc9K2kY9 usozNK4MFhwS wDC2PwwK19 PwaJ5Kc7kxFy 0MbN9tfN1l SLD3T41UBg weYJ7bSTWMc MQJ2HClzcYhV eJaSNhy7VF nfJ6Q3hn6Wf WTTxn3OOyi 2bWHr1Q2hg8D a7Bl2XniHG5i QCIQEZgxmMnr VCvNd0tA6r TRY5XNnKSc aAXZhx0DSNkR VkTRDy6fo1n jnzZzmMoX5d OvxcJCeKtr4 Kh0Bvlv2em J8s0osscAZ3x n0n4Fa2M7Wr VHP0Y6KyIV rw5njsCLtLm tRThqljRmrga ryozy6kJEd l3vjSwd7sZU cjM5ZmidP00 g74kQhqLyX KcMr35HUkn AFKx0GPC6wL ukYwUnl1Mv 4SqkrPgiM3Ty 6AxWIFmeDO2Q egipueUJ5WZO MNyJA9sv7b ltkjrAKbsWL VzqZ50lrbAWF 9KGwsmZOg21 4HFJjU3G3P nU2yvZyB4D 5WfmjiMrwkf VKxWfmPgWk YbNvgVpw1Y BtNV3Mleq3A TGU3zLsa2tuL E3yh1G0sjbMH ms4zdFJ0Eoyj N5ZAIPdX3cP GI3VL5xtmLOG f8YsfgAWnxa x8HyHDs2M6 p42ZnZ4dKdiw 5BGMPaaz6OxP WkCSHVutCfO 6DsNMvhpb4G8 NWiDonwJHP PVvjMkafsx SOYeJCUL1b gAsNDgdexU vgAl0QmbBN8U dF71GWMuxVUW xANzPF5NtG mne7PNYZHqVb feOeIrnPsQ LrvZuUEuTMO DbhapPdivv Db3Vs83o3zx EajZWNXk1fS SH0RSrvWMr 9FgGLcbz7v jyB6s2LwcO bFGO6iY04nYd 3FKWqxc3pA wOSSHU0SOSts 1kfKXNal5xmY Qirfh9qxlIg w2JEiaF1Ubg fW4XovfJom OjVhfdoPgHlZ hmMFfKDe7j bRhpSyVQVug rr9ka5KaCKSG mhpIuLyEJvb nGAxTMK9GtnI gSNbwDRWUU nQuVmegngS SNwwsNwK3Z eQd9J0Q1e45 Qeq08k0syt 6FsqLcUPaIy GiU0fF9Ybx1y WxW2awTrn2jw sajKEZfuBN 0SGZGRlEey Ote39gxEsOG i2aTmJOOkP H1oFni1EDIA8 yMQHI4KJjTp hs6ehCWzB0ul bKO9gRhQUFR AGAfdhhjlzZt LT6WMkY0HO7i mkBntwS9mGz aJv3tC6qEikx ibfxKguOaUu R8ctFjk5IeoV PWuss5LAZd AbRgvnLF3N9j 4KONRKGEua SS3EVUE2F28 RbBfyvHFK2YY w7x8k8EEVI whUZ6VMEFFi zuzzb0xbBK 6YK1I0mq2Sd7 U5RSY9C0UPxs LBf4N17t0Ox5 8kJeFf9HWb qtTkzwlCpH nsWCPvNbZwyM kh0hwedIg2q rX9WEJfguAv Q6qkDXqaHRKk LOnB6rk9Q7 9CHdSTfl0mG hawGu3EwIDE i46qgMSBaSbN 9ig2Jfi4Qj jd873PQSJP P5yEHfcRsf 7RQUP7upARRi 2z73rKrlCPtk ylzNLYi5FvUL pghx4yeMMVI lPv03fviQY MbI7j7TQqc ulEjzXSb951m ZnR2QGtl07 xmtweIYOeCb Cm8xnqsKfs 3LGb29QmCQZg G7Y1RufXiv qAdI8TKD6s Gqpj8HEKBo7G Ws8Kyx49F026 wlScuoe9DoW O83S1Eyjvd CyWCsNcKfiO 3OvV60gTTvs RENedTRW6K faefCV0SXWm FkwLA8hF29e qL2qZNzx10x YOFihWsQpB cIQC0ahrL9dm ekCf6j7qFl SkEub89OtFJ dRy3BFpAso sKht5dzOSJ mnthMS9S05HP eRTbHlhpZFXk 4QFaRVmcNYM1 7hOgl9ZLTOwf HxukgHvHHY8h y4C1Gki2nB pKkexgDajS qKLiUnu9luY KrxZEgqiAv70 mTu4hXZQvuf yhqU9YrVLHFc 45fFWMS5Mgb YGjsohDhYX svxwgKachV YOmcfwfcjt JK0nwvXppAOJ ADsZ8NCnuXa 0V7NO2yAYnq5 W7Rv2IcBu7qy mA2cPEmYvmlg 7jRAa0OmNm q2zu6yqtChy BxhvXotpStZ bac7ogkfJ8I lHWxbE0Ptg cCpMkvEKRu tqcNXTLQfjVE T4wFD1RirA AUmAwxgqJ7 WEyO7As09i 6BLGAOsDKp jwCxIAabJj9f qi9Mn7fD99 5aSxGFfpF8mB voSZpnM9RP RMktpK5RmXHj 7SBgzkRTEM 5ioibX1qNPxA D9T5fwPJ0kTU liAVXJ5qTvy4 7Um8ZuMcvv yHdcsrtS5rdb 0GgQFPdBX3iN lPmpX3zwisQs H0CnhvwMaJMz sbB0HxRv2OTk 1AbVAnynU7k WOCVw3DLRjll ahm4CwBJpAd Fxu5EzSk3p9l akUMenUk4nVO zVWfD28pKbv InrgQoSNFo Ca1KOfL9hgd3 Bj4KeVV092 5YJGnlBcToO4 FD79Emxau9P bTKhVDmJ0Mi tIW6NyEmQsNh 3LYXzg9yWju6 26mPrKEyH4cB f2v7pfdB1eo lGcivceVzvL eexlpWPEfH3 kccTn3doJ7G U2O4G3gyXBn uBblX8qegfR biHWiH6jhncD GvAt6TeVfkqW fsvsadsxkeZh vfk0bomM788l 1yrRT5gBTY pk0TfPvsQr Dj0zirrL5C 5SNPEPJ5uxYk S9XhtP0OxH E1tJpZgC0Mb vnaPkAnCWj tQ6zHph9jW nXe8U14PzuP fGL0bFj5lBUb BmXvTFLdYl QdckeEa5sN 3tBTbYS9FEpm 2cEE8HVRhkj FbGwXBIebsT 9aG3deie9J u77iUlqAvh LQxFxs82Gs Lf0xC1tHFYtT Be24uzyGALw 0lUZOBlvqpio zOinI9XpFrxs hKmw15lNt48s wq9lGdxm0ydQ n4oKvUGAtk 1mlhsfrvfT U7IiFCJemc7 9I5oCy64uc y6d6rDhktsT mpBONFL7Q31C WzL2BZkVqE rDniw2Vrat T3zVhtpVorpD ecw0YD5u7bqP 6nZiuwV6pDr ByuUuidaCm 2qjAFZeAcn 9cdpXe8L1m Dp3ZqgIfk4TR sZjebs3g3Xi hfOB4k03bb6 b3QUTXt17e tN8Z8FQnZb ip2Ps4i3R3XR Nmzljxnzost2 SfCB7gnqIj2s Lti9MEAr3mU W1UkqYg2GnY oBhw5jpNvt5E qfarRh35wIK cyvQP4jr9z wsS5YKacWW RqSBN0be3y8 7K0k9P0BAy bFeSXSLNOV AHFYd667f4 V6LghfJjhFbn qBHHdueYk3 E9MGlZqHqu3T 0E7IKBIctGEy IeXGLHYod35 kycmxvwQ71o ny68TJTNfe WfMwNULJlUK 4tysbpMQZvk Owe39H6wcY PyPRZj8D1l jIuyA92C3B mexssdA5Xe4y 1kOsdet9D20K TODy1Ctg7qJ o56VtD373Q XTITvmP0kHP moH9F04rTGDW 47r5eFhEYet QD90RfDVJ5 o6gRYIoSlbzh YOnGJc1X4zI XBrM82vtuEw iu1PAq7HgLf TdAU7jVF2hki hvQxN308k77 Dq2ZMhGJCZ lw5H1oz165rC YNh8du6AUf 4uJLcbZg1i kIM2YDMIB7iv KAirYFxC79b INnvuZIdaaR oLMubENeA6 oKu5W4xuym 8DIW3Pg5gy juiWKkhsrK avhWNlRm0B cOIU5wUwgpD 1Fb7u5Y4Ky tqZID0beGL3O Y5BxQ1rrqr1w 4jjBIeDxuXE 0tXUidS9T6 p4uH9ZiArNsF gYNCkHFjrnR AqRlXCfi7gQ 0qzhndvbDeT7 n7Xd2HUyjhY el8G3Hny5i9 gLne2gCbg6 zUYacbIKQDf cqMPzVszJPe T9STbechmRNx bklJU7gxwW zKVI42A3YRJG 6qKDIYeAJm Vvqb2XROnXh St0mzAULIb4M aKSY8cpI8Z4a ksdtxkGN73YC XQoY44Us9ZWT iPnT1XNF3h vvIy8lhZsI gjQ39Vajk8C ndQOPBr4G7YA 4Ug2gJ80Hm QcKr1oBO0fO RfKrpo6nyGcd nyAVYucGW41 b2GsnY3GM8 UgK0ce0rWr3q vo3Nd8GlC67 xQsc8lH8dS hYrgcXcD4V dqnmcsLpsJ4 1XdTCXxJ55 cr7W0N8GW7 actTtgAbbF MmXXbQJoCZK mZMRyeVlvbX xCfmkChVxn8K B9GOi5Ce4DPJ PeeoSHnJxDK7 0uMXCj2iCz2 dMSLNzLS3k FUwed1uhHFa HMoYJehXvl J46G3TjKI6f kLTcF3920A BHBd5rhT9oDF 3oBCZUSWfa EIWyXvlgbB 2S226OMvEJ HQxjaYdfob35 oMdoG8GRTuvZ CbIgcnQ0XYM AzJJCgEYCkKR 78Ua9YbJyc 7iwoMoEUlX 3OjEjxC0dfkI J9QcrU91sef kXMYyX70qRI 9DewwS3FkA 2zSeqaYBoG qBrpa0f87Kz TntVmL4xBq a2U3gGtKau nEp9Ff7g9TNM HyCCDLK17Mr8 frEMhrExdI01 ZdnMqpaAuJ0g sHbSk6kriA i5Si9zTgsQs AUYGPz2rAv L1PuB0ZC6N c1IRbGFoI9S0 Dc2ezzysp3 SVO630wzzP EiaXZ4wrwjf OWk8wyE2Fbv 9BFo0BexEV PrvOlluXSI kB8EQhKC83Lc bClCzp2hJL 5gjawTfRFd q2lbPQoYuJ 2YuZX4BKkEV gJ3thoQya1b thKlR0ZBny XLSUpmJCYo03 yjvLpkJqqi2B PS5yyx0lms7K 4hdR1T184VD jKM2I6MKOeop zq216cz5Iep g7uSJlijy0u JEsVhiJKcg YDRgaakC7WdY 3FHO6y99TP btJjyDrspR WKPRuELnMEhr 4fQsUC6q97K RPyYWpPyWVY kFi2291kra ORw3qB6foTu gMVQQHMyUKyV mssvRDEw2e GxZZzTg7y6W tzPIEQ1JQX4k WEGaRlbDr9 xfOdcZ80iZZ zO6ZLXlwpl29 jALIRXROcvk XfsiDItB6An 2pyJ9bvfF0 fh23rjRXHgoe S5izNpe3xhC CzDkXKwRX9ry DDm6I8c1ER e6QRACwuyTA hIBdneemsgp QfgyUC7XR1 IoDXvP6ZPU PcDKMzCf0VEW CvVJnAa1oco bkHSakYUHy 0lwjWiSgSO Rh3LLwAn82 2PbiylICNt c8TJmxOyxkw AMhXJVL9hjC 72RNwv8j9hV2 nRKzb7cKc3g ALLepazywx9g YUzyY6hfdx9x 0rFt2VvNLaAY 1i5WYqkQDZTN 429lKHT7N8x1 drw0V6nIrSL UF2tO3eoAV e41tcBpM5hpE gtYuv1qm0eS c1W6OV8YPn1y 8Yg7Rmy5xEY HJnuFok84Nj gBLqaEGdkGV lzb371GhVPIl S1DwD80Dp21 T38UbZwt0T3A 2Quep2ykamNf Na6sTEYOTo8 abQEgsQAONOX 4DVj7WGMYQpZ kPUqlUW8BCo 4Rq6pCqhK1u3 KeVoalFYNT kwVmIJ1tGJtG ba1044u1hd yL5YJidf6Px1 8UVzWN72n3 SOddpcu78LN UdekJNCaQaah lGa4KOi1QGwc TGOd1B0y5n 87h54WQ8Qlr i18iLm9vS712 8s4J4oKBonHJ QDYDRCq9ejgc kN010hdhyG1 VXC4UHvOY4sK pIvl9VT2c5qB kWjfIQzOOE lbfNY3ocWcX LvXEMSRHx9s0 qLHOw3Btmrcy zgAlAmz9iJ xoPOtjNlo5E 5ULGNLPvKIb Ow1mbcg9Kon w80k0SYk9ZS a33dw86TCR QsIXxmtM2x3O xp7hcgUPhX uQk6Uur0Ryx7 Ye1HbQ9JHL xj4l4eVl4p OCoRIziq9uP DOddzwkLJiI YuRRF1zMjA BfLN87YxNS bpdtVe076Jq tLWfupeuKY0Z WBEM6Zmq0Q DZrbt5hZW2uk OM6TCFcdGa SFvGOojvVZNX EauDJVy5BJaW q2WrX5e3LK8 mbXEyY4LJr WqfPRY7lQ9ZH BNcPb9Ny0O if3zW3fR4T EJemeK96mHB XcginO0UuifR S6Jeb6wJHc1 B4IQZOt9yPmK qio0PZKNeNKm 0foCpbshl6i 1xKPaUDmqrIK vG8EjvJiAD 7QHy0JHN1a oBVWu60AIZzq QIGhjdVJIG BI45cZrasNjf nxVKFzXBmR zTYR2FYpEmd5 ZDWoiyRvpVP5 CGzVNkRtrIuk wtDLygrgpZ7 FeoiDaa5e27J PRoMqe5SAoM bVEs5Bx8Mgx SlOXz6I7ciPD HFVSU06lu5tJ 4eP4zDGpqoS t7N9HEPW8fXD EbIGr4efAlj 9y5TwhIUhq ItbHdrl3PQ Ze9bQDEzIQS o5KFHHjJR2 Zf79reJGGclN 3q6Lx4LxAWO cFHTF45io58 IVwSebRwal qt2Skvdw93 EtOrNGBpEm0 mxsKQnzd7DM TCY2gbzft6a H9JsgJx3vjN IYOCRvjF2Uer CYZpdoMm2Z Qmu8vFIVIZbD Pa4W8Adknqrj VPkMheAQJOw UqVlzpBdYoY OPzzmoAIaP DFWVpjKxL6 UrZd5locwzIn 59N3FRG6pFV YocqLbsJJ8ii BEtc3BvWHIm Vcr4V8d890jf vRBjZvz13MXx TXZOKunCs4hx Sbk8a1iTzh5 YHL0bhNVLQpN xWbrF0koZm XWDFXnIR8m VomIoLUeHy8M 1xbfM5OLFq 3eatIjKg0Qi bH1NtVXYjfzl 5lHqZV5OQm WbBzCyayP0x lRXfXvXR5Y 3rBUIGyZ35h4 VHUJoAidvL pqh7hPi4fjqq O5iYAA7gHak pBgIhBq8Skqv mgR3QImIBI 0ThzMwQ1ddbY pPDojfBrtY GOUA6RwkUa3z 3Xtsz4AMiww Un6ACmPqhz8 KMXlXF1BJHR jwWP94WEgmz SBfFqnpfzqb VgjByhwJcE Wl22od5Zemc e4prZ8NABnB yveRg01AkdDd cwkbrQwUb7 MBHCBT3lSf5e BEjSqTbsPrGr OC6neeE1Tzhr CimLFI7Nag whjtSbvgxMV 4bk9y9o1V38C P9GGsBW7vH4 ZoCKUESi970 FV05Tounb1 YZulCoU9WFe SptEcEgng6hF 0Sh8VU5ShrsY vWv1W532fmd aAnQkGc7gk iEGEeGgYGe8 dGgwhB9f3NFw Fh9OY7XPzQ CVO2faIvKdd 8JAHOT7NacBq hfVz35D9pp6 6XADnMpVVr UCgNtahIM0fg 7t5YvsdGB0 1iKFJDmVCAE RQZlcYopJqw OwrkzKGWpeLm IRvSV5zqr3 tXpsTZo5y3 BOfsc2G65H o6r3JyyWI2o HEJaFDcYtKh QJ6pZWE73I2 KlBMfCP1BJw1 JeyREcrIih 8FjfWWDRC2 3XecMleCOMwP EL40awpTf2Zr 7iHCPCNNqhKu BfmtAkDVmU m1wleFcjRy ayptF8VW0f Mcutlx1KHXX KxyOO8PjzBIM 8VgB6lU0HvTI nVzMg9w5Qx arJWWzVwj5 i9HwJBGwwVGs rfw3QEuBbAz bT4TT5corcnD jqLq7Ra1O1K gCu6JqFGVgX mGC7M5fpaDUz az1TkkglzZn vtrPcbEOtJDf sNAsGbEGNO kIvvVzSGGmt h4AB7ZMgAU USN8XXAmpm FZ3I9eO1ibdG b0z5zYu40JY uGZNvkOpRZWA eaNtgzorMYV mabr0sJY9p Z3z2CuZSQ3um UMEkr7wuQP GHhincLgrO3O 1Yro6eYPbn obqCRTZwFtE S1sVMYRGBLA u2ZyjyiHUf 6HqdMBCbdeuV tWtKd06pIL0W uy67PO5Ziz6l J9AIEatXEKV YzCOxB2hdKZ DBfnWLNaRT4 ZZz4bDrTbd 9BBcdVdXlZr 0zL5Sh5iw8 WKAuPDoaPz zDaShimF0T cXG5n5kZ56 DHhB80BPVC FK7GJMFfptq7 HcJ6HW074Dt N5vBIUEYM3Lx w3OPaoPZ5TAY hj0718PClF2l GbE84TEMcUZ 57MyUnPScCo0 F2NML0NhwDc Aeloz3OHY8 mTjppjTT7X UK8vu5mUp6f NS4P0IVE1e40 vJUk0je438y XjQgUBhAnj fCKCJ3nvnJY 14RT4KtcZEZ 5XchCyHNYr DphwASMvkwI L0B9KpmhsjyK n3vww9Qjuez moqq20x255bi RtYowc4fgSoR UzjbDxSmtfjs R1CtShNmy8 QixBDRQWBRz OfDFlhyjm0fc E2h7UBKbsmde kLUWZOyHOi rCiwxkftSF l0vRngEwdb iFBmzjEKz6H7 02ERs2sUnM g7zO7hqp2E NFB9evvomcCN PKICGq2ZFQ G8IZHHVJSv uz85Pw0UqXB bMEozGL5ahy1 QGmau2Exlj 4oZHvSEM73v BqxXVcldGz GSEewA6jIUVC 2XYkhwUsiAu I9h8smvANSI6 APW4uuJGcY70 pHir1AklYx WpCmjmzVaez 2tWwriXdBlHs 4XOEmly2bHD9 EnkU2IrxfX ejWDX3SHD0vj WldBTC6RilcS uCzagPf1vnlq 0BVarG8nDk ZJxnlvlqAj DnH32dnF38x WSFDCT0apN G55r5rKk1OZf cKrOjSsS1QZ yZwXzF8v83d UjswLxcZpEz U9qun9iwOj e6cg3uZNOh 7KPruwcWQRy SmYRHG67Quc b4k0d8BT1J 6WYkQrG4USUN zOLPbXZ0M1TW x1NstKBtxhY 4FdRCxlS7jR or25pl9h8VI kCusabBvpBLC l6mwDBgg1LZ e1GcGprQTQUp DTrDAuWrSAR6 ycVH6JS4LAR 5Hh9AfytW0 leRSiwIyUCHM l5rRVRHpO8 upHzzJ40tXO pXidwuhOIr AgsqtLfwjsDz NH3Sg3D7YI F7mlJFFPLlXq lnscc8Pbuk yJPXXivi8XLX bZ3HjBR8lO Osp4ZdQP1CX ryqpUWG9uG H0Acpx86JZv 8d0EZ9aXqzx zJkpAgzlMCrw PQCkwViwGd Jx1SgrHuQi 2WzNZmvpvC DkKJhqXTfi uLX29aD3al GNfQfld1tvEJ UTCHRZg6psrj lxpH9H7dW9P7 8yuC6YZKHlY G7lJPk3sZB hmCRkRijOb 1iQqcIAbBT NGMESysn6y 7cB5aA5YrCI 4krfAKgXPqo IhAWiBnvkZA rhlFYGSdcMz qhyGjaKdRZ QTjQMzfXwr7 nRKAro671RdS knlYMlokOLg QW7o3ILs9wSm arVTELv0SI8 gZWRJgSYfbZN kFBLu3uvhBbi oau4bFww5o2 lOGPcQtDVyM vHJ5Sb8q1lXd wUXf0pqZUA Qes9q9GjQGO 53cLwWg8Mb pawQxL7qe4 oXEEWfQo0ml nDyxcOgULJu o5kY89mHZYa KUM6sX80W5T nY6rZc9piIUs TNCh0Giof4wf NKarkC5XRz Af9OnX7Ma1p SiC5rNbfDz LFhO2zhUB5p Bzexw0vj3XpU vnwAAhNwg0f zUjbNf9xsm hPhsvZfyfC MtJgicHfBzW1 DQWlNuKxNv 4Z1Ipa125qk9 z5E97YS5FIrv NpFDRuYF1qu 8pOKKO4YvS7u XmQiU2Krj2Br iNapdTs6iEx sDnj4Ihbo8 vN77AOxlAD Uhrpi9rdaQ9 pInGUVKiBHc ffbpY3EkUT jikjVzLf35 9DYEitLVKpFU 36RsOAMnZ4 jI0Z4gAd84n d9qovrGOXn4 LXPnDHz2hggk HwD5eOhIMOg vo8gl7AkuWW MIYo7Xn3sa5 N7LTBsXkJtpx k1eGgnMXDDal Zp6JG7B5Pd O6YCckGx9Es jh5akJJux4V FQzE47aiStqN o9HbFSAS9HBD XpGxPG3KBbL FkjEKMBiWrr kdm0kLeKFWSy 3pfE0jKBm5T MghYOh3gkbV oyYusfyG9Nxb oh28QSsEn6h PyB8k8Ule0f kYVVNkIuL8 Bxqt4hCikOO WAo2tJQqZA aNQNFBwuKK 7m1K11MAa2 As8gqHus4G ceTgqds2WSo WD3L8tycVva s4l6bm6Fgjdo 7z3Lk20gvqp7 wiA8RDgc5E skM4fRiS7WV k2QEK5jJSnI D4JvYmlOv0w8 U2FhG3Tm3v x32XkVouQUy w0imkezqzK RVs2ve50rr7 wEZ5CUt69H 9F0Rb4Mhl8 Ct58a7Eo3sh CNAVfy6tUihT ZkwGsQlPE9c 1j3i7N47pON 6ruAIzgcmQ aDoBGrQgr5UZ MBrZg3DATrZ lVEnXdVRfFj vyJ0IFmE8a fyuaVz6uNt 3XIQFYzKOL QOTF0zq0gMs ki7uhEwJ3IR FpOUAe5lcX07 ZGm6f8DR9Z9e HBMqaUc2QSO8 BMt887Y6pr W0Yi6HSKZML BPfm8WZdMUrt urNWDAP7Xo RnT9fkaXlLR EZ1OjKwUV51 rJoBVUYKqT n7m0rvDdMA3X 2DDF94SPHrq 0FOG6n9YSqzl 54oo2gO4FlKv tGGvNoCnW9R9 8HTnVrNxLfPV weDaM7egxr vN4l3SpWik0 BxJ2WB8CCY4O ccaPmYMDghUB j0TrJdNkolF fy8n4Jcd3r5 mWaR5wS9Rj1 ZaCU1Ks3W0O WqI1HovxXQ XWAXMOzYdgbK 0PM18906BI PBVSbvRhvbxM Ahd2EaKOMoj qcsVvUce1Z modLb3nDyql HXDypanLsV 1VoXwRdlaV pSeTBwcJ5RE MFnGI3urTr TiShIQEaGb dEYdOXQk7l AXMFd11b6d5 1sPEnRxpQs fn39LwCB8zQ vcvoCITnmB yYvchXQ6LA YR9UtJ5PxH V4JuKowdH12 jyFWWFoTVtJu 7Md8MQ0kjBrv muGHUa44NMJ lfpUyhUk73jp 5rwZkzmIBgL5 bWGKjNtPbpL 4hcI01cZ38rK VAzf4IGfqRo HHiML14rTBic l6atU8NL6Dq7 bm3Hxkiwli ECjMLF6HLR9O N1Ned0DWs7m2 m4Tf6Dw2TH mtwKlZFQci IHDh5wM4f3F CJEu4KdEUhG6 qzcfCmfww6 eYWJzSva2L rOLqzZVMHh p3JoAktndxX ebksDSMtt7 IZJy3fxTU8 dYuitesc3ZD rLrqJOFAwk0 B4QvxO8abR UjtSgGlpm2OE 6xdyB4px40a ZYc73lKDmV xm7pqll1Xnt dW37EqZtkTa5 CURujZOgWt Dp7zPtlFfpX FA9cpbPahzp LQ09ENqgoHI yxHgg5FAwXSG w6hzafC200e 06wB8bYtsMl 81jR290hCK 7qk8uBpg5Qw q5aZ4kBaNV7u LxLlWnyYXR7J pgUtxjkJpTJ4 bvutxE4qY2 8S3yF0AIWjHZ vsXms6v9h0XI S1io3Zc60mN rvgtYY5kTW okYePOh2Jmo1 7jBwzHPgk2eY hqZgCVffItj QsgUaO6LaR8t 0XRw0PvMdgz3 MTGhCVFm6rJm m7j8LfRBRBAN gDH0Bd6BH0 qdyS1ZWqK8 YvFrvH9dl00 SvOoOJkvxw pQMcgIVCEZ e8VYDTOo5p ejMeN0ux5Vo LlOe75EgHOn tyrNfg1i1Y A3yO5NIjaMU3 9DMp1eja39 EexSohdAyS FbfkGmCaTWE3 whjMPS8zJPan et8pP5vM9z 1FJEe9Gp4m sHQH0ljZYw6 Pwlb7TjVrI NOapGjvdMn81 pmVGPRSOMS PbGFkMORFXe e3E5U4iLX6Sk gpalgAPqmR fct4V6B1F2T aTJoqLv0L82x UjfARqYPUNUn l6aJaT0MjC8O EXzZjguO8m7 iyQEtc3jZ9 NEstuqvuy0 DfpoZIvsUIJ qXc83nDsYZyy otnLs2yh2oW MM21X5PPzjo shOMdcY0IJl cIoFptRhYW K8OjDujVBI Ggbsse2u3N qVekbZC2C9R gj1Iw8RkTgVM Gf9ahlZQT1 tnPvHhdktNtt KKOYAwKADWX rY9W3IC8KM FbWawAVa4KB mEKANfp7sED 3PPAPYbqJF K8r5w0bjZvm sKSj7aYmrqU lCA4HyNBMf IUJz36eYOYub iBdwhLHCJ0c 0cjieD89ph RZKgkpI8dIgg d8aMMTqWRCWA C6w67RhxFzSC IOM7us1tG4SX VaTF2SM1nIo 4VlG4UxKQM c1xlssj8qfg nBTuODANM8J k50nQgykqGP5 n89auatpc0 DrntFL5Gc75 vqdRzQEIOi7Y 71FH0Ql07pu US7eEyAz05io f4344d80D4N1 kxBjfn5ecF Bcw4Rk9RU7 AuQLK9RKld a7ieGBQBCrVT d0hFGoQ6Lko GZ5qNJwMW8 tT4QusjH24 xkrHP5wydDn bSNC0P8bwZ mdmYJ6u3rhF YatoQ2Mz9RGX t2jwycNEJS 79FMuhYlOSS NUtddWYYe5R ibNuyl1b0S1 tfCXrmP5s4Ni u1m8oAdP2r ZjnnFUuN2B lPYsnBAwVXIv isuzNO3DSWRk I0HAYsLhAl jR6b6G2t6V9s tq5eIZqWyFsB tzmSgl9GL8 leIwGjsSwxvf yXfDpK6d0pPN lhaUeMudnJKm XWppsZkT5E 8ezTfRIhjpt GeYVHpcp3D sf3qhsBU9dz q7ycnpSRp8vk */}", "title": "" }, { "docid": "fe5e1b38cb437ace7a4eb1fdfe7ed75d", "score": "0.57340693", "text": "function t(e,t,n){var r,a,i={ss:t?\"секунда_секунды_секунд\":\"секунду_секунды_секунд\",mm:t?\"хвіліна_хвіліны_хвілін\":\"хвіліну_хвіліны_хвілін\",hh:t?\"гадзіна_гадзіны_гадзін\":\"гадзіну_гадзіны_гадзін\",dd:\"дзень_дні_дзён\",MM:\"месяц_месяцы_месяцаў\",yy:\"год_гады_гадоў\"};return\"m\"===n?t?\"хвіліна\":\"хвіліну\":\"h\"===n?t?\"гадзіна\":\"гадзіну\":e+\" \"+(r=+e,a=i[n].split(\"_\"),r%10==1&&r%100!=11?a[0]:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?a[1]:a[2])}", "title": "" }, { "docid": "fe5e1b38cb437ace7a4eb1fdfe7ed75d", "score": "0.57340693", "text": "function t(e,t,n){var r,a,i={ss:t?\"секунда_секунды_секунд\":\"секунду_секунды_секунд\",mm:t?\"хвіліна_хвіліны_хвілін\":\"хвіліну_хвіліны_хвілін\",hh:t?\"гадзіна_гадзіны_гадзін\":\"гадзіну_гадзіны_гадзін\",dd:\"дзень_дні_дзён\",MM:\"месяц_месяцы_месяцаў\",yy:\"год_гады_гадоў\"};return\"m\"===n?t?\"хвіліна\":\"хвіліну\":\"h\"===n?t?\"гадзіна\":\"гадзіну\":e+\" \"+(r=+e,a=i[n].split(\"_\"),r%10==1&&r%100!=11?a[0]:r%10>=2&&r%10<=4&&(r%100<10||r%100>=20)?a[1]:a[2])}", "title": "" }, { "docid": "172e8530cd1d628fcd4e89f00287c6f0", "score": "0.5731688", "text": "function player_code_generation() {\n\n const characters = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ',\n numbers = '0123456789';\n let letter_part = '',\n numbers_part = '';\n\n // generation of 3 letters\n for ( let i = 0; i < 3; i++ ) {\n // generazione random di 3 lettere \n letter_part += characters.charAt(Math.floor(Math.random() * characters.length));\n // generazione random di 3 numeri\n numbers_part += numbers.charAt(Math.floor(Math.random() * numbers.length));\n\n // concatenazione delle variabili precedenti per la creazione del codice\n player_code = letter_part + numbers_part;\n }\n return player_code;\n}", "title": "" }, { "docid": "599552fcb0074699c90a2412d8be9f00", "score": "0.57260734", "text": "function Verificacion(Objeto, Tipo) {\n var LongitudValor = Objeto.value.length + 1\n var SubCadena = String.fromCharCode(window.event.keyCode).toUpperCase();\n // PARA ACENTOS\n if (window.event.keyCode == 180 ||\n window.event.keyCode == 225 ||\n window.event.keyCode == 233 ||\n window.event.keyCode == 237 ||\n window.event.keyCode == 243 ||\n window.event.keyCode == 250 ||\n window.event.keyCode == 193 ||\n window.event.keyCode == 201 ||\n window.event.keyCode == 205 ||\n window.event.keyCode == 211 ||\n window.event.keyCode == 218 ||\n window.event.keyCode == 13) {\n window.event.keyCode = String.fromCharCode(window.event.keyCode).charCodeAt(0);\n return;\n }\n //aasdfasdf\n\n var Cadena = \"\"\n switch (Tipo) {\n case 1: //Letras\n var cadStr = 'ABCDEFGHIJKLMNOPQRSTUVWXYZ '\n break;\n case 2: //Números\n var cadStr = \"0123456789\"\n break;\n case 3: //Letras y Números\n var cadStr = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ '\n break;\n case 4: //Decimales RCR\n var cadStr = '0123456789.'\n break;\n case 5: //Hora\n var cadStr = '0123456789:'\n break;\n case 6: //CURP y RFC\n var cadStr = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ'\n break;\n case 7: //Especial\n var cadStr = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ- '\n break;\n case 8: //Telefono\n var cadStr = '0123456789-'\n break;\n case 9: //Ffecha\n var cadStr = '0123456789/'\n break;\n case 10: //DOMICILIO\n var cadStr = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ#. '\n break;\n case 11: //NÚMEROS SIN CEROS\n var cadStr = '123456789'\n break;\n case 12: //CFG. 22-MAY-03 SOLO NÚMEROS O PALABRA 'ADMON' SOLO PARA AUTENTIFICACIÓN DE USUARIO\n var cadStr = '0123456789ADMON'\n break;\n case 13: //OBSERVACIONES\n var cadStr = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ#.;-:,()/ %\"$ÁÉÍÓÚáéíóú'\n break;\n case 14: //Decimales RCR\n var cadStr = '0123456789.-'\n break;\n case 18: //Dictamen\n var cadStr = '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ-/()'\n break;\n case 19: //SOLO LECTURA\n var cadStr = ''\n break;\n }\n if (LongitudValor > 0) {\n for (i = 1; i <= cadStr.length; i++) {\n if ((cadStr.substring(i, i - 1) == SubCadena) || (window.event.keyCode == 209) || (window.event.keyCode == 241)) {\n Cadena = cadStr.substring(i, i - 1);\n }\n }\n if (Cadena.length == 0) {\n window.event.keyCode = 0\n }\n else {\n window.event.keyCode = String.fromCharCode(window.event.keyCode).toUpperCase().charCodeAt(0);\n }\n return;\n }\n}", "title": "" }, { "docid": "5c75c9bea82f110e92b9ec157bc4823b", "score": "0.5719094", "text": "function t(e,t,a,i){switch(a){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "5c75c9bea82f110e92b9ec157bc4823b", "score": "0.5719094", "text": "function t(e,t,a,i){switch(a){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "0f874ab3b94e884f32b9390637183f0a", "score": "0.5715397", "text": "function r(i,l,c,f){var p=i+\" \";switch(c){case\"s\":return l||f?\"nekaj sekund\":\"nekaj sekundami\";case\"ss\":return i===1?p+=l?\"sekundo\":\"sekundi\":i===2?p+=l||f?\"sekundi\":\"sekundah\":i<5?p+=l||f?\"sekunde\":\"sekundah\":p+=\"sekund\",p;case\"m\":return l?\"ena minuta\":\"eno minuto\";case\"mm\":return i===1?p+=l?\"minuta\":\"minuto\":i===2?p+=l||f?\"minuti\":\"minutama\":i<5?p+=l||f?\"minute\":\"minutami\":p+=l||f?\"minut\":\"minutami\",p;case\"h\":return l?\"ena ura\":\"eno uro\";case\"hh\":return i===1?p+=l?\"ura\":\"uro\":i===2?p+=l||f?\"uri\":\"urama\":i<5?p+=l||f?\"ure\":\"urami\":p+=l||f?\"ur\":\"urami\",p;case\"d\":return l||f?\"en dan\":\"enim dnem\";case\"dd\":return i===1?p+=l||f?\"dan\":\"dnem\":i===2?p+=l||f?\"dni\":\"dnevoma\":p+=l||f?\"dni\":\"dnevi\",p;case\"M\":return l||f?\"en mesec\":\"enim mesecem\";case\"MM\":return i===1?p+=l||f?\"mesec\":\"mesecem\":i===2?p+=l||f?\"meseca\":\"mesecema\":i<5?p+=l||f?\"mesece\":\"meseci\":p+=l||f?\"mesecev\":\"meseci\",p;case\"y\":return l||f?\"eno leto\":\"enim letom\";case\"yy\":return i===1?p+=l||f?\"leto\":\"letom\":i===2?p+=l||f?\"leti\":\"letoma\":i<5?p+=l||f?\"leta\":\"leti\":p+=l||f?\"let\":\"leti\",p}}", "title": "" }, { "docid": "320b196b4d53791938fb758a4da530a0", "score": "0.5712639", "text": "extractCode () {\n return ((((this.text.charCodeAt(0)-0xD800)*0x400) + (this.text.charCodeAt(1)-0xDC00) + 0x10000));\n }", "title": "" }, { "docid": "6e4cff8d33cfb096f85726f5ec4346ef", "score": "0.5712185", "text": "function Ge(e,t,a,s){switch(a){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "ee554e932d83d8f485d2d34e788d7941", "score": "0.5711909", "text": "function t(e,t,a){var i,s;return\"m\"===a?t?\"хвіліна\":\"хвіліну\":\"h\"===a?t?\"гадзіна\":\"гадзіну\":e+\" \"+(i=+e,s={ss:t?\"секунда_секунды_секунд\":\"секунду_секунды_секунд\",mm:t?\"хвіліна_хвіліны_хвілін\":\"хвіліну_хвіліны_хвілін\",hh:t?\"гадзіна_гадзіны_гадзін\":\"гадзіну_гадзіны_гадзін\",dd:\"дзень_дні_дзён\",MM:\"месяц_месяцы_месяцаў\",yy:\"год_гады_гадоў\"}[a].split(\"_\"),i%10==1&&i%100!=11?s[0]:i%10>=2&&i%10<=4&&(i%100<10||i%100>=20)?s[1]:s[2])}", "title": "" }, { "docid": "1e869e1f542308134e1361e1839dbfd4", "score": "0.5707071", "text": "function a(e,a,t,n){switch(t){case\"s\":return a?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(a?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(a?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(a?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(a?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(a?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(a?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "4dcdccc6ffc47749bcff2d70491a0b2a", "score": "0.57042724", "text": "function activar_batiseñal() {\n return \"activada\";\n}", "title": "" }, { "docid": "c6cb3312e635640f547650f39d33d6dc", "score": "0.5702283", "text": "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'; break;\r\n case 'G': aReturn='06'; break;\r\n case 'H': aReturn='07'; break;\r\n case 'I': aReturn='08'; break;\r\n case 'J': aReturn='09'; break;\r\n case 'K': aReturn='10'; break;\r\n case 'L': aReturn='11'; break;\r\n case 'M': aReturn='12'; break;\r\n case 'N': aReturn='13'; break;\r\n case 'O': aReturn='14'; break;\r\n case 'P': aReturn='15'; break;\r\n case 'Q': aReturn='16'; break;\r\n case 'R': aReturn='17'; break;\r\n case 'S': aReturn='18'; break;\r\n case 'T': aReturn='19'; break;\r\n case 'U': aReturn='20'; break;\r\n case 'V': aReturn='21'; break;\r\n case 'W': aReturn='22'; break;\r\n case 'X': aReturn='23'; break;\r\n case 'Y': aReturn='24'; break;\r\n case 'Z': aReturn='25'; break;\r\n case 'a': aReturn='26'; break;\r\n case 'b': aReturn='27'; break;\r\n case 'c': aReturn='28'; break;\r\n case 'd': aReturn='29'; break;\r\n case 'e': aReturn='30'; break;\r\n case 'f': aReturn='31'; break;\r\n case 'g': aReturn='32'; break;\r\n case 'h': aReturn='33'; break;\r\n case 'i': aReturn='34'; break;\r\n case 'j': aReturn='35'; break;\r\n case 'k': aReturn='36'; break;\r\n case 'l': aReturn='37'; break;\r\n case 'm': aReturn='38'; break;\r\n case 'n': aReturn='39'; break;\r\n case 'o': aReturn='40'; break;\r\n case 'p': aReturn='41'; break;\r\n case 'q': aReturn='42'; break;\r\n case 'r': aReturn='43'; break;\r\n case 's': aReturn='44'; break;\r\n case 't': aReturn='45'; break;\r\n case 'u': aReturn='46'; break;\r\n case 'v': aReturn='47'; break;\r\n case 'w': aReturn='48'; break;\r\n case 'x': aReturn='49'; break;\r\n case 'y': aReturn='50'; break;\r\n case 'z': aReturn='51'; break;\r\n case '0': aReturn='52'; break;\r\n case '1': aReturn='53'; break;\r\n case '2': aReturn='54'; break;\r\n case '3': aReturn='55'; break;\r\n case '4': aReturn='56'; break;\r\n case '5': aReturn='57'; break;\r\n case '6': aReturn='58'; break;\r\n case '7': aReturn='59'; break;\r\n case '8': aReturn='60'; break;\r\n case '9': aReturn='61'; break;\r\n case '+': aReturn='62'; break;\r\n case '/': aReturn='63'; break;\r\n default: aReturn=''; break;\r\n }\r\n }\r\n catch(err)\r\n {\r\n DebugLog(err.message.toString());\r\n }\r\n return aReturn;\r\n}", "title": "" }, { "docid": "1d6294e9e594599ba3e2ec31793cd873", "score": "0.5702257", "text": "function kaliTerusRekursif(angka) {\r\n // you can only write your code here!\r\n let angkaString = angka.toString();\r\n let hasil = kaliRekursif(angka);\r\n let hasilString = hasil.toString();\r\n if(hasilString.length > 1){\r\n hasil = kaliTerusRekursif(hasil);\r\n }\r\n return hasil;\r\n \r\n}", "title": "" }, { "docid": "5a106ad9b93227f2ee84a0b0317f188e", "score": "0.57020724", "text": "function saludo2(){\n return \"Hola buen dia 888\";\n }", "title": "" }, { "docid": "624d45b3d06c92e644f692c619556668", "score": "0.57002187", "text": "function a(e,a,t,n){var i=e+\" \";switch(t){case\"s\":return a||n?\"nekaj sekund\":\"nekaj sekundami\";case\"ss\":return i+=1===e?a?\"sekundo\":\"sekundi\":2===e?a||n?\"sekundi\":\"sekundah\":e<5?a||n?\"sekunde\":\"sekundah\":\"sekund\";case\"m\":return a?\"ena minuta\":\"eno minuto\";case\"mm\":return i+=1===e?a?\"minuta\":\"minuto\":2===e?a||n?\"minuti\":\"minutama\":e<5?a||n?\"minute\":\"minutami\":a||n?\"minut\":\"minutami\";case\"h\":return a?\"ena ura\":\"eno uro\";case\"hh\":return i+=1===e?a?\"ura\":\"uro\":2===e?a||n?\"uri\":\"urama\":e<5?a||n?\"ure\":\"urami\":a||n?\"ur\":\"urami\";case\"d\":return a||n?\"en dan\":\"enim dnem\";case\"dd\":return i+=1===e?a||n?\"dan\":\"dnem\":2===e?a||n?\"dni\":\"dnevoma\":a||n?\"dni\":\"dnevi\";case\"M\":return a||n?\"en mesec\":\"enim mesecem\";case\"MM\":return i+=1===e?a||n?\"mesec\":\"mesecem\":2===e?a||n?\"meseca\":\"mesecema\":e<5?a||n?\"mesece\":\"meseci\":a||n?\"mesecev\":\"meseci\";case\"y\":return a||n?\"eno leto\":\"enim letom\";case\"yy\":return i+=1===e?a||n?\"leto\":\"letom\":2===e?a||n?\"leti\":\"letoma\":e<5?a||n?\"leta\":\"leti\":a||n?\"let\":\"leti\"}}", "title": "" }, { "docid": "688fbe333bcb12b86ad479e0e5ffe662", "score": "0.56982243", "text": "function t(e,t,a,i){var r=e+\" \";switch(a){case\"s\":return t||i?\"nekaj sekund\":\"nekaj sekundami\";case\"ss\":return r+=1===e?t?\"sekundo\":\"sekundi\":2===e?t||i?\"sekundi\":\"sekundah\":e<5?t||i?\"sekunde\":\"sekundah\":\"sekund\",r;case\"m\":return t?\"ena minuta\":\"eno minuto\";case\"mm\":return r+=1===e?t?\"minuta\":\"minuto\":2===e?t||i?\"minuti\":\"minutama\":e<5?t||i?\"minute\":\"minutami\":t||i?\"minut\":\"minutami\",r;case\"h\":return t?\"ena ura\":\"eno uro\";case\"hh\":return r+=1===e?t?\"ura\":\"uro\":2===e?t||i?\"uri\":\"urama\":e<5?t||i?\"ure\":\"urami\":t||i?\"ur\":\"urami\",r;case\"d\":return t||i?\"en dan\":\"enim dnem\";case\"dd\":return r+=1===e?t||i?\"dan\":\"dnem\":2===e?t||i?\"dni\":\"dnevoma\":t||i?\"dni\":\"dnevi\",r;case\"M\":return t||i?\"en mesec\":\"enim mesecem\";case\"MM\":return r+=1===e?t||i?\"mesec\":\"mesecem\":2===e?t||i?\"meseca\":\"mesecema\":e<5?t||i?\"mesece\":\"meseci\":t||i?\"mesecev\":\"meseci\",r;case\"y\":return t||i?\"eno leto\":\"enim letom\";case\"yy\":return r+=1===e?t||i?\"leto\":\"letom\":2===e?t||i?\"leti\":\"letoma\":e<5?t||i?\"leta\":\"leti\":t||i?\"let\":\"leti\",r}}", "title": "" }, { "docid": "e5780afa86d2e61a4ce7f65c62a6d12a", "score": "0.5697596", "text": "function t(e,t,a,n){switch(a){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "e5780afa86d2e61a4ce7f65c62a6d12a", "score": "0.5697596", "text": "function t(e,t,a,n){switch(a){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" }, { "docid": "2727e13a10cd98e74eb147eb9a7e11c3", "score": "0.5692513", "text": "function t(e,t,n,a){switch(n){case\"s\":return t?\"хэдхэн секунд\":\"хэдхэн секундын\";case\"ss\":return e+(t?\" секунд\":\" секундын\");case\"m\":case\"mm\":return e+(t?\" минут\":\" минутын\");case\"h\":case\"hh\":return e+(t?\" цаг\":\" цагийн\");case\"d\":case\"dd\":return e+(t?\" өдөр\":\" өдрийн\");case\"M\":case\"MM\":return e+(t?\" сар\":\" сарын\");case\"y\":case\"yy\":return e+(t?\" жил\":\" жилийн\");default:return e}}", "title": "" } ]
ddc036eb348cf76f9d6fb8576915984a
get("/api/contacts/:id") endpoint not used by Angular app delete("/api/contacts/:id")
[ { "docid": "988fca31b0f63c817e8fd625f46859c5", "score": "0.66189337", "text": "deleteContact(delContactId: String): Promise<void | String> {\n return this.http.delete(this.contactsUrl + '/' + delContactId)\n .toPromise()\n .then(response => response.json() as String)\n .catch(this.handleError);\n }", "title": "" } ]
[ { "docid": "a8ad9567e5d3d11e28d5d9c5db17b8f5", "score": "0.6859458", "text": "delete(id) {\n return this.rest.delete(`${this.baseUrl}/${id}`);\n }", "title": "" }, { "docid": "a8ad9567e5d3d11e28d5d9c5db17b8f5", "score": "0.6859458", "text": "delete(id) {\n return this.rest.delete(`${this.baseUrl}/${id}`);\n }", "title": "" }, { "docid": "3ee1591f9736e5cc8db9f53e0e77d57e", "score": "0.6574619", "text": "Delete() {\n return {\n method: 'DELETE',\n path: '/contact/{id}',\n config: {\n description: 'delete contact item',\n notes: 'Deletes the contact item that has the id provided.',\n tags: ['api'],\n handler: (request, reply) => {\n return this.BaseDeleteHandler(this.GetCollectionName(), request.params.id)\n .then(() => {\n reply();\n })\n .catch((err) => {\n reply(Boom.wrap(err, 400));\n })\n },\n validate: {\n params: {\n id: joi.string().hex().required().description(\"Delete contact by id \"),\n }\n }\n }\n };\n }", "title": "" }, { "docid": "6524528e32dd37a94b96db377a70cab9", "score": "0.65552896", "text": "delete(req, res) {\n this._bookDao\n .delete(req.params.id)\n .then(() => res.status(200).end())\n .catch(console.error);\n }", "title": "" }, { "docid": "dc64a38dd5ffd4bb1750661cc2163b6a", "score": "0.64801365", "text": "initDeleteEndpoint() {\n this.router.delete('/:id', (req, res) =>\n this.getDAO().remove(req.params.id, { user: req.user }).then(result => {\n if (result === 0) {\n return this.sendErr(res, 404, 'Not found');\n }\n return res.status(200).send({ success: true });\n }).catch(err => {\n debug('[delete]', err.message);\n return this.sendErr(res, 400, err.message);\n }));\n }", "title": "" }, { "docid": "641fa7a4f777853aeb40e1964162257e", "score": "0.6459054", "text": "deleteCard(cardID) {\n return http.delete(`/cards/${cardID}`);// delete the card with the id passed\n }", "title": "" }, { "docid": "e0d112356c5f80cb3a0e016386326951", "score": "0.64210933", "text": "delete(name){\n return this.$http.delete('/api/user/' + name);\n }", "title": "" }, { "docid": "c726b95dcb109e7e4c0fcb46304aee35", "score": "0.64113444", "text": "delete(id) {\n return http.delete(`/removePuppy/${id}`);\n \n }", "title": "" }, { "docid": "ce46bf359e1d0111def9fc20ad5b279a", "score": "0.6408434", "text": "deleteObj(uri, id) {\n // Post options\n const httpOptions = {\n headers: new HttpHeaders({\n 'Authorization': 'Bearer ' + this.accessToken\n })\n };\n // Url\n const url = this.apiURL + uri + (id ? '/' + id : '');\n // Do request\n return this.httpClient\n .delete(url, httpOptions)\n .pipe(\n // Map response\n map(() => true));\n }", "title": "" }, { "docid": "60025e503d858916fb6177882b2a674b", "score": "0.6366267", "text": "deleteById(req, res) {\n Activity.findByIdAndRemove(req.params.id).then(result => {\n res.json(result);\n })\n .catch(err => {\n res.json(err);\n });\n }", "title": "" }, { "docid": "015438094788ec94fb72f9651830c5e9", "score": "0.63543826", "text": "delete(...args) {\n this.route('delete', ...args);\n }", "title": "" }, { "docid": "48d1b3b789d858d58c5d22048c7d86a3", "score": "0.63379085", "text": "function Delete(id) {\n\n $.ajax({\n url: Host+\"/api/contacts/deletecontact?id=\" + id,\n type: \"DELETE\",\n contentType: \"application/json;charset=UTF-8\",\n success: function (result) {\n location.reload();\n },\n error: function (errormessage) {\n alert(errormessage.responseText);\n }\n });\n\n}", "title": "" }, { "docid": "1b7ebff50a3e0aedc6e9c3a41c6f70fc", "score": "0.6336877", "text": "delete(req, res) {\n logging.logTheinfo(\"widgets delete Router\");\n res.status(200).send(\"delete\");\n\n }", "title": "" }, { "docid": "8a9362eb5b6c42731dd96f73b26f27b6", "score": "0.6232084", "text": "function deletePatient(id) {\n fetch(`http://localhost:3000/patients/${id}`, {\n method: 'DELETE'\n }).then(res => {\n if (!res.error) {\n location.reload()\n }\n }).catch(err => {\n console.log('Error during process ', err)\n })\n}", "title": "" }, { "docid": "461a0aead09a9a50f59aa20ab3d245b4", "score": "0.62068164", "text": "function deleteData(id) {\n url = 'http://localhost:3000/api/data/' + id;\n fetch(url, {\n method: 'DELETE',\n headers: {\n 'Content-Type': 'application/json'\n },\n redirect: 'follow',\n })\n .then((resp) => {\n getAll();\n })\n}", "title": "" }, { "docid": "c926d13ce8f51962be34103895e8a28b", "score": "0.61812174", "text": "deletePost(p) {\n return this.http.get(\"http://localhost:8080/api/posts/delete/\" + p.id);\n }", "title": "" }, { "docid": "2695878bdaa2d245a0b6f774ef31258b", "score": "0.61773455", "text": "@DELETE('/epics/:id')\n @websocket('epics', 'delete')\n @parameters('id')\n @authenticated\n async delete (ctx) {\n await super.delete({ ctx, databaseType: Epic })\n\n ctx.response.status = StatusCode.noContent\n return true\n }", "title": "" }, { "docid": "fd580343925302d1c5aa088de9268b41", "score": "0.61460626", "text": "delete(id) {\n return axios.delete(BuildUrl(this.apiPath), id).pipe(ErrorOnBadStatus);\n }", "title": "" }, { "docid": "6fd4c159ccf44ab955c5271e3a426eab", "score": "0.6145975", "text": "delete(req, res, next) {\n this.transactionService.delete(req.params.id)\n .then((data) => res.send(httpStatus.OK, data))\n .catch((error) => {\n res.send(httpStatus.InternalServerError, error);\n })\n .then(next);\n }", "title": "" }, { "docid": "10cd8b25e5e7952561e79bd75ef972ab", "score": "0.6139104", "text": "function deleteRoute(routeId) {\n return $http.delete(\"/api/route/\"+routeId)\n .then(function (response) {\n return response.data;\n });\n }", "title": "" }, { "docid": "9cbbdce4e32c91a7b2d25afdee420766", "score": "0.61156774", "text": "static delete( route, params, opts = { } ) {\n const options = { ...opts, method: \"delete\" };\n return iNaturalistAPI.post( route, params, options );\n }", "title": "" }, { "docid": "2ab6a08882121e6304500902751c6413", "score": "0.61151636", "text": "delete(uri, action) {\n\n this.route('DELETE', uri, action);\n }", "title": "" }, { "docid": "7acd307b604baab0dcab4bf549bf047b", "score": "0.6114412", "text": "static async delete(req, res) {\n\t\t\n\t\ttry {\n\t\t\t\n\t\t\tconst { id } = req.params\n console.log('here')\n\t\t\t\n\t\t\t// deleting student info\n\t\t\tawait studentService.Deleting(id)\n\n\t\t\t// create response\n\t\t\tconst response = {\n\t\t\t\tsuccess: true,\n\t\t\t}\n\n\t\t\tres.send(response)\n\t\t} catch (e) {\n\t\t\tres.send(e)\n\t\t}\n\t}", "title": "" }, { "docid": "e99199aafcda464ef11e9bd0bc541d09", "score": "0.6111822", "text": "function del(req, res, next) {\n req.url = `/${req.params.nested}/${req.params.nestedId}`\n next()\n }", "title": "" }, { "docid": "9d2a65f822995d67c525e936d9e1b415", "score": "0.61039937", "text": "function order_delete_get(req, res) {\n res.send('NOT IMPLEMENTED: order delete GET');\n}", "title": "" }, { "docid": "3008f83544e62d7e452a03bb9078242c", "score": "0.60974365", "text": "del(url, opt = {}) {\n opt.method = 'DELETE';\n return this.sendRequest(url, opt);\n }", "title": "" }, { "docid": "05dc17b7e56e498d37482a565b811fda", "score": "0.60959077", "text": "function _delete(id) {\n console.log(\"on delete service:\", id);\n const requestOptions = {\n method: \"DELETE\",\n headers: authHeader()\n };\n\n return fetch(`${getUrl(URL)}/${id}`, requestOptions).then(handleResponse);\n}", "title": "" }, { "docid": "42ee00c4c981977f7b8d1539c92bdf70", "score": "0.60932004", "text": "delete(resource, id) {\n const url = `${baseUrl}/${resource}/${id}/`\n return fetch(url, {\n method: \"DELETE\",\n headers: {\n \"Content-Type\": \"application/json\",\n \"Authorization\": `Token ${user.getToken()}`\n }\n })\n }", "title": "" }, { "docid": "57d7d84cc509f11b2e02dc0fd1e8a559", "score": "0.6080629", "text": "delete(req, res) {\n studentDAO.deleteStudent(db, req.params.studentID)\n .then(() => {\n res.sendStatus(204)\n })\n .catch(err => {\n console.error(err)\n res.sendStatus(404)\n })\n }", "title": "" }, { "docid": "d0f4addef96e756f187a0b0bee3cd9d7", "score": "0.60769635", "text": "delete(req, res) {\n const { index } = req.params\n \n if (!isValidIndex(index)) {\n return res.status(HTTP_NOT_FOUND).send()\n }\n\n const deletedResource = simpleDatabase.splice(index, 1)[0]\n\n return res.status(HTTP_OK).json(deletedResource)\n }", "title": "" }, { "docid": "1093a4b7e9703cedd4089079797af944", "score": "0.60740334", "text": "del(url, options) {\n return this.request(url, this._addTypeToOptionsFor(options, 'DELETE'));\n }", "title": "" }, { "docid": "2ae38b965b051da51212a598117452d0", "score": "0.6051183", "text": "async DeleteSingleDoctorService(req,res) {\n\n }", "title": "" }, { "docid": "dda2cec2958e83fed78b84cc0a643ba8", "score": "0.60387856", "text": "removePost(id){\n console.log(\"remove id:\" + id);\n fetch(\"http://localhost:8080/delete/\" + id, {\n method: 'DELETE',\n });\n }", "title": "" }, { "docid": "bdda046c57eb8d7049dd8a118981f6cc", "score": "0.6036663", "text": "delete() {\n\t\treturn this.fetch(baseApiURL + this.URIPath, { method: 'DELETE' });\n\t}", "title": "" }, { "docid": "5c097adcfbe7031128f7a202f187dee4", "score": "0.6023517", "text": "function removePerson(personid, userId){\n var promise = $http({\n method: 'DELETE',\n url:'/lovedones-delete/'+ personid + '/' + userId\n }).then(function successfulCallback(response){\n lovedones = response.data;\n }, function(error){\n console.log(error);\n });\n return promise;\n }", "title": "" }, { "docid": "a5a2f357a349312f7f02bc14c495b4ee", "score": "0.6022639", "text": "function _delete(id) {\n\n return axios.delete('https://reqres.in/api/users/'+id)\n .then(resp => {\n return resp;\n }).catch(err => {\n console.log(err);\n throw err;\n });\n // return fetch(`${config.apiUrl}/users/${id}`, requestOptions).then(handleResponse);\n}", "title": "" }, { "docid": "af44d3cc1509c1ddd3eff037027e5eaf", "score": "0.6007935", "text": "async destroy(req, res){\n let endereco = await Endereco.deleteOne({_id : req.params.id});\n return res.json(Endereco);\n }", "title": "" }, { "docid": "ab876f69f45c3e805fcaece2713f9722", "score": "0.600629", "text": "delete(req, res) {\n Item.destroy({\n where: {\n id: req.params.id\n }\n })\n .then((deletedRecords) => {\n res.status(200).json(deletedRecords);\n })\n .catch((error) => {\n res.status(500).json(error);\n });\n }", "title": "" }, { "docid": "b5a1a6ddcdaccaef362521285b8c2fea", "score": "0.60030985", "text": "deleteContactById(id) {\n let index = this.contacts.findIndex(contact => contact.id === id)\n let deleteObject = this.contacts[index]\n this.contacts = this.contacts.filter(contact => contact.id !== id)\n\n return deleteObject\n }", "title": "" }, { "docid": "ff5385d07d62e4ab5af133d7c2dad790", "score": "0.59830594", "text": "handleDelete(id){\n const request = new Request();\n const url = '/api/journalists/' + id;\n request.delete(url).then(() => {\n window.location = '/journalists'\n })\n }", "title": "" }, { "docid": "d3073fa46662dbdb3b8fa2a2edecc8b8", "score": "0.5960609", "text": "delete(req, res) {\n Hotel.remove({_id: req.params.id}, function(err, result) {\n if (err) {\n return res.send(err);\n }\n return res.json(results);\n });\n }", "title": "" }, { "docid": "19bb20745e2a7cb4eb2edd49d2cbefc1", "score": "0.5949159", "text": "del(url, data) {\n return fetch(this.baseURL + url, {\n method: \"DELETE\",\n headers: {\n Accept: \"application/json\",\n \"Content-Type\": \"application/json\",\n },\n body: JSON.stringify(data),\n })\n .then((response) => response.json());\n }", "title": "" }, { "docid": "3efede2744470f5c6f58f3045eb7b7ea", "score": "0.5945382", "text": "delete(id, query_params = {}) {\n const key = `delete|${id}`;\n const query = Object(_api__WEBPACK_IMPORTED_MODULE_5__[\"toQueryString\"])(query_params);\n if (!this._promises[key]) {\n this._promises[key] = new Promise((resolve, reject) => {\n const url = `${this.route()}/${id}${query ? '?' + query : ''}`;\n Object(_placeos_ts_client__WEBPACK_IMPORTED_MODULE_2__[\"del\"])(url).subscribe((_) => null, (e) => reject(e), () => {\n resolve();\n });\n });\n }\n return this._promises[key];\n }", "title": "" }, { "docid": "3868640de13d3e87d104dd87026acf56", "score": "0.5944481", "text": "deleteCustomer(params) {\r\n return Api().delete('/customers/' + params)\r\n }", "title": "" }, { "docid": "715faf83bd093f58ef322cfd9de7a142", "score": "0.59354335", "text": "deleteComponent({ type, path }, fetchParams) {\n const url = `/api/${type}/${path}/delete`;\n const errorMessage = `Error deleting ${type}`;\n return this.post(url, \"\", fetchParams, errorMessage)\n .then( response => response.json() );\n }", "title": "" }, { "docid": "cb2f6320f790fbe727cbb5caf68ec0b3", "score": "0.5935012", "text": "del(url, data) {\n return fetch(this.getBaseURL() + url, {\n method: \"DELETE\",\n headers: {\n Accept: \"application/json\",\n \"Content-Type\": \"application/json\",\n },\n body: JSON.stringify(data),\n })\n .then((response) => response.json());\n }", "title": "" }, { "docid": "749c8d12bfab3509d1ce8e84793b5ac1", "score": "0.59304494", "text": "delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }", "title": "" }, { "docid": "f389919b6213520e74e47f3f9138dd45", "score": "0.59143984", "text": "function _delete(id) {\n\treturn fetchHelper.httpDelete('/users/${id}');\n}", "title": "" }, { "docid": "90cf7fb44f22ef92e62a3807254a00d7", "score": "0.5914312", "text": "deleteData(resource,resourceId) {\n return fetch(`http://localhost:8088/${resource}/${resourceId}`, {\n method: \"DELETE\",\n headers: {\n \"Content-Type\": \"application/json\"\n },\n})\n}", "title": "" }, { "docid": "b09ffb08cf87448889520edade80c887", "score": "0.5895559", "text": "function deletepeople(req, res) {\n \n var peopleId = req.params.id;\n people.findByIdAndRemove(peopleId, (err, peopleRemoved) => {\n if (err) {\n res.status(500).send({\n message: \"error en la petición para eliminar el people\"\n });\n } else {\n if (!peopleRemoved) {\n res.status(404).send({\n message: \"el people no se pudo eliminar\"\n });\n } else {\n \n res.status(200).send({\n peopleRemoved\n }); \n }\n }\n }); \n}", "title": "" }, { "docid": "515a8a7def81290b3f846dc565a02d9a", "score": "0.58921313", "text": "function deleteEmployee(req,res){\n console.log('deleting employee ' ,req.params.id);\n userService.deleteEmployee(req.params.id)\n .then(function () {\n res.sendStatus(200);\n })\n .catch(function (err) {\n res.status(400).send(err);\n });\n}", "title": "" }, { "docid": "19ff60514d41f47b2aee991a003ca563", "score": "0.589152", "text": "DeleteUser(req, res) {\n let email = req.params['id'];\n this.UserDB.delete({ email })\n .then(result => res.status(200).json(result))\n .catch(error => res.status(404));\n }", "title": "" }, { "docid": "e401185cddb850a17f3199e313b0bd53", "score": "0.588953", "text": "del(url, options) {\n return this.request(url, this._addTypeToOptionsFor(options, 'DELETE'));\n }", "title": "" }, { "docid": "2ba97814c308f14dfa02c78e24291d77", "score": "0.5886742", "text": "function deleteUser() {\n request('http://localhost:3333/api/users/' + document.getElementById(\"id\").value, \"DELETE\");\n}", "title": "" }, { "docid": "22983fc9c3716df6eee407d780c72618", "score": "0.5879324", "text": "function _delete(id) {\n const requestOptions = {\n method: 'DELETE',\n headers: authHeader()\n };\n\n}", "title": "" }, { "docid": "522ed5545855b8372aede6f923080c73", "score": "0.5874182", "text": "deleteById(req, res) {\n this.Model\n .destroy({where: {id: req.params.id}})\n .then(item => {\n let responseCode = 0;\n\n if (item === 0) {\n responseCode = -2;\n }\n\n return Response.create(res, responseCode, []);\n })\n .catch(err => {\n return Response.create(res, -1, err);\n });\n }", "title": "" }, { "docid": "d17dfbd1c25e69a015eaa4a4f6208944", "score": "0.5866154", "text": "delete(id) {\n if (!id) {\n return Promise.reject(new Error('invalid_id'));\n }\n return this.iugu.makeRequest('DELETE', `/customers/${id}`).begin();\n }", "title": "" }, { "docid": "8ee18cf86aa14349d875cf680e7e6c96", "score": "0.5864399", "text": "function _delete(id) {\n const requestOptions = {\n method: \"DELETE\",\n headers: requestHeaders(),\n };\n\n return fetch(`${config.apiHost}/employees/${id}`, requestOptions).then(\n handleResponse\n );\n}", "title": "" }, { "docid": "4571f253d5539126dfe358620cb11a05", "score": "0.5855489", "text": "static delete(req, res) {\n const { id } = req.params\n\n Article.destroy({\n where: { id },\n })\n .then((deletedData) => {\n if (!deletedData) throw { status: 404, message: 'Article not found!' }\n\n res.status(200).json({ message: 'Successfully delete article!' })\n })\n .catch((err) => {\n if (err.status) {\n res.status(err.status).json({ message: err.message })\n } else {\n res\n .status(500)\n .json({ message: err.message || 'internal error server' })\n }\n })\n }", "title": "" }, { "docid": "303f3f0e00facd274e0fc92a839325bc", "score": "0.58547986", "text": "function estDeleteId(req, res, next) {\n try {\n console.log('apiREST params', req.params);\n console.log('apiREST query', req.query);\n console.log('apiREST body', req.body);\n\n let sql = 'SELECT * FROM personas';\n con.query(sql,[], function(err,result) {\n if(err) {\n // Enviar error SQL\n console.error('ERR',err.message);\n res.status(500).send({\n finalizado: true,\n mensaje: 'delete Error SQL',\n });\n } else {\n // Manipular resultados\n res.status(200).send({\n finalizado: true,\n mensaje: 'delete OK',\n datos: result,\n });\n }\n\t\t});\n\n } catch(e) {\n console.log('ERROR', e);\n res.status(501).send({\n finalizado: true,\n mensaje: 'delete Error',\n });\n }\n}", "title": "" }, { "docid": "6b31dfa6ecd3a1ae311b1f92ce02108b", "score": "0.5849651", "text": "function deleteEmployee(employeeId) {\n $http({\n method: 'DELETE',\n url: '/employee/' + employeeId\n }).then(function(response) {\n getEmployee();\n });\n }", "title": "" }, { "docid": "2df60dbfa6841dde34666ff9672b8ca5", "score": "0.5831137", "text": "deleteSupplier(params){\r\n return Api().delete('/suppliers/' + params)\r\n }", "title": "" }, { "docid": "8f76f72ed28ddd34a8dee32619414c38", "score": "0.5824273", "text": "async destroy (req, res, id) {\n throw new Error('destroy: Implementation Missing!')\n }", "title": "" }, { "docid": "21650652432ce4bbd0d6775fd2d643d5", "score": "0.58227175", "text": "async delete({request, response, params: {id}}) {\n\n const name = await nameService.findNameBy('id', id);\n\n if (name) {\n\n name.delete()\n\n return response.status(200).send({\n status: 200,\n message: \"name deleted\"\n })\n }\n else{\n return response.status(400).send({\n status: 400,\n message: \"invalid name id\"\n })\n }\n }", "title": "" }, { "docid": "64e53c3ebfbb6a307fd367fbae425562", "score": "0.5820343", "text": "function _delete(id) {\n const requestOptions = {\n method: 'DELETE',\n headers: authHeader()\n };\n\n return fetch(`http://restservices.itcodesolutions.com/api/v1/auth/users/${id}`, requestOptions).then(handleResponse);\n}", "title": "" }, { "docid": "2b85b462f3a5a3b8c17a8c813d59c32f", "score": "0.58181345", "text": "function _delete(id) {\n const requestOptions = {\n method: 'DELETE',\n headers: authHeader()\n };\n\n return fetch(`${apiUrl}employee/delete/${id}`, requestOptions).then(handleResponse);\n}", "title": "" }, { "docid": "cccd036e92b070fe0bc498b28b0af336", "score": "0.581779", "text": "delete(url, requestOptions = {}) {\n return this.request({ ...requestOptions,\n url,\n method: \"DELETE\"\n });\n }", "title": "" }, { "docid": "958839d9147780e19f23a9db8dbf7e46", "score": "0.58124363", "text": "delete () {\n this.app.delete('/event/destroy/:id', this.jwt.verifyOrganizerToken(), (req, res) => {\n try {\n this.EventModel.findByIdAndRemove(req.params.id).exec().then(event => {\n res.status(200).json(event || {})\n }).catch(err => {\n res.status(404).json({\n code: 404,\n message: err + `Cannot delete Event with id=${req.params.id}.`\n })\n })\n } catch (err) {\n res.status(500).json({\n code: 500,\n message: err\n })\n }\n })\n }", "title": "" }, { "docid": "e65080e3bd578a5de3fb56a703f6b7d6", "score": "0.5809755", "text": "delete(req, res) {\n RegistroEstudo.destroy({\n where: {\n id: req.params.id\n }\n })\n .then(function (deletedRecords) {\n res.status(200).json(deletedRecords);\n })\n .catch(function (error) {\n res.status(500).json(error);\n });\n }", "title": "" }, { "docid": "b079398939062fa99d80bc99015cf8b5", "score": "0.5807943", "text": "function _delete(id) {\n const requestOptions = {\n method: 'DELETE',\n headers: authHeader()\n };\n\n return fetch('/users/' + id, requestOptions).then(handleResponse);;\n}", "title": "" }, { "docid": "a2922b7a3b1a049df732b916baaa7dcc", "score": "0.57980955", "text": "function removeFriend( id ) {\n var request = $http({\n method: \"delete\",\n url: \"api/index.cfm\",\n params: {\n action: \"delete\"\n },\n data: {\n id: id\n }\n });\n return( request.then( handleSuccess, handleError ) );\n }", "title": "" }, { "docid": "097125fea21a86b971380b0fab48d001", "score": "0.57940656", "text": "deleteAppointment(id) {\n return axios.delete(`/api/appointments/${id}`);\n }", "title": "" }, { "docid": "70f4159e2c91b4c4da7312f52b75c21a", "score": "0.579312", "text": "async destroy(req, resp) {\n try {\n const { id } = req.params;\n\n let del = await Dev.findByIdAndRemove(req.params.id);\n\n if (!del) {\n return resp.status(404).json(`ID ${id} não encontrado na base`);\n } else {\n return resp.status(200).json(`Deletado com sucesso o id ${id}`);\n }\n } catch (err) {\n return resp.status(500).json(err);\n }\n }", "title": "" }, { "docid": "36c73ff6d8d527cc22310f9b0b27043e", "score": "0.5791969", "text": "async deleteservice({\n view,\n request,\n session,\n response\n }) {\n if (request.ajax()) {\n const id = request.input('id')\n const service = await Service.find(id)\n await service.delete()\n\n response.send({\n status: 'success'\n })\n } else {\n return 'Bad request Type...';\n }\n\n }", "title": "" }, { "docid": "0fa3c70105732eb9cbf8f7caee0d60ca", "score": "0.57907945", "text": "deleteById(req, res) {\n let id = req.params.id;\n\n this.userdao.deleteById(id)\n .then(this.common.editSuccess(res))\n .catch(this.common.serverError(res));\n }", "title": "" }, { "docid": "e22d7b727b82108fcebc919ecbcd7b9d", "score": "0.57851917", "text": "function deleteContact(contact) {\n var future = $q.defer();\n $http.post('/contacts/deleteContact', contact).success(function (data) {\n future.resolve(data);\n }, function (err) { future.reject(err); });\n return future.promise;\n }", "title": "" }, { "docid": "6e2b53dde07aebc3b3591e40188a94de", "score": "0.5784684", "text": "function _delete(id) {\n const requestOptions = {\n method: \"DELETE\",\n headers: authHeader(),\n };\n\n return fetch(`${config.apiUrl}/todos/${id}`, requestOptions)\n .then(handleResponse)\n .catch((error) => {\n throw error;\n });\n}", "title": "" }, { "docid": "294f15f88a3f912e6754025785052a2c", "score": "0.57821035", "text": "function deleteUser(userId){\n var url = \"/api/user/\"+userId;\n return $http.delete(url);\n\n }", "title": "" }, { "docid": "93ca8d48012239aa755adec2fd690692", "score": "0.57796377", "text": "function remove(id) {\n\t\t\treturn $http({\n\t\t\t\turl: 'api/comercios/' + id,\n\t\t\t\tmethod: \"DELETE\"\n\t\t\t}).then(\n\t\t\t\tfunction success(response) {\n\t\t\t\t\treturn response.data;\n\t\t\t\t},\n\t\t\t\tfunction error(error) {\n\t\t\t\t\treturn error.data;\n\t\t\t\t});\n\t\t}", "title": "" }, { "docid": "42677d16583d54bd5f0459d418556fc4", "score": "0.5779444", "text": "removeProduct(id) {\n API.delete(`${this.productsRoute}${id}`);\n }", "title": "" }, { "docid": "0d0d58be93ec0fc5eddf37cb8204ec1c", "score": "0.5776515", "text": "delete(params)\n {\n let opts = this.buildCallOpts({method:'DELETE'});\n return this.doRequest({method: 'DELETE'}, params._id, params);\n }", "title": "" }, { "docid": "13457951d63f2c8160cabca6b6f597fc", "score": "0.57727575", "text": "function deleteBlog(req,res){\n res.header(\"Access-Control-Allow-Origin\", \"*\");\n const {id} = req.query;\n blogModel.deleteBlogFromDB(id).then((result)=>{\n res.status(200).send(result);\n },(error)=>{\n res.status(200).send(error);\n });\n}", "title": "" }, { "docid": "adcb0b84dc497a64201de5ebaaa69859", "score": "0.5769883", "text": "async delete(req, res) {\n try {\n const id = await userRepository.delete(req.params.id);\n res.json('deleted user. redirect to website landing page');\n } catch (err) {\n console.log('error', err);\n }\n }", "title": "" }, { "docid": "5f8e9c534ffd65483915d7e3f352adce", "score": "0.5767898", "text": "delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }", "title": "" }, { "docid": "5f8e9c534ffd65483915d7e3f352adce", "score": "0.5767898", "text": "delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }", "title": "" }, { "docid": "5f8e9c534ffd65483915d7e3f352adce", "score": "0.5767898", "text": "delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }", "title": "" }, { "docid": "5f8e9c534ffd65483915d7e3f352adce", "score": "0.5767898", "text": "delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }", "title": "" }, { "docid": "5f8e9c534ffd65483915d7e3f352adce", "score": "0.5767898", "text": "delete(url, options = {}) {\n return this.request('DELETE', url, options);\n }", "title": "" }, { "docid": "5e1261aaa2c2796622b20eaa0d2c6596", "score": "0.5766162", "text": "destroyTask(id) {\n fetch('http://localhost:9000/task/:id', {\n method: 'DELETE',\n body: JSON.stringify({\n id: id\n }),\n headers: { \"Content-Type\": \"application/json\" }\n })\n .then(function (response) {\n return response.json()\n });\n }", "title": "" }, { "docid": "775b73bea05aa2b21dc1acbe0a3a2909", "score": "0.57651377", "text": "function deleteUser(id) {\n var url = \"/api/user\" + id;\n return $http.delete(url);\n }", "title": "" }, { "docid": "63a00f117a3619618b8b9c6bd0276cec", "score": "0.57606685", "text": "function todoDelete(id) {\n \t// Inititate the promise to be returned.\n \tvar defer = $q.defer();\n \t// Use $http.delete to put the generated API key to use, for the delete function.\n \t$http.delete('http://localhost:60401/api/VSTDAs' + '/' + id). then(\n \t\t// If the promise succeeds, return the data using the following code.\n \t\tfunction(response) {\n \t\t\tdefer.resolve(response.data);\n \t\t},\n \t\t// If the promise fails, reject the data using the following.\n \t\tfunction(error) {\n \t\t\tdefer.reject(error);\n \t\t}\n \t);\n \treturn defer.promise;\t\n }", "title": "" }, { "docid": "ec3a957d314ffa228a5aaae1bc5d7737", "score": "0.57578266", "text": "static test_delete(id) {\n return CourseModel.send_delete(\"/courses/\" + id + \"?query_only=true\")\n }", "title": "" }, { "docid": "b6cee25a31f1d81c63942cedc835f3b8", "score": "0.57510334", "text": "function deleteInvoice(req, res, next) {\n\n var id = req.swagger.params.id.value;\n var status = req.swagger.params.status.value;\n InvoiceService.deleteInvoice(id, status)\n .then(function (response) {\n res.json(response);\n })\n .catch(function (response) {\n var statusCode = response.statusCode;\n var msg = response.message;\n res.status(statusCode).send({ message: msg });\n }); \n }", "title": "" }, { "docid": "b69b341b00bd6f8457a652b8961dbe64", "score": "0.57486874", "text": "static deleteById(req, res) {\n\t\t//delete referensi di user dulu\n\t\tUser.findByIdAndUpdate(req.headers.userId, {\n\t\t\t$pull: { userTodos: { $in: ObjectId(req.params.todoId) } }\n\t\t})\n\t\t\t.exec()\n\t\t\t.then(deleteResponse => {\n\t\t\t\tres.json(deleteResponse);\n\t\t\t\t///return Todo.findByIdAndRemove(ObjectId(req.params.todoId));\n\t\t\t})\n\t\t\t.then(response => {\n\t\t\t\tres.status(200).json({\n\t\t\t\t\tmessage: \"Todo Deleted\"\n\t\t\t\t});\n\t\t\t})\n\t\t\t.catch(err => {\n\t\t\t\tres.status(400).json({\n\t\t\t\t\tmessage: err.message,\n\t\t\t\t\tdata: err\n\t\t\t\t});\n\t\t\t});\n\t}", "title": "" }, { "docid": "aacf5ace3d992689c5e71251ba121168", "score": "0.5744646", "text": "function handleDelete(id) {\n fetch(`/products/${id}`, {\n method: 'delete',\n headers: {\n 'Content-Type': 'application/json',\n },\n })\n .then((res) => {\n return res.json()\n })\n .then((data) => {\n console.log(data);\n })\n .catch(function () {\n console.log(\"error fetch destroy\");\n });\n }", "title": "" }, { "docid": "c0e3ce0402fbef16ff0597d6b8a9ec2f", "score": "0.5738811", "text": "async deleteTodo(req, res) {\n try {\n const deleteTodo = await Todo.findByIdAndRemove(req.query.id);\n if (deleteTodo) {\n return res.send({ message: SUCCESS });\n } else {\n return res.status({ message: FAILED });\n }\n } catch (error) {\n return res.status(500).send(error);\n }\n }", "title": "" }, { "docid": "d15e8a784eb626ac59572cd86b27de36", "score": "0.5735774", "text": "function deleteContact() {\n $.ajax({\n url: apiUrl+anime._id+\"/\",\n type: 'DELETE',\n success: function (data) {\n window.location.href = \"./index.html\";\n },\n error: function (request, status, error) {\n console.log(error, status, request);\n },\n complete: function(){return;}\n });\n return;\n }", "title": "" }, { "docid": "a23f2d9c190c67468732acf44ba3b792", "score": "0.5730965", "text": "async destroy(req, res) {\r\n const bill = await Bill.findByIdAndRemove(req.params.id);\r\n return res.json(bill);\r\n }", "title": "" }, { "docid": "1684642a12a3c823b59d7b5671a0d8f1", "score": "0.5730304", "text": "function deleteCompany(companyId) {\n var path = \"/api/company/\" + companyId;\n return fetch(path, {\n method: \"DELETE\",\n headers: new Headers({\n \"Content-Type\": \"application/json\",\n }),\n credentials: \"include\",\n })\n .then((response) => {\n return response.json;\n })\n .catch((err) => {\n console.log(err);\n });\n}", "title": "" }, { "docid": "ce06f24412af55f139c804fc740f6886", "score": "0.5725589", "text": "delete(req, res) {\n Player.findByIdAndDelete(req.params.id)\n .then(deletedPlayer => res.json(deletedPlayer))\n .catch(err => res.status(400).json(err));\n }", "title": "" } ]
24fa5dfb329ca2a0857f02f0916c5c0d
Set table head fixed
[ { "docid": "ac18130d4b2e00e52f240c2f6336666d", "score": "0.776801", "text": "function fixHead() {\n var thead = $(settings.table).find(\"thead\");\n var tr = thead.find(\"tr\");\n var cells = thead.find(\"tr > *\");\n\n setBackground(cells);\n cells.css({\n 'position': 'relative'\n });\n }", "title": "" } ]
[ { "docid": "872489073b3f1a0d7572b44866bfb740", "score": "0.7341591", "text": "setTableHeader() {\n if (this.$el.parent().length > 0) {\n let $tableCopy = null;\n this.$el.parent().height(this.settings.options.tableContainerHeight);\n this.$el.addClass('fixed');\n $tableCopy = this.$el.clone(true, true);\n $tableCopy.attr('id', $tableCopy.attr('id') + '_');\n $tableCopy.find('tbody, tfoot').remove();\n $tableCopy.css({\n position: 'absolute',\n 'background-color': this.settings.options.tableHeaderColor,\n border: this.$el.find('th').eq(1).css('border-left'),\n 'z-index': 1\n });\n this.$scroll.prepend($tableCopy);\n this.$el.find('thead').hide();\n this.$el.css('margin-top', $tableCopy.find('thead').height());\n }\n }", "title": "" }, { "docid": "b0c7c06bfcc131e24f28294a9e5ee955", "score": "0.6722066", "text": "function fixTableHeader(table) {\n\n // if already executed, re-calculate header width\n var newTable = $('#' + table.attr('id') + '-thead');\n if (newTable.length) {\n newTable.attr('style', 'width:' + (table.width() + 1) + 'px; margin-left:' + table.offset().left + 'px; top:' + themeConfig.navbarHeight + 'px;');\n return;\n }\n\n // clone table\n newTable = table.clone();\n\n // remove tbody\n newTable.children('tbody').remove();\n\n // change id to avoid conflicts\n newTable.attr('id', newTable.attr('id') + '-thead')\n .addClass('table-header-fixed hidden');\n\n // insert before current table\n newTable.insertBefore(table);\n\n // events\n $(window).on('scroll', function () {\n\n if (isOnScreen(table))\n newTable.addClass('hidden').removeClass('table-header-fixed');\n else\n newTable.addClass('table-header-fixed').removeClass('hidden');\n\n });\n\n // init fix header\n if (isOnScreen(table))\n newTable.addClass('hidden').removeClass('table-header-fixed');\n else\n newTable.addClass('table-header-fixed').removeClass('hidden');\n\n var tableLeft = table.offset().left;\n var tableWidth = table.width() + 1;\n newTable.attr('style', 'width:' + tableWidth + 'px; margin-left:' + tableLeft + 'px; top:' + themeConfig.navbarHeight + 'px;');\n\n setTimeout(function () {\n tableLeft = table.offset().left;\n tableWidth = table.width() + 1;\n newTable.attr('style', 'width:' + tableWidth + 'px; margin-left:' + tableLeft + 'px; top:' + themeConfig.navbarHeight + 'px;');\n }, 0);\n\n $(window).on('resize', function () {\n tableLeft = table.offset().left;\n tableWidth = table.width() + 1;\n newTable.attr('style', 'width:' + tableWidth + 'px; margin-left:' + tableLeft + 'px; top:' + themeConfig.navbarHeight + 'px;');\n });\n\n}", "title": "" }, { "docid": "b0f7492ea2641363579cb427522ec0d6", "score": "0.6668006", "text": "resizeFixed(){\n this.requestTick(()=>{\n this._meta.offsetHeight = this.header.offsetHeight;\n this._meta.ticking=false;\n this.scrollFixed(); // to compensate top offset in case after resize the table is less in height and top has changed\n })\n }", "title": "" }, { "docid": "f2a0062412769b3978ff94033b9f4417", "score": "0.660067", "text": "function adjustScrollTable() {\n $(\".n-table-scrollbar\").each(function () {\n var colspanTotal = $(this).closest(\"table.n-table\").find(\"thead th\").length;\n var scrollTablePrifx = \"<tr><th colspan='\" + colspanTotal + \"' style='padding: 0; border:none; border-bottom-left-radius: 7px; border-bottom-right-radius: 7px;'><table class='n-table-scrollbar'>\";\n var scrollTableSuffix = \"</table></th></tr>\";\n var scrollTableHtml = $(this).html();\n\n $(this).html(scrollTablePrifx + scrollTableHtml + scrollTableSuffix);\n $(this).removeClass(\"n-table-scrollbar\");\n });\n }", "title": "" }, { "docid": "4d524870c2b3010305892a494ebb40b7", "score": "0.65797067", "text": "function initTableFixed() {\n\n var fcBody = document.querySelector(\".tbl-fixed .fix-column > .tbody\"),\n rcBody = document.querySelector(\".tbl-fixed .rest-columns > .tbody\"),\n rcHead = document.querySelector(\".tbl-fixed .rest-columns > .thead\");\n\n // adjust width of columns\n // \n // if columns don't occupy full width, expand them\n // \n var firstRow = $(rcBody).children()[0],\n firstRowSize = firstRow.getBoundingClientRect(),\n rcBodySize = $(rcBody)[0].getBoundingClientRect(),\n colSize = 120,\n offset = 10;\n\n if (rcBodySize.width > firstRowSize.width) {\n colSize = (rcBodySize.width / $(firstRow).children().length) - offset;\n\n $('.tbl-fixed .rest-columns > .tbody > .trow > span').each(function(){\n $(this).css('width', colSize);\n });\n\n $('.tbl-fixed .rest-columns > .thead > span').each(function(){\n $(this).css('width', colSize);\n });\n }\n\n\n rcBody.addEventListener(\"scroll\", function() {\n fcBody.scrollTop = this.scrollTop;\n rcHead.scrollLeft = this.scrollLeft;\n }, { passive: true });\n}", "title": "" }, { "docid": "1cfcbd6d418c83ecefc617d6bd47a55f", "score": "0.6544111", "text": "function staticHeader(tableName){\n\t\ttable = $(tableName);\n\t\ttable.after(\"<table id='header-fixed'></table>\")\n\t\tvar tableOffset = table.offset().top;\n\t\tvar $header = $(\"#table-1 > thead\").clone();\n\t\tvar $fixedHeader = $(\"#header-fixed\").append($header);\n\n\t\t$(window).bind(\"scroll\", function() {\n\t\t var offset = $(this).scrollTop();\n\t\t if (offset >= tableOffset && $fixedHeader.is(\":hidden\")) {\n\t\t $fixedHeader.show();\n\t\t }\n\t\t else if (offset < tableOffset) {\n\t\t $fixedHeader.hide();\n\t\t }\n\t\t});\n\t}", "title": "" }, { "docid": "6250ee05702b9933738795febb6cad71", "score": "0.6395149", "text": "function fixedHeader() {\n //take tables offset and tableHead\n let table = document.getElementById(\"myTable\");\n let tHead = document.getElementsByTagName(\"thead\");\n let tableWrapper = document.getElementById(\"myTable_wrapper\");\n let td = document.getElementsByClassName(\"hiddenDataTd\");\n //on scroll move header with content like a position fixed\n $(tableWrapper).bind(\"scroll\", function () {\n let offset = $(this).scrollTop();\n if (offset >= table.offsetTop - 30) {\n tHead[0].style.cssText = \"transform: translateY(\" + offset + \"px)\";\n } else if (offset < table.offsetTop) {\n tHead[0].style.cssText = \"transform: translateY(0)\";\n }\n for (let i = 0; i < td.length; i++) {\n if (offset >= td[i].offsetTop - 110) {\n let fullData = td[i];\n console.log(offset);\n console.log(td[i].offsetTop);\n\n fullData.style.cssText = \"visibility: hidden\";\n } else {\n let fullData = td[i];\n fullData.style.cssText = \"visibility: visible\";\n }\n }\n paginate();\n });\n}", "title": "" }, { "docid": "c38dd7afa3e584c6f057c0a6b8f75622", "score": "0.63896143", "text": "function controlTableWidth(obj) {\n var windowWidth = window.parent.innerWidth || window.parent.document.documentElement.clientWidth || window.parent.document.body.clientWidth;\n var tableWidth = windowWidth * 0.96 - 120;\n var fixedColWidth = obj.find('.table-hd').width();\n obj.find('.table-body').css('width',tableWidth - fixedColWidth);\n}", "title": "" }, { "docid": "39f516a2bbdeb9c053bf06ff2a40d8ec", "score": "0.6340072", "text": "function _fix_table_heads(table)\n {\n var sizer_tr = {left:null, top:null, wide:null, high:null};\n var sizer_td = {left:null, top:null, wide:null, high:null};\n var sizer_th = {left:null, top:null, wide:null, high:null};\n\n function reposition_element(ref, flo, sizer)\n {\n var ref_par = ref.parentNode;\n var os = SFW.get_relative_offset(ref, ref_par);\n flo.style.left = SFW.px(os.left + sizer.left);\n flo.style.top = SFW.px(os.top + sizer.top);\n }\n\n function resize_element(ref, flo, sizer)\n {\n flo.style.height = SFW.px(ref.offsetHeight + sizer.high);\n flo.style.width = SFW.px(ref.offsetWidth + sizer.wide);\n }\n\n function calculate_sizer(ref, flo, sizer)\n {\n sizer.left = ref.clientLeft - flo.clientLeft;\n sizer.top = ref.clientTop - flo.clientTop;\n\n sizer.wide = ref.clientWidth - flo.clientWidth;\n sizer.high = ref.clientHeight - flo.clientHeight;\n }\n\n function align_cells(ref, flo)\n {\n var r,f,i;\n\n r = SFW.first_child_element(ref);\n f = SFW.first_child_element(flo);\n\n if (!r || !f)\n return;\n\n var sizer = null;\n switch(r.tagName.toLowerCase())\n {\n case \"th\": sizer = sizer_th; break;\n case \"td\": sizer = sizer_td; break;\n }\n\n if (sizer.wide==null)\n {\n reposition_element(r,f,sizer);\n resize_element(r,f,sizer);\n calculate_sizer(r,f,sizer);\n }\n\n while (r && f)\n {\n reposition_element(r,f,sizer);\n resize_element(r,f,sizer);\n\n r = SFW.next_sibling_element(r);\n f = SFW.next_sibling_element(f);\n }\n }\n\n function align_pair(ref, flo)\n {\n var sizer = null;\n switch(ref.tagName.toLowerCase())\n {\n case \"tr\": sizer = sizer_tr; break;\n case \"th\": sizer = sizer_th; break;\n case \"td\": sizer = sizer_td; break;\n }\n \n var osref = SFW.get_doc_offset(ref);\n flo.style.left = SFW.px(osref.left);\n flo.style.top = SFW.px(osref.top);\n resize_element(ref,flo,sizer);\n\n if (sizer.high===null)\n {\n calculate_sizer(ref,flo,sizer);\n\n if (sizer.left || sizer.top)\n reposition_element(ref,flo,sizer);\n if (sizer.wide || sizer.high)\n resize_element(ref,flo,sizer);\n }\n\n var first = SFW.first_child_element(ref);\n if (first)\n {\n var ftag = first.tagName.toLowerCase();\n if (ftag==\"th\" || ftag==\"td\")\n align_cells(ref, flo);\n }\n\n flo.style.visibility = \"visible\";\n }\n\n var re_headfix = /headfix_\\S+/;\n function align_paired_rows(thead)\n {\n var match, classname, trmatch;\n var currow = SFW.first_child_element(thead);\n while (currow)\n {\n if (is_tr_el(currow) && class_includes(currow,\"floater\"))\n if ((match=currow.className.match(re_headfix)) && (classname=match[0]))\n if ((trmatch=find_matched_headfix_row(currow, classname)))\n align_pair(trmatch,currow,sizer_tr);\n currow = SFW.next_sibling_element(currow);\n }\n }\n\n // search nextSiblings for match\n function find_matched_headfix_row(tr, hf_name)\n {\n var cname = tr.className;\n var fpos = cname.lastIndexOf(\" floater\");\n cname = cname.substring(0,fpos);\n \n var n = tr.parentNode.firstChild;\n while (n)\n {\n if (is_tr_el(n))\n if (n.className == cname)\n return n;\n n = n.nextSibling;\n }\n\n return null;\n }\n\n // replace function with function in closure:\n _fix_table_heads = function(tab)\n {\n var thead = tab.getElementsByTagName(\"thead\");\n if (thead && thead.length)\n align_paired_rows(thead[0]);\n };\n\n // must explicitely call the function when setting up the closure:\n SFW.fix_table_heads = _fix_table_heads;\n _fix_table_heads(table);\n \n }", "title": "" }, { "docid": "50ea1902477b8c8035abd94e95815923", "score": "0.6278363", "text": "function fixFoot() {\n var tfoot = $(settings.table).find(\"tfoot\");\n var tr = tfoot.find(\"tr\");\n var cells = tfoot.find(\"tr > *\");\n\n setBackground(cells);\n cells.css({\n 'position': 'relative'\n });\n }", "title": "" }, { "docid": "50ea1902477b8c8035abd94e95815923", "score": "0.6278363", "text": "function fixFoot() {\n var tfoot = $(settings.table).find(\"tfoot\");\n var tr = tfoot.find(\"tr\");\n var cells = tfoot.find(\"tr > *\");\n\n setBackground(cells);\n cells.css({\n 'position': 'relative'\n });\n }", "title": "" }, { "docid": "0660648c459b7d0a4fc78dfa6eafd803", "score": "0.610109", "text": "function tableBreakrInit() {\n\t\ttables.forEach((table) => {\n\t\t\tlet columnCount = table.querySelectorAll('tr')[0].childElementCount;\n\t\t\ttable.classList.add( columnCount + '-column' );\n\t\t\t//Define the header row as either the <th> row, or the first <td> in each column\n\t\t\tlet headings = table.querySelectorAll('th') || table.querySelectorAll('tr:first-of-type td');\n\t\t\tisolateHeadings(table,headings);\n\t\t});\n\t\t}", "title": "" }, { "docid": "a498bfa033d260933e124fe380712ccd", "score": "0.6033048", "text": "floatHeader(){\n\n var\n tablePos = this.$tableWrapper.offset().top,\n tableHeight = this.$tableWrapper.height() - this.$headerWrapper.height()\n\n tablePos < this.offset && tablePos > - tableHeight\n ? this.$headerWrapper.css('display', 'block')\n : this.$headerWrapper.css('display', 'none')\n this.sideScroll()\n }", "title": "" }, { "docid": "88c69ca058c7f517f6d34887ae5990ee", "score": "0.60329205", "text": "function _setHeaders() {\n // if no headers specified, we will use the fields as headers.\n _headers = (_headers == null || _headers.length < 1) ? _fields : _headers;\n var h = _buildRowColumns(_headers, '', 1);\n if (_table.children('thead').length < 1) _table.prepend('<thead></thead>');\n _table.children('thead').html(h);\n }", "title": "" }, { "docid": "cdeea741192908b75461e9c67434861f", "score": "0.6015639", "text": "function setTableHeadWidth() {\n var tableHeadChildren = $(\".table-head>*\");\n var tableHeadCopyChildren = $(\".table-head-copy>*\");\n $.each(tableHeadChildren, function (index, element) {\n $(element).css({ \"min-width\": $(tableHeadCopyChildren[index]).outerWidth() });\n });\n}", "title": "" }, { "docid": "2db9c33db88759aa7c40696ac85cad3a", "score": "0.6012196", "text": "function synch_scroll(){\n $('#table_header_').scrollLeft($(\"#patients_table_\").scrollLeft());\n}", "title": "" }, { "docid": "0eee9e5b41b16d8d90304628a4b4b422", "score": "0.59660715", "text": "function tableHeader() {\n ; buf.push('\\n <thead>\\n <tr>\\n <th nowrap class=\"', escape((46, PacketUIColumnType.ENCODING_LABEL )), '\"></th>\\n ');47; if (showToAddress) { ; buf.push('\\n <th nowrap class=\"', escape((48, PacketUIColumnType.TO_ADDRESS )), '\">', escape((48, i18n.to() )), '</th>\\n ');49; } ; buf.push('\\n ');50; if (showFromAddress) { ; buf.push('\\n <th nowrap class=\"', escape((51, PacketUIColumnType.FROM_ADDRESS )), '\">', escape((51, i18n.from() )), '</th>\\n ');52; } ; buf.push('\\n ');53; if (showPacketInfo) { ; buf.push('\\n <th nowrap class=\"', escape((54, PacketUIColumnType.PACKET_INFO )), '\">', escape((54, i18n.packet() )), '</th>\\n ');55; } ; buf.push('\\n <th class=\"', escape((56, PacketUIColumnType.MESSAGE )), '\">\\n ', escape((57, i18n.message() )), '\\n <div class=\"packet-controls\">\\n <span class=\"netsim-button secondary remove-packet-button\" title=\"', escape((59, i18n.removePacket() )), '\"><i class=\"fa fa-times\"></i></span>\\n </div>\\n </th>\\n </tr>\\n </thead>\\n ');64;\n }", "title": "" }, { "docid": "c2886dacb45ddd20dd5b73b3449db32e", "score": "0.5950061", "text": "function setParent() {\n var parent = $(settings.parent);\n var table = $(settings.table);\n\n parent.append(table);\n parent\n .css({\n 'overflow-x': 'auto',\n 'overflow-y': 'auto'\n });\n\n parent.scroll(function () {\n var scrollWidth = parent[0].scrollWidth;\n var clientWidth = parent[0].clientWidth;\n var scrollHeight = parent[0].scrollHeight;\n var clientHeight = parent[0].clientHeight;\n var top = parent.scrollTop();\n var left = parent.scrollLeft();\n\n if (settings.head)\n this.find(\"thead tr > *\").css(\"top\", top);\n\n if (settings.foot)\n this.find(\"tfoot tr > *\").css(\"bottom\", scrollHeight - clientHeight - top);\n\n if (settings.left > 0)\n settings.leftColumns.css(\"left\", left);\n\n if (settings.right > 0)\n settings.rightColumns.css(\"right\", scrollWidth - clientWidth - left);\n }.bind(table));\n }", "title": "" }, { "docid": "c2886dacb45ddd20dd5b73b3449db32e", "score": "0.5950061", "text": "function setParent() {\n var parent = $(settings.parent);\n var table = $(settings.table);\n\n parent.append(table);\n parent\n .css({\n 'overflow-x': 'auto',\n 'overflow-y': 'auto'\n });\n\n parent.scroll(function () {\n var scrollWidth = parent[0].scrollWidth;\n var clientWidth = parent[0].clientWidth;\n var scrollHeight = parent[0].scrollHeight;\n var clientHeight = parent[0].clientHeight;\n var top = parent.scrollTop();\n var left = parent.scrollLeft();\n\n if (settings.head)\n this.find(\"thead tr > *\").css(\"top\", top);\n\n if (settings.foot)\n this.find(\"tfoot tr > *\").css(\"bottom\", scrollHeight - clientHeight - top);\n\n if (settings.left > 0)\n settings.leftColumns.css(\"left\", left);\n\n if (settings.right > 0)\n settings.rightColumns.css(\"right\", scrollWidth - clientWidth - left);\n }.bind(table));\n }", "title": "" }, { "docid": "aa668b0f88025e31662a91514c6b8bc3", "score": "0.5948433", "text": "function writeHead(row,arr){var ii=arr.length;while(ii--){tab.setText (row,ii,arr[ii] ) // Write header row\r\n .setStyleAttribute(row,ii,\"backgroundColor\",\"darkorange\")\r\n .setStyleAttribute(row,ii,\"color\" ,\"white\" )\r\n .setStyleAttribute(row,ii,\"fontWeight\" ,\"bold\" );}}", "title": "" }, { "docid": "aa668b0f88025e31662a91514c6b8bc3", "score": "0.5948433", "text": "function writeHead(row,arr){var ii=arr.length;while(ii--){tab.setText (row,ii,arr[ii] ) // Write header row\r\n .setStyleAttribute(row,ii,\"backgroundColor\",\"darkorange\")\r\n .setStyleAttribute(row,ii,\"color\" ,\"white\" )\r\n .setStyleAttribute(row,ii,\"fontWeight\" ,\"bold\" );}}", "title": "" }, { "docid": "aa668b0f88025e31662a91514c6b8bc3", "score": "0.5948433", "text": "function writeHead(row,arr){var ii=arr.length;while(ii--){tab.setText (row,ii,arr[ii] ) // Write header row\r\n .setStyleAttribute(row,ii,\"backgroundColor\",\"darkorange\")\r\n .setStyleAttribute(row,ii,\"color\" ,\"white\" )\r\n .setStyleAttribute(row,ii,\"fontWeight\" ,\"bold\" );}}", "title": "" }, { "docid": "a8dce462ec58515d79aa56ce100d71f3", "score": "0.590207", "text": "function setTableHeaderCellWidth(_contentItem) {\n\n var _lsw = _contentItem.lsWire;\n\n // Find the first cell on the page, so we can get the dom width\n var firstCell = $(\"td\", \".ui-page-active\").first()[0];\n\n if (firstCell != undefined) {\n\n // Calculate the width our header cells should be, based on width\n // of the cells holding the content\n var padding = parseInt($(firstCell).css(\"padding-left\")) * 2;\n var width = firstCell.getBoundingClientRect().width;\n lsw.cellWidth = width - padding;\n\n var cssRule = lsWire.getStyleRule(_lsw.styleSheet, \".lswire-fixed-element th\");\n cssRule.rule.style.cssText = \"width: \" + _lsw.cellWidth + \"px !important; \";\n\n }\n }", "title": "" }, { "docid": "99003296b8400a4f9c11ce49439a8c00", "score": "0.587321", "text": "function setCorner() {\n var table = $(settings.table);\n\n if (settings.head) {\n if (settings.left > 0) {\n var tr = table.find(\"thead tr\");\n\n tr.each(function (k, row) {\n solverLeftColspan(row, function (cell) {\n $(cell).css(\"z-index\", settings['z-index'] + 1);\n });\n });\n }\n\n if (settings.right > 0) {\n var tr = table.find(\"thead tr\");\n\n tr.each(function (k, row) {\n solveRightColspan(row, function (cell) {\n $(cell).css(\"z-index\", settings['z-index'] + 1);\n });\n });\n }\n }\n\n if (settings.foot) {\n if (settings.left > 0) {\n var tr = table.find(\"tfoot tr\");\n\n tr.each(function (k, row) {\n solverLeftColspan(row, function (cell) {\n $(cell).css(\"z-index\", settings['z-index']);\n });\n });\n }\n\n if (settings.right > 0) {\n var tr = table.find(\"tfoot tr\");\n\n tr.each(function (k, row) {\n solveRightColspan(row, function (cell) {\n $(cell).css(\"z-index\", settings['z-index']);\n });\n });\n }\n }\n }", "title": "" }, { "docid": "85b02a19a0be62663163428ea779b5e7", "score": "0.58560246", "text": "function table(head) {\n this.table = new cliTable({\n head: head,\n });\n this.hasRows = false;\n }", "title": "" }, { "docid": "a31f9de877aaf66371c08a3f610a7c04", "score": "0.58510613", "text": "function change_headers_width(){\n $(\".handsontable col.rowHeader \").css( \"width\", rowHeadersMaxWidth + 50);\n $datacardTable.handsontable('getInstance').render();\n}", "title": "" }, { "docid": "a1a5d44982945d8781bbebfee66ade7a", "score": "0.58213454", "text": "function firstDataTableScrollAdjust() {\n // first render of data table\n jsDataTableScrollAdjust();\n \n window.onresize = function() {\n // adjust the hight of the data table on a browser resize event\n jsDataTableScrollAdjust();\n };\n}", "title": "" }, { "docid": "97475e39e770919996cf0642e12c513d", "score": "0.58135706", "text": "function setScrollTableClass() {\n if (!scope.vm.folder) {\n return;\n }\n bodyWrapper.css(\"height\", \"calc(100% - 31px)\");\n table.css(\"margin-bottom\", \"0\");\n var hasVertScroll = bodyWrapper[0].scrollHeight > bodyWrapper[0].clientHeight;\n if (hasVertScroll) {\n table.css(\"min-width\", \"612px\");\n bodyWrapper.css(\"height\", \"calc(100% - 31px)\");\n table.css(\"margin-bottom\", \"0\");\n element.addClass(scrollClass);\n } else {\n table.css(\"min-width\", \"629px\");\n bodyWrapper.css(\"height\", \"auto\");\n var spacing = bodyWrapper[0].scrollWidth > bodyWrapper[0].clientWidth ? 17 : 0;\n table.css(\"margin-bottom\", (element[0].clientHeight - table[0].clientHeight - 31 - spacing) + \"px\");\n element.removeClass(scrollClass);\n }\n }", "title": "" }, { "docid": "532be1d4cca67771ad82521730494202", "score": "0.5813521", "text": "resize(){\n\n var\n contentWidth = this.$table.outerWidth(),\n viewportWidth = this.$tableWrapper.innerWidth()\n\n this.$headerWrapper.width(this.$tableWrapper.width())\n this.scrollRange = parseInt(contentWidth - viewportWidth)\n this.offset = parseInt($body.css('padding-top').replace(/px$/, ''))\n\n this.$headerWrapper.css(\n {\n top: this.offset,\n left: this.$tableWrapper.offset().left,\n height: $('tr', this.$tableWrapper).outerHeight()\n }\n )\n\n this.floatHeader()\n }", "title": "" }, { "docid": "fabc74fb776b9605461e15cfb58e463c", "score": "0.57907015", "text": "function cssHead() {\n //get values\n var horizontal = locationHorz(horz);\n //CSS to make responsive tables work\n var tableCss = '<style> @media (max-width:450px){ .topTable{border:0!important;}th{display:none!important;} .border{border:none!important;padding:5px 2%!important;} .responsive-stacked-table thead{display:none;} .responsive-stacked-table td, .responsive-stacked-table th, .responsive-stacked-table tr{display:block;} .responsive-stacked-table td{border-top:none;} .responsive-stacked-table tr td:first-child{border-top:1px solid #ddd!important; font-weight:700; margin-top:10px; padding-top:20px !important;} .responsive-stacked-table.with-mobile-labels tr td:first-child{font-weight:300} .responsive-stacked-table.with-mobile-labels td:before{display:block;font-weight:700;}'\n\n for (var x = 1; x <= horizontal; x++) {\n // headLabel = document.getElementById('head' + x).value;\n var id = \"#head\"\n id = id + x\n var headLabel = $('#output').contents().find(id).html();\n tableCss += '.responsive-stacked-table.with-mobile-labels td:nth-of-type(' + x + '):before { content:\"' + headLabel + '\"; font-family: &#39;ClanPro-News&#39;,&#39;HelveticaNeue-Light&#39;, &#39;Helvetica Neue Light&#39;, Helvetica, Arial, sans-serif; font-size: 16px;}';\n }\n tableCss += '} </style>'\n return tableCss;\n}", "title": "" }, { "docid": "be431750ce8134d5bc66033cdad7e814", "score": "0.5762175", "text": "renderTable() {\n let headerDiv = this.getPanel();\n headerDiv.appendChild(this.createHeaderTable());\n this.setTable(headerDiv.querySelector('.e-table'));\n if (!this.parent.getFrozenColumns() && !this.parent.getFrozenRightColumnsCount() && !this.parent.getFrozenLeftColumnsCount()) {\n this.initializeHeaderDrag();\n this.initializeHeaderDrop();\n }\n this.parent.notify(headerRefreshed, { rows: this.rows, args: { isFrozen: this.parent.isFrozenGrid() } });\n }", "title": "" }, { "docid": "80ded09ef76d5aa627ab1bbbc6ac29c0", "score": "0.5755673", "text": "function constructHeaderTblSTVariance() {\t\n\tprintHeadInnerTable = '<div class=\"page\"><table cellspacing=\"0\" class=\"printDeviceLogTable ContentTable\" style=\"font-size: 15px;height:45%;min-height:560px;max-height:580px;table-layout: fixed; width: 1100px;\" width=\"100%\">'\n\t\t+'<thead><tr><th rowspan=\"2\" width=\"50px\">Article</th>'\n\t\t+'<th rowspan=\"2\" width=\"150px\">Description</th>'\n\t\t+'<th rowspan=\"2\" width=\"50px\">Value($)</th>'\n\t\t//+'<th rowspan=\"2\" width=\"50px\">Location</th>'\n\t\t+'<th rowspan=\"2\" width=\"50px\">Base</br>Count</th>'\n\t\t+'<th colspan=\"4\" class=\"centerValue columnDivider\" width=\"250px\">Re-Count</th>'\n\t\t+'<th rowspan=\"2\" class=\"centerValue\" width=\"50px\">Total</br>Count</th>'\n\t\t+'<th rowspan=\"2\" class=\"centerValue\" width=\"50px\">SOH</th>'\n\t\t+'<th colspan=\"2\" class=\"centerValue columnDivider\">Variance</th>'\n\t\t+'</tr><tr class=\"subHeader\">'\n\t\t+'<th class=\"centerValue\" width=\"25px\">1</th>'\n\t\t+'<th class=\"centerValue\" width=\"25px\">2</th>'\n\t\t+'<th class=\"centerValue\" width=\"25px\">3</th>'\n\t\t+'<th class=\"centerValue\" width=\"25px\">4</th>'\n\t\t+'<th class=\"centerValue\" width=\"50px\">Qty.</th>'\n\t\t+'<th class=\"centerValue\" width=\"50px\">$Value</th></tr></thead>';\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\n}", "title": "" }, { "docid": "e7799c87fe68fbbc3fc07f4c81b5be9a", "score": "0.5743226", "text": "function addPersistHeader() {\r\n\t_log('addPersistHeader() Start',DLOG);\r\n\tGM_addStyle(\".floatingHeader {position: fixed; top: 0;visibility: hidden; display:inline-block;}\");\r\n\tvar floatingHeader;\r\n\t$('#productTable').addClass('persist-area');\r\n\t$('#productTable>thead').find('tr:first').addClass('persist-header');\r\n\t$(\".persist-area\").each(function() {\r\n\t\tfloatingHeader = $(\".persist-header\", this);\r\n\t\t\r\n\t\tfloatingHeader.before(floatingHeader.clone().attr('id','realheader'));\r\n\t\r\n\t\tfloatingHeader.children().css(\"width\", function(i, val){\r\n\t\t\treturn $(floatingHeader).children().eq(i).css(\"width\", val);\r\n\t\t});\r\n\t\t\r\n\t\tfloatingHeader.addClass(\"floatingHeader\");\r\n\t\tfloatingHeader.css('width', $('.persist-area').width());\r\n\t});\r\n\r\n\tfloatingHeader.find('th').width(function(i, val) {\r\n\t\t\tif(i==2){return 64;}// for the image column so the alt text doesn't mess with the column width of images.\r\n\t\t\telse{return $('#realheader').find('tr:first>th').eq(i).width();}\r\n\r\n\t});\r\n\r\n\t$(window).scroll(updateTableHeaders).trigger(\"scroll\");\r\n\t_log('addPersistHeader() End',DLOG);\r\n}", "title": "" }, { "docid": "29f29407eb56c4f93d9212c1e19bd4de", "score": "0.57393503", "text": "function _fnBuildHead( oSettings )\n\t\t{\n\t\t\tvar i, nTh, iLen, j, jLen;\n\t\t\tvar anTr = oSettings.nTHead.getElementsByTagName('tr');\n\t\t\tvar iThs = oSettings.nTHead.getElementsByTagName('th').length;\n\t\t\tvar iCorrector = 0;\n\t\t\tvar jqChildren;\n\t\t\t\n\t\t\t/* If there is a header in place - then use it - otherwise it's going to get nuked... */\n\t\t\tif ( iThs !== 0 )\n\t\t\t{\n\t\t\t\t/* We've got a thead from the DOM, so remove hidden columns and apply width to vis cols */\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tnTh = oSettings.aoColumns[i].nTh;\n\t\t\t\t\t\n\t\t\t\t\tif ( oSettings.aoColumns[i].sClass !== null )\n\t\t\t\t\t{\n\t\t\t\t\t\t$(nTh).addClass( oSettings.aoColumns[i].sClass );\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t/* Set the title of the column if it is user defined (not what was auto detected) */\n\t\t\t\t\tif ( oSettings.aoColumns[i].sTitle != nTh.innerHTML )\n\t\t\t\t\t{\n\t\t\t\t\t\tnTh.innerHTML = oSettings.aoColumns[i].sTitle;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t/* We don't have a header in the DOM - so we are going to have to create one */\n\t\t\t\tvar nTr = document.createElement( \"tr\" );\n\t\t\t\t\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tnTh = oSettings.aoColumns[i].nTh;\n\t\t\t\t\tnTh.innerHTML = oSettings.aoColumns[i].sTitle;\n\t\t\t\t\t\n\t\t\t\t\tif ( oSettings.aoColumns[i].sClass !== null )\n\t\t\t\t\t{\n\t\t\t\t\t\t$(nTh).addClass( oSettings.aoColumns[i].sClass );\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tnTr.appendChild( nTh );\n\t\t\t\t}\n\t\t\t\t$(oSettings.nTHead).html( '' )[0].appendChild( nTr );\n\t\t\t\t_fnDetectHeader( oSettings.aoHeader, oSettings.nTHead );\n\t\t\t}\n\t\t\t\n\t\t\t/* Add the extra markup needed by jQuery UI's themes */\n\t\t\tif ( oSettings.bJUI )\n\t\t\t{\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tnTh = oSettings.aoColumns[i].nTh;\n\t\t\t\t\t\n\t\t\t\t\tvar nDiv = document.createElement('div');\n\t\t\t\t\tnDiv.className = oSettings.oClasses.sSortJUIWrapper;\n\t\t\t\t\t$(nTh).contents().appendTo(nDiv);\n\t\t\t\t\t\n\t\t\t\t\tvar nSpan = document.createElement('span');\n\t\t\t\t\tnSpan.className = oSettings.oClasses.sSortIcon;\n\t\t\t\t\tnDiv.appendChild( nSpan );\n\t\t\t\t\tnTh.appendChild( nDiv );\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t/* Add sort listener */\n\t\t\tvar fnNoSelect = function (e) {\n\t\t\t\tthis.onselectstart = function() { return false; };\n\t\t\t\treturn false;\n\t\t\t};\n\t\t\t\n\t\t\tif ( oSettings.oFeatures.bSort )\n\t\t\t{\n\t\t\t\tfor ( i=0 ; i<oSettings.aoColumns.length ; i++ )\n\t\t\t\t{\n\t\t\t\t\tif ( oSettings.aoColumns[i].bSortable !== false )\n\t\t\t\t\t{\n\t\t\t\t\t\t_fnSortAttachListener( oSettings, oSettings.aoColumns[i].nTh, i );\n\t\t\t\t\t\t\n\t\t\t\t\t\t/* Take the brutal approach to cancelling text selection in header */\n\t\t\t\t\t\t$(oSettings.aoColumns[i].nTh).bind( 'mousedown.DT', fnNoSelect );\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$(oSettings.aoColumns[i].nTh).addClass( oSettings.oClasses.sSortableNone );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t/* Deal with the footer - add classes if required */\n\t\t\tif ( oSettings.oClasses.sFooterTH !== \"\" )\n\t\t\t{\n\t\t\t\t$(oSettings.nTFoot).children('tr').children('th').addClass( oSettings.oClasses.sFooterTH );\n\t\t\t}\n\t\t\t\n\t\t\t/* Cache the footer elements */\n\t\t\tif ( oSettings.nTFoot !== null )\n\t\t\t{\n\t\t\t\tvar anCells = _fnGetUniqueThs( oSettings, null, oSettings.aoFooter );\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tif ( typeof anCells[i] != 'undefined' )\n\t\t\t\t\t{\n\t\t\t\t\t\toSettings.aoColumns[i].nTf = anCells[i];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "7992eb8bebd84c91e0d06966ac2b8da5", "score": "0.57356143", "text": "function _fnBuildHead( oSettings )\n\t\t{\n\t\t\tvar i, nTh, iLen, j, jLen;\n\t\t\tvar anTr = oSettings.nTHead.getElementsByTagName('tr');\n\t\t\tvar iths = oSettings.nTHead.getElementsByTagName('th').length;\n\t\t\tvar iCorrector = 0;\n\t\t\tvar jqChildren;\n\t\t\t\n\t\t\t/* If there is a header in place - then use it - otherwise it's going to get nuked... */\n\t\t\tif ( iths !== 0 )\n\t\t\t{\n\t\t\t\t/* We've got a thead from the DOM, so remove hidden columns and apply width to vis cols */\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tnTh = oSettings.aoColumns[i].nTh;\n\t\t\t\t\t\n\t\t\t\t\tif ( oSettings.aoColumns[i].sClass !== null )\n\t\t\t\t\t{\n\t\t\t\t\t\t$(nTh).addClass( oSettings.aoColumns[i].sClass );\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\t/* Set the title of the column if it is user defined (not what was auto detected) */\n\t\t\t\t\tif ( oSettings.aoColumns[i].sTitle != nTh.innerHTML )\n\t\t\t\t\t{\n\t\t\t\t\t\tnTh.innerHTML = oSettings.aoColumns[i].sTitle;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t/* We don't have a header in the DOM - so we are going to have to create one */\n\t\t\t\tvar nTr = document.createElement( \"tr\" );\n\t\t\t\t\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tnTh = oSettings.aoColumns[i].nTh;\n\t\t\t\t\tnTh.innerHTML = oSettings.aoColumns[i].sTitle;\n\t\t\t\t\t\n\t\t\t\t\tif ( oSettings.aoColumns[i].sClass !== null )\n\t\t\t\t\t{\n\t\t\t\t\t\t$(nTh).addClass( oSettings.aoColumns[i].sClass );\n\t\t\t\t\t}\n\t\t\t\t\t\n\t\t\t\t\tnTr.appendChild( nTh );\n\t\t\t\t}\n\t\t\t\t$(oSettings.nTHead).html( '' )[0].appendChild( nTr );\n\t\t\t\t_fnDetectHeader( oSettings.aoHeader, oSettings.nTHead );\n\t\t\t}\n\t\t\t\n\t\t\t/* Add the extra markup needed by jQuery UI's themes */\n\t\t\tif ( oSettings.bJUI )\n\t\t\t{\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tnTh = oSettings.aoColumns[i].nTh;\n\t\t\t\t\t\n\t\t\t\t\tvar nDiv = document.createElement('div');\n\t\t\t\t\tnDiv.className = oSettings.oClasses.sSortJUIWrapper;\n\t\t\t\t\t$(nTh).contents().appendTo(nDiv);\n\t\t\t\t\t\n\t\t\t\t\tvar nSpan = document.createElement('span');\n\t\t\t\t\tnSpan.className = oSettings.oClasses.sSortIcon;\n\t\t\t\t\tnDiv.appendChild( nSpan );\n\t\t\t\t\tnTh.appendChild( nDiv );\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t/* Add sort listener */\n\t\t\tvar fnNoSelect = function (e) {\n\t\t\t\tthis.onselectstart = function() { return false; };\n\t\t\t\treturn false;\n\t\t\t};\n\t\t\t\n\t\t\tif ( oSettings.oFeatures.bSort )\n\t\t\t{\n\t\t\t\tfor ( i=0 ; i<oSettings.aoColumns.length ; i++ )\n\t\t\t\t{\n\t\t\t\t\tif ( oSettings.aoColumns[i].bSortable !== false )\n\t\t\t\t\t{\n\t\t\t\t\t\t_fnSortAttachListener( oSettings, oSettings.aoColumns[i].nTh, i );\n\t\t\t\t\t\t\n\t\t\t\t\t\t/* Take the brutal approach to cancelling text selection in header */\n\t\t\t\t\t\t$(oSettings.aoColumns[i].nTh).bind( 'mousedown.DT', fnNoSelect );\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\t$(oSettings.aoColumns[i].nTh).addClass( oSettings.oClasses.sSortableNone );\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t/* Deal with the footer - add classes if required */\n\t\t\tif ( oSettings.oClasses.sFooterTH !== \"\" )\n\t\t\t{\n\t\t\t\t$('>tr>th', oSettings.nTFoot).addClass( oSettings.oClasses.sFooterTH );\n\t\t\t}\n\t\t\t\n\t\t\t/* Cache the footer elements */\n\t\t\tif ( oSettings.nTFoot !== null )\n\t\t\t{\n\t\t\t\tvar anCells = _fnGetUniqueThs( oSettings, null, oSettings.aoFooter );\n\t\t\t\tfor ( i=0, iLen=oSettings.aoColumns.length ; i<iLen ; i++ )\n\t\t\t\t{\n\t\t\t\t\tif ( typeof anCells[i] != 'undefined' )\n\t\t\t\t\t{\n\t\t\t\t\t\toSettings.aoColumns[i].nTf = anCells[i];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "4a810f6116d9856eadbab64df415048d", "score": "0.57206357", "text": "createTableHead() {\n var thead = document.createElement(\"thead\");\n var tr = document.createElement(\"tr\");\n\n //Loop through the th list and add to thead and tr\n for (let key of this.ths) {\n var th = document.createElement(\"th\");\n th.classList.add(key);\n th.innerHTML = key;\n tr.appendChild(th);\n thead.appendChild(tr);\n }\n\n table.appendChild(thead);\n }", "title": "" }, { "docid": "94ace96cf74f2ea702c626fed1e2a731", "score": "0.57180345", "text": "adjust() {\n const { columnHeadersCount, rowHeadersCount } = this.table;\n let TR = this.rootNode.firstChild;\n\n if (columnHeadersCount) {\n const { columnsToRender } = this.table;\n const allColumnsToRender = columnsToRender + rowHeadersCount;\n\n for (let i = 0, len = columnHeadersCount; i < len; i++) {\n TR = this.rootNode.childNodes[i];\n\n if (!TR) {\n TR = this.table.rootDocument.createElement('tr');\n this.rootNode.appendChild(TR);\n }\n this.renderedNodes = TR.childNodes.length;\n\n while (this.renderedNodes < allColumnsToRender) {\n TR.appendChild(this.table.rootDocument.createElement('th'));\n this.renderedNodes += 1;\n }\n while (this.renderedNodes > allColumnsToRender) {\n TR.removeChild(TR.lastChild);\n this.renderedNodes -= 1;\n }\n }\n const theadChildrenLength = this.rootNode.childNodes.length;\n\n if (theadChildrenLength > columnHeadersCount) {\n for (let i = columnHeadersCount; i < theadChildrenLength; i++) {\n this.rootNode.removeChild(this.rootNode.lastChild);\n }\n }\n } else if (TR) {\n empty(TR);\n }\n }", "title": "" }, { "docid": "b116a3c1262cc4b7d5f2cef2a2cf3333", "score": "0.5712295", "text": "function firstColumnFix(){\n\t\t$('tr > .table-size:nth-child(1)').addClass(\"width-cell\");\n\t}", "title": "" }, { "docid": "0933ed60bcd576175a2d09060e06f14e", "score": "0.5697943", "text": "function resizeTbl() {\n\t\t// table scroll\n\t\tvar tblBodyHeight = $(\"#tblBody\").height();\n\t\tvar divBodyHeight = $(\"#divBody\").height();\n\t\tif (tblBodyHeight > divBodyHeight) {\n\t\t\t$(\"#divBody\").css(\"overflow-y\", \"scroll\");\n\t\t\t$(\"#divHead\").width($(\"#divBody\").width() - 17);\n\t\t\t$(window).resize(function() {\n\t\t\t\t$(\"#divHead\").width($(\"#divBody\").width() - 17);\n\t\t\t});\n\t\t} else {\n\t\t\t$(\"#divHead\").width($(\"#divBody\").width());\n\t\t\t$(window).resize(function() {\n\t\t\t\t$(\"#divHead\").width($(\"#divBody\").width());\n\t\t\t});\n\t\t\t$(\"#divBody\").css(\"overflow-y\", \"hidden\");\n\t\t}\n\t}", "title": "" }, { "docid": "f022db46f1aded694909df9191945079", "score": "0.5694693", "text": "function fillTable() {\n let body = document.body,\n tbl = document.createElement('table');\n tbl.setAttribute('id', 'jeopardy')\n th = document.createElement('thead');\n tbl.style.width = '100px';\n tbl.style.border = '1px solid black';\n for (let i = 0; i < 5; i++) {\n let tr = tbl.insertRow();\n for (let j = 0; j < 6; j++) {\n let td = tr.insertCell();\n td.setAttribute('id', 'cell')\n td.appendChild(document.createTextNode('?'));\n td.style.border = '1px solid black';\n }\n }\n\n for (let i = 0; i <= 0; i++) {\n let tr = th.insertRow();\n for (let j = 0; j < 6; j++) {\n let head = tr.insertCell();\n head.setAttribute('id', 'head-cell')\n head.style.border = '1px solid black';\n }\n }\n tbl.appendChild(th);\n body.appendChild(tbl);\n\n}", "title": "" }, { "docid": "b8b32f7d0fadbf094d9de552708ab336", "score": "0.5676563", "text": "function addFixedColumn() {\n instance.updateSettings({\n fixedColumnsLeft: fixedColumnsCount + 1\n });\n fixedColumnsCount++;\n }", "title": "" }, { "docid": "7160cc3806a2318cdf8f212d49f9952e", "score": "0.56674296", "text": "function th(tableH) {\n //get values\n var horizontal = locationHorz(horz);\n var vertical = locationVert(vertz);\n var headLabel;\n var tableH = [];\n\n for (var x = 1; x <= horizontal; x++) {\n // headLabel = document.getElementById('head' + x).value;\n var id = \"#head\"\n id = id + x\n var headLabel = $('#output').contents().find(id).html();\n if (headLabel == null){\n headLabel = \"Edit here\"\n }\n tableH += tableHead(headLabel, x);\n }\n return tableH;\n}", "title": "" }, { "docid": "2f11bf2425e3abf93766682a4fb412f8", "score": "0.5661815", "text": "function stickTableHeader() {\n if (view !== VIEWS.AREA_SYS && view !== VIEWS.AREA_SRC && view !== VIEWS.LOOP && view !== VIEWS.VERIF && view !== VIEWS.INCREMENTAL)\n return;\n var reportBody = $(currentPane + ' #report-area')[0];\n if (!reportBody)\n return;\n var areaTable = $(currentPane + ' #area-table-content')[0];\n if (!areaTable)\n return;\n var panel = reportBody.getBoundingClientRect();\n var table = areaTable.getBoundingClientRect();\n var rowWidth = 0.0;\n var tableWidth = table.width;\n var systemRow;\n var tableHeader = $(currentPane + ' #table-header').filter(function () {\n if ($(this).is(\":visible\"))\n return true;\n return false;\n });\n systemRow = $(currentPane + ' #first-row')\n .filter(function () {\n if ($(this).is(':visible'))\n return true;\n return false;\n });\n tableHeader.css('position', 'absolute')\n .css('top', (panel.top - table.top))\n .css('left', 0);\n tableHeader.find('th').each(function (i) {\n var itemWidth = (systemRow.find('td').eq(i))[0].getBoundingClientRect().width;\n if (i === 0) {\n // This column contains the expand/collapse all button. Check if need to resize button\n if (itemWidth < $('#collapseAll').outerWidth() || itemWidth < 116) {\n $('#collapseAll').outerWidth(itemWidth);\n $('#expandAll').outerWidth(itemWidth);\n }\n else {\n $('#collapseAll').outerWidth(116);\n $('#expandAll').outerWidth(116);\n }\n }\n rowWidth += itemWidth;\n $(this).css('min-width', itemWidth);\n });\n // Set the Spacer row height equal to current tableHeader height\n systemRow.css('height', tableHeader.outerHeight());\n // if we just hid the selected row, unselect it and clear details pane\n if (view.clickDown && view.clickDown.offsetParent === null) {\n unsetClick();\n }\n}", "title": "" }, { "docid": "f59f28ebaacfd9144330650492753a8b", "score": "0.56548995", "text": "function createTableHead(config) {\n let table_head = document.createElement(\"thead\");\n document.querySelector(\".customers\").appendChild(table_head);\n let head = document.createElement(\"tr\");\n table_head.appendChild(head);\n let head_cell = document.createElement(\"th\");\n head_cell.innerHTML = \"№\";\n head.appendChild(head_cell);\n for (let i = 0; i < config.columns.length; i++) {\n let head_cell = document.createElement(\"th\");\n head_cell.innerHTML = `${config.columns[i].title}`;\n head.appendChild(head_cell);\n }\n let head_cell_action = document.createElement(\"th\");\n head_cell_action.innerHTML = \"Action\";\n head.appendChild(head_cell_action);\n}", "title": "" }, { "docid": "f3691e475117cd59a2a3870724c2e45c", "score": "0.5654637", "text": "function fillTableCustomHeadings(array, tableID) {\r\n\tlet heading = '<thead>';\r\n\tfor (let keys in array[0]) {\r\n\t\theading += `<th>${keys}</th>`;\r\n\t}\r\n\theading += '</thead>';\r\n\tlet body = '';\r\n\tarray.map(function(object) {\r\n\t\tbody += `<tbody><tr>`;\r\n\t\tfor (let i in object) {\r\n\t\t\tbody += `<td>${object[i]}</td>`;\r\n\t\t}\r\n\t\tbody += `</tr></tbody>`;\r\n\t});\r\n\tdocument.getElementById(tableID).innerHTML = heading + body;\r\n}", "title": "" }, { "docid": "6b988f17bf5d2410592089bacae80ba9", "score": "0.56274194", "text": "gameMainTableFixWidthScrollbar() {\r\n var table_header_width = document.getElementsByClassName(\"table_header\")[0].offsetWidth;\r\n var table_body_width = document.getElementsByClassName(\"table_body\")[0].offsetWidth;\r\n var scrollbar_width_fixer = document.getElementsByClassName(\"scrollbar_width_fixer\")[0];\r\n scrollbar_width_fixer.style.width = table_header_width - table_body_width + \"px\";\r\n }", "title": "" }, { "docid": "a41403a1e3f6f63b0153471d288afb9a", "score": "0.5617798", "text": "function generateTableHead(table, data) {\n var thead = table.createTHead();\n var row = thead.insertRow();\n data.forEach((key)=> {\n var cell = row.insertCell();\n cell.innerHTML= key;\n })\n }", "title": "" }, { "docid": "a68e827ee89aa5c89f0f5211d862b295", "score": "0.56098", "text": "function HeaderTable(log, limit) {\n var self = HeaderTable.staticTable.map(entryFromPair);\n self._log = log;\n self._limit = limit || DEFAULT_HEADER_TABLE_LIMIT;\n self._staticLength = self.length;\n self._size = 0;\n self._enforceLimit = HeaderTable.prototype._enforceLimit;\n self.add = HeaderTable.prototype.add;\n self.setSizeLimit = HeaderTable.prototype.setSizeLimit;\n return self;\n}", "title": "" }, { "docid": "bcef8d879025872d03256848a9044c0c", "score": "0.56065404", "text": "m_createTableHeaders() {\n var row = this.m_createTableRow(); \n for (var i = 0; i < this.columns.length; i++) {\n var th = this.m_createTableHeader();\n if (this.columns[i].title) th.textContent = this.columns[i].title;\n if (this.columns[i].sortable) th.classList.add(\"sortable-column\", \"sorting_asc\");\n row.appendChild(th);\n }\n this.thead.appendChild(row);\n }", "title": "" }, { "docid": "28882223885e4f827c57a7da7da784af", "score": "0.555903", "text": "function createTHead(table) {\n var thead = table.tHead;\n if (thead) return thead;\n thead = document.createElement(\"thead\");\n var tbody = table.tBodies[0];\n table.insertBefore(thead, tbody);\n for (var i = 0; i < tbody.rows.length; i++) {\n var tbodyrow = tbody.rows[0];\n if (tbodyrow.querySelectorAll(\"td\").length !== 0 || tbodyrow.classList.contains(\"first-row\")) break;\n thead.appendChild(tbodyrow);\n }\n return thead;\n}", "title": "" }, { "docid": "02a3a9cb95611e314fd36c64c69ba611", "score": "0.555691", "text": "function printTHead (thead) {\n var row = '<tr>';\n for(var i=0; i < TABLE_HEADING.length; i++) {\n row += '<th>' + TABLE_HEADING[i][1] + '</th>';\n }\n row += '</tr>'\n thead.append(row);\n}", "title": "" }, { "docid": "a490178cc566d23a5fb767ab8ccd725d", "score": "0.5542667", "text": "function header(title, msg) {\n console.clear();\n\n var table = new Table({\n chars: { 'top': '═', 'top-left': '╔', 'top-right': '╗', 'bottom': '═', 'bottom-left': '╚', 'bottom-right': '╝', 'left': '║', 'right': '║' },\n head: [title],\n colWidths: [72],\n colAligns: ['middle']\n });\n console.log(table.toString());\n\n if (msg.length < 1) {\n console.log();\n } else {\n console.log();\n console.log(colors.red('=> '), msg)\n console.log()\n }\n}", "title": "" }, { "docid": "c74c7f2a14063a6b0bc20f81b71f4e44", "score": "0.5536092", "text": "function header(title, msg) {\n console.clear();\n\n var table = new config.Table({\n chars: { 'top': '═', 'top-left': '╔', 'top-right': '╗', 'bottom': '═', 'bottom-left': '╚', 'bottom-right': '╝', 'left': '║', 'right': '║' },\n head: [title],\n colWidths: [72],\n colAligns: ['middle']\n });\n console.log(table.toString());\n\n if (msg.length < 1) {\n console.log();\n } else {\n console.log();\n console.log(config.colors.red('=> '), msg)\n console.log()\n }\n}", "title": "" }, { "docid": "e31f868eeed4e9db3b897d41f0db30bf", "score": "0.5521684", "text": "function tableHeader(ID,n,Header_content){\r\n\tvar tbl = document.getElementById(ID);\r\n\tif(tbl != null){\t//Check if there is some errors while getElementById\r\n\t\ttbl.classList.add(\"Table\");\t//Add class to the table\r\n\t\tvar Header = tbl.createTHead();\t//Create Header to the table\r\n\t\tvar hrow = Header.insertRow(0);\t//Create row for the header\r\n\t\tfor(var i = 0; i < n; i++){\t\r\n\t\t\tvar hcell = hrow.insertCell(i); //Insert n cells to the header\r\n\t\t\thcell.innerHTML = Header_content[i];\t//add content to the header cells\r\n\t\t}\r\n\t}\r\n}", "title": "" }, { "docid": "5cdd2d4bcdddee424fc30e0e9a6a97d5", "score": "0.5512001", "text": "fixHeaderWithBody() {\n var currentScrollLeft = this._private.htmlCache.content.scrollLeft;\n var header = this._private.htmlCache.header.children[0].children[0];\n header.style.left = -currentScrollLeft + \"px\";\n if (this._private.lockedColumns > 0) { //todo in own function, its used a few places now\n //this have super bad performance in IE...\n currentScrollLeft = this._private.htmlCache.content.scrollLeft; //need the updated one...\n for (var lockedColNo = this._private.lockedColumns; lockedColNo--;) {\n var fix = this._private.node.querySelectorAll(\".\" + this._private.css.gridColumn + lockedColNo);\n //for(var i = 0; i < fix.length; i++){\n for (var i = fix.length; i--;) {\n fix[i].style.left = currentScrollLeft + \"px\";\n fix[i].style.zIndex = this._private.internalDragDropCount;\n fix[i].style.position = \"relative\";\n }\n }\n }\n }", "title": "" }, { "docid": "e0d31f71c0dcce8ff40cf76252d05635", "score": "0.5511534", "text": "function _init( el ) {\n el.find('>thead>tr').prepend('<th><div class=\"line_selector\"></div></th>');\n el.find('>tbody>tr').prepend('<td><div class=\"line_selector\"></div></td>');\n }", "title": "" }, { "docid": "755ad3134dbbc7fdd8fa21d11c010552", "score": "0.5510591", "text": "addFixedColumn() {\n this.hot.updateSettings({\n fixedColumnsLeft: this.fixedColumnsCount + 1\n });\n\n this.fixedColumnsCount++;\n }", "title": "" }, { "docid": "5025b3a5d747593e3959fda18eca9ffe", "score": "0.5509632", "text": "function tableHeader(content, idTable = \"uploadStatusTable\") {\n // NOTE: Use first, before any other addRow call\n let table = document.getElementById(idTable);\n let r = document.createElement(\"div\");\n r.style.display = \"table-row\";\n content.map(c => {\n let h = document.createElement(\"div\");\n h.style.display = \"table-cell\";\n h.style.paddingLeft = \"6px\";\n h.style.fontWeight = \"bold\";\n h.innerHTML = c;\n r.appendChild(h);\n })\n table.appendChild(r);\n}", "title": "" }, { "docid": "875ab779b3a3d3c6fec3e2ca52cebbab", "score": "0.5507569", "text": "function CreateHead() {\n var tr = \"\", td1 = \"\", td2 = \"\", td3 = \"\", tdHead = \"\";\n td1 = \"<th class='text-center' style='vertical-align: middle; width:\" + nWidthIndicator + \"px;'>Indicator</th>\";\n td2 = \"<th class='text-center' style='vertical-align: middle; width:\" + nWidthTD + \"px;'>Unit</th>\";\n td3 = \"<th class='text-center' style='vertical-align: middle; width:\" + nWidthTD + \"px;'>Target</th>\";\n for (var i = 1; i <= 12 ; i++) {\n tdHead += \"<th class='text-center QHead_\" + getQrt(i) + \"' style='width:\" + nWidthTD + \"px;'>Q\" + getQrt(i) + \" : \" + arrM[i - 1] + \"</th>\";\n }\n tr = \"<thead><tr>\" + td1 + td2 + td3 + tdHead + \"</tr></thead>\";\n return tr;\n}", "title": "" }, { "docid": "90047d8ddb023c41072e70e742e83391", "score": "0.54710233", "text": "function createThead(table, data) {\r\n\ttable.innerHTML = '';\r\n\tlet thead = table.createTHead();\r\n\tlet row = thead.insertRow();\r\n\r\n\tfor (let key of data) {\r\n\t\tlet th = document.createElement('th');\r\n\t\tlet text = document.createTextNode(key);\r\n\t\tth.appendChild(text);\r\n\t\trow.appendChild(th);\r\n\t}\r\n}", "title": "" }, { "docid": "28ee4ed40f6ba05d71e9d70cca00f072", "score": "0.54698986", "text": "renderHead(){\n const row = document.createElement('tr')\n row.className = 'simpletable-head'\n\n // Create a cell for each col\n this.columns.forEach(option => {\n const cell = document.createElement('th')\n cell.textContent = option.label\n\n if(option.classList) {\n cell.classList = option.classList\n }\n cell.setAttribute('field', option.field)\n\n // If sortable append icon and add event listener\n if(option.sortable) {\n const sort = document.createElement('i')\n sort.classList.add(\"fal\", \"fa-long-arrow-down\", \"simpletable-sort\")\n cell.appendChild(sort)\n sort.addEventListener('click', evt => this.handleSort(evt))\n }\n row.appendChild(cell)\n });\n // Append to table\n this.table.appendChild(row)\n }", "title": "" }, { "docid": "acf800c713672847528e8dc22faf4d72", "score": "0.5466547", "text": "function fixTableCaretPos() {\n\t\t\teditor.on('KeyDown SetContent VisualAid', function() {\n\t\t\t\tvar last;\n\n\t\t\t\t// Skip empty text nodes from the end\n\t\t\t\tfor (last = editor.getBody().lastChild; last; last = last.previousSibling) {\n\t\t\t\t\tif (last.nodeType == 3) {\n\t\t\t\t\t\tif (last.nodeValue.length > 0) {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t} else if (last.nodeType == 1 && (last.tagName == 'BR' || !last.getAttribute('data-mce-bogus'))) {\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (last && last.nodeName == 'TABLE') {\n\t\t\t\t\tif (editor.settings.forced_root_block) {\n\t\t\t\t\t\teditor.dom.add(\n\t\t\t\t\t\t\teditor.getBody(),\n\t\t\t\t\t\t\teditor.settings.forced_root_block,\n\t\t\t\t\t\t\teditor.settings.forced_root_block_attrs,\n\t\t\t\t\t\t\tEnv.ie && Env.ie < 10 ? '&nbsp;' : '<br data-mce-bogus=\"1\" />'\n\t\t\t\t\t\t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\teditor.dom.add(editor.getBody(), 'br', {'data-mce-bogus': '1'});\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t});\n\n\t\t\teditor.on('PreProcess', function(o) {\n\t\t\t\tvar last = o.node.lastChild;\n\n\t\t\t\tif (last && (last.nodeName == \"BR\" || (last.childNodes.length == 1 &&\n\t\t\t\t\t(last.firstChild.nodeName == 'BR' || last.firstChild.nodeValue == '\\u00a0'))) &&\n\t\t\t\t\tlast.previousSibling && last.previousSibling.nodeName == \"TABLE\") {\n\t\t\t\t\teditor.dom.remove(last);\n\t\t\t\t}\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "b49d6d4be2bb7d08b4180201974da505", "score": "0.5464695", "text": "function init_table (table) {\n // hide table during consturction\n table.hide(0);\n\n // construct time header\n header = create_elem('tr').addClass('header-row');\n header.append(create_elem('td').addClass('top-square')); // empty square\n table.append(header);\n\n time_heading(header);\n\n // show table once created\n table.show(0);\n}", "title": "" }, { "docid": "8e788d0823e23da463a15fc0fe0e4d27", "score": "0.54586124", "text": "function setHeaderWidthAndPos() {\n var left = -1 * bodyWrapper[0].scrollLeft;\n var width = bodyWrapper[0].clientWidth + (-1 * left);\n var buffer = bodyWrapper[0].scrollHeight > bodyWrapper[0].clientHeight ? 17 : 0;\n headerWrapper.css(\"left\", left + \"px\");\n headerWrapper.css(\"width\", (width + buffer) + \"px\");\n }", "title": "" }, { "docid": "1228af5c3524bfc5b9e29f0c8ec3d78d", "score": "0.54560405", "text": "_fix_css_in_table(id){\n d3.select('#' + id + '_wrapper')\n .insert(\"div\", \".dataTables_filter + *\")\n .attr('class', 'pc-table-contents')\n .node()\n .appendChild(document.getElementById(id));\n }", "title": "" }, { "docid": "07c68769e7d08c0c5e8eb5cb137c0225", "score": "0.54496026", "text": "function generateTableHead(table,data) {\n let thead = table.createTHead();\n let row = thead.insertRow();\n let th1 = document.createElement(\"th\");\n row.appendChild(th1);\n data.forEach((item,index) => {\n let th = document.createElement(\"th\");\n let text = document.createTextNode(item.title);\n th.appendChild(text);\n row.appendChild(th);\n });\n }", "title": "" }, { "docid": "3e9fd876aafbd8c27cd2eb950cc8a766", "score": "0.5442345", "text": "function setTableTitles(isForced) {\n if (!isForced) {\n return;\n }\n for (var r=0; r<this.countRows(); r++) {\n for (var c=0; c<this.countCols(); c++) {\n cellProperties = this.getCellMeta(r, c);\n if (cellProperties.renderer != valueRenderer) {\n continue;\n }\n if ('valid' in cellProperties && (!cellProperties.valid)) {\n title = cellProperties.validationError; \n } else {\n customizedContent = fromKeysToCustomizedContent(getKeysFromCellPosition(this, r, c));\n title = localized_messages.content_variable_table_value + customizedContent;\n }\n cell = this.getCell(r,c);\n cell.setAttribute(\"title\", title);\n }\n }\n}", "title": "" }, { "docid": "aceb3c020d1be1ed675ee000ff280790", "score": "0.544162", "text": "clearTable() {\n this._hasHeaders = false;\n document.querySelector(\"#leaderboard\").innerHTML = \"<tbody></tbody>\";\n }", "title": "" }, { "docid": "a03c7a9e5c89c12fd5d57f3569982ed2", "score": "0.54388577", "text": "function resetTable(){\n $(\"#tablewrapper\").html(\"<table class='table' id='coursetable'> <thead> <tr> </tr> </thead> <tbody> </tbody> </table>\");\n}", "title": "" }, { "docid": "276d561b9f130b0005ad4145bd8b2647", "score": "0.54050916", "text": "function Layout_Tables_2(cmdi, cmd) {\n var trs_header, trs_lines, trs_filter, count\n var id, linha, sline, sColumns, index, value, has_header\n\n sColumns = split_csv(cmdi.columns) // colunas da tabela\n\n // Remove as 'tr' se cmd.header.clear = true\n if (cmd.pages.length == 0 && cmd.clear) { $(\"#\" + cmdi.table_name + \" tr\").remove() }\n\n if (cmdi.header.show) {\n // Inicializa trs_header com as 'tr' do header do template e em seguida ajusta algumas informacoes (attr, hide, adiciona td de pagina se for o caso e etc.)\n trs_header = $(cmdi.header.template)\n trs_header = Layout_Ajust_Linhas(cmdi, cmd, trs_header, true)\n\n trs_header.each(function (index, tr) {\n $(tr).attr(\"id\", $(tr).attr(\"id\") + \"eader\")\n th_td = $(tr).find(\"th\").clone()\n $(tr).find(\"th\").remove()\n id = $(th_td).attr(\"id\").slice(0, -3)\n\n $.each(cmd.htbl, function (index, line) {\n sline = split_csv(line)\n linha = sline[0] // a primeira column e' usada para indicar a linha\n\n th = th_td.clone().attr(\"id\", id + \"_th_\" + linha)\n tag = $(th).children()\n\n if (tag.length > 0) {\n index = sColumns.indexOf(id) + 1 //Obtem o indice da coluna relacionada e acrescenta + 1, pois a 1a. ocorrencia e' da linha\n if (index > 0) {\n value = sline[index]\n\n if (tag.is(\"input[type='text']\") || tag.is(\"textarea\") || tag.is(\"select\")) {\n $(tag).val(value)\n }\n else if (tag.is(\"label\") || tag.is(\"button\") || tag.is(\"span\")) {\n $(tag).text(value)\n }\n else if ($(tag).is(':checkbox')) {\n $(tag).prop('checked', (value == \"True\" || value == \"true\")).bootstrapSwitch()\n }\n else if (tag.is(\"img\")) {\n $(tag).attr(\"src\", (value.length) ? value : htbl_buttons_default[cmdi.itens.red_button])\n }\n }\n $(tag).attr(\"id\", id + \"_\" + linha)\n th.appendTo($(tr))\n }\n });\n });\n\n Set_Color(trs_header, \"cell_header\", true, true, false)\n\n trs_header.appendTo(\"#\" + cmdi.table_name)\n }\n\n // Inicializa trs_lines com as 'tr' das linhas do template e em seguida ajusta algumas informacoes (attr, hide, adiciona td de pagina se for o caso e etc.)\n trs_lines = $(cmdi.itens.template)\n trs_lines = Layout_Ajust_Linhas(cmdi, cmd, trs_lines, false)\n\n trs_lines.each(function (index, tr) {\n th_td = $(tr).find(\"td\").clone()\n $(tr).find(\"td\").remove()\n id = $(th_td).attr(\"id\").slice(0, -3)\n\n $.each(cmd.htbl, function (index, line) {\n sline = split_csv(line)\n linha = sline[0] // a primeira column e' usada para indicar a linha\n\n td = th_td.clone().attr(\"id\", id + \"_td_\" + linha)\n tag = $(td).children()\n\n if (tag.length > 0) {\n index = sColumns.indexOf(id) + 1 //Obtem o indice da coluna relacionada e acrescenta + 1, pois a 1a. ocorrencia e' da linha\n if (index > 0) {\n value = sline[index]\n\n if (tag.is(\"input[type='text']\") || tag.is(\"textarea\") || tag.is(\"select\")) {\n $(tag).val(value)\n }\n else if (tag.is(\"label\") || tag.is(\"button\") || tag.is(\"span\")) {\n $(tag).text(value)\n }\n else if (tag.is(\"img\")) {\n $(tag).attr(\"src\", (value.length) ? value : htbl_buttons_default[cmdi.itens.red_button])\n }\n }\n $(tag).attr(\"id\", id + \"_\" + linha)\n td.appendTo($(tr))\n }\n });\n });\n\n trs_lines.appendTo(\"#\" + cmdi.table_name)\n\n Set_Color(trs_lines, \"cell\", true, true, false)\n\n // Pauta o table.\n pauta_table(cmdi.table_name)\n\n // Ativa resisable\n $('th, td').resizable({ handles: 'e' });\n\n // Arredonda os corners \n round_table_corner(cmdi.tbl_referencia + \"_table\")\n}", "title": "" }, { "docid": "a9b341d174b1479c8aa8d39210b59cf1", "score": "0.5392854", "text": "function resetTable(){\n\tvar newTableBody = document.createElement(\"tbody\");\n\tvar oldTableBody = document.getElementById(\"tableBody\");\n\toldTableBody.parentNode.replaceChild(newTableBody, oldTableBody);\n\tnewTableBody.id = \"tableBody\";\n}", "title": "" }, { "docid": "c81ac2b84d261aed3b5e7eeb1518b6f3", "score": "0.5388838", "text": "function createTableHeader(array) {\n var newThRow = document.createElement('tr');\n positionTable.appendChild(newTHead);\n newTHead.appendChild(newThRow);\n for (var j = 0; j < array.length; j++) {\n var newTh = document.createElement('th');\n newThRow.appendChild(newTh);\n newTh.textContent = array[j];\n if (j === 0){\n newTh.id = 'firstItem';\n };\n };\n}", "title": "" }, { "docid": "5fdb496b60befdd12da8a6e0f83ba6f7", "score": "0.53866696", "text": "getTable () {\n const el = super.getTable()\n el.classList.add('table', 'table-scroll')\n if (this.options.table_border) el.classList.add('je-table-border')\n if (this.options.table_zebrastyle) el.classList.add('table-striped')\n return el\n }", "title": "" }, { "docid": "508df8336d7de01dd422df530dc76266", "score": "0.5377403", "text": "function ativarDatatableMenor() {\n\t\t\n\t\tvar data_table\t\t\t= $.extend({}, table_default);\n\t\t\tdata_table.scrollY = '197px';\n\t\t\tdata_table.language = {emptyTable : \"Escolha itens da tabela acima\"};\n\n\t\t$('.conteudo-filtro .estacao-bloco .table').DataTable(data_table);\n\t\t\n\t}", "title": "" }, { "docid": "8aab42e5c1fd319b1bf8ada8e17f5bd0", "score": "0.5373879", "text": "function _fnDrawHead( oSettings, aoSource, bIncludeHidden )\n\t\t{\n\t\t\tvar i, iLen, j, jLen, k, kLen;\n\t\t\tvar aoLocal = [];\n\t\t\tvar aApplied = [];\n\t\t\tvar iColumns = oSettings.aoColumns.length;\n\t\t\tvar iRowspan, iColspan;\n\n\t\t\tif ( typeof bIncludeHidden == 'undefined' )\n\t\t\t{\n\t\t\t\tbIncludeHidden = false;\n\t\t\t}\n\n\t\t\t/* Make a copy of the master layout array, but without the visible columns in it */\n\t\t\tfor ( i=0, iLen=aoSource.length ; i<iLen ; i++ )\n\t\t\t{\n\t\t\t\taoLocal[i] = aoSource[i].slice();\n\t\t\t\taoLocal[i].nTr = aoSource[i].nTr;\n\n\t\t\t\t/* Remove any columns which are currently hidden */\n\t\t\t\tfor ( j=iColumns-1 ; j>=0 ; j-- )\n\t\t\t\t{\n\t\t\t\t\tif ( !oSettings.aoColumns[j].bVisible && !bIncludeHidden )\n\t\t\t\t\t{\n\t\t\t\t\t\taoLocal[i].splice( j, 1 );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* Prep the applied array - it needs an element for each row */\n\t\t\t\taApplied.push( [] );\n\t\t\t}\n\n\t\t\tfor ( i=0, iLen=aoLocal.length ; i<iLen ; i++ )\n\t\t\t{\n\t\t\t\t/* All cells are going to be replaced, so empty out the row */\n\t\t\t\tif ( aoLocal[i].nTr )\n\t\t\t\t{\n\t\t\t\t\tfor ( k=0, kLen=aoLocal[i].nTr.childNodes.length ; k<kLen ; k++ )\n\t\t\t\t\t{\n\t\t\t\t\t\taoLocal[i].nTr.removeChild( aoLocal[i].nTr.childNodes[0] );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tfor ( j=0, jLen=aoLocal[i].length ; j<jLen ; j++ )\n\t\t\t\t{\n\t\t\t\t\tiRowspan = 1;\n\t\t\t\t\tiColspan = 1;\n\n\t\t\t\t\t/* Check to see if there is already a cell (row/colspan) covering our target\n\t\t\t\t\t * insert point. If there is, then there is nothing to do.\n\t\t\t\t\t */\n\t\t\t\t\tif ( typeof aApplied[i][j] == 'undefined' )\n\t\t\t\t\t{\n\t\t\t\t\t\taoLocal[i].nTr.appendChild( aoLocal[i][j].cell );\n\t\t\t\t\t\taApplied[i][j] = 1;\n\n\t\t\t\t\t\t/* Expand the cell to cover as many rows as needed */\n\t\t\t\t\t\twhile ( typeof aoLocal[i+iRowspan] != 'undefined' &&\n\t\t\t\t\t\t aoLocal[i][j].cell == aoLocal[i+iRowspan][j].cell )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\taApplied[i+iRowspan][j] = 1;\n\t\t\t\t\t\t\tiRowspan++;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* Expand the cell to cover as many columns as needed */\n\t\t\t\t\t\twhile ( typeof aoLocal[i][j+iColspan] != 'undefined' &&\n\t\t\t\t\t\t aoLocal[i][j].cell == aoLocal[i][j+iColspan].cell )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t/* Must update the applied array over the rows for the columns */\n\t\t\t\t\t\t\tfor ( k=0 ; k<iRowspan ; k++ )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\taApplied[i+k][j+iColspan] = 1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tiColspan++;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* Do the actual expansion in the DOM */\n\t\t\t\t\t\taoLocal[i][j].cell.setAttribute('rowspan', iRowspan);\n\t\t\t\t\t\taoLocal[i][j].cell.setAttribute('colspan', iColspan);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "abb26ba99ed5c50b71cd76027d849470", "score": "0.5373879", "text": "function _fnDrawHead( oSettings, aoSource, bIncludeHidden )\n\t\t{\n\t\t\tvar i, iLen, j, jLen, k, kLen;\n\t\t\tvar aoLocal = [];\n\t\t\tvar aApplied = [];\n\t\t\tvar iColumns = oSettings.aoColumns.length;\n\t\t\tvar iRowspan, iColspan;\n\n\t\t\tif ( typeof bIncludeHidden == 'undefined' )\n\t\t\t{\n\t\t\t\tbIncludeHidden = false;\n\t\t\t}\n\n\t\t\t/* Make a copy of the master layout array, but without the visible columns in it */\n\t\t\tfor ( i=0, iLen=aoSource.length ; i<iLen ; i++ )\n\t\t\t{\n\t\t\t\taoLocal[i] = aoSource[i].slice();\n\t\t\t\taoLocal[i].nTr = aoSource[i].nTr;\n\n\t\t\t\t/* Remove any columns which are currently hidden */\n\t\t\t\tfor ( j=iColumns-1 ; j>=0 ; j-- )\n\t\t\t\t{\n\t\t\t\t\tif ( !oSettings.aoColumns[j].bVisible && !bIncludeHidden )\n\t\t\t\t\t{\n\t\t\t\t\t\taoLocal[i].splice( j, 1 );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\t/* Prep the applied array - it needs an element for each row */\n\t\t\t\taApplied.push( [] );\n\t\t\t}\n\n\t\t\tfor ( i=0, iLen=aoLocal.length ; i<iLen ; i++ )\n\t\t\t{\n\t\t\t\t/* All cells are going to be replaced, so empty out the row */\n\t\t\t\tif ( aoLocal[i].nTr )\n\t\t\t\t{\n\t\t\t\t\tfor ( k=0, kLen=aoLocal[i].nTr.childNodes.length ; k<kLen ; k++ )\n\t\t\t\t\t{\n\t\t\t\t\t\taoLocal[i].nTr.removeChild( aoLocal[i].nTr.childNodes[0] );\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tfor ( j=0, jLen=aoLocal[i].length ; j<jLen ; j++ )\n\t\t\t\t{\n\t\t\t\t\tiRowspan = 1;\n\t\t\t\t\tiColspan = 1;\n\n\t\t\t\t\t/* Check to see if there is already a cell (row/colspan) covering our target\n\t\t\t\t\t * insert point. If there is, then there is nothing to do.\n\t\t\t\t\t */\n\t\t\t\t\tif ( typeof aApplied[i][j] == 'undefined' )\n\t\t\t\t\t{\n\t\t\t\t\t\taoLocal[i].nTr.appendChild( aoLocal[i][j].cell );\n\t\t\t\t\t\taApplied[i][j] = 1;\n\n\t\t\t\t\t\t/* Expand the cell to cover as many rows as needed */\n\t\t\t\t\t\twhile ( typeof aoLocal[i+iRowspan] != 'undefined' &&\n\t\t\t\t\t\t aoLocal[i][j].cell == aoLocal[i+iRowspan][j].cell )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\taApplied[i+iRowspan][j] = 1;\n\t\t\t\t\t\t\tiRowspan++;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* Expand the cell to cover as many columns as needed */\n\t\t\t\t\t\twhile ( typeof aoLocal[i][j+iColspan] != 'undefined' &&\n\t\t\t\t\t\t aoLocal[i][j].cell == aoLocal[i][j+iColspan].cell )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t/* Must update the applied array over the rows for the columns */\n\t\t\t\t\t\t\tfor ( k=0 ; k<iRowspan ; k++ )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\taApplied[i+k][j+iColspan] = 1;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tiColspan++;\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t/* Do the actual expansion in the DOM */\n\t\t\t\t\t\taoLocal[i][j].cell.rowSpan = iRowspan;\n\t\t\t\t\t\taoLocal[i][j].cell.colSpan = iColspan;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "565066b62053bab1bfc3db00440f2be4", "score": "0.53635603", "text": "function renderHead() {\n var tableHead = document.createElement('thead');\n tableHead.appendChild(newEl('th',''));\n\n for (var i of hours) {\n tableHead.appendChild(newEl('th',i));\n }\n\n tableHead.appendChild(newEl('th','Total'));\n salesTable.appendChild(tableHead);\n}", "title": "" }, { "docid": "f8cc220393557a8e7c79ddbabf051c9f", "score": "0.5354724", "text": "function headFun() {\n var tableFirstRow = document.createElement(\"tr\");\n table.appendChild(tableFirstRow);\n\n var headerArray = [\n \" \",\n \"6:00am\",\n \"7:00am\",\n \"8:00am\",\n \"9:00am\",\n \"10:00am\",\n \"11:00am\",\n \"12:00pm\",\n \"1:00pm\",\n \"2:00pm\",\n \"3:00pm\",\n \"4:00pm\",\n \"5:00pm\",\n \"6:00pm\",\n \"7:00pm\",\n \"Daily Location Total\",\n ];\n for (var i = 0; i < headerArray.length; i++) {\n var headerOne = document.createElement(\"th\");\n\n headerOne.textContent = headerArray[i];\n tableFirstRow.appendChild(headerOne);\n }\n}", "title": "" }, { "docid": "9a362711970dc71a55598a8b88ba0cd7", "score": "0.53508335", "text": "function adjustHeaders()\n {\n var xPos = (parent.w - totalHeaderWidth)/2;\n //set the x position for each of the tab's header text\n for(var i = 0; i < tabs.length; i++)\n {\n tabs[i].setHeaderPos({x:xPos});\n xPos += model.headerFont.measureText(model.headerPixelSize,tabs[i].getHeaderText()).w;\n xPos += model.headerGap;\n }\n\n // set the position and width of the bottom separator\n botSeparator.x = (parent.w - totalHeaderWidth - model.headerGap)/2;\n botSeparator.w = totalHeaderWidth + model.headerGap;\n\n }", "title": "" }, { "docid": "086a79a534bdd1ac06da9e4792c11b8e", "score": "0.5349621", "text": "function parseHeadTable(data, start) {\n\t var head = {};\n\t var p = new parse.Parser(data, start);\n\t head.version = p.parseVersion();\n\t head.fontRevision = Math.round(p.parseFixed() * 1000) / 1000;\n\t head.checkSumAdjustment = p.parseULong();\n\t head.magicNumber = p.parseULong();\n\t check.argument(head.magicNumber === 0x5F0F3CF5, 'Font header has wrong magic number.');\n\t head.flags = p.parseUShort();\n\t head.unitsPerEm = p.parseUShort();\n\t head.created = p.parseLongDateTime();\n\t head.modified = p.parseLongDateTime();\n\t head.xMin = p.parseShort();\n\t head.yMin = p.parseShort();\n\t head.xMax = p.parseShort();\n\t head.yMax = p.parseShort();\n\t head.macStyle = p.parseUShort();\n\t head.lowestRecPPEM = p.parseUShort();\n\t head.fontDirectionHint = p.parseShort();\n\t head.indexToLocFormat = p.parseShort(); // 50\n\t head.glyphDataFormat = p.parseShort();\n\t return head;\n\t}", "title": "" }, { "docid": "bf135305accd4430b5f50a6e22dd9230", "score": "0.53423494", "text": "tableHeader() {\n return \"<tr>\" + this.HEADER.map(el => \"<th>\" + el + \"</th>\").join(\"\") + \"</tr>\";\n }", "title": "" }, { "docid": "8d2f8f09aadb6b10decb36039f250d1c", "score": "0.5339048", "text": "function printTableHeader() {\n console.log(' Time Value N_O Roll_Sum Min_Value Max_Value');\n console.log('-------------------------------------------------------');\n}", "title": "" }, { "docid": "64644a4671f721ca0e029cdcf171fbcf", "score": "0.5337285", "text": "function resetTable(tableID){\n var table = document.getElementById(tableID);\n table.innerHTML = \"\";\n var row = table.insertRow();\n var headerCell1 = row.insertCell(0);\n headerCell1.outerHTML = \"<th>ID</th>\";\n var headerCell2 = row.insertCell(1);\n headerCell2.outerHTML = \"<th>Description</th>\";\n}", "title": "" }, { "docid": "5f2c6c6f321b1e9f97f5103e2996b397", "score": "0.53306913", "text": "function parseHeadTable(data,start){var head={};var p=new parse.Parser(data,start);head.version=p.parseVersion();head.fontRevision=Math.round(p.parseFixed()*1000)/1000;head.checkSumAdjustment=p.parseULong();head.magicNumber=p.parseULong();check.argument(head.magicNumber===0x5F0F3CF5,'Font header has wrong magic number.');head.flags=p.parseUShort();head.unitsPerEm=p.parseUShort();head.created=p.parseLongDateTime();head.modified=p.parseLongDateTime();head.xMin=p.parseShort();head.yMin=p.parseShort();head.xMax=p.parseShort();head.yMax=p.parseShort();head.macStyle=p.parseUShort();head.lowestRecPPEM=p.parseUShort();head.fontDirectionHint=p.parseShort();head.indexToLocFormat=p.parseShort();head.glyphDataFormat=p.parseShort();return head;}", "title": "" }, { "docid": "76dc0969a4ec9fffc63f90ee307ab954", "score": "0.5327138", "text": "function Table() {\n this.columns = null; // written with the first row\n this.rows = [];\n }", "title": "" }, { "docid": "1252f988005584a67f566e69b54255fa", "score": "0.5324519", "text": "function newsTableHeaders() {\n return \"<tr>\" +\n \"<td style='width:95px;'> Date</td>\" +\n \"<td> Partial Data</td>\" +\n \"<td style='width:205px;'> Opts</td>\" +\n \"</tr>\";\n}", "title": "" }, { "docid": "f3f92840b8720d447c8c9d4263dcc595", "score": "0.5318322", "text": "function generateTableHead(table) {\n let thead = table.createTHead();\n// insertRow creating rows\n let row = thead.insertRow();\n for (let key of data) {\n let th = document.createElement(\"th\");\n let text = document.createTextNode(key);\n th.appendChild(text);\n row.appendChild(th);\n }\n}", "title": "" }, { "docid": "c1e51e4d1ea5663eab0d9e1dc8b55453", "score": "0.5311344", "text": "function tableHead() {\n var tableHeadEl = document.createElement('thead');\n tableHeadEl.textContent = 'Times';\n tableEl.appendChild(tableHeadEl);\n\n for (var i = 0; i < openTimes.length; i++) {\n var hourEl = document.createElement('th');\n hourEl.textContent = openTimes[i];\n tableHeadEl.appendChild(hourEl);\n }\n\n var storeTotalEl = document.createElement('th');\n storeTotalEl.textContent = 'Daily Total';\n tableHeadEl.appendChild(storeTotalEl);\n}", "title": "" }, { "docid": "87d1144cd5d24accd7c327346ceb3d88", "score": "0.53084177", "text": "function setTracksTopFontToWhite() {\n var ss = SpreadsheetApp.getActiveSpreadsheet();\n var sheet = ss.getSheetByName(getNewSheetName());\n for(var i = 0; i < _numTables(); i++) {\n var tableHeader = ss.getRangeByName(\"PairsDocTableHeader\" + i);\n var tracksTop = sheet.getRange(tableHeader.getRow()+1, \n 1,\n 4,\n 1);\n tracksTop.setFontColor(\"white\");\n } \n}", "title": "" }, { "docid": "ce05e6f52784da998b29ca6fb6200125", "score": "0.53067493", "text": "function setLeft(depth) {\n var leftWidth = (depth * 100) + 70 + 70 + 30; //날짜, 주파수, 그래프\n\n $(\"#tableTopLeft\").css(\"width\",leftWidth);\n $(\"#tableMiddleLeft\").css(\"width\",leftWidth);\n $(\"#tableBottomLeft\").css(\"width\",leftWidth);\n\n $(\"#tableTopLeft\").unwrap();\n $(\"#tableTopLeft\").wrap(\"<div name='divTopLeft' id='divTopLeft'></div>\");\n $(\"#tableBottomLeft\").unwrap();\n $(\"#tableBottomLeft\").wrap(\"<div name='divBottomLeft' id='divBottomLeft'></div>\");\n\n var middleWidth = 720 + 100 * (3-depth); //620 : css에서 div[name=divTopRight] width 값, 100 : title 그룹의 width 값\n //hide 된 td의 padding & margin 분 추가\n if(depth === 1) {\n middleWidth += 20;\n } else if (depth === 2) {\n middleWidth += 10;\n }\n $(\"#tableTopRight\").unwrap();\n $(\"#tableTopRight\").wrap(\"<div name='divTopRight' id='divTopRight' style='width:\"+middleWidth+\"px;'></div>\");\n $(\"#tableMiddleRight\").unwrap();\n $(\"#tableMiddleRight\").wrap(\"<div name='divMiddleRight' id='divMiddleRight' onscroll='javascript:scrollY();' style='width:\"+(middleWidth+16)+\"px;'></div>\"); //16 : scroll width 값\n $(\"#tableBottomRight\").unwrap();\n $(\"#tableBottomRight\").wrap(\"<div name='divBottomRight' id='divBottomRight' onscroll='javascript:scrollX();' style='width:\"+middleWidth+\"px;'></div>\");\n\n $(\"#tableMiddleLeft tbody\").empty();\n $(\"#tableMiddleRight tbody\").empty();\n $(\"#tableBottomRight\").find(\"td\").html(\"&nbsp;\");\n\n /*===============================================================================\n * For SCROLL APPEND\n *==============================================================================*/\n $(\"#divMiddleRight\").scroll(function(){\n if($(this)[0].scrollHeight - $(this).scrollTop() <= $(this).outerHeight())\n {\n appendToTable(function(){}); //callback 필요시 삽입\n }\n });\n /*===============================================================================\n * End For SCROLL APPEND\n *==============================================================================*/\n}", "title": "" }, { "docid": "0955d48c5ed0744f2be45729dad84100", "score": "0.53051597", "text": "renderTableHead() {\n return (\n <thead>\n <tr>\n <th scope=\"col\">#</th>\n <th scope=\"col\">Part Number</th>\n <th scope=\"col\">Description</th>\n <th scope=\"col\">Quantity</th>\n <th scope=\"col\">Unit Price</th>\n <th scope=\"col\">Extended Price</th>\n </tr>\n </thead>\n );\n }", "title": "" }, { "docid": "7a3cff66f7888631a1c008c496225938", "score": "0.5304578", "text": "function showTableHeader(table)\n{\n\tvar header = table.selectAll(\"thead\").data(function(d) { return [d.columns] });\n\theader.enter().append(\"thead\");\n\tvar headerRows = header.selectAll(\"tr\").data(function(d) { return [d] });\n\theaderRows.enter().append(\"tr\");\n\tvar headerData = headerRows.selectAll(\"th\").data(function(d) { return d; });\n\theaderData.enter().append(\"th\");\n\theaderData.text(function (d) { return d.title})\n}", "title": "" }, { "docid": "80f6c03c8eeef7c59df4ab1dabe9aeeb", "score": "0.53033173", "text": "moveCaretToHead() {\n const layoutPos = this.getLayoutTextPosition(this.caret);\n const wline = this.wrappedLines[layoutPos.wlineIndex];\n this.caret = this.getHeadTextPosition(wline);\n }", "title": "" }, { "docid": "0ece5267d5526f5ca6b2e7ede1eda327", "score": "0.5301675", "text": "function updateTableWidth() {\r\n\t\t$('.tradinntabl td:nth-child(3) span').attr('style', 'width: 50px !important');\r\n\t}", "title": "" }, { "docid": "96e4fa78da86825914d24bce84042ec9", "score": "0.52995443", "text": "function appendTable() {\n\t\tvar snippet = '<table class=\"table\">\\n'+\n\t\t'\t<thead>\\n'+\n\t\t'\t\t<tr>\\n'+\n\t\t'\t\t\t<th>#</th>\\n'+\n\t\t'\t\t\t<th>First Name</th>\\n'+\n\t\t'\t\t\t<th>Last Name</th>\\n'+\n\t\t'\t\t\t<th>Username</th>\\n'+\n\t\t'\t\t</tr>\\n'+\n\t\t'\t</thead>\\n'+\n\t\t'\t<tbody>\\n'+\n\t\t'\t\t<tr>\\n'+\n\t\t'\t\t\t<th scope=\"row\">1</th>\\n'+\n\t\t'\t\t\t<td>Mark</td>\\n'+\n\t\t'\t\t\t<td>Otto</td>\\n'+\n\t\t'\t\t\t<td>@mdo</td>\\n'+\n\t\t'\t\t</tr>\\n'+\n\t\t'\t</tbody>\\n'+\n\t\t'</table>';\n\n\t\tvar editor = edManager.getCurrentFullEditor();\n\t\tif(editor){\n\t\t\tvar insertionPos = editor.getCursorPos();\n\t\t\teditor.document.replaceRange(snippet, insertionPos);\n\t\t}\n\t}", "title": "" }, { "docid": "7893214303b9d00768f463dcf0836b7b", "score": "0.52870864", "text": "function _fnFeatureHtmlTable ( oSettings )\n\t\t{\n\t\t\t/* Chack if scrolling is enabled or not - if not then leave the DOM unaltered */\n\t\t\tif ( oSettings.oScroll.sX === \"\" && oSettings.oScroll.sY === \"\" )\n\t\t\t{\n\t\t\t\treturn oSettings.nTable;\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * The HTML structure that we want to generate in this function is:\n\t\t\t * div - nScroller\n\t\t\t * div - nScrollHead\n\t\t\t * div - nScrollHeadInner\n\t\t\t * table - nScrollHeadTable\n\t\t\t * thead - nThead\n\t\t\t * div - nScrollBody\n\t\t\t * table - oSettings.nTable\n\t\t\t * thead - nTheadSize\n\t\t\t * tbody - nTbody\n\t\t\t * div - nScrollFoot\n\t\t\t * div - nScrollFootInner\n\t\t\t * table - nScrollFootTable\n\t\t\t * tfoot - nTfoot\n\t\t\t */\n\t\t\tvar\n\t\t\t \tnScroller = document.createElement('div'),\n\t\t\t \tnScrollHead = document.createElement('div'),\n\t\t\t \tnScrollHeadInner = document.createElement('div'),\n\t\t\t \tnScrollBody = document.createElement('div'),\n\t\t\t \tnScrollFoot = document.createElement('div'),\n\t\t\t \tnScrollFootInner = document.createElement('div'),\n\t\t\t \tnScrollHeadTable = oSettings.nTable.cloneNode(false),\n\t\t\t \tnScrollFootTable = oSettings.nTable.cloneNode(false),\n\t\t\t\tnThead = oSettings.nTable.getElementsByTagName('thead')[0],\n\t\t\t \tnTfoot = oSettings.nTable.getElementsByTagName('tfoot').length === 0 ? null : \n\t\t\t\t\toSettings.nTable.getElementsByTagName('tfoot')[0],\n\t\t\t\toClasses = (typeof oInit.bJQueryUI != 'undefined' && oInit.bJQueryUI) ?\n\t\t\t\t\t_oExt.oJUIClasses : _oExt.oStdClasses;\n\t\t\t\n\t\t\tnScrollHead.appendChild( nScrollHeadInner );\n\t\t\tnScrollFoot.appendChild( nScrollFootInner );\n\t\t\tnScrollBody.appendChild( oSettings.nTable );\n\t\t\tnScroller.appendChild( nScrollHead );\n\t\t\tnScroller.appendChild( nScrollBody );\n\t\t\tnScrollHeadInner.appendChild( nScrollHeadTable );\n\t\t\tnScrollHeadTable.appendChild( nThead );\n\t\t\tif ( nTfoot !== null )\n\t\t\t{\n\t\t\t\tnScroller.appendChild( nScrollFoot );\n\t\t\t\tnScrollFootInner.appendChild( nScrollFootTable );\n\t\t\t\tnScrollFootTable.appendChild( nTfoot );\n\t\t\t}\n\t\t\t\n\t\t\tnScroller.className = oClasses.sScrollWrapper;\n\t\t\tnScrollHead.className = oClasses.sScrollHead;\n\t\t\tnScrollHeadInner.className = oClasses.sScrollHeadInner;\n\t\t\tnScrollBody.className = oClasses.sScrollBody;\n\t\t\tnScrollFoot.className = oClasses.sScrollFoot;\n\t\t\tnScrollFootInner.className = oClasses.sScrollFootInner;\n\t\t\t\n\t\t\tif ( oSettings.oScroll.bAutoCss )\n\t\t\t{\n\t\t\t\tnScrollHead.style.overflow = \"hidden\";\n\t\t\t\tnScrollHead.style.position = \"relative\";\n\t\t\t\tnScrollFoot.style.overflow = \"hidden\";\n\t\t\t\tnScrollBody.style.overflow = \"auto\";\n\t\t\t}\n\t\t\t\n\t\t\tnScrollHead.style.border = \"0\";\n\t\t\tnScrollHead.style.width = \"100%\";\n\t\t\tnScrollFoot.style.border = \"0\";\n\t\t\tnScrollHeadInner.style.width = \"150%\"; /* will be overwritten */\n\t\t\t\n\t\t\t/* Modify attributes to respect the clones */\n\t\t\tnScrollHeadTable.removeAttribute('id');\n\t\t\tnScrollHeadTable.style.marginLeft = \"0\";\n\t\t\toSettings.nTable.style.marginLeft = \"0\";\n\t\t\tif ( nTfoot !== null )\n\t\t\t{\n\t\t\t\tnScrollFootTable.removeAttribute('id');\n\t\t\t\tnScrollFootTable.style.marginLeft = \"0\";\n\t\t\t}\n\t\t\t\n\t\t\t/* Move any caption elements from the body to the header */\n\t\t\tvar nCaptions = $('>caption', oSettings.nTable);\n\t\t\tfor ( var i=0, iLen=nCaptions.length ; i<iLen ; i++ )\n\t\t\t{\n\t\t\t\tnScrollHeadTable.appendChild( nCaptions[i] );\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * Sizing\n\t\t\t */\n\t\t\t/* When xscrolling add the width and a scroller to move the header with the body */\n\t\t\tif ( oSettings.oScroll.sX !== \"\" )\n\t\t\t{\n\t\t\t\tnScrollHead.style.width = _fnStringToCss( oSettings.oScroll.sX );\n\t\t\t\tnScrollBody.style.width = _fnStringToCss( oSettings.oScroll.sX );\n\t\t\t\t\n\t\t\t\tif ( nTfoot !== null )\n\t\t\t\t{\n\t\t\t\t\tnScrollFoot.style.width = _fnStringToCss( oSettings.oScroll.sX );\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t/* When the body is scrolled, then we also want to scroll the headers */\n\t\t\t\t$(nScrollBody).scroll( function (e) {\n\t\t\t\t\tnScrollHead.scrollLeft = this.scrollLeft;\n\t\t\t\t\t\n\t\t\t\t\tif ( nTfoot !== null )\n\t\t\t\t\t{\n\t\t\t\t\t\tnScrollFoot.scrollLeft = this.scrollLeft;\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t}\n\t\t\t\n\t\t\t/* When yscrolling, add the height */\n\t\t\tif ( oSettings.oScroll.sY !== \"\" )\n\t\t\t{\n\t\t\t\tnScrollBody.style.height = _fnStringToCss( oSettings.oScroll.sY );\n\t\t\t}\n\t\t\t\n\t\t\t/* Redraw - align columns across the tables */\n\t\t\toSettings.aoDrawCallback.push( {\n\t\t\t\t\"fn\": _fnScrollDraw,\n\t\t\t\t\"sName\": \"scrolling\"\n\t\t\t} );\n\t\t\t\n\t\t\t/* Infinite scrolling event handlers */\n\t\t\tif ( oSettings.oScroll.bInfinite )\n\t\t\t{\n\t\t\t\t$(nScrollBody).scroll( function() {\n\t\t\t\t\t/* Use a blocker to stop scrolling from loading more data while other data is still loading */\n\t\t\t\t\tif ( !oSettings.bDrawing )\n\t\t\t\t\t{\n\t\t\t\t\t\t/* Check if we should load the next data set */\n\t\t\t\t\t\tif ( $(this).scrollTop() + $(this).height() > \n\t\t\t\t\t\t\t$(oSettings.nTable).height() - oSettings.oScroll.iLoadGap )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t/* Only do the redraw if we have to - we might be at the end of the data */\n\t\t\t\t\t\t\tif ( oSettings.fnDisplayEnd() < oSettings.fnRecordsDisplay() )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t_fnPageChange( oSettings, 'next' );\n\t\t\t\t\t\t\t\t_fnCalculateEnd( oSettings );\n\t\t\t\t\t\t\t\t_fnDraw( oSettings );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t}\n\t\t\t\n\t\t\toSettings.nScrollHead = nScrollHead;\n\t\t\toSettings.nScrollFoot = nScrollFoot;\n\t\t\t\n\t\t\treturn nScroller;\n\t\t}", "title": "" }, { "docid": "0bfc61274eea0755276604ba18350fc8", "score": "0.52870864", "text": "function _fnFeatureHtmlTable ( oSettings )\n\t\t{\n\t\t\t/* Chack if scrolling is enabled or not - if not then leave the DOM unaltered */\n\t\t\tif ( oSettings.oScroll.sX === \"\" && oSettings.oScroll.sY === \"\" )\n\t\t\t{\n\t\t\t\treturn oSettings.nTable;\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * The HTML structure that we want to generate in this function is:\n\t\t\t * div - nScroller\n\t\t\t * div - nScrollHead\n\t\t\t * div - nScrollHeadInner\n\t\t\t * table - nScrollHeadTable\n\t\t\t * thead - nThead\n\t\t\t * div - nScrollBody\n\t\t\t * table - oSettings.nTable\n\t\t\t * thead - nTheadSize\n\t\t\t * tbody - nTbody\n\t\t\t * div - nScrollFoot\n\t\t\t * div - nScrollFootInner\n\t\t\t * table - nScrollFootTable\n\t\t\t * tfoot - nTfoot\n\t\t\t */\n\t\t\tvar\n\t\t\t \tnScroller = document.createElement('div'),\n\t\t\t \tnScrollHead = document.createElement('div'),\n\t\t\t \tnScrollHeadInner = document.createElement('div'),\n\t\t\t \tnScrollBody = document.createElement('div'),\n\t\t\t \tnScrollFoot = document.createElement('div'),\n\t\t\t \tnScrollFootInner = document.createElement('div'),\n\t\t\t \tnScrollHeadTable = oSettings.nTable.cloneNode(false),\n\t\t\t \tnScrollFootTable = oSettings.nTable.cloneNode(false),\n\t\t\t\tnThead = oSettings.nTable.getElementsByTagName('thead')[0],\n\t\t\t \tnTfoot = oSettings.nTable.getElementsByTagName('tfoot').length === 0 ? null : \n\t\t\t\t\toSettings.nTable.getElementsByTagName('tfoot')[0],\n\t\t\t\toClasses = (typeof oInit.bJQueryUI != 'undefined' && oInit.bJQueryUI) ?\n\t\t\t\t\t_oExt.oJUIClasses : _oExt.oStdClasses;\n\t\t\t\n\t\t\tnScrollHead.appendChild( nScrollHeadInner );\n\t\t\tnScrollFoot.appendChild( nScrollFootInner );\n\t\t\tnScrollBody.appendChild( oSettings.nTable );\n\t\t\tnScroller.appendChild( nScrollHead );\n\t\t\tnScroller.appendChild( nScrollBody );\n\t\t\tnScrollHeadInner.appendChild( nScrollHeadTable );\n\t\t\tnScrollHeadTable.appendChild( nThead );\n\t\t\tif ( nTfoot !== null )\n\t\t\t{\n\t\t\t\tnScroller.appendChild( nScrollFoot );\n\t\t\t\tnScrollFootInner.appendChild( nScrollFootTable );\n\t\t\t\tnScrollFootTable.appendChild( nTfoot );\n\t\t\t}\n\t\t\t\n\t\t\tnScroller.className = oClasses.sScrollWrapper;\n\t\t\tnScrollHead.className = oClasses.sScrollHead;\n\t\t\tnScrollHeadInner.className = oClasses.sScrollHeadInner;\n\t\t\tnScrollBody.className = oClasses.sScrollBody;\n\t\t\tnScrollFoot.className = oClasses.sScrollFoot;\n\t\t\tnScrollFootInner.className = oClasses.sScrollFootInner;\n\t\t\t\n\t\t\tif ( oSettings.oScroll.bAutoCss )\n\t\t\t{\n\t\t\t\tnScrollHead.style.overflow = \"hidden\";\n\t\t\t\tnScrollHead.style.position = \"relative\";\n\t\t\t\tnScrollFoot.style.overflow = \"hidden\";\n\t\t\t\tnScrollBody.style.overflow = \"auto\";\n\t\t\t}\n\t\t\t\n\t\t\tnScrollHead.style.border = \"0\";\n\t\t\tnScrollHead.style.width = \"100%\";\n\t\t\tnScrollFoot.style.border = \"0\";\n\t\t\tnScrollHeadInner.style.width = \"150%\"; /* will be overwritten */\n\t\t\t\n\t\t\t/* Modify attributes to respect the clones */\n\t\t\tnScrollHeadTable.removeAttribute('id');\n\t\t\tnScrollHeadTable.style.marginLeft = \"0\";\n\t\t\toSettings.nTable.style.marginLeft = \"0\";\n\t\t\tif ( nTfoot !== null )\n\t\t\t{\n\t\t\t\tnScrollFootTable.removeAttribute('id');\n\t\t\t\tnScrollFootTable.style.marginLeft = \"0\";\n\t\t\t}\n\t\t\t\n\t\t\t/* Move any caption elements from the body to the header */\n\t\t\tvar nCaptions = $(oSettings.nTable).children('caption');\n\t\t\tfor ( var i=0, iLen=nCaptions.length ; i<iLen ; i++ )\n\t\t\t{\n\t\t\t\tnScrollHeadTable.appendChild( nCaptions[i] );\n\t\t\t}\n\t\t\t\n\t\t\t/*\n\t\t\t * Sizing\n\t\t\t */\n\t\t\t/* When xscrolling add the width and a scroller to move the header with the body */\n\t\t\tif ( oSettings.oScroll.sX !== \"\" )\n\t\t\t{\n\t\t\t\tnScrollHead.style.width = _fnStringToCss( oSettings.oScroll.sX );\n\t\t\t\tnScrollBody.style.width = _fnStringToCss( oSettings.oScroll.sX );\n\t\t\t\t\n\t\t\t\tif ( nTfoot !== null )\n\t\t\t\t{\n\t\t\t\t\tnScrollFoot.style.width = _fnStringToCss( oSettings.oScroll.sX );\t\n\t\t\t\t}\n\t\t\t\t\n\t\t\t\t/* When the body is scrolled, then we also want to scroll the headers */\n\t\t\t\t$(nScrollBody).scroll( function (e) {\n\t\t\t\t\tnScrollHead.scrollLeft = this.scrollLeft;\n\t\t\t\t\t\n\t\t\t\t\tif ( nTfoot !== null )\n\t\t\t\t\t{\n\t\t\t\t\t\tnScrollFoot.scrollLeft = this.scrollLeft;\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t}\n\t\t\t\n\t\t\t/* When yscrolling, add the height */\n\t\t\tif ( oSettings.oScroll.sY !== \"\" )\n\t\t\t{\n\t\t\t\tnScrollBody.style.height = _fnStringToCss( oSettings.oScroll.sY );\n\t\t\t}\n\t\t\t\n\t\t\t/* Redraw - align columns across the tables */\n\t\t\toSettings.aoDrawCallback.push( {\n\t\t\t\t\"fn\": _fnScrollDraw,\n\t\t\t\t\"sName\": \"scrolling\"\n\t\t\t} );\n\t\t\t\n\t\t\t/* Infinite scrolling event handlers */\n\t\t\tif ( oSettings.oScroll.bInfinite )\n\t\t\t{\n\t\t\t\t$(nScrollBody).scroll( function() {\n\t\t\t\t\t/* Use a blocker to stop scrolling from loading more data while other data is still loading */\n\t\t\t\t\tif ( !oSettings.bDrawing )\n\t\t\t\t\t{\n\t\t\t\t\t\t/* Check if we should load the next data set */\n\t\t\t\t\t\tif ( $(this).scrollTop() + $(this).height() > \n\t\t\t\t\t\t\t$(oSettings.nTable).height() - oSettings.oScroll.iLoadGap )\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t/* Only do the redraw if we have to - we might be at the end of the data */\n\t\t\t\t\t\t\tif ( oSettings.fnDisplayEnd() < oSettings.fnRecordsDisplay() )\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t_fnPageChange( oSettings, 'next' );\n\t\t\t\t\t\t\t\t_fnCalculateEnd( oSettings );\n\t\t\t\t\t\t\t\t_fnDraw( oSettings );\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} );\n\t\t\t}\n\t\t\t\n\t\t\toSettings.nScrollHead = nScrollHead;\n\t\t\toSettings.nScrollFoot = nScrollFoot;\n\t\t\t\n\t\t\treturn nScroller;\n\t\t}", "title": "" }, { "docid": "62a653b7a268e33731f3475880950f7c", "score": "0.5282976", "text": "function generateTableHead(tablename) {\r\n let table = document.getElementById(tablename);\r\n let row = table.insertRow();\r\n row.insertCell(0).innerHTML = \"Courses\";\r\n for (let i = 0; i < courses.length; i++) {\r\n let cell = row.insertCell(i + 1);\r\n cell.colSpan = 2;\r\n cell.innerHTML = courses[i];\r\n }\r\n}", "title": "" }, { "docid": "3638f0a92bbbd389abd4367a8768085b", "score": "0.52779526", "text": "function sondraHuxtable() {\n document.getElementById(\"theoHuxtable\").style.width = \"100%\";\n}", "title": "" } ]
60769ca675c27a700c5f02ba82a99632
Courses Condition COSS Controller of Site Safety POST MENTORNING ASSESSMENT (Within 4 months)
[ { "docid": "12b75aedd8298a593cabe2487037f624", "score": "0.0", "text": "function DisableDrug8(){\n\t\tif ($('#DD8').is(\":checked\") || $('#ND8').is(\":checked\") || $('#DM8').is(\":checked\") || $('#NM8').is(\":checked\")){\n\t\t\tvar element = document.getElementById(\"disbl8\");\n\t\t\telement.classList.add(\"disabled\");\n\t\t\tdocument.getElementById(\"cmsg8\").style.display = \"block\";\n\t\t\tdocument.getElementById(\"lmsent8\").style.display = \"none\";\n\t\t} else {\t\t\n\t\t\tdocument.getElementById(\"cmsg8\").style.display = \"none\";\n\t\t\tdocument.getElementById(\"lmsent8\").style.display = \"none\";\n\t\t\tvar element = document.getElementById(\"disbl8\");\n\t\t\telement.classList.remove(\"disabled\")\n\t\t}\n\t}", "title": "" } ]
[ { "docid": "fef7e0f4ff902a638abb565e39ca983b", "score": "0.55769175", "text": "function TermsAndConditions(){\n\t\t\tdays=60;\n\t\t\tmyDate = new Date();\n\t\t\tmyDate.setTime(myDate.getTime()+(days*24*60*60*1000));\n\t\t\tdocument.cookie = 'TermsAndConditions=Accepted; expires=' + myDate.toGMTString();\n\t\t}", "title": "" }, { "docid": "88b88f610ef9bd7023cd00923534e4e2", "score": "0.545007", "text": "function mainProcess() {\n\tlogDebug(\"This process inactivates Prequal license records that have been sitting in Additional Info Required, Pending, or Open status for longer than 6 months.\" + br);\n\t\n\tdtToday = new Date();\t\n\tdtSixMonthDate = new Date(dateAdd(dtToday, -183));\n\tstrSixMonthDate = jsDateToMMDDYYYY(dtSixMonthDate);\t\t\n\tlogDebug(\"6 Months Past Date: \" + strSixMonthDate);\n\t\n\tvar lpResult = aa.cap.getByAppType(\"Licenses\", \"Engineering\", \"Prequalified Contractor\", \"Na\");\n\t\n\tif (lpResult.getSuccess()) {\n\t\tlps = lpResult.getOutput();\n\t\tlogDebug(\"Number of Prequal records found: \" + lps.length + br);\n\t} else {\n\t\tlogDebug(\"ERROR: Retrieving permits: \" + lpResult.getErrorType() + \":\" + lpResult.getErrorMessage());\n\t\treturn false;\n\t}\n\t\t\n\tlogDebug(\"List of Prequal records set to Inactive: \" + br);\n\t\n\tfor (lp in lps) {\t\n\n\t\tif (elapsed() > maxSeconds){ // only continue if time hasn't expired\t\t\t\n\t\t\tlogDebug(\"A script timeout has caused partial completion of this process. Please re-run. \" + elapsed() + \" seconds elapsed, \" + maxSeconds + \" allowed.\") ;\n\t\t\ttimeExpired = true ;\n\t\t\tbreak;\n\t\t}\n\t\t\t\n\t\tb1App = lps[lp];\t\t\n\t\tvar b1CapId = b1App.getCapID();\t\t\n\t\tcapId = aa.cap.getCapID(b1CapId.getID1(), b1CapId.getID2(), b1CapId.getID3()).getOutput();\n\t\taltId = capId.getCustomID();\n\t\tcap = aa.cap.getCap(capId).getOutput();\n\t\tcapMod = cap.getCapModel();\t\t\n\t\t\n\t\tif (cap) {\n\t\t\tappStatus = cap.getCapStatus();\n\t\t\tappStatusDate = capMod.capStatusDate;\t\t\t\n\t\t\t\n\t\t\tif (appStatus == \"Additional Info Required\" || appStatus == \"Pending\" || appStatus == \"Open\" ) {\n\t\t\t\t//if (altId == \"LPC2010000-00445\") {\t\t\t\t\t\n\t\t\t\t\tstrRecStatusDate = (appStatusDate.getMonth() + 1) + \"/\" + appStatusDate.getDate() + \"/\" + (appStatusDate.getYear() + 1900);\t\t\t\t\t\n\t\t\t\t\tdtAppStatusDate = new Date(strRecStatusDate);\t\t\t\t\t\n\n\t\t\t\t\tif (dtAppStatusDate < dtSixMonthDate){\n\t\t\t\t\t\tgetContactInfo();\n\t\t\t\t\t\tlogDebug(\"Contractor Business Name: \" + contactBizName)\n\t\t\t\t\t\tlogDebug(\"Prequal License: \" + altId);\n\t\t\t\t\t\tlogDebug(\"Record Status & Status Date: \" + appStatus + \", \" + strRecStatusDate);\t\t\t\t\t\t\n\t\t\t\t\t\t//logDebug(\"Record Status Date is older than 6 months, so inactivate record\");\n\t\t\t\t\t\tupdateAppStatus(statusInactive, \"Updated by batch script\");\n \tlicEditExpInfo(statusInactive, null);\n\t\t\t\t\t\tlogDebug(\"Updated Record & Renewal Expiration status to \" + statusInactive + \".\");\n\t\t\t\t\t\trecsInactivatedCnt++;\t\t\t\t\t\t\n\t\t\t\t\t\tlogDebug(\"\");\n\t\t\t\t\t}\t\t\t\t\t\n\t\t\t\t//} //End specific rec test.\n\t\t\t}\n\t\t}\n\t}\n\tlogDebug(\"Total Prequal records set to Inactive: \" + recsInactivatedCnt);\n}", "title": "" }, { "docid": "b82dc657cb5098c38bb56d8b98f5c17a", "score": "0.5359874", "text": "function checkActivityStatusForCPR()\n\t\t{\n\t\t\tvar collectionProtocolRegistrationVal = parseInt(document.forms[0].collectionProtocolRegistrationValueCounter.value);\n\t\t\tvar isAllActive = true;\n\t\t\tfor(i = 1 ; i <= collectionProtocolRegistrationVal ; i++)\n\t\t\t{\n\t\t\t\tvar name = \"collectionProtocolRegistrationValue(ClinicalStudyRegistration:\" + i +\"_activityStatus)\";\n\t\t\t\tif((document.getElementById(name) != undefined) && document.getElementById(name).value==\"Disabled\")\n\t\t\t\t{\n\t\t\t\t\tisAllActive = false;\n\t\t\t\t\tvar go = confirm(\"Disabling any data will disable ALL its associated data also. Once disabled you will not be able to recover any of the data back from the system. Please refer to the user manual for more details. \\n Do you really want to disable?\");\n\t\t\t\t\tif (go==true)\n\t\t\t\t\t{\n\t\t\t\t\t\tdocument.forms[0].submit();\n\t\t\t\t\t}\n\t\t\t\t\telse\n\t\t\t\t\t{\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tif (isAllActive==true)\n\t\t\t{\n\t\t\t\tdocument.forms[0].submit();\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "4abaa7f5070dd84e5bddb4148e1e4ed7", "score": "0.5357149", "text": "validateDegreeReqs() {\n let program = this.props.program\n let terms = program.terms\n for (let term of terms) {\n let courses = this.props.courses\n for (let course of program[term].courses) {\n if (course == \"MSCI 261\" || courses[course].replaces == \"MSCI 261\") {\n return true\n }\n }\n }\n\n return false\n }", "title": "" }, { "docid": "8c831bd061547352d1849d4a415b8d13", "score": "0.5284249", "text": "function C37512_Pay_CC_required_fields_Expiration()\n{\ntry {\n Log.AppendFolder(\"C37512_Pay_CC_required_fields_Expiration\");\n InitializationEnviornment.initiliaze();\n AppLoginLogout.login();\n var keyWordNm =\"Daily Admission\";\n var packageNm = \"Date/Time\";\n var subPakNm=\"Children (Ages 3-12)\";\n var qty = 2; \n var dateD = CommonCalender.getTodaysDate();\n selectQuantity(qty);\n var givenPaymentType = \"Credit Card\";\n \n WrapperFunction.selectKeywordName(keyWordNm);\n selectPackage(packageNm,subPakNm);\n aqUtils.Delay(3000); \n if(datetimeformSubWindow.Exists){\n selectDateFromSubWindow(dateD); \n selectNextButtonFromSubWindow();\n }\n finilizeOrder();\n aqUtils.Delay(2000);\n \n var settlementTotal =orderDetailsTotal.Caption;\n applyAmount= aqString.Replace(settlementTotal,\"$\",\"\"); \n OrderInfo.prototype.OrderTotalAmount = applyAmount.trim();\n ConvertReservationsToPurchase.selectPaymentType(givenPaymentType);\n Button.clickOnButton(CC_EnterNumber);\n SelectPaymentType.enterCCNumber(\"4444333322221111\");\n CC_ExpirationMonth.ClickItem(\"01 - January\");\n var yearDisplay = CC_ExpirationYear.Label(\"labelDisplay\").Caption;\n var currYear = aqDateTime.GetYear(aqDateTime.Today());\n if(VerifyCheckProperty.compareStringObj(yearDisplay,currYear))\n {\n Log.Message(\"Default current year displayed\"); \n }else{\n merlinLogError(\"Default current year is not displayed\");\n return;\n }\n \n CC_StreetAddress.Keys(\"Pune\");\n CC_ZipCode.Keys(\"1234\"); \n aqUtils.Delay(2000);\n Button.clickOnButton(applyBalance);\n \n if(!ccMonthlErrorindicator.Exists){\n merlinLogError(\"Month error indicator is not displayed.\");\n return;\n } \n CC_ExpirationMonth.ClickItem(\"05 - May\");\n CC_ExpirationYear.Keys(\"[Down][Down][Down]\");\n aqUtils.Delay(2000);\n Button.clickOnButton(applyBalance); \n aqUtils.Delay(2000); \n// var cardLastDigit = paymentListFirstItem.PaymentListItem(\"payItem\").Label(\"descLabel\").Caption;\n// if( !VerifyCheckProperty.compareStringObj(cardLastDigit,\"Visa 1111\")){\n// merlinLogError(\"Credit Card last digit is not displayed in applied amount.\");\n// return;\n// }\n var correctcardLastDigit = false;\n var cnt = paymentListFirstItem.PaymentListItem(\"payItem\").HGroup(0).ChildCount;\n for( j = 0; j<cnt;j++){\n lbl= paymentListFirstItem.PaymentListItem(\"payItem\").HGroup(0).Child(j).Caption;\n if(lbl.startsWith(\"Visa 1111\")){\n correctcardLastDigit = true; \n }\n } \n if(correctcardLastDigit){\n Log.Message(\"Credit Card last digit is correctly displayed in applied amount.\");\n return; \n }else{\n merlinLogError(\"Credit Card last digit is not displayed in applied amount.\");\n return; \n }\n Log.Message(\"Complete the order\");\n WrapperFunction.settlementCompleteOrder();\n aqUtils.Delay(3000);\n validateTicket(\"Don't Validate\");\n Log.Message(\"Don't Validate the order\"); \n verifyTotalOnConfirmationPage(settlementTotal);\n var orderId = cnf_orderID1.Caption;\n if (orderId == null){\n merlinLogError(\"Order id is not present\");\n return;\n } \n var OrderID= (orderId.split('#')[1]).trim();\n OrderInfo.prototype.OrderID = OrderID;\n Log.Message(\"Order id is set:\"+OrderID); \n \n } catch (e) {\n\t merlinLogError(\"Oops! There's some glitch in the script: \" + e.message);\n\t return;\n }\n finally { \n AppLoginLogout.logout(); \n\t Log.PopLogFolder();\n } \n}", "title": "" }, { "docid": "e5b4fb86045c9d2af53fa8766478ae79", "score": "0.5257879", "text": "function updatestdQualificationbycourse(executionContext) {\n try {\n var formContext = executionContext.getFormContext();\n var qualificationLable = formContext.getAttribute(\"new_studentqualification\").getText()\n if (qualificationLable == \"MCA\") {\n var coursevalue = formContext.getAttribute(\"new_studentcourse\").setValue(1);\n formContext.getControl(\"new_email\").setDisabled(false);\n formContext.getControl(\"new_stdmarks\").setDisabled(true);\n formContext.getAttribute(\"new_stdmarks\").setValue(null);\n }\n if (qualificationLable == \"Btech\") {\n var coursevalue = formContext.getAttribute(\"new_studentcourse\").setValue(2);\n formContext.getControl(\"new_stdmarks\").setDisabled(false);\n formContext.getControl(\"new_email\").setDisabled(true);\n formContext.getAttribute(\"new_email\").setValue(null);\n }\n }\n catch (e) {\n Xrm.Utility.alertDialog(e.message);\n }\n}", "title": "" }, { "docid": "2d2c4530efb4f45edb25a1b89b961948", "score": "0.52220094", "text": "function checkCourseValidate(){\n\tvar subject_id, title, number, start_date, checkvalid;\n\tsubject_id = $(\"#Course_subject_id\").val();\n\t//title = $(\"#Course_title\").val();\n\twnumber = $(\"#numberSessionPerWeek\").val();\n\ttotalSession = $(\"#numberOfSession\").val();\n\tstart_date = $(\"#startDate\").val();\n\tcheckvalid = true;\n\tif(wnumber==\"\" || start_date==\"\" || totalSession<0 || totalSession>200){\n\t\tcheckvalid = false;\n\t}else{\n\t\tif(!(start_date>=currentDate && start_date<=\"2100-01-01\")){\n\t\t\tcheckvalid = false;\n\t\t}\n\t}\n\treturn checkvalid;\n}", "title": "" }, { "docid": "ca64b8a9573c63628fe3d2ba4319e29c", "score": "0.51441574", "text": "accountDetails(request, response) {\n const loggedInUser = accounts.getCurrentUser(request);\n let assessments = assessmentStore.getUserAssessments(loggedInUser.id);\n let singularCondition = false;\n\n if (assessments.length == 1) {\n singularCondition = true;\n }\n\n const viewData = {\n user: loggedInUser,\n assessments: assessments.length,\n singularCondition: singularCondition,\n };\n\n response.render(\"accountDetails\", viewData);\n }", "title": "" }, { "docid": "b4962da2f5ef64721c6af3157af3d66a", "score": "0.50530356", "text": "calcCommission(){\n\t\t\tif(this.picked == \"Quarterly\"){\n\t\t\t\t this.totalContractValue = this.addedPrice * 4;\n\t\t\t }\n\t\t\telse{\n\t\t\t\tthis.totalContractValue = this.addedPrice * 6;\n\t\t\t }\n\t\t\tthis.commission = this.totalContractValue * .5;\n\t\t}", "title": "" }, { "docid": "a33159f2bd15aaafae90f6fa998cd31f", "score": "0.5038631", "text": "privado(){\r\n if(this.persona.datosDecision.totalSemanasCotizadas >= 1250){\r\n this.todaLaVida();\r\n this.diezYears();\r\n let valorpensiontv = this.persona.datosLiquidacion.pIBLtv * 0.9;\r\n let valorpension10 = this.persona.datosLiquidacion.pIBL10A * 0.9;\r\n if(valorpensiontv >= valorpension10){\r\n this.datosLiquidacion.valorPensionDecreto = valorpensiontv;\r\n this.persona.regimen = \"Decreto 758 de 1990 - IBL Toda la Vida\";\r\n }else{\r\n this.datosLiquidacion.valorPensionDecreto = valorpension10;\r\n this.persona.regimen = \"Decreto 758 de 1990 - IBL 10 años >= 1250 semanas\";\r\n }\r\n }else{\r\n this.diezYears();\r\n this.montoPension10();\r\n this.persona.regimen = \"Decreto 758 de 1990 - IBL 10 años\";\r\n }\r\n this.ley797();\r\n if(!this.regimentr){\r\n this.persona.regimen = \"Ley 797 de 2003\";\r\n }\r\n }", "title": "" }, { "docid": "cbcac1387efcd40e3b5f6b47df2e529f", "score": "0.5030097", "text": "function checkVisaExpiry(){\r\n\r\n}", "title": "" }, { "docid": "c001f78abc5e2504a8d02c092e22c200", "score": "0.5013347", "text": "function submitForm () {\n var inputSemester = $('#inputSemester').val(),\n inputDepartment = $('#inputDepartment').val().toLowerCase(),\n inputCourseNumber = $('#inputCourseNumber').val(),\n inputKeywords = $('#inputKeywords').val().toLowerCase(),\n inputTitle = $('#inputTitle').val().toLowerCase(),\n inputInstructors = $('#inputInstructors').val().toLowerCase()\n openSeats = ($('#openSeats').is(':checked')) ? true:false,\n openWaitlist = ($('#openWaitlist').is(':checked')) ? true:false,\n exclude = ($('#exclude').is(':checked')) ? true:false,\n unitsMin = $('#unitsMin').val(),\n unitsMax = $('#unitsMax').val(),\n lowerDiv = ($('#lowerDiv').is(':checked')) ? true:false,\n upperDiv = ($('#upperDiv').is(':checked')) ? true:false,\n graduate = ($('#graduate').is(':checked')) ? true:false,\n professional = ($('#professional').is(':checked')) ? true:false,\n berkeleyConnect = ($('#berkeleyConnect').is(':checked')) ? true:false,\n courseThread = ($('#courseThread').is(':checked')) ? true:false,\n freshSophSem = ($('#freshSophSem').is(':checked')) ? true:false,\n r_AC = ($('#r-AC').is(':checked')) ? true:false,\n r_AH = ($('#r-AH').is(':checked')) ? true:false,\n r_AI = ($('#r-AI').is(':checked')) ? true:false,\n r_RCA = ($('#r-RCA').is(':checked')) ? true:false,\n r_RCB = ($('#r-RCB').is(':checked')) ? true:false,\n r_AL = ($('#r-AL').is(':checked')) ? true:false,\n r_BS = ($('#r-BS').is(':checked')) ? true:false,\n r_HS = ($('#r-HS').is(':checked')) ? true:false,\n r_IS = ($('#r-IS').is(':checked')) ? true:false,\n r_PV = ($('#r-PV').is(':checked')) ? true:false,\n r_PS = ($('#r-PS').is(':checked')) ? true:false,\n r_SBS = ($('#r-SBS').is(':checked')) ? true:false,\n reqMajor = $('#reqMajor').val().toLowerCase(),\n reqMinor = $('#reqMinor').val().toLowerCase(),\n times = $('.selected'),\n selectedCells = [],\n filename = '';\n\n // for each selected time\n times.each(function () {\n var time, day;\n\n // if the selected item is a time/day cell, get the time and day attributes and add them to the array\n if ($(this).hasClass('selectable')) {\n time = $(this).attr('data-time');\n day = $(this).attr('data-day');\n selectedCells.push({'time': time, 'day': day});\n }\n });\n\n\n // pre-determined search functions\n\n // Search #1: Public Health - Utilitarian\n // Major = Public Health, Semester = Fall 2014\n if (((reqMajor.indexOf('public health') >= 0) || (reqMajor.indexOf('pb hlth') >= 0)) && inputSemester === '2014fall') {\n window.location.href = 's1_pub_health.html';\n }\n\n // Search #2: Breadth Requirements - Planner\n // All L&S requirement boxes are checked. RCA and RCB boxes are checked. Semester field is All.\n else if (r_RCA && r_RCB && r_AL && r_BS && r_HS && r_IS && r_PV && r_PS && r_SBS && (inputSemester === 'all')) {\n window.location.href = 's2_breadth.html';\n }\n\n // Search #3: Sustainability - Focused Explorer\n // Keyword has \"sustainability\". Semester field is All.\n else if ((inputKeywords.indexOf('sustainability') >= 0) && (inputSemester === 'all')) {\n window.location.href = 's3_sustain.html';\n }\n\n // Search #4: Time-based - Utilitarian\n // Calendar is set to MW 9-12:30, and all of Th. Semester is Fall 2014.\n else if ((selectedCells.length > 0) && (inputSemester === '2014fall')) {\n var m = false,\n w = false,\n tu = false,\n th = false;\n // this is pretty relaxed; as long as any m and w have a morning cell selected, and any tu/th cells, it will pass.\n for (var i = 0; i < selectedCells.length; i++) {\n var day = selectedCells[i].day,\n time = selectedCells[i].time;\n if (day === 'mon') {\n if ((time === 'time-1') || (time === 'time-2') || (time === 'time-3')) {\n m = true;\n }\n }\n else if (day === 'wed') {\n if ((time === 'time-1') || (time === 'time-2') || (time === 'time-3')) {\n w = true;\n }\n }\n else if (day === 'tue') {\n tu = true;\n }\n else if (day === 'thu') {\n th = true;\n }\n }\n\n if (m && w && tu && th && (inputSemester === '2014fall')) {\n window.location.href = 's4_schedule.html';\n }\n }\n\n // Search #5: Backup search - Seeker\n // Open seats is checked. Semester is Fall 2014.\n else if (openSeats && (inputSemester === '2014fall')) {\n window.location.href = 's5_open.html';\n }\n\n // catchall\n else {\n // IT DOES NOTHING\n }\n}", "title": "" }, { "docid": "e9d4bcbece43a48d8b08ca2dc37f2a24", "score": "0.49847355", "text": "function valideLicence(req, res, next) {\n\tconsole.log(req.user.licence);\n\t// if user is authenticated in the session, carry on\t\n\tif (req.user.licence>=new Date())\n\t\tconsole.log('true');\n\t\treturn next();\n\n\t// if they aren't redirect them to the home page\n\tres.redirect('/');\n}", "title": "" }, { "docid": "d1b1f73af022604a4c65d7dea9b99dd4", "score": "0.49615988", "text": "function passesCritical(){\n return (billsTotal()>= criticalLevelSet);\n}", "title": "" }, { "docid": "2e5680235a732841c0e975133c357ccf", "score": "0.49437886", "text": "function acceptProposalOfSubmittedPolicy()\n{\n var edited_Name= document.getElementById(\"customerName1\").innerHTML;\n\n var edited_Dob= document.getElementById(\"c_dob\").innerHTML;\n\n var edited_Age= document.getElementById(\"c_age\").innerHTML;\n var edited_occupation= document.getElementById(\"c_Occupation\").innerHTML;\n var edited_martialStatus= document.getElementById(\"martialStatus\").innerHTML;\n var edited_policyType= document.getElementById(\"policyType\").innerHTML;\n var edited_term= document.getElementById(\"term\").innerHTML;\n var edited_sumAssured= document.getElementById(\"sumAssured\").innerHTML;\n var edited_DiseasesCovered= document.getElementById(\"DiseasesCovered\").innerHTML;\n var edited_gender= document.getElementById(\"gender\").innerHTML;\n\n\n var edited_Pharmacies= document.getElementById(\"c_Pharmacies_Allowed\").innerHTML;\n var edited_Hosptials= document.getElementById(\"c_Hospitals_Allowed\").innerHTML;\n var edited_ReEmberse= document.getElementById(\"c_Reemberse\").innerHTML;\n var edited_RoomRent= document.getElementById(\"c_RoomRent\").innerHTML;\n var edited_PharmacyLimit= document.getElementById(\"c_Pharmacy_Limit\").innerHTML;\n var edited_Riders_Deductable_Amount= document.getElementById(\"c_Deductable_Rider_Customer\").innerHTML;\n var edited_Base_Deductable_Amount= document.getElementById(\"c_Deductable_Base_Customer\").innerHTML;\n var edited_Coverage_Amount_for_Rider= document.getElementById(\"c_Coverage_Rider\").innerHTML;\n var edited_Rider_TimePeriod= document.getElementById(\"c_Rider_Term\").innerHTML;\n var edited_Medical_History= document.getElementById(\"c_Medical_History\").innerHTML;\n var edited_PolicyOwner= document.getElementById(\"POwner\").innerHTML;\n var edited_limitedPerDay= document.getElementById(\"c_limitperDay\").innerHTML;\n\n var agentNumber= \"A2017Sravan\";\n var PolicyNumber= document.getElementById(\"c_policyNumber\").innerHTML;\n var edited_emergency_amount= document.getElementById(\"c_limit_emergency\").innerHTML;\n var edited_limit_per_Year= document.getElementById(\"c_limit_per_year\").innerHTML;\n\n\n /*Entering the details into Database*/\n\n $.post('/Customer_Details_Approved_By_Insurance_Company',{AgentNumber: agentNumber,CustomerName: edited_Name,PolicyNumber: PolicyNumber,DateOfBirth: edited_Dob,\n Age: edited_Age,Gender:edited_gender,Occupation:edited_occupation,Martial_Status:edited_martialStatus,Policy_Type: edited_policyType,Term: edited_policyType,\n Sum_Assured: edited_sumAssured,Diseases_Covered: edited_DiseasesCovered,Medical_History: edited_Medical_History,Rider_Term: edited_Rider_TimePeriod,\n Rider_Coverage_Amount: edited_Coverage_Amount_for_Rider,Policy_Owner: edited_PolicyOwner,Deductable_Base: edited_Base_Deductable_Amount,\n Deductible_Rider: edited_Riders_Deductable_Amount,Limit_Per_Day: edited_limitedPerDay,Limit_For_Pharmacy: edited_PharmacyLimit,Limit_For_RoomRent: edited_RoomRent,\n ReEmburse: edited_ReEmberse,Pharmacies_Allowed: edited_Pharmacies,Hospitals_Allowed: edited_Hosptials,Year_Limit: edited_limit_per_Year,Emergency_Limit: edited_emergency_amount},function (data)\n {\n alert(\"data coming from policy Information\"+ JSON.stringify(data));\n });\n\n regulatorInstance.acceptProposalOfSubmittedPolicy.sendTransaction(0,{from: regulatorAccount, gas: defaultGas}).then(\n function (txHash) {\n $(\"#acceptProposalSuccess2\").html('<i class=\"fa fa-check\"</i>'+ ' Transaction'+ txHash + \" added to the blockchain\");\n $(\"#acceptProposalSuccess2\").show().delay(5000).fadeOut();\n }\n )\n\n // getCustomerInformation();\n\n}", "title": "" }, { "docid": "9a33553d48b997a2fece5c5f15831935", "score": "0.4942318", "text": "function FourDayDiscountIsAchieved(daysOnCamping) {\n if (daysOnCamping % 4 == 0) {\n return true;\n }\n return false;\n}", "title": "" }, { "docid": "d8216c120ed08fdc65f426c309e3b10b", "score": "0.49355334", "text": "function cookieRedirect() {\n var semester = getCookie(\"semester\");\n if(semester !== undefined) {\n if(semester <= 6 && semester >= 1) {\n window.location.href = '/' + semester + 'semester.php';\n }\n }\n}", "title": "" }, { "docid": "2ef754cacb023bb7fb0d777eb34df7ee", "score": "0.49074692", "text": "function validateExpritation() {\n const expirationDate = store.getters.getExpDate\n const now = new Date()\n if (now.getTime() > expirationDate.getTime()) {\n // Emit an alert to main Vue component\n // EventBus.$emit('token-expired')\n store.dispatch('logOut')\n }\n}", "title": "" }, { "docid": "8020065ab33bbf5ea345971d8afa3edd", "score": "0.4905591", "text": "function expiryCheck()\n{\n var date = document.getElementById('cust-expiry').value;\n var elements = date.split('-');\n var expiryMonth = elements[1];\n var expiryYear = elements[0];\n if (expiryMonth[0] == 0){\n expiryMonth = expiryMonth[1];\n }\n //Check if year is in future or if year is current and month is at least current month. As months are indexed at 0, we subtract 1\n if (expiryYear > new Date().getFullYear() || (expiryYear = new Date().getFullYear() && expiryMonth - 1 >= new Date().getMonth()))\n {\n document.getElementById('cust-expiry-error').innerHTML=\"\";\n document.getElementById('cust-expiry').style.backgroundColor='';\n return true;\n }else\n {\n document.getElementById('cust-expiry-error').innerHTML=\"<br>Credit card has expired or invalid expiry date. Please try another card.\";\n document.getElementById('cust-expiry').style.backgroundColor='hsla(360, 70%, 85%, 1)';\n return false;\n }\n}", "title": "" }, { "docid": "3f1829db8eb39c7ceca9c1b0f3262f00", "score": "0.48860767", "text": "function specialCasesRecalc(mission) {\n\t\n}", "title": "" }, { "docid": "083b48cbedad08d11ad276afd3cd537f", "score": "0.48834068", "text": "checkCurrentDateTargets() {\n let currentDate = new Date()\n let currentMonth = currentDate.getMonth()\n\n let checkTargets = this.checkTargetEnabled()\n\n // Check firebase to see if editing targets is enabled\n // Perhaps allow ability to change which months users can change data from admin panel...\n if (checkTargets || currentMonth <= 3) {\n this.enableTargets()\n } else {\n console.log(\"Current month is nothing the timeframe to enter targets\")\n console.log(\"Data cannot be submitted without admin persmissions\")\n }\n }", "title": "" }, { "docid": "eb7257823724a967e082c93d1d5c1db3", "score": "0.48798355", "text": "generateRequiredKCs() {\n this.courses.forEach((value)=>{\n // Generate all required KCs for every course.\n value.generateAllIngoingKCs(this);\n });\n }", "title": "" }, { "docid": "8da91a2f9eea79bedbed4f69b475d976", "score": "0.48674598", "text": "function canIGetADrivingLicense(age){\r\n if(age>=20){\r\n return \"yes you can\";\r\n }else{\r\n return `please come back after ${20-age} years to get one`;\r\n }\r\n}", "title": "" }, { "docid": "2429935d561ba65523f78a5e34847322", "score": "0.48533538", "text": "get courses() {\n // 6. key/value pairs \n return {\n appetizers: this._courses.appetizers,\n mains: this._courses.mains,\n desserts: this._courses.desserts\n }\n }", "title": "" }, { "docid": "78206573fff900cfe5971ebeaa1aa742", "score": "0.4846127", "text": "function giveCommission()\n{\n for(var j=0; j<rentals.length;j++)\n {\n var timeDay=get_date(rentals[j].id);\n var commission = rentals[j].price*0.70;\n\n console.log('Commission for '+ rentals[j].driver.firstName+ ''+ rentals[j].driver.lastName + 'course is ' + commission + '.');\n var insurance = commission/2;\n\n console.log('Insurance for '+ rentals[j].driver.firstName+ ''+ rentals[j].driver.lastName + 'course is ' + insurance + '.');\n rentals[j].commission.insurance=insurance;\n\n var assistanceRoad=timeDay*1;\n console.log('Road assistance for '+ rentals[j].driver.firstName+ ''+ rentals[j].driver.lastName + 'course is ' + assistanceRoad + '.');\n\n rentals[j].commission.assistance=assistanceRoad;\n\n var drivy = commission - insurance - assistanceRoad;\n console.log('Drivy for '+ rentals[j].driver.firstName+ ''+ rentals[j].driver.lastName + 'course is ' + drivy + '.');\n\n rentals[j].commission.drivy=drivy;\n }\n}", "title": "" }, { "docid": "4fb4363831a3bba08415df1de89d9b65", "score": "0.48453537", "text": "function TceCondition() {\n\tthis.time = null;\n\tthis.pass = null;\n\tthis.amount = null;\n\tthis.currency = null;\n\tthis.methodsOfPayment = null;\n\tthis.daylightHours = null;\n\tthis.discountAvailable = null;\n\tthis.tollSystemsIds = null;\n}", "title": "" }, { "docid": "24fdd850c7b1da767bc40be883ce57c2", "score": "0.484291", "text": "get courses() {\n return {\n appetizers: this.appetizers,\n mains: this.mains,\n desserts: this.desserts,\n }\n }", "title": "" }, { "docid": "146fd4c2c971f6422a75642a3307782a", "score": "0.48394194", "text": "analyzeMerchantLoyalty(safetyTally){\n\n if(this.props.route.params.product.firstTranDateRange >= 365){\n safetyTally += 2;\n } \n if(this.props.route.params.product.firstTranDateRange >= 1095){\n safetyTally += 2;\n } \n\n return safetyTally;\n }", "title": "" }, { "docid": "e5c16bd3390eddc17f6e4044b888f876", "score": "0.4829063", "text": "function registerSubmit() {\n let regTime = $('#reg-time').val();\n let regDate = $('#reg-date').val();\n let rin = $('#rin').val();\n let password = $('#password').val();\n\n // check for unusual registration dates\n let reg = parse(regDate + 'T' + regTime);\n // if registration is before 8 AM or after 8 PM and not now (same hour),\n // or on a weekend and not today\n if (((getHours(reg) > 20 || getHours(reg) < 8) && !isThisHour(reg)) ||\n (!isToday(reg) && isWeekend(reg))) {\n if (!confirm('Registration date/time is unusual, continue?')) {\n return;\n }\n }\n\n // fill array with nonempty CRNs from input fields\n let valid = [];\n for (let i = 0; i < 6; i++) {\n let idStr = '#crn' + (i + 1);\n if ($(idStr).val().length != 0) {\n valid.push($(idStr).val());\n }\n }\n\n $('#set-reg-time').html(regTime);\n $('#set-reg-date').html(regDate);\n\n if (valid.length > 0) {\n let queryStr = 'https://yacs.cs.rpi.edu/api/v5/sections.json?show_periods&crn=';\n for (let i = 0; i < valid.length; i++) {\n queryStr += valid[i];\n if (i != valid.length - 1) {\n queryStr += ',';\n }\n }\n\n // use jQuery to get json from YACS api\n $.getJSON(queryStr, function(data) {\n let courses = [];\n // create Courses from returned json\n for (let i = 0; i < data.sections.length; i++) {\n let courseJSON = data.sections[i];\n let course = new Course(courseJSON.crn, courseJSON);\n courses.push(course);\n }\n let schedule = new Schedule(courses);\n\n if (schedule.hasConflicts()) {\n window.alert('Conflicts in schedule, ' +\n 'will not be able to register.');\n return;\n }\n\n // for each course in the created schedule,\n // set corresponding element to course string\n let anycourses = false;\n for (let i = 0; i < schedule.courses.length; i++) {\n $('#set-crn' + (i + 1)).html(\n '<li>' + schedule.courses[i].toHTML() + '</li>'\n );\n anycourses = true;\n }\n\n let sis = new SISUser(rin, password);\n\n sis.name((name) => {\n // display name of user\n $('#set-realname').html(name);\n $('#crn-input').hide();\n $('#reg-details').fadeIn('slow');\n if (anycourses) {\n $('#reg-details-courses').show();\n }\n let end = parse(regDate + 'T' + regTime);\n // create timer to register when time is reached\n let timer = setInterval(() => {\n let now = Date();\n // if now is after registration time, register\n if (isAfter(now, end)) {\n $('#countdown').hide();\n clearInterval(timer);\n sis.register($('#reg-term').val(), valid, (crns) => {\n $('#status').fadeIn('slow');\n if (crns.length != 0) {\n let status = 'Successfully registered for: '\n + crns.reduce((x, y) => x + ', ' + y);\n $('#status').html(status);\n } else {\n $('#status').html(\n 'Failed to register for all courses'\n );\n }\n });\n // otherwise, update countdown\n } else {\n $('#countdown').html(distanceInWordsStrict(now, end));\n }\n }, 1000);\n });\n });\n } else {\n window.alert('No CRNs chosen.');\n }\n}", "title": "" }, { "docid": "c569c03f0d2193f416d633bda30b21f5", "score": "0.48251858", "text": "function checkyearofcensus() {\r\n \r\n loadDate();\r\n\r\n}", "title": "" }, { "docid": "f3b03821beaf4ba661e093cef264952f", "score": "0.4820848", "text": "function renew_amc_submit_check()\n{\n reset_fields();\n var checking_status = true;\n renew_date_check($(\"customer_contract_date\")) ? \"\" : checking_status = false;\n check_name(\"customer_name\") ? \"\" : checking_status = false;\n check_address() ? \"\" : checking_status = false;\n (!contact_numbers(\"customer_mobile_number\") || !contact_numbers(\"customer_phone_number\")) ? checking_status = false : \"\";\n check_paid_amount(\"customer_contract_amount\") ? \"\" : checking_status = false;\n check_name(\"customer_model_name\") ? \"\" : checking_status = false;\n checking_status ? \"\" : error_message();\n return checking_status;\n}", "title": "" }, { "docid": "cf0a68944d679dfe53a7ea91a6d09f91", "score": "0.4818712", "text": "function canIGetADrivingLicense(age1) {\r\n if (age1 >= 20) {\r\n return console.log(\"yes you can\");\r\n } else {\r\n let xx = 20 - age1;\r\n return console.log(`please come back after ${xx} years to get one`);\r\n }\r\n}", "title": "" }, { "docid": "1df084d26e323541db2e6e5b6d95ce2b", "score": "0.48186123", "text": "get courses() {\n return {\n appetizers: this.appetizers,\n mains: this.mains,\n desserts: this.desserts\n }\n }", "title": "" }, { "docid": "223827209861c07afe3ead9bc9259129", "score": "0.4815539", "text": "function prerequisitiesValidator (Prerequisities, Enrollment){\n // arg Prerequisities should be in this format:\n // Prerequisities = {\"code\":{\"1\": [\"COMP9021\", \"COMP9024\"],\"2\": [\"COMP9020\", \"COMP9024\"]},\"UOC\": 0}\n let canBeEnrolled = false;\n //console.log(Prerequisities.code, Enrollment);\n if (Prerequisities.code[1].length === 0 && Prerequisities.code[2].length === 0){\n //console.log('1');\n canBeEnrolled = true;\n }else if(Prerequisities.code[1].length >= 1 && Prerequisities.code[2].length === 0){\n //console.log('2');\n for(let course of Prerequisities.code[1]){\n if(Enrollment.includes(course)){\n canBeEnrolled = true;\n break;\n }\n }\n }else if(Prerequisities.code[1].length === 0 && Prerequisities.code[2] >= 1){\n //console.log('3');\n for(let course of Prerequisities.code[2]){\n if(Enrollment.includes(course)){\n canBeEnrolled = true;\n break;\n }\n }\n }else if(Prerequisities.code[1].length >= 1 && Prerequisities.code[2].length >=1 ){\n //console.log('4');\n let validatorCodeList1 = false;\n let validatorCodeList2 = false;\n for(let course of Prerequisities.code[1]){\n if(Enrollment.includes(course)){\n canBeEnrolled = true;\n break;\n }\n }\n for(let course of Prerequisities.code[2]){\n if(Enrollment.includes(course)){\n canBeEnrolled = true;\n break;\n }\n }\n if(validatorCodeList1 === true && validatorCodeList2 === true){\n canBeEnrolled = true;\n }\n }\n return canBeEnrolled;\n}", "title": "" }, { "docid": "26057653446fa46eb1959d271b6366fe", "score": "0.4813283", "text": "function init() {\n // [ validateMonth function returns true or false based on the month number passed as a parameter]\n function validateMonth(month)\n {\n var valid = true;\n if(isNaN(month))\n {\n valid = false;\n }\n else\n {\n var num = parseInt(month);\n if (num <1 || num >12)\n {\n valid = false;\n }\n }\n return valid;\n }\n // [ validateMonth function returns true or false based on the Year value passed as a parameter]\n function validateYear(yr)\n {\n var valid = true;\n if(isNaN(yr))\n {\n valid=false;\n }\n else\n {\n var num = parseInt(yr);\n var d = new Date();\n if((num > (d.getFullYear()+5)) || (num < d.getFullYear()))\n {\n valid = false;\n }\n\n }\n return valid;\n\n }\n\n // [ validateExpiry function displays the result in paragraph <p> after verifying the validity of credit card]\n function validateExpiry()\n {\n var month = document.getElementById(\"monthNo\").value;\n var year = document.getElementById(\"year\").value;\n var output=\"\";\n var validMonth= validateMonth(month);\n var validYear= validateYear(year);\n if(validMonth && validYear)\n {\n output=\"Expiry Date is Valid\";\n }\n else\n {\n output=\"Expiry Date is invalid\";\n }\n console.log(output);\n document.getElementById(\"msg\").innerText= output;\n }\n\n var btnCheck= document.getElementById(\"check\");\n btnCheck.onclick=function() {validateExpiry()};\n\n\n}", "title": "" }, { "docid": "84779b147e80d7d8145908df61d2b4ca", "score": "0.47964597", "text": "async function determineCourses(programmeId){\n \n let Y1S1 = {}; // List of all courses for Year 1 Semester 1\n let Y1S2 = {}; // List of all courses for Year 1 Semester 2\n let Y2S1 = {}; // List of all courses for Year 2 Semester 1\n let Y2S2 = {}; // List of all courses for Year 2 Semester 2\n let Y3S1 = {}; // List of all courses for Year 3 Semester 1\n let Y3S2 = {}; // List of all courses for Year 3 Semester 2\n var programmeCourses = {}; // Dictionary to store all programme courses\n var semesterArr = []; // Array to store courses by semester\n var coreSemesterArr = []; // Array to store core courses by semester\n var today = new Date(); // Today's date\n var currentSem; // Value to store current semester\n\n var courses = await getProgrammeCourses(programmeId);\n\n \n for (var i=0; i<courses.length; i++) { // Initialise Courses for Degree using thier Level and Semester\n if (courses[i].level === \"I\") {\n if (courses[i].semester === \"1\") {\n Y1S1[courses[i].courseCode] = \"N\";\n }\n if (courses[i].semester === \"2\") {\n Y1S2[courses[i].courseCode] = \"N\";\n }\n }\n if (courses[i].level === \"II\") {\n if (courses[i].semester === \"1\") {\n Y2S1[courses[i].courseCode] = \"N\";\n }\n if (courses[i].semester === \"2\") {\n Y2S2[courses[i].courseCode] = \"N\";\n }\n }\n if (courses[i].level === \"III\") {\n if (courses[i].semester === \"1\") {\n Y3S1[courses[i].courseCode] = \"N\";\n }\n if (courses[i].semester === \"2\") {\n Y3S2[courses[i].courseCode] = \"N\";\n }\n }\n }\n\n programmeCourses = determineStudentCourses(courses); // Determine what courses a student failed, passed, didnt do or is in progress\n semesterArr = splitBySem(programmeCourses, courses); // Split courses by semester\n var coreCourses = getCoreCourses(courses); // Get core courses\n coreSemesterArr = splitBySem(programmeCourses, coreCourses); // Split core courses by semester\n\n var recCourses = [];\n var counter = 0;\n var year = 1;\n var sem = 1;\n var key;\n\n\n Y1S1 = semesterArr[0];\n Y1S2 = semesterArr[1];\n Y2S1 = semesterArr[2];\n Y2S2 = semesterArr[3];\n Y3S1 = semesterArr[4];\n Y3S2 = semesterArr[5];\n\n counter = 0;\n // If a student passed, failed or the course is in progress, assume that the student is in the next semester\n for (key in Y1S1) {\n if (Y1S1[key].grade === \"P\" || Y1S1[key].grade === \"F\" || Y1S1[key].grade === \"IP\") {\n counter+=1;\n }\n }\n if (counter > 1) {\n sem = 2;\n }\n counter = 0;\n if (year === 1 && sem === 2) {\n for (key in Y1S2) {\n if (Y1S2[key].grade === \"P\" || Y1S2[key].grade === \"F\" || Y1S2[key].grade === \"IP\") {\n counter+=1;\n }\n }\n if (counter > 1) {\n sem = 1;\n year = 2;\n }\n }\n counter = 0;\n if (year === 2 && sem === 1) {\n for (key in Y2S1) {\n if (Y2S1[key].grade === \"P\" || Y2S1[key].grade === \"F\" || Y2S1[key].grade === \"IP\") {\n counter+=1;\n }\n }\n if (counter > 1) {\n sem = 2;\n }\n }\n counter = 0;\n if (year === 2 && sem === 2) {\n for (key in Y2S2) {\n if (Y2S2[key].grade === \"P\" || Y2S2[key].grade === \"F\" || Y3S1[key].grade === \"IP\") {\n counter+=1;\n }\n }\n if (counter > 1) {\n sem = 1;\n year = 3;\n }\n }\n counter = 0;\n if (year === 3 && sem === 1) {\n for (key in Y3S1) {\n if (Y3S1[key].grade === \"P\" || Y3S1[key].grade === \"F\" || Y3S2[key].grade === \"IP\") {\n counter+=1;\n }\n }\n if (counter > 1) {\n sem = 2;\n }\n }\n\n if (today.getMonth() < 4) { // If the date is currently between January and April\n currentSem = 2;\n }\n // else if (today.getMonth() < 6) { // If the date is currently between May and July\n // currentSem = 1;\n // }\n else { // If the date is currently between August and December\n currentSem = 1;\n }\n\n // Recommended courses based on current year and semester if the student has not done the course yet\n if (year === 1 && currentSem === 1) {\n for (key in Y1S1) {\n if (Y1S1[key].grade === \"N\") {\n recCourses.push(Y1S1[key].courseCode)\n }\n }\n }\n if (year === 1 && currentSem === 2) {\n for (key in Y1S2) {\n if (Y1S2[key].grade === \"N\") {\n recCourses.push(Y1S2[key].courseCode)\n }\n }\n }\n if (year === 2 && currentSem === 1) {\n for (key in Y2S1) {\n if (Y2S1[key].grade === \"N\") {\n recCourses.push(Y2S1[key].courseCode)\n }\n }\n }\n if (year === 2 && currentSem === 2) {\n for (key in Y2S2) {\n if (Y2S2[key].grade === \"N\") {\n recCourses.push(Y2S2[key].courseCode)\n }\n }\n }\n if (year === 3 && currentSem === 1) {\n for (key in Y3S1) {\n if (Y3S1[key].grade === \"N\") {\n recCourses.push(Y3S1[key].courseCode)\n }\n }\n }\n if (year === 3 && currentSem === 2) {\n for (key in Y3S2) {\n if (Y3S2[key].grade === \"N\") {\n recCourses.push(Y3S2[key].courseCode)\n }\n }\n }\n \n recCourses = recommendCoreCourses(coreSemesterArr, year, currentSem, recCourses);\n removeCoursesNoPrereq(recCourses, courses, programmeCourses);\n props.setRecommended(recCourses);\n props.setLevel(year);\n if (props.recCourses !== null) {\n props.setLoad(false);\n }\n setProcessed(true);\n }", "title": "" }, { "docid": "cc159708e0f61cf146feecb00c34ee6b", "score": "0.47899133", "text": "checkCurrentDateActuals() {\n let currentDate = new Date()\n let currentDay = currentDate.getDate()\n\n let checkActuals = this.checkActualEnabled()\n\n // Check firebase to see if editing actuals is enabled\n // Allow user to submit entry for actuals if \n if (checkActuals || (currentDay <= 14)) {\n this.enableActuals()\n // Display error messaging\n } else {\n console.log(\"Current date is within latter half of the month!\")\n console.log(\"Data cannot be submitted without admin permissions\")\n }\n }", "title": "" }, { "docid": "757082a21ece6b10726a91c99d6d5c11", "score": "0.47832945", "text": "_isRestricted(date) {\n const restrictedDates = this.restrictedDates;\n let isRestricted = false;\n\n for (let i = 0; i < restrictedDates.length; i++) {\n if (date.equalDateParts(restrictedDates[i])) {\n isRestricted = true;\n break;\n }\n }\n\n return isRestricted;\n }", "title": "" }, { "docid": "b6de686e7989771a7ee644944d4ef957", "score": "0.47729802", "text": "function getsDiscount() {\n if ((productsBought > 2) || (membership = premium)); }", "title": "" }, { "docid": "898c4a970319ef2d8c2c02c9352aedc0", "score": "0.47726166", "text": "function afterAccountSubmit(type)\n{\n if (type == 'edit') \n\t{\n try \n\t\t{\n var sysdate = new Date();\n var submitDate = nlapiDateToString(sysdate, 'mm/dd/yyyy');\n\t\t\tvar submissionDate = nlapiDateToString(sysdate,'datetime');\n\t\t\tvar acctype = nlapiGetFieldText('custrecord_account_type');\n\t\t\t// For determining submission time and approval time\n\t\t\tnlapiLogExecution('DEBUG', 'Date is', sysdate);\n var min = sysdate.getMinutes();\n if (min == 0) \n\t\t\t{\n nlapiLogExecution('DEBUG', 'IN', 'here'); \n var currenttime = sysdate.getHours() + \":\" + \"00\";\n nlapiLogExecution('DEBUG', 'IN', currenttime);\n \n }\n else \n if (min == 1 || min == 2 || min == 3 || min == 4 || min == 5 || min == 6 || min == 7 || min == 8 || min == 9) {\n nlapiLogExecution('DEBUG', 'IN', min);\n var currenttime = sysdate.getHours() + \":\" + \"0\" + sysdate.getMinutes();\n nlapiLogExecution('DEBUG', 'IN', currenttime);\n \n }\n else \n\t\t\t\t{\n var currenttime = sysdate.getHours() + \":\" + sysdate.getMinutes();\n }\n\t\t\t\t\n\t\t\t// If data edited using CSV imported \n\t\t\tif (nlapiGetContext().getExecutionContext() == 'csvimport') \n\t\t\t{\n\t\t\t\tnlapiSetFieldValue('custrecord_account_type', acctype);\n\t\t\t\tnlapiSetFieldValue('custrecord_approval_status_coa', '1');\n\t\t\t\tnlapiSetFieldValue('custrecord_submissiondateandtime_ua',submissionDate);\n\t\t\t\tnlapiSubmitField('customrecord_accounts', nlapiGetRecordId(),['custrecord_approval_status_coa','custrecord_submissiondateandtime_ua'],['1',submissionDate]);\n var subs = nlapiGetFieldValues('custrecord_subs_coa');\n var subVal = subs[0];\n if (subVal != null && subVal != '') \n\t\t\t\t{\n var filter = new Array();\n filter[0] = new nlobjSearchFilter('custrecord_subs_approver', null, 'anyof', subVal);\n filter[1] = new nlobjSearchFilter('isinactive', null, 'is', 'F');\n var rec = nlapiSearchRecord('customrecord_coaapprover', null, filter);\n if (rec != null) \n\t\t\t\t\t{\n var coaApprover = nlapiLookupField('customrecord_coaapprover', rec[0].getId(), 'custrecord_coaapp');\n nlapiSetFieldValue('custrecord_approver_coa', coaApprover);\n nlapiSubmitField('customrecord_accounts', nlapiGetRecordId(), 'custrecord_approver_coa', coaApprover);\n }\n else \n\t\t\t\t\t{\n alert('There is no Approver assigned for this Subsidiary. Please contact your Administrator.');\n nlapiSetFieldValue('custrecord_approver_coa', '');\n }\n }\t\n\t\t\t\tvar appstatus = nlapiGetFieldValue('custrecord_approval_status_coa');\n\t\t\t\tvar coaid = nlapiGetFieldValue('custrecord_coaid');\n\t\t\t\tnlapiLogExecution('DEBUG','appstatus '+appstatus,' coaid '+coaid);\n\t\t\t\tif(coaid){\n\t\t\t\t\tnlapiSubmitField('account', coaid, 'isinactive','T');\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\t//Start- For DFCT0050515 need to remove the condition for checking the Requester field value by Jitendra on 24th April 2015 \n\t\t\t\tnlapiSetFieldValue('custrecord_owner_ea', nlapiGetUser());\n\t\t\t\tnlapiSubmitField('customrecord_accounts', nlapiGetRecordId(), 'custrecord_owner_ea', nlapiGetUser());\n\t\t\t/*END - For DFCT0050515*/\n\t\t\t\n\t\t\tif (nlapiGetRecordId() != null && nlapiGetRecordId() != '' && nlapiGetFieldValue('custrecord_approval_status_coa') == '1') \n\t\t\t{\n\t\t\t\tvar approver = nlapiGetFieldValue('custrecord_approver_coa');\n\t\t\t\tnlapiSetFieldValue('custrecord_submissiondateandtime_ua',submissionDate);\n\t\t\t\tnlapiSubmitField('customrecord_accounts', nlapiGetRecordId(), ['custrecord_date_submit_ea','custrecord_submit_time_updateaccount','custrecord_approve_time_updateaccount','custrecord_submissiondateandtime_ua'],[submitDate,currenttime,'',submissionDate]);\n\t\t\t\t\n\t\t\t\t// Sending the mail for approval\n\t\t\t\tvar rLink = reqUrl + nlapiResolveURL('RECORD', 'customrecord_accounts', nlapiGetRecordId(), 'VIEW');\n\t\t\t\tvar Email = nlapiSendEmail(fromEmail, approver, 'A COA needs your Approval', 'Hi,' + '<br><br>' + 'Please approve the following COA:' + '<br>' + nlapiGetFieldValue('custrecord_accntnumber') + '<br><br>' + 'Thanks' + '<br>' + '<a href=' + rLink + '><b>View Record</b></a>', null, null, null);\n\t\t\t}\t\t\t\n\t\t\tvar appstatus = nlapiGetFieldValue('custrecord_approval_status_coa');\n\t\t\tvar coaid = nlapiGetFieldValue('custrecord_coaid');\n\t\t\tnlapiLogExecution('DEBUG','appstatus out'+appstatus,' coaid '+coaid);\n\t\t\tif(coaid !=null && coaid != '' && appstatus == '1')\n\t\t\t{\n\t\t\t\tnlapiSubmitField('account', coaid, 'isinactive','T');\n\t\t\t\tnlapiLogExecution('DEBUG','appstatus in'+appstatus,' coaid '+coaid);\n\t\t\t}\n } \n catch (e) \n\t\t{\n nlapiLogExecution('ERROR', e.name || e.getCode(), e.message || e.getDetails());\n }\t\t\n }\n}", "title": "" }, { "docid": "76d789d46d1c4f0265d32629f7a646af", "score": "0.4772293", "text": "function PreValidate(submissionData)\n{\n let valid = true;\n\n $(\"#cardNumberSection .warning span\").html(\"Card number is required.\");\n\n MarkValid(\"#cardNumberSection\");\n MarkValid(\"#cardholderNameSection\");\n MarkValid(\"#cvvSection\");\n MarkValid(\"#expirySection\");\n\n if (submissionData.cardNumber.length == 0)\n {\n MarkInvalid(\"#cardNumberSection\");\n valid = false;\n }\n\n if (submissionData.cardholderName.length == 0)\n {\n MarkInvalid(\"#cardholderNameSection\");\n valid = false; \n }\n\n if (submissionData.cvv.length == 0)\n {\n MarkInvalid(\"#cvvSection\");\n valid = false; \n }\n \n if (StringEquals(submissionData.expMonth, \"MM\") || StringEquals(submissionData.expYear, \"YYYY\"))\n {\n MarkInvalid(\"#expirySection\");\n\n if (StringEquals(submissionData.expMonth, \"MM\"))\n {\n MarkInvalid(\"#expirySection #expiryMonth\")\n }\n\n if (StringEquals(submissionData.expYear, \"YYYY\"))\n {\n MarkInvalid(\"#expirySection #expiryYear\")\n }\n\n valid = false; \n }\n else\n {\n let month = submissionData.expMonth;\n let year = submissionData.expYear;\n } \n\n return valid; \n}", "title": "" }, { "docid": "73d1bb5899668826f5118c9e11801c58", "score": "0.4764328", "text": "function EnableMegamissions()\n{\n GoPage('missions');\n IncrementTaskIf(DocTest(\"<i>MegaMissions Active!</i>\"));\n FormSubmit('megamis', 'Enabling megamissions');\n}", "title": "" }, { "docid": "75f4ac68bd08a46916c49ba0c8550110", "score": "0.4756548", "text": "function evaluateForm(newCamp) {\n var formIsValid = true;\n if (newCamp.campName.value == \"\") {\n newCamp.campName.setAttribute(\"class\", \"required\");\n document.getElementById(\"campName\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.comfort.value == \"\") {\n document.getElementById(\"comfort\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n\n }\n if (newCamp.isolation.value == \"\") {\n document.getElementById(\"isolation\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.accessibility.value == \"\") {\n document.getElementById(\"accessibility\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.pet.value == \"\") {\n document.getElementById(\"pet\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.family.value == \"\") {\n document.getElementById(\"family\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.activities.value == \"\") {\n document.getElementById(\"activities\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.areaType.value == \"\") {\n document.getElementById(\"areaType\").setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.lat.value == \"\") {\n document.getElementById(\"location\").setAttribute(\"class\", \"required\");\n newCamp.lat.setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n if (newCamp.long.value == \"\") {\n document.getElementById(\"location\").setAttribute(\"class\", \"required\");\n newCamp.long.setAttribute(\"class\", \"required\");\n formIsValid = false;\n }\n console.log(formIsValid);\n if (formIsValid) {\n buildCampArray(newCamp);\n };\n}", "title": "" }, { "docid": "437679f0f2b139ebb49ccffaf61b4f29", "score": "0.47499487", "text": "function applyCourse(action)\n {\n var data = accountData();\n data['courseId'] = $('#courseSelect').val(); // setting the value to course drop-down based on course we selected - apply.scala.html\n data['courseStartDate'] = $('#courseStartDate').val();\n data['accomodationType'] = $('[name=accommOption]:checked').val();\n var successHandler = function(){ $('#message').text('Course Save is successful').show().delay(5000).fadeOut();\n if(action == 'save')\n {\n window.location=\"/account\" // open /account page if successful\n }\n else\n {\n window.location=\"/paymentgpg?courseId=\"+data['courseId'] //open paymentgpg with course details\n }\n }\n var failureHandler = function(xhr, status, error){ $('#message').text('Course Save is failed with ' + error).show().delay(5000).fadeOut();}\n ajaxHandler(action == 'save' ? '/studentCourse/save' : '/studentCourse/apply', 'POST', data, successHandler, failureHandler);\n }", "title": "" }, { "docid": "037fcb30b21edf1e68d3ba87d80291db", "score": "0.47491133", "text": "get courses (){\n return {\n appetizers: this.appetizers,\n mains: this.mains,\n desserts: this.desserts\n };\n }", "title": "" }, { "docid": "d9581cd622a710fa6e4ad0a407eb82fb", "score": "0.47340325", "text": "function verifyOwnCourse() {\n UserCoursesService.listUserCourses($scope.user.id).then(function (data) {\n userCoursesTable = data;\n $scope.ownCourse = false;\n for (var i = 0; i < userCoursesTable.length; i++) {\n userCourseIds[i] = userCoursesTable[i].id_curso;\n if ($stateParams.courseId == userCourseIds[i]) {\n // If the user is registered in the selected course, $scope.ownCourse\n // is set to true. We use this in the view for validate if the button\n // for registration to the course appers or the button for the view of\n // course contents\n $scope.ownCourse = true;\n }\n }\n });\n }", "title": "" }, { "docid": "0f4c52bddc181d12fecc7c902ad69c2d", "score": "0.47327486", "text": "function checkCoupon(enteredCode, correctCode, currentDate, expirationDate){\n\n}", "title": "" }, { "docid": "c0b45cb9506abcfa8d66fa74c0b71e56", "score": "0.47251216", "text": "function verCarreras(form) {\r\n form.id_career_log.disabled = true;\r\n if (valideIdUser(form))\r\n if (validatePassLength(form)) {\r\n form.btnAcces.disabled = false;\r\n }\r\n if (form.id_group_log.value == 0) {\r\n form.btnAcces.disabled = true;\r\n }\r\n else if (form.id_group_log.value == 3) {\r\n form.id_career_log.disabled = false;\r\n form.id_career_log.focus();\r\n }\r\n}", "title": "" }, { "docid": "4c260c4aa3e8e38369e6533f8593086a", "score": "0.47054422", "text": "destroy(currentYear){\n let messageForThrow =\"The book thrown out if it is over 5 years old\";\n let total = currentYear-this.copyrightDate;\n if(total > 5){\n this.hasBeenDiscarded = \"yes \"+messageForThrow;\n }else{\n this.hasBeenDiscarded =\"No\";\n }\n return this.hasBeenDiscarded+\", years:\"+total;\n }", "title": "" }, { "docid": "a13e85068edc42447cc8182b8573bad9", "score": "0.47029397", "text": "isValidate(){\n this.isError = false;\n this.isShowError = false;\n /*--Check Enrolment End date is blank or not -- */\n var enrollmentEndDate = this.template.querySelector('.EnrollmentEndDate');\n var enrollmentEndDateValue = enrollmentEndDate.value;\n if(enrollmentEndDateValue !== '' && enrollmentEndDateValue !== null && enrollmentEndDateValue !== undefined){\n enrollmentEndDate.setCustomValidity('');\n }else {\n enrollmentEndDate.setCustomValidity('Enrollment End Date is balnk..!!');\n this.isError = true;\n }\n enrollmentEndDate.reportValidity();\n\n /*--Check Enrolment Cancel Reason is blank or not -- */\n var CancellationReason = this.template.querySelector('.CancellationReason');\n var CancellationReasonValue = CancellationReason.value;\n if(CancellationReasonValue !== '' && CancellationReasonValue !== null && CancellationReasonValue !== undefined){\n CancellationReason.setCustomValidity('');\n }else {\n CancellationReason.setCustomValidity('Enrollment Cancellation Reason is blank..!!');\n this.isError = true;\n }\n CancellationReason.reportValidity();\n\n /*--Check Enrolment Notice Period is blank or not -- */\n var noticePeriod = this.template.querySelector('.noticePeriod');\n var noticePeriodValue = noticePeriod.value;\n if(noticePeriodValue !== '' && noticePeriodValue !== null && noticePeriodValue !== undefined){\n noticePeriod.setCustomValidity('');\n }else {\n noticePeriod.setCustomValidity('Enrollment Notice Period Day is blank..!!');\n this.isError = true;\n }\n noticePeriod.reportValidity();\n\n /*--Check Enrolment Last Session is blank or not -- */\n var lastSessiondate = this.template.querySelector('.lastSessiondate');\n var lastSessiondateValue = lastSessiondate.value;\n if(lastSessiondateValue !== '' && lastSessiondateValue !== null && lastSessiondateValue !== undefined){\n lastSessiondate.setCustomValidity('');\n }else {\n lastSessiondate.setCustomValidity('Enrollment Last Session Date is blank.!!');\n this.isError = true;\n }\n lastSessiondate.reportValidity();\n\n /*--Check requested Id is blank or not -- */\n if(this.requestedId !== '' && this.requestedId !== null && this.requestedId !== undefined){\n \n }else {\n this.errorMessage = 'Please Select Enrollment Requested By field value.';\n this.isShowError = true;\n this.isError = true;\n }\n }", "title": "" }, { "docid": "e55c5e424875b9affd75d55cf0a469a2", "score": "0.47000903", "text": "function validateCCMonth(){\n\tvar input = jQuery('#exp-month').val();\n\tvar retval = validMonth(input);\n\trequiredAction('#exp-month',retval);\n\treturn retval;\n}", "title": "" }, { "docid": "368802c9b2e8dc8af41c5616557d49da", "score": "0.46952102", "text": "function c_course(){\n if(this.timeLeft > 0){\n if(this.isWin == 0){\n this.c_c_1.x += 5;\n this.c_c_2.x += 7;\n this.c_c_3.x += 10;\n }\n }\n }", "title": "" }, { "docid": "5bb934b36e09930d8c10b18768a5c0c1", "score": "0.46948454", "text": "function admittedGrad() {\n\t\t\tif($(\"body.gradadmit\").length) {\n\t\t\t//For some reason %0A is added for carriage returns throughout the cookie, we need to remove them to decode it\n\t\t\tvar data = readCookie(\"gradinfo\");\n\t\t\tdata = $.base64Decode(unescape(data.replace(/%0A/ig, \"\")));\n\t\t\t\n\t\t\t// Hide the Request Info button since they don't need it anymore\n\t\t\t$(\"#make-gift\").hide();\n\t\t\t\n\t\t\t// Split up the data since it is sparated by three pipes (|||)\n\t\t\tvar data_ar = data.split(\"|||\");\n\t\t\t// Array setup as: ID|||FName|||LName|||Dept|||Major|||Degree|||Term|||FullPart|||International|||BS/MS|||Confirmed\n\t\t\tif(data_ar[1].length > 0 && data_ar[3].length > 0) {\n\t\t\t\t// Create the text that is added to the first paragraph.\n\t\t\t\tvar introtext = \"Welcome \"+data_ar[1]+\",<br/><br/>Congratulations on your admission to WPI's graduate program in \" + data_ar[4] + \". We're pleased that you are considering joining us in \" + data_ar[6] + \" as a \";\n\t\t\t\tif (data_ar[7]==\"Y\") { introtext += \"full-time\"; $(\".parttime\").hide(); }\n\t\t\t\telse { introtext += \"part-time\"; }\n\t\t\t\tintrotext += \" student pursuing your \"+data_ar[5]+\".\";\n\t\t\t\t$(\"#content p:eq(0)\").html(introtext);\n\t\t\t}\n\t\t\t// Hide the Payment form button if they have already accepted admission\n\t\t\tif(data_ar[10] == \"Y\") { $(\".modSideButton\").hide(); }\n\t\t\t// Hide the international students block if they are not international students\n\t\t\tif(data_ar[8] == \"N\") { $(\"#modFeaturedContent\").hide(); }\n\t\t\t\n\t\t\t// Loop through all the Righ Column Text Modules to see if there is one for the major the current user is part of.\n\t\t\t// The H3 must match the Major Name in Banner plus Info added to the end.\n\t\t\t$(\".modCallout h3\").each(function() {\n\t\t\t\t\t\t\t // If there is a match hide the default module and display the specific module\n\t\t\t\t\t\t\t if($(this).text() == data_ar[4] + \" Information\") {\n\t\t\t\t\t\t\t $(\".modCallout\").hide();\n\t\t\t\t\t\t\t $(this).parent().show();\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t });\n\t\t\n\t\t\t// Add a button to logout\n\t\t\t$(\"#extra\").append(\"<a class=\\\"modSideButton logout\\\"><span> </span> Logout</a>\");\n\t\t\n\t\t\t// When the button to logout is clicked, remove the cookie and then redirect to the login page\n\t\t\t$(\".logout\").click(function() { \n\t\t\t\t\t\t //alert(\"erasing cookie\");\n\t\t\t\t\t\t eraseCookie(\"gradinfo\", \".wpi.edu\");\n\t\t\t\t\t\t //\t\t\t alert(\"cookie erased\");\n\t\t\t\t\t\t location.href=\"/admissions/graduate/login.html\";\n\t\t\t\t\t });\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "7c963c938dfb299b267db957b7ad7106", "score": "0.46937892", "text": "changeDuringcourse(req, res) {\n const _id = req.params._id;\n const during = req.body.during;\n CourseModel.findOne({ _id: _id, isCheck: 0 })\n .then((data) => {\n data.during = during;\n data.save();\n res.status(200).json({\n status: 200,\n success: true,\n message: \"Successfully changed during time\",\n });\n })\n .catch((err) =>\n res.status(402).json({\n status: 402,\n success: true,\n message: \"No valid courses found\",\n })\n );\n }", "title": "" }, { "docid": "40fbfd0f49d5ad93c3e9f3d53d3675b2", "score": "0.46930003", "text": "function getSpecializationSessionSchedule(specializationCourses, enrollmentDate) {\n var coursesSchdule = [];\n var i;\n var numOfSpecCourses = specializationCourses.length;\n var launchDate;\n var rFreq;\n var dur;\n var enrollmentDateObj = new Date(enrollmentDate);\n var sessionStart;\n var sessionEnd;\n var nextSession = enrollmentDate;\n \n //loop through all courses \n for(i = 0; i < numOfSpecCourses; i++){\n launchDate = specializationCourses[i][0];\n rFreq = specializationCourses[i][1];\n dur = specializationCourses[i][2];\n \n sessionStart = getUpcomingSession(launchDate, rFreq, nextSession); \n sessionEnd = sessionStart.addDays(7*dur);\n \n //calculate next session (nextsession begins on the same date that this session ends)\n nextSession = sessionEnd.valueOf();\n coursesSchdule.push([sessionStart.valueOf(), sessionEnd.valueOf()]); \n } \n return coursesSchdule;\n\n}", "title": "" }, { "docid": "a81a83a0cb6eb1a1798bb68e0e1b2e86", "score": "0.46904862", "text": "function view_state_and_quarter(state,course_id) {\n\tlocation.href='/reviews/view/'+state+'/'+course_id; \n}", "title": "" }, { "docid": "f8276c5f220e923ec291833ee45210b5", "score": "0.46860242", "text": "function purchaseMM(){\n if(!cookie.count >= cookie.upgradesPurchased[0]){\n \n if(cookie.count >= cookie.upgradeCosts[0]) {\n cookie.cookieType = \"Chocolate Chip\";\n cookie.logMessage = \"New Upgrade: \" + cookie.cookieType;\n addLogText();\n cookie.upgradesPurchased[0] = true; // Change the boolean of the first index Chocolate Chip to true\n increaseUpgradeCount();\n showUpgrades(); // refreshes the boolean array\n }\n \n else {\n alert(\"You must have \" + cookie.upgradeCosts[0] + \"clicks!\");\n }\n }\n else {\n alert(\"You have already purchaed this upgrade!\");\n \n }\n \n }", "title": "" }, { "docid": "29ce6a792848206493b77d7fbddaeb54", "score": "0.46725142", "text": "neededCredit(part){\n\t\tif(part==\"major1\"){\n\n\t\t\treturn Math.max(this.credit1-this.sumCredit(this.major1Courses),0);\n\t\t}\n\t\telse if(part==\"major2\"){\n\t\t\treturn Math.max(this.credit2-this.sumCredit(this.major2Courses),0);\n\t\t}\n\t\telse if(part==\"outside\"){\n\t\t\treturn Math.max(this.creditOutside-this.sumCredit(this.outsideCourses),0);\n\t\t}\n\t\telse{\n\t\t\treturn Math.max(this.creditGraduate-this.sumCredit(this.allCourses),0);\n\t\t}\n\t}", "title": "" }, { "docid": "5c786e71f0711d9253066ce92c6c2ed3", "score": "0.46712998", "text": "function purchase_validate()\n{\n\tvar result = true;\n\tvar errmsg = \"\";\n\tvar d = new Date();\n\tvar month = document.getElementById(\"exp-month\").value;\n\tvar year = document.getElementById(\"exp-year\").value;\n\tyear = \"20\"+ year;\n\tif(month>12 || month<1)\n\t{\n\t\tresult = false;\n\t\terrmsg +=\"Enter valid month\"; \n\t}\n\tif(result)\n\t{\n\t\tif(year < d.getFullYear())\n\t\t{\n\t\t\tresult = false;\n\t\t\terrmsg +=\"Card is expired.\";\n\t\t}\n\t\telse if(year == d.getFullYear())\n\t\t\t{\n\t\t\t\tif(month < d.getMonth()+1)\n\t\t\t\t{\n\t\t\t\t\tresult = false;\n\t\t\t\t\terrmsg +=\"Card is expired.\";\n\t\t\t\t}\n\t\t\t}\n\t}\n\tif(!result)\t\n\t\talert(errmsg);\n\t\n\tif(result)\t\n\t\tresult = confirm(\"Are you sure?\");\n\t\t\n\treturn result;\n}", "title": "" }, { "docid": "436cff5986837d23c7f6375e5394d411", "score": "0.466686", "text": "function pbl_e5831ee218d2e811a96c000d3a3099e5(eventContext) {\n\ttry {\n\t\tvar v0 = (!Mscrm.BusinessRules.Utility.isNull(eventContext) && typeof eventContext.getFormContext === \"function\") ? eventContext.getFormContext().data.entity : Xrm.Page.data.entity;\n\t\tvar v1 = v0.attributes.get('caseorigincode');\n\t\tvar v2 = v0.attributes.get('checkemail');\n\t\tvar v3 = v0.attributes.get('casetypecode');\n\t\tvar v4 = v0.attributes.get('msdyn_incidenttype');\n\t\tvar v5 = v0.attributes.get('isescalated');\n\t\tvar v6 = v0.attributes.get('customerid');\n\t\tvar v7 = v0.attributes.get('escalatedon');\n\t\tvar v8 = v0.attributes.get('modifiedon');\n\t\tvar v9 = v0.attributes.get('description');\n\t\tvar v10 = v0.attributes.get('socialprofileid');\n\t\tvar v11 = v0.attributes.get('emailaddress');\n\t\tvar v13 = v0.attributes.get('title');\n\t\tvar v14 = {\n\t\t\tmessage: Mscrm.BusinessRulesScript.GetResourceString('c301a11d-7151-44dc-a849-0b27d41c70f1', 'Check your email'),\n\t\t\tactions: null\n\t\t};\n\t\tvar v15 = '';\n\t\tvar v17 = function (op1, op2, e) {\n\t\t\treturn e(op1, op2);\n\t\t};\n\t\tif (((v1) == undefined || (v1) == null || (v1) === \"\") || ((v2) == undefined || (v2) == null || (v2) === \"\") || ((v3) == undefined || (v3) == null || (v3) === \"\") || ((v4) == undefined || (v4) == null || (v4) === \"\") || ((v5) == undefined || (v5) == null || (v5) === \"\") || ((v6) == undefined || (v6) == null || (v6) === \"\") || ((v7) == undefined || (v7) == null || (v7) === \"\") || ((v8) == undefined || (v8) == null || (v8) === \"\") || ((v9) == undefined || (v9) == null || (v9) === \"\") || ((v10) == undefined || (v10) == null || (v10) === \"\") || ((v11) == undefined || (v11) == null || (v11) === \"\")) {\n\t\t\treturn;\n\t\t}\n\t\tvar v12 = (v1) ? v1.getValue() : null;\n\t\tvar v16 = (v3) ? v3.getValue() : null;\n\t\tvar v18 = (v9) ? v9.getValue() : null;\n\t\tif ((v12) === (1)) {\n\t\t\t(Xrm.Page.ui.getFormType() == 1 && (v13 != null && (typeof v13.getValue() === 'boolean' || (v13.getValue() === null || (typeof v13.getValue() === 'string' && v13.getValue().trim.length === 0)))) ? v13.setValue('Origin is phone') : null);\n\t\t} else if ((v12) === (2)) {\n\t\t\tv14.actions = [function () {\n\t\t\t\t\tv11.setValue('this is a recommendation');\n\t\t\t\t}\n\t\t\t];\n\t\t\tv2.controls.forEach(function (c, i) {\n\t\t\t\tc.addNotification({\n\t\t\t\t\tmessages: [Mscrm.BusinessRulesScript.GetResourceString('aeea14f7-231f-4f9f-92c3-2faeac40a124', 'Check email')],\n\t\t\t\t\tnotificationLevel: Xrm.NotificationLevel.recommendation,\n\t\t\t\t\tuniqueId: 'e5831ee2-18d2-e811-a96c-000d3a3099e5SetMessageStep3',\n\t\t\t\t\tactions: [v14]\n\t\t\t\t});\n\t\t\t});\n\t\t\tv15 = v15 + 'e5831ee2-18d2-e811-a96c-000d3a3099e5SetMessageStep3\\x3b';\n\t\t} else if ((v16) === (1)) {\n\t\t\tv4.controls.forEach(function (c, i) {\n\t\t\t\tc.setDisabled(true);\n\t\t\t});\n\t\t} else if ((v16) === (2)) {\n\t\t\tv1.controls.forEach(function (c, i) {\n\t\t\t\tc.setNotification(Mscrm.BusinessRulesScript.GetResourceString('bbeec792-00eb-40bc-886b-f5045e2073e7', 'This is a test error message'), 'e5831ee2-18d2-e811-a96c-000d3a3099e5SetMessageStep7');\n\t\t\t});\n\t\t\tv15 = v15 + 'e5831ee2-18d2-e811-a96c-000d3a3099e5SetMessageStep7\\x3b';\n\t\t} else if ((v16) === (3)) {\n\t\t\tv5.setValue(true);\n\t\t\tv6.setValue([{\n\t\t\t\t\t\tid: '\\x7bc302470e-6dcb-e811-a974-000d3a1be90a\\x7d',\n\t\t\t\t\t\tentityType: 'account',\n\t\t\t\t\t\tname: '1'\n\t\t\t\t\t}\n\t\t\t\t]);\n\t\t\tv7.setValue(v17((v8) ? v8.getUtcValue() : null, 0, function (op1, op2) {\n\t\t\t\t\tif ((op1) == undefined || (op1) == null || (op1) === \"\" || (op2) == undefined || (op2) == null || (op2) === \"\") {\n\t\t\t\t\t\treturn null;\n\t\t\t\t\t}\n\t\t\t\t\tvar result = op1;\n\t\t\t\t\tresult.setDate(op1.getDate() + op2);\n\t\t\t\t\treturn result;\n\t\t\t\t}));\n\t\t} else if (v17((v18), ('Help'), function (op1, op2) {\n\t\t\t\tif ((op1) == undefined || (op1) == null || (op1) === \"\") {\n\t\t\t\t\treturn false;\n\t\t\t\t}\n\t\t\t\treturn op1.toUpperCase().indexOf(op2.toUpperCase()) == 0;\n\t\t\t})) {\n\t\t\tv10.controls.forEach(function (c, i) {\n\t\t\t\tc.setVisible(false);\n\t\t\t});\n\t\t} else if (true) {\n\t\t\tv11.setRequiredLevel('required');\n\t\t}\n\t\tvar v19 = [{\n\t\t\t\t'CId': 'checkemail',\n\t\t\t\t'SId': 'e5831ee2-18d2-e811-a96c-000d3a3099e5SetMessageStep3'\n\t\t\t}, {\n\t\t\t\t'CId': 'caseorigincode',\n\t\t\t\t'SId': 'e5831ee2-18d2-e811-a96c-000d3a3099e5SetMessageStep7'\n\t\t\t}\n\t\t];\n\t\tfor (var i = 0; i < v19.length; i++) {\n\t\t\tvar l1 = v19[i];\n\t\t\tif (v15.indexOf(l1.SId + '\\x3b') === -1) {\n\t\t\t\tvar v0 = (l1.RId) ? v0.relatedEntities.get(l1.RId) : v0;\n\t\t\t\tvar attributeObject = (v0) ? v0.attributes.get(l1.CId) : null;\n\t\t\t\t(attributeObject) && attributeObject.controls.forEach(function (c, i) {\n\t\t\t\t\tc.clearNotification(l1.SId);\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t} catch (e) {\n\t\tMscrm.BusinessRules.ErrorHandlerFactory.getHandler(e, arguments.callee).handleError();\n\t}\n}", "title": "" }, { "docid": "b09c7cf2740e29a98a94d11996e17c91", "score": "0.46599954", "text": "async check() {\n const day = this.nascimento.split(dateFormats.separatorSlash)[0];\n const month = this.nascimento.split(dateFormats.separatorSlash)[1];\n const year = this.nascimento.split(dateFormats.separatorSlash)[2];\n const birthDate = new Date(year + dateFormats.separatorDash + month + dateFormats.separatorDash + day);\n let presentDate = new Date();\n presentDate.setHours(0);\n presentDate.setMinutes(0);\n presentDate.setUTCMilliseconds(0);\n\n // Variables needed for the response\n const ageFromDate = moment(presentDate).diff(moment(birthDate), 'years');\n this.totalCoverage = quotation.sumIndividualCoverage(this.coberturas);\n this.totalPrize = quotation.calcPrizeWithDiscounts(this.coberturas, ageFromDate);\n this.n = quotation.amountOfPayments();\n this.pmt = quotation.calcParcelValue();\n this.vencimento = moment(quotation.next5thBusinessDay(presentDate)).format(dateFormats.dayMonthYear);\n\n // Checks if the person has more than 18 years old\n if (!quotation.isMoreThan18YearsOld(birthDate)) {\n return {status: status.BAD_REQUEST, message: localize.getString('fail.tooYoung', 'pt')};\n }\n\n // Checks if the city is valid\n if (!(await address.isValidCity(this.endereco.cidade))) {\n return {status: status.BAD_REQUEST, message: localize.getString('fail.unregisteredCity', 'pt')};\n }\n\n // Checks if the CEP is valid\n if (!(await address.isValidCEP(this.endereco.cep))) {\n return {status: status.BAD_REQUEST, message: localize.getString('fail.illegal.postalCode', 'pt')};\n }\n\n // Checks if there is one mandatory coverage present\n if (!quotation.hasMandatoryCoverage(this.coberturas)) {\n return {status: status.BAD_REQUEST, message: localize.getString('fail.missing.mandatoryCoverage', 'pt')};\n }\n\n // Max number of coverages excedded\n if (this.coberturas.length > 4) {\n return {status: status.BAD_REQUEST, message: localize.getString('fail.tooManyCoverages', 'pt')};\n }\n\n return {status: status.OK};\n }", "title": "" }, { "docid": "a5ee1adc8ed11b8da3c97387c1b9011f", "score": "0.46599644", "text": "function C17332_Error_Message_Expired_CC()\n{\ntry{\n Log.AppendFolder(\"C17332_Error_Message_Expired_CC\"); \n InitializationEnviornment.initiliaze();\n AppLoginLogout.login(); \n WrapperFunction.selectKeyword(\"Daily Admission\"); \n selectPackage(\"Open Dated\",\"Children (Ages 3-12)\");\n aqUtils.Delay(3000);\n WrapperFunction.finilizeOrder()\n aqUtils.Delay(3000);\n CreditCardButton.Click();\n if(CC_EnterNumber.Exist && CC_EnterNumber.Visible)\n {\n Button.clickOnButton(CC_EnterNumber);\n SelectPaymentType.enterCCNumber(\"4444333322221111\");\n //CC_ExpirationMonth.ClickItem(\"04 - April\");\n //CC_ExpirationYear.Keys(\"[Down]\");\n CC_StreetAddress.Keys(\"MBS\");\n CC_ZipCode.Keys(\"90210\");\n \n WrapperFunction.verifyBalance(labelTotal,PaymentType_BalanceLabel);\n var paymentTypeBal=WrapperFunction.getTextValue(PaymentType_BalanceLabel);\n paymentTypeBal= aqString.Replace(paymentTypeBal,\"Balance: $\",\"\");\n WrapperFunction.setTextValue(PayamountTextBox,paymentTypeBal);\n Button.clickOnButton(applyButton); \n aqUtils.Delay(2000);\n \n if(/*(ccYearErrorindicator.Exists && ccYearErrorindicator.Visible) ||*/(\n ccMonthlErrorindicator.Exists && ccMonthlErrorindicator.Visible)){\n Log.Message(\" A red border is displayed as the expired date is a problem.\");\n }else{\n merlinLogError(\" A red border is not displayed as the expired date is a problem.\");\n } \n }else{\n merlinLogError(\"The interface is not changes from Cash to the Credit Card.\");\n merlinLogError(\"Credit Card fields are not displayed.\");\n } \n AppLoginLogout.logout(); \n } catch (e) {\n\t merlinLogError(\"Oops! There's some glitch in the script: \" + e.message);\n\t return;\n }\n finally { \n\t Log.PopLogFolder();\n } \n}", "title": "" }, { "docid": "9136ca1b3134fbf06197fc0de9fcf03f", "score": "0.4654573", "text": "function requiredCrystals() {\n required = Math.floor(Math.random() * (120 - 19 + 1) + 19);\n log(`Points needed: ${required}`);\n $requiredCrystals.text(required);\n return required;\n }", "title": "" }, { "docid": "a8967381155b6637aad417999d1b20d9", "score": "0.46504682", "text": "function validateCCYear(){\n\tvar input = jQuery('#exp-year').val();\n\tvar retval = validYear(input);\n\trequiredAction('#exp-year',retval);\n\treturn retval;\n}", "title": "" }, { "docid": "d6e117bfc4a319a8eb6707874dea4c38", "score": "0.46503192", "text": "function page_startSearch(request) {\r\n var LOG_TITLE = 'page_startSearch';\r\n var newActPeriod = nlapiLoadConfiguration(\"companypreferences\").getFieldValue(\"custscript_apco_acct_period\");\r\n nlapiLogExecution('DEBUG', 'period ', ' config sesttings ' + ': ' + newActPeriod);\r\n var stUser = nlapiGetUser();\r\n var objEmpLocation = 'customrecord_rtf_course_group';\r\n\r\n\r\n var _SEARCHFORM = nlapiCreateForm('Accounting Periods');\r\n\r\n //buttons for choosing on how the searching for the items will execute\r\n _SEARCHFORM.addSubmitButton('Update Projects');\r\n\r\n _SEARCHFORM.addField('custpage_lbc_from_location', 'select', 'Accounting Period: ', 'accountingperiod').setDisplayType('inline').setDefaultValue(newActPeriod);\r\n //store in a parameter the values needed for processing the records\r\n _SEARCHFORM.addField('custpage_action', 'text', 'Action').setDisplayType('hidden').setDefaultValue('GET_ITEMS');\r\n\r\n return _SEARCHFORM;\r\n}", "title": "" }, { "docid": "2610ac04e0824c4d1bad3ad5fa4b3f65", "score": "0.46492088", "text": "function getCurrentYearMonth()\n{\n var currentYear = new Date().getFullYear();\n var currentMonth = new Date().getMonth() + 1;\n if (currentMonth < 10){\n currentMonth = \"0\" + currentMonth;\n }\n var currentYearMonth = currentYear + \"-\" + currentMonth;\n document.getElementById('cust-expiry').min = String(currentYearMonth);\n}", "title": "" }, { "docid": "b31f88bfed085a52c0a9f67a80b396a4", "score": "0.464626", "text": "function calcSecurity() {\n\n // percent = balanceScore + supplyScore [%]\n var percent, balanceScore, supplyScore;\n \n balanceScore = 0.0;\n supplyScore = 0.0;\n \n // WEIGHTS SHOULD ADD UP TO 1.0\n var BALANCE_WEIGHT = 0.5;\n var SUPPLY_WEIGHT = 0.5;\n\n // Magnitude of allowed value difference before score reaches 0% (1.0 for 100% deviance; 2.0 for 200% deviance, etc)\n var TOLERANCE = 2.0;\n // Ideal %Capacity Available in Network\n var IDEAL_NETWORK_BUFFER = 0.2;\n \n var siteCapacity;\n var totalCapacity, numBackup, bufferSupply;\n var scoreCount;\n var current;\n \n // If Demand Exists; NCE's Score Counts toward Total\n scoreCount = 0;\n \n // Cycles through Each NCE\n for (var i=0; i<agileModel.activeProfiles.length; i++) {\n\n numBackup = 0.0;\n \n // Calculates NCE Capacity at each site;\n siteCapacity = new Array(agileModel.SITES.length);\n for (var s=0; s<agileModel.SITES.length; s++) {\n siteCapacity[s] = 0.0;\n for (var b=0; b<agileModel.SITES[s].siteBuild.length; b++) {\n current = agileModel.SITES[s].siteBuild[b];\n if (current.PROFILE_INDEX == agileModel.activeProfiles[i].ABSOLUTE_INDEX) {\n siteCapacity[s] += current.capacity;\n }\n }\n \n }\n \n // Calculates Total NCE Capacity\n totalCapacity = 0.0;\n for (var s=0; s<agileModel.SITES.length; s++) {\n totalCapacity += siteCapacity[s];\n }\n \n var demand = float(agileModel.activeProfiles[i].demandProfile.getString(2, min(session.current.TURN, NUM_INTERVALS-1) ));\n demand /= 1000.0; // units of kiloTons\n \n // Calaculates normalized balance and supply scores and adds them to total\n if ( demand > 0) { // Only scores if demand exists\n // If Demand Exists; NCE's Score Counts toward Total\n scoreCount ++;\n \n // Determines how many \"backup\" sites there are\n if (agileModel.SITES.length == 1) {\n // Scores Perfect if only one site\n numBackup = 1.0;\n } else {\n // assigns \"1\" if capacity exists at site\n for (var s=0; s<agileModel.SITES.length; s++) {\n if (siteCapacity[s] > 0.0) {\n numBackup += 1.0;\n }\n }\n }\n \n // normalizes balance/backup to a score 0.0 - 1.0;\n if (agileModel.SITES.length > 1) {\n numBackup -= 1.0; // Eliminates effect of first site\n numBackup /= (agileModel.SITES.length - 1);\n if (numBackup < 0.0) numBackup = 0.0;\n }\n \n // Adds the current NCE's balance score to the overall\n balanceScore += agileModel.activeProfiles[i].weightBalance * numBackup;\n \n\n // Calculate Normalized supply score and add it to total\n var sup = 0;\n bufferSupply = (1.0 + IDEAL_NETWORK_BUFFER) * demand / totalCapacity;\n if (totalCapacity == 0) {\n sup = 0.0;\n } else if (bufferSupply > 0 && bufferSupply <= 1.0) {\n sup = 1.0;\n } else if (bufferSupply > 1.0) {\n sup = TOLERANCE - bufferSupply;\n if (sup < 0.0) sup = 0;\n }\n supplyScore += agileModel.activeProfiles[i].weightSupply * sup;\n \n }\n \n }\n \n // Aggregate scores\n balanceScore /= scoreCount;\n supplyScore /= scoreCount;\n percent = BALANCE_WEIGHT * balanceScore + SUPPLY_WEIGHT * supplyScore;\n \n return percent;\n}", "title": "" }, { "docid": "c04bbcdc5fe204d5b11bfd90c5506363", "score": "0.46398628", "text": "function DiscountCampaign() {\n \n //If the special campaign is selected then the enddate will always be one week in the future.\n if (document.getElementById('MainContent_discountCampaigne').checked) {\n //Locks the end date so the enddate always will be one week in the future.\n document.getElementById('MainContent_endDate').disabled = true;\n var startDate = document.getElementById('MainContent_startDate').value;\n var newDate = new Date(startDate)\n newDate = AddDays(newDate, 7);\n document.getElementById('MainContent_endDate').value = ConvertDateFormat(newDate);\n\n //Sets the max persons to 4.\n var adults = document.getElementById('MainContent_Voksne');\n var childen = document.getElementById('MainContent_Børn');\n adults.max = (4- childen.value).toString();\n childen.max = (4 - adults.value).toString();\n\n //Sets access to the waterpark determent on the persons.\n document.getElementById('MainContent_VoksenBadeland').value = adults.value * 7;\n document.getElementById('MainContent_BadelandBarn').value = childen.value * 7;\n\n document.getElementById('MainContent_VoksenMorgenkomplet').value = adults.value * 6;\n document.getElementById('MainContent_BarnMorgenkomplet').value = childen.value * 6;\n\n SetPriceLabels(1099, 0, 0, 0, 0);\n }\n \n}", "title": "" }, { "docid": "f60d248f768b52d4bc5e646c6888d6e8", "score": "0.46374106", "text": "get courses(){\n return {\n appetizers: this._course.appetizers,\n mains: this._course.mains,\n desserts: this._course.desserts\n }\n }", "title": "" }, { "docid": "6d9e89127c05afa9721d679580bf5117", "score": "0.46285006", "text": "function CS (){\n\t\t// configuration\n\t\tthis.accountId = config.accountId;\n\t\tthis.siteNS = config.siteNS;\t\t\n\t\tthis.customVars = {};\n\t}", "title": "" }, { "docid": "44f17481b01dcd027e4aa2c8f7cee0e3", "score": "0.46224624", "text": "visit(agent, date) {\n if (agent.state != State.QUARANTINED) {\n if (agent.medicalStatus.infectionDate !== undefined) {\n agent.state = State.QUARANTINED\n if (agent.medicalStatus.certifiedPositiveBy == undefined) {\n agent.medicalStatus.certifiedPositiveBy = this.id\n }\n agent.medicalStatus.quarantinedDate = new Date(date)\n } else {\n agent.state = State.NORMAL\n }\n }\n }", "title": "" }, { "docid": "aa55fc1a0030446e5918ed5c9b7519fc", "score": "0.46206194", "text": "get mains() {\n return this._courses.mains;\n }", "title": "" }, { "docid": "662ffd4f2c43fd93e60ba24baab682b3", "score": "0.46193504", "text": "function reqSatisfied(preReqList) {\n //console.log(\"Testing for satisfaction of requirements(\"+req+\") isArray:\"+Array.isArray(req));\n // No Prereq\n if (preReqList.length === 0)\n return entryTerm;\n\n // Identify maxYear so that we can stop iteration (no future courses planned)\n var years = Object.keys(plan);\n years = years.map(function(x){ return parseInt(x); });\n years.sort(function(a,b){ return a-b; });\n var maxYear = years[years.length-1];\n\n var earliestTermList = [];\n\n for(var zzz=0; zzz < preReqList.length; zzz++) {\n var req = preReqList[zzz];\n\n if (Array.isArray(req)===false) {\n //console.log(\"================ SIMPLE REQ ================== looking for(\"+req+\")\");\n // Simple Req -- just find the course in the plan and return the term after its location\n var satisfied = false;\n if (transferredIn.includes(req)) {\n earliestTermList.push(entryTerm);\n satisfied = true;\n }\n else {\n for(var it=entryTerm; Math.floor(it/3) <= maxYear; it++) {\n var currTerm = it%3;\n var currYear = Math.floor(it/3);\n if (typeof plan[currYear] !== \"undefined\" && typeof plan[currYear][currTerm] !== \"undefined\") {\n if (plan[currYear][currTerm].includes(req)) {\n earliestTermList.push(it+1);\n satisfied = true;\n break;\n }\n }\n }\n }\n if (satisfied === false)\n return -1;\n } else if (Number.isInteger(req[0])) {\n // Take n credits from\n var satisfied = false;\n var creditsRemaining = req[0];\n var coursesAvailable = req[1].slice();\n for(var it=entryTerm; Math.floor(it/3) <= maxYear; it++) {\n var currTerm = it%3;\n var currYear = Math.floor(it/3);\n if (typeof plan[currYear] !== \"undefined\" && typeof plan[currYear][currTerm] !== \"undefined\") {\n // Valid term with classes in it\n for(var i=0; i < coursesAvailable.length; i++) {\n if (plan[currYear][currTerm].includes(coursesAvailable[i])) {\n creditsRemaining -= catalog[coursesAvailable[i]].credits;\n //console.log(\" - creditsRemaining: \"+creditsRemaining +\" - took: \"+coursesAvailable[i] +\" at index: \"+i);\n //sleep(500);\n if (creditsRemaining <= 0) {\n earliestTermList.push(it+1);\n satisfied = true;\n break;\n }\n if (catalog[coursesAvailable[i]].doubleTake === false) {\n coursesAvailable.splice(i,1);\n i-=1;\n }\n }\n }\n if (satisfied === true)\n break;\n }\n }\n if (creditsRemaining > 0)\n return -1;\n } else {\n //console.log(\"===== you are required to take one of the following: [\"+req+\"]\");\n // Take one of the following\n var satisfied = false;\n for(var it=entryTerm; Math.floor(it/3) <= maxYear; it++) {\n var currTerm = it%3;\n var currYear = Math.floor(it/3);\n if (typeof plan[currYear] !== \"undefined\" && typeof plan[currYear][currTerm] !== \"undefined\") {\n // Current term works due to transferred prereq\n if (transferredIn.includes(req)) {\n earliestTermList.push(entryTerm);\n satisfied = true;\n break;\n }\n // Valid term with classes in it\n for(var i=0; i < req.length; i++) {\n if (plan[currYear][currTerm].includes(req[i])) {\n earliestTermList.push(it+1);\n satisfied = true;\n break;\n }\n }\n }\n if (satisfied === true)\n break;\n }\n if (satisfied === false)\n return -1;\n }\n }\n\n // Find max of earliestTermList and return it\n earliestTermList.sort(function(a,b){ return a-b; });\n return earliestTermList[earliestTermList.length-1];\n}", "title": "" }, { "docid": "a96e2c5c891405e3f6fb07b86c116dec", "score": "0.46155533", "text": "function sectionate(courses) {\n\tfor (var i=0; i < courses.length; i++) {\n\t\tif (courses[i].courseNum < 100) {\n\t\t\tlowerCourses.push(courses[i]);\n\t\t}\n\t\telse if ((courses[i].courseNum >= 100) && (courses[i].courseNum < 200)) {\n\t\t\tupperCourses.push(courses[i]);\n\t\t}\n\t\telse if (courses[i].courseNum >= 200) {\n\t\t\tgradCourses.push(courses[i]);\n\t\t}\n\t\telse {\n\t\t\tnoNumCourses.push(courses[i]);\n\t\t}\n\t}\n}", "title": "" }, { "docid": "6d3ed9fcb8851c5d9521c247eae54543", "score": "0.46022823", "text": "function isCourseFormValid(){\r\n return(CAddField.isValid() && CMailField.isValid() && CTitleField.isValid()&& CLNameField.isValid() && CFNameField.isValid() && CTelephoneField.isValid() && CMobileField.isValid());\r\n }", "title": "" }, { "docid": "ecd13778b607f7a0f5b858edb55790e5", "score": "0.45927113", "text": "function row_39() {\n var score = 0;\n if (rowYearsSince(39) > 0) {\n // Do they have a policy to make IPD available on request [if they have any start date in 39]\n score = 250;\n var discount = 0;\n if (!rowFlaggedTrue(40)) {\n // Include unlicensed treatments\n discount += 0.25;\n }\n if (!rowFlaggedTrue(41)) {\n // Include off-label uses\n discount += 0.25;\n }\n if (!rowFlaggedTrue(42)) {\n // Include discountphase 4 trials\n discount += 0.25;\n }\n score = score - (score * discount);\n // Divide retrospective score by 25, then multiply for every year\n // to which the retrospective policy applies.\n score = score / 25 * rowYearsSince(39);\n }\n return score\n}", "title": "" }, { "docid": "68de4b76f1b009dae18d4c767e8e3d90", "score": "0.45918295", "text": "function isECourseFormValid(){\r\n return( CourseNameField.isValid() && CourseDaysField.isValid());\r\n }", "title": "" }, { "docid": "6f7f20ea33fd635445e3c310c6edc787", "score": "0.45864183", "text": "function isThereCapacity() {\n var data = {\n action: 'capacity',\n group: 'General Public'\n }; \n\n RegistrationFactory.isThereCapacity(data)\n .then(function(response) {\n $scope.capacity = response;\n });\n }", "title": "" }, { "docid": "12c9327cb4b4410467ed36c191a3aa0a", "score": "0.45805785", "text": "function isEligible(student) {\n // assumed student is not eligible\n let flag = false;\n console.log(student.marks);\n if(student.marks > 60) {\n flag = true;\n }\n return flag;\n}", "title": "" }, { "docid": "3d11f12991d443d44032f2edef81831a", "score": "0.45765513", "text": "function commissisonRule(follower_cnts, product_cost, cpm, bonus_rate, max_commission){\n if(typeof follower_cnts != 'number'){\n // by default, commission is $80\n return 80;\n }\n\n let cpm_tier;\n const follower_5k_mod = Math.floor(follower_cnts / 5000);\n\n if(follower_cnts <= 30000){\n cpm_tier = cpm;\n }else if(follower_cnts > 30000 && follower_cnts <= 50000){\n cpm_tier = cpm - 1;\n }else if(follower_cnts > 50000 && follower_cnts <= 100000){\n cpm_tier = cpm - 2;\n }else if(follower_cnts > 100000 && follower_cnts <= 200000){\n cpm_tier = cpm - 3;\n }else{\n cpm_tier = cpm - 4;\n }\n let commission_dollar = Math.min(Math.max(cpm_tier * 5 * follower_5k_mod - product_cost, 0), max_commission);\n\n let bonus_dollar = Math.floor(commission_dollar * bonus_rate);\n commission_dollar = Math.floor(commission_dollar / 10) * 10;\n return {\n commission_dollar,\n bonus_dollar\n }\n}", "title": "" }, { "docid": "f05e02c2f468b259c2e5ea366a0a82eb", "score": "0.45755178", "text": "function minDate() {\n // var allowed = document.getElementById('allowed')\n // let date = new Date();\n // let day = date.getDay('calender');\n // console.log(day)\n // return day;\n var today = new Date();\n var dd = String(today.getDate()).padStart(2, '0');\n var mm = String(today.getMonth() + 1).padStart(2, '0');\n var yyyy = today.getFullYear();\n \n today = mm + '/' + dd + '/' + yyyy;\n //SPLIT -- Look Up.\n // SLICE -- seperates 1999-11-11 \n // let variable = obj.slice(0,4); //1999\n // let variable2 = obj.slice(5,7); // 11\n // let variable3 = obj.slice(8,10); //11\n //Substring similar to SLICE index=>(0,0)<= how many character to move from there\n let inputDate = document.getElementById('input2').value;\n let d = new Date(inputDate)\n let day = d.getUTCDate();\n let month = d.getUTCMonth() + 1;\n let year = d.getUTCFullYear();\n\n let allow = document.getElementById('allowed');\n\n if (yyyy - year > 18) {\n\n allow.innerHTML = \"Welcome to Here.\"\n } else if (yyyy - year < 18) {\n\n allow.innerHTML = \"Leave my Website.\"\n } else {89\n if (month < mm) {\n\n allow.innerHTML = \"Welcome to Here.\"\n } else if (month > mm) {\n\n allow.innerHTML = \"Leave my Website.\"\n } else {\n if (day <= dd) {\n allow.innerHTML = \"Welcome to Here.\"\n } else {\n \n allow.innerHTML = \"Leave my Website.\"\n }\n }\n }\n \n}", "title": "" }, { "docid": "8d862a2e98d2c869be7cb76af4ccc55d", "score": "0.45735306", "text": "function uridFromTimetable(){\n var cpSS = SpreadsheetApp.openById(myCoursePlannerDocId);\n var rsSS = SpreadsheetApp.getActiveSpreadsheet();\n \n var tempTT = cpSS.getSheetByName(myClassSectionDefnSheet).getDataRange().getValues();\n // Logger.log(tempTT);\n var myTT = ss2Obj(tempTT,9,0);\n var courseDefn = cpSS.getSheetByName(courseDefnSheet).getDataRange().getValues();\n var fourYears = [{year: 9, prop:\"G9\"},{year: 10, prop:\"G10\"}, {year: 11, prop:\"G11\"},{year: 12, prop:\"G12\"}]; //The 4 years in the 4-year plan and the column in courseDefn that contains info about whether course is in that yeargroup's plan.\n var blocks = [1,2,3,4,5,6,7];\n var depts = cpSS.getSheetByName(deptDefnSheet).getDataRange().getValues();\n \n //Create an object of courses\n var courseObj = ss2Obj(courseDefn, 1,0);\n\n \n //create an object for 4-year plan combinations of options\n var fourYearPlan = {}\n for(var gr in fourYears){\n fourYearPlan[fourYears[gr].year] = { grade:fourYears[gr].year, prop: fourYears[gr].prop};\n for(var d = 1; d < depts.length; d++) fourYearPlan[fourYears[gr].year][depts[d][0]] = [];\n }\n for (var course in courseObj){\n for(var gr in fourYears){\n var thisYGrp = fourYears[gr].year;\n if(courseObj[course][fourYears[gr].prop] > 0){ \n var thisDept = courseObj[course].Department;\n if(blocks.indexOf(thisDept) > -1){\n fourYearPlan[thisYGrp][thisDept].push(course);\n }\n }\n }\n }\n \n var ssResults = ss2Obj(rsSS.getSheetByName(\"Valid Requests\").getDataRange().getValues(),0,0);\n var invalidRequests = ss2Obj(rsSS.getSheetByName(\"Problem Requests\").getDataRange().getValues(),0,0); \n\n var transcripts = SpreadsheetApp.openById(myListDocID).getSheetByName(myCreditsSheetName).getDataRange().getValues();\n \n var results = textifyDates(SpreadsheetApp.openById(mySurveyCollector).getSheetByName(mySurveySheetName).getDataRange().getValues());\n \n return {courseObj: courseObj, studentObj: ssResults, fourYearPlan: fourYearPlan, tt: tempTT, invalidRequests: invalidRequests, thisUser: thisUser, transcripts: transcripts, savedResults: results};\n \n}", "title": "" }, { "docid": "45d86816d5343032c87f763435ed6d85", "score": "0.45708257", "text": "function selectYear(){\n var restriction = \"1=1\";\n if (valueExistsNotEmpty(getFieldRes('bl.site_id'))) {\n restriction += \" and exists(select 1 from bl where gb_fp_setup.bl_id = bl.bl_id and \" + getFieldRes('bl.site_id') + \")\";\n }\n \n if (valueExistsNotEmpty(getFieldRes('gb_fp_setup.scenario_id'))) {\n restriction += \" and \" + getFieldRes('gb_fp_setup.scenario_id');\n }\n View.selectValue(\"abGbFpEsExpConsole\", '', [\"gb_fp_setup.calc_year\"], \"gb_fp_setup\", [\"gb_fp_setup.calc_year\"], [\"gb_fp_setup.calc_year\"], restriction, null, null, null, null, null, null, 'multiple');\n \n}", "title": "" }, { "docid": "2855b80e0a34f4c446dade6825f8fa4e", "score": "0.4568774", "text": "function calcCAPEX() {\n var expenses = 0.0;\n var current;\n for (var i=0; i<agileModel.SITES.length; i++) {\n for (var j=0; j<agileModel.SITES[i].siteBuild.length; j++) {\n current = agileModel.SITES[i].siteBuild[j];\n if (!current.capEx_Logged) { // Ensures capital cost for build is only counted once\n expenses += current.buildCost;\n if (current.age != 0) current.capEx_Logged = false;\n }\n }\n }\n return expenses;\n}", "title": "" }, { "docid": "7575c3ec9181b1ceb002e2ddc106e4a9", "score": "0.45679063", "text": "addProductionCookies() {\n this.Model.cookieCount += this.getTotalProductionPerSecond(this.Model) / 10;\n }", "title": "" }, { "docid": "8d7743ff9a1d5aa3d9e9bd6913db6d27", "score": "0.4561486", "text": "function _Create(objRequest) {\n nlapiLogExecution('AUDIT','CREATE Courses', '=====START=====');\n var stCustId = objRequest['CustomerId'];\n var httpBody = objRequest;\n var objDataResponse = {\n Response: 'F',\n Message: 'Default Value',\n ReturnId: ''\n };\n\n\n var newICourseRecord = nlapiCreateRecord('customrecord_rc_course');\n // newICourseRecord.setFieldValue('custrecord_rc_course_', httpBody)\n try {\n newICourseRecord.setFieldValue('custrecord_rc_course_title', httpBody.Title),\n newICourseRecord.setFieldValue('custrecord_rc_course_number', httpBody.Number),\n newICourseRecord.setFieldValue('custrecord_rc_course_credit_level', httpBody.CreditLevel.Id),\n newICourseRecord.setFieldValue('custrecord_rc_course_credit_hours', httpBody.CreditHours),\n newICourseRecord.setFieldValue('custrecord_rc_course_syllabi_name', httpBody.SyllabiName),\n // How do deal w this\n newICourseRecord.setFieldValue('custrecord_rc_course_institution', httpBody.ModeOfInstruction),\n newICourseRecord.setFieldValue('custrecord_rc_course_reg_course', httpBody.RegisteredCourseId)\n objDataResponse.ReturnId = nlapiSubmitRecord(newICourseRecord, true)\n } catch (ex) {\n nlapiLogExecution('ERROR', 'Something broke trying to set fields' + ex.message)\n\n }\n\n if(objDataResponse.ReturnId){\n objDataResponse.Response = 'T';\n objDataResponse.Message = 'Yo it seems as though we have been successful with endevour'\n }\n\n // Ask john.\n //1.)How to deal with \"missing\" values. What values must be supplied at any given stage\n // Mode up is required(looking at ns)\n\n // its either a list OR a record A list has id and value when writing i only provide an ID, don't pass anything but the id\n // think of it as an Enumerator, a number that means something else.\n //2.)How to deal with list objects\n\n\n\n objResponse.setContentType('PLAINTEXT');\n objResponse.write(JSON.stringify(objDataResponse));\n nlapiLogExecution('AUDIT','CREATE Courses', '======END======');\n return (JSON.stringify(objDataResponse));\n}", "title": "" }, { "docid": "90d42912b4d3a1b465490d98dde6cd4a", "score": "0.4560845", "text": "getStudentCourses(studentid) {\n return Boekingen.find({$and:[{Student: studentid},{Academiejaar: currentAcademiejaar }]})\n }", "title": "" }, { "docid": "e71c41ba1888a8fa6a273cc8038224f9", "score": "0.455228", "text": "function _cheetah() {\n\n\t\t\t// disable further removals for 1s\n\t\t\tvm.disableAdd = true;\n\n\t\t\tLinkVoteChallengeService\n\t\t\t\t.getMockItemsData()\n\t\t\t\t.then( function( response ) {\n\n\t\t\t\t\tLinkVoteChallengeService.setAppData( { items: response.data.posts, userCheated: true }, false );\n\n\t\t\t\t\t// set timeout to wait localstorage update (~1s enough?)\n\t\t\t\t\t$timeout( function() {\n\n\t\t\t\t\t\tvm.isUserCheated = true;\n\n\t\t\t\t\t\t// disable further removals for 1s\n\t\t\t\t\t\tvm.disableAdd = false;\n\n\t\t\t\t\t\t// @see toaster.controller.js\n\t\t\t\t\t\t$rootScope.$broadcast( 'mso.showToaster', { toasterType: 'mso.simpleToast', message: 'You\\'ve added <strong>25 items</strong> with some kind of poisonous elixir!' } );\n\n\t\t\t\t\t}, 1000 );\n\t\t\t\t\t\n\t\t\t\t} );\n\n\t\t}", "title": "" }, { "docid": "73fdbbad27daed69de787fafa3fb1eeb", "score": "0.45479888", "text": "function mainSection() {\n\n var formattedCommencementDate = '';\n var formattedExpiryDate = '';\n var formattedUltimateExpiryDate = '';\n var formattedBusinessStartDate = '';\n\n dateListedForSale = format.format({\n value: dateListedForSale,\n type: format.Type.DATE\n });\n var dateListedForSaleArray = dateListedForSale.split('/');\n if (dateListedForSaleArray[1] < 10) {\n dateListedForSaleArray[1] = '0' + dateListedForSaleArray[1];\n }\n if (dateListedForSaleArray[0] < 10) {\n dateListedForSaleArray[0] = '0' + dateListedForSaleArray[0];\n }\n var formattedDateListedForSale = dateListedForSaleArray[2] + '-' +\n dateListedForSaleArray[1] +\n '-' + dateListedForSaleArray[0];\n\n if (!isNullorEmpty(commencementDate)) {\n commencementDate = format.format({\n value: commencementDate,\n type: format.Type.DATE\n });\n\n var commencementDateArray = commencementDate.split('/');\n if (commencementDateArray[1] < 10) {\n commencementDateArray[1] = '0' + commencementDateArray[1];\n }\n if (commencementDateArray[0] < 10) {\n commencementDateArray[0] = '0' + commencementDateArray[0];\n }\n var formattedCommencementDate = commencementDateArray[2] + '-' +\n commencementDateArray[1] +\n '-' + commencementDateArray[0];\n }\n\n if (!isNullorEmpty(expiryDate)) {\n expiryDate = format.format({\n value: expiryDate,\n type: format.Type.DATE\n });\n var expiryDateArray = expiryDate.split('/');\n if (expiryDateArray[1] < 10) {\n expiryDateArray[1] = '0' + expiryDateArray[1];\n }\n if (expiryDateArray[0] < 10) {\n expiryDateArray[0] = '0' + expiryDateArray[0];\n }\n var formattedExpiryDate = expiryDateArray[2] + '-' +\n expiryDateArray[1] +\n '-' + expiryDateArray[0];\n }\n\n if (!isNullorEmpty(ultimateExpiryDate)) {\n ultimateExpiryDate = format.format({\n value: ultimateExpiryDate,\n type: format.Type.DATE\n });\n var ultimateExpiryDateArray = ultimateExpiryDate.split('/');\n if (ultimateExpiryDateArray[1] < 10) {\n ultimateExpiryDateArray[1] = '0' + ultimateExpiryDateArray[1];\n }\n if (ultimateExpiryDateArray[0] < 10) {\n ultimateExpiryDateArray[0] = '0' + ultimateExpiryDateArray[0];\n }\n var formattedUltimateExpiryDate = ultimateExpiryDateArray[2] + '-' +\n ultimateExpiryDateArray[1] +\n '-' + ultimateExpiryDateArray[0];\n }\n if (!isNullorEmpty(businessStartDate)) {\n businessStartDate = format.format({\n value: businessStartDate,\n type: format.Type.DATE\n });\n var businessStartDateArray = businessStartDate.split('/');\n if (businessStartDateArray[1] < 10) {\n businessStartDateArray[1] = '0' + businessStartDateArray[1];\n }\n if (businessStartDateArray[0] < 10) {\n businessStartDateArray[0] = '0' + businessStartDateArray[0];\n }\n var formattedBusinessStartDate = businessStartDateArray[2] + '-' +\n businessStartDateArray[1] +\n '-' + businessStartDateArray[0];\n }\n\n\n var inlineHtml =\n '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-12 heading1\"><h4><span class=\"label label-default col-xs-12\" style=\"background-color: #103D39;\">MAIN DETAILS</span></h4></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">TRADING ENTITY <span class=\"mandatory\">*</span></span><input id=\"tradingEntity\" class=\"form-control tradingEntity\" value=\"' +\n tradingEntity + '\" readonly/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">MAIN CONTACT <span class=\"mandatory\">*</span></span><input id=\"mainContact\" class=\"form-control mainContact\" value=\"' +\n mainContact + '\" readonly/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">MOBILE NUMBER <span class=\"mandatory\">*</span></span><input id=\"contactNumber\" class=\"form-control contactNumber\" value=\"' +\n contactNumber + '\" readonly/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">EMAIL<span class=\"mandatory\">*</span></span><input id=\"email\" class=\"form-control email\" value=\"' +\n email + '\" readonly/></div></div>';\n\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">ABN <span class=\"mandatory\">*</span></span><input id=\"abn\" class=\"form-control abn\" value=\"' +\n abn + '\" readonly/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">DATE LISTED FOR SALE <span class=\"mandatory\">*</span></span><input id=\"dateListedForSale\" class=\"form-control dateListedForSale\" type=\"date\" value=\"' +\n formattedDateListedForSale + '\" readonly/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-12 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">ADDRESS<span class=\"mandatory\">*</span></span><textarea id=\"address\" class=\"form-control address\" style=\"height: 125px\" readonly/>' +\n address + '</textarea></div></div>';\n\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">COMMENCEMENT DATE <span class=\"mandatory\">*</span></span><input id=\"commencementDate\" class=\"form-control commencementDate\" type=\"date\" value=\"' +\n formattedCommencementDate + '\" readonly/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">EXPIRY DATE <span class=\"mandatory\">*</span></span><input id=\"expiryDate\" class=\"form-control expiryDate\" type=\"date\" value=\"' +\n formattedExpiryDate + '\" readonly/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">ULTIMATE EXPIRY DATE <span class=\"mandatory\">*</span></span><input id=\"ultimateExpiryDate\" class=\"form-control ultimateExpiryDate\" type=\"date\" value=\"' +\n formattedUltimateExpiryDate + '\" readonly/></div></div>';\n\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-3 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">UNLIMTED TERM OFFER<span class=\"mandatory\">*</span></span><select id=\"unlimitedTermOffer\" class=\"form-control unlimitedTermOffer\" readonly>';\n if (unlimitedTermOffer == 1) {\n inlineHtml += '<option value=\"1\" selected>Yes</option>';\n } else {\n inlineHtml += '<option value=\"2\">No</option>';\n }\n inlineHtml += '</select></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n\n\n if (!isNullorEmpty(deedOfVariation) || deedOfVariationUploaded == 1) {\n\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">UNLIMTED TERM OFFER<span class=\"mandatory\">*</span></span><select id=\"unlimitedTermOffer\" class=\"form-control unlimitedTermOffer\" readonly>';\n if (unlimitedTermOffer == 1) {\n inlineHtml += '<option value=\"1\" selected>Yes</option>';\n } else {\n inlineHtml += '<option value=\"2\">No</option>';\n }\n inlineHtml += '</select></div></div>';\n if (unlimitedTermOffer == 1) {\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">UNLIMITED TERM FEE ($) <span class=\"mandatory\">*</span></span><input id=\"unlimitedTermFee\" class=\"form-control unlimitedTermFee\" value=\"25000\" readonly/></div></div>';\n } else {\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">UNLIMITED TERM FEE ($) <span class=\"mandatory\">*</span></span><input id=\"unlimitedTermFee\" class=\"form-control unlimitedTermFee\" value=\"0\" readonly/></div></div>';\n }\n\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">RENEWAL TERMS (YEARS) <span class=\"mandatory\">*</span></span><input id=\"renewalTerms\" class=\"form-control renewalTerms\" value=\"' +\n renewalTerms + '\" readonly/></div></div>';\n\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n if (!isNullorEmpty(deedOfVariation)) {\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n var fileObj = file.load({\n id: deedOfVariation\n });\n var fullURL = baseURL + fileObj.url;\n inlineHtml +=\n '<div class=\"col-xs-2\"></div>';\n inlineHtml +=\n '<div class=\"col-xs-8\" style=\"text-align: center;\"><iframe id=\"viewer\" frameborder=\"0\" scrolling=\"no\" width=\"400\" height=\"600\" src=\"' +\n fullURL + '\"></iframe></div>';\n inlineHtml +=\n '<div class=\"col-xs-2\"></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n }\n\n inlineHtml +=\n '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-12 heading1\"><h4><span class=\"label label-default col-xs-12\" style=\"background-color: #103D39;\">PRESALES DETAILS</span></h4></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n if (unlimitedTermOffer == 1) {\n inlineHtml +=\n '<div class=\"col-xs-12 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">TERM ON FRANCHISEE IM <span class=\"mandatory\">*</span></span><input id=\"termOnIM\" class=\"form-control termOnIM\" value=\"Unlimited\" readonly/></div></div>';\n } else {\n inlineHtml +=\n '<div class=\"col-xs-12 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">TERM ON FRANCHISEE IM <span class=\"mandatory\">*</span></span><input id=\"termOnIM\" class=\"form-control termOnIM\" value=\"' +\n termOnIM + '\" /></div></div>';\n }\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">DATE BUSINESS STARTED <span class=\"mandatory\">*</span></span><input id=\"businessStartDate\" class=\"form-control businessStartDate\" type=\"date\" value=\"' +\n formattedBusinessStartDate + '\"/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">TOTAL DAILY RUN TIME <span class=\"mandatory\">*</span></span><input id=\"dailyRunTime\" class=\"form-control dailyRunTime\" value=\"' +\n dailyRunTime + '\"/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">LOW PRICE ($) <span class=\"mandatory\">*</span></span><input id=\"lowPrice\" class=\"form-control lowPrice\" value=\"' +\n lowPrice + '\"/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">HIGH PRICE ($) <span class=\"mandatory\">*</span></span><input id=\"highPrice\" class=\"form-control highPrice\" value=\"' +\n highPrice + '\"/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">SERVICE REVENUE ($) <span class=\"mandatory\">*</span></span><input id=\"serviceRevenue\" class=\"form-control serviceRevenue\" value=\"' +\n serviceRevenue + '\"/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">YEAR<span class=\"mandatory\">*</span></span><input id=\"serviceRevenueYear\" class=\"form-control serviceRevenueYear\" value=\"' +\n serviceRevenueYear + '\"/></div></div>';\n\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">MPEX COMMISSION ($) <span class=\"mandatory\">*</span></span><input id=\"mpexRevenue\" class=\"form-control mpexRevenue\" value=\"' +\n mpexRevenue + '\"/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">YEAR<span class=\"mandatory\">*</span></span><input id=\"mpexRevenueYear\" class=\"form-control mpexRevenueYear\" value=\"' +\n mpexRevenueYear + '\"/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">SENDLE COMMISSION ($) <span class=\"mandatory\">*</span></span><input id=\"sendleRevenue\" class=\"form-control sendleRevenue\" value=\"' +\n sendleRevenue + '\"/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-6 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">YEAR<span class=\"mandatory\">*</span></span><input id=\"sendleRevenueYear\" class=\"form-control sendleRevenueYear\" value=\"' +\n sendleRevenueYear + '\"/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">SALES COMMISSION (%) <span class=\"mandatory\">*</span></span><input id=\"salesCommission\" class=\"form-control salesCommission\" value=\"' +\n salesCommission + '\"/></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">NAB ACCREDITATION<span class=\"mandatory\">*</span></span><select id=\"nabAccreditation\" class=\"form-control nabAccreditation\">';\n if (isNullorEmpty(nabAccreditation) || nabAccreditation == 2) {\n inlineHtml +=\n '<option value=\"1\" >Yes</option><option value=\"2\" selected>No</option>';\n\n } else {\n inlineHtml +=\n '<option value=\"1\" selected>Yes</option><option value=\"2\">No</option>';\n\n }\n\n inlineHtml += '</select></div></div>';\n inlineHtml +=\n '<div class=\"col-xs-4 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">NAB ACCREDITATION FEE ($) <span class=\"mandatory\">*</span></span><input id=\"nabAccreditationFee\" class=\"form-control nabAccreditationFee\" value=\"' +\n nabAccreditationFee + '\"/></div></div>';\n\n inlineHtml += '</div></div>';\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n inlineHtml +=\n '<div class=\"col-xs-12 name_section\"><div class=\"input-group\"><span class=\"input-group-addon\">SALE PRICE<span class=\"mandatory\">*</span></span><input id=\"finalPurchasePrice\" class=\"form-control finalPurchasePrice\" value=\"' +\n finalPurchasePrice + '\"/></div></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n\n if (!isNullorEmpty(territoryMapDoc)) {\n inlineHtml += '<div class=\"form-group container\">';\n inlineHtml += '<div class=\"row\">';\n var fileObj2 = file.load({\n id: territoryMapDoc\n });\n var fullURL = baseURL + fileObj2.url;\n inlineHtml +=\n '<div class=\"col-xs-2\"></div>';\n inlineHtml +=\n '<div class=\"col-xs-8\" style=\"text-align: center;\"><iframe id=\"viewer\" frameborder=\"0\" scrolling=\"no\" width=\"400\" height=\"600\" src=\"' +\n fullURL + '\"></iframe></div>';\n inlineHtml +=\n '<div class=\"col-xs-2\"></div>';\n inlineHtml += '</div>';\n inlineHtml += '</div>';\n }\n }\n\n return inlineHtml\n\n }", "title": "" }, { "docid": "bff41f11c52ca9c6cca04f2aabc0f155", "score": "0.45473957", "text": "function canGold() {\n return !isQuestActive() && getBronze() >= 5 && getGoldToday() < 3;\n}", "title": "" }, { "docid": "f37fb5ff1dd1ed95d76de498c96cb088", "score": "0.4545077", "text": "function validateExpiry()\n {\n var month = document.getElementById(\"monthNo\").value;\n var year = document.getElementById(\"year\").value;\n var output=\"\";\n var validMonth= validateMonth(month);\n var validYear= validateYear(year);\n if(validMonth && validYear)\n {\n output=\"Expiry Date is Valid\";\n }\n else\n {\n output=\"Expiry Date is invalid\";\n }\n console.log(output);\n document.getElementById(\"msg\").innerText= output;\n }", "title": "" }, { "docid": "c452dc9a9dbe34a0f3523b20920d5761", "score": "0.4544573", "text": "get courses(){\n return {\n appetizers: this.appetizers,\n mains: this.mains,\n desserts: this.desserts,\n }\n }", "title": "" }, { "docid": "4bae8173fc1bfde5c99c585c85260c0c", "score": "0.45323646", "text": "function startAdminQuiz() {\n //TODO\n //add a lambda function that returns all the quizzes relative to each admin's courses that they are allowed to edit and review.\n //that should be placed here\n \n \n \n}", "title": "" }, { "docid": "530c9b0c7466cf3488bcb72c5f896e29", "score": "0.45295125", "text": "function beforeSubmit(context) {\r\n var newApproval = context.newRecord;\r\n\r\n // On Create\r\n if(context.type === context.UserEventType.CREATE) {\r\n // Get the change type\r\n var approvalChangeType = newApproval.getValue({fieldId: 'custrecord_cr_change_type'});\r\n \r\n // Get the Policy Approvers\r\n var policyApprovers = getPolicyApprovers(approvalChangeType);\r\n \r\n // Set Policy Approvers as Mandatory Approvers of CR\r\n newApproval.setValue('custrecord_cr_mandated_approvers', policyApprovers);\r\n \r\n // Set all other fields' default\r\n newApproval.setText('custrecord_cr_approval_status', 'Pending Approval');\r\n newApproval.setText('custrecord_cr_completion_status', 'Open'); \r\n }\r\n // On Edit\r\n else if(context.type === context.UserEventType.EDIT){\r\n var oldRecord = context.oldRecord;\r\n\r\n // Mandated Approvers\r\n var mandatedApprovers = oldRecord.getValue({fieldId: 'custrecord_cr_mandated_approvers'});\r\n for(var i in mandatedApprovers) {\r\n mandatedApprovers[i] = parseInt(mandatedApprovers[i]);\r\n }\r\n\r\n // Currently logged In User\r\n var currentUser = runtime.getCurrentUser().id;\r\n\r\n // Approval Status Changes\r\n var previousApprovalStatus = oldRecord.getText({fieldId: 'custrecord_cr_approval_status'});\r\n var currentApprovalStatus = newApproval.getText({fieldId: 'custrecord_cr_approval_status'});\r\n\r\n // Current User is a Mandatory Approver\r\n if(mandatedApprovers.indexOf(currentUser) > -1) {\r\n // Approval Status has changed\r\n if(previousApprovalStatus !== currentApprovalStatus) {\r\n var currentApprovers = [];\r\n var oldApprovers = oldRecord.getValue({fieldId: 'custrecord_cr_approved_by'});\r\n if(oldApprovers != 0) {\r\n // Transform array String to Integer\r\n for(var i in oldApprovers) {\r\n currentApprovers.push(parseInt(oldApprovers[i]));\r\n }\r\n }\r\n\r\n if(currentApprovalStatus == 'Approved') {\r\n // Add Approver to Approved By list\r\n if(currentApprovers.indexOf(currentUser) < 0) {\r\n currentApprovers.push(currentUser);\r\n newApproval.setValue('custrecord_cr_approved_by', currentApprovers);\r\n }\r\n\r\n // Set the Approval Date\r\n newApproval.setValue('custrecord_cr_approved_date', new Date());\r\n\r\n // Check if ALL Mandated Approvers have already approved\r\n if(mandatedApprovers.length !== currentApprovers) {\r\n // Approval not yet complete. Revert to Pending Approval.\r\n newApproval.setText('custrecord_cr_approval_status', 'Pending Approval');\r\n }\r\n }\r\n else if(currentApprovalStatus == 'Rejected') {\r\n // Add Approver to Approved By list\r\n if(currentApprovers.indexOf(currentUser) < 0) {\r\n currentApprovers.push(currentUser);\r\n newApproval.setValue('custrecord_cr_approved_by', currentApprovers);\r\n }\r\n\r\n // Date Rejected\r\n newApproval.setValue('custrecord_cr_approved_date', new Date()); \r\n }\r\n }\r\n }\r\n else {\r\n // Revert to old Approval Status\r\n if(previousApprovalStatus !== currentApprovalStatus && currentApprovalStatus !== 'Pending Approval') {\r\n newApproval.setText('custrecord_cr_approval_status', previousApprovalStatus);\r\n }\r\n }\r\n }\r\n }", "title": "" }, { "docid": "6165ce31764c60699a450c7ad86919bc", "score": "0.45284444", "text": "function handleClaimers(flag, brain) {\n let role = 'claimer';\n let reserveAgain = false;\n if (!(flag.room && flag.room.controller.my)) {\n flag.requiredCreepAmounts[role] = 1;\n } else {\n flag.requiredCreepAmounts[role] = 0;\n }\n return flag.requestCreepIfNeeded(brain, role, {\n assignment: flag,\n workRoom: flag.roomName,\n patternRepetitionLimit: 1\n });\n }", "title": "" }, { "docid": "7f0f08cea2cbfa91096390f1df4da960", "score": "0.45284018", "text": "getDegreeCourse() {\n return this.degree_course;\n }", "title": "" }, { "docid": "9d9f21336fea804a6308e5a8cc980887", "score": "0.4527166", "text": "'click #cb-save'( e, t ) {\n e.preventDefault();\n \n t.$( '#intro-modal' ).modal( 'hide' );\n\n // CHECK THAT THERE'S CONTENT\n\n\n let uname = Students.findOne( { _id: Meteor.userId() },\n { fullName:1 } ).fullName\n , cinfo = Session.get('cinfo'); \n \n let pobj = P.dump();\n if ( pobj.length <= 0 ) {\n Bert.alert(\"You can't save an EMPTY course!!\", 'danger');\n return;\n }\n\n Meteor.setTimeout(function(){\n Meteor.call('saveBuiltCourse', cinfo.cname,\n cinfo.company_id,\n cinfo.creator_type,\n cinfo.credits,\n cinfo.keywords,\n cinfo.passing_percent,\n cinfo.icon,\n pobj,\n uname,\n function( error, result )\n {\n if( error ) {\n alert( 'Error' );\n } else {\n console.log( 'result is ' + result );\n //Session.set(\"data\", result)\n Courses.insert({\n _id: result,\n credits: cinfo.credits,\n name: cinfo.cname,\n passing_percent: cinfo.passing_percent,\n company_id: [cinfo.company_id],\n times_completed: 0,\n icon: cinfo.icon,\n public: false,\n creator_type: cinfo.creator_type,\n creator_id: cinfo.creator_id,\n created_at: new Date(),\n approved: true,\n type: 'course',\n isArchived: false\n });\n }\n });\n \n //-----------------------------------------------\n /*\n * IF THE COURSE CREATOR IS A TEACHER\n * ASSIGN TEACHER A FIXED 2 CREDITS\n *--------------------------------------------- */\n if ( Meteor.user().roles && Meteor.user().roles.teacher ) {\n Students.update({ _id: Meteor.userId() },\n {\n $inc: { current_credits: 2 }\n });\n }\n //-----------------------------------------------\n // SET PAGE COUNTS\n t.page.set( 1 );\n t.total.set( 1 );\n }, 300);\n \n P = null;\n \n Session.set( 'my_id', null );\n Session.set( 'cinfo', null );\n Session.set( 'test_id', null );\n Session.set( 'Scratch', null );\n \n Meteor.setTimeout(function(){\n Bert.alert(\n 'Your Course was saved!',\n 'success',\n 'growl-top-right'\n );\n }, 500);\n \n let roles = Meteor.user() && Meteor.user().roles;\n \n if ( roles && roles.admin )\n {\n FlowRouter.go( 'admin-dashboard', { _id: Meteor.userId() });\n return;\n }\n if ( roles && roles.teacher )\n {\n FlowRouter.go( 'teacher-dashboard', { _id: Meteor.userId() });\n return;\n }\n if ( roles && roles.SuperAdmin )\n {\n FlowRouter.go( 'super-admin-dashboard', { _id: Meteor.userId() });\n return;\n }\n//---------------------------------------------/SAVE COURSE-------\n }", "title": "" }, { "docid": "e2e28643e65cd435d1ec436c070466ff", "score": "0.45233586", "text": "function calculateCOPO(){\n\n const {courseCode, passoutYear} = req.body;\n const FETCH_CO_VALUES_QUERY = `SELECT * FROM final_co where course_code = \"${courseCode}\"`;\n const FETCH_CO_PO_MAPPING_QUERY = `SELECT * FROM final_co where co_po_mapping = \"${courseCode}\"`;\n \n}", "title": "" }, { "docid": "9bb471f9d6b522adbb7e627bc508717a", "score": "0.4523023", "text": "function submitTable() {\n\n if (prerequisiteTable == null) return;\n var selectedCourses = prerequisiteTable.getStringFormat();\n var maxCourseTaking = document.getElementById('max').value || 5;\n\n var page = TIMETABLE_URL;\n var params = { action: \"timeTable\", \n courseCompleted: selectedCourses, \n program: prerequisiteTable.getProgramName(),\n max: maxCourseTaking\n };\n\n SetCookie(\"TimeTableInfo\", params);\n\n window.location.href = TIMETABLE_URL;\n}", "title": "" }, { "docid": "cdacecaaf15df32516c86e4389d8243b", "score": "0.45178777", "text": "compute() {\n const v = {}\n\n // Total Overnight Capital Cost [M$]\n v['Total Capital Cost [M$]'] =\n (this.params['Capex [$]'] * this.params['Scale [tCO2/year]']) / MILLION\n\n // Lead Time Multiplier\n v['Lead Time Multiplier'] = this.leadTimeMult(\n this.params['DAC Section Lead Time [years]']\n )\n\n // Capital Cost(including Lead Time)[M$]\n v['Capital Cost (including Lead Time) [M$]'] =\n v['Total Capital Cost [M$]'] * v['Lead Time Multiplier']\n\n // Capital Recovery[$/tCO2eq]\n v['Capital Recovery [$/tCO2eq]'] =\n (v['Capital Cost (including Lead Time) [M$]'] *\n this.recoveryFactor() *\n MILLION) /\n this.params['Scale [tCO2/year]']\n\n // Fixed O&M [$/tCO2eq]\n v['Fixed O&M [$/tCO2eq]'] = this.params['Fixed O&M Costs [$/tCO2]']\n\n // Variable O&M [$/tCO2eq]\n v['Variable O&M [$/tCO2eq]'] = this.params['Variable O&M Cost [$/tCO2]']\n\n return v\n }", "title": "" }, { "docid": "51c1f4c49194b5400942d982c5b9fa90", "score": "0.45164376", "text": "function groupValidSsRequests() {\n \n var surveySS = SpreadsheetApp.openById(mySurveyCollector);\n var courseSS = SpreadsheetApp.openById(myCoursePlannerDocId);\n var listSS = SpreadsheetApp.openById(myListDocID);\n\n //Get all student data\n var allStudentInfo = listSS.getSheetByName(myStudentDataSheetName).getDataRange().getValues();\n var studentInfo = ArrayLib.filterByValue(allStudentInfo, 7, true);\n Logger.log(studentInfo);\n//Get all request data \n var requests = surveySS.getSheetByName(myRequestsSheetName).getDataRange().getValues();\n \n var myOutput = []; //will store data and write back to spreadsheet;\n var myProblemOutput = [];\n myOutput.push([\"Student ID\",\"Student Email\",\"HRM\",\"Given Name\",\"Last Name\",\"TotalRequests\",\"UniqueRequestsID\",\"ENGCredits\",\"MathCredits\",\"ScienceCredits\",\"HumanitiesCredits\",\"World Language\",\"PE Credits\",\"VPA Credits\",\"CS Credits\",\"Elective Credits\",\"MAC5C\"]); \n myProblemOutput.push([\"Student ID\",\"Student Email\",\"HRM\",\"Given Name\",\"Last Name\",\"TotalRequests\",\"UniqueRequestsID\",\"ENGCredits\",\"MathCredits\",\"ScienceCredits\",\"HumanitiesCredits\",\"World Language\",\"PE Credits\",\"VPA Credits\",\"CS Credits\",\"Elective Credits\",\"MAC5C\",\"Unapproved Classes\",\"Problem - Unapproved\",\"Not enough Credits\"]);\n \n var startRow = 0;\n var requestsObject = createRequestsObject(requests, requestActiveCol); //Puts all requests into an object, Student IDs as keys, requests as arrays under the studentID.\n \n for (var s = startRow; s < studentInfo.length ; s++){\n var thisStudentID = studentInfo[s][0];\n var myDeptsCounts = [0,0,0,0,0,0,0,0,0,0];\n var totalRequest = 0;\n var myCourses = [];\n var unapprovedCourses = [];\n var problem_Unapproved = false;\n var problem_RequestNumber = false;\n if (requestsObject.hasOwnProperty(thisStudentID)){ //Students has made requests\n var hasMAC5C = false;\n var myRequests = requestsObject[thisStudentID];\n for (var r=0; r < myRequests.length; r++){ //loop through each of this student's requests\n if(myRequests[r][recActiveCol] == true){ //if this request has been approved\n myDeptsCounts[myRequests[r][deptCol]]++;\n if(myRequests[r][courseReqCol] == 'MAC5C') { //if MAC5C is chosen, add MAC51 and MAC52\n myCourses.push('MAC51');\n myCourses.push('MAC52');\n myDeptsCounts[myRequests[r][deptCol]]++; // add an extra credit to Math column.\n hasMAC5C = true;\n } else { //if it is any course other than MAC5C, add the course to the request list.\n myCourses.push(myRequests[r][courseReqCol]);\n }\n } else {\n problem_Unapproved = true;\n unapprovedCourses.push(myRequests[r][courseReqCol]);\n }\n }\n totalRequest = myCourses.length;\n }\n if (totalRequest != 7) problem_RequestNumber = true;\n var myURID = \"\";\n myCourses.sort();\n for (var c=0; c < myCourses.length; c++) { myURID += myCourses[c]+\",\" }\n \n \n if (problem_RequestNumber || problem_Unapproved){ //if Problems, write to problem sheet\n myProblemOutput.push([studentInfo[s][0],studentInfo[s][1],studentInfo[s][2],studentInfo[s][3],studentInfo[s][4],totalRequest,myURID,myDeptsCounts[1],myDeptsCounts[2],myDeptsCounts[3],myDeptsCounts[4],myDeptsCounts[5],myDeptsCounts[6],myDeptsCounts[7],myDeptsCounts[8],myDeptsCounts[9], hasMAC5C, unapprovedCourses.toString(),problem_Unapproved, problem_RequestNumber]);\n } else { //if no problems, write to main output sheet.\n myOutput.push([studentInfo[s][0],studentInfo[s][1],studentInfo[s][2],studentInfo[s][3],studentInfo[s][4],totalRequest,myURID,myDeptsCounts[1],myDeptsCounts[2],myDeptsCounts[3],myDeptsCounts[4],myDeptsCounts[5],myDeptsCounts[6],myDeptsCounts[7],myDeptsCounts[8],myDeptsCounts[9], hasMAC5C]);\n }\n }\n SpreadsheetApp.getActive().getSheetByName('Valid Requests').clear().getRange(1, 1, myOutput.length, myOutput[0].length).setValues(myOutput);\n SpreadsheetApp.getActive().getSheetByName('Problem Requests').clear().getRange(1, 1, myProblemOutput.length, myProblemOutput[0].length).setValues(myProblemOutput);\n}", "title": "" } ]
a11e72d52a86a879c294ce3d1f82dfc5
Makes the request to the server to delete a user.
[ { "docid": "d0126bb5135a8c34042f2d04fac41b5c", "score": "0.0", "text": "handleDeleteUser(result, username) {\n if (result.value) {\n // Assumes that the user has confirmed the action to delete the account.\n deleteUser({ username: username })\n .then(() => generateAdminActionSuccessDialog(USER, DELETE))\n .catch(() => generateSomethingWentWrongDialog())\n }\n }", "title": "" } ]
[ { "docid": "0a2687da0557355cbb4e03854e714e84", "score": "0.8214467", "text": "static deleteUser() {\n\t\tAjaxModule.doDelete({\n\t\t\tpath: `${HOST}/api/user`,\n\t\t});\n\t}", "title": "" }, { "docid": "294da3421c04488c55c3956a38caffae", "score": "0.8141127", "text": "function deleteUser () {\n\n\t/* We call the destroy() method to intitiate the API DELETE request */\n\tuser.destroy(function (error,response) {\n\t if (error) { \n\t\t\t // Error - there was a problem deleting the entity\n document.getElementById('result-text').innerHTML\n = \"Error! Unable to delete your user. \"\n + \"Check that the 'uuid' of the user you tried to delete is correct.\"\n + \"<br/><br/>\"\n + \"Error message:\" + JSON.stringify(error);\t\t \n\t\t\t} else { \n\t\t\t // Success - the entity was successfully deleted\n\t\t\t document.getElementById('result-text').innerHTML\n = \"Success! The user has been deleted.\"\n\t\t}\n\t});\t \n}", "title": "" }, { "docid": "66beffde443f735217bcfb9d423d9596", "score": "0.7948836", "text": "async delete(req, res) {\n try {\n const {userId} = req.params\n const user = await User.findByPk(userId)\n await user.destroy()\n res.send(user)\n } catch (err) {\n res.status(400).send({\n error: 'Error deleting User'\n })\n }\n }", "title": "" }, { "docid": "0ffa066ec1f4f25e7bcb7fdb3fd69eb8", "score": "0.7849003", "text": "async delete({user}, res) {\n await User.remove(user);\n res.sendStatus(202);\n }", "title": "" }, { "docid": "ee14b7a15f482ff05e866fc94a17b4d5", "score": "0.77963287", "text": "async function _delete(request) {\n try {\n const user = new User()\n user.phone = request.queryString().phone\n await datastore.delete('users', user.phone)\n return new Server.Response({\n statusCode: 200\n })\n } catch(err) {\n console.dir(err)\n return new Server.Response({\n statusCode: 500,\n payload: {\n msg: `Failed to delete user`,\n err: `${err.name} - ${err.message}`,\n }\n })\n }\n}", "title": "" }, { "docid": "b6fc27810140bdae69032f806e13399c", "score": "0.7734254", "text": "function userDelete(req, res){\n User\n .findById(req.params.id)\n .exec()\n .then(user => user.remove())\n .then(() => res.redirect('/users'));\n}", "title": "" }, { "docid": "2a5ff4004fafcd5736a443778621017f", "score": "0.7733274", "text": "function deleteUser(req,res) {\n var userId = req.params.userId;\n\n userModel\n .deleteUser(userId)\n //responds with some stats\n .then(function (stats) {\n\n res.sendStatus(200);\n },\n function (error) {\n res.statusCode(404).send(error);\n });\n\n\n }", "title": "" }, { "docid": "7397cbb8fe00c038ec1543e9d54e0294", "score": "0.76958054", "text": "function deleteUser(object)\n{\n\t// Create our XMLHttpRequest variable\n\tvar request = new XMLHttpRequest();\n\n\t// Create the deletion url for user\n\tvar url = \"/api/users/\" + object.id;\n\t\n\t// Open a socket to the url\n\trequest.open('DELETE', url);\n\t\n\t// Handle on load\n\trequest.onload = function() \n\t{\n\t\tif (request.status === 200 || request.status === 201 || request.status === 204)\n\t\t{\n\t\t\talert(\"Deletion Successful!\");\n\t\t\tupdateTables();\n\t\t}\n\t\telse\n\t\t{\n\t\t\talert(`Error ${request.status}: ${request.statusText}`);\n\t\t}\n\t};\n\t\n\t// Handle on errors\t\n\trequest.error = function() \n\t{\n\t\talert(\"Request Failed!\");\n\t};\n\n\trequest.send();\t\n\t\n}", "title": "" }, { "docid": "74dda2eca90951a3282ca2bc7faea028", "score": "0.7685339", "text": "function deleteUser(req, res){\n userModel.deleteUser(req.params.id)\n .then(\n function (doc) {\n res.json(doc);\n },\n function ( err ) {\n res.status(400).send(err);\n }\n );\n }", "title": "" }, { "docid": "a3ac1fdf007c286fb39cc784cab44483", "score": "0.7660741", "text": "delete({ user }, res) {\n\t\tlogger.info('UPDATE a user by id')\n\t\tusers.splice(users.indexOf(user), 1)\n\t\tres.sendStatus(204)\n\t}", "title": "" }, { "docid": "92335a85a2873682f4da7b92b88b5848", "score": "0.7652478", "text": "function deleteUser(app) {\n return function(request, response) {\n const id = request.params.id;\n if (typeof id === 'undefined') {\n response.sendStatus(BAD_REQUEST);\n }\n else {\n request.app.locals.model.users.deleteUser(id).\n then(function() { \n console.log(\"STATUS:- Deleted user \" + request.params.id);\n response.end();\n }).\n catch((err) => {\n console.error(err);\n response.sendStatus(NOT_FOUND);\n });\n }\n };\n}", "title": "" }, { "docid": "fb60d10ea1b26805f1d60b051e0c38dd", "score": "0.76435494", "text": "function DeleteUser(req, res, next) {\n const { knex } = req.app.locals;\n const { id } = req.params;\n knex('user')\n .where('user_id', id)\n .del()\n .then(response => {\n if (response) {\n res.status(204).json(`User ${id} has been deleted.`);\n }\n else {\n res.status(400).json(`User ${id} cannot be found.`)\n }\n })\n .catch(error => res.status(500).json(error));\n}", "title": "" }, { "docid": "6e07f57aa5573a31f1b55e0eb72d7a33", "score": "0.7623583", "text": "static async deleteUser(req, res) {\n const { id } = req.params;\n\n try {\n await User.findOneAndDelete({ _id: id });\n res.status(200).json({\n message: \"The user has been deleted\"\n });\n } catch (e) {\n res.status(500).json({ message: \"an internal error has been ocurred\" });\n }\n }", "title": "" }, { "docid": "9c2172a653e8114394b33dabac527d42", "score": "0.75848204", "text": "function deleteUser(id) {\n var xhttp;\n xhttp = new XMLHttpRequest();\n xhttp.onreadystatechange = function() {\n if (this.readyState == 4 && this.status == 200) {\n getUsers();\n }\n };\n\n xhttp.open(\"DELETE\", \"http://localhost:8080/api/user/userRemoval/\" + id, true);\n xhttp.setRequestHeader(\"Content-type\", \"application/json\");\n xhttp.send();\n}", "title": "" }, { "docid": "6e43630eff2aa01bc597baf8973c7e93", "score": "0.75748044", "text": "function deleteUser(req, res) {\n var userId = req.params.userId;\n userModel\n .deleteUser(userId)\n .then(\n function (user) {\n res.json(user);\n },\n function (error) {\n res.status(error.statusCode).send(\"Could not delete the user on the server\");\n })\n\n\n /* var id = req.params.userId;\n for (var i in users) {\n if (users[i]._id === id) {\n users.splice(i, 1);\n res.sendStatus(200);\n return;\n }\n }\n res.status(404).send(\"Unable to remove user with ID: \" + id);*/\n }", "title": "" }, { "docid": "9e1996fef07c8703abc3bc13cffb91f5", "score": "0.75561994", "text": "async deleteUser (){\n let payload = new FormData();\n payload.append(\"token\", Auth.getToken());\n const request = await fetch('https://tddd27-nikha864-backend.herokuapp.com/delete_user', {\n method: 'post',\n body: payload\n });\n\n let response = await request.json();\n if(response.success){\n Auth.logOut();\n browserHistory.push('/');\n }\n }", "title": "" }, { "docid": "48616043379eeb83f133cdbbae1b46bb", "score": "0.7541068", "text": "function deleteUser(id){\n\n}", "title": "" }, { "docid": "419978600c77eefdfefc7c006a1dbc73", "score": "0.75246847", "text": "doDelete(req, res){\r\n if (req.body._id) {\r\n User.findByIdAndRemove(\r\n req.body._id,\r\n function (err, user) {\r\n if(err){\r\n console.log(err);\r\n return res.redirect('/user?error=deleting');\r\n }\r\n console.log(\"User deleted:\", user);\r\n clearSession(req.session, function () {\r\n res.redirect('/');\r\n });\r\n }\r\n );\r\n }\r\n }", "title": "" }, { "docid": "178065dff6fb78b1288e07c156998f7f", "score": "0.74939173", "text": "async function deleteUser() {\n const inputId = document.getElementById(\"inputId\").value;\n const status = await makeRequest(\n `http://localhost:3000/users/${inputId}`,\n \"DELETE\"\n );\n console.log(status);\n}", "title": "" }, { "docid": "eb2bcda15f3858cbaa338c2fc8853e3f", "score": "0.7474974", "text": "deleteUser(req, res) {\n try {\n const id = req.params.id;\n User.destroy({\n where: { id: id },\n }).then((num) => {\n if (num == 1)\n return res.status(200).send(\"User was deleted succesfully\");\n return res\n .status(404)\n .send(\n `Cannot deleted User with id=${id}. Maybe User was not found !`\n );\n });\n } catch (error) {\n res.status(500).send(error);\n }\n }", "title": "" }, { "docid": "9aa349208aef884258828be401b66797", "score": "0.7460329", "text": "function deleteUser(userId) {\n let request = new XMLHttpRequest();\n request.open(\"DELETE\", \"http://localhost:8080/users/\" + userId);\n request.send();\n request.onload = () => {\n if (request.status === 200) {\n console.log('user with id ' + userId + 'deleted successfully');\n deleteUserFromHtmlTable(userId);\n } else {\n console.log(\"error\");\n }\n };\n}", "title": "" }, { "docid": "1fc87849f0004c9173ab4da174acaee7", "score": "0.74569225", "text": "function deleteUser (req, res) {\n\n let { user_id } = req.params;\n let user;\n let initialUserL = userDB.length;\n userDB = userDB.filter(function (user) {\n return user.user_id != user_id;\n })\n if (initialUserL == userDB.length) {\n return res.status(404).json({\n status: \"failure\",\n message: \"user not found\"\n })\n }\n\n res.status(200).json({\n status: \"success\",\n user: \"User Deleted\"\n })\n}", "title": "" }, { "docid": "91de0623a5f8c80e42fd6e7d51969a0c", "score": "0.74465007", "text": "function deleteUser(email){\n db.user.delete(email);\n console.log('User deleted succesfully');\n}", "title": "" }, { "docid": "374afa315fbf816407bbd5c1598ff26b", "score": "0.7439655", "text": "function destroy(req, res) {\n User.remove({\n _id: req.params.user_id\n }, function(err, user) {\n if (err) res.send(err);\n\n res.json({ message: 'Successfully deleted' });\n });\n}", "title": "" }, { "docid": "d89ceb684944bf6615fc5e2e3bb186ef", "score": "0.7431304", "text": "function deleteUser() {\n\n let userId = document.getElementById(\"deleteUserId\").value\n userFacade.deleteUser(userId)\n\n}", "title": "" }, { "docid": "abe9b6a595baffdeaa9d333d3b76e40c", "score": "0.7428852", "text": "function deleteUser(request, workflow, user)\n{\n RiakDBAccessor.remove('users', user._id, function(error)\n {\n if (error)\n return workflow.emit('exception', error);\n\n workflow.emit('response');\n });\n}", "title": "" }, { "docid": "67fa25af4a764a410fe15c7b9c2519e2", "score": "0.74221325", "text": "function deleteUser(){\n UserService.deleteUser(vm.user._id)\n .success(function(){\n $location.url(\"/login\");\n })\n .error(function(e){\n console.log(e);\n });\n\n }", "title": "" }, { "docid": "43e9ec81e84f9a0f75f4f24cd03446d2", "score": "0.74205214", "text": "function deleteUser() {\n let userToDelete = document.getElementById('userID');\n\n const xhr = new XMLHttpRequest();\n xhr.open(\"DELETE\", \"/api/users/\" + userToDelete.innerText, true)\n xhr.onload = function() {\n if (xhr.status === 204) {\n alert('User Deleted');\n getUsers(1);\n } else {\n alert('Error: ' + xhr.status);\n }\n\n }\n xhr.send()\n}", "title": "" }, { "docid": "9574cfe26025d992b7649d7a7fd88da9", "score": "0.74184364", "text": "function deleteUser(req, res) {\n var userId = req.user.sub;\n if (req.params._id !== userId) {\n // can only delete own account\n return res.status(401).send('You can only delete your own account');\n }\n \n userService.delete(userId)\n .then(function () {\n res.sendStatus(200);\n })\n .catch(function (err) {\n res.status(400).send(err);\n });\n}", "title": "" }, { "docid": "38ce785740a9d4adc5541903c9ed5e4f", "score": "0.7409367", "text": "function deleteUser(req, res) {\n var userId = req.params.userId;\n\n userModel\n .deleteUser(userId)\n .then(function (response) {\n if (response.result.n === 0) {\n res.sendStatus(404);\n } else {\n res.sendStatus(200);\n }\n }, function(err) {\n console.log(err);\n res.sendStatus(404);\n });\n}", "title": "" }, { "docid": "276599018c0cee17787ad5f0ce1bb3cd", "score": "0.74059325", "text": "async deleteUser(userId = null) {\n return this._apiRequest(`/api/v1/users/${userId || ''}`, 'DELETE');\n }", "title": "" }, { "docid": "bc82ff57fbdfe74e05b74c55e01cfd3b", "score": "0.7398394", "text": "delete(userId) {\n return Api().delete(`users/${userId}`);\n }", "title": "" }, { "docid": "409150fc061d8d8c5df6173cabbe80fe", "score": "0.73811096", "text": "async delete ({ request, auth, response }) {\n const userData = await auth.getUser() \n console.log(auth.getUser()) \n await userData.delete()\n return \n }", "title": "" }, { "docid": "96909b5bb0e7b791cf4fd7a8ce781fea", "score": "0.7377138", "text": "function _delete(req, res) {\n\n User.findByIdAndRemove(req.params._id, (err,result) => {\n if(err)\n {\n return res.json({\n code: constant.ERROR,\n message: message.USER.USER_NOT_FOUND\n });\n }\n return res.json({\n code: constant.SUCCESS,\n message: message.USER.USER_DELETED_SUCCESS,\n result: result\n });\n })\n}", "title": "" }, { "docid": "cbe4816ad2828571a4cf523e21792043", "score": "0.73706543", "text": "function deleteUser(id) {\n\t\t\t\treturn User.delete({id:id}).$promise.then(function(success) {\n\t\t\t\t\tconsole.log(success);\n\t\t\t\t}, function(error) {\n\t\t\t\t\tconsole.log(error);\n\t\t\t\t});\n\t\t\t}", "title": "" }, { "docid": "2da35ec9f137f3259277364b75c5c570", "score": "0.73626435", "text": "static async deleteUser(req, res){\n try {\n const {id} = req.params\n const deletedUser = await User.findByIdAndDelete(id);\n if(!deletedUser){\n return res.status(500).json({message: \"can NOT delete user at the moment\"});\n }\n res.status(200).json({message: \"User successfully deleted\"});\n } catch (error) {\n console.log(error);\n }\n }", "title": "" }, { "docid": "bf6262739ffce9a8e6ea550853eecc60", "score": "0.73618007", "text": "function deleteUser(req, res) {\n console.log(req.params._id);\n db.User.findOneAndRemove({_id: req.params._id}, function(err, deletedUser) {\n res.json(deletedUser);\n });\n}", "title": "" }, { "docid": "7a45fe3d2b6cd8e4408b07f759b3e63b", "score": "0.73422563", "text": "function deleteUser(req, res, next) {\n User.findOne({_id: req.params.id}).exec((err, user) => {\n User.remove({_id: req.params.id},(err, object)=>{\n if(err){\n res.status(500).json(err);\n }else{\n res.status(200).json(object);\n }\n });\n });\n\n}", "title": "" }, { "docid": "279407938755726b6fb9db016f229684", "score": "0.7317087", "text": "function deleteUser(request, response, next){\n var responseData = {};\n\n //Check for a logged in user\n if(request.session.user){\n var isAllowed = false;\n\n //Check permissions\n for(index in request.session.user['acl']){\n if(request.session.user['acl'][index] == 'DELETE_USERS'){\n isAllowed = true;\n }\n }\n\n if(isAllowed){\n var deleteUser = request.body;\n var existingUser;\n\n //Find user\n for(index in shared.get('users')){\n if(shared.get('users')[index]['id'] == deleteUser['id']){\n existingUser = shared.get('users')[index];\n }\n }\n\n //If the user exists, then delete and output to file\n if(existingUser && existingUser['id'] == deleteUser['id']){\n delete shared.get('users')[existingUser['username']];\n\n fs.writeFileSync('models/users.json', JSON.stringify(shared.get('users')));\n\n responseData['id'] = deleteUser['id'];\n responseData['success'] = true;\n } else {\n responseData['success'] = false;\n responseData['err'] = 'User does not exist';\n }\n } else {\n responseData['sucess'] = false;\n responseData['err'] = 'You do not have the necessary permissions';\n }\n } else {\n responseData['success'] = false;\n responseData['err'] = 'You are not logged in';\n }\n\n response.send(responseData);\n}", "title": "" }, { "docid": "965ea5faea8808e8f800b3efb2434c8c", "score": "0.73139846", "text": "function deleteUser(user_id) { \r\n Users.destroy({\r\n where: { id: user_id }\r\n })\r\n .then(num => {\r\n if (num == 1) {\r\n res.send({\r\n message: \"User was deleted successfully!\"\r\n });\r\n } else {\r\n res.send({\r\n message: `Cannot delete user with id=${id}. Maybe user was not found!`\r\n });\r\n }\r\n })\r\n .catch(err => {\r\n res.status(500).send({\r\n message: \"Could not delete user with id=\" + id\r\n });\r\n });\r\n }", "title": "" }, { "docid": "9a8b636b6c7988201fd9935cc91cd003", "score": "0.73043436", "text": "destroy(req, res) {\n return Users\n .findById(req.params.userId)\n .then(user => {\n if (!user) {\n return res.status(400).send({\n message: 'User Not Found',\n });\n }\n return user\n .destroy()\n .then(() => res.status(204).send())\n .catch((error) => res.status(400).send(error));\n })\n .catch((error) => res.status(400).send(error));\n }", "title": "" }, { "docid": "f3d2fccc27f11bf6c1e72c688fff7600", "score": "0.72861785", "text": "async function delete_ ({id}) {\n if (id === this.session.get('user_id')) {\n throw invalidParameters('a user cannot delete itself')\n }\n\n await this.deleteUser(id)\n}", "title": "" }, { "docid": "3ee793c258ab482b4653c7b4100e34a9", "score": "0.72677064", "text": "static async delete(req, res){\n let status = 200;\n let body = {};\n\n try { \n await User.findOneAndRemove({_id: req.params.id});\n body = {\n 'message': 'User deleted'\n };\n } catch (error) {\n status = 500;\n body = {'message': error.message};\n }\n return res.status(status).json(body);\n }", "title": "" }, { "docid": "817131b91920648a955613b153cd400f", "score": "0.7257064", "text": "function deleteUserById(req, res) {\n const token = getToken(req.headers);\n if (token) {\n let decoded = jwt.decode(token, config.secret);\n const promise = User.findByIdAndRemove(req.params.id, {\n _id: req.params.id\n });\n promise\n .then(user =>\n res.status(200).send({\n success: true,\n msg: \"User was successfully deleted\",\n deleted_user: user\n })\n )\n .catch(err =>\n res.status(401).send({\n success: false,\n msg: \"Authentication failed. User not found.\",\n err: err\n })\n );\n } else {\n res.status(401).send({\n success: false,\n msg: \"No token provided.\"\n });\n }\n }", "title": "" }, { "docid": "0f0db0628ead530d3b9f284d35ef6f64", "score": "0.7252681", "text": "function deleteUser() {\n\n\n let id = document.getElementById(\"userIDtoDelete\").value\n userFacade.deleteUser(id)\n .then(data => (JSON.stringify(data)))\n .catch(err => {\n if (err.status) {\n err.fullError.then(e => document.getElementById(\"errorDelete\").innerText = e.msg)\n }\n else { console.log(\"Network error\"); }\n });\n\n}", "title": "" }, { "docid": "a08f35dc359e65ad6953aa0646a4b709", "score": "0.7237662", "text": "delete (params) {\n return vue_seed().delete(`/v1/user/${params.id}`)\n }", "title": "" }, { "docid": "98486cfc33d9b69da17ac0b15c73f176", "score": "0.7236873", "text": "function deleteUserById(req,res){\n try{\n const {idUser} = req.params;\n const users = dbManager.User.findAll();\n\n const user = dbManager.User.destroy({\n where:{\n idUser: idUser\n }\n });\n res.json(users);\n\n }catch(error){\n // Print error on console\n console.log(error);\n // Send error message as a response \n res.status(500).send({\n message: \"Some error occurred\"\n });\n }\n}", "title": "" }, { "docid": "3504c45ae51659f867f28a6edf50bccf", "score": "0.7233188", "text": "function deleteUser(id) {\n return db('user').where({id}).del();\n}", "title": "" }, { "docid": "e8ce20912849bfb48d3522f8596a0fa2", "score": "0.72298527", "text": "function delUser () {\n let user = document.getElementById(\"DeleteUser\").value\n deleteUser(user);\n}", "title": "" }, { "docid": "db4e5b63db0b607f818d13951711e459", "score": "0.7223312", "text": "async deleteUser(req,res) {\n console.log(req.params[\"id\"]);\n let id = req.params[\"id\"];\n let result = await UserService.deleteUser(id);\n res.json(result);\n }", "title": "" }, { "docid": "70c4cc18dab46fa3e7be389a1f415adf", "score": "0.7219862", "text": "function deleteUser(userId) {\n var url = \"/api/petshelter/user/\" + userId;\n return $http.delete(url);\n }", "title": "" }, { "docid": "562b5188fe7010061668ccfd2a9a464a", "score": "0.72186685", "text": "handleDelete() {\n console.log('Deleting user');\n fetch('/user/'+this.props.userData.id, {\n method: 'DELETE',\n headers: {\n 'Content-Type': 'application/json',\n 'Authorization': this.props.userData.token\n }\n }).then(response => {\n this.props.logOut()\n }).catch(error => console.log(error))\n }", "title": "" }, { "docid": "9644188c0662e3dbd6c22b724db6c5ad", "score": "0.7218439", "text": "function dbDeleteUser(id) {\r\n selectedUsers.delete(id);\r\n\r\n var deleteDict = {\r\n \"id\": id\r\n };\r\n\r\n var xhr = new XMLHttpRequest();\r\n xhr.open(\"POST\", \"/admin/users/delete\", true);\r\n xhr.setRequestHeader(\"Content-Type\", \"application/json\");\r\n // TODO: also set xhr.timeout and xhr.ontimeout?\r\n xhr.responseType = \"json\";\r\n xhr.onload = function () {\r\n if (xhr.status == 200) {\r\n showAlert(\"info\", \"\", \"Successfully deleted user\")\r\n } else {\r\n showAlert(\"danger\", \"Error\", \"Failed to delete user (Error \" + xhr.status + \")\");\r\n }\r\n dbUpdateUsers();\r\n }\r\n xhr.send(JSON.stringify(deleteDict));\r\n }", "title": "" }, { "docid": "5b1626d45bbae0a7b6fd4efa9b97881a", "score": "0.72183216", "text": "deleteUser({ params }, res) {\n User.findOneAndDelete({ _id: params.id, })\n .then(result => {\n if (!result) {\n res.status(400).json({ message: 'No user found' });\n return;\n }\n res.json(result);\n })\n .catch(err => res.status(400).json(err));\n }", "title": "" }, { "docid": "2e8ecce3dd8e212d005c3fddb5895814", "score": "0.721358", "text": "async function handleDeleteUser(req, res) {\n\n const { username } = req.params;\n User.findOneAndDelete({ username: username }, (err, result) => {\n if (err) return res.send(500, err)\n res.status(202).send('deleted');\n });\n}", "title": "" }, { "docid": "381da2d823d8b4fb69f8f5c6d29c3cb2", "score": "0.7213151", "text": "function deleteUser(id) {\n var deferred = $q.defer();\n $http.delete(REST_SERVICE_URI+id)\n .then(\n function (response) {\n deferred.resolve(response.data);\n },\n function(errResponse){\n console.error('Error while deleting User');\n deferred.reject(errResponse);\n }\n );\n return deferred.promise;\n }", "title": "" }, { "docid": "dfb73ef7f1a56175c8ab1b3e72e26c9c", "score": "0.7209384", "text": "async deleteUser({ params }, res) {\n const deletedUser = await User.findByIdAndDelete({ _id: params.id });\n if (!deletedUser) {\n res.status(404).json({ message: 'User Not Found !!' });\n }\n res.json({ message: \"User has been deleted\" });\n }", "title": "" }, { "docid": "28fd878af394fe11d08de113091fbded", "score": "0.7208616", "text": "function deleteUser() {\n let username = $(\"#user\").text();\n $.ajax({\n url: \"/api/user/delete/\" + username,\n method: \"DELETE\",\n success: function (results) {\n alert(results);\n $(window).attr(\"location\", \"./index.html\");\n },\n error: function (XHR, status, error) {\n alert(XHR.responseText);\n },\n });\n}", "title": "" }, { "docid": "4ef126b41a096bb57718e344c1c57d2b", "score": "0.7205192", "text": "async destroy({ params, response }) {\n\t\tconst { id } = params;\n\t\tconst user = await User.findOrFail(id);\n\t\tconst result = await user.delete();\n\t\tif (!result) {\n\t\t\treturn response\n\t\t\t\t.status(400)\n\t\t\t\t.send(\n\t\t\t\t\terrorPayload(\n\t\t\t\t\t\terrors.RESOURCE_DELETED_ERROR,\n\t\t\t\t\t\tantl('error.resource.resourceDeletedError'),\n\t\t\t\t\t),\n\t\t\t\t);\n\t\t}\n\t\treturn response.status(200).send({ success: true });\n\t}", "title": "" }, { "docid": "d4c4f704e821e79ef5f88ef041fb4cd8", "score": "0.71944994", "text": "static deleteUser(id) {\n return axios.delete(`${url}${id}`)\n }", "title": "" }, { "docid": "fe5f98fce9ae640df45f71910a2ac317", "score": "0.7181113", "text": "destroy(req,res){\n modelo.usuarios.destroy({ \n where: {userId: req.params.id\n } \n }).then(function(user) {\n res.status(200).json(\n {\n sucess: true,\n messages: 'Usuario eliminado',\n errors: null,\n data: [user]\n }\n );\n }).catch(function(error){\n res.status(401).json(\n {\n sucess: true,\n messages: 'Error al eliminar',\n errors: 401,\n data: []\n }\n );\n });\n }", "title": "" }, { "docid": "4515265ba86f00d2e04fc901c9844a4f", "score": "0.71800715", "text": "deleteUser(email) {\n // let accessCode = this.generateAccessToken();\n let user = this.getUserBy(email);\n let userId = user[0]['id'];\n let url = `https://developers.stage.redhat.com/auth/admin/realms/rhd/users/${userId}`;\n try {\n wait(request('DELETE', url, {headers: {\"Authorization\": `Bearer ${this.accessCode}`}, agent: false}));\n console.log(`Deleted RHD site user with email: ${email}`);\n } catch (e) {\n return new Error(`failed to delete user with email: ${email}. Error was ${e}`)\n }\n }", "title": "" }, { "docid": "fef591ddaf509a433673d2bc02551041", "score": "0.717821", "text": "static async deleteUser(id){\n await axios.delete(`http://localhost:3001/users/${id}`);\n console.log(\"This account has been successfully deleted\");\n }", "title": "" }, { "docid": "5aa731c0ebe0d2c0019da62d44bf9ad4", "score": "0.7168608", "text": "function deleteUser(x){\n\tvar user = new Object();\n\tuser.id = x;\n\tvar xhttp = new XMLHttpRequest();\n\txhttp.onreadystatechange = function(){\n\t\tif((this.readyState == 4)&&(this.status == 200)){\n\t\t\tvar mes=JSON.parse(this.responseText);\n\t\t\tconsole.log(mes);\n\t\t\tdisplayDetails();\n\t\t}\n\t};\n\txhttp.open('DELETE','http://192.168.1.2:3000/removeUser',true);\n\txhttp.setRequestHeader('Content-Type','application/json');\n\txhttp.send(JSON.stringify(user));\n}", "title": "" }, { "docid": "5421edc9e7d4a31ce793d1976373adfb", "score": "0.716551", "text": "function deleteUser(req, res) {\n // Delete document in database.\n var dbDeleteUser = new Promise(function(resolve, reject) {\n dbQuerier.deleteDoc(\"user\", req.params.id, resolve, reject)\n })\n \n // If document deleted, send success message.\n dbDeleteUser.then(function() {\n res.json(\"Successfully deleted user.\")\n })\n // If document not deleted, send error message.\n .catch(function(err) {\n console.log(err.message)\n res.json(\"Failed to delete user.\")\n })\n}", "title": "" }, { "docid": "233d67ba4cb93cd1053edc190a039b1b", "score": "0.7148852", "text": "async delete(username) {\n try {\n /* Get user to update */\n const userToDelete = await getUserByUsername(username);\n if (userToDelete === null) {\n return {\n statusCode: HTTP.NotFound,\n data: \"User Not Found\",\n };\n }\n\n await userToDelete.destroy();\n return { statusCode: HTTP.OK, data: \"User deleted\" };\n } catch (err) {\n debug(\"[User|Delete]: \", err);\n return { statusCode: HTTP.InternalServerError, data: err };\n }\n }", "title": "" }, { "docid": "0ceda4cfa55078e357e69acc7a45e7f8", "score": "0.7145324", "text": "deleteUser({ params }, res) {\n User.findOneAndDelete({ _id: params.id })\n .then(dbUserData => {\n if (!dbUserData) {\n res.status(404).json({ message: 'No User found with this id!' });\n return;\n }\n res.json(dbUserData);\n })\n .catch(err => res.status(400).json(err));\n }", "title": "" }, { "docid": "230b739aa5437854647ceda18a917c90", "score": "0.7136905", "text": "deleteUser(request, response) {\n return __awaiter(this, void 0, void 0, function* () {\n yield this.userService.delete(request.user);\n });\n }", "title": "" }, { "docid": "6ae43e1bfdc4b7a42c4ce5639cbff914", "score": "0.7132214", "text": "function deleteById(req, res)\n{\n User.remove({_id: req.params.userId}, function(err,user){\n if(err){\n res.send(err);\n }\n res.redirect('http://localhost:8080');\n });\n}", "title": "" }, { "docid": "a04b7a6cdd329b74232c4004a6692ddc", "score": "0.71078235", "text": "removeUser(id) {\n return fetch(`${remoteURL}/users/${id}`, { method: \"DELETE\" }).then(\n response => response.json()\n );\n }", "title": "" }, { "docid": "57f1b468c9fe62ce183ae0e48dc14e14", "score": "0.7100526", "text": "async deleteUser(criteria) {\n const { User } = Schemas.getInstance().models;\n try {\n await User.destroy(criteria);\n return { status: 'success' };\n } catch(error) {\n Logger.LOG_ERROR('UserModel', { status: 'Error occurred while deleting user', error });\n return { status: 'error', error }\n }\n }", "title": "" }, { "docid": "710b268048457fd1d1c13ddb296ac706", "score": "0.70914036", "text": "function DeleteUser(id) {\n ajaxCall(\"DELETE\", \"../api/Users/\" + id, \"\", deleteUserSuccess, deleteUserError);\n}", "title": "" }, { "docid": "72ebb479d40fb5b9b9737ee329882a6a", "score": "0.7090972", "text": "function _delete(id) {\n const requestOptions = {\n method: \"DELETE\",\n headers: authHeader()\n };\n\n return fetch(`${userUrl}/${id}`, requestOptions).then(handleResponse);\n}", "title": "" }, { "docid": "a566de63e40c9dfc82f3d05fc4f2fd06", "score": "0.70813304", "text": "deleteUser(id){\n const { endPoint, userDelete } = env.api;\n\n fetch(`${endPoint}${userDelete}/${id}`, {\n method: 'DELETE',\n headers: {'Content-Type': 'application/json'}\n })\n .then(response => response.json())\n .then(result => {\n // Actualizando la lista de usuarios\n this.loadUsers();\n })\n .catch(console.log);\n }", "title": "" }, { "docid": "274badbb0bac9f5e00c8f21404db6aa8", "score": "0.7075066", "text": "async destroy({ auth, request, response }) {\n const user = await User.findOrFail(request.params.id);\n\n if (!auth.user.is_admin) {\n return response\n .status(401)\n .send(\"Não autorizado a deletar outro usuário\");\n }\n await user.delete();\n }", "title": "" }, { "docid": "c65a2eac8ec8b08ac104cf8964c8d235", "score": "0.707297", "text": "function DeleteUser(userId) {\r\n UserData.deleteOne({ _id: userId }).exec();\r\n}", "title": "" }, { "docid": "cf0dfa4203eb015e5f251cb585d6302e", "score": "0.706722", "text": "async function deleteUser(ctx) {\n const id = ctx.params.id;\n let result = await model.getById(id);\n \n if (result.length){\n const data = result[0];\n console.log(\"trying to delete\", data);\n \n const empPermission = can.empDelete(ctx.state.user, data);\n const userPermission = can.userDelete(ctx.state.user, data);\n \n if (empPermission.granted){\n const result = await model.delById(id);\n if (result.affectedRows) {\n ctx.body = {ID: id, deleted: true}\n }\n } else if (userPermission.granted){\n const result = await model.delById(id);\n if (result.affectedRows) {\n ctx.body = {ID: id, deleted: true}\n }\n } else {\n ctx.status = 403;\n } \n }\n}", "title": "" }, { "docid": "acda08ff2701410d3c14ac4819a59064", "score": "0.7048856", "text": "function deleteUser() {\r\n \t\r\n \tself.confirm_title = 'Delete';\r\n\t\tself.confirm_type = BootstrapDialog.TYPE_DANGER;\r\n\t\tself.confirm_msg = self.confirm_title+ ' ' + self.user.username + ' user?';\r\n\t\tself.confirm_btnclass = 'btn-danger';\r\n\t\tConfirmDialogService.confirmBox(self.confirm_title, self.confirm_type, self.confirm_msg, self.confirm_btnclass)\r\n\t\t\t.then(\r\n\t\t\t\t\tfunction (res) {\r\n\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\tUserService.deleteUser(self.user.user_id)\r\n\t\t\t\t\t\t.then(\r\n\t\t\t\t\t\t\t\tfunction (msg) {\r\n\t\t\t\t\t\t\t\t\tvar index = self.users.indexOf(self.user);\r\n\t\t\t\t\t\t\t\t\tself.users.splice(index,1);\r\n\t\t\t\t\t\t\t\t\tself.message =self.user.username+ \" username Deleted..!\";\r\n\t\t\t\t\t\t\t\t\tsuccessAnimate('.success');\r\n\t\t\t\t\t\t\t\t\twindow.setTimeout( function(){\t \t \t\t\r\n\t\t\t\t\t\t\t\t\t\tnewOrClose();\r\n\t \t\t\t\t\t\t\t},5000);\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\t}, function(referdata) {\r\n\t\t\t\t\t\t\t\t\tself.message =self.user.username+ \" referred in several process..!\";\r\n\t\t\t\t\t\t\t\t\tsuccessAnimate('.failure');\r\n\t\t\t\t\t\t\t\t\twindow.setTimeout( function(){\t \t \t\t\r\n\t\t\t\t\t\t\t\t\t\tnewOrClose();\r\n\t \t\t\t\t\t\t\t},5000);\r\n\t\t\t\t\t\t\t\t},\r\n\t\t\t\t\t\t\t\tfunction (errResponse) {\r\n\t\t\t\t\t self.message = \"Error while deleting user \"+self.user.username+\" \";\r\n\t\t\t\t \t\t\tsuccessAnimate('.failure'); \t\t\r\n\t\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\t);\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t}\r\n\t\t\t\t);\r\n\t\t\r\n }", "title": "" }, { "docid": "6566b87668b297b8c44aa157be4c3500", "score": "0.70481586", "text": "async function delete_user() {\n const jwt = sessionStorage.getItem(\"jwt\");\n const ID = sessionStorage.getItem(\"eliminate_user\");\n if(jwt!=null){\n let response = await fetch('http://localhost:3000/user/'+ID,\n {\n method:'DELETE',\n headers:{\"Authorization\":\"Bearer \"+jwt}\n });\n let eliminado = await response.json();\n console.log(eliminado);\n $('#table_users').find(`[data-id='${ID}']`)[0].remove();\n $('#modal_user_delete').modal('hide');\n }\n}", "title": "" }, { "docid": "a2b171587c2de9d12bc8097b453dc1ee", "score": "0.70465744", "text": "function _delete(id) {\n return API.delete(`/users/${id}/`)\n}", "title": "" }, { "docid": "8a74a97722c92adf479b03fa79d904b4", "score": "0.70452213", "text": "async destroy(req, res){\n let user = await User.deleteOne({_id : req.params.id});\n return res.json(user);\n }", "title": "" }, { "docid": "cc0d6d00d4be6f4060601fa679065107", "score": "0.7034893", "text": "async destroy ({ auth, params }) {\r\n const u = await auth.getUser()\r\n await Database.raw('SET hq.usuario = ' + u.nombre)\r\n const { id } = params;\r\n const user = await User.find(id)\r\n user.delete();\r\n return {\r\n message: 'Destroyed!',\r\n user\r\n };\r\n }", "title": "" }, { "docid": "5348a4544395ce96a51a2e621ebad2a0", "score": "0.7027632", "text": "static delete(req, res, callback){\n if(!req.id || isNaN(req.id)){\n callback({code: 400, message: 'Parámetros inválidos'}); \n }\n\n User.findAll({where: {id: req.id}}).then(users => {\n if(users.length !== 0){\n User.destroy({where: {id: req.id}}).then(userDeleted => {\n if(userDeleted.length !== 0){\n callback({code: 200, deleted: true});\n }\n else {\n callback({code: 200, deleted: false}); \n }\n })\n }\n else {\n callback({code: 204, message: 'El usuario no existe.'}); \n } \n })\n }", "title": "" }, { "docid": "64549ccfd4794f5f8bcac7eba0d628dd", "score": "0.70097715", "text": "async destroy ({ params }) {\n const user = await Provider.findOrFail(params.id)\n\n await user.delete()\n }", "title": "" }, { "docid": "ca6052b774c7b1194117616f85a66741", "score": "0.70059985", "text": "delete(req, res) {\n return __awaiter(this, void 0, void 0, function* () {\n try {\n const id = req.params.id;\n const deleteT = yield tipo_userData.deleteTipo_user(id);\n res.json({ text: 'tipo user Eliminado' });\n res.send(deleteT);\n }\n catch (error) {\n res.status(400).send(error.message);\n }\n });\n }", "title": "" }, { "docid": "20289c8a4dd0fa7a772949840b9e3e4f", "score": "0.70028406", "text": "async function _delete(id) {\n\n const response = await API.delete('/users/' + id,);\n const user = handleResponse(response);\n return user;\n}", "title": "" }, { "docid": "d0c68e8dfe91f8d9d0fb6e102e63448a", "score": "0.70025694", "text": "async function deleteUser(req, res){\n const user_id = req.params.userId;\n try {\n let user = await User.findById(user_id);\n if(!user) return response.notFound(res,\"User doesn't exists!!!\");\n if (user.is_admin) return response.forbidden(res, \"Can't delete an admin user\");\n if (req.user.is_admin || req.user._id.toString() === user._id.toString()) {\n await User.findByIdAndDelete(user_id);\n }\n response.noContent(res)\n }catch (err) {\n log.error(err);\n response.internal(res, err);\n }\n}", "title": "" }, { "docid": "7daf2184dcd23fe66e26bc9607082222", "score": "0.698887", "text": "deleteUser(id) {\n return axios.delete(`/api/user/${id}`);\n }", "title": "" }, { "docid": "e6b8db8e1788b649dcfc50fe4862efd5", "score": "0.6981886", "text": "function deleteUser(id,callback){\n $http({\n method: 'DELETE',\n url: getUrl() + '/api/users/'+id\n }).then(\n function success(response){\n alert('Usuario eliminado');\n callback(true);\n },\n function error(response){\n callback(false);\n }\n );\n }", "title": "" }, { "docid": "b02068d1e3aad14da4ed31c948b50afd", "score": "0.69772536", "text": "DeleteUser(serviceName, userId) {\n let url = `/caas/registry/${serviceName}/users/${userId}`;\n return this.client.request('DELETE', url);\n }", "title": "" }, { "docid": "af30e70e7f3fe13f6b304660cc244d34", "score": "0.697158", "text": "async function deleteUser(userId) {\n return db('users').where({ id: userId }).del();\n}", "title": "" }, { "docid": "d510e65f020f7643d767d8f173f3cb2a", "score": "0.6967933", "text": "function remove(username){\n $.ajax({\n url: \"/deleteUser?userName=\"+username,\n type: \"DELETE\",\n dataType: \"JSON\",\n success: function(respose) {\n \tconsole.log(respose);\n \twindow.location.reload();\n },\n error:function(xhr){\n \talert(xhr.responseText);\n }\n });\n }", "title": "" }, { "docid": "988ce8c6de964ab126ed02bce379fe03", "score": "0.6967548", "text": "function remove(req, res) {\n ensureAuthenticated(req, res, (req, res) => {\n if (!_.has(req.body, 'id')) {\n return res.json({\n success: false,\n err: 'Require userID',\n });\n }\n const userID = req.body.id;\n // Please use integers not strings in the JSON body.\n if (req.session.passport.user.id !== userID) {\n return res.json({\n success: false,\n err: 'You can only delete yourself',\n });\n }\n mUser.remove(userID, (err, userID) => {\n if (err) {\n return res.json({\n success: false,\n err: err,\n });\n }\n res.json({\n success: true,\n id: userID,\n });\n });\n });\n}", "title": "" }, { "docid": "a79fda6612ff9e3abd29fc61aff6ff34", "score": "0.6958018", "text": "function deleteUser(){\n\t\n\t$.ajax({\n\t\ttype: \"POST\",\n\t\turl: \"../admin/dashboard/deleteUser\",\n\t\tdataType:'json',\n\t\tdata: {\n\t\t\tid:UserId\n\t\t},\n\t\tsuccess: function(data){\n\t\t\t$(\"#divAlertWarningUser\").hide();\n\t\t\t$('#alertUser').html(data);\n\t\t\t$('#divAlertUser').show(1000).delay(1500);\n\t\t\t$('#divAlertUser').hide(1000);\n\t\t\tgetUserByResidencial();\n },\n\t\terror: function(){\n\t\t\t$(\"#divAlertWarningResidential\").hide();\n\t\t\talert('Error al eliminar la residencia. Intentelo mas tarde');\n }\n\t});\n\t\n}", "title": "" }, { "docid": "7804e20f4d795a860fe7cc9ad8d84d3c", "score": "0.69575095", "text": "async function deleteUser(token, id) {\n try {\n let response = await fetch(\"/api/user/\" + id, {\n method: \"DELETE\",\n headers: {\n Accept: \"application/json\",\n \"Content-Type\": \"application/json\",\n Authorization: `Bearer ${token}`,\n },\n });\n return response.ok;\n } catch (err) {\n console.error(\"GETTING USER FAILED\", err);\n return false;\n }\n}", "title": "" }, { "docid": "cd19499f9af88e69afb58c77b3f0ae0f", "score": "0.6954413", "text": "function removeUser (req, res) {\n User.remove({ _id: req.params.user_id }, function (err, result) {\n if (err) {\n console.log(err);\n return err;\n }\n res.json({\n status: 'success',\n message: 'User removed'\n });\n });\n}", "title": "" }, { "docid": "8eb1d63fe2c2252f17e108ed89974286", "score": "0.6952196", "text": "function deleteUser() {\n $removeBtn = $(event.currentTarget);\n $userId = $removeBtn\n .parent()\n .parent()\n .parent()\n .attr('id');\n userService\n .deleteUser($userId)\n .then(findAllUsers);\n $userId = -1;\n // alert('Delete User Successful');\n $('#deleteSuccessAlert').css('display', 'block');\n $('#deleteSuccessAlert').delay(2000).slideUp(200);\n\n }", "title": "" }, { "docid": "4428f6394ccfc6df8d9e9107d9e69c75", "score": "0.6949018", "text": "function destroy(req, res) {\n return _user2.default.findByIdAndRemove(req.params.id).exec().then(function () {\n res.status(204).end();\n }).catch(handleError(res));\n}", "title": "" }, { "docid": "520365c8f50c9a3a017ab8e19f455abb", "score": "0.69459677", "text": "function deleteUserOnServer() {\n var $pass1 = $('#pass1D');\n COMM.json(\"/user\", {\n \"cmd\" : \"deleteUser\",\n \"accountName\" : userState.accountName,\n \"password\" : $pass1.val()\n }, function(result) {\n if (result.rc === \"ok\") {\n $('.modal').modal('hide'); // close all opened popups\n logout();\n displayMessage(\"MESSAGE_USER_DELETED\", \"TOAST\", \"\");\n } else {\n displayMessage(result.message, \"POPUP\", \"\");\n }\n });\n}", "title": "" }, { "docid": "3b82de2878c17ce8ff7c8687d65ad592", "score": "0.69423366", "text": "function deleteUser(userId) {\n return UserModel.remove({_id: userId});\n }", "title": "" }, { "docid": "732979ca2c8f55fd4fa6cfa69a8ce80b", "score": "0.694096", "text": "function _delete(id) {\n const requestOptions = {\n method: 'DELETE',\n headers: authHeader()\n };\n\n return fetch(env.api + '/users/' + id, requestOptions).then(handleResponse);\n}", "title": "" } ]
2e7fb3b80f089228a9e4e933e913aeaf
display product table and availability of product
[ { "docid": "6b4845f092c449afadfae5589d1b2d56", "score": "0.0", "text": "function merch() {\n connection.query(\"SELECT * FROM products\", function(err, result) {\n if (err) throw err;\n for (var i = 0; i < result.length; i++) {\n //display productstable: id,name,price > 0, else no stock\n var r = result[i];\n if (r.stock_quantity > 0) {\n var price = Number.parseFloat(r.price);\n var stock = Number.parseFloat(r.stock_quantity);\n console.log(\n \"Item ID: \" +\n r.item_id +\n \" \" +\n \"Name: \" +\n r.product_name +\n \" \" +\n \"Price: $\" +\n price.toFixed(2) +\n \" \" +\n \"Stock: \" +\n \" \" +\n stock\n );\n } else {\n console.log(\n \"Item ID: \" +\n r.item_id +\n \" \" +\n \"Name: \" +\n r.product_name +\n \" \" +\n \"Stock:\" +\n \" \" +\n \"Out of stock my dude!\"\n );\n }\n }\n purchase();\n });\n}", "title": "" } ]
[ { "docid": "c1e36447d2d47a7e67e220002744b40f", "score": "0.7427007", "text": "function displayProducts() {\n\t\n\tvar sql = 'SELECT item, product_name, price FROM products'\n\n\tconnection.query(sql, function(err, result){\n\n\t\tif(err) console.log(err)\n\n\t\t//creates a table for the information from the mysql database to be placed\n\t\tconsole.log('>>>>>>Products Available for Purchase<<<<<<'.blue)\n\t\tvar table = new Table({\n\t\t\thead: ['Item Id#', 'Product Name', 'Price'],\n\t\t\tchars: chars,\n\t\t\tcolAligns: [null, null, 'right'],\n\t\t\tstyle: {\n\t\t\t\thead: ['blue'],\n\t\t\t\tcompact: false\n\t\t\t}\n\t\t})\n\n\t\t//loops through each item in the mysql database and pushes that information into a new row in the table\n\t\t\n\t\tfor(var i = 0; i < result.length; i++){\n\t\t\ttable.push([result[i].item, result[i].product_name, result[i].price])\n\t\t}\n\t\t//show the product info in tabular form\n\n\t\tconsole.log(table.toString())\n\t\t\n\t\t//determine what customer wants to do\n\t\t\n\t\tdetermineAction()\n\t})\n}", "title": "" }, { "docid": "bd08a7f538aafbb6719900689421b36d", "score": "0.72667205", "text": "function viewProducts() {\n\n\t// make database connection and get complete Products table\n\tconnection.query('SELECT * FROM Products', function(err, res) {\n\n\t\t// if there is an error, throw it\n\t\tif (err) throw err;\n\n\t\t// display the stock table, but first a new line\n\t\tconsole.log(\"\\n\")\n\t\tconsole.table(res);\n\n\t\t// now return to task choices\n\t\tstart();\n\t})\n}", "title": "" }, { "docid": "21a3032a20836775de9296b3b3fa7516", "score": "0.723602", "text": "function displayProducts() {\n connection.query(\"SELECT * FROM products\", function (err, res) {\n var tableType = 'inventory';\n err ? (message.dbError(), redirect()) : (tables.makeManagerTables(res, tableType),\n setTimeout(redirect, 2000));\n });\n}", "title": "" }, { "docid": "f71f63299800ca1ac0c8aa3bb17b07db", "score": "0.7227078", "text": "function viewProducts() {\n connection.query(\"SELECT item_id, product_name, price, stock_quantity FROM products\", function (err, res) {\n if (err) throw err;\n var columns = columnify(res)\n console.log(chalk.green(\"\\n\\n***************Available Products***************\"))\n console.log(columns + \"\\n\\n\");\n makeSelection();\n });\n\n}", "title": "" }, { "docid": "dc9b8c3fdb8882890cf92dcb3819148d", "score": "0.7119186", "text": "function displayProducts() {\n // Select query to display all items within table in database\n connection.query(\"SELECT item_id, product_name, price, stock_quantity FROM products\", function(err, data) {\n if(err) {\n console.log(err);\n }else {\n console.log(\"\");\n // Log data in tabular format\n console.table(data);\n // Display menu\n getManagerAction();\n }\n });\n}", "title": "" }, { "docid": "cd83f3664c3f338768cbb4dd6a427609", "score": "0.7107407", "text": "function showProducts() {\n console.clear();\n header();\n var table = new Table({\n head: [\n \"ITEM ID\".red.bold.underline,\n \"PRODUCT NAME\".blue.bold.underline,\n \"DEPARTMENT\".green.bold.underline,\n \"PRICE\".yellow.bold.underline,\n \"STOCK\".magenta.bold.underline\n ],\n colWidths: [10, 40, 15, 10, 10],\n chars: {\n top: \"═\",\n \"top-mid\": \"╤\",\n \"top-left\": \"╔\",\n \"top-right\": \"╗\",\n bottom: \"═\",\n \"bottom-mid\": \"╧\",\n \"bottom-left\": \"╚\",\n \"bottom-right\": \"╝\",\n left: \"║\",\n \"left-mid\": \"╟\",\n mid: \"─\",\n \"mid-mid\": \"┼\",\n right: \"║\",\n \"right-mid\": \"╢\",\n middle: \"│\"\n }\n });\n connection.query(\"SELECT * FROM products\", function(err, res) {\n for (var i = 0; i < res.length; i++) {\n table.push([\n (res[i].item_id + \"\").red,\n (res[i].product_name + \"\").blue,\n (res[i].department_name + \"\").green,\n (res[i].price + \"\").yellow,\n (res[i].stock_quantity + \"\").magenta\n ]);\n }\n console.log(table.toString() + \"\\n\");\n again();\n });\n}", "title": "" }, { "docid": "31899d1f899d18508a4fdaa09af9d3fd", "score": "0.7017748", "text": "function displayOfferings() {\n console.log(chalk.green(\"\\n\\nBamazon\\n\"));\n connection.query(\"SELECT * FROM products\\n\", function (err, res) {\n if (err) throw err;\n\n // using easy-table npm to create a table of the available goods\n var t = new Table;\n res.forEach(function (product) {\n t.cell(\"Item\", product.item_id);\n t.cell(\"Product\", product.product_name);\n t.cell(\"Department\", product.department_name);\n t.cell(\"Price\", product.price);\n t.cell(\"Quantity\", product.stock_quantity);\n t.newRow();\n });\n console.log(t.toString());\n // run the function to interact with the user\n askUser();\n });\n}", "title": "" }, { "docid": "425e69b8acd93a95e9ed9b5ab2a2cd04", "score": "0.69931954", "text": "function viewProducts() \n{\n\n\t// \n\tconnection.query('SELECT * FROM Products', function(err, res) {\n\n\t\t// throw error if occurs \n\t\tif (err) throw err;\n\n\t\t\n\t\tconsole.log('\\n' + \"Stock Inventory\" + '\\n')\n\t\tconsole.table(res);\n\n\t\t\n\t\tstart();\n\t})\n}", "title": "" }, { "docid": "81c9dd2b266a742b65ba8d32c4329416", "score": "0.6948968", "text": "function displayAllProducts() {\n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n var table = new Table({\n head: ['Item #', 'Product Name', 'Department', 'Price', 'Stock'],\n colWidths: [8, 45, 16, 12, 8]\n });\n for (i = 0; i < res.length; i++) {\n table.push([res[i].item_id, res[i].product_name, res[i].department_name, '$' + parseFloat(res[i].price).toFixed(2), res[i].stock_quantity]);\n }\n console.log(table.toString());\n console.log(\"\");\n menu();\n });\n}", "title": "" }, { "docid": "4c9a928811e6a1c5d964f0309822b7b8", "score": "0.6937841", "text": "function displayProducts() {\n\n // get categories for post\n console.log(\"Selecting all Available Items...\\n\");\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) {\n console.log(err);\n throw err;\n } else {\n // used for the easy-table package\n var t = new Table;\n\n // // Log all results of the SELECT statement\n res.forEach((productList, i) => {\n // t.cell is used for easy-table set-up\n t.cell('Product Id', productList.id)\n t.cell('Department Name',productList.department_name)\n t.cell('Description', productList.product_name)\n t.cell('Price',productList.customer_price,Table.number(2))\n t.cell('Quantity', productList.quantity)\n t.cell('Product Sales', productList.product_sales)\n t.newRow()\n\n })\n console.log(t.toString());\n \n // call initial prompts to start \n initialPromts();\n \n }\n }\n )\n}", "title": "" }, { "docid": "9b3ef5a289806f2fe9da5c9398146a67", "score": "0.6880136", "text": "function displayStore() {\n connection.query(\"SELECT * FROM products\", function (error, response) {\n if (error) throw error;\n // displaying everything all nice and friendly like\n console.log(\"GLAMAZON PRODUCTS\");\n var table = new Table({\n head: [\"Item ID\", \"Product Name\", \"Price\"],\n colWidths: [10, 50, 10]\n });\n for (var i = 0; i < response.length; i++) {\n table.push(\n [response[i].item_id, response[i].product_name, `$${response[i].price}`]\n )\n }\n console.log(table.toString());\n })\n }", "title": "" }, { "docid": "0fc666b8d9a8baa4fca02fa873b939b4", "score": "0.68664694", "text": "function inventoryDisplay() {\n connection.query(\"SELECT * FROM products\", function(err, res){\n\n if (err) throw err;\n \n //log for results of query for all products available for sale\n console.table(res);\n })\n}", "title": "" }, { "docid": "01d1fbddbceb663922868083a446c622", "score": "0.6860019", "text": "function printProductTable(res, restart) {\n var table = new Table({\n head: ['Item#', 'Product Name', 'Department', 'Price', 'Available Quantity']\n , colWidths: [10, 20, 15, 10, 20]\n });\n for (var i = 0; i < res.length; i++) {\n table.push(\n [res[i].id, res[i].product_name, res[i].department_name, res[i].price, res[i].stock_quantity]\n );\n }\n console.log(chalk.bgGreenBright(table.toString()))\n if (restart) {\n // re-prompt the manager for available actions\n start();\n }\n}", "title": "" }, { "docid": "92887e793a71521a1aec1148b3a694bb", "score": "0.6804614", "text": "function checkList() {\n let lengthProductRows = $('.d-i-table__row--product').length;\n\n if (lengthProductRows) $('.js-det-table').show();\n else $('.js-det-table').hide();\n }", "title": "" }, { "docid": "d94bdbfc399776a3a0da78cf26e24f35", "score": "0.67486745", "text": "function displayTableProducts(data) {\n const table = document.createElement(\"table\");\n table.setAttribute(\"border\", 1);\n\n let index = 0;\n data.data.products.forEach((product) => {\n table.insertRow(index).insertCell(0).innerText = product.name;\n index++;\n });\n\n const tableProduct = document.getElementById(\"table-products\");\n tableProduct.appendChild(table);\n}", "title": "" }, { "docid": "16e823cb00b29f5f963c6950a30afd42", "score": "0.67354417", "text": "function displayProducts() {\n console.log(\"\\nInventory\\n\");\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err;\n console.table(res);\n console.log(\"\\n\");\n reRun();\n });\n}", "title": "" }, { "docid": "19abea56b24d8601b73f0264add9cc18", "score": "0.67225695", "text": "function showResults(products){\n\t$('#productsTable tbody').empty();\n\tproducts.forEach(function(product){\n\t\t$('#exampleRow #id').text(product['ID']);\n\t\t$('#exampleRow #reference').text(product['reference']);\n\t\t$('#exampleRow #label').text(product['label']);\n\t\t$('#exampleRow #price').text(product['price']);\n\t\t$('#exampleRow .delete').attr('id', product['ID']);\n\t\t$('#exampleRow img').attr('src', product['image']);\n\n\t\tadded = new Date(product['added']);\n\t\tupdated = new Date(product['updated']);\n\t\tif (product['added'] === null)\n\t\t\tstrAdded = '-';\n\t\telse\n\t\t\tstrAdded = String(added.getDate()).padStart(2,'0') + '/' + String(added.getMonth()+1).padStart(2,'0') + '/' + added.getFullYear();\n\t\tif (product['updated'] === null)\n\t\t\tstrUpdated = '-';\n\t\telse\n\t\t\tstrUpdated = String(updated.getDate()).padStart(2,'0') + '/' + String(updated.getMonth()+1).padStart(2,'0') + '/' + updated.getFullYear();\n\t\t$('#exampleRow #added').text(strAdded);\n\t\t$('#exampleRow #updated').text(strUpdated);\n\n\t\tif(product['available'] == 1){\n\t\t\t$('#exampleRow #available i:last-child').addClass(\"hidden\");\n\t\t\t$('#exampleRow #available i:first-child').removeClass(\"hidden\");\n\t\t}\n\t\telse{\n\t\t\t$('#exampleRow #available i:first-child').addClass(\"hidden\");\n\t\t\t$('#exampleRow #available i:last-child').removeClass(\"hidden\");\n\t\t}\n\n\t\t$('#productsTable tbody').append($('#exampleRow').clone());\n\n\t\t$('#productsTable tbody tr').last().attr('id', product['ID']);\n\t});\n\n\t$('#productsTable tbody tr').removeClass('hidden');\n\n\tif(products.length != 0){\n\t\t$('#productsNumber').text(products.length + ' produits trouvés');\n\t}\n\telse{\n\t\t$('#productsNumber').text('Aucun produit trouvé');\n\t}\n}", "title": "" }, { "docid": "6950b8f69bd390fc648cccef7ad33eb5", "score": "0.67016035", "text": "function displayStock() {\n\tvar table = new Table(tableSpecs);\n\n\tconnection.query(\"SELECT * FROM products\", function(err, res){\n\t\tif (err) throw err;\n\t\t//Pass each object key into the table object to create a row. Repeat for all rows\n\t\tfor (var i = 0; i < res.length; i++) {\n\t\t\ttable.push(Object.keys(res[i]).map(function(key) {return res[i][key];}));\n\t\t}\n\t\tconsole.log(table.toString());\n\t\tpromptManager();\n\t});\n}", "title": "" }, { "docid": "858cda76a21b241ec7d2185875feab28", "score": "0.66987187", "text": "function showProducts() {\n var query = connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n console.log(res);\n\n for (var i = 0; i < res.length; i++) {\n var table = new Table({\n head: ['Item ID', 'Product', 'Department', 'Price', 'Quantity']\n , colWidths: [10, 60, 15, 10, 10]\n });\n\n // table is an Array, so you can `push`, `unshift`, `splice` and friends\n table.push([res[i].item_id, res[i].product_name, res[i].department_name, res[i].price, res[i].stock_quantity]\n );\n console.log(table.toString());\n }\n\n choseProduct();\n });\n}", "title": "" }, { "docid": "2271f98cf4d421b5777d7d15288ad89f", "score": "0.66980124", "text": "function viewProducts() {\n\n connection.query(\"SELECT * FROM products\", function (err, res) {\n\n if (err) throw err;\n\n displayTable(res);\n connection.end();\n\n\n });\n}", "title": "" }, { "docid": "1ecce6812c549a3ca3cf11e4d7f83472", "score": "0.66924864", "text": "function viewProducts() {\n console.log(\"\\nHere are all products available for purchase...\\n\");\n\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err;\n console.log('-------------------------------------------------------------------------------------------------------------------------------------------------------------------------');\n\n for (var i = 0; i < res.length; i++) {\n console.log(\"ID: \" + res[i].item_id + \" | \" + \"Product: \" + res[i].product_name + \" | \" + \"Department Name: \" + res[i].department_name + \" | \" + \"Price: \" + res[i].price + \" | \" + \"QTY Available: \" + res[i].stock_quantity);\n console.log('---------------------------------------------------------------------------------------------------------------------------------------------------------------------');\n }\n\n start();\n });\n}", "title": "" }, { "docid": "d0c39c4ca4ae448f1cf593040d347ee9", "score": "0.66839236", "text": "function showProducts() {\n connection.query(\n \"SELECT * FROM bamazon_db.products;\", function (err, res) {\n console.table(res);\n start();\n }\n )\n}", "title": "" }, { "docid": "9bbd1fc3195bf4c0281d9e7bbf336c1f", "score": "0.6669634", "text": "function showProducts() {\n\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err;\n let table = new Tablefy()\n table.draw(res)\n mainMenu();\n });\n}", "title": "" }, { "docid": "0bcd2bf78142d8c9964e13beb9f6b861", "score": "0.6647799", "text": "function viewProducts() {\n connection.query('SELECT * FROM products', function (err, results) {\n if (err) {\n console.log(err);\n }\n console.log(\"\\n All available products: \\n\");\n for (var i = 0; i < results.length; i++) {\n console.log(\n results[i].itemID + \" \" + \n results[i].productName + \" [\" + \n results[i].price + \"] Qty: \" + \n results[i].stockQuantity\n );\n }\n console.log(\"\\n--------------\\n\");\n menu();\n })\n}", "title": "" }, { "docid": "3e40c2561364790e6e951a8d994494ab", "score": "0.664476", "text": "function showProducts() {\n var productTable = new Table({\n head: [' Item ID: ', ' Product: ', ' Department: ', ' Price: ', ' Stock: ', 'Total Sales:'],\n });\n\n var query = \"SELECT * FROM products\";\n\n connection.query(query, function (err, result) {\n if (err) throw err;\n result.forEach(function (column) {\n productTable.push([column.item_id, \n column.product_name, \n column.department_name, \n '$' + column.price, \n column.stock_quantity, \n '$' + column.product_sales]);\n });\n console.log(\"\\n\" + productTable.toString() + \"\\n\");\n startApp();\n });\n}", "title": "" }, { "docid": "10932c6280795c642427b56bddb658b4", "score": "0.66085577", "text": "function viewProductsForSale() {\n connection.query(\"SELECT * FROM products\", (err, res) => {\n let productListing = new Table({\n head: [chalk.blueBright.bold(\"ID\"), chalk.blueBright.bold(\"PRODUCT NAME\"), chalk.blueBright.bold(\"DEPARTMENT\"), chalk.blueBright.bold(\"PRICE\"), chalk.blueBright.bold(\"QTY\")],\n });\n for (let i = 0; i < res.length; i++) {\n productListing.push([chalk.redBright.bold(res[i].item_id), res[i].product_name, res[i].department_name, chalk.greenBright(`$${res[i].price}`), res[i].stock_quantity]);\n }\n console.log(`${productListing.toString()}`);\n connection.end();\n });\n}", "title": "" }, { "docid": "45cc68f57909913206c5c036dd9b2e60", "score": "0.66056335", "text": "function viewProducts() {\n connection.query('SELECT * FROM Products', function(err, res) {\n console.log('\\n');\n console.table(res)\n });\n}", "title": "" }, { "docid": "8efe488e5a1c090b13653ace76bfd630", "score": "0.6605373", "text": "function displayData(products){\n\tconst rows = products.map(product => {\n\t\treturn `<tr>\n\t\t\t\t\t\t\t<td>${product.ProductId}</td>\n\t\t\t\t\t\t\t<td>${product.CategoryId}</td>\n\t\t\t\t\t\t\t<td>${product.ProductName}</td>\n\t\t\t\t\t\t\t<td>${product.ProductDescription}</td>\n\t\t\t\t\t\t\t<td>${product.ProductStock}</td>\n\t\t\t\t\t\t\t<td>${product.ProductPrice}</td>\n\t\t\t\t\t\t</tr>`;\n\t});\n\n\tdocument.getElementById(\"productRows\").innerHTML = rows.join(\"\");\n\n\tgetDataAsync();\n}", "title": "" }, { "docid": "608489fc33076a37616df8c80b5cb4f2", "score": "0.66010857", "text": "function viewProducts() {\n connection.query(\"SELECT * FROM products\", function(err, results) {\n for (var i = 0; i < results.length; i++) {\n console.log('\\nPRODUCT ID: ' + results[i].id + '\\nPRODUCT NAME: ' + results[i].productName + '\\nDEPT NAME: ' + results[i].departmentName + '\\nPRICE: $' + results[i].price + '\\nQUANTITY IN STOCK: ' + results[i].stockQuantity + '\\n*************');\n }\n mgrOption();\n })\n}", "title": "" }, { "docid": "9c29ab65ab8f9fcf3761d92a2065eb1c", "score": "0.65928185", "text": "function displayProducts() {\n let data = [];\n let output;\n let query = \"SELECT * FROM products\";\n connection.query(query, function(err, res){\n if(err) throw err;\n let row = [\"ID#\", \"PRODUCT\", \"DEPARTMENT\", \"PRICE\", \"QTY\"];\n data.push(row);\n for (let i = 0; i < res.length; i++) {\n row = [];\n row.push(res[i].id, res[i].product_name, res[i].department_name, \"[$\" + res[i].price + \"]\", res[i].stock_quantity);\n data.push(row);\n }\n output = table(data);\n console.log(output);\n inq.askCustomer(res);\n })\n}", "title": "" }, { "docid": "118f08332dcf47e1fc913954fd7f9411", "score": "0.65849286", "text": "function displayAllProd() {\n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n console.log(`\\nAll products:\\n`)\n\n var table = new Table({\n head: [`ID #`, `Item Name`, `Department`, `Price`, `Stock`]\n , colWidths: [7, 25, 25, 10, 7]\n });\n\n for (var i = 0; i < res.length; i++) {\n\n table.push([res[i].id, res[i].product_name, res[i].department_name, `$${res[i].price}`, res[i].stock_quantity]);\n }\n console.log(table.toString());\n console.log(`\\n----------------------------------------------------------------------\\n`);\n userPrompt();\n });\n}", "title": "" }, { "docid": "60444cb91717eb8cb79f1eba7c8edc76", "score": "0.65789944", "text": "function viewAllProducts() {\n connection.query('SELECT * FROM products ORDER BY department_name', function(error, res) {\n if (error) throw error;\n var table = new Table({\n head: ['item_Id', 'Product Name', 'Department', 'Price', 'Stock Quantity']\n });\n\n for (i = 0; i < res.length; i++) {\n table.push(\n [res[i].item_id, res[i].product_name, res[i].department_name, res[i].price, res[i].stock_quantity]\n );\n }\n console.log(table.toString());\n promptAction();\n // connection.end();\n });\n}", "title": "" }, { "docid": "0ce5e399d55cb223e21f15a1347b7803", "score": "0.6574896", "text": "function showProducts() {\n connection.query('SELECT item_id, product_name, price FROM products', function(err, res) {\n if(err) console.log(err);\n\n var table = new Table({\n head: ['Item ID', 'Item Name', 'Product Price']\n , colWidths: [30, 30, 30]\n });\n\n for (i = 0; i < res.length; i++) {\n table.push([res[i].item_id, res[i].product_name, res[i].price])\n };\n console.log(table.toString());\n processAnswers();\n })\n\n}", "title": "" }, { "docid": "8d0d1c6435f44f147db2cf842caa23cb", "score": "0.6565342", "text": "function viewProducts() {\n connection.query(\n \"SELECT item_id, product_name, price, stock_quantity FROM inventory;\",\n \n function(err, results) {\n if (err) throw err;\n console.table(results);\n\n start();\n }\n );\n}", "title": "" }, { "docid": "b4d8d5e6fbe70cd5cec84b5484d14594", "score": "0.65651196", "text": "function showProducts() {\n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n console.log( \"\\n Available Products:\\n-----------------\\n\")\n for (var i=0; i<res.length;i++) {\n console.log(\n \"Product Name: \"+res[i].product_name+ \n \"\\n Item ID: \"+res[i].item_id+ \n \"\\n Price: $\"+res[i].price+ \"\\n\");\n }\n whichProduct();\n \n });\n}", "title": "" }, { "docid": "997d9215c5b3b2b128bd1f1ae5c8e00b", "score": "0.6559837", "text": "function inventoryTable() {\n\tconnection.query('SELECT * FROM products', function (err, results) {\n\t\tif (err) throw err;\n\t\tconsole.table(results);\n\t});\n}", "title": "" }, { "docid": "8731bb3bb1e9273e0b219de186a57c88", "score": "0.65387917", "text": "function showProduct() {\n console.log(\"Here are our products!\\n\");\n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n for (i=0; i < res.length; i++) {\n table.push(\n [res[i].id, res[i].product_name, \"$\" + res[i].price, res[i].stock_quantity]\n );\n };\n console.log(table.toString());\n question1();\n });\n}", "title": "" }, { "docid": "1553323cad6f38bfa29e21b855139830", "score": "0.65346295", "text": "function showInventory() {\n connection.query(\"SELECT * FROM products\", function (err, response) {\n if (err) throw err;\n // Show the table in the terminal\n console.table(response);\n // Prompt for user to select product\n promptUser();\n });\n}", "title": "" }, { "docid": "377e955bd643a491e85a6d07052793a2", "score": "0.6529083", "text": "function viewProducts(){\n connection.query(\"SELECT * FROM products\", function(err, result) {\n if (err) throw err;\n \n console.table(result);\n });\n}", "title": "" }, { "docid": "a4353a7dc74984472b9db84f6070ac67", "score": "0.65230304", "text": "showProductAvailable() {\n let elAvailable = document.getElementById('available');\n let elUnavailable = document.getElementById('unavailable');\n elAvailable.style.display = '';\n elUnavailable.style.display = 'none';\n }", "title": "" }, { "docid": "279cc39ea41e7d2592482b17d0890efc", "score": "0.6506929", "text": "function productTable(){\n resultTable.style.border='1px solid black';\n resultTable.hidden = false;\n var thEl1 = document.createElement('th');\n var thEl2 = document.createElement('th');\n var trEl = document.createElement('tr');\n\n thEl1.textContent='Products';\n trEl.appendChild(thEl1);\n thEl2.textContent='Votes';\n trEl.appendChild(thEl2);\n resultTable.appendChild(trEl);\n for (var i = 0; i < allProducts.length; i++) {\n var trEl = document.createElement('tr');\n var tdEl = document.createElement('td');\n tdEl.textContent = allProducts[i].name;\n trEl.appendChild(tdEl);\n var tdEl = document.createElement('td');\n tdEl.textContent = allProducts[i].tally;\n trEl.appendChild(tdEl);\n resultTable.appendChild(trEl);\n }\n}", "title": "" }, { "docid": "c445a97bdd92bfe1acaf3ebf50b29a37", "score": "0.65050685", "text": "function view() {\n rend(displayManager, \"select * from products;\");\n}", "title": "" }, { "docid": "bba130f973154188505a70348c532a7a", "score": "0.6494826", "text": "function showProducts() {\n // Select * (ALL) items from table 'products'\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err;\n // Display table on terminal\n console.table(res);\n // Then ask the customer for the Item ID of the book they'd like to buy\n askForItemID(res);\n });\n}", "title": "" }, { "docid": "72da6b441f880d77ffa9d3f642814e37", "score": "0.64166015", "text": "function viewProducts() {\n connection.query('SELECT sku,product_name,price,stock_quantity FROM products', function (err, res) {\n if (err) throw err\n console.table(res)\n connection.end()\n }) \n}", "title": "" }, { "docid": "d7b943fb0783e725ecfcbb2f08a8c1ae", "score": "0.640713", "text": "function showProducts() {\n console.log(`--------------------------------------------`);\n let query = \"SELECT * FROM products\";\n connection.query(query, function (err, res) {\n if (err) throw err;\n console.table(res);\n console.log(`---------------------------------------------`);\n managerNavigate();\n });\n}", "title": "" }, { "docid": "222abefaf65624b26433a26c87b81e63", "score": "0.64023364", "text": "function showInventory() {\n\t//selects only the id, name, price columns from the table\n\tconnection.query(\"SELECT item_id, product_name, price FROM products\", function (error, results) {\n\t\tif (error) {\n\t\t\tthrow error;\n\t\t}\n\t\t//will print the inventory in a more readable format using console.table npm package\n\t\tconsole.table(results);\n\t\t//will run the buyProduct function to interact with user\n\t\tbuyProduct();\n\t});\n}", "title": "" }, { "docid": "074697b27e9fbe0a79a02d8a9fd7ddb0", "score": "0.6400339", "text": "function displayProducts(productsInStore) {\nlet values = [\n [prodId = '',\n prodName = '',\n prodPrice = '',\n prodQuantity = ''\n ],\n];\n\nfor (let i = 0; i < productsInStore.length; i++) {\n values.push([productsInStore[i].product_id,\n productsInStore[i].product_name.trim(),\n productsInStore[i].product_price.toFixed(2),\n productsInStore[i].stock_quantity\n ]);\n};\nconsole.table(['Product ID', 'Product Name', 'Price/Unit', 'Quantity on Hand'], values);\n}", "title": "" }, { "docid": "f4caa0d0b755fb740eb240d24c523ba7", "score": "0.6398499", "text": "function viewProducts(){\n\n // Construct the db query string\n queryStr = 'SELECT * FROM products';\n\n // Make the db query\n connection.query(queryStr, function(err, res) {\n if (err) throw err;\n //creating the table that holds all the products\n var table = new Table({\n head: ['ID', 'Product Name', 'Department', 'Price', 'Stock']\n });\n\n //DISPLAYS ALL ITEMS FOR SALE \n console.log(\"\\n\");\n console.log(\" HERE ARE ALL THE ITEMS AVAILABLE FOR SALE \".bold);\n //looping through res to print the results\n for (var i = 0; i < res.length; i++) {\n table.push([res[i].item_id, res[i].product_name, res[i].department_name, \"$\" + res[i].price.toFixed(2), res[i].stock_quantity]);\n }\n //printing the table \n console.log(table.toString());\n\n \n promptManager();\n })\n}//end of viewProduct function", "title": "" }, { "docid": "1b9a52c22598a0f8012aaae5cce8fd7e", "score": "0.63870084", "text": "function viewProducts() {\n\n // Query the database for all items on sale\n connection.query(\"SELECT * FROM products\", function (err, results) {\n if (err) throw err;\n\n var productArray = []\n\n results.forEach(p => {\n productArray.push({\n ID: p.item_id,\n Name: p.product_name,\n Price: p.price,\n QTY: p.stock_quantity\n });\n });\n\n // Display all the product\n console.log('\\n\\t** ALL PRODUCTS TABLE **\\n');\n console.table(productArray);\n\n // Ask user if want to return to main menu or quit\n var message = \"Want to return to the main menu?\"\n again(message);\n });\n}", "title": "" }, { "docid": "6869c11b3dedaa65962901e007b768aa", "score": "0.63805395", "text": "function viewProducts() {\n\n //query products database to list all products and information\n connection.query(\"SELECT * FROM products\", function (err, results) {\n if (err) {\n console.log(`error ${err}`);\n throw err;\n };\n //format printing of products\n\n let productsInStore = results;\n displayProducts(productsInStore);\n managerOptions();\n });\n\n\n}", "title": "" }, { "docid": "024c37fbb5c09447bdf5a569f6a60401", "score": "0.63791955", "text": "function viewProducts () {\n connection.query('SELECT item_id, product_name, price, stock_quantity FROM Products', function(err, result) {\n if (err) {\n console.log(err)\n connection.end();\n return ;\n }\n // Display products\n displayProducts(result);\n connection.end();\n });\n\n}", "title": "" }, { "docid": "88739993788093a37f25c54f01e37fe5", "score": "0.637886", "text": "function availableProducts() {\n connection.query(\"SELECT * FROM products\", function (err, res) {\n console.log(\"\\n \" + \"These are all available products at this time: \".cyan.bold + \" \\n\");\n for (let i = 0; i < res.length; i++) {\n if (res[i].stock_quantity > 0) {\n console.log(res[i].id + \" | \" + (\"Item: \" + res[i].product_name).magenta + \" | \" + (\"Department: \" + res[i].department_name).yellow + \" | \" + (\"Price: $\" + res[i].price).blue + \" | \" + (\"Quantity Available: \" + res[i].stock_quantity).cyan);\n console.log(\"-----------------------------------\".green + \" \\n\");\n }\n }\n inquire();\n })\n}", "title": "" }, { "docid": "80ae48081c5b302396ef03b8d4dcdade", "score": "0.6372456", "text": "displayProduct(){\n let output = {\n 'id': this.id,\n 'name' : this.name,\n 'brand' : this.brand,\n 'basePrice' : this.basePrice,\n 'category_id' : this.category_id,\n 'category_name' : this.category.name,\n 'details': this.details,\n 'tax': this.tax,\n 'inStock' : this.inStock,\n 'outOfStock' : this.outOfStock,\n //'lastUpdated': this.lastUpdated\n }\n if(this.inStock==0){\n output.outOfStock='true';\n }\n return output;\n }", "title": "" }, { "docid": "3c9733f48c3b3359fad8df46dc68cb61", "score": "0.636762", "text": "function displayTable(res) {\n var displayTable = new table({\n head: [\"Item ID\", \"Product Name\", \"Category\", \"Price\", \"Quantity\", \"Product Sales\"],\n colWidths: [10, 25, 25, 10, 14, 10]\n });\n for (var i = 0; i < res.length; i++) {\n if (res[i].product_sales === null) {\n res[i].product_sales = 0;\n };\n displayTable.push(\n [res[i].item_id, res[i].product_name, res[i].department_name, res[i].price, res[i].stock_quantity, res[i].product_sales]\n );\n }\n console.log(displayTable.toString());\n}", "title": "" }, { "docid": "243868831ecaec9e6e7a9a4d9d624614", "score": "0.6363016", "text": "function displayProducts(result) {\n var str;\n var idLength = 7;\n var nameLength = 36;\n \n\n console.log('+---------+--------------------------------------+---------+-----------+');\n console.log('| item_id | product_name | quantity| price |');\n console.log('+---------+--------------------------------------+---------+-----------+');\n result.forEach(function (item) {\n str = printf('| %7s | %36s | %7d | % 9.2f |', my_util.pad(item.item_id, idLength), my_util.pad(item.product_name, nameLength), item.stock_quantity, item.price);\n console.log(str);\n });\n console.log('+---------+--------------------------------------+---------+-----------+');\n}", "title": "" }, { "docid": "caad4f5fc87cb0921dcb943afe7f745e", "score": "0.6345564", "text": "function viewProducts() {\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err;\n for (let i = 0; i < res.length; i++) {\n console.log(divider);\n console.log(\"product ID: \" + res[i].item_id);\n console.log(\"product name: \" + res[i].product_name);\n console.log(\"department: \" + res[i].department_name);\n console.log(\"price: $\" + res[i].price);\n console.log(\"stock: \" + res[i].stock_quantity);\n }\n console.log(divider);\n newOperation(\"view products\");\n })\n\n }", "title": "" }, { "docid": "df43e5c15b2a613ce965351af59893b2", "score": "0.6340707", "text": "function displayProducts() {\n\n connection.query(\"SELECT * FROM products\", function (err, res) {\n\n if (err) throw err;\n\n var table = new Table({\n\n head: ['ITEM ID', 'NAME', 'PRICE', 'STOCK']\n\n , colWidths: [10, 40, 10, 10]\n\n });\n\n for (var i = 0; i < res.length; i++) {\n\n table.push(\n\n [res[i].id, res[i].product, res[i].price, + res[i].quantity]\n );\n }\n console.log(table.toString());\n\n order();\n\n });\n\n}", "title": "" }, { "docid": "e3729b946b066a8b58162fc2067f29b7", "score": "0.63186264", "text": "function displayItems(){\n connection.query(\"SELECT * FROM products\", function(err, res){\n \n var productTable = [];\n for (var i = 0; i < res.length; i++) {\n productTable.push(\n {\n //\"Item ID\": res[i].item_id,\n \"Product Name\": res[i].product_name,\n \"Department Name\": res[i].department_name,\n \"Price\": res[i].price,\n \"Stock Quantity\": res[i].stock_quantity\n }\n );\n }\n console.table(productTable);\n start(res);\n })\n}", "title": "" }, { "docid": "5fcccef85aa6dc9e8ba16bde8db27097", "score": "0.6306577", "text": "function displayProduct(product) {\n let containerProduct = document.getElementById('container-prod');\n let container = document.querySelector('.container-product');\n\n // appel des fonctions avec leur bon paramètres\n setGeneral( container, product.imageUrl, '.product-image' ) \n setGeneral( container, product.name, '.product-title' ) \n setGeneral( container, product.price / 100, '.product-price' ) \n setGeneral( container, product.description, '.product-descript' ) \n lensesOption(product);\n\n // suppression du display-none\n container.classList.remove('d-none');\n // ajout des données au template de base\n containerProduct.append(container);\n}", "title": "" }, { "docid": "31ce2f7b3acb85d345300cc686ef51f8", "score": "0.63042974", "text": "function viewProduct(){\n // query the database for all items being sold\n var query = \"SELECT item_id, product_name,department_name,price,Stock_quantity FROM products\";\n\n console.log(\"Products for Sale in Bamazon:\");\n connection.query(query,function(err, res) {\n if (err) throw err;\n \n // instantiate the table \n var table = new Table({\n head: ['item_id', 'product_name','department_name','price','Stock_quantity'],\n colWidths: [20,40,20,20,20,20]\n });\n \n for (var i = 0; i < res.length; i++) {\n //pushing the res into the table array.\n table.push(\n [res[i].item_id,res[i].product_name,res[i].department_name,res[i].price,res[i].Stock_quantity]\n );\n }; \n console.log(table.toString()); \n }); \n}", "title": "" }, { "docid": "d63248ec33c4f74592a22278b0777733", "score": "0.62989694", "text": "function viewProducts(query) {\n connection.query(query, function(err, res) {\n if (err) throw err;\n if (res.length === 0) {\n console.log(`\\nno low stock\\n`);\n return continueQuestion();\n }\n console.log(`\\n${columnify(res)}\\n`);\n continueQuestion();\n });\n}", "title": "" }, { "docid": "b2616b66512d484085e690d49876e171", "score": "0.6297344", "text": "function products(){\n //console.log(\"=============== AVAILABLE PRODUCTS ===============\");\n var query = \"SELECT * FROM products\";\n connection.query(query, function(err, res){\n if(err) throw err;\n console.table(res);\n menu();\n });\n}", "title": "" }, { "docid": "cc1cede16c882efd6feef972d303d96d", "score": "0.6285545", "text": "function displayProducts() {\n\n console.log(\"\\n🌎 Welcome to Bamazon 👋. Here's everything we have on sale: \\n\")\n\n connection.query(\n \"SELECT * FROM products\", \n function(err, data) {\n // account for potential errors\n if (err) throw err;\n\n // instantiate a new table to display in the command line\n var table = new Table({\n head: [\"ITEM ID=\", \"===========PRODUCT===========\", \"====DEPARTMENT====\", \"=PRICE=\", \"=STOCK=\"],\n colWidths: [10, 32, 20, 10, 10]\n });\n\n // push each item in the database to my table\n\t\tfor (var i = 0; i < data.length; i++) {\n\n table.push([data[i].item_id, data[i].product_name, data[i].department_name, data[i].price, data[i].stock_quantity])\n }\n\n // console.log the table once it's been completed\n console.log(table.toString());\n\n console.log(\"\\n==============💸================💸=================💸=================💸==========\\n\")\n // call my prompt function to begin asking user which item they would like to buy\n promptUser();\n });\n}", "title": "" }, { "docid": "7e6bc2772d76a3412ebf6e912a449025", "score": "0.6283171", "text": "function displayInventory() {\n connection.query(\"SELECT itemID, product_name, dept_name, price, quantity FROM ??\", [\"products\"], (err, data) => {\n if (err) throw err;\n console.table(data);\n takeOrder();\n });\n}", "title": "" }, { "docid": "20a08519164cf2502026987b68f3714e", "score": "0.6281891", "text": "function renderProductsTable(productsList) {\n\n\tvar rowHtml = \"\";\n\t$(\"#productInfoTable tbody\").empty();\n\t$.each(productsList, function(key, value) {\n\t\trowHtml = \"<tr>\"\n\t\t\t+ \"<td class='no'>\" + value.productId + \"</td>\"\n\t\t\t+ \"<td>\" + value.productName + \"</td>\"\n\t\t\t+ \"<td class='quantity'>\" + value.quantity + \"</td>\"\n\t\t\t+ \"<td class='price-td'>\" + currencyFormat(value.price) + \"₫</td>\"\n\t\t\t+ \"<td class='brand-logo-td'>\" + value.brandEntity.brandName + \"</td>\"\n\t\t\t+ \"<td class='sale-date'>\" + getFormattedDate(value.saleDate) + \"</td>\"\n\t\t\t+ \"<td>\" + value.description + \"</td>\"\n\t\t\t+ \"<td class='text-center'><a href='\" + value.image + \"' data-toggle='lightbox' data-max-width='1000'><img class='img-fluid' src='\" + value.image + \"'></td>\"\n\t\t\t+ \"<td class='action-btns'>\"\n\t\t\t+ \"<a class='edit-btn' data-id='\" + value.productId + \"'><i class='fas fa-edit'></i></a> | <a class='delete-btn' data-name='\" + value.productName + \"' data-id='\" + value.productId + \"'><i class='fas fa-trash-alt'></i></a>\"\n\t\t\t+ \"</td>\"\n\t\t\"</tr>\";\n\t\t$(\"#productInfoTable tbody\").append(rowHtml);\n\t})\n}", "title": "" }, { "docid": "be87c258196e64e689222ca498589e1c", "score": "0.62750894", "text": "function getProducts() {\n var init = {\n method : 'GET',\n headers : header\n \n };\n\n req = new Request(products_url,init)\n\n fetch(req)\n .then((res)=>{\n console.log(res);\n status = res.status\n return res.json();\n })\n .then((data)=>{\n if (status==401){\n window.location.href = \"index.html\";\n }\n console.log(data['products in stock']);\n\n rowNum = 1; //the row id\n data['products in stock'].forEach(product => {\n console.log(product['product_name']);\n\n // save the queried data in a list for ease of retrieving\n\n product_item[product['product_id']] = {\n \"product_image\":product['product_image'],\n \"product_name\":product['product_name'],\n \"description\":product['description'],\n \"product_price\":product['product_price'],\n \"quantity\":product['quantity']\n };\n products_table = document.getElementById('tbl-products')\n let tr = createNode('tr'),\n td = createNode('td');\n\n // table data\n t_data=[\n rowNum,product['product_name'],\n product['quantity'],\n product['product_price']\n ];\n tr = addTableData(tr,td,t_data);\n console.log(tr);\n\n // add the view edit and delete buttons\n if (JSON.parse(sessionStorage.current_user).role == \"attendant\"){\n td = createNode('td')\n td.innerHTML=` <i id=\"${product['product_id']}\" onclick=\"showProductPane(this)\" class=\"fas fa-eye\"> </i>`;\n td.className=\"text-green\";\n appendNode(tr,td);\n\n }\n if (JSON.parse(sessionStorage.current_user).role == \"admin\"){\n td = createNode('td')\n td.innerHTML=` <i id=\"${product['product_id']}\" onclick=\"showProductPane(this)\" class=\"fas fa-eye\"></i>`;\n td.className=\"text-green\";\n appendNode(tr,td);\n\n // add an edit button\n td = createNode('td')\n td.innerHTML=` <i class=\"fas fa-edit\" onclick=\"editProduct(${product['product_id']})\"></i>`;\n td.className=\"text-warn\";\n appendNode(tr,td);\n\n // add delete button\n td = createNode('td')\n td.innerHTML=` <i class=\"fas fa-trash\" onclick=\"deleteProduct(${product['product_id']})\"></i>`;\n td.className=\"text-red\";\n appendNode(tr,td);\n\n\n }\n\n appendNode(products_table,tr);\n rowNum +=1\n });\n\n });\n}", "title": "" }, { "docid": "1078e0f2e7f508d7b07e31baba4f6cde", "score": "0.6272502", "text": "function displayTable() {\n\n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n for (var i = 0; i < res.length; i++) {\n console.log(res[i].item_id + \" | \" + res[i].product_name + \" | \" + res[i].department_name + \" | \" + res[i].price + \" | \" + res[i].stock_quantity);\n\n\n }\n console.log(\"\\n\");\n console.log(\"------------------------------\");\n\n });\n}", "title": "" }, { "docid": "d8ef302ebceb0e228e92bb0b566d7ff9", "score": "0.6269989", "text": "function showProductsInStore(restart) {\n var query = \"SELECT * FROM products\";\n connection.query(query, function (err, res) {\n printProductTable(res, restart);\n })\n}", "title": "" }, { "docid": "9127b88c4a5c8ff57786e569af4b02a1", "score": "0.62637603", "text": "function displayProducts(product, output) {\n output += `\n <div class=\"card-dtl\">\n <div class=\"img\">\n <img src=\"${product.src}\" alt=\"product image\">\n <div class=\"dtl-list open\">\n <ul>\n <li class=\"product-dtl clr-light\">Product Details</li>\n <li class=\"dtl-list-item clr-light\">Model : ${product.modelNo}</li>\n <li class=\"dtl-list-item clr-light\">Brand : ${product.brand}</li>\n <li class=\"dtl-list-item clr-light\">Color : ${product.color}</li>\n <li class=\"dtl-list-item clr-light\">Available Stock : ${product.stock}</li>\n </ul>\n </div>\n </div>\n <div class=\"content\">\n <h2 class=\"product-heading clr-light\">${product.name}</h2>\n <p class=\"product-discript-dtl clr-light\" >${product.discrip}</p>\n <div class=\"dtl\"><a class=\"btn-dtl clr-light\">view details</a></div>\n <div class=\"abt-product open\">\n <ul>\n <li class=\"abt-head clr-light\">About This Product</li>\n <li class=\"abt-pnt clr-light\">${product.dtl[0]}</li>\n <li class=\"abt-pnt clr-light\">${product.dtl[1]}</li>\n <li class=\"abt-pnt clr-light\">${product.dtl[2]}</li>\n <li class=\"abt-pnt clr-light\">${product.dtl[3]}</li>\n <li class=\"abt-pnt clr-light\">${product.dtl[4]}</li>\n </ul>\n </div>\n <div class=\"price-tag\">\n <h2 class=\"price clr-light\">&euro; ${product.price}</h2>\n <a href=\"./basket.html\" class=\"btn-sec clr-light\" id=\"${product.productID}\">Buy Now</a>\n <i class=\"fas fa-shopping-cart icon clr-light\" id=\"${product.productID}\"></i>\n </div>\n </div>\n </div>`;\n return output;\n}", "title": "" }, { "docid": "9f8bd0e4c2b0840dd059f871862f5d6b", "score": "0.6258441", "text": "function showLowInventory() {\n var table = new Table({\n head: [\n \"ITEM ID\".red.bold.underline,\n \"PRODUCT NAME\".blue.bold.underline,\n \"DEPARTMENT\".green.bold.underline,\n \"PRICE\".yellow.bold.underline,\n \"STOCK\".magenta.bold.underline\n ],\n colWidths: [10, 40, 15, 10, 10],\n chars: {\n top: \"═\",\n \"top-mid\": \"╤\",\n \"top-left\": \"╔\",\n \"top-right\": \"╗\",\n bottom: \"═\",\n \"bottom-mid\": \"╧\",\n \"bottom-left\": \"╚\",\n \"bottom-right\": \"╝\",\n left: \"║\",\n \"left-mid\": \"╟\",\n mid: \"─\",\n \"mid-mid\": \"┼\",\n right: \"║\",\n \"right-mid\": \"╢\",\n middle: \"│\"\n }\n });\n connection.query(\"SELECT * FROM products WHERE stock_quantity<5\", function(\n err,\n res\n ) {\n for (var i = 0; i < res.length; i++) {\n table.push([\n (res[i].item_id + \"\").red,\n (res[i].product_name + \"\").blue,\n (res[i].department_name + \"\").green,\n (res[i].price + \"\").yellow,\n (res[i].stock_quantity + \"\").magenta\n ]);\n }\n console.log(table.toString() + \"\\n\");\n again();\n });\n}", "title": "" }, { "docid": "285686e389fae6385960d4a8d64750a3", "score": "0.6257144", "text": "function viewProducts(){\n\tconnection.query('SELECT * FROM products', function(err, res){\n\t\tif(err) throw err;\n\t\tconsole.log(\"Here is a list of all items in stock: \");\n\t\tconsole.log();\n\t\tfor(var key in res){\n\t\t\tconsole.log(\"Item Id: \" + res[key].item_id);\n\t\t\tconsole.log(\"Product Name: \" + res[key].product_name);\n\t\t\tconsole.log(\"Price: \" + res[key].price);\n\t\t\tconsole.log(\"Quantity: \" + res[key].stock_quantity);\n\t\t\tconsole.log();\n\t\t}\n\t})\n}", "title": "" }, { "docid": "7ae725ae1ab0278b4d8767f758a3e4f2", "score": "0.62551457", "text": "function viewProduct() {\n connection.query(`SELECT item_id, product_name, price, stock_quantity FROM products`, function (err, res) {\n if (err) throw err;\n res.forEach(function (item) {\n console.log(`\nID: ${item.item_id}\nProduct: ${item.product_name}\nPrice: ${item.price}\nStock: ${item.stock_quantity}\n-----------------------------------------------------`)\n });\n //Send user back to prompt screen\n logIn();\n });\n}", "title": "" }, { "docid": "178db4a0d51e2c9ca5e7fbdf2fcd1236", "score": "0.62528956", "text": "listDefautl(){\n let table = '';\n for(let i = 0; i < this.products.length; i++){\n table += this.products[i].infoHTML();\n }\n return table;\n }", "title": "" }, { "docid": "0ee9cea953055f75c0b90f6200fa313b", "score": "0.6239475", "text": "function displaySales(){\n \n var productsTable = new Table({\n head: [\"product_id\", \"product_name\", \"price\"], colWidths: [20, 20, 20]\n });\n\n var query = \"SELECT * FROM products\";\n\n connection.query(query, function(err, res) {\n if (err) throw err;\n for(i=0;i<res.length;i++){\n productsTable.push([res[i].item_id, res[i].product_name, res[i].price]);\n }\n //output productss table\n console.log(productsTable.toString());\n buyPrompt(res);\n\n });\n}", "title": "" }, { "docid": "5d80958a644f4e7e3772e0ea53fa105e", "score": "0.6220082", "text": "function readProducts() {\n // log(chalk.bg)\n log(chalk.green(\" Welcome to the Bamazon App,Here is the Current Inventory List\"));\n // log(chalk.red(\"--------------------------------------------------------\\n\"));\n log(chalk.green(\"**********************************************************\\n\"));\n log(chalk.red(\"----------------------------------------------------------------------\"));\n var query = connection.query(\"select item_id, product_name, price, stock_quantity from products\", function (err, res) {\n if (err) throw err;\n // Log all results of the SELECT statement\n for (var i = 0; i < res.length; i++) {\n maintable.push(res[i]);\n }\n var columns = columnify(maintable, {\n columnSplitter: ' | '\n });\n log(chalk.yellow(columns));\n log(chalk.red(\"----------------------------------------------------------------------\"));\n userDisplay();\n });\n\n\n}", "title": "" }, { "docid": "77df031c60f9e01dd58863b4d2d77096", "score": "0.6209347", "text": "function showProducts() {\n connection.query(\"SELECT item_id, product_name, format(price,2) as price FROM products\", function (err, results) {\n if (err) throw err;\n console.log(\"\\n\"+ columnify(results) + \"\\n\");\n makeSelection();\n });\n}", "title": "" }, { "docid": "b8439315ab864b7cf4da0035b423ad43", "score": "0.6197652", "text": "function viewProduct() {\n // list all items with id, names, prices, and quantities\n var query = \"SELECT * FROM products\";\n connection.query(query, function (err, res) {\n if (err) throw err;\n console.log(`--------------------`);\n for (var i = 0; i < res.length; i++) {\n console.log(`${res[i].item_id} ${res[i].product_name} $${res[i].price} \nQuantity: ${res[i].stock_quantity}\n `);\n };\n });\n}", "title": "" }, { "docid": "888dd49181e5fa2e5c5cbfc6bde8711c", "score": "0.61958855", "text": "function displayAll() {\n connection.query(\"SELECT id, product_name, department_name, price, stock_quantity FROM products\", function(err, res){\n if (err) throw err;\n console.log(\"\");\n console.log(' WELCOME TO BAMAZON ');\n var table = new Table({\n head: ['ID', 'Item', 'Department', 'Price', 'Stock'],\n colWidths: [10, 30, 30, 10, 10],\n });\n for (var i = 0; i < res.length; i++) {\n table.push([res[i].id, res[i].product_name, res[i].department_name, res[i].price, res[i].stock_quantity,]);\n }\n console.log(table.toString());\n productId();\n }); //end connection to products\n}", "title": "" }, { "docid": "d0992296c3b5f9f0b7269e5c677187f7", "score": "0.6191632", "text": "function viewProd() {\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err;\n console.log(\" I.D. | Product | Price | Quantity in stock\");\n console.log(\"------------------------------------------------\");\n\n for (var i = 0; i < res.length; i++) {\n console.log(\" \" + res[i].id + \" | \" + res[i].product_name + \" | \" + res[i].price + \" | \" + res[i].stock_quantity);\n console.log(\"------------------------------------------------\");\n }\n startApp();\n })\n}", "title": "" }, { "docid": "ad1fbe16d4bd9f0cc577a7fe0994490d", "score": "0.6182527", "text": "function showProducts() {\n \n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n for (var i = 0; i < res.length; i++) {\n\tconsole.log(res[i].item_id + \" | \" + res[i].product_name + \" | \" + res[i].department_name + \" | $\" + res[i].price + \" | \" + res[i].stock_quantity);\n\t}\n\tbuyItem();\n });\n}", "title": "" }, { "docid": "ede71e465d7262dbe71e5eec3c9cb2eb", "score": "0.6178118", "text": "function showAllFormattedItems() {\n var showquery = connection.query(\"SELECT * FROM bamazon.products;\", function (err, results) {\n if (err) throw err;\n // console.table(results);\n\n for (var i = 0; i < results.length; i++) {\n\n console.log(results[i].id + \":\" + results[i].product_name + \" | \" + results[i].department_name + \" |\\tcost \" + results[i].price + \" |\\t\" + results[i].quantity);\n }\n console.log(\"-----------------------------------\");\n questions();\n });\n}", "title": "" }, { "docid": "2f7ac5d5e6530614953fdabca11d888a", "score": "0.6175765", "text": "function displayItems() {\n connection.query(\"SELECT * FROM products\", function (err, res) {\n console.table(res);\n startShopping(res);\n })\n}", "title": "" }, { "docid": "0c97c89f60fcc305a805323b4226fadb", "score": "0.61750525", "text": "function show_products() {\n var data = { action : 'Show Product Table' };\n $.ajax({\n type: 'POST',\n url : url,\n data: data,\n cache: false,\n success:function(data) {\n $('#show_table').html(data);\n }\n })\n}", "title": "" }, { "docid": "c7d849fd32a7d5bd881bf07da23a4389", "score": "0.6170009", "text": "function displayAll() {\n // Query database for all products for sale\n connection.query(\"SELECT * FROM products\", function (err, results) {\n if (err) throw err;\n let productArr = [];\n for (var i = 0; i < results.length; i++) {\n productArr.push(new Product(results[i].item_id, results[i].product_name, results[i].price));\n }\n console.table(productArr);\n whichProduct();\n });\n}", "title": "" }, { "docid": "e14ca400d2b5a0a5214499eb62cc5ce0", "score": "0.616157", "text": "function displayProducts() {\n// connection.query(\"SELECT * FROM products\", function(err,results){\n connection.query(\"SELECT item_id, product_name, price FROM products\", function(err,results){\n if (err) throw err;\n\n\n console.log(\"----------------------------------------------------\\n\");\n console.log(\"--- Welcome to Bamazon! ---\\n\");\n console.log(\"--- Shop Today's Top Sellers! ---\\n\");\n console.log(\"----------------------------------------------------\\n\");\n \n // console.log(results);\n\n //show products in a table\n var table = new Table({\n head: [\"Product ID\", \"Product Name\", \"Price\"],\n colWidths: [12, 30, 8],\n colAligns: [\"center\", \"left\", \"right\"],\n style: { \n head: [\"aqua\"],\n compact: true\n }\n });\n for(var i=0; i<results.length; i++){\n //prints price in currency format\n var num =Number.parseFloat(results[i].price);\n var numString = num.toFixed(2);\n table.push([results[i].item_id, results[i].product_name, \"$\"+ numString]);\n } \n //add values to the table\n console.log(table.toString());\n console.log(\"\");\n });\n }", "title": "" }, { "docid": "09c55bbbea50cd91263280a285aba83b", "score": "0.6154546", "text": "function viewAllProducts() {\n console.log(\"Viewing All Products\");\n\n connection.query(\"SELECT * FROM Products\", function (err, res) {\n if (err) throw err;\n console.log(\" \")\n\n for (var i = 0; i < res.length; i++) {\n console.log(\"ID: \" + res[i].item_id + \" | \" + \"Product: \" + res[i].product_name + \" | \" + \"Deparment: \" + res[i].department_name\n + \" | \" + \"Price: \" + res[i].price + \" | \" + \"Quantity: \" + res[i].stock_quantity)\n }\n\n // start function\n start();\n });\n}", "title": "" }, { "docid": "6ffa3e42b6fbd9abfd2dee9aed7c28dc", "score": "0.61520773", "text": "function displayProductById(id){\n var table = new Table({\n head: ['Item Id', 'Product Name', 'Total Sales']\n , colWidths: [15, 65, 20]\n }); \n \nconnection.query('SELECT item_id, product_name, product_sales FROM products WHERE ?',{item_id: id}, function (error, results, fields) {\n // error will be an Error if one occurred during the query\n // results will contain the results of the query\n // fields will contain information about the returned results fields (if any)\n if(error) throw error;\n console.log(\"Product Sale Details\");\n console.log(\"---------------------\");\n results.forEach(function(item){\n //console.log(\"Id: \"+ item.item_id + \" || Name: \" + item.product_name +\" || Price: \"+ item.price);\n table.push([item.item_id, item.product_name, \"$\"+item.product_sales]);\n });\n console.log(table.toString());\n connection.end();\n });\n}", "title": "" }, { "docid": "1e0981144667a1d99a4dc4ec6777198f", "score": "0.6149401", "text": "function viewProducts() {\n db.query(\"SELECT * FROM products\", function(err, result){\n if (err) {\n console.log(err)\n } else {\n console.table(result)\n } \n })\n}", "title": "" }, { "docid": "0ed60b46ba191e269c470a58780e4719", "score": "0.6148801", "text": "function createProductTable(product) {\r\n var productTable = document.createElement('table');\r\n\r\n for (var row = 0; row < product.length; row++) {\r\n var productRow = document.createElement('tr');\r\n for (var col = 0; col < product[row].length; col++) {\r\n var productComponent = document.createElement('td');\r\n productComponent.className = 'prod-result';\r\n var componentValue = document.createTextNode(product[row][col]);\r\n productComponent.appendChild(componentValue);\r\n productRow.appendChild(productComponent);\r\n }\r\n productTable.appendChild(productRow);\r\n }\r\n\r\n return productTable;\r\n}", "title": "" }, { "docid": "e9987bffcce3728e8e11c9c63dc9cceb", "score": "0.6147545", "text": "function loadProducts () {\n\n\t\tvar productContainer = document.getElementById('productList');\n\n\t\tfor ( var product in scope.productList ) {\n\t\t\tdisplayProduct(productContainer, scope.productList[product], product);\n\t\t}\n\n\t}", "title": "" }, { "docid": "e8c79e24aea9110691482c548df86bd6", "score": "0.61451155", "text": "function view_products() {\n var self = this;\n var options = U.clone(self.query);\n\n // Total.js monitoring fulltext stats\n self.query.search && MODULE('webcounter').inc('fulltext');\n\n // DB\n self.$query(options, function (err, response) {\n if (self.query.manufacturer)\n self.repository.manufacturer = F.global.manufacturers.findItem('linker', self.query.manufacturer);\n self.view('products-all', response);\n });\n}", "title": "" }, { "docid": "d10c7bf50317fd0e9b0fe7dab5017178", "score": "0.6145019", "text": "function viewProduct(){\n\n let query = \"SELECT departments.department_id,departments.department_name,departments.over_head_costs,SUM(products.product_sales) AS product_sales, (SUM(products.product_sales) - departments.over_head_costs) AS total_profit FROM products LEFT JOIN departments ON departments.department_name = products.department_name GROUP BY departments.department_name\"\n connection.query(query, function(err, profit){\n if(err) throw err;\n // console.log(profit)\n\n // Create a Table \n const table = cTable.getTable(profit);\n\n // console logging the table created\n console.log(\"\\nSupervisor Net Profit Sheet\\n\".bold.blue)\n console.log(table);\n continueWithBamazon()\n })\n }", "title": "" }, { "docid": "7003ba26c6e8335086ee945ceea622bf", "score": "0.6141136", "text": "function viewProducts() {\n\n // get all products from table and go through them all displaying each piece of info \n\n connection.query(\"SELECT * FROM products\", function (err, res) {\n\n // throw err if error\n\n for (var i = 0; i < res.length; i++) {\n console.log(\"Product Name: \" + res[i].product_name);\n console.log(\"Item Number: \" + res[i].item_id);\n console.log(\"Department: \" + res[i].department_name);\n console.log(\"Quantity in Stock: \" + res[i].stock_quantity);\n console.log(\"Price: $\" + (res[i].price).toFixed(2));\n console.log(\"-----------------------------------\");\n }\n });\n}", "title": "" }, { "docid": "230d2a8cbd3394576ac75f4a6bde03ff", "score": "0.61401474", "text": "function displayProductList(tabName) {\r\n \r\n // Show the selected table\r\n styleDisplay();\r\n \r\n if (tabName == 'best') {\r\n $('#BestProductsPanel').show();\r\n document.getElementById('BestProductsPanel').style.display = 'block';\r\n }\r\n else {\r\n $('#' + loadedTables[tabName] + '_wrapper').show()\r\n //var tab = loadedTables[tabName]+'_wrapper';\r\n //document.getElementById(tab).style.display = 'block';\r\n }\r\n\r\n // Hide the current table\r\n if (currentTab == 'best') {\r\n $('#BestProductsPanel').hide();\r\n //document.getElementById('BestProductsPanel').style.display = 'block';\r\n }\r\n else {\r\n $('#' + loadedTables[currentTab] + '_wrapper').hide();\r\n //var ctab = loadedTables[currentTab]+'_wrapper';\r\n //document.getElementById(ctab).style.display = 'block';\r\n //document.getElementById('favorites_wrapper').style.display = 'none';\r\n \r\n }\r\n // set the current tab\r\n console.log(tabName);\r\n currentTab = tabName;\r\n}", "title": "" }, { "docid": "9b50894bb1e30dc51e4fea2afeb0adbe", "score": "0.6138614", "text": "function displayProducts() {\n console.log(\"Welcome to Bamazon!!!\\n\");\n\n var tableItems = [];\n connection.query(\"SELECT * FROM products\", function (err, res) {\n for (var i = 0; i < res.length; i++) {\n tableItems.push(\n {\n ID: res[i].item_id,\n Product_Name: res[i].product_name,\n Department: res[i].department_name,\n Price: res[i].price,\n Quantity: res[i].stock_quantity\n }\n );\n }\n const table = cTable.getTable(tableItems);\n console.log(table);\n\n buyItems();\n });\n}", "title": "" }, { "docid": "d89aec2ab75bd4bb4ce1a71e52f521df", "score": "0.6133958", "text": "function showProducts() {\n const query = \"SELECT * FROM products\";\n connection.query(query, function(err, res) {\n if (err) throw err;\n for (var i = 0; i < res.length; i++) {\n console.log(\n \"\\nItem ID: \" + res[i].item_id + \n \"\\nProduct Name: \" + res[i].product_name + \n \"\\nPrice: \" + \"$\" + res[i].price + \"\\n*~*~*~*~*~*~*~\\n\")\n }\n })\n }", "title": "" }, { "docid": "a847467118bdecee6456b2dc7aff42b5", "score": "0.6132178", "text": "function updateProductInfo() {\n if (window.innerWidth < 440) { // If window width < 440px\n productAvailable.firstElementChild.textContent = `In Stock`; // Set product availability to short version\n } else {\n productAvailable.firstElementChild.textContent = `In Stock ~ ${productPage.available} available`; // Set product availability to long version\n }\n}", "title": "" }, { "docid": "de53f308c3cedcfa41e153231b9888a1", "score": "0.6130294", "text": "showComboProducts(combos) {\n var lenCombo = combos.length;\n var html = \" \";\n if (lenCombo > 0) {\n for (var r = 0, lengthCombo = lenCombo; r < lengthCombo; r++) {\n var comboPro = combos[r][\"menu_product_name\"];\n var comboQty = combos[r][\"menu_product_qty\"];\n var comboPrice = combos[r][\"menu_product_price\"];\n var newPrice = comboPrice > 0 ? \" (+\" + comboPrice + \")\" : \"\";\n var comboQtyChk = comboQty !== \"\" ? parseInt(comboQty) : 0;\n if (comboQtyChk > 0) {\n html += \"<p>\" + comboQty + \" X \" + comboPro + newPrice + \" </p> \";\n }\n }\n return html;\n }\n return \"\";\n }", "title": "" }, { "docid": "1f836f5b61a17255b55304b34fb268e9", "score": "0.6126143", "text": "function viewProducts(){\n connection.query('SELECT * FROM `products`', function(err, res){\n if (err) console.log(err);\n for (let z = 0; z < res.length; z++){\n console.table(res[z]);\n }\n mainReplay();\n });\n}", "title": "" }, { "docid": "759c79483ff84be68eb6a85dd1f1479d", "score": "0.612334", "text": "function displayProduct(product) {\n let div = document.createElement('div');\n let img = document.createElement('img');\n let h4 = document.createElement('h4');\n let p = document.createElement('p');\n let h6 = document.createElement('h6');\n let a = document.createElement('a');\n\n div.setAttribute('class', 'products');\n img.setAttribute('src', 'images/' + product.img);\n h4.innerText = product.name;\n p.innerText = 'Model Name: ' + product.modue;\n h6.innerText = product.price + '.00';\n a.innerText = 'add to cart';\n a.setAttribute('href', '#');\n\n div.appendChild(img);\n div.appendChild(h4);\n div.appendChild(p);\n div.appendChild(h6);\n div.appendChild(a);\n main.appendChild(div);\n }", "title": "" }, { "docid": "db0977d866c3345443f7564da5934c8b", "score": "0.6117838", "text": "function loadProducts() {\n connection.query(\"SELECT * FROM products\", function (err, res) {\n if (err) throw err\n console.log(chalk.blue('Welcome to Bamazon!'));\n //displays items in a table\n console.table(res);\n\n //then prompt the customer for choice of item\n promptCustomerForItem();\n\n })\n}", "title": "" } ]
6cb8d7f4cf0736235b5e786dc2d154f6
connect element first with element difference
[ { "docid": "843dcd8464ee1f6fb08cb217147f6c59", "score": "0.49341798", "text": "function connectArray(arrayFirst) {\n let arrayDouble = [];\n arrayDouble.push(arrayFirst)\n for (let i = 0; i < arrayInitial.length; i++) {\n arrayDouble.push(arrayInitial[i]);\n console.log(arrayDouble);\n }\n // console.log(arrayDouble);\n}", "title": "" } ]
[ { "docid": "e69ae35aedb7bb7ff31906d1f431eb9a", "score": "0.5743456", "text": "function ElementMerger(arr) { \n while(arr.length > 1){\n let newArr = []\n for(let i = 0; i < arr.length - 1; i++){\n let curr = arr[i];\n let next = arr[i + 1];\n let diff = Math.abs(next - curr);\n newArr.push(diff);\n }\n arr = newArr\n }\n \n // code goes here \n return arr[0]; \n\n}", "title": "" }, { "docid": "eb2083bf537b0fecbf4ce9571b2a841b", "score": "0.5521648", "text": "union(n1, n2) {\n // console.log(\"Union between \" + n1 + ' ' + n2);\n var prev = this.table[n2];\n for(var i=0; i<this.table.length;i++){\n if(this.table[i] == prev){\n this.table[i] = this.table[n1];\n }\n }\n }", "title": "" }, { "docid": "0c4eca1eeb64b3eba94847f8c2e560a4", "score": "0.5486713", "text": "difference(first, second) {\n if (null === first || null === second) {\n return {\n x: 0,\n y: 0,\n };\n }\n return {\n x: first.x - second.x,\n y: first.y - second.y\n };\n }", "title": "" }, { "docid": "668b41eda11131505e5653f12dd1fd2c", "score": "0.5403491", "text": "function nonMutatingConcat(original, attach) {\n // Add your code below this line\n return first.concat(second);\n\n // Add your code above this line\n}", "title": "" }, { "docid": "e1638d874ca40cb13f46567e9b994e1e", "score": "0.533208", "text": "function funcionDeComparacao (elem1, elem2) { return (elem2 - elem1); }", "title": "" }, { "docid": "4fe0d902e4ac74d4db9b533280f60037", "score": "0.5305134", "text": "function adjugate(H){\n return [[H[1][1], -H[1][0]], [-H[0][1], H[0][0]]];\n}", "title": "" }, { "docid": "bca407cfdf23bfa1ef75f4a1827128e2", "score": "0.5301478", "text": "function spotTheDifferences(before, after) {\n\n function rec(before, after) {\n\n var nbBefore = before.children().length;\n var nbAfter = after.children().length;\n if (nbBefore !== nbAfter) {\n return [{\n \"removed\": before,\n \"added\": after,\n }];\n }\n\n var nbChildren = nbBefore;\n if (nbChildren === 0) { // both leaves\n if (before.html() !== after.html()) {\n return [{\n \"removed\": before,\n \"added\": after,\n }];\n } else {\n return [];;\n }\n }\n\n var everyChildChanged = true;\n\n var childrenChanges = _.range(nbChildren).reduce(function(acc, i) {\n var tmp = rec($(before.children()[i]), $(after.children()[i]));\n if (tmp.length === 0) { everyChildChanged = false; }\n return acc.concat(tmp);\n }, [])\n ;\n\n if (everyChildChanged) {\n return [{\n \"removed\": before,\n \"added\": after,\n }];\n } else {\n return childrenChanges;\n }\n\n }\n\n var removed = [];\n var added = [];\n\n _(rec($(before).children(), $(after).children())).each(function(pair, ndx) {\n pair.removed.css(\"background-color\", diffColor(ndx));\n pair.added.css(\"background-color\", diffColor(ndx));\n //removed.push(pair.removed);\n //added.push(pair.added);\n });\n\n return {\"removed\": removed, \"added\": added};\n}", "title": "" }, { "docid": "c25ff5d785ee7c254f1677fbb1e7cf0c", "score": "0.52839136", "text": "function swapDOMElements(domEle1, domEle2) {\n var parent2 = domEle2.parentNode;\n var next2 = domEle2.nextSibling;\n if (next2 === domEle1) {\n parent2.insertBefore(domEle1, domEle2);\n } else {\n domEle1.parentNode.insertBefore(domEle2, domEle1);\n if (next2) {\n parent2.insertBefore(domEle1, next2);\n } else {\n parent2.appendChild(domEle1);\n }\n }\n}", "title": "" }, { "docid": "a0c9567e9aa063b02cac535aaf863c0b", "score": "0.5278914", "text": "_combine(sub, main) {\n for (const to of Array.from(sub.start)) {\n for (const from of Array.from(main.end)) {\n from.connect(to, sub.multi);\n }\n }\n\n main.end = sub.end;\n return (main.nodes = main.nodes.concat(sub.nodes));\n }", "title": "" }, { "docid": "bc1aedb2f0b961bee8add9464b4475cb", "score": "0.5277936", "text": "function pass2(elem) {\n var min = blockG.outEdges(elem).reduce(function(acc, e) {\n return Math.min(acc, xs[e.w] - blockG.edge(e));\n }, Number.POSITIVE_INFINITY);\n\n var node = g.node(elem);\n if (min !== Number.POSITIVE_INFINITY && node.borderType !== borderType) {\n xs[elem] = Math.max(xs[elem], min);\n }\n }", "title": "" }, { "docid": "ea38b170e5d9267110baca595f4d36ff", "score": "0.526879", "text": "function Unite(NewGraph,u,v,w,p) {\n\tvar weight, weight1 = w;\n\tvar ptr1 = NewGraph[u];\n\tvar ptr = NewGraph[v];\n\tconsole.log(ptr);\n\tconsole.log(ptr1);\n\tvar temp;\n\t/* loop which attaches each element of the second set to the \n\t * first set untill we get broken edge which has its weight set to 0\n\t * and it parent point to itself */\n\twhile(ptr.data != ptr1.data) { \n\t\ttemp = NewGraph[ptr.parent];\n\t\tweight = weight1;\n\t\tweight1 = ptr.weight;\n\t\tptr.parent = ptr1.data;\n\t\tptr.p = p; /* setting the representative element of element in the second set\n\t\t\t\t\t* to the representative element of the first set*/\n\t\tptr.weight = weight;\n\t\tptr1 = ptr;\n\t\tptr = temp;\n\t}\n}", "title": "" }, { "docid": "2a797902f3a6083959c647494d59067c", "score": "0.5257155", "text": "insertTwo(element){\n this.values.push(element);\n this.bubbleUp();\n return this.values;\n }", "title": "" }, { "docid": "aae80a3ccaf9d8c264cd423c923f5692", "score": "0.5235665", "text": "function addTwoLists(currNode1, currNode2) {\n\n // var currNode1 = l1; // p1\n // var currNode2 = l2; // p2\n var currNode3 = new Node();\n var previous = null;\n // console.log(currNode1.element);\n// while (!(currNode1 == null)) {\n // // save next or you lose it!!!\n // var save = currNode1.next;\n // // reverse pointer\n // currNode1.next = previous;\n // // increment previous to current node\n // previous = currNode1;\n // // increment node to next node or null at end of list\n // currNode1 = save;\n// currNode1.element.reverse();\n// console.log(previous.element);\n// }\n // while (!(p1 == null && p2 == null)) {\n //\n // }\n}", "title": "" }, { "docid": "bebfe1a3f0abf895cbdbb4bb9ceda37a", "score": "0.52329296", "text": "addEdge(v1, v2) {\n v1.adjacent.add(v2);\n v2.adjacent.add(v1);\n }", "title": "" }, { "docid": "bebfe1a3f0abf895cbdbb4bb9ceda37a", "score": "0.52329296", "text": "addEdge(v1, v2) {\n v1.adjacent.add(v2);\n v2.adjacent.add(v1);\n }", "title": "" }, { "docid": "bebfe1a3f0abf895cbdbb4bb9ceda37a", "score": "0.52329296", "text": "addEdge(v1, v2) {\n v1.adjacent.add(v2);\n v2.adjacent.add(v1);\n }", "title": "" }, { "docid": "bebfe1a3f0abf895cbdbb4bb9ceda37a", "score": "0.52329296", "text": "addEdge(v1, v2) {\n v1.adjacent.add(v2);\n v2.adjacent.add(v1);\n }", "title": "" }, { "docid": "625d01209dd3590b7803df0c9e2e226e", "score": "0.523084", "text": "addEdge(v1, v2) {\n for (let node of this.nodes) {\n if (node === v1) {\n node.adjacent.add(v2);\n }\n if (node === v2) {\n node.adjacent.add(v1);\n }\n }\n }", "title": "" }, { "docid": "64925bc533660f0cb0b5bf84411715b5", "score": "0.5230017", "text": "static connectVertex(_v1 , _v2 ){\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n const e1 = new Edges( _v1 ,_v2 , couleur ) ;\n // eslint-disable-next-line @typescript-eslint/no-use-before-define\n const e2 = new Edges( _v2 , _v1 , couleur) ;\n _v1.listEdges.push( e1 ) ;\n _v1.listEdges.push( e2 ) ;\n _v2.listEdges.push( e1 );\n _v2.listEdges.push( e2 );\n return [e1,e2]\n }", "title": "" }, { "docid": "d6874840f1a7061aa16c85d006a700e2", "score": "0.5221977", "text": "function pass2(elem) {\n var min = blockG.outEdges(elem).reduce(function(acc, e) {\n return Math.min(acc, xs[e.w] - blockG.edge(e));\n }, Number.POSITIVE_INFINITY);\n\n var node = g.node(elem);\n if (min !== Number.POSITIVE_INFINITY && node.borderType !== borderType) {\n xs[elem] = Math.max(xs[elem], min);\n }\n }", "title": "" }, { "docid": "05678d5fcd978af147c551e7682dd33a", "score": "0.5210442", "text": "function connectEdge(n0, n1) {\n\tsetModifiedFlag();\n\tconsole.log(\"connectEdge()\");\n\n\tvar selection_nodes = [n0, n1];\n\n\t// operation from selection\n\tif (n0 == null || n1 == null) {\n\t\tselection_nodes = getSelectedNodes();\n\t\tif (selection_nodes.length != 2) {\n\t\t\tthrow new Error().message = arguments.callee.name + \" : selection_nodes.length != 2...\";\n\t\t}\n\t}\n\n\tif (findEdgeByNodeDirection(selection_nodes[0], selection_nodes[1]).length > 0) {\n\t\tclearSelectedObjects();\n\t\tthrow new Error().message = arguments.callee.name + \" : already exists edge...\";\n\t}\n\n\tvar e = new Edge(svg_edge_layer, selection_nodes[0], selection_nodes[1]);\n\tedges.push(e);\n\n\tclearSelectedObjects();\n\n\treturn e;\n}", "title": "" }, { "docid": "e521becd2567461dd594a137bc36c95b", "score": "0.52094096", "text": "function pass2(elem) {\n var min = blockG.outEdges(elem).reduce(function(acc, e) {\n return Math.min(acc, xs[e.w] - blockG.edge(e));\n }, Number.POSITIVE_INFINITY);\n\n var node = g.node(elem);\n if (min !== Number.POSITIVE_INFINITY && node.borderType !== borderType) {\n xs[elem] = Math.max(xs[elem], min);\n }\n }", "title": "" }, { "docid": "e521becd2567461dd594a137bc36c95b", "score": "0.52094096", "text": "function pass2(elem) {\n var min = blockG.outEdges(elem).reduce(function(acc, e) {\n return Math.min(acc, xs[e.w] - blockG.edge(e));\n }, Number.POSITIVE_INFINITY);\n\n var node = g.node(elem);\n if (min !== Number.POSITIVE_INFINITY && node.borderType !== borderType) {\n xs[elem] = Math.max(xs[elem], min);\n }\n }", "title": "" }, { "docid": "e521becd2567461dd594a137bc36c95b", "score": "0.52094096", "text": "function pass2(elem) {\n var min = blockG.outEdges(elem).reduce(function(acc, e) {\n return Math.min(acc, xs[e.w] - blockG.edge(e));\n }, Number.POSITIVE_INFINITY);\n\n var node = g.node(elem);\n if (min !== Number.POSITIVE_INFINITY && node.borderType !== borderType) {\n xs[elem] = Math.max(xs[elem], min);\n }\n }", "title": "" }, { "docid": "ab5ca0640bd6a6e4a3cb7b4be3c19de7", "score": "0.5188608", "text": "addEdge (v1, v2) {\n\t\tv1.adjacent.add(v2);\n\t\tv2.adjacent.add(v1);\n\t}", "title": "" }, { "docid": "81740d8ec8c8cba3b499658f12274e4c", "score": "0.5188347", "text": "function orderCrossover(firstPath, secondPath) {\n\tvar firstChild = [];\n\n\tvar i = Math.floor(firstPath.length * getRandomIntInclusive(0, 1) );\n\tvar j = Math.floor(firstPath.length * getRandomIntInclusive(0, 1) );\n\tvar first = Math.min(i, j);\n\tvar second = Math.max(i, j);\n\n\tfor (i = first; i <= second; i++) {\n\t\tfirstChild[i] = firstPath[i];\n\t}\n\n\tvar indexInSecond = 0;\n\tfor ( i = 0; i < firstPath.length; i++) {\n\t\tif (i >= first && i <= second) {\n\t\t\tcontinue;\n\t\t}\n\t\t// omit points already added\n\t\twhile (contains(firstChild, secondPath[indexInSecond], first, second)) {\n\t\t\tindexInSecond++;\n\t\t}\n\t\tfirstChild[i] = secondPath[indexInSecond];\n\t\tindexInSecond++;\n\t}\n\treturn firstChild;\n}", "title": "" }, { "docid": "927340967b2a1784dd435c766b823dab", "score": "0.51581395", "text": "function connectVerts(v0, v1) {\n v0.edges.push(new Edge(v1));\n v1.edges.push(new Edge(v0));\n }", "title": "" }, { "docid": "4aa2195c31b1adc88571b9a62e0917d2", "score": "0.514949", "text": "function relativeComplement(one, other) {\n var result = [];\n var i = 0, j = 0;\n while (i < one.length || j < other.length) {\n if (i >= one.length) {\n result.push(other[j++]);\n }\n else if (j >= other.length) {\n result.push(one[i++]);\n }\n else if (one[i] === other[j]) {\n i++;\n j++;\n continue;\n }\n else if (one[i] < other[j]) {\n result.push(one[i++]);\n }\n else {\n j++;\n }\n }\n return result;\n}", "title": "" }, { "docid": "bdaf721613ebe691edf0b55b729535ef", "score": "0.51052845", "text": "function mergeContents(element1, element2) {\n while (element2.firstChild) {\n element1.appendChild(element2.firstChild);\n }\n element2.parentNode.removeChild(element2);\n }", "title": "" }, { "docid": "bdaf721613ebe691edf0b55b729535ef", "score": "0.51052845", "text": "function mergeContents(element1, element2) {\n while (element2.firstChild) {\n element1.appendChild(element2.firstChild);\n }\n element2.parentNode.removeChild(element2);\n }", "title": "" }, { "docid": "90df16f3a5013a79d2088f57f7322c7a", "score": "0.5099938", "text": "function nodesByPosition(first, second) {\n return first.pos - second.pos;\n}", "title": "" }, { "docid": "16a1d4acabb741afea678791c0e817d6", "score": "0.5075455", "text": "function diff( o, n ) {\r\n var ns = new Object();\r\n var os = new Object();\r\n \r\n for ( var i = 0; i < n.length; i++ ) {\r\n if ( ns[ n[i] ] == null )\r\n ns[ n[i] ] = { rows: new Array(), o: null };\r\n ns[ n[i] ].rows.push( i );\r\n }\r\n \r\n for ( var i = 0; i < o.length; i++ ) {\r\n if ( os[ o[i] ] == null )\r\n os[ o[i] ] = { rows: new Array(), n: null };\r\n os[ o[i] ].rows.push( i );\r\n }\r\n \r\n for ( var i in ns ) {\r\n if ( ns[i].rows.length == 1 && typeof(os[i]) != \"undefined\" && os[i].rows.length == 1 ) {\r\n n[ ns[i].rows[0] ] = { text: n[ ns[i].rows[0] ], row: os[i].rows[0] };\r\n o[ os[i].rows[0] ] = { text: o[ os[i].rows[0] ], row: ns[i].rows[0] };\r\n }\r\n }\r\n \r\n for ( var i = 0; i < n.length - 1; i++ ) {\r\n if ( n[i].text != null && n[i+1].text == null && n[i].row + 1 < o.length && o[ n[i].row + 1 ].text == null && \r\n n[i+1] == o[ n[i].row + 1 ] ) {\r\n n[i+1] = { text: n[i+1], row: n[i].row + 1 };\r\n o[n[i].row+1] = { text: o[n[i].row+1], row: i + 1 };\r\n }\r\n }\r\n \r\n for ( var i = n.length - 1; i > 0; i-- ) {\r\n if ( n[i].text != null && n[i-1].text == null && n[i].row > 0 && o[ n[i].row - 1 ].text == null && \r\n n[i-1] == o[ n[i].row - 1 ] ) {\r\n n[i-1] = { text: n[i-1], row: n[i].row - 1 };\r\n o[n[i].row-1] = { text: o[n[i].row-1], row: i - 1 };\r\n }\r\n }\r\n \r\n return { o: o, n: n };\r\n}", "title": "" }, { "docid": "9b529c48208ffcd071e1f0c0f69514bf", "score": "0.5052641", "text": "function Diff() {}", "title": "" }, { "docid": "6331398ecf2958712368a9329e7bb0c3", "score": "0.5051088", "text": "function order(a, b) {\r\n\treturn +b.value - +a.value;\r\n}", "title": "" }, { "docid": "d1f6f7657dc0d57ae24f4f6834b59025", "score": "0.50407517", "text": "function compare(A,Aid,B,Bid,godeep) {\n\t\n\tif (first) {\n\t\tlet Aval = \"\"+A.outerHTML, Bval = \"\"+B.outerHTML;\n\t\tif (Aval.length > 1024) {\n\t\t\tAval = Aval.substr(0,1000)+'...['+(Aval.length-1000)+' more not shown]';\n\t\t}\n\t\tif (Bval.length > 1024) {\n\t\t\tBval = Bval.substr(0,1000)+'...['+(Bval.length-1000)+' more not shown]';\n\t\t}\n\t\tdocument.getElementById('htmA').value = Aval;\n\t\tdocument.getElementById('htmB').value = Bval;\n\t\tfirst = false;\n\t\tif (A === B) {\n\t\t\taddlog('Those are identical (the same node)');\n\t\t\treturn;\n\t\t}\n\t}\n\t\n\tif (A.nodeName != B.nodeName) {\n\t\taddlog(Aid+' is <'+A.nodeName+'>, '+Bid+' is <'+B.nodeName+'>.');\n\t}\n\tfor (let a=0; a<A.attributes.length; a++) {\n\t\tlet key = A.attributes[a].name,\n\t\t other = B.attributes[key];\n\t\tif (other !== undefined) {//both have attr.\n\t\t\tif (A.attributes[a].value != other.value) {\n\t\t\t\taddlog(Aid+' has attr '+key+'='+(A.attributes[key].value || 'undefined'));\n\t\t\t\taddlog(Bid+' has attr '+key+'='+(B.attributes[key].value || 'undefined'));\n\t\t\t}\n\t\t} else {\n\t\t\taddlog(Aid+' has attr '+key+'='+(A.attributes[key].value || 'undefined')+', not in other el.')\n\t\t}\n\t}\n\t//Also check for the other's unique attr:\n\tfor (let b=0; b<B.attributes.length; b++) {\n\t\tlet key = B.attributes[b].name,\n\t\t other = A.attributes[key];\n\t\tif (other === undefined) {\n\t\t\taddlog(Bid+' has attr ' +\n\t\t\t key + '=' + (B.attributes[key].value || 'undefined') + ', not in other el.')\n\t\t}\n\t}\n\t//This doesn't work with clones\n\tvar cssA = A.ownerDocument.defaultView.getComputedStyle(A,null),\n\t cssB = B.ownerDocument.defaultView.getComputedStyle(B,null);\n\t\n\tfor (let i=0; i<cssA.length; i++) {\n\t\tif (cssA.getPropertyValue(cssA[i]) != cssB.getPropertyValue(cssB[i])) {\n\t\t\taddlog(Aid+' css '+cssA[i]+'='+cssA.getPropertyValue(cssA[i]));\n\t\t\taddlog(Bid+' css '+cssB[i]+'='+cssB.getPropertyValue(cssB[i]));\n\t\t}\n\t}\n\t\n\t//If applicable, check before/after.\n\tif( document.getElementById('checkBefore').checked ) {\n\t cssA = A.ownerDocument.defaultView.getComputedStyle(A, ':before')\n\t cssB = B.ownerDocument.defaultView.getComputedStyle(B, ':before');\n\t let contentA = cssA['content'], contentB = cssB['content'];\n\t if( contentA != 'none' || contentB != 'none') {\n\t\t//One or both have a before.\n\t\tif( contentA === 'none' ) {\n\t\t addlog(Bid+' has :before element, A does not, here.');\n\t\t} else if ( contentB === 'none' ) {\n\t\t addlog(Aid+' has :before element, B does not, here.');\n\t\t} else {\n\t\t //Both. compare:\n\t\t for (let i=0; i<cssA.length; i++) {\n\t\t\tif (cssA.getPropertyValue(cssA[i]) != cssB.getPropertyValue(cssB[i])) {\n\t\t\t\taddlog(Aid+':before css '+cssA[i]+'='+cssA.getPropertyValue(cssA[i]));\n\t\t\t\taddlog(Bid+':before css '+cssB[i]+'='+cssB.getPropertyValue(cssB[i]));\n\t\t\t}\n\t\t }\n\t\t}\n\t }\n\t \n\t}\n\t//TODO maybe de-duplicate these two with a function('before/after') if any more is added.\n\tif( document.getElementById('checkAfter').checked ) {\n\t cssA = A.ownerDocument.defaultView.getComputedStyle(A, ':after');\n\t cssB = B.ownerDocument.defaultView.getComputedStyle(B, ':after');\n\t let contentA = cssA['content'], contentB = cssB['content'];\n\t if( contentA != 'none' || contentB != 'none') {\n\t\t//One or both have a after.\n\t\tif( contentA === 'none' ) {\n\t\t addlog(Bid+' has :after element, A does not, here.');\n\t\t} else if ( contentB === 'none' ) {\n\t\t addlog(Aid+' has :after element, B does not, here.');\n\t\t} else {\n\t\t //Both. compare:\n\t\t for (let i=0; i<cssA.length; i++) {\n\t\t\tif (cssA.getPropertyValue(cssA[i]) != cssB.getPropertyValue(cssB[i])) {\n\t\t\t\taddlog(Aid+':after css '+cssA[i]+'='+cssA.getPropertyValue(cssA[i]));\n\t\t\t\taddlog(Bid+':after css '+cssB[i]+'='+cssB.getPropertyValue(cssB[i]));\n\t\t\t}\n\t\t }\n\t\t}\n\t }\n\t \n\t}\n\t\n\tif (A.children.length !== B.children.length) {\n\t\taddlog(Aid+' has '+A.children.length+' children, '+Bid+' has '+B.children.length);\n\t}\n\tif (A.textContent !== B.textContent) {\n\t\taddlog(Aid+' textContent differs from '+Bid);\n\t}\n\tif (godeep > 0) {\n\t\tfor (let i=0; i<A.children.length; i++) {\n\t\t\tif (i< B.children.length) { //compare it\n\t\t\t\tcompare(A.children[i], Aid+'.children['+i+']',\n\t\t\t\t\t\tB.children[i], Bid+'.children['+i+']', godeep-1)\n\t\t\t}\n\t\t}\n\t}\n}", "title": "" }, { "docid": "2cf952868d3ca9b64abd3dbea2992ae5", "score": "0.50357854", "text": "function addCompareLinks() {\n $(\".trims-container, .cars-container\").children().each(function(idx, value) {\n if ($(value).hasClass('style')) {\n var compareLink = compareLinks[idx];\n var trimDivider = trimDividers[idx];\n $(value).before(compareLink);\n $(value).after(trimDivider);\n }\n });\n }", "title": "" }, { "docid": "bb14a8c8fc4dabd09ec553db81b36d6c", "score": "0.50221664", "text": "function prepend(elem,prev){var parent=elem.parent;if(parent){var childs=parent.children;childs.splice(childs.lastIndexOf(elem),0,prev);}if(elem.prev){elem.prev.next=prev;}prev.parent=parent;prev.prev=elem.prev;prev.next=elem;elem.prev=prev;}", "title": "" }, { "docid": "e4d86dcb54457deb4760c90eb3b88a43", "score": "0.50220054", "text": "union(first, second) {\n let firstID = this.array[first];\n let secondID = this.array[second];\n\n for(let i = 0; i <= this.array.length; i++) {\n if(this.array[i] == firstID) {\n this.array[i] = secondID;\n }\n }\n console.log(this.array);\n }", "title": "" }, { "docid": "88423621138107233ba0174fbdfd8787", "score": "0.5021938", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + \",\" + b.index];\n }", "title": "" }, { "docid": "52c71eb3a1501d4727f5564229870496", "score": "0.5004347", "text": "function caminodirecto(lista1, lista2, listaligada)\n{\n\tvar lista_resultado = new LinkedList();\n\tif(lista1.length==1&&lista2.length==1)\n\t{\n\t\tvar linea = lista1[0].idlinea;\n\t\tvar estacion1 = lista1[0].idestacion;\n\t\tvar estacion2 = lista2[0].idestacion;\n\t\tlista_resultado.add(lista1[0]);\n\t\tvar operacion;\n\t\tif(estacion1>estacion2)\n\t\t{\n\t\t\toperacion=1;\n\t\t}else{\n\t\t\toperacion=0;\n\t\t}\n\n\t\tdo\n\t\t{\n\t\t\tif(operacion==1)\n\t\t\t{\n\t\t\t\testacion1--;\n\t\t\t}else{\n\t\t\t\testacion1++;\n\t\t\t}\n\t\t\tif(listaligada.get(estacion1).idestacion!=estacion2)\n\t\t\t{\n\t\t\t\tlista_resultado.add(listaligada.get(estacion1));\n\t\t\t}else{\n\t\t\t\tlista_resultado.add(listaligada.get(estacion2));\n\t\t\t\treturn lista_resultado;\n\t\t\t}\n\t\t\t\n\t\t}while(estacion1!=estacion2);\n\t}else\n\t{\n\t\t//Este caso sera para los casos en el que el nodo que estamos evaluando es una estacion de cruce\n\t\tvar lineacompartida = compartenlineas(lista1, lista2, 1);\n\t\tif(lineacompartida)\n\t\t{\n\t\t\t//Existen 2 casos\n\t\t\t//Que ambos puntos sean estacion de cruce\n\t\t\tif(lista1.length>1&&lista2.length>1)\n\t\t\t{\n\t\t\t\t//si ambos son nodos de cruce entonces necesito los 2 objetos que compartan linea\n\t\t\t\tlet a=0;\n\t\t\t\t//realizamos 2 ciclos para recorrer las listas en busca de la linea que tengan en comun\n\t\t\t\tfor(a=0;a<lista1.length;a++)\n\t\t\t\t{\n\t\t\t\t\tlet b=0;\n\t\t\t\t\tfor(b=0;b<lista2.length;b++)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(lista1[a].idlinea==lista2[b].idlinea)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tvar envio1=[lista1[a]];\n\t\t\t\t\t\t\tvar envio2=[lista2[b]];\n\t\t\t\t\t\t\tcaminodirecto(envio1, envio2, listaligada)\n\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}else\n\t\t\t{\n\t\t\t\t//El segundo caso es que solo 1 de los dos sea estacion de cruce\n\t\t\t\tlet a=0;\n\t\t\t\t//realizamos 1 ciclo para recorrer la lista en busca de la linea que tengan en comun\n\t\t\t\tfor(a=0;a<lista1.length;a++)\n\t\t\t\t{\n\t\t\t\t\tlet b=0;\n\t\t\t\t\tfor(b=0;b<lista2.length;b++)\n\t\t\t\t\t{\n\t\t\t\t\t\tif(lista1[a].idlinea==lista2[b].idlinea)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tvar envio1=[lista1[a]];\n\t\t\t\t\t\t\tvar envio2=[lista2[b]];\n\t\t\t\t\t\t\t//Aqui tenemos un poco de recursividad ya que ahora volvemos a enviar los valores a la funcion \n\t\t\t\t\t\t\t//pero ahora solo enviamos el valor de la linea por lo que deberia regresar la lista entre esos 2 puntos\n\t\t\t\t\t\t\tcaminodirecto(envio1, envio2, listaligada)\n\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t//alert(\"Aqui iria el codigo para cuando alguno de los puntos es esacion de cruce\");\n\t}\n\treturn lista_resultado;\n}", "title": "" }, { "docid": "4651c7df6aab6d7dcc0eed7f54284fc7", "score": "0.5003739", "text": "function coupleFirst(x) {\n return x.first;\n }", "title": "" }, { "docid": "173ec21acbde0368177f8f6e57d4c651", "score": "0.5001007", "text": "function neighboring(a, b) {\n linkedByIndex[a.id + ',' + b.id] || linkedByIndex[b.id + ',' + a.id];\n }", "title": "" }, { "docid": "5c9796629769d3e3c802de672b50a41f", "score": "0.49849093", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + \",\" + b.index];\n }", "title": "" }, { "docid": "6e36002cda79dc6f691e3cc839e2547d", "score": "0.49846148", "text": "function mergeTwo(node1, node2){\n let p = node1\n let q = node2\n let s = null\n let newHead = null\n if( p == null) { return q }\n if( q == null) { return p }\n\n if(p && q){\n if(p.val > q.val){\n s = q\n q = s.next\n }else{\n s = p\n p = s.next\n }\n }\n newHead = s\n while( p && q){\n if(p.val > q.val){\n s.next = q\n s = q\n q = s.next \n }else{\n s.next = p\n s = p\n p = s.next\n }\n }\n if(p == null){\n s.next = q\n }\n if(q == null){\n s.next = p\n }\n // console.log(JSON.stringify(newHead))\n return newHead\n}", "title": "" }, { "docid": "8a8d593d4d1ebcb21bc05063229486d2", "score": "0.49799627", "text": "connectVertex( _v1 , _v2 ){\n const e = Vertex.connectVertex(_v1 , _v2 );\n this.listEdge.push(e[0]) ;\n this.listEdge.push(e[1]) ;\n return [e[0] , e[1] ]\n\n }", "title": "" }, { "docid": "c96194d80fd17cf78a63c7450891438f", "score": "0.49776432", "text": "function sortbyClusters(element1, element2) {\n return element1.clusters - element2.clusters;\n}", "title": "" }, { "docid": "476fda77748d67b2b190e5aed6b3dbe3", "score": "0.49772552", "text": "function arraydiff2(a, b) {\n var removed = a.slice(),\n inserted = b.slice();\n\n for (var i = removed.length - 1; i >= 0; i--) {\n var indexInserted = inserted.indexOf(removed[i]);\n if (indexInserted >= 0) {\n removed.splice(i, 1);\n inserted.splice(indexInserted, 1);\n }\n }\n\n return { inserted: inserted, removed: removed };\n}", "title": "" }, { "docid": "c1b3b94fa8d7c311b58644253b8153d8", "score": "0.49760145", "text": "neighboring (a, b) {\n return this.linkedByIndex[a.index + ',' + b.index]\n }", "title": "" }, { "docid": "19dc4ced88a89096aa4289e3f9079858", "score": "0.4975839", "text": "union(x, y) {\n const parentX = this.find(x);\n const parentY = this.find(y);\n\n const parentArr = this.parentArr;\n const parentXRank = -(parentArr[parentX]);\n const parentYRank = -(parentArr[parentY]);\n\n if(parentXRank >= parentYRank) {\n parentArr[parentX] += parentArr[parentY];\n parentArr[parentY] = parentX;\n } else {\n parentArr[parentY] += parentArr[parentX];\n parentArr[parentX] = parentY;\n }\n }", "title": "" }, { "docid": "1659eaabe34a05d820ca7d16e3334e7d", "score": "0.4975438", "text": "function neighboring(a, b) {\r\n return linkedByIndex[a.index + ',' + b.index];\r\n }", "title": "" }, { "docid": "e8595379d2b4e50a2456d446a053eb3b", "score": "0.49672708", "text": "function pass1(elem) {\n xs[elem] = blockG.inEdges(elem).reduce(function(acc, e) {\n return Math.max(acc, xs[e.v] + blockG.edge(e));\n }, 0);\n }", "title": "" }, { "docid": "0378a17cbfb17cc9fe3ddf3512141864", "score": "0.49656048", "text": "function getDiff(i, j) {\n\t\tif (i > 0 && j > 0 && s1[i] == s2[j]) {\n\t\t\treturn getDiff(i - 1, j - 1) + s1[i];\n\t\t}\n\t\telse if (j > 0 && (i == 0 || table[i][j - 1] >= table[i - 1][j])) {\n\t\t\treturn getDiff(i, j - 1) + \"+\" + s2[j];\n\t\t}\n\t\telse if (i > 0 && (j == 0 || table[i - 1][j] >= table[i][j - 1])) {\n\t\t\treturn getDiff(i - 1, j) + \"-\" + s1[i];\n\t\t}\n\t\telse {\n\t\t\treturn \"\";\n\t\t}\n\t}", "title": "" }, { "docid": "1a9c3b416275adc8b7c5003323f5558b", "score": "0.49602252", "text": "join(otherSection) {\n let beforeMarker = this.markers.tail;\n let afterMarker = null;\n\n otherSection.markers.forEach(m => {\n if (!m.isBlank) {\n m = m.clone();\n this.markers.append(m);\n if (!afterMarker) {\n afterMarker = m;\n }\n }\n });\n\n return { beforeMarker, afterMarker };\n }", "title": "" }, { "docid": "3cc1f8672bd22eed7cd14afec3df690b", "score": "0.4958629", "text": "function getDeltas(orig, changed) {\n if (!orig && !changed) {\n throw new ReferenceError(\"both nodes doesn't actually exist\");\n }\n /* check if both nodes are DOM nodes and not just text nodes */\n if (orig && changed &&\n orig.type === 'DOM' && changed.type === 'DOM') {\n const deltas = [];\n /* we've tried to match a node that turns out not to be the same\n * we want to mark that this is a divergence, but there may be more\n * relevant deltas among its children, so let's just add this divergence\n * and continue descending */\n if (!nodeEquals(orig, changed)) {\n let props1 = orig.prop || [];\n let props2 = changed.prop || [];\n const omittedProps = params_1.RingerParams.params.compensation.omittedProps;\n props1 = _.omit(props1, omittedProps);\n props2 = _.omit(props2, omittedProps);\n const diffProps = divergingProps(props1, props2);\n for (const diffProp of diffProps) {\n deltas.push({\n type: 'Property is different.',\n orig: orig,\n changed: changed,\n divergingProp: diffProp\n });\n }\n }\n return deltas;\n }\n else {\n /* at least one node isn't a DOM node */\n if (!orig) {\n return [{\n type: 'New node in changed DOM.',\n orig: orig,\n changed: changed\n }];\n }\n else if (!changed) {\n return [{\n type: 'Node missing in changed DOM.',\n orig: orig,\n changed: changed\n }];\n }\n else if (orig.type === 'DOM' || changed.type === 'DOM') {\n return [{\n type: 'Node types differ.',\n orig: orig,\n changed: changed\n }];\n }\n else if (orig.type === 'text' && orig.type === 'text') {\n /* Both nodes should be text nodes */\n if (nodeEquals(orig, changed)) {\n return [];\n }\n /* sad, we descended all the way and the nodes aren't the same */\n return [{\n 'type': 'Nodes not the same.',\n 'orig': orig,\n 'changed': changed\n }];\n }\n else {\n throw new ReferenceError(\"Unable to create deltas.\");\n }\n }\n }", "title": "" }, { "docid": "0f123c867a36eb379d52ed87054a4d83", "score": "0.49519014", "text": "function connectElements(DOMElement1, DOMElement2, color, thickness, lineId) {\n\t\tvar offset1 = getElementOffset(DOMElement1);\n\t\tvar offset2 = getElementOffset(DOMElement2);\n\n\t\tconnectPoints(offset1, offset2, color, thickness, lineId);\n\t}", "title": "" }, { "docid": "7eb2278d6dbea3e4a3c7140e327b93e9", "score": "0.4944185", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + \",\" + b.index];\n}", "title": "" }, { "docid": "41ea2f4fc3a5a71bdd90e0354626d46f", "score": "0.4944025", "text": "decomposeLeft(_to, result) { result.push(this); }", "title": "" }, { "docid": "41ea2f4fc3a5a71bdd90e0354626d46f", "score": "0.4944025", "text": "decomposeLeft(_to, result) { result.push(this); }", "title": "" }, { "docid": "b3c5e5c46e648bf00d1b99d8e18b4f2f", "score": "0.4935883", "text": "function pass1(elem) {\n xs[elem] = blockG.inEdges(elem).reduce(function(acc, e) {\n return Math.max(acc, xs[e.v] + blockG.edge(e));\n }, 0);\n }", "title": "" }, { "docid": "4ec293f7623123d3fdfcce180c23d5f3", "score": "0.49298498", "text": "function halfwayBetween(element1, element2) {\n\treturn (element1.offset().top + element2.offset().top) / 2;\n}", "title": "" }, { "docid": "ecaae6d751c30045c72724f14e872a0f", "score": "0.49296477", "text": "function makeConcatRule(firstInputPortName, secondInputPortName) {\n return makeSchemaPropagationRule([firstInputPortName, secondInputPortName], function (moduleNode, workspace, schema1, schema2) {\n return Model.SchemaUtils.concat(schema1, schema2);\n });\n }", "title": "" }, { "docid": "daba84654a5988d239108e04deb1f3cf", "score": "0.49291867", "text": "union(x, y) {\n const parentX = this.find(x);\n const parentY = this.find(y);\n this.parentArr[parentX] = parentY;\n }", "title": "" }, { "docid": "6bf4289952807c2dd096db153fc36161", "score": "0.49279934", "text": "addEdge(v1, v2) {\n\t\tv1.adjacent.add(v2);\n\t\tv2.adjacent.add(v1);\n\t}", "title": "" }, { "docid": "bc973ddaf9db403108d64e87f9216641", "score": "0.49279562", "text": "function connectFirstItems(firstItems,secondItems,thirdItems) {\n //draw connections for each widget\n $(firstItems).each(function () {\n var sourceEndpoint = instance.selectEndpoints({source: this.firstChild}).get(0); //the selected source endpoint\n //checks if there are widgets with x=2\n if (secondItems.length > 0) {\n connectEndpointsMiddle(sourceEndpoint, secondItems);\n }\n else {\n //checks if there are widgets with x=3\n if (thirdItems.length > 0) {\n connectEndpointsMiddle(sourceEndpoint, thirdItems);\n }\n else {\n //else connect directly to end widget\n connectEndpointsEnd(sourceEndpoint);\n }\n }\n });\n }", "title": "" }, { "docid": "110f686f307d2ffd85d8a64149e33274", "score": "0.49235377", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + \",\" + b.index];\n }", "title": "" }, { "docid": "110f686f307d2ffd85d8a64149e33274", "score": "0.49235377", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + \",\" + b.index];\n }", "title": "" }, { "docid": "3c04a4ce917f37b9fddd4edf4c4b15c5", "score": "0.49175572", "text": "function resta(p1, p2) {\n return [p1[0] - p2[0], p1[1] - p2[1]];\n}", "title": "" }, { "docid": "cb637de7adfd34e71990a7036e41929d", "score": "0.49172524", "text": "function swap(arr, i, j) {\n $container.insertBefore($container.childNodes[j], $container.childNodes[i]);\n}", "title": "" }, { "docid": "9c1f4b9cf220850524ddc61c155951c9", "score": "0.4906653", "text": "transpose(){\r\n //scambio le righe con le colonne\r\n for(let i=0; i<4; i++) {\r\n for(let j=0; j<i; j++){//lavoro solo sulla diagonale\r\n let tmp = this.get(i,j);\r\n this.set(this.get(j,i), i, j);\r\n this.set(tmp, j ,i);\r\n }\r\n } \r\n //inverto le righe\r\n for(let i=0; i<4; i++) this.elements[i].reverse();\r\n \r\n }", "title": "" }, { "docid": "d8fc0543e2a1ffa8d9ef6f176d95a807", "score": "0.4906432", "text": "function combine(prev, curr) {\n return prev + curr;\n}", "title": "" }, { "docid": "58d5c5b319bee2eae82c592b500c6f0f", "score": "0.49009255", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + ',' + b.index];\n }", "title": "" }, { "docid": "4f67757bb84bc8cbf3773b39c27aa199", "score": "0.49002564", "text": "function swap( a, b )\n{\n var ap = a.parentNode;\n var bp = b.parentNode;\n ap.appendChild( b );\n bp.appendChild( a );\n}", "title": "" }, { "docid": "0a2bcf5bd73214fa83c12e5a8aea2b89", "score": "0.48956603", "text": "function pass1(elem) {\n xs[elem] = blockG.inEdges(elem).reduce(function(acc, e) {\n return Math.max(acc, xs[e.v] + blockG.edge(e));\n }, 0);\n }", "title": "" }, { "docid": "0a2bcf5bd73214fa83c12e5a8aea2b89", "score": "0.48956603", "text": "function pass1(elem) {\n xs[elem] = blockG.inEdges(elem).reduce(function(acc, e) {\n return Math.max(acc, xs[e.v] + blockG.edge(e));\n }, 0);\n }", "title": "" }, { "docid": "0a2bcf5bd73214fa83c12e5a8aea2b89", "score": "0.48956603", "text": "function pass1(elem) {\n xs[elem] = blockG.inEdges(elem).reduce(function(acc, e) {\n return Math.max(acc, xs[e.v] + blockG.edge(e));\n }, 0);\n }", "title": "" }, { "docid": "e43a2bbc1a7c966ab2adbc999eb1c543", "score": "0.48937088", "text": "function diffNode(prev, next, path) {\n var changes = [];\n var replaceNode = Actions.replaceNode;\n var setAttribute = Actions.setAttribute;\n var sameNode = Actions.sameNode;\n var removeNode = Actions.removeNode;\n var updateThunk = Actions.updateThunk;\n\n // No left node to compare it to\n // TODO: This should just return a createNode action\n\n if (prev === null || prev === undefined) {\n throw new Error('Left node must not be null or undefined');\n }\n\n // Bail out and skip updating this whole sub-tree\n if (prev === next) {\n changes.push(sameNode());\n return changes;\n }\n\n // Remove\n if (prev != null && next == null) {\n changes.push(removeNode(prev));\n return changes;\n }\n\n // Replace\n if (prev.type !== next.type) {\n changes.push(replaceNode(prev, next, path));\n return changes;\n }\n\n // Text\n if ((0, _element.isText)(next)) {\n if (prev.nodeValue !== next.nodeValue) {\n changes.push(setAttribute('nodeValue', next.nodeValue, prev.nodeValue));\n }\n return changes;\n }\n\n // Thunk\n if ((0, _element.isThunk)(next)) {\n if ((0, _element.isSameThunk)(prev, next)) {\n changes.push(updateThunk(prev, next, path));\n } else {\n changes.push(replaceNode(prev, next, path));\n }\n return changes;\n }\n\n // Empty\n if ((0, _element.isEmpty)(next)) {\n return changes;\n }\n\n changes = diffAttributes(prev, next);\n changes.push(diffChildren(prev, next, path));\n\n return changes;\n}", "title": "" }, { "docid": "598b6fb17c67046e29e3a2c0b2b20399", "score": "0.4892655", "text": "function neighboring(a, b) {\n return linkedByIndex[a.index + \",\" + b.index];\n }", "title": "" }, { "docid": "2ab60d4c56db1b8275f6fb2fc243a929", "score": "0.48906094", "text": "function optimizeAdjacent(nodes) {\n\tnodes.splice(0, nodes.length, ...flatten({ elements: nodes }));\n\n\tfor(let i = nodes.length - 1; i > 0; i--) {\n\t\tlet prev = nodes[i - 1];\n\t\tlet prevHTML = prev && rawUpdate(prev);\n\t\tif(prevHTML === false) {\n\t\t\tcontinue;\n\t\t}\n\n\t\tlet curr = nodes[i];\n\t\tlet currHTML = curr && rawUpdate(curr);\n\t\tif(currHTML === false) {\n\t\t\tcontinue;\n\t\t}\n\n\t\trawUpdate(prev, prevHTML + currHTML);\n\t\trewriteNode(curr, {}); // invalidates references elsewhere -- XXX: hacky\n\t\tnodes.splice(i, 1);\n\t}\n\treturn nodes;\n}", "title": "" }, { "docid": "eb5c02137b932bfd34d25c832539db3a", "score": "0.48901802", "text": "function prepend(listt, el) {\n return {value: el, rest: listt}\n}", "title": "" }, { "docid": "f402dc7137eddb031e487404b374e5c3", "score": "0.4882763", "text": "function calcDifference(aryNow, aryPrior){\n\t// aryNow=currentList\n\tvar newEle=aryNow.filter(ele=>!aryPrior.map(feature=>feature['bike_id']).includes(ele['bike_id']));\n\tvar eleRem=aryPrior.filter(ele=>!aryNow.map(feature=>feature['bike_id']).includes(ele['bike_id']));\n\t// var bikeRemFeatures=eleRem.map(bikeId=>aryPrior.find(feature=>feature['bike_id']==bikeId));\n\t// console.log(newEle);\n\t// console.log(eleRem);\n\treturn [newEle, eleRem];\n}", "title": "" }, { "docid": "f402dc7137eddb031e487404b374e5c3", "score": "0.4882763", "text": "function calcDifference(aryNow, aryPrior){\n\t// aryNow=currentList\n\tvar newEle=aryNow.filter(ele=>!aryPrior.map(feature=>feature['bike_id']).includes(ele['bike_id']));\n\tvar eleRem=aryPrior.filter(ele=>!aryNow.map(feature=>feature['bike_id']).includes(ele['bike_id']));\n\t// var bikeRemFeatures=eleRem.map(bikeId=>aryPrior.find(feature=>feature['bike_id']==bikeId));\n\t// console.log(newEle);\n\t// console.log(eleRem);\n\treturn [newEle, eleRem];\n}", "title": "" }, { "docid": "a5c90c9669f52d6d18d877ec21c4e238", "score": "0.4875527", "text": "function pairElement(str) {\n var arr1 = [\"A\", \"T\"];\n var arr2 = [\"C\", \"G\"];\n var arrStr = str.split('');\n var result = [];\n \n while (arrStr.length){\n result.push(arrStr.splice(0, 1));\n }\n \n result.forEach(function(arr){\n if(arr1.indexOf(arr[0]) > -1){\n arr.push(arr1[1 - (arr1.indexOf(arr[0]))]);\n }\n else{\n arr.push(arr2[1 - (arr2.indexOf(arr[0]))]);\n }\n });\n \n return result;\n}", "title": "" }, { "docid": "e7c354aca290df5b95c0956e5f0cffa3", "score": "0.4868329", "text": "function mergeTrains(train1, element1, train2, element2)\n {\n var finalTrain = null;\n var trainToRemove = null;\n var mergeStartElement = null;\n\n //If both trains have TrainLocomotive don't merge\n if (train1.head instanceof TrainLocomotive && train2.head instanceof TrainLocomotive)\n {\n return;\n }\n\n //If one of the elements has no more connection left, don't merge\n if (element1.isFullyConnected() || element2.isFullyConnected())\n {\n return;\n }\n\n //Decide which train to merge into the other one\n if (train1.head instanceof TrainLocomotive || train2.head instanceof TrainLocomotive)\n {\n //If one of the trains has a locomotive, merge into it\n if (train1.head instanceof TrainLocomotive) {\n finalTrain = train1;\n trainToRemove = train2;\n mergeStartElement = element2;\n } else if (train2.head instanceof TrainLocomotive) {\n finalTrain = train2;\n trainToRemove = train1;\n mergeStartElement = element1;\n }\n }\n else //Merging two list of carriges\n {\n if (train1.head == element1)\n {\n //reverse order of element inside train1\n service.reverseTrainElements(train1);\n }\n finalTrain = train1;\n trainToRemove = train2;\n mergeStartElement = element2;\n }\n\n var tempElement = finalTrain.head;\n\n var trainTail = service.getTrainTail(finalTrain);\n\n //Add to the target train\n while (mergeStartElement)\n {\n var nextElement = null;\n\n //decide if next or previous\n if (mergeStartElement.nextElement)\n {\n nextElement = mergeStartElement.nextElement;\n } else {\n nextElement = mergeStartElement.previousElement;\n }\n\n trainTail.nextElement = mergeStartElement;\n if (mergeStartElement.previousElement)\n {\n mergeStartElement.previousElement.nextElement = null;\n }\n if (mergeStartElement.nextElement)\n {\n mergeStartElement.nextElement.previousElement = null;\n }\n mergeStartElement.previousElement = trainTail;\n\n trainTail = mergeStartElement;\n\n //move to the next item\n mergeStartElement = nextElement;\n }\n \n //Remove from source train\n trainToRemove.head = null;\n }", "title": "" }, { "docid": "bc8e74b5990c16f2639197437b9361da", "score": "0.48662013", "text": "function unir_rutas(ruta1,ruta2)\r\n{\r\nvar inicio=ruta1.length - 1;\r\nvar tam=inicio+ruta2.length;//\r\n\r\n\tfor(var i=inicio;i<tam;i++)\r\n\t{\r\n\truta1[i]=ruta2[i-inicio];\r\n\t}\r\n}", "title": "" }, { "docid": "c6194d8adf0c14c571d23496fefc93b1", "score": "0.48653632", "text": "function prepend(elem, prev) {\n removeElement(prev);\n var parent = elem.parent;\n if (parent) {\n var childs = parent.children;\n childs.splice(childs.indexOf(elem), 0, prev);\n }\n if (elem.prev) {\n elem.prev.next = prev;\n }\n prev.parent = parent;\n prev.prev = elem.prev;\n prev.next = elem;\n elem.prev = prev;\n}", "title": "" }, { "docid": "c6194d8adf0c14c571d23496fefc93b1", "score": "0.48653632", "text": "function prepend(elem, prev) {\n removeElement(prev);\n var parent = elem.parent;\n if (parent) {\n var childs = parent.children;\n childs.splice(childs.indexOf(elem), 0, prev);\n }\n if (elem.prev) {\n elem.prev.next = prev;\n }\n prev.parent = parent;\n prev.prev = elem.prev;\n prev.next = elem;\n elem.prev = prev;\n}", "title": "" }, { "docid": "c6194d8adf0c14c571d23496fefc93b1", "score": "0.48653632", "text": "function prepend(elem, prev) {\n removeElement(prev);\n var parent = elem.parent;\n if (parent) {\n var childs = parent.children;\n childs.splice(childs.indexOf(elem), 0, prev);\n }\n if (elem.prev) {\n elem.prev.next = prev;\n }\n prev.parent = parent;\n prev.prev = elem.prev;\n prev.next = elem;\n elem.prev = prev;\n}", "title": "" }, { "docid": "c6194d8adf0c14c571d23496fefc93b1", "score": "0.48653632", "text": "function prepend(elem, prev) {\n removeElement(prev);\n var parent = elem.parent;\n if (parent) {\n var childs = parent.children;\n childs.splice(childs.indexOf(elem), 0, prev);\n }\n if (elem.prev) {\n elem.prev.next = prev;\n }\n prev.parent = parent;\n prev.prev = elem.prev;\n prev.next = elem;\n elem.prev = prev;\n}", "title": "" }, { "docid": "c6194d8adf0c14c571d23496fefc93b1", "score": "0.48653632", "text": "function prepend(elem, prev) {\n removeElement(prev);\n var parent = elem.parent;\n if (parent) {\n var childs = parent.children;\n childs.splice(childs.indexOf(elem), 0, prev);\n }\n if (elem.prev) {\n elem.prev.next = prev;\n }\n prev.parent = parent;\n prev.prev = elem.prev;\n prev.next = elem;\n elem.prev = prev;\n}", "title": "" }, { "docid": "c6194d8adf0c14c571d23496fefc93b1", "score": "0.48653632", "text": "function prepend(elem, prev) {\n removeElement(prev);\n var parent = elem.parent;\n if (parent) {\n var childs = parent.children;\n childs.splice(childs.indexOf(elem), 0, prev);\n }\n if (elem.prev) {\n elem.prev.next = prev;\n }\n prev.parent = parent;\n prev.prev = elem.prev;\n prev.next = elem;\n elem.prev = prev;\n}", "title": "" }, { "docid": "1bbe6eca9988b9295ec4a08081332ab5", "score": "0.4860344", "text": "function drawElementConnection(element)\n {\n if (element.nextElement)\n {\n var DOMElement1 = document.getElementById(\"train-element-\" + vm.elementsHeap.indexOf(element));\n var DOMElement2 = document.getElementById(\"train-element-\" + vm.elementsHeap.indexOf(element.nextElement));\n\n drawLineService.connectElements(DOMElement1, DOMElement2, \"red\", 1, \"connection-\" + vm.elementsHeap.indexOf(element));\n }\n }", "title": "" }, { "docid": "5fefd834eebfedea2f7c7155a825e26e", "score": "0.4853923", "text": "function switchElems(i1, i2, mojaLista){\n let c = mojaLista[i1]\n mojaLista[i1] = mojaLista[i2]\n mojaLista[i2] = c\n }", "title": "" }, { "docid": "509f3c9fed0058129344b285f16ac2ed", "score": "0.4852079", "text": "function symDiff(arrayOne, arrayTwo) {\n\t\tvar result = [];\n\t\t//arrayOne pushes the elements to result which are present only in arrayOne as well as not already part of result\n\t\tarrayOne.forEach(function(item) {\n\t\t\tif (arrayTwo.indexOf(item) < 0 && result.indexOf(item) < 0) {\n\t\t\t\tresult.push(item);\n\t\t\t}\n\t\t});\n\t\t//arrayTwo pushes the elements to result which are present only in arrayTwo as well as not already a part of the result\n\t\tarrayTwo.forEach(function(item) {\n\t\t\tif (arrayOne.indexOf(item) < 0 && result.indexOf(item) < 0) {\n\t\t\t\tresult.push(item);\n\t\t\t}\n\t\t});\n\t\treturn result;\n\t}", "title": "" }, { "docid": "2f01575bf90b3c854d2eab787d614d4c", "score": "0.48507392", "text": "function mergeIdenticalAnchorNodes (elements) {\r\n\r\n\t\tif (elements instanceof CKEDITOR.dom.range) {\r\n\r\n\t\t\tvar walker = new CKEDITOR.dom.walker(elements);\r\n\r\n\t\t\t// The walker evaluator function tells the walker what nodes to pause at. Here we are walking anchor nodes.\r\n\t\t\twalker.evaluator = function(node) {\treturn (node.type === CKEDITOR.NODE_ELEMENT && node.$.nodeName == 'A')};\r\n\t\t\twalker.breakOnFalse = false;\t\t//we need to search all nodes in the range\r\n\r\n\t\t\twhile (walker.next()) {\t//an anchor node is found\r\n\t\t\t\twalker.current.mergeSiblings();\t//merge identical sibling anchor nodes\r\n\t\t\t}\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "a9e6aa09910579c22e8c3b3ea1a7aaa5", "score": "0.48433077", "text": "function shiftedDiff(first, second) {\n let count = 0;\n let maxRotations = first.length;\n while (count < maxRotations) {\n if (first === second) {\n break;\n }\n first = first.slice(-1) + first.slice(0, first.length - 1);\n count++;\n }\n return count === maxRotations ? -1 : count;\n}", "title": "" }, { "docid": "ed66e1e65b56086d32469786f409d926", "score": "0.4840621", "text": "connect(start, hash_array) {\n const array_connect_with_start = [], queue = []\n // push the first element in the return array\n array_connect_with_start.push(...hash_array[start])\n // use queue to maintain the working element\n queue.push(...hash_array[start])\n\n while(queue.length > 0) {\n const element = queue.shift()\n if (hash_array[element]) {\n // loop the current element's target list\n for (let el of hash_array[element]) {\n // if not added into the return array\n if (!array_connect_with_start.includes(el)) {\n // added it\n array_connect_with_start.push(el)\n // and put into the queue for the following check\n queue.push(el)\n }\n }\n }\n }\n return array_connect_with_start\n }", "title": "" }, { "docid": "12e0f0282fd493938004b736b6692964", "score": "0.4839815", "text": "function joinAdjacentLists(opts, node) {\n if (node.object !== 'document' && node.object !== 'block') {\n return undefined;\n }\n\n var invalids = node.nodes.map(function (child, i) {\n if (!(0, _utils.isList)(opts, child)) return null;\n var next = node.nodes.get(i + 1);\n if (!next || next.type !== child.type) return null;\n return [child, next];\n }).filter(Boolean);\n\n if (invalids.isEmpty()) {\n return undefined;\n }\n\n /**\n * Join the list pairs\n */\n // We join in reverse order, so that multiple lists folds onto the first one\n return function (change) {\n invalids.reverse().forEach(function (pair) {\n var _pair = _slicedToArray(pair, 2),\n first = _pair[0],\n second = _pair[1];\n\n var updatedSecond = change.value.document.getDescendant(second.key);\n updatedSecond.nodes.forEach(function (secondNode, index) {\n change.moveNodeByKey(secondNode.key, first.key, first.nodes.size + index, { normalize: false });\n });\n\n change.removeNodeByKey(second.key, { normalize: false });\n });\n };\n}", "title": "" }, { "docid": "95fd398fcb8a15ef72b5af912ce6eb5b", "score": "0.4834181", "text": "function byX1(seg1, seg2) {\n return seg1.x1 - seg2.x1;\n }", "title": "" }, { "docid": "30544cc830d0cdf18cca7eac26cc645f", "score": "0.48330125", "text": "swapElements(ind1, ind2) {\n console.log('swapping ' + ind1 + ' and ' + ind2);\n // shortcut if possible\n if(ind1 == ind2) return;\n // swap elems\n let elems = this.elems;\n let tempelem = elems[ind1];\n elems[ind1] = elems[ind2];\n elems[ind2] = tempelem;\n // swap divs\n let divs = this.elemDivs;\n let div1 = divs[ind1];\n let div2 = divs[ind2];\n divs[ind1] = div2;\n divs[ind2] = div1;\n // update visuals\n setOffsetPercent(div1,ind2,elems.length);\n setOffsetPercent(div2,ind1,elems.length);\n }", "title": "" }, { "docid": "69f4a19d4cb47eab538864da298f4d20", "score": "0.48313776", "text": "function delta(before, after, compare) {\n var removed = [];\n var added = [];\n var beforeIdx = 0;\n var afterIdx = 0;\n while (true) {\n if (beforeIdx === before.length) {\n added.push.apply(added, after.slice(afterIdx));\n break;\n }\n if (afterIdx === after.length) {\n removed.push.apply(removed, before.slice(beforeIdx));\n break;\n }\n var beforeElement = before[beforeIdx];\n var afterElement = after[afterIdx];\n var n = compare(beforeElement, afterElement);\n if (n === 0) {\n // equal\n beforeIdx += 1;\n afterIdx += 1;\n }\n else if (n < 0) {\n // beforeElement is smaller -> before element removed\n removed.push(beforeElement);\n beforeIdx += 1;\n }\n else if (n > 0) {\n // beforeElement is greater -> after element added\n added.push(afterElement);\n afterIdx += 1;\n }\n }\n return { removed: removed, added: added };\n }", "title": "" } ]
43470333a84d5cb0326b8f1bb0f3c0a9
Convert an Arraylike object to a real Array.
[ { "docid": "e67d69eccb833f5717a57ea2d29c66ed", "score": "0.0", "text": "function toArray (list, start) {\n start = start || 0;\n var i = list.length - start;\n var ret = new Array(i);\n while (i--) {\n ret[i] = list[i + start];\n }\n return ret\n}", "title": "" } ]
[ { "docid": "c8078fc8dc1a8e911b3d2126ce7a827b", "score": "0.74741274", "text": "function toArray(arrayLikeObj){\n return [].slice.call(arrayLikeObj);\n }", "title": "" }, { "docid": "8f6358a9e10b6f03bda0ab42834f90d4", "score": "0.73040587", "text": "function convertArray( array, type, forceClone ) {\n\n\tif ( ! array || // let 'undefined' and 'null' pass\n\t\t! forceClone && array.constructor === type ) return array;\n\n\tif ( typeof type.BYTES_PER_ELEMENT === 'number' ) {\n\n\t\treturn new type( array ); // create typed array\n\n\t}\n\n\treturn Array.prototype.slice.call( array ); // create Array\n\n}", "title": "" }, { "docid": "bcfd32f73ea512260512ce01cbfcf034", "score": "0.72893906", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n }", "title": "" }, { "docid": "61fda403f0a6444f0ff72878f4c67074", "score": "0.726932", "text": "function makeArray(obj) {\n if (Array.isArray(obj)) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = (typeof obj === 'undefined' ? 'undefined' : _typeof(obj)) == 'object' && typeof obj.length == 'number';\n if (isArrayLike) {\n // convert nodeList to array\n return arraySlice.call(obj);\n }\n\n // array of single index\n return [obj];\n }", "title": "" }, { "docid": "5e24943cbb04c8865bd03d21b1ec4522", "score": "0.7204196", "text": "function makeArray(obj) {\n obj = _.toArray(obj);\n }", "title": "" }, { "docid": "1da52b24b311e1af6132bc031981494a", "score": "0.71301657", "text": "function toArray(obj) {\n try {\n return slice.call(obj);\n } catch(e) {\n var ret = [];\n each(obj, function(val) {\n ret.push(val);\n });\n return ret;\n }\n }", "title": "" }, { "docid": "2894d0469f6be002c3a21e77bb9cd903", "score": "0.7129415", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n}", "title": "" }, { "docid": "2894d0469f6be002c3a21e77bb9cd903", "score": "0.7129415", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n}", "title": "" }, { "docid": "2894d0469f6be002c3a21e77bb9cd903", "score": "0.7129415", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n}", "title": "" }, { "docid": "2894d0469f6be002c3a21e77bb9cd903", "score": "0.7129415", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n}", "title": "" }, { "docid": "2894d0469f6be002c3a21e77bb9cd903", "score": "0.7129415", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n}", "title": "" }, { "docid": "2894d0469f6be002c3a21e77bb9cd903", "score": "0.7129415", "text": "function makeArray( obj ) {\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n return obj;\n }\n\n var isArrayLike = typeof obj == 'object' && typeof obj.length == 'number';\n if ( isArrayLike ) {\n // convert nodeList to array\n return arraySlice.call( obj );\n }\n\n // array of single index\n return [ obj ];\n}", "title": "" }, { "docid": "fc8e183b118f881d7d058aff40637ea3", "score": "0.7102765", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n }", "title": "" }, { "docid": "b10ab31e710b4214f9e50f71305bc711", "score": "0.7091932", "text": "function arrayify (obj) {\n if (!Array.isArray(obj)) return [obj];\n return obj;\n}", "title": "" }, { "docid": "05be4618ba27be2aa94bb259859133bd", "score": "0.7084348", "text": "function makeArray(obj) {\n var ary = [];\n if (isArray(obj)) {\n // use object if already an array\n ary = obj;\n } else if (typeof obj.length === \"number\") {\n // convert nodeList to array\n for (var i = 0, len = obj.length; i < len; i++) {\n ary.push(obj[i]);\n }\n } else {\n // array of single index\n ary.push(obj);\n }\n return ary;\n }", "title": "" }, { "docid": "f9715bd3390cf7a326052ee3bd784379", "score": "0.70842785", "text": "function toArray(obj) {\n return Array.isArray(obj) ? obj : [obj];\n}", "title": "" }, { "docid": "889e059293138d132502178c84269415", "score": "0.70570785", "text": "function makeArray( obj ) {\n\t var ary = [];\n\t if ( isArray( obj ) ) {\n\t // use object if already an array\n\t ary = obj;\n\t } else if ( typeof obj.length === 'number' ) {\n\t // convert nodeList to array\n\t for ( var i=0, len = obj.length; i < len; i++ ) {\n\t ary.push( obj[i] );\n\t }\n\t } else {\n\t // array of single index\n\t ary.push( obj );\n\t }\n\t return ary;\n\t}", "title": "" }, { "docid": "889e059293138d132502178c84269415", "score": "0.70570785", "text": "function makeArray( obj ) {\n\t var ary = [];\n\t if ( isArray( obj ) ) {\n\t // use object if already an array\n\t ary = obj;\n\t } else if ( typeof obj.length === 'number' ) {\n\t // convert nodeList to array\n\t for ( var i=0, len = obj.length; i < len; i++ ) {\n\t ary.push( obj[i] );\n\t }\n\t } else {\n\t // array of single index\n\t ary.push( obj );\n\t }\n\t return ary;\n\t}", "title": "" }, { "docid": "0764c785c03f45991414e59468a08c75", "score": "0.70535296", "text": "function toArray(obj) {\n if (!Array.isArray(obj)) {\n return [obj];\n }\n return obj;\n}", "title": "" }, { "docid": "4fb33b64cbb45d0fb1580bf7d72360a7", "score": "0.7044281", "text": "function makeArray(obj) {\r\n var ary = [];\r\n if (isArray(obj)) {\r\n // use object if already an array\r\n ary = obj;\r\n } else if (obj && typeof obj.length === 'number') {\r\n // convert nodeList to array\r\n for (var i = 0, len = obj.length; i < len; i++) {\r\n ary.push(obj[i]);\r\n }\r\n } else {\r\n // array of single index\r\n ary.push(obj);\r\n }\r\n return ary;\r\n }", "title": "" }, { "docid": "b4df9e3fdb6f9747919d7e42231cff9b", "score": "0.70432085", "text": "function makeArray( obj ) {\n\t var ary = [];\n\t if ( isArray( obj ) ) {\n\t // use object if already an array\n\t ary = obj;\n\t } else if ( obj && typeof obj.length === 'number' ) {\n\t // convert nodeList to array\n\t for ( var i=0, len = obj.length; i < len; i++ ) {\n\t ary.push( obj[i] );\n\t }\n\t } else {\n\t // array of single index\n\t ary.push( obj );\n\t }\n\t return ary;\n\t}", "title": "" }, { "docid": "7b0d58b96dec487f687fad4af965b8a8", "score": "0.70431584", "text": "function toArray(arrayLike) {\n if (isCallable(Array.from)) {\n return Array.from(arrayLike);\n }\n /* istanbul ignore next */\n return _copyArray(arrayLike);\n }", "title": "" }, { "docid": "ae45bfcd3e441d06111ff936e14ef27e", "score": "0.70372033", "text": "function makeArray(obj) {\n var ary = [];\n if (isArray(obj)) {\n // use object if already an array\n ary = obj;\n } else if (typeof obj.length == 'number') {\n // convert nodeList to array\n for (var i = 0; i < obj.length; i++) {\n ary.push(obj[i]);\n }\n } else {\n // array of single index\n ary.push(obj);\n }\n return ary;\n }", "title": "" }, { "docid": "fb6742e8af969920897879c3cbe036e7", "score": "0.70145124", "text": "function makeArray(obj) {\n var ary = [];\n if (isArray(obj)) {\n // use object if already an array\n ary = obj;\n } else if (obj && typeof obj.length === 'number') {\n // convert nodeList to array\n for (var i = 0, len = obj.length; i < len; i++) {\n ary.push(obj[i]);\n }\n } else {\n // array of single index\n ary.push(obj);\n }\n return ary;\n }", "title": "" }, { "docid": "fb6742e8af969920897879c3cbe036e7", "score": "0.70145124", "text": "function makeArray(obj) {\n var ary = [];\n if (isArray(obj)) {\n // use object if already an array\n ary = obj;\n } else if (obj && typeof obj.length === 'number') {\n // convert nodeList to array\n for (var i = 0, len = obj.length; i < len; i++) {\n ary.push(obj[i]);\n }\n } else {\n // array of single index\n ary.push(obj);\n }\n return ary;\n }", "title": "" }, { "docid": "c3a86b3d8ab8445221547f90ec9085b0", "score": "0.69816303", "text": "function toArray(arrayLike) {\n if (isCallable(Array.from)) {\n return Array.from(arrayLike);\n }\n /* istanbul ignore next */\n return _copyArray(arrayLike);\n}", "title": "" }, { "docid": "c3a86b3d8ab8445221547f90ec9085b0", "score": "0.69816303", "text": "function toArray(arrayLike) {\n if (isCallable(Array.from)) {\n return Array.from(arrayLike);\n }\n /* istanbul ignore next */\n return _copyArray(arrayLike);\n}", "title": "" }, { "docid": "b92f87b2f35a62450ac7174b84bfb7bf", "score": "0.69692945", "text": "function toArray(arrayLike) {\n if (isCallable(Array.from)) {\n return Array.from(arrayLike);\n }\n /* istanbul ignore next */\n\n\n return _copyArray(arrayLike);\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "caa1e92e6c961131972b31c96b02dfcb", "score": "0.6956208", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "8450c6451f86e59d6f62894d40e0c140", "score": "0.6940442", "text": "function makeArray( obj ) {\n var ary = [];\n if ( isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length === 'number' ) {\n // convert nodeList to array\n for ( var i=0, len = obj.length; i < len; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "2e077305e4d0093a2c96408a1c91f196", "score": "0.693542", "text": "function makeArray( obj ) {\r\n var ary = [];\r\n if ( isArray( obj ) ) {\r\n // use object if already an array\r\n ary = obj;\r\n } else if ( typeof obj.length === 'number' ) {\r\n // convert nodeList to array\r\n for ( var i=0, len = obj.length; i < len; i++ ) {\r\n ary.push( obj[i] );\r\n }\r\n } else {\r\n // array of single index\r\n ary.push( obj );\r\n }\r\n return ary;\r\n}", "title": "" }, { "docid": "2e077305e4d0093a2c96408a1c91f196", "score": "0.693542", "text": "function makeArray( obj ) {\r\n var ary = [];\r\n if ( isArray( obj ) ) {\r\n // use object if already an array\r\n ary = obj;\r\n } else if ( typeof obj.length === 'number' ) {\r\n // convert nodeList to array\r\n for ( var i=0, len = obj.length; i < len; i++ ) {\r\n ary.push( obj[i] );\r\n }\r\n } else {\r\n // array of single index\r\n ary.push( obj );\r\n }\r\n return ary;\r\n}", "title": "" }, { "docid": "6128f38a7e84fe0be41a45020ba7032e", "score": "0.69279015", "text": "function _toConsumableArray(arr) {\n if (Array.isArray(arr)) {\n for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) {\n arr2[i] = arr[i];\n }\n\n return arr2;\n } else {\n return Array.from(arr);\n }\n }", "title": "" }, { "docid": "de11f2abc6c7372a386d28f2ecdc6cb4", "score": "0.6917323", "text": "function makeArray(obj) {\n var ary = [];\n if (Array.isArray(obj)) {\n // use object if already an array\n ary = obj;\n } else if (obj && typeof obj.length == 'number') {\n // convert nodeList to array\n for (var i = 0; i < obj.length; i++) {\n ary.push(obj[i]);\n }\n } else {\n // array of single index\n ary.push(obj);\n }\n return ary;\n }", "title": "" }, { "docid": "f47a19fe9acd237f0ee5b756f003280a", "score": "0.69058067", "text": "function toArray(arrLike) {\n // or asArray(), or array(), or *whatever*\n return [].slice.call(arrLike);\n}", "title": "" }, { "docid": "2d43c5e1242cf7fdd8a62bf9f308c31f", "score": "0.6904489", "text": "function makeArray( obj ) {\n\t var ary = [];\n\t if ( Array.isArray( obj ) ) {\n\t // use object if already an array\n\t ary = obj;\n\t } else if ( typeof obj.length == 'number' ) {\n\t // convert nodeList to array\n\t for ( var i=0; i < obj.length; i++ ) {\n\t ary.push( obj[i] );\n\t }\n\t } else {\n\t // array of single index\n\t ary.push( obj );\n\t }\n\t return ary;\n\t}", "title": "" }, { "docid": "2d43c5e1242cf7fdd8a62bf9f308c31f", "score": "0.6904489", "text": "function makeArray( obj ) {\n\t var ary = [];\n\t if ( Array.isArray( obj ) ) {\n\t // use object if already an array\n\t ary = obj;\n\t } else if ( typeof obj.length == 'number' ) {\n\t // convert nodeList to array\n\t for ( var i=0; i < obj.length; i++ ) {\n\t ary.push( obj[i] );\n\t }\n\t } else {\n\t // array of single index\n\t ary.push( obj );\n\t }\n\t return ary;\n\t}", "title": "" }, { "docid": "3a96a83354346a5cf61b71af79daed02", "score": "0.6889841", "text": "function _toConsumableArray(arr) {\n\tif (Array.isArray(arr)) {\n\t\tfor (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) {\n\t\t\tarr2[i] = arr[i];\n\t\t}\n\t\treturn arr2;\n\t} else {\n\t\treturn Array.from(arr);\n\t}\n}", "title": "" }, { "docid": "a1f2f5c604e407139ecc770b466b58a0", "score": "0.6876045", "text": "function arrayFrom(arrayLikeObject){\n return [].slice.call(arrayLikeObject);\n}", "title": "" }, { "docid": "ea96c4dcf7f8a34c3f7450000abb18f3", "score": "0.6864623", "text": "function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }", "title": "" }, { "docid": "ea96c4dcf7f8a34c3f7450000abb18f3", "score": "0.6864623", "text": "function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }", "title": "" }, { "docid": "ea96c4dcf7f8a34c3f7450000abb18f3", "score": "0.6864623", "text": "function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }", "title": "" }, { "docid": "ea96c4dcf7f8a34c3f7450000abb18f3", "score": "0.6864623", "text": "function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }", "title": "" }, { "docid": "ea96c4dcf7f8a34c3f7450000abb18f3", "score": "0.6864623", "text": "function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }", "title": "" }, { "docid": "ea96c4dcf7f8a34c3f7450000abb18f3", "score": "0.6864623", "text": "function _toConsumableArray(arr) { if (Array.isArray(arr)) { for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) { arr2[i] = arr[i]; } return arr2; } else { return Array.from(arr); } }", "title": "" }, { "docid": "981b3d69b68eca63c1d33f4f28c6df31", "score": "0.686321", "text": "function _toConsumableArray(arr) {\r\n if (Array.isArray(arr)) {\r\n for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) {\r\n arr2[i] = arr[i];\r\n }\r\n return arr2;\r\n } else {\r\n return Array.from(arr);\r\n }\r\n}", "title": "" }, { "docid": "2848f18fa7da0e7fe77c8622e6d23989", "score": "0.6849828", "text": "function _toConsumableArray(arr) {\n if (Array.isArray(arr)) {\n for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) arr2[i] = arr[i];\n return arr2;\n }\n return Array.from(arr);\n }", "title": "" }, { "docid": "2848f18fa7da0e7fe77c8622e6d23989", "score": "0.6849828", "text": "function _toConsumableArray(arr) {\n if (Array.isArray(arr)) {\n for (var i = 0, arr2 = Array(arr.length); i < arr.length; i++) arr2[i] = arr[i];\n return arr2;\n }\n return Array.from(arr);\n }", "title": "" }, { "docid": "8b9e9d73b43572f0ca645cab9fc07ef1", "score": "0.68374753", "text": "function _setCoerce(obj) {\n return _array.call(this, Array.from(obj));\n}", "title": "" }, { "docid": "8b9e9d73b43572f0ca645cab9fc07ef1", "score": "0.68374753", "text": "function _setCoerce(obj) {\n return _array.call(this, Array.from(obj));\n}", "title": "" }, { "docid": "8b9e9d73b43572f0ca645cab9fc07ef1", "score": "0.68374753", "text": "function _setCoerce(obj) {\n return _array.call(this, Array.from(obj));\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "79381ed8e90cfdad5dcdb37378add09a", "score": "0.6790964", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "aab487da7660a25ab22c27aec44182c2", "score": "0.67638004", "text": "function makeArray( obj ) {\n var ary = [];\n if ( Array.isArray( obj ) ) {\n // use object if already an array\n ary = obj;\n } else if ( obj && typeof obj.length == 'number' ) {\n // convert nodeList to array\n for ( var i=0; i < obj.length; i++ ) {\n ary.push( obj[i] );\n }\n } else {\n // array of single index\n ary.push( obj );\n }\n return ary;\n}", "title": "" }, { "docid": "2cdabc386daa313b04c89e88139032bb", "score": "0.6757895", "text": "function arraify(obj) {\n return (obj.constructor === Array) ? obj : [obj]; \n}", "title": "" }, { "docid": "09f00c5a49112bdb0ce38de1f925148b", "score": "0.67537546", "text": "function toArray ( obj ) {\n return Array.prototype.slice.call( obj );\n}", "title": "" }, { "docid": "f143c11922b449ae0bd87df41b490594", "score": "0.6742764", "text": "function toArray(obj) {\t\n obj = wrapIterator(obj);\n if (obj instanceof java.util.Enumeration) {\n var res = new Array();\n while (obj.hasMoreElements()) {\n res[res.length] = obj.nextElement();\n }\n return res;\n } else if (obj instanceof Array) {\n return obj;\n } else {\n var res = new Array();\n for (var index in obj) {\n res[res.length] = obj[index];\n }\n return res;\n }\n}", "title": "" }, { "docid": "2c9b696dfae1ac1b49f71ffa9e16cec8", "score": "0.6717003", "text": "function _toConsumableArray(arr){if(Array.isArray(arr)){for(var i=0,arr2=Array(arr.length);i<arr.length;i++){arr2[i]=arr[i];}return arr2;}else{return Array.from(arr);}}", "title": "" }, { "docid": "90ad0c44fd629215634bf327e28b6574", "score": "0.67066926", "text": "function toArray(obj) {\n if (!obj) return [];\n if (isArray(obj)) return slice.call(obj);\n if (isString(obj)) {\n // Keep surrogate pair characters together\n return obj.match(reStrSymbol);\n }\n if (isArrayLike(obj)) return map(obj, identity);\n return values(obj);\n}", "title": "" }, { "docid": "90ad0c44fd629215634bf327e28b6574", "score": "0.67066926", "text": "function toArray(obj) {\n if (!obj) return [];\n if (isArray(obj)) return slice.call(obj);\n if (isString(obj)) {\n // Keep surrogate pair characters together\n return obj.match(reStrSymbol);\n }\n if (isArrayLike(obj)) return map(obj, identity);\n return values(obj);\n}", "title": "" }, { "docid": "99915e082487944106f26658f4e4ce77", "score": "0.66977435", "text": "function toArray(obj) {\n\tvar rez = [];\n\tfor (var i in obj) {\n\t\trez.push(obj[i]);\n\t}\n\treturn rez;\n}", "title": "" }, { "docid": "3855f8b864f56c788e51a30af1a60755", "score": "0.66914684", "text": "function toArray(obj) {\n if (!obj) return [];\n if (isArray(obj)) return slice.call(obj);\n if (isString(obj)) {\n // Keep surrogate pair characters together\n return obj.match(reStrSymbol);\n }\n if (isArrayLike(obj)) return map(obj, identity);\n return values(obj);\n }", "title": "" }, { "docid": "ee5ea835f5a34796a51f220344d63421", "score": "0.6676109", "text": "function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _nonIterableSpread(); }", "title": "" } ]
a6dec045a00604ce600acbe4b64ced5f
Convert backtrace from any format to Ruby format
[ { "docid": "4eeb133897971d5b5bb345121c394608", "score": "0.72159547", "text": "function correct_backtrace(backtrace) {\n var new_bt = [], m;\n\n for (var i = 0; i < backtrace.length; i++) {\n var loc = backtrace[i];\n if (!loc || !loc.$$is_string) {\n /* Do nothing */\n }\n /* Chromium format */\n else if ((m = loc.match(/^ at (.*?) \\((.*?)\\)$/))) {\n new_bt.push(m[2] + \":in `\" + m[1] + \"'\");\n }\n else if ((m = loc.match(/^ at (.*?)$/))) {\n new_bt.push(m[1] + \":in `undefined'\");\n }\n /* Node format */\n else if ((m = loc.match(/^ from (.*?)$/))) {\n new_bt.push(m[1]);\n }\n /* Mozilla/Apple format */\n else if ((m = loc.match(/^(.*?)@(.*?)$/))) {\n new_bt.push(m[2] + ':in `' + m[1] + \"'\");\n }\n }\n\n return new_bt;\n }", "title": "" } ]
[ { "docid": "97682c0e2bbb33de3afadab279273f76", "score": "0.5838679", "text": "function transformException(e) {\n var stack = e.stack;\n // evidence of v8 thunk?\n if (Array.isArray(stack)) {\n return {\n message: e.message,\n frames: stack,\n };\n }\n\n // handle the spidermonkey case, maybe\n var o = {\n message: e.message,\n frames: [],\n };\n var sframes = e.stack.split(\"\\n\"), frames = o.frames, match;\n for (var i = 0; i < sframes.length; i++) {\n if ((match = SM_STACK_FORMAT.exec(sframes[i]))) {\n frames.push({\n filename: simplifyFilename(match[2]),\n lineNo: match[3],\n funcName: bits[1],\n });\n }\n }\n\n return o;\n}", "title": "" }, { "docid": "62219302420f4ad2024d0fdae6b8928e", "score": "0.57818204", "text": "function raw() {\n return raw_traceback(raw)\n}", "title": "" }, { "docid": "466a23c7b8ff34783d392e01bea338ae", "score": "0.57004917", "text": "function getBackTrace(message, url, line) {\n var backTrace = [\"no backtrace\"];\n if (typeof message === \"object\") {\n backTrace = printStackTrace({\"e\": message});\n } else {\n backTrace = printStackTrace();\n }\n return backTrace;\n }", "title": "" }, { "docid": "daa320587ea06115c26cd9174bf1ad88", "score": "0.56866604", "text": "function _stackTrace(){}", "title": "" }, { "docid": "8be54cb0eaa60674300ff9243546f8dc", "score": "0.568569", "text": "function backtrace() {\n\n if(c.destroyed) return console.log('destroyed, aborting backtrace')\n\n c.reqBacktrace(function(err, res) {\n\n if(err) return console.error(err)\n\n var frame = res.frames[0]\n logPos(frame, res)\n })\n}", "title": "" }, { "docid": "dbaeca4b46f84f4d72a7b585dda43a91", "score": "0.55941385", "text": "function reformatStack(error, stack) {\n var fileNameShift = 0;\n var lineNumberShift = 0;\n var frameStrings = stack.split('\\n');\n var m = reMueller.exec(frameStrings[0]);\n if (m) {\n var fileNameFormatted = m[1];\n if (fileNameFormatted.length > error.fileNameColumns) {\n // the other stack will need to step up\n error.fileNameColumns = fileNameFormatted.length;\n } else {\n // We need to move this one over\n fileNameShift = error.fileNameColumns - fileNameFormatted.length;\n }\n var lineNumberFormatted = m[2];\n if (lineNumberFormatted.length > error.lineNumberColumns) {\n error.lineNumberColumns = lineNumberFormatted.length;\n } else {\n lineNumberShift = error.lineNumberColumns - lineNumberFormatted.length;\n }\n\n if (lineNumberShift || fileNameShift) {\n var fileNamePadding = \"\";\n while (fileNameShift--) {\n fileNamePadding += ' ';\n }\n var lineNumberPadding = \"\";\n while (lineNumberShift--) {\n lineNumberPadding += ' ';\n }\n\n var oldFileNameColumns = fileNameFormatted.length;\n var frames = frameStrings.map(function splitter(frameString) {\n var fileName = frameString.substr(0, oldFileNameColumns);\n var rest = frameString.substr(oldFileNameColumns);\n return fileNamePadding + fileName + lineNumberPadding + rest;\n });\n return frames.join('\\n');\n } else {\n return stack;\n }\n } else {\n console.error(\"reformatStack fails \", frameStrings);\n }\n}", "title": "" }, { "docid": "39b25cc1103ce5db8811186e4c33d2a6", "score": "0.54775023", "text": "function getStackFrames(err)\n{\n var arr = err.stack.split('\\n');\n arr.pop();\n return arr.reverse();\n}", "title": "" }, { "docid": "032a889a73d6657d61d55bca528ca833", "score": "0.5453881", "text": "function getBidiStackTrace(cdpStackTrace) {\n const stackFrames = cdpStackTrace?.callFrames.map((callFrame) => {\n return {\n columnNumber: callFrame.columnNumber,\n functionName: callFrame.functionName,\n lineNumber: callFrame.lineNumber,\n url: callFrame.url,\n };\n });\n return stackFrames ? { callFrames: stackFrames } : undefined;\n}", "title": "" }, { "docid": "3c10378d38a8d5254fe0698fd7a2f27b", "score": "0.5411993", "text": "function prepareStackTrace(error, stack) {\n\t if (emptyCacheBetweenOperations) {\n\t fileContentsCache = {};\n\t sourceMapCache = {};\n\t }\n\t\n\t return error + stack.map(function(frame) {\n\t return '\\n at ' + wrapCallSite(frame);\n\t }).join('');\n\t}", "title": "" }, { "docid": "7fd2b12acb694cd761d6c05eb89d4e37", "score": "0.5397808", "text": "function stackString(e) {\n var str = '' + e + '\\n';\n if (!e.stack) {\n return str + 'No stack available.\\n';\n }\n var lines = e.stack.toString().split('\\n');\n var toprint = [];\n for (var i = 0; i < lines.length; i++) {\n var line = lines[i];\n if (line.indexOf('ecmaunit.js') > -1) {\n // remove useless bit of traceback\n break;\n }\n if (line.charAt(0) == '(') {\n line = 'function' + line;\n }\n var chunks = line.split('@');\n toprint.push(chunks);\n }\n // toprint.reverse(); No - I prefer the latest at the top by the error message -tbl\n\n for (var i = 0; i < toprint.length; i++) {\n str += ' ' + toprint[i][1] + '\\n ' + toprint[i][0];\n }\n return str;\n}", "title": "" }, { "docid": "7fd2b12acb694cd761d6c05eb89d4e37", "score": "0.5397808", "text": "function stackString(e) {\n var str = '' + e + '\\n';\n if (!e.stack) {\n return str + 'No stack available.\\n';\n }\n var lines = e.stack.toString().split('\\n');\n var toprint = [];\n for (var i = 0; i < lines.length; i++) {\n var line = lines[i];\n if (line.indexOf('ecmaunit.js') > -1) {\n // remove useless bit of traceback\n break;\n }\n if (line.charAt(0) == '(') {\n line = 'function' + line;\n }\n var chunks = line.split('@');\n toprint.push(chunks);\n }\n // toprint.reverse(); No - I prefer the latest at the top by the error message -tbl\n\n for (var i = 0; i < toprint.length; i++) {\n str += ' ' + toprint[i][1] + '\\n ' + toprint[i][0];\n }\n return str;\n}", "title": "" }, { "docid": "7fd2b12acb694cd761d6c05eb89d4e37", "score": "0.5397808", "text": "function stackString(e) {\n var str = '' + e + '\\n';\n if (!e.stack) {\n return str + 'No stack available.\\n';\n }\n var lines = e.stack.toString().split('\\n');\n var toprint = [];\n for (var i = 0; i < lines.length; i++) {\n var line = lines[i];\n if (line.indexOf('ecmaunit.js') > -1) {\n // remove useless bit of traceback\n break;\n }\n if (line.charAt(0) == '(') {\n line = 'function' + line;\n }\n var chunks = line.split('@');\n toprint.push(chunks);\n }\n // toprint.reverse(); No - I prefer the latest at the top by the error message -tbl\n\n for (var i = 0; i < toprint.length; i++) {\n str += ' ' + toprint[i][1] + '\\n ' + toprint[i][0];\n }\n return str;\n}", "title": "" }, { "docid": "7fd2b12acb694cd761d6c05eb89d4e37", "score": "0.5397808", "text": "function stackString(e) {\n var str = '' + e + '\\n';\n if (!e.stack) {\n return str + 'No stack available.\\n';\n }\n var lines = e.stack.toString().split('\\n');\n var toprint = [];\n for (var i = 0; i < lines.length; i++) {\n var line = lines[i];\n if (line.indexOf('ecmaunit.js') > -1) {\n // remove useless bit of traceback\n break;\n }\n if (line.charAt(0) == '(') {\n line = 'function' + line;\n }\n var chunks = line.split('@');\n toprint.push(chunks);\n }\n // toprint.reverse(); No - I prefer the latest at the top by the error message -tbl\n\n for (var i = 0; i < toprint.length; i++) {\n str += ' ' + toprint[i][1] + '\\n ' + toprint[i][0];\n }\n return str;\n}", "title": "" }, { "docid": "c6291509559f7e43e07121fd6e66d49f", "score": "0.53905386", "text": "function printStackTrace(a){a=a||{guess:!0};var b=a.e||null,c=!!a.guess,d=new printStackTrace.implementation,e=d.run(b);return c?d.guessAnonymousFunctions(e):e}", "title": "" }, { "docid": "2f3f55876b8a7e8fb645ed7a628ba71c", "score": "0.5374932", "text": "function S(de,fe){if(fe instanceof Error){const E=fe;return`${de}: ${E.message}\n${E.stack}`}else{if(typeof fe==\"string\")return`${de}: ${fe}`;if(fe)return`${de}: ${fe.toString()}`}return de}", "title": "" }, { "docid": "6d153d29bda47b3720c6d3c019365c3a", "score": "0.5324517", "text": "function getCWStack(err) {\n var stack = err.stack;\n if (!stack) { return void 0; }\n var lines = stack.split('\\n');\n var frames = lines.map(function(line) {\n var match = FFFramePattern.exec(line);\n if (match) {\n return {\n name: match[1].trim() || '?',\n source: match[2].trim() || '?',\n span: [[+match[3]]]\n };\n } else {\n return {\n name: line.trim() || '?',\n source: '?',\n span: []\n };\n }\n });\n return { calls: frames };\n }", "title": "" }, { "docid": "25c57f0e2c446819d24f519bfe2510c3", "score": "0.52456635", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n return error + stack.map(function(frame) {\n return '\\n at ' + wrapCallSite(frame);\n }).join('');\n}", "title": "" }, { "docid": "6d337687a1b5afeb49e695cc54a7da2b", "score": "0.5230372", "text": "function TraceFormatter () {\n}", "title": "" }, { "docid": "380ae6e9ca7f7148b95c2a9487d6b04c", "score": "0.52247816", "text": "function massage(warning, frames) {\n var message = stripInlineStacktrace(warning)\n\n // Reassemble the stack with full filenames provided by React\n var stack = ''\n var lastFilename = void 0\n var lastLineNumber = void 0\n for (var index = 0; index < frames.length; ++index) {\n var _frames$index = frames[index],\n fileName = _frames$index.fileName,\n lineNumber = _frames$index.lineNumber\n\n if (fileName == null || lineNumber == null) {\n continue\n }\n\n // TODO: instead, collapse them in the UI\n if (\n fileName === lastFilename &&\n typeof lineNumber === 'number' &&\n typeof lastLineNumber === 'number' &&\n Math.abs(lineNumber - lastLineNumber) < 3\n ) {\n continue\n }\n lastFilename = fileName\n lastLineNumber = lineNumber\n\n var name = frames[index].name\n\n name = name || '(anonymous function)'\n stack += 'in ' + name + ' (at ' + fileName + ':' + lineNumber + ')\\n'\n }\n\n return { message: message, stack: stack }\n }", "title": "" }, { "docid": "345b875144bc54540120561e19aa603d", "score": "0.5220361", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n\n return error + stack.map(function(frame) {\n return '\\n at ' + wrapCallSite(frame);\n }).join('');\n}", "title": "" }, { "docid": "345b875144bc54540120561e19aa603d", "score": "0.5220361", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n\n return error + stack.map(function(frame) {\n return '\\n at ' + wrapCallSite(frame);\n }).join('');\n}", "title": "" }, { "docid": "5495986613d4737d1ac58b41a3db9518", "score": "0.52106935", "text": "function massage(warning, frames) {\n var message = stripInlineStacktrace(warning);\n\n // Reassemble the stack with full filenames provided by React\n var stack = '';\n var lastFilename = void 0;\n var lastLineNumber = void 0;\n for (var index = 0; index < frames.length; ++index) {\n var _frames$index = frames[index],\n fileName = _frames$index.fileName,\n lineNumber = _frames$index.lineNumber;\n\n if (fileName == null || lineNumber == null) {\n continue;\n }\n\n // TODO: instead, collapse them in the UI\n if (fileName === lastFilename && typeof lineNumber === 'number' && typeof lastLineNumber === 'number' && Math.abs(lineNumber - lastLineNumber) < 3) {\n continue;\n }\n lastFilename = fileName;\n lastLineNumber = lineNumber;\n\n var name = frames[index].name;\n\n name = name || '(anonymous function)';\n stack += 'in ' + name + ' (at ' + fileName + ':' + lineNumber + ')\\n';\n }\n\n return { message: message, stack: stack };\n}", "title": "" }, { "docid": "5495986613d4737d1ac58b41a3db9518", "score": "0.52106935", "text": "function massage(warning, frames) {\n var message = stripInlineStacktrace(warning);\n\n // Reassemble the stack with full filenames provided by React\n var stack = '';\n var lastFilename = void 0;\n var lastLineNumber = void 0;\n for (var index = 0; index < frames.length; ++index) {\n var _frames$index = frames[index],\n fileName = _frames$index.fileName,\n lineNumber = _frames$index.lineNumber;\n\n if (fileName == null || lineNumber == null) {\n continue;\n }\n\n // TODO: instead, collapse them in the UI\n if (fileName === lastFilename && typeof lineNumber === 'number' && typeof lastLineNumber === 'number' && Math.abs(lineNumber - lastLineNumber) < 3) {\n continue;\n }\n lastFilename = fileName;\n lastLineNumber = lineNumber;\n\n var name = frames[index].name;\n\n name = name || '(anonymous function)';\n stack += 'in ' + name + ' (at ' + fileName + ':' + lineNumber + ')\\n';\n }\n\n return { message: message, stack: stack };\n}", "title": "" }, { "docid": "5495986613d4737d1ac58b41a3db9518", "score": "0.52106935", "text": "function massage(warning, frames) {\n var message = stripInlineStacktrace(warning);\n\n // Reassemble the stack with full filenames provided by React\n var stack = '';\n var lastFilename = void 0;\n var lastLineNumber = void 0;\n for (var index = 0; index < frames.length; ++index) {\n var _frames$index = frames[index],\n fileName = _frames$index.fileName,\n lineNumber = _frames$index.lineNumber;\n\n if (fileName == null || lineNumber == null) {\n continue;\n }\n\n // TODO: instead, collapse them in the UI\n if (fileName === lastFilename && typeof lineNumber === 'number' && typeof lastLineNumber === 'number' && Math.abs(lineNumber - lastLineNumber) < 3) {\n continue;\n }\n lastFilename = fileName;\n lastLineNumber = lineNumber;\n\n var name = frames[index].name;\n\n name = name || '(anonymous function)';\n stack += 'in ' + name + ' (at ' + fileName + ':' + lineNumber + ')\\n';\n }\n\n return { message: message, stack: stack };\n}", "title": "" }, { "docid": "5495986613d4737d1ac58b41a3db9518", "score": "0.52106935", "text": "function massage(warning, frames) {\n var message = stripInlineStacktrace(warning);\n\n // Reassemble the stack with full filenames provided by React\n var stack = '';\n var lastFilename = void 0;\n var lastLineNumber = void 0;\n for (var index = 0; index < frames.length; ++index) {\n var _frames$index = frames[index],\n fileName = _frames$index.fileName,\n lineNumber = _frames$index.lineNumber;\n\n if (fileName == null || lineNumber == null) {\n continue;\n }\n\n // TODO: instead, collapse them in the UI\n if (fileName === lastFilename && typeof lineNumber === 'number' && typeof lastLineNumber === 'number' && Math.abs(lineNumber - lastLineNumber) < 3) {\n continue;\n }\n lastFilename = fileName;\n lastLineNumber = lineNumber;\n\n var name = frames[index].name;\n\n name = name || '(anonymous function)';\n stack += 'in ' + name + ' (at ' + fileName + ':' + lineNumber + ')\\n';\n }\n\n return { message: message, stack: stack };\n}", "title": "" }, { "docid": "358ce06d50f62d4f3dfe7a3e514759cc", "score": "0.5160291", "text": "function massage(warning,frames){var message=stripInlineStacktrace(warning);// Reassemble the stack with full filenames provided by React\nvar stack='';var lastFilename=void 0;var lastLineNumber=void 0;for(var index=0;index<frames.length;++index){var _frames$index=frames[index],fileName=_frames$index.fileName,lineNumber=_frames$index.lineNumber;if(fileName==null||lineNumber==null){continue;}// TODO: instead, collapse them in the UI\nif(fileName===lastFilename&&typeof lineNumber==='number'&&typeof lastLineNumber==='number'&&Math.abs(lineNumber-lastLineNumber)<3){continue;}lastFilename=fileName;lastLineNumber=lineNumber;var name=frames[index].name;name=name||'(anonymous function)';stack+='in '+name+' (at '+fileName+':'+lineNumber+')\\n';}return{message:message,stack:stack};}", "title": "" }, { "docid": "cc2f2958c90a0d3e0370c29a45b9d9ac", "score": "0.5156142", "text": "_checkLastInstruction(trace, stacktrace, functionJumpdests, jumpedIntoFunction) {\n const lastStep = trace.steps[trace.steps.length - 1];\n if (!(0, message_trace_1.isEvmStep)(lastStep)) {\n throw new Error(\"This should not happen: MessageTrace ends with a subtrace\");\n }\n const lastInstruction = trace.bytecode.getInstruction(lastStep.pc);\n const revertOrInvalidStacktrace = this._checkRevertOrInvalidOpcode(trace, stacktrace, lastInstruction, functionJumpdests, jumpedIntoFunction);\n if (revertOrInvalidStacktrace !== undefined) {\n return revertOrInvalidStacktrace;\n }\n if ((0, message_trace_1.isDecodedCallTrace)(trace) && !jumpedIntoFunction) {\n if (this._hasFailedInsideTheFallbackFunction(trace) ||\n this._hasFailedInsideTheReceiveFunction(trace)) {\n return [\n this._instructionWithinFunctionToRevertStackTraceEntry(trace, lastInstruction),\n ];\n }\n // Sometimes we do fail inside of a function but there's no jump into\n if (lastInstruction.location !== undefined) {\n const failingFunction = lastInstruction.location.getContainingFunction();\n if (failingFunction !== undefined) {\n return [\n {\n type: solidity_stack_trace_1.StackTraceEntryType.REVERT_ERROR,\n sourceReference: this._getFunctionStartSourceReference(trace, failingFunction),\n message: new return_data_1.ReturnData(trace.returnData),\n isInvalidOpcodeError: lastInstruction.opcode === opcodes_1.Opcode.INVALID,\n },\n ];\n }\n }\n const calledFunction = trace.bytecode.contract.getFunctionFromSelector(trace.calldata.slice(0, 4));\n if (calledFunction !== undefined) {\n return [\n {\n type: solidity_stack_trace_1.StackTraceEntryType.INVALID_PARAMS_ERROR,\n sourceReference: this._getFunctionStartSourceReference(trace, calledFunction),\n },\n ];\n }\n if (this._solidity063MaybeUnmappedRevert(trace)) {\n const revertFrame = this._solidity063GetFrameForUnmappedRevertBeforeFunction(trace);\n if (revertFrame !== undefined) {\n return [revertFrame];\n }\n }\n return [this._getOtherErrorBeforeCalledFunctionStackTraceEntry(trace)];\n }\n }", "title": "" }, { "docid": "1ecbf06ce554c3ba771fe378360cfc60", "score": "0.5155888", "text": "static removeErrorRecovery(fn) {\n var parseFn = fn;\n try {\n var ast = esprima.parse(parseFn);\n\n var labeled = JSONSelect.match(':has(:root > .label > .name:val(\"_handle_error\"))', ast);\n var reduced_code = labeled[0].body.consequent.body[3].consequent.body;\n reduced_code[0] = labeled[0].body.consequent.body[1]; // remove the line: error_rule_depth = locateNearestErrorRecoveryRule(state);\n reduced_code[4].expression.arguments[1].properties.pop(); // remove the line: 'recoverable: error_rule_depth !== false'\n labeled[0].body.consequent.body = reduced_code;\n\n return escodegen.generate(ast)\n .replace(/_handle_error:\\s?/,\"\")\n .replace(/\\\\\\\\n/g,\"\\\\n\");\n } catch (e) {\n return parseFn;\n }\n }", "title": "" }, { "docid": "9734179d55c5dce05498a5848b13a5b4", "score": "0.51455516", "text": "_solidity063GetFrameForUnmappedRevertBeforeFunction(trace) {\n let revertFrame = this._solidity063GetFrameForUnmappedRevertWithinFunction(trace);\n if (revertFrame === undefined ||\n revertFrame.sourceReference === undefined) {\n if (trace.bytecode.contract.receive === undefined ||\n trace.calldata.length > 0) {\n if (trace.bytecode.contract.fallback !== undefined) {\n // Failed within the fallback\n const location = trace.bytecode.contract.fallback.location;\n revertFrame = {\n type: solidity_stack_trace_1.StackTraceEntryType.UNMAPPED_SOLC_0_6_3_REVERT_ERROR,\n sourceReference: {\n contract: trace.bytecode.contract.name,\n function: solidity_stack_trace_1.FALLBACK_FUNCTION_NAME,\n sourceName: location.file.sourceName,\n sourceContent: location.file.content,\n line: location.getStartingLineNumber(),\n range: [location.offset, location.offset + location.length],\n },\n };\n this._solidity063CorrectLineNumber(revertFrame);\n }\n }\n else {\n // Failed within the receive function\n const location = trace.bytecode.contract.receive.location;\n revertFrame = {\n type: solidity_stack_trace_1.StackTraceEntryType.UNMAPPED_SOLC_0_6_3_REVERT_ERROR,\n sourceReference: {\n contract: trace.bytecode.contract.name,\n function: solidity_stack_trace_1.RECEIVE_FUNCTION_NAME,\n sourceName: location.file.sourceName,\n sourceContent: location.file.content,\n line: location.getStartingLineNumber(),\n range: [location.offset, location.offset + location.length],\n },\n };\n this._solidity063CorrectLineNumber(revertFrame);\n }\n }\n return revertFrame;\n }", "title": "" }, { "docid": "3c27a010c738c1a7e56473f47752b452", "score": "0.5143616", "text": "function stripInlineStacktrace(message) {\n return message.split('\\n').filter(function (line) {\n return !line.match(/^\\s*in/);\n }).join('\\n'); // \" in Foo\"\n}", "title": "" }, { "docid": "b3cac5d2955a83cbc16cdd78549c2253", "score": "0.51295745", "text": "function getStackFrames(error){var unhandledRejection=arguments.length>1&&arguments[1]!==undefined?arguments[1]:false;var contextSize=arguments.length>2&&arguments[2]!==undefined?arguments[2]:3;var parsedFrames=Object(__WEBPACK_IMPORTED_MODULE_0__parser__[\"a\"/* parse */])(error);var enhancedFramesPromise=void 0;if(error.__unmap_source){enhancedFramesPromise=Object(__WEBPACK_IMPORTED_MODULE_2__unmapper__[\"a\"/* unmap */])(// $FlowFixMe\nerror.__unmap_source,parsedFrames,contextSize);}else{enhancedFramesPromise=Object(__WEBPACK_IMPORTED_MODULE_1__mapper__[\"a\"/* map */])(parsedFrames,contextSize);}return enhancedFramesPromise.then(function(enhancedFrames){if(enhancedFrames.map(function(f){return f._originalFileName;}).filter(function(f){return f!=null&&f.indexOf('node_modules')===-1;}).length===0){return null;}return enhancedFrames.filter(function(_ref){var functionName=_ref.functionName;return functionName==null||functionName.indexOf('__stack_frame_overlay_proxy_console__')===-1;});});}", "title": "" }, { "docid": "8c711ff9f735fd1ced114f81c8c6cdc5", "score": "0.5097631", "text": "function TrimStackTracePath(line) {\n if (line) {\n line = line.replace(/ \\(.+([\\\\\\/]test[\\\\\\/]|[\\\\\\/]unittest[\\\\\\/]).[^\\\\\\/]*./ig, \" (\");\n // normalize output by replacing leading whitespace (\\s+) of each stack line (starting with 'at ') with 3 spaces (to preserve current baselines)\n line = line.replace(/^\\s+at /gm, ' at ');\n }\n return line;\n}", "title": "" }, { "docid": "b6069573b19157d3c666e35d1ecae7ee", "score": "0.5070792", "text": "function r(e){return Object.prototype.toString.call(e)}", "title": "" }, { "docid": "edf85854e409ac336e22ee9099cda6b1", "score": "0.5059047", "text": "function makeRetrace() {\n const captured = {}\n Error.captureStackTrace(captured, makeRetrace)\n return (err /*: Error */) => {\n\n // eslint-disable-next-line no-param-reassign\n err.stack = [\n ...err.stack.split('\\n'),\n ' ...retrace...',\n ...captured.stack.split('\\n').slice(1)\n ].join('\\n')\n throw err\n }\n}", "title": "" }, { "docid": "b74144e7d775aea2b49460f7bf610d22", "score": "0.50469106", "text": "function copyStackTrace(target, source) {\n target.stack = source.stack.replace(source.message, target.message);\n }", "title": "" }, { "docid": "a974c51ee5be149a9c517a06d46eb4cb", "score": "0.5042124", "text": "function getCallerLineInfo(env) {\n const errstk = new Error()\n .stack\n .split(\"\\n\")\n .slice(2)\n .map((frame) => frame.substring(frame.indexOf(\"(\") + 1, frame.lastIndexOf(\")\")))\n .filter((frame) => !frame.includes(env.logger_path));\n\n return errstk[0];\n}", "title": "" }, { "docid": "909ba7b5e07dfd039acb15befd77d43c", "score": "0.5040965", "text": "function stackTrace(skip) {\n if (!skip) skip = 0;\n\n var e = new Error();\n var s = e.stack.split('\\n');\n\n // skipping myself\n s = s.slice(2 + skip);\n\n var output = [];\n s.forEach(function (line) {\n output.push(line.replace(' at ', ''));\n });\n\n return output;\n }", "title": "" }, { "docid": "fca85b5b55abb27c037de8e63d2b1f45", "score": "0.5032629", "text": "function tr(){\n\t\tconsole.log(new Error().stack)\n\t}", "title": "" }, { "docid": "def7593827cc7e12fc1751e74d60ba90", "score": "0.50320005", "text": "function stripSentryFramesAndReverse(stack) {\n if (!stack.length) {\n return [];\n }\n\n const localStack = stack.slice(0, STACKTRACE_FRAME_LIMIT);\n\n const lastFrameFunction = localStack[localStack.length - 1].function;\n // If stack starts with one of our API calls, remove it (starts, meaning it's the top of the stack - aka last call)\n if (lastFrameFunction && /sentryWrapped/.test(lastFrameFunction)) {\n localStack.pop();\n }\n\n // Reversing in the middle of the procedure allows us to just pop the values off the stack\n localStack.reverse();\n\n const firstFrameFunction = localStack[localStack.length - 1].function;\n // If stack ends with one of our internal API calls, remove it (ends, meaning it's the bottom of the stack - aka top-most call)\n if (firstFrameFunction && /captureMessage|captureException/.test(firstFrameFunction)) {\n localStack.pop();\n }\n\n return localStack.map(frame => ({\n ...frame,\n filename: frame.filename || localStack[localStack.length - 1].filename,\n function: frame.function || '?',\n }));\n}", "title": "" }, { "docid": "6d2976d72ac2b0c448ab7fad2ae3db1a", "score": "0.5028977", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n\n var name = error.name || 'Error';\n var message = error.message || '';\n var errorString = name + \": \" + message;\n\n var state = { nextPosition: null, curPosition: null };\n var processedStack = [];\n for (var i = stack.length - 1; i >= 0; i--) {\n processedStack.push('\\n at ' + wrapCallSite(stack[i], state));\n state.nextPosition = state.curPosition;\n }\n state.curPosition = state.nextPosition = null;\n return errorString + processedStack.reverse().join('');\n}", "title": "" }, { "docid": "6d2976d72ac2b0c448ab7fad2ae3db1a", "score": "0.5028977", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n\n var name = error.name || 'Error';\n var message = error.message || '';\n var errorString = name + \": \" + message;\n\n var state = { nextPosition: null, curPosition: null };\n var processedStack = [];\n for (var i = stack.length - 1; i >= 0; i--) {\n processedStack.push('\\n at ' + wrapCallSite(stack[i], state));\n state.nextPosition = state.curPosition;\n }\n state.curPosition = state.nextPosition = null;\n return errorString + processedStack.reverse().join('');\n}", "title": "" }, { "docid": "a3a3a068e750113956964b520f8011d4", "score": "0.5009155", "text": "function parseStackTraceLines(stack) {\n if (!stack) {\n return [\"(... no stack trace available ...)\"];\n } else {\n var currentLines = stack.split(\"\\n\");\n return stripEmptyLines(currentLines);\n }\n}", "title": "" }, { "docid": "73fe76432bae045422a6be52cd937372", "score": "0.5004344", "text": "function stack(strip=0){\n\n\t// No stack property on Error objects in ie9, unfortunately.\n\t// https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Error/Stack\n\treturn (new Error().stack || '').split(\"\\n\").slice(2+strip).join(\"\\n\")\n}", "title": "" }, { "docid": "f65e6775b5dd038c2bb296947184ee5c", "score": "0.4991684", "text": "function formatLogArguments (args) {\n const requestInstance = getNamespace('main').get('reqId')\n const strInstance = (requestInstance) ? ' INST:' + requestInstance : ''\n\n args = Array.prototype.slice.call(args)\n let stackInfo = getStackInfo(1)\n if (stackInfo) {\n // get file path relative to project root\n let calleeStr = '(' + stackInfo.relativePath + ':' + stackInfo.line + ')' + strInstance\n\n if (typeof (args[0]) === 'string') {\n args[0] = calleeStr + ' ' + args[0]\n } else {\n args.unshift(calleeStr)\n }\n }\n return args\n}", "title": "" }, { "docid": "3d66529d43924fa97e411fc890140bca", "score": "0.49871352", "text": "function removeErrorRecovery (fn) {\n var parseFn = String(fn);\n try {\n var ast = esprima.parse(parseFn);\n\n var labeled = JSONSelect.match(':has(:root > .label > .name:val(\"_handle_error\"))', ast);\n var reduced_code = labeled[0].body.consequent.body[3].consequent.body;\n reduced_code[0] = labeled[0].body.consequent.body[1]; // remove the line: error_rule_depth = locateNearestErrorRecoveryRule(state);\n reduced_code[4].expression.arguments[1].properties.pop(); // remove the line: 'recoverable: error_rule_depth !== false'\n labeled[0].body.consequent.body = reduced_code;\n\n return escodegen.generate(ast).replace(/_handle_error:\\s?/,\"\").replace(/\\\\\\\\n/g,\"\\\\n\");\n } catch (e) {\n return parseFn;\n }\n}", "title": "" }, { "docid": "f0b80bbf7125035f4374392de941d9f1", "score": "0.49677232", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n\n var name = error.name || 'Error';\n var message = error.message || '';\n var errorString = name + \": \" + message;\n\n return errorString + stack.map(function(frame) {\n return '\\n at ' + wrapCallSite(frame);\n }).join('');\n}", "title": "" }, { "docid": "f0b80bbf7125035f4374392de941d9f1", "score": "0.49677232", "text": "function prepareStackTrace(error, stack) {\n if (emptyCacheBetweenOperations) {\n fileContentsCache = {};\n sourceMapCache = {};\n }\n\n var name = error.name || 'Error';\n var message = error.message || '';\n var errorString = name + \": \" + message;\n\n return errorString + stack.map(function(frame) {\n return '\\n at ' + wrapCallSite(frame);\n }).join('');\n}", "title": "" }, { "docid": "a7a566f5c4be30d61da31f2a163cd409", "score": "0.4950859", "text": "function prepareObjectStackTrace(obj,stack){return stack;}", "title": "" }, { "docid": "cb91fbb07011a391fde5608e3340acec", "score": "0.49250633", "text": "function exceptionToDiagnostic(e) {\n return {\n message: `${e.reason}`,\n location: {\n start: e.mark.position,\n end: e.mark.position + e.mark.column,\n },\n severity: 2,\n };\n }", "title": "" }, { "docid": "c1e03646bd535d1241237929dd6cb0b7", "score": "0.49195966", "text": "function extractStackFrameInfo(data) {\n return {\n level: parseInt(data.level, 10),\n func: data.func,\n address: data.addr,\n filename: data.file,\n fullname: data.fullname,\n line: data.line ? parseInt(data.line, 10) : undefined,\n from: data.from\n };\n}", "title": "" }, { "docid": "204da4074247dc9a503355e00d6c4dc1", "score": "0.49071977", "text": "function copyStackTrace(target, source) {\n target.stack = source.stack.replace(source.message, target.message);\n}", "title": "" }, { "docid": "2dd2cb73f6999f13bbc90eb1cb1a7755", "score": "0.48943317", "text": "function formatStack(start, ex) {\n if (ex != undefined)\n start = 0;\n else if (start === undefined)\n start = 1;\n \n if (ex==undefined)\n try {\n // garbage\n xyz[pdq] = lakjsdflkj;\n } catch (e) {\n ex = e;\n }\n \n // only works on mozilla!\n if (typeof(ex) == \"object\" && 'stack' in ex) {\n var stack = ex.stack.split('\\n');\n var formattedStack = [];\n for (var i=start; i<stack.length; i++) {\n var frame = stack[i].split('@');\n // sourceFile:lineNumber: declaration....\n formattedStack.push(frame[1] + \": \" + frame[0].slice(0,50));\n }\n \n formattedStack = formattedStack.join(\"\\n\");\n return formattedStack;\n } else if (typeof ex == \"string\") {\n return \"(no stack, ex was a \" + typeof(ex) + \"!!)\";\n }\n \n return \"\";\n}", "title": "" }, { "docid": "da33f7e2c18670da3703c80d69d185e3", "score": "0.4877772", "text": "function getCWStack(err) {\n var sst = ssts.get(err);\n if (sst === void 0 && err instanceof Error) {\n // We hope it triggers prepareStackTrace\n var ignore = err.stack;\n sst = ssts.get(err);\n }\n if (sst === void 0) { return void 0; }\n\n return { calls: sst.map(function(frame) {\n return {\n name: '' + (frame.getFunctionName() ||\n frame.getMethodName() || '?'),\n source: '' + (frame.getFileName() || '?'),\n span: [ [ frame.getLineNumber(), frame.getColumnNumber() ] ]\n };\n })};\n }", "title": "" }, { "docid": "18f80d7bb3c789a4f6b312c3ef54b4c1", "score": "0.4849929", "text": "_checkRevertOrInvalidOpcode(trace, stacktrace, lastInstruction, functionJumpdests, jumpedIntoFunction) {\n var _a;\n if (lastInstruction.opcode !== opcodes_1.Opcode.REVERT &&\n lastInstruction.opcode !== opcodes_1.Opcode.INVALID) {\n return;\n }\n const inferredStacktrace = [...stacktrace];\n if (lastInstruction.location !== undefined &&\n (!(0, message_trace_1.isDecodedCallTrace)(trace) || jumpedIntoFunction)) {\n // There should always be a function here, but that's not the case with optimizations.\n //\n // If this is a create trace, we already checked args and nonpayable failures before\n // calling this function.\n //\n // If it's a call trace, we already jumped into a function. But optimizations can happen.\n const failingFunction = lastInstruction.location.getContainingFunction();\n // If the failure is in a modifier we add an entry with the function/constructor\n if (failingFunction !== undefined &&\n failingFunction.type === model_1.ContractFunctionType.MODIFIER) {\n inferredStacktrace.push(this._getEntryBeforeFailureInModifier(trace, functionJumpdests));\n }\n }\n const panicStacktrace = this._checkPanic(trace, inferredStacktrace, lastInstruction);\n if (panicStacktrace !== undefined) {\n return panicStacktrace;\n }\n const customErrorStacktrace = this._checkCustomErrors(trace, inferredStacktrace, lastInstruction);\n if (customErrorStacktrace !== undefined) {\n return customErrorStacktrace;\n }\n if (lastInstruction.location !== undefined &&\n (!(0, message_trace_1.isDecodedCallTrace)(trace) || jumpedIntoFunction)) {\n const failingFunction = lastInstruction.location.getContainingFunction();\n if (failingFunction !== undefined) {\n inferredStacktrace.push(this._instructionWithinFunctionToRevertStackTraceEntry(trace, lastInstruction));\n }\n else if ((0, message_trace_1.isDecodedCallTrace)(trace)) {\n // This is here because of the optimizations\n inferredStacktrace.push({\n type: solidity_stack_trace_1.StackTraceEntryType.REVERT_ERROR,\n sourceReference: this._getFunctionStartSourceReference(trace, trace.bytecode.contract.getFunctionFromSelector(trace.calldata.slice(0, 4))),\n message: new return_data_1.ReturnData(trace.returnData),\n isInvalidOpcodeError: lastInstruction.opcode === opcodes_1.Opcode.INVALID,\n });\n }\n else {\n // This is here because of the optimizations\n inferredStacktrace.push({\n type: solidity_stack_trace_1.StackTraceEntryType.REVERT_ERROR,\n sourceReference: this._getConstructorStartSourceReference(trace),\n message: new return_data_1.ReturnData(trace.returnData),\n isInvalidOpcodeError: lastInstruction.opcode === opcodes_1.Opcode.INVALID,\n });\n }\n return this._fixInitialModifier(trace, inferredStacktrace);\n }\n // If the revert instruction is not mapped but there is return data,\n // we add the frame anyway, sith the best sourceReference we can get\n if (lastInstruction.location === undefined && trace.returnData.length > 0) {\n const revertFrame = {\n type: solidity_stack_trace_1.StackTraceEntryType.REVERT_ERROR,\n sourceReference: (_a = this._getLastSourceReference(trace)) !== null && _a !== void 0 ? _a : this._getContractStartWithoutFunctionSourceReference(trace),\n message: new return_data_1.ReturnData(trace.returnData),\n isInvalidOpcodeError: lastInstruction.opcode === opcodes_1.Opcode.INVALID,\n };\n inferredStacktrace.push(revertFrame);\n return this._fixInitialModifier(trace, inferredStacktrace);\n }\n }", "title": "" }, { "docid": "c3a65c16b8cce3d3055bfe290ad4c1f2", "score": "0.48440677", "text": "function fixArguments(that, args){\n var logEvent = that.logger.logEvent;\n args = $.from(args);\n args.shift(); // Removing the original un-formatted log message from the argument list.\n\n // Prepending the newly formatted log message to the argument list.\n if (logEvent.data){\n args = [that.format(), logEvent.data].concat(args);\n } else {\n args = [that.format()].concat(args);\n }\n return args;\n }", "title": "" }, { "docid": "156573fefe449d7e3aba44111ae776b6", "score": "0.48282087", "text": "function getStack(err) {\n if (err !== Object(err)) { return void 0; }\n var cwStack = ses.getCWStack(err);\n if (!cwStack) { return void 0; }\n var result = ses.stackString(cwStack);\n if (err instanceof Error) { result = err + '\\n' + result; }\n return result;\n }", "title": "" }, { "docid": "04815d5151bdc2321d49328cd51c9799", "score": "0.48180643", "text": "function i(e,t){const r={message:\"string\"==typeof(null==e?void 0:e.message)?e.message:String(e)};if(null!==(n=e)&&!Array.isArray(n)&&\"object\"==typeof n){const{errorType:n,stack:i,name:s}=e;if(\"string\"==typeof n&&(r.errorType=n),\"string\"==typeof i){const e=\"string\"==typeof s?s:void 0;r.stack=((e,r)=>{if(!t)return e;const n=e.split(\"\\n\");return n.shift(),void 0!==r&&n.unshift(r),n.join(\"\\n\")})(i,e)}}var n;return r}", "title": "" }, { "docid": "0cb918eb3d27365e2e99372793d1c82d", "score": "0.48064098", "text": "function parseArgs(args) {\n return args.map(function (val) {\n if (val != null && val.inspect) {\n return val.inspect();\n } else {\n try {\n return (/*istanbul ignore next*/(0, _stringify2.default)(val) || val + \"\"\n );\n } catch (e) {\n return util.inspect(val);\n }\n }\n });\n}", "title": "" }, { "docid": "d6a04be0075b210097587e4c7f685124", "score": "0.47978583", "text": "function getStack(){var limit=Error.stackTraceLimit;var obj={};var prep=Error.prepareStackTrace;Error.prepareStackTrace=prepareObjectStackTrace;Error.stackTraceLimit=Math.max(10,limit);// capture the stack\nError.captureStackTrace(obj);// slice this function off the top\nvar stack=obj.stack.slice(1);Error.prepareStackTrace=prep;Error.stackTraceLimit=limit;return stack;}", "title": "" }, { "docid": "1726607267a895a46069b5ea9424dd39", "score": "0.4791981", "text": "extractCallStackHelper(fileContents, statistics) {\n // Grab only the lines that we are interested in, removing header junk for each of the lines\n let lines = fileContents.match(\n // /(?:(?:(?:start|end|resume|reend).*Nest=.*)|(?:call (?:int|private|method|getter|setter).*)|End-Function.*|end-get.*|end-set.*|end-method.*)/gm\n // Update: Looks like we no longer need to search for any enders. We can just use \"return stack:\" instead. This seems to be more accurate, especially in the case of constructors calling other methods.\n /(?:(?:(?:start|end|resume|reend).*Nest=.*)|(?:call (?:int|private|method|getter|setter).*)|return stack:.*)/gm);\n // if there are lines in this session, store it in fileContents\n lines != null ? (fileContents = lines.join(\"\\n\")) : (fileContents = \"\");\n // Get the lowest nest value\n let lowestNestValue = statistics.lowestNestValue;\n // reset fileContents since it is now stored in lines\n fileContents = \"\";\n let prevNestLevel = 0;\n let nestLevel = 0;\n let nestLevelOffset = 0;\n // extContext will store a list of contexts to keep track of all the start and start-ext calls\n // consider renaming this to startContext???\n let extContext = [];\n // resumeContext will store a list of contexts to keep track of all the resume calls\n let resumeContext = [];\n let lastCall = \"\";\n // perform initial formatting based on Nest value\n if (lines) {\n // for each line\n lines.forEach(lineContents => {\n let lineMatchResult = /(start-ext|start|end-ext|end|resume|reend)\\s+Nest=(\\d+)/.exec(lineContents);\n // if we have matched a start-ext, start, end-ext, end, resume or reend\n if (lineMatchResult && lineMatchResult.length > 0) {\n prevNestLevel = nestLevel;\n nestLevel =\n nestLevelOffset + parseInt(lineMatchResult[2]) - lowestNestValue;\n // Always ensure that the next nest level is only indented by 1 tab, and not more\n if (nestLevel - prevNestLevel > 1) {\n nestLevel = prevNestLevel + 1;\n }\n if (resumeContext.length > 0)\n // The resume code already adds an extra tab, so don't need to indent here\n nestLevel -= 1;\n for (let startIndex = 0; startIndex < nestLevel; startIndex++) {\n lineContents = \"\\t\" + lineContents;\n }\n fileContents += lineContents + \"\\n\";\n let matchArray = [];\n switch (lineMatchResult[1]) {\n case \"start\":\n lastCall = \"start\";\n // E.g. >>> start Nest=12 DERIVED_ADDR.ADDRESSLONG.RowInit\n matchArray = lineContents.match(/start\\s+Nest=(?:\\d+).*?((?:\\w+\\.?)+)/);\n extContext.push(matchArray[1]);\n break;\n case \"start-ext\":\n lastCall = \"start\";\n // keep track of start-ext location so that we can append the location to call private and call int lines\n // E.g. >>> start-ext Nest=14 ActivePrograms_SCT SSR_STUDENT_RECORDS.SR_StudentData.StudentActivePrograms.OnExecute\n matchArray = lineContents.match(/start-ext\\s+Nest=(?:\\d+)\\s+\\w+\\s+((?:\\w+\\.?)+)/);\n extContext.push(matchArray[1]);\n break;\n case \"resume\":\n lastCall = \"resume\";\n matchArray = lineContents.match(/resume\\s+Nest=(?:\\d+)\\s*\\.?\\s*((?:\\w+\\.?)+)/);\n resumeContext.push(matchArray[1]);\n break;\n case \"end-ext\":\n lastCall = \"end\";\n // remove the last element from extContext\n extContext.pop();\n break;\n case \"end\":\n lastCall = \"end\";\n // remove the last element from extContext\n extContext.pop();\n break;\n case \"reend\":\n lastCall = \"reend\";\n resumeContext.pop();\n break;\n default:\n break;\n }\n }\n else {\n // we haven't matched a start-ext, start, end-ext, end, resume or rend\n // look for calls to other methods/functions, or other enders\n // lineMatchResult = /(call (int|setter|getter|private|method)|End-Function|end-get|end-set|end-method|%s)/.exec(\n lineMatchResult = /(call (int|setter|getter|private|method)|return stack:|%s)/.exec(lineContents);\n // if we have found a match to calls to other methods/functions or other enders\n if (lineMatchResult && lineMatchResult.length > 0) {\n // if the last call was a start or a call then increment the nest level\n if (lastCall == \"start\" || lastCall.slice(0, 4) == \"call\")\n nestLevel += 1;\n switch (lineMatchResult[1]) {\n case \"call method\":\n lastCall = \"callMethod\";\n // Re-arrange the line so that the call is at the start (like all other lines)\n lineContents = lineContents.replace(/call method\\s+((?:\\w+:?)+)\\.(\\w+)/, \"call $2 $1.OnExecute\");\n break;\n case \"call getter\":\n lastCall = \"callGetter\";\n // Re-arrange the line so that the call is at the start (like all other lines)\n lineContents = lineContents.replace(/call getter\\s+((?:\\w+:?)+)\\.(\\w+)/, \"call getter $2 $1.OnExecute\");\n break;\n case \"call setter\":\n lastCall = \"callSetter\";\n // Remove extra space after call setter and also rearrange setter so that it is at the start (like all other lines)\n // E.g. call setter EO:CA:Address.EditPageHeader\n lineContents = lineContents.replace(/call setter\\s+((?:\\w+:?)+)\\.(\\w+)/, \"call setter $2 $1.OnExecute\");\n break;\n case \"call private\":\n lastCall = \"callPrivate\";\n // Now we need to append the last value in extContext (i.e. )\n if (extContext.length > 0) {\n lineContents = lineContents.replace(/call private\\s+(\\w+)/gm, `call $1 ${extContext[extContext.length - 1]}`);\n }\n break;\n case \"call int\":\n lastCall = \"callInt\";\n // Now we need to append the last value in extContext (i.e. )\n if (extContext.length > 0) {\n lineContents = lineContents.replace(/call int\\s+(\\w+)/gm, `call $1 ${extContext[extContext.length - 1]}`);\n }\n break;\n case \"return stack:\":\n lastCall = \"endSomething\";\n nestLevel -= 1;\n break;\n // case \"End-Function\":\n // lastCall = \"endFunction\";\n // nestLevel -= 1;\n // break;\n // case \"end-get\":\n // lastCall = \"endGet\";\n // nestLevel -= 1;\n // break;\n // case \"end-set\":\n // lastCall = \"endSet\";\n // nestLevel -= 1;\n // break;\n // case \"end-method\":\n // lastCall = \"endMethod\";\n // nestLevel -= 1;\n // break;\n default:\n break;\n }\n }\n for (let startIndex = 0; startIndex < nestLevel; startIndex++) {\n lineContents = \"\\t\" + lineContents;\n }\n fileContents += lineContents + \"\\n\";\n } // end - if we have matched a start-ext, start, end-ext, end, resume or reend\n }); // end - for each line\n } //end - perform initial formatting based on Nest value\n // Remove Nest from each line since we no longer need it\n fileContents = fileContents.replace(/\\s+Nest=\\d+/g, \"\");\n // Remove unnecessary trailer junk (e.g. params= or #params=)\n fileContents = fileContents.replace(/Dur=.*/g, \"\");\n fileContents = fileContents.replace(/[\\s]#?params=\\d+/g, \"\");\n // Are there any resume or reend statements?\n // If so, then reformat the session specific string based on the resume and reend statements\n if (/(resume|reend)\\s(.*)/.test(fileContents)) {\n // first remove any dots straight after the resume/reend (if there are any)\n fileContents = fileContents.replace(/(resume|reend)\\s+\\.\\s+(.*)/g, \"$1 $2\");\n // Store remaining text line by line in an object called results\n // results has a key value of the line number and the value is the actual line contents itself\n let results = fileContents.split(\"\\n\");\n let resumeResults = new Map();\n let reendResults = new Map();\n let endResults = new Map();\n // Find resume, reend and end statements and store the line numbers in a map object along with the results\n // Note: lineNo starts from 0, so the lines in resumeResults, reendResults and endResults will be 1 less than they actually are\n for (let lineNo = 0; lineNo <= results.length; lineNo++) {\n let lineMatchResult = /(resume|reend|end)\\s.*?((?:\\w+\\.?)+((?:\\s(?:\\w+\\.?)+)?))/.exec(results[lineNo]);\n if (lineMatchResult && lineMatchResult.length > 0) {\n switch (lineMatchResult[1]) {\n case \"resume\":\n resumeResults.set(lineNo, lineMatchResult[2]);\n break;\n case \"reend\":\n reendResults.set(lineNo, lineMatchResult[2]);\n break;\n case \"end\":\n endResults.set(lineNo, lineMatchResult[2]);\n break;\n default:\n break;\n }\n }\n }\n // Add a tab to each line before resume until you reach an end for that event\n resumeResults.forEach((resumeResultsLine, resumeResultsLineNo) => {\n // If there is actually an end within the same session, then format all lines after the end and before the resume\n // to do: provide an example to help with debugging\n // console.log(resumeResultsLineNo);\n // console.log(resumeResultsLine);\n // if we find the resumeResults line in end results it means we have an end within the same session??\n if (this.findValue(endResults, resumeResultsLine) != null) {\n // go backwards starting from resume results line number until you find an end\n for (let x = resumeResultsLineNo; x >= 0; x--) {\n let regexEndStatement = new RegExp(`end\\\\s+${resumeResultsLine}`, \"g\");\n let matchEndStatementResult = regexEndStatement.exec(results[x]);\n // if there is a match, we have reached the end statement, so we don't need to add any more tabs\n if (matchEndStatementResult && matchEndStatementResult.length > 0) {\n // break out of the for loop\n break;\n }\n else {\n if (x != resumeResultsLineNo) {\n results[x] = \"\\t\" + results[x];\n }\n }\n }\n }\n });\n // End- Add a tab to each line before resume until you reach an end for that event\n // Add a tab to each line before reend until you reach a resume for that event\n reendResults.forEach((reendResultsLine, reendResultsLineNo) => {\n // If there is actually an end within the same session, then format all lines after the end and before the resume\n // to do: provide an example to help with debugging\n // go backwards starting from reend results line number until you find a resume\n for (let x = reendResultsLineNo; x >= 0; x--) {\n let regexEndStatement = new RegExp(`resume\\\\s.*?${reendResultsLine}`, \"g\");\n let matchEndStatementResult = regexEndStatement.exec(results[x]);\n // if there is a match, we have reached the end statement, so we don't need to add any more tabs\n if (matchEndStatementResult && matchEndStatementResult.length > 0) {\n // break out of the for loop\n break;\n }\n else {\n if (x != reendResultsLineNo) {\n results[x] = \"\\t\" + results[x];\n }\n }\n }\n }); // End - Add a tab to each line before reend until you reach an end for that event\n // store results in fileContents\n fileContents = results.join(\"\\n\");\n }\n // Clean lines\n // Remove the end-ext, End-Function, end-method, end and reend calls, since we no longer need them\n let cleaned_lines = fileContents.match(/(?:.*(?:start|resume).*)|.*(?:call\\s.*).*/gm);\n // if there lines in this session, store it in fileContents\n cleaned_lines != null ? (fileContents = cleaned_lines.join(\"\\n\")) : null;\n // Prefix all calls with suffix .OnExecute (apart from getter, setter and app engine steps) with call method\n fileContents = fileContents.replace(/call\\s(?!(?:getter|setter))(.*\\.OnExecute)$/gm, \"call method $1\");\n // Prefix all remaining calls with call function\n fileContents = fileContents.replace(/call\\s(?!(?:method|getter|setter|%s))(.*(?!\\.OnExecute))$/gm, \"call function $1\");\n // Rename eligible call methods to call constructors\n fileContents = fileContents.replace(/call\\smethod\\s+(\\w+)(\\s.*\\1.OnExecute)/gm, \"call constructor $1$2\");\n // Rename to call function those start-ext calls that do not have getters, setters or constructors appended\n fileContents = fileContents.replace(/start-ext\\s(\\w+)\\s(\\w+\\.\\w+\\.\\w+)$/gm, \"call function $1 $2\");\n // Replace any remaining start-ext with calls based on the last word in the line\n // e.g. start-ext isSaveWarning PT_NAV2.NavOptions.OnExecute getter\n // becomes call getter isSaveWarning PT_NAV2.NavOptions.OnExecute\n fileContents = fileContents.replace(/start-ext\\s(\\w+)\\s(.*)\\s(constructor|method|getter|setter)/gm, \"call $3 $1 $2\");\n // Finally rename CI functions\n fileContents = fileContents.replace(/start-ext\\s(\\w+)\\s(\\w+\\.\\w+)$/gm, \"call function $1 $2\");\n // Replace any colons with dots\n fileContents = fileContents.replace(/:/gm, \".\");\n return fileContents;\n }", "title": "" }, { "docid": "80b79aab41054678eb587324a8efab48", "score": "0.47846094", "text": "function formatPlain(msg,caller,stack){var timestamp=new Date().toUTCString();var formatted=timestamp+' '+this._namespace+' deprecated '+msg;// add stack trace\nif(this._traced){for(var i=0;i<stack.length;i++){formatted+='\\n at '+callSiteToString(stack[i]);}return formatted;}if(caller){formatted+=' at '+formatLocation(caller);}return formatted;}", "title": "" }, { "docid": "457df4ba2261088db45de5a2986ddece", "score": "0.4779089", "text": "function i(e,t){if(\"function\"==typeof e)return e(t);const n=Object.keys(t);for(const r of n)\"message\"!==r&&(e=e.replace(\"{\"+r.toUpperCase()+\"}\",t[r]));return e}", "title": "" }, { "docid": "457df4ba2261088db45de5a2986ddece", "score": "0.4779089", "text": "function i(e,t){if(\"function\"==typeof e)return e(t);const n=Object.keys(t);for(const r of n)\"message\"!==r&&(e=e.replace(\"{\"+r.toUpperCase()+\"}\",t[r]));return e}", "title": "" }, { "docid": "aa6c5c49f04f2afd4098cdf9aa0fcb81", "score": "0.4778693", "text": "function methodToLua(src) {\n console.log(\"=====================methodToLua=====================\");\n var aSrc = src;\n\n //replace block params into some unique character\n var toReplaceParam = paramArrayInMethod(aSrc);\n if(toReplaceParam.length > 0) {\n for(var i = 0; i < toReplaceParam.length; i++) {\n aSrc = aSrc.replace(toReplaceParam[i], \"##\" + i + \"##\");\n }\n }\n\n //made the method in a single line\n aSrc = aSrc.replace(/\\n/g, ' ');\n aSrc = aSrc.replace(/ {2,}/g, ' ');\n aSrc = aSrc.replace(/ *: */g, ':');\n var caller = aSrc.match(/\\[[^ ]* /g);\n if(!caller) {\n alertError(src);\n }\n caller = caller[0];\n caller = caller.slice(1, caller.length - 1);\n var result = caller + \":\";\n var allParams = \"\";\n\n //match the method body\n var methodBodys = aSrc.match(/ [^: ]*:/g);\n //the call doesn't have param;\n if(!methodBodys) {\n methodBodys = aSrc.split(\" \");\n var aMethod = methodBodys[1];\n aMethod = aMethod.slice(0, aMethod.length - 1);\n result = result + aMethod + \"()\";\n //wax framework will solve 'alloc'\n if(aMethod == \"alloc\") {\n return caller;\n }\n\n if(toReplaceParam.length > 0) {\n for(var i = 0; i < toReplaceParam.length; i++) {\n result = result.replace(\"##\" + i + \"##\", toReplaceParam[i]);\n }\n }\n return result;\n }\n\n //convert oc method call grammar to lua\n //for example:\n //[NSString stringWithCString:luaStr encoding:NSUTF8StringEncoding];\n //->\n //NSString:stringWithCString_encoding(luaStr, NSUTF8StringEncoding)\n for(var i = 0; i < methodBodys.length; i++) {\n var aBody = methodBodys[i];\n aBody = aBody.slice(1, aBody.length - 1);\n if(i != 0) {\n result = result + \"_\";\n }\n result = result + aBody;\n var reg = methodBodys[i] + \".*\";\n var start = reg.length;\n var end = 1;\n if(i == methodBodys.length - 1) {\n reg = reg + \"\\]\";\n } else {\n var nextBody = methodBodys[i + 1];\n reg = reg + nextBody;\n end = nextBody.length;\n }\n reg = new RegExp(reg, \"g\");\n reg = aSrc.match(reg);\n if(!reg) {\n alertError(src);\n }\n reg = reg[0];\n var aParam = reg.slice(start - 2, reg.length - end);\n if(i != 0) {\n allParams = allParams + \",\";\n }\n allParams = allParams + aParam;\n }\n result = result + \"(\" + allParams + \")\";\n\n //recover block params\n if(toReplaceParam.length > 0) {\n for(var i = 0; i < toReplaceParam.length; i++) {\n result = result.replace(\"##\" + i + \"##\", toReplaceParam[i]);\n }\n }\n return result;\n}", "title": "" }, { "docid": "04de807f4763691aba5a910916a1d1e8", "score": "0.47591093", "text": "function rlf(format) {\n var args = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n args[_i - 1] = arguments[_i];\n }\n return lf_va(format, args);\n }", "title": "" }, { "docid": "632b833fc109540a07c1519a8e47b77c", "score": "0.47556704", "text": "function sLog() {\r\n var args = convertArgumentsToArray(arguments[0])\r\n\r\n\r\n\r\n var stackTrace = sh.errors.getStackTrace()\r\n var calls = stackTrace.split(\"\\n\");\r\n var trueCall = calls[4]\r\n var prototypeName = calls[5]\r\n\r\n function getS(s) {\r\n s = s.split(\"at \")[1];\r\n return s\r\n }\r\n\r\n trueCall = getS(trueCall);\r\n prototypeName = getS(prototypeName);\r\n\r\n function stripPrototype(s) {\r\n //FlexMXMLtoStyleExplorerConvertor.convertFile (C:\\Users\\user1\\Dropbox\\projects\\crypto\\proxy\\css\\convertMXMLSkinToExplorer.js:40:44)\r\n s = s.split(\".\")[0];\r\n return s\r\n }\r\n\r\n //LineProcHelper.getLineWith (C:\\Users\\user1\\Dropbox\\projects\\crypto\\proxy\\css\\convertMXMLSkinToExplorer.js:29:30)\r\n function getLinePrototype(s) {\r\n var methodCall = s.split(\" (\")[0] //LineProcHelper.getLineWith\r\n var prototype = methodCall.split(\".\")[0];\r\n var method = methodCall.split(\".\")[1];\r\n var line = \"(\" + s.split(\" (\")[1]; //(c:\\)\r\n return {prototype: prototype, method: method, line: line}\r\n }\r\n\r\n var lists = getLinePrototype(trueCall)\r\n var prototype = lists.prototype;\r\n var method = lists.method;\r\n var line = lists.line;\r\n\r\n prototypeName = stripPrototype(prototypeName);\r\n //console.log(stackTrace + 'llllllllll')\r\n /*console.log(trueCall)\r\n console.log(prototypeName)*/\r\n\r\n //console.log(stackTrace)\r\n // args.unshift(label)\r\n args.unshift(lists.method);\r\n args.unshift(lists.prototype);\r\n args.unshift('>>>*> ');\r\n args.push(lists.line);\r\n var str = \"\\t\" + args.join(\" \") + \"\\n\"\r\n str = args.join(\" \")\r\n console.log(str)\r\n //var fx = console.log;\r\n //fx.apply(null, args)\r\n //console.log()\r\n return str;\r\n }", "title": "" }, { "docid": "0e263681518529470ec915a695448416", "score": "0.47297335", "text": "function stacktraceFromException(exception) {\n return exception.stack || exception.backtrace || exception.stacktrace;\n }", "title": "" }, { "docid": "8d60438b304dcf85aae4f524b3fea553", "score": "0.47241044", "text": "function captureStackTrace(below = captureStackTrace, limit = Number.MAX_SAFE_INTEGER) {\n if (!(0, debug_1.debugModeEnabled)()) {\n return ['stack traces disabled'];\n }\n const object = {};\n const previousLimit = Error.stackTraceLimit;\n try {\n Error.stackTraceLimit = limit;\n Error.captureStackTrace(object, below);\n }\n finally {\n Error.stackTraceLimit = previousLimit;\n }\n if (!object.stack) {\n return [];\n }\n return object.stack.split('\\n').slice(1).map(s => s.replace(/^\\s*at\\s+/, ''));\n}", "title": "" }, { "docid": "f11efb2ae5ea6ac32600ed7c54af9337", "score": "0.47118494", "text": "function __trace (object) {\n\treturn Array.from(object.trace);\n}", "title": "" }, { "docid": "8570c3cacc21f005a1336248f9dcb42b", "score": "0.47043034", "text": "function createStackString(stack){var str=this.name+': '+this.namespace;if(this.message){str+=' deprecated '+this.message;}for(var i=0;i<stack.length;i++){str+='\\n at '+callSiteToString(stack[i]);}return str;}", "title": "" }, { "docid": "2a31e6ee14567619a56ea9307304be1f", "score": "0.46967685", "text": "function generateStacktrace() {\n var stacktrace;\n var MAX_FAKE_STACK_SIZE = 10;\n var ANONYMOUS_FUNCTION_PLACEHOLDER = \"[anonymous]\";\n\n // Try to generate a real stacktrace (most browsers, except IE9 and below).\n try {\n throw new Error(\"\");\n } catch (exception) {\n stacktrace = stacktraceFromException(exception);\n }\n\n // Otherwise, build a fake stacktrace from the list of method names by\n // looping through the list of functions that called this one (and skip\n // whoever called us).\n if (!stacktrace) {\n var functionStack = [];\n var curr = arguments.callee.caller.caller;\n while (curr && functionStack.length < MAX_FAKE_STACK_SIZE) {\n var fn = FUNCTION_REGEX.test(curr.toString()) ? RegExp.$1 || ANONYMOUS_FUNCTION_PLACEHOLDER : ANONYMOUS_FUNCTION_PLACEHOLDER;\n functionStack.push(fn);\n curr = curr.caller;\n }\n\n stacktrace = functionStack.join(\"\\n\");\n }\n\n return stacktrace;\n }", "title": "" }, { "docid": "c2636d1d3e3f22580f3ae444cddc8f0b", "score": "0.46927002", "text": "function formatMessage(message) {\n\tif (message.message) {\n\t\tmessage = message.message;\n\t}\n\tlet lines = message.split(\"\\n\");\n\n\t// Strip Webpack-added headers off errors/warnings\n\t// https://github.com/webpack/webpack/blob/master/lib/ModuleError.js\n\tlines = lines.filter((line) => !/Module [A-z ]+\\(from/.test(line));\n\n\t// Transform parsing error into syntax error\n\t// TODO: move this to our ESLint formatter?\n\tlines = lines.map((line) => {\n\t\tconst parsingError = /Line (\\d+):(?:(\\d+):)?\\s*Parsing error: (.+)$/.exec(line);\n\t\tif (!parsingError) {\n\t\t\treturn line;\n\t\t}\n\t\tconst [, errorLine, errorColumn, errorMessage] = parsingError;\n\t\treturn `${friendlySyntaxErrorLabel} ${errorMessage} (${errorLine}:${errorColumn})`;\n\t});\n\n\tmessage = lines.join(\"\\n\");\n\t// Smoosh syntax errors (commonly found in CSS)\n\tmessage = message.replace(/SyntaxError\\s+\\((\\d+):(\\d+)\\)\\s*(.+?)\\n/g, `${friendlySyntaxErrorLabel} $3 ($1:$2)\\n`);\n\t// Remove columns from ESLint formatter output (we added these for more\n\t// accurate syntax errors)\n\tmessage = message.replace(/Line (\\d+):\\d+:/g, \"Line $1:\");\n\t// Clean up export errors\n\tmessage = message.replace(/^.*export '(.+?)' was not found in '(.+?)'.*$/gm, `Attempted import error: '$1' is not exported from '$2'.`);\n\tmessage = message.replace(\n\t\t/^.*export 'default' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm,\n\t\t`Attempted import error: '$2' does not contain a default export (imported as '$1').`\n\t);\n\tmessage = message.replace(\n\t\t/^.*export '(.+?)' \\(imported as '(.+?)'\\) was not found in '(.+?)'.*$/gm,\n\t\t`Attempted import error: '$1' is not exported from '$3' (imported as '$2').`\n\t);\n\tlines = message.split(\"\\n\");\n\n\t// Remove leading newline\n\tif (lines.length > 2 && lines[1].trim() === \"\") {\n\t\tlines.splice(1, 1);\n\t}\n\t// Clean up file name\n\tlines[0] = lines[0].replace(/^(.*) \\d+:\\d+-\\d+$/, \"$1\");\n\n\t// Cleans up verbose \"module not found\" messages for files and packages.\n\tif (lines[1] && lines[1].indexOf(\"Module not found: \") === 0) {\n\t\tlines = [lines[0], lines[1].replace(\"Error: \", \"\").replace(\"Module not found: Cannot find file:\", \"Cannot find file:\")];\n\t}\n\n\t// Add helpful message for users trying to use Sass for the first time\n\tif (lines[1] && lines[1].match(/Cannot find module.+node-sass/)) {\n\t\tlines[1] = \"To import Sass files, you first need to install node-sass.\\n\";\n\t\tlines[1] += \"Run `npm install node-sass` or `yarn add node-sass` inside your workspace.\";\n\t}\n\n\tlines[0] = chalk.inverse(lines[0]);\n\n\tmessage = lines.join(\"\\n\");\n\t// Internal stacks are generally useless so we strip them... with the\n\t// exception of stacks containing `webpack:` because they're normally\n\t// from user code generated by Webpack. For more information see\n\t// https://github.com/facebook/create-react-app/pull/1050\n\tmessage = message.replace(/^\\s*at\\s((?!webpack:).)*:\\d+:\\d+[\\s)]*(\\n|$)/gm, \"\"); // at ... ...:x:y\n\tmessage = message.replace(/^\\s*at\\s<anonymous>(\\n|$)/gm, \"\"); // at <anonymous>\n\tlines = message.split(\"\\n\");\n\n\t// Remove duplicated newlines\n\tlines = lines.filter((line, index, arr) => index === 0 || line.trim() !== \"\" || line.trim() !== arr[index - 1].trim());\n\n\t// Reassemble the message\n\tmessage = lines.join(\"\\n\");\n\treturn message.trim();\n}", "title": "" }, { "docid": "e07cd825e2ca86fdf1a8074718f2e129", "score": "0.46857932", "text": "function getFullErrorStack(ex)\n{\n var ret = ex.stack || ex.toString();\n if (ex.cause && typeof (ex.cause) === 'function') {\n var cex = ex.cause();\n if (cex) {\n ret += '\\nCaused by: ' + getFullErrorStack(cex);\n }\n }\n return (ret);\n}", "title": "" }, { "docid": "e0e8803003d44df47c7771e7f671171e", "score": "0.4685289", "text": "getCallerFromStack() {\n\t\t\tconst _prepareStackTrace = Error.prepareStackTrace;\n\t\t\tError.prepareStackTrace = (_, stack) => stack;\n\t\t\tconst stack = new Error().stack;\n\t\t\tError.prepareStackTrace = _prepareStackTrace;\n\n\t\t\tif (stack.length > 2) {\n\t\t\t\tconst site = stack[2];\n\t\t\t\treturn {\n\t\t\t\t\tfilename: site.getFileName().substring(cwd.length + 1),\n\t\t\t\t\tlineNumber: site.getLineNumber(),\n\t\t\t\t\tcolumnNumber: site.getColumnNumber(),\n\t\t\t\t\tmethodName: site.getMethodName(),\n\t\t\t\t\tfunctionName: site.getFunctionName(),\n\t\t\t\t};\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "21b2a71392dee8f5672c45726d7cbd4b", "score": "0.46713904", "text": "function convertMethodCall(src) {\n console.log(\"=====================convertMethodCall=====================\");\n var result = src;\n //while is to convert oc method call to lua\n //the reg only match the method which don't have inner call\n //so it would loop for many times\n while(result.match(/[\\[\\]]/g)) {\n var toBeReplaceArray = result.match(/\\[[^\\[\\]]*\\]/g);\n if(!toBeReplaceArray) {\n break;\n }\n if(toBeReplaceArray.length < 1) {\n break;\n }\n for(var i = 0; i < toBeReplaceArray.length; i++) {\n var aMethod = toBeReplaceArray[i];\n var aLuaMethod = methodToLua(aMethod);\n result = result.replace(aMethod, aLuaMethod);\n }\n }\n return result;\n}", "title": "" }, { "docid": "a1f241da298b97184e7d37fa8f4ad73b", "score": "0.46683997", "text": "function computeTraceback(path) {\n var paths = [];\n globalTraceback(paths, path, getNeighboured);\n return paths;\n }", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "296bf5bb21013f87c11b28505273bd68", "score": "0.4660027", "text": "function dumpException(ex)\n{\n\tvar ret;\n\n\tif (!(ex instanceof Error))\n\t\tthrow (new Error(jsSprintf('invalid type for %%r: %j', ex)));\n\n\t/* Note that V8 prepends \"ex.stack\" with ex.toString(). */\n\tret = 'EXCEPTION: ' + ex.constructor.name + ': ' + ex.stack;\n\n\tif (ex.cause && typeof (ex.cause) === 'function') {\n\t\tvar cex = ex.cause();\n\t\tif (cex) {\n\t\t\tret += '\\nCaused by: ' + dumpException(cex);\n\t\t}\n\t}\n\n\treturn (ret);\n}", "title": "" }, { "docid": "f8cf51a395c1c679b3f36be60d977a0d", "score": "0.46487522", "text": "function formatError (err) {\n if (err.stack) {\n try {\n var frame = parse(err)[0]\n err.callsite = '('\n + relative(process.cwd(), frame.filepath)\n + ':' + frame.lineNumber\n + ':' + frame.columnNumber + ')'\n } catch (e) {}\n }\n return format('[%s] %s %s', err.name || 'Error', err.message, err.callsite || '')\n}", "title": "" }, { "docid": "8044462dd661ff20b2197f50db70c8a7", "score": "0.46438032", "text": "function convertDebugFrame(arr) {\n var converted = [];\n for(var i = 0; i < arr.length; i++) {\n converted[i] = [[arr[i], 0]];\n }\n return converted;\n}", "title": "" }, { "docid": "eb13793c610c1d3088e56048a0a9401a", "score": "0.46374524", "text": "function stackString(cwStack) {\n if (!cwStack) { return void 0; }\n var calls = cwStack.calls;\n\n var result = calls.map(function(call) {\n\n var spanString = call.span.map(function(subSpan) {\n return subSpan.join(':');\n }).join('::');\n if (spanString) { spanString = ':' + spanString; }\n\n return ' at ' + call.name + ' (' + call.source + spanString + ')';\n\n });\n return result.join('\\n');\n }", "title": "" }, { "docid": "c07e07790bd35aa21ec6ab9c178d90f4", "score": "0.4626059", "text": "function f(t,e){if(\"function\"==typeof t)return t(e);for(var n=0,r=Object.keys(e);n<r.length;n++){var o=r[n];\"message\"!==o&&(t=t.replace(\"{\"+o.toUpperCase()+\"}\",e[o]))}return t}", "title": "" } ]
ec938d1dd172ea60ab540dc887e41312
Initialize a new `Emitter`.
[ { "docid": "c62e1fb63be2b2a4dbda2f79c7f519fb", "score": "0.0", "text": "function Emitter(obj){if(obj)return mixin(obj);}", "title": "" } ]
[ { "docid": "72726bb3dc89af8ee393ace66740ce64", "score": "0.7560931", "text": "function MyEmitter() { EventEmitter.call(this); }", "title": "" }, { "docid": "fa01c49d9af09bd0f2a0d1f32ca9d552", "score": "0.7513115", "text": "function Emitter() {\r\n this.events = {};\r\n}", "title": "" }, { "docid": "fb2c2b450d26ab88fcc8ea54dff49c3d", "score": "0.7444301", "text": "function Emitter() {\n\n this._events = {};\n this._isDestroyed = false;\n\n }", "title": "" }, { "docid": "6d6765c78cffeb4b0646f1cf9fb17b52", "score": "0.7427433", "text": "function Emitter() {\n this.callbacks = {};\n}", "title": "" }, { "docid": "6d6765c78cffeb4b0646f1cf9fb17b52", "score": "0.7427433", "text": "function Emitter() {\n this.callbacks = {};\n}", "title": "" }, { "docid": "6d6765c78cffeb4b0646f1cf9fb17b52", "score": "0.7427433", "text": "function Emitter() {\n this.callbacks = {};\n}", "title": "" }, { "docid": "6d6765c78cffeb4b0646f1cf9fb17b52", "score": "0.7427433", "text": "function Emitter() {\n this.callbacks = {};\n}", "title": "" }, { "docid": "bbb2d68c1fd340b98516c8bee4239d58", "score": "0.73995936", "text": "function Emitter() {\n this.listeners = {};\n }", "title": "" }, { "docid": "a5b29024ae5793a90359f1267f80d339", "score": "0.7260658", "text": "function Emitter() {\n EventEmitter.call(this);\n}", "title": "" }, { "docid": "51c5da8de68589ee414b288be8bd1403", "score": "0.7170509", "text": "function Emitter() {\n var self = {\n listeners: {},\n on: function on(eventName, handler) {\n if (self.listeners[eventName] === undefined) self.listeners[eventName] = [];\n self.listeners[eventName].push(handler);\n },\n emit: function emit(eventName) {\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n if (self.listeners[eventName] !== undefined) self.listeners[eventName].forEach(function (handler) {\n return handler.apply(args);\n });\n }\n };\n return self;\n}", "title": "" }, { "docid": "1eed49302d4c56e1541268d4c3e91774", "score": "0.6806861", "text": "constructor(...args) {\n /** @ignore */ this._emitter = new EventEmitter();\n }", "title": "" }, { "docid": "52c829afa192ef5795c272555efb37e0", "score": "0.6722565", "text": "function init() {\n eventEmitter = new EventEmitter();\n\n // Listen to the sequencer's \"upcoming beat\" event.\n events.addListener('SCHEDULED_BEAT', scheduleRawBeat);\n }", "title": "" }, { "docid": "704ef3235f1c4f5091d1d4b0e86c112f", "score": "0.66783756", "text": "function EventEmitter() {\n \t this._events = new Events();\n \t this._eventsCount = 0;\n \t}", "title": "" }, { "docid": "80c195336a492ad8cfbea2a2a3cd7fc4", "score": "0.6648594", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n }", "title": "" }, { "docid": "80c195336a492ad8cfbea2a2a3cd7fc4", "score": "0.6648594", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n }", "title": "" }, { "docid": "e0227a630b340409379ed5af9ac4d294", "score": "0.65833455", "text": "function EventEmitter() {\n this._events = new Events()\n this._eventsCount = 0\n }", "title": "" }, { "docid": "256b3cd4758ee449101fd16b26c38e39", "score": "0.6578973", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n }", "title": "" }, { "docid": "1dea5f6442d67c8219a0e37b1785a03e", "score": "0.65606207", "text": "function EventEmitter() {\n this._events = new Events(), this._eventsCount = 0;\n }", "title": "" }, { "docid": "38050131acd0c7df83d1c5aed3baba99", "score": "0.6551611", "text": "function EventEmitter() {\n\t this._events = new Events();\n\t this._eventsCount = 0;\n\t}", "title": "" }, { "docid": "38050131acd0c7df83d1c5aed3baba99", "score": "0.6551611", "text": "function EventEmitter() {\n\t this._events = new Events();\n\t this._eventsCount = 0;\n\t}", "title": "" }, { "docid": "38050131acd0c7df83d1c5aed3baba99", "score": "0.6551611", "text": "function EventEmitter() {\n\t this._events = new Events();\n\t this._eventsCount = 0;\n\t}", "title": "" }, { "docid": "38050131acd0c7df83d1c5aed3baba99", "score": "0.6551611", "text": "function EventEmitter() {\n\t this._events = new Events();\n\t this._eventsCount = 0;\n\t}", "title": "" }, { "docid": "38050131acd0c7df83d1c5aed3baba99", "score": "0.6551611", "text": "function EventEmitter() {\n\t this._events = new Events();\n\t this._eventsCount = 0;\n\t}", "title": "" }, { "docid": "b86ca745a0602c6daca9b342c15f4b33", "score": "0.6468669", "text": "function createEmitter() {\r\n const events = new Map();\r\n const emitter = {\r\n events,\r\n on(event, handler) {\r\n const handlers = events.get(event);\r\n const added = handlers && handlers.push(handler);\r\n if (!added) {\r\n events.set(event, [handler]);\r\n }\r\n },\r\n off(event, handler) {\r\n const handlers = events.get(event);\r\n if (handlers) {\r\n handlers.splice(handlers.indexOf(handler) >>> 0, 1);\r\n }\r\n },\r\n emit(event, payload) {\r\n (events.get(event) || [])\r\n .slice()\r\n .map(handler => handler(payload));\r\n (events.get('*') || [])\r\n .slice()\r\n .map(handler => handler(event, payload));\r\n }\r\n };\r\n return emitter;\r\n}", "title": "" }, { "docid": "cfa17fd17242accf4af6242ad8fbe093", "score": "0.6459374", "text": "function EventEmitter(){this._events=new Events();this._eventsCount=0;}", "title": "" }, { "docid": "cfa17fd17242accf4af6242ad8fbe093", "score": "0.6459374", "text": "function EventEmitter(){this._events=new Events();this._eventsCount=0;}", "title": "" }, { "docid": "117d841251afce283319b9fc09cbf291", "score": "0.64104563", "text": "constructor () {\n\t\tObject.defineProperty(this, 'EventEmitter', {\n\t\t\tvalue: {\n\t\t\t\tlisteners: {},\n\t\t\t\tpropagate: propagate,\n\t\t\t\tstopPropagation: stopPropagation,\n\t\t\t\tparent: null,\n\t\t\t\tparentPrefix: ''\n\t\t\t}\n\t\t});\n\t}", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "78dfde7e93ed1f8c76b5037fe031c98e", "score": "0.6398693", "text": "function EventEmitter() { /* Nothing to set */ }", "title": "" }, { "docid": "80fff10930594834f0ad0a8fae3c6823", "score": "0.6384416", "text": "function EventEmitter(){}", "title": "" }, { "docid": "80fff10930594834f0ad0a8fae3c6823", "score": "0.6384416", "text": "function EventEmitter(){}", "title": "" }, { "docid": "80fff10930594834f0ad0a8fae3c6823", "score": "0.6384416", "text": "function EventEmitter(){}", "title": "" }, { "docid": "80fff10930594834f0ad0a8fae3c6823", "score": "0.6384416", "text": "function EventEmitter(){}", "title": "" }, { "docid": "aff7cdd21392168e97b244fefc02b72e", "score": "0.637871", "text": "function emitter() {\n return this.eventEmitter;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" }, { "docid": "02d4dd9e606757e92b341c09a07ef547", "score": "0.63766956", "text": "function EventEmitter() {\n this._events = new Events();\n this._eventsCount = 0;\n}", "title": "" } ]
a94165361841ea3de51f557bc742247c
Reset the scheduler's state.
[ { "docid": "bc17b279dbd9853b8b9ceeeefb7de395", "score": "0.0", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n if (true) {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" } ]
[ { "docid": "2ef68c1458e0a04a6a18a776555a62e1", "score": "0.83020246", "text": "function resetSchedulerState() {\n queue.length = 0;\n has$1 = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "11c739cfd4b54f568f987d84fe7c412b", "score": "0.8217631", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "11c739cfd4b54f568f987d84fe7c412b", "score": "0.8217631", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "11c739cfd4b54f568f987d84fe7c412b", "score": "0.8217631", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "11c739cfd4b54f568f987d84fe7c412b", "score": "0.8217631", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "829d7ed5823abfc29dfb547c13272cca", "score": "0.82158494", "text": "function resetSchedulerState () {\n\t queue.length = 0;\n\t has$1 = {};\n\t {\n\t circular = {};\n\t }\n\t waiting = flushing = false;\n\t}", "title": "" }, { "docid": "4155be140ebd62e47ee3de9f34b9006d", "score": "0.8174081", "text": "function resetSchedulerState() {\n index$1 = queue.length = activatedChildren.length = 0;\n has$1 = {};\n waiting = flushing = false;\n }", "title": "" }, { "docid": "fbfa87bd2fd9ec497e51f9f7c82017be", "score": "0.81561536", "text": "function resetSchedulerState () {\n queue.length = 0\n has$1 = {}\n {\n circular = {}\n }\n waiting = flushing = false\n}", "title": "" }, { "docid": "61569d718305ed74c9745b35cbad7fde", "score": "0.81140536", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "61569d718305ed74c9745b35cbad7fde", "score": "0.81140536", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "61569d718305ed74c9745b35cbad7fde", "score": "0.81140536", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "61569d718305ed74c9745b35cbad7fde", "score": "0.81140536", "text": "function resetSchedulerState () {\n queue.length = 0;\n has$1 = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "0876f5e8c5605e42c0b39b09542e1502", "score": "0.81102544", "text": "function resetSchedulerState () {\n\t queue.length = 0;\n\t has = {};\n\t if (true) {\n\t circular = {};\n\t }\n\t waiting = flushing = false;\n\t}", "title": "" }, { "docid": "bb2eef80942ff3cd4f200d1bbe29a31a", "score": "0.8087698", "text": "function resetSchedulerState() {\n queue.length = 0;\n has$1 = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "3179d31508214af8f766bb019a3fb5a4", "score": "0.80703217", "text": "function resetSchedulerState () {\n queue.length = 0;\n has = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "3179d31508214af8f766bb019a3fb5a4", "score": "0.80703217", "text": "function resetSchedulerState () {\n queue.length = 0;\n has = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "8ab2396b28252cdd35f0728233456a70", "score": "0.80288833", "text": "function resetSchedulerState() {\n index$1 = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "8c945ecde8a2eefe3165718e1cd21934", "score": "0.8027141", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n waiting = flushing = false;\n }", "title": "" }, { "docid": "3e6cb8d77641475e4b098310c1036cdf", "score": "0.80154663", "text": "function resetSchedulerState() {\n index$1 = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "0b34d350f6b7acaaec141cf9104c2cf7", "score": "0.80003595", "text": "function resetSchedulerState() {\n queue.length = 0\n has = {}\n if (process.env.NODE_ENV !== 'production') {\n circular = {}\n }\n waiting = flushing = false\n}", "title": "" }, { "docid": "882ff676b9ca29d4c048bee6094de88e", "score": "0.79596335", "text": "function resetSchedulerState () {\n index = queue$1.length = activatedChildren.length = 0;\n has = {};\n waiting = flushing = false;\n}", "title": "" }, { "docid": "1e2443a2dbf1ba05462acc4791baa0d1", "score": "0.7958977", "text": "function resetSchedulerState () {\n index$1 = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "2b91fd1552a9a978b0395403feaea428", "score": "0.79544383", "text": "function resetSchedulerState() {\n index = queue.length = activatedChildren.length = 0\n has = {}\n waiting = flushing = false\n }", "title": "" }, { "docid": "205f932ad92cb3b295e12e5533c5353d", "score": "0.79518664", "text": "function resetSchedulerState() {\n index$1 = queue.length = activatedChildren.length = 0;\n has = {};\n if (true) {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "ffc1ad5a70f76a8aca9c24a4b588f5e4", "score": "0.79464346", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n waiting = flushing = false;\n}", "title": "" }, { "docid": "ffc1ad5a70f76a8aca9c24a4b588f5e4", "score": "0.79464346", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n waiting = flushing = false;\n}", "title": "" }, { "docid": "ffc1ad5a70f76a8aca9c24a4b588f5e4", "score": "0.79464346", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n waiting = flushing = false;\n}", "title": "" }, { "docid": "3a0ef67acb1e34c0b77de8e654ad0827", "score": "0.7930694", "text": "function resetSchedulerState() {\n index$1 = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "83d036426aaa0907609fba83c418b052", "score": "0.7924793", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "83d036426aaa0907609fba83c418b052", "score": "0.7924793", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "83d036426aaa0907609fba83c418b052", "score": "0.7924793", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "83d036426aaa0907609fba83c418b052", "score": "0.7924793", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "e315cc188bd3e8856abf2d7de49c7eef", "score": "0.79144746", "text": "function resetSchedulerState() {\n queue.length = 0;\n userQueue.length = 0;\n has = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = false;\n}", "title": "" }, { "docid": "e315cc188bd3e8856abf2d7de49c7eef", "score": "0.79144746", "text": "function resetSchedulerState() {\n queue.length = 0;\n userQueue.length = 0;\n has = {};\n if (process.env.NODE_ENV !== 'production') {\n circular = {};\n }\n waiting = false;\n}", "title": "" }, { "docid": "e8ddd30850a2f806a5c7a8e905ce8069", "score": "0.78955543", "text": "function resetSchedulerState() {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "e8ddd30850a2f806a5c7a8e905ce8069", "score": "0.78955543", "text": "function resetSchedulerState() {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n }", "title": "" }, { "docid": "20ef5e7287ae8e758c5608be414259b2", "score": "0.788747", "text": "function resetSchedulerState () {\n queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" }, { "docid": "719561cde91ba6ae23f9a00d1f6f36ef", "score": "0.78867775", "text": "function resetSchedulerState () {\n index = queue.length = activatedChildren.length = 0;\n has = {};\n {\n circular = {};\n }\n waiting = flushing = false;\n}", "title": "" } ]
a128b13f23105d1f62415d486c14ad99
create an onclick function for the background color blue
[ { "docid": "2c53e38ec043e2b7e021d47b210df974", "score": "0.77002126", "text": "function bgColorBlue (event){ // create the function with the name bgColorBlue on event\n document.getElementById(\"blue\").style.backgroundColor= \"blue\"; // tell what the function need to do using \"style.backgroundColor\" to change it\n }", "title": "" } ]
[ { "docid": "3f19a779362947ac311fe80c7fcf7e36", "score": "0.74275684", "text": "function bgColorGreen (event){ // create the function with the name bgColorGreen on event\n document.getElementById(\"green\").style.backgroundColor= \"green\"; // tell what the function need to do using \"style.backgroundColor\" to change it\n }", "title": "" }, { "docid": "1966f567949a5ef0dff34133d4b09b7a", "score": "0.7354568", "text": "function box4_click(evt){\r\n\t\r\n\tif(bcolor == 0){\r\n\t\t\r\n\tdocument.documentElement.style.backgroundColor = \"#000\"\r\n\t\r\n\tbcolor = 1;\r\n\t\t\r\n\t}else if(bcolor == 1){\r\n\t\t\r\n\t\tdocument.documentElement.style.backgroundColor = \"#FFF\"\r\n\t\t\r\n\t\tbcolor = 0;\r\n\t}\r\n\t\t\r\n\t\r\n}", "title": "" }, { "docid": "75b5d3c4c92943b84a0f249deca217c2", "score": "0.7317672", "text": "function onClickPaint(event) {\n event.target.style.backgroundColor = currentColor;\n}", "title": "" }, { "docid": "f9dfc802311e83e6e4002ed4249a3a9d", "score": "0.72610664", "text": "function bgColorRed (event){ // create the function with the name bgColorRed on event\n document.getElementById(\"red\").style.backgroundColor= \"red\"; // tell what the function need to do using \"style.backgroundColor\" to change it\n }", "title": "" }, { "docid": "514189072e40cc8ffabd7e7ecf534402", "score": "0.7208785", "text": "function bgColorYellow (event){ // create the function with the name bgColorYellow on event\n document.getElementById(\"yellow\").style.backgroundColor= \"yellow\"; // tell what the function need to do using \"style.backgroundColor\" to change it\n }", "title": "" }, { "docid": "466b6365a2eaac6afd2abdc4dbdb5121", "score": "0.7171906", "text": "function mousePressed(){\nbackgroundColor = blue;\n\n}", "title": "" }, { "docid": "9a56d2bd46ff3f1ea34baf339b6d7eba", "score": "0.7103351", "text": "function clickEvent(){\n console.log(\"button clicked\")\n var item1=document.getElementById('one');\n item1.style.backgroundColor=\"cyan\";\n \n}", "title": "" }, { "docid": "0ba4d2405a4f2f9515237b2e75e13ec0", "score": "0.708566", "text": "function on(objeto) {\r\nobjeto.style.background='#FFC37F';\r\n}", "title": "" }, { "docid": "ad32fc06ae65508fe6330d0d9bffdb3d", "score": "0.70503527", "text": "function itsClicked() {\n\n //Use the this method to retrieve the desired attribute\n this.style.backgroundColor = this.getAttribute(\"data-color\");\n}", "title": "" }, { "docid": "9f9dfa761dfd3e912a9f4684b626abff", "score": "0.70285815", "text": "function colorThemOwn() {\n button.style.background = buttonValue;\n }", "title": "" }, { "docid": "fd7ac362c3a33806b75065079134d4bd", "score": "0.6994536", "text": "function btnClick(e){\n console.log(\"the button was clicked\");\n console.log(e.target);\n console.log(e);\n // *here we send the colour value(called data-colour in the html) to the function changeBackground\n changeBackground(e.target.dataset.colour);\n}", "title": "" }, { "docid": "596627cb9e4553d00dfa867747b0f05a", "score": "0.69646543", "text": "function POV(but)\n{\n but.style.backgroundColor=\"#FFB547\";\n but.style.color=color_on;\n}", "title": "" }, { "docid": "d00bf2e675fd1d582d2cca285f053aaf", "score": "0.69627124", "text": "function changecolor(color){\n document.getElementById(color).addEventListener(\"click\",colorButton);\n function colorButton(){\n document.getElementById(\"square\").style.backgroundColor = color;\n }\n}", "title": "" }, { "docid": "4d9627a0dc1d78f3f8504d860c3df85c", "score": "0.69344616", "text": "function colorButton(element,color){\n element.style.backgroundColor=color;\n}", "title": "" }, { "docid": "e444422011369da602dcb7abb28843f9", "score": "0.69216985", "text": "function yellowcolor() {\n\t\t\t document.getElementByID(\"btn\").style.backgroundcolor =\"yellow\";\n\t\t\t \n\t\t }", "title": "" }, { "docid": "cb87a9016213b1a2caa9bdd4f1ce503f", "score": "0.6920712", "text": "function setNormalColor(){\n btn.style.background =\"\";\n }", "title": "" }, { "docid": "3fbcdd7ff60b42ea8349d60f69cc9085", "score": "0.69160676", "text": "function clickablePixel(){ //make it turn black\n event.target.style.backgroundColor = randomColor;\n}", "title": "" }, { "docid": "8e73957a3181650dcad373f3b94d561b", "score": "0.6888247", "text": "function clickColor(event) {\n event.currentTarget.classList.add(\"aqua\");\n\n if(event.currentTarget.classList.contains(\"aqua\")) {\n event.currentTarget.classList.toggle(\"salmon\");\n } \n }", "title": "" }, { "docid": "57662ac02d6d6d5361f046605a29729e", "score": "0.68858886", "text": "function drawingColor(clickEvent) {\n var btn = clickEvent.target;\n if (imouseDown === true) {\n btn.style.backgroundColor = color;\n }\n\n}", "title": "" }, { "docid": "1589f8b5d0f0139f7ebf5f6a8ad1a515", "score": "0.6882959", "text": "function changecolor(color){\n caja.style.background=color;\n}", "title": "" }, { "docid": "5221d6f590952405faa863e5e40117d9", "score": "0.6873482", "text": "function colorOne() {\n green.style.backgroundColor = \"lightgreen\";\n}", "title": "" }, { "docid": "71d5d97bd06b60549750d8076cdf00bc", "score": "0.6859812", "text": "function ChangeColor(e) {\n e.target.style.backgroundColor = \"blue\";\n }", "title": "" }, { "docid": "bf9b847e57571b16fbccff5212262de2", "score": "0.6845027", "text": "function apply_task_onclick() {\r\n for (i = 0; i < tasks_list.length-1 ; i++) {\r\n var task = tasks_list[i];\r\n //task.style.background=\"aliceblue\"\r\n task.onclick = function (e) {task_onclick(e)};\r\n }\r\n}", "title": "" }, { "docid": "f3ec54ce88168e4c4068b066f02c7e34", "score": "0.684221", "text": "function activateEvents(){\n //anonymous function calls style function with target and color arguments\n wrapper.addEventListener(\"click\", function(e){\n style(e, \" tomato \")\n });\n}", "title": "" }, { "docid": "de02e9dffb7c187e75cb10eadc72cbae", "score": "0.6818307", "text": "function changeColor(e){\n e.target.style.backgroundColor = 'black';\n}", "title": "" }, { "docid": "0de149b8364609a5fe99c77ed03fb7aa", "score": "0.6801218", "text": "function onColorChange(sq){\n\tsq.style.backgroundColor = createRGB();\n}", "title": "" }, { "docid": "76b3690320df63456701dbcbd8edb1fc", "score": "0.6794417", "text": "function gosI(e)\r\n{this.style.background='#FFFFFF';\r\n}", "title": "" }, { "docid": "4636813045f8adfe26fb3854cd22dbc4", "score": "0.67896295", "text": "function clickChange() {\n\tconst randomColor = 'rgb(' + rgb(255) + ',' + rgb(255) + ',' + rgb(255) + ')';\n event.target.style.backgroundColor = randomColor;\n document.getElementById(\"click-color\").innerHTML = \"This color's rgb code is \" + randomColor;\n}", "title": "" }, { "docid": "8ca6f247b2d6af103a86225b38f86311", "score": "0.67826", "text": "function CelActiveButton() {\n document.getElementById(\"cel\").style.backgroundColor = \"#3b6978\";\n document.getElementById(\"far\").style.backgroundColor = \"#204051\";\n}", "title": "" }, { "docid": "47d8d7af91ee646546552dab882ae04e", "score": "0.6778935", "text": "function isClicked(event){\r\n //retrieve the color stored in data-attribute in the variable changedColor of the event target\r\n let changedColor = event.target.getAttribute(\"data-attribute\");\r\n //change the event target's color to changedColor\r\n event.target.style.backgroundColor = changedColor;\r\n}", "title": "" }, { "docid": "75c9b80bc99a9432783c31d26611187c", "score": "0.6775914", "text": "function btnClicked(element) {\n if(isClicked(rainbowBtn) === true) {\n element.style.backgroundColor = rdmColor(element);\n } else if(isClicked(colorInputLabel) === true) {\n element.style.backgroundColor = color;\n } else if(isClicked(eraseBtn) === true) {\n element.style.backgroundColor = 'white';\n } \n}", "title": "" }, { "docid": "fffed7915ba61be2418b2b2825053d8a", "score": "0.67339283", "text": "function cambiaColor(color){\n caja2.style.background=color;\n}", "title": "" }, { "docid": "85a3fc596776238caeebcfcab0471282", "score": "0.66973215", "text": "function cambiaColor(color) {\n caja.style.background = color; \n}", "title": "" }, { "docid": "5ae2fd19cb98ad8acbe00ffd7db72277", "score": "0.6685763", "text": "function bgClicked(elmnt) {\t\n\tvar color1 = elmnt.getElementsByTagName(\"p\")[0].getAttribute(\"bgColor\");\n\tvar color2 = elmnt.getElementsByTagName(\"p\")[1].getAttribute(\"bgColor\");\n\t\n\tvar selectedBGColors = {\n\t\t0:{\n\t\t\t\"id\" : \"color1\",\n\t\t\t\"value\" : color1\n\t\t},\n\t\t1:{\n\t\t\t\"id\" : \"color2\",\n\t\t\t\"value\" : color2\n\t\t}\n\t};\n\t\n\tself.port.emit(\"colorSelection\", selectedBGColors);\n\t\n}", "title": "" }, { "docid": "416037c984a7d197a1cd84808ffd2a6d", "score": "0.66855687", "text": "function absolutePaint(e) {\n e.target.style.backgroundColor = \"rgb(255, 255, 255)\";\n}", "title": "" }, { "docid": "db6201a06bdacab161c8130da7541a30", "score": "0.66727334", "text": "function selected() {\n colorSelected = document.getElementById(\"selectedID\").value;\n let data = document.querySelectorAll(\"td\");\n data.forEach((td) => {\n td.onclick = function() {\n td.style.backgroundColor = colorSelected;\n }\n });\n\n}", "title": "" }, { "docid": "fb0b4e1668b6621f4a3d5817bef084d6", "score": "0.6660919", "text": "function clickedBox(event) {\n const color = colorInput.value;\n event.target.style.backgroundColor = color;\n \n}", "title": "" }, { "docid": "d3075e7ee19662f05665c52872050a16", "score": "0.6658502", "text": "function changeColor(e) {\n if (e.style.backgroundColor != \"green\") {\n e.style.backgroundColor = \"green\";\n } else {\n e.style.backgroundColor = \"antiquewhite\";\n }\n}", "title": "" }, { "docid": "298a17e43524b1a4ccd654b9e44cec78", "score": "0.6652415", "text": "function mouseClick (id) {\n var temp = event.target.id;\n this.addEventListener(\"onmousedown\", changeColor(temp)); \n document.getElementById(temp).style\n .setProperty('opacity', \"1\");\n \n}", "title": "" }, { "docid": "c1b869e86e7663b6046c982251f620cb", "score": "0.66399723", "text": "function blue() {\r\n document.getElementById('header').style.backgroundColor = '#20b2aa'\r\n}", "title": "" }, { "docid": "588f53606456a3dd1acb8d7ca71d01dc", "score": "0.6638994", "text": "function cambiaColor(color){\n\n caja.style.background = color ; \n}", "title": "" }, { "docid": "d6a3a8185945ee476b04fc40df4620ba", "score": "0.663188", "text": "function thirdFunction1() {\n var box4 = document.querySelector(\"#b4\");\n box4.style.backgroundColor = \"blue\";\n console.log(\"clicked down\");\n}", "title": "" }, { "docid": "d64f710d013edddd88f1ec8c68ed95bc", "score": "0.66125804", "text": "function mousePressed(){\n background(0,255,0);\n}", "title": "" }, { "docid": "fcf2d406c0b85e3422b03503c2e197bc", "score": "0.6602617", "text": "function handleClick() {\n const button = document.getElementById(\"target\")\n if (button.style.backgroundColor === \"blue\") {\n button.style.backgroundColor = \"\"\n } else {\n button.style.background = \"blue\"\n }\n}", "title": "" }, { "docid": "3b1c3e6908ec82a8183741b8cc32847e", "score": "0.65943265", "text": "function colorCells(){\n var color = document.getElementById(\"colorPicker\").value; // get the value of color\n event.target.style.background = color //this color the cell that we clicked on\n}", "title": "" }, { "docid": "0ce411bb9a36ba967bf6e85495f70be9", "score": "0.6569765", "text": "function addColor(event) {\n event.target.style.backgroundColor = \"#3592C9\";\n}", "title": "" }, { "docid": "6b66856d8da234b63ff4800e6b1df1b1", "score": "0.65655255", "text": "function cambiaColor(color){\n caja.style.background = color;\n}", "title": "" }, { "docid": "e7fddf32108b56e5e0c0489436964997", "score": "0.6552945", "text": "function draw(e) {\n e.target.style.background = 'black';\n}", "title": "" }, { "docid": "a5c9846ad4f073bf36490e8f893f6e38", "score": "0.6538113", "text": "function addBlack(e){\r\n e.srcElement.style.backgroundColor = \"black\";\r\n}", "title": "" }, { "docid": "be55a58eb40072b2af728c24d5dbeedf", "score": "0.6530525", "text": "function cambiaColor(color) {\n caja.style.background = color;\n}", "title": "" }, { "docid": "f42f8c9c5f61d5cfee95dc8903b0a1fd", "score": "0.6527197", "text": "function greenButtonHandler(){\n var button = document.getElementById(\"green-button\");\n button.style.backgroundColor = \"#1e1e24\";\n button.style.color = \"#9b9bc4\";\n button.innerHTML = \"Aww, thanks for touching me <3\";\n}", "title": "" }, { "docid": "81bb47c33ba431f814e13658d3fcb5ae", "score": "0.6519445", "text": "function pintarGrilla(e){\n e.target.style.backgroundColor = indicadorColor.style.backgroundColor;\n}", "title": "" }, { "docid": "32ccd9008ea44726a218764467b2c9e0", "score": "0.65147877", "text": "function clickedBox(event) {\n\tconsole.log(\"colorPicker is running!\");\n\tconst color = document.getElementById(\"colorPicker\").value\n\tevent.target.style.backgroundColor = color;\n}", "title": "" }, { "docid": "a2ba8bc14068d56aa227dd6eec50f9b5", "score": "0.651142", "text": "function set_background() {\n const pBackgroundColor = document.getElementById('change-color');\n pBackgroundColor.style.backgroundColor = 'red';\n }", "title": "" }, { "docid": "5f1812240bfc792c7e8f10aed1686207", "score": "0.6510945", "text": "function cambiaColor(color){\n\tcaja.style.background=color;\n}", "title": "" }, { "docid": "7542880930c18d1699f6bf606b2cde1c", "score": "0.650406", "text": "function changeRed() {\n red.style.backgroundColor = \"#8B0000\"\n}", "title": "" }, { "docid": "a864ff71d0b0dd6db7b3cb6dc3a184f0", "score": "0.6503823", "text": "function setColor(color, id) {\n if (color != null) {\n var cell = document.getElementById(id);\n cell.setAttribute(\"style\", \"background: \" + color);\n\n // add function\n if (cell.getAttribute(\"onclick\") == null) {\n cell.setAttribute(\"onclick\", \"activeCell(this)\");\n }\n }\n}", "title": "" }, { "docid": "ff0931f45cdca863a22db9adf1e9fa94", "score": "0.6494768", "text": "function cambiarColor(color){\n caja.style.background = color;\n}", "title": "" }, { "docid": "f9c1e2cc53acf26eb22a5821fc9abf6a", "score": "0.64835685", "text": "function changeBackground(){\r\n\r\nvar text = document.getElementById(\"event\").style.backgroundColor =\"red\";\r\n\r\n}", "title": "" }, { "docid": "9b5f4966790474bd04ccce9a02546c8f", "score": "0.647978", "text": "function FilaActiva(xID)\n{\n document.getElementById(xID).style.backgroundColor = \"#ECF3F5\";\n}", "title": "" }, { "docid": "6d91536b946d37182722d4b1f98a85a8", "score": "0.6478201", "text": "function addColor() {\n theGrid.on(\"click\", \"td\", function(e) {\n $(this).css(\"background-color\", currentColor);\n });\n }", "title": "" }, { "docid": "dcd3f7098857c3db17f1861f95901ed5", "score": "0.64736116", "text": "function cambiaColor(color){\n caja.style.background = (color);\n}", "title": "" }, { "docid": "a19d61ea8e541b62f9f31d823083b809", "score": "0.64734125", "text": "function change_one() {\n this.style.backgroundColor = \"#008000\";\n}", "title": "" }, { "docid": "f5882c923b8eaa3dae562af5c259d80a", "score": "0.6471879", "text": "function elegirColor (evt) {\n /* Obtengo el color */\n micoTiti = $(\"#colorPicker\").val();\n\n /* Asigno el color a la celda en la que se hizo click */\n $('#pixel_canvas').on('click', 'td', function() {\n $(this).css('background-color', micoTiti );\n });\n console.log(micoTiti);\n}", "title": "" }, { "docid": "6b7393cdd1c1fb61edfecc8399f21e07", "score": "0.6440847", "text": "function makeYellow(event) {\n event.currentTarget.style['background-color'] = 'yellow';\n}", "title": "" }, { "docid": "79d867ac14f11acacefcee2886a25c9f", "score": "0.64404064", "text": "function changeColor() {\n bgcolor = color(255, 0, 255);\n\n}", "title": "" }, { "docid": "a4ee740aa69532e2e9c8557353dc25ad", "score": "0.6439386", "text": "function onClick() { \n //The third line is the function that is done after the item is clicked. In this case the function is turning the text red.\n myitem.style.color= \"red\"; \n myitem.style.backgroundColor= \"black\";\n }", "title": "" }, { "docid": "4ee5ff3de70e72abbf7d7b13c5472bf2", "score": "0.6438747", "text": "SetButton(wall){\n \n var col = document.getElementById(wall).style.backgroundColor;\n if(col==\"lightgrey\"){\n \n document.getElementById(wall).style.backgroundColor =\"rosybrown\";\n }\n else{\n \n document.getElementById(wall).style.backgroundColor=\"lightgrey\";\n }\n}", "title": "" }, { "docid": "c76fe935b5f07198e87c6c0216101754", "score": "0.64372355", "text": "function Draw(e) {\n \n Object.assign(e.target.style, {\n backgroundColor : '#FF0000',\n });\n}", "title": "" }, { "docid": "cfafd9e57049e04f1c2332e4c7dac520", "score": "0.64286214", "text": "function redCheck(event) {\n event.target.setAttribute(\"style\", \"background-color: #F22C36;\");\n }", "title": "" }, { "docid": "c546dead0b90dc354abb5185b8d410a9", "score": "0.64184886", "text": "function greenIsTheBestColor(event){\n event.target.style.backgroundColor = \"green\";\n}", "title": "" }, { "docid": "3bc33d13b9190cbdf074f5587599f7db", "score": "0.64182884", "text": "function selectColor(){\n createBoxes();\n checkIfClicked();\n displayColor();\n}", "title": "" }, { "docid": "4519d69066ddcb4652d158579ea5b20f", "score": "0.64134103", "text": "function random_bg_color() {\n var x = Math.floor(Math.random() * 256);\n var y = Math.floor(Math.random() * 256);\n var z = Math.floor(Math.random() * 256);\n var bgColor = \"rgb(\" + x + \",\" + y + \",\" + z + \")\";\n document.body.style.background = bgColor;\n document.getElementById('loadQuote').onclick = bgColor;\n \n }", "title": "" }, { "docid": "285c4d4789772936a836b086b13f2b73", "score": "0.63961875", "text": "function test_button() {\n var my_test_div = document.getElementById(\"test\");\n my_test_div.innerHTML= \"button clicked!\";\n my_test_div.style.backgroundColor = \"blue\"; /*change the background in blue*/\n alert(\"clicked\");\n\n}", "title": "" }, { "docid": "a7e421da49dead2ea2d327e101095990", "score": "0.6391484", "text": "function changeColor() {\n this.style.backgroundColor = colorSelected;\n}", "title": "" }, { "docid": "a55c2169a2375d00e4d7af5650f48925", "score": "0.6386554", "text": "function aplicarOutputButton(ID, value){\n if (value == 1) {\n document.getElementById(ID).style.backgroundColor = \"red\";\n }else{\n document.getElementById(ID).style.backgroundColor = \"grey\";\n }\n}", "title": "" }, { "docid": "590fce2f4077e5d969b30b3eedabd79c", "score": "0.63759464", "text": "function colorButtonHandler() {\n\t\tArray.prototype.forEach.call(playersColorsButtons, (btn) => {\n\t\t\tbtn.addEventListener(\"click\", (e) => {\n\t\t\t\tlet btnStyle = window.getComputedStyle(btn);\n\t\t\t\tlet color = btnStyle.getPropertyValue(\"background-color\");\n\t\t\t\te.preventDefault();\n\t\t\t\tbtn.classList.contains(\"cs1\")\n\t\t\t\t\t? pickColor(\"cs1\", color)\n\t\t\t\t\t: pickColor(\"cs2\", color);\n\t\t\t});\n\t\t});\n\t}", "title": "" }, { "docid": "81930b39a9b68448b7c6ba05efbdac30", "score": "0.6374173", "text": "function drawColor()\n{ \n if (isColored)\n {\n //is already colored, making black\n randBtn.textContent=\"Color: Off\"\n randBtn.style.backgroundColor=\"\";\n divs.forEach(cell => cell.addEventListener('mouseover', addClass));\n isColored=false;\n }\n else\n {\n //not colored, adding color\n randBtn.textContent=\"Color: On\"\n randBtn.style.backgroundColor=\"Salmon\";\n divs.forEach(cell => cell.addEventListener('mouseover', addClass));\n isColored=true;\n }\n}", "title": "" }, { "docid": "0ff11ec982eff58e6a04bc313b8ef9ad", "score": "0.6364069", "text": "function cambiaColor(color){\n\tcaja.style.background = color;\n}", "title": "" }, { "docid": "bb36f99ccccd8a1c673f7ecaf20dbc35", "score": "0.6362856", "text": "function clicar() {\n\n area.innerText = 'Clicou!';\n area.style.backgroundColor = 'red';\n\n}", "title": "" }, { "docid": "445888c3c51f3f29fb215fdcfb6e8845", "score": "0.63610685", "text": "function over() {\n document.querySelector('#button').style.background = \"#2d18a1\";\n}", "title": "" }, { "docid": "6fa3c694a75486967ceebe54a8eac2c1", "score": "0.6357344", "text": "function changeColor()\n{\n // bodyBackGround.style.backgroundColor=\"red\";\n // if (changeColor.arguments[0]===0)\n // {\n // colorBtn1.style.color=\"red\";\n // bodyBackGround.style.backgroundColor='red';\n // }\n // else if(changeColor.arguments[1]===1)\n // {\n // // changing the background color to a random index of the possible color list\n // bodyBackGround.style.backgroundColor=possibleColors[Math.floor(Math.random()*possibleColors.length)];\n // }\n // else if (changeColor.arguments[2]===2)\n // {\n // bodyBackGround.style.backgroundColor='blue';\n // }\n\n // Uncomment the following to generate a random number and attach this function to any event listener variable\n bodyBackGround.style.backgroundColor=possibleColors[Math.floor(Math.random()*possibleColors.length)];\n\n \n}", "title": "" }, { "docid": "0f72053e6617a71e1630ae4444918c81", "score": "0.63530695", "text": "function chBackground (x){\n x.style.background = \"#F0F0F0\";\n}", "title": "" }, { "docid": "0445afa27aad2609b6fc8c11f607dd4c", "score": "0.6353031", "text": "function changeColor(newColor) {\n let btn = document.getElementById(\"text\");\n btn.style.backgroundColor = newColor;\n}", "title": "" }, { "docid": "5d9cd65191b9f0b7ac6aa99657964664", "score": "0.635046", "text": "function changeBackgroundColor(event) {\n console.log(\"Click happened! Here's the click event:\");\n console.log(event); \n document.body.style.background = getRandomColor();\n}", "title": "" }, { "docid": "50a15aa6bf28b64f79149e448c48a1b6", "score": "0.6350079", "text": "function leop(){\n props.style.color = \"blue\";\n console.log(\"clicked\");\n}", "title": "" }, { "docid": "31a97b71f5039694f9b376f98c0b700f", "score": "0.6347671", "text": "function task_onclick(e) {\r\n console.log(\"task_onclick\")\r\n var task = e.target.parentNode\r\n if (task.cells[5].innerHTML==\" ► \") { \r\n console.log(\"aliceblue\")\r\n //reset_task_choice()\r\n task.style.background=\"linear-gradient(to left,lightgreen,white)\"\r\n task.style.backgroundAttachment=\"fixed\"\r\n task.cells[5].innerHTML=\"&#10074; &#10074;\"\r\n } else {\r\n console.log(\"else\")\r\n task.style.background=\"aliceblue\"\r\n task.cells[5].innerHTML=\" ► \";\r\n }\r\n updateCookies();\r\n}", "title": "" }, { "docid": "c608be08758d5519b41fd3ea0b42458f", "score": "0.6344696", "text": "function changeColor(event) {\n \n if(square == true){\n event.currentTarget.style.backgroundColor = '#FF0000';\n square = false\n }else{\n event.currentTarget.style.backgroundColor = '#0000FF';\n square = true;\n }\n \n \n}", "title": "" }, { "docid": "ff8f3f8aea6c76b4b3e45121c7b6ee03", "score": "0.6324593", "text": "function onGranted() {\r\n requestButton.style.background = \"#73AD21\";\r\n}", "title": "" }, { "docid": "3cccadb7bf2d010a1d587bc2f9809aa0", "score": "0.6319703", "text": "function changeBackground(id,color) \n{\n document.getElementById(id).style.background = color;\n}", "title": "" }, { "docid": "4b677f672b58e2b359fb3611804e9142", "score": "0.63111734", "text": "actionOnClick(){\n continueButton.setStyle({ color: '#ff0'});\n }", "title": "" }, { "docid": "c4636606141edca784dfb2d214f79136", "score": "0.6308175", "text": "function changeColor(btn, color) {\n $(btn).css(\"background-color\", color);\n}", "title": "" }, { "docid": "ebc0e236495d3abc7c2f82b23ed90385", "score": "0.6307461", "text": "function onClick() { // function added to make color change on click\n myitem.style.color = \"green\";\n myitem.style.fontSize = \"2em\";\n}", "title": "" }, { "docid": "d6f9b1c421545a2d520d8fac4ce1dd6c", "score": "0.63061154", "text": "function cambiarColor(id) {\n document.getElementById(id).style.backgroundColor = \"green\";\n\n}", "title": "" }, { "docid": "60f92d75e1ed5a348f332db2bf8d174b", "score": "0.630512", "text": "function moon(){\r\n document.body.style.backgroundColor = \"#161625\"; \r\n document.getElementById(\"side\").style.backgroundColor = \"#1e1e30\";\r\n document.getElementById(\"searchbar\").style.backgroundColor = \"#1E1E30\";\r\n document.getElementById(\"sun\").style.backgroundColor = \"#161625\";\r\n document.getElementById(\"moon\").style.backgroundColor = \"#161625\";\r\n document.getElementById(\"calc\").style.backgroundColor = \"#1E1E30\";\r\n alt_black();\r\n }", "title": "" }, { "docid": "cccf612b51a9d4cbb08f18f4cb450e91", "score": "0.6304133", "text": "function changeBackground(color) {\r\n switch (color) {\r\n case \"green\":\r\n greenButton.style.backgroundColor = \"#003E00\";\r\n setTimeout(function() {\r\n greenButton.style.backgroundColor = \"green\";\r\n }, 100);\r\n break;\r\n case \"red\":\r\n redButton.style.backgroundColor = \"#A00000\";\r\n setTimeout(function() {\r\n redButton.style.backgroundColor = \"red\";\r\n }, 100);\r\n break;\r\n case \"yellow\":\r\n yellowButton.style.backgroundColor = \"#A0A000\";\r\n setTimeout(function() {\r\n yellowButton.style.backgroundColor = \"yellow\";\r\n }, 100);\r\n break;\r\n case \"blue\":\r\n blueButton.style.backgroundColor = \"#0000A0\";\r\n setTimeout(function() {\r\n blueButton.style.backgroundColor = \"blue\";\r\n }, 100);\r\n break;\r\n }\r\n}", "title": "" }, { "docid": "2d1016308ca50a62a4a8c74e1e4fe46b", "score": "0.6303078", "text": "function changeColor(element){\n\telement.style.backgroundColor = '#888'\n}", "title": "" }, { "docid": "6f08da7aaa4127a99832ac0f0655c1a0", "score": "0.6292594", "text": "function handleSolidClick() {\n solidState = !solidState;\n document.getElementById('solid-container').style.color = (solidState) ? BLACK : GREY;\n}", "title": "" }, { "docid": "5bb751066e3f641168d4a0f7c15bc8f4", "score": "0.6282972", "text": "function onmouse() {\n var x;\n x = document.getElementById(\"demo\");\n\tx.style.backgroundColor = \"red\";\n}", "title": "" }, { "docid": "b3860bf057ad1a3b51c78f6199473aae", "score": "0.6266689", "text": "function correctClicked(){\n // Set every square to the desired color\n for (var index = 0; index < squares.length; index++)\n squares[index].style.backgroundColor = desiredColor;\n\n // Set the heading background to the desired color\n heading.style.backgroundColor = desiredColor;\n\n // Change \"New Colors\" to \"Play Again\"\n newColorsBtn.textContent = \"Play Again\";\n}", "title": "" } ]
b39cb880d3f1b38c375deb84d579b143
Merge two option objects into a new one. Core utility used in both instantiation and inheritance.
[ { "docid": "442979889cff4f6d05e17e8bb7c442a9", "score": "0.0", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (process.env.NODE_ENV !== 'production') {\n checkComponents(child);\n }\n normalizeProps(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = typeof extendsFrom === 'function'\n ? mergeOptions(parent, extendsFrom.options, vm)\n : mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n var mixin = child.mixins[i];\n if (mixin.prototype instanceof Vue$2) {\n mixin = mixin.options;\n }\n parent = mergeOptions(parent, mixin, vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" } ]
[ { "docid": "513080177a1d2c4654e2b930b839bcb8", "score": "0.7287205", "text": "function merge_options(o1, o2) {\r\n\r\n\t\t\tvar o3 = {},\r\n\t\t\t\tattrname;\r\n\r\n\t\t\tfor (attrname in o1) {\r\n\t\t\t\tif (o1.hasOwnProperty(attrname)) {\r\n\t\t\t\t\to3[attrname] = o1[attrname];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\tfor (attrname in o2) {\r\n\t\t\t\tif (o2.hasOwnProperty(attrname)) {\r\n\t\t\t\t\to3[attrname] = o2[attrname];\r\n\t\t\t\t}\r\n\t\t\t}\r\n\r\n\t\t\treturn o3;\r\n\t\t}", "title": "" }, { "docid": "0017ac46ddce01d58ae583ce57330cfd", "score": "0.7285076", "text": "function merge_options(obj1,obj2){\n var obj3 = {};\n for (var attr in obj1) { obj3[attr] = obj1[attr]; }\n for (var attr in obj2) { obj3[attr] = obj2[attr]; }\n return obj3;\n}", "title": "" }, { "docid": "31345313827f5535ec18fb80693219f1", "score": "0.72172296", "text": "function _mergeOptions(obj1,obj2) {\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "31345313827f5535ec18fb80693219f1", "score": "0.72172296", "text": "function _mergeOptions(obj1,obj2) {\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "31345313827f5535ec18fb80693219f1", "score": "0.72172296", "text": "function _mergeOptions(obj1,obj2) {\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "31345313827f5535ec18fb80693219f1", "score": "0.72172296", "text": "function _mergeOptions(obj1,obj2) {\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "31345313827f5535ec18fb80693219f1", "score": "0.72172296", "text": "function _mergeOptions(obj1,obj2) {\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "31345313827f5535ec18fb80693219f1", "score": "0.72172296", "text": "function _mergeOptions(obj1,obj2) {\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "2bdf96b4fa1735ec3309d50d3397e816", "score": "0.72129375", "text": "function mergeOptions() {\n var mergedOptions = {};\n var args = arguments;\n // Iterate over all specified options objects and add all properties to the new options object\n for (var i = 0; i < args[_LENGTH_]; i++) {\n var argument = args[i];\n for (var key in argument) {\n if (argument.hasOwnProperty(key)) {\n mergedOptions[key] = argument[key];\n }\n }\n }\n return mergedOptions;\n }", "title": "" }, { "docid": "d76982543cf8e56de6f056d70539403f", "score": "0.7202331", "text": "function merge_options(obj1, obj2) {\n var obj3 = {};\n for (var attrname in obj1) {\n obj3[attrname] = obj1[attrname];\n }\n for (var attrname in obj2) {\n obj3[attrname] = obj2[attrname];\n }\n return obj3;\n}", "title": "" }, { "docid": "73d1df3e46da2af17eaea5bad35d6989", "score": "0.71798235", "text": "function merge_options(obj1,obj2){\n var obj3 = {};\n for (var attrname in obj1) { obj3[attrname] = obj1[attrname]; }\n for (var attrname in obj2) { obj3[attrname] = obj2[attrname]; }\n return obj3;\n }", "title": "" }, { "docid": "1ace4f235bfdbffc2a367fa49d86e2e9", "score": "0.71396905", "text": "function _mergeOptions(obj1, obj2) {\n var obj3 = {};\n for (var attrname in obj1) {\n obj3[attrname] = obj1[attrname];\n }\n for (var attrname in obj2) {\n obj3[attrname] = obj2[attrname];\n }\n return obj3;\n }", "title": "" }, { "docid": "8801d56daba9b9d1d7d852906f57e753", "score": "0.71209466", "text": "function mergeOpts(opts1, opts2) {\n var newOpts = __assign({}, opts1);\n if (opts2.hasOwnProperty(\"discover\")) {\n newOpts.discover = opts2.discover;\n }\n if (opts2.hasOwnProperty(\"numberedExpressions\")) {\n newOpts.numberedExpressions = opts2.numberedExpressions;\n }\n if (opts2.extract && opts2.extract.location) {\n if (newOpts.extract) {\n newOpts.extract.location = opts2.extract.location;\n }\n else {\n newOpts.extract = opts2.extract;\n }\n }\n return newOpts;\n}", "title": "" }, { "docid": "1233d26c8affda5a7ad32e06a51878a8", "score": "0.7107326", "text": "function mergeOption(oldOption, newOption) {\n\t newOption = newOption || {};\n\t\n\t each(newOption, function (newCptOpt, mainType) {\n\t if (newCptOpt == null) {\n\t return;\n\t }\n\t\n\t var oldCptOpt = oldOption[mainType];\n\t\n\t if (!ComponentModel.hasClass(mainType)) {\n\t oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n\t }\n\t else {\n\t newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n\t oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\t\n\t var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\t\n\t oldOption[mainType] = map(mapResult, function (item) {\n\t return (item.option && item.exist)\n\t ? merge(item.exist, item.option, true)\n\t : (item.exist || item.option);\n\t });\n\t }\n\t });\n\t }", "title": "" }, { "docid": "640b5e6efdab45aafaf81dc25b4b8e35", "score": "0.7095771", "text": "function mergeOptions(optionObjs) {\n return mergeProps(optionObjs, complexOptions);\n } // TODO: move this stuff to a \"plugin\"-related file...", "title": "" }, { "docid": "d52a5f2ecb2ce59cc1495c53bd1136a4", "score": "0.7092563", "text": "function mergeOptions(optionObjs){return util_1.mergeProps(optionObjs,complexOptions);}", "title": "" }, { "docid": "72f30df73cbc06fb798ba85cbfe777e2", "score": "0.70788187", "text": "function mergeOptions(optionObjs){return mergeProps(optionObjs,complexOptions);}", "title": "" }, { "docid": "9c74e351181803dc6564b9acf4c3f947", "score": "0.70700115", "text": "function mergeOption(oldOption, newOption) {\n\t newOption = newOption || {};\n\n\t each(newOption, function (newCptOpt, mainType) {\n\t if (newCptOpt == null) {\n\t return;\n\t }\n\n\t var oldCptOpt = oldOption[mainType];\n\n\t if (!ComponentModel.hasClass(mainType)) {\n\t oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n\t }\n\t else {\n\t newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n\t oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\n\t var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\n\t oldOption[mainType] = map(mapResult, function (item) {\n\t return (item.option && item.exist)\n\t ? merge(item.exist, item.option, true)\n\t : (item.exist || item.option);\n\t });\n\t }\n\t });\n\t }", "title": "" }, { "docid": "9c74e351181803dc6564b9acf4c3f947", "score": "0.70700115", "text": "function mergeOption(oldOption, newOption) {\n\t newOption = newOption || {};\n\n\t each(newOption, function (newCptOpt, mainType) {\n\t if (newCptOpt == null) {\n\t return;\n\t }\n\n\t var oldCptOpt = oldOption[mainType];\n\n\t if (!ComponentModel.hasClass(mainType)) {\n\t oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n\t }\n\t else {\n\t newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n\t oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\n\t var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\n\t oldOption[mainType] = map(mapResult, function (item) {\n\t return (item.option && item.exist)\n\t ? merge(item.exist, item.option, true)\n\t : (item.exist || item.option);\n\t });\n\t }\n\t });\n\t }", "title": "" }, { "docid": "9c74e351181803dc6564b9acf4c3f947", "score": "0.70700115", "text": "function mergeOption(oldOption, newOption) {\n\t newOption = newOption || {};\n\n\t each(newOption, function (newCptOpt, mainType) {\n\t if (newCptOpt == null) {\n\t return;\n\t }\n\n\t var oldCptOpt = oldOption[mainType];\n\n\t if (!ComponentModel.hasClass(mainType)) {\n\t oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n\t }\n\t else {\n\t newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n\t oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\n\t var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\n\t oldOption[mainType] = map(mapResult, function (item) {\n\t return (item.option && item.exist)\n\t ? merge(item.exist, item.option, true)\n\t : (item.exist || item.option);\n\t });\n\t }\n\t });\n\t }", "title": "" }, { "docid": "710211e10cc74477d304b565b2dbfbc3", "score": "0.70519984", "text": "mergeOptions(obj1, obj2) {\n let obj3 = {};\n for (let attr1 in obj1) { obj3[attr1] = obj1[attr1] }\n for (let attr2 in obj2) { obj3[attr2] = obj2[attr2] }\n return obj3;\n }", "title": "" }, { "docid": "8fd9bc568ddf9ce2e0c49bfd6a47d09a", "score": "0.70509684", "text": "function mergeOption(oldOption, newOption) {\n\t newOption = newOption || {};\n\t each(newOption, function (newCptOpt, mainType) {\n\t if (newCptOpt == null) {\n\t return;\n\t }\n\n\t var oldCptOpt = oldOption[mainType];\n\n\t if (!ComponentModel.hasClass(mainType)) {\n\t oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n\t } else {\n\t newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n\t oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\t var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\t oldOption[mainType] = map(mapResult, function (item) {\n\t return item.option && item.exist ? merge(item.exist, item.option, true) : item.exist || item.option;\n\t });\n\t }\n\t });\n\t}", "title": "" }, { "docid": "b328f7e5b68aba9e353016324f844cdb", "score": "0.7029564", "text": "function mergeOptions(obj1, obj2) {\n var obj3 = {};\n for (var attrname in obj1) {\n if (obj1.hasOwnProperty(attrname)) {\n obj3[attrname] = obj1[attrname];\n }\n }\n for (var attrname in obj2) {\n if (obj2.hasOwnProperty(attrname)) {\n obj3[attrname] = obj2[attrname];\n }\n }\n return obj3;\n}", "title": "" }, { "docid": "e0554711592184413c6c318592f02a25", "score": "0.7018433", "text": "function mergeOption(oldOption, newOption) {\n\t newOption = newOption || {};\n\n\t each(newOption, function (newCptOpt, mainType) {\n\t if (newCptOpt == null) {\n\t return;\n\t }\n\n\t var oldCptOpt = oldOption[mainType];\n\n\t if (!ComponentModel.hasClass(mainType)) {\n\t oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n\t } else {\n\t newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n\t oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\n\t var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\n\t oldOption[mainType] = map(mapResult, function (item) {\n\t return item.option && item.exist ? merge(item.exist, item.option, true) : item.exist || item.option;\n\t });\n\t }\n\t });\n\t}", "title": "" }, { "docid": "efb1562f68723eeb5bcafa8815d8461b", "score": "0.6979369", "text": "function mergeOption(oldOption, newOption) {\n newOption = newOption || {};\n\n each(newOption, function (newCptOpt, mainType) {\n if (newCptOpt == null) {\n return;\n }\n\n var oldCptOpt = oldOption[mainType];\n\n if (!ComponentModel.hasClass(mainType)) {\n oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n }\n else {\n newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\n var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\n oldOption[mainType] = map(mapResult, function (item) {\n return (item.option && item.exist)\n ? merge(item.exist, item.option, true)\n : (item.exist || item.option);\n });\n }\n });\n }", "title": "" }, { "docid": "efb1562f68723eeb5bcafa8815d8461b", "score": "0.6979369", "text": "function mergeOption(oldOption, newOption) {\n newOption = newOption || {};\n\n each(newOption, function (newCptOpt, mainType) {\n if (newCptOpt == null) {\n return;\n }\n\n var oldCptOpt = oldOption[mainType];\n\n if (!ComponentModel.hasClass(mainType)) {\n oldOption[mainType] = merge(oldCptOpt, newCptOpt, true);\n }\n else {\n newCptOpt = modelUtil.normalizeToArray(newCptOpt);\n oldCptOpt = modelUtil.normalizeToArray(oldCptOpt);\n\n var mapResult = modelUtil.mappingToExists(oldCptOpt, newCptOpt);\n\n oldOption[mainType] = map(mapResult, function (item) {\n return (item.option && item.exist)\n ? merge(item.exist, item.option, true)\n : (item.exist || item.option);\n });\n }\n });\n }", "title": "" }, { "docid": "67b93a4b4c95d992339b3ed45f1cfb91", "score": "0.6957411", "text": "function mergeOption(oldOption, newOption) {\n newOption = newOption || {};\n\n each$4(newOption, function (newCptOpt, mainType) {\n if (newCptOpt == null) {\n return;\n }\n\n var oldCptOpt = oldOption[mainType];\n\n if (!ComponentModel.hasClass(mainType)) {\n oldOption[mainType] = merge$1(oldCptOpt, newCptOpt, true);\n }\n else {\n newCptOpt = normalizeToArray(newCptOpt);\n oldCptOpt = normalizeToArray(oldCptOpt);\n\n var mapResult = mappingToExists(oldCptOpt, newCptOpt);\n\n oldOption[mainType] = map$1(mapResult, function (item) {\n return (item.option && item.exist)\n ? merge$1(item.exist, item.option, true)\n : (item.exist || item.option);\n });\n }\n });\n}", "title": "" }, { "docid": "15a83e92a2a52b345674a33dc6406507", "score": "0.6888813", "text": "function merge() {\n var i,\n args = arguments,\n len,\n ret = {},\n doCopy = function (copy, original) {\n var value, key;\n\n // An object is replacing a primitive\n if (typeof copy !== 'object') {\n copy = {};\n }\n\n for (key in original) {\n if (original.hasOwnProperty(key)) {\n value = original[key];\n\n // Copy the contents of objects, but not arrays or DOM nodes\n if (value && typeof value === 'object' && Object.prototype.toString.call(value) !== '[object Array]' &&\n key !== 'renderTo' && typeof value.nodeType !== 'number') {\n copy[key] = doCopy(copy[key] || {}, value);\n\n // Primitives and arrays are copied over directly\n } else {\n copy[key] = original[key];\n }\n }\n }\n return copy;\n };\n\n // If first argument is true, copy into the existing object. Used in setOptions.\n if (args[0] === true) {\n ret = args[1];\n args = Array.prototype.slice.call(args, 2);\n }\n\n // For each argument, extend the return\n len = args.length;\n for (i = 0; i < len; i++) {\n ret = doCopy(ret, args[i]);\n }\n\n return ret;\n }", "title": "" }, { "docid": "230470edc989d54fe09c369fffe73c58", "score": "0.6869222", "text": "function mergeOptions(target) {\n\n\tfunction mergeIntoTarget(name, value) {\n\t\tif ($.isPlainObject(value) && $.isPlainObject(target[name]) && !isForcedAtomicOption(name)) {\n\t\t\t// merge into a new object to avoid destruction\n\t\t\ttarget[name] = mergeOptions({}, target[name], value); // combine. `value` object takes precedence\n\t\t}\n\t\telse if (value !== undefined) { // only use values that are set and not undefined\n\t\t\ttarget[name] = value;\n\t\t}\n\t}\n\n\tfor (var i=1; i<arguments.length; i++) {\n\t\t$.each(arguments[i], mergeIntoTarget);\n\t}\n\n\treturn target;\n}", "title": "" }, { "docid": "230470edc989d54fe09c369fffe73c58", "score": "0.6869222", "text": "function mergeOptions(target) {\n\n\tfunction mergeIntoTarget(name, value) {\n\t\tif ($.isPlainObject(value) && $.isPlainObject(target[name]) && !isForcedAtomicOption(name)) {\n\t\t\t// merge into a new object to avoid destruction\n\t\t\ttarget[name] = mergeOptions({}, target[name], value); // combine. `value` object takes precedence\n\t\t}\n\t\telse if (value !== undefined) { // only use values that are set and not undefined\n\t\t\ttarget[name] = value;\n\t\t}\n\t}\n\n\tfor (var i=1; i<arguments.length; i++) {\n\t\t$.each(arguments[i], mergeIntoTarget);\n\t}\n\n\treturn target;\n}", "title": "" }, { "docid": "638d26ffd6c0875f4ffa6c0516d6ce1e", "score": "0.68142974", "text": "function mergeOptions(parent,child,vm){if(true){checkComponents(child);}if(typeof child==='function'){child=child.options;}normalizeProps(child,vm);normalizeInject(child,vm);normalizeDirectives(child);// Apply extends and mixins on the child options,\n// but only if it is a raw options object that isn't\n// the result of another mergeOptions call.\n// Only merged options has the _base property.\nif(!child._base){if(child.extends){parent=mergeOptions(parent,child.extends,vm);}if(child.mixins){for(var i=0,l=child.mixins.length;i<l;i++){parent=mergeOptions(parent,child.mixins[i],vm);}}}var options={};var key;for(key in parent){mergeField(key);}for(key in child){if(!hasOwn(parent,key)){mergeField(key);}}function mergeField(key){var strat=strats[key]||defaultStrat;options[key]=strat(parent[key],child[key],vm,key);}return options;}", "title": "" }, { "docid": "7c9710a7eb462d73eab9317ec2b20c19", "score": "0.68047196", "text": "function merge() {\n\tvar i,\n\t\targs = arguments,\n\t\tlen,\n\t\tret = {},\n\t\tdoCopy = function (copy, original) {\n\t\t\tvar value, key;\n\n\t\t\t// An object is replacing a primitive\n\t\t\tif (typeof copy !== 'object') {\n\t\t\t\tcopy = {};\n\t\t\t}\n\n\t\t\tfor (key in original) {\n\t\t\t\tif (original.hasOwnProperty(key)) {\n\t\t\t\t\tvalue = original[key];\n\n\t\t\t\t\t// Copy the contents of objects, but not arrays or DOM nodes\n\t\t\t\t\tif (value && typeof value === 'object' && Object.prototype.toString.call(value) !== '[object Array]' &&\n\t\t\t\t\t\t\tkey !== 'renderTo' && typeof value.nodeType !== 'number') {\n\t\t\t\t\t\tcopy[key] = doCopy(copy[key] || {}, value);\n\t\t\t\t\n\t\t\t\t\t// Primitives and arrays are copied over directly\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcopy[key] = original[key];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn copy;\n\t\t};\n\n\t// If first argument is true, copy into the existing object. Used in setOptions.\n\tif (args[0] === true) {\n\t\tret = args[1];\n\t\targs = Array.prototype.slice.call(args, 2);\n\t}\n\n\t// For each argument, extend the return\n\tlen = args.length;\n\tfor (i = 0; i < len; i++) {\n\t\tret = doCopy(ret, args[i]);\n\t}\n\n\treturn ret;\n}", "title": "" }, { "docid": "aba11436b16df0b4274a1d7b4539f2a0", "score": "0.6804594", "text": "function mergeOptions(dstOptions, srcOptions) {\n if (!dstOptions && !srcOptions) { \n return {};\n }\n\n if (!dstOptions) {\n return angular.copy(srcOptions);\n }\n\n if (!dstOptions) {\n return dstOptions;\n }\n\n return angular.extend({}, srcOptions, dstOptions);\n }", "title": "" }, { "docid": "8fc74ef0205fa8fb6b6ae046488e3ea5", "score": "0.679449", "text": "function _mergeOptions(opts)\n\t{\n\t\tif (EZ.isObject(opts))\n\t\t{\n\t\t\tif ('.defaults.groups'.ov(opts))\t\t\n\t\t\t{\n\t\t\t\tObject.keys(opts).forEach(function(key)\n\t\t\t\t{\n\t\t\t\t\tif (typeof(opts[key]) == 'function') return;\n\t\t\t\t\t\n\t\t\t\t\tvar value = getValue(key, opts[key]);\n\t\t\t\t\tif (value instanceof Object)\n\t\t\t\t\t\tvalue = value.cloneObject({objects:false, functions:false})\t\n\t\t\t\t\t\n\t\t\t\t\toptions[key] = value;\n\t\t\t\t});\n\t\t\t}\n\t\t\telse\t\t\t\t\t\t\t\t\t//11-11-2016 replaced by above (deep clone) \n\t\t\t{\n\t\t\t\tfor (var key in opts)\n\t\t\t\t{\n\t\t\t\t\tif (typeof(opts[key]) != 'function')\n\t\t\t\t\t\toptions[key] = getValue(key, opts[key]);\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "e613d38a7edfd43e8b0e77e2ed4ddb45", "score": "0.6789904", "text": "function merge() {\n\tvar i,\n\t\targs = arguments,\n\t\tlen,\n\t\tret = {},\n\t\tdoCopy = function (copy, original) {\n\t\t\tvar value, key;\n\n\t\t\t// An object is replacing a primitive\n\t\t\tif (typeof copy !== 'object') {\n\t\t\t\tcopy = {};\n\t\t\t}\n\n\t\t\tfor (key in original) {\n\t\t\t\tif (original.hasOwnProperty(key)) {\n\t\t\t\t\tvalue = original[key];\n\n\t\t\t\t\t// Copy the contents of objects, but not arrays or DOM nodes\n\t\t\t\t\tif (value && typeof value === 'object' && Object.prototype.toString.call(value) !== '[object Array]'\n\t\t\t\t\t\t\t&& key !== 'renderTo' && typeof value.nodeType !== 'number') {\n\t\t\t\t\t\tcopy[key] = doCopy(copy[key] || {}, value);\n\t\t\t\t\n\t\t\t\t\t// Primitives and arrays are copied over directly\n\t\t\t\t\t} else {\n\t\t\t\t\t\tcopy[key] = original[key];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t\treturn copy;\n\t\t};\n\n\t// If first argument is true, copy into the existing object. Used in setOptions.\n\tif (args[0] === true) {\n\t\tret = args[1];\n\t\targs = Array.prototype.slice.call(args, 2);\n\t}\n\n\t// For each argument, extend the return\n\tlen = args.length;\n\tfor (i = 0; i < len; i++) {\n\t\tret = doCopy(ret, args[i]);\n\t}\n\n\treturn ret;\n}", "title": "" }, { "docid": "05bf668711d18c4edf6ec2a7316ae1c6", "score": "0.6779908", "text": "function merge() {\n var i,\n args = arguments,\n len,\n ret = {};\n\n function doCopy(copy, original) {\n var value, key;\n\n // An object is replacing a primitive\n if (typeof copy !== 'object') {\n copy = {};\n }\n\n for (key in original) {\n if (original.hasOwnProperty(key)) {\n value = original[key];\n\n // Copy the contents of objects, but not arrays or DOM nodes\n if (value && key !== 'renderTo' && typeof value.nodeType !== 'number' &&\n typeof value === 'object' && Object.prototype.toString.call(value) !== '[object Array]') {\n copy[key] = doCopy(copy[key] || {}, value);\n }\n // Primitives and arrays are copied over directly\n else {\n copy[key] = original[key];\n }\n }\n }\n\n return copy;\n }\n\n // If first argument is true, copy into the existing object. Used in setOptions.\n if (args[0] === true) {\n ret = args[1];\n args = Array.prototype.slice.call(args, 2);\n }\n\n // For each argument, extend the return\n len = args.length;\n for (i = 0; i < len; i++) {\n ret = doCopy(ret, args[i]);\n }\n\n return ret;\n }", "title": "" }, { "docid": "6a4c4aa3456cf9418c9b207b2846d2f2", "score": "0.67141724", "text": "function mergeOptions(parent, child, vm) {\n // if (\"development\" !== 'production') {\n // checkComponents(child)\n // }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key = void 0;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn$1(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n}", "title": "" }, { "docid": "8b5d625fe4aa196e96cf7209b593a3f9", "score": "0.6657422", "text": "function mergeOptions(parent, child, vm) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n }", "title": "" }, { "docid": "8b5d625fe4aa196e96cf7209b593a3f9", "score": "0.6657422", "text": "function mergeOptions(parent, child, vm) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n }", "title": "" }, { "docid": "48c731b26a6a69a683b883860578f67e", "score": "0.66410035", "text": "function mergeOptions(parent, child, vm) {\n if (process.env.NODE_ENV !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n}", "title": "" }, { "docid": "48c731b26a6a69a683b883860578f67e", "score": "0.66410035", "text": "function mergeOptions(parent, child, vm) {\n if (process.env.NODE_ENV !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n}", "title": "" }, { "docid": "9b51cbe8b88ce4acc6c375d623e22071", "score": "0.662823", "text": "function mergeOptions(parent, child, vm) {\n if (\"development\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "7874f937ba29458ed2d0c0adc269ccab", "score": "0.6609852", "text": "function mergeOptions(parent, child, vm) {\n if ('production' !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child);\n normalizeInject(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n }", "title": "" }, { "docid": "e18f51f149be9cae404cb5a219632f6b", "score": "0.66089875", "text": "function common_mergeOptions( tgt, src )\n{\n // If the target evaluates to something that is false, then there\n // is likely nothing to merge. Return src.\n if (!tgt)\n return src;\n // If the source isn't a real value, then there is likely nothing\n // to merge. Return tgt.\n if (typeof src === 'undefined' || src === null)\n return tgt;\n\n for (var key in src)\n {\n if (src.hasOwnProperty( key ))\n {\n var srcCopy = src[ key ];\n\n // Prevent never-ending loop\n if (tgt === srcCopy)\n continue;\n\n // Check to see if the source is an object that evaluates to true\n // (ie, not null). Do not merge arrays!\n if (srcCopy && common_toType( srcCopy ) == 'object')\n {\n // Make sure the target is an object, or create a new one\n var tgtCopy = (tgt[ key ] && common_toType( tgt[ key ] ) == 'object') ? tgt[ key ] : {};\n\n tgt[ key ] = common_mergeOptions( tgtCopy, srcCopy );\n }\n else\n tgt[ key ] = srcCopy;\n }\n }\n\n return tgt;\n}", "title": "" }, { "docid": "8debb3ac9f3061699ca7ae0db3f940c7", "score": "0.65951794", "text": "function mergeOptions(optionObjs) {\n return mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "8debb3ac9f3061699ca7ae0db3f940c7", "score": "0.65951794", "text": "function mergeOptions(optionObjs) {\n return mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "6b17beb91ea1e293c3c8808eb1646789", "score": "0.659445", "text": "function mergeOptions(optionObjs) {\r\n return util_1.mergeProps(optionObjs, complexOptions);\r\n}", "title": "" }, { "docid": "1a5f94dc0a7479f09ba4e071ed3abbf7", "score": "0.6594311", "text": "function mergeOptions(parent, child, vm) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options;\n }", "title": "" }, { "docid": "dd8e0d61b9be34b81c15733bc8c84667", "score": "0.6590078", "text": "function mergeOptions() {\n for (var _len = arguments.length, opts = Array(_len), _key = 0; _key < _len; _key++) {\n opts[_key] = arguments[_key];\n }\n\n var headers = opts.reduce(function (merged, options) {\n if (!merged && !options.headers) {\n return null;\n }\n return assign(merged || {}, options.headers || {});\n }, null);\n return assign.apply(undefined, opts.concat([headers ? { headers: headers } : {}]));\n}", "title": "" }, { "docid": "4b3fe6538d5be8a53b009ec6f157b9f4", "score": "0.6583925", "text": "function mergeOptions(optionObjs) {\n return util_1.mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "4b3fe6538d5be8a53b009ec6f157b9f4", "score": "0.6583925", "text": "function mergeOptions(optionObjs) {\n return util_1.mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "2af43f12e2eb7ff97e6f0d8cd12997af", "score": "0.6582746", "text": "function mergeOptions(parent,child,vm){if(true){checkComponents(child);}if(typeof child==='function'){child=child.options;}normalizeProps(child);normalizeInject(child);normalizeDirectives(child);var extendsFrom=child.extends;if(extendsFrom){parent=mergeOptions(parent,extendsFrom,vm);}if(child.mixins){for(var i=0,l=child.mixins.length;i<l;i++){parent=mergeOptions(parent,child.mixins[i],vm);}}var options={};var key;for(key in parent){mergeField(key);}for(key in child){if(!hasOwn(parent,key)){mergeField(key);}}function mergeField(key){var strat=strats[key]||defaultStrat;options[key]=strat(parent[key],child[key],vm,key);}return options;}", "title": "" }, { "docid": "c432972cca20b5039181a4e0764c2ac6", "score": "0.65780026", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (Object({\"BROWSER\":true}).NODE_ENV !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "498859eeef3a2cebb1c2af27bf3e4b7a", "score": "0.6565368", "text": "function mergeOptions(options) {\n return Object.assign({\n width: 250,\n height: 80,\n color: '#ebebeb',\n alpha: 0.8,\n font: '10px Arial'\n }, options);\n }", "title": "" }, { "docid": "5a28b4248df7c6bac53752bce1a2ac2d", "score": "0.65646005", "text": "function mergeOptions(parent, child, vm) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child[\"extends\"]) {\n parent = mergeOptions(parent, child[\"extends\"], vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "e1ca1e8756d0574c7482d6e873960db9", "score": "0.65627205", "text": "function mergeOptions(mergeTarget, options, option) {\n var globalOptions = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};\n\n // Local helpers\n var isPresent = function isPresent(obj) {\n return obj !== null && obj !== undefined;\n };\n\n var isObject = function isObject(obj) {\n return obj !== null && _typeof_1(obj) === 'object';\n }; // https://stackoverflow.com/a/34491287/1223531\n\n\n var isEmpty = function isEmpty(obj) {\n for (var x in obj) {\n if (Object.prototype.hasOwnProperty.call(obj, x)) {\n return false;\n }\n }\n\n return true;\n }; // Guards\n\n\n if (!isObject(mergeTarget)) {\n throw new Error('Parameter mergeTarget must be an object');\n }\n\n if (!isObject(options)) {\n throw new Error('Parameter options must be an object');\n }\n\n if (!isPresent(option)) {\n throw new Error('Parameter option must have a value');\n }\n\n if (!isObject(globalOptions)) {\n throw new Error('Parameter globalOptions must be an object');\n } //\n // Actual merge routine, separated from main logic\n // Only a single level of options is merged. Deeper levels are ref'd. This may actually be an issue.\n //\n\n\n var doMerge = function doMerge(target, options, option) {\n if (!isObject(target[option])) {\n target[option] = {};\n }\n\n var src = options[option];\n var dst = target[option];\n\n for (var prop in src) {\n if (Object.prototype.hasOwnProperty.call(src, prop)) {\n dst[prop] = src[prop];\n }\n }\n }; // Local initialization\n\n\n var srcOption = options[option];\n var globalPassed = isObject(globalOptions) && !isEmpty(globalOptions);\n var globalOption = globalPassed ? globalOptions[option] : undefined;\n var globalEnabled = globalOption ? globalOption.enabled : undefined; /////////////////////////////////////////\n // Main routine\n /////////////////////////////////////////\n\n if (srcOption === undefined) {\n return; // Nothing to do\n }\n\n if (typeof srcOption === 'boolean') {\n if (!isObject(mergeTarget[option])) {\n mergeTarget[option] = {};\n }\n\n mergeTarget[option].enabled = srcOption;\n return;\n }\n\n if (srcOption === null && !isObject(mergeTarget[option])) {\n // If possible, explicit copy from globals\n if (isPresent(globalOption)) {\n mergeTarget[option] = Object.create(globalOption);\n } else {\n return; // Nothing to do\n }\n }\n\n if (!isObject(srcOption)) {\n return;\n } //\n // Ensure that 'enabled' is properly set. It is required internally\n // Note that the value from options will always overwrite the existing value\n //\n\n\n var enabled = true; // default value\n\n if (srcOption.enabled !== undefined) {\n enabled = srcOption.enabled;\n } else {\n // Take from globals, if present\n if (globalEnabled !== undefined) {\n enabled = globalOption.enabled;\n }\n }\n\n doMerge(mergeTarget, options, option);\n mergeTarget[option].enabled = enabled;\n }", "title": "" }, { "docid": "aa2d494d5d2ca0236b5d2b78ac61ddae", "score": "0.6561546", "text": "function mergeOptions(parent, child, vm) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "3e7777e99629c3de6ae58ff6b7aebf3c", "score": "0.65548724", "text": "function mergeOptions(parent, child, vm) {\n if (\"production\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "daa73fa6ea689031cfc75a2a2e3cc5cc", "score": "0.6553047", "text": "function mergeOptions(parent, child, vm) {\n if (\"development\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "daa73fa6ea689031cfc75a2a2e3cc5cc", "score": "0.6553047", "text": "function mergeOptions(parent, child, vm) {\n if (\"development\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "daa73fa6ea689031cfc75a2a2e3cc5cc", "score": "0.6553047", "text": "function mergeOptions(parent, child, vm) {\n if (\"development\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "daa73fa6ea689031cfc75a2a2e3cc5cc", "score": "0.6553047", "text": "function mergeOptions(parent, child, vm) {\n if (\"development\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "daa73fa6ea689031cfc75a2a2e3cc5cc", "score": "0.6553047", "text": "function mergeOptions(parent, child, vm) {\n if (\"development\" !== 'production') {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child); // Apply extends and mixins on the child options,\n // but only if it is a raw options object that isn't\n // the result of another mergeOptions call.\n // Only merged options has the _base property.\n\n if (!child._base) {\n if (child.extends) {\n parent = mergeOptions(parent, child.extends, vm);\n }\n\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n }\n\n var options = {};\n var key;\n\n for (key in parent) {\n mergeField(key);\n }\n\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n\n return options;\n}", "title": "" }, { "docid": "e9ee2e77d925abc56e139f39a64db406", "score": "0.6550394", "text": "function mergeOptions(optionObjs) {\r\n\treturn mergeProps(optionObjs, complexOptions);\r\n}", "title": "" }, { "docid": "490b0c86e2500eda9a00f6fc9ccdc388", "score": "0.65495044", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "490b0c86e2500eda9a00f6fc9ccdc388", "score": "0.65495044", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "490b0c86e2500eda9a00f6fc9ccdc388", "score": "0.65495044", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "490b0c86e2500eda9a00f6fc9ccdc388", "score": "0.65495044", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "490b0c86e2500eda9a00f6fc9ccdc388", "score": "0.65495044", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "490b0c86e2500eda9a00f6fc9ccdc388", "score": "0.65495044", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "dfdda32252a3e0989cbe2137606f96fd", "score": "0.65468746", "text": "function mergeOptions(parent, child, vm) {\n if (typeof child === \"function\") {\n child = child.options\n }\n\n normalizeProps(child)\n normalizeInject(child)\n normalizeDirectives(child)\n var extendsFrom = child.extends\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm)\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm)\n }\n }\n var options = {}\n var key\n for (key in parent) {\n mergeField(key)\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key)\n }\n }\n\n function mergeField(key) {\n var strat = strats[key] || defaultStrat\n options[key] = strat(parent[key], child[key], vm, key)\n }\n return options\n }", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "cfcfd4f19302c7777830b2b59080e1b8", "score": "0.6544672", "text": "function mergeOptions(optionObjs) {\n\treturn mergeProps(optionObjs, complexOptions);\n}", "title": "" }, { "docid": "586f1409ba0483d0fd66aa209d17c4be", "score": "0.6541892", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child);\n normalizeInject(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "7c5bfc290e0b2e98c7328ee23c8d128a", "score": "0.65388286", "text": "function mergeJsonOptions(a, b) {\n var _a, _b;\n let c = Object.assign(Object.assign({}, a), b);\n c.typeRegistry = [...((_a = a === null || a === void 0 ? void 0 : a.typeRegistry) !== null && _a !== void 0 ? _a : []), ...((_b = b === null || b === void 0 ? void 0 : b.typeRegistry) !== null && _b !== void 0 ? _b : [])];\n return c;\n}", "title": "" }, { "docid": "f6104e8821ba5e38c67b3f451b1a9e1c", "score": "0.653199", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child);\n normalizeInject(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "f6104e8821ba5e38c67b3f451b1a9e1c", "score": "0.653199", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child);\n normalizeInject(child);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" }, { "docid": "452ee1e976f2e262f9c193671c47770d", "score": "0.65305406", "text": "function mergeOptions (\n parent,\n child,\n vm\n) {\n if (true) {\n checkComponents(child);\n }\n\n if (typeof child === 'function') {\n child = child.options;\n }\n\n normalizeProps(child, vm);\n normalizeInject(child, vm);\n normalizeDirectives(child);\n var extendsFrom = child.extends;\n if (extendsFrom) {\n parent = mergeOptions(parent, extendsFrom, vm);\n }\n if (child.mixins) {\n for (var i = 0, l = child.mixins.length; i < l; i++) {\n parent = mergeOptions(parent, child.mixins[i], vm);\n }\n }\n var options = {};\n var key;\n for (key in parent) {\n mergeField(key);\n }\n for (key in child) {\n if (!hasOwn(parent, key)) {\n mergeField(key);\n }\n }\n function mergeField (key) {\n var strat = strats[key] || defaultStrat;\n options[key] = strat(parent[key], child[key], vm, key);\n }\n return options\n}", "title": "" } ]
b2cc1e4985f2968a5533ee822bf199f7
get wines by user ID
[ { "docid": "bec24cc3dbba8eeef253dbcd274f4c3f", "score": "0.7014791", "text": "async function getWinesByUserID(user_id) {\n try {\n const wines = await db.any(`select * from wines where user_id=$1`, [user_id]);\n console.log(wines)\n return wines;\n } catch (err) {\n console.log(err)\n return [];\n }\n}", "title": "" } ]
[ { "docid": "e86a82fbc6b901662af4fcbb8e426c49", "score": "0.6622037", "text": "async function favoriteWinesByUser(user_id) {\n try {\n const wines = await db.any(`SELECT wines.id, wines.wine_name, wines.wine_name, wines.wine_price, wines.wine_store, wines.wine_label, wines.comments, wines.wine_rating, favorite_wines.user_id \n FROM wines \n INNER JOIN favorite_wines\n ON wines.id = favorite_wines.wine_id\n where favorite_wines.user_id=$1;`, [user_id]);\n console.log(wines)\n return wines;\n } catch (err) {\n console.log(err)\n return [];\n }\n}", "title": "" }, { "docid": "607d9260bdb624d24f4f5944635dd6ee", "score": "0.61872077", "text": "async function searchWinesByUserId(user_id, searchText) {\n try {\n const MyWineSearch = await db.any(` select * from wines\n where (wine_name ILIKE '%$2#%' \n or wine_type ilike '%$2#%'\n or wine_store ilike '%$2#%'\n or comments ilike '%$2#%')\n and user_id=$1\n `, [user_id, searchText]);\n return MyWineSearch;\n } catch (err) {\n return [];\n }\n}", "title": "" }, { "docid": "5db9b9c97c7478dcae92447bef6f547c", "score": "0.60645366", "text": "async function getWinesByID(id) {\n try {\n const winesById = await db.any(`select * from wines where id=$1`, [id]);\n console.log(winesById)\n return winesById;\n } catch (err) {\n console.log(err)\n return [];\n }\n}", "title": "" }, { "docid": "664e3e696c8f1a83040ea789ea5e002e", "score": "0.5908487", "text": "function getTrainingsByUser(_id) {\n var deferred = Q.defer();\n var userObj_id = new ObjectId(_id);\n logger.debug(\"Will query trainings for userID: %s\", userObj_id);\n db.trainings.find({ userID: userObj_id }).toArray(function(err, trainings) {\n if (err) { deferred.reject(err);\n logger.error(\"Error in query for trainings: \" + err);\n }\n if (trainings) {\n deferred.resolve(trainings);\n \n } else {\n // user not found\n logger.debug(\"Training DB query returned nothing: %s \", trainings);\n trainings = {};\n deferred.resolve(trainings);\n }\n });\n\n return deferred.promise;\n}", "title": "" }, { "docid": "e852a508d8dd34c25a7fa9ee37ccbdc4", "score": "0.5746474", "text": "function getWines(event){\n if(document.getElementById(\"menu_wine\").getAttribute(\"data-status\") === \"active\" && event !== \"filter\"){\n return;\n }\n\n document.getElementById(\"menu_beer\").setAttribute(\"data-status\", \"inactive\");\n document.getElementById(\"menu_wine\").setAttribute(\"data-status\", \"active\");\n document.getElementById(\"menu_drinks\").setAttribute(\"data-status\", \"inactive\");\n\n var str = \"item.itemKind.includes('v') \"; // TODO: sökning efter faktiskt namn.\n var items = fetchFromDb(str);\n clearItems();\n printAllDrinks(items);\n update_view_dictionary();\n\n}", "title": "" }, { "docid": "c45d68d17459d342514d673fc5d79a12", "score": "0.5679772", "text": "function getUser(id){\n for (i in users){\n if (i.userId === id){\n return i\n }\n }\n return null\n}", "title": "" }, { "docid": "4cea870e53ad4cd02bc21940807be438", "score": "0.56139225", "text": "getMeters(user_id) {\n this.medidoresUser = [], [];\n for (let index = 0; index < this.medidores.length; index++) {\n const element = this.medidores[index];\n if (element.user && element.user._id === user_id) {\n this.medidoresUser.push(element);\n }\n }\n }", "title": "" }, { "docid": "e4e6febd4450e1de444b25da519ac18e", "score": "0.55933964", "text": "static getUserWinnings(user, callback) {\n MongoClient.connect(url,{\n poolSize: 100\n }, function (err, db) {\n if (err === null) {\n let collection = db.collection('winners');\n collection.findOne({\"winners\": {$exists: true}}, function (err, result) {\n if(result.winners == null) {\n console.log(\"Incorrect Mongo format: winners\");\n return;\n }\n let winners = result.winners;\n for (let i = 0; i < winners.length; i++) {\n if (winners[i].user == user) {\n console.log(\"winner found\",winners[i]);\n callback(winners[i].winnings);\n }\n }\n callback(0);\n });\n }\n MongoApi.closeConnection(db);\n });\n }", "title": "" }, { "docid": "0ccc59a6e235a9b8356375e9107acb18", "score": "0.5581783", "text": "async function getChillers({ userId }) {\n try {\n // Check if the user exists\n const existedUser = await users.findOne({\n cognito_id: userId,\n });\n if (!existedUser) {\n throw 'User does not exist';\n }\n\n // Find all the chillers that are matchable with the user\n // - Chiller's id should not be the same as the user's id\n // - Chiller's id should not already existed in the user's likes/dislikes arrays\n // - Chiller's gender must match user's gender preference\n // - One of chiller's game must match user's game list item\n const response = await users\n .find({\n $and: [\n { cognito_id: { $ne: existedUser.cognito_id } },\n { cognito_id: { $nin: existedUser.likes } },\n { cognito_id: { $nin: existedUser.dislikes } },\n { gender: existedUser.gender_pref },\n { games: { $elemMatch: { $in: existedUser.games } } },\n ],\n })\n .toArray();\n\n return response;\n } catch (error) {\n throw error;\n }\n }", "title": "" }, { "docid": "4e5fadd4811aed57e64eb5457efdae52", "score": "0.55800784", "text": "function queryByUserID(ws_client, options, cb) {\n\t\tmarbles_lib.queryByUserID(options, function (err, resp) {\n\t\t\tif (err != null) {\n\t\t\t\tconsole.log('');\n\t\t\t\tlogger.debug('[checking] could not query by user id:', err);\n\t\t\t\tvar obj = {\n\t\t\t\t\tmsg: 'error',\n\t\t\t\t\te: err,\n\t\t\t\t};\n\t\t\t\tif (ws_client) ws_client.send(JSON.stringify(obj)); \t\t\t\t\t\t\t\t//send to a client\n\t\t\t\telse wss.broadcast(obj);\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//send to all clients\n\t\t\t\tif (cb) cb();\n\t\t\t}\n\t\t\telse {\n\t\t\t\tvar billsList = resp.parsed;\n\t\t\t\tif (billsList) {\n\t\t\t\t\tlogger.debug('[checking] number of bills:', billsList.length);\n\t\t\t\t}\n\n\t\t\t\tvar knownAsString = JSON.stringify(known_everything);\t\t\t//stringify for easy comparison (order should stay the same)\n\t\t\t\tvar latestListAsString = JSON.stringify(billsList);\n\n\t\t\t\tif (knownAsString === latestListAsString) {\n\t\t\t\t\tlogger.debug('[checking] same bills list as last time');\n\t\t\t\t\tif (ws_client !== null) {\t\t\t\t\t\t\t\t\t//if this is answering a clients req, send to 1 client\n\t\t\t\t\t\tlogger.debug('[checking] sending to 1 client');\n\t\t\t\t\t\tws_client.send(JSON.stringify({ msg: 'everything', e: err, everything: latestListAsString }));\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\telse {\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t//detected new things, send it out\n\t\t\t\t\tlogger.debug('[checking] there are new things, sending to all clients');\n\t\t\t\t\tknown_everything = latestListAsString;\n\t\t\t\t\twss.broadcast({ msg: 'everything', e: err, everything: latestListAsString });\t//sent to all clients\n\t\t\t\t}\n\t\t\t\tif (cb) cb();\n\t\t\t}\n\t\t});\n\t}", "title": "" }, { "docid": "5419d2f3ae9edbb7ecaa314625c9e328", "score": "0.5509538", "text": "getUser(id) {\n return this.users.filter(user => user.id === id)[0]; //VOY A TENER EL PRIMER ELEMENTO DE LA LISTA ES DECIR SOLO UN USUARIO / AL COLOCARLE QUIERO EL PRIMER ELEMENTO SOLO ME DARA EL OBJETO YA NO COMO LISTA DE OBJETO SINO SOLO EL OBJETO\n }", "title": "" }, { "docid": "a99f02f252a1920cfc59049a44fa2f7e", "score": "0.5494953", "text": "getDataFromID(id) {\n return this.users.find((user) => id === user.id);\n }", "title": "" }, { "docid": "ec81707e295016a30ce0b226d9f8070d", "score": "0.5484553", "text": "function getUserObjectByIDObject(user){\r\n\tfor(var i =0; i<users.length; i++){\r\n\t\tif(users[i].id == user.id){\r\n\t\t\treturn users[i];\r\n\t\t}\r\n\t}\r\n}", "title": "" }, { "docid": "f74a4f0c93779e23d88b6b4f4a898031", "score": "0.54349667", "text": "function getWins(userId) {\n $.get(\"./getPlayerWinCount?id=\" + userId, function (result) {\n // create the output\n let text = \"<p>You have won \" + result.game_count + \" game(s).</p>\";\n\n // append the output to main content\n $(\"#mainContent\").append(text);\n });\n}", "title": "" }, { "docid": "4c1c682d9937a0855941d353b043d834", "score": "0.5434399", "text": "static getAll(userId) {\n const query = 'SELECT user_level FROM Members WHERE id = $1';\n return db.one(query, userId).then(() => {\n const query = 'SELECT * FROM MEMBERS WHERE id != $1';\n return db.any(query, userId);\n });\n }", "title": "" }, { "docid": "aae5b4c0e3956556a806852e77317b77", "score": "0.54239416", "text": "function getAllUserRents(userId){\n return queryDB(`SELECT * FROM rent WHERE user_id = ?;`, userId)\n .then((results) => {\n return results;\n });\n}", "title": "" }, { "docid": "824cdeca8aaa1299be6578a82b5e6918", "score": "0.5416667", "text": "getBoardsByUser(userID = 1) {\n const query = boardRef.orderByChild('owner').equalTo(userId)\n return query.once('value')\n }", "title": "" }, { "docid": "326fa05f2cd9b4076db966026a9bf359", "score": "0.53950554", "text": "function checkUserWalls(user_id, callback) {\n var User = require('../models/user');\n User.findOne({ _id: user_id }, { subjects: 1, degree: 1, college: 1 },\n function (err, result) {\n if (err)\n throw err;\n var subjects = [];\n var colleges = [];\n var degrees = [];\n\n for (var i in result.subjects) {\n subjects.push(result.subjects[i].subject_id);\n }\n for (var i in result.college) {\n colleges.push(result.college[i].college_id);\n }\n for (var i in result.degree) {\n degrees.push(result.degree[i].degree_id);\n }\n callback({ subjects: subjects, colleges: colleges, degrees: degrees });\n });\n}", "title": "" }, { "docid": "a6fea77b5c5c5e4b70e7766381ec3fb2", "score": "0.53706867", "text": "function getWinners(data,callback) {\n\n return callback(data).map(e=>getWinner(e));\n\n}", "title": "" }, { "docid": "942cc4ffcb4f0a21935bc4e6f0055529", "score": "0.53420746", "text": "function getOtherUsers (users, id) {\n return users.filterNot(userData => userData.get('id') === id);\n}", "title": "" }, { "docid": "ba8920736b76faa23e057fff71789f53", "score": "0.53394276", "text": "async function deleteFavWine(wine_id, user_id) {\n const delFavWine = await db.one(`DELETE from favorite_wines WHERE wine_id=$1 and user_id=$2;`, [wine_id, user_id])\n if (delFavWine.rowCount === 1) {\n return id;\n } else {\n return null;\n \n }}", "title": "" }, { "docid": "7d1bd0edab4284579fae71d3091b5bfa", "score": "0.5337689", "text": "function search(data) { \r\n for (var i=0 ; i < users.length ; i++) {\r\n if (users[i]._id == data) { \r\n return users[i]; // 5 le return \r\n }\r\n }\r\n }", "title": "" }, { "docid": "a1572df0a5fa0615592e442479d9252f", "score": "0.5333406", "text": "function getUser(id){\n console.log(\"[inside getUser\", id);\n console.log(\"users array: \", users)\n return users.find((user) => user.id ===id);\n \n}", "title": "" }, { "docid": "06be821e2a7722134c8c8a798ad004d1", "score": "0.530915", "text": "getUser(id){\n return this.users.filter((user)=> user.id === id)[0]; /* FINDING AND RETURNING THE USER WITH SAME ID AND RETURNING IT WHICH WILL BE AT INDEX 0 */\n }", "title": "" }, { "docid": "854cbd6698b56b7fd1a1064e545486ef", "score": "0.5301966", "text": "function getUserMeetings(userID, userType, callback) {\n let query;\n if (userType === 'coach') {\n query = `\n SELECT name, time, duration, date, \"/app/imgs/coach_placeholder.png\" AS image_src\n FROM Meetings\n LEFT OUTER JOIN Profiles ON Profiles.user_id = Meetings.startup_id\n WHERE Meetings.coach_id = ? AND date = (SELECT MAX(date) FROM Meetings);`;\n } else {\n query = `\n SELECT name, time, duration, date, \"/app/imgs/coach_placeholder.png\" AS image_src\n FROM Meetings\n LEFT OUTER JOIN Profiles ON Profiles.user_id = Meetings.coach_id\n WHERE Meetings.startup_id = ? AND date = (SELECT MAX(date) FROM Meetings);`;\n }\n db.all(query, [userID], (err, result) => {\n if (err) return callback(err);\n return callback(err, result);\n });\n}", "title": "" }, { "docid": "3ca933b85b5391ce25c19b3e70207066", "score": "0.52976066", "text": "function getAll(id) {\n return db('people').where({'user_id': id});\n}", "title": "" }, { "docid": "a7b80652c23538d28b7bf635e28e4d66", "score": "0.52900225", "text": "static getBingo(user, callback) {\n MongoApi.getCalledNumbers(function (calledNums) {\n MongoApi.getUserTickets(user, function (tickets) {\n if (tickets != null && tickets) {\n let isItBingo = CalculateBingo.isItBingo(calledNums, tickets);\n callback(isItBingo);\n }\n });\n });\n }", "title": "" }, { "docid": "f0f2484b4e2b895f5ed9e47a6eb952c6", "score": "0.525471", "text": "function winesIndex(req, res) {\n Wine.find((err, wines) => {\n if(err) return res.status(500).json({ error: \"500: server error\" });\n res.json(wines);\n });\n}", "title": "" }, { "docid": "129772b696c19fc1e4878ec24de49937", "score": "0.5242657", "text": "function getObjectsOwnedByUser(req, res, next) {\n var userid = req.param(\"userid\");\n objectService.getObjectsOwnedByUser(userid, (error, response) => {\n if (response == null) {\n ResponseHandler(404, response, res);\n return;\n }\n ResponseHandler(error, response, res);\n });\n}", "title": "" }, { "docid": "67eaad530d052497ef2e85e81ff871f8", "score": "0.52419806", "text": "function findUser(userlist, id){\n for (var i in userlist){\n if (userlist[i].uid === id){\n return userlist[i]\n }\n }\n}", "title": "" }, { "docid": "5e7011bf8c372b958fe0c6d247fd267b", "score": "0.5238167", "text": "function getByOwner( userId, callback ) {\n\tParty.find({ owner: userId }, callback );\n}", "title": "" }, { "docid": "d9fc43b019e54e209701b524b695da21", "score": "0.5229988", "text": "function getShopUser(memberObj){\n return data.users.find(user => {\n return user.id === memberObj.user.id.toString();\n })\n}", "title": "" }, { "docid": "68157a4d2a9acbd1cce5f3de8979bd91", "score": "0.52269304", "text": "function getPersonElevator (user) {\n\t\tvar shaft = user.shaft;\n\t\tfor(var i = 0; i < elevators[shaft].users.length; i++) {\n\t\t\tif(user === elevators[shaft].users[i]) {\n\t\t\t\treturn elevators[i];\n\t\t\t}\n\t\t}\n\t\treturn false;\n\t}", "title": "" }, { "docid": "b7d63ff6496812de7d8f456ea4d14111", "score": "0.520773", "text": "function getMyPolls(polls, user) {\n var myPolls = polls.filter(function (el) {\n return el.owner === user;\n });\n console.log(myPolls);\n return myPolls;\n}", "title": "" }, { "docid": "908792398e3c1e40c435c67a939099e6", "score": "0.5196037", "text": "getUserData(id) {\n const { users } = this.props;\n let data = users.users;\n let result = data.filter(user => user.login.uuid === id);\n\n return result;\n }", "title": "" }, { "docid": "b1fa43b33032f6779002b1dc1e191689", "score": "0.518253", "text": "function getByIdWithUser(id) {\n\t\treturn TokenFactory.query('SELECT * FROM `token` t JOIN `user` u ON t.`userid` = u.`id` WHERE t.`id` = ' + parseInt(id, 10) + ';');\n\t}", "title": "" }, { "docid": "71ee728016739f04f791cc6e1beb5898", "score": "0.5179329", "text": "function urlsForUser(id) {\n let filteredObj = {};\n for (let k in urlDatabase) {\n if (urlDatabase[k].userID === id) {\n filteredObj[k] = urlDatabase[k];\n }\n }\n return filteredObj;\n}", "title": "" }, { "docid": "36c429fa24e99d84df549bb71d5b0f64", "score": "0.51625764", "text": "function urlsForUser(id) {\n for (let i in users) {\n if (users[i].id === id) {\n let usersUrls = urlDatabase[id];\n return usersUrls;\n }\n }\n}", "title": "" }, { "docid": "db5b1106324dce317d11789294de3718", "score": "0.51584405", "text": "function getTrucks(id){\n return db('trucks_table')\n .where('owner_id', id)\n \n}", "title": "" }, { "docid": "d7878c64c3a4c7bcfbb79b1472c34144", "score": "0.514185", "text": "async function getSightings(ctx){\n sightings = await db.selectSightings();\n ctx.body = sightings;\n}", "title": "" }, { "docid": "75fbc3192f416d5924e2bd1ecfc1e3c4", "score": "0.5136858", "text": "function index(req, res, next) {\n User.findById({_id: req.session.passport.user}, function(err, user) {\n var id = user.id;\n Wishlist.find({ creator: id}, function(err, wishlists) {\n res.json(wishlists);\n })\n })\n}", "title": "" }, { "docid": "d63bb6349baf9661d4b5e9c6fb8a1e58", "score": "0.5123203", "text": "function getUser(id) {\n // return the one user with that id\n const user = users.find(user => user.id === id);\n return user;\n}", "title": "" }, { "docid": "85f4de328cb1aefaf0b66f2594d3102e", "score": "0.5121117", "text": "function getNotificationsByUserId(req, res, next){\n var userid = req.params.userid;\n\n User\n .findOne({\n where:{'google.id':userid}\n })\n .then(function(member){\n console.log(userid);\n Notification\n .findAll({\n where: {memberId: member.id},\n order: ['createdAt']\n })\n .then(function(notifications){\n res.send({\n notifications: notifications\n });\n }, function(){\n next();\n });\n }, function(){\n next()\n });\n}", "title": "" }, { "docid": "0671fd0540505a93b90de50710e34190", "score": "0.5110922", "text": "function getBusinessNotes(user_id) {\n const query = {\n text:'SELECT body FROM admin_notes WHERE noteable_id IN (SELECT business_id FROM business_membership WHERE user_id = $1)',\n values: [user_id],\n };\n\n client.query(query, (err, res) => {\n if(err){\n throw err;\n }\n else{\n SetBusinessNotes(res);\n }\n client.end()\n })\n}", "title": "" }, { "docid": "19c8e2c8fa893d56287d885807e8c161", "score": "0.51075613", "text": "function findUser(start, end){\n\tdirectionsServiceForTime = new google.maps.DirectionsService();\n var requestForTime = {\n \torigin: start,\n \t\tdestination: user.start,\n \t\ttravelMode: google.maps.DirectionsTravelMode['BICYCLING']\n };\n directionsServiceForTime.route(requestForTime, function(response, status){\n \tif (status == google.maps.DirectionsStatus.OK){\n \t\tif(parseInt(response.routes[0].legs[0].duration.text) < 5){\n \t\t\tyourMatch = user;\n \t\t}\n \t}\n })\n}", "title": "" }, { "docid": "bc49a70204bdd680caccaf20530a2cd1", "score": "0.51015884", "text": "function getSubordinates(userId) {\r\n if (typeof users[userId] === 'undefined') \r\n return `The user with ID \"${userId}\" could not be found.`\r\n \r\n return users[userId].getSubordinateUsers()\r\n}", "title": "" }, { "docid": "a07625d293479724fe79bfb58359632f", "score": "0.50938153", "text": "function getOwnSites(userID) {\n commonService\n .getUserSites(userID)\n .then(function (response) {\n vm.sites = response.data;\n vm.selectedSite = vm.sites[0];\n });\n }", "title": "" }, { "docid": "08a73c15f311d82f9ba48f5644c31450", "score": "0.50847477", "text": "function getUserById(users, id, cb) {\n for(var i = 0; i < users.length; i++) {\n if(users[i].id === id) {\n return cb(users[i]);\n }\n }\n console.log(\"Not Found\");\n }", "title": "" }, { "docid": "eae62db7e792ace36b34ec29c415567c", "score": "0.5082568", "text": "function getThisWeeksEntries() {\n\tconst user = JSON.parse(localStorage.getItem('user'));\n\tconst userId = user._id;\n\tconst today = moment().startOf('day').toISOString();\n\tconst endDate = today;\n\tconst startDate = moment(today).startOf('week').toISOString();\n\n\t$.ajax({\n\t\turl: `/api/entries/week/${userId}/`,\n\t\ttype: 'GET',\n\t\tdata: {\n\t\t\tstartDate: startDate,\n\t\t\tendDate: endDate\n\t\t},\n\t\tcontentType: 'application/json',\n\t\tdataType: 'json',\n\t\tsuccess: displayTodayEntry,\n\t\terror: function(err) {\n\t\t\talert('Something went wrong');\n\t\t}\n\t});\n}", "title": "" }, { "docid": "7d5db32882e6b9889b634780f36e3f7a", "score": "0.5080942", "text": "function findByUser(id) {\n return db(\"property\").where(\"user_id\", \"=\", id);\n}", "title": "" }, { "docid": "b3c307d52cc797e7634672f73e0cda32", "score": "0.5077913", "text": "function getWinners() {\n $scope.winners = filterFilter($scope.participants, {winner: 1});\n }", "title": "" }, { "docid": "0863c9662fae944383d2c0c9842ff0e5", "score": "0.50693375", "text": "function findUserById(userId) {\n for (let i = 0; i < users.length; i++) {\n if (users[i].id === userId) {\n return users[i];\n }\n }\n }", "title": "" }, { "docid": "c16ead7c9c62ef3c14031817ac1d0baa", "score": "0.5068144", "text": "function getASingleUser(userID){\r\n var xhr = new XMLHttpRequest();\r\n xhr.open(\"GET\",\"api/users/\" + String(userID), true);\r\n xhr.onload = function() {\r\n if (xhr.readyState === 4 && xhr.status >= 200 && xhr.status < 300) {\r\n var objUser = JSON.parse(xhr.responseText);\r\n renderSingleUser(objUser)\r\n }\r\n else {\r\n alert(\"Error \" + xhr.status);\r\n }\r\n };\r\n xhr.send()\r\n}", "title": "" }, { "docid": "a258d183c8a25760dbfebbcb5cd77ab8", "score": "0.50668925", "text": "static getAllItems(user_id) {\n return db\n .manyOrNone(`\n SELECT * FROM outfits\n JOIN shopping_carts \n ON outfits.id = shopping_carts.shopping_cart_item\n WHERE shopping_carts.user_id = ${user_id};`)\n .then((items) => {\n return items.map((item) => {\n return new Outfit(item);\n });\n });\n }", "title": "" }, { "docid": "2e93a2b39f8da3487776473f261a2797", "score": "0.50588924", "text": "function $getUser(id_user) {\n return $(\"li.opt_user>span\").filter(function (index) {\n return id_user == parseIdUser($(this).text());\n }).eq(0);\n}", "title": "" }, { "docid": "1f563780862af6901419083b4ca7bcb3", "score": "0.50541455", "text": "async function wantByUserID(res, user_id) {\n let json = { success: false, error: null, data: null };\n try {\n const wantList = await query(\"SELECT * FROM mywishlist WHERE user_id = ?\", [\n user_id,\n ]);\n json = { ...json, success: true, data: wantList };\n } catch (err) {\n json.error = \"Something went wrong.\";\n } finally {\n return res.send(json);\n }\n}", "title": "" }, { "docid": "d2a6cd31ba2bf64551e8299ea77f1e03", "score": "0.504015", "text": "function ListUsers(ws) {\n var returnMessage = {}\n returnMessage[\"type\"] = \"user-list\";\n returnMessage[\"data\"] = [];\n \n switch (ws.gamemode) {\n case \"server\":\n wss.clients.forEach(function each(client) {\n var user = {}\n user[\"user-id\"] = client.userId;\n user[\"user-name\"] = client.userName;\n user[\"lobby-id\"] = client.lobbyId;\n user[\"gamemode\"] = client.gamemode;\n returnMessage.data.push(user);\n });\n break;\n case \"player\" || \"spectator\":\n if (ws.lobbyId === -1) {\n SendUserError(ws, \"list-users\", \"not in a lobby\")\n return;\n }\n for (var i=0; i<lobbies[lobbyId][\"users\"].length; i++) {\n var user = {}\n user[\"user-id\"] = lobbies[lobbyId][\"users\"][i].userId;\n user[\"user-name\"] = lobbies[lobbyId][\"users\"][i].userName;\n user[\"lobby-id\"] = lobbies[lobbyId][\"users\"][i].lobbyId;\n user[\"gamemode\"] = lobbies[lobbyId][\"users\"][i].gamemode;\n returnMessage.data.push(user);\n }\n break;\n }\n ws.send(JSON.stringify(returnMessage));\n}", "title": "" }, { "docid": "5ed16c1535831d9b77db5ec189822aa8", "score": "0.5037338", "text": "function findWebsitesByUser(userId) {\n var url = \"/api/user/\" +userId +\"/website\";\n\n return $http.get(url)\n //unwrap response\n .then(function (response) {\n // return as embedded response\n return response.data;\n });\n\n }", "title": "" }, { "docid": "f6241a48517cdb3b94a3d449a5f98853", "score": "0.5031834", "text": "function getBillsForUser(userEmail) {\n var queryURL = baseUrl + 'api/users/bills/';\n $.ajax({\n url: queryURL + userEmail,\n method: 'GET',\n }).then(function (response) {\n response.forEach(bill => {\n buildBillViewRow(bill, $('#current-bills'));\n });\n });\n }", "title": "" }, { "docid": "1441561606a0ad96fc3b3bedfddd7dbd", "score": "0.50233483", "text": "function getUserById(userid) {\n}", "title": "" }, { "docid": "f81c8f72dc28c0f165879e4baa085cd2", "score": "0.5013534", "text": "function findUser(name) {\n let userIndex;\n let userMovements;\n for (let i = 0; i < fakeData.length; i++) {\n if (name === fakeData[i].owner) {\n userIndex = i;\n userMovements = fakeData[i].movements;\n }\n }\n return [userIndex, userMovements];\n}", "title": "" }, { "docid": "6249abddb9d6d65ccaf3509f59109c6b", "score": "0.5008167", "text": "async function getWeatherFromWoeid() {\n const API_URL_WOEID = `${API_URL_LOC}${woeid}/`\n const fetchWeatherWoeid = await fetch(API_URL_WOEID)\n const weatherData = await fetchWeatherWoeid.json()\n setIsLoading(false)\n setIsNearestLoc(false)\n setWoeid(weatherData)\n }", "title": "" }, { "docid": "0f03e939868e05d9973d0877f45119fb", "score": "0.5002743", "text": "'board.getUserAllBoards' (userId){\n let allBoards = Boards.find().fetch()\n let userBoard = []\n allBoards.map((board) => {\n if(boardUtils.checkInBoardUser(userId)){\n userBoard.push(board)\n }\n })\n return allBoards\n }", "title": "" }, { "docid": "62e0e6cc44bfb6824e8016946b197fcd", "score": "0.50025976", "text": "function getuser(ID){\n makeRequest('./data/' + ID + '.json').then(callback.successfull, callback.error);\n \n}", "title": "" }, { "docid": "7bc019035b1bc782ce4886f35244125c", "score": "0.5002325", "text": "function generateWorkout(user) {\n const workouts = [{\n user: user._id,\n name: \"Morning\"\n }, {\n user: user._id,\n name: \"Afternoon\"\n }, {\n user: user._id,\n name: \"Evening\"\n }, {\n user: user._id,\n name: \"Best\"\n }];\n return workouts[0];\n}", "title": "" }, { "docid": "404b84a7e92c8f9400178ff440ec59bc", "score": "0.49944028", "text": "static getUser(id) {\n const users = [\n {\n _id: 1,\n name: 'Michel Weststrate',\n twitterHandle: 'mweststrate',\n },\n {\n _id: 2,\n name: 'Jeff Hansen',\n twitterHandle: 'jeffijoe',\n },\n ]\n return Promise.resolve(users.find((x) => x._id === id))\n }", "title": "" }, { "docid": "0715e4e13233140d2dc1a028ea7dec0b", "score": "0.49927822", "text": "function findAllRoomsIdsForUserIncludingMentions(userId, callback) {\n return Promise.all([\n unreadItemService.getRoomIdsMentioningUser(userId),\n roomMembershipService.findRoomIdsForUser(userId)\n ])\n .spread(function(mentions, memberships) {\n var hash = collections.hashArray(memberships);\n var nonMemberRooms = [];\n _.each(mentions, function(mentionTroupeId) {\n if (!hash[mentionTroupeId]) {\n hash[mentionTroupeId] = true;\n nonMemberRooms.push(mentionTroupeId);\n }\n });\n\n return [Object.keys(hash), nonMemberRooms];\n })\n .asCallback(callback);\n}", "title": "" }, { "docid": "3ab0361823b2e766d6d5f616205e6068", "score": "0.4992633", "text": "function getUserLeave(socketId) {\n return users.filter(user => user.socketId === socketId)\n}", "title": "" }, { "docid": "812581ce2f7cace4347c899bc4f57cc4", "score": "0.49926132", "text": "function findWebsitesByUser(userId) {\n\t\t\treturn $http.get(\"/api/user/\"+userId+\"/website\")\n .then(function (response) {\n return response.data;\n });\n\t\t}", "title": "" }, { "docid": "4bf94a0903447d276fa86d7cc1d67ba3", "score": "0.49906382", "text": "allGameIDsOfUser(userID) {\n let games = [];\n for (var [key, value] of this.games) {\n if (\n (value.player1 !== null && value.player1.user.id == userID) ||\n (value.player2 !== null && value.player2.user.id == userID)\n ) {\n games.push(value.gameID);\n }\n }\n return games;\n }", "title": "" }, { "docid": "50dd7f666de9bf53527ecee9c788c6bb", "score": "0.4989615", "text": "async function getUserById(id) {\n try {\n const {\n rows: [user],\n } = await client.query(\n `\n SELECT *\n FROM users\n WHERE id=$1;\n `,\n [id]\n );\n\n //get orders for user\n const orders = await getAllOrdersByUserId({ id });\n if (orders.length != 0) {\n user.orders = orders;\n }\n\n\n\n //get reviews for user\n const reviews = await getAllReviewsByUserId({ id });\n if (reviews.length != 0) {\n user.reviews = reviews;\n }\n\n return user;\n } catch (error) {\n throw error;\n }\n}", "title": "" }, { "docid": "dca0f01328caa8ae67a45900fe4bcc8c", "score": "0.49895057", "text": "static findAllBookingOfUser(userId) {\n return db.execute(`\n SELECT b.*\n FROM bookings b \n WHERE b.borrowerId = '${userId}' ORDER BY b.id DESC;\n `);\n }", "title": "" }, { "docid": "cbcf6b89fcf007e765257fffabb0b7b0", "score": "0.49870983", "text": "static borrowUserIdea(user, id, borrowedTo) {\n if (isNaN(id)) {\n // convert to number\n id = ideas[user].indexOf(id);\n } else {\n id -= 1;\n }\n let idea = ideas[user][id];\n // todo borrow mark\n return idea;\n }", "title": "" }, { "docid": "319bb2ca7b2321ff3f15e3eec5579d4f", "score": "0.49794012", "text": "function getItemByUserId(user_id) {\n return db(\"items\").where({ user_id });\n}", "title": "" }, { "docid": "169f1ad289a049c8ad11ff25e058dbb5", "score": "0.49634328", "text": "function getUsersInRoom(roomname) {\n var allusers = $.get(\"http://allthetime.io/rtos/rooms?roomName=\" + roomname, function(data) {\n data[\"userList\"].forEach(function(user) {\n connectToUser(user);\n })\n });\n }", "title": "" }, { "docid": "19c107b1d6a05f92c48af82f83d40daf", "score": "0.49598446", "text": "function chosenWine(wines) {\n\tif (wines.length == 0) return null;\n\tif (wines.length == 1) return wines[0].name;\n\treturn wines.sort((a, b) => a.price - b.price)[1].name;\n}", "title": "" }, { "docid": "7a18365e15f93eed6e141f76902355d7", "score": "0.49570113", "text": "function getUser(id) {\n return $http.get('http://jsonplaceholder.typicode.com/users?id=' + id)\n .then(getUsersSuccess)\n .catch(getUsersError);\n }", "title": "" }, { "docid": "e646ec6ea616da545bd87eebab5478e9", "score": "0.49567592", "text": "function getUsersInRoom(room){\n users.filter((user) => user.room === room);\n}", "title": "" }, { "docid": "e0f642d412cb06147132e15b4890fce3", "score": "0.49534985", "text": "getUsuario(id) {\n for (let usuario of this.lista) {\n if (usuario.id === id) {\n return usuario;\n }\n }\n }", "title": "" }, { "docid": "996031d3e859f78e5026ca5a9a9d5437", "score": "0.49516526", "text": "function getUserById(id) {\n return getUserByProperty('id', id);\n}", "title": "" }, { "docid": "e6dbfbe6a6cbe140a9be844c0ca8de8c", "score": "0.49515736", "text": "function findUserById(userId)\n{\n\tfor(var key in userList)\n\t{\n\t\tconsole.log(userId)\n\t\tif(userList[key].userId == userId)\n\t\t{\n\t\t\treturn userList[key];\n\t\t}\n\t}\n\n\treturn 0;\n}", "title": "" }, { "docid": "2df758e8b7d873731d06e28f5a737e84", "score": "0.49497667", "text": "getAllUserPoliticians(userId) {\n return fetch(`${remoteUrl}/users/${userId}?_embed=savedPoliticians`).then(r => r.json())\n }", "title": "" }, { "docid": "2c1bad6c639eb12f9d0fd7c91ce2f81a", "score": "0.49404687", "text": "function urlsForUser(id) {\n var filteredURLs = {};\n for (var key in urlDatabase) {\n if (urlDatabase[key].userID == id) {\n filteredURLs[key] = urlDatabase[key];\n }\n }\n return filteredURLs;\n}", "title": "" }, { "docid": "43621269f37707118dcf00b4c49b8d3c", "score": "0.49382398", "text": "async getHobbies(userId = \"\") {\n const res = this.request(`interests/${userId}`);\n return res;\n }", "title": "" }, { "docid": "34a525910ffe634a7645528b75287811", "score": "0.49319407", "text": "function getPostsByUser(id) {\n const sql = `SELECT * FROM user_post WHERE userID = '${id}';`;\n const list = [];\n return db.execute(sql).then(([resp]) => {\n resp.forEach((elem) => {\n list.push(getPost(elem.postID));\n });\n return list;\n });\n}", "title": "" }, { "docid": "ccbaafa18fe2efac338c574b79e89434", "score": "0.4929694", "text": "function Addonlineuser(userid, ws){\n\tvar currentws = new connectioninfo();\n\tcurrentws.uuid = userid;\n\tcurrentws.ws = ws;\n\tfor(var i = 0; i < ClientIDlist.length; i++){\n\t\tconsole.log(ClientIDlist[i].uuid);\n\t\tif(ClientIDlist[i].uuid === userid){\n\t\t\treturn\n\t\t}\n\t}\n\tClientIDlist.push(currentws);\n}", "title": "" }, { "docid": "11b4109517e774750dc8c65f0b3d990f", "score": "0.4927947", "text": "getWinner() {\n if (this.rounds.length == 4) {\n return this.rounds[3][0];\n }\n else {\n return this.rounds[4][0];\n }\n }", "title": "" }, { "docid": "428bee73da47b0d18ab831f74caf8774", "score": "0.49208108", "text": "function findVotantById(iden) {\n\tfor(var i = 0 ; i < votants.length ; i++) {\n\t\tif(votants[i].ID == iden) {\n\t\t\treturn votants[i];\n\t\t}\n\t}\n}", "title": "" }, { "docid": "29fecd612afee4bf00ee702a7f2afc63", "score": "0.4918164", "text": "function findUser(users, id){\n \n return users.find(function(user, i){ return (user.id === id);}); \n }", "title": "" }, { "docid": "29fecd612afee4bf00ee702a7f2afc63", "score": "0.4918164", "text": "function findUser(users, id){\n \n return users.find(function(user, i){ return (user.id === id);}); \n }", "title": "" }, { "docid": "9524e4afd1931e25006fb2ae50ed553e", "score": "0.49167654", "text": "getAlivePlayers(id) {\n return this.getRoom(id).players.filter((player) => player.alive === true);\n }", "title": "" }, { "docid": "4626b4f199ba3ca8322d39632ef52844", "score": "0.49113083", "text": "function getEventByGateId(id) {\n return events.find(item => item.record.gateId === id);\n}", "title": "" }, { "docid": "2a0567cb7d175354849359b391d4fdd0", "score": "0.49091056", "text": "function getLovedOneInfo(userid) {\n var promise = $http({\n method: 'GET',\n url: '/lovedones/' + userid,\n params: {\n userid: userid\n }\n }).then(function successfulCallback(response) {\n lovedones = response.data;\n }, function(error) {\n console.log(error);\n });\n return promise;\n }", "title": "" }, { "docid": "3231c36fbc0cd96ff5199b539924a850", "score": "0.49088714", "text": "static getByUserID(request, response) {\r\n\r\n console.log(request.params.client);\r\n\r\n itemsModel.getByUserID(request.params.client)\r\n .then( data => {\r\n if (data.length > 0) {\r\n response.json(data); \r\n } else {\r\n response.sendStatus(404);\r\n console.log('Items not found. Client: ', request.params.client);\r\n }\r\n })\r\n .catch(err => {\r\n response.sendStatus(500);\r\n console.log('Error getting items by client: ', request.params.client, err);\r\n });\r\n \r\n }", "title": "" }, { "docid": "9afd5a11151cda6b01f1f7cfe7f9e637", "score": "0.49087843", "text": "function urlsForUser(id) {\n let filteredUrls = {};\n for (let url in urlDatabase) {\n if (urlDatabase[url].userID === id) {\n filteredUrls[url] = urlDatabase[url]\n }\n }\n return filteredUrls;\n}", "title": "" }, { "docid": "0841acce6752d7d913703ad25f36e089", "score": "0.4908782", "text": "getSteamUser(id) {\r\n\t\treturn new Promise(res => {\r\n\t\t\tres(this.steam.friends.personaStates[id])\r\n\t\t})\r\n\t}", "title": "" }, { "docid": "e1eeb409e74ab58c33a2f183ed2bfe46", "score": "0.4905197", "text": "function retrieveMyDoWhops(uid, currentDoWhopID) {\n doWhopDescriptionRootRef.on(\n 'value',\n function(snapshot) {\n var doWhopDescriptions = snapshot.val();\n var userDowhopCardDiv = document.getElementById('user-dowhop-cards');\n var isCurrentDoWhop = false;\n userDowhopCardDiv.innerHTML = '';\n _.map(snapshot.val())\n .reverse()\n .forEach(function(doWhopDescription) {\n var doerDescriptionEmails = [];\n\n if (doWhopDescription.doerDescription) {\n doerDescriptionEmails = doWhopDescription.doerDescription.split(', ');\n }\n\n if (\n (doWhopDescription.creatorDescription && doWhopDescription.creatorDescription.toLowerCase()) ===\n person.email.toLowerCase() ||\n doerDescriptionEmails.some(function(doerDescriptionEmail) {\n return doerDescriptionEmail.toLowerCase() === person.email.toLowerCase();\n })\n ) {\n // Begin experiment for filtering selected vs current DoWhop:\n\n // console.log('is current dowhop?', doWhopDescription.doWhopDescriptionKey === currentDoWhopID);\n doWhopDescription.doWhopDescriptionKey === currentDoWhopID\n ? (isCurrentDoWhop = true)\n : (isCurrentDoWhop = false);\n\n makeDoWhopSelector(userDowhopCardDiv, doWhopDescription, isCurrentDoWhop);\n }\n });\n },\n function(errorObject) {\n console.log('retrieveMyDoWhops Data Read Failure: ' + errorObject.code);\n }\n );\n\n // TODO figure out if this code is still used\n // no longer pushing doer objects to app_users\n var rootRefDoer = database.ref('app_users/' + uid);\n rootRefDoer.child('doer').on('value', function(snapshot) {\n snapshot.forEach(function(snapshot) {\n var doWhopItem = snapshot.key;\n retrieveElement(snapshot.key);\n });\n });\n function retrieveElement(key) {\n var userDowhopCardDiv = document.getElementById('user-dowhop-cards');\n var doWhopDescriptionRef = database.ref('DoWhopDescriptions').child(key);\n doWhopDescriptionRef.once('value').then(function(doWhopDescription) {\n if (doWhopDescription) {\n makeDoWhopSelector(userDowhopCardDiv, doWhopDescription);\n }\n });\n }\n function addDoWhopImage(files_arr, node) {\n if (!file.type.match('image/.*')) {\n alert('You can only add images at the moment.');\n return;\n }\n return (file = files_arr[0]);\n }\n}", "title": "" }, { "docid": "fda59a1bba244e7a582e85b1ae4085a7", "score": "0.4903839", "text": "function getUsers(ids) {\n return rp.get(\"https://api.twitch.tv/helix/users\", {\n headers: {\n \"Client-ID\": config[\"twitch-client-id\"],\n \"Authorization\": \"Bearer \" + config[\"twitch-access-token\"],\n },\n qs: {\n \"id\": ids,\n\n },\n json: true,\n });\n}", "title": "" }, { "docid": "af18cb514412d4da25b9e60ae13b1382", "score": "0.49031708", "text": "function getUserById(id){\n return $http.get(url.user + id).then( handleSuccess, handleError);\n }", "title": "" }, { "docid": "3a56ebbcd537e45e5e9807e96fc75d80", "score": "0.49028623", "text": "function getId(handle, callback){\n var params = {\n screen_name: handle//idsArr[playerNumber]\n };\n \n twit.get('users/show', params, function(err, reply){\n if (err) {\n if (err.code == 34) {\n callback(\"error\");\n console.log(\"no users found with that handle\");\n } \n }\n else{\n callback(reply.id);\n }\n }); \n}", "title": "" } ]
49dd96064dbd3aa6b3a5f0b1758e6bbb
Deepcopies an array or object.
[ { "docid": "35b6dfd14cdc41354308b7fda0593237", "score": "0.69435656", "text": "function deepCopy(source)\n{\n var result, key, value;\n result = Array.isArray(source) ? [] : {};\n for (key in source)\n {\n value = source[key];\n result[key] = (typeof value === 'object') ? deepCopy(value) : value;\n }\n return result;\n}", "title": "" } ]
[ { "docid": "562795fa3d69558c475c28819fe1c17b", "score": "0.7522486", "text": "function deepCopy(a, b){\n for(var i = 0; i<a.length; i++){\n if(typeof a[i] == 'object' && Object.prototype.toString.call(a[i]) != '[object Array]'){\n b[i] = JSON.parse(JSON.stringify(a[i]))\n }else{\n b[i] = a[i]\n }\n }\n}", "title": "" }, { "docid": "d25c9bb1f8d4db9aa5603682dfe8835b", "score": "0.7009971", "text": "function cloneDeep(val){\n if (Array.isArray(val)){\n var arrCopy = val.slice();\n for (var i = 0; i < arrCopy.length; i++){\n if (typeof(arrCopy[i] === 'object')){\n arrCopy[i] = Object.assign({},arrCopy[i]);\n }\n }\n return arrCopy;\n }\n if (typeof(val) === 'object'){\n return Object.assign({},val);\n }\n return val;\n}", "title": "" }, { "docid": "df70d93bf20e8f92579abc60b92458c0", "score": "0.6990538", "text": "function makeDeepCopy() {\n 'use strict';\n\n var personObj, numbersArr, copiedObj, copiedArr;\n\n personObj = {\n firstName: 'Ivan',\n lastName: 'Ivanov',\n age: 21,\n occupation: 'student'\n };\n\n numbersArr = [3, 15, 6, 8, 11, 21];\n\n copiedObj = clone(personObj);\n copiedArr = clone(numbersArr);\n\n console.log('Original object -> firstName: ' + personObj.firstName + '; lastName: ' + personObj.lastName + '; age: ' + personObj.age + '; occupation: ' + personObj.occupation + '.');\n console.log('Copied object -> firstName: ' + copiedObj.firstName + '; lastName: ' + copiedObj.lastName + '; age: ' + copiedObj.age + '; occupation: ' + copiedObj.occupation + '.');\n console.log('');\n console.log('Original array: ' + numbersArr + '.');\n console.log('Copied array: ' + copiedArr.join(' ') + '.');\n}", "title": "" }, { "docid": "acd302d5ddca954d847dd90497799444", "score": "0.6942421", "text": "function deepCopy(o) {\r\n var copy = o,k;\r\n \r\n if (o && typeof o === 'object') {\r\n copy = Object.prototype.toString.call(o) === '[object Array]' ? [] : {};\r\n for (k in o) {\r\n copy[k] = deepCopy(o[k]);\r\n }\r\n }\r\n \r\n return copy;\r\n}", "title": "" }, { "docid": "36cc728518fcc890f935794de75cebd2", "score": "0.69259435", "text": "function deepCopy(o) {\n var copy = o,k;\n \n if (o && typeof o === 'object') {\n copy = Object.prototype.toString.call(o) === '[object Array]' ? [] : {};\n for (k in o) {\n copy[k] = deepCopy(o[k]);\n }\n }\n return copy;\n}", "title": "" }, { "docid": "e9d49e7c9201d9c963e039a00e61e889", "score": "0.6871843", "text": "function deepCopy(old){\r\n\tif (Array.isArray(old)){\r\n\t\tvar newthing = [];\r\n\t\tfor (var i = 0; i< old.length; i++){\r\n\t\t\tnewthing.push(jQuery.extend(true, {}, old[i]));\r\n\t\t\t}\r\n\t\t}\r\n\telse {\r\n\t\tvar newthing = jQuery.extend(true, {}, old);\r\n\t}\r\n\treturn newthing;\r\n}", "title": "" }, { "docid": "3241d17c7a9539b0777b69143612c456", "score": "0.6859572", "text": "function clone(a) {\n\t if (isArray$5(a)) {\n\t return map$2(a).call(a, function (value) {\n\t return clone(value);\n\t });\n\t } else if (_typeof_1(a) === \"object\" && a !== null) {\n\t return deepObjectAssignNonentry({}, a);\n\t } else {\n\t return a;\n\t }\n\t}", "title": "" }, { "docid": "09116c52cffb4094383ff62617c3f4b9", "score": "0.68429834", "text": "function clone(a) {\n if (_Array$isArray(a)) {\n return _mapInstanceProperty(a).call(a, function (value) {\n return clone(value);\n });\n } else if (_typeof$1(a) === \"object\" && a !== null) {\n return deepObjectAssignNonentry({}, a);\n } else {\n return a;\n }\n}", "title": "" }, { "docid": "96eb1dde309b9758677664f791912080", "score": "0.6825067", "text": "function deepCopy(o) {\n\treturn JSON.parse(JSON.stringify(o));\n}", "title": "" }, { "docid": "6321287c1b2920bbf0edab5969f2666b", "score": "0.6792307", "text": "function deepCopy(source) {\n var target = Array.isArray(source) ? [] : {}\n for (var key in source) {\n if (Object.prototype.hasOwnProperty.call(source, key)) {\n if (typeof (key) === 'object' && key !== null) {\n target[key] = deepCopy(key)\n } else {\n target[key] = source[key];\n }\n }\n }\n return target;\n}", "title": "" }, { "docid": "af1eacf82babc75d343f771865365ee0", "score": "0.6785484", "text": "function shallowCopy(a, b){\n for(var i = 0; i<a.length; i++){\n if(typeof a[i] == 'object' && Object.prototype.toString.call(a[i]) != '[object Array]'){\n b[i] = Object.assign({}, a[i])\n }else{\n b[i] = a[i]\n }\n }\n}", "title": "" }, { "docid": "acba53c78ccddd11bf8f76d655774a53", "score": "0.67509604", "text": "function deepCopy(value) {\r\n // Do nothing for primitive values.\r\n if (isPrimitive(value)) {\r\n return value;\r\n }\r\n // Deep copy an array.\r\n if (isArray(value)) {\r\n return deepArrayCopy(value);\r\n }\r\n // Deep copy an object.\r\n return deepObjectCopy(value);\r\n }", "title": "" }, { "docid": "b8bdfdfc561d138e7c08a48ba0861da2", "score": "0.6737011", "text": "function deepCopy(value) {\n // Do nothing for primitive values.\n if (isPrimitive(value)) {\n return value;\n }\n // Deep copy an array.\n if (isArray(value)) {\n return deepArrayCopy(value);\n }\n // Deep copy an object.\n return deepObjectCopy(value);\n }", "title": "" }, { "docid": "10a1295162db2ce0b95431ad69e57254", "score": "0.6724121", "text": "function shallowCopy(src,dst){if(isArray(src)){dst=dst||[];for(var i=0,ii=src.length;i<ii;i++){dst[i]=src[i];}}else if(isObject(src)){dst=dst||{};for(var key in src){if(!(key.charAt(0)==='$'&&key.charAt(1)==='$')){dst[key]=src[key];}}}return dst||src;}", "title": "" }, { "docid": "10a1295162db2ce0b95431ad69e57254", "score": "0.6724121", "text": "function shallowCopy(src,dst){if(isArray(src)){dst=dst||[];for(var i=0,ii=src.length;i<ii;i++){dst[i]=src[i];}}else if(isObject(src)){dst=dst||{};for(var key in src){if(!(key.charAt(0)==='$'&&key.charAt(1)==='$')){dst[key]=src[key];}}}return dst||src;}", "title": "" }, { "docid": "49236565115eed414edb2c781da6611e", "score": "0.6689356", "text": "function deepClone(source) {\n let dest;\n\n if (isBasicType(source)) {\n return source;\n }\n\n if (isDate(source)) {\n return new Date(source);\n }\n\n dest = isArray(source) ? [] : {};\n\n for (const key in source) {\n // Use getOwnPropertyDescriptor instead of source[key] to prevent from triggering setter/getter.\n const descriptor = Object.getOwnPropertyDescriptor(source, key);\n\n if (descriptor) {\n if (!isFunction(descriptor.value)) {\n dest[key] = deepClone(descriptor.value);\n } else {\n Object.defineProperty(dest, key, descriptor);\n }\n }\n }\n\n if (!isArray(source)) {\n const prototype = Reflect.getPrototypeOf(source);\n Reflect.setPrototypeOf(dest, prototype);\n }\n\n return dest;\n}", "title": "" }, { "docid": "327d31f2f465cf04b17f47f2b556d629", "score": "0.6649595", "text": "function deepCopy(obj) {\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker]) throw new Error('attempted deep copy of cyclic object');\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker) continue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete obj[marker];\n\t\treturn ret;\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++) ret.push(deepCopy(obj[key]));\n\n\t\tdelete obj[marker];\n\t\treturn ret;\n\t}\n\n\t/*\n * It must be a primitive type -- just return it.\n */\n\treturn obj;\n}", "title": "" }, { "docid": "34f8c30a7196795e9da3e6eb3ec5be72", "score": "0.6635002", "text": "function deepCopy(obj) {\n var ret, key;\n var marker = '__deepCopy';\n if (obj && obj[marker]) throw new Error('attempted deep copy of cyclic object');\n\n if (obj && obj.constructor == Object) {\n ret = {};\n obj[marker] = true;\n\n for (key in obj) {\n if (key == marker) continue;\n ret[key] = deepCopy(obj[key]);\n }\n\n delete obj[marker];\n return ret;\n }\n\n if (obj && obj.constructor == Array) {\n ret = [];\n obj[marker] = true;\n\n for (key = 0; key < obj.length; key++) ret.push(deepCopy(obj[key]));\n\n delete obj[marker];\n return ret;\n }\n /*\n * It must be a primitive type -- just return it.\n */\n\n\n return obj;\n}", "title": "" }, { "docid": "01766fddf46c007b232a3d33ced10dfd", "score": "0.6630756", "text": "function clone(a) {\n if (Array.isArray(a)) {\n return a.map((value) => clone(value));\n }\n else if (typeof a === \"object\" && a !== null) {\n return deepObjectAssignNonentry({}, a);\n }\n else {\n return a;\n }\n}", "title": "" }, { "docid": "01766fddf46c007b232a3d33ced10dfd", "score": "0.6630756", "text": "function clone(a) {\n if (Array.isArray(a)) {\n return a.map((value) => clone(value));\n }\n else if (typeof a === \"object\" && a !== null) {\n return deepObjectAssignNonentry({}, a);\n }\n else {\n return a;\n }\n}", "title": "" }, { "docid": "bb1068124ea00439d9b3ee78bcf99032", "score": "0.662815", "text": "function deepCopy(obj){var ret,key;var marker='__deepCopy';if(obj&&obj[marker])throw new Error('attempted deep copy of cyclic object');if(obj&&obj.constructor==Object){ret={};obj[marker]=true;for(key in obj){if(key==marker)continue;ret[key]=deepCopy(obj[key]);}delete obj[marker];return ret;}if(obj&&obj.constructor==Array){ret=[];obj[marker]=true;for(key=0;key<obj.length;key++){ret.push(deepCopy(obj[key]));}delete obj[marker];return ret;}/*\n\t * It must be a primitive type -- just return it.\n\t */return obj;}", "title": "" }, { "docid": "1143abf0ce1f66c115e348b566e04d8f", "score": "0.6610324", "text": "function deepCopy(obj)\n\t{\n\t\tvar ret, key;\n\t\tvar marker = '__deepCopy';\n\n\t\tif (obj && obj[marker])\n\t\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\t\tif (obj && obj.constructor == Object) {\n\t\t\tret = {};\n\t\t\tobj[marker] = true;\n\n\t\t\tfor (key in obj) {\n\t\t\t\tif (key == marker)\n\t\t\t\t\tcontinue;\n\n\t\t\t\tret[key] = deepCopy(obj[key]);\n\t\t\t}\n\n\t\t\tdelete (obj[marker]);\n\t\t\treturn (ret);\n\t\t}\n\n\t\tif (obj && obj.constructor == Array) {\n\t\t\tret = [];\n\t\t\tobj[marker] = true;\n\n\t\t\tfor (key = 0; key < obj.length; key++)\n\t\t\t\tret.push(deepCopy(obj[key]));\n\n\t\t\tdelete (obj[marker]);\n\t\t\treturn (ret);\n\t\t}\n\n\t\t/*\n\t\t * It must be a primitive type -- just return it.\n\t\t */\n\t\treturn (obj);\n\t}", "title": "" }, { "docid": "1143abf0ce1f66c115e348b566e04d8f", "score": "0.6610324", "text": "function deepCopy(obj)\n\t{\n\t\tvar ret, key;\n\t\tvar marker = '__deepCopy';\n\n\t\tif (obj && obj[marker])\n\t\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\t\tif (obj && obj.constructor == Object) {\n\t\t\tret = {};\n\t\t\tobj[marker] = true;\n\n\t\t\tfor (key in obj) {\n\t\t\t\tif (key == marker)\n\t\t\t\t\tcontinue;\n\n\t\t\t\tret[key] = deepCopy(obj[key]);\n\t\t\t}\n\n\t\t\tdelete (obj[marker]);\n\t\t\treturn (ret);\n\t\t}\n\n\t\tif (obj && obj.constructor == Array) {\n\t\t\tret = [];\n\t\t\tobj[marker] = true;\n\n\t\t\tfor (key = 0; key < obj.length; key++)\n\t\t\t\tret.push(deepCopy(obj[key]));\n\n\t\t\tdelete (obj[marker]);\n\t\t\treturn (ret);\n\t\t}\n\n\t\t/*\n\t\t * It must be a primitive type -- just return it.\n\t\t */\n\t\treturn (obj);\n\t}", "title": "" }, { "docid": "75a8fa1c39770d2bb4f551c67835abb7", "score": "0.65873885", "text": "function deepCopy(obj)\n\t{\n\t\tvar ret, key;\n\t\tvar marker = '__deepCopy';\n\t\n\t\tif (obj && obj[marker])\n\t\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\t\n\t\tif (obj && obj.constructor == Object) {\n\t\t\tret = {};\n\t\t\tobj[marker] = true;\n\t\n\t\t\tfor (key in obj) {\n\t\t\t\tif (key == marker)\n\t\t\t\t\tcontinue;\n\t\n\t\t\t\tret[key] = deepCopy(obj[key]);\n\t\t\t}\n\t\n\t\t\tdelete (obj[marker]);\n\t\t\treturn (ret);\n\t\t}\n\t\n\t\tif (obj && obj.constructor == Array) {\n\t\t\tret = [];\n\t\t\tobj[marker] = true;\n\t\n\t\t\tfor (key = 0; key < obj.length; key++)\n\t\t\t\tret.push(deepCopy(obj[key]));\n\t\n\t\t\tdelete (obj[marker]);\n\t\t\treturn (ret);\n\t\t}\n\t\n\t\t/*\n\t\t * It must be a primitive type -- just return it.\n\t\t */\n\t\treturn (obj);\n\t}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "d73feb6acfcac5d8b1107458592d3162", "score": "0.6579849", "text": "function deepCopy(obj)\n{\n\tvar ret, key;\n\tvar marker = '__deepCopy';\n\n\tif (obj && obj[marker])\n\t\tthrow (new Error('attempted deep copy of cyclic object'));\n\n\tif (obj && obj.constructor == Object) {\n\t\tret = {};\n\t\tobj[marker] = true;\n\n\t\tfor (key in obj) {\n\t\t\tif (key == marker)\n\t\t\t\tcontinue;\n\n\t\t\tret[key] = deepCopy(obj[key]);\n\t\t}\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\tif (obj && obj.constructor == Array) {\n\t\tret = [];\n\t\tobj[marker] = true;\n\n\t\tfor (key = 0; key < obj.length; key++)\n\t\t\tret.push(deepCopy(obj[key]));\n\n\t\tdelete (obj[marker]);\n\t\treturn (ret);\n\t}\n\n\t/*\n\t * It must be a primitive type -- just return it.\n\t */\n\treturn (obj);\n}", "title": "" }, { "docid": "f733a88f0938aa026f3e5bf9b95bc510", "score": "0.6545615", "text": "function clone (obj) {\n var copy = Array.isArray(obj) ? [] : {}\n for (var i in obj) {\n if (Array.isArray(obj[i])) {\n copy[i] = obj[i].slice(0)\n } else if (obj[i] instanceof Buffer) {\n copy[i] = obj[i].slice(0)\n } else if (typeof obj[i] !== 'function') {\n copy[i] = obj[i] instanceof Object ? clone(obj[i]) : obj[i]\n } else if (typeof obj[i] === 'function') {\n copy[i] = obj[i]\n }\n }\n return copy\n}", "title": "" }, { "docid": "9b53678b9a3e98f3796dd8123c30ada7", "score": "0.6544695", "text": "function copyObj(src) {\n\t\tlet target = Array.isArray(src) ? [] : {};\n\t\tfor (let prop in src)\n\t\t\ttarget[prop] = src[prop] && typeof src[prop] === 'object' ? copyObj(src[prop]) : src[prop];\n\t\treturn target;\n\t}", "title": "" }, { "docid": "e3542f6ceae8c01103cd67e307015051", "score": "0.654", "text": "function copy(o) {\n var output, v, key;\n output = Array.isArray(o) ? [] : {};\n for (key in o) {\n v = o[key];\n output[key] = (typeof v === \"object\") ? copy(v) : v;\n }\n return output;\n }", "title": "" }, { "docid": "cb1401a0857a74b0c5926c4fa8614592", "score": "0.653607", "text": "function deepClone(object) {\n // IMPLEMENT ME\n}", "title": "" }, { "docid": "fb9c68686fabe6cba366b21cf1b7b24e", "score": "0.6524714", "text": "function deepCopy(val){\n return JSON.parse(JSON.stringify(val))\n}", "title": "" }, { "docid": "638fdcb344e19461a3315345f5ebe3af", "score": "0.65097964", "text": "function deepClone(data)\n{\n return JSON.parse( JSON.stringify( data ) );\n}", "title": "" }, { "docid": "bab89879ec3033ca399b952f31eb00b1", "score": "0.648366", "text": "function deepCopy(){\n var animal = {a:10,b:20,c:30}\n var people = animal;\n console.log(\"people\",people);\n people.a = 100;\n\n console.log(\"people:\",people)\n console.log(\"animal:\",animal);\n console.log(\"----------\")\n\n var dog = JSON.parse(JSON.stringify(animal))\n dog.b = 200\n console.log(\"animal:\",animal);\n console.log(\"dog\",dog)\n}", "title": "" }, { "docid": "af054c079ffc71341ffecd2322ef4620", "score": "0.64609456", "text": "function clone(arr) {\n\t\tvar i, _i, temp;\n\t\tif( typeof arr !== 'object' ) {\n\t\t\treturn arr;\n\t\t}\n\t\telse {\n\t\t\tif (arr.concat) {\n\t\t\t\ttemp = [];\n\t\t\t\tfor (i = 0, _i = arr.length; i < _i; i++) {\n\t\t\t\t\ttemp[i] = arguments.callee(arr[i]);\n\t\t\t\t}\n\t\t\t}\n\t\t\telse {\n\t\t\t\ttemp = {};\n\t\t\t\tfor (i in arr) {\n\t\t\t\t\ttemp[i] = arguments.callee(arr[i]);\n\t\t\t\t}\n\t\t\t} \n\t\t\treturn temp;\n\t\t}\n\t}", "title": "" }, { "docid": "1324287cbebdf0293ddb2f88e0986631", "score": "0.6420575", "text": "function shallowCopy(val) {\n if (val instanceof Array) {\n return val.slice(0);\n }\n else if (val instanceof NonAV) {\n return val.copy();\n }\n else if (typeof (val) === \"object\") {\n var obj = {};\n for (var attr in val)\n obj[attr] = val[attr];\n return obj;\n }\n return val;\n}", "title": "" }, { "docid": "513bda8ddad32d9afde71eb938afdf5d", "score": "0.64165014", "text": "function clone(value) {\n\t switch (getType(value)) {\n\t case \"array\":\n\t return value.map(function (item) {\n\t return clone(item);\n\t });\n\t case \"object\":\n\t return map(value, function (v, k) {\n\t return clone(v);\n\t });\n\t default:\n\t return value;\n\t }\n\t }", "title": "" }, { "docid": "d01c1012172c85244066e3a6108cd83e", "score": "0.6414405", "text": "function deepCopy(input) {\n if (Array.isArray(input)) {\n return input.map(deepCopy);\n } else if (input instanceof Date) {\n return new Date(input.valueOf());\n } else if (_typeof(input) === 'object' && input) {\n // non-null object\n return mapHash(input, deepCopy);\n } else {\n // everything else (null, function, etc)\n return input;\n }\n}", "title": "" }, { "docid": "9317f3186b53f2030ce24f0941e1ca81", "score": "0.63899595", "text": "function copy(obj)\r\n\t{\r\n\t\tif (typeof obj !== 'object' || obj === null)\r\n\t\t\treturn obj;\r\n\t\tvar cpy = obj instanceof Array ? [] : {};\r\n\t\tfor (var key in obj)\r\n\t\t\tcpy[key] = copy(obj[key]);\r\n\t\treturn cpy;\r\n\t}", "title": "" }, { "docid": "d94caedea1695aad79fb0620ebaf6b53", "score": "0.6386581", "text": "function deepClone(obj) {\n\t\t\tswitch (typeof obj) {\n\t\t\t\tcase 'object':\n\t\t\t\t\treturn JSON.parse(JSON.stringify(obj)); //Faster than ES5 clone - http://jsperf.com/deep-cloning-of-objects/5\n\t\t\t\tcase 'undefined':\n\t\t\t\t\treturn null; //this is how JSON.stringify behaves for array items\n\t\t\t\tdefault:\n\t\t\t\t\treturn obj; //no need to clone primitives\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "52dab70a72bef60a316af178e11902f2", "score": "0.63811207", "text": "function copy(o) {\n var output, v, key;\n output = Array.isArray(o) ? [] : {};\n for (key in o) {\n v = o[key];\n output[key] = (typeof v === \"object\") ? copy(v) : v;\n }\n\n return output;\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "6e8d68859f74059ea1374e81f46dc2cd", "score": "0.63757247", "text": "function deepCopy(value) {\n return deepExtend(undefined, value);\n}", "title": "" }, { "docid": "4bee8d381ed0d0bb668277e794230030", "score": "0.637507", "text": "function deepObjCopy(obj) {\n return JSON.parse(JSON.stringify(obj));\n}", "title": "" }, { "docid": "0f883e68d2bf838091856c6a02201f21", "score": "0.6373744", "text": "function deepCopy(value) {\r\n return deepExtend(undefined, value);\r\n}", "title": "" }, { "docid": "8e5793f8fcce59098501a507d5eaab36", "score": "0.637323", "text": "function deepCopy(source, target) {\n // Implementing Tail Call Elimination\n function tce(source, target) {\n for (var prop in source) {\n if (source.hasOwnProperty(prop)) {\n if (!target.hasOwnProperty(prop)) {\n target[prop] = source[prop];\n } else if (_typeof(source[prop]) === \"object\") {\n tce(source[prop], target[prop]);\n }\n }\n }\n }\n\n return tce(source, target);\n}", "title": "" }, { "docid": "d2ace5a6d12b453e7703f8b9be2ee4bd", "score": "0.6369681", "text": "function deepCopy(input) {\n if (Array.isArray(input)) {\n return input.map(deepCopy);\n }\n else if (input instanceof Date) {\n return new Date(input.valueOf());\n }\n else if (typeof input === 'object' && input) { // non-null object\n return mapHash(input, deepCopy);\n }\n else { // everything else (null, function, etc)\n return input;\n }\n }", "title": "" }, { "docid": "d2ace5a6d12b453e7703f8b9be2ee4bd", "score": "0.6369681", "text": "function deepCopy(input) {\n if (Array.isArray(input)) {\n return input.map(deepCopy);\n }\n else if (input instanceof Date) {\n return new Date(input.valueOf());\n }\n else if (typeof input === 'object' && input) { // non-null object\n return mapHash(input, deepCopy);\n }\n else { // everything else (null, function, etc)\n return input;\n }\n }", "title": "" }, { "docid": "2931c7883a65a4bd8e2a8aba2d4e82c9", "score": "0.63640684", "text": "function clone(obj) {\n if (!isObject(obj)) return obj;\n return isArray(obj) ? obj.slice() : extend({}, obj);\n }", "title": "" }, { "docid": "0d793dae9edff681a67fbe5a2a5b5b7a", "score": "0.6344602", "text": "function copy(obj)\n\t{\n\t\tif (typeof obj !== 'object' || obj === null)\n\t\t\treturn obj;\n\t\tvar cpy = obj instanceof Array ? [] : {};\n\t\tfor (var key in obj)\n\t\t\tcpy[key] = copy(obj[key]);\n\t\treturn cpy;\n\t}", "title": "" }, { "docid": "0d793dae9edff681a67fbe5a2a5b5b7a", "score": "0.6344602", "text": "function copy(obj)\n\t{\n\t\tif (typeof obj !== 'object' || obj === null)\n\t\t\treturn obj;\n\t\tvar cpy = obj instanceof Array ? [] : {};\n\t\tfor (var key in obj)\n\t\t\tcpy[key] = copy(obj[key]);\n\t\treturn cpy;\n\t}", "title": "" }, { "docid": "0d793dae9edff681a67fbe5a2a5b5b7a", "score": "0.6344602", "text": "function copy(obj)\n\t{\n\t\tif (typeof obj !== 'object' || obj === null)\n\t\t\treturn obj;\n\t\tvar cpy = obj instanceof Array ? [] : {};\n\t\tfor (var key in obj)\n\t\t\tcpy[key] = copy(obj[key]);\n\t\treturn cpy;\n\t}", "title": "" }, { "docid": "229979b34c40bde6077a8bf926ad2d38", "score": "0.6339054", "text": "function copyFromData(src, dst) {\n for (var prop in src) {\n if (src[prop] !== undefined && src[prop] != null && ! isFunction(dst[prop]))\n if (dst[prop] instanceof Array) {\n var s = src[prop][0];\n if (s !== undefined && hasProperties(s) && ! (s instanceof Array)) {\n for (var n = 0 ; n < dst[prop].length ; n++)\n if (src[prop][n] !== undefined)\n copyFromData(src[prop][n], dst[prop][n]);\n }\n else\n cloneArray(src[prop], dst[prop]);\n }\n else if (! hasProperties(dst[prop]) || typeof dst[prop] === 'string')\n dst[prop] = src[prop];\n else\n copyFromData(src[prop], dst[prop]);\n }\n }", "title": "" }, { "docid": "3854977cfe3d59721b40583982b362c0", "score": "0.6331531", "text": "function clone(obj) {\n if (!isObject(obj)) return obj;\n return isArray(obj) ? obj.slice() : extend({}, obj);\n }", "title": "" }, { "docid": "a053b895fb01c4bddf22a57e4244698a", "score": "0.6328202", "text": "function deepClone(obj){\n return JSON.parse(JSON.stringify(obj));\n}", "title": "" }, { "docid": "52438683ca40e297cd4e0ebb876e14ac", "score": "0.63199204", "text": "function shallowCopy(src, dst) {\n\t if (isArray(src)) {\n\t dst = dst || [];\n\t\n\t for (var i = 0, ii = src.length; i < ii; i++) {\n\t dst[i] = src[i];\n\t }\n\t } else if (isObject(src)) {\n\t dst = dst || {};\n\t\n\t for (var key in src) {\n\t if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n\t dst[key] = src[key];\n\t }\n\t }\n\t }\n\t\n\t return dst || src;\n\t}", "title": "" }, { "docid": "52438683ca40e297cd4e0ebb876e14ac", "score": "0.63199204", "text": "function shallowCopy(src, dst) {\n\t if (isArray(src)) {\n\t dst = dst || [];\n\t\n\t for (var i = 0, ii = src.length; i < ii; i++) {\n\t dst[i] = src[i];\n\t }\n\t } else if (isObject(src)) {\n\t dst = dst || {};\n\t\n\t for (var key in src) {\n\t if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n\t dst[key] = src[key];\n\t }\n\t }\n\t }\n\t\n\t return dst || src;\n\t}", "title": "" }, { "docid": "52438683ca40e297cd4e0ebb876e14ac", "score": "0.63199204", "text": "function shallowCopy(src, dst) {\n\t if (isArray(src)) {\n\t dst = dst || [];\n\t\n\t for (var i = 0, ii = src.length; i < ii; i++) {\n\t dst[i] = src[i];\n\t }\n\t } else if (isObject(src)) {\n\t dst = dst || {};\n\t\n\t for (var key in src) {\n\t if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n\t dst[key] = src[key];\n\t }\n\t }\n\t }\n\t\n\t return dst || src;\n\t}", "title": "" }, { "docid": "ce8f9f9b0ca432c9de6deb6864c95880", "score": "0.6318299", "text": "function arrayCopy(arr) {\n return JSON.parse(JSON.stringify(arr));\n}", "title": "" }, { "docid": "60a7f29f5757870abe58020617e7d311", "score": "0.6312808", "text": "function cloneDeep(obj) { return JSON.parse(JSON.stringify(obj)) }", "title": "" }, { "docid": "27d374592d63754a331622ebad0ce19e", "score": "0.63068926", "text": "function deepCloneObj(aObj) {\n return JSON.parse(JSON.stringify(aObj))\n}", "title": "" }, { "docid": "841dc09bdedce6a2f20220c76a2abd37", "score": "0.6306737", "text": "function DeepCopyAnArray(sourceArray)\n{\n let returnArray = [];\n for (let i = 0; i < sourceArray.length; i++)\n {\n returnArray.push(JSON.parse(JSON.stringify(sourceArray[i])));\n }\n\n return returnArray;\n}", "title": "" }, { "docid": "f4e1b3fa3945e1461e133e60462bdf06", "score": "0.62866294", "text": "function deepObjectAssign() {\n\t var merged = deepObjectAssignNonentry.apply(void 0, arguments);\n\t stripDelete(merged);\n\t return merged;\n\t}", "title": "" }, { "docid": "5a23a3a6fea7c438382aa597f418962c", "score": "0.6281834", "text": "function clone(src, deepMode) {\n\n var _new;\n var cur;\n if(_A(src)) {\n\n // copy array\n _new = new Array();\n\n for(var iVal = 0; iVal < src.length; iVal++) {\n\n cur = src[iVal];\n\n // deepMode\n if(deepMode && _o(cur)) {\n _new[iVal] = clone(cur, deepMode);\n }\n else {\n _new[iVal] = cur;\n }\n }\n }\n else if(_o(src)) {\n\n // copy object\n _new = new Object();\n\n var key;\n\n for(key in src) {\n\n cur = src[key];\n\n if(deepMode && _o(cur)) {\n _new[key] = clone(cur, deepMode);\n }\n else {\n _new[key] = cur;\n }\n }\n }\n else {\n _new = src;\n }\n\n return _new;\n }", "title": "" }, { "docid": "e239bf600c21b68703ed0bb1ec244498", "score": "0.62706715", "text": "function deepCopy(v) {\n return JSON.parse(JSON.stringify(v));\n }", "title": "" }, { "docid": "9c1dd5f745542278ed8c3e72025a8ea3", "score": "0.6262402", "text": "function deepObjectAssign() {\n var merged = deepObjectAssignNonentry.apply(void 0, arguments);\n stripDelete(merged);\n return merged;\n}", "title": "" }, { "docid": "3e1436ab94d609898158bb3c5c37ed45", "score": "0.62522256", "text": "function shallowCopy(src, dst) {\n if (isArray(src)) {\n dst = dst || [];\n\n for (var i = 0, ii = src.length; i < ii; i++) {\n dst[i] = src[i];\n }\n } else if (isObject(src)) {\n dst = dst || {};\n\n for (var key in src) {\n if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n dst[key] = src[key];\n }\n }\n }\n\n return dst || src;\n }", "title": "" }, { "docid": "3e1436ab94d609898158bb3c5c37ed45", "score": "0.62522256", "text": "function shallowCopy(src, dst) {\n if (isArray(src)) {\n dst = dst || [];\n\n for (var i = 0, ii = src.length; i < ii; i++) {\n dst[i] = src[i];\n }\n } else if (isObject(src)) {\n dst = dst || {};\n\n for (var key in src) {\n if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n dst[key] = src[key];\n }\n }\n }\n\n return dst || src;\n }", "title": "" }, { "docid": "3e1436ab94d609898158bb3c5c37ed45", "score": "0.62522256", "text": "function shallowCopy(src, dst) {\n if (isArray(src)) {\n dst = dst || [];\n\n for (var i = 0, ii = src.length; i < ii; i++) {\n dst[i] = src[i];\n }\n } else if (isObject(src)) {\n dst = dst || {};\n\n for (var key in src) {\n if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n dst[key] = src[key];\n }\n }\n }\n\n return dst || src;\n }", "title": "" }, { "docid": "3e1436ab94d609898158bb3c5c37ed45", "score": "0.62522256", "text": "function shallowCopy(src, dst) {\n if (isArray(src)) {\n dst = dst || [];\n\n for (var i = 0, ii = src.length; i < ii; i++) {\n dst[i] = src[i];\n }\n } else if (isObject(src)) {\n dst = dst || {};\n\n for (var key in src) {\n if (!(key.charAt(0) === '$' && key.charAt(1) === '$')) {\n dst[key] = src[key];\n }\n }\n }\n\n return dst || src;\n }", "title": "" }, { "docid": "23c9595edf64db31574276e1831a96c4", "score": "0.6251029", "text": "function deepObjectAssignNonentry() {\n\t for (var _len2 = arguments.length, values = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n\t values[_key2] = arguments[_key2];\n\t }\n\n\t if (values.length < 2) {\n\t return values[0];\n\t } else if (values.length > 2) {\n\t var _context2;\n\n\t return deepObjectAssignNonentry.apply(void 0, concat$2(_context2 = [deepObjectAssign(values[0], values[1])]).call(_context2, toConsumableArray(slice$3(values).call(values, 2))));\n\t }\n\n\t var a = values[0];\n\t var b = values[1];\n\n\t var _iterator = _createForOfIteratorHelper(ownKeys$3(b)),\n\t _step;\n\n\t try {\n\t for (_iterator.s(); !(_step = _iterator.n()).done;) {\n\t var prop = _step.value;\n\t if (!Object.prototype.propertyIsEnumerable.call(b, prop)) ;else if (b[prop] === DELETE) {\n\t delete a[prop];\n\t } else if (a[prop] !== null && b[prop] !== null && _typeof_1(a[prop]) === \"object\" && _typeof_1(b[prop]) === \"object\" && !isArray$5(a[prop]) && !isArray$5(b[prop])) {\n\t a[prop] = deepObjectAssignNonentry(a[prop], b[prop]);\n\t } else {\n\t a[prop] = clone(b[prop]);\n\t }\n\t }\n\t } catch (err) {\n\t _iterator.e(err);\n\t } finally {\n\t _iterator.f();\n\t }\n\n\t return a;\n\t}", "title": "" }, { "docid": "28494e4d12ae4ce5a651da0e444ffe0b", "score": "0.62411016", "text": "function copy(obj)\n\t{\n\t\tif (typeof obj !== 'object' || obj === null)\n\t\t\treturn obj;\n\t\tvar cpy = Array.isArray(obj) ? [] : {};\n\t\tfor (var key in obj)\n\t\t\tcpy[key] = copy(obj[key]);\n\t\treturn cpy;\n\t}", "title": "" } ]
3d765eeaae103674f553c79878d093d9
Transform mouse x,y cords to something useable by the canvas.
[ { "docid": "7e7305390c06926be96eae1d28aa016f", "score": "0.0", "text": "getMouseVec2(e) {\n return { x: e.pageX - this.offsetX, y: e.pageY - this.offsetY };\n }", "title": "" } ]
[ { "docid": "598750e83eaa5642946b91f33ed9823f", "score": "0.71753895", "text": "function update_mouse(event){\n\trect = canvas.getBoundingClientRect();\n\n mouse_x = (1*event.x-rect.left)/(rect.width); \n\tmouse_y = (1*event.y-rect.top)/(rect.height);\n \n}", "title": "" }, { "docid": "38575ade2bbba9f1af99f397505c6b5b", "score": "0.71567273", "text": "function updateMouseCoords(event) {\n const canvasPosition = renderer.domElement.getBoundingClientRect();\n mouse.x = ((event.clientX - canvasPosition.left)/getCanvasWidth()) * 2 - 1;\n mouse.y = -((event.clientY - canvasPosition.top)/getCanvasHeight()) * 2 + 1;\n}", "title": "" }, { "docid": "01a4e120a2e13d161fb7230f84a8a55b", "score": "0.7053197", "text": "function setMouse(e) {\n //sets the x-axis coordinates and then subtracts the x-axis of the canvas\n mouseX = e.clientX - canvasPos.x;\n //sets the y-axis coordinates and then subtracts the y-axis of the canvas\n mouseY = e.clientY - canvasPos.y;\n //console.log(\"x: \" + mouseX + \" y: \" + mouseY);\n}", "title": "" }, { "docid": "32094be6cd08675c690a43719f3e7bd7", "score": "0.70432186", "text": "function updateMouseXY(e) {\n mouseX = e.x;\n mouseY = e.y;\n}", "title": "" }, { "docid": "8d92de745d45f3adb8e676cb5afb7f4c", "score": "0.70388305", "text": "function MouseMove (event){\r\n var rect = canvas.getBoundingClientRect();\r\n input.mouse.x = event.clientX - rect.left;\r\n input.mouse.y = event.clientY - rect.top;\r\n}", "title": "" }, { "docid": "f2935df33d570e1139d01c1462f31c07", "score": "0.7022916", "text": "function transformMouseCoords(e)\r\n {\r\n\t e = e || window.event;\r\n\t var x,y;\r\n\t if (e.pageX || e.pageY) \r\n\t { \r\n\t x = e.pageX;\r\n\t y = e.pageY;\r\n\t }\r\n\t else { \r\n\t x = e.clientX + document.body.scrollLeft + document.documentElement.scrollLeft; \r\n\t y = e.clientY + document.body.scrollTop + document.documentElement.scrollTop; \r\n\t } \r\n\treturn {x:x,y:e.y}; // nu gewoon de muiscoords ten opzichte van window.\r\n }", "title": "" }, { "docid": "f2935df33d570e1139d01c1462f31c07", "score": "0.7022916", "text": "function transformMouseCoords(e)\r\n {\r\n\t e = e || window.event;\r\n\t var x,y;\r\n\t if (e.pageX || e.pageY) \r\n\t { \r\n\t x = e.pageX;\r\n\t y = e.pageY;\r\n\t }\r\n\t else { \r\n\t x = e.clientX + document.body.scrollLeft + document.documentElement.scrollLeft; \r\n\t y = e.clientY + document.body.scrollTop + document.documentElement.scrollTop; \r\n\t } \r\n\treturn {x:x,y:e.y}; // nu gewoon de muiscoords ten opzichte van window.\r\n }", "title": "" }, { "docid": "2cd66c4d53ae8eba78e4c2dc5669c76c", "score": "0.68953186", "text": "function convertCoords(ev){\n var x = ev.clientX; // x coordinate of a mouse pointer\n var y = ev.clientY; // y coordinate of a mouse pointer\n var rect = ev.target.getBoundingClientRect();\n\n x = ((x - rect.left) - canvas.width/2)/(canvas.width/2);\n y = (canvas.height/2 - (y - rect.top))/(canvas.height/2);\n\n return ([x,y]);\n}", "title": "" }, { "docid": "c8099faa0a4a8d5a0d00b38fb069fe51", "score": "0.6871675", "text": "setRotatedCanvasMouse() {\n var canvasWidth = this.canvas.width;\n var canvasHeight = this.canvas.height;\n var p = convertToTransform(new Point2D({x: this.canvasMouseX, y: this.canvasMouseY}),\n new Point2D({x: canvasWidth / 2, y: canvasHeight / 2}), this.hvacApplication.viewAngle,\n this.hvacApplication.viewScale);\n this.rotatedCanvasMouseX = p.getX();\n this.rotatedCanvasMouseY = p.getY();\n }", "title": "" }, { "docid": "c377307671bd35071f703f3029add460", "score": "0.68117905", "text": "function updateMousePos(evt)\n{\n var rect = canvas.getBoundingClientRect();\n var root = document.documentElement;\n\n mouseX = evt.clientX - rect.left - root.scrollLeft;\n mouseY = evt.clientY - rect.top - root.scrollTop;\n}", "title": "" }, { "docid": "7f02128afc129365d7ddbeacba89ea78", "score": "0.6790213", "text": "function getMousePosition(e, canvas) {\r\n const rect = canvas.getBoundingClientRect(), // abs. size of element\r\n scaleX = canvas.width / rect.width, // relationship bitmap vs. element for X\r\n scaleY = canvas.height / rect.height; // relationship bitmap vs. element for Y\r\n\r\n return {\r\n x: (e.clientX - rect.left - 150) * scaleX, // scale mouse coordinates after they have\r\n y: (e.clientY - rect.top - 200) * scaleY, // been adjusted to be relative to element\r\n };\r\n}", "title": "" }, { "docid": "92c5727b39c60f3aa899c85184d7fc37", "score": "0.6774733", "text": "function onCanvasMouseMove(event){\n\n\tevent.preventDefault();\n\n\tmouse.x = ( ( event.clientX - canvasDims.left ) / ( canvasDims.right - canvasDims.left ) ) * 2 - 1;\n\tmouse.y = - ( ( event.clientY - canvasDims.top ) / ( canvasDims.bottom - canvasDims.top ) ) * 2 + 1;\n\n\t//console.log(mouse);\n}", "title": "" }, { "docid": "a9ac0784695395e90a73dcc10ceae061", "score": "0.67722154", "text": "function normalizeMouseXY(e){\n\tvar x;\n\tvar y;\n\tif (e.pageX || e.pageY) { \n\t x = e.pageX;\n\t y = e.pageY;\n\t}\n\telse { \n\t x = e.clientX + document.body.scrollLeft + document.documentElement.scrollLeft; \n\t y = e.clientY + document.body.scrollTop + document.documentElement.scrollTop; \n\t} \n\tx -= canvas.offsetLeft;\n\ty -= canvas.offsetTop;\n\t\n\t// x and y contain the mouse position r\n\t// Do something with this information\n\treturn [x,y];\n}", "title": "" }, { "docid": "71096a7d440c23e6bfd3c03196f88ff3", "score": "0.6726573", "text": "function getMousePosition(canvasEl, e) {\n let rect = canvas.getBoundingClientRect();\n x = e.clientX - rect.left;\n y = e.clientY - rect.top;\n\n //Find the Cartesian coordinates in pixels from the origin\n let pixelX = x - originX;\n let pixelY = originY - y;\n\n //Scale the pixel units into actual Cartesian units\n\n cartesianX = Math.round(pixelX/pixelScale);\n cartesianY = Math.round(pixelY/pixelScale);\n}", "title": "" }, { "docid": "d7cd628238ac3119be2f606ffe10ac08", "score": "0.6623761", "text": "function mouseToCanvas(mcoord) {\n\n if (mcoord === undefined)\n return;\n\n var cvc;\n \n cvc = g.cv.getBoundingClientRect();\n $('#test').text('CORD: '+ mcoord.x);\n return {\n x: (mcoord.x - cvc.left) * (g.cv.width / cvc.width),\n y: (mcoord.y - cvc.top) * (g.cv.height / cvc.height)\n }\n}", "title": "" }, { "docid": "2c58e64a4f6ebb5add122e04c4f968ba", "score": "0.6618353", "text": "function update_coordinates (event) {\n\n\tvar canvas = document.getElementById('canvas');\n\tvar position = canvas.getBoundingClientRect();\n\n\tdocument.getElementById(\"cx\").innerHTML = event.clientX - position.left;\n\tdocument.getElementById(\"cy\").innerHTML = event.clientY - position.top;\n}", "title": "" }, { "docid": "13de85da792da42766ab8f4390ee75ba", "score": "0.6601383", "text": "function mouseMove(){\n\t$( \"canvas\" ).mousemove(function(event){\n\t\tcircle.x = event.pageX;\n\t\tcircle.y = event.pageY;\n\t});\n}", "title": "" }, { "docid": "7a3e365ff8fa1f5f8195de3a46311531", "score": "0.6599558", "text": "function mouseClicked()\n{\n mouseShapeX = mouseX;\n mouseShapeY = mouseY;\n}", "title": "" }, { "docid": "885555cf5dcbab52dc5fb1d88ce82032", "score": "0.65819836", "text": "function getPosition(event){\n\tvar rect = canvas.getBoundingClientRect();\n\n\tmouse_coord.x = event.clientX - rect.left;\n\tmouse_coord.y = event.clientY - rect.top;\n\n}", "title": "" }, { "docid": "45e47913cf6c7a85a0af39d3f1de08fa", "score": "0.655307", "text": "cursorPoint (event) {\n let svg = document.querySelector('svg#Canvas')\n let pt = svg.createSVGPoint()\n pt.x = event.clientX\n pt.y = event.clientY\n\n let zoomTransform = document.querySelector('svg#Canvas #zoomTransform')\n pt = pt.matrixTransform(zoomTransform.getCTM().inverse())\n pt = pt.matrixTransform(svg.getScreenCTM().inverse())\n return [pt.x, pt.y]\n }", "title": "" }, { "docid": "92e3cdffb35c2032d47d4361b3d7811b", "score": "0.65462977", "text": "function getMousePos(canvas,event){\n var rect = canvas.getBoundingClientRect();\n scaleX = canvas.width / rect.width;\n scaleY = canvas.height / rect.height;\n return {\n x: parseInt(event.clientX-rect.left) * scaleX,\n y: parseInt(event.clientY-rect.top) * scaleY\n };\n}", "title": "" }, { "docid": "395bbde2d958bccb33f82fa9a7925fe8", "score": "0.6531641", "text": "function trackPosition(e) {\n\tcursorX = e.clientX - ctx.canvas.offsetLeft;\n\tcursorY = e.clientY - ctx.canvas.offsetTop;\n}", "title": "" }, { "docid": "5a50309678b2553e99adc7e118238472", "score": "0.65177816", "text": "function mouseMove(event) {\n mouse.x = event.clientX;\n mouse.y = event.clientY;\n}", "title": "" }, { "docid": "5903d4d719d656fe3e9b57c2d3479739", "score": "0.6495492", "text": "function relMouseCoords(event){\n var totalOffsetX = 0;\n var totalOffsetY = 0;\n var canvasX = 0;\n var canvasY = 0;\n var currentElement = this;\n\n do{\n totalOffsetX += currentElement.offsetLeft - currentElement.scrollLeft;\n totalOffsetY += currentElement.offsetTop - currentElement.scrollTop;\n }\n while(currentElement = currentElement.offsetParent)\n\n canvasX = event.pageX - totalOffsetX;\n canvasY = event.pageY - totalOffsetY;\n\n return {x:canvasX, y:canvasY}\n}", "title": "" }, { "docid": "5903d4d719d656fe3e9b57c2d3479739", "score": "0.6495492", "text": "function relMouseCoords(event){\n var totalOffsetX = 0;\n var totalOffsetY = 0;\n var canvasX = 0;\n var canvasY = 0;\n var currentElement = this;\n\n do{\n totalOffsetX += currentElement.offsetLeft - currentElement.scrollLeft;\n totalOffsetY += currentElement.offsetTop - currentElement.scrollTop;\n }\n while(currentElement = currentElement.offsetParent)\n\n canvasX = event.pageX - totalOffsetX;\n canvasY = event.pageY - totalOffsetY;\n\n return {x:canvasX, y:canvasY}\n}", "title": "" }, { "docid": "5bd849d90c1f111358b8bebd5921c0e0", "score": "0.64953667", "text": "function cursorPoint(evt){\n\n var pt = svg.createSVGPoint();\n \n pt.x = evt.clientX;\n pt.y = evt.clientY + 30;\n\n transfom = pt.matrixTransform(svg.getScreenCTM().inverse());\n return transfom;\n}", "title": "" }, { "docid": "55679d076a54c8f9e5dc98c3597de2ca", "score": "0.64861053", "text": "getMousePos(e) {\n this.mouseX = e.offsetX;\n this.mouseY = e.offsetY; \n }", "title": "" }, { "docid": "555944cff9f5362bc82d6f61158317b2", "score": "0.6486088", "text": "function handleMouseDown(e) {\n mouseX = parseInt(e.clientX - offsetX);\n mouseY = parseInt(e.clientY - offsetY);\n // Put your mousedown stuff here\n myMouse.x = mouseX;\n myMouse.y = mouseY;\n\n}", "title": "" }, { "docid": "dbbcb09ea8b9d47fa3ba759f11d05dbe", "score": "0.6484992", "text": "makeMouse()\n\t{\n\t\tthis.cursor = {\n\t\t\tx: -999,\n\t\t\ty: -999,\n\t\t\tmouseDown: false,\n\t\t\tmouseClicked: false,\n\t\t\tonMouseDown: e => {\n\t\t\t\tthis.verboseLog(\"run\", \"makeMouse\", \"Mouse Down: \", e);\n\t\t\t\tthis.cursor.mouseDown = true;\n\t\t\t},\n\t\t\tonMouseMove: e => {\n\t\t\t\tthis.verboseLog(\"excessive\", \"makeMouse\", \"Mouse Position: \", [e.clientX, e.clientY]);\n\t\t\t\tvar canvasBound = this.canvas.getBoundingClientRect();\n\t\t\t\tthis.cursor[\"x\"] = this.cursor.scale * (e.clientX - canvasBound.left);\n\t\t\t\tthis.cursor[\"y\"] = this.cursor.scale * (e.clientY - canvasBound.top);\n\t\t\t},\n\t\t\tonMouseClick: e => {\n\t\t\t\tthis.verboseLog(\"run\", \"makeMouse\", \"Mouse Up: \", e);\n\t\t\t\tthis.cursor.mouseClicked = true;\n\t\t\t\tthis.cursor.mouseDown = false;\n\t\t\t}\n\t\t};\n\t}", "title": "" }, { "docid": "5623feb6ca497d755df3e103e306fa2f", "score": "0.64780384", "text": "function getMouseXY(e) {\r\n var canvas = document.getElementById('canvas_example');\r\n //the boundingrect is used to get the co-oridates of the user's click relative to the the top left of the canvas\r\n var boundingRect = canvas.getBoundingClientRect();\r\n var offsetX = boundingRect.left;\r\n var offsetY = boundingRect.top;\r\n //takes the border width away from the canvas height and width to get completely accurate co-ordinates to get the actual width\r\n //and hegiht of the clickable canvas area\r\n var w = (boundingRect.width-canvas.width)/2;\r\n var h = (boundingRect.height-canvas.height)/2;\r\n offsetX += w;\r\n offsetY += h;\r\n // use clientX and clientY as getBoundingClientRect is used above to take away the offset in the width and height\r\n //caused by any padding and canvas border\r\n var mx = Math.round(e.clientX-offsetX);\r\n var my = Math.round(e.clientY-offsetY);\r\n //returns mx as x and my as y\r\n return {x: mx, y: my};\r\n}", "title": "" }, { "docid": "8f6923f027a3b60dbfc1095e3616d51f", "score": "0.647731", "text": "function mousePressed(){\r\n\tlet x = map(mouseX,0,width,-1,1);\r\n\tlet y = map(mouseY,0,height,1,-1);\r\n\t\r\n\tx_val.push(x);\r\n\ty_val.push(y);\r\n}", "title": "" }, { "docid": "36359753e719448c7fdd71f12291b31f", "score": "0.6458707", "text": "mouseToWorld() {\n return this.coordsToWorld(this.mouseX, this.mouseY);\n }", "title": "" }, { "docid": "7a9aa22f237eb0f010e82136edd5ee10", "score": "0.64495504", "text": "function relMouseCoords(event){\r\n var totalOffsetX = 0;\r\n var totalOffsetY = 0;\r\n var canvasX = 0;\r\n var canvasY = 0;\r\n var currentElement = this;\r\n do {\r\n totalOffsetX += currentElement.offsetLeft - currentElement.scrollLeft;\r\n totalOffsetY += currentElement.offsetTop - currentElement.scrollTop;\r\n }\r\n while(currentElement = currentElement.offsetParent)\r\n\r\n canvasX = event.pageX - totalOffsetX;\r\n canvasY = event.pageY - totalOffsetY;\r\n if (event.offsetX !== undefined && event.offsetY !== undefined) { \r\n return {x:event.offsetX, y: canvas.height - event.offsetY}; \r\n } else {\r\n return {x:canvasX, y: canvas.height - canvasY}\r\n }\r\n}", "title": "" }, { "docid": "985d214dec9337e54b3fab7aad362611", "score": "0.6448937", "text": "function setMouseCoords(event){\n\tmouseDocX = event.clientX;\n\tmouseDocY = event.clientY;\n\tmouseScreenX = event.screenX;\n\tmouseScreenY = event.screenY;\n}", "title": "" }, { "docid": "1cbbb20b43cac1fd52a7f32b5637a1bd", "score": "0.64460397", "text": "function handleMouse(e){\n\tsrc.x = e.clientX;\n\tsrc.y = e.clientY;\n}", "title": "" }, { "docid": "4a0d70959e9b4292135371d8dcbd9d59", "score": "0.6426615", "text": "function activateMouseInput(){\n\t$(function(){\n\n\tcanvas.onclick = mouseClickCanvas;\n\n\tvar canvasOffsetx = getOffset( canvas ).left; \n\tvar canvasOffsety = getOffset( canvas ).top; \n\t\t$('#canvas').mousemove(function(e){\n\t\t mousePos={\n\t\t x: ((e.clientX)+(cursorWidth/2)) - canvasOffsetx,\n\t\t\t\ty: ((e.clientY)+(cursorWidth/2)) - canvasOffsety\n\t\t };\n\t\t // console.log(mousePos);\n\t\t});\n\n\t});\n}", "title": "" }, { "docid": "52bd6b9dfc5ee275be0cea4c89048272", "score": "0.6424367", "text": "transformCoords(x: number, y: number) {\n return {\n x: (x * this.im.scale) + this.im.position.x,\n y: (y * this.im.scale) + this.im.position.y,\n };\n }", "title": "" }, { "docid": "850f92c656226c94aea49016e5e2bed1", "score": "0.6417091", "text": "function setMousePos(canvas, evt) {\n\t\tvar rect = canvas.getBoundingClientRect();\n\t mousePos.x = evt.clientX - rect.left;\n\t\tmousePos.y = evt.clientY - rect.top;\n\t}", "title": "" }, { "docid": "1f0cf3033ffd068c95eaffe669d9cb6a", "score": "0.64119315", "text": "function relMouseCoords(event){\n var totalOffsetX = 0;\n var totalOffsetY = 0;\n var canvasX = 0;\n var canvasY = 0;\n var currentElement = this;\n\n do{\n totalOffsetX += currentElement.offsetLeft;\n totalOffsetY += currentElement.offsetTop;\n }\n while(currentElement = currentElement.offsetParent)\n\n canvasX = event.pageX - totalOffsetX;\n canvasY = event.pageY - totalOffsetY;\n\n return {x:canvasX, y:canvasY}\n}", "title": "" }, { "docid": "a6e008a3a94be6516febf3dd043b81a5", "score": "0.6394207", "text": "function transformCoordinates() {\n\n }", "title": "" }, { "docid": "5bd58a27c246123225b766ee5e2da634", "score": "0.63866043", "text": "function normalizeMouse(/*float*/ x, /*float*/ y){\n\tvar offsetX = this.main.gameSurface.canvas.offsetLeft;\n\tvar offsetY = this.main.gameSurface.canvas.offsetTop;\n\t//var width \t= this.main.gameSurface.canvas.width;\n\t//var height \t= this.main.gameSurface.canvas.height;\n\t\n\tmouseX = x - offsetX;\n\tmouseY = y - offsetY;\n}", "title": "" }, { "docid": "92082e0a1ad0f7251c0ba477abb17c67", "score": "0.6373181", "text": "handleMouseMove(e) {\n this.pt.x = e.clientX;\n this.pt.y = e.clientY;\n\n const cursporpt = this.pt.matrixTransform(\n this.svg.current.getScreenCTM().inverse()\n );\n this.setState({\n x: cursporpt.x,\n y: cursporpt.y\n });\n }", "title": "" }, { "docid": "3c408d4873ce8fca3254cebb006e4514", "score": "0.6372477", "text": "function getCurrentMousePos(canvas, evt) {//return X&Y of current mousePosition\n var rect = canvas.getBoundingClientRect();\n\n return {\n x: Math.round((evt.clientX - rect.left) / (rect.right - rect.left) * canvas.width),\n y: Math.round((evt.clientY - rect.top) / (rect.bottom - rect.top) * canvas.height)\n };\n}", "title": "" }, { "docid": "f64add26dd861d221ac40e3962897897", "score": "0.63578176", "text": "function calculateMousePosition(evt) {\n var rect = canvas.getBoundingClientRect();\n var root = document.documentElement;\n var mouseX = evt.clientX - rect.left - root.scrollLeft;\n var mouseY = evt.clientY - rect.top - root.scrollTop;\n return { X: mouseX, y: mouseY };\n}", "title": "" }, { "docid": "f860f8185a24967d4f4491523a371d69", "score": "0.6357105", "text": "function mouseUpdate(x) {\n let self = x;\n self.canvas.addEventListener(\"mousemove\", function (e) {\n self.mouse.x = e.clientX;\n self.mouse.y = e.clientY;\n });\n }", "title": "" }, { "docid": "fea22732d9db75e30993f9c66521978a", "score": "0.6357098", "text": "_mapMousePosition(x, y) {\n return ({ // convert to [-1..1] range\n x: 2.0 * ((x - this._canvas.offsetLeft) - 0.5 * this._canvas.clientWidth) / this._canvas.clientWidth,\n y: 2.0 * (0.5 * this._canvas.clientHeight - (y - this._canvas.offsetTop)) / this._canvas.clientHeight,\n z: 0\n });\n }", "title": "" }, { "docid": "3470373754ea4188dd561d8228816a16", "score": "0.63475144", "text": "function updateMouseCoords(event, coordsObj) {\n coordsObj.x = ((event.clientX - renderer.domElement.offsetLeft + 0.5) / window.innerWidth) * 2 - 1;\n coordsObj.y = -((event.clientY - renderer.domElement.offsetTop + 0.5) / window.innerHeight) * 2 + 1;\n}", "title": "" }, { "docid": "54858d45a042c01d1d96e18153581fb5", "score": "0.6335847", "text": "function alert_coords(evt) {\n pt.x = evt.clientX;\n pt.y = evt.clientY;\n\n // The cursor point, translated into svg coordinates\n var cursorpt = pt.matrixTransform(svg.getScreenCTM().inverse());\n \n}", "title": "" }, { "docid": "93a6c9ada25c339365a5870dd866d414", "score": "0.63324094", "text": "function updateCoordinates(event) {\n let canvas = document.getElementById(\"canvas\");\n let rect = canvas.getBoundingClientRect();\n xCoordinate = event.clientX - rect.left;\n yCoordinate = event.clientY - rect.top;\n }", "title": "" }, { "docid": "81e0ce59e215789bc3395b1380cc0d37", "score": "0.6330638", "text": "function handleMouseMove(event){\r\n //here we converting mouse pos val recived\r\n //to a normalized value varying between -1 and 1;\r\n //this is the formula for the horizontall axis;\r\n \r\n var tx=-1+ (event.clientX/WIDTH)*2;\r\n \r\n //for the vertical (becouse the 2d y goes the opposite direction of the 3d y)\r\n \r\n var ty=1-(event.clientY/HEIGHT)*2;\r\n mousePos={x:tx,y:ty};\r\n}", "title": "" }, { "docid": "0ba9c5613ec682c8fd6aa2c6ec7dce41", "score": "0.6317837", "text": "function calculateMousePosition(evt) {\n\tvar rect = canvas.getBoundingClientRect(); \t\t\t\t// get handle on the black area on the browser \n\tvar root = document.documentElement;\t\t\t\t\t// get handle on the html document\n\tvar mouseX = evt.clientX - rect.left - root.scrollLeft;\n\tvar mouseY = evt.clientY - rect.left - root.scrollLeft;\n\treturn{\n\t\tx:mouseX,\n\t\ty:mouseY\n\t};\n}", "title": "" }, { "docid": "e7bde1761f810a847c91120c0e402dc1", "score": "0.6311753", "text": "function getMousePos(canvas, evt) {\n\tvar rect = canvas.getBoundingClientRect(), // abs. size of element\n\tscaleX = canvas.width / rect.width, // relationship bitmap vs. element for X\n\tscaleY = canvas.height / rect.height; // relationship bitmap vs. element for Y\n\treturn {\n\t\tx: (evt.clientX - rect.left) * scaleX, // scale mouse coordinates after they have\n\t\ty: (evt.clientY - rect.top) * scaleY // been adjusted to be relative to element\n\t}\n}", "title": "" }, { "docid": "c4e3b885f68a4d170c43d344d72f8611", "score": "0.62997085", "text": "function updateMouseCoords(event, coordsObj) {\n coordsObj.x = ((event.clientX - renderer.domElement.offsetLeft + 0.5) / window.innerWidth) * 2 - 1;\n coordsObj.y = -((event.clientY - renderer.domElement.offsetTop + 0.5) / window.innerHeight) * 2 + 1;\n}", "title": "" }, { "docid": "486689ab86d976957c33b00287a09fa7", "score": "0.629178", "text": "function onMouseMove(e) {\n\n let rect = canvas.getBoundingClientRect();\n\n mouse.screenX = ((e.clientX - rect.left) / (rect.right - rect.left) * canvas.width);\n mouse.screenY = ((e.clientY - rect.top) / (rect.bottom - rect.top) * canvas.height)\n\n let x = mouse.screenX + camPosX - halfWidth;\n let y = mouse.screenY + camPosY - halfHeight;\n\n mouse.dx = x - mouse.x;\n mouse.dy = y - mouse.y;\n mouse.x = x;\n mouse.y = y;\n}", "title": "" }, { "docid": "5e180b3e756a306739dc9a39e214cfc4", "score": "0.6288465", "text": "function mousePosition(evt) {\n var rect = canvas.getBoundingClientRect();\n var root = document.documentElement;\n var mouseX = evt.clientX - rect.left - root.scrollLeft;\n var mouseY = evt.clientY - rect.top - root.scrollTop;\n return {\n x: mouseX,\n y: mouseY\n };\n}", "title": "" }, { "docid": "e436d6c691a831fb6e3bc3c237bf4e94", "score": "0.6287009", "text": "function getMouseCoordinates(canvas, event) {\n var totalOffsetX = 0;\n var totalOffsetY = 0;\n var canvasX = 0;\n var canvasY = 0;\n var currentElement = canvas;\n\n do {\n totalOffsetX += currentElement.offsetLeft - currentElement.scrollLeft;\n totalOffsetY += currentElement.offsetTop - currentElement.scrollTop;\n }\n while(currentElement = currentElement.offsetParent)\n\n canvasX = event.pageX - totalOffsetX;\n canvasY = event.pageY - totalOffsetY;\n\n return { x: canvasX, y: canvasY };\n}", "title": "" }, { "docid": "df5fd54817eaa40c4e8c01e3cf9d38be", "score": "0.6283465", "text": "function getRealMousePos(evt)\n{\n var rect = canvas.getBoundingClientRect(),\n scaleX = canvas.width / rect.width,\n scaleY = canvas.height / rect.height;\n\n return {\n x: ((evt.clientX - rect.left) * scaleX) - offset,\n y: ((evt.clientY - rect.top) * scaleY) - offset\n }\n}", "title": "" }, { "docid": "b4a2b85917126156c6fc53d7204a9ec5", "score": "0.62780464", "text": "function convertMousePos(event) {\n let mp = getMousePos(event)\n let convX = Math.floor(mp[0] / scale)\n let convY = Math.floor(mp[1] / scale)\n return [convX, convY]\n}", "title": "" }, { "docid": "83de5cc9f52a808f15fa7712765343d7", "score": "0.6268388", "text": "function mouseClicked() {\n let x = map(mouseX, 0, width, -1, 1);\n let y = map(mouseY, 0, height, 1, -1);\n x_vals.push(x);\n y_vals.push(y);\n}", "title": "" }, { "docid": "5fbdaa1d723c9369cfcdad31d9d77f4c", "score": "0.6265206", "text": "function getMousePosition(c, event) {\n let rect = c.canvas.getBoundingClientRect();\n let x = event.clientX - rect.left;\n let y = event.clientY - rect.top;\n return [x, y]; \n}", "title": "" }, { "docid": "4ed0b23e37e1fad29166619b4d2cb22f", "score": "0.6260992", "text": "canvasPoint(event) {\n const svg = document.getElementById('game-canvas');\n const point = svg.createSVGPoint();\n point.x = event.clientX;\n point.y = event.clientY;\n const { x, y } = point.matrixTransform(svg.getScreenCTM().inverse());\n return {x, y};\n }", "title": "" }, { "docid": "ad17b24c325a0efe6cc9d76aec85a9e9", "score": "0.62594795", "text": "function getPosition(event){\ncoord.x = event.clientX - canvas.offsetLeft;\ncoord.y = event.clientY - canvas.offsetTop;\n}", "title": "" }, { "docid": "8a7f279785145bf506fd1bf1a73f8f77", "score": "0.62564313", "text": "function mouseClicked() {\n MouseClickedAtX = mouseX;\n MouseClickedAtY = mouseY;\n}", "title": "" }, { "docid": "b8cce2b88323b42a4aacf408f4525d42", "score": "0.62493134", "text": "function calculateMousePos(evt) {\n var rect = canvas.getBoundingClientRect(); //the area in our browser that the canvas is in\n var root = document.documentElement; \n var mouseX = evt.clientX - rect.left - root.scrollLeft;\n var mouseY = evt.clientY - rect.top - root.scrollTop;\n return {\n x:mouseX,\n y:mouseY\n };\n}", "title": "" }, { "docid": "a108ed49976057c2b10490ae20d46988", "score": "0.6242719", "text": "function canvasClicked(event) {\n var rect = canvas.getBoundingClientRect();\n console.log(\"X: \" + (event.clientX - rect.left - 3) / scale + \" Y: \" + (event.clientY - rect.top - 3)/ scale);\n}", "title": "" }, { "docid": "41b0c27874efd364c48eb530f9a80565", "score": "0.62396204", "text": "relMouseCoords(e) {\n const c = GameMapGui.mouseCoords(e);\n const factor = this.dispo.zoom;\n c.x = Math.round((c.x / factor) - (this.pan.x / factor));\n c.y = Math.round((c.y / factor) - (this.pan.y / factor));\n return c;\n }", "title": "" }, { "docid": "f1b703ef213b049001163a471edcce0c", "score": "0.62385374", "text": "function getMousePos(canvas, e) {\n var rect = canvas.getBoundingClientRect();\n return {\n x: Math.round(\n (e.clientX - rect.left) / (rect.right - rect.left) * canvas.width),\n y: Math.round(\n (e.clientY - rect.top) / (rect.bottom - rect.top) * canvas.height)\n };\n }", "title": "" }, { "docid": "9d364d4c0770224d861d0af9168bc86c", "score": "0.62367773", "text": "getMousePos(canvas, evt) {\n var rect = canvas.getBoundingClientRect();\n return {\n x: evt.clientX - rect.left,\n y: evt.clientY - rect.top\n };\n }", "title": "" }, { "docid": "9431de349c0482287fd0dddf774166ab", "score": "0.6234744", "text": "function handleMouseMove(event) {\n mouseX = event.pageX;\n mouseY = event.pageY;\n}", "title": "" }, { "docid": "3163ea74a59e52c1bf8f6a9c9af81d93", "score": "0.6229427", "text": "function GetMouse(e) {\n return {x:e.offsetX,y:e.offsetY};\n}", "title": "" }, { "docid": "812c0113c3d6fdcd8e1af4c1f10c003b", "score": "0.6227257", "text": "function getCanvasMousePosition (event) {\n var rect = canvas.getBoundingClientRect();\n\n return {\n x: event.clientX - rect.left,\n y: event.clientY - rect.top\n }//(got some help for this online!)\n}", "title": "" }, { "docid": "bd5f8c6e7d92defafa0dfb875ab099a3", "score": "0.62108403", "text": "function getMousePos(evt)\n{\n var rect = canvas.getBoundingClientRect(),\n scaleX = canvas.width / rect.width,\n scaleY = canvas.height / rect.height;\n\n return {\n //x: Math.floor(((evt.clientX - rect.left) * scaleX) / pixelSize - 0.5), //-1\n //y: Math.floor(((evt.clientY - rect.top) * scaleY) / pixelSize - 0.5)\n\n //x: Math.round(((evt.clientX - rect.left) * scaleX) / pixelSize) - 1, //-1\n //y: Math.round(((evt.clientY - rect.top) * scaleY) / pixelSize) - 1\n\n x: ((evt.clientX - rect.left) * scaleX - offset) / pixelSize,\n y: ((evt.clientY - rect.top) * scaleY - offset) / pixelSize\n }\n}", "title": "" }, { "docid": "fadfd38d47631103077af61290941f5f", "score": "0.61966825", "text": "function mouseMovement(mousePos) {\n\t\tmouse.x = mousePos.x;\n\t\tmouse.y = mousePos.y;\n }", "title": "" }, { "docid": "7194bd493eb0ef7c07580021f0792e3f", "score": "0.61963314", "text": "function GetMousePosition(x,y){\r\n // Get canvas size and position in web page\r\n let canvasSizeData = canvas.getBoundingClientRect();\r\n return { x: (x - canvasSizeData.left) * (canvas.width / canvasSizeData.width),\r\n y: (y - canvasSizeData.top) * (canvas.height / canvasSizeData.height)\r\n };\r\n}", "title": "" }, { "docid": "90c5eeabca52bae542fc812693ae6783", "score": "0.6188564", "text": "function mousemove(e) {\n e.preventDefault();\n\n cursor = e.offsetX / scale;\n}", "title": "" }, { "docid": "816933433aa6ff78294371eb82b309c9", "score": "0.61884576", "text": "function setCursorPositions(e){\n\tpreviousPosition.x = currentPosition.x;\n\tpreviousPosition.y = currentPosition.y;\n\tif (e.changedTouches == undefined){\n\t\tcurrentPosition.x = e.layerX - canvas.offsetLeft;\n\t\tcurrentPosition.y = e.layerY - canvas.offsetTop;\n\t}else{\n\t\tcurrentPosition.x = e.changedTouches[0].pageX - canvas.offsetLeft;\n\t\tcurrentPosition.y = e.changedTouches[0].pageY - canvas.offsetTop;\n\t}\n}", "title": "" }, { "docid": "99077ffab6076938519fdaace78a8552", "score": "0.61831766", "text": "set_canvas_cursor_position(x,y) {\n\t\tthis.cursorx = clamp(x, 0, this.main_canvas_el.width);\n\t\tthis.cursory = clamp(y, 0, this.main_canvas_el.height);\t\n\t}", "title": "" }, { "docid": "6435c81b7cccb311d042c78693beb323", "score": "0.6176608", "text": "function mouseMove(e) {\n\t\tpmouseX = mouseX;\n\t\tpmouseY = mouseY;\n\t\tmouseX = e.clientX - canvas.offsetLeft;\n\t\tmouseY = e.clientY - canvas.offsetTop;\n\t\tdrawOnCanvas();\n\t}", "title": "" }, { "docid": "c7fee55d6b6b5ba9200d26eafc0400c9", "score": "0.6173934", "text": "function trackPosition(e) { mouse.x = e.pageX; mouse.y = e.pageY; }", "title": "" }, { "docid": "d3d1eb6bdf5ef54a31d50095e26d641b", "score": "0.6166918", "text": "function relMouseCoords(event){\n var totalOffsetX = 0,\n totalOffsetY = 0,\n canvasX = 0,\n canvasY = 0,\n currentElement = this,\n test = [],\n elts = [];\n\n\tif (event.offsetX !== undefined && event.offsetY !== undefined) { return {x:event.offsetX, y:event.offsetY}; }\n\t//if (event.layerX !== undefined && event.layerY !== undefined) { return {x:event.layerX, y:event.layerY}; }\n\n do{\n totalOffsetX += currentElement.offsetLeft - currentElement.scrollLeft;\n totalOffsetY += currentElement.offsetTop - currentElement.scrollTop;\n //test[test.length] = currentElement.offsetLeft - currentElement.scrollLeft\n //elts[elts.length] = currentElement\n }\n while(currentElement = currentElement.offsetParent)\n\n canvasX = event.pageX - totalOffsetX;\n canvasY = event.pageY - totalOffsetY;\n\n //hack to deal with FF scroll, better solution TBD:\n if(event.offsetX == undefined){\n \tcanvasX -= document.body.scrollLeft;\n \tcanvasY -= document.body.scrollTop;\n }\n\n return {x:canvasX, y:canvasY}\n}", "title": "" }, { "docid": "e3153fe894bf5b3759c9ff6ce9a7c87d", "score": "0.6164445", "text": "function mouseClicked() {\n // normalize point\n let x = map(mouseX, 0, width, 0, 1);\n let y = map(mouseY, 0, height, 0, 1);\n pushPoint(x, y);\n}", "title": "" }, { "docid": "57de02c62df9c6936863b51c9d6a9c24", "score": "0.6164207", "text": "function updateMousePos(evt) {\r\n var canvas = document.getElementById('layer1');\r\n var rect = canvas.getBoundingClientRect();\r\n g_mousepos.x = evt.clientX - rect.left;\r\n g_mousepos.y = evt.clientY - rect.top;\r\n}", "title": "" }, { "docid": "e1479eeacc35aeddf831a80d6bbd54f5", "score": "0.61616033", "text": "function mousePos(canvas, evt) {\n let rect = canvas.getBoundingClientRect();\n return {\n x: evt.clientX - rect.left,\n y: evt.clientY - rect.top\n };\n}", "title": "" }, { "docid": "5156f7ffb3345a5905f84eba00aac23b", "score": "0.6138982", "text": "function getMousePos(canvas, evt) {\n var mouseX, mouseY;\n if (evt.offsetX) {\n mouseX = evt.offsetX;\n mouseY = evt.offsetY;\n } else if (evt.layerX) {\n mouseX = evt.layerX;\n mouseY = evt.layerY;\n }\n return {\n x: mouseX,\n y: mouseY\n };\n }", "title": "" }, { "docid": "2d34b846d16a882163b1920e556c37b8", "score": "0.61341566", "text": "function getMousePos(canvas, e) {\n var rect = canvas.getBoundingClientRect();\n return {\n x: Math.round((e.clientX - rect.left)/(rect.right - rect.left)*canvas.width),\n y: Math.round((e.clientY - rect.top)/(rect.bottom - rect.top)*canvas.height)\n };\n }", "title": "" }, { "docid": "4c3b5176c3e4160bf4ed7e4fd22c3de3", "score": "0.61249274", "text": "function get_cursor_position(e){\r\n var x;\r\n var y;\r\n \r\n if (e.pageX || e.pageY) {\r\n x = e.pageX;\r\n y = e.pageY;\r\n } else {\r\n x = e.clientX + \r\n document.body.scrollLeft + \r\n document.documentElement.scrollLeft;\r\n y = e.clientY + \r\n document.body.scrollTop + \r\n document.documentElment.scrollTop;\r\n }\r\n \r\n x -= canvas.offsetLeft;\r\n y -= canvas.offsetTop;\r\n x = Math.floor(x / entitySize);\r\n y = Math.floor(y / entitySize);\r\n return [x,y]\r\n}", "title": "" }, { "docid": "27d85d4f9c5f1044f2850055395f8193", "score": "0.61247915", "text": "function calcMousePos(e){\n\t\t\tlet rect = canvas.getBoundingClientRect();\n\t\t\tlet root = document.documentElement;\n\t\t\tlet mouseX = e.clientX - rect.left - root.scrollLeft;\n\t\t\tlet mouseY = e.clientY - rect.top - root.scrollTop;\n\t\t\treturn {\n\t\t\t\tx: mouseX,\n\t\t\t\ty: mouseY\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "a5cb09920178d683030394f936bce1b7", "score": "0.6117167", "text": "function getMouseCoord(canvas, rect, x, y){\n\treturn ([((x - rect.left) - canvas.width/2)/(canvas.width/2),\n\t (canvas.height/2 - (y - rect.top))/(canvas.height/2), 0 ]);\n}", "title": "" }, { "docid": "db5a281611d183c620259078726f8996", "score": "0.61159706", "text": "function ev_canvas (ev) {\n if (ev.layerX || ev.layerX == 0) { // Firefox\n ev._x = ev.layerX;\n ev._y = ev.layerY;\n } else if (ev.offsetX || ev.offsetX == 0) { // Opera\n ev._x = ev.offsetX;\n ev._y = ev.offsetY;\n }\n\n // Call the event handler of the tool.\n var func = tool[ev.type];\n if (func) {\n func(ev);\n }\n }", "title": "" }, { "docid": "0da31559e6bbcd62a792af1e327dbb9f", "score": "0.61158067", "text": "positionToCanvas (x, y) {\n let bbox = this.canvas.getBoundingClientRect()\n return {\n x: x - bbox.left * (this.canvas.width / bbox.width),\n y: y - bbox.top * (this.canvas.height / bbox.height)\n }\n }", "title": "" }, { "docid": "0af07396b23dddad5cfc05589cb724ca", "score": "0.6109418", "text": "function mouseX() {\n return mouseX;\n}", "title": "" }, { "docid": "ae6b968efc7f6f68f29df07b0200533c", "score": "0.6105211", "text": "function mouseLocation(event){\n XPOS = event.clientX;\n YPOS = event.clientY;\n}", "title": "" }, { "docid": "2424a3516fafcaa03f40cb60cc616866", "score": "0.6105048", "text": "function getMousePos(canvas, evt) {\r\n var rect = canvas.getBoundingClientRect();\r\n return {\r\n x: evt.clientX - rect.left,\r\n y: evt.clientY - rect.top\r\n };\r\n}", "title": "" }, { "docid": "978f6439695e9930c93218b8c831247f", "score": "0.6104298", "text": "function updateMousePosition(event) {\n mouseX = event.clientX - (window.innerWidth - worldRect.width) * .5;\n mouseY = event.clientY - (window.innerHeight - worldRect.height) * .5;\n }", "title": "" }, { "docid": "5316bb719c5448b3c340987fb4392683", "score": "0.6100962", "text": "getCanvasMouseX(event) {\n //Get mouse position\n let bounds = event.target.getBoundingClientRect();\n let mouseX = event.clientX - bounds.left;\n mouseX = mouseX * this.canvas.width / bounds.width;\n return Math.floor(mouseX / 100);\n }", "title": "" }, { "docid": "b18d861d9fb597448ac3ebc107e2a1da", "score": "0.60939175", "text": "function ev_canvas (ev) {\n if (ev.layerX || ev.layerX == 0) { // Firefox\n ev._x = ev.layerX;\n ev._y = ev.layerY;\n } else if (ev.offsetX || ev.offsetX == 0) { // Opera\n ev._x = ev.offsetX;\n ev._y = ev.offsetY;\n }\n\n // Call the event handler of the tool.\n var func = tool[ev.type];\n if (func) {\n func(ev);\n } \n }", "title": "" }, { "docid": "66aa6b027a47df5c7239a209dbe0c963", "score": "0.60929483", "text": "function calculateMousePos(evt) {\n\tvar rect = scaledCanvas.getBoundingClientRect(),\n\t\troot = document.documentElement;\n\n\t// account for the margins, canvas position on page, scroll amount, etc.\n\tmouseX = evt.clientX - rect.left;\n\tmouseY = evt.clientY - rect.top;\n\tvar canvasStretch = scaledCanvas.width/ canvas.width;\n\tmouseX /= canvasStretch;\n\tmouseY /= canvasStretch;\n}", "title": "" }, { "docid": "a727a47b467566e6a6b01e8dd57b4f7f", "score": "0.60928506", "text": "moveToMousePosition() {\n this.setPosition(mouseX - this.w / 2, mouseY - this.h / 2);\n }", "title": "" }, { "docid": "bfa3fbe7dd4acdad8fe5c459269532d9", "score": "0.608904", "text": "function getMouse(mousePosition) {\n mouseX = mousePosition.layerX;\n mouseY = mousePosition.layerY;\n}", "title": "" }, { "docid": "68850c606e6ffc5adf2f9fbec361ddaf", "score": "0.60886896", "text": "function transformCoordinates(x, y) {\n var pt = svg.createSVGPoint();\n pt.x = x;\n pt.y = y;\n pt = pt.matrixTransform(svg.getScreenCTM().inverse());\n\n return [pt.x, pt.y];\n }", "title": "" }, { "docid": "51e4cad76994550feffe623a02ec25cd", "score": "0.60820097", "text": "function convertCoords(x,y) {\n let convertedX = spacingPoints[0];\n let convertedY = spacingPoints[0];\n let xDiff = Math.abs(x-spacingPoints[0]);\n let yDiff = Math.abs(y-spacingPoints[0]);\n\n // find the point on the board closest the where the mouse clicked\n let coords = {};\n spacingPoints.map(function(thisPoint) {\n let thisXDiff = Math.abs(x-thisPoint);\n let thisYDiff = Math.abs(y-thisPoint);\n if (thisXDiff < xDiff) {\n coords.X = thisPoint; \n xDiff = thisXDiff;\n }\n if (thisYDiff < yDiff) {\n coords.Y = thisPoint; \n yDiff = thisYDiff;\n }\n });\n\n return coords;\n}", "title": "" } ]
3b7d525996b4c94fa88c9f09a3fe1c1b
Send response to an OPTIONS request.
[ { "docid": "16c48e1350076416bc0b682c76444df2", "score": "0.75244814", "text": "_sendOptionsResponse() {\n\n\t\t// create response headers set\n\t\tconst response = new EndpointCallResponse(this._app, 200);\n\n\t\t// list allowed methods\n\t\tthis._allowedMethods.forEach(\n\t\t\tmethod => {\n\t\t\t\tresponse.header(\n\t\t\t\t\t'Allow', (method === 'GET' ? 'GET, HEAD' : method));\n\t\t\t}\n\t\t);\n\t\tresponse.header('Allow', 'OPTIONS');\n\n\t\t// add zero content length header\n\t\tresponse.header('Content-Length', 0);\n\n\t\t// response always varies depending on the \"Origin\" header\n\t\tresponse.header('Vary', 'Origin');\n\n\t\t// process CORS preflight request\n\t\tconst origin = this._httpRequest.headers['origin'];\n\t\tconst requestedMethod =\n\t\t\tthis._httpRequest.headers['access-control-request-method'];\n\t\tif (origin && requestedMethod) {\n\n\t\t\t// check if origin is allowed\n\t\t\tlet allowedOrigin;\n\t\t\tif (this._app._allowedPublicOriginsPattern\n\t\t\t\t&& this._endpointMatch.handler.isPublic(\n\t\t\t\t\tthis._endpointMatch.resourceUri,\n\t\t\t\t\tthis._endpointMatch.uriParams)\n\t\t\t\t&& this._app._allowedPublicOriginsPattern.test(origin)) {\n\t\t\t\tallowedOrigin = 'ALLOWED_SPECIFIC';\n\t\t\t} else if (!this._app._allowedSecureOriginsPattern) {\n\t\t\t\tallowedOrigin = 'ALLOWED_ANY';\n\t\t\t} else if (this._app._allowedSecureOriginsPattern.test(origin)) {\n\t\t\t\tallowedOrigin = 'ALLOWED_SPECIFIC_PLUS_CRED';\n\t\t\t} else {\n\t\t\t\tallowedOrigin = 'DISALLOWED';\n\t\t\t}\n\n\t\t\t// proceed if allowed origin and method\n\t\t\tif (allowedOrigin !== 'DISALLOWED') {\n\n\t\t\t\t// allow the origin\n\t\t\t\tresponse.header(\n\t\t\t\t\t'Access-Control-Allow-Origin',\n\t\t\t\t\t(allowedOrigin === 'ALLOWED_ANY' ? '*' : origin));\n\n\t\t\t\t// allow credentials, if allowed\n\t\t\t\tif (allowedOrigin === 'ALLOWED_SPECIFIC_PLUS_CRED')\n\t\t\t\t\tresponse.header('Access-Control-Allow-Credentials', 'true');\n\n\t\t\t\t// allow caching of the preflight response (for 20 days)\n\t\t\t\tresponse.header('Access-Control-Max-Age', 20 * 24 * 3600);\n\n\t\t\t\t// allow method and headers\n\t\t\t\tresponse.header('Access-Control-Allow-Method', requestedMethod);\n\t\t\t\tconst requestedHeaders =\n\t\t\t\t\tthis._httpRequest.headers['access-control-request-headers'];\n\t\t\t\tif (requestedHeaders)\n\t\t\t\t\tresponse.header(\n\t\t\t\t\t\t'Access-Control-Allow-Headers', requestedHeaders);\n\t\t\t}\n\t\t}\n\n\t\t// send OK response\n\t\tthis._httpResponse.writeHead(response.statusCode, response.headers);\n\t\tthis._httpResponse.end();\n\t}", "title": "" } ]
[ { "docid": "d437b2246855ca6876de56b11bb2a6fa", "score": "0.73784786", "text": "function handle_options(req, res) {\n console.log(\"OPTIONS request to patientService\");\n // You must send something back to end the request\n res.send();\n}", "title": "" }, { "docid": "da71274705e652a8363b67eb80e3fdb9", "score": "0.64931816", "text": "function sendOptionsResponse(res, options, next) {\n\t try {\n\t var body = options.join(',');\n\t res.set('Allow', body);\n\t res.send(body);\n\t } catch (err) {\n\t next(err);\n\t }\n\t}", "title": "" }, { "docid": "ed153724c99533fe4831b0fde60079ec", "score": "0.63560456", "text": "async function sendOptionsResponse(ctx, options) {\n var body = options.join(',');\n ctx.set('Allow', body);\n ctx.body = body;\n}", "title": "" }, { "docid": "f642c64103d7bb0ef0b6a42f77e6b5df", "score": "0.6311657", "text": "function sendOptionsResponse(res, options, next) {\n try {\n var body = options.join(',');\n res.set('Allow', body);\n res.send(body);\n } catch (err) {\n next(err);\n }\n}", "title": "" }, { "docid": "f642c64103d7bb0ef0b6a42f77e6b5df", "score": "0.6311657", "text": "function sendOptionsResponse(res, options, next) {\n try {\n var body = options.join(',');\n res.set('Allow', body);\n res.send(body);\n } catch (err) {\n next(err);\n }\n}", "title": "" }, { "docid": "f642c64103d7bb0ef0b6a42f77e6b5df", "score": "0.6311657", "text": "function sendOptionsResponse(res, options, next) {\n try {\n var body = options.join(',');\n res.set('Allow', body);\n res.send(body);\n } catch (err) {\n next(err);\n }\n}", "title": "" }, { "docid": "f642c64103d7bb0ef0b6a42f77e6b5df", "score": "0.6311657", "text": "function sendOptionsResponse(res, options, next) {\n try {\n var body = options.join(',');\n res.set('Allow', body);\n res.send(body);\n } catch (err) {\n next(err);\n }\n}", "title": "" }, { "docid": "f642c64103d7bb0ef0b6a42f77e6b5df", "score": "0.6311657", "text": "function sendOptionsResponse(res, options, next) {\n try {\n var body = options.join(',');\n res.set('Allow', body);\n res.send(body);\n } catch (err) {\n next(err);\n }\n}", "title": "" }, { "docid": "f642c64103d7bb0ef0b6a42f77e6b5df", "score": "0.6311657", "text": "function sendOptionsResponse(res, options, next) {\n try {\n var body = options.join(',');\n res.set('Allow', body);\n res.send(body);\n } catch (err) {\n next(err);\n }\n}", "title": "" }, { "docid": "6ed5527276678c1fb19617e7ce2f65c3", "score": "0.62323254", "text": "function processOptionsRequest(req, res) {\n \n res.writeHead(200, {\n 'Content-Type': 'text/plain',\n 'Access-Control-Allow-Origin': '*',\n 'Access-Control-Allow-Headers': 'Origin, X-Requested-With, Content-Type, Accept'\n });\n \n // res.end('Kapott adatok: ' + JSON.stringify(post));\n res.end('options sent');\n}", "title": "" }, { "docid": "09f8cfde6d9df81533480a3f2d573dc0", "score": "0.61170226", "text": "options(ctx) {\n ctx.response.headers.set('Allow', this.allowedMethods());\n }", "title": "" }, { "docid": "0d7673729b140cfef8cba23c54ef14e7", "score": "0.6081221", "text": "options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }", "title": "" }, { "docid": "0d7673729b140cfef8cba23c54ef14e7", "score": "0.6081221", "text": "options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }", "title": "" }, { "docid": "0d7673729b140cfef8cba23c54ef14e7", "score": "0.6081221", "text": "options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }", "title": "" }, { "docid": "0d7673729b140cfef8cba23c54ef14e7", "score": "0.6081221", "text": "options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }", "title": "" }, { "docid": "0d7673729b140cfef8cba23c54ef14e7", "score": "0.6081221", "text": "options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }", "title": "" }, { "docid": "0d7673729b140cfef8cba23c54ef14e7", "score": "0.6081221", "text": "options(url, options = {}) {\n return this.request('OPTIONS', url, options);\n }", "title": "" }, { "docid": "c44297fb4efe06a469906db7421aab4c", "score": "0.5556027", "text": "function allowCrossDomain(req, res, next) {\n res.header('Access-Control-Allow-Origin', '*');\n res.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE,OPTIONS');\n res.header('Access-Control-Allow-Headers', 'Content-Type, Authorization, Content-Length, X-Requested-With');\n\n // intercept OPTIONS method\n if ('OPTIONS' === req.method) {\n res.send(200);\n }\n else {\n next();\n }\n }", "title": "" }, { "docid": "fb3dd77cffb9818ebaa7cd9dff71cc06", "score": "0.5485066", "text": "function allowCrossDomain(req, res, next) {\n res.header('Access-Control-Allow-Origin', '*');\n res.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE');\n res.header('Access-Control-Allow-Headers', 'Content-Type');\n\n if ('OPTIONS' == req.method) {\n res.send(200);\n } else {\n next();\n }\n }", "title": "" }, { "docid": "a3da201f5e4c2d6cf29933c90e54dc0a", "score": "0.5374168", "text": "setCORSOptions(opt = {}) {\n this.corsOptions = opt;\n }", "title": "" }, { "docid": "d97021cf9091b17e54529a53730bc68f", "score": "0.5351775", "text": "function setCors(req, res) {\n // Set CORS headers\n\tres.setHeader('Access-Control-Allow-Origin', '*');\n\tres.setHeader('Access-Control-Request-Method', '*');\n\tres.setHeader('Access-Control-Allow-Methods', 'OPTIONS, GET, POST, PUT');\n\t//res.setHeader('Access-Control-Allow-Headers', '*');\n\tif ( req.method === 'OPTIONS' ) {\n\t\tres.writeHead(200);\n\t\tres.end();\n\t\treturn;\n\t}\n\n}", "title": "" }, { "docid": "7d31aa561292b243aa7a74e4ae967d75", "score": "0.5333884", "text": "function HandleCrossDomainRequests(req, res, next) {\n res.header('Access-Control-Allow-Origin', '*');\n res.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE');\n res.header('Access-Control-Allow-Headers', 'X-Requested-With, Content-Type, Authorization');\n \n // intercept OPTIONS method\n if ('OPTIONS' == req.method) {\n res.send(204);\n }\n else {\n next();\n }\n}", "title": "" }, { "docid": "58ed85d35122ab31156369760417e27b", "score": "0.5316652", "text": "options(route, ...middleware) {\n return this._addRoute(route, middleware, \"OPTIONS\");\n }", "title": "" }, { "docid": "d2f321084045cbf443f67600dc31dc69", "score": "0.53126895", "text": "function unknownMethodHandler(req, res) {\n // handle CORS\n if (req.method.toLowerCase() === 'options') {\n log.write('on OPTIONS, origin: ' + req.headers.origin);\n //log.write(' request-hdrs: ' + req.headers['Access-Control-Request-Headers']);\n log.write(' request-hdrs: ' + JSON.stringify(req.headers, null, 2));\n // var allowedHeaders = ['Accept', 'Authorization', 'Origin', 'Referer', \n // 'User-Agent', 'X-Requested-With'];\n var allowedHeaders = ['Authorization','Content-Type','X-Requested-With'];\n //if (res.methods.indexOf('OPTIONS') === -1) res.methods.push('OPTIONS');\n\n res.header('Access-Control-Allow-Credentials', true);\n res.header('Access-Control-Allow-Headers', allowedHeaders.join(', '));\n res.header('Access-Control-Allow-Methods', 'OPTIONS, GET, POST, PUT');\n res.header('Access-Control-Allow-Origin', req.headers.origin);\n res.header('Access-Control-Max-Age', '60'); // delta seconds\n return res.send(204);\n }\n return res.send(new restify.MethodNotAllowedError());\n}", "title": "" }, { "docid": "fbed1f86c9cfaf6f9ba7b35083fb424d", "score": "0.53020585", "text": "function addAllowResponseHeader (options) {\n var f = function (request, response, next) {\n var allowed = [];\n\n if (options.head !== false) allowed.push('HEAD');\n if (options.get !== false) allowed.push('GET');\n if (options.post !== false) allowed.push('POST');\n if (options.put !== false) allowed.push('PUT');\n if (options.del !== false) allowed.push('DELETE');\n\n response.set('Allow', allowed.join(', '));\n\n next();\n };\n\n return f;\n}", "title": "" }, { "docid": "3080da421be4d5fb26b2612584360b3d", "score": "0.5276941", "text": "function unknownMethodHandler(req, res) {\n if (req.method.toLowerCase() === 'options') {\n var allowHeaders = ['Accept', 'Accept-Version', 'Content-Type', 'Api-Version', 'Origin', 'X-Requested-With', 'Authorization']; // added Origin & X-Requested-With & **Authorization**\n\n if (res.methods.indexOf('OPTIONS') === -1) res.methods.push('OPTIONS');\n\n res.header('Access-Control-Allow-Credentials', true);\n res.header('Access-Control-Allow-Headers', allowHeaders.join(', '));\n res.header('Access-Control-Allow-Methods', res.methods.join(', '));\n res.header('Access-Control-Allow-Origin', req.headers.origin);\n\n return res.send(200);\n }\n else\n return res.send(new restify.MethodNotAllowedError());\n}", "title": "" }, { "docid": "696c2edaf991f0b3490a5280e7813df3", "score": "0.52698255", "text": "function allowCrossDomain(req, res, next) {\r\n res.setHeader('Access-Control-Allow-Origin', '*');\r\n res.setHeader('Access-Control-Allow-Methods', 'PUT, GET, POST, DELETE');\r\n res.setHeader('Access-Control-Allow-Headers', 'Authorization');\r\n\r\n // end pre flights\r\n if (req.method === 'OPTIONS') {\r\n res.writeHead(204);\r\n res.end();\r\n } else {\r\n next();\r\n }\r\n}", "title": "" }, { "docid": "527018126a13055114110eb53164e848", "score": "0.52694875", "text": "function handleResponse(res, status, data) {\n res.writeHead(status, defaultCorsHeaders);\n res.end(data);\n}", "title": "" }, { "docid": "335b197b4f45bc0be33b3bb041329d38", "score": "0.523246", "text": "function doCORSRequest(options, printResult) {\n\t// In a function call the constructor and make new request x\n var x = new XMLHttpRequest();\n\t// Initialize request by call the open method of the х request, and give it parameters:\n\t//options.method - here should be(GET) and url in our case url consists of\n\t//cors_api_url + options.url where options.url is a property url of the options object, take the method (GET) also \n\t// from the options object. Remember that all object options we give to the function doCORSRequest as\n\t// an argument \n x.open(options.method, cors_api_url + options.url);\n // Call methods onload and onerror of our request х, it means that when events x.onload or x.onerror \n //is come we will perform function which just call printResult with argument x response. x.response is \n // a string with information obtained from api.\n x.onload = x.onerror = function() {\n printResult(x.response);\n };\n\n //Send request\n x.send();\n }", "title": "" }, { "docid": "305585eaf73b151a58cbeec6449c8cb9", "score": "0.50875336", "text": "async preflight() {\n return { ...this.headers, ...response.headers };\n }", "title": "" }, { "docid": "07e52bb3b1ac5c288987c585fd13928d", "score": "0.4999253", "text": "function getServerRequestOptions(method, originalUrl, options) {\n return {\n method,\n headers: {\n ...DEFAULT_HEADERS,\n ...options.body !== undefined ? { 'Content-Length': Buffer.byteLength(options.body) } : {},\n ...options.headers\n },\n timeout: options.timeout || 0,\n ...parseUrl(originalUrl),\n // auth derived from options is preferred over auth that came from URL\n ...composeAuthHeader(options.username, options.password),\n };\n}", "title": "" }, { "docid": "64bd2fde482ccec2e627d4ae90eaaf32", "score": "0.49894276", "text": "function sendResponse(req, res, options) {\n if (options && options.headers) {\n _.each(options.headers, function(value, key) {\n res.setHeader(key, value);\n });\n }\n res.setHeader('Pragma', \"no-cache\");\n res.setHeader('Cache-Control',\"no-cache, no-store, max-age=0, must-revalidate\");\n res.setHeader('Expires',\"0\");\n // if (Server.isShuttingDown()) {\n // res.setHeader('Connection', 'close');\n // }\n\n var statusCode = (options && options.statusCode) ? options.statusCode : 200;\n res.writeHead(statusCode);\n\n var body = (options && options.body) ? options.body : \"\";\n res.end(body);\n\n logResponse(req, res.statusCode, body.length);\n}", "title": "" }, { "docid": "d76cbacfc9ec83c86e1343d7980e8ebe", "score": "0.49657992", "text": "allowCors(response) {\n response.setHeader('Access-Control-Allow-Origin', '*');\n response.setHeader('Access-Control-Allow-Credentials', 'true');\n response.setHeader('Access-Control-Allow-Methods', 'GET,HEAD,OPTIONS,POST,PUT');\n response.setHeader('Access-Control-Allow-Headers', 'Access-Control-Allow-Headers, Origin,Accept, X-Requested-With, Content-Type, Access-Control-Request-Method, Access-Control-Request-Headers');\n }", "title": "" }, { "docid": "d76cbacfc9ec83c86e1343d7980e8ebe", "score": "0.49657992", "text": "allowCors(response) {\n response.setHeader('Access-Control-Allow-Origin', '*');\n response.setHeader('Access-Control-Allow-Credentials', 'true');\n response.setHeader('Access-Control-Allow-Methods', 'GET,HEAD,OPTIONS,POST,PUT');\n response.setHeader('Access-Control-Allow-Headers', 'Access-Control-Allow-Headers, Origin,Accept, X-Requested-With, Content-Type, Access-Control-Request-Method, Access-Control-Request-Headers');\n }", "title": "" }, { "docid": "8ddacadd740494dedaf678cf4ce9af3e", "score": "0.49333203", "text": "getPostOptions(url) {\n var that = this;\n if (url == '')\n url = '/sony/IRCC';\n var post_options = null;\n if (that.comp == 'true') {\n post_options = {\n host: 'closure-compiler.appspot.com',\n port: '80',\n path: url,\n method: 'POST',\n headers: {}\n };\n } else {\n post_options = {\n host: that.ip,\n port: that.port,\n path: url,\n method: 'POST',\n headers: {}\n };\n }\n if (!isNull(this.cookie)) {\n post_options.headers.Cookie = this.cookie; // = { 'Cookie': cookie };\n }\n if (!isNull(this.pwd)) {\n var encpin = 'Basic ' + base64.encode(':' + this.pwd);\n post_options.headers.Authorization = encpin; // {': encpin };\n }\n if (url == '/sony/IRCC') {\n post_options.headers['Content-Type'] = 'text/xml';\n post_options.headers.SOAPACTION = '\"urn:schemas-sony-com:service:IRCC:1#X_SendIRCC\"';\n }\n return post_options;\n }", "title": "" }, { "docid": "531809a1a1b05515e5f8f096dbe1e9a2", "score": "0.49098876", "text": "function sendResponse(proxyResponse, response, data) {\n var headers = proxyResponse.headers;\n var keys = Object.keys(headers);\n for (var i = 0; i < keys.length; i++) {\n var ignoreHeaders = ['content-length', 'content-encoding'];\n if (ignoreHeaders.indexOf(keys[i]) === -1) {\n response.setHeader(keys[i], headers[keys[i]]);\n }\n }\n response.writeHead(proxyResponse.statusCode);\n response.end(data);\n}", "title": "" }, { "docid": "98815539f94e2b9fb93f963615e55671", "score": "0.48830533", "text": "function setCors(req, res, verb) {\n let dom = this[config].cors,\n ref = req.headers['origin'] || req.headers['referer'];\n if (dom === true) {\n dom = ref || '*';\n } else if (dom instanceof Array) {\n if (!ref) {\n dom = false;\n } else {\n let found = false;\n for (let i = 0, len = dom.length; i < len; i++) {\n if (dom[i].indexOf(ref) === -1) continue;\n found = true;\n dom = dom[i];\n break;\n }\n if (!found) return;\n }\n }\n // CHECK if we have corsIgnore in settings\n let ignoreHosts;\n if (typeof this[config].corsIgnore === 'string') {\n ignoreHosts = [this[config].corsIgnore];\n } else if (this[config].corsIgnore instanceof Array) {\n ignoreHosts = this[config].corsIgnore;\n }\n if (ignoreHosts instanceof Array) {\n let origin = getRawOrigin(dom);\n for (let i = 0; i < ignoreHosts.length; i++) {\n let domain = ignoreHosts[i],\n isMatch = matchCorsOrigin(domain, origin, dom);\n if (isMatch) return;\n }\n }\n if (!dom) return;\n res.header('Access-Control-Allow-Origin', getCleanOrigin(dom));\n res.header('Access-Control-Allow-Methods', CORS_METHODS);\n res.header('Access-Control-Allow-Credentials', 'true');\n res.header('Access-Control-Allow-Headers', req.headers['access-control-request-headers'] || '*');\n res.header('Access-Control-Max-Age', '600');\n }", "title": "" }, { "docid": "60b2e5c70b980b6f361feb39d20c7426", "score": "0.48419833", "text": "prepareRequest(options) {\n options.headers['Authorization'] = 'Basic ' + new Buffer(this.username + ':' + this.password).toString('base64');\n options.headers['X-TFS-FedAuthRedirect'] = 'Suppress';\n }", "title": "" }, { "docid": "5dc0571b2478aaeb062bb633a21eccfc", "score": "0.48303953", "text": "enableCors(originDomain, opt) {\n this.cors = {\n credentials: true\n };\n if (typeof originDomain === 'string') { // remove any trailing /\n let corsDomain;\n if (originDomain.indexOf('://') !== -1) {\n let tmp = originDomain.split('//');\n corsDomain = tmp[0] + '//';\n tmp[1] = tmp[1].split('/')[0];\n corsDomain += tmp[1];\n } else {\n corsDomain = originDomain.split('/')[0];\n }\n this.cors.domain = corsDomain;\n }\n if (typeof originDomain === 'object') opt = originDomain;\n if (typeof opt === 'object' && opt) {\n if (opt.credentials === false) {\n this.cors.credentials = false;\n } else {\n this.cors.credentials = true;\n }\n }\n return this;\n }", "title": "" }, { "docid": "69902ae45c90c385c9f5dae5e70a7dbb", "score": "0.48092607", "text": "function setResponse(data) {\n\n return {\n statusCode: 200,\n headers: {\n \"Access-Control-Allow-Origin\": \"*\",\n \"Some-Random-Header\": \"OKDOKE\"\n // \"Access-Control-Allow-Credentials\" : true // Required for cookies, authorization headers with HTTPS\n },\n body: JSON.stringify(data)\n };\n\n}", "title": "" }, { "docid": "1e3f8ab6447f1aa53941f7ca3a4e69d9", "score": "0.47904405", "text": "getRequestOpts(opt) {\n return Object.assign({\n method: \"GET\"\n }, opt, {\n path: url.resolve(\"/kapacitor/v1/\", opt.path)\n });\n }", "title": "" }, { "docid": "8e21022923706f740cdf7d3dc8ba3c8b", "score": "0.4782032", "text": "function makeRequest (options, sendResponse) {\n $.ajax(options).then((data, textStatus, jqXHR) => {\n jqXHR.allResponseHeaders = makeHeaderObject(jqXHR.getAllResponseHeaders());\n sendResponse({data, textStatus, jqXHR});\n }, (jqXHR, textStatus, errorThrown) => {\n jqXHR.allResponseHeaders = makeHeaderObject(jqXHR.getAllResponseHeaders());\n sendResponse({jqXHR, textStatus, errorThrown});\n });\n}", "title": "" }, { "docid": "c7bcf969fa6d774fbdf58f5505b7a2e3", "score": "0.4778899", "text": "options() {\n\t\tthis.ctx.status = 200;\n\t\tthis.render();\n\t}", "title": "" }, { "docid": "b34cb0a340d235a0120749069ff78e6f", "score": "0.47773463", "text": "send(options) {\r\n options.method = (options.method || 'GET').toUpperCase();\r\n\r\n // if the given data is a jquery element\r\n // then we will assume it is a jquery form element\r\n\r\n // because PATCH and PUT requests don't accept form data\r\n // so it will be exclusively to POST request\r\n if (['POST', 'PUT', 'PATCH'].includes(options.method)) {\r\n // a fix for sending form-data to back-end if the request method is PUT\r\n // as uploading files is not supported in the PUT requests\r\n if (options.method == 'PUT') {\r\n let uploadablePut = typeof options.uploadablePut != 'undefined' ? options.uploadablePut : (this.options.uploadablePut);\r\n if (uploadablePut) {\r\n options.method = 'POST';\r\n if (Is.formHandler(options.data)) {\r\n options.data.set('_method', 'PUT');\r\n } else if (Is.object(options.data)) {\r\n options.data._method = 'PUT';\r\n }\r\n }\r\n }\r\n\r\n if (!Is.empty(options.data) && (Is.jquery(options.data) || Is.formHandler(options.data))) {\r\n options.data = new FormData(options.data[0]);\r\n options.cache = false;\r\n options.processData = false;\r\n options.contentType = false;\r\n }\r\n\r\n }\r\n\r\n if (this.events.trigger('http.loading', options.url, options) === false) return;\r\n\r\n if (options.progress) {\r\n ajaxOptions.xhr = () => {\r\n var xhr = new window.XMLHttpRequest();\r\n xhr.upload.addEventListener(\"progress\", (evt) => {\r\n if (evt.lengthComputable && options.progress) {\r\n var percentComplete = evt.loaded / evt.total;\r\n /* Do something with upload progress here */\r\n if (options.progress) {\r\n options.progress(percentComplete);\r\n }\r\n }\r\n }, false);\r\n return xhr;\r\n };\r\n }\r\n\r\n // echo(options);\r\n\r\n let jqXHR = $.ajax(options);\r\n\r\n return new Promise((resolve, reject) => {\r\n jqXHR.then(resolve).catch((xhr, statusText, errorThrown) => {\r\n let response = xhr.responseJSON || xhr.responseText;\r\n reject(response, xhr.status, errorThrown, statusText, xhr);\r\n });\r\n });\r\n }", "title": "" }, { "docid": "14f13cf1526f77ce09f5444d60b9c085", "score": "0.47601235", "text": "setProxyOptions() {\n if (this.proxy instanceof HTMLSelectElement && this.options) {\n this.proxy.options.length = 0;\n this.options.forEach(option => {\n const proxyOption = option.proxy ||\n (option instanceof HTMLOptionElement ? option.cloneNode() : null);\n if (proxyOption) {\n this.proxy.appendChild(proxyOption);\n }\n });\n }\n }", "title": "" }, { "docid": "e7de9b66cf99a9d4db7e55ee12f403ee", "score": "0.47040957", "text": "prepareRequest(options) {\n options.headers['Authorization'] = 'Bearer ' + this.token;\n options.headers['X-TFS-FedAuthRedirect'] = 'Suppress';\n }", "title": "" }, { "docid": "bd4a31cebeb5213bf694237c9a8160f7", "score": "0.4696486", "text": "proxyReqOptDecorator(options) {\n options.headers['x-forwarded-host'] = 'localhost:3000';\n\n return options;\n }", "title": "" }, { "docid": "4bdb36497e62fb378345a25954eeb7b0", "score": "0.46862605", "text": "sendResponse() {\n this.res.status(this.resp.status).send(this.resp);\n }", "title": "" }, { "docid": "1061ee1c8935b301d4fbccd813fb0076", "score": "0.46831727", "text": "function makeCorsRequest(form) {\n// var url = 'http://34.249.146.67:4242';\n// const data = new FormData(form);\n// var xhr = createCORSRequest('POST', url);\n// if (!xhr) {\n// return;\n// }\n \n // Response handlers.\n xhr.onload = function() {\n var text = xhr.responseText;\n showResponse(text)\n //alert('Response from CORS request to ' + url);\n };\n\n xhr.onerror = function() {\n alert('Woops, there was an error making the request.');\n };\n xhr.send(data);\n}", "title": "" }, { "docid": "56d91cf43be524d3f57750d587c69ba0", "score": "0.46654776", "text": "prepareRequest(options) {\n options.headers['Authorization'] = 'Basic ' + new Buffer('PAT:' + this.token).toString('base64');\n options.headers['X-TFS-FedAuthRedirect'] = 'Suppress';\n }", "title": "" }, { "docid": "ffa80d13b5dec6aacd0b6a9121c4166d", "score": "0.466372", "text": "function createOptions(content) {\n var options = {\n host: settings.host,\n port: settings.port,\n headers: {\n 'Authorization' : 'Basic ' + new Buffer(settings.username + ':' + settings.password).toString('base64'),\n 'Content-Type': 'application/json'\n }\n };\n\n options.path = '/api/2/project/' + settings.project_slug + '/resource/' + settings.resource_slug + '/content';\n options.method = 'PUT';\n options.data = JSON.stringify({\n content: JSON.stringify(content)\n });\n\n options.headers['Content-Length'] = Buffer.byteLength(options.data);\n return options;\n}", "title": "" }, { "docid": "9196c4e5e3f469830277284cf6dea971", "score": "0.46514297", "text": "prepareRequest(options) {\n options.headers['Authorization'] = 'Bearer ' + this.token;\n }", "title": "" }, { "docid": "9196c4e5e3f469830277284cf6dea971", "score": "0.46514297", "text": "prepareRequest(options) {\n options.headers['Authorization'] = 'Bearer ' + this.token;\n }", "title": "" }, { "docid": "9196c4e5e3f469830277284cf6dea971", "score": "0.46514297", "text": "prepareRequest(options) {\n options.headers['Authorization'] = 'Bearer ' + this.token;\n }", "title": "" }, { "docid": "76e7417037aba54435efb0ab1785d5c5", "score": "0.46389377", "text": "@api\n get options() {\n return this._options;\n }", "title": "" }, { "docid": "ba28dc660b6f48feeb070ed440d5dc54", "score": "0.46009156", "text": "function https(options, formData) {\n DEBUG_LOG('\\n\\n\\n\\n');\n DEBUG_LOG('>>> request:\\n' + options.method + ': ' + options.hostname + options.path);\n\n options = options || {};\n options.headers = options.headers || {};\n\n formData = formData || [];\n\n var data = form.getData(formData);\n\n options.headers['Content-Type'] = data.contentType;\n\n if (options.method !== 'GET') {\n options.headers['Content-Length'] = data.contentLength;\n }\n\n DEBUG_LOG('\\n>>> request headers\\n', options.headers);\n\n // stick the data at the end of the url for GET requests\n if (options.method === 'GET' && data.buffer.toString() !== '') {\n DEBUG_LOG('\\n>>> query string:\\n', data.buffer.toString());\n options.path += '?' + data.buffer.toString();\n }\n\n return _when2['default'].promise(function (resolve, reject) {\n\n var req = _https2['default'].request(options, function (res) {\n\n res._req = req; // attach a reference back to the request\n\n res.setEncoding('utf8');\n var body = '';\n res.on('error', function (error) {\n return reject(error);\n });\n res.on('data', function (chunk) {\n body += chunk;\n });\n res.on('end', function () {\n res._body = body; // attach the response body to the object\n res._status = res.statusCode;\n res._headers = res.headers;\n DEBUG_LOG('\\n>>> response headers:\\n', res._headers);\n DEBUG_LOG('\\n>>> response body:\\n', String(body).substring(0, 1000));\n DEBUG_LOG('\\n>>> status:\\n', res.statusCode);\n return resolve(res);\n });\n });\n\n req.on('error', function (error) {\n return reject(error);\n });\n\n if (options.method !== 'GET') {\n DEBUG_LOG('\\n>>> request body:\\n', data.buffer.toString());\n req.write(data.buffer);\n }\n\n req.end();\n }).then(function (res) {\n var canRedirect = String(res._status).substring(0, 1) === '3' && typeof res._headers.location !== 'undefined';\n\n if (canRedirect) {\n // Make the call again with the new hostname, path, and form data\n var parsed = _url2['default'].parse(res._headers.location);\n options.hostname = parsed.hostname;\n options.path = parsed.pathname;\n return https(options, parsed.query);\n }\n\n return res;\n });\n}", "title": "" }, { "docid": "669a35edcff1ce33e4d2b65b0c81b1fa", "score": "0.45994172", "text": "constructor(options = {})\n\t{\n\t\tconst { secure, host, port, headers, clone_request } = options\n\n\t\t// For those who don't wish to proxy API requests to API servers\n\t\t// and prefer to query those API servers directly (for whatever reasons).\n\t\t// Direct API calls will contain user's cookies (e.g. JWT token).\n\t\tconst format_url = options.format_url || this.format_url.bind(this)\n\n\t\t// Clone HTTP request cookies on the server-side\n\t\t// (to make authentication work)\n\t\tif (clone_request)\n\t\t{\n\t\t\tthis.server = true\n\t\t\tthis.cookies = clone_request.headers.cookie\n\t\t}\n\t\t\n\t\tthis.host = host\n\t\tthis.port = port || 80\n\t\tthis.secure = secure\n\n\t\tthis.on_before_send_listeners = []\n\n\t\tconst http_methods =\n\t\t[\n\t\t\t'get',\n\t\t\t'post',\n\t\t\t'put',\n\t\t\t'patch',\n\t\t\t'delete',\n\t\t\t'head',\n\t\t\t'options'\n\t\t]\n\n\t\t// Define HTTP methods on this instance\n\t\tfor (let method of http_methods)\n\t\t{\n\t\t\tthis[method] = (path, data, options = {}) =>\n\t\t\t{\n\t\t\t\t// `url` will be absolute for server-side\n\t\t\t\tconst url = format_url(path, this.server)\n\n\t\t\t\treturn new Promise((resolve, reject) =>\n\t\t\t\t{\n\t\t\t\t\t// Create Http request\n\t\t\t\t\tconst agent = this.server ? superagent.agent() : superagent\n\t\t\t\t\tconst request = agent[method](url)\n\n\t\t\t\t\t// Attach data to the outgoing HTTP request\n\t\t\t\t\tif (data)\n\t\t\t\t\t{\n\t\t\t\t\t\tswitch (method)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tcase 'get':\n\t\t\t\t\t\t\t\trequest.query(data)\n\t\t\t\t\t\t\t\tbreak\n\n\t\t\t\t\t\t\tcase 'post':\n\t\t\t\t\t\t\tcase 'put':\n\t\t\t\t\t\t\tcase 'patch':\n\t\t\t\t\t\t\tcase 'head':\n\t\t\t\t\t\t\tcase 'options':\n\t\t\t\t\t\t\t\trequest.send(data)\n\t\t\t\t\t\t\t\tbreak\n\n\t\t\t\t\t\t\tcase 'delete':\n\t\t\t\t\t\t\t\tthrow new Error(`\"data\" supplied for HTTP DELETE request: ${JSON.stringify(data)}`)\n\n\t\t\t\t\t\t\tdefault:\n\t\t\t\t\t\t\t\tthrow new Error(`Unknown HTTP method: ${method}`)\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\t// Server side only\n\t\t\t\t\t// (copies user authentication cookies to retain session specific data)\n\t\t\t\t\tif (this.cookies)\n\t\t\t\t\t{\n\t\t\t\t\t\trequest.set('cookie', this.cookies)\n\t\t\t\t\t}\n\n\t\t\t\t\t// Apply default HTTP headers\n\t\t\t\t\tif (headers)\n\t\t\t\t\t{\n\t\t\t\t\t\trequest.set(headers)\n\t\t\t\t\t}\n\n\t\t\t\t\t// Apply this HTTP request specific HTTP headers\n\t\t\t\t\tif (options.headers)\n\t\t\t\t\t{\n\t\t\t\t\t\trequest.set(options.headers)\n\t\t\t\t\t}\n\n\t\t\t\t\t// // Set HTTP locale header\n\t\t\t\t\t// // (for example, for getting localized response)\n\t\t\t\t\t// if (options.locale)\n\t\t\t\t\t// {\n\t\t\t\t\t// \trequest.set('accept-language', options.locale)\n\t\t\t\t\t// }\n\n\t\t\t\t\t// Apply custom adjustments to HTTP request\n\t\t\t\t\tfor (let listener of this.on_before_send_listeners)\n\t\t\t\t\t{\n\t\t\t\t\t\tlistener(request)\n\t\t\t\t\t}\n\n\t\t\t\t\t// Send HTTP request\n\t\t\t\t\trequest.end((error, response) => \n\t\t\t\t\t{\n\t\t\t\t\t\t// this turned out to be a lame way of handling cookies,\n\t\t\t\t\t\t// because cookies are sent in request \n\t\t\t\t\t\t// with no additional parameters\n\t\t\t\t\t\t// such as `path`, `httpOnly` and `expires`,\n\t\t\t\t\t\t// so there were cookie duplication issues.\n\t\t\t\t\t\t//\n\t\t\t\t\t\t// now superagent.agent() handles cookies correctly.\n\t\t\t\t\t\t//\n\t\t\t\t\t\t// if (response)\n\t\t\t\t\t\t// {\n\t\t\t\t\t\t// \tif (response.get('set-cookie'))\n\t\t\t\t\t\t// \t{\n\t\t\t\t\t\t// \t\tthis.cookies = response.get('set-cookie')\n\t\t\t\t\t\t// \t}\n\t\t\t\t\t\t// }\n\n\t\t\t\t\t\t// If there was an error, then reject the Promise\n\t\t\t\t\t\tif (error)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\t// `superagent` would have already output the error to console\n\t\t\t\t\t\t\t// console.error(error.stack)\n\n\t\t\t\t\t\t\t// console.log('[react-isomorphic-render] (http request error)')\n\n\t\t\t\t\t\t\t// Infer additional `error` properties from the HTTP response\n\t\t\t\t\t\t\tif (response)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t// Set `error.status` to HTTP response status code\n\t\t\t\t\t\t\t\terror.status = response.statusCode\n\n\t\t\t\t\t\t\t\tswitch (response.type)\n\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t// Set error `data` from response body,\n\t\t\t\t\t\t\t\t\tcase 'application/json':\n\t\t\t\t\t\t\t\t\t\t// if (!is_object(error.data))\n\t\t\t\t\t\t\t\t\t\terror.data = parse_dates(response.body)\n\n\t\t\t\t\t\t\t\t\t\t// Set the more meaningful message for the error (if available)\n\t\t\t\t\t\t\t\t\t\tif (error.data.message)\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\terror.message = error.data.message\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tbreak\n\n\t\t\t\t\t\t\t\t\t// If the HTTP response was not a JSON object,\n\t\t\t\t\t\t\t\t\t// but rather a text or an HTML page,\n\t\t\t\t\t\t\t\t\t// then include that information in the `error`\n\t\t\t\t\t\t\t\t\t// for future reference (e.g. easier debugging).\n\n\t\t\t\t\t\t\t\t\tcase 'text/plain':\n\t\t\t\t\t\t\t\t\t\terror.message = response.text\n\t\t\t\t\t\t\t\t\t\tbreak\n\n\t\t\t\t\t\t\t\t\tcase 'text/html':\n\t\t\t\t\t\t\t\t\t\terror.html = response.text\n\n\t\t\t\t\t\t\t\t\t\t// Recover the original error message (if any)\n\t\t\t\t\t\t\t\t\t\tif (response.headers['x-error-message'])\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\terror.message = response.headers['x-error-message']\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\t// Recover the original error stack trace (if any)\n\t\t\t\t\t\t\t\t\t\tif (response.headers['x-error-stack-trace'])\n\t\t\t\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\t\t\t\terror.stack = JSON.parse(response.headers['x-error-stack-trace'])\n\t\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t\tbreak\n\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t// HTTP request failed with an `error`\n\t\t\t\t\t\t\treturn reject(error)\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// HTTP request completed without errors,\n\t\t\t\t\t\t// so return the HTTP response data.\n\n\t\t\t\t\t\t// If HTTP response status is \"204 - No content\"\n\t\t\t\t\t\t// (e.g. PUT, DELETE)\n\t\t\t\t\t\t// then resolve with an empty result\n\t\t\t\t\t\tif (response.statusCode === 204)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\treturn resolve()\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Else, the result is HTTP response body\n\t\t\t\t\t\tresolve(parse_dates(response.body))\n\t\t\t\t\t})\n\t\t\t\t})\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "44b406f09ff7d0c6908ec909c1346caa", "score": "0.45971927", "text": "_httpClientOptions(options) {\n return options;\n }", "title": "" }, { "docid": "7336f422985d97c86bf45e822ab2e936", "score": "0.45967206", "text": "function allowXDM(req, res, next) {\n var aca = 'Access-Control-Allow-'\n , xf = function(s){ return 'X-File-'+s }\n\n res.header(aca + 'Origin', config.allow_origin)\n res.header(aca + 'Credentials', true)\n res.header(aca + 'Methods', 'POST, GET, PUT, OPTIONS')\n res.header(aca + 'Headers', ['Content-Type', xf('Name'), xf('Type'), xf('Size')])\n\n next()\n}", "title": "" }, { "docid": "0f2dba222b625816f2e86ba6a6e397c2", "score": "0.45788825", "text": "function CORS(req, res, next) {\n res.header('Access-Control-Allow-Origin', '*');\n res.header('Access-Control-Allow-Methods', 'PUT, GET, HEAD, POST, DELETE, OPTIONS');\n res.header('Access-Control-Allow-Headers', 'Origin, X-Requested-With, X-Api-Token, Content-Type, Accept, Authorization, Access-Control-Allow-Credentials');\n res.header('Access-Control-Allow-Credentials', 'true');\n next();\n}", "title": "" }, { "docid": "083d26dcdef3de55db35750b644d7a9b", "score": "0.45736706", "text": "function prepareRequestOptions(req, loggingOptions) {\n connectorProxy = req.body['connector-proxy-request'];\n \n username = connectorProxy['user-name'];\n password = connectorProxy['password'];\n url = connectorProxy['url'];\n method = connectorProxy['method'];\n \n loggingOptions.callouts_data.request_body = JSON.stringify(req.body);\n loggingOptions.callouts_data.url = url;\n loggingOptions.callouts_data.method = method;\n \n if (method == null || method == '') {\n method = 'GET';\n }\n method = method.toUpperCase();\n\n // parse the URL for the actual parameters\n urlParams = parseUrl(url);\n\n validate.validateSendRequestInput(username, password, url, method);\n \n var requestOptions = {\n host: urlParams['host'],\n path: urlParams['path'],\n method: method,\n headers: {\n 'Authorization': 'Basic ' + new Buffer(username + ':' + password).toString('base64')\n }\n };\n \n if (urlParams['port'] != null) {\n requestOptions['port'] = urlParams['port'];\n }\n\n return requestOptions;\n}", "title": "" }, { "docid": "d32d7b8c40fcc53b4e94f76af795d1cc", "score": "0.45629358", "text": "function cors(opts) {\n assert.optionalObject(opts, 'options');\n opts = opts || {};\n assert.optionalArrayOfString(opts.origins, 'options.origins');\n assert.optionalBool(opts.credentials, 'options.credentials');\n assert.optionalArrayOfString(opts.headers, 'options.headers');\n\n var headers = (opts.headers || []).slice(0);\n// var origins = opts.origins || ['*'];\n\n EXPOSE_HEADERS.forEach(function (h) {\n if (headers.indexOf(h) === -1)\n headers.push(h);\n });\n\n // Handler for simple requests\n function restifyCORSSimple(req, res, next) {\n var origin;\n var origins;\n if(req.customer) {\n console.log('==============req.customer.origins: ', req.customer.origins)\n origins = req.customer.origins || [''];\n if(_.isString(origins)){\n origins = origins.replace(/\\s+/g, '');\n console.log('==========origins after replace: ', origins);\n origins = origins.split(';').toString().split(',');\n console.log('==========origins post processing: ', origins);\n }\n }\n else\n origins = ['']\n\n if (!(origin = matchOrigin(req, origins))) {\n console.log('==============matchOrigin req.badCors: ', req.badCors)\n console.log(\"==============req.headers['origin']: \", req.headers['origin'])\n\n var regexp = /http[s]?:\\/\\//;\n var isAjax = regexp.test(req.headers['origin']);\n\n if(isAjax) {\n console.log('isAjax: ', isAjax);\n req.badCors = true;\n }\n else {\n console.log('isAjax: ', isAjax);\n }\n\n///--- Alternative check isAjax\n\n// if( !_.isUndefined(req.headers['origin']) ) {\n// console.log('isAjax: ', isAjax);\n// req.badCors = true;\n// }\n// else {\n// console.log('isAjax: ', isAjax);\n// }\n\n\n next();\n return;\n }\n\n function corsOnHeader() {\n origin = req.headers['origin'];\n if (opts.credentials) {\n res.setHeader(AC_ALLOW_ORIGIN, origin);\n res.setHeader(AC_ALLOW_CREDS, 'true');\n } else {\n res.setHeader(AC_ALLOW_ORIGIN, origin);\n }\n\n res.setHeader(AC_EXPOSE_HEADERS, headers.join(', '));\n }\n\n res.once('header', corsOnHeader);\n next();\n }\n\n return (restifyCORSSimple);\n}", "title": "" }, { "docid": "d57ef7c5a310d24f89dfc81e4573e958", "score": "0.45614526", "text": "enableOption() {\n if (!this.checked) {\n this.$store.commit(UNSELECT_API_PARAM, this.apiParam.name());\n } else {\n this.updateOption(this.optionValue());\n }\n\n this.clearCurrentResults();\n }", "title": "" }, { "docid": "e4c381d9e01d0eb2418866653d687eb2", "score": "0.45536754", "text": "sendRequest(method, options)\n {\n debug('sendRequest()');\n\n return this._dialog.sendRequest(method, options);\n }", "title": "" }, { "docid": "e4c381d9e01d0eb2418866653d687eb2", "score": "0.45536754", "text": "sendRequest(method, options)\n {\n debug('sendRequest()');\n\n return this._dialog.sendRequest(method, options);\n }", "title": "" }, { "docid": "18ff71dd35281c13efba61cdcd8e2047", "score": "0.45449504", "text": "accepted(res, data) {\r\n this.send(res, data, 202);\r\n }", "title": "" }, { "docid": "8c0d8ecec816f63747f7c6a64c5f95ea", "score": "0.45436117", "text": "function sendRequest(path, data, onResponse=res => {}) {\n axios.post(path, data, {baseURL: config.url, withCredentials: true}).then(res => onResponse(res));\n}", "title": "" }, { "docid": "0092e0e03c3ea0619efc24b78cf5dd01", "score": "0.45270848", "text": "send(options) {\n this.setDefaults(options)\n return this.transport()\n }", "title": "" }, { "docid": "244197190cc41cff53a55e3f6537b90a", "score": "0.45239055", "text": "function method(request,next){if(request.emulateHTTP&&/^(PUT|PATCH|DELETE)$/i.test(request.method)){request.headers['X-HTTP-Method-Override']=request.method;request.method='POST';}next();}", "title": "" }, { "docid": "4649f107d34dae211820536938b5031a", "score": "0.4521444", "text": "get options() {\n return this._options;\n }", "title": "" }, { "docid": "776cec4305e56cf54802a994eba21550", "score": "0.45138603", "text": "_handleOptions(modified, current) {\n // Automatically add the service host itself to the list of exclusions\n // to avoid reporting on the reports themselves\n let serviceHost = modified.collector_host;\n if (serviceHost) {\n this._addServiceHostToExclusions(current);\n }\n\n // Set up the proxied fetch calls unless disabled\n if (!this._proxyInited && current.fetch_instrumentation) {\n this._proxyInited = true;\n window.fetch = this._instrumentFetch();\n }\n }", "title": "" }, { "docid": "e03c130ce5e87cf9f260ecd2a0204b03", "score": "0.44947332", "text": "_getOptions(method, path, json) {\n // get default params of pagination in correct order\n // limit and offset could be configured in json as well.\n const {\n searchParams,\n pagination = this.pagination,\n ...queryOptions\n } = (json || {});\n const limit = (pagination && pagination.limit)\n || (json && json.limit) || this.limit\n || (pagination && DEFAULTPAGINATIONLIMIT);\n const offset = (pagination && pagination.offset)\n || (json && json.offset) || 0;\n if (pagination) {\n pagination.backoff = pagination.backoff || DEFAULTPAGINATIONBACKOFF;\n pagination.countLimit = pagination.countLimit || DEFAULTPAGINATIONCOUNTLIMIT;\n }\n // With pagination, only queryOptions should be passed as querystring (see 1)\n const querystring = method === 'GET' && json ? `?${buildQs(pagination ? queryOptions : json)}` : '';\n // String path is relative, urls passed as URL object are absolute\n const options = {\n method,\n responseType: 'json',\n url: typeof path === 'string' ? `v2/${path}${querystring}` : path.toString()\n };\n if (typeof path === 'string') {\n options.prefixUrl = this.host;\n }\n debug('using options:', JSON.stringify(options));\n if (['POST', 'PATCH'].includes(method)) {\n options.json = json;\n }\n if (pagination && method === 'GET') {\n // (1) Because with pagination all options go into searchParams\n options.searchParams = buildQs({ ...searchParams, ...queryOptions, limit, offset });\n // Setup pagination\n options.pagination = {\n ...pagination,\n paginate: response => {\n // Run got's paginate\n let newOptions;\n try {\n newOptions = this.fetch.defaults\n .options.pagination.paginate(response);\n } catch (ep) {\n // no pagination\n return false;\n }\n // Update searchParams\n if (newOptions) {\n debug('next: ', newOptions.url.href);\n newOptions.searchParams = newOptions.url.searchParams;\n }\n return newOptions;\n }\n };\n debug('using pagination options:', JSON.stringify(options.pagination));\n }\n return options;\n }", "title": "" }, { "docid": "5cfefbbc6c8cf7ef16c3dcafd3eeefae", "score": "0.44820738", "text": "function method(request,next){if(request.emulateHTTP&&/^(PUT|PATCH|DELETE)$/i.test(request.method)){request.headers.set('X-HTTP-Method-Override',request.method);request.method='POST';}next();}", "title": "" }, { "docid": "617354e6a90a94b0fedf519f0899b088", "score": "0.44800752", "text": "makeOptions(method, addToken, body) {\n var opts = {\n method: method,\n headers: {\n \"Content-type\": \"application/json\",\n 'Accept': 'application/json',\n }\n }\n if (addToken && this.loggedIn()) {\n opts.headers[\"x-access-token\"] = this.getToken();\n }\n if (body) {\n opts.body = JSON.stringify(body);\n }\n return opts;\n }", "title": "" }, { "docid": "9d76df10ca1e4698c643fe9aadc72846", "score": "0.447753", "text": "get options() {\n return this._options;\n }", "title": "" }, { "docid": "9d76df10ca1e4698c643fe9aadc72846", "score": "0.447753", "text": "get options() {\n return this._options;\n }", "title": "" }, { "docid": "9d76df10ca1e4698c643fe9aadc72846", "score": "0.447753", "text": "get options() {\n return this._options;\n }", "title": "" }, { "docid": "3617b502414f69c7b995da994fac8466", "score": "0.44643205", "text": "function method (request, next) {\n\t\n\t if (request.emulateHTTP && /^(PUT|PATCH|DELETE)$/i.test(request.method)) {\n\t request.headers['X-HTTP-Method-Override'] = request.method;\n\t request.method = 'POST';\n\t }\n\t\n\t next();\n\t}", "title": "" }, { "docid": "3ad73f2e03b82f5d37d99caf6028323f", "score": "0.44525948", "text": "function cors(req, res, next){\n res.header(\"Access-Control-Allow-Origin\", \"*\");\n \tres.header(\"Access-Control-Allow-Headers\", \"Origin, X-Requested-With, Content-Type, Accept\");\n \tres.header(\"Access-Control-Allow-Methods\", \"GET,POST,DELETE,OPTIONS,PUT\");\n \tnext();\n}", "title": "" }, { "docid": "3ad73f2e03b82f5d37d99caf6028323f", "score": "0.44525948", "text": "function cors(req, res, next){\n res.header(\"Access-Control-Allow-Origin\", \"*\");\n \tres.header(\"Access-Control-Allow-Headers\", \"Origin, X-Requested-With, Content-Type, Accept\");\n \tres.header(\"Access-Control-Allow-Methods\", \"GET,POST,DELETE,OPTIONS,PUT\");\n \tnext();\n}", "title": "" }, { "docid": "3ad73f2e03b82f5d37d99caf6028323f", "score": "0.44525948", "text": "function cors(req, res, next){\n res.header(\"Access-Control-Allow-Origin\", \"*\");\n \tres.header(\"Access-Control-Allow-Headers\", \"Origin, X-Requested-With, Content-Type, Accept\");\n \tres.header(\"Access-Control-Allow-Methods\", \"GET,POST,DELETE,OPTIONS,PUT\");\n \tnext();\n}", "title": "" }, { "docid": "084c950693134d921f6e4f7d2034c0e6", "score": "0.44413525", "text": "async function updateOption(req, res) {\n try {\n const optionList = await service.updateOption(req.body);\n return res.status(200).json({\n success: true,\n message: ''\n });\n } catch (e) {\n res.status(400).json({ Error: e.message })\n }\n}", "title": "" }, { "docid": "4f2a35baf48c31111d95a0f9ab9a1607", "score": "0.44370863", "text": "request(url, options) {\n return Bluebird\n .resolve(this.mergeOptions(options))\n .then((options) => {\n return this.$http.request(url, this.requestOptions(options, url));\n })\n .tap(v => {\n /*\n console.dir({\n url,\n v,\n });\n */\n });\n }", "title": "" }, { "docid": "5dfa9e4728e1a35588f8f25eab2aeae5", "score": "0.44200835", "text": "allowedMethods(options = {}) {\n const implemented = this._methods;\n return async function allowedMethods(context, next) {\n await next();\n const allowed = new Set();\n if (!context.response.status ||\n context.response.status === deps_ts_7.Status.NotFound) {\n const contextRoutesMatched = contextRouteMatches.get(context);\n if (contextRoutesMatched) {\n for (const layer of contextRoutesMatched) {\n for (const method of layer.methods) {\n allowed.add(method);\n }\n }\n }\n const allowedValue = Array.from(allowed).join(\", \");\n if (!implemented.includes(context.request.method)) {\n if (options.throw) {\n let notImplementedThrowable;\n if (typeof options.notImplemented === \"function\") {\n notImplementedThrowable = options.notImplemented();\n }\n else {\n notImplementedThrowable = new NotImplemented();\n }\n throw notImplementedThrowable;\n }\n else {\n context.response.status = deps_ts_7.Status.NotImplemented;\n context.response.headers.set(\"Allow\", allowedValue);\n }\n }\n else if (allowed.size) {\n if (context.request.method === \"OPTIONS\") {\n context.response.status = deps_ts_7.Status.OK;\n context.response.body = \"\";\n context.response.headers.set(\"Allow\", allowedValue);\n }\n else if (!allowed.has(context.request.method)) {\n if (options.throw) {\n let notAllowedThrowable;\n if (typeof options.methodNotAllowed === \"function\") {\n notAllowedThrowable = options.methodNotAllowed();\n }\n else {\n notAllowedThrowable = new MethodNotAllowed();\n }\n throw notAllowedThrowable;\n }\n else {\n context.response.status = deps_ts_7.Status.MethodNotAllowed;\n context.response.headers.set(\"Allow\", allowedValue);\n }\n }\n }\n }\n };\n }", "title": "" }, { "docid": "77733b9bef1a2b35648b1d566f6fa874", "score": "0.4418786", "text": "prepareRequest(options) {\n options.headers['Authorization'] =\n 'Basic ' + Buffer.from('PAT:' + this.token).toString('base64');\n }", "title": "" }, { "docid": "77733b9bef1a2b35648b1d566f6fa874", "score": "0.4418786", "text": "prepareRequest(options) {\n options.headers['Authorization'] =\n 'Basic ' + Buffer.from('PAT:' + this.token).toString('base64');\n }", "title": "" }, { "docid": "77733b9bef1a2b35648b1d566f6fa874", "score": "0.4418786", "text": "prepareRequest(options) {\n options.headers['Authorization'] =\n 'Basic ' + Buffer.from('PAT:' + this.token).toString('base64');\n }", "title": "" }, { "docid": "8b4496f63f3af03ea8fc6bea4a07a6ce", "score": "0.44086674", "text": "function addHeaders(options, config) {\n const { method } = options\n const { data } = config\n let headers\n\n if (method == \"GET\" || method == \"DELETE\") {\n headers = Headers.URLENCODED\n } else {\n if (typeof data == \"object\" && !(data instanceof FormData)) {\n headers = Headers.JSON\n } else if (typeof data == \"string\") {\n try {\n JSON.parse(data)\n headers = Headers.JSON\n } catch (e) {\n headers = Headers.PLAIN\n }\n }\n }\n\n if (headers) options.headers = { ...headers, ...options.headers }\n\n return options\n}", "title": "" }, { "docid": "240bc2d45fda9fbb62d7a9a3d6b697a3", "score": "0.43972492", "text": "setOptOut(path, optOutOn, onSuccess, onError) {\n let endpoint = BASE_URL + path + \"/\" + optOutOn + \"/setOptOut\";\n dataProvider.updateData(endpoint, onSuccess, onError);\n }", "title": "" }, { "docid": "31ab9f7493f72352945e62a9991d3a25", "score": "0.43968374", "text": "function requestOptions(cmd, options) {\n options = options || {};\n\n if(!('strictSSL' in options)) {\n options.strictSSL = !cmd.insecure;\n }\n\n // FIXME: document followRedirct option\n if(!('followRedirect' in options)) {\n options.followRedirect = true;\n }\n\n // FIXME: document maxRedirects option\n if(!('maxRedirects' in options)) {\n // Handle \"--max-redirs 0\" as followRedirect = false\n if(cmd.maxRedirs === 0) {\n options.followRedirect = false;\n }\n else {\n options.followRedirect = cmd.maxRedirs;\n }\n }\n\n // set httpSignature key and keyId from config\n if(options._httpSignatureFromConfig) {\n var cfg = options._httpSignatureFromConfig;\n delete options._httpSignatureFromConfig;\n options.httpSignature = options.httpSignature || {};\n options.httpSignature.keyId = cfg.publicKey.id;\n options.httpSignature.key = cfg.publicKey.privateKeyPem;\n }\n\n // FIXME: add noAuth option to skip this\n // if using http signature, add default headers if none specified\n if(options.httpSignature && !options.httpSignature.headers) {\n options.httpSignature = options.httpSignature || {};\n options.httpSignature.headers = ['request-line', 'host', 'date'];\n }\n\n return options;\n}", "title": "" }, { "docid": "8902741acf112eeb4faf7e9fe6e87d33", "score": "0.43913996", "text": "processOutgoingRequest(request, response) {\n \n // its only of any use if the outgoing request has knowledge\n // of the originatig request\n if (request.hasOrigin()) {\n\n // wait for the response to be sent\n response.onSend = () => {\n\n // we need the origin response to write our \n // data on\n const originResponse = request.getOrigin().getResponse();\n\n\n // check if there is any cost recorded on the response\n if (response.hasMetaData('rate-limit-cost')) {\n const originalCost = originResponse.hasMetaData('rate-limit-cost') ? originResponse.getMetaData('rate-limit-cost') : 0;\n\n\n // add both costs, write them on the origin\n originResponse.setMetaData('rate-limit-cost', originalCost+response.hasMetaData('rate-limit-cost'));\n }\n }\n }\n\n\n return Promise.resolve();\n }", "title": "" }, { "docid": "238f3175b8e1d2d46ef9963fb721f442", "score": "0.43888843", "text": "function handleCORSRequests(req, res, next) {\n res.setHeader('Access-Control-Allow-Origin', '*');\n res.setHeader('Access-Control-Allow-Methods', 'GET, POST');\n res.setHeader('Access-Control-Allow-Headers', 'X-Requested-With, content-type, Authorization');\n next();\n }", "title": "" }, { "docid": "03928ec747a86b36d70799c8f45c1f68", "score": "0.43845376", "text": "setOptions(options) {\n for(let [i, val] of Object.entries(this.opt)) {\n if(options.hasOwnProperty(i)) {\n this.opt[i] = options[i];\n }\n }\n }", "title": "" }, { "docid": "cb82e448f43c8b326711c35fb547ccf4", "score": "0.43745083", "text": "function method (request, next) {\n\n\t if (request.emulateHTTP && /^(PUT|PATCH|DELETE)$/i.test(request.method)) {\n\t request.headers.set('X-HTTP-Method-Override', request.method);\n\t request.method = 'POST';\n\t }\n\n\t next();\n\t}", "title": "" }, { "docid": "c5eb09da53f1ca59e3db36ccbe0b87cc", "score": "0.43681678", "text": "function addHeaders(res, document) {\n\t\tvar allow = 'GET,HEAD,DELETE,OPTIONS';\n\t\tif (isContainer(document)) {\n\t\t\tres.links({\n\t\t\t\ttype: document.interactionModel\n\t\t\t});\n\t\t\tallow += ',POST';\n\t\t\tres.set('Accept-Post', media.turtle + ',' + media.jsonld + ',' + media.json);\n\t\t} else {\n\t\t\tallow += ',PUT';\n\t\t}\n\n\t\tres.set('Allow', allow);\n\t}", "title": "" }, { "docid": "e114f41d374b9e31a96968811a0515e9", "score": "0.43616015", "text": "function allowCrossDomain(req, res, next) {\n res.header('Access-Control-Allow-Origin', '*');\n res.header('Access-Control-Allow-Methods', 'GET,PUT,POST,DELETE,PATCH,OPTIONS');\n res.header('Access-Control-Allow-Headers', 'Content-Type, Authorization, Content-Length, X-Requested-With');\n next();\n}", "title": "" }, { "docid": "9968c72f674eacbb3a76284bd6cac6ff", "score": "0.4356062", "text": "request(options, data, callback) {\n // http o https\n var http = require(this.protocol); // http, o https\n\n var respuesta = {\n status: null,\n body: \"\",\n headers: null,\n };\n\n var auxRequest = http.request(options, (responseChannel) => {\n responseChannel.on(\"data\", (chunk) => {\n respuesta.body += chunk;\n });\n\n responseChannel.on(\"end\", () => {\n respuesta.status = responseChannel.statusCode;\n respuesta.headers = responseChannel.headers;\n callback(respuesta);\n });\n });\n\n if (data != undefined && data != null) {\n var body = JSON.stringify(data);\n auxRequest.setHeader(\"Content-Length\", Buffer.byteLength(body));\n auxRequest.setHeader(\"Content-Type\", \"application/json\");\n auxRequest.write(body);\n }\n\n auxRequest.end();\n }", "title": "" }, { "docid": "f1878ecc304f0962283c04526c4c0e56", "score": "0.43527928", "text": "async sendResponse() {\r\n\t\tconst response = await this.router.dispatch();\r\n\t\tconst status = HttpStatusCode.getStatusFromCode(response.getStatusCode());\r\n\r\n\t\tlogger.info(`💌 << ${response.getStatusCode()} ${status}`);\r\n\r\n\t\tthis.httpResponse.writeHead(response.getStatusCode(), {\r\n\t\t\t'Content-Type': 'application/json',\r\n\t\t});\r\n\t\tthis.httpResponse.end(response.toString());\r\n\t}", "title": "" }, { "docid": "315f747f900e374e13e5551d4442d53f", "score": "0.43432587", "text": "uploadAccounts(auth){\n \n var accountOptions = Object.assign(this.defaultOptions); //clone options (do not want to change original default options object)\n accountOptions.method = 'GET';\n accountOptions.url = this.base_url + 'accounts';\n accountOptions.headers.Authorization = '{cobSession=' + auth.cobSession + ', userSession=' + auth.userSession + '}';\n\n console.log(accountOptions);\n\n axios(accountOptions)\n .then((response) => {\n let accountData = { \n 'bank_name': 'yodlee', \n 'data': response.data, \n 'download_date': this.now\n }\n return accountData\n })\n .then((accountData) => {\n this.appResponse.send(\"Saving accounts to Mongo:<br><br>\" + JSON.stringify(accountData, null, 2));\n this.saveToMongo(accountData, \"yodlee_accounts\");\n return accountData;\n })\n .catch((error) => {\n console.log(\"Error: \" + error)\n })\n }", "title": "" }, { "docid": "5f5bc450999b055381cf2ad2a87d8881", "score": "0.43423802", "text": "get options() {\n return this.__options;\n }", "title": "" } ]
7eb7ce9fcfb01f1c7dd534f6e09a3c7e
Remove the selected range. If the cursor is collapsed, remove the following character. This operation is Unicodeaware, so removing a single character will remove a surrogate pair properly as well.
[ { "docid": "935c87be664f7b4e09cc27ca04bf7cae", "score": "0.54034305", "text": "function keyCommandPlainDelete(editorState){var afterRemoval=removeTextWithStrategy(editorState,function(strategyState){var selection=strategyState.getSelection();var content=strategyState.getCurrentContent();var key=selection.getAnchorKey();var offset=selection.getAnchorOffset();var charAhead=content.getBlockForKey(key).getText()[offset];return moveSelectionForward(strategyState,charAhead?UnicodeUtils.getUTF16Length(charAhead,0):1);},'forward');if(afterRemoval===editorState.getCurrentContent()){return editorState;}var selection=editorState.getSelection();return EditorState.push(editorState,afterRemoval.set('selectionBefore',selection),selection.isCollapsed()?'delete-character':'remove-range');}", "title": "" } ]
[ { "docid": "3e1ccdd837855ecf542167f7f92fd9c8", "score": "0.6592837", "text": "function clearRange(maskCharData, selectionStart, selectionCount) {\n for (var i = 0; i < maskCharData.length; i++) {\n if (maskCharData[i].displayIndex >= selectionStart) {\n if (maskCharData[i].displayIndex >= selectionStart + selectionCount) {\n break;\n }\n maskCharData[i].value = undefined;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "3e1ccdd837855ecf542167f7f92fd9c8", "score": "0.6592837", "text": "function clearRange(maskCharData, selectionStart, selectionCount) {\n for (var i = 0; i < maskCharData.length; i++) {\n if (maskCharData[i].displayIndex >= selectionStart) {\n if (maskCharData[i].displayIndex >= selectionStart + selectionCount) {\n break;\n }\n maskCharData[i].value = undefined;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "3e1ccdd837855ecf542167f7f92fd9c8", "score": "0.6592837", "text": "function clearRange(maskCharData, selectionStart, selectionCount) {\n for (var i = 0; i < maskCharData.length; i++) {\n if (maskCharData[i].displayIndex >= selectionStart) {\n if (maskCharData[i].displayIndex >= selectionStart + selectionCount) {\n break;\n }\n maskCharData[i].value = undefined;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "3c53a43147519ca6fd32778249ed75d1", "score": "0.6308465", "text": "clearSelection() {\n\t\tif (this.target) {\n\t\t\tthis.target.blur();\n\t\t}\n\n\t\twindow.getSelection().removeAllRanges();\n\t}", "title": "" }, { "docid": "09c4441693559298a6b8d4d45a3c68c5", "score": "0.6175529", "text": "_onClickRemove() {\n const offset = this.offset();\n this.editor.deleteText(offset, this.length());\n this.editor.setSelection(offset);\n }", "title": "" }, { "docid": "7a0744596e92522d2bbd0f6627914742", "score": "0.6134963", "text": "function removeCursor(self) {\n if (self.config.end_of_words && !self.config.loop) {\n if(self.element.classList.contains('removeAtEnd')) {\n self.element.classList.remove('typewriter-cursor');\n }\n }\n }", "title": "" }, { "docid": "0ee2f239d449cd3269aea6e69dd96389", "score": "0.6073361", "text": "function removeCursor(parentElement) { parentElement.children(\"span.ti-cursor\").remove(); }", "title": "" }, { "docid": "a18f6872f06ef80245f418d1be88a677", "score": "0.60630935", "text": "clearSelection() {\r\n this._setSelection(null);\r\n }", "title": "" }, { "docid": "1949c5f2c95351a71ac5fd7927d57819", "score": "0.6055022", "text": "function clearSelection() {\n if (document.selection)\n document.selection.empty();\n else if (window.getSelection)\n window.getSelection().removeAllRanges();\n }", "title": "" }, { "docid": "554f0b8d30fe7759eef68002f20dbfd7", "score": "0.6051409", "text": "clear(): void {\n // From: http://stackoverflow.com/a/3169849/3001914\n // Note that we don't support IE at all.\n const getSelection = window.getSelection;\n if (getSelection != null) {\n if (getSelection().empty) {\n // Chrome\n getSelection().empty();\n return;\n } else if (getSelection().removeAllRanges) {\n // Firefox\n getSelection().removeAllRanges();\n return;\n }\n }\n\n logger.warn('clearing of text selection not supported');\n }", "title": "" }, { "docid": "193d820d9616847641e9fdea9b800580", "score": "0.60225385", "text": "function deselectText() {\n $output.find('p:first-of-type').removeClass('insert-above');\n $output.find('p:first-of-type').removeClass('selected-for-removal');\n\n if (window.getSelection) { // All browsers, except <= IE8\n var selection = window.getSelection();\n selection.removeAllRanges();\n } else {\n if (document.selection.createRange) { // <= IE8\n var range = document.selection.createRange();\n document.selection.empty();\n }\n }\n }", "title": "" }, { "docid": "02da4978fc01bbcf1ca82e5d12532912", "score": "0.59662634", "text": "function clearSelection() {\n if ( document.selection ) {\n document.selection.empty();\n } else if ( window.getSelection ) {\n window.getSelection().removeAllRanges();\n }\n }", "title": "" }, { "docid": "f27d05803072f07978441e38dfacef9f", "score": "0.59535736", "text": "function chop() {\n // DOM (!)\n if (selection && selection.liststype === ELEMENT_TYPE) {\n //Is a div, has text, take off the last character\n if (selection.innerText !== \"\") {\n selection.innerText = selection.innerText.slice(0, -1);\n }\n /* TODO: Decide if I like the removal on backspace...\n but when I was using it in the real world, I held down backspace\n and that caused me to delete more from the next elements text\n than I was anticipating... seems more dangrous than it was\n worth. Will remove eventually depending on real-world usage.\n else {\n //Remove until there's only a blank element\n if (selection.previousElementSibling !== null) {\n var toSelect = selection.previousElementSibling;\n selection.remove();\n selection = select(toSelect);\n } else if (selection.nextElementSibling !== null) {\n var toSelect = selection.nextElementSibling;\n selection.remove();\n selection = select(toSelect);\n }\n }*/\n }\n }", "title": "" }, { "docid": "054f0c311bc298960e0ed2b1752e164b", "score": "0.5951637", "text": "function clearSelection() {\n selectionInsert.innerHTML = '';\n separatorCounter = 0;\n}", "title": "" }, { "docid": "9157c15a1570928b39406d00ab946c1d", "score": "0.59085757", "text": "function clearNext(maskCharData, selectionStart) {\n for (var i = 0; i < maskCharData.length; i++) {\n if (maskCharData[i].displayIndex >= selectionStart) {\n maskCharData[i].value = undefined;\n break;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "9157c15a1570928b39406d00ab946c1d", "score": "0.59085757", "text": "function clearNext(maskCharData, selectionStart) {\n for (var i = 0; i < maskCharData.length; i++) {\n if (maskCharData[i].displayIndex >= selectionStart) {\n maskCharData[i].value = undefined;\n break;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "9157c15a1570928b39406d00ab946c1d", "score": "0.59085757", "text": "function clearNext(maskCharData, selectionStart) {\n for (var i = 0; i < maskCharData.length; i++) {\n if (maskCharData[i].displayIndex >= selectionStart) {\n maskCharData[i].value = undefined;\n break;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "fb5de0501b11c6e0544484bf3979f931", "score": "0.5856809", "text": "function selectionClear() {\n\t\tinfoClose(_selection);\n\t\tselectionSet(null);\n\t}", "title": "" }, { "docid": "42dd463490225d26ef4de4999f272ff1", "score": "0.58272606", "text": "function rangeDelete(){\n from.value = \"\";\n to.value = \"\";\n}", "title": "" }, { "docid": "719f2bfc36e5f29873ac96b1559700e5", "score": "0.5822104", "text": "function clearSelection() {\r\n if ( document.selection ) {\r\n document.selection.empty();\r\n } else if ( window.getSelection ) {\r\n window.getSelection().removeAllRanges();\r\n }\r\n}", "title": "" }, { "docid": "805efd02af55512d39fa0783f943a9f3", "score": "0.5796979", "text": "clearSelection() {\n this._clearSelection();\n }", "title": "" }, { "docid": "d4977b015435c845b220e4094e330b9c", "score": "0.5791074", "text": "_popRange() {\n\t\tthis._ranges.pop();\n\t}", "title": "" }, { "docid": "42b7e56361ab4534e59d259016a07cc7", "score": "0.5744837", "text": "_processCharacterDeletion() {\n let left;\n let right;\n\n if (!this.selection.length) {\n [left, right] = this._getUnformattedLeftAndRightPartAroundTheSelection();\n if (left === '' && right === '') {\n this.throwInput = false;\n }\n\n if (this.isTrailingNegative && AutoNumericHelper.isNegative(AutoNumericHelper.getElementValue(this.domElement))) {\n [left, right] = this._processCharacterDeletionIfTrailingNegativeSign([left, right]);\n } else {\n if (this.eventKey === AutoNumericEnum.keyName.Backspace) {\n left = left.substring(0, left.length - 1);\n } else {\n right = right.substring(1, right.length);\n }\n }\n } else {\n this._expandSelectionOnSign();\n [left, right] = this._getUnformattedLeftAndRightPartAroundTheSelection();\n }\n\n this._setValueParts(left, right);\n }", "title": "" }, { "docid": "3daf841b81369865ea35a22d192575ac", "score": "0.5727744", "text": "function clearSelection() {\n\tif (window.getSelection) {window.getSelection().removeAllRanges();}\n\telse if (document.selection) {document.selection.empty();}\n}", "title": "" }, { "docid": "0f5fe2be046cfaa565e518083d6ab96c", "score": "0.571439", "text": "function UnHighlight() { if (selection != null) UnHighlight(selection); }", "title": "" }, { "docid": "de021f0fe62cda6ff4011d940b6f23e3", "score": "0.57096857", "text": "_removeChar() {\n let elText = this.text;\n this.text = elText.substr( 0, elText.length - 1 );\n }", "title": "" }, { "docid": "04a63e1498525a197e89765c786b746b", "score": "0.56371963", "text": "function deselectAllText() {\n // DOM (!)\n if (window.getSelection) {\n window.getSelection().removeAllRanges();\n }\n else if (document.selection) {\n document.selection.empty();\n }\n }", "title": "" }, { "docid": "e45e23ba50c75dc1f8f3962db0465de4", "score": "0.5630746", "text": "clearSelection() {\r\n this.broker.selection.splice(0);\r\n this.displaySelection(this.broker.selection);\r\n }", "title": "" }, { "docid": "afd777488a782d679b96a8401c27c40d", "score": "0.56257915", "text": "Cut(str)\n {\n if(this.HasSelection())\n {\n this.deleteSelection(str);\n this.preferredX = null;\n return 1;\n }\n return 0;\n }", "title": "" }, { "docid": "1e3e01574b441f31c2ca65f48b77bbda", "score": "0.56194", "text": "function removeFromWord(die){\n $scope.currentWord = $scope.currentWord.substring(0, $scope.currentWord.length-1);\n die.selected = false;\n $scope.selectedPositions.pop();\n }", "title": "" }, { "docid": "45c98ccd94f396c1ea8feb0d303ec61d", "score": "0.56139314", "text": "function clearPrev(maskCharData, selectionStart) {\n for (var i = maskCharData.length - 1; i >= 0; i--) {\n if (maskCharData[i].displayIndex < selectionStart) {\n maskCharData[i].value = undefined;\n break;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "45c98ccd94f396c1ea8feb0d303ec61d", "score": "0.56139314", "text": "function clearPrev(maskCharData, selectionStart) {\n for (var i = maskCharData.length - 1; i >= 0; i--) {\n if (maskCharData[i].displayIndex < selectionStart) {\n maskCharData[i].value = undefined;\n break;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "45c98ccd94f396c1ea8feb0d303ec61d", "score": "0.56139314", "text": "function clearPrev(maskCharData, selectionStart) {\n for (var i = maskCharData.length - 1; i >= 0; i--) {\n if (maskCharData[i].displayIndex < selectionStart) {\n maskCharData[i].value = undefined;\n break;\n }\n }\n return maskCharData;\n}", "title": "" }, { "docid": "fc5039b3dac2eed4a713d826a55b6402", "score": "0.55865145", "text": "function pbRemoveColours() {\n let startIndex = currentSelection.startIndex;\n let endIndex = currentSelection.endIndex;\n\n if (startIndex > endIndex) {\n let tmp = startIndex;\n startIndex = endIndex;\n endIndex = tmp;\n }\n\n for (let i=startIndex; i<=endIndex; i++) {\n coloursList.removeChild(coloursList.children[startIndex]);\n }\n clearBorders();\n}", "title": "" }, { "docid": "1371a5dbb757b03130a391622d87be9e", "score": "0.5576781", "text": "deleteContent() {\n this._wwe.getEditor().setSelection(this._range);\n this._wwe.getEditor().insertHTML('');\n this._range = this._wwe.getRange();\n }", "title": "" }, { "docid": "1dee9b989337928eb11e5a929c02d102", "score": "0.5575886", "text": "function del(range) {\r\n return { range: range, newText: '' };\r\n }", "title": "" }, { "docid": "1dee9b989337928eb11e5a929c02d102", "score": "0.5575886", "text": "function del(range) {\r\n return { range: range, newText: '' };\r\n }", "title": "" }, { "docid": "de91b38eff22899736477bae06dddf3f", "score": "0.5571501", "text": "function clearLine() {\n cursor.horizontalAbsolute(0).eraseLine();\n}", "title": "" }, { "docid": "b2ba6a9b5d850460bf01c2c72930cdde", "score": "0.556823", "text": "function del(range) {\n return {\n range: range,\n newText: ''\n };\n }", "title": "" }, { "docid": "b2ba6a9b5d850460bf01c2c72930cdde", "score": "0.556823", "text": "function del(range) {\n return {\n range: range,\n newText: ''\n };\n }", "title": "" }, { "docid": "0e21d2c4b43a41fbb302082a901f74cc", "score": "0.5567717", "text": "function getCharacterRemovalRange(block, selectionState, direction) {\n\t var start = selectionState.getStartOffset(), end = selectionState.getEndOffset(), entityKey = block.getEntityAt(start);\n\t if (!entityKey) return selectionState;\n\t var entity = DraftEntity.get(entityKey), mutability = entity.getMutability();\n\t // `MUTABLE` entities can just have the specified range of text removed\n\t // directly. No adjustments are needed.\n\t if (\"MUTABLE\" === mutability) return selectionState;\n\t // Find the entity range that overlaps with our removal range.\n\t var entityRanges = getRangesForDraftEntity(block, entityKey).filter(function(range) {\n\t return start < range.end && end > range.start;\n\t });\n\t 1 != entityRanges.length ? invariant(!1) : void 0;\n\t var entityRange = entityRanges[0];\n\t // For `IMMUTABLE` entity types, we will remove the entire entity range.\n\t if (\"IMMUTABLE\" === mutability) return selectionState.merge({\n\t anchorOffset: entityRange.start,\n\t focusOffset: entityRange.end,\n\t isBackward: !1\n\t });\n\t // For `SEGMENTED` entity types, determine the appropriate segment to\n\t // remove.\n\t var removalRange = DraftEntitySegments.getRemovalRange(start, end, block.getText().slice(entityRange.start, entityRange.end), entityRange.start, direction);\n\t return selectionState.merge({\n\t anchorOffset: removalRange.start,\n\t focusOffset: removalRange.end,\n\t isBackward: !1\n\t });\n\t }", "title": "" }, { "docid": "db3fb751d84292f556445fda72a489ca", "score": "0.5550555", "text": "function selectionDelete() {\n\t\tif (_selection != null) {\n\t\t\t_selection.setMap(null);\n\t\t\tselectionClear;\n\t\t}\n\t}", "title": "" }, { "docid": "695a7ec26692249ae6bbe0dfa8baea16", "score": "0.55219537", "text": "function AntiCopas() {\n\t\tvar Seleksi = getSelection();\n\t\tif (Seleksi.rangeCount != 0)Seleksi.removeAllRanges();\n\t}", "title": "" }, { "docid": "173fcffca91cd7ce83141065945631eb", "score": "0.549586", "text": "function del(range) {\n return { range: range, newText: '' };\n }", "title": "" }, { "docid": "173fcffca91cd7ce83141065945631eb", "score": "0.549586", "text": "function del(range) {\n return { range: range, newText: '' };\n }", "title": "" }, { "docid": "173fcffca91cd7ce83141065945631eb", "score": "0.549586", "text": "function del(range) {\n return { range: range, newText: '' };\n }", "title": "" }, { "docid": "21add30defd482ae8d8b4c2f5ce93067", "score": "0.5491003", "text": "delete(editor) {\n var options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {};\n Editor.withoutNormalizing(editor, () => {\n var {\n reverse = false,\n unit = 'character',\n distance = 1,\n voids = false\n } = options;\n var {\n at = editor.selection,\n hanging = false\n } = options;\n\n if (!at) {\n return;\n }\n\n if (Range.isRange(at) && Range.isCollapsed(at)) {\n at = at.anchor;\n }\n\n if (Point.isPoint(at)) {\n var furthestVoid = Editor.void(editor, {\n at,\n mode: 'highest'\n });\n\n if (!voids && furthestVoid) {\n var [, voidPath] = furthestVoid;\n at = voidPath;\n } else {\n var opts = {\n unit,\n distance\n };\n var target = reverse ? Editor.before(editor, at, opts) || Editor.start(editor, []) : Editor.after(editor, at, opts) || Editor.end(editor, []);\n at = {\n anchor: at,\n focus: target\n };\n hanging = true;\n }\n }\n\n if (Path.isPath(at)) {\n Transforms.removeNodes(editor, {\n at,\n voids\n });\n return;\n }\n\n if (Range.isCollapsed(at)) {\n return;\n }\n\n if (!hanging) {\n var [, _end] = Range.edges(at);\n var endOfDoc = Editor.end(editor, []);\n\n if (!Point.equals(_end, endOfDoc)) {\n at = Editor.unhangRange(editor, at, {\n voids\n });\n }\n }\n\n var [start, end] = Range.edges(at);\n var startBlock = Editor.above(editor, {\n match: n => Editor.isBlock(editor, n),\n at: start,\n voids\n });\n var endBlock = Editor.above(editor, {\n match: n => Editor.isBlock(editor, n),\n at: end,\n voids\n });\n var isAcrossBlocks = startBlock && endBlock && !Path.equals(startBlock[1], endBlock[1]);\n var isSingleText = Path.equals(start.path, end.path);\n var startVoid = voids ? null : Editor.void(editor, {\n at: start,\n mode: 'highest'\n });\n var endVoid = voids ? null : Editor.void(editor, {\n at: end,\n mode: 'highest'\n }); // If the start or end points are inside an inline void, nudge them out.\n\n if (startVoid) {\n var before = Editor.before(editor, start);\n\n if (before && startBlock && Path.isAncestor(startBlock[1], before.path)) {\n start = before;\n }\n }\n\n if (endVoid) {\n var after = Editor.after(editor, end);\n\n if (after && endBlock && Path.isAncestor(endBlock[1], after.path)) {\n end = after;\n }\n } // Get the highest nodes that are completely inside the range, as well as\n // the start and end nodes.\n\n\n var matches = [];\n var lastPath;\n\n for (var entry of Editor.nodes(editor, {\n at,\n voids\n })) {\n var [node, path] = entry;\n\n if (lastPath && Path.compare(path, lastPath) === 0) {\n continue;\n }\n\n if (!voids && Editor.isVoid(editor, node) || !Path.isCommon(path, start.path) && !Path.isCommon(path, end.path)) {\n matches.push(entry);\n lastPath = path;\n }\n }\n\n var pathRefs = Array.from(matches, (_ref) => {\n var [, p] = _ref;\n return Editor.pathRef(editor, p);\n });\n var startRef = Editor.pointRef(editor, start);\n var endRef = Editor.pointRef(editor, end);\n\n if (!isSingleText && !startVoid) {\n var _point = startRef.current;\n var [_node] = Editor.leaf(editor, _point);\n var {\n path: _path\n } = _point;\n var {\n offset\n } = start;\n\n var text = _node.text.slice(offset);\n\n editor.apply({\n type: 'remove_text',\n path: _path,\n offset,\n text\n });\n }\n\n for (var pathRef of pathRefs) {\n var _path2 = pathRef.unref();\n\n Transforms.removeNodes(editor, {\n at: _path2,\n voids\n });\n }\n\n if (!endVoid) {\n var _point2 = endRef.current;\n var [_node2] = Editor.leaf(editor, _point2);\n var {\n path: _path3\n } = _point2;\n\n var _offset = isSingleText ? start.offset : 0;\n\n var _text = _node2.text.slice(_offset, end.offset);\n\n editor.apply({\n type: 'remove_text',\n path: _path3,\n offset: _offset,\n text: _text\n });\n }\n\n if (!isSingleText && isAcrossBlocks && endRef.current && startRef.current) {\n Transforms.mergeNodes(editor, {\n at: endRef.current,\n hanging: true,\n voids\n });\n }\n\n var point = reverse ? startRef.unref() || endRef.unref() : endRef.unref() || startRef.unref();\n\n if (options.at == null && point) {\n Transforms.select(editor, point);\n }\n });\n }", "title": "" }, { "docid": "df379a00a555bae66cdd78d98ed457cd", "score": "0.54872507", "text": "function collapseRangeToEnd(range){return isCollapsedRange(range)?range:moveRangePos(range,range.end);}", "title": "" }, { "docid": "eade43646476198f7e081472050027b8", "score": "0.54804355", "text": "deleteToLeft() {\n const start = this.input.selectionStart;\n const text = this.input.value;\n\n if (start === 0) return;\n\n this.input.value = text.slice(0, (start - 1)) + text.slice((start + 1));\n this.input.focus();\n this.input.selectionStart = start - 1;\n this.input.selectionEnd = this.input.selectionStart;\n }", "title": "" }, { "docid": "6ff16da1d0d2e83b93f5bcdb77acb421", "score": "0.5464866", "text": "function trimNbspAfterDeleteAndPaddValue() {\n\t\t\tvar rng, container, offset;\n\n\t\t\trng = selection.getRng(true);\n\t\t\tcontainer = rng.startContainer;\n\t\t\toffset = rng.startOffset;\n\n\t\t\tif (container.nodeType == 3 && rng.collapsed) {\n\t\t\t\tif (container.data[offset] === '\\u00a0') {\n\t\t\t\t\tcontainer.deleteData(offset, 1);\n\n\t\t\t\t\tif (!/[\\u00a0| ]$/.test(value)) {\n\t\t\t\t\t\tvalue += ' ';\n\t\t\t\t\t}\n\t\t\t\t} else if (container.data[offset - 1] === '\\u00a0') {\n\t\t\t\t\tcontainer.deleteData(offset - 1, 1);\n\n\t\t\t\t\tif (!/[\\u00a0| ]$/.test(value)) {\n\t\t\t\t\t\tvalue = ' ' + value;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "6ff16da1d0d2e83b93f5bcdb77acb421", "score": "0.5464866", "text": "function trimNbspAfterDeleteAndPaddValue() {\n\t\t\tvar rng, container, offset;\n\n\t\t\trng = selection.getRng(true);\n\t\t\tcontainer = rng.startContainer;\n\t\t\toffset = rng.startOffset;\n\n\t\t\tif (container.nodeType == 3 && rng.collapsed) {\n\t\t\t\tif (container.data[offset] === '\\u00a0') {\n\t\t\t\t\tcontainer.deleteData(offset, 1);\n\n\t\t\t\t\tif (!/[\\u00a0| ]$/.test(value)) {\n\t\t\t\t\t\tvalue += ' ';\n\t\t\t\t\t}\n\t\t\t\t} else if (container.data[offset - 1] === '\\u00a0') {\n\t\t\t\t\tcontainer.deleteData(offset - 1, 1);\n\n\t\t\t\t\tif (!/[\\u00a0| ]$/.test(value)) {\n\t\t\t\t\t\tvalue = ' ' + value;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "2cbfce6508040e4b4603863b1f1244b4", "score": "0.5461758", "text": "clearFeatureSelection() {\n this.editor.clearFeatureSelection();\n }", "title": "" }, { "docid": "60d8e5df4e8726c0afd27b34b0de43b5", "score": "0.5422765", "text": "function removeTextWithStrategy(editorState,strategy,direction){var selection=editorState.getSelection();var content=editorState.getCurrentContent();var target=selection;if(selection.isCollapsed()){if(direction==='forward'){if(editorState.isSelectionAtEndOfContent()){return content;}}else if(editorState.isSelectionAtStartOfContent()){return content;}target=strategy(editorState);if(target===selection){return content;}}return DraftModifier.removeRange(content,target,direction);}", "title": "" }, { "docid": "c83327812fede17401b4a3ce52943bf6", "score": "0.5406298", "text": "function collapseToStart(e) {\n\te.range.end = e.range.start\n}", "title": "" }, { "docid": "0b5e4c71d0bd0237ef171ef3d3ae852a", "score": "0.5406025", "text": "function getTrimmedSelection() {\n const selection = String(window.getSelection());\n return selection.replace(/^\\s+|\\s+$/g, '');\n}", "title": "" }, { "docid": "e40a6226b3e2b1d8052bfb1e96f4f0a2", "score": "0.54001343", "text": "removeRange({ columns, start, table, stop, owner }) {\n\t\treturn this.$publish('removeRange', { columns, start, table, stop, owner });\n\t}", "title": "" }, { "docid": "838b52b66101f0ce70a6859622edfc64", "score": "0.5386233", "text": "function removeSelection(key, modifiers) {\n\n if (key === 46) {\n editorActions.trigger('removeSelection');\n\n return true;\n }\n }", "title": "" }, { "docid": "1819bb373c9edc7c56e6360c23d3a201", "score": "0.53789884", "text": "clearSelection() {\r\n this.selectionManager.clear();\r\n super.clearSelection();\r\n }", "title": "" }, { "docid": "1de3411e8e98d7a96c74333c94c673d1", "score": "0.5372611", "text": "removeHighlight(highlight) {\n const doc = this.el.ownerDocument || this.el.document;\n const highlightRange = doc.createRange();\n highlightRange.selectNodeContents(highlight);\n highlight.parentNode.insertBefore(highlightRange.extractContents(), highlight);\n highlight.parentNode.removeChild(highlight);\n }", "title": "" }, { "docid": "eebef3f0deb026a71d74302132a9c26e", "score": "0.53709346", "text": "function keyCommandPlainDelete(editorState) {\n\t var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n\t var selection = strategyState.getSelection();\n\t var content = strategyState.getCurrentContent();\n\t var key = selection.getAnchorKey();\n\t var offset = selection.getAnchorOffset();\n\t var charAhead = content.getBlockForKey(key).getText()[offset];\n\t return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n\t }, 'forward');\n\n\t if (afterRemoval === editorState.getCurrentContent()) {\n\t return editorState;\n\t }\n\n\t var selection = editorState.getSelection();\n\n\t return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n\t}", "title": "" }, { "docid": "eebef3f0deb026a71d74302132a9c26e", "score": "0.53709346", "text": "function keyCommandPlainDelete(editorState) {\n\t var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n\t var selection = strategyState.getSelection();\n\t var content = strategyState.getCurrentContent();\n\t var key = selection.getAnchorKey();\n\t var offset = selection.getAnchorOffset();\n\t var charAhead = content.getBlockForKey(key).getText()[offset];\n\t return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n\t }, 'forward');\n\n\t if (afterRemoval === editorState.getCurrentContent()) {\n\t return editorState;\n\t }\n\n\t var selection = editorState.getSelection();\n\n\t return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n\t}", "title": "" }, { "docid": "77b5c9d5fbb027077149900d650bc4c0", "score": "0.5366466", "text": "function clearSelection() {\n return {\n type: actions.CLEAR_SELECTION,\n };\n}", "title": "" }, { "docid": "8be6534f3569b5d2cb04473fe35a19ae", "score": "0.53558296", "text": "function deleteNearSelection(cm,compute){var ranges=cm.doc.sel.ranges,kill=[]; // Build up a set of ranges to kill first, merging overlapping\n\t// ranges.\n\tfor(var i=0;i<ranges.length;i++){var toKill=compute(ranges[i]);while(kill.length&&cmp(toKill.from,lst(kill).to)<=0){var replaced=kill.pop();if(cmp(replaced.from,toKill.from)<0){toKill.from=replaced.from;break;}}kill.push(toKill);} // Next, remove those actual ranges.\n\trunInOp(cm,function(){for(var i=kill.length-1;i>=0;i--)replaceRange(cm.doc,\"\",kill[i].from,kill[i].to,\"+delete\");ensureCursorVisible(cm);});} // Used for horizontal relative motion. Dir is -1 or 1 (left or", "title": "" }, { "docid": "a646102d1ffe518834273b71c8a29d29", "score": "0.5348422", "text": "function cut() {\n // DOM (!)\n if (selection && selection.liststype === ELEMENT_TYPE) {\n cutOrCopied = selection.innerText;\n deleteSelection();\n } else if (selection && selection.liststype === LIST_TYPE) {\n cutOrCopied = [];\n Array.from(selection.children).forEach(function (c) {\n cutOrCopied.push(c.innerText);\n });\n deleteSelection();\n }\n }", "title": "" }, { "docid": "9067b96ed8530871e8fc34f36ae1490c", "score": "0.53309965", "text": "function removeGhostSelection() {\n\t\t\teditor.on('Undo Redo SetContent', function(e) {\n\t\t\t\tif (!e.initial) {\n\t\t\t\t\teditor.execCommand('mceRepaint');\n\t\t\t\t}\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "9067b96ed8530871e8fc34f36ae1490c", "score": "0.53309965", "text": "function removeGhostSelection() {\n\t\t\teditor.on('Undo Redo SetContent', function(e) {\n\t\t\t\tif (!e.initial) {\n\t\t\t\t\teditor.execCommand('mceRepaint');\n\t\t\t\t}\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "9067b96ed8530871e8fc34f36ae1490c", "score": "0.53309965", "text": "function removeGhostSelection() {\n\t\t\teditor.on('Undo Redo SetContent', function(e) {\n\t\t\t\tif (!e.initial) {\n\t\t\t\t\teditor.execCommand('mceRepaint');\n\t\t\t\t}\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "21f8caea5ad3dd63dcf904da41dbda5f", "score": "0.5323829", "text": "deleteSelection(e) {\n\t var direction, selection, caret, tail;\n\t var self = this;\n\t direction = e && e.keyCode === KEY_BACKSPACE ? -1 : 1;\n\t selection = getSelection(self.control_input); // determine items that will be removed\n\n\t const rm_items = [];\n\n\t if (self.activeItems.length) {\n\t tail = getTail(self.activeItems, direction);\n\t caret = nodeIndex(tail);\n\n\t if (direction > 0) {\n\t caret++;\n\t }\n\n\t for (const item of self.activeItems) {\n\t rm_items.push(item);\n\t }\n\t } else if ((self.isFocused || self.settings.mode === 'single') && self.items.length) {\n\t const items = self.controlChildren();\n\n\t if (direction < 0 && selection.start === 0 && selection.length === 0) {\n\t rm_items.push(items[self.caretPos - 1]);\n\t } else if (direction > 0 && selection.start === self.inputValue().length) {\n\t rm_items.push(items[self.caretPos]);\n\t }\n\t }\n\n\t const values = rm_items.map(item => item.dataset.value); // allow the callback to abort\n\n\t if (!values.length || typeof self.settings.onDelete === 'function' && self.settings.onDelete.call(self, values, e) === false) {\n\t return false;\n\t }\n\n\t preventDefault(e, true); // perform removal\n\n\t if (typeof caret !== 'undefined') {\n\t self.setCaret(caret);\n\t }\n\n\t while (rm_items.length) {\n\t self.removeItem(rm_items.pop());\n\t }\n\n\t self.showInput();\n\t self.positionDropdown();\n\t self.refreshOptions(false);\n\t return true;\n\t }", "title": "" }, { "docid": "dbcf1c4cd8e8278693417cf27e5fffc0", "score": "0.5322209", "text": "backspace() {\n let newCursor = this.cursorNode.previousSibling;\n\n if(newCursor !== null) {\n let oldCursor = this.cursorNode;\n this.cursorNode = newCursor;\n\n oldCursor.delete();\n this.updateValue();\n }\n }", "title": "" }, { "docid": "c06674554c93fdd32e5949e1681fd126", "score": "0.53121316", "text": "function removeCaretContainer(node, move_caret) {\n\t\t\t\tvar child, rng;\n\n\t\t\t\tif (!node) {\n\t\t\t\t\tnode = getParentCaretContainer(selection.getStart());\n\n\t\t\t\t\tif (!node) {\n\t\t\t\t\t\twhile ((node = dom.get(caretContainerId))) {\n\t\t\t\t\t\t\tremoveCaretContainer(node, false);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\trng = selection.getRng(true);\n\n\t\t\t\t\tif (isCaretContainerEmpty(node)) {\n\t\t\t\t\t\tif (move_caret !== false) {\n\t\t\t\t\t\t\trng.setStartBefore(node);\n\t\t\t\t\t\t\trng.setEndBefore(node);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchild = findFirstTextNode(node);\n\n\t\t\t\t\t\tif (child.nodeValue.charAt(0) === INVISIBLE_CHAR) {\n\t\t\t\t\t\t\tchild.deleteData(0, 1);\n\n\t\t\t\t\t\t\t// Fix for bug #6976\n\t\t\t\t\t\t\tif (rng.startContainer == child && rng.startOffset > 0) {\n\t\t\t\t\t\t\t\trng.setStart(child, rng.startOffset - 1);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (rng.endContainer == child && rng.endOffset > 0) {\n\t\t\t\t\t\t\t\trng.setEnd(child, rng.endOffset - 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node, 1);\n\t\t\t\t\t}\n\n\t\t\t\t\tselection.setRng(rng);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "c06674554c93fdd32e5949e1681fd126", "score": "0.53121316", "text": "function removeCaretContainer(node, move_caret) {\n\t\t\t\tvar child, rng;\n\n\t\t\t\tif (!node) {\n\t\t\t\t\tnode = getParentCaretContainer(selection.getStart());\n\n\t\t\t\t\tif (!node) {\n\t\t\t\t\t\twhile ((node = dom.get(caretContainerId))) {\n\t\t\t\t\t\t\tremoveCaretContainer(node, false);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\trng = selection.getRng(true);\n\n\t\t\t\t\tif (isCaretContainerEmpty(node)) {\n\t\t\t\t\t\tif (move_caret !== false) {\n\t\t\t\t\t\t\trng.setStartBefore(node);\n\t\t\t\t\t\t\trng.setEndBefore(node);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchild = findFirstTextNode(node);\n\n\t\t\t\t\t\tif (child.nodeValue.charAt(0) === INVISIBLE_CHAR) {\n\t\t\t\t\t\t\tchild.deleteData(0, 1);\n\n\t\t\t\t\t\t\t// Fix for bug #6976\n\t\t\t\t\t\t\tif (rng.startContainer == child && rng.startOffset > 0) {\n\t\t\t\t\t\t\t\trng.setStart(child, rng.startOffset - 1);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (rng.endContainer == child && rng.endOffset > 0) {\n\t\t\t\t\t\t\t\trng.setEnd(child, rng.endOffset - 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node, 1);\n\t\t\t\t\t}\n\n\t\t\t\t\tselection.setRng(rng);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "c06674554c93fdd32e5949e1681fd126", "score": "0.53121316", "text": "function removeCaretContainer(node, move_caret) {\n\t\t\t\tvar child, rng;\n\n\t\t\t\tif (!node) {\n\t\t\t\t\tnode = getParentCaretContainer(selection.getStart());\n\n\t\t\t\t\tif (!node) {\n\t\t\t\t\t\twhile ((node = dom.get(caretContainerId))) {\n\t\t\t\t\t\t\tremoveCaretContainer(node, false);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\trng = selection.getRng(true);\n\n\t\t\t\t\tif (isCaretContainerEmpty(node)) {\n\t\t\t\t\t\tif (move_caret !== false) {\n\t\t\t\t\t\t\trng.setStartBefore(node);\n\t\t\t\t\t\t\trng.setEndBefore(node);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchild = findFirstTextNode(node);\n\n\t\t\t\t\t\tif (child.nodeValue.charAt(0) === INVISIBLE_CHAR) {\n\t\t\t\t\t\t\tchild.deleteData(0, 1);\n\n\t\t\t\t\t\t\t// Fix for bug #6976\n\t\t\t\t\t\t\tif (rng.startContainer == child && rng.startOffset > 0) {\n\t\t\t\t\t\t\t\trng.setStart(child, rng.startOffset - 1);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (rng.endContainer == child && rng.endOffset > 0) {\n\t\t\t\t\t\t\t\trng.setEnd(child, rng.endOffset - 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node, 1);\n\t\t\t\t\t}\n\n\t\t\t\t\tselection.setRng(rng);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "c06674554c93fdd32e5949e1681fd126", "score": "0.53121316", "text": "function removeCaretContainer(node, move_caret) {\n\t\t\t\tvar child, rng;\n\n\t\t\t\tif (!node) {\n\t\t\t\t\tnode = getParentCaretContainer(selection.getStart());\n\n\t\t\t\t\tif (!node) {\n\t\t\t\t\t\twhile ((node = dom.get(caretContainerId))) {\n\t\t\t\t\t\t\tremoveCaretContainer(node, false);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} else {\n\t\t\t\t\trng = selection.getRng(true);\n\n\t\t\t\t\tif (isCaretContainerEmpty(node)) {\n\t\t\t\t\t\tif (move_caret !== false) {\n\t\t\t\t\t\t\trng.setStartBefore(node);\n\t\t\t\t\t\t\trng.setEndBefore(node);\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tchild = findFirstTextNode(node);\n\n\t\t\t\t\t\tif (child.nodeValue.charAt(0) === INVISIBLE_CHAR) {\n\t\t\t\t\t\t\tchild.deleteData(0, 1);\n\n\t\t\t\t\t\t\t// Fix for bug #6976\n\t\t\t\t\t\t\tif (rng.startContainer == child && rng.startOffset > 0) {\n\t\t\t\t\t\t\t\trng.setStart(child, rng.startOffset - 1);\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tif (rng.endContainer == child && rng.endOffset > 0) {\n\t\t\t\t\t\t\t\trng.setEnd(child, rng.endOffset - 1);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tdom.remove(node, 1);\n\t\t\t\t\t}\n\n\t\t\t\t\tselection.setRng(rng);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "c3b7b43458bf8ce5d76c9567159ce7bd", "score": "0.5304417", "text": "function normalizeSelection() {\n\t\t\t// Normalize selection for example <b>a</b><i>|a</i> becomes <b>a|</b><i>a</i> except for Ctrl+A since it selects everything\n\t\t\teditor.on('keyup focusin mouseup', function(e) {\n\t\t\t\tif (e.keyCode != 65 || !VK.metaKeyPressed(e)) {\n\t\t\t\t\tselection.normalize();\n\t\t\t\t}\n\t\t\t}, true);\n\t\t}", "title": "" }, { "docid": "c3b7b43458bf8ce5d76c9567159ce7bd", "score": "0.5304417", "text": "function normalizeSelection() {\n\t\t\t// Normalize selection for example <b>a</b><i>|a</i> becomes <b>a|</b><i>a</i> except for Ctrl+A since it selects everything\n\t\t\teditor.on('keyup focusin mouseup', function(e) {\n\t\t\t\tif (e.keyCode != 65 || !VK.metaKeyPressed(e)) {\n\t\t\t\t\tselection.normalize();\n\t\t\t\t}\n\t\t\t}, true);\n\t\t}", "title": "" }, { "docid": "c3b7b43458bf8ce5d76c9567159ce7bd", "score": "0.5304417", "text": "function normalizeSelection() {\n\t\t\t// Normalize selection for example <b>a</b><i>|a</i> becomes <b>a|</b><i>a</i> except for Ctrl+A since it selects everything\n\t\t\teditor.on('keyup focusin mouseup', function(e) {\n\t\t\t\tif (e.keyCode != 65 || !VK.metaKeyPressed(e)) {\n\t\t\t\t\tselection.normalize();\n\t\t\t\t}\n\t\t\t}, true);\n\t\t}", "title": "" }, { "docid": "c3b7b43458bf8ce5d76c9567159ce7bd", "score": "0.5304417", "text": "function normalizeSelection() {\n\t\t\t// Normalize selection for example <b>a</b><i>|a</i> becomes <b>a|</b><i>a</i> except for Ctrl+A since it selects everything\n\t\t\teditor.on('keyup focusin mouseup', function(e) {\n\t\t\t\tif (e.keyCode != 65 || !VK.metaKeyPressed(e)) {\n\t\t\t\t\tselection.normalize();\n\t\t\t\t}\n\t\t\t}, true);\n\t\t}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "616555240b80860a6ac1175c2bdd2bcf", "score": "0.5302704", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "ccfbf74c7e2b1ff6811a387501573349", "score": "0.52966255", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "ccfbf74c7e2b1ff6811a387501573349", "score": "0.52966255", "text": "function keyCommandPlainDelete(editorState) {\n var afterRemoval = removeTextWithStrategy(editorState, function (strategyState) {\n var selection = strategyState.getSelection();\n var content = strategyState.getCurrentContent();\n var key = selection.getAnchorKey();\n var offset = selection.getAnchorOffset();\n var charAhead = content.getBlockForKey(key).getText()[offset];\n return moveSelectionForward(strategyState, charAhead ? UnicodeUtils.getUTF16Length(charAhead, 0) : 1);\n }, 'forward');\n\n if (afterRemoval === editorState.getCurrentContent()) {\n return editorState;\n }\n\n var selection = editorState.getSelection();\n return EditorState.push(editorState, afterRemoval.set('selectionBefore', selection), selection.isCollapsed() ? 'delete-character' : 'remove-range');\n}", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" }, { "docid": "dd91cfe5a494632f631b73bd363409ab", "score": "0.5283521", "text": "function deleteNearSelection(cm, compute) {\n var ranges = cm.doc.sel.ranges, kill = [];\n // Build up a set of ranges to kill first, merging overlapping\n // ranges.\n for (var i = 0; i < ranges.length; i++) {\n var toKill = compute(ranges[i]);\n while (kill.length && cmp(toKill.from, lst(kill).to) <= 0) {\n var replaced = kill.pop();\n if (cmp(replaced.from, toKill.from) < 0) {\n toKill.from = replaced.from;\n break;\n }\n }\n kill.push(toKill);\n }\n // Next, remove those actual ranges.\n runInOp(cm, function() {\n for (var i = kill.length - 1; i >= 0; i--)\n replaceRange(cm.doc, \"\", kill[i].from, kill[i].to, \"+delete\");\n ensureCursorVisible(cm);\n });\n }", "title": "" } ]
95e363b8d9a557fdc8be4ee309db4417
Runs the next migration that has not yet been run
[ { "docid": "f7ad9e0433297342592eeca4cfa91e61", "score": "0.5908031", "text": "up(config) {\n this._disableProcessing();\n this.config = getMergedConfig$2(config, this.config);\n\n return migrationListResolver\n .listAllAndCompleted(this.config, this.knex)\n .then((value) => {\n if (!this.config.disableMigrationsListValidation) {\n validateMigrationList(this.config.migrationSource, value);\n }\n return value;\n })\n .then(([all, completed]) => {\n const newMigrations = getNewMigrations(\n this.config.migrationSource,\n all,\n completed\n );\n\n let migrationToRun;\n const name = this.config.name;\n if (name) {\n if (!completed.includes(name)) {\n migrationToRun = newMigrations.find((migration) => {\n return (\n this.config.migrationSource.getMigrationName(migration) === name\n );\n });\n if (!migrationToRun) {\n throw new Error(`Migration \"${name}\" not found.`);\n }\n }\n } else {\n migrationToRun = newMigrations[0];\n }\n\n const migrationsToRun = [];\n if (migrationToRun) {\n migrationsToRun.push(migrationToRun);\n }\n\n const transactionForAll =\n !this.config.disableTransactions &&\n isEmpty$2(\n filter$1(migrationsToRun, (migration) => {\n const migrationContents = this.config.migrationSource.getMigration(\n migration\n );\n\n return !this._useTransaction(migrationContents);\n })\n );\n\n if (transactionForAll) {\n return this.knex.transaction((trx) => {\n return this._runBatch(migrationsToRun, 'up', trx);\n });\n } else {\n return this._runBatch(migrationsToRun, 'up');\n }\n });\n }", "title": "" } ]
[ { "docid": "5be1f42bea50db079b4eb3ff52cd79c9", "score": "0.75131184", "text": "function run() {\n var migrationName = 'Migration_' + path.parse(__filename).name;\n var runDate = Util.getInternalVar(migrationName);\n if (runDate) {\n log.info(`Skipping migration ${migrationName}: was run on ${runDate}`);\n return;\n }\n log.info(`Running migration ${migrationName}`);\n initCoreAPTrustSettings();\n fixUserCanDelete();\n deleteLegacySettings();\n migrateEasyStoreFiles();\n var now = new Date().toISOString();\n log.info(`Finished ${migrationName} at ${now}`);\n Util.setInternalVar(migrationName, now);\n}", "title": "" }, { "docid": "cdcfc0fdc39a71cb7099c9bd3a7819df", "score": "0.72700787", "text": "function runNextScript(error) {\n if (error) {\n Migration.log.error('Error saving migration', localScriptName, 'to database!');\n Migration.log.error(error);\n Migration.finish(error);\n return cb(error);\n }\n const migrationEndTime = process.hrtime(migrationStartTime);\n Migration.log.info('%s finished sucessfully. Migration time was %ds %dms',\n localScriptName, migrationEndTime[0], migrationEndTime[1] / 1000000);\n migrationCallIndex += 1;\n if (migrationCallIndex < migrationCallStack.length) {\n migrationCallStack[migrationCallIndex]();\n } else {\n Migration.finish();\n }\n return cb();\n }", "title": "" }, { "docid": "eab9caed84ed4a14f0089e3878c9f173", "score": "0.6809515", "text": "function getNextMigrator() {\n if (migrators[i]) {\n let mig = migrators[i];\n\n // Increment i to point to the next migrator\n i++;\n migLOG(\"starting migrator: \" + mig.title);\n label.value = props.formatStringFromName(\"migratingApp\", [mig.title], 1);\n meter.value = ((i - 1) / migrators.length) * 100;\n mig.args.push(getNextMigrator);\n\n try {\n mig.migrate(...mig.args);\n } catch (e) {\n migLOG(\"Failed to migrate: \" + mig.title);\n migLOG(e);\n getNextMigrator();\n }\n } else {\n migLOG(\"migration done\");\n wizard.canAdvance = true;\n label.value = props.GetStringFromName(\"finished\");\n meter.value = 100;\n gMigrateWizard.setCanRewindFalse();\n }\n }", "title": "" }, { "docid": "801baa0d72d00970e831ed4c3f030ebb", "score": "0.67671764", "text": "async run(direction = 'up', migrationName, ...args) {\n await this.sync();\n\n if (direction !== 'up' && direction !== 'down') {\n throw new Error(`The '${direction}' is not supported, use the 'up' or 'down' direction`);\n }\n\n const untilMigration = migrationName ?\n await this.migrationModel.findOne({ name: migrationName }) :\n await this.migrationModel.findOne().sort({ createdAt: direction === 'up' ? -1 : 1 });\n\n if (!untilMigration) {\n if (migrationName) throw new ReferenceError(\"Could not find that migration in the database\");\n else throw new Error(\"There are no pending migrations.\");\n }\n\n let query = {\n createdAt: { $lte: untilMigration.createdAt },\n state: 'down'\n };\n\n if (direction == 'down') {\n query = {\n createdAt: { $gte: untilMigration.createdAt },\n state: 'up'\n };\n }\n\n\n const sortDirection = direction == 'up' ? 1 : -1;\n const migrationsToRun = await this.migrationModel.find(query)\n .sort({ createdAt: sortDirection });\n\n if (!migrationsToRun.length) {\n if (this.cli) {\n this.log('There are no migrations to run'.yellow);\n this.log(`Current Migrations' Statuses: `);\n await this.list();\n }\n }\n\n let self = this;\n let numMigrationsRan = 0;\n let migrationsRan = [];\n\n for (const migration of migrationsToRun) {\n const migrationFilePath = path.join(self.migrationPath, migration.filename);\n let migrationFunctions;\n migrationFunctions = require(migrationFilePath);\n\n if (!migrationFunctions[direction]) {\n throw new Error(`The \"${direction}\" export is not defined in ${migration.filename}.`.red);\n }\n\n try {\n await new Promise((resolve, reject) => {\n const callPromise = migrationFunctions[direction].call(\n this.connection.model.bind(this.connection),\n function callback(err) {\n if (err) return reject(err);\n resolve();\n },\n ...args\n );\n\n if (callPromise && typeof callPromise.then === 'function') {\n callPromise.then(resolve).catch(reject);\n }\n });\n\n this.log(`${direction.toUpperCase()}: `[direction == 'up' ? 'green' : 'red'] + ` ${migration.filename} `);\n\n await this.migrationModel.where({ name: migration.name }).updateMany({ $set: { state: direction } });\n migrationsRan.push(migration.toJSON());\n numMigrationsRan++;\n } catch (err) {\n this.log(`Failed to run migration ${migration.name} due to an error.`.red);\n this.log(`Not continuing. Make sure your data is in consistent state`.red);\n throw err instanceof (Error) ? err : new Error(err);\n }\n }\n\n if (migrationsToRun.length == numMigrationsRan && numMigrationsRan > 0) this.log('All migrations finished successfully.'.green);\n return migrationsRan;\n }", "title": "" }, { "docid": "5df63c8a4114fc7f5fd1b6e85a7efa89", "score": "0.65383995", "text": "function runUpMigrations(migrations, existing) {\n\n //Done\n if (migrations.length === 0) {\n return Promise.resolve('Finished all migrations');\n }\n\n //Get migration\n let migration = migrations.shift();\n status.start('Running migration', migration);\n\n //Run migration\n return checkDidntRunBefore(migration, existing)\n .then(() => loadScript(migration))\n .then(script => checkHasMethod(script, 'up'))\n .then(runner => runner())\n .then(() => status.ok())\n .then(() => Migration.save(migration))\n .catch(MethodInvalid, AlreadyRan, error => status.skip(error.message))\n .catch(error => status.error(error))\n .then(() => runUpMigrations(migrations, existing));\n}", "title": "" }, { "docid": "559de0343779a84ab0a4ad3c133a71db", "score": "0.64948", "text": "function runMigrations (version, cb) {\n // version represents the index of last migration ran on this db\n // if -1, no migrations have bene run\n\n function runMigrationVersion (version, migrationCb) {\n console.log(`running migration ${version}: ${migrations[version]}`)\n\n // use a transaction to ensure version is\n // incremented only if the migration succeeds\n connHandler.beginTransaction(function (err) {\n if (err) return migrationCb(err)\n\n connHandler.query(migrations[version], (err) => {\n if (err) return migrationCb(err)\n\n connHandler.query('UPDATE version SET version = version + 1 LIMIT 1', migrationCb)\n })\n })\n }\n\n if (version === migrations.length - 1) {\n console.log('no migrations to run')\n cb(null)\n } else {\n // https://stackoverflow.com/a/36963945/2788187\n // returns an array of numbers within specified range\n const range = (start, end) => Array.from({length: (end - start)}, (v, k) => k + start)\n\n const versionsToRun = range(version + 1, migrations.length)\n\n // run each migration, in series, run after the other. call `cb` when done\n async.eachSeries(versionsToRun, runMigrationVersion, cb)\n }\n }", "title": "" }, { "docid": "75159dd8d316bcb4ab510f56fad40e8e", "score": "0.6425454", "text": "async executeMigration(migration) {\n const Source = this.getMigrationSource(migration);\n const client = await this.getClient(Source.disableTransactions);\n try {\n const schema = new Source(client, migration.name, this.dryRun);\n this.emit('migration:start', this.migratedFiles[migration.name]);\n if (this.direction === 'up') {\n const response = await schema.execUp(); // Handles dry run itself\n await this.recordMigrated(client, migration.name, response); // Handles dry run itself\n }\n else if (this.direction === 'down') {\n const response = await schema.execDown(); // Handles dry run itself\n await this.recordRollback(client, migration.name, response); // Handles dry run itself\n }\n await this.commit(client);\n this.migratedFiles[migration.name].status = 'completed';\n this.emit('migration:completed', this.migratedFiles[migration.name]);\n }\n catch (error) {\n this.error = error;\n this.migratedFiles[migration.name].status = 'error';\n this.emit('migration:error', this.migratedFiles[migration.name]);\n await this.rollback(client);\n throw error;\n }\n }", "title": "" }, { "docid": "b204b467d1ac066e33c61008748e5f48", "score": "0.62240326", "text": "function runMigrations() {\n return new Promise((resolve, reject) => {\n const dbMigrate = DbMigrate.getInstance(true);\n\n dbMigrate.up((error, results = []) => {\n if (error) {\n return reject(error);\n }\n\n resolve(results);\n });\n });\n}", "title": "" }, { "docid": "689a28c498fd6a6e99e0bed069f0de50", "score": "0.62015676", "text": "function migrateStartingWith(ver) {\n\t\t\t\tstate = 1;\n\t\t\t\t$log.debug(\"Main Migrator starting\");\n\t\t\t\t//return doMigration(ver + 1)\n\t\t\t\tvar deferred = $q.defer();\n\n\t\t\t\ttry {\n\t\t\t\t\treturn doMigration(ver + 1).then(function () {\n\t\t\t\t\t\treturn deferred.resolve();\n\t\t\t\t\t});\n\t\t\t\t} catch (e) {\n\t\t\t\t\tdeferred.reject(e);\n\t\t\t\t}\n\n\t\t\t\treturn deferred.promise;\n\t\t\t}", "title": "" }, { "docid": "1eabde2211c65188f0b9843141fb8035", "score": "0.6150707", "text": "function doMigration(number) {\n\t\t\t\tvar deferred = $q.defer();\n\t\t\t\tif (migrations[number]) {\n\t\t\t\t\tdb.transaction(function (t) {\n\t\t\t\t\t\tt.executeSql(\"update \" + MIGRATOR_TABLE + \" set version = ?\", [number], function (t) {\n\t\t\t\t\t\t\t$log.info(\"Beginning migration \" + number);\n\t\t\t\t\t\t\tmigrations[number](t);\n\t\t\t\t\t\t\t$log.info(\"Completed migration \" + number);\n\t\t\t\t\t\t\tdoMigration(number + 1).then(function () {\n\t\t\t\t\t\t\t\treturn deferred.resolve();\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t}, function (t, err) {\n\t\t\t\t\t\t\t$log.error(\"Error!: %o (while upgrading to %s from %s)\", err, number);\n\t\t\t\t\t\t\tdeferred.reject(err);\n\t\t\t\t\t\t});\n\t\t\t\t\t});\n\t\t\t\t} else {\n\t\t\t\t\t$log.debug(\"Migrations complete.\");\n\t\t\t\t\tstate = 2;\n\t\t\t\t\tdeferred.resolve();\n\t\t\t\t}\n\n\t\t\t\treturn deferred.promise;\n\t\t\t}", "title": "" }, { "docid": "e1c83cb2d56fde103e0fb5536c504347", "score": "0.6127137", "text": "function run(migrationDir) {\n migrationDir = migrationDir || defaultMigrationDir;\n\n getMigrationsFromDisk(migrationDir)\n .then(function(migrations) {\n if (migrations.length === 0) {\n return Q(false);\n }\n\n return pgconnect(process.env.DATABASE_URL)\n .spread(function(client, done) {\n var pgquery = Q.nbind(client.query, client);\n\n return pgquery('BEGIN')\n .then(function() {\n return createMigrationTable(client)\n })\n .then(function() {\n return getMigrationsFromDb(client);\n })\n .then(function(dbMigrations) {\n return determineMigrationsToRun(migrations, dbMigrations);\n })\n .then(function(migrations) {\n return runMigrationsAgainstDb(client, migrations);\n })\n .then(function(numberOfMigrationsExecuted) {\n return pgquery('COMMIT')\n .then(function() {\n return Q(numberOfMigrationsExecuted);\n });\n })\n .then(function(numberOfMigrationsExecuted) {\n done(client);\n return Q(numberOfMigrationsExecuted);\n });\n\n }, function(err) {\n console.log(err);\n process.exit(1);\n });\n })\n .then(function(numberOfMigrationsExecuted) {\n if (numberOfMigrationsExecuted === 0) {\n console.log('Database is at latest version.');\n } else {\n console.log('Migration completed successfully.\\n\\t' + numberOfMigrationsExecuted + ' migrations executed');\n }\n return Q.resolve();\n })\n .fin(function() {\n pg.end();\n })\n .done();\n}", "title": "" }, { "docid": "f2dcc8ef88aee0b1976250349bb8e93e", "score": "0.61048", "text": "async function Migrate(callback){\n var storedMigrations = await db.SequelizeMeta.findAll({where:{},raw:true});\n \n const allList = _.pluck(storedMigrations,'name');\n \n var pendingList = [];\n if(migrationFiles.length){\n pendingList = migrationFiles.filter(ele=> {\n return allList.indexOf(ele) === -1;\n });\n\n if(pendingList.length){\n async.eachSeries(pendingList,function(file,callback){\n let module = require(migrationPath+'/'+file); \n module.down(db.sequelize.queryInterface,db.Sequelize).then(function(){\n return module.up(db.sequelize.queryInterface,db.Sequelize);\n }).then(function(){\n return db.SequelizeMeta.create({name:file}).then(function(result){\n callback(null);\n });\n }); \n \n },function(err){\n if(err){\n callback(err,null);\n }else{\n callback(null,true);\n }\n }); \n }else{\n console.log('There are no pending migrations');\n callback(null,true);\n }\n }\n }", "title": "" }, { "docid": "ada3442c09e403dce12e4fd73952b7b2", "score": "0.6096978", "text": "function runMigrationVersion (version, migrationCb) {\n console.log(`running migration ${version}: ${migrations[version]}`)\n\n // use a transaction to ensure version is\n // incremented only if the migration succeeds\n connHandler.beginTransaction(function (err) {\n if (err) return migrationCb(err)\n\n connHandler.query(migrations[version], (err) => {\n if (err) return migrationCb(err)\n\n connHandler.query('UPDATE version SET version = version + 1 LIMIT 1', migrationCb)\n })\n })\n }", "title": "" }, { "docid": "02eb691550a3e1ef1687d22929370b87", "score": "0.6047034", "text": "async function migrate(migrations, migrationTarget) { // Migrate the database to migrationTarget in migrations.\n let targetMigrationIndex = migrations.findIndex(m => m.name === migrationTarget); // Find the index of the migration named migrationTarget.\n if (targetMigrationIndex === -1) targetMigrationIndex = migrationTarget === 0 ? migrationTarget : (migrationTarget || migrations.length - 1); // If there's no migration to be found, treat migrationTarget as an index, or go to the last migration.\n const client = global.DB; // Grab a single connection from the pool for the migration transaction.\n try { // This might not work because I may have made a mistake in writing SQL. In which case we should ROLLBACK.\n console.log(`Migration target`, [client.config.database, targetMigrationIndex, (migrations[targetMigrationIndex] || { name: 'EMPTY' }).name]); // Where are we going?\n await client.query('BEGIN'); // Start migration transaction!\n await client.query(`CREATE TABLE IF NOT EXISTS migration (db_name TEXT NOT NULL PRIMARY KEY UNIQUE, latest_index INT NOT NULL DEFAULT -1, latest_name TEXT )`); // First time setup, create tables to keep track of current migration.\n await client.query(`CREATE TABLE IF NOT EXISTS migration_log (id SERIAL PRIMARY KEY, db_name TEXT, created_time TIMESTAMP DEFAULT NOW(), name TEXT, direction TEXT, query TEXT, index INT );`); // First time setup, create log of actions taken during migrations.\n var { rows: [migrationStatus] } = await client.query('SELECT * FROM migration WHERE db_name = $1', [client.config.database]); // Get the migration status.\n if (!migrationStatus) // No migration status. Try creating one.\n var { rows: [migrationStatus] } = await client.query(\"INSERT INTO migration (db_name) VALUES ($1) RETURNING *\", [client.config.database]); // Create the migration status!\n for (let i = parseInt(migrationStatus.latest_index); i > targetMigrationIndex; i--) { // If the migration target is below current migration, we need to roll back some migrations.\n await Promise.all(migrations[i].down.map(query => client.query(query))); // Take down a migration.\n await client.query('INSERT INTO migration_log (db_name, name, direction, query, index) VALUES ($1, $2, $3, $4, $5)', [client.config.database, migrations[i].name, 'down', migrations[i].down.join(\";\\n\") + ';', i.toString()]); // Log what we've done to the database.\n } // Migrations have been rolled back if needed.\n for (let i = parseInt(migrationStatus.latest_index) + 1; i <= targetMigrationIndex; i++) { // If the migration target is above current migration, let's up the unapplied migrations.\n await Promise.all(migrations[i].up.map(query => client.query(query))); // Bring up a migration.\n await client.query('INSERT INTO migration_log (db_name, name, direction, query, index) VALUES ($1, $2, $3, $4, $5)', [client.config.database, migrations[i].name, 'up', migrations[i].up.join(\";\\n\") + ';', i.toString()]); // Log what we have done to the database.\n } // Migrations have been applied if needed.\n await client.query('UPDATE migration SET latest_index = $1, latest_name = $2', [targetMigrationIndex.toString(), (migrations[targetMigrationIndex] || {}).name]); // Update migration status to match our actions.\n await client.query('COMMIT'); // Commit the migrations. Hooray!\n console.log((parseInt(migrationStatus.latest_index) === targetMigrationIndex) ? 'Migration already on target' : 'Migration COMMIT'); // Here's what I have done (or haven't done, more often.)\n } catch (err) { // I made a mistake in my SQL, please don't leave the database in a broken state.\n await client.query('ROLLBACK'); // Roll back the transaction!\n console.error('Migration ROLLBACK');\n throw err; // Pass the error on, we need to stop the program!\n }\n} // Our migrations have been applied and all is well under the moon.", "title": "" }, { "docid": "40e81b36012832a3cc9086aef4797fb0", "score": "0.60137737", "text": "async run() {\n const service = this.service;\n const usersTableName = this.getUsersTableName();\n const oldUsersTableName = this.getDepreciatedUsersTableName();\n const report = this.report;\n const usersItems = await this.loadUsersTable();\n const users = new UsersHolder({ usersTableName, oldUsersTableName, report });\n users.setItems(usersItems);\n\n // Do we have a status = 'completed' stored in the deployment store for this table\n const status = await service.findDeploymentItem(this.deploymentId);\n if (status === 'completed') {\n this.log.info(prefix('Users table migration - already migrated. Skipping'));\n return users;\n }\n\n try {\n this.log.info(prefix('Users table migration - started'));\n\n const oldUsersItems = await this.loadDepreciatedUsersTable();\n this.log.info(prefix(`Users table migration - examining ${_.size(oldUsersItems)} users`));\n const uncommittedItems = await users.getNewUserItems(oldUsersItems);\n if (!_.isEmpty(uncommittedItems)) {\n await this.updateUsers(uncommittedItems);\n } else {\n this.log.info(prefix('Users table migration - all users are accounted for, no need to update any rows'));\n }\n\n await service.saveDeploymentItem({ id: this.deploymentId, value: 'completed' });\n this.log.info(prefix('Users table migration - completed'));\n return users;\n } catch (error) {\n this.log.info(prefix('Users table migration - failed'));\n throw error;\n }\n }", "title": "" }, { "docid": "aba6072e5f5cd94eb0a5e05d241db31c", "score": "0.59965926", "text": "async function generateMigrationScript() {\n const configs = JSON.parse(fs.readFileSync(configPath, 'utf8'));\n for (let i = 0; i < dbTypes.length; i++) {\n const dbType = dbTypes[i];\n const config = configs[dbType];\n config.database = config.database || dbName;\n await clearDatabase(dbType, config);\n const connection = await typeorm.createConnection(config);\n oldMigration = path.join(migrationPath, dbType, fileName + '-typeorm.ts');\n\n //// Ne foncionne pas encore bien (pas eu le temps de finir) \n //// il faut enlever le false pour tenter de débug la gé nération de script de migration au lieu de seulement générer les scripts de création\n //// Problème liée au chargement du dernier script de création\n //// Erreur : \"la relation « excde_UNIQUE » existe déjà\"\n\n if (fs.existsSync(oldMigration) && false) {\n shell.exec('tsc ' + oldMigration + ' --outDir ' + path.join(mainPath, dbType));\n const createPath = path.join(mainPath, dbType, fileName + '-typeorm.js');\n const file = fs.readFileSync(createPath, 'utf8')\n .replace(new RegExp(lastDbName, 'g'), dbName);\n fs.writeFileSync(createPath, file);\n const req = require(createPath);\n await req[Object.keys(req)[1]].prototype.up(connection.createQueryRunner())\n .catch(err => {\n console.log(err);\n });\n }\n updateDataTypes(dbType);\n const ormconfig = '[' + JSON.stringify(config).replace('}', ',\"synchronize\":false,\"entities\":[\"entities/*.ts\"]}]');\n fs.writeFileSync('ormconfig.json', ormconfig);\n const errors = shell.exec(\"ts-node \" + path.join(directoryPath, \"node_modules/typeorm/cli.js\") + \" migration:generate -n migration-\" + dbType).stderr;\n await typeorm.getConnection().close();\n await clearDatabase(dbType, config);\n typeormMigrationToScript(dbType);\n if (errors) {\n return Promise.reject(errors);\n }\n }\n return Promise.resolve();\n}", "title": "" }, { "docid": "a64f20d90aad632c01f1ffdef321bb43", "score": "0.5990146", "text": "function runMigrationsAgainstDb(client, migrations) {\n var pgquery = Q.nbind(client.query, client);\n\n // create a chain of functions that execute the migrations against the DB so \n // that only the next migration is run after the previous one successfully \n // finishes.\n // \n // given a set of migrations like ['1.sql', '2.sql', '3.sql']\n // the result of the reduceRight operation will be \n // function() {\n // return runMigrationAgainstDb('1.sql')\n // .then(function() {\n // return runMigrationAgainstDb('2.sql')\n // .then(function() {\n // return runMigrationAgainstDb('3.sql')\n // .then(function() {\n // // last function\n // })\n // })\n // })\n // }\n return (migrations.reduceRight(function(next, migration) {\n return function(numberOfMigrationsExecuted) {\n console.log('executing migration: ', migration.filename);\n\n return runMigrationAgainstDb(client, migration)\n .then(function() {\n return pgquery('INSERT INTO migrations (filename) VALUES ($1)', [migration.filename]);\n })\n .then(function() {\n return next(numberOfMigrationsExecuted + 1);\n });\n };\n }, function(numberOfMigrationsExecuted) {\n // this is the last function to be executed in the chain\n return Q.resolve(numberOfMigrationsExecuted);\n }))(0);\n}", "title": "" }, { "docid": "1f7aeba2731082ada95bab14810c0419", "score": "0.59657264", "text": "function nextStep() {\n initModelNew();\n createNextGeneration();\n updateView();\n counter++;\n replace();\n}", "title": "" }, { "docid": "25ce335c6dfe2e916cf55e82beeed0a3", "score": "0.5858784", "text": "async function main() {\n try {\n const rollback = await db.migrate.rollback();\n const latest = await db.migrate.latest();\n if (rollback.length > 0) {\n console.log('database successfully rolledback');\n }\n\n if (latest.length > 0) {\n console.log('database successfully latest');\n }\n fetchVillage();\n } catch (err) {\n console.log({ message: err.message });\n }\n}", "title": "" }, { "docid": "9ff9b58a57ae2560d187edc0d9a504c9", "score": "0.58400226", "text": "startMigration() {\n this.loading.migrate = true;\n return this.TucPackMigrationProcess.startMigration()\n .then((migrationTask) => {\n this.process.migrationTaskId = migrationTask.id;\n this.process.currentStep = 'migration';\n })\n .catch((error) => {\n this.TucToast.error(\n [\n this.$translate.instant('telecom_pack_migration_error'),\n get(error, 'data.message', ''),\n ].join(' '),\n );\n return this.$q.reject(error);\n })\n .finally(() => {\n this.loading.migrate = false;\n });\n }", "title": "" }, { "docid": "91f579d3a0066a5f3251c662418983e3", "score": "0.5814032", "text": "function runMigration(direction, migrations) {\n return function (version, callback) {\n var key = lookup(version, migrations);\n\n if (!key) {\n var error = new Error('Could not find migration with the following lookup parameter: ' + _.quote(version));\n error.name = 'MigrationNotFound';\n return callback(error);\n }\n \n // Override the `query` method for the migration helpers with a version\n // that queues the intended query and immediately moves on. in a migration\n // we want to handle the queries in parallel.\n helpers.client.query = function query() {\n return QueryRunner.enqueue(arguments);\n };\n\n migrations[key][direction].bind(helpers)(helpers);\n QueryRunner.flush();\n QueryRunner.once('done', function (err) {\n // #TODO: pass back an error saying\n // - the version of the migration\n // - what went wrong\n // - exactly which query failed?\n if (err) return callback(err);\n var ver = (direction === 'up')\n ? key\n : previous(version, migrations);\n this.updateSchemaVersion(ver, callback);\n }.bind(this));\n\n };\n }", "title": "" }, { "docid": "ad5d41ca4eca7f973ea2d6ac04d0fdf4", "score": "0.57614625", "text": "async function down () { \n // Write migration here\n}", "title": "" }, { "docid": "560652afdfae3551dd6c7aab3e7f00bd", "score": "0.57411367", "text": "async runDown(batch) {\n if (this.app.inProduction && this.migrationsConfig.disableRollbacksInProduction) {\n throw new Error('Rollback in production environment is disabled. Check \"config/database\" file for options.');\n }\n if (batch === undefined) {\n batch = (await this.getLatestBatch()) - 1;\n }\n const existing = await this.getMigratedFilesTillBatch(batch);\n const collected = await this.migrationSource.getMigrations();\n /**\n * Finding schema files for migrations to rollback. We do not perform\n * rollback when any of the files are missing\n */\n existing.forEach((file) => {\n const migration = collected.find(({ name }) => name === file.name);\n if (!migration) {\n throw new utils_1.Exception(`Cannot perform rollback. Schema file {${file.name}} is missing`, 500, 'E_MISSING_SCHEMA_FILES');\n }\n this.migratedFiles[migration.name] = {\n status: 'pending',\n queries: [],\n file: migration,\n batch: file.batch,\n };\n });\n const filesToMigrate = Object.keys(this.migratedFiles);\n for (let name of filesToMigrate) {\n await this.executeMigration(this.migratedFiles[name].file);\n }\n }", "title": "" }, { "docid": "2ab5657e381b182934cc1ecbefd34e70", "score": "0.57056123", "text": "async function runUpgrades ({db, oldVersion, upgradeTransaction}) {\n // get the ones that haven't been run\n var upgrades = db._schemas.filter(s => s.version > oldVersion)\n db._activeSchema = db._schemas.filter(s => s.version <= oldVersion).reduce(Schemas.merge, {})\n if (oldVersion > 0 && !db._activeSchema) {\n throw new SchemaError(`Missing schema for previous version (${oldVersion}), unable to run upgrade.`)\n }\n debug(`running upgrade from ${oldVersion}, ${upgrades.length} upgrade(s) found`)\n\n // diff and apply changes\n var tablesToRebuild = []\n for (let schema of upgrades) {\n // compute diff\n debug(`applying upgrade for version ${schema.version}`)\n var diff = Schemas.diff(db._activeSchema, schema)\n\n // apply diff\n await Schemas.applyDiff(db, upgradeTransaction, diff)\n tablesToRebuild.push(diff.tablesToRebuild)\n\n // update current schema\n db._activeSchema = Schemas.merge(db._activeSchema, schema)\n debug(`version ${schema.version} applied`)\n }\n\n // track the tables that need rebuilding\n db._tablesToRebuild = Array.from(new Set(...tablesToRebuild))\n debug('Injest.runUpgrades complete', (db._tablesToRebuild.length === 0) ? '- no rebuilds needed' : 'REBUILD REQUIRED')\n}", "title": "" }, { "docid": "b3c1bd21d25b339e8adb068f968ff89f", "score": "0.5693898", "text": "async function migrate() {\n try {\n // TODO: This should use UserTable.create() instead of hardcoding the query, but I was having\n // more trouble publishing the sql package than I would have liked...\n await query(`\n CREATE TABLE IF NOT EXISTS user_data (\n id INT NOT NULL AUTO_INCREMENT PRIMARY KEY,\n email VARCHAR(100) NOT NULL,\n data TEXT NOT NULL\n )`);\n\n await query(`\n CREATE TABLE IF NOT EXISTS task_data (\n id INT NOT NULL AUTO_INCREMENT PRIMARY KEY,\n date DATE NOT NULL,\n task_name VARCHAR(100) NOT NULL,\n data TEXT\n )`);\n\n console.log(\"migration ran successfully\");\n } catch (e) {\n console.error(e.message);\n console.error(\"could not run migration, double check your credentials.\");\n process.exit(1);\n }\n}", "title": "" }, { "docid": "2f5bc6cc139691758596208190087537", "score": "0.5690154", "text": "function runDownMigrations(migrations) {\n\n //Done\n if (migrations.length === 0) {\n return Promise.resolve('Finished all migrations');\n }\n\n //Get migration\n let migration = migrations.shift();\n status.start('Rolling back migration', migration.file);\n\n //Load the script and run the migration\n return loadScript(migration.file)\n .then(script => checkHasMethod(script, 'down'))\n .then(runner => runner())\n .then(() => status.ok())\n .catch(MethodInvalid, error => status.skip(error.message))\n .catch(error => status.error(error))\n .then(() => Migration.remove(migration))\n .then(() => runDownMigrations(migrations));\n}", "title": "" }, { "docid": "f96c7d3cd870bc4eb93dbc6a19a3e045", "score": "0.5681093", "text": "function doMigrateApp() {\n L.info('Migrating app');\n }", "title": "" }, { "docid": "e8a8b63e3e1e9ab9396a790756fbe6c0", "score": "0.5671026", "text": "async migrate(config) {\n await migrate_1.migrate(this, config);\n }", "title": "" }, { "docid": "1a29361f938002b52c68d5251ba89948", "score": "0.567015", "text": "async onTakeoverMigration() {\n State.commit('swagMigration/process/setIsMigrating', true);\n State.commit('swagMigration/ui/setIsLoading', true);\n\n await this.migrationWorkerService.isMigrationRunningInOtherTab().then((isRunning) => {\n if (isRunning) {\n State.commit('swagMigration/ui/setIsLoading', false);\n this.isTakeoverForbidden = true;\n this.onInvalidMigrationAccessToken();\n }\n });\n\n if (this.isTakeoverForbidden) {\n return;\n }\n\n await this.migrationWorkerService.checkForRunningMigration().then((runState) => {\n if (runState.isMigrationRunning === false) {\n State.commit('swagMigration/process/setIsMigrating', false);\n State.commit('swagMigration/ui/setIsLoading', false);\n this.isOtherMigrationRunning = false;\n this.$router.push({ name: 'swag.migration.index.main' });\n return;\n }\n\n this.migrationWorkerService.takeoverMigration(runState.runUuid).then(() => {\n State.commit('swagMigration/ui/setIsLoading', false);\n this.migrationWorkerService.restoreRunningMigration();\n this.restoreRunningMigration();\n });\n });\n }", "title": "" }, { "docid": "db3d69734dbcb14aeada75e23a7fa382", "score": "0.5660407", "text": "function runMigration4(tx, callback) {\n\n function updateRows(rows) {\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var doc_id_rev = parseHexString(row.hex, encoding);\n var idx = doc_id_rev.lastIndexOf('::');\n var doc_id = doc_id_rev.substring(0, idx);\n var rev = doc_id_rev.substring(idx + 2);\n var sql = 'UPDATE ' + BY_SEQ_STORE +\n ' SET doc_id=?, rev=? WHERE doc_id_rev=?';\n tx.executeSql(sql, [doc_id, rev, doc_id_rev], function () {\n doNext();\n });\n }\n doNext();\n }\n\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN doc_id';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN rev';\n tx.executeSql(sql, [], function (tx) {\n tx.executeSql(BY_SEQ_STORE_DOC_ID_REV_INDEX_SQL, [], function (tx) {\n var sql = 'SELECT hex(doc_id_rev) as hex FROM ' + BY_SEQ_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n updateRows(rows);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "db3d69734dbcb14aeada75e23a7fa382", "score": "0.5660407", "text": "function runMigration4(tx, callback) {\n\n function updateRows(rows) {\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var doc_id_rev = parseHexString(row.hex, encoding);\n var idx = doc_id_rev.lastIndexOf('::');\n var doc_id = doc_id_rev.substring(0, idx);\n var rev = doc_id_rev.substring(idx + 2);\n var sql = 'UPDATE ' + BY_SEQ_STORE +\n ' SET doc_id=?, rev=? WHERE doc_id_rev=?';\n tx.executeSql(sql, [doc_id, rev, doc_id_rev], function () {\n doNext();\n });\n }\n doNext();\n }\n\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN doc_id';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN rev';\n tx.executeSql(sql, [], function (tx) {\n tx.executeSql(BY_SEQ_STORE_DOC_ID_REV_INDEX_SQL, [], function (tx) {\n var sql = 'SELECT hex(doc_id_rev) as hex FROM ' + BY_SEQ_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n updateRows(rows);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "db3d69734dbcb14aeada75e23a7fa382", "score": "0.5660407", "text": "function runMigration4(tx, callback) {\n\n function updateRows(rows) {\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var doc_id_rev = parseHexString(row.hex, encoding);\n var idx = doc_id_rev.lastIndexOf('::');\n var doc_id = doc_id_rev.substring(0, idx);\n var rev = doc_id_rev.substring(idx + 2);\n var sql = 'UPDATE ' + BY_SEQ_STORE +\n ' SET doc_id=?, rev=? WHERE doc_id_rev=?';\n tx.executeSql(sql, [doc_id, rev, doc_id_rev], function () {\n doNext();\n });\n }\n doNext();\n }\n\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN doc_id';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN rev';\n tx.executeSql(sql, [], function (tx) {\n tx.executeSql(BY_SEQ_STORE_DOC_ID_REV_INDEX_SQL, [], function (tx) {\n var sql = 'SELECT hex(doc_id_rev) as hex FROM ' + BY_SEQ_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n updateRows(rows);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "db3d69734dbcb14aeada75e23a7fa382", "score": "0.5660407", "text": "function runMigration4(tx, callback) {\n\n function updateRows(rows) {\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var doc_id_rev = parseHexString(row.hex, encoding);\n var idx = doc_id_rev.lastIndexOf('::');\n var doc_id = doc_id_rev.substring(0, idx);\n var rev = doc_id_rev.substring(idx + 2);\n var sql = 'UPDATE ' + BY_SEQ_STORE +\n ' SET doc_id=?, rev=? WHERE doc_id_rev=?';\n tx.executeSql(sql, [doc_id, rev, doc_id_rev], function () {\n doNext();\n });\n }\n doNext();\n }\n\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN doc_id';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE + ' ADD COLUMN rev';\n tx.executeSql(sql, [], function (tx) {\n tx.executeSql(BY_SEQ_STORE_DOC_ID_REV_INDEX_SQL, [], function (tx) {\n var sql = 'SELECT hex(doc_id_rev) as hex FROM ' + BY_SEQ_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n updateRows(rows);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "32931ebe4da28a9c12f701c86a889ef7", "score": "0.5657197", "text": "function runMigration4(tx, callback) {\n\n function updateRows(rows) {\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var doc_id_rev = parseHexString(row.hex, encoding);\n var idx = doc_id_rev.lastIndexOf('::');\n var doc_id = doc_id_rev.substring(0, idx);\n var rev$$1 = doc_id_rev.substring(idx + 2);\n var sql = 'UPDATE ' + BY_SEQ_STORE$1 +\n ' SET doc_id=?, rev=? WHERE doc_id_rev=?';\n tx.executeSql(sql, [doc_id, rev$$1, doc_id_rev], function () {\n doNext();\n });\n }\n doNext();\n }\n\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE$1 + ' ADD COLUMN doc_id';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'ALTER TABLE ' + BY_SEQ_STORE$1 + ' ADD COLUMN rev';\n tx.executeSql(sql, [], function (tx) {\n tx.executeSql(BY_SEQ_STORE_DOC_ID_REV_INDEX_SQL, [], function (tx) {\n var sql = 'SELECT hex(doc_id_rev) as hex FROM ' + BY_SEQ_STORE$1;\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n updateRows(rows);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "70a24deaae461cc724482f44ee7a16fe", "score": "0.5646148", "text": "function startDataMigration() {\n mysql.query(`select * from leases where id >= ${offset}`)\n .on('result', async (row) => {\n mysql.pause()\n try {\n let user = getUserFrom(row)\n let savedUser = await findOrCreateUser(user)\n let biz = getBusinessFrom(row)\n let loan = getLoanFrom(row)\n biz.user = savedUser\n loan.user = savedUser\n let bizloan = await Promise.all(\n [findOrcreateBusiness(biz), findOrCreateLoan(loan)]\n )\n console.log(row.id)\n offset = row.id\n mysql.resume()\n } catch (e) {\n throw e\n }\n })\n .on('error', (err) => {\n console.log('error ocurred at offset ' + offset)\n startDataMigration()\n })\n }", "title": "" }, { "docid": "caa95dfbffd64fe29b6719c543faf2b1", "score": "0.564207", "text": "function runMigration2(tx, callback) {\n // index used for the join in the allDocs query\n tx.executeSql(DOC_STORE_WINNINGSEQ_INDEX_SQL);\n\n tx.executeSql('ALTER TABLE ' + BY_SEQ_STORE +\n ' ADD COLUMN deleted TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql(BY_SEQ_STORE_DELETED_INDEX_SQL);\n tx.executeSql('ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN local TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql('CREATE INDEX IF NOT EXISTS \\'doc-store-local-idx\\' ON ' +\n DOC_STORE + ' (local, id)');\n\n var sql = 'SELECT ' + DOC_STORE + '.winningseq AS seq, ' + DOC_STORE +\n '.json AS metadata FROM ' + BY_SEQ_STORE + ' JOIN ' + DOC_STORE +\n ' ON ' + BY_SEQ_STORE + '.seq = ' + DOC_STORE + '.winningseq';\n\n tx.executeSql(sql, [], function (tx, result) {\n\n var deleted = [];\n var local = [];\n\n for (var i = 0; i < result.rows.length; i++) {\n var item = result.rows.item(i);\n var seq = item.seq;\n var metadata = JSON.parse(item.metadata);\n if (isDeleted(metadata)) {\n deleted.push(seq);\n }\n if (isLocalId(metadata.id)) {\n local.push(metadata.id);\n }\n }\n tx.executeSql('UPDATE ' + DOC_STORE + 'SET local = 1 WHERE id IN ' +\n qMarks(local.length), local, function () {\n tx.executeSql('UPDATE ' + BY_SEQ_STORE +\n ' SET deleted = 1 WHERE seq IN ' +\n qMarks(deleted.length), deleted, callback);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "caa95dfbffd64fe29b6719c543faf2b1", "score": "0.564207", "text": "function runMigration2(tx, callback) {\n // index used for the join in the allDocs query\n tx.executeSql(DOC_STORE_WINNINGSEQ_INDEX_SQL);\n\n tx.executeSql('ALTER TABLE ' + BY_SEQ_STORE +\n ' ADD COLUMN deleted TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql(BY_SEQ_STORE_DELETED_INDEX_SQL);\n tx.executeSql('ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN local TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql('CREATE INDEX IF NOT EXISTS \\'doc-store-local-idx\\' ON ' +\n DOC_STORE + ' (local, id)');\n\n var sql = 'SELECT ' + DOC_STORE + '.winningseq AS seq, ' + DOC_STORE +\n '.json AS metadata FROM ' + BY_SEQ_STORE + ' JOIN ' + DOC_STORE +\n ' ON ' + BY_SEQ_STORE + '.seq = ' + DOC_STORE + '.winningseq';\n\n tx.executeSql(sql, [], function (tx, result) {\n\n var deleted = [];\n var local = [];\n\n for (var i = 0; i < result.rows.length; i++) {\n var item = result.rows.item(i);\n var seq = item.seq;\n var metadata = JSON.parse(item.metadata);\n if (isDeleted(metadata)) {\n deleted.push(seq);\n }\n if (isLocalId(metadata.id)) {\n local.push(metadata.id);\n }\n }\n tx.executeSql('UPDATE ' + DOC_STORE + 'SET local = 1 WHERE id IN ' +\n qMarks(local.length), local, function () {\n tx.executeSql('UPDATE ' + BY_SEQ_STORE +\n ' SET deleted = 1 WHERE seq IN ' +\n qMarks(deleted.length), deleted, callback);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "b51af7b4f08e6afb12a3b1d29ce268e6", "score": "0.5636965", "text": "function runMigration2(tx, callback) {\n // index used for the join in the allDocs query\n tx.executeSql(DOC_STORE_WINNINGSEQ_INDEX_SQL);\n\n tx.executeSql('ALTER TABLE ' + BY_SEQ_STORE$1 +\n ' ADD COLUMN deleted TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql(BY_SEQ_STORE_DELETED_INDEX_SQL);\n tx.executeSql('ALTER TABLE ' + DOC_STORE$1 +\n ' ADD COLUMN local TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql('CREATE INDEX IF NOT EXISTS \\'doc-store-local-idx\\' ON ' +\n DOC_STORE$1 + ' (local, id)');\n\n var sql = 'SELECT ' + DOC_STORE$1 + '.winningseq AS seq, ' + DOC_STORE$1 +\n '.json AS metadata FROM ' + BY_SEQ_STORE$1 + ' JOIN ' + DOC_STORE$1 +\n ' ON ' + BY_SEQ_STORE$1 + '.seq = ' + DOC_STORE$1 + '.winningseq';\n\n tx.executeSql(sql, [], function (tx, result) {\n\n var deleted = [];\n var local = [];\n\n for (var i = 0; i < result.rows.length; i++) {\n var item = result.rows.item(i);\n var seq = item.seq;\n var metadata = JSON.parse(item.metadata);\n if (isDeleted(metadata)) {\n deleted.push(seq);\n }\n if (isLocalId(metadata.id)) {\n local.push(metadata.id);\n }\n }\n tx.executeSql('UPDATE ' + DOC_STORE$1 + 'SET local = 1 WHERE id IN ' +\n qMarks(local.length), local, function () {\n tx.executeSql('UPDATE ' + BY_SEQ_STORE$1 +\n ' SET deleted = 1 WHERE seq IN ' +\n qMarks(deleted.length), deleted, callback);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "faf1bc96c12dca9bd97fac650e09db31", "score": "0.5623042", "text": "function runMigration2(tx, callback) {\n // index used for the join in the allDocs query\n tx.executeSql(DOC_STORE_WINNINGSEQ_INDEX_SQL);\n\n tx.executeSql('ALTER TABLE ' + BY_SEQ_STORE +\n ' ADD COLUMN deleted TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql(BY_SEQ_STORE_DELETED_INDEX_SQL);\n tx.executeSql('ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN local TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql('CREATE INDEX IF NOT EXISTS \\'doc-store-local-idx\\' ON ' +\n DOC_STORE + ' (local, id)');\n\n var sql = 'SELECT ' + DOC_STORE + '.winningseq AS seq, ' + DOC_STORE +\n '.json AS metadata FROM ' + BY_SEQ_STORE + ' JOIN ' + DOC_STORE +\n ' ON ' + BY_SEQ_STORE + '.seq = ' + DOC_STORE + '.winningseq';\n\n tx.executeSql(sql, [], function (tx, result) {\n\n var deleted = [];\n var local = [];\n\n for (var i = 0; i < result.rows.length; i++) {\n var item = result.rows.item(i);\n var seq = item.seq;\n var metadata = JSON.parse(item.metadata);\n if (utils.isDeleted(metadata)) {\n deleted.push(seq);\n }\n if (utils.isLocalId(metadata.id)) {\n local.push(metadata.id);\n }\n }\n tx.executeSql('UPDATE ' + DOC_STORE + 'SET local = 1 WHERE id IN ' +\n qMarks(local.length), local, function () {\n tx.executeSql('UPDATE ' + BY_SEQ_STORE +\n ' SET deleted = 1 WHERE seq IN ' +\n qMarks(deleted.length), deleted, callback);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "faf1bc96c12dca9bd97fac650e09db31", "score": "0.5623042", "text": "function runMigration2(tx, callback) {\n // index used for the join in the allDocs query\n tx.executeSql(DOC_STORE_WINNINGSEQ_INDEX_SQL);\n\n tx.executeSql('ALTER TABLE ' + BY_SEQ_STORE +\n ' ADD COLUMN deleted TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql(BY_SEQ_STORE_DELETED_INDEX_SQL);\n tx.executeSql('ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN local TINYINT(1) DEFAULT 0', [], function () {\n tx.executeSql('CREATE INDEX IF NOT EXISTS \\'doc-store-local-idx\\' ON ' +\n DOC_STORE + ' (local, id)');\n\n var sql = 'SELECT ' + DOC_STORE + '.winningseq AS seq, ' + DOC_STORE +\n '.json AS metadata FROM ' + BY_SEQ_STORE + ' JOIN ' + DOC_STORE +\n ' ON ' + BY_SEQ_STORE + '.seq = ' + DOC_STORE + '.winningseq';\n\n tx.executeSql(sql, [], function (tx, result) {\n\n var deleted = [];\n var local = [];\n\n for (var i = 0; i < result.rows.length; i++) {\n var item = result.rows.item(i);\n var seq = item.seq;\n var metadata = JSON.parse(item.metadata);\n if (utils.isDeleted(metadata)) {\n deleted.push(seq);\n }\n if (utils.isLocalId(metadata.id)) {\n local.push(metadata.id);\n }\n }\n tx.executeSql('UPDATE ' + DOC_STORE + 'SET local = 1 WHERE id IN ' +\n qMarks(local.length), local, function () {\n tx.executeSql('UPDATE ' + BY_SEQ_STORE +\n ' SET deleted = 1 WHERE seq IN ' +\n qMarks(deleted.length), deleted, callback);\n });\n });\n });\n });\n }", "title": "" }, { "docid": "b1404d1e7b5e62db45b241c149282542", "score": "0.5584918", "text": "function nextSeed() {\n\tsetSeed();\n\treroll();\n}", "title": "" }, { "docid": "a20c2bc764a59a171b48432a040e18f4", "score": "0.55603606", "text": "async function migrationSeed(callback){\n \n var pendingFiles;\n var storageSeeds = await db.SequelizeData.findAll({where:{},raw:true});\n storageSeeds = _.pluck(storageSeeds,'name');\n pendingFiles = seedFiles.filter(ele => {\n return storageSeeds.indexOf(ele) === -1;\n });\n\n async.eachSeries(pendingFiles,function(file,callback){\n let module = require(seedPath+'/'+file);\n module.down(db.sequelize.queryInterface,db.Sequelize)\n .then(function(){\n return module.up(db.sequelize.queryInterface,db.Sequelize)\n }).then(function(){\n db.SequelizeData.create({\n name:file\n }).then(function(result){\n console.log('Successfully updated seed:::',file)\n callback(null);\n });\n }).catch(err => {\n callback(err,null);\n }) \n },function(err){\n if(err){ \n callback(err,null);\n }else{\n \n callback(null,true);\n }\n }); \n }", "title": "" }, { "docid": "e361bfb3f2b11d67d62ca6921f798c56", "score": "0.5512327", "text": "async function down () {\n // Write migration here\n}", "title": "" }, { "docid": "f35238e4837421f7100d41fcb1b31dba", "score": "0.5463111", "text": "_waterfallBatch(batchNo, migrations, direction, trx) {\n const trxOrKnex = trx || this.knex;\n const { tableName, schemaName, disableTransactions } = this.config;\n let current = Promise.resolve();\n const log = [];\n each$1(migrations, (migration) => {\n const name = this.config.migrationSource.getMigrationName(migration);\n this._activeMigration.fileName = name;\n const migrationContent = this.config.migrationSource.getMigration(\n migration\n );\n\n // We're going to run each of the migrations in the current \"up\".\n current = current\n .then(() => {\n this._activeMigration.fileName = name;\n if (\n !trx &&\n this._useTransaction(migrationContent, disableTransactions)\n ) {\n this.knex.enableProcessing();\n return this._transaction(\n this.knex,\n migrationContent,\n direction,\n name\n );\n }\n\n trxOrKnex.enableProcessing();\n return checkPromise(\n this.knex.client.logger,\n migrationContent[direction](trxOrKnex),\n name\n );\n })\n .then(() => {\n trxOrKnex.disableProcessing();\n this.knex.disableProcessing();\n log.push(name);\n if (direction === 'up') {\n return trxOrKnex\n .into(getTableName$3(tableName, schemaName))\n .insert({\n name,\n batch: batchNo,\n migration_time: new Date(),\n });\n }\n if (direction === 'down') {\n return trxOrKnex\n .from(getTableName$3(tableName, schemaName))\n .where({ name })\n .del();\n }\n });\n });\n\n return current.then(() => [batchNo, log]);\n }", "title": "" }, { "docid": "df998267d53b5cbfb244dc4b209f65a9", "score": "0.54428756", "text": "async migrateFromBeta () {\n return migrateFromBeta.migrate(self.knex)\n }", "title": "" }, { "docid": "036f708d8dff8ca18c70e17225515736", "score": "0.5434472", "text": "function run() {\n // Run the first test from the tests array\n if (tests.length > 0) {\n tests[0](function () { \n doNext();\n });\n }\n else {\n console.log(\"cleaning up db connection\")\n sqlutils.endConnection();\n }\n}", "title": "" }, { "docid": "d7285033afe3343f4af8ac146ba2ef4e", "score": "0.542831", "text": "_runBatch(migrations, direction, trx) {\n return (\n this._getLock(trx)\n // When there is a wrapping transaction, some migrations\n // could have been done while waiting for the lock:\n .then(() =>\n trx\n ? migrationListResolver.listCompleted(\n this.config.tableName,\n this.config.schemaName,\n trx\n )\n : []\n )\n .then(\n (completed) =>\n (migrations = getNewMigrations(\n this.config.migrationSource,\n migrations,\n completed\n ))\n )\n .then(() =>\n Promise.all(\n migrations.map(this._validateMigrationStructure.bind(this))\n )\n )\n .then(() => this._latestBatchNumber(trx))\n .then((batchNo) => {\n if (direction === 'up') batchNo++;\n return batchNo;\n })\n .then((batchNo) => {\n return this._waterfallBatch(batchNo, migrations, direction, trx);\n })\n .then(async (res) => {\n await this._freeLock(trx);\n return res;\n })\n .catch(async (error) => {\n let cleanupReady = Promise.resolve();\n\n if (error instanceof LockError) {\n // If locking error do not free the lock.\n this.knex.client.logger.warn(\n `Can't take lock to run migrations: ${error.message}`\n );\n this.knex.client.logger.warn(\n 'If you are sure migrations are not running you can release the ' +\n 'lock manually by deleting all the rows = require(migrations lock ' +\n 'table: ' +\n getLockTableNameWithSchema$2(\n this.config.tableName,\n this.config.schemaName\n )\n );\n } else {\n if (this._activeMigration.fileName) {\n this.knex.client.logger.warn(\n `migration file \"${this._activeMigration.fileName}\" failed`\n );\n }\n this.knex.client.logger.warn(\n `migration failed with error: ${error.message}`\n );\n // If the error was not due to a locking issue, then remove the lock.\n cleanupReady = this._freeLock(trx);\n }\n\n try {\n await cleanupReady;\n // eslint-disable-next-line no-empty\n } catch (e) {}\n throw error;\n })\n );\n }", "title": "" }, { "docid": "f1a0c9f7695430d1daa58b08b2e51126", "score": "0.53964746", "text": "onConfiscatedMigration() {\n this.onInvalidMigrationAccessToken();\n this.isMigrationInterrupted = true;\n this.$nextTick(() => {\n this.$refs.loadingScreenTakeover.refreshState();\n });\n }", "title": "" }, { "docid": "72dad00d3890e4bd0634ca53c0fd1583", "score": "0.5383207", "text": "function runMigration7(tx, callback) {\n var sql = 'ALTER TABLE ' + DOC_STORE$1 +\n ' ADD COLUMN max_seq INTEGER';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'UPDATE ' + DOC_STORE$1 + ' SET max_seq=(SELECT MAX(seq) FROM ' +\n BY_SEQ_STORE$1 + ' WHERE doc_id=id)';\n tx.executeSql(sql, [], function (tx) {\n // add unique index after filling, else we'll get a constraint\n // error when we do the ALTER TABLE\n var sql =\n 'CREATE UNIQUE INDEX IF NOT EXISTS \\'doc-max-seq-idx\\' ON ' +\n DOC_STORE$1 + ' (max_seq)';\n tx.executeSql(sql, [], callback);\n });\n });\n }", "title": "" }, { "docid": "f1145ff7a5f62909cad13a7f8e2d7df2", "score": "0.53502125", "text": "function runMigration7(tx, callback) {\n var sql = 'ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN max_seq INTEGER';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'UPDATE ' + DOC_STORE + ' SET max_seq=(SELECT MAX(seq) FROM ' +\n BY_SEQ_STORE + ' WHERE doc_id=id)';\n tx.executeSql(sql, [], function (tx) {\n // add unique index after filling, else we'll get a constraint\n // error when we do the ALTER TABLE\n var sql =\n 'CREATE UNIQUE INDEX IF NOT EXISTS \\'doc-max-seq-idx\\' ON ' +\n DOC_STORE + ' (max_seq)';\n tx.executeSql(sql, [], callback);\n });\n });\n }", "title": "" }, { "docid": "f1145ff7a5f62909cad13a7f8e2d7df2", "score": "0.53502125", "text": "function runMigration7(tx, callback) {\n var sql = 'ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN max_seq INTEGER';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'UPDATE ' + DOC_STORE + ' SET max_seq=(SELECT MAX(seq) FROM ' +\n BY_SEQ_STORE + ' WHERE doc_id=id)';\n tx.executeSql(sql, [], function (tx) {\n // add unique index after filling, else we'll get a constraint\n // error when we do the ALTER TABLE\n var sql =\n 'CREATE UNIQUE INDEX IF NOT EXISTS \\'doc-max-seq-idx\\' ON ' +\n DOC_STORE + ' (max_seq)';\n tx.executeSql(sql, [], callback);\n });\n });\n }", "title": "" }, { "docid": "f1145ff7a5f62909cad13a7f8e2d7df2", "score": "0.53502125", "text": "function runMigration7(tx, callback) {\n var sql = 'ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN max_seq INTEGER';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'UPDATE ' + DOC_STORE + ' SET max_seq=(SELECT MAX(seq) FROM ' +\n BY_SEQ_STORE + ' WHERE doc_id=id)';\n tx.executeSql(sql, [], function (tx) {\n // add unique index after filling, else we'll get a constraint\n // error when we do the ALTER TABLE\n var sql =\n 'CREATE UNIQUE INDEX IF NOT EXISTS \\'doc-max-seq-idx\\' ON ' +\n DOC_STORE + ' (max_seq)';\n tx.executeSql(sql, [], callback);\n });\n });\n }", "title": "" }, { "docid": "f1145ff7a5f62909cad13a7f8e2d7df2", "score": "0.53502125", "text": "function runMigration7(tx, callback) {\n var sql = 'ALTER TABLE ' + DOC_STORE +\n ' ADD COLUMN max_seq INTEGER';\n tx.executeSql(sql, [], function (tx) {\n var sql = 'UPDATE ' + DOC_STORE + ' SET max_seq=(SELECT MAX(seq) FROM ' +\n BY_SEQ_STORE + ' WHERE doc_id=id)';\n tx.executeSql(sql, [], function (tx) {\n // add unique index after filling, else we'll get a constraint\n // error when we do the ALTER TABLE\n var sql =\n 'CREATE UNIQUE INDEX IF NOT EXISTS \\'doc-max-seq-idx\\' ON ' +\n DOC_STORE + ' (max_seq)';\n tx.executeSql(sql, [], callback);\n });\n });\n }", "title": "" }, { "docid": "e5179cebc69cce20e5ae5ecbea258b2b", "score": "0.53455895", "text": "onStop() {\n return this.migrationService.abortMigration(this.runId).then(() => {\n this.showAbortMigrationConfirmDialog = false;\n this.isMigrationInterrupted = false;\n State.commit('swagMigration/process/setIsMigrating', false);\n State.commit('swagMigration/ui/setIsPaused', false);\n State.commit('swagMigration/ui/setIsLoading', false);\n this.$nextTick(() => {\n this.$router.push({ name: 'swag.migration.index.main' });\n });\n });\n }", "title": "" }, { "docid": "39975ea0036e27017a2bbe6900a17020", "score": "0.5342107", "text": "function runMigration5(tx, callback) {\n\n function migrateAttsAndSeqs(tx) {\n // need to actually populate the table. this is the expensive part,\n // so as an optimization, check first that this database even\n // contains attachments\n var sql = 'SELECT COUNT(*) AS cnt FROM ' + ATTACH_STORE$1;\n tx.executeSql(sql, [], function (tx, res) {\n var count = res.rows.item(0).cnt;\n if (!count) {\n return callback(tx);\n }\n\n var offset = 0;\n var pageSize = 10;\n function nextPage() {\n var sql = select(\n SELECT_DOCS + ', ' + DOC_STORE$1 + '.id AS id',\n [DOC_STORE$1, BY_SEQ_STORE$1],\n DOC_STORE_AND_BY_SEQ_JOINER,\n null,\n DOC_STORE$1 + '.id '\n );\n sql += ' LIMIT ' + pageSize + ' OFFSET ' + offset;\n offset += pageSize;\n tx.executeSql(sql, [], function (tx, res) {\n if (!res.rows.length) {\n return callback(tx);\n }\n var digestSeqs = {};\n function addDigestSeq(digest, seq) {\n // uniq digest/seq pairs, just in case there are dups\n var seqs = digestSeqs[digest] = (digestSeqs[digest] || []);\n if (seqs.indexOf(seq) === -1) {\n seqs.push(seq);\n }\n }\n for (var i = 0; i < res.rows.length; i++) {\n var row = res.rows.item(i);\n var doc = unstringifyDoc(row.data, row.id, row.rev);\n var atts = Object.keys(doc._attachments || {});\n for (var j = 0; j < atts.length; j++) {\n var att = doc._attachments[atts[j]];\n addDigestSeq(att.digest, row.seq);\n }\n }\n var digestSeqPairs = [];\n Object.keys(digestSeqs).forEach(function (digest) {\n var seqs = digestSeqs[digest];\n seqs.forEach(function (seq) {\n digestSeqPairs.push([digest, seq]);\n });\n });\n if (!digestSeqPairs.length) {\n return nextPage();\n }\n var numDone = 0;\n digestSeqPairs.forEach(function (pair) {\n var sql = 'INSERT INTO ' + ATTACH_AND_SEQ_STORE$1 +\n ' (digest, seq) VALUES (?,?)';\n tx.executeSql(sql, pair, function () {\n if (++numDone === digestSeqPairs.length) {\n nextPage();\n }\n });\n });\n });\n }\n nextPage();\n });\n }\n\n var attachAndRev = 'CREATE TABLE IF NOT EXISTS ' +\n ATTACH_AND_SEQ_STORE$1 + ' (digest, seq INTEGER)';\n tx.executeSql(attachAndRev, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_ATTACH_INDEX_SQL, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_SEQ_INDEX_SQL, [],\n migrateAttsAndSeqs);\n });\n });\n }", "title": "" }, { "docid": "20eb2b6931cb7cd6d3d9aab706b8430a", "score": "0.5336693", "text": "function runMigration5(tx, callback) {\n\n function migrateAttsAndSeqs(tx) {\n // need to actually populate the table. this is the expensive part,\n // so as an optimization, check first that this database even\n // contains attachments\n var sql = 'SELECT COUNT(*) AS cnt FROM ' + ATTACH_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var count = res.rows.item(0).cnt;\n if (!count) {\n return callback(tx);\n }\n\n var offset = 0;\n var pageSize = 10;\n function nextPage() {\n var sql = select(\n SELECT_DOCS + ', ' + DOC_STORE + '.id AS id',\n [DOC_STORE, BY_SEQ_STORE],\n DOC_STORE_AND_BY_SEQ_JOINER,\n null,\n DOC_STORE + '.id '\n );\n sql += ' LIMIT ' + pageSize + ' OFFSET ' + offset;\n offset += pageSize;\n tx.executeSql(sql, [], function (tx, res) {\n if (!res.rows.length) {\n return callback(tx);\n }\n var digestSeqs = {};\n function addDigestSeq(digest, seq) {\n // uniq digest/seq pairs, just in case there are dups\n var seqs = digestSeqs[digest] = (digestSeqs[digest] || []);\n if (seqs.indexOf(seq) === -1) {\n seqs.push(seq);\n }\n }\n for (var i = 0; i < res.rows.length; i++) {\n var row = res.rows.item(i);\n var doc = unstringifyDoc(row.data, row.id, row.rev);\n var atts = Object.keys(doc._attachments || {});\n for (var j = 0; j < atts.length; j++) {\n var att = doc._attachments[atts[j]];\n addDigestSeq(att.digest, row.seq);\n }\n }\n var digestSeqPairs = [];\n Object.keys(digestSeqs).forEach(function (digest) {\n var seqs = digestSeqs[digest];\n seqs.forEach(function (seq) {\n digestSeqPairs.push([digest, seq]);\n });\n });\n if (!digestSeqPairs.length) {\n return nextPage();\n }\n var numDone = 0;\n digestSeqPairs.forEach(function (pair) {\n var sql = 'INSERT INTO ' + ATTACH_AND_SEQ_STORE +\n ' (digest, seq) VALUES (?,?)';\n tx.executeSql(sql, pair, function () {\n if (++numDone === digestSeqPairs.length) {\n nextPage();\n }\n });\n });\n });\n }\n nextPage();\n });\n }\n\n var attachAndRev = 'CREATE TABLE IF NOT EXISTS ' +\n ATTACH_AND_SEQ_STORE + ' (digest, seq INTEGER)';\n tx.executeSql(attachAndRev, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_ATTACH_INDEX_SQL, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_SEQ_INDEX_SQL, [],\n migrateAttsAndSeqs);\n });\n });\n }", "title": "" }, { "docid": "20eb2b6931cb7cd6d3d9aab706b8430a", "score": "0.5336693", "text": "function runMigration5(tx, callback) {\n\n function migrateAttsAndSeqs(tx) {\n // need to actually populate the table. this is the expensive part,\n // so as an optimization, check first that this database even\n // contains attachments\n var sql = 'SELECT COUNT(*) AS cnt FROM ' + ATTACH_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var count = res.rows.item(0).cnt;\n if (!count) {\n return callback(tx);\n }\n\n var offset = 0;\n var pageSize = 10;\n function nextPage() {\n var sql = select(\n SELECT_DOCS + ', ' + DOC_STORE + '.id AS id',\n [DOC_STORE, BY_SEQ_STORE],\n DOC_STORE_AND_BY_SEQ_JOINER,\n null,\n DOC_STORE + '.id '\n );\n sql += ' LIMIT ' + pageSize + ' OFFSET ' + offset;\n offset += pageSize;\n tx.executeSql(sql, [], function (tx, res) {\n if (!res.rows.length) {\n return callback(tx);\n }\n var digestSeqs = {};\n function addDigestSeq(digest, seq) {\n // uniq digest/seq pairs, just in case there are dups\n var seqs = digestSeqs[digest] = (digestSeqs[digest] || []);\n if (seqs.indexOf(seq) === -1) {\n seqs.push(seq);\n }\n }\n for (var i = 0; i < res.rows.length; i++) {\n var row = res.rows.item(i);\n var doc = unstringifyDoc(row.data, row.id, row.rev);\n var atts = Object.keys(doc._attachments || {});\n for (var j = 0; j < atts.length; j++) {\n var att = doc._attachments[atts[j]];\n addDigestSeq(att.digest, row.seq);\n }\n }\n var digestSeqPairs = [];\n Object.keys(digestSeqs).forEach(function (digest) {\n var seqs = digestSeqs[digest];\n seqs.forEach(function (seq) {\n digestSeqPairs.push([digest, seq]);\n });\n });\n if (!digestSeqPairs.length) {\n return nextPage();\n }\n var numDone = 0;\n digestSeqPairs.forEach(function (pair) {\n var sql = 'INSERT INTO ' + ATTACH_AND_SEQ_STORE +\n ' (digest, seq) VALUES (?,?)';\n tx.executeSql(sql, pair, function () {\n if (++numDone === digestSeqPairs.length) {\n nextPage();\n }\n });\n });\n });\n }\n nextPage();\n });\n }\n\n var attachAndRev = 'CREATE TABLE IF NOT EXISTS ' +\n ATTACH_AND_SEQ_STORE + ' (digest, seq INTEGER)';\n tx.executeSql(attachAndRev, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_ATTACH_INDEX_SQL, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_SEQ_INDEX_SQL, [],\n migrateAttsAndSeqs);\n });\n });\n }", "title": "" }, { "docid": "20eb2b6931cb7cd6d3d9aab706b8430a", "score": "0.5336693", "text": "function runMigration5(tx, callback) {\n\n function migrateAttsAndSeqs(tx) {\n // need to actually populate the table. this is the expensive part,\n // so as an optimization, check first that this database even\n // contains attachments\n var sql = 'SELECT COUNT(*) AS cnt FROM ' + ATTACH_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var count = res.rows.item(0).cnt;\n if (!count) {\n return callback(tx);\n }\n\n var offset = 0;\n var pageSize = 10;\n function nextPage() {\n var sql = select(\n SELECT_DOCS + ', ' + DOC_STORE + '.id AS id',\n [DOC_STORE, BY_SEQ_STORE],\n DOC_STORE_AND_BY_SEQ_JOINER,\n null,\n DOC_STORE + '.id '\n );\n sql += ' LIMIT ' + pageSize + ' OFFSET ' + offset;\n offset += pageSize;\n tx.executeSql(sql, [], function (tx, res) {\n if (!res.rows.length) {\n return callback(tx);\n }\n var digestSeqs = {};\n function addDigestSeq(digest, seq) {\n // uniq digest/seq pairs, just in case there are dups\n var seqs = digestSeqs[digest] = (digestSeqs[digest] || []);\n if (seqs.indexOf(seq) === -1) {\n seqs.push(seq);\n }\n }\n for (var i = 0; i < res.rows.length; i++) {\n var row = res.rows.item(i);\n var doc = unstringifyDoc(row.data, row.id, row.rev);\n var atts = Object.keys(doc._attachments || {});\n for (var j = 0; j < atts.length; j++) {\n var att = doc._attachments[atts[j]];\n addDigestSeq(att.digest, row.seq);\n }\n }\n var digestSeqPairs = [];\n Object.keys(digestSeqs).forEach(function (digest) {\n var seqs = digestSeqs[digest];\n seqs.forEach(function (seq) {\n digestSeqPairs.push([digest, seq]);\n });\n });\n if (!digestSeqPairs.length) {\n return nextPage();\n }\n var numDone = 0;\n digestSeqPairs.forEach(function (pair) {\n var sql = 'INSERT INTO ' + ATTACH_AND_SEQ_STORE +\n ' (digest, seq) VALUES (?,?)';\n tx.executeSql(sql, pair, function () {\n if (++numDone === digestSeqPairs.length) {\n nextPage();\n }\n });\n });\n });\n }\n nextPage();\n });\n }\n\n var attachAndRev = 'CREATE TABLE IF NOT EXISTS ' +\n ATTACH_AND_SEQ_STORE + ' (digest, seq INTEGER)';\n tx.executeSql(attachAndRev, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_ATTACH_INDEX_SQL, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_SEQ_INDEX_SQL, [],\n migrateAttsAndSeqs);\n });\n });\n }", "title": "" }, { "docid": "20eb2b6931cb7cd6d3d9aab706b8430a", "score": "0.5336693", "text": "function runMigration5(tx, callback) {\n\n function migrateAttsAndSeqs(tx) {\n // need to actually populate the table. this is the expensive part,\n // so as an optimization, check first that this database even\n // contains attachments\n var sql = 'SELECT COUNT(*) AS cnt FROM ' + ATTACH_STORE;\n tx.executeSql(sql, [], function (tx, res) {\n var count = res.rows.item(0).cnt;\n if (!count) {\n return callback(tx);\n }\n\n var offset = 0;\n var pageSize = 10;\n function nextPage() {\n var sql = select(\n SELECT_DOCS + ', ' + DOC_STORE + '.id AS id',\n [DOC_STORE, BY_SEQ_STORE],\n DOC_STORE_AND_BY_SEQ_JOINER,\n null,\n DOC_STORE + '.id '\n );\n sql += ' LIMIT ' + pageSize + ' OFFSET ' + offset;\n offset += pageSize;\n tx.executeSql(sql, [], function (tx, res) {\n if (!res.rows.length) {\n return callback(tx);\n }\n var digestSeqs = {};\n function addDigestSeq(digest, seq) {\n // uniq digest/seq pairs, just in case there are dups\n var seqs = digestSeqs[digest] = (digestSeqs[digest] || []);\n if (seqs.indexOf(seq) === -1) {\n seqs.push(seq);\n }\n }\n for (var i = 0; i < res.rows.length; i++) {\n var row = res.rows.item(i);\n var doc = unstringifyDoc(row.data, row.id, row.rev);\n var atts = Object.keys(doc._attachments || {});\n for (var j = 0; j < atts.length; j++) {\n var att = doc._attachments[atts[j]];\n addDigestSeq(att.digest, row.seq);\n }\n }\n var digestSeqPairs = [];\n Object.keys(digestSeqs).forEach(function (digest) {\n var seqs = digestSeqs[digest];\n seqs.forEach(function (seq) {\n digestSeqPairs.push([digest, seq]);\n });\n });\n if (!digestSeqPairs.length) {\n return nextPage();\n }\n var numDone = 0;\n digestSeqPairs.forEach(function (pair) {\n var sql = 'INSERT INTO ' + ATTACH_AND_SEQ_STORE +\n ' (digest, seq) VALUES (?,?)';\n tx.executeSql(sql, pair, function () {\n if (++numDone === digestSeqPairs.length) {\n nextPage();\n }\n });\n });\n });\n }\n nextPage();\n });\n }\n\n var attachAndRev = 'CREATE TABLE IF NOT EXISTS ' +\n ATTACH_AND_SEQ_STORE + ' (digest, seq INTEGER)';\n tx.executeSql(attachAndRev, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_ATTACH_INDEX_SQL, [], function (tx) {\n tx.executeSql(\n ATTACH_AND_SEQ_STORE_SEQ_INDEX_SQL, [],\n migrateAttsAndSeqs);\n });\n });\n }", "title": "" }, { "docid": "f01ca43a329a7f05221c0ee7480497c3", "score": "0.5327865", "text": "async function up () {\n // Write migration here\n await new Promise((resolve, reject) => {\n // setTimeout(()=> { resolve('ok'); }, 3000);\n return Project.updateMany({\"settings.max_agent_served_chat\":{$exists:true}}, { $rename: { \"settings.max_agent_served_chat\": \"settings.max_agent_assigned_chat\" } } , function (err, updates) {\n if (err) {\n winston.error(\"Schema updated project.settings max_assigned_chat error \",err);\n return reject(err);\n }\n winston.info(\"Schema updated for \" + updates.nModified + \" project.settings max_assigned_chat field\")\n return resolve('ok'); \n }); \n }); \n}", "title": "" }, { "docid": "1c1e6ce167ff97132cd1008956a86d42", "score": "0.53120375", "text": "function runMigration3(tx, callback) {\n var local = 'CREATE TABLE IF NOT EXISTS ' + LOCAL_STORE$1 +\n ' (id UNIQUE, rev, json)';\n tx.executeSql(local, [], function () {\n var sql = 'SELECT ' + DOC_STORE$1 + '.id AS id, ' +\n BY_SEQ_STORE$1 + '.json AS data ' +\n 'FROM ' + BY_SEQ_STORE$1 + ' JOIN ' +\n DOC_STORE$1 + ' ON ' + BY_SEQ_STORE$1 + '.seq = ' +\n DOC_STORE$1 + '.winningseq WHERE local = 1';\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var rev$$1 = JSON.parse(row.data)._rev;\n tx.executeSql('INSERT INTO ' + LOCAL_STORE$1 +\n ' (id, rev, json) VALUES (?,?,?)',\n [row.id, rev$$1, row.data], function (tx) {\n tx.executeSql('DELETE FROM ' + DOC_STORE$1 + ' WHERE id=?',\n [row.id], function (tx) {\n tx.executeSql('DELETE FROM ' + BY_SEQ_STORE$1 + ' WHERE seq=?',\n [row.seq], function () {\n doNext();\n });\n });\n });\n }\n doNext();\n });\n });\n }", "title": "" }, { "docid": "a604650f9155936e4240a9511d87ab55", "score": "0.5308179", "text": "async sync() {\n try {\n const filesInMigrationFolder = fs.readdirSync(this.migrationPath);\n const migrationsInDatabase = await this.migrationModel.find({});\n // Go over migrations in folder and delete any files not in DB\n const migrationsInFolder = _.filter(filesInMigrationFolder, file => /\\d{13,}\\-.+.js$/.test(file))\n .map(filename => {\n const fileCreatedAt = parseInt(filename.split('-')[0]);\n const existsInDatabase = migrationsInDatabase.some(m => filename == m.filename);\n return { createdAt: fileCreatedAt, filename, existsInDatabase };\n });\n\n const filesNotInDb = _.filter(migrationsInFolder, { existsInDatabase: false }).map(f => f.filename);\n let migrationsToImport = filesNotInDb;\n this.log('Synchronizing database with file system migrations...');\n if (!this.autosync && migrationsToImport.length) {\n const answers = await new Promise(function (resolve) {\n ask.prompt({\n type: 'checkbox',\n message: 'The following migrations exist in the migrations folder but not in the database. Select the ones you want to import into the database',\n name: 'migrationsToImport',\n choices: filesNotInDb\n }, (answers) => {\n resolve(answers);\n });\n });\n\n migrationsToImport = answers.migrationsToImport;\n }\n\n return Promise.map(migrationsToImport, async (migrationToImport) => {\n const filePath = path.join(this.migrationPath, migrationToImport),\n timestampSeparatorIndex = migrationToImport.indexOf('-'),\n timestamp = migrationToImport.slice(0, timestampSeparatorIndex),\n migrationName = migrationToImport.slice(timestampSeparatorIndex + 1, migrationToImport.lastIndexOf('.'));\n\n this.log(`Adding migration ${filePath} into database from file system. State is ` + `DOWN`.red);\n const createdMigration = await this.migrationModel.create({\n name: migrationName,\n createdAt: timestamp\n });\n return createdMigration.toJSON();\n });\n } catch (error) {\n this.log(`Could not synchronise migrations in the migrations folder up to the database.`.red);\n throw error;\n }\n }", "title": "" }, { "docid": "f27ebb7187440ce8079831b3e4cffa37", "score": "0.52960956", "text": "async onAbortOtherMigration() {\n State.commit('swagMigration/ui/setIsLoading', true);\n State.commit('swagMigration/process/setIsMigrating', true);\n\n await this.migrationWorkerService.isMigrationRunningInOtherTab().then((isRunning) => {\n if (isRunning) {\n State.commit('swagMigration/ui/setIsLoading', false);\n this.isTakeoverForbidden = true;\n this.onInvalidMigrationAccessToken();\n }\n });\n\n if (this.isTakeoverForbidden) {\n return;\n }\n\n await this.migrationWorkerService.checkForRunningMigration().then((runState) => {\n if (runState.isMigrationRunning === false) {\n State.commit('swagMigration/process/setIsMigrating', false);\n State.commit('swagMigration/ui/setIsLoading', false);\n this.isOtherMigrationRunning = false;\n this.$router.push({ name: 'swag.migration.index.main' });\n return;\n }\n\n this.migrationService.abortMigration(runState.runUuid).then(() => {\n State.commit('swagMigration/process/setIsMigrating', false);\n State.commit('swagMigration/ui/setIsLoading', false);\n this.isOtherMigrationRunning = false;\n this.$router.push({ name: 'swag.migration.index.main' });\n });\n });\n }", "title": "" }, { "docid": "112524d2d8e60cbbffeafa6dfd05a780", "score": "0.5295032", "text": "async function reload_database() {\n const drop_db_cmd = 'rm development.db.sqlite && rm test.db.sqlite'\n const db_migrate_cmd = 'npx sequelize db:migrate'\n const db_seed_cmd = 'npx sequelize --seeders-path seeders/ db:seed:all'\n\n console.log('1) Dropping DB...')\n await exec(drop_db_cmd)\n\n console.log('2) Running Migrations...')\n await exec(db_migrate_cmd)\n\n console.log('3) Seeding DB...')\n await exec(db_seed_cmd)\n\n console.log('- Success!')\n}", "title": "" }, { "docid": "11bb78a6f8cd966e732f35a7ddce3d93", "score": "0.5276282", "text": "function lastBuildToBuild() {\n reloadDBName();\n if (fs.existsSync(alterSqlPath)) {\n fs.copyFileSync(alterSqlPath, path.join(alterPath, fileName + updateTime + '.sql'));\n }\n copyMigrationLastBuildToBuild()\n fs.copySync(entityPath, path.join(typeormEntitiesPath, fileName + updateTime));\n if (fs.existsSync(path.join(typeormEntitiesPath, fileName))) {\n fs.removeSync(path.join(typeormEntitiesPath, fileName));\n }\n fs.copySync(entityPath, path.join(typeormEntitiesPath, fileName));\n fs.copySync(tsSeqPath, path.join(tsSequelizeModelsPath, fileName + updateTime));\n fs.copyFileSync(sqlPath, oldSqlPath);\n fs.copyFileSync(sqlPath, oldSqlPath.replace('.sql', updateTime + '.sql'));\n fs.copyFileSync(pngPath, path.join(previewPath, fileName + '.png'));\n fs.copyFileSync(tempXMLPath, actualXMLPath);\n fs.remove(mainPath);\n}", "title": "" }, { "docid": "be48298caca863536fd4aee1eb885c08", "score": "0.5274426", "text": "function runMigration3(tx, callback) {\n var local = 'CREATE TABLE IF NOT EXISTS ' + LOCAL_STORE +\n ' (id UNIQUE, rev, json)';\n tx.executeSql(local, [], function () {\n var sql = 'SELECT ' + DOC_STORE + '.id AS id, ' +\n BY_SEQ_STORE + '.json AS data ' +\n 'FROM ' + BY_SEQ_STORE + ' JOIN ' +\n DOC_STORE + ' ON ' + BY_SEQ_STORE + '.seq = ' +\n DOC_STORE + '.winningseq WHERE local = 1';\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var rev = JSON.parse(row.data)._rev;\n tx.executeSql('INSERT INTO ' + LOCAL_STORE +\n ' (id, rev, json) VALUES (?,?,?)',\n [row.id, rev, row.data], function (tx) {\n tx.executeSql('DELETE FROM ' + DOC_STORE + ' WHERE id=?',\n [row.id], function (tx) {\n tx.executeSql('DELETE FROM ' + BY_SEQ_STORE + ' WHERE seq=?',\n [row.seq], function () {\n doNext();\n });\n });\n });\n }\n doNext();\n });\n });\n }", "title": "" }, { "docid": "be48298caca863536fd4aee1eb885c08", "score": "0.5274426", "text": "function runMigration3(tx, callback) {\n var local = 'CREATE TABLE IF NOT EXISTS ' + LOCAL_STORE +\n ' (id UNIQUE, rev, json)';\n tx.executeSql(local, [], function () {\n var sql = 'SELECT ' + DOC_STORE + '.id AS id, ' +\n BY_SEQ_STORE + '.json AS data ' +\n 'FROM ' + BY_SEQ_STORE + ' JOIN ' +\n DOC_STORE + ' ON ' + BY_SEQ_STORE + '.seq = ' +\n DOC_STORE + '.winningseq WHERE local = 1';\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var rev = JSON.parse(row.data)._rev;\n tx.executeSql('INSERT INTO ' + LOCAL_STORE +\n ' (id, rev, json) VALUES (?,?,?)',\n [row.id, rev, row.data], function (tx) {\n tx.executeSql('DELETE FROM ' + DOC_STORE + ' WHERE id=?',\n [row.id], function (tx) {\n tx.executeSql('DELETE FROM ' + BY_SEQ_STORE + ' WHERE seq=?',\n [row.seq], function () {\n doNext();\n });\n });\n });\n }\n doNext();\n });\n });\n }", "title": "" }, { "docid": "be48298caca863536fd4aee1eb885c08", "score": "0.5274426", "text": "function runMigration3(tx, callback) {\n var local = 'CREATE TABLE IF NOT EXISTS ' + LOCAL_STORE +\n ' (id UNIQUE, rev, json)';\n tx.executeSql(local, [], function () {\n var sql = 'SELECT ' + DOC_STORE + '.id AS id, ' +\n BY_SEQ_STORE + '.json AS data ' +\n 'FROM ' + BY_SEQ_STORE + ' JOIN ' +\n DOC_STORE + ' ON ' + BY_SEQ_STORE + '.seq = ' +\n DOC_STORE + '.winningseq WHERE local = 1';\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var rev = JSON.parse(row.data)._rev;\n tx.executeSql('INSERT INTO ' + LOCAL_STORE +\n ' (id, rev, json) VALUES (?,?,?)',\n [row.id, rev, row.data], function (tx) {\n tx.executeSql('DELETE FROM ' + DOC_STORE + ' WHERE id=?',\n [row.id], function (tx) {\n tx.executeSql('DELETE FROM ' + BY_SEQ_STORE + ' WHERE seq=?',\n [row.seq], function () {\n doNext();\n });\n });\n });\n }\n doNext();\n });\n });\n }", "title": "" }, { "docid": "be48298caca863536fd4aee1eb885c08", "score": "0.5274426", "text": "function runMigration3(tx, callback) {\n var local = 'CREATE TABLE IF NOT EXISTS ' + LOCAL_STORE +\n ' (id UNIQUE, rev, json)';\n tx.executeSql(local, [], function () {\n var sql = 'SELECT ' + DOC_STORE + '.id AS id, ' +\n BY_SEQ_STORE + '.json AS data ' +\n 'FROM ' + BY_SEQ_STORE + ' JOIN ' +\n DOC_STORE + ' ON ' + BY_SEQ_STORE + '.seq = ' +\n DOC_STORE + '.winningseq WHERE local = 1';\n tx.executeSql(sql, [], function (tx, res) {\n var rows = [];\n for (var i = 0; i < res.rows.length; i++) {\n rows.push(res.rows.item(i));\n }\n function doNext() {\n if (!rows.length) {\n return callback(tx);\n }\n var row = rows.shift();\n var rev = JSON.parse(row.data)._rev;\n tx.executeSql('INSERT INTO ' + LOCAL_STORE +\n ' (id, rev, json) VALUES (?,?,?)',\n [row.id, rev, row.data], function (tx) {\n tx.executeSql('DELETE FROM ' + DOC_STORE + ' WHERE id=?',\n [row.id], function (tx) {\n tx.executeSql('DELETE FROM ' + BY_SEQ_STORE + ' WHERE seq=?',\n [row.seq], function () {\n doNext();\n });\n });\n });\n }\n doNext();\n });\n });\n }", "title": "" }, { "docid": "758fc13068490fa7d22175057407d346", "score": "0.52690125", "text": "function runMigration6(tx, callback) {\n var sql = 'ALTER TABLE ' + ATTACH_STORE$1 +\n ' ADD COLUMN escaped TINYINT(1) DEFAULT 0';\n tx.executeSql(sql, [], callback);\n }", "title": "" }, { "docid": "1cdc5ec8ff4f27514fa0db55a459b763", "score": "0.5241349", "text": "function guildMigrate(){\n\tfresh.forEach(function(guild, idx){ \t//iterate self\n\t\tfor (let i = 0; i < fresh.length; i++){\n\t\t\tif (i !== idx){ //ignore self\n\t\t\t\tif (guild.guildName === fresh[i].guildName && guild.guildRealm !== fresh[i].guildRealm){\n\t\t\t\t\tif (fresh[i].guildData.completedArray.length > guild.guildData.completedArray.length){\n\t\t\t\t\t\ttriggerTooltip(`${guild.guildName} - ${blizzspaceToSpace(guild.guildRealm)} migrated to ${fresh[i].guildName} - ${blizzspaceToSpace(fresh[i].guildRealm)}`)\n\t\t\t\t\t\ttooltip = true;\n\t\t\t\t\t\tguildRequestList.forEach(function(replace){\n\t\t\t\t\t\t\tif (replace.guildName === fresh[i].guildName && replace.guildRealm === guild.guildRealm){\n\t\t\t\t\t\t\t\treplace.oldRealm = replace.guildRealm;\n\t\t\t\t\t\t\t\treplace.guildName = fresh[i].guildName; //useless?\n\t\t\t\t\t\t\t\treplace.guildRealm = fresh[i].guildRealm;\n\t\t\t\t\t\t\t}\t\t\t\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t});\n}", "title": "" }, { "docid": "f4e5c3fc93be7b72367b7284c7f43777", "score": "0.5209586", "text": "function runMigration6(tx, callback) {\n var sql = 'ALTER TABLE ' + ATTACH_STORE +\n ' ADD COLUMN escaped TINYINT(1) DEFAULT 0';\n tx.executeSql(sql, [], callback);\n }", "title": "" }, { "docid": "f4e5c3fc93be7b72367b7284c7f43777", "score": "0.5209586", "text": "function runMigration6(tx, callback) {\n var sql = 'ALTER TABLE ' + ATTACH_STORE +\n ' ADD COLUMN escaped TINYINT(1) DEFAULT 0';\n tx.executeSql(sql, [], callback);\n }", "title": "" }, { "docid": "f4e5c3fc93be7b72367b7284c7f43777", "score": "0.5209586", "text": "function runMigration6(tx, callback) {\n var sql = 'ALTER TABLE ' + ATTACH_STORE +\n ' ADD COLUMN escaped TINYINT(1) DEFAULT 0';\n tx.executeSql(sql, [], callback);\n }", "title": "" }, { "docid": "f4e5c3fc93be7b72367b7284c7f43777", "score": "0.5209586", "text": "function runMigration6(tx, callback) {\n var sql = 'ALTER TABLE ' + ATTACH_STORE +\n ' ADD COLUMN escaped TINYINT(1) DEFAULT 0';\n tx.executeSql(sql, [], callback);\n }", "title": "" }, { "docid": "68c87f24429fe6e89ca49c6e40dda45e", "score": "0.520553", "text": "function copyMigrationLastBuildToBuild() {\n const migrationTypes = ['typeorm', 'script'];\n for (let i = 0; i < dbTypes.length; i++) {\n const dbType = dbTypes[i];\n const migrationDbPath = path.join(migrationPath, dbType);\n shell.mkdir('-p', migrationDbPath);\n for (let j = 0; j < migrationTypes.length; j++) {\n const migrationType = migrationTypes[j];\n const endName = migrationType === 'typeorm' ? '.ts' : '.js';\n const lastBuildMigrationPath = path.join(mainPath, 'migration-' + migrationType + '-' + dbType + endName);\n const buildMigrationPath = path.join(migrationDbPath, updateTime.substring(1, updateTime.length) + '-' + fileName + '-' + migrationType + endName);\n if (fs.existsSync(lastBuildMigrationPath)) {\n fs.copyFileSync(lastBuildMigrationPath, buildMigrationPath);\n fs.copyFileSync(lastBuildMigrationPath, path.join(migrationDbPath, fileName + '-' + migrationType + endName));\n }\n }\n }\n}", "title": "" }, { "docid": "34e15331cacb83394ef6ce49d346bee9", "score": "0.51734185", "text": "_createMigrationHistoryTable() {\n var tableName = this.db.getSchema().getRawTableName(this.migrationTable);\n this.stdout('Creating migration history table \"' + tableName + '\"...', Console.FG_YELLOW);\n\n return this.db.createCommand()\n .createTable(this.migrationTable, {\n version: 'varchar(180) NOT NULL PRIMARY KEY',\n apply_time: 'integer'\n })\n .then(() => {\n return this.db.createCommand()\n .insert(this.migrationTable, {\n version: this.__static.BASE_MIGRATION,\n apply_time: Math.round((new Date()).getTime() / 1000)\n });\n }).then(() => {\n this.stdout(\"Done.\\n\", Console.FG_GREEN);\n });\n }", "title": "" }, { "docid": "1622b26cd3c6f210fdc2931557e7f6f1", "score": "0.516789", "text": "function runNextPendingManager() {\n lock.acquire(RESOURCE_KEY, function(done) {\n const pendingMigrationManagers = _.reject(managerPool, manager => {\n return manager.getState() !== CHILD_STATES.PENDING;\n });\n\n if (pendingMigrationManagers.length > 0) {\n pendingMigrationManagers[0].setState(CHILD_STATES.RUNNING);\n pendingMigrationManagers[0].forkMigrationWorker();\n }\n\n done();\n });\n }", "title": "" }, { "docid": "154da631030dc4f20a3f6f228b36a28a", "score": "0.51410186", "text": "function nextStep() {\n function moveOn(stepRunner) {\n step++;\n updateDemoText();\n stepRunner();\n }\n\n if (step == WELCOME_STEP)\n moveOn(runCreationStep);\n else if (step == CREATION_STEP)\n endCreationStep(function() { moveOn(runGroupingStep); });\n else if (step == GROUPING_STEP)\n moveOn(runGrahamScanStep);\n else if (step == GRAHAM_SCAN_STEP)\n moveOn(runJarvisMarchStep);\n else if (step == JARVIS_MARCH_STEP)\n moveOn(runCompletedHullStep);\n else if (step == COMPLETED_HULL_STEP)\n restartDemo();\n }", "title": "" }, { "docid": "b33b647e1ae21faddd4ff9db7d429b0e", "score": "0.51363444", "text": "function forkMigrationWorker() {\n child = fork(CHILD_PATH, process.argv);\n child.send({ schema: tenant.schema, direction: 'up' });\n\n // A child migration worker messages its parent (this process) if there is\n // an error, or if there is a new migration file being worked on.\n child.on('message', message => {\n if (message.error) {\n console.log(`Error from child migration: ${ message.error.message }`.underline.yellow);\n setErrorOnProgressBar();\n setGeneralError(message.error);\n } else {\n setCurrentMigration(message.currentMigration);\n }\n });\n\n // When a child exists, set it in a complete state, and then check to see\n // if all managers have finished. If not, runNextPendingManager().\n child.on('exit', () => {\n state = CHILD_STATES.COMPLETE;\n\n const allHaveCompleted = _.every(managerPool, manager => {\n return manager.getState() === CHILD_STATES.COMPLETE;\n });\n\n if (!allHaveCompleted) {\n runNextPendingManager();\n } else {\n process.exit(0);\n }\n });\n }", "title": "" }, { "docid": "dfdc76d52a9bf0c9cbe7bfef32029fb4", "score": "0.51356167", "text": "async function nextQ(){\n if(currentQ < allQs.length){\n setCurrentQ(currentQ + 1)\n upDateCurrentQInFirestore(allQs[currentQ].id)\n undoPending()\n return; \n } else {\n await runningQuizDocument\n .update({\n hasEnded: true\n }, {merge: true})\n return setQuizEnded(true)\n }\n }", "title": "" }, { "docid": "5b2100cf26a277e09ff92ca6e797af06", "score": "0.5111474", "text": "function autoUpgrade() {\n let myPs = df.getAllOwnedPlanets().filter(p => p.owner === df.account)\n let upgradeablePs = myPs.filter(p => df.planetHelper.planetCanUpgrade(p))\n terminal._events.Print(`Upgrade bot checking ${myPs.length} planets...${upgradeablePs.length === 0 ? ' no luck\\n' : '\\n'}`)\n for (let p of upgradeablePs) {\n terminal._events.Print(`Upgrading L${p.planetLevel} ${p.locationId}\\n`, 'Green')\n const branch = p.upgradeState.lastIndexOf(Math.min(...p.upgradeState))\n df.upgrade(p.locationId, branch)\n }\n }", "title": "" }, { "docid": "118bce668d4988a3f80fea3ead47daa7", "score": "0.5103765", "text": "async handleMigration () {\n\n\t\t// look for any companies the user is in that are not yet migrated\n\t\t// (or get the manually set company)\n\t\tlet companyIds, companies;\n\t\tif (this.companyId) {\n\t\t\tconst company = await this.data.companies.getById(this.companyId.toLowerCase());\n\t\t\tif (!company) {\n\t\t\t\treturn 'notFound';\n\t\t\t}\n\t\t\tcompanies = [company];\n\t\t\tcompanyIds = [company.id];\n\t\t} else if (this.company) {\n\t\t\tcompanies = [this.company];\n\t\t\tcompanyIds = [this.company.id];\n\t\t} else {\n\t\t\tconst excludeCompanyIds = (this.migrationData && this.migrationData.excludeCompanyIds) || [];\n\t\t\tcompanyIds = this.request.user.get('companyIds') || [];\n\t\t\tcompanyIds = companyIds.filter(companyId => {\n\t\t\t\tif (excludeCompanyIds.includes(companyId)) {\n\t\t\t\t\tthis.log(`Excluding company ${companyId} from company-centric migration by order`);\n\t\t\t\t\treturn false;\n\t\t\t\t} else {\n\t\t\t\t\treturn true;\n\t\t\t\t}\n\t\t\t});\n\t\t\tcompanies = await this.data.companies.getByIds(companyIds);\n\t\t}\n\n\t\tconst migrationStatus = companies.reduce((stat, company) => {\n\t\t\tif (company.deactivated) {\n\t\t\t\t// don't care\n\t\t\t} else if (company.isBeingMigratedToCompanyCentric) {\n\t\t\t\tstat.migrationInProgress.push(company);\n\t\t\t} if (company.hasBeenMigratedToCompanyCentric) {\n\t\t\t\tstat.migrated.push(company);\n\t\t\t} else if ((company.teamIds || []).length > 1) {\n\t\t\t\t// to minimize change of race condition, mark this company as being migrated RIGHT NOW...\n\t\t\t\t// don't even await\n\t\t\t\tif (this.dryRun) {\n\t\t\t\t\tthis.log(`Would have marked company ${company.id} as being migrated`);\n\t\t\t\t} else {\n\t\t\t\t\tthis.data.companies.updateDirect(\n\t\t\t\t\t\t{ id: this.data.companies.objectIdSafe(company.id) },\n\t\t\t\t\t\t{ $set: { isBeingMigratedToCompanyCentric: true } }\n\t\t\t\t\t);\n\t\t\t\t}\n\t\t\t\tstat.unmigratedMultiTeam.push(company);\n\t\t\t} else {\n\t\t\t\tstat.unmigratedSingleTeam.push(company);\n\t\t\t}\n\t\t\treturn stat;\n\t\t}, {\n\t\t\tmigrated: [],\n\t\t\tunmigratedSingleTeam: [],\n\t\t\tunmigratedMultiTeam: [],\n\t\t\tmigrationInProgress: []\n\t\t});\n\n\t\tif (\n\t\t\tmigrationStatus.unmigratedSingleTeam.length === 0 &&\n\t\t\tmigrationStatus.unmigratedMultiTeam.length === 0 &&\n\t\t\tmigrationStatus.migrationInProgress.length === 0) {\n\t\t\t// all companies migrated\n\t\t\tthis.log(`All companies of (${companyIds}) have already been migrated`);\n\t\t\treturn;\n\t\t}\n\n\t\t// in all other cases we will not honor the request, user must at least refresh, and maybe wait\n\t\tlet errorCode = 'needsRefresh';\n\n\t\t// companies with only one team are trivial, we'll do those first\n\t\tif (migrationStatus.unmigratedSingleTeam.length > 0) {\n\t\t\tcompanyIds = migrationStatus.unmigratedSingleTeam.map(c => c.id);\n\t\t\tthis.log(`Found ${companyIds.length} single-team unmigrated companies (${companyIds}), performing trivial migration...`);\n\t\t\tawait this.migrateSingleTeamCompanies(companies);\n\t\t}\n\n\t\t// if we have any multi-team companies that must be migrated, kick these off now\n\t\t// if they are merges they are non-trivial and may take time, but for now those won't be automatic\n\t\tif (migrationStatus.unmigratedMultiTeam.length > 0) {\n\t\t\tcompanyIds = migrationStatus.unmigratedMultiTeam.map(c => c.id);\n\t\t\tthis.log(`Found ${companyIds.length} multi-team unmigrated companies (${companyIds}), kicking off migrations...`);\n\t\t\tawait Promise.all(migrationStatus.unmigratedMultiTeam.map(async company => {\n\t\t\t\tawait this.migrateMultiTeamCompany(company);\n\t\t\t}));\n\t\t\terrorCode = 'migrationInProgress';\n\t\t}\n\n\t\t// if there are any companies for which migration is already in progress, the migrationInProgress\n\t\t// error needs to be returned for the client to wait\n\t\tif (migrationStatus.migrationInProgress.length > 0) {\n\t\t\tcompanyIds = migrationStatus.migrationInProgress.map(c => c.id);\n\t\t\tthis.log(`These companies have company-centric migration already in progress: ${companyIds}`);\n\t\t\terrorCode = 'migrationInProgress';\n\t\t}\n\n\t\treturn errorCode;\n\t}", "title": "" }, { "docid": "e27242dc82554ebc9dce3e6073277464", "score": "0.5087078", "text": "async function down(params) {\n const { all, root } = params;\n const rootDir = root || process.cwd();\n await connectToDb(await getConfig(rootDir));\n const completedMigrations = await rethinkdb_ts_1.r\n .table(MIGRATION_TABLE_NAME)\n .orderBy({ index: 'timestamp' })\n .run();\n if (completedMigrations.length === 0) {\n logInfo('No new migrations');\n await rethinkdb_ts_1.r.getPoolMaster()?.drain();\n return;\n }\n const migrationsToRollBack = all\n ? completedMigrations.reverse()\n : [completedMigrations[completedMigrations.length - 1]];\n const migrations = requireMigrations(migrationsToRollBack, rootDir);\n for (let i = 0; i < migrations.length; i++) {\n const migration = migrations[i];\n logInfo(chalk_1.default.black.bgYellow(' ↓ down ↓ '), migration.timestamp, chalk_1.default.yellow(migration.name));\n const { name } = migration;\n try {\n await migration.code.down(rethinkdb_ts_1.r);\n }\n catch (e) {\n logError(`Migration failed: ${name}`, e);\n await rethinkdb_ts_1.r.getPoolMaster()?.drain();\n return;\n }\n await rethinkdb_ts_1.r.table(MIGRATION_TABLE_NAME).get(migration.id).delete().run();\n }\n logInfo('Migration successful');\n await rethinkdb_ts_1.r.getPoolMaster()?.drain();\n}", "title": "" }, { "docid": "359575a65203bfe111df79b2c80af7ed", "score": "0.5086801", "text": "function typeormMigrationToScript(dbType) {\n migrationTypeormPath = path.join(mainPath, 'migration-typeorm-' + dbType + '.ts');\n migrationUpPath = path.join(mainPath, 'migration-up-' + dbType + '.sql');\n migrationDownPath = path.join(mainPath, 'migration-down-' + dbType + '.sql');\n let oldMigration;\n if (dbType === 'postgres') {\n oldMigration = klawSync(path.join(mainPath, 'postgres-entities')).filter(f => f.path.endsWith('migration-' + dbType + '.ts'))[0];\n } else {\n oldMigration = klawSync(entityPath).filter(f => f.path.endsWith('migration-' + dbType + '.ts'))[0];\n }\n\n if (oldMigration) {\n const oldMigrationPath = oldMigration.path;\n fs.moveSync(oldMigrationPath, migrationTypeormPath);\n const migration = fs.readFileSync(migrationTypeormPath, 'utf8').replace(/double\\(..\\)/g, 'double')\n .replace(/double precision\\(..\\)/g, 'double precision')\n .replace(/'CURRENT_TIMESTAMP'/g, 'CURRENT_TIMESTAMP');\n fs.writeFileSync(migrationTypeormPath, migration);\n\n // formatage du fichier de migration typeorm en script sql\n let scriptUp = migration.substring(migration.indexOf('up'), migration.indexOf('down'));\n scriptUp = scriptUp.substring(scriptUp.indexOf('await queryRunner'), scriptUp.indexOf('\\n }'));\n let scriptDown = migration.substring(migration.indexOf('down'), migration.length);\n scriptDown = scriptDown.substring(scriptDown.indexOf('await queryRunner'), scriptDown.indexOf('\\n }'));\n let quote;\n let jsFile;\n if (dbType === 'mysql') {\n quote = '\"';\n const reg = new RegExp('.*\\\\(' + quote + '(.*)' + quote + '\\\\);', 'g')\n scriptUp = scriptUp.replace(reg, quote + '$1;' + quote + ' +');\n scriptUp = scriptUp.substring(0, scriptUp.length - 2);\n scriptDown = scriptDown.replace(reg, quote + '$1;' + quote + ' +');\n scriptDown = scriptDown.substring(0, scriptDown.length - 2);\n jsFile = \"exports.up = \" + scriptUp + \";\\n\\nexports.down = \" + scriptDown + \";\\n\"\n } else if (dbType === 'postgres' || dbType === 'sqlite') {\n quote = '`';\n const reg = new RegExp('.*\\\\(' + quote + '(.*)' + quote + '\\\\);', 'g')\n scriptUp = scriptUp.replace(reg, '$1;');\n scriptDown = scriptDown.replace(reg, '$1;');\n jsFile = \"exports.up = \" + quote + scriptUp + quote + \";\\n\\nexports.down = \" + quote + scriptDown + quote + \";\\n\"\n }\n\n fs.writeFileSync(path.join(mainPath, 'migration-script-' + dbType + '.js'), jsFile);\n }\n}", "title": "" }, { "docid": "d28ed38b2a3460e40226a1ae06ee2860", "score": "0.5056812", "text": "function migrateProgress({ action, migration }) {\n let symbol = action;\n if (action === 'migrate') {\n symbol = '\\u25b2';\n } else if (action === 'revert') {\n symbol = '\\u25bc';\n }\n const [migDate, ...migDescription] = getMigrationName(migration).split(/_/);\n const y = migDate.slice(0, 4);\n const m = migDate.slice(4, 6);\n const d = migDate.slice(6, 8);\n logger.info(` ${symbol} ${[y, m, d].join('-')}: ${migDescription.join('_')}`);\n}", "title": "" }, { "docid": "b85739eaca762a019536c0c7db22c8cb", "score": "0.50530446", "text": "revert(migrations, dir, preview = false) {\n return __awaiter(this, void 0, void 0, function* () {\n const clone = [...migrations];\n const newDir = dir === 'up' ? 'down' : 'up';\n let result = { type: newDir, ok: false, message: 'Unknown', count: 0, success: 0, failed: 0, names: [] };\n let revertNames = [];\n let last;\n let name = '';\n const count = migrations.length;\n let success = 0;\n const migrated = [];\n try {\n // Ensure migrations are in correct order\n // using timestamped filenames.\n if (dir === 'up') {\n // we'll be descending so we need last first.\n clone.sort().reverse();\n }\n else {\n // we'll be ascending as we are reverting a down\n // sort ensuring that the oldest is first.\n clone.sort();\n }\n // The revert migration names will now be the opposite\n // of whatever the clone order is.\n revertNames = [...clone].reverse().map(file => utils_1.getBaseName(file.filename));\n // Get last to store as active migration.\n last = clone[clone.length - 1];\n name = utils_1.getBaseName(last.filename);\n result = this.checkPreviewAndScope('up', clone, preview);\n if (!result.count || result.isPreview)\n return result;\n for (const [, file] of migrations.entries()) {\n this.emit(newDir, file);\n const fn = utils_1.promisifyMigration(file[newDir]);\n yield fn(this.connection)\n .then(_ => {\n success += 1;\n migrated.push(file);\n });\n }\n result.ok = count === success;\n }\n catch (err) {\n result = Object.assign(Object.assign({}, result), { ok: false, message: err, names: migrated.map(m => m.filename) });\n }\n result.count = count;\n result.success = success;\n result.failed = Math.max(0, count - success);\n if (result.ok) {\n result.message = `Revert Migration ${newDir} successful`;\n result.names = migrated.map(m => m.filename);\n }\n if (result.ok && migrated.length) {\n this.reverts = [revertNames, newDir];\n this.active = [name, newDir];\n }\n this.emit('migration', result);\n return result;\n });\n }", "title": "" }, { "docid": "316982dfe67520b144aa392011c2e1f5", "score": "0.5050101", "text": "executePendingTasks(migrationDir, adapter, logger = exports.CLI_LOGGER) {\n return __awaiter(this, void 0, void 0, function* () {\n while (true) {\n logger.log(this.toString());\n const tasks = this.newCommits.reduce((prev, next) => prev.concat(next.tasks), []);\n if (tasks.length > 0) {\n logger.log('Starting migration\\n\\n');\n const hasChanged = yield adapter.waitForPending(logger);\n if (hasChanged) {\n logger.log('The pending migrations have changed, reloading..\\n\\n');\n continue;\n }\n // create pending tasks\n for (const task of tasks) {\n task.head = this.head;\n yield adapter.beginMigrationTask(task);\n }\n for (const commit of this.newCommits) {\n logger.log(`${chalk_1.default.yellow.bold(commit.shortSha1)} ${commit.subject}\\n`);\n for (const task of commit.tasks) {\n logger.log(task.toString() + ' ...');\n const interval = setInterval(() => logger.log('.'), 100);\n try {\n yield task.execute(migrationDir, adapter, this.head, commit);\n }\n finally {\n clearInterval(interval);\n }\n logger.log(' Success\\n');\n }\n }\n logger.log(chalk_1.default.green('\\nAll migrations successful\\n'));\n }\n break;\n }\n });\n }", "title": "" }, { "docid": "18bf976e4410b00f7d09e601852f0030", "score": "0.502063", "text": "function setCurrentMigration(migrationId) {\n currentMigrationId = migrationId;\n const nextId = tenant.schema + ':' + migrationId + '-'.repeat(100);\n bar.tick(1, { id: nextId.substr(0, 36) });\n }", "title": "" }, { "docid": "e4848ade551b2cfe670b72fbfd7778ce", "score": "0.50121576", "text": "_promoteCurrentStep(){\n singleton._currentStepIndex = singleton._currentStepIndex + 1;\n singleton.currentRun.currentStep = (singleton.currentRun.currentTestCase) ? singleton.currentRun.currentTestCase.pickle.steps[singleton._currentStepIndex] : undefined;\n }", "title": "" }, { "docid": "194c51e6bd9f97d448ddb1bf74614d6c", "score": "0.5008442", "text": "function doNextCompaction(self) {\n var task = self._compactionQueue[0];\n var opts = task.opts;\n var callback = task.callback;\n self.get('_local/compaction').catch(function () {\n return false;\n }).then(function (doc) {\n if (doc && doc.last_seq) {\n opts.last_seq = doc.last_seq;\n }\n self._compact(opts, function (err, res) {\n /* istanbul ignore if */\n if (err) {\n callback(err);\n } else {\n callback(null, res);\n }\n __WEBPACK_IMPORTED_MODULE_2_immediate___default()(function () {\n self._compactionQueue.shift();\n if (self._compactionQueue.length) {\n doNextCompaction(self);\n }\n });\n });\n });\n}", "title": "" }, { "docid": "cdb4c6d2216d31aeed96e1c7422532ad", "score": "0.500636", "text": "async boot() {\n this.emit('start');\n this.booted = true;\n await this.acquireLock();\n await this.makeMigrationsTable();\n }", "title": "" }, { "docid": "6f395f9323e48a3216b6ad400c261fc7", "score": "0.50042856", "text": "function doNextCompaction(self) {\n var task = self._compactionQueue[0];\n var opts = task.opts;\n var callback = task.callback;\n self.get('_local/compaction').catch(function () {\n return false;\n }).then(function (doc) {\n if (doc && doc.last_seq) {\n opts.last_seq = doc.last_seq;\n }\n self._compact(opts, function (err, res) {\n /* istanbul ignore if */\n if (err) {\n callback(err);\n } else {\n callback(null, res);\n }\n immediate__WEBPACK_IMPORTED_MODULE_0___default()(function () {\n self._compactionQueue.shift();\n if (self._compactionQueue.length) {\n doNextCompaction(self);\n }\n });\n });\n });\n}", "title": "" }, { "docid": "428c439972f9acfe6ac1dd53f0368b16", "score": "0.49970487", "text": "function doNextCompaction(self) {\n var task = self._compactionQueue[0];\n var opts = task.opts;\n var callback = task.callback;\n self.get('_local/compaction').catch(function () {\n return false;\n }).then(function (doc) {\n if (doc && doc.last_seq) {\n opts.last_seq = doc.last_seq;\n }\n self._compact(opts, function (err, res) {\n /* istanbul ignore if */\n if (err) {\n callback(err);\n } else {\n callback(null, res);\n }\n pouchdbUtils.nextTick(function () {\n self._compactionQueue.shift();\n if (self._compactionQueue.length) {\n doNextCompaction(self);\n }\n });\n });\n });\n}", "title": "" }, { "docid": "561089b9898162cdfc3c4c45193c6399", "score": "0.49969572", "text": "function migrationCheck(type, username) {\n var key = lastVersionKey;\n\n // retrieving last run version\n return Peerio.TinyDB.getItem(key, type === 'user' && username )\n .then(lastVersion => {\n // if it's less then current running migration for app or user\n if (!lastVersion || Peerio.Util.simpleSemverCompare(lastVersion, Peerio.runtime.version) === -1)\n return type === 'user' ? doMigrateUser(username) : doMigrateApp();\n\n L.info('{0} migrator found last run version {1} is up to date with runtime version {2}', type, lastVersion, Peerio.runtime.version);\n })\n // saving new version number\n .then(()=>Peerio.TinyDB.saveItem(key, Peerio.runtime.version, type === 'user' && username ))\n .catch(err => L.error(\"Error migrating app. {0} {1}\", type === 'user' ? ' for username ' + username : '', err));\n }", "title": "" }, { "docid": "c8e5ac80a55cbb2e70c804ae62b831c5", "score": "0.49857536", "text": "function applyDbUpdate() {\n const docId = 'external';\n const agentDb = localNano.use(names.agent());\n return agentDb.get(docId)\n .catch(e=>{\n if (e.statusCode === 404) {\n return {\n _id: docId,\n reset_types: []\n };\n }\n else {\n logger.error('cannot access agent.%s doc', docId, e.message);\n }\n })\n .then(doc=>{\n if (doc && doc.reset_types.join('') !== update.external.reset_types.join('')) {\n logger.log('update agent \"%s\" migration doc', docId);\n\n doc.reset_types = update.external.reset_types;\n\n return Promise.all(doc.reset_types.map(type=>{\n const taskDb = localNano.use(taskDbName);\n return taskDb.get(type)\n .catch(logger.error)\n .then(counter=>{\n if (counter) {\n counter.value = 0;\n return taskDb.insert(counter);\n }\n return Promise.resolve();\n });\n }))\n .then(()=>{\n return agentDb.insert(doc);\n });\n }\n\n return Promise.resolve();\n\n })\n .then(()=>{\n\n });\n }", "title": "" }, { "docid": "6326d2003af8dafe729bd51001fc9f19", "score": "0.4971416", "text": "async function entryPoint(options) {\n vprint(options, 'Starting subscription migration');\n try {\n await run(options);\n } finally {\n await sequelize.close();\n }\n vprint(options, 'Finished subscription migration');\n}", "title": "" }, { "docid": "3898ba73008ad889614b8b0ef555572a", "score": "0.49710262", "text": "latest(config) {\n this._disableProcessing();\n this.config = getMergedConfig$2(config, this.config);\n\n return migrationListResolver\n .listAllAndCompleted(this.config, this.knex)\n .then((value) => {\n if (!this.config.disableMigrationsListValidation) {\n validateMigrationList(this.config.migrationSource, value);\n }\n return value;\n })\n .then(([all, completed]) => {\n const migrations = getNewMigrations(\n this.config.migrationSource,\n all,\n completed\n );\n\n const transactionForAll =\n !this.config.disableTransactions &&\n isEmpty$2(\n filter$1(migrations, (migration) => {\n const migrationContents = this.config.migrationSource.getMigration(\n migration\n );\n return !this._useTransaction(migrationContents);\n })\n );\n\n if (transactionForAll) {\n return this.knex.transaction((trx) => {\n return this._runBatch(migrations, 'up', trx);\n });\n } else {\n return this._runBatch(migrations, 'up');\n }\n });\n }", "title": "" }, { "docid": "7f31af35deed9db43d4ce7758c3f3438", "score": "0.49641964", "text": "function migrate4_18_0() {\n console.log('Migrate to v4.18.0');\n TAS.repeating('hench5')\n .attrs('psionclai-science-macro527','psionclair-science-macro527')\n .fields('psiontelepathic-macro505','psiontelepathic-science-macro505')\n .each(function (row) {\n let macro = row.S['psiontelepathic-macro505'].trim();\n if (macro !== '') {\n console.log('Moved macro from psiontelepathic-macro505 to psiontelepathic-science-macro505');\n row.S['psiontelepathic-science-macro505'] = macro;\n }\n }, function (rowSet, attrSet) {\n let macro = attrSet.S['psionclai-science-macro527'].trim();\n if (macro !== '') {\n console.log('Moved macro from psionclai-science-macro527 to psionclair-science-macro527');\n attrSet.S['psionclair-science-macro527'] = macro;\n }\n }).execute();\n}", "title": "" }, { "docid": "b7d1211e9092cbe6c541204a2ee00fd2", "score": "0.49533483", "text": "async makeMigrationsTable() {\n const client = this.client;\n const hasTable = await client.schema.hasTable(this.migrationsConfig.tableName);\n if (hasTable) {\n return;\n }\n this.emit('create:schema:table');\n await client.schema.createTable(this.migrationsConfig.tableName, (table) => {\n table.increments().notNullable();\n table.string('name').notNullable();\n table.integer('batch').notNullable();\n table.timestamp('migration_time').defaultTo(client.getWriteClient().fn.now());\n });\n }", "title": "" } ]
e341b8b3347a4b307ac7e6c0c9d48888
Throw an array to it and a function which can generate promises and it will call them sequentially, one after another
[ { "docid": "b7b5f1c7d9d8520874a4b4191ae76f79", "score": "0.5835844", "text": "function sequence(items, consumer) {\n\t var results = [];\n\t var runner = function runner() {\n\t var item = items.shift();\n\t if (item) {\n\t return consumer(item).then(function (result) {\n\t results.push(result);\n\t }).then(runner);\n\t }\n\n\t return Promise.resolve(results);\n\t };\n\n\t return runner();\n\t}", "title": "" } ]
[ { "docid": "829d91a1fe08d899a450d02104096721", "score": "0.7541427", "text": "function _promise_sequence(array, func) {\n\t\tlet chain = _promise(array.shift());\n\t\tchain = array.reduce((chain, item) => {\n\t\t\treturn chain.then(() => func(item));\n\t\t}, chain.then(item => func(item)));\n\t\treturn chain;\n\t}", "title": "" }, { "docid": "baed5c85e298273a6d4d2130d6320cb4", "score": "0.6803935", "text": "function myRace(arr) {\n return new Promise((resolve, reject) => {\n arr.forEach(element => {\n element\n .then(res => {\n resolve(res);\n })\n .catch(res => reject(res));\n });\n });\n}", "title": "" }, { "docid": "0f704280a416a3c07be810aab2d4a5ca", "score": "0.667241", "text": "function serialExecute(funcs) {\n var results = [];\n return promiseLoop(function(loop, resolve, reject) {\n if (!funcs.length) {\n resolve(results);\n return;\n }\n Promise.resolve(funcs.shift()())\n .then(function(result) {\n results.push(result);\n loop();\n }, reject);\n });\n }", "title": "" }, { "docid": "02205c08346e50fb790ccdda55f429df", "score": "0.6618778", "text": "function sequentialPromise(promiseArray) {\n const result = promiseArray.reduce(\n (reduced, promise, index) => {\n reduced.results.push(undefined);\n return {\n chain: reduced.chain\n .then(() => promise)\n .then(result => reduced.results[ index ] = result),\n results: reduced.results\n };\n },\n {\n chain: Promise.resolve(),\n results: []\n });\n return result.chain.then(() => result.results);\n}", "title": "" }, { "docid": "23aeea1605b2b7d9cc317ffbd4d2220a", "score": "0.6612807", "text": "function allInSequence(arr, f){\n if(arr.length === 0){\n var def = Q.defer();\n def.resolve([]);\n return def.promise;\n }\n\n if(arr.length === 1){\n return f(arr[0]).then(function(res){\n return [res];\n })\n }\n else{\n var first = arr[0];\n var tail = arr.slice(1);\n\n return f(first).then(function(res){\n return allInSequence(tail, f).then(function(tailRes){\n tailRes.push(res);\n return tailRes;\n });\n });\n }\n}", "title": "" }, { "docid": "69d8583b07dbb944d58c2b5e342edc03", "score": "0.65903455", "text": "function runPromises(arr, input) {\n\treturn arr.reduce(\n\t\t(promiseChain, currFunc) => promiseChain.then(currFunc),\n\t\t\tPromise.resolve(input)\n\t)\n}", "title": "" }, { "docid": "0db631953e7971fa087ea92db3ae085e", "score": "0.6585943", "text": "function promiseAll(fnArr) {\n return Promise.all(fnArr.map(fn => fn()));\n}", "title": "" }, { "docid": "882ac7175a105d808d626ba3c922f8a1", "score": "0.6544443", "text": "function execute(){\n // passing input from the array for promise execution and removing it from the array.\n var timeout = timeouts.shift();\n console.log(timeouts.length,' '+ timeouts);\n execPromise(timeout,execute);\n}", "title": "" }, { "docid": "3952a2ee1c5aefe1c43a402bd1d38788", "score": "0.63485277", "text": "function seqPromises( promises ) {\n\t\treturn function( args ) {\n\t\t\tvar i = 0;\n\t\t\tvar p = promises[i++].action( args );\n\t\t\t// Cascade all hooks\n\t\t\twhile( i < promises.length ) {\n\t\t\t\tp = p.then( promises[i++].action );\n\t\t\t}\n\t\t\treturn p;\n\t\t};\n\t}", "title": "" }, { "docid": "e63f99475171cf3ff3d931776fc6296f", "score": "0.6330104", "text": "function promiseSeq( arr, predicate, consecutive=10 ) {\n return chunkArray(arr, consecutive).reduce(( prom, items, ix ) => {\n // wait for the previous Promise.all() to resolve\n return prom.then(( allResults ) => {\n console.log('\\nSET', ix);\n return Promise.all(\n // then we build up the next set of simultaneous promises\n items.map(( item ) => {\n // call the processing function\n return predicate(item, ix)\n })\n )\n .then(( results ) => {\n // then push the results into the collected array\n return allResults.concat(results);\n });\n });\n }, Promise.resolve([]));\n\n function chunkArray( startArray, chunkSize ) {\n let j = -1;\n return startArray.reduce(( arr, item, ix ) => {\n j += ix % chunkSize === 0 ? 1 : 0;\n arr[ j ] = [\n ...( arr[ j ] || []),\n item,\n ];\n return arr;\n }, []);\n }\n}", "title": "" }, { "docid": "ea8b8b9bdc41231380549cf82bd87fd3", "score": "0.6292677", "text": "function test2(){\n\tconsole.log('begin (2)');\n\t\n\tvar myPromises = [];\n\tfor (var int = 0; int < 5; int++) {\n\t\t\n\t\tvar asyncPromise = function(arg){\n\t\t\t\n\t\t\treturn Q.Promise(function(resolve,reject){\n\t\t\t\tasyncLog(arg,function(result){\n\t\t\t\t\tresolve(result);\n\t\t\t\t});\n\t\t\t})\n\t\t}\t\t\n\t\tmyPromises.push(asyncPromise(int));\n\t}\n\t\n\tQ.all(myPromises)\n\t\t.then(function(result){\n\t\t\tconsole.log('(2) allSettled : result = '+JSON.stringify(result));\n\t\t});\n\tconsole.log('end (2)');\n}", "title": "" }, { "docid": "13d935d94a1710979fa93ba51d3de6c3", "score": "0.62440467", "text": "batch_p(requests = [], config) {\n let _this = this;\n\n config = _.extend({\n split: 42,\n }, config);\n\n return new Promise((resolve, reject) => {\n if (!Array.isArray(requests)) {\n reject({error: {message: 'TypeError'}});\n }\n\n let promises = [];\n\n while (requests.length) {\n let promises_part = requests.splice(0, config.split);\n promises.push(_this.api_p('/', 'post', {batch: promises_part}));\n }\n\n Promise.all(promises.map(p => p.catch(e => e)))\n .then(response => {\n let result = [];\n\n response.forEach((response_array) => {\n response_array.forEach((item) => {\n try {\n result.push(JSON.parse(item.body));\n } catch (e) {\n result.push({error: {message: 'JSON.parse() of item.body failed', item: item}});\n }\n });\n });\n\n resolve(result);\n });\n\n });\n }", "title": "" }, { "docid": "7eef1b5349d8b780444669366bbbf082", "score": "0.6195866", "text": "async chapter_sample(param, prev){\n\n let tgt = ['foo', 'bar', 'baz'];\n let res = [];\n let handler = Promise.all(tgt.map((ver) => {\n\n return new Promise((resolve, reject) => {\n\n // Generates handler object.\n let w = this.core.backroom.pop({\n data: ver\n });\n\n // Main loop.\n w.run(async (data) => {\n let ret = [];\n await (new Promise((res) => {\n console.log(\"waiting\", data);\n setTimeout(() => {\n res();\n }, 1000)\n }));\n // Do Your Heavy Things.\n for(let i = 0; i < 100; i++){\n ret.push(data + \":\" + i);\n }\n return ret;\n }).then((r) => {\n res = res.concat(r);\n setTimeout(() => {\n resolve(r);\n }, 0);\n }).catch((e) => {\n reject(e);\n });\n\n });\n\n }));\n\n handler\n .then(() => {\n console.log(\"RESULT\", res);\n })\n .catch((e) => {\n console.log(e);\n });\n\n }", "title": "" }, { "docid": "57a5032ad02a06129c76c6b3e709fda3", "score": "0.61688447", "text": "function goThroughArray(arr) {\n var i = 0;\n return iterate();\n\n\n function iterate(){\n return Promise.resolve(turnOnLight(arr[i]))\n .then(function(){\n i++;\n return function(resolve){\n setTimeout(resolve, 500);\n }\n })\n .then(function(resolve){\n if (i < arr.length) iterate();\n else resolve\n });\n }\n }", "title": "" }, { "docid": "78b0628cfc5634d371d475a96ed105e8", "score": "0.6156121", "text": "function sequence(values, fn, initialValue) {\n var result = Promise.resolve(initialValue);\n values.forEach(function (value) {\n result = result.then(function (lastResult) {\n return fn(value, lastResult);\n });\n });\n return result;\n}", "title": "" }, { "docid": "c1c060a14f6aaaeb331bb68a728f72c1", "score": "0.6153595", "text": "function racePromises(promises) {\n return new Promise(function (resolve, reject) { return promises.forEach(function (value) { return Promise.resolve(value).then(resolve, reject); }); });\n}", "title": "" }, { "docid": "c0256f640701783853c9e5acaba027e7", "score": "0.6138457", "text": "function waitForAll(result) {\n\t\t//console.log(\"waiting\", resultArr);\n return Promise.all(result).then(function(resArr){ \n result.pop();\n result.push(resArr);\n return result;\n })\n }", "title": "" }, { "docid": "57fb73dcade6e4da44c4674a1cf1266b", "score": "0.6074314", "text": "function each (fn) {\n assert.equal(typeof fn, 'function')\n return function (arr) {\n arr = Array.isArray(arr) ? arr : [arr]\n\n return arr.reduce(function (prev, curr, i) {\n return prev.then(function () { return fn(curr, i, arr.length) })\n }, Promise.resolve()).then(function () {})\n }\n}", "title": "" }, { "docid": "d879d739eda15538757981b19a148b1a", "score": "0.59888816", "text": "function eachSeries(arr, fun) {\n\t return arr.reduce(function (p, e) {\n\t return p.then(function () {\n\t return fun(e);\n\t });\n\t }, Promise.resolve());\n\t}", "title": "" }, { "docid": "8cffeeb3126e11e57cea380cb4aa2108", "score": "0.59785676", "text": "function generatePromises(data) {\n let ret = [];\n \n try {\n let json = JSON.parse(data);\n for (let i = json.relations.length; i > 0; --i) {\n if (json.relations[i] && json.relations[i].type && json.relations[i].type === 'wikipedia') {\n let arr = (json.relations[i].url.resource).split('/');\n ret.push(wikipediaApiCall(arr[arr.length - 1]));\n break;\n }\n }\n\n for (let j = json['release-groups'].length - 1; j >= 0; j--) {\n if (json['release-groups'][j]) {\n ret.push(coverArtArchiveApiCall(json['release-groups'][j].id, {\n \"title\": json['release-groups'][j].title,\n \"id\": json['release-groups'][j].id,\n \"images\": []\n }));\n }\n }\n\n } catch (e) {\n return [new Promise((resolve, reject) => {\n reject(e);\n })];\n }\n\n if (!ret.length) {\n return [new Promise((resolve, reject) => {\n reject(e);\n })];\n } else {\n return ret;\n }\n}", "title": "" }, { "docid": "8eb91aea773ef0ce0e248f05bfae793c", "score": "0.59566855", "text": "async function testlinkArray(array) {\n let results = [];\n /* for(let i=0;i<array.length;i++){\n console.log(array[i]);\n let res=await startRequest(array[i]);\n if (res.statusCode === 200) {\n res.destroy();\n results.push(array[i]);\n } else {\n res.destroy();\n }\n } */\n\n let promiseArray = [];\n array.forEach(element => {\n if (element.toLowerCase().indexOf(\"https\") >= 0) {\n promiseArray.push(startRequestHttps(element));\n }\n else {\n promiseArray.push(startRequest(element));\n }\n });\n let resArray = await Promise.all(promiseArray);\n for (let res of resArray) {\n //console.log(res.req.agent.protocol);\n if (res.statusCode === 200) {\n results.push(res.req.agent.protocol+\"//\"+res.req.socket._host + res.req.path);\n }\n res.destroy();\n }\n\n return results;\n\n function startRequest(url) {\n return new Promise((resolve, reject) => {\n let req = Http.request(url, { timeout: 3000 }, res => { resolve(res) });\n req.end();\n });\n }\n function startRequestHttps(url) {\n return new Promise(function (resolve, reject) {\n let req = Https.request(url, { timeout: 3000 }, res => { resolve(res) });\n req.end();\n });\n }\n /* function testlink(url, callback) {\n let req = Http.request(\"url\", { timeout: 3000 }, callback);\n console.log(111111);\n req.end();\n }\n console.log(2222222);\n function series(url) {\n if (typeof (url) == 'string') {\n console.log(333333333333);\n testlink(url, res => {\n if (res.statusCode === 200) {\n console.log(444444);\n res.destroy();\n results.push(url);\n } else {\n res.destroy();\n }\n return series(array.shift());\n });\n }else{\n console.log(555555);\n return results;\n }\n }\n console.log(66666666);\n series(array.shift());\n console.log(777777777); */\n}", "title": "" }, { "docid": "6e30471eb7b3ce52a404c8a5797a2dc2", "score": "0.5954715", "text": "handlePayments(organization, payments) {\n let _this = this;\n return new Promise((resolve, reject) => {\n let paymentList = [];\n let paymentPromises = [];\n let payment = new Payments(_this.univers, organization);\n for(let i in payments) {\n paymentPromises.push(payment.handleCreatePayment(payments[i]).then((p) => {\n paymentList.push(p);\n }));\n }\n\n Promise.all(paymentPromises).then((result) => {\n return resolve(paymentList);\n }).catch((err) => {\n return reject(err);\n })\n });\n }", "title": "" }, { "docid": "4f3876ee5c85d9f043ee4a9de6871c33", "score": "0.5865849", "text": "function all(list) {\n\tlet result=[];\n\tlet count=0;\n\tlet newPromise=new Promise((res,rej) => {\n\t\tfor(let i=0; i<list.length; i++){\n\t\t\tlist[i].then(msg => {\n\t\t\t\tcount++;\n\t\t\t\tresult[i]=msg;\n\t\t\t\tif(count===list.length){res(result)};\n\t\t\t});\n\t\t}\n\n\t\t// ideally `res(['it', 'works'])`\n\t\treturn result;\n\t});\n\n\tconsole.log(result);\n\n\t// Part 2 TODO: add your implementation here\n\treturn newPromise;\n}", "title": "" }, { "docid": "b582336fdf5e66db17f8e6c9d9cee63e", "score": "0.5858965", "text": "function sequence(items, consumer) {\n\t var results = [];\n\t var runner = function runner() {\n\t var item = items.shift();\n\t if (item) {\n\t return consumer(item).then(function (result) {\n\t results.push(result);\n\t }).then(runner);\n\t }\n\t\n\t return Promise.resolve(results);\n\t };\n\t\n\t return runner();\n\t}", "title": "" }, { "docid": "70d300aa73e40bfa669ebec970d027e3", "score": "0.58549917", "text": "getAll() {\n // dummy\n return Promise.resolve([1, 2, 3]);\n }", "title": "" }, { "docid": "ab41ee7bb8747289e06deb596938bdd3", "score": "0.58444816", "text": "function mainIter() {\n return new Promise(function(resolve, reject) {\n //console.log(url_array[data_count]);\n newPage().then(function(pageSuccessMsg) {\n console.log(pageSuccessMsg);\n return new Promise(function(resolve, reject) {\n setTimeout(function() {\n resolve();\n }, nextPageWait);\n });\n }).then(function() {\n return pageNav(\"https://www.cnn.com\");\n }).then(function(pageNavMessage) {\n console.log(pageNavMessage);\n return new Promise(function(resolve, reject) {\n setTimeout(function() {\n resolve();\n }, pageLoadWait);\n });\n }).then(function() {\n data_count++;\n setTimeout(function() {\n resolve();\n }, nextPageWait);\n });\n });\n }", "title": "" }, { "docid": "7109d94757712ebd4b15b7efed65f9e5", "score": "0.58344054", "text": "function eachSeries(arr, fun) {\n return arr.reduce(function (p, e) {\n return p.then(function () {\n return fun(e);\n });\n }, Promise.resolve());\n}", "title": "" }, { "docid": "7109d94757712ebd4b15b7efed65f9e5", "score": "0.58344054", "text": "function eachSeries(arr, fun) {\n return arr.reduce(function (p, e) {\n return p.then(function () {\n return fun(e);\n });\n }, Promise.resolve());\n}", "title": "" }, { "docid": "7109d94757712ebd4b15b7efed65f9e5", "score": "0.58344054", "text": "function eachSeries(arr, fun) {\n return arr.reduce(function (p, e) {\n return p.then(function () {\n return fun(e);\n });\n }, Promise.resolve());\n}", "title": "" }, { "docid": "480b774d30d59dc502a263a34e165389", "score": "0.5829049", "text": "function asyncAll (\n\t array ,\n\t fn ,\n\t callback \n\t) {\n\t if (!array.length) { return callback(null, []); }\n\t var remaining = array.length;\n\t var results = new Array(array.length);\n\t var error = null;\n\t array.forEach(function (item, i) {\n\t fn(item, function (err, result) {\n\t if (err) { error = err; }\n\t results[i] = ((result ) ); // https://github.com/facebook/flow/issues/2123\n\t if (--remaining === 0) { callback(error, results); }\n\t });\n\t });\n\t}", "title": "" }, { "docid": "05494bd700039daed8a491c11183e79e", "score": "0.582071", "text": "function bundle(ps, shouldFulfillCB) {\n\t\tif (!Array.isArray(ps)) ps = [ps];\n\t\tvar p = promise(), nPromises = ps.length, nFinished = 0;\n\t\tif (nPromises === 0) {\n\t\t\tp.fulfill([]);\n\t\t\treturn p;\n\t\t}\n\n\t\tvar results = []; results.length = nPromises;\n\t\tvar fails = [];\n\t\tvar addResult = function(v, index, isfail) {\n\t\t\tresults[index] = v;\n\t\t\tif (isfail) fails.push(index);\n\t\t\tif ((++nFinished) == nPromises) {\n\t\t\t\tif (!shouldFulfillCB) p.fulfill(results);\n\t\t\t\telse if (shouldFulfillCB(results, fails)) p.fulfill(results);\n\t\t\t\telse p.reject(results);\n\t\t\t}\n\t\t};\n\t\tfor (var i=0; i < nPromises; i++)\n\t\t\tpromise(ps[i]).succeed(addResult, i, false).fail(addResult, i, true);\n\t\treturn p;\n\t}", "title": "" }, { "docid": "b99c9a72782212ab425d0beecc1bf1f7", "score": "0.58205026", "text": "function arrayIterate(values, fn) {\n return new Promise(((resolve, reject) => {\n // Are there any values to check?\n if (values.length === 0) {\n // All were rejected\n reject()\n }\n // Try the first value\n fn(values[0]).then((val) => {\n // Resolved, we're all done\n resolve(val)\n }).catch(() => {\n // Rejected, remove the first item from the array and recursively\n // try the next one\n values.shift()\n arrayIterate(values, fn).then(resolve).catch(reject)\n })\n }))\n}", "title": "" }, { "docid": "cb74db95d74abeca852c08013cb5d7ea", "score": "0.5805406", "text": "function makeActorPromises() {\n // empty arr that actors is pushed into\n let promiseArray = [];\n // loops through moviesArry (movie data)\n for (let i = 0; i < movieArr.length; i++) {\n // sets actorURL to url that gets actor info\n let actorURL = `https://api.themoviedb.org/3/movie/${movieArr[i]}/credits?api_key=${dbGet.key}`;\n // adds actors to promiseArr\n promiseArray.push(getActors(actorURL));\n }\n return promiseArray;\n}", "title": "" }, { "docid": "b6550ffeb4a1be00a6fbdf21581886a0", "score": "0.5792095", "text": "async function obtenerPersonajes(){\n try {\n let ids = [1, 2, 3, 4, 5, 6, 7]\n let promises = ids.map( obtenerPersonaje)\n // Usamos await para que la ejecucion de codigo no avanze hasta que se ejecuten todas las promesas, entonces se guardar en\n // la variable personajes\n var personajes = await Promise.all(promises)\n console.log(personajes)\n } catch (error) {\n onerror(error) \n }\n \n}", "title": "" }, { "docid": "32690443420972d1e15646806eec9247", "score": "0.5789478", "text": "async function obtrenerPersonajes(){\nvar ids = [1,2,3,4,5,6,7]\nvar promesas = ids.map(id => obtenerPersonaje(id))\ntry{\n var personajes = await Promise.all(promesas)\n console.log(personajes)\n}catch(id){\n onError(id)\n}\n}", "title": "" }, { "docid": "db93353a9ab54a0dad2a84f49d36bb97", "score": "0.57561237", "text": "function aa(){\n\t\treturn new Promise(function(resolve, reject){\n\t\t\tresponseArray.forEach(function(element, index, array){\n\t\t\t\tconsole.log(\"iteratively: \" + JSON.stringify(data));\n\t\t\t\telement.json(data);\n\t\t\t});\t\t\t\n\t\t\tresolve(responseArray.length);\n\t\t})\n\t}", "title": "" }, { "docid": "bf6670ff94746b5ab6abb65ad81e148f", "score": "0.57558775", "text": "async function old(){\n for(const prom of await Promise.all(promiseArr)){\n console.log('for old:', prom)\n }\n}", "title": "" }, { "docid": "8a715ff85ad9ddc42a5024890d07ba45", "score": "0.57537323", "text": "function bundle(ps, shouldFulfillCB) {\n\tif (!Array.isArray(ps)) ps = [ps];\n\tvar p = promise(), nPromises = ps.length, nFinished = 0;\n\tif (nPromises === 0) {\n\t\tp.fulfill([]);\n\t\treturn p;\n\t}\n\n\tvar results = []; results.length = nPromises;\n\tvar fails = [];\n\tvar addResult = function(v, index, isfail) {\n\t\tresults[index] = v;\n\t\tif (isfail) fails.push(index);\n\t\tif ((++nFinished) == nPromises) {\n\t\t\tif (!shouldFulfillCB) p.fulfill(results);\n\t\t\telse if (shouldFulfillCB(results, fails)) p.fulfill(results);\n\t\t\telse p.reject(results);\n\t\t}\n\t};\n\tfor (var i=0; i < nPromises; i++)\n\t\tpromise(ps[i]).succeed(addResult, i, false).fail(addResult, i, true);\n\treturn p;\n}", "title": "" }, { "docid": "25179c96add79e62f1e358a49d3554a3", "score": "0.57418936", "text": "runSteps() {\n return Promise.all(buildSteps.map(step => this.runStep(new step(this))));\n }", "title": "" }, { "docid": "6f6cb57e465da09f8a6d76d29ab237de", "score": "0.57309765", "text": "function makeTasks(done) {\n var taskParams = [\n [1, 300]\n , [2, 200]\n , [3, 100]\n , [4, 500]\n , [5, 100]\n ]\n ;\n\n // Task functions are not really async, but work for testing purposes\n // generateTask :: [Int, Int] -> ( (a -> b) -> IO )\n function generateTask(ps) {\n return function (f) {\n setTimeout(function () { f(ps[0]); }, ps[1], done.fail);\n };\n }\n\n return taskParams.map(generateTask);\n }", "title": "" }, { "docid": "acf4885f834b05154b8fe4fde7224022", "score": "0.5711166", "text": "function parallel(args, callback)\n{\n\tvar funcs, rv, doneOne, i;\n\n\tmod_assert.equal(typeof (args), 'object', '\"args\" must be an object');\n\tmod_assert.ok(Array.isArray(args['funcs']),\n\t '\"args.funcs\" must be specified and must be an array');\n\tmod_assert.equal(typeof (callback), 'function',\n\t 'callback argument must be specified and must be a function');\n\n\tfuncs = args['funcs'].slice(0);\n\n\trv = {\n\t 'operations': new Array(funcs.length),\n\t 'successes': [],\n\t 'ndone': 0,\n\t 'nerrors': 0\n\t};\n\n\tif (funcs.length === 0) {\n\t\tsetImmediate(function () { callback(null, rv); });\n\t\treturn (rv);\n\t}\n\n\tdoneOne = function (entry) {\n\t\treturn (function (err, result) {\n\t\t\tmod_assert.equal(entry['status'], 'pending');\n\n\t\t\tentry['err'] = err;\n\t\t\tentry['result'] = result;\n\t\t\tentry['status'] = err ? 'fail' : 'ok';\n\n\t\t\tif (err)\n\t\t\t\trv['nerrors']++;\n\t\t\telse\n\t\t\t\trv['successes'].push(result);\n\n\t\t\tif (++rv['ndone'] < funcs.length)\n\t\t\t\treturn;\n\n\t\t\tvar errors = rv['operations'].filter(function (ent) {\n\t\t\t\treturn (ent['status'] == 'fail');\n\t\t\t}).map(function (ent) { return (ent['err']); });\n\n\t\t\tif (errors.length > 0)\n\t\t\t\tcallback(new mod_verror.MultiError(errors), rv);\n\t\t\telse\n\t\t\t\tcallback(null, rv);\n\t\t});\n\t};\n\n\tfor (i = 0; i < funcs.length; i++) {\n\t\trv['operations'][i] = {\n\t\t\t'func': funcs[i],\n\t\t\t'funcname': funcs[i].name || '(anon)',\n\t\t\t'status': 'pending'\n\t\t};\n\n\t\tfuncs[i](doneOne(rv['operations'][i]));\n\t}\n\n\treturn (rv);\n}", "title": "" }, { "docid": "7c2a9a19ecb59e34e3f1df226eb108dd", "score": "0.5701506", "text": "function promiseMap(xs, f) {\n const n = xs.length - 1\n const loop = i => f(xs[i], i).then(\n y => i >= n ? [y] : loop(i + 1).then(ys => [y, ...ys])\n )\n return loop(0)\n}", "title": "" }, { "docid": "1267c60bc4ef364194a7f8a621900b47", "score": "0.56958497", "text": "async function generateMultiRequest(options, array) {\n\tconst requests = [];\n\tif (!templateParser) {\n\t\ttemplateParser = options.parseFunction;\n\t}\n\tif (!templateNameForParser) {\n\t\ttemplateNameForParser = options.templateName;\n\t}\n\n\tfor (let j = options.beginning; j < options.end; j++) {\n\t\tconst timedPromise = new Promise((resolve, reject) => {\n\t\t\tconst url = `https://www.arcgis.com/sharing/rest/content/items/${\n\t\t\t\tarray[j]\n\t\t\t}/data?f=json`;\n\t\t\tlet currentId = array[j];\n\t\t\tlet currentJ = j;\n\n\t\t\taxios\n\t\t\t\t.get(url)\n\t\t\t\t.then(axiosResponse => {\n\t\t\t\t\tif (axiosResponse) {\n\t\t\t\t\t\taxiosResponse.id = currentId;\n\t\t\t\t\t}\n\t\t\t\t\tresolve(axiosResponse);\n\t\t\t\t})\n\t\t\t\t.catch(() => {\n\t\t\t\t\tfailedIds.push(currentId);\n\t\t\t\t\tnewItems = [];\n\t\t\t\t\tresolve();\n\t\t\t\t});\n\t\t});\n\t\trequests.push(timedPromise);\n\t}\n\tawait Promise.all(requests)\n\t\t.then(res => {\n\t\t\tparseResponses(res, array);\n\t\t})\n\t\t.catch(() => {\n\t\t\tnewItems = [];\n\t\t\tgenerateMultiRequest(\n\t\t\t\t{\n\t\t\t\t\tbeginning: end,\n\t\t\t\t\tend: end + batchSize\n\t\t\t\t},\n\t\t\t\tarray\n\t\t\t);\n\t\t});\n}", "title": "" }, { "docid": "5e62f271e67e51b5e8598b4a49204ae6", "score": "0.5692516", "text": "function xrayPromise(...args) {\n return new Promise(( resolve, reject ) => {\n xray(...args)(( err, obj ) => {\n if ( err ) {\n return reject(err);\n }\n return resolve(obj);\n });\n });\n}", "title": "" }, { "docid": "fb6334a13b32f084eddea68e2bc4eb83", "score": "0.5690607", "text": "function when() {\n var promises = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n promises[_i - 0] = arguments[_i];\n }\n var allDone = defer();\n if (!promises.length) {\n allDone.resolve([]);\n return allDone.promise();\n }\n var resolved = 0;\n var results = [];\n promises.forEach(function (p, i) {\n p.done(function (v) {\n results[i] = v;\n ++resolved;\n if (resolved === promises.length && allDone.status !== 1 /* Rejected */)\n allDone.resolve(results);\n }).fail(function (e) {\n if (allDone.status !== 1 /* Rejected */)\n allDone.reject(new Error(\"when: one or more promises were rejected\"));\n });\n });\n return allDone.promise();\n }", "title": "" }, { "docid": "8c1306236d82122bab4c16d1481e0a50", "score": "0.56901103", "text": "function load_files(files_array){\n //https://stackoverflow.com/questions/49744707/how-to-use-promise-all-on-array-of-promises-which-take-parameters\n Promise.all(\n files_array.map( //map location to promise\n file => loadfile(file))) // promises\n .then(results => { \n // executed when all promises resolved, \n // results is the array of results resolved by the promises\n console.log(results);\n //call Nim\n onReadyNimCallback();\n })\n .catch(err => { \n // catch if single promise fails to resolve\n console.log(err);\n });\n}", "title": "" }, { "docid": "e39176ae8d84f023293ee2add4090736", "score": "0.5654322", "text": "function makeRequestsFromArray(arr) {\n let index = 0;\n\n console.log(\"function test1\");\n \n\n request();\n\n\n\n\n function request() {\n // console.log(\"ugh\");\n return axios.get('http://www.philart.net/api/art/' + index + '.json').then((response) => {\n let artwork = {};\n\n console.log(\"function test\");\n\n artwork.artist = response.data.body.artists[0].name;\n artwork.title = response.data.body.title.display;\n artwork.imageurl = response.data.body.pictures[0].large.url;\n artwork.lat = response.data.body.location.latitude;\n artwork.lng = response.data.body.location.longitude;\n artwork.location = response.data.body.location.description;\n\n Artwork.findOneAndUpdate(\n { title: response.data.body.title.display },\n artwork,\n { upsert: true, new: true, runValidators: true })\n .then((dbArtwork) => {\n // console.log(dbArtwork);\n });\n index++;\n // console.log(index);\n if (index >= arr.length) {\n return 'done';\n }\n return request();\n })\n\n .catch(err => {\n // console.log(\"There was an error\");\n index++;\n return request();\n });\n };\n }", "title": "" }, { "docid": "da1829cf9bc7c9a46412d46fc7ee410e", "score": "0.5653796", "text": "function chain() {\n var functions = Array.prototype.slice.call(arguments, 0);\n if (functions.length > 0) {\n var firstFunction = functions.shift();\n var firstPromise = firstFunction.call();\n firstPromise.done(function () {\n chain.apply(null, functions);\n });\n }\n }", "title": "" }, { "docid": "409aae43599f7a3066fd4ffae4246369", "score": "0.5641625", "text": "function raceSucceed(promises) {\n return new Promise(function(resolve, reject) {\n var promisesThrown = 0;\n var drop = false;\n var errors = [];\n for (var i = 0; i < promises.length; i++) {\n (function(i) {\n promises[i].then(function(result) {\n if (!drop && errors[i] == undefined) {\n console.log(\"Promise \" + i + \" won!\");\n drop = true;\n resolve(result);\n }\n }, function(error) {\n console.log(\"Promise \" + i + \" had an error!\");\n console.log(error);\n errors[i] = error;\n promisesThrown += 1;\n if (promisesThrown == promises.length) {\n console.log(\"All rejected.\");\n reject(errors);\n }\n });\n }(i));\n }\n });\n}", "title": "" }, { "docid": "abc22511778b283e6f412ee7af2e938e", "score": "0.563261", "text": "function executeForeEach(array, func) {\n for(let i = 0; i < array.length; i++){\n func(array[i]);\n }\n return array;\n}", "title": "" }, { "docid": "3a99e79fc2819bf3caf8bdb8c6e6d9ff", "score": "0.5629581", "text": "function lift(fn) {\n return function () {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i - 0] = arguments[_i];\n }\n return Promise.all(args)\n .then(function (values) {\n return fn.apply(undefined, values);\n });\n };\n}", "title": "" }, { "docid": "b67e0f60e12e3406bec72ff02da0b350", "score": "0.56277806", "text": "function flushPromises () {\n return new Promise(resolve => setImmediate(resolve))\n }", "title": "" }, { "docid": "6795fb2f5a967666e27173d8825225f8", "score": "0.5626852", "text": "function resolvePromisesSequentially(promiseFunctions) {\n if (!Array.isArray(promiseFunctions)) {\n throw new Error(\"First argument needs to be an array of Promises\");\n }\n\n return new Promise(function (resolve, reject) {\n var count = 0;\n var results = [];\n\n function iterationFunction(previousPromise, currentPromise) {\n return previousPromise.then(function (result) {\n if (count++ !== 0) {\n results = results.concat(result);\n }\n\n return currentPromise(result, results, count);\n }).catch(function (err) {\n return reject(err);\n });\n }\n\n promiseFunctions = promiseFunctions.concat(function () {\n return Promise.resolve();\n });\n promiseFunctions.reduce(iterationFunction, Promise.resolve(false)).then(function () {\n resolve(results);\n });\n });\n}", "title": "" }, { "docid": "7c552d499a1cc0676a2be4c75d308ed0", "score": "0.56045365", "text": "function delayPromisers(promisers, delayMillis=DEFAULT_DELAY_MILLIS){\n\treturn promisers.map(p => {\n\t\treturn function() {\n\t\t\treturn new Promise((resolve) => {\n\t\t\t\tsetTimeout( () => { resolve( p() ); }, delayMillis);\n\t\t\t})\n\t\t\t;\n\t\t};\n\t});\n}", "title": "" }, { "docid": "0cd720741a991c47b4764e5410f2ac9d", "score": "0.5596957", "text": "function pool(promiseFactories, limit) {\n return new Promise(function (resolve, reject) {\n var running = 0;\n var current = 0;\n var done = 0;\n var len = promiseFactories.length;\n var err;\n\n function runNext() {\n running++;\n promiseFactories[current++]().then(onSuccess, onError);\n }\n\n function doNext() {\n if (++done === len) {\n /* istanbul ignore if */\n if (err) {\n reject(err);\n } else {\n resolve();\n }\n } else {\n runNextBatch();\n }\n }\n\n function onSuccess() {\n running--;\n doNext();\n }\n /* istanbul ignore next */\n\n\n function onError(thisErr) {\n running--;\n err = err || thisErr;\n doNext();\n }\n\n function runNextBatch() {\n while (running < limit && current < len) {\n runNext();\n }\n }\n\n runNextBatch();\n });\n}", "title": "" }, { "docid": "e53845704415369c8ffacd17c7e84d4a", "score": "0.55961865", "text": "reduceOrderPromises(promises) {\n const promise = promises.shift();\n if (promise) {\n promise().then(() => {\n this.reduceOrderPromises(promises);\n });\n }\n }", "title": "" }, { "docid": "31395ddc43db45a28190ba4e918e7229", "score": "0.55838823", "text": "static async _runReturnHandlers(handlers) {\n for (const handler of handlers) {\n await new Promise((resolve, reject) => {\n handler((err) => (err ? reject(err) : resolve()))\n })\n }\n }", "title": "" }, { "docid": "2238b0a63e65259c103d3599c79bd1e5", "score": "0.5581484", "text": "function forAsync(arr, work) {\n\tfunction loop(arr, i) {\n\t\treturn new Promise((resolve, reject) => {\n\t\t\tif (i >= arr.length) { resolve() }\n\t\t\telse try {\n\t\t\t\tPromise.resolve(work(arr[i], i))\n\t\t\t\t\t.then(() => resolve(loop(arr, i + 1)))\n\t\t\t\t\t.catch(reject);\n\t\t\t} catch (error) { reject(error) }\n\t\t})\n\t}\n\treturn loop(arr, 0);\n}", "title": "" }, { "docid": "609dced474b7c8b7b3513747a1e24984", "score": "0.55739045", "text": "scrapeDataForMultipleUrls(urls){\n return Promise.all(urls.map(this.scrapeDataForOneUrl.bind(this)));\n }", "title": "" }, { "docid": "898795cbeaf03d9b93128670fe220669", "score": "0.55698913", "text": "function flushPromises() {\n return new Promise(function (resolve) { return setImmediate(resolve); });\n }", "title": "" }, { "docid": "f70a74151e771fbd2308af72764f8c4d", "score": "0.5566686", "text": "function thenUntilOutOfCallBacks(promise) {\n let count = 0;\n while(arguments[count]) {\n let callback = arguments[count]\n promise = promise.then(callback)\n count += 1\n }\n return promise\n}", "title": "" }, { "docid": "003fe2334c0cf5466e5e0f0f4b81e0f5", "score": "0.5564631", "text": "function pool(promiseFactories, limit) {\n return new Promise(function (resolve, reject) {\n var running = 0;\n var current = 0;\n var done = 0;\n var len = promiseFactories.length;\n var err;\n\n function runNext() {\n running++;\n promiseFactories[current++]().then(onSuccess, onError);\n }\n\n function doNext() {\n if (++done === len) {\n /* istanbul ignore if */\n if (err) {\n reject(err);\n } else {\n resolve();\n }\n } else {\n runNextBatch();\n }\n }\n\n function onSuccess() {\n running--;\n doNext();\n }\n\n /* istanbul ignore next */\n function onError(thisErr) {\n running--;\n err = err || thisErr;\n doNext();\n }\n\n function runNextBatch() {\n while (running < limit && current < len) {\n runNext();\n }\n }\n\n runNextBatch();\n });\n}", "title": "" }, { "docid": "8e7cccd64f411293a915d1e66a7a62f2", "score": "0.55614305", "text": "function all (promiseArr) {\n // deferred to handle all the promiseArr members being finished\n var allFinishedDeferred = q.defer();\n\n // holder for the resolved values of each promiseArr member\n var finishedValuesArr = [];\n\n // flag to indicate whether all promiseArr members are resolved\n var allFinished = false;\n\n // promiseArr members paired with a flag indicating whether it is finished\n // a flag is used (instead of checking for a resolved value) so that promises\n // can resolve with value undefined values.\n var finishedArr = promiseArr.map(function (promise) {\n return {\n promise: promise,\n isFinished: false\n };\n });\n\n finishedArr.forEach(function (promiseObj, index) {\n promiseObj.promise.then(function (value) {\n finishedValuesArr[index] = value;\n promiseObj.isFinished = true;\n\n allFinished = finishedArr.every(function (promiseObj) {\n return promiseObj.isFinished;\n });\n\n if (allFinished) {\n allFinishedDeferred.resolve(finishedValuesArr);\n }\n\n });\n });\n\n return allFinishedDeferred.promise;\n }", "title": "" }, { "docid": "1d42a42c0282865fea9fadde2e99292d", "score": "0.55581397", "text": "function GetPromises(type) { // this function turns all of the http requests into promises\n const promises = []; // array to store the promises\n for (let i = 0; i < 10; i += 1) { // for loop goes to 10 because there are 10 pages in the API\n promises.push(new Promise(((resolve, reject) => {\n axios.get('https://temp-data.herokuapp.com/' + type + '?pageNum='\n + i, {\n headers: {\n Authorization: process.env.API_KEY // Using the Bearer Token for Authorization\n } // calling the API with axios\n }).then((response) => {\n resolve(response.data); // returning the data as a successful Promise\n }).catch((err) => {\n reject(err); // returning the error as a unsuccessful Promise\n });\n })));\n }\n return promises; // returning all of the promises\n}", "title": "" }, { "docid": "495a438221be7ab2b7c69f1a508ce96d", "score": "0.5553794", "text": "function a(e,t,n,i){return new(n||(n=Promise))((function(r,a){function o(e){try{l(i.next(e))}catch(t){a(t)}}function s(e){try{l(i[\"throw\"](e))}catch(t){a(t)}}function l(e){e.done?r(e.value):new n((function(t){t(e.value)})).then(o,s)}l((i=i.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "a667ded8de227505640df34e0bdbfa9b", "score": "0.5551695", "text": "function chainPromises(calls, val) {\n if (!calls || !calls.length) {\n return Q.when(val);\n }\n return calls.reduce(Q.when, Q.when(val));\n}", "title": "" }, { "docid": "2e2665cf4e4d8932ecca54bfa1db055b", "score": "0.5548955", "text": "function m(e,t,n,a){return new(n||(n=Promise))((function(r,s){function i(e){try{u(a.next(e))}catch(e){s(e)}}function o(e){try{u(a.throw(e))}catch(e){s(e)}}function u(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(i,o)}u((a=a.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "d3c99f343d0291fd8cff4154a56839be", "score": "0.554496", "text": "function callPrintful(newOrdersArray) {\n return new Promise(function (resolve, reject) {\n var ok_callback = function (data, info) {\n console.log('SUCCESS');\n console.log(data);\n\n //If response includes paging information, show total number available\n if (info.total_items) {\n console.log('Total items available: ' + info.total_items);\n }\n }\n\n var error_callback = function (message, info) {\n console.log('ERROR ' + message);\n //Dump raw response\n console.log(info.response_raw);\n }\n\n ///Construct client\n var pf = new PrintfulClient(printfulKey);\n // \"external_variant_id\" is how Printful tracks items\n for (var i = 0; i < newOrdersArray.length; i++) {\n pf.post('orders',\n {\n recipient: {\n name: newOrdersArray[i].ship_to_name,\n address1: newOrdersArray[i].ship_to_street,\n city: newOrdersArray[i].ship_to_city,\n state_code: newOrdersArray[i].ship_to_state,\n country_code: newOrdersArray[i].ship_to_country_code,\n zip: newOrdersArray[i].ship_to_zip\n },\n items: [\n {\n external_variant_id: newOrdersArray[i].variant_id,\n name: newOrdersArray[i].item_name,\n quantity: 1,\n }\n ]\n }\n ).success(ok_callback).error(error_callback);\n }\n resolve(newOrdersArray);\n });\n\n}", "title": "" }, { "docid": "4b7ffb66e3380ca97a694c7199a96f0b", "score": "0.5543182", "text": "async function obtenemosPersonajesConAsynAwait() {\n var ids = [1, 2, 3, 4, 5]\n var promesas = ids.map( id => obtenerPersonaje(id) )\n try {\n var personajes = await Promise.all(promesas)\n console.log(personajes)\n } catch(reason) {\n console.log(reason)\n }\n}", "title": "" }, { "docid": "9ae2a0af6208fd09ebf822b0dffee4f9", "score": "0.5542247", "text": "execRequests(actions) {\n return Promise.all(\n actions.map(({ method, path, data }) => {\n return this[method](path, data);\n })\n );\n }", "title": "" }, { "docid": "5928d387e384c1602cd3b3e8e52f223a", "score": "0.5541409", "text": "function TriggerPromiseReactions(reactions, argument) {\n for (var i = 0, len = reactions.length; i < len; ++i)\n EnqueueJob('PromiseJobs', PromiseReactionJob, [reactions[i], argument]);\n return undefined;\n }", "title": "" }, { "docid": "994734e67e09a9e37567acfdae8e2f6e", "score": "0.5540994", "text": "function returnArgumentsAsRealArrayUsingCall() {}", "title": "" }, { "docid": "116e976aae927de135cf9bbb61feaa12", "score": "0.5524817", "text": "function createPoems(cb) {\n async.parallel([\n function(callback) {\n poemCreate('THE GREATEST', 'Charles John Quarto', false, '1980', '1982', 'Poem', ['The greatest event I ever saw',\n 'Took place in the Catskill Mountains',\n 'When Harry Blankley my grandfather',\n 'Threw rocks at a low flying helicopter',\n 'Not understanding those confounded things',\n 'While I stood with my dumbfounded cousins',\n 'And watched the greatest event I ever saw',\n 'It was the greatest breaking of the Law'], false, false, 'The greatest event I ever saw', callback);\n },\n function(callback) {\n poemCreate('WEIGHTLIFTERS', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Ellen and I on Twenty Five A',\n 'Slow down our car mutually',\n 'There is something in the road',\n 'That will not move',\n 'The car halts',\n 'Shy of a dead collie',\n '\\n',\n 'We get out',\n 'And step into a sad ballet',\n 'Ellen almost stoops',\n 'She stops and weeps',\n 'Her tears don’t fall, they rise',\n 'I cannot lift the dog at all',\n 'I can barely lift my eyes . . .'], false, false, 'Ellen and I on Twenty Five A', callback);\n },\n function(callback) {\n poemCreate('TOWNES', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'He was a distant troubadour',\n 'When he was singing at my door',\n 'So I gave him all my money',\n 'That’s what the money’s for',\n '\\n',\n 'He was an owl of a man',\n 'He had the wisdom in his hand',\n 'He had the sunset in his eyes',\n 'He had the midnight in his sight',\n '\\n',\n 'He’d show up like a ghost',\n 'Deep in New Mexico',\n 'His songs were angel birds',\n 'That always saw you home',\n '\\n',\n 'He was a distant troubadour',\n 'A shadow of the truth',\n 'Sometimes he’d wander off',\n 'Without leaving the room',\n '\\n',\n 'He had a touch of the tumbleweed',\n 'In his throat',\n 'He didn’t say that much',\n 'Except in what he wrote',\n '\\n',\n 'And there lies the beauty',\n 'That he left in this world',\n 'Like an Indian blanket',\n 'Around a runaway girl . . .'], false, false, 'He was a distant troubadour', callback);\n },\n function(callback) {\n poemCreate('METEORS', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Bathing in the meteor shower',\n 'Oceans open to the light',\n 'Earth receives her baptism',\n 'Tonight',\n '\\n',\n 'And just then when you touched me',\n 'It was like an angel landing on a lily pad',\n 'With all your gentle might',\n 'The kiss of sight',\n '\\n',\n 'Let the love songs rockabye the blues',\n 'Let the breezes turn the Bible pages',\n 'Back through the beginning',\n 'Before the old and new',\n 'When the murmur became a choir',\n 'Unremoved',\n '\\n',\n 'And when the stars first dreamed themselves',\n 'A sky',\n 'To send wishes back to the world',\n 'In the form of meteors',\n 'I was already yours'], false, false, 'Bathing in the meteor shower', callback);\n },\n function(callback) {\n poemCreate('KING PRIDE 1956', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'June’s mask’s a comfort',\n 'And school is losing hold',\n 'Grandma has squired her rocker',\n 'Nearby the kitchen stove',\n 'Where it’s muffins as ever',\n 'Kingpride, her cat,',\n 'The world champion mousetrap',\n 'Is smiling like a hunter',\n 'In Grandma’s sweet clutch',\n '\\n',\n 'Grandpa was on the roof',\n 'This morning, getting',\n 'Ready for Heaven',\n 'He was really reading',\n 'The Bible awfully loud',\n 'He rattled swarms of crows',\n 'And I love the way he’s proud',\n '\\n',\n 'I burst with the Field',\n 'And Stream magazine',\n 'Out on the porch',\n 'Inventing what I’ll be',\n 'Yesterday, I saw a peacock',\n 'Who may have recognized me . . .'], false, false, 'June’s mask’s a comfort', callback);\n },\n function(callback) {\n poemCreate('ALMOST', 'Charles John Quarto', false, '1980', '1982', 'Poem', [\n 'My father lay in his hammock',\n 'Like a snake in sneakers',\n 'His brothers arrived like junk mail',\n 'My sister shrank in her doll house',\n 'In a snowy fairy tale while',\n 'I ran the country of my room',\n 'Like some kid ghost',\n '\\n',\n 'My cousin wore thin socks',\n 'And failed to salute my dog',\n 'Even though it was a holiday',\n 'Mother was swimming in the cooking sherry',\n 'Floating through household chores',\n 'In hazy charge of the cheeseburgers',\n '\\n',\n 'At the maple shaded picnic table',\n 'Smiling diver flies struck',\n 'At the cow’s eyes of the ketchup spills',\n 'And my father made a fist',\n 'Out of his face',\n 'His brothers swallowed',\n 'A bottle’s worth of olives',\n 'As the radio played Patti Page',\n 'And Perry Como',\n 'Until my cousin’s socks collapsed',\n '\\n',\n 'That night',\n 'My father had a new explosion',\n 'When I went to the softball game',\n 'With Elihu Robinson',\n 'And came home way after the rules',\n 'Right away he crushed my fun',\n 'But when I asked him',\n 'How come the moon was allowed',\n 'To stay out so late',\n 'He almost called me son . . . .'], false, false, 'My father lay in his hammock', callback);\n },\n function(callback) {\n poemCreate('BLUE MORNING STARS', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Remember the drift of the days',\n 'By the river',\n 'When we swore we’d be each other’s',\n 'Blue morning stars',\n 'Angels over Mexico',\n 'Angels in our hearts',\n '\\n',\n 'Rodeo riders',\n 'And feathers on wires',\n 'Things that hold on tight',\n 'Darling I feel that way tonight',\n '\\n',\n 'And I’m long past the language',\n 'Of saying nothing',\n 'And I find you unhidden in all my songs',\n 'I will meet you in the pull of the moon',\n 'On the midnight',\n 'When the gypsies face their wings',\n 'We’ll make every scarecrow sing',\n '\\n',\n 'Just remember the drift of the days',\n 'By the river',\n 'When we swore we’d be each other’s',\n 'Blue morning stars',\n 'I know that’s who we are'], false, false, 'Remember the drift of the days', callback);\n },\n function(callback) {\n poemCreate('OLE POPS\\' MAGIC JAR', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Ole Pops, he had a magic jar',\n 'He told me to never look in there',\n 'It was from somewhere way back in the Bible',\n 'Some little country with a lot of syllables',\n 'He kept it way up on a shelf',\n 'Buried in the years',\n 'Once I saw him close his eyes',\n 'And hold it to his ear',\n 'Like it was made of Jupiter',\n '\\n',\n 'Sometimes we’d hear him in his room',\n 'Alchemizing the moon',\n 'Instructions for something',\n 'We do not presume',\n 'Other times it sounded like',\n 'He was juggling clocks',\n 'Like he was making a mountain',\n 'Out of a music box',\n '\\n',\n 'The sides were painted pyramids',\n 'Irises and irids',\n 'A lion and a lynx',\n 'A river made of light',\n 'And a raven made of Sphinx',\n 'Missing symbols in a strand',\n 'Eight faces in a tree',\n 'Nine fingers on a hand',\n 'Extending eternity',\n 'So one night I dreamed it',\n 'Dreaming of me',\n 'Reaching up to touch the lid',\n 'I felt like human amethyst',\n '\\n',\n 'The day he died',\n 'I grew new eyes and made the climb',\n 'And opened it up as it did me',\n 'Then looking down into the black',\n 'I saw ole Pops and his seven sisters',\n 'Saintly waving back',\n '\\n',\n 'Old Pops, he had a magic jar',\n 'Sometimes he’d ease the top off',\n 'Releasing a new star . . . . .'], false, false, 'Ole Pops, he had a magic jar', callback);\n },\n function(callback) {\n poemCreate('THE GREENLAWN WATER TOWER', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Almost as rude as war',\n 'She stood there helicopter high',\n 'Like a bully blessed with radar',\n 'I remember shrinking under',\n 'Her metal daredevil belly',\n 'Staring up her ladder legs',\n 'With twenty twenty envy',\n 'And zero Mohawk blood',\n '\\n',\n 'Yea, the mystery of altitude',\n 'Thrusts tower’s shadows on cowards',\n 'But certain friends',\n 'Who brought brave sneakers',\n 'Immunized with Rhinegold',\n 'Came lugging buckets of Dutch Boy',\n 'And climbed the scares',\n 'Up to her dreamy mezzanine',\n 'To splash the class numerals',\n 'In God’s blue eyes',\n 'With all the privileges of Hillary',\n 'I can still hear their',\n 'Heroes’ echoes laughing in the sky',\n '\\n',\n 'And I recall my neck grew mad',\n 'Foster child of wonder',\n 'At the Greenlawn Water Tower',\n 'For maintaining a tall',\n 'Hold on her secrets',\n 'So, two nights later',\n 'I chucked a beer can at her',\n 'But it was like trying',\n 'To hit the government with',\n 'A snowball . . .'], false, false, 'Almost as rude as war', callback);\n },\n function(callback) {\n poemCreate('AT LOVE\\'S BRIGHT CAMPAIGN', 'Charles John Quarto', false, '1980', '1982', 'Poem', [\n 'Often have I marveled at love’s bright campaign',\n 'I’ve been staggered by its grandeur in the rain',\n 'I’ve counted all the pretty ribbons',\n 'Strewn down many country lanes',\n 'Reasoned out the milkman’s whistle',\n 'And the mailman’s promenade',\n 'And seen smiles that no science could explain',\n '\\n',\n 'Often have I marveled at love’s bright campaign',\n 'I’ve witnessed giants armed with flowers in parades',\n 'I’ve heard a hobo gain direction',\n 'Murmuring a woman’s name',\n 'Watched him wander out of trouble',\n 'Concentrating on the train',\n 'That would take him to some home so far away',\n '\\n',\n 'Often have I marveled at love’s bright campaign',\n 'I’ve swallowed hermit’s tears along with my champagne',\n 'I’ve toasted every soldier’s romance',\n 'Be it provident or plain',\n 'Lit a loving little candle',\n 'As if summary remains',\n 'I’ve found the heart to be much wiser than the brain'], false, false, 'Often have I marveled at love’s bright campaign', callback);\n },\n function(callback) {\n poemCreate('WHEN MY SISTER FELL OUT OF THE MAPLE TREE', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'When my sister fell out of the maple tree',\n 'She broke her arm and dignity',\n 'My mother screamed perhaps at God',\n 'As neighbors streamed into the yard',\n '\\n',\n 'Alan Probeck shook his head',\n 'Even Mrs. Smith got out of her pool',\n 'So we knew it was a big to do',\n 'Even Mr. Tilden',\n 'Stopped yelling at his children',\n 'For a minute or two',\n '\\n',\n 'When my sister fell out of the maple tree',\n 'My doggie wagged his tail at me',\n 'As if perhaps to celebrate',\n 'So I brought out twenty puppy cakes',\n '\\n',\n 'My mother drove her to the doctor',\n 'For further punishment',\n 'As Mrs. Smith returned to her tan',\n 'And Alan Probeck made his exit',\n '\\n',\n 'When my sister fell out of the maple tree',\n 'She didn’t make a sound',\n 'But she still stuck her tongue out at me',\n 'Before she hit the ground . . .'], false, false, 'When my sister fell out of the maple tree', callback);\n },\n function(callback) {\n poemCreate('LIGHT BRINGS FIRE', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Light brings fire',\n 'Fire light',\n 'Shelter cave',\n 'And shadow kite',\n '\\n',\n 'Light draws nearer',\n 'Day or night',\n 'Light brings fire',\n 'Fire light',\n '\\n',\n 'Sun my signal',\n 'Star my guide',\n 'Light brings fire',\n 'Deep inside',\n '\\n',\n 'Moon my mirror',\n 'Wind my comb',\n 'Light my bearer',\n 'Leads me home',\n '\\n',\n 'Light brings fire',\n 'Fire light',\n 'Darkness closeness',\n 'But to what',\n '\\n',\n 'Light draws clearer',\n 'Night or day',\n 'And it blesses blindly',\n 'What’s in the way',\n '\\n',\n 'Sees what’s real',\n 'Knows what’s right',\n 'Light brings fire',\n 'Fire light'], false, false, 'Light brings fire', callback);\n },\n function(callback) {\n poemCreate('THE GARDEN IN THE ROSE', 'Charles John Quarto', false, 'Present', '2013', 'Poem', [\n 'Now that you have heard the sea in a shell',\n 'Open your heart to the sky',\n 'Let the wind bring you everything',\n 'If not your world',\n 'Well then your wing',\n 'It is there you shall come to understand',\n 'What the child’s forever telling the man',\n 'It is here that you will remember',\n 'What every angel knows',\n 'Love looks for you through your own eyes',\n 'Whenever they open or close',\n 'Learn to see the garden in the rose'], false, false, 'Now that you have heard the sea in a shell', callback);\n },\n function(callback) {\n poemCreate('LOOK DEEP INTO THE EYES OF DOGS', 'Charles John Quarto', false, '1980', '1982', 'Poem', [\n 'Look deep into the eyes of dogs',\n 'They know the true master',\n 'Is contained within',\n 'So they put up with the leash',\n 'And give you permission to convince yourself',\n 'That you are right',\n 'To tell them when to eat',\n 'And where to sit',\n 'And at whose feet',\n '\\n',\n 'Look deep into the eyes of dogs',\n 'They are not ashamed to be perfect',\n 'Even in the cage of your address',\n 'They consider your statement',\n 'And energize their faith',\n 'Coming over to you',\n 'And always responding with grace',\n 'As if saying:',\n '“You know, I love you silly folks',\n 'But honestly',\n 'My eyes show more than my tail does',\n 'And as soon as you figure that out',\n 'I’ll teach you some other tricks” . . . .'], false, false, 'Look deep into the eyes of dogs', callback);\n },\n function(callback) {\n poemCreate('STRAWBERRIES', 'Charles John Quarto', false, '1980', '1982', 'Poem', [\n 'When Freddie Ditmar',\n 'And I got caught stealing strawberries',\n 'Redhanded from the Tilden farm',\n 'We had nearly filled our milk pails',\n 'When Old Man Tilden crossed the field',\n 'And drew a buckshot bead on us',\n 'With the family gun',\n 'Our hands went up like spring corn',\n 'As he asked what in the tarnation',\n 'We were doing, but he knew . . .',\n 'So he marched us to his farmhouse',\n 'Called a cop who made us promise',\n 'That we believed in God and Heaven',\n 'Which was true',\n 'Trouble was we believed in strawberries',\n 'Still do . . .'], false, false, 'When Freddie Ditmar', callback);\n },\n ],\n // optional callback\n cb);\n}", "title": "" }, { "docid": "aa2284c558ec5ff1fbbf136db6e4af2c", "score": "0.55233294", "text": "function PromiseQueue() {\n\n var _queueOfPromiseProducingFunctions = []\n var _currentlyExecutingPromise = undefined\n\n function _executeNextPromiseProducingFunction() {\n\n //assumption: _queueOfPromiseProducingFunctions.length > 0\n\n var promiseProducingFunctionToExecute = _queueOfPromiseProducingFunctions.splice(0,1)[0]\n _currentlyExecutingPromise = promiseProducingFunctionToExecute()\n _currentlyExecutingPromise\n .then(function () {\n if (_queueOfPromiseProducingFunctions.length) {\n _executeNextPromiseProducingFunction()\n }\n else {\n _currentlyExecutingPromise = undefined\n //then wait for the next call to enqueue()\n }\n })\n }\n\n this.enqueue = function (promiseProducingFunction) {\n if (!_currentlyExecutingPromise && !_queueOfPromiseProducingFunctions.length) { //may be redundant to also check for _queueOfPromiseProducingFunctions.length - also we'd be stuck if _queueOfPromiseProducingFunctions.length > 0 but _currentlyExecutingPromise === undefined\n _queueOfPromiseProducingFunctions.push(promiseProducingFunction)\n _executeNextPromiseProducingFunction()\n return\n }\n else {\n _queueOfPromiseProducingFunctions.push(promiseProducingFunction)\n return\n }\n\n }\n\n}", "title": "" }, { "docid": "e60a2f07afd0799fd4cc8b3de0c3eb8e", "score": "0.55200845", "text": "function flushPromises() {\n return new Promise(resolve => setImmediate(resolve))\n}", "title": "" }, { "docid": "e60a2f07afd0799fd4cc8b3de0c3eb8e", "score": "0.55200845", "text": "function flushPromises() {\n return new Promise(resolve => setImmediate(resolve))\n}", "title": "" }, { "docid": "db69917feadedf281fddfa856219e0e4", "score": "0.55186164", "text": "function scheduleFuturePromotions(validationRunOnly) {\n\n\tjson_file_reader.filelist()\n\t\t.then((files) => {\n\t\t\tlog(files);\n\n\t\t\tlog(\"files is array - %s\", Array.isArray(files));\n\n\t\t\tif (files.length === 0) {\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\tlet readPromises = [];\n\t\t\tlet readPromise;\n\n\t\t\tfor (var fileName of files) {\n\t\t\t\tlog(\"Reading file %s\", fileName);\n\n\t\t\t\treadPromise = json_file_reader.read(fileName);\n\t\t\t\treadPromises.push(readPromise);\t\n\t\t\t}\n\n\t\t\t// http://stackoverflow.com/questions/20100245/how-can-i-execute-array-of-promises-in-sequential-order\n\n\t\t\tPromise.all(readPromises)\n\t\t\t\t.then((results) => {\n\t\t\t\n\t\t\t\t\t// The reduce make sure we perform the operation in sequence\n\t\t\t\t\t// http://stackoverflow.com/questions/20100245/how-can-i-execute-array-of-promises-in-sequential-order\n\t\t\t\t\tresults.reduce(function(curr, next) {\n\t\t\t\t\t\treturn curr.then(function() {\n\n\t\t\t\t\t\t\tlet promotionScheduleObjectsArray;\n\t\t\t\t\t\t\tlet validationResult;\n\t\t\t\t\t\t\tlet startTime;\n\t\t\t\t\t\t\tlet endTime;\n\t\t\t\t\t\t\tlet promotionFamily;\n\n\t\t\t\t\t\t\tif (process.argv[2] !== undefined &&\n\t\t\t\t\t\t\t\tprocess.argv[2] !== (next.fileName + \".json\")) {\n\t\t\t\t\t\t\t\tlog(\"**** Skipping file %s due to argv[2] %s\", next.fileName, process.argv[2]);\n\t\t\t\t\t\t\t\treturn Promise.resolve(\"Skipping file \" + next.fileName + \" due to argv[2] \" + process.argv[2]);\n\t\t\t\t\t\t\t} \t\n\n\n\t\t\t\t\t\t\tlog(\"***fileName = %s , object = %s\", next.fileName,util.inspect(next.object, {showHidden: false, depth: null}));\n\t\t\t\t\t\t\tvalidationResult = validatePromotionSchedule( next.fileName, next.object);\n\n\t\t\t\t\t\t\tif(!validationResult) {\n\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , validation failed\", next.fileName);\n\t\t\t\t\t\t\t\treturn Promise.reject(\"*** fileName = \" + next.fileName + \" , validation failed \");\n\t\t\t\t\t\t\t}\n\n\n\t\t\t\t\t\t\tstartTime \t\t= validationResult.startDate;\t\t// start at 00:00 hh:mm\n\t\t\t\t\t\t\tendTime \t\t= validationResult.endDate;\n\t\t\t\t\t\t\tpromotionFamily = validationResult.promotionFamily;\n\n\t\t\t\t\t\t\t// For now we support only dine in and takoeut\n\t\t\t\t\t\t\tif (promotionFamily !== AppConstants.PROMOTION_FAMILY_DINE_IN && \n\t\t\t\t\t\t\t\tpromotionFamily !== AppConstants.PROMOTION_FAMILY_TAKE_OUT ) {\n\n\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , unsupported promotionFamily = %s\", next.fileName, promotionFamily);\n\t\t\t\t\t\t\t\treturn Promise.reject(\"*** fileName = \" + next.fileName + \" , unsupported promotionFamily = \" + promotionFamily);\n\n\t\t\t\t\t\t\t}\n\n\n\t\t\t\t\t\t\tstartTime = moment(startTime).hour(0).minute(0).second(0).toDate();\t\n\t\t\t\t\t\t\tendTime = moment(endTime).hour(23).minute(59).second(59).toDate();\n\n\t\t\t\t\t\t\tpromotionScheduleObjectsArray = validationResult.promotionScheduleObjectsArray;\n\n\n\t\t\t\t\t\t\tlog(\"*** fileName = %s , Object is valid - %s\", next.fileName, promotionScheduleObjectsArray !== null ? promotionScheduleObjectsArray.length : null );\n\n\t\t\t\t\t\t\tif (promotionScheduleObjectsArray === null || promotionScheduleObjectsArray.length === 0) {\n\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , has empty promotionScheduleObjectsArray = %s\", next.fileName, promotionScheduleObjectsArray);\n\t\t\t\t\t\t\t\treturn Promise.reject(\"*** fileName = \" + next.fileName + \" , has empty promotionScheduleObjectsArray = \" + promotionScheduleObjectsArray);\n\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\tlet restaurantName \t= promotionScheduleObjectsArray[0].restaurantName;\n\t\t\t\t\t\t\tlet restaurantObjectId \t= promotionScheduleObjectsArray[0].restaurantObjectId;\n\n\t\t\t\t\t\t\tlog (\"restaurantName = %s , restaurantObjectId= %s, startTime = %s , endTime = %s promotionFamily = %s\",\n\t\t\t\t\t\t\t\t restaurantName, restaurantObjectId, startTime, endTime, promotionFamily);\n\n\t\t\t\t\t\t\tlet restaurant = Restaurant.createWithoutData(restaurantObjectId);\t\n\n\t\t\t\t\t\t\treturn restaurant.fetch()\n\t\t\t\t\t\t\t\t.then((restaurantObj) => {\n\n\t\t\t\t\t\t\t\t\tif (restaurantObj === null || restaurantObj === undefined ) {\n\t\t\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , restaurantName - %s restaurantObjectId = %s Did not find restaurant object\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\trestaurantName, restaurantObjectId );\t\n\n\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" Did not find restaurant object in DB\");\n\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tif (restaurantObj.get(AppConstants.KParseRestaurantNameKey) !== restaurantName) {\n\t\t\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , restaurantName - %s restaurantObjectId = %s Did not match restaurant name %s %s\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\trestaurantName, restaurantObjectId,restaurantObj.get(AppConstants.KParseRestaurantNameKey), restaurantName );\t\n\n\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" Mismatch in restaurant name\");\n\t\t\t\t\t\t\t\t\t} \n\t\t\t\t\t\t\t\t\telse {\n\t\t\t\t\t\t\t\t\t\tlog(\"Restaurant name match\");\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\t// Check that the restaurant support the type of the promotion\n\t\t\t\t\t\t\t\t\tlet allowDineIn = restaurantObj.get(AppConstants.KParseRestaurantAllowDineInKey);\n\t\t\t\t\t\t\t\t\tlet allowTakeOut = restaurantObj.get(AppConstants.KParseRestaurantAllowTakeOutKey);\n\t\t\t\t\t\t\t\t\tlet allowDelivery = restaurantObj.get(AppConstants.KParseRestaurantAllowDeliveryKey);\n\n\t\t\t\t\t\t\t\t\t// For now we do not allow delivery\n\n\t\t\t\t\t\t\t\t\tif (allowDineIn === undefined){\n\t\t\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , restaurantName - %s restaurantObjectId = %s missing allowDineIn field!\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\trestaurantName, restaurantObjectId,restaurantObj.get(AppConstants.KParseRestaurantNameKey), restaurantName );\t\n\n\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" missing allowDineIn field\");\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tif (allowTakeOut === undefined){\n\t\t\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , restaurantName - %s restaurantObjectId = %s missing allowTakeOut field!\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\trestaurantName, restaurantObjectId,restaurantObj.get(AppConstants.KParseRestaurantNameKey), restaurantName );\t\n\n\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" missing allowTakeOut field\");\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tif (promotionFamily === AppConstants.PROMOTION_FAMILY_DINE_IN && !allowDineIn){\n\t\t\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , restaurantName - %s promotionFamily = %s restaurantObjectId = %s restaurant does not support dine-in!!!\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\trestaurantName, promotionFamily, restaurantObjectId,restaurantObj.get(AppConstants.KParseRestaurantNameKey), restaurantName );\t\n\n\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" restaurant does not support dine-in\");\n\t\t\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t\t\tif (promotionFamily === AppConstants.PROMOTION_FAMILY_TAKE_OUT && !allowTakeOut){\n\t\t\t\t\t\t\t\t\t\tlogError(\"*** fileName = %s , restaurantName - %s promotionFamily = %s restaurantObjectId = %s restaurant does not support take-out!!!\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\trestaurantName,promotionFamily , restaurantObjectId,restaurantObj.get(AppConstants.KParseRestaurantNameKey), restaurantName );\t\n\n\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" restaurant does not support takeout\");\n\t\t\t\t\t\t\t\t\t}\n\n\n\n\t\t\t\t\t\t\t\t\tlet promotionQuery = new Parse.Query(Promotion);\n\n\t\t\t\t\t\t\t\t\tpromotionQuery.equalTo(AppConstants.KParsePromotionRestaurantKey, restaurant);\t\n\t\t\t\t\t\t\t\t\tpromotionQuery.greaterThanOrEqualTo(AppConstants.KParsePromotionStartTimeKey, startTime);\n\t\t\t\t\t\t\t\t\tpromotionQuery.lessThanOrEqualTo(AppConstants.KParsePromotionEndTimeKey, endTime);\n\n\t\t\t\t\t\t\t\t\tpromotionQuery.notEqualTo(AppConstants.KParsePromotionCanceledKey, true);\n\n\t\t\t\t\t\t\t\t\t// We are looking only for conflict with promotion of the same promotion family\n\t\t\t\t\t\t\t\t\t// So we allow two promotion for the same restaurant at the same time as long one is dine in and the \n\t\t\t\t\t\t\t\t\tpromotionQuery.equalTo(AppConstants.KParsePromotionPromotionFamilyKey, promotionFamily);\n\n\n\t\t\t\t\t\t\t\t\treturn promotionQuery.find()\n\t\t\t\t\t\t\t\t\t\t.then((objects) => {\n\n\t\t\t\t\t\t\t\t\t\t\tlog(\"%s Got %s results for promotion query\", next.fileName, objects.length);\n\n\t\t\t\t\t\t\t\t\t\t\t for (var i = 0; i < objects.length; i++) {\n\t\t\t\t\t\t\t\t\t \t\t var object = objects[i];\n\t\t\t\t\t\t\t\t\t \t\tlog(\"Promotion id %s , restuarnt id %s and its attributes\", object.id, object.get(\"restaurant\").id, util.inspect( object.get(\"restaurant\").attributes) );\n\t\t\t\t\t\t\t\t\t \t}\n\n\t\t\t\t\t\t\t\t\t \tif (objects.length > 0) {\n\t\t\t\t\t\t\t\t\t \t\tlogError(\"*** fileName = %s , restaurantName - %s restaurantObjectId = %s There is allready other promotion for that time period %s\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\t\t\trestaurantName, restaurantObjectId, restaurantName );\t\n\n\t\t\t\t\t\t\t\t\t\t\t\t\treturn Promise.reject(\"fileName \" + next.fileName + \" There is allready other promotion for that time period\" +\n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\"promotionFamily = \" + promotionFamily);\n\t\t\t\t\t\t\t\t\t \t}\n\n\t\t\t\t\t\t\t\t\t \tif (validationRunOnly) {\n\t\t\t\t\t\t\t\t\t \t\tlog(\"VALIDATION_RUN is set so we do not actually schedule the promotions \");\n\t\t\t\t\t\t\t\t\t \t\treturn Promise.resolve(\"VALIDATION_RUN is set so we do not actually schedule the promotions\");\n\t\t\t\t\t\t\t\t\t \t}\n\n\t\t\t\t\t\t\t\t\t \t// Save promotion to backend\t\t\n\n\t\t\t\t\t\t\t\t\t \tlet newPromotions = [];\n\n\t\t\t\t\t\t\t\t\t \tfor (let promotionScheduleObject of promotionScheduleObjectsArray) {\n\n\t\t\t\t\t\t\t\t\t \t\tlet promotion = new Promotion();\n\t\t\t\t\t\t\t\t\t \t\tlet acl = new Parse.ACL();\n\t\t\t\t\t\t\t\t\t\t\t\tacl.setPublicReadAccess(true);\n\t\t\t\t\t\t\t\t\t\t\t\tacl.setPublicWriteAccess(true);\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.setACL(acl);\t\n\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionStartTimeKey \t\t , promotionScheduleObject.startTime);\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionEndTimeKey \t , promotionScheduleObject.endTime);\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionOriginalEndTimeKey , promotionScheduleObject.endTime);\n\t\t\t\t\t\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t // For takeout, delivery the max number of order is saved in the table for 2\n\t\t\t\t\t\t\t\t\t\t\t if (promotionFamily === AppConstants.PROMOTION_FAMILY_DINE_IN) {\n\t\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionTotalTables2Key, promotionScheduleObject.tableFor2 );\n\t\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionMaxPartySizeKey, 0 );\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t\t\t\t\telse if (promotionFamily === AppConstants.PROMOTION_FAMILY_TAKE_OUT){\n\t\t\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionTotalTables2Key, promotionScheduleObject.maxNumberOfOrders );\n\t\t\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionMaxPartySizeKey, promotionScheduleObject.maxPartySize );\n\t\t\t\t\t\t\t\t\t\t\t\t}\n\n\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionTotalTables4Key, promotionScheduleObject.tableFor4 );\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionTotalTables5Key, promotionScheduleObject.tableFor5 );\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionTotalTables6Key, promotionScheduleObject.tableFor6 );\n\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotiontMaxDiscountKey, promotionScheduleObject.discount);\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionAlcoholIncludedKey, promotionScheduleObject.alcohol);\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionMaxHoldTimeKey, promotionScheduleObject.duration);\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionLocationKey, restaurantObj.get(AppConstants.KParseRestaurantLocationKey));\n\t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionCanceledKey , false);\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionStoppedKey , false);\n\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionBlockTableSpilloverKey, false);\n\n\t\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionBlockSingleGuestKey, false); \n\t\t\t\t\t\t\t\t\t\t\t \t\t\t\t\t\t\t\t\t\t\t \n\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionRestaurantKey, restaurantObj);\n\t\t\t\t\t\t\t\t\t\t\t \t\t\n\t\t\t\t\t\t\t\t\t\t var tempArray = [\"\"];\n\t\t\t\t\t\t\t\t\t\t\t \t\t \n\t\t\t\t\t\t\t\t\t\t promotion.set(AppConstants.KParsePromotionSpecialNotesKey, tempArray);\n\n\t\t\t\t\t\t\t\t\t\t // Set the new fields for promotion family, type, maxPartySize\n\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionMaxPartySizeKey \t, promotionScheduleObject.maxPartySize);\n\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionTypeBitMaskKey \t, promotionScheduleObject.promotionTypeBitMask);\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t// Add the strings names\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionTypeNameArrayKey \t, \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tgetPromotionTypeNameArray(promotionScheduleObject.promotionTypeBitMask));\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionPromotionFamilyKey \t, promotionScheduleObject.promotionFamily);\n\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t// Add the strings names\n\t\t\t\t\t\t\t\t\t\t\t\tpromotion.set(AppConstants.KParsePromotionPromotionNameFamilyKey , \n\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\t\tgetPromotionFamilyName(promotionScheduleObject.promotionFamily));\n\n\n\t\t\t\t\t\t\t\t\t\t\t log(\"Promotion = %s\", util.inspect(promotion));\n\n\t\t\t\t\t\t\t\t\t\t\t newPromotions.push(promotion);\n\t\t\t\t\t\t\t\t\t \t}\n\n\t\t\t\t\t\t\t\t\t \tlog(\"*** fileName = %s , restaurantName - %s restaurantObjectId = %s generating %s promotions\", next.fileName, \n\t\t\t\t\t\t\t\t\t\t\t\t\trestaurantName, restaurantObjectId, newPromotions.length );\t\n\n\t\t\t\t\t\t\t\t\t \treturn Parse.Object.saveAll(newPromotions, { useMasterKey: true })\n\t\t\t\t\t\t\t\t\t \t\t.then((results) => {\n\t\t\t\t\t\t\t\t\t \t\t\tlog (\"results = %s\", results);\t\n\t\t\t\t\t\t\t\t\t \t\t})\n\t\t\t\t\t\t\t\t\t \t\t.catch((err) => {\n\t\t\t\t\t\t\t\t\t \t\t\tlogError(\"err = %s\", err);\n\t\t\t\t\t\t\t\t\t \t\t} );\t\n\n\t\t\t\t\t\t\t\t\t\t});\n\n\n\t\t\t\t\t\t\t\t\t});\n\n\n\t\t\t\t\t\t});\n\n\t\t\t\t\t}, Promise.resolve())\n\t\t\t\t\t.then(() => {\n\t\t\t\t\t\tlog(\"All Done \" );\n\t\t\t\t\t})\n\t\t\t\t\t.catch((err) => {\n\t\t\t\t\t\tlogError(\"Got error %s\", util.inspect(err, {showHidden: false, depth: null}));\t\n\t\t\t\t\t});\n\n\n\t\t\t\t})\n\t\t\t\t.catch((err) => {\n\t\t\t\t\tlogError(\"Got error readig file %s\", util.inspect(err, {showHidden: false, depth: null}));\t\n\t\t\t\t})\n\t\t\t;\n\n\t\t})\n\t\t.catch((err) => {\n\t\t\tlogError(\"Got error reading files in directory %s \", util.inspect(err, {showHidden: false, depth: null}));\n\t\t});\n}", "title": "" }, { "docid": "8adfaf456b042e9eee152b76aaac4fc2", "score": "0.55100757", "text": "function pool(promiseFactories, limit) {\n return new PouchPromise(function (resolve, reject) {\n var running = 0;\n var current = 0;\n var done = 0;\n var len = promiseFactories.length;\n var err;\n\n function runNext() {\n running++;\n promiseFactories[current++]().then(onSuccess, onError);\n }\n\n function doNext() {\n if (++done === len) {\n /* istanbul ignore if */\n if (err) {\n reject(err);\n } else {\n resolve();\n }\n } else {\n runNextBatch();\n }\n }\n\n function onSuccess() {\n running--;\n doNext();\n }\n\n /* istanbul ignore next */\n function onError(thisErr) {\n running--;\n err = err || thisErr;\n doNext();\n }\n\n function runNextBatch() {\n while (running < limit && current < len) {\n runNext();\n }\n }\n\n runNextBatch();\n });\n}", "title": "" }, { "docid": "43cb02fffa9678abbde30244d2eb03ab", "score": "0.5502646", "text": "function sx(e,t,n,l){return new(n||(n=Promise))((function(a,o){function r(e){try{s(l.next(e))}catch(t){o(t)}}function i(e){try{s(l.throw(e))}catch(t){o(t)}}function s(e){var t;e.done?a(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(r,i)}s((l=l.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "78946e4c16a85da9c68cc0000b3fd207", "score": "0.5494834", "text": "function seq(arr, callback, index) {\n // first call, without an index\n if (typeof index === 'undefined') {\n index = 0\n }\n\n arr[index](function() {\n index++\n if (index === arr.length) {\n callback()\n } else {\n seq(arr, callback, index)\n }\n })\n }", "title": "" }, { "docid": "560da0457e79c35a3e0e0ee97b241031", "score": "0.54902035", "text": "static batch_program(){\n\treturn new Promise(function(resolve, reject) {\n\tif (err) {reject(err);}\n con.query(\"SELECT * FROM users\", function (err, result, fields) {\n if (err) throw err;\n\t for (var i = 0; i < result.length; i++) {\n\t\t \n con.query(\"SELECT * FROM users WHERE users.id = \"+result[i].id, function (err, result) {\n if (err) {reject(err);}\n resolve(result);\n });\n }\n });\n\n\t})\n }", "title": "" }, { "docid": "42ca95f162bb662079d12403dde01f96", "score": "0.54829407", "text": "function g(e,t,l,r){return new(l||(l=Promise))((function(i,n){function o(e){try{s(r.next(e))}catch(e){n(e)}}function a(e){try{s(r.throw(e))}catch(e){n(e)}}function s(e){e.done?i(e.value):new l((function(t){t(e.value)})).then(o,a)}s((r=r.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "07480cb01d694255ece3e257a235ed0f", "score": "0.5478298", "text": "async function o$2(o,m,a,p){return a=l$1.from(a),m$2(o,\"execute\",a,m,p).then((t=>{const r=t.data.results||[],o=t.data.messages||[];return {results:r.map(f$1),messages:o.map((t=>a$3.fromJSON(t)))}}))}", "title": "" }, { "docid": "4b748f3fa4eda03f1e2e5673c14cfc19", "score": "0.54773015", "text": "function B(e,t,n,r){return new(n||(n=Promise))((function(o,i){function a(e){try{s(r.next(e))}catch(e){i(e)}}function c(e){try{s(r.throw(e))}catch(e){i(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(a,c)}s((r=r.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "c7088094d41f4a25203ab5990dc6dbf3", "score": "0.546978", "text": "async function task(){\n // if we call one promise without the await keyword vo baki sab ke sath parallel chahla gha\n // prmse(3,\"anita\") ye hata ke dekh samaj me aaye gha \n await prmse(3,\"aman\")\n await prmse(3,\"bablu\")\n await prmse(3,\"annu\")\n await prmse(3,\"renu\")\n await prmse(3,\"tona\")\n await prmse(3,\"banti\")\n \n}", "title": "" }, { "docid": "4627b1fd9d3d631b0708d35bf77c4f91", "score": "0.5465966", "text": "await(callback) {\n if (outstanding < 1)\n callback();\n else\n callbacks.push(callback);\n }", "title": "" }, { "docid": "f0bcd6ba95fe41945e8a1aa19cebaf82", "score": "0.5463315", "text": "function a(e,t,n,i){function r(e){return e instanceof n?e:new n((function(t){t(e)}))}return new(n||(n=Promise))((function(n,a){function o(e){try{l(i.next(e))}catch(t){a(t)}}function s(e){try{l(i[\"throw\"](e))}catch(t){a(t)}}function l(e){e.done?n(e.value):r(e.value).then(o,s)}l((i=i.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "ef78d2b532bf39c67fde0dec1940fcb0", "score": "0.5461724", "text": "function genPromise(i){\n return new Promise((resolve,reject)=>{\n setTimeout(()=> {\n console.log('seconds : ',new Date().getSeconds());\n console.log('executing : ',i);\n resolve(i+i);\n },i);\n })\n}", "title": "" }, { "docid": "78560eb18cf29ef79f70c8911df78d8e", "score": "0.54613125", "text": "settle() {\n if (this._notify) {\n this._notify(this);\n }\n\n let cb = function (defer, err) {\n if (err) {\n return defer.reject(err);\n }\n\n defer.resolve();\n }\n\n let promises = [];\n for (let doAwait of this._awaits) {\n let defer = when.defer();\n promises.push(defer.promise);\n doAwait(this.context, _.bind(cb, defer));\n }\n\n let self = this;\n return when.all(promises)\n .then(_ => {\n for (let fulfill of self._fulfills) {\n fulfill(self);\n }\n\n this._defer.resolve();\n\n return;\n })\n .catch(err => {\n for (let reject of self._rejects) {\n reject(self);\n }\n\n this._defer.reject(err);\n })\n .finally(_ => processNext());\n }", "title": "" }, { "docid": "20b062394c12f28bfc79f65b171b4aef", "score": "0.5460472", "text": "function mapAfterAllReturn(arr, mapper, returnValue) {\n const results = new Array(arr.length);\n let containsPromise = false;\n\n for (let i = 0, l = arr.length; i < l; ++i) {\n results[i] = mapper(arr[i]);\n\n if (isPromise(results[i])) {\n containsPromise = true;\n }\n }\n\n if (containsPromise) {\n return Promise.all(results).then(() => returnValue);\n } else {\n return returnValue;\n }\n}", "title": "" }, { "docid": "46556c0a400a4fd6bbc922c55587b129", "score": "0.54563403", "text": "function t(e,t,n,i){return new(n||(n=Promise))((function(r,s){function o(e){try{h(i.next(e))}catch(e){s(e)}}function a(e){try{h(i.throw(e))}catch(e){s(e)}}function h(e){e.done?r(e.value):new n((function(t){t(e.value)})).then(o,a)}h((i=i.apply(e,t||[])).next())}))}", "title": "" }, { "docid": "824aa7865e474e068fd1a3771eae310c", "score": "0.54484445", "text": "async function fn() {\n for (let i = 0; i < arr.length; i++) {\n let e = arr[i];\n let p = new Promise((resolve) => {\n setTimeout(resolve, e, e);\n });\n console.log(`as you see`);\n await p.then(console.log);\n }\n}", "title": "" }, { "docid": "7274441ffe41f39063d8813495c5defc", "score": "0.54476064", "text": "async function doAsync(inputArrayOrString) {\n try {\n if (!Array.isArray(inputArrayOrString)) throw 'Input should be an array'\n for (let element of inputArrayOrString) {\n if (Array.isArray(element)) {\n const promises = element.map(async (str) => { return await asyncOp(str) });\n await Promise.all(promises)\n } else {\n if (typeof (inputArrayOrString) != 'string') throw 'Input should only be array of strings'\n await asyncOp(element)\n }\n }\n\n } catch (err) {\n return err;\n }\n}", "title": "" }, { "docid": "7d4765ffb906f5726a626ee4c3f1b74d", "score": "0.54463303", "text": "function promiseLoop(func) {\n return new Promise(function(resolve, reject) {\n (function loop() {\n try {\n func(loop, resolve, reject);\n } catch (e) {\n reject(e);\n }\n }());\n });\n }", "title": "" }, { "docid": "1b37b98f04cb27eb3977a1480b5dff24", "score": "0.5433874", "text": "function giveMeEverything() {\n var promises = [];\n var callback;\n\n function thenHandler() {\n // console.log('in thenHandler::: ', arguments);\n callback(Array.prototype.slice.call(arguments));\n }\n\n function self() {\n var arg;\n for (var i = 0; i < arguments.length; i++) {\n arg = arguments[i];\n\n if (arg instanceof Function) {\n callback = arg;\n $.when.apply($, promises)\n .then(thenHandler, thenHandler);\n } else {\n promises.push(arg);\n }\n }\n return self;\n }\n\n self.apply(this, arguments);\n\n return self;\n }", "title": "" }, { "docid": "1a555d94eb92feb70dd12d6c220853ad", "score": "0.54335994", "text": "async function imprimirP6(array){\n for(let i of array){\n console.log(`imprimint ${i}`);\n let res = await new Promise((resolve)=>{\n setTimeout(()=>{\n resolve();\n },1000);\n }).then(()=>{\n p6.innerText += ` ${i}`;\n return i; \n });\n console.log(`imprimit ${res}`);\n }\n }", "title": "" }, { "docid": "f018a2b9b3846e4caf65b80681c7cb49", "score": "0.54319173", "text": "function do_n_at_a_time(arr, n, promiseFn) {\r\n function n_recursive(arr, n, acc, callbackFn) {\r\n if (arr.length === 0) {\r\n callbackFn(acc);\r\n } else {\r\n var max = (arr.length < n) ? arr.length : n;\r\n var promises = [];\r\n for (var i = 0; i < max; ++i) {\r\n var curObject = arr.shift();\r\n promises.push(promiseFn(curObject));\r\n }\r\n Promise.all(promises)\r\n .then(function (results) {\r\n for (var i = 0; i < results.length; ++i) {\r\n acc.push(results[i]);\r\n }\r\n n_recursive(arr, n, acc, callbackFn);\r\n });\r\n }\r\n }\r\n\r\n var new_arr = arr.slice();\r\n return new Promise(function (fulfill, reject) {\r\n n_recursive(new_arr, n, [], fulfill);\r\n });\r\n}", "title": "" }, { "docid": "c159bca8c92ff2db03dd4dd0003be0cf", "score": "0.54287803", "text": "function foo(bar, baz) {\n var x = bar * baz;\n// Zwrot obu obietnic.\n return [\n Promise.resolve(x),\n getY(x)\n ];\n}", "title": "" }, { "docid": "32558633115a4e61ef247e8f6a12e539", "score": "0.5424871", "text": "function loop() {\n // loop through async func calls\n var args = arguments;\n if (args.length <= 0) return;\n (function chain(i) {\n if (i >= args.length || typeof args[i] !== \"function\") return;\n window.setTimeout(function () {\n args[i]();\n chain(i + 1);\n }, 300);\n })(0);\n}", "title": "" } ]
be625efcf2a79f15d2709a4c5d9a1880
end on a partial character, we simply let v8 handle that.
[ { "docid": "81ca1d1ec254d67fbe7012ed1bfd8b70", "score": "0.0", "text": "function utf16End(buf){var r=buf&&buf.length?this.write(buf):'';if(this.lastNeed){var end=this.lastTotal-this.lastNeed;return r+this.lastChar.toString('utf16le',0,end);}return r;}", "title": "" } ]
[ { "docid": "59d738297034850e8dfcd166dd841d9d", "score": "0.6395447", "text": "eof() {\n if (this.#index >= this.#str.length) {\n return true; \n }\n }", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "a3b240167282781d191d8b39365c340b", "score": "0.6372055", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n\t return r;\n\t}", "title": "" }, { "docid": "4e4bf71853eb2baba36b9bc0f56aba21", "score": "0.636487", "text": "function utf8End(buf) {\r\n\t\t\t\tvar r = buf && buf.length ? this.write(buf) : \"\";\r\n\t\t\t\tif (this.lastNeed) return r + \"\\ufffd\";\r\n\t\t\t\treturn r;\r\n\t\t\t}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "e03d8befa319f85762e9703074ac8345", "score": "0.63621074", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd'.repeat(this.lastTotal - this.lastNeed);\n return r;\n}", "title": "" }, { "docid": "baa11a7f0f4583aa7f58e793014e9641", "score": "0.6350106", "text": "function utf8End(buf) {\r\n var r = buf && buf.length ? this.write(buf) : '';\r\n if (this.lastNeed) return r + '\\ufffd';\r\n return r;\r\n}", "title": "" }, { "docid": "26daa6e6474c448c0d29cc351ee4b74d", "score": "0.63495123", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : \"\";\n if (this.lastNeed) return r + \"\\ufffd\";\n return r;\n }", "title": "" }, { "docid": "26daa6e6474c448c0d29cc351ee4b74d", "score": "0.63495123", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : \"\";\n if (this.lastNeed) return r + \"\\ufffd\";\n return r;\n }", "title": "" }, { "docid": "612bc0cd0dd569317f2122ed050c1678", "score": "0.6348028", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd';\n\t return r;\n\t}", "title": "" }, { "docid": "612bc0cd0dd569317f2122ed050c1678", "score": "0.6348028", "text": "function utf8End(buf) {\n\t var r = buf && buf.length ? this.write(buf) : '';\n\t if (this.lastNeed) return r + '\\ufffd';\n\t return r;\n\t}", "title": "" }, { "docid": "8c0359b23ef4caf6b5b2ff44b0673fde", "score": "0.6334093", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n }", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" }, { "docid": "a33f779cad40bcf58802677f8297cad5", "score": "0.6311278", "text": "function utf8End(buf) {\n var r = buf && buf.length ? this.write(buf) : '';\n if (this.lastNeed) return r + '\\ufffd';\n return r;\n}", "title": "" } ]
9f0a87484ad56f7265a1722ff03c5c7a
if we find a formula, parse it to find the from (row and column) and the to (row and column) and then perform the calculation by getting all the numeric values from the 2d array and generating a total parse the formula with a call to getFormula ... finally take the calculated total and insert into the HTML table
[ { "docid": "9924c3fbf208f8a9d310836c93bb0aee", "score": "0.75810385", "text": "function calculateCell(row, column) {\r\n // begin by getting the formula parts\r\n var tokenArray = getFormula(tblArray[row][column]);\r\n\r\n // tokenArray[1] and tokenArray[2] contain the from and to references\r\n // need more validation if this was a production level app\r\n\r\n if (tokenArray !== null) {\r\n var fromColumn = tokenArray[1].substr(0, 1);\r\n var fromRow = tokenArray[1].substr(1, tokenArray[1].length - 1);\r\n\r\n var toColumn = tokenArray[2].substr(0, 1);\r\n var toRow = tokenArray[2].substr(1, tokenArray[2].length - 1);\r\n\r\n // assign the actual row/column index values for the tblArray\r\n var fromRowIndex = parseFloat(fromRow) - 1;\r\n var fromColIndex = fromColumn.charCodeAt(0) - 65;\r\n\r\n var toRowIndex = parseFloat(toRow) - 1;\r\n var toColIndex = toColumn.charCodeAt(0) - 65;\r\n\r\n var sumTotal = 0;\r\n\r\n for (var i = fromRowIndex; i <= toRowIndex; i++) {\r\n for (var j = fromColIndex; j <= toColIndex; j++) {\r\n // make sure we have a number for addition\r\n // Assume value 0 if there is no information on this cell\r\n if (!tblArray[i][j]) {\r\n tblArray[i][j] = \"0\";\r\n }\r\n if (tblArray[i][j].startsWith(\"=\")) {\r\n let cell = document.getElementById(Number(i + 1) + \"_\" + Number(j + 1));\r\n sumTotal += parseFloat(cell.textContent);\r\n }\r\n if (isFloat(tblArray[i][j])) {\r\n sumTotal += parseFloat(tblArray[i][j]);\r\n }\r\n }\r\n }\r\n\r\n // we now have the total... insert into spreadsheet cell\r\n // ... get the cell id\r\n var cellID = (row + 1) + \"_\" + (column + 1);\r\n var ref = document.getElementById(cellID)\r\n ref.innerHTML = sumTotal;\r\n }\r\n}", "title": "" } ]
[ { "docid": "7fa4708d0b963cb1044587c4ad54dadd", "score": "0.7036254", "text": "function recalculate() {\r\n for (var i = 0; i < tableRow; i++) {\r\n for (var j = 0; j < tableCol; j++) {\r\n // check to see if table element is a formula\r\n if (tblArray[i][j].indexOf(\"=SUM\") !== -1) {\r\n // apply the formula for cell at row/column i/j\r\n calculateCell(i, j);\r\n }\r\n }\r\n }\r\n}", "title": "" }, { "docid": "171b6d4f9ac2f116465a397782a032ee", "score": "0.6694466", "text": "function calculateFormula(formula, row, col) {\n\n var pat = formula.match(/\\b[a-z_]+\\b/g);\n var formu = formula;\n\n // Solución para IE\n for(var k in pat) {\n if(!/^\\d+$/.test(k)) {\n delete(pat[k]);\n }\n }\n \n for(var k in pat) {\n var exp = 'td:eq(' + cols[pat[k]].pos + ') ' + cols[pat[k]].type;\n var val = parseFloat( $(row).find(exp).val() ) || 0;\n var reg = new RegExp('\\\\b' + pat[k] + '\\\\b')\n formu = formu.replace(reg, val);\n }\n\n var res = eval(formu);\n // Posicionando la respuesta correspondiente\n var cell = $(row).find('td:eq(' + cols[col].pos + ')');\n if(cols[col].type == \"\") {\n $(cell).html(res);\n }else{\n $(cell).find(type).html(res);\n }\n }", "title": "" }, { "docid": "1199bb548dc3dab75dad7aa55fc74f0e", "score": "0.6623213", "text": "function calculate(e) {\n\n var target = e.target || e.srcElement;\n var row = $(target).parents('tr').eq(0);\n var col = $(target).parents('td').eq(0)[0].cellIndex;\n var i = 0;\n col = findColBy(col, 'pos').name;\n \n for(var k in cols) {\n reg = \"\\\\b\" + col + \"\\\\b\";\n var reg = new RegExp(reg);\n if(cols[k].formula && reg.test(cols[k].formula)) {\n calculateFormula(cols[k].formula, row, k);\n }\n }\n }", "title": "" }, { "docid": "f5715b1787213e0012cca94e849b5604", "score": "0.6310124", "text": "function matrixFirstValues() {\r\n var answerString = \"\";\r\n var table = document.getElementById('matrixFirst');\r\n for (var r = 0, n = table.rows.length; r < n; r++) {\r\n if (r >= 1) {\r\n\r\n var strLength = answerString.length;\r\n answerString = (answerString.slice(0, strLength - 1));\r\n answerString += \"\\\\\\\\\";\r\n }\r\n for (var c = 0; c < mFirstY; c++) {\r\n var rowId = r + 1;\r\n var colId = c + 1;\r\n var Cell = document.getElementById(\"a\" + rowId + colId).value;\r\n var str = Cell;\r\n var pos = str.indexOf(\"/\");\r\n var minuspos = Cell.indexOf(\"-\");\r\n if (Cell.charAt(minuspos) === \"-\" && Cell.charAt(pos) === \"/\") {\r\n var str2 = str.replace(\"-\", \"\");\r\n var start = str2.slice(0, pos - 1);\r\n start = \"\\\\frac {\" + start + \"}\";\r\n var end = Cell;\r\n var afterSlash = str.substr(str.indexOf(\"/\") + 1);\r\n end = \"{\" + afterSlash + \"}\";\r\n var fractionbracketstart = \"(-\";\r\n var fractionbracketend = \")\" + \"&\";\r\n var fractionbracket = fractionbracketstart + start + end + fractionbracketend;\r\n answerString += fractionbracket;\r\n } else if (Cell.charAt(pos) === \"/\") {\r\n var stringLength = Cell.length;\r\n var String1 = Cell;\r\n var start = str.slice(0, pos);\r\n start = \"\\\\frac {\" + start + \"}\";\r\n var end = Cell;\r\n var afterSlash = str.substr(str.indexOf(\"/\") + 1);\r\n end = \"{\" + afterSlash + \"}&\";\r\n Cell = start + end;\r\n answerString += Cell;\r\n } else if (Cell.charAt(0) === \"-\") {\r\n Cell = \"(\" + Cell + \")\" + \"&\";\r\n answerString += Cell;\r\n } else {\r\n var Cell = document.getElementById(\"a\" + rowId + colId).value + \"&\";\r\n answerString += Cell;\r\n }\r\n\r\n\r\n\r\n\r\n }\r\n }\r\n var strLength = answerString.length;\r\n answerString = (answerString.slice(0, strLength - 1));\r\n return answerString;\r\n}", "title": "" }, { "docid": "e51246fb2f2c01edf27496dbd68597ca", "score": "0.6242793", "text": "function matrixSecondValues() {\r\n var answerString = \"\";\r\n var table = document.getElementById('matrixSecond');\r\n for (var r = 0, n = table.rows.length; r < n; r++) {\r\n if (r >= 1) {\r\n var strLength = answerString.length;\r\n answerString = (answerString.slice(0, strLength - 1));\r\n answerString += \"\\\\\\\\\";\r\n };\r\n\r\n for (var c = 0; c < mSecondY; c++) {\r\n var rowId = r + 1;\r\n var colId = c + 1;\r\n var Cell = document.getElementById(\"b\" + rowId + colId).value;\r\n var str = Cell;\r\n var pos = str.indexOf(\"/\");\r\n var minuspos = str.indexOf(\"-\");\r\n if (Cell.charAt(minuspos) === \"-\" && Cell.charAt(pos) === \"/\") {\r\n var str2 = str.replace(\"-\", \"\");\r\n var start = str2.slice(0, pos - 1);\r\n start = \"\\\\frac {\" + start + \"}\";\r\n var end = Cell;\r\n var afterSlash = str.substr(str.indexOf(\"/\") + 1);\r\n end = \"{\" + afterSlash + \"}\";\r\n var fractionbracketstart = \"(-\";\r\n var fractionbracketend = \")\" + \"&\";\r\n var fractionbracket = fractionbracketstart + start + end + fractionbracketend;\r\n answerString += fractionbracket;\r\n } else if (Cell.charAt(pos) === \"/\") {\r\n var stringLength = Cell.length;\r\n var String1 = Cell;\r\n var start = str.slice(0, pos);\r\n start = \"\\\\frac {\" + start + \"}\";\r\n var end = Cell;\r\n var afterSlash = str.substr(str.indexOf(\"/\") + 1);\r\n end = \"{\" + afterSlash + \"}&\";\r\n Cell = start + end;\r\n minuspos = Cell.indexOf(\"-\");\r\n answerString += Cell;\r\n } else if (Cell.charAt(0) === \"-\") {\r\n Cell = \"(\" + Cell + \")\" + \"&\";\r\n answerString += Cell;\r\n } else {\r\n var Cell = document.getElementById(\"b\" + rowId + colId).value + \"&\";\r\n answerString += Cell;\r\n }\r\n\r\n\r\n\r\n\r\n }\r\n }\r\n var strLength = answerString.length;\r\n answerString = (answerString.slice(0, strLength - 1));\r\n return answerString;\r\n}", "title": "" }, { "docid": "3e7f4061812471af5e5727ed4a2adf19", "score": "0.5880101", "text": "function Xsumming () {\n//alertx(\"summing : tableTitle.length = \" + tableTitle.length + \" totalFieldNameIndex = \" + totalFieldNameIndex);\n\n\tfor (i =0;i <tableTitle.length;i++) {\n\t\n\tif ( isNaN( Number(tableArray[i][totalFieldNameIndex]) )) {\n \n// if ( isNaN( Number(tableArray[i][totalFieldNameIndex])) || Number(tableArray[i][totalFieldNameIndex]) === 0) {\n\t\n //Number(tableArray[i][totalFieldNameIndex] if = Edit will be made a number = 0 which is NaN so condition not met. Therefore added || Number(tableArray[i][totalFieldNameIndex]) === 0 to cover EDIT entries\n\t\n\t\n\t\t//i++;\n\t\talert(\"is this the alert?Addition column in record \" + (i+1) + \" contains a non number!\");\n\t\ti++;\n\t\t//break;\n\t\t}//end if ( isNaN( Number(tableArray[i][totalFieldNameIndex])) || Number(tableArray[i][totalFieldNameIndex]) === 0) {\n\t\t\n\tfieldSUM = fieldSUM + Number(tableArray[i][totalFieldNameIndex]);\n\t\n\t//alertx(\"i = \" +i + \" fieldSUM = \" + fieldSUM);\n\t//totalFieldNameIndex replaced with k\n//if (fieldSUM === NaN) {\n//alert(\"The array contains a non number so unable to complete sum!\");\t\n//}\n//alert(\"fieldSUM = \" + fieldSUM);\n//alert(\"typeof fieldSUM = \" + typeof(fieldSUM));\n//fieldNamesArray[totalFieldNameIndex].textContent = \" TOTAL = \" + fieldSUM;\n// fieldNamesArray[totalFieldNameIndex].textContent = \" TOTAL = \";\n\t}//end for loop\n\ttotalFieldNameListener = false;\n\tresetFields = true;//flag used in displayTable to keep fields being messed up\n\treturn fieldSUM;\n\t//alert(\"fieldNamesArray[totalFieldNameIndex].textContent = \" + fieldNamesArray[totalFieldNameIndex].textContent);\n}//end function Xsumming", "title": "" }, { "docid": "4b0a55920a025cd77d00c65d83670d69", "score": "0.5871423", "text": "function sum_cells(e1, e2) {\n let minC = e1.getAttribute(\"columnId\").charCodeAt(0) - 65;\n let minR = parseInt(e1.getAttribute(\"rowId\")) - 1;\n let maxC = e2.getAttribute(\"columnId\").charCodeAt(0) - 65;\n let maxR = parseInt(e2.getAttribute(\"rowId\")) - 1;\n // Get the sum;\n let sum = 0;\n for (let i = minC; i <= maxC; i++) {\n for (let j = minR; j <= maxR; j++) {\n sum += (table_arr[i][j].innerText === \"\" ? 0 : parseInt(table_arr[i][j].innerText));\n }\n }\n return sum;\n}", "title": "" }, { "docid": "da66d965798da9ef3d6fa6397f6ed776", "score": "0.5833563", "text": "function justAddNumbers () {\n\tfor (i =0;i <tableTitle.length;i++) {\n\t\n\tif ( isNaN( Number(tableArray[i][totalFieldNameIndex]) )) {\n \n// if ( isNaN( Number(tableArray[i][totalFieldNameIndex])) || Number(tableArray[i][totalFieldNameIndex]) === 0) {\n\t\n //Number(tableArray[i][totalFieldNameIndex] if = Edit will be made a number = 0 which is NaN so condition not met. Therefore added || Number(tableArray[i][totalFieldNameIndex]) === 0 to cover EDIT entries\n\t\n\t\n\t\t//i++;\n\t\tif(calculationAlerts) {\n\t\talert(\"Addition column in record \" + (i+1) + \" contains a non number!\");\n\t\t}//end if(calculationAlerts) \n\t\t\n\t\ti++;\n\t\t//break;\n\t\t}//end if ( isNaN( Number(tableArray[i][totalFieldNameIndex])) || Number(tableArray[i][totalFieldNameIndex]) === 0) {\n\tif(isNaN(Number(tableArray[i][totalFieldNameIndex])) ) {\n\t\tcontinue;\n\t}\n\t\t\n\tfieldSUM = fieldSUM + Number(tableArray[i][totalFieldNameIndex]);\n\t\n\t//alertxy(\"i = \" + i + \" fieldSUM = \" + fieldSUM);\n\t\n}//end for loop\t\n\t//alertx(\"i = \" +i + \" fieldSUM = \" + fieldSUM);\n\t//totalFieldNameIndex replaced with k\n//if (fieldSUM === NaN) {\n//alert(\"The array contains a non number so unable to complete sum!\");\t\n//}\n//alert(\"fieldSUM = \" + fieldSUM);\n//alert(\"typeof fieldSUM = \" + typeof(fieldSUM));\n//fieldNamesArray[totalFieldNameIndex].textContent = \" TOTAL = \" + fieldSUM;\n// fieldNamesArray[totalFieldNameIndex].textContent = \" TOTAL = \";\n//alertxy(\"rowSummed false or rowSummed true but not last field : fieldSUM = \" + fieldSUM);\n\n}//end function just add numbers", "title": "" }, { "docid": "e17da55280ab8ec1483aaf84fc0fe4fa", "score": "0.5814509", "text": "function evaluateFormula(formula) {\n //convert ( A1 + A2 ) -> ( 10 + 20 )\n // split with space\n\n let formulaTokens = formula.split(\" \");\n for(let i=0; i<formulaTokens.length; i++) {\n let ascii = formulaTokens[i].charCodeAt(0);\n if(ascii >= 65 && ascii<=90) {\n let {rowId, colId} = getRowAndColId(formulaTokens[i]);\n let value = sheetDB[rowId][colId].value;\n formulaTokens[i] = value;\n }\n }\n formulaTokens = formulaTokens.join(\" \");\n\n return eval(formulaTokens);\n}", "title": "" }, { "docid": "3e53482b2a6303c1f4e98d17cb79c7be", "score": "0.5689292", "text": "function MatrixCal(tempR) {\n var positionTable = {\n \"11\": {\n \"x\": 550,\n \"y\": 240\n },\n \"12\": {\n \"x\": 100,\n \"y\": 105\n },\n \"13\": {\n \"x\": 50,\n \"y\": 290\n },\n \"14\": {\n \"x\": 160,\n \"y\": 240\n }, // (260, 240) ,(450, 240)\n \"15\": {\n \"x\": 310,\n \"y\": 90\n },\n \"16\": {\n \"x\": 310,\n \"y\": 323\n },\n \"17\": {\n \"x\": 496,\n \"y\": 419\n },\n \"18\": {\n \"x\": 550,\n \"y\": 419\n },\n \"21\": {\n \"x\": 774,\n \"y\": 332\n },\n \"22\": {\n \"x\": 650,\n \"y\": 230\n },\n \"23\": {\n \"x\": 1041,\n \"y\": 60\n },\n \"24\": {\n \"x\": 731,\n \"y\": 240\n }, //(834, 240) , (1020, 240)\n \"25\": {\n \"x\": 685,\n \"y\": 325\n },\n \"26\": {\n \"x\": 950,\n \"y\": 340\n },\n \"27\": {\n \"x\": 970,\n \"y\": 150\n },\n \"31\": {\n \"x\": 775,\n \"y\": 770\n },\n \"32\": {\n \"x\": 960,\n \"y\": 680\n },\n \"33\": {\n \"x\": 656,\n \"y\": 710\n },\n \"34\": {\n \"x\": 730,\n \"y\": 690\n }, //(830, 690)\n \"35\": {\n \"x\": 1060,\n \"y\": 690\n },\n \"36\": {\n \"x\": 660,\n \"y\": 518\n },\n };\n var result = [];\n for (var i = 0; i < tempR.length; i++) {\n var zone = parseInt(tempR[i].zone);\n if ((typeof tempR[i].floor === 'number') && (!isNaN(zone))) {\n result.push(positionTable[(zone + tempR[i].floor * 10).toString()]);\n } else if ((typeof tempR[i].floor === 'number') && (isNaN(zone))) {\n\n }\n }\n return result;\n }", "title": "" }, { "docid": "48351959927f819f437586e13baa44bc", "score": "0.5675593", "text": "function evaluateFormula(formula){\n let formulaTokens = formula.split(\" \");\n for (let i = 0; i < formulaTokens.length; i++) {\n let ascii = formulaTokens[i].charCodeAt(0);\n if (ascii >= 65 && ascii <= 90) {\n let { rid, cid } = getRIDCIDfromAddress(formulaTokens[i]);\n let value = sheetDB[rid][cid].value;\n if (value == \"\") {\n value = 0;\n }\n formulaTokens[i] = value;\n }\n }\n // [(,10,+,20,)]\n let evaluatedFormula = formulaTokens.join(\" \");\n // ( 10 + 20 ) \n // stack \n return infixEvaluation(evaluatedFormula);\n}", "title": "" }, { "docid": "a777baa38d0489d692f672cf273551f0", "score": "0.5637283", "text": "function get_monthly_total() {\n //erase previous data in the table and make the first row with the legend\n var table = document.getElementById(\"output_table\");\n reset_table(table);\n\n //get all the data elemtents from the different files\n var cases = casesXML.getElementsByTagName('data');\n var testing = testingXML.getElementsByTagName('data');\n var hospital = hospitalXML.getElementsByTagName('data');\n\n // //add code here to handle the extra data from the casesXML file\n\n for (month=1; month<=12; month++) {\n var row = table.insertRow(-1);\n var date_col = row.insertCell(0);\n var cases_col = row.insertCell(1);\n var tests_done_col = row.insertCell(2);\n var tests_planned_col = row.insertCell(3);\n var patients_in_hospital_col = row.insertCell(4);\n\n var cases_total = 0;\n var tests_done_total = 0;\n var tests_planned_total = 0;\n var hospital_cases_total = 0;\n\n table = document.getElementById(\"output_table\");\n tr = table.getElementsByTagName('tr');\n\n for (i=0; i+3 < cases.length; i++) {\n if ((cases[i+3].getElementsByTagName('date').item(0).innerHTML.split(\"-\")[1] == month)) {\n cases_total += parseInt(cases[i+3].getElementsByTagName('newCasesByPublishDate').item(0).innerHTML);\n if (testing[i] != undefined && !isNaN(parseInt(testing[i].getElementsByTagName('newPCRTestsByPublishDate').item(0).innerHTML))) {\n tests_done_total += parseInt(testing[i].getElementsByTagName('newPCRTestsByPublishDate').item(0).innerHTML);\n }\n tests_planned_total += (testing[i] != undefined ? parseInt(testing[i].getElementsByTagName('plannedPCRCapacityByPublishDate').item(0).innerHTML) : 0);\n hospital_cases_total += (hospital[i] != undefined ? parseInt(hospital[i].getElementsByTagName('hospitalCases').item(0).innerHTML) : 0);\n }\n\n }\n var months = ['January', 'February', 'March', 'April', 'May', 'June', 'July', 'August', 'September', 'October', 'November', 'December'];\n date_col.innerHTML = months[month-1] + \" 2020\";\n cases_col.innerHTML = cases_total;\n tests_done_col.innerHTML = tests_done_total;\n tests_planned_col.innerHTML = tests_planned_total;\n patients_in_hospital_col.innerHTML = hospital_cases_total;\n }\n }", "title": "" }, { "docid": "dfb868d27b80bd89b872a3f263040515", "score": "0.5631501", "text": "function table_initial(variables,contraintes)\n{\n var i = 0;\n var t;\n var k;\n var j;\n var array = Array();\n while (i < contraintes)\n {\n array[i]=Array();\n j = 0;\n while(j < variables)\n {\n var a = document.getElementById('x'.concat((i+1).toString(),(j+1).toString()));\n array[i][j] = eval(a.value);\n j++;\n }\n t = 1;\n while(t <= contraintes)\n {\n var a = document.getElementById('contraint'.concat(t.toString()));\n if(t == i + 1)\n {\n if(a.value == '<=')\n {\n array[i][j] = 1;\n j++;\n }\n else if(a.value == '>=')\n {\n array[i][j] = -1;\n j++;\n }\n }\n else\n {\n if(a.value != '=')\n {\n array[i][j] = 0;\n j++;\n }\n }\n t++;\n }\n k = 1;\n while(k <= contraintes)\n {\n var a = document.getElementById('contraint'.concat(k.toString()));\n if(k == i + 1)\n {\n if(a.value != '<=')\n {\n array[i][j] = 1;\n j++;\n }\n }\n else\n {\n if(a.value != '<=')\n {\n array[i][j] = 0;\n j++;\n }\n }\n k++;\n }\n array[i][j] = eval(document.getElementById('b'.concat((i+1).toString())).value);\n i++;\n }\n return array;\n}", "title": "" }, { "docid": "dfa1c002f5a6981b29754f6a70625f9e", "score": "0.55582714", "text": "function buildTable(){\n\n //Test to see if this function is reached.\n console.log(\"Reached buildTable\");\n submit();\n\n //document.getElementById(\"xLengthError\").innerHTML = \"\";\n //document.getElementById(\"yLengthError\").innerHTML = \"\";\n /*\n * Create 4 variables taken from the forum.\n * */\n var yLength = parseInt($('input[name=r]').val()),\n xLength = parseInt($('input[name=c]').val()),\n xStart = parseInt($('input[name=ry]').val()),\n yStart = parseInt($('input[name=rx]').val());\n\n\n\n /*\n * Use dx and dy to hold values passed in and be able to change them without\n * affecting the original values so these can be reset when needed.\n *\n * firstPassX - is used to test if it is in the top x row and print the values that were specified by user.\n *\n * firstPassY - is used to test for the first cell in the table and if true make it blank.\n *\n * secondPassY - is used to test for second row of the table because dy should not\n * get incremented before that or the table will be off by 1.\n *\n *\n * */\n var dx = xStart;\n var dy = yStart;\n var firstPassX = true;\n var firstPassY = true;\n var secondPassY = true;\n\n\n if(typeof yLength === 'number' && yLength > 0 && typeof xLength === 'number' && xLength > 0){\n var table = '<table>';\n table += '<tbody>';\n for(var i = 0; i <= yLength; i++){\n var y1col = true;\n dx = xStart;\n table += '<tr>';\n for(var j = 0; j <= xLength; j++){\n\n /*Test for first cell in table if true leave blank.*/\n if( firstPassY == true ){\n table += '<td class=\"emptyCell\">'+\" \"+'</td>';\n firstPassY = false;\n }\n /*Test for first row to populate given values.*/\n else if( firstPassX == true){\n table += '<td class=\"topRow\">'+dx+'</td>';\n dx++;\n }\n /*Fill in all other table values.*/\n else{\n /*Test for the first column to populate given values.*/\n if( y1col == true){\n table += '<td>'+dy+'</td>';\n y1col = false;\n }\n /*Needed this to fix my off by 1. Was production a extra column after the first row.*/\n if( j != xLength ){\n table += '<td>'+dx*dy+'</td>';\n }\n dx++;\n }\n\n\n }\n firstPassX = false;\n table += '</tr>';\n\n /*Needed this to only increment the y after the first row because it was left blank in first row.*/\n if( secondPassY == false ){\n dy++;\n }\n /*After first row make false to start incrementing y.*/\n secondPassY = false;\n }\n table += '</tbody>';\n table += '</table>';\n\n\n\n\n\n //$('#table').html(table);\n addTab($(\"#tabs\"), \"tab-\" + tabCounter, \"Tab \" + tabCounter, table);\n\n }\n}", "title": "" }, { "docid": "7125bd80969381d5237900d5331ed633", "score": "0.55387497", "text": "function addTablewithFormula() {\n var data = [['numbers', 'formulas'], [1, '=1'], [2, '=2'], [3, '=3']];\n\n data.headers = [['numbers', 'formulas']];\n data.rows = [\n [1, '=1'],\n [2, '=2'],\n [3, '=3'],\n ];\n var data1 = new Office.TableData();\n\n data1.headers = [['numbers', 'formulas']];\n data1.rows = [\n [1, '=[@numbers]'],\n [2, '=[@numbers]'],\n [3, '=[@numbers]'],\n ];\n\n var opts = { coercionType: Office.CoercionType.Matrix };\n var callback = function (res) {\n if (res.status === Office.AsyncResultStatus.Failed)\n return console.log(\"Err: setting data: \" + res.error.message);\n };\n var callback1 = function (res) {\n if (res.status === Office.AsyncResultStatus.Failed)\n return console.log(\"Err: setting data: \" + res.error.message);\n };\n Office.context.document.setSelectedDataAsync([['numbers', 'formulas'], [1, '=1'], [1, '=2'], [1, '=3']], { coercionType: \"matrix\" },\n function (asyncResult) {\n var error = asyncResult.error;\n if (asyncResult.status === \"failed\"){\n write(error.name + \": \" + error.message);\n }\n });\n\n}", "title": "" }, { "docid": "d3f13a297b5397d615b0c9d693f737e4", "score": "0.5520089", "text": "function CalcularTotal(){\n var suma=0;\n \n value=$(\"#excelcapital td#1-6\")[0].innerText.replace(/[^0-9.]/g, \"\");\n suma+=parseFloat((value!=\"\"?value:0));\n \n for(i=9;i<=13;i++){\n value=$(\"#excelcapital td#1-\" + i)[0].innerText.replace(/[^0-9.]/g, \"\");\n suma+=parseFloat((value!=\"\"?value:0));\n }\n \n for(i=16;i<=23;i++){\n value=$(\"#excelcapital td#1-\" + i)[0].innerText.replace(/[^0-9.]/g, \"\");\n suma+=parseFloat((value!=\"\"?value:0));\n }\n \n $('#excelcapital td#3-6').removeClass(\"readonly\");\n $('#excelcapital').jexcel('setValue', 'D7', suma);\n \n for(i=9;i<=13;i++){\n $('#excelcapital td#3-' + i).removeClass(\"readonly\");\n $('#excelcapital').jexcel('setValue', 'D'+(i+1), suma);\n \n /*$('#excelactivos td#2-' + i).removeClass(\"readonly\");\n $('#excelactivos').jexcel('setValue', 'C'+(i+1), \"=IF(OR(B\"+(i+1)+\"<=0,D\"+(i+1)+\"<=0),0,B\"+(i+1)+\"/D\"+(i+1)+\"*100)\");*/\n } \n for(i=16;i<=23;i++){\n $('#excelcapital td#3-' + i).removeClass(\"readonly\");\n $('#excelcapital').jexcel('setValue', 'D'+(i+1), suma);\n }\n \n \n $(\"#total\").val(' $ ' + numeral(suma).format('0,0.00'));\n \n}", "title": "" }, { "docid": "a59c6d63ac4368b479a2526f3a76e79a", "score": "0.55116886", "text": "function calcTotal(){\n\n //Variable to hold total of all expense rows\n var totalExp = 0;\n\n //Adds values from row to totalExp\n for (j = 1; j <= 4; j++){\n totalExp += calcRow(j);\n }\n\n return totalExp;\n}", "title": "" }, { "docid": "f7926a4203ab4cecdc943a9c7ae70f0c", "score": "0.5500453", "text": "function evaluateFormula(formula) {\n let formulaTokens = formula.split(' ');\n for (let i = 0; i < formulaTokens.length; i++) {\n let ascii = formulaTokens[i].charCodeAt(0);\n if (ascii >= 65 && ascii <= 90) {\n let { rid, cid } = getRIDCIDfromAddress(formulaTokens[i]);\n let value = sheetDB[rid][cid].value;\n if (value == '') {\n value = 0;\n }\n formulaTokens[i] = value;\n }\n }\n // [(,10,+,20,)]\n let evaluatedFormula = formulaTokens.join(' ');\n // ( 10 + 20 )\n // stack\n return infixEvaluation(evaluatedFormula);\n}", "title": "" }, { "docid": "68e22f524a43de9c2cfc6dbd2154e262", "score": "0.55000824", "text": "function setFormula(cell) {\n \n formulaSet = true;\n var formula = $(cell).attr('formula');\n var col = $(cell).attr('col');\n if(formula) {\n cols[col]['formula'] = formula;\n \n // Regitrar elementos que causan que se ejecute el calculo (Adición de eventos)\n for(var k in cols) {\n reg = \"\\\\b\" + k + \"\\\\b\";\n var reg = new RegExp(reg);\n \n if( reg.test(formula))\n setEvent(k);\n }\n }\n }", "title": "" }, { "docid": "c1966b8db1471f802346e3f0f134f066", "score": "0.5495549", "text": "function makeOutTable()\n{\n //\n // Price vs MPG output table\n //\n var cols = document.getElementById(\"prices\").value;\n var rows = document.getElementById(\"mgps\").value;\n var dbg = '';\n\n dbg = 'Rows=' + rows + ' Cols=' + cols + \"\\n\";\n document.getElementById('debug').value += dbg; \n\n var tableArray = new Array(rows+1);\n\n // Get the table\n var table = document.getElementById(\"outTable\");\n\n removeOutTable();\n\n tableArray[0] = table.insertRow(0);\n var tblNameCell = tableArray[0].insertCell(0);\n tblNameCell.innerHTML = \"Price/Fuel Comsumption\";\n\n for (var i = 1; i <= cols; i++)\n {\n var price = parseFloat(document.getElementById('pTable_' + i).value);\n var cell = tableArray[0].insertCell(i);\n cell.innerHTML = \"Price \" + i + \" ($\" + price.toFixed(0) + \")\";\n }\n\n var months = document.getElementById('years').value * 12;\n var interest = parseFloat(document.getElementById('interest').value);\n interest = interest / 100 / 12;\n var mlYears = document.getElementById('mlYear').value;\n var prGal = document.getElementById('prGal').value;\n\n var lowest = new Array(3); // [0] - cost [1] - row/i [2] - cols/j\n var highest = new Array(3); // [0] - cost [1] - row/i [2] - cols/j\n\n lowest[0] = 1000000;\n lowest[1] = 1;\n lowest[2] = 1;\n highest[0] = 0;\n highest[1] = 1;\n highest[2] = 1;\n\n\n for (var i = 1; i <= rows; i++)\n {\n tableArray[i] = table.insertRow(i);\n var hCell = tableArray[i].insertCell(0);\n var mpg = parseFloat(document.getElementById('mTable_' + i).value);\n hCell.innerHTML = \"MPG \" + i + \" (\" + mpg.toFixed(2) + \")\";\n for (var j = 1; j <= cols; j++)\n {\n // Calculate Cost per month\n var price = parseFloat(document.getElementById('pTable_' + j).value);\n\n // compute the monthly payment figure\n var x = Math.pow(1 + interest, months); //Math.pow computes powers\n var monthly = (price*x*interest)/(x-1);\n\n var cell = tableArray[i].insertCell(j);\n var pmo = document.createElement('output');\n pmo.type = 'text';\n pmo.name = 'pmo_' + i + '_' + j;\n pmo.id = 'pmo_' + i + '_' + j;\n pmo.size = 20;\n pmo.maxlength = 20;\n pmo.value = '$' + monthly.toFixed(2) + ' /mo';\n cell.appendChild(pmo);\n cell.appendChild(document.createElement('BR'));\n\n // Calculate Cost per Mile\n var pml = document.createElement('output');\n pml.type = 'text';\n pml.name = 'pml_' + i + '_' + j;\n pml.id = 'pml_' + i + '_' + j;\n pml.size = 20;\n pml.maxlength = 20;\n pml.value = '$' + (prGal/mpg).toFixed(2) + ' /ml';\n cell.appendChild(pml);\n cell.appendChild(document.createElement('BR'));\n\n // Calculate Total Cost per Month\n var tot = document.createElement('output');\n tot.type = 'text';\n tot.name = 'tab_' + i + '_' + j;\n tot.id = 'tab_' + i + '_' + j;\n tot.size = 20;\n tot.maxlength = 20;\n var cost = (monthly + (prGal/mpg) * (mlYears/12));\n tot.value = '$' + cost.toFixed(2);\n cell.appendChild(tot);\n\n if (highest[0] < cost)\n {\n highest[0] = cost;\n if (document.getElementById('tab_' + highest[1] + '_' + highest[2]).style.color == \"red\")\n {\n document.getElementById('tab_' + highest[1] + '_' + highest[2]).style.color = \"white\";\n }\n highest[1] = i;\n highest[2] = j\n tot.style.color = \"red\";\n }\n if (lowest[0] >= cost)\n {\n lowest[0] = cost;\n if (document.getElementById('tab_' + lowest[1] + '_' + lowest[2]).style.color == \"green\")\n {\n document.getElementById('tab_' + lowest[1] + '_' + lowest[2]).style.color = \"white\";\n }\n lowest[1] = i;\n lowest[2] = j;\n tot.style.color = \"green\";\n }\n }\n }\n\n //\n // Price vs Repair costs output table\n //\n rows = document.getElementById(\"repairs\").value;\n\n var pVrArray = new Array(rows+1);\n\n // Get the table\n var pVrtable = document.getElementById(\"prVrepTable\");\n\n pVrtable[0] = pVrtable.insertRow(0);\n var pVrNameCell = pVrtable[0].insertCell(0);\n pVrNameCell.innerHTML = \"Price/Maintance costs\";\n\n lowest[0] = 1000000;\n lowest[1] = 1;\n lowest[2] = 1;\n highest[0] = 0;\n highest[1] = 1;\n highest[2] = 1;\n\n for (var i = 1; i <= cols; i++)\n {\n var price = parseFloat(document.getElementById('pTable_' + i).value);\n var cell = pVrtable[0].insertCell(i);\n cell.innerHTML = \"Price \" + i + \" ($\" + price.toFixed(0) + \")\";\n }\n\n for (var i = 1; i <= rows; i++)\n {\n pVrtable[i] = pVrtable.insertRow(i);\n var hCell = pVrtable[i].insertCell(0);\n var rep = parseFloat(document.getElementById('rTable_' + i).value);\n hCell.innerHTML = \"Maintance Cost \" + i + \" (\" + rep.toFixed(2) + \")\";\n \n for (var j = 1; j <= cols; j++)\n {\n // Calculate Cost per month\n var price = parseFloat(document.getElementById('pTable_' + j).value);\n\n // compute the monthly payment figure\n var x = Math.pow(1 + interest, months); //Math.pow computes powers\n var monthly = (price*x*interest)/(x-1);\n\n var cell = pVrtable[i].insertCell(j);\n var pmo = document.createElement('output');\n pmo.type = 'text';\n pmo.name = 'pmor_' + i + '_' + j;\n pmo.id = 'pmor_' + i + '_' + j;\n pmo.size = 20;\n pmo.maxlength = 20;\n pmo.value = '$' + monthly.toFixed(2) + ' /mo';\n cell.appendChild(pmo);\n cell.appendChild(document.createElement('BR'));\n\n // Calculate Cost per Mile\n var prep = document.createElement('output');\n prep.type = 'text';\n prep.name = 'prep_' + i + '_' + j;\n prep.id = 'prep_' + i + '_' + j;\n prep.size = 20;\n prep.maxlength = 20;\n prep.value = '$' + rep.toFixed(2) + ' /mo';\n cell.appendChild(prep);\n cell.appendChild(document.createElement('BR'));\n\n // Calculate Total Cost per Month\n var tot = document.createElement('output');\n tot.type = 'text';\n tot.name = 'tabr_' + i + '_' + j;\n tot.id = 'tabr_' + i + '_' + j;\n tot.size = 20;\n tot.maxlength = 20;\n var cost = (monthly + rep);\n tot.value = '$' + cost.toFixed(2);\n cell.appendChild(tot);\n\n if (highest[0] < cost)\n {\n highest[0] = cost;\n if (document.getElementById('tabr_' + highest[1] + '_' + highest[2]).style.color == \"red\")\n {\n document.getElementById('tabr_' + highest[1] + '_' + highest[2]).style.color = \"white\";\n }\n highest[1] = i;\n highest[2] = j\n tot.style.color = \"red\";\n }\n if (lowest[0] >= cost)\n {\n lowest[0] = cost;\n if (document.getElementById('tabr_' + lowest[1] + '_' + lowest[2]).style.color == \"green\")\n {\n document.getElementById('tabr_' + lowest[1] + '_' + lowest[2]).style.color = \"white\";\n }\n lowest[1] = i;\n lowest[2] = j;\n tot.style.color = \"green\";\n }\n }\n }\n\n //\n // Price vs Insurance costs output table\n //\n rows = document.getElementById(\"insurances\").value;\n\n var pVinArray = new Array(rows+1);\n\n // Get the table\n var pVintable = document.getElementById(\"prVinTable\");\n\n pVinArray[0] = pVintable.insertRow(0);\n var pVinNameCell = pVinArray[0].insertCell(0);\n pVinNameCell.innerHTML = \"Price/Insurance Premium\";\n\n lowest[0] = 1000000;\n lowest[1] = 1;\n lowest[2] = 1;\n highest[0] = 0;\n highest[1] = 1;\n highest[2] = 1;\n\n for (var i = 1; i <= cols; i++)\n {\n var price = parseFloat(document.getElementById('pTable_' + i).value);\n var cell = pVinArray[0].insertCell(i);\n cell.innerHTML = \"Price \" + i + \" ($\" + price.toFixed(0) + \")\";\n }\n\n for (var i = 1; i <= rows; i++)\n {\n pVinArray[i] = pVintable.insertRow(i);\n var hCell = pVinArray[i].insertCell(0);\n var ins = parseFloat(document.getElementById('InTable_' + i).value);\n hCell.innerHTML = \"Insurance Premium \" + i + \" (\" + rep.toFixed(2) + \")\";\n\n for (var j = 1; j <= cols; j++)\n {\n // Calculate Cost per month\n var price = parseFloat(document.getElementById('pTable_' + j).value);\n\n // compute the monthly payment figure\n var x = Math.pow(1 + interest, months); //Math.pow computes powers\n var monthly = (price*x*interest)/(x-1);\n\n var cell = pVinArray[i].insertCell(j);\n var pmo = document.createElement('output');\n pmo.type = 'text';\n pmo.name = 'pmoin_' + i + '_' + j;\n pmo.id = 'pmoin_' + i + '_' + j;\n pmo.size = 20;\n pmo.maxlength = 20;\n pmo.value = '$' + monthly.toFixed(2) + ' /mo';\n cell.appendChild(pmo);\n cell.appendChild(document.createElement('BR'));\n\n // Calculate Cost per Mile\n var pins = document.createElement('output');\n pins.type = 'text';\n pins.name = 'prep_' + i + '_' + j;\n pins.id = 'prep_' + i + '_' + j;\n pins.size = 20;\n pins.maxlength = 20;\n pins.value = '$' + ins.toFixed(2) + ' /mo';\n cell.appendChild(pins);\n cell.appendChild(document.createElement('BR'));\n\n // Calculate Total Cost per Month\n var tot = document.createElement('output');\n tot.type = 'text';\n tot.name = 'tabin_' + i + '_' + j;\n tot.id = 'tabin_' + i + '_' + j;\n tot.size = 20;\n tot.maxlength = 20;\n var cost = (monthly + ins);\n tot.value = '$' + cost.toFixed(2);\n cell.appendChild(tot);\n\n if (highest[0] < cost)\n {\n highest[0] = cost;\n if (document.getElementById('tabin_' + highest[1] + '_' + highest[2]).style.color == \"red\")\n {\n document.getElementById('tabin_' + highest[1] + '_' + highest[2]).style.color = \"white\";\n }\n highest[1] = i;\n highest[2] = j\n tot.style.color = \"red\";\n }\n if (lowest[0] >= cost)\n {\n lowest[0] = cost;\n if (document.getElementById('tabin_' + lowest[1] + '_' + lowest[2]).style.color == \"green\")\n {\n document.getElementById('tabin_' + lowest[1] + '_' + lowest[2]).style.color = \"white\";\n }\n lowest[1] = i;\n lowest[2] = j;\n tot.style.color = \"green\";\n }\n }\n }\n\n return(true);\n} // makeOutTable", "title": "" }, { "docid": "91f16a7c9bd854ece3218cf081252b3b", "score": "0.5482049", "text": "function populateTable(lx, hx, ly, hy){\r\n\r\n var rows = $(\"#multTable tr\");\r\n var numOfRows = rows.length;\r\n\r\n // If user entered values out of order, just swap them so that the multiplication table goes from\r\n // the smaller value to the larger value\r\n if((hy - ly) < 0){\r\n [hy, ly] = [ly, hy];\r\n }\r\n if((hx - lx) < 0){\r\n [hx, lx] = [lx, hx];\r\n }\r\n\r\n // Populate the first row with the multiplier range\r\n $(\"#multTable tr:first-child td\").each( function(index, elem){\r\n if(index != 0){\r\n $(elem).html(lx + index - 1);\r\n $(elem).css({\r\n \"border-style\" : \"solid\",\r\n \"border-width\" : \"4px\",\r\n \"border-color\" : \"cyan\",\r\n \"background-color\" : \"black\",\r\n \"color\" : \"cyan\",\r\n \"padding\" : \"5px\"\r\n });\r\n }else{\r\n $(elem).css({\r\n \"border-style\" : \"solid\",\r\n \"border-width\" : \"4px\",\r\n \"border-color\" : \"cyan\",\r\n \"background-color\" : \"black\",\r\n \"color\" : \"cyan\",\r\n \"padding\" : \"5px\"\r\n });\r\n }\r\n });\r\n\r\n // Go through the table, and add each of the values\r\n rows.each(function(rIndex, rVal){\r\n var cols = $(this).find(\"td\");\r\n var numOfCols = cols.length;\r\n\r\n cols.each(function(cIndex, cVal){\r\n // Populate first column with the multiplicand range\r\n if(rIndex != 0 && cIndex == 0){\r\n $(this).html(ly + rIndex - 1);\r\n $(this).css({\r\n \"border-style\" : \"solid\",\r\n \"border-width\" : \"4px\",\r\n \"border-color\" : \"cyan\",\r\n \"background-color\" : \"black\",\r\n \"color\" : \"cyan\",\r\n \"padding\" : \"5px\"\r\n });\r\n }\r\n else if(rIndex != 0){\r\n var val = ($(rVal).find(\"td:first-child\").html() * $(rows[0]).find(\"td:nth-child(\" + (cIndex + 1) + \")\").html());\r\n $(this).html(val);\r\n }\r\n });\r\n });\r\n\r\n}", "title": "" }, { "docid": "42c1cc05f9d30eb791cc053bda9637cb", "score": "0.5465833", "text": "function expressionEvaluator() {\n var multiplyIndex = expressionArray.indexOf('x') //finds first index of * in the array\n var divideIndex = expressionArray.indexOf('÷') //finds first index of / in the array\n var addIndex = expressionArray.indexOf('+')\n var subtractIndex = expressionArray.indexOf('-')\n\n // [1, +, 9, /, 3, +, 4, *, 5] expressionArray\n while (multiplyIndex !== -1 || divideIndex !== -1) {\n\n if (multiplyIndex < divideIndex && multiplyIndex > 0 || divideIndex === -1) {\n expressionArray.splice(multiplyIndex-1, 3, expressionArray[multiplyIndex-1]*expressionArray[multiplyIndex+1]) // splices out 3 items and inserts product of the 3 items\n } else if (divideIndex < multiplyIndex && divideIndex > 0 || multiplyIndex === -1) {\n expressionArray.splice(divideIndex-1, 3, expressionArray[divideIndex-1]/expressionArray[divideIndex+1]) //splices out 3 items and inserts quotient of the 3 items\n }\n \n multiplyIndex = expressionArray.indexOf('x') //finds first index of * in the array\n divideIndex = expressionArray.indexOf('÷') //finds first index of / in the array\n }\n\n while (addIndex !== -1 || subtractIndex !== -1) {\n \n if (addIndex < subtractIndex && addIndex > 0 || subtractIndex === -1) {\n expressionArray.splice(addIndex-1, 3, expressionArray[addIndex-1]+expressionArray[addIndex+1])\n } else if (subtractIndex < addIndex && subtractIndex > 0 || addIndex === -1) {\n expressionArray.splice(subtractIndex-1, 3, expressionArray[subtractIndex-1]-expressionArray[subtractIndex+1])\n }\n \n addIndex = expressionArray.indexOf('+') // finds first index of + in the array\n subtractIndex = expressionArray.indexOf('-') // finds the first index of - in the array\n }\n\n total = expressionArray[0]\n console.log(expressionArray)\n }", "title": "" }, { "docid": "def249b0e34374ace3cf48c07eb718ec", "score": "0.54542387", "text": "function LE0601() {\n calculatefor(new Array(\n \" 0601 to 0700\",\n// 601 3 24\n1940656.062451, 13.0, 4703.9, \" 1.633\", \" 0.567\", 2,\n-22.72131, 0.91390, 0.24902,\n -2.26508, -0.90652, 0.00000, 0.49883, 0.00000, 1.90266, 3.26263,\n 185.5288519, 0.48414, -8.900e-05,\n -1.7576400, -0.15956, 1.050e-04,\n// 601 9 18\n1940833.549680, 1.0, 4699.3, \" 1.658\", \" 0.660\", 2,\n-23.05782, 0.98285, 0.26780,\n -2.34573, -1.19718, 0.00000, 0.19231, 0.00000, 1.58340, 2.72960,\n 357.4960900, 0.55861, 1.740e-04,\n -1.7803201, 0.18519, 1.610e-04,\n// 602 2 12\n1940980.830142, 8.0, 4695.5, \" 0.392\", \"-0.605\", 3,\n -6.37931, 0.98884, 0.26944,\n -1.48232, 0.00000, 0.00000, -0.07659, 0.00000, 0.00000, 1.32597,\n 148.0908092, 0.58770, -5.530e-04,\n 11.6120396, -0.15196, -5.330e-04,\n// 602 3 13\n1941010.308845, 19.0, 4694.7, \" 0.345\", \"-0.671\", 3,\n-17.44361, 0.96103, 0.26186,\n -0.95770, 0.00000, 0.00000, 0.41228, 0.00000, 0.00000, 1.77789,\n 175.8948428, 0.53498, -3.230e-04,\n 3.2039600, -0.17823, -6.400e-05,\n// 602 8 8\n1941158.298949, 19.0, 4690.9, \" 0.305\", \"-0.760\", 3,\n -7.71856, 0.91039, 0.24806,\n -1.20139, 0.00000, 0.00000, 0.17478, 0.00000, 0.00000, 1.55382,\n 319.6258602, 0.50926, -1.330e-04,\n -14.4648192, 0.11079, 5.730e-04,\n// 602 9 7\n1941187.910589, 10.0, 4690.1, \" 0.245\", \"-0.806\", 3,\n-14.77191, 0.93024, 0.25347,\n -1.35485, 0.00000, 0.00000, -0.14587, 0.00000, 0.00000, 1.06718,\n 348.0005424, 0.50542, 1.600e-05,\n -6.6488698, 0.16292, 3.160e-04,\n// 603 2 1\n1941335.443970, 23.0, 4686.3, \" 1.696\", \" 0.730\", 2,\n-16.07697, 1.02300, 0.27874,\n -2.78169, -1.73702, 0.00000, -0.34471, 0.00000, 1.04732, 2.09259,\n 138.0405410, 0.64606, -4.890e-04,\n 15.6518890, -0.13303, -9.320e-04,\n// 603 7 28\n1941512.318281, 20.0, 4681.7, \" 1.638\", \" 0.565\", 2,\n -7.45455, 0.90150, 0.24564,\n -3.17215, -1.78346, 0.00000, -0.36126, 0.00000, 1.06038, 2.45002,\n 309.1848506, 0.51437, -2.920e-04,\n -18.1045605, 0.08097, 6.730e-04,\n// 604 1 22\n1941690.103390, 14.0, 4677.1, \" 2.752\", \" 1.773\", 1,\n -1.77463, 1.01103, 0.27548,\n -2.22215, -1.29055, -0.33816, 0.48137, 1.30109, 2.25362, 3.18386,\n 126.8616524, 0.65129, -1.890e-04,\n 19.3076300, -0.09306, -1.181e-03,\n// 604 7 16\n1941866.436656, 22.0, 4672.5, \" 2.712\", \" 1.679\", 1,\n -6.18781, 0.93379, 0.25444,\n -2.48824, -1.41790, -0.37437, 0.47975, 1.33353, 2.37681, 3.44950,\n 297.7451853, 0.56789, -4.130e-04,\n -21.2161009, 0.05066, 9.300e-04,\n// 605 1 11\n1942044.614233, 3.0, 4667.9, \" 1.455\", \" 0.424\", 2,\n-13.47777, 0.96254, 0.26227,\n -2.76577, -1.43679, 0.00000, -0.25841, 0.00000, 0.92243, 2.24882,\n 116.0528507, 0.60791, 5.200e-05,\n 22.2129005, -0.04836, -1.150e-03,\n// 605 7 6\n1942220.852176, 8.0, 4663.4, \" 1.306\", \" 0.329\", 2,\n-20.89916, 0.98596, 0.26865,\n -1.87668, -0.57967, 0.00000, 0.45223, 0.00000, 1.48167, 2.78071,\n 286.6898684, 0.64557, -3.300e-04,\n -23.5314497, 0.01437, 1.326e-03,\n// 605 12 1\n1942369.048457, 13.0, 4659.5, \" 0.141\", \"-0.963\", 3,\n -6.16042, 0.90131, 0.24559,\n -0.80591, 0.00000, 0.00000, 0.16297, 0.00000, 0.00000, 1.13326,\n 71.1027884, 0.51857, 4.300e-04,\n 21.1029298, 0.10772, -7.760e-04,\n// 605 12 31\n1942398.829990, 8.0, 4658.8, \" 0.111\", \"-0.976\", 3,\n -9.20281, 0.91440, 0.24915,\n -0.92523, 0.00000, 0.00000, -0.08024, 0.00000, 0.00000, 0.76851,\n 103.8882633, 0.56015, 1.350e-04,\n 24.3958084, -0.00386, -1.032e-03,\n// 606 5 27\n1942546.234679, 18.0, 4654.9, \" 1.079\", \" 0.139\", 2,\n-13.51609, 1.02248, 0.27860,\n -2.44564, -1.03097, 0.00000, -0.36770, 0.00000, 0.29606, 1.71004,\n 246.3109649, 0.65852, 7.420e-04,\n -20.8623006, -0.15871, 1.247e-03,\n// 606 6 26\n1942575.507653, 0.0, 4654.2, \" 0.026\", \"-0.917\", 3,\n -5.59408, 1.02111, 0.27823,\n -0.17237, 0.00000, 0.00000, 0.18368, 0.00000, 0.00000, 0.53837,\n 275.7883948, 0.69885, 8.900e-05,\n -25.0564807, -0.03010, 1.640e-03,\n// 606 11 20\n1942723.013599, 12.0, 4650.4, \" 1.372\", \" 0.279\", 2,\n -7.90188, 0.91049, 0.24809,\n -2.31437, -0.70898, 0.00000, 0.32637, 0.00000, 1.35987, 2.96658,\n 58.7551655, 0.51326, 3.590e-04,\n 19.7104694, 0.14981, -7.650e-04,\n// 607 5 17\n1942900.907204, 10.0, 4645.8, \" 2.429\", \" 1.458\", 1,\n-22.21101, 0.99157, 0.27018,\n -2.94690, -1.99186, -0.96885, -0.22711, 0.51501, 1.53818, 2.49121,\n 235.4432870, 0.60284, 9.400e-04,\n -19.5904015, -0.18906, 9.290e-04,\n// 607 11 9\n1943077.191412, 17.0, 4641.2, \" 2.673\", \" 1.634\", 1,\n -3.62692, 0.95602, 0.26049,\n -3.30767, -2.25422, -1.22869, -0.40610, 0.41611, 1.44135, 2.49726,\n 47.3735022, 0.54595, 3.760e-04,\n 17.7478009, 0.19984, -8.410e-04,\n// 608 5 5\n1943255.357341, 21.0, 4636.6, \" 1.841\", \" 0.814\", 2,\n-11.91963, 0.93940, 0.25597,\n -3.17696, -1.99490, 0.00000, -0.42382, 0.00000, 1.14894, 2.32887,\n 224.7339192, 0.52451, 7.930e-04,\n -17.6774602, -0.19972, 6.150e-04,\n// 608 10 29\n1943431.671960, 4.0, 4632.0, \" 1.786\", \" 0.801\", 2,\n-17.33553, 1.00665, 0.27429,\n -2.39633, -1.33587, 0.00000, 0.12705, 0.00000, 1.58907, 2.65140,\n 35.9380990, 0.58238, 5.090e-04,\n 15.0019709, 0.25265, -8.180e-04,\n// 609 3 26\n1943579.844911, 8.0, 4628.2, \" 0.087\", \"-0.995\", 3,\n -3.59953, 0.89969, 0.24515,\n -0.48319, 0.00000, 0.00000, 0.27787, 0.00000, 0.00000, 1.03835,\n 187.7825138, 0.43417, 4.500e-05,\n -1.8804200, -0.23543, 6.000e-05,\n// 609 4 25\n1943609.505952, 0.0, 4627.5, \" 0.406\", \"-0.664\", 3,\n -9.65014, 0.90329, 0.24613,\n -1.44544, 0.00000, 0.00000, 0.14284, 0.00000, 0.00000, 1.73290,\n 213.6244662, 0.46803, 5.180e-04,\n -14.8991202, -0.20734, 4.460e-04,\n// 609 9 19\n1943756.923409, 10.0, 4623.7, \" 0.289\", \"-0.679\", 3,\n-13.96342, 1.01368, 0.27620,\n -1.01803, 0.00000, 0.00000, 0.16182, 0.00000, 0.00000, 1.34362,\n 359.3032761, 0.54841, 4.300e-05,\n -1.8469000, 0.30016, 1.600e-04,\n// 609 10 18\n1943786.322391, 20.0, 4622.9, \" 0.579\", \"-0.386\", 3,\n -2.03046, 1.02426, 0.27908,\n -1.87245, 0.00000, 0.00000, -0.26262, 0.00000, 0.00000, 1.34807,\n 25.5341892, 0.58451, 6.480e-04,\n 12.0392500, 0.28280, -5.940e-04,\n// 610 3 15\n1943933.902937, 10.0, 4619.1, \" 1.453\", \" 0.398\", 2,\n -2.33278, 0.92501, 0.25204,\n -2.95428, -1.52431, 0.00000, -0.32950, 0.00000, 0.86304, 2.29461,\n 177.7062226, 0.45727, -2.170e-04,\n 1.7698800, -0.25161, 2.800e-05,\n// 610 9 8\n1944111.478741, 23.0, 4614.5, \" 1.524\", \" 0.513\", 2,\n -1.66656, 0.96742, 0.26360,\n -2.03049, -0.78303, 0.00000, 0.48978, 0.00000, 1.76464, 3.00935,\n 349.1008586, 0.50382, -1.300e-05,\n -5.5192500, 0.27108, 3.300e-04,\n// 611 3 4\n1944288.230911, 18.0, 4609.9, \" 2.833\", \" 1.830\", 1,\n-19.04961, 0.97663, 0.26611,\n -3.27450, -2.28751, -1.30188, -0.45813, 0.38533, 1.37073, 2.35987,\n 167.5564795, 0.51361, -4.500e-04,\n 5.3718400, -0.27547, -9.800e-05,\n// 611 8 29\n1944465.757257, 6.0, 4605.4, \" 2.889\", \" 1.827\", 1,\n-19.38612, 0.91810, 0.25016,\n -2.87909, -1.75617, -0.69972, 0.17417, 1.04830, 2.10494, 3.22599,\n 338.9113092, 0.46268, -1.610e-04,\n -8.9514402, 0.23526, 3.570e-04,\n// 612 2 22\n1944642.817461, 8.0, 4600.8, \" 1.576\", \" 0.612\", 2,\n -5.75001, 1.01843, 0.27750,\n -2.77500, -1.68567, 0.00000, -0.38094, 0.00000, 0.92319, 2.01375,\n 157.3571493, 0.56882, -5.480e-04,\n 8.7818201, -0.28574, -3.700e-04,\n// 612 8 17\n1944819.790188, 7.0, 4596.2, \" 1.533\", \" 0.452\", 2,\n-19.12211, 0.89962, 0.24513,\n -2.80029, -1.33357, 0.00000, -0.03548, 0.00000, 1.26253, 2.72996,\n 328.3160465, 0.45704, -3.760e-04,\n -12.2255204, 0.21001, 3.710e-04,\n// 613 1 12\n1944968.052393, 13.0, 4592.4, \" 0.460\", \"-0.533\", 3,\n -3.38063, 0.99943, 0.27232,\n -1.23686, 0.00000, 0.00000, 0.25744, 0.00000, 0.00000, 1.75413,\n 117.6719607, 0.63303, -5.360e-04,\n 22.5057602, -0.16586, -1.296e-03,\n// 613 2 10\n1944997.493195, 0.0, 4591.7, \" 0.337\", \"-0.631\", 3,\n-14.44493, 1.01799, 0.27738,\n -1.42730, 0.00000, 0.00000, -0.16331, 0.00000, 0.00000, 1.10263,\n 146.9082849, 0.58523, -4.530e-04,\n 11.9502100, -0.26336, -6.560e-04,\n// 613 7 7\n1945144.336205, 20.0, 4587.9, \" 0.487\", \"-0.530\", 3,\n -8.79654, 0.94804, 0.25832,\n -1.55756, 0.00000, 0.00000, 0.06892, 0.00000, 0.00000, 1.69171,\n 288.8279909, 0.58412, -7.790e-04,\n -23.7217593, 0.11903, 1.047e-03,\n// 613 8 6\n1945173.853582, 8.0, 4587.1, \" 0.219\", \"-0.830\", 3,\n-18.85810, 0.92372, 0.25169,\n -0.67251, 0.00000, 0.00000, 0.48598, 0.00000, 0.00000, 1.64062,\n 317.2010065, 0.49934, -6.340e-04,\n -15.1744810, 0.19661, 4.820e-04,\n// 614 1 1\n1945322.487891, 0.0, 4583.3, \" 1.666\", \" 0.616\", 2,\n-17.08925, 0.94678, 0.25797,\n -2.96348, -1.69161, 0.00000, -0.29062, 0.00000, 1.11227, 2.38140,\n 106.0459542, 0.58364, -2.440e-04,\n 23.4086309, -0.10996, -1.130e-03,\n// 614 6 27\n1945498.833611, 8.0, 4578.7, \" 1.948\", \" 0.985\", 2,\n-21.50242, 0.99927, 0.27228,\n -2.57674, -1.57628, 0.00000, 0.00667, 0.00000, 1.58858, 2.59064,\n 277.5393001, 0.65778, -6.770e-04,\n -23.9205212, 0.08742, 1.369e-03,\n// 614 12 22\n1945676.614942, 3.0, 4574.1, \" 2.869\", \" 1.771\", 1,\n-14.81976, 0.90582, 0.24681,\n -3.37232, -2.18898, -1.11171, -0.24139, 0.62909, 1.70650, 2.88851,\n 93.5695277, 0.54238, -1.420e-04,\n 23.5471591, -0.05864, -9.510e-04,\n// 615 6 17\n1945853.526060, 1.0, 4569.6, \" 2.345\", \" 1.405\", 1,\n -5.19460, 1.02338, 0.27885,\n -2.97626, -2.07890, -1.07020, -0.37455, 0.32109, 1.32980, 2.22724,\n 266.7359626, 0.69132, -2.390e-04,\n -23.2932212, 0.04420, 1.514e-03,\n// 615 12 11\n1946030.572620, 2.0, 4565.0, \" 1.630\", \" 0.529\", 2,\n-16.56123, 0.90429, 0.24640,\n -3.07581, -1.63636, 0.00000, -0.25711, 0.00000, 1.12122, 2.56188,\n 81.0054015, 0.54063, -1.450e-04,\n 22.7176992, -0.01447, -9.060e-04,\n// 616 6 5\n1946208.223625, 17.0, 4560.5, \" 0.971\", \" 0.011\", 2,\n-13.88952, 1.00148, 0.27288,\n -1.67619, 0.17516, 0.00000, 0.36699, 0.00000, 0.56155, 2.41128,\n 255.3471412, 0.65761, 2.570e-04,\n -21.9300896, -0.00678, 1.304e-03,\n// 616 10 30\n1946355.081032, 14.0, 4556.7, \" 0.108\", \"-0.912\", 3,\n -7.23840, 0.97193, 0.26483,\n -0.83146, 0.00000, 0.00000, -0.05523, 0.00000, 0.00000, 0.71595,\n 37.4192084, 0.58349, 1.540e-04,\n 16.4107794, 0.13438, -8.640e-04,\n// 616 11 29\n1946384.679975, 4.0, 4555.9, \" 0.428\", \"-0.627\", 3,\n-15.29448, 0.94322, 0.25701,\n -1.23630, 0.00000, 0.00000, 0.31939, 0.00000, 0.00000, 1.87136,\n 68.5192693, 0.57993, -1.140e-04,\n 20.8836005, 0.03142, -9.890e-04,\n// 617 4 26\n1946533.241206, 18.0, 4552.1, \" 1.300\", \" 0.257\", 2,\n-15.53110, 0.92606, 0.25233,\n -2.72585, -1.18935, 0.00000, -0.21107, 0.00000, 0.76986, 2.30439,\n 215.8359585, 0.52643, 4.940e-04,\n -15.1860599, -0.12416, 5.680e-04,\n// 617 10 20\n1946709.630408, 3.0, 4547.6, \" 1.429\", \" 0.456\", 2,\n-18.94153, 1.01642, 0.27695,\n -2.19981, -1.02618, 0.00000, 0.12980, 0.00000, 1.28476, 2.45975,\n 26.9874896, 0.61862, 2.570e-04,\n 12.0653900, 0.16984, -7.200e-04,\n// 618 4 15\n1946887.321285, 20.0, 4543.0, \" 2.679\", \" 1.603\", 1,\n-14.26435, 0.89991, 0.24521,\n -3.40937, -2.24196, -1.14404, -0.28916, 0.56577, 1.66375, 2.83081,\n 205.6828550, 0.48369, 2.410e-04,\n -10.8286400, -0.13501, 3.700e-04,\n// 618 10 9\n1947064.297153, 19.0, 4538.5, \" 2.674\", \" 1.707\", 1,\n -3.63645, 1.02002, 0.27793,\n -2.53573, -1.62343, -0.67504, 0.13166, 0.93848, 1.88697, 2.79859,\n 17.1563885, 0.60946, 3.630e-04,\n 7.4571800, 0.18709, -3.860e-04,\n// 619 4 4\n1947241.354718, 21.0, 4533.9, \" 1.743\", \" 0.683\", 2,\n-14.00034, 0.91601, 0.24959,\n -3.29350, -1.99647, 0.00000, -0.48677, 0.00000, 1.02151, 2.32007,\n 195.8015110, 0.49094, 2.000e-06,\n -6.1482200, -0.15314, 2.670e-04,\n// 619 9 29\n1947418.885436, 9.0, 4529.3, \" 1.714\", \" 0.709\", 2,\n-14.33685, 0.97999, 0.26702,\n -2.32336, -1.18227, 0.00000, 0.25047, 0.00000, 1.68474, 2.82344,\n 7.4555698, 0.55635, 3.130e-04,\n 2.5977098, 0.18224, -4.600e-05,\n// 620 2 23\n1947566.170670, 16.0, 4525.5, \" 0.346\", \"-0.644\", 3,\n-21.65835, 0.99150, 0.27016,\n -1.22661, 0.00000, 0.00000, 0.09607, 0.00000, 0.00000, 1.41550,\n 158.3466661, 0.57834, -4.590e-04,\n 7.7057597, -0.17275, -3.200e-04,\n// 620 3 24\n1947595.625513, 3.0, 4524.8, \" 0.434\", \"-0.575\", 3,\n -8.72265, 0.96416, 0.26271,\n -1.50418, 0.00000, 0.00000, 0.01230, 0.00000, 0.00000, 1.52480,\n 185.9337865, 0.53774, -1.970e-04,\n -1.2037999, -0.17856, 1.290e-04,\n// 620 8 19\n1947743.587017, 2.0, 4521.0, \" 0.189\", \"-0.881\", 3,\n -0.00033, 0.90864, 0.24758,\n -1.01071, 0.00000, 0.00000, 0.08841, 0.00000, 0.00000, 1.19050,\n 329.9404294, 0.49490, -1.120e-04,\n -10.9271902, 0.13195, 4.260e-04,\n// 620 9 17\n1947773.222869, 17.0, 4520.2, \" 0.316\", \"-0.742\", 3,\n -7.05368, 0.92764, 0.25276,\n -1.02118, 0.00000, 0.00000, 0.34886, 0.00000, 0.00000, 1.72250,\n 357.6966243, 0.49808, 1.140e-04,\n -2.4005101, 0.16636, 1.500e-04,\n// 621 2 12\n1947920.797872, 7.0, 4516.4, \" 1.656\", \" 0.694\", 2,\n -7.35601, 1.02349, 0.27888,\n -2.26831, -1.21584, 0.00000, 0.14893, 0.00000, 1.51350, 2.56652,\n 148.4697754, 0.63011, -4.340e-04,\n 12.1706304, -0.16170, -7.010e-04,\n// 621 8 8\n1948097.597795, 2.0, 4511.9, \" 1.509\", \" 0.435\", 2,\n -0.73906, 0.90236, 0.24587,\n -2.39104, -0.92521, 0.00000, 0.34707, 0.00000, 1.61858, 3.08558,\n 319.3888254, 0.50240, -3.180e-04,\n -15.1569599, 0.10713, 5.420e-04,\n// 622 2 1\n1948275.459977, 23.0, 4507.3, \" 2.780\", \" 1.801\", 1,\n-16.05093, 1.00900, 0.27493,\n -2.66971, -1.73713, -0.78430, 0.03945, 0.86339, 1.81638, 2.74750,\n 138.3414518, 0.63074, -2.330e-04,\n 16.2408016, -0.13002, -9.700e-04,\n// 622 7 28\n1948451.726195, 5.0, 4502.8, \" 2.846\", \" 1.813\", 1,\n-22.46958, 0.93678, 0.25525,\n -2.53329, -1.47038, -0.43904, 0.42867, 1.29607, 2.32715, 3.39248,\n 308.6778593, 0.55821, -5.040e-04,\n -18.8391302, 0.08570, 7.970e-04,\n// 623 1 22\n1948629.962355, 11.0, 4498.2, \" 1.472\", \" 0.440\", 2,\n -4.75680, 0.95960, 0.26147,\n -2.42867, -1.10435, 0.00000, 0.09653, 0.00000, 1.29981, 2.62144,\n 127.4791151, 0.58971, -6.900e-05,\n 19.8825902, -0.08665, -1.008e-03,\n// 623 7 17\n1948806.157398, 16.0, 4493.7, \" 1.439\", \" 0.463\", 2,\n-12.17819, 0.98908, 0.26950,\n -2.62090, -1.41794, 0.00000, -0.22245, 0.00000, 0.97094, 2.17579,\n 298.3553125, 0.63820, -5.180e-04,\n -21.8260898, 0.05959, 1.204e-03,\n// 623 12 12\n1948954.383230, 21.0, 4489.9, \" 0.128\", \"-0.977\", 3,\n-21.43945, 0.90067, 0.24541,\n -0.72812, 0.00000, 0.00000, 0.19753, 0.00000, 0.00000, 1.12438,\n 83.0638566, 0.52912, 3.000e-04,\n 22.0923203, 0.06775, -8.440e-04,\n// 624 1 11\n1948984.165059, 16.0, 4489.1, \" 0.125\", \"-0.963\", 3,\n -0.48184, 0.91262, 0.24867,\n -0.93491, 0.00000, 0.00000, -0.03859, 0.00000, 0.00000, 0.86123,\n 115.9028324, 0.54940, -3.800e-05,\n 22.8681598, -0.04420, -9.560e-04,\n// 624 6 7\n1949131.544793, 1.0, 4485.4, \" 0.945\", \" 0.003\", 2,\n -5.79786, 1.02177, 0.27841,\n -1.89858, -0.02809, 0.00000, 0.07502, 0.00000, 0.17892, 2.04869,\n 257.1658020, 0.67359, 6.070e-04,\n -22.0365501, -0.11330, 1.365e-03,\n// 624 7 6\n1949160.819773, 8.0, 4484.6, \" 0.154\", \"-0.789\", 3,\n-20.87311, 1.02201, 0.27847,\n -1.18599, 0.00000, 0.00000, -0.32545, 0.00000, 0.00000, 0.53413,\n 287.6209325, 0.69526, -1.840e-04,\n -24.1356209, 0.02119, 1.573e-03,\n// 624 11 30\n1949308.351962, 20.0, 4480.8, \" 1.363\", \" 0.272\", 2,\n-23.18091, 0.91212, 0.24853,\n -2.18213, -0.57353, 0.00000, 0.44710, 0.00000, 1.46579, 3.07586,\n 70.4662625, 0.53225, 2.830e-04,\n 21.6053005, 0.11359, -8.740e-04,\n// 625 5 27\n1949486.209557, 17.0, 4476.3, \" 2.291\", \" 1.317\", 1,\n-14.49278, 0.98850, 0.26934,\n -2.67707, -1.70385, -0.62262, 0.02937, 0.68186, 1.76325, 2.73439,\n 246.2550120, 0.61885, 8.820e-04,\n -21.5104599, -0.14948, 1.081e-03,\n// 625 11 20\n1949662.543178, 1.0, 4471.8, \" 2.661\", \" 1.624\", 1,\n-18.90595, 0.95888, 0.26127,\n -2.85431, -1.80558, -0.78182, 0.03627, 0.85398, 1.87745, 2.92862,\n 58.6001817, 0.57075, 3.720e-04,\n 20.3501200, 0.16696, -9.980e-04,\n// 626 5 17\n1949840.642830, 3.0, 4467.2, \" 1.982\", \" 0.954\", 2,\n -5.20413, 0.93631, 0.25512,\n -2.38771, -1.23630, 0.00000, 0.42793, 0.00000, 2.09355, 3.24281,\n 234.9817028, 0.53954, 7.990e-04,\n -20.1454602, -0.16997, 7.550e-04,\n// 626 11 9\n1950017.034003, 13.0, 4462.7, \" 1.804\", \" 0.819\", 2,\n -7.61183, 1.00874, 0.27486,\n -2.70881, -1.65559, 0.00000, -0.18392, 0.00000, 1.28692, 2.34187,\n 47.2386026, 0.60892, 6.060e-04,\n 18.4043699, 0.22226, -1.035e-03,\n// 627 5 6\n1950194.777946, 7.0, 4458.1, \" 0.548\", \"-0.520\", 3,\n -1.93191, 0.90227, 0.24585,\n -2.15298, 0.00000, 0.00000, -0.32930, 0.00000, 0.00000, 1.49577,\n 224.2523635, 0.48510, 5.730e-04,\n -18.1819397, -0.18459, 5.870e-04,\n// 627 9 30\n1950342.268417, 18.0, 4454.4, \" 0.235\", \"-0.738\", 3,\n -5.24245, 1.01200, 0.27575,\n -0.63018, 0.00000, 0.00000, 0.44200, 0.00000, 0.00000, 1.51648,\n 9.1824602, 0.54851, 2.650e-04,\n 2.4054799, 0.29596, -3.000e-05,\n// 627 10 30\n1950371.683782, 4.0, 4453.6, \" 0.603\", \"-0.365\", 3,\n-17.30949, 1.02393, 0.27899,\n -1.22948, 0.00000, 0.00000, 0.41077, 0.00000, 0.00000, 2.05199,\n 35.8820812, 0.60431, 8.200e-04,\n 15.6652404, 0.26004, -8.080e-04,\n// 628 3 25\n1950519.204841, 17.0, 4449.8, \" 1.355\", \" 0.306\", 2,\n-18.61455, 0.92759, 0.25275,\n -2.63612, -1.14375, 0.00000, -0.08381, 0.00000, 0.97358, 2.46757,\n 187.4290788, 0.46095, -7.800e-05,\n -2.4031700, -0.25141, 1.660e-04,\n// 628 9 19\n1950696.804989, 7.0, 4445.3, \" 1.454\", \" 0.436\", 2,\n-16.94559, 0.96437, 0.26277,\n -2.17391, -0.87137, 0.00000, 0.31973, 0.00000, 1.51309, 2.81282,\n 359.1665903, 0.49649, 1.650e-04,\n -1.1891001, 0.27329, 1.630e-04,\n// 629 3 15\n1950873.557171, 1.0, 4440.8, \" 2.753\", \" 1.757\", 1,\n-11.33138, 0.97961, 0.26692,\n -2.42883, -1.45072, -0.46577, 0.37209, 1.20966, 2.19436, 3.17455,\n 177.0826810, 0.51220, -2.730e-04,\n 1.3564900, -0.28225, 6.300e-05,\n// 629 9 8\n1951051.059692, 13.0, 4436.2, \" 2.800\", \" 1.732\", 1,\n-11.66789, 0.91594, 0.24957,\n -2.63211, -1.49845, -0.43551, 0.43261, 1.30096, 2.36406, 3.49590,\n 348.8127612, 0.45156, -3.800e-05,\n -4.9215897, 0.24354, 2.210e-04,\n// 630 3 4\n1951228.160649, 16.0, 4431.7, \" 1.636\", \" 0.675\", 2,\n-21.02904, 1.01957, 0.27781,\n -2.56046, -1.50024, 0.00000, -0.14443, 0.00000, 1.21092, 2.27227,\n 167.3752609, 0.55858, -3.360e-04,\n 4.7282198, -0.29926, -1.720e-04,\n// 630 8 28\n1951405.078260, 14.0, 4427.2, \" 1.647\", \" 0.563\", 2,\n-11.40388, 0.89986, 0.24519,\n -2.95029, -1.54423, 0.00000, -0.12176, 0.00000, 1.30055, 2.70746,\n 338.4991756, 0.44431, -2.810e-04,\n -8.4401194, 0.22528, 2.390e-04,\n// 631 1 23\n1951553.410388, 22.0, 4423.4, \" 0.435\", \"-0.558\", 3,\n-17.65693, 0.99694, 0.27164,\n -1.61082, 0.00000, 0.00000, -0.15068, 0.00000, 0.00000, 1.31199,\n 129.5649320, 0.60540, -5.720e-04,\n 19.9731107, -0.20593, -1.102e-03,\n// 631 2 22\n1951582.841927, 8.0, 4422.6, \" 0.379\", \"-0.587\", 3,\n -5.72396, 1.01640, 0.27694,\n -1.13087, 0.00000, 0.00000, 0.20625, 0.00000, 0.00000, 1.54546,\n 157.1149098, 0.56670, -2.780e-04,\n 8.2023998, -0.28285, -4.570e-04,\n// 631 7 19\n1951729.628479, 3.0, 4418.9, \" 0.362\", \"-0.653\", 3,\n -1.07831, 0.95133, 0.25922,\n -1.33047, 0.00000, 0.00000, 0.08349, 0.00000, 0.00000, 1.49318,\n 300.0550733, 0.57017, -8.810e-04,\n -22.0527189, 0.15829, 9.210e-04,\n// 631 8 17\n1951759.148174, 16.0, 4418.1, \" 0.340\", \"-0.710\", 3,\n-10.13713, 0.92631, 0.25240,\n -1.86426, 0.00000, 0.00000, -0.44383, 0.00000, 0.00000, 0.97326,\n 328.0227855, 0.48419, -5.550e-04,\n -11.6570395, 0.22081, 3.260e-04,\n// 632 1 13\n1951907.834746, 8.0, 4414.3, \" 1.648\", \" 0.597\", 2,\n -8.36828, 0.94402, 0.25722,\n -2.63928, -1.35365, 0.00000, 0.03389, 0.00000, 1.42335, 2.70617,\n 117.8038926, 0.56258, -3.590e-04,\n 21.7902603, -0.14989, -1.014e-03,\n// 632 7 7\n1952084.140523, 15.0, 4409.8, \" 1.818\", \" 0.856\", 2,\n-13.78419, 1.00198, 0.27301,\n -2.15874, -1.13338, 0.00000, 0.37256, 0.00000, 1.87732, 2.90412,\n 288.6840105, 0.64810, -8.600e-04,\n -23.0794995, 0.13352, 1.278e-03,\n// 633 1 1\n1952261.950256, 11.0, 4405.3, \" 2.883\", \" 1.784\", 1,\n -6.09879, 0.90465, 0.24650,\n -3.32937, -2.14424, -1.06581, -0.19386, 0.67824, 1.75679, 2.94069,\n 105.6710588, 0.53082, -2.990e-04,\n 22.8085715, -0.09962, -8.950e-04,\n// 633 6 27\n1952438.837141, 8.0, 4400.8, \" 2.479\", \" 1.539\", 1,\n-21.47637, 1.02339, 0.27885,\n -2.52948, -1.64118, -0.67098, 0.09139, 0.85378, 1.82402, 2.71230,\n 277.8015794, 0.68526, -4.660e-04,\n -23.2324599, 0.09309, 1.487e-03,\n// 633 12 21\n1952615.908828, 10.0, 4396.3, \" 1.641\", \" 0.542\", 2,\n -7.84026, 0.90542, 0.24671,\n -3.00776, -1.57976, 0.00000, -0.18812, 0.00000, 1.20256, 2.63195,\n 93.1025613, 0.53967, -3.220e-04,\n 22.9536891, -0.05658, -9.020e-04,\n// 634 6 17\n1952793.527599, 1.0, 4391.7, \" 1.104\", \" 0.141\", 2,\n -5.16855, 0.99877, 0.27214,\n -2.49186, -1.01987, 0.00000, -0.33762, 0.00000, 0.34717, 1.81759,\n 267.0705872, 0.65617, 2.900e-05,\n -22.6282596, 0.04250, 1.349e-03,\n// 634 11 10\n1952940.434864, 22.0, 4388.0, \" 0.102\", \"-0.917\", 3,\n-22.51743, 0.97483, 0.26562,\n -0.31589, 0.00000, 0.00000, 0.43674, 0.00000, 0.00000, 1.18435,\n 48.3274918, 0.60486, 1.390e-04,\n 19.6256299, 0.10460, -1.055e-03,\n// 634 12 10\n1952970.030667, 13.0, 4387.2, \" 0.438\", \"-0.614\", 3,\n -5.57077, 0.94592, 0.25774,\n -1.83066, 0.00000, 0.00000, -0.26399, 0.00000, 0.00000, 1.29905,\n 80.8298793, 0.58853, -3.000e-04,\n 22.0743296, -0.01381, -1.046e-03,\n// 635 5 8\n1953118.523920, 1.0, 4383.4, \" 1.157\", \" 0.113\", 2,\n -7.81287, 0.92340, 0.25161,\n -2.84372, -1.08997, 0.00000, -0.42591, 0.00000, 0.24105, 1.99289,\n 226.3703095, 0.53842, 4.880e-04,\n -18.4361491, -0.09779, 7.270e-04,\n// 635 10 31\n1953294.990892, 12.0, 4378.9, \" 1.410\", \" 0.436\", 2,\n -9.21783, 1.01795, 0.27737,\n -2.53497, -1.35112, 0.00000, -0.21858, 0.00000, 0.91300, 2.09807,\n 37.9812101, 0.63787, 3.250e-04,\n 15.8798107, 0.14357, -9.640e-04,\n// 636 4 26\n1953472.596630, 2.0, 4374.4, \" 2.539\", \" 1.466\", 1,\n -7.54886, 0.89967, 0.24514,\n -2.78488, -1.61084, -0.48079, 0.31912, 1.11908, 2.24918, 3.42306,\n 215.4892991, 0.49509, 2.730e-04,\n -14.4398498, -0.11723, 5.140e-04,\n// 636 10 20\n1953649.653043, 4.0, 4369.9, \" 2.644\", \" 1.673\", 1,\n-17.91275, 1.01893, 0.27763,\n -2.99806, -2.08000, -1.12663, -0.32696, 0.47285, 1.42634, 2.34362,\n 27.8471798, 0.62140, 4.890e-04,\n 11.6389796, 0.16810, -6.350e-04,\n// 637 4 15\n1953826.642833, 3.0, 4365.4, \" 1.864\", \" 0.810\", 2,\n -7.28485, 0.91826, 0.25020,\n -2.41938, -1.17644, 0.00000, 0.42800, 0.00000, 2.03116, 3.27577,\n 205.2418024, 0.50215, 6.800e-05,\n -10.0362193, -0.14159, 4.200e-04,\n// 637 10 9\n1954004.226390, 17.0, 4360.9, \" 1.757\", \" 0.747\", 2,\n -5.61588, 0.97713, 0.26625,\n -2.17008, -1.03140, 0.00000, 0.43335, 0.00000, 1.89959, 3.03584,\n 17.4908406, 0.55948, 4.390e-04,\n 6.8758003, 0.17201, -2.510e-04,\n// 638 3 6\n1954151.505721, 0.0, 4357.1, \" 0.288\", \"-0.696\", 3,\n-12.93738, 0.99414, 0.27088,\n -1.07162, 0.00000, 0.00000, 0.13731, 0.00000, 0.00000, 1.34285,\n 168.3920302, 0.57324, -3.300e-04,\n 3.5167402, -0.18622, -1.050e-04,\n// 638 4 4\n1954180.937010, 10.0, 4356.4, \" 0.537\", \"-0.467\", 3,\n -1.00441, 0.96735, 0.26358,\n -1.17276, 0.00000, 0.00000, 0.48824, 0.00000, 0.00000, 2.14571,\n 195.4756427, 0.54616, -8.100e-05,\n -5.3588699, -0.17227, 3.150e-04,\n// 638 8 30\n1954328.879981, 9.0, 4352.6, \" 0.086\", \"-0.990\", 3,\n-16.28210, 0.90705, 0.24715,\n -0.62945, 0.00000, 0.00000, 0.11955, 0.00000, 0.00000, 0.87154,\n 339.9869820, 0.48340, -5.600e-05,\n -7.0106902, 0.14695, 2.750e-04,\n// 638 9 29\n1954358.540778, 1.0, 4351.8, \" 0.374\", \"-0.690\", 3,\n-22.33271, 0.92516, 0.25209,\n -1.51079, 0.00000, 0.00000, -0.02132, 0.00000, 0.00000, 1.47137,\n 7.8528802, 0.49611, 2.180e-04,\n 2.0415499, 0.16360, -2.000e-05,\n// 639 2 23\n1954506.146324, 16.0, 4348.1, \" 1.604\", \" 0.645\", 2,\n-21.63230, 1.02384, 0.27897,\n -2.87972, -1.81421, 0.00000, -0.48823, 0.00000, 0.83765, 1.90364,\n 159.2332110, 0.61632, -3.210e-04,\n 8.1029599, -0.18351, -4.500e-04,\n// 639 8 19\n1954682.883180, 9.0, 4343.6, \" 1.393\", \" 0.317\", 2,\n-17.02083, 0.90336, 0.24615,\n -2.46810, -0.90833, 0.00000, 0.19633, 0.00000, 1.29995, 2.86111,\n 329.7645384, 0.49082, -2.990e-04,\n -11.6200702, 0.12889, 3.950e-04,\n// 640 2 13\n1954860.810745, 7.0, 4339.1, \" 2.819\", \" 1.841\", 1,\n -7.32996, 1.00681, 0.27433,\n -2.25704, -1.32353, -0.36991, 0.45787, 1.28587, 2.23965, 3.17163,\n 148.8396711, 0.61131, -1.890e-04,\n 12.7344301, -0.15697, -7.500e-04,\n// 640 8 7\n1955037.022038, 13.0, 4334.6, \" 2.781\", \" 1.749\", 1,\n-13.74861, 0.93982, 0.25608,\n -3.42138, -2.36203, -1.33152, -0.47110, 0.38899, 1.41926, 2.48109,\n 319.7923256, 0.54594, -5.330e-04,\n -15.7345002, 0.11677, 6.320e-04,\n// 641 2 1\n1955215.306033, 19.0, 4330.1, \" 1.496\", \" 0.463\", 2,\n-20.03583, 0.95664, 0.26066,\n -2.20230, -0.88756, 0.00000, 0.34480, 0.00000, 1.57948, 2.89146,\n 138.5516167, 0.56957, -1.120e-04,\n 16.8705297, -0.11824, -8.380e-04,\n// 641 7 27\n1955391.466314, 23.0, 4325.6, \" 1.565\", \" 0.590\", 2,\n -4.45996, 0.99213, 0.27033,\n -2.26443, -1.12756, 0.00000, 0.19153, 0.00000, 1.50881, 2.64746,\n 309.0508969, 0.62704, -6.170e-04,\n -19.4533401, 0.09765, 1.041e-03,\n// 641 12 23\n1955539.718260, 5.0, 4321.8, \" 0.116\", \"-0.989\", 3,\n-12.71848, 0.90016, 0.24527,\n -0.64408, 0.00000, 0.00000, 0.23823, 0.00000, 0.00000, 1.12153,\n 95.1179930, 0.53302, 1.370e-04,\n 22.1535205, 0.02626, -8.630e-04,\n// 642 1 21\n1955569.497221, 0.0, 4321.1, \" 0.144\", \"-0.944\", 3,\n-15.76087, 0.91093, 0.24821,\n -1.02866, 0.00000, 0.00000, -0.06670, 0.00000, 0.00000, 0.89847,\n 127.5997636, 0.53380, -1.480e-04,\n 20.5132301, -0.07967, -8.360e-04,\n// 642 6 18\n1955716.854184, 9.0, 4317.3, \" 0.809\", \"-0.133\", 3,\n-21.07689, 1.02089, 0.27817,\n -2.35388, 0.00000, 0.00000, -0.49958, 0.00000, 0.00000, 1.35512,\n 268.8315739, 0.68257, 3.900e-04,\n -22.5192293, -0.06224, 1.430e-03,\n// 642 7 17\n1955746.133670, 15.0, 4316.6, \" 0.278\", \"-0.665\", 3,\n-13.15488, 1.02275, 0.27867,\n -0.93648, 0.00000, 0.00000, 0.20808, 0.00000, 0.00000, 1.35196,\n 298.5256847, 0.68419, -3.710e-04,\n -22.4424102, 0.06586, 1.438e-03,\n// 642 12 12\n1955893.692338, 5.0, 4312.8, \" 1.357\", \" 0.267\", 2,\n-13.45721, 0.91384, 0.24900,\n -3.00238, -1.39480, 0.00000, -0.38389, 0.00000, 0.62499, 2.23421,\n 82.9568890, 0.54678, 1.390e-04,\n 22.7058506, 0.07133, -9.470e-04,\n// 643 6 8\n1956071.509381, 0.0, 4308.3, \" 2.148\", \" 1.172\", 1,\n -6.77455, 0.98535, 0.26848,\n -2.46049, -1.46292, -0.28025, 0.22514, 0.73121, 1.91403, 2.90948,\n 257.3203829, 0.63036, 7.440e-04,\n -22.7132084, -0.10577, 1.192e-03,\n// 643 12 1\n1956247.898223, 10.0, 4303.8, \" 2.655\", \" 1.620\", 1,\n -9.18225, 0.96173, 0.26205,\n -3.32222, -2.27902, -1.25785, -0.44264, 0.37220, 1.39309, 2.43871,\n 70.7311987, 0.59400, 2.790e-04,\n 22.3333491, 0.12561, -1.136e-03,\n// 644 5 27\n1956425.925888, 10.0, 4299.3, \" 2.129\", \" 1.098\", 1,\n-21.48590, 0.93329, 0.25430,\n -2.65037, -1.52193, -0.18586, 0.22131, 0.62928, 1.96568, 3.09195,\n 246.0922622, 0.55475, 7.390e-04,\n -22.1574905, -0.13390, 8.870e-04,\n// 644 11 19\n1956602.398624, 22.0, 4294.8, \" 1.817\", \" 0.832\", 2,\n-21.88812, 1.01071, 0.27539,\n -2.95756, -1.91049, 0.00000, -0.43302, 0.00000, 1.04367, 2.09234,\n 58.9306126, 0.63638, 6.090e-04,\n 21.1347500, 0.18361, -1.241e-03,\n// 645 5 16\n1956780.048235, 13.0, 4290.3, \" 0.695\", \"-0.373\", 3,\n-19.21642, 0.90141, 0.24561,\n -1.86878, 0.00000, 0.00000, 0.15765, 0.00000, 0.00000, 2.18514,\n 234.7413894, 0.50229, 5.740e-04,\n -20.7441998, -0.15756, 7.140e-04,\n// 645 10 11\n1956927.617943, 3.0, 4286.6, \" 0.191\", \"-0.786\", 3,\n-19.51874, 1.01021, 0.27526,\n -1.14244, 0.00000, 0.00000, -0.16937, 0.00000, 0.00000, 0.80635,\n 19.6928800, 0.55601, 4.840e-04,\n 6.8200301, 0.28414, -2.380e-04,\n// 645 11 9\n1956957.048190, 13.0, 4285.9, \" 0.620\", \"-0.350\", 3,\n -7.58578, 1.02344, 0.27886,\n -1.50530, 0.00000, 0.00000, 0.15656, 0.00000, 0.00000, 1.81944,\n 47.1858701, 0.62921, 9.270e-04,\n 19.0559699, 0.22752, -1.044e-03,\n// 646 4 6\n1957104.502846, 0.0, 4282.1, \" 1.248\", \" 0.204\", 2,\n-10.89632, 0.93030, 0.25349,\n -2.39930, -0.80865, 0.00000, 0.06831, 0.00000, 0.94241, 2.53472,\n 197.2124232, 0.47026, 5.700e-05,\n -6.4773403, -0.24541, 3.050e-04,\n// 646 9 30\n1957282.136076, 15.0, 4277.6, \" 1.395\", \" 0.371\", 2,\n -8.22462, 0.96136, 0.26195,\n -2.20514, -0.84693, 0.00000, 0.26582, 0.00000, 1.38103, 2.73636,\n 9.2132302, 0.49567, 3.410e-04,\n 3.1522501, 0.26882, -2.000e-06,\n// 647 3 26\n1957458.878516, 9.0, 4273.1, \" 2.661\", \" 1.670\", 1,\n -2.61041, 0.98260, 0.26773,\n -2.69850, -1.72756, -0.73811, 0.08438, 0.90654, 1.89574, 2.86866,\n 187.0869000, 0.51648, -8.100e-05,\n -2.9710000, -0.28241, 2.370e-04,\n// 647 9 19\n1957636.368066, 21.0, 4268.6, \" 2.724\", \" 1.650\", 1,\n -2.94692, 0.91392, 0.24902,\n -3.23972, -2.09428, -1.02048, -0.16641, 0.68789, 1.76184, 2.90550,\n 359.0447398, 0.44611, 1.020e-04,\n -0.5019800, 0.24624, 8.100e-05,\n// 648 3 14\n1957813.497468, 0.0, 4264.1, \" 1.711\", \" 0.754\", 2,\n-12.30807, 1.02057, 0.27808,\n -2.50361, -1.47373, 0.00000, -0.06077, 0.00000, 1.35187, 2.38275,\n 177.2745956, 0.55471, -1.080e-04,\n 0.5076400, -0.30546, 2.200e-05,\n// 648 9 7\n1957990.374101, 21.0, 4259.7, \" 1.745\", \" 0.658\", 2,\n -3.68565, 0.90026, 0.24530,\n -2.89949, -1.53486, 0.00000, -0.02158, 0.00000, 1.49147, 2.85708,\n 348.4635200, 0.43624, -1.670e-04,\n -4.3823702, 0.23489, 1.100e-04,\n// 649 2 3\n1958138.762908, 6.0, 4255.9, \" 0.398\", \"-0.595\", 3,\n -8.93596, 0.99433, 0.27093,\n -1.09535, 0.00000, 0.00000, 0.30979, 0.00000, 0.00000, 1.71768,\n 140.4794786, 0.57870, -5.100e-04,\n 16.9584701, -0.23610, -9.050e-04,\n// 649 3 4\n1958168.184427, 16.0, 4255.2, \" 0.434\", \"-0.531\", 3,\n-21.00299, 1.01464, 0.27646,\n -0.99929, 0.00000, 0.00000, 0.42625, 0.00000, 0.00000, 1.85396,\n 167.1236368, 0.55366, -7.300e-05,\n 4.1521800, -0.29483, -2.640e-04,\n// 649 7 29\n1958314.925807, 10.0, 4251.5, \" 0.246\", \"-0.767\", 3,\n-17.36008, 0.95464, 0.26012,\n -0.95555, 0.00000, 0.00000, 0.21936, 0.00000, 0.00000, 1.38947,\n 310.9531592, 0.55338, -9.040e-04,\n -19.6899293, 0.19276, 7.660e-04,\n// 649 8 27\n1958344.449530, 23.0, 4250.7, \" 0.448\", \"-0.602\", 3,\n -2.41890, 0.92896, 0.25312,\n -1.82119, 0.00000, 0.00000, -0.21129, 0.00000, 0.00000, 1.39573,\n 338.0554318, 0.47367, -4.470e-04,\n -7.9473298, 0.23832, 1.810e-04,\n// 650 1 23\n1958493.176815, 16.0, 4247.0, \" 1.621\", \" 0.569\", 2,\n-23.64731, 0.94126, 0.25647,\n -2.42457, -1.12104, 0.00000, 0.24355, 0.00000, 1.61008, 2.91074,\n 129.2580925, 0.53841, -3.920e-04,\n 19.3814899, -0.18406, -8.670e-04,\n// 650 7 18\n1958669.450192, 23.0, 4242.5, \" 1.692\", \" 0.731\", 2,\n -5.06322, 1.00457, 0.27372,\n -2.67057, -1.61346, 0.00000, -0.19539, 0.00000, 1.22135, 2.27974,\n 300.2442969, 0.63054, -9.690e-04,\n -21.3173602, 0.17830, 1.118e-03,\n// 651 1 12\n1958847.281890, 19.0, 4238.0, \" 2.904\", \" 1.806\", 1,\n-21.37782, 0.90359, 0.24621,\n -3.37343, -2.18769, -1.10827, -0.23464, 0.63913, 1.71866, 2.90327,\n 117.5713383, 0.51359, -3.980e-04,\n 21.1705487, -0.13715, -7.960e-04,\n// 651 7 8\n1959024.149075, 16.0, 4233.5, \" 2.613\", \" 1.671\", 1,\n-12.75540, 1.02323, 0.27880,\n -3.05709, -2.17349, -1.22594, -0.42221, 0.38155, 1.32914, 2.21262,\n 289.4623515, 0.67008, -6.580e-04,\n -22.2556984, 0.14275, 1.379e-03,\n// 652 1 1\n1959201.244417, 18.0, 4229.0, \" 1.655\", \" 0.558\", 2,\n-23.11929, 0.90668, 0.24705,\n -2.95452, -1.54067, 0.00000, -0.13398, 0.00000, 1.27170, 2.68711,\n 105.1522581, 0.53147, -4.750e-04,\n 22.2532600, -0.09796, -8.440e-04,\n// 652 6 27\n1959378.831205, 8.0, 4224.5, \" 1.236\", \" 0.270\", 2,\n-21.45032, 0.99598, 0.27138,\n -2.30580, -0.98203, 0.00000, -0.05107, 0.00000, 0.88224, 2.20445,\n 278.1993149, 0.64644, -1.780e-04,\n -22.5265701, 0.08900, 1.323e-03,\n// 652 11 21\n1959525.792405, 7.0, 4220.8, \" 0.102\", \"-0.916\", 3,\n-12.79372, 0.97766, 0.26639,\n -0.73129, 0.00000, 0.00000, 0.01773, 0.00000, 0.00000, 0.76177,\n 60.2255072, 0.62537, 2.900e-05,\n 22.2763597, 0.06516, -1.226e-03,\n// 652 12 20\n1959555.382164, 21.0, 4220.1, \" 0.448\", \"-0.601\", 3,\n-20.84980, 0.94866, 0.25849,\n -1.40466, 0.00000, 0.00000, 0.17195, 0.00000, 0.00000, 1.74502,\n 92.6688238, 0.58999, -4.950e-04,\n 22.3450100, -0.05915, -1.043e-03,\n// 653 5 18\n1959703.802881, 7.0, 4216.4, \" 1.008\", \"-0.037\", 3,\n -1.09737, 0.92084, 0.25091,\n -2.03104, 0.00000, 0.00000, 0.26915, 0.00000, 0.00000, 2.57063,\n 236.7303132, 0.54916, 4.260e-04,\n -21.0485991, -0.06752, 8.610e-04,\n// 653 11 10\n1959880.355575, 21.0, 4211.9, \" 1.399\", \" 0.424\", 2,\n-23.49412, 1.01931, 0.27774,\n -2.77380, -1.58407, 0.00000, -0.46621, 0.00000, 0.65075, 1.84155,\n 49.3441518, 0.65874, 3.090e-04,\n 19.1472093, 0.10851, -1.194e-03,\n// 654 5 7\n1960057.867499, 9.0, 4207.4, \" 2.390\", \" 1.318\", 1,\n-23.83063, 0.89959, 0.24512,\n -3.25814, -2.07167, -0.88167, -0.18003, 0.52162, 1.71166, 2.89814,\n 226.1100657, 0.50887, 2.650e-04,\n -17.7333397, -0.09272, 6.550e-04,\n// 654 10 31\n1960235.013449, 12.0, 4203.0, \" 2.623\", \" 1.649\", 1,\n -9.19178, 1.01771, 0.27730,\n -2.35270, -1.42909, -0.47132, 0.32278, 1.11704, 2.07494, 2.99766,\n 38.2007802, 0.63601, 5.630e-04,\n 15.2755695, 0.14215, -8.680e-04,\n// 655 4 26\n1960411.927366, 10.0, 4198.5, \" 1.996\", \" 0.947\", 2,\n-23.56662, 0.92066, 0.25086,\n -2.62737, -1.43145, 0.00000, 0.25678, 0.00000, 1.94388, 3.14161,\n 215.4115716, 0.51689, 1.080e-04,\n -13.7575702, -0.12317, 5.770e-04,\n// 655 10 21\n1960589.571714, 2.0, 4194.0, \" 1.789\", \" 0.773\", 2,\n-19.89218, 0.97429, 0.26547,\n -2.90679, -1.76678, 0.00000, -0.27887, 0.00000, 1.21051, 2.34805,\n 28.2819197, 0.56834, 5.390e-04,\n 11.0771402, 0.15365, -4.660e-04,\n// 656 3 16\n1960736.836185, 8.0, 4190.3, \" 0.220\", \"-0.760\", 3,\n -4.21641, 0.99673, 0.27158,\n -0.98922, 0.00000, 0.00000, 0.06844, 0.00000, 0.00000, 1.12255,\n 178.3271004, 0.57341, -1.820e-04,\n -0.8236700, -0.19226, 1.130e-04,\n// 656 4 14\n1960766.245234, 18.0, 4189.6, \" 0.649\", \"-0.349\", 3,\n-16.28344, 0.97056, 0.26446,\n -1.91144, 0.00000, 0.00000, -0.11438, 0.00000, 0.00000, 1.67964,\n 205.7087414, 0.55919, 1.700e-05,\n -9.4837996, -0.15833, 5.110e-04,\n// 656 10 9\n1960943.863742, 9.0, 4185.1, \" 0.421\", \"-0.649\", 3,\n-13.61174, 0.92281, 0.25144,\n -1.84980, 0.00000, 0.00000, -0.27020, 0.00000, 0.00000, 1.31233,\n 18.0857194, 0.49927, 3.120e-04,\n 6.3757101, 0.15413, -1.890e-04,\n// 657 3 5\n1961091.490415, 0.0, 4181.4, \" 1.543\", \" 0.586\", 2,\n-12.91133, 1.02402, 0.27902,\n -2.59047, -1.50606, 0.00000, -0.23004, 0.00000, 1.04595, 2.13078,\n 169.1663005, 0.60793, -1.670e-04,\n 3.9300797, -0.19607, -2.120e-04,\n// 657 8 29\n1961268.174322, 16.0, 4176.9, \" 1.289\", \" 0.211\", 2,\n -9.30260, 0.90450, 0.24646,\n -2.40728, -0.73055, 0.00000, 0.18372, 0.00000, 1.09667, 2.77499,\n 339.8486297, 0.48193, -2.450e-04,\n -7.7029499, 0.14470, 2.440e-04,\n// 658 2 23\n1961446.156485, 16.0, 4172.4, \" 2.825\", \" 1.847\", 1,\n-21.60625, 1.00449, 0.27370,\n -2.96479, -2.02993, -1.07439, -0.24435, 0.58591, 1.54163, 2.47489,\n 159.6489509, 0.59474, -8.900e-05,\n 8.6457499, -0.17708, -5.150e-04,\n// 658 8 18\n1961622.323814, 20.0, 4168.0, \" 2.670\", \" 1.639\", 1,\n -6.03037, 0.94288, 0.25691,\n -3.16290, -2.10430, -1.06609, -0.22847, 0.60878, 1.64675, 2.70788,\n 329.9953442, 0.53558, -5.040e-04,\n -12.2312799, 0.14035, 4.610e-04,\n// 659 2 13\n1961800.642736, 3.0, 4163.5, \" 1.534\", \" 0.501\", 2,\n-11.31486, 0.95364, 0.25984,\n -2.15037, -0.85242, 0.00000, 0.42566, 0.00000, 1.70596, 3.00110,\n 149.2750001, 0.55036, -8.900e-05,\n 13.3044794, -0.14253, -6.530e-04,\n// 659 8 8\n1961976.780784, 7.0, 4159.1, \" 1.681\", \" 0.706\", 2,\n-19.73899, 0.99506, 0.27113,\n -2.76282, -1.67317, 0.00000, -0.26118, 0.00000, 1.14926, 2.24059,\n 319.9971220, 0.61283, -6.420e-04,\n -16.3699605, 0.13165, 8.380e-04,\n// 660 1 3\n1962125.050537, 13.0, 4155.3, \" 0.098\", \"-1.006\", 3,\n -3.99751, 0.89977, 0.24517,\n -0.60083, 0.00000, 0.00000, 0.21288, 0.00000, 0.00000, 1.02736,\n 107.1040393, 0.52986, -2.400e-05,\n 21.2825501, -0.01444, -8.280e-04,\n// 660 2 2\n1962154.822981, 8.0, 4154.6, \" 0.174\", \"-0.912\", 3,\n -7.03990, 0.90933, 0.24777,\n -1.30820, 0.00000, 0.00000, -0.24846, 0.00000, 0.00000, 0.81415,\n 138.9156385, 0.51635, -1.920e-04,\n 17.4498407, -0.10898, -6.910e-04,\n// 660 6 28\n1962302.164959, 16.0, 4150.9, \" 0.677\", \"-0.267\", 3,\n-13.35866, 1.01984, 0.27788,\n -1.76242, 0.00000, 0.00000, -0.04100, 0.00000, 0.00000, 1.68121,\n 279.8212936, 0.68229, 1.670e-04,\n -22.1106798, -0.01355, 1.414e-03,\n// 660 7 27\n1962331.451858, 23.0, 4150.2, \" 0.395\", \"-0.550\", 3,\n -4.43391, 1.02331, 0.27882,\n -1.50317, 0.00000, 0.00000, -0.15540, 0.00000, 0.00000, 1.19190,\n 309.7828746, 0.66741, -4.880e-04,\n -19.9760101, 0.10782, 1.244e-03,\n// 660 12 22\n1962479.031782, 13.0, 4146.4, \" 1.347\", \" 0.260\", 2,\n -4.73624, 0.91567, 0.24950,\n -2.84205, -1.23409, 0.00000, -0.23722, 0.00000, 0.75754, 2.36730,\n 95.0005069, 0.55383, -3.800e-05,\n 22.7699212, 0.02883, -9.630e-04,\n// 661 6 18\n1962656.808762, 7.0, 4142.0, \" 2.007\", \" 1.028\", 1,\n-23.05632, 0.98216, 0.26761,\n -2.24752, -1.21889, 0.19836, 0.41029, 0.62311, 2.04054, 3.06702,\n 268.5338869, 0.63520, 5.480e-04,\n -23.1351211, -0.05980, 1.247e-03,\n// 661 12 11\n1962833.254716, 18.0, 4137.6, \" 2.650\", \" 1.618\", 1,\n -0.46128, 0.96456, 0.26282,\n -2.75513, -1.71819, -0.69995, 0.11319, 0.92596, 1.94392, 2.98327,\n 82.5096824, 0.61114, 1.130e-04,\n 23.3092192, 0.08163, -1.219e-03,\n// 662 6 7\n1963011.205199, 17.0, 4133.1, \" 2.282\", \" 1.248\", 1,\n-13.76767, 0.93033, 0.25349,\n -2.99657, -1.88467, -0.69414, -0.07523, 0.54429, 1.73509, 2.84482,\n 257.4781056, 0.56589, 6.110e-04,\n -23.4146193, -0.09393, 9.850e-04,\n// 662 12 1\n1963187.766284, 6.0, 4128.7, \" 1.823\", \" 0.840\", 2,\n-13.16715, 1.01253, 0.27589,\n -2.13097, -1.08872, 0.00000, 0.39083, 0.00000, 1.86962, 2.91333,\n 70.3182660, 0.65984, 5.130e-04,\n 22.9193196, 0.14051, -1.400e-03,\n// 663 5 27\n1963365.314464, 20.0, 4124.2, \" 0.851\", \"-0.217\", 3,\n-11.49818, 0.90070, 0.24542,\n -2.66182, 0.00000, 0.00000, -0.45285, 0.00000, 0.00000, 1.75685,\n 246.0647502, 0.51951, 5.150e-04,\n -22.8112899, -0.12416, 8.330e-04,\n// 663 10 22\n1963512.972888, 11.0, 4120.5, \" 0.159\", \"-0.823\", 3,\n-10.79777, 1.00833, 0.27474,\n -0.54264, 0.00000, 0.00000, 0.34930, 0.00000, 0.00000, 1.24420,\n 29.8358407, 0.56858, 6.660e-04,\n 10.6810797, 0.26523, -4.340e-04,\n// 663 11 20\n1963542.416115, 22.0, 4119.8, \" 0.629\", \"-0.344\", 3,\n-21.86207, 1.02279, 0.27869,\n -1.68669, 0.00000, 0.00000, -0.01324, 0.00000, 0.00000, 1.66128,\n 58.8907858, 0.65469, 9.300e-04,\n 21.7778208, 0.18679, -1.267e-03,\n// 664 4 16\n1963689.796052, 7.0, 4116.0, \" 1.129\", \" 0.091\", 2,\n -3.17809, 0.93314, 0.25426,\n -2.26201, -0.48907, 0.00000, 0.10525, 0.00000, 0.69633, 2.47096,\n 207.1533947, 0.48478, 1.770e-04,\n -10.3309497, -0.23342, 4.490e-04,\n// 664 10 10\n1963867.472665, 23.0, 4111.6, \" 1.350\", \" 0.320\", 2,\n-23.50365, 0.95842, 0.26115,\n -2.11038, -0.69982, 0.00000, 0.34397, 0.00000, 1.39037, 2.79803,\n 19.3551100, 0.50107, 5.060e-04,\n 7.3699696, 0.25777, -1.680e-04,\n// 665 4 5\n1964044.195866, 17.0, 4107.2, \" 2.558\", \" 1.574\", 1,\n-17.88944, 0.98557, 0.26854,\n -3.06062, -2.09457, -1.09323, -0.29921, 0.49445, 1.49551, 2.46346,\n 197.1699531, 0.52734, 1.060e-04,\n -7.2026104, -0.27559, 4.140e-04,\n// 665 9 30\n1964221.681147, 4.0, 4102.7, \" 2.659\", \" 1.580\", 1,\n-19.22869, 0.91205, 0.24851,\n -2.73253, -1.57480, -0.48731, 0.34752, 1.18259, 2.27020, 3.42622,\n 8.8190301, 0.44636, 2.330e-04,\n 3.6880400, 0.24290, -5.100e-05,\n// 666 3 26\n1964398.830282, 8.0, 4098.3, \" 1.795\", \" 0.842\", 2,\n -3.58710, 1.02144, 0.27832,\n -2.54417, -1.54312, 0.00000, -0.07324, 0.00000, 1.39646, 2.39838,\n 187.1582072, 0.55765, 1.240e-04,\n -3.7502900, -0.30437, 2.160e-04,\n// 666 9 19\n1964575.675737, 4.0, 4093.9, \" 1.831\", \" 0.742\", 2,\n-19.96742, 0.90078, 0.24544,\n -2.69956, -1.36497, 0.00000, 0.21769, 0.00000, 1.80008, 3.13577,\n 358.3054128, 0.43347, -4.500e-05,\n -0.1801400, 0.23897, -1.700e-05,\n// 667 2 14\n1964724.110256, 15.0, 4090.1, \" 0.351\", \"-0.642\", 3,\n-23.21225, 0.99161, 0.27019,\n -1.68242, 0.00000, 0.00000, -0.35386, 0.00000, 0.00000, 0.97773,\n 151.6085069, 0.55401, -3.770e-04,\n 13.1618608, -0.26003, -6.940e-04,\n// 667 3 16\n1964753.521066, 1.0, 4089.4, \" 0.501\", \"-0.463\", 3,\n-11.27928, 1.01273, 0.27594,\n -2.01818, 0.00000, 0.00000, -0.49441, 0.00000, 0.00000, 1.03159,\n 177.5744682, 0.54732, 1.570e-04,\n -0.3720400, -0.29963, -5.800e-05,\n// 667 8 9\n1964900.228370, 17.0, 4085.7, \" 0.141\", \"-0.872\", 3,\n -9.64185, 0.95794, 0.26102,\n -0.41303, 0.00000, 0.00000, 0.48089, 0.00000, 0.00000, 1.36955,\n 321.4871961, 0.53651, -8.560e-04,\n -16.7437187, 0.22153, 5.980e-04,\n// 667 9 8\n1964929.757756, 6.0, 4085.0, \" 0.544\", \"-0.506\", 3,\n-18.70067, 0.93166, 0.25386,\n -1.56608, 0.00000, 0.00000, 0.18615, 0.00000, 0.00000, 1.93589,\n 347.8696214, 0.46774, -3.170e-04,\n -3.9734899, 0.25009, 3.800e-05,\n// 668 2 4\n1965078.513973, 0.0, 4081.2, \" 1.584\", \" 0.532\", 2,\n-14.92633, 0.93852, 0.25572,\n -2.32199, -0.99544, 0.00000, 0.33535, 0.00000, 1.66815, 2.99179,\n 140.3549916, 0.51430, -3.520e-04,\n 16.2980898, -0.21154, -7.060e-04,\n// 668 7 29\n1965254.764433, 6.0, 4076.8, \" 1.576\", \" 0.615\", 2,\n-21.34498, 1.00702, 0.27439,\n -2.07121, -0.97626, 0.00000, 0.34639, 0.00000, 1.66760, 2.76367,\n 310.8545313, 0.61167, -9.770e-04,\n -19.0312600, 0.21530, 9.420e-04,\n// 669 1 23\n1965432.609415, 3.0, 4072.4, \" 2.881\", \" 1.784\", 1,\n-12.65685, 0.90264, 0.24595,\n -3.51502, -2.32929, -1.24861, -0.37405, 0.50064, 1.58142, 2.76611,\n 129.1552435, 0.49342, -4.280e-04,\n 18.7213504, -0.16958, -6.690e-04,\n// 669 7 18\n1965609.464256, 23.0, 4068.0, \" 2.740\", \" 1.796\", 1,\n -5.03717, 1.02290, 0.27871,\n -2.50148, -1.61878, -0.68175, 0.14215, 0.96609, 1.90316, 2.78562,\n 300.2379585, 0.65016, -7.480e-04,\n -20.6474809, 0.18521, 1.230e-03,\n// 670 1 12\n1965786.577558, 2.0, 4063.6, \" 1.674\", \" 0.581\", 2,\n-14.39832, 0.90805, 0.24742,\n -2.96204, -1.56622, 0.00000, -0.13862, 0.00000, 1.28796, 2.68549,\n 117.0012907, 0.51748, -5.730e-04,\n 20.6573795, -0.13638, -7.420e-04,\n// 670 7 8\n1965964.135400, 15.0, 4059.1, \" 1.367\", \" 0.397\", 2,\n-13.73209, 0.99311, 0.27060,\n -2.09515, -0.86163, 0.00000, 0.24959, 0.00000, 1.36301, 2.59495,\n 289.2595222, 0.62961, -3.390e-04,\n -21.6356795, 0.13306, 1.236e-03,\n// 670 12 2\n1966111.152233, 16.0, 4055.5, \" 0.104\", \"-0.911\", 3,\n -3.07001, 0.98044, 0.26714,\n -1.10230, 0.00000, 0.00000, -0.34641, 0.00000, 0.00000, 0.40458,\n 72.4855738, 0.64094, -1.720e-04,\n 24.0904802, 0.01910, -1.345e-03,\n// 671 1 1\n1966140.732729, 6.0, 4054.7, \" 0.461\", \"-0.584\", 3,\n-11.12609, 0.95142, 0.25924,\n -2.00542, 0.00000, 0.00000, -0.41450, 0.00000, 0.00000, 1.17301,\n 105.0493954, 0.58242, -6.720e-04,\n 21.6095198, -0.10605, -9.680e-04,\n// 671 5 29\n1966289.078678, 14.0, 4051.0, \" 0.854\", \"-0.193\", 3,\n-17.37914, 0.91839, 0.25024,\n -2.26975, 0.00000, 0.00000, -0.11174, 0.00000, 0.00000, 2.04786,\n 247.9844432, 0.55802, 2.990e-04,\n -23.0755107, -0.03103, 9.710e-04,\n// 671 11 22\n1966465.722787, 5.0, 4046.6, \" 1.392\", \" 0.418\", 2,\n-14.77314, 1.02052, 0.27807,\n -1.95434, -0.76183, 0.00000, 0.34690, 0.00000, 1.45481, 2.64822,\n 60.4195597, 0.67746, 2.110e-04,\n 21.6538392, 0.06813, -1.385e-03,\n// 672 5 17\n1966643.135614, 15.0, 4042.2, \" 2.234\", \" 1.164\", 1,\n-17.11513, 0.89968, 0.24514,\n -2.78725, -1.58090, -0.27783, 0.25473, 0.78726, 2.09035, 3.29687,\n 236.5677547, 0.52207, 2.060e-04,\n -20.3816789, -0.06410, 7.780e-04,\n// 672 11 10\n1966820.377370, 21.0, 4037.8, \" 2.610\", \" 1.633\", 1,\n-23.46807, 1.01636, 0.27693,\n -2.62342, -1.69480, -0.73332, 0.05688, 0.84725, 1.80886, 2.73649,\n 49.5391708, 0.65300, 5.530e-04,\n 18.5327706, 0.10653, -1.098e-03,\n// 673 5 6\n1966997.209121, 17.0, 4033.4, \" 2.135\", \" 1.091\", 1,\n-15.84838, 0.92319, 0.25155,\n -2.89631, -1.74007, -0.37837, 0.01890, 0.41546, 1.77689, 2.93509,\n 225.8850519, 0.53371, 1.030e-04,\n -17.0339112, -0.09841, 7.290e-04,\n// 673 10 31\n1967174.920911, 10.0, 4028.9, \" 1.812\", \" 0.791\", 2,\n-11.17120, 0.97145, 0.26470,\n -2.54627, -1.40223, 0.00000, 0.10188, 0.00000, 1.60746, 2.74901,\n 38.7945524, 0.57951, 5.900e-04,\n 14.7337306, 0.12870, -6.650e-04,\n// 674 3 27\n1967322.161613, 16.0, 4025.3, \" 0.139\", \"-0.835\", 3,\n-19.49543, 0.99928, 0.27228,\n -0.96625, 0.00000, 0.00000, -0.12129, 0.00000, 0.00000, 0.71991,\n 188.2645066, 0.57930, -3.000e-05,\n -5.1855898, -0.19079, 3.320e-04,\n// 674 4 26\n1967351.549709, 1.0, 4024.5, \" 0.771\", \"-0.221\", 3,\n -8.56521, 0.97381, 0.26534,\n -1.73291, 0.00000, 0.00000, 0.19302, 0.00000, 0.00000, 2.11644,\n 215.6158489, 0.57600, 7.800e-05,\n -13.1265094, -0.13824, 6.980e-04,\n// 674 10 20\n1967529.192099, 17.0, 4020.1, \" 0.455\", \"-0.620\", 3,\n -4.89077, 0.92059, 0.25084,\n -2.03323, 0.00000, 0.00000, -0.38962, 0.00000, 0.00000, 1.25669,\n 28.5074508, 0.50680, 3.840e-04,\n 10.4614695, 0.13800, -3.560e-04,\n// 675 3 17\n1967676.827730, 8.0, 4016.4, \" 1.466\", \" 0.513\", 2,\n -4.19036, 1.02405, 0.27903,\n -2.45479, -1.34129, 0.00000, -0.13448, 0.00000, 1.07241, 2.18624,\n 179.0029203, 0.60499, 5.000e-06,\n -0.3852600, -0.20081, 2.500e-05,\n// 675 9 9\n1967853.472944, 23.0, 4012.0, \" 1.200\", \" 0.120\", 2,\n -1.58436, 0.90575, 0.24680,\n -2.17209, -0.34866, 0.00000, 0.35065, 0.00000, 1.04833, 2.87353,\n 349.7210944, 0.47692, -1.680e-04,\n -3.5345599, 0.15454, 9.300e-05,\n// 676 3 5\n1968031.495912, 0.0, 4007.6, \" 2.762\", \" 1.785\", 1,\n-12.88528, 1.00203, 0.27303,\n -2.82332, -1.88635, -0.92667, -0.09811, 0.73070, 1.69058, 2.62587,\n 169.6481566, 0.58321, 4.700e-05,\n 4.4466201, -0.18788, -2.930e-04,\n// 676 8 29\n1968207.632526, 3.0, 4003.2, \" 2.573\", \" 1.542\", 1,\n-22.31214, 0.94595, 0.25775,\n -2.73535, -1.67558, -0.62338, 0.18061, 0.98420, 2.03616, 3.09852,\n 339.8947745, 0.52794, -4.330e-04,\n -8.3679106, 0.15777, 2.840e-04,\n// 677 2 23\n1968385.973834, 11.0, 3998.8, \" 1.583\", \" 0.550\", 2,\n -2.59389, 0.95062, 0.25902,\n -2.23782, -0.96062, 0.00000, 0.37201, 0.00000, 1.70672, 2.98110,\n 159.6955738, 0.53427, -1.800e-05,\n 9.3221794, -0.15938, -4.660e-04,\n// 677 8 18\n1968562.100605, 14.0, 3994.4, \" 1.786\", \" 0.812\", 2,\n-12.02075, 0.99788, 0.27190,\n -2.12323, -1.06855, 0.00000, 0.41453, 0.00000, 1.89626, 2.95253,\n 329.9652094, 0.60071, -5.920e-04,\n -12.9259503, 0.15717, 6.310e-04,\n// 678 1 13\n1968710.380841, 21.0, 3990.7, \" 0.076\", \"-1.027\", 3,\n-19.27653, 0.89951, 0.24510,\n -0.57864, 0.00000, 0.00000, 0.14019, 0.00000, 0.00000, 0.85954,\n 118.8755766, 0.52083, -1.500e-04,\n 19.5274596, -0.05214, -7.460e-04,\n// 678 2 12\n1968740.143847, 15.0, 3990.0, \" 0.215\", \"-0.870\", 3,\n-23.32167, 0.90782, 0.24736,\n -0.72208, 0.00000, 0.00000, 0.45233, 0.00000, 0.00000, 1.62924,\n 149.3503234, 0.50018, -1.780e-04,\n 13.9480804, -0.13046, -5.390e-04,\n// 678 7 9\n1968887.476088, 23.0, 3986.3, \" 0.547\", \"-0.400\", 3,\n -5.64042, 1.01864, 0.27755,\n -1.14338, 0.00000, 0.00000, 0.42612, 0.00000, 0.00000, 1.99681,\n 290.6901190, 0.67437, -3.000e-05,\n -20.9391197, 0.03316, 1.330e-03,\n// 678 8 8\n1968916.773036, 7.0, 3985.6, \" 0.505\", \"-0.442\", 3,\n-19.71294, 1.02370, 0.27893,\n -1.95582, 0.00000, 0.00000, -0.44714, 0.00000, 0.00000, 1.06119,\n 320.6561806, 0.64872, -5.060e-04,\n -16.8727802, 0.14254, 1.017e-03,\n// 679 1 2\n1969064.371526, 21.0, 3981.9, \" 1.337\", \" 0.253\", 2,\n-20.01526, 0.91759, 0.25002,\n -2.67336, -1.06611, 0.00000, -0.08339, 0.00000, 0.89714, 2.50637,\n 106.9651201, 0.55346, -2.140e-04,\n 21.9081186, -0.01328, -9.210e-04,\n// 679 6 29\n1969242.107715, 15.0, 3977.5, \" 1.867\", \" 0.884\", 2,\n-14.33535, 0.97892, 0.26673,\n -3.03759, -1.96987, 0.00000, -0.41483, 0.00000, 1.14156, 2.20713,\n 280.3987998, 0.63297, 3.170e-04,\n -22.7620596, -0.01130, 1.242e-03,\n// 679 12 23\n1969418.611408, 3.0, 3973.1, \" 2.644\", \" 1.616\", 1,\n-14.73756, 0.96739, 0.26359,\n -3.18277, -2.15268, -1.13732, -0.32622, 0.48452, 1.49962, 2.53209,\n 94.9895308, 0.62043, -1.130e-04,\n 23.4270895, 0.03270, -1.239e-03,\n// 680 6 17\n1969596.484180, 0.0, 3968.7, \" 2.434\", \" 1.397\", 1,\n -6.04943, 0.92749, 0.25272,\n -3.34204, -2.23992, -1.12284, -0.37968, 0.36394, 1.48127, 2.58124,\n 269.0224367, 0.57079, 4.310e-04,\n -23.8476994, -0.05181, 1.033e-03,\n// 680 12 11\n1969773.134774, 15.0, 3964.3, \" 1.827\", \" 0.845\", 2,\n -3.44344, 1.01421, 0.27635,\n -2.28380, -1.24622, 0.00000, 0.23458, 0.00000, 1.71466, 2.75353,\n 82.6029896, 0.67784, 3.060e-04,\n 23.9839497, 0.08948, -1.511e-03,\n// 681 6 7\n1969950.580073, 2.0, 3959.9, \" 1.009\", \"-0.060\", 3,\n -4.78269, 0.90017, 0.24528,\n -2.44624, 0.00000, 0.00000, -0.07824, 0.00000, 0.00000, 2.29022,\n 257.1335635, 0.53213, 3.960e-04,\n -24.0071399, -0.08850, 9.140e-04,\n// 681 11 1\n1970098.330868, 20.0, 3956.2, \" 0.133\", \"-0.853\", 3,\n -1.07406, 1.00634, 0.27420,\n -0.88005, 0.00000, 0.00000, -0.05916, 0.00000, 0.00000, 0.76496,\n 40.8300717, 0.58695, 8.070e-04,\n 14.3959607, 0.23786, -6.490e-04,\n// 681 12 1\n1970127.785076, 7.0, 3955.5, \" 0.634\", \"-0.340\", 3,\n-12.13836, 1.02199, 0.27847,\n -1.83981, 0.00000, 0.00000, -0.15817, 0.00000, 0.00000, 1.52455,\n 70.9651805, 0.67673, 8.130e-04,\n 23.6961409, 0.13896, -1.453e-03,\n// 682 4 27\n1970275.086656, 14.0, 3951.9, \" 1.003\", \"-0.029\", 3,\n-19.45985, 0.93609, 0.25506,\n -2.17202, 0.00000, 0.00000, 0.07975, 0.00000, 0.00000, 2.32961,\n 217.3290652, 0.50363, 2.700e-04,\n -13.8396298, -0.21523, 5.970e-04,\n// 682 10 22\n1970452.813255, 8.0, 3947.4, \" 1.314\", \" 0.278\", 2,\n-13.77994, 0.95551, 0.26035,\n -2.92419, -1.46432, 0.00000, -0.48188, 0.00000, 0.50332, 1.96027,\n 30.2129183, 0.51320, 6.560e-04,\n 11.5688105, 0.23943, -3.490e-04,\n// 683 4 17\n1970629.508454, 0.0, 3943.0, \" 2.444\", \" 1.465\", 1,\n-10.17120, 0.98853, 0.26935,\n -2.53244, -1.56804, -0.54346, 0.20290, 0.94884, 1.97313, 2.93933,\n 206.8943940, 0.54378, 2.670e-04,\n -10.9414704, -0.26273, 5.850e-04,\n// 683 10 11\n1970807.000183, 12.0, 3938.7, \" 2.607\", \" 1.523\", 1,\n-10.50771, 0.91033, 0.24804,\n -3.08135, -1.91182, -0.80996, 0.00439, 0.81898, 1.92094, 3.08883,\n 19.1429797, 0.45276, 3.650e-04,\n 8.0011500, 0.23360, -1.920e-04,\n// 684 4 5\n1970984.157633, 16.0, 3934.3, \" 1.892\", \" 0.942\", 2,\n-18.86613, 1.02216, 0.27851,\n -2.71774, -1.74400, 0.00000, -0.21680, 0.00000, 1.31031, 2.28478,\n 197.1369360, 0.56737, 3.480e-04,\n -7.9176902, -0.29589, 4.150e-04,\n// 684 9 29\n1971160.984252, 12.0, 3929.9, \" 1.903\", \" 0.812\", 2,\n-11.24644, 0.90145, 0.24563,\n -3.32474, -2.01178, 0.00000, -0.37795, 0.00000, 1.25556, 2.56973,\n 8.5648301, 0.43641, 8.800e-05,\n 4.2764502, 0.23726, -1.500e-04,\n// 685 2 24\n1971309.450953, 23.0, 3926.3, \" 0.291\", \"-0.702\", 3,\n-14.49127, 0.98877, 0.26941,\n -1.39554, 0.00000, 0.00000, -0.17713, 0.00000, 0.00000, 1.04470,\n 161.8775597, 0.53521, -2.070e-04,\n 9.2199895, -0.27460, -5.040e-04,\n// 685 3 26\n1971338.851623, 8.0, 3925.5, \" 0.581\", \"-0.383\", 3,\n -3.56105, 1.01066, 0.27538,\n -1.19116, 0.00000, 0.00000, 0.43894, 0.00000, 0.00000, 2.07125,\n 186.9314859, 0.54713, 3.690e-04,\n -4.3430599, -0.29695, 1.150e-04,\n// 685 8 20\n1971485.537605, 1.0, 3921.9, \" 0.048\", \"-0.964\", 3,\n -0.92087, 0.96122, 0.26191,\n -0.62188, 0.00000, 0.00000, -0.09748, 0.00000, 0.00000, 0.42129,\n 332.1872065, 0.52043, -7.440e-04,\n -13.0931200, 0.24504, 4.160e-04,\n// 685 9 18\n1971515.073611, 14.0, 3921.2, \" 0.625\", \"-0.425\", 3,\n -9.97969, 0.93439, 0.25460,\n -2.09175, 0.00000, 0.00000, -0.23335, 0.00000, 0.00000, 1.62288,\n 358.0199109, 0.46681, -1.640e-04,\n 0.3957900, 0.25594, -1.120e-04,\n// 686 2 14\n1971663.844369, 8.0, 3917.5, \" 1.534\", \" 0.481\", 2,\n -6.20536, 0.93579, 0.25498,\n -2.37326, -1.01501, 0.00000, 0.26486, 0.00000, 1.54683, 2.90215,\n 151.1039062, 0.49292, -2.580e-04,\n 12.6729405, -0.23203, -5.440e-04,\n// 686 8 9\n1971840.082696, 14.0, 3913.1, \" 1.468\", \" 0.507\", 2,\n-12.62401, 1.00934, 0.27502,\n -2.37412, -1.23373, 0.00000, -0.01529, 0.00000, 1.20163, 2.34300,\n 321.7209252, 0.59078, -8.980e-04,\n -15.9413200, 0.24761, 7.340e-04,\n// 687 2 3\n1972017.931697, 10.0, 3908.7, \" 2.839\", \" 1.744\", 1,\n -4.93861, 0.90181, 0.24572,\n -2.78067, -1.59570, -0.51286, 0.36073, 1.23444, 2.31735, 3.50139,\n 139.8971367, 0.47407, -4.010e-04,\n 15.7775304, -0.19490, -5.360e-04,\n// 687 7 30\n1972194.782214, 7.0, 3904.3, \" 2.801\", \" 1.855\", 1,\n-20.31619, 1.02241, 0.27858,\n -2.87509, -1.98983, -1.05408, -0.22687, 0.60038, 1.53617, 2.42106,\n 311.3668775, 0.62582, -7.480e-04,\n -18.1650503, 0.22401, 1.032e-03,\n// 688 1 23\n1972371.907265, 10.0, 3900.0, \" 1.702\", \" 0.613\", 2,\n -5.67734, 0.90956, 0.24783,\n -3.05487, -1.68191, 0.00000, -0.22564, 0.00000, 1.22960, 2.60440,\n 128.5366606, 0.50031, -6.030e-04,\n 18.2532605, -0.17014, -6.110e-04,\n// 688 7 18\n1972549.441400, 23.0, 3895.6, \" 1.493\", \" 0.518\", 2,\n -5.01111, 0.99018, 0.26980,\n -2.83076, -1.65711, 0.00000, -0.40639, 0.00000, 0.84634, 2.01840,\n 300.7442121, 0.60681, -4.310e-04,\n -19.8247299, 0.17492, 1.093e-03,\n// 688 12 13\n1972696.514045, 0.0, 3891.9, \" 0.109\", \"-0.904\", 3,\n-18.34903, 0.98315, 0.26788,\n -0.43149, 0.00000, 0.00000, 0.33708, 0.00000, 0.00000, 1.10084,\n 84.3382879, 0.64903, -4.160e-04,\n 24.9946897, -0.02856, -1.397e-03,\n// 689 1 11\n1972726.082396, 14.0, 3891.2, \" 0.477\", \"-0.563\", 3,\n -2.40512, 0.95422, 0.26000,\n -1.63258, 0.00000, 0.00000, -0.02250, 0.00000, 0.00000, 1.58430,\n 116.6471864, 0.56967, -7.790e-04,\n 20.0737211, -0.14804, -8.490e-04,\n// 689 6 8\n1972874.351837, 20.0, 3887.6, \" 0.697\", \"-0.353\", 3,\n-10.66364, 0.91606, 0.24960,\n -1.54235, 0.00000, 0.00000, 0.44408, 0.00000, 0.00000, 2.43239,\n 258.9606938, 0.56134, 1.320e-04,\n -24.3279488, 0.00674, 1.035e-03,\n// 689 7 8\n1972903.878233, 9.0, 3886.9, \" 0.016\", \"-1.011\", 3,\n-19.72246, 0.93784, 0.25554,\n -0.23565, 0.00000, 0.00000, 0.07758, 0.00000, 0.00000, 0.39641,\n 289.3657726, 0.56009, -2.200e-04,\n -20.9459806, 0.11778, 9.590e-04,\n// 689 12 2\n1973051.092342, 14.0, 3883.2, \" 1.390\", \" 0.415\", 2,\n -5.04943, 1.02157, 0.27835,\n -2.08121, -0.88868, 0.00000, 0.21621, 0.00000, 1.32036, 2.51359,\n 72.5013174, 0.69140, -1.000e-06,\n 23.4527403, 0.01869, -1.526e-03,\n// 690 5 28\n1973228.401456, 22.0, 3878.9, \" 2.074\", \" 1.005\", 1,\n -9.39689, 0.89995, 0.24522,\n -3.35924, -2.12408, -0.46269, -0.36505, -0.26752, 1.39386, 2.62933,\n 247.8755153, 0.53331, 9.000e-05,\n -22.4286405, -0.02924, 8.770e-04,\n// 690 11 22\n1973405.743955, 6.0, 3874.5, \" 2.604\", \" 1.624\", 1,\n-13.74436, 1.01488, 0.27653,\n -2.83076, -1.89760, -0.93323, -0.14508, 0.64326, 1.60775, 2.53982,\n 61.2634091, 0.66808, 4.440e-04,\n 21.0957598, 0.06333, -1.293e-03,\n// 691 5 17\n1973582.488824, 0.0, 3870.1, \" 2.281\", \" 1.241\", 1,\n -8.13015, 0.92586, 0.25228,\n -3.20761, -2.08413, -0.88272, -0.26823, 0.34568, 1.54684, 2.67241,\n 236.6910806, 0.55055, 4.200e-05,\n -19.7434592, -0.06757, 8.640e-04,\n// 691 11 11\n1973760.273381, 19.0, 3865.7, \" 1.826\", \" 0.800\", 2,\n -1.44749, 0.96861, 0.26392,\n -3.10342, -1.95326, 0.00000, -0.43884, 0.00000, 1.07707, 2.22474,\n 50.2444117, 0.59299, 5.730e-04,\n 17.9792316, 0.09526, -8.600e-04,\n// 692 4 6\n1973907.483412, 0.0, 3862.1, \" 0.050\", \"-0.919\", 3,\n-10.77446, 1.00177, 0.27296,\n -0.90771, 0.00000, 0.00000, -0.39810, 0.00000, 0.00000, 0.10753,\n 198.3165779, 0.59083, 1.090e-04,\n -9.4379904, -0.18160, 5.560e-04,\n// 692 5 6\n1973936.852692, 8.0, 3861.4, \" 0.898\", \"-0.089\", 3,\n -0.84697, 0.97704, 0.26622,\n -1.57796, 0.00000, 0.00000, 0.46461, 0.00000, 0.00000, 2.50520,\n 225.8014094, 0.59491, 8.800e-05,\n -16.3437189, -0.11134, 8.800e-04,\n// 692 10 31\n1974114.523435, 1.0, 3857.0, \" 0.482\", \"-0.598\", 3,\n-20.16979, 0.91848, 0.25026,\n -2.13071, 0.00000, 0.00000, -0.43756, 0.00000, 0.00000, 1.25811,\n 39.2144315, 0.51744, 4.170e-04,\n 14.1575700, 0.11530, -5.190e-04,\n// 693 3 27\n1974262.161075, 16.0, 3853.4, \" 1.380\", \" 0.430\", 2,\n-19.46938, 1.02392, 0.27899,\n -2.40733, -1.25339, 0.00000, -0.13420, 0.00000, 0.98515, 2.13933,\n 188.8473403, 0.60787, 1.780e-04,\n -4.7153099, -0.19772, 2.630e-04,\n// 693 9 20\n1974438.778256, 7.0, 3849.1, \" 1.126\", \" 0.044\", 2,\n-16.86339, 0.90713, 0.24717,\n -2.78190, -0.74803, 0.00000, -0.32185, 0.00000, 0.10239, 2.13817,\n 359.9574170, 0.47632, -7.500e-05,\n 0.9174800, 0.15831, -6.400e-05,\n// 694 3 17\n1974616.829161, 8.0, 3844.7, \" 2.686\", \" 1.710\", 1,\n -4.16430, 0.99943, 0.27232,\n -2.82861, -1.88821, -0.92066, -0.10013, 0.72067, 1.68844, 2.62711,\n 179.5517670, 0.57716, 1.990e-04,\n 0.1074600, -0.19101, -7.200e-05,\n// 694 9 9\n1974792.948029, 11.0, 3840.3, \" 2.489\", \" 1.459\", 1,\n-13.59116, 0.94903, 0.25859,\n -3.14355, -2.08147, -1.01088, -0.24731, 0.51580, 1.58617, 2.65088,\n 350.0934490, 0.52359, -3.320e-04,\n -4.0981596, 0.16919, 9.900e-05,\n// 695 3 6\n1974971.297220, 19.0, 3836.0, \" 1.647\", \" 0.614\", 2,\n-17.87292, 0.94759, 0.25820,\n -2.51687, -1.26496, 0.00000, 0.13327, 0.00000, 1.53341, 2.78250,\n 169.9015293, 0.52271, 8.200e-05,\n 5.0609900, -0.16892, -2.810e-04,\n// 695 8 29\n1975147.426921, 22.0, 3831.6, \" 1.879\", \" 0.904\", 2,\n -3.29978, 1.00057, 0.27263,\n -2.31897, -1.28993, 0.00000, 0.24611, 0.00000, 1.78098, 2.81152,\n 340.2219678, 0.59034, -4.900e-04,\n -8.9629405, 0.17684, 4.080e-04,\n// 696 1 25\n1975295.705606, 5.0, 3828.0, \" 0.043\", \"-1.057\", 3,\n-10.55556, 0.89937, 0.24506,\n -0.60849, 0.00000, 0.00000, -0.06547, 0.00000, 0.00000, 0.47781,\n 130.3332053, 0.50822, -2.220e-04,\n 16.9798998, -0.08515, -6.300e-04,\n// 696 2 23\n1975325.456804, 23.0, 3827.3, \" 0.271\", \"-0.812\", 3,\n-14.60069, 0.90641, 0.24698,\n -1.35132, 0.00000, 0.00000, -0.03670, 0.00000, 0.00000, 1.28002,\n 159.9730981, 0.48657, -1.230e-04,\n 9.9082703, -0.14641, -3.790e-04,\n// 696 7 20\n1975472.790550, 7.0, 3823.6, \" 0.425\", \"-0.524\", 3,\n-20.91945, 1.01729, 0.27719,\n -1.42940, 0.00000, 0.00000, -0.02680, 0.00000, 0.00000, 1.37740,\n 301.9936723, 0.66021, -1.810e-04,\n -18.9782099, 0.07822, 1.184e-03,\n// 696 8 18\n1975502.099931, 14.0, 3822.9, \" 0.603\", \"-0.346\", 3,\n-11.99470, 1.02392, 0.27899,\n -1.23526, 0.00000, 0.00000, 0.39835, 0.00000, 0.00000, 2.03172,\n 330.5219517, 0.63205, -4.380e-04,\n -13.4333804, 0.16777, 7.900e-04,\n// 697 1 13\n1975649.708425, 5.0, 3819.3, \" 1.319\", \" 0.241\", 2,\n-11.29429, 0.91962, 0.25057,\n -2.56749, -0.95481, 0.00000, 0.00220, 0.00000, 0.95691, 2.57172,\n 118.7056142, 0.54677, -3.520e-04,\n 20.1698201, -0.05270, -8.280e-04,\n// 697 7 9\n1975827.406894, 22.0, 3815.0, \" 1.730\", \" 0.742\", 2,\n -6.61711, 0.97567, 0.26585,\n -2.81521, -1.69882, 0.00000, -0.23456, 0.00000, 1.23138, 2.34564,\n 291.5080205, 0.62246, 1.260e-04,\n -21.5384603, 0.03233, 1.168e-03,\n// 698 1 2\n1976003.967274, 11.0, 3810.6, \" 2.635\", \" 1.611\", 1,\n -6.01659, 0.97020, 0.26436,\n -2.62958, -1.60678, -0.59387, 0.21459, 1.02268, 2.03535, 3.06049,\n 106.7751452, 0.62116, -3.260e-04,\n 22.5699401, -0.01355, -1.187e-03,\n// 698 6 29\n1976181.761818, 6.0, 3806.3, \" 2.588\", \" 1.547\", 1,\n-23.33393, 0.92474, 0.25197,\n -2.71169, -1.61354, -0.53767, 0.28364, 1.10529, 2.18139, 3.27743,\n 280.0139596, 0.56796, 2.440e-04,\n -23.4183503, -0.01172, 1.023e-03,\n// 698 12 23\n1976358.503331, 0.0, 3801.9, \" 1.832\", \" 0.852\", 2,\n-17.71973, 1.01576, 0.27677,\n -2.43513, -1.40287, 0.00000, 0.07994, 0.00000, 1.56206, 2.59545,\n 94.9957873, 0.68626, 3.500e-05,\n 24.0827194, 0.03577, -1.540e-03,\n// 699 6 18\n1976535.844169, 8.0, 3797.6, \" 1.171\", \" 0.102\", 2,\n-22.06719, 0.89981, 0.24518,\n -2.24893, -0.38786, 0.00000, 0.26005, 0.00000, 0.90826, 2.76927,\n 268.3431334, 0.53936, 2.340e-04,\n -24.4275210, -0.05060, 9.550e-04,\n// 699 11 13\n1976683.692989, 5.0, 3794.0, \" 0.116\", \"-0.873\", 3,\n-15.35035, 1.00428, 0.27364,\n -1.13895, 0.00000, 0.00000, -0.36827, 0.00000, 0.00000, 0.40589,\n 52.1780827, 0.60773, 8.740e-04,\n 17.5293202, 0.20272, -8.600e-04,\n// 699 12 12\n1976713.155402, 16.0, 3793.3, \" 0.636\", \"-0.339\", 3,\n -2.41465, 1.02104, 0.27821,\n -1.95572, 0.00000, 0.00000, -0.27036, 0.00000, 0.00000, 1.41608,\n 83.3028518, 0.69133, 5.850e-04,\n 24.7047908, 0.08613, -1.571e-03,\n// 700 5 7\n1976860.374561, 21.0, 3789.6, \" 0.871\", \"-0.156\", 3,\n-11.74162, 0.93914, 0.25589,\n -2.12807, 0.00000, 0.00000, -0.01055, 0.00000, 0.00000, 2.10465,\n 227.7946635, 0.52536, 3.210e-04,\n -16.8817602, -0.19074, 7.450e-04,\n// 700 11 1\n1977038.157543, 16.0, 3785.3, \" 1.287\", \" 0.246\", 2,\n -5.05896, 0.95267, 0.25958,\n -2.65411, -1.15014, 0.00000, -0.21897, 0.00000, 0.71507, 2.21611,\n 40.8637377, 0.52835, 7.570e-04,\n 15.1071593, 0.21485, -5.220e-04\n));\n}", "title": "" }, { "docid": "f94b7d3db0b5d52b23a5b420270fb8f5", "score": "0.5439239", "text": "function evaluateFormula(formula) {\n // eg: ( 2 * A1 )\n // split - [(, 2, *, A1, )]\n // DB -> get value of A1\n // replace - [(, 2, *, 10, )]\n // (2 * 10)\n // get result from it\n // return 20 (use of eval function or we can use infix evaluation)\n // usage of eval function is not good as any script can be run through it\n\n let tokens = formula.split(\" \");\n tokens.forEach(function(token) {\n let char = token.charCodeAt(0);\n if(char >= 65 && char <= 90) {\n let { rowId, colId } = getRowColIdFromAddress(token);\n let cellObject = sheetDB[rowId][colId];\n let { value } = cellObject;\n formula = formula.replace(token, value);\n }\n });\n\n // need to use infix evaluation\n let evaledRes = eval(formula);\n return evaledRes;\n}", "title": "" }, { "docid": "fd3ec7f237d95930636d756f6e5b0a0f", "score": "0.5390543", "text": "function maketable() {\nvar horz1 = Number(document.getElementById(\"start_horizontal1\").value);\nvar horz2 = Number(document.getElementById(\"end_horizontal2\").value);\nvar vertical1 = Number(document.getElementById(\"start_vertical1\").value);\nvar vertical2 = Number(document.getElementById(\"end_vertical2\").value);\n\n//this hadles error and checks if row and horizonatal 1 values are less than their end values\n//this will create multiplication table using the logic written below according to the needs of the user\n var tableresult=\"<tr><th> </th>\";\n for(var m = horz1; m <= horz2; m++){\n tableresult += \"<th>\" + m + \"</th>\";\n}\n tableresult += \"</tr>\";\nfor(var n = vertical1; n <= vertical2; n++) {\n tableresult += \"<tr><th>\" + n + \"</th>\";\n for(var p = horz1; p <= horz2; p++) {\n tableresult += \"<td>\" + n*p + \"</td>\";\n }\n tableresult += \"</tr>\";\n }\n\n var table = document.getElementById(\"mult_Table\").innerHTML = tableresult;\n\n }", "title": "" }, { "docid": "1857676de01cb6c31cfc07700a2ab370", "score": "0.5385319", "text": "function CalculateNumbers() {\n \n // For each tile\n for (var i = 0; i < cols; i++) {\n for (var j = 0; j < rows; j++) {\n var $calcCell = document.querySelectorAll(`[data-row='${j}'][data-col='${i}']`);\n var total = 0;\n \n // For each tile adjacent\n for (var offI = -1; offI <= 1; offI++) {\n for (var offJ = -1; offJ <= 1; offJ++) {\n finalI = i + offI;\n finalJ = j + offJ;\n \n // Checks for boundaries of the grid\n if (finalI > -1 && finalI < cols && finalJ > -1 && finalJ < rows) {\n var $numCell = document.querySelectorAll(`[data-row='${finalJ}'][data-col='${finalI}']`);\n \n // If the adjacent cell has a mine, increase the total by one\n if ($($numCell).hasClass('mine')) {\n total++;\n }\n }\n }\n }\n \n // Give the tile the attribute for its total and the text of its total\n $($calcCell).attr('data-num', total);\n $($calcCell).text(total);\n if (total == 0) { $($calcCell).text(''); }\n }\n }\n}", "title": "" }, { "docid": "e3cdb05cf8c8b61919242a008840fa53", "score": "0.53697747", "text": "function allCokPerHour() {\n\n // var container = document.getElementById('location1');\n\n // var tableEl = document.createElement('table');\n // container.appendChild(tableEl);\n\n var row = document.createElement('tr');//new row\n tableEl.appendChild(row);\n\n var head = document.createElement('th');\n row.appendChild(head);\n\n head.textContent = 'Total';\n\n // this loops calculat table valus vertically.\n // the first loop hold on spisific\"obenHour\" until the next loop get all that \"obenHour\" valus for all rows.\n\n var perHour = [];//to creat array contains all total amount per hour\n var all = 0; //to save the total of total\n for (var hour = 0; hour < obenHour.length; hour++) {\n var totalSum = 0;\n for (var index = 0; index < locations.length; index++) { //make the globle \"locations\"array as counter wich is contains the locations objects \n totalSum += locations[index].purchasedPerHour[hour]; //add \"totalSum\" to previous, asb for sure valus and start from 0\n }\n\n all += totalSum;\n perHour.push(totalSum);//save in array\n\n var cell = document.createElement('td');\n row.appendChild(cell);\n cell.textContent = perHour[hour];\n }\n var cell = document.createElement('td');\n row.appendChild(cell);\n cell.textContent = all;\n\n perHour.push(all);\n\n \n return [totalSum, perHour];\n}", "title": "" }, { "docid": "f683df764d553637e294e080da2fb7f9", "score": "0.53634876", "text": "function create_table() {\n var horiz_lower = Number(document.getElementById(\"x_lower\").value);\n var horiz_upper = Number(document.getElementById(\"x_upper\").value);\n var vert_lower = Number(document.getElementById(\"y_lower\").value);\n var vert_upper = Number(document.getElementById(\"y_upper\").value);\n\n // Used this StackOverflow page for reference: \n // https://stackoverflow.com/questions/14643617/create-table-using-javascript\n var div = document.getElementById(\"table\");\n var tbl = document.createElement(\"table\");\n var tbo = document.createElement(\"tbody\");\n\n var row = document.createElement(\"tr\");\n row.appendChild(document.createElement(\"th\"));\n\n for (var i = horiz_lower; i <= horiz_upper; i++) {\n var x_index = document.createElement(\"th\");\n x_index.innerText = i;\n row.appendChild(x_index);\n }\n tbo.appendChild(row);\n\n for (var y = vert_lower; y <= vert_upper; y++) {\n var row = document.createElement(\"tr\");\n var vert_index = document.createElement(\"th\");\n var vert_index_content = document.createTextNode(y);\n vert_index.appendChild(vert_index_content);\n row.appendChild(vert_index);\n\n for (var x = horiz_lower; x <= horiz_upper; x++) {\n var cell = document.createElement(\"td\");\n var cell_text = document.createTextNode( y*x );\n cell.appendChild(cell_text);\n row.appendChild(cell);\n }\n tbo.appendChild(row);\n }\n tbl.appendChild(tbo);\n div.appendChild(tbl);\n div.replaceChild(tbl, div.childNodes[0]);\n}", "title": "" }, { "docid": "05daeca2f968c78e49a590be05fae498", "score": "0.5361955", "text": "function operate() {\n var matrix = this.matrix,\n dataProvider = this.dataProvider;\n matrix.cellReferences.length = 0;\n Object(_helpers_array__WEBPACK_IMPORTED_MODULE_6__[\"arrayEach\"])(matrix.data, function (cell) {\n cell.setState(_cell_value__WEBPACK_IMPORTED_MODULE_8__[\"default\"].STATE_OUT_OFF_DATE);\n cell.clearPrecedents();\n var row = cell.row,\n column = cell.column;\n var value = dataProvider.getSourceDataAtCell(row, column);\n\n if (Object(_utils__WEBPACK_IMPORTED_MODULE_7__[\"isFormulaExpression\"])(value)) {\n var prevRow = visualRows.get(cell);\n var expModifier = new _expressionModifier__WEBPACK_IMPORTED_MODULE_9__[\"default\"](value);\n expModifier.translate({\n row: dataProvider.t.toVisualRow(row) - prevRow\n });\n dataProvider.updateSourceData(row, column, expModifier.toString());\n }\n });\n visualRows = null;\n}", "title": "" }, { "docid": "d8a575e72462d3ed7ef27021d57bdea8", "score": "0.5346153", "text": "function tabelaContinua(arrayOrdenado, totalCol2) {\n\n valoresCol1 = []\n valoresCol2 = []\n\n\n //achando o priElemento do arrayOrdenado\n let priElemento = parseInt(arrayOrdenado.slice(0, 1))\n\n //achando o ultElemento do arrayOrdenado\n let ultElemento = parseInt(arrayOrdenado.slice(-1))\n\n //calc de Amplitude Total\n let AmpliTotal = ultElemento - priElemento\n\n //achando o index do 1º numero a ser pesquisado (1º maior que AmpliTotal)\n let indexInicial = arrayOrdenado.findIndex(elemento => elemento > AmpliTotal)\n\n //calc de qtd de Classes\n let qtdClasses = Math.sqrt(arrayOrdenado.length)\n\n //arredondando qtd de Classes e voltando para o numero anterior\n qtdClasses = Math.round(qtdClasses) - 1\n\n //calc de intervalo de Classe\n let intClasse = ''\n\n for (var i = indexInicial; i < arrayOrdenado.length; i++) {\n //Encontrando o intervalo de Classe: \n let Ak = arrayOrdenado[i]\n parseFloat(Ak)\n intClasse = Ak / qtdClasses\n intClasse = parseFloat(intClasse)\n\n typeof (intClasse)\n\n //Se o intervalo de Classe for redondo, achamos o ideal\n if (intClasse == Math.round(intClasse)) {\n break\n }\n\n /*Se chegar ao final do array e não encontrar intervalo de Classe redondo,\n então acrescentamos +1 no qtdClasses e reiniciamos a busca*/\n if (i == arrayOrdenado.length - 1) {\n qtdClasses += 1\n const newLocal = indexInicial - 1\n i = newLocal\n }\n }\n\n let corpo = ''\n\n let numLinha = 0\n\n // lembre-se priElemento e ultElemento vem do arrayOrdenado\n for (let i = priElemento; i <= ultElemento; i += intClasse) {\n numLinha++\n\n if (i + intClasse >= ultElemento) {\n\n corpo += `<tr class='linha${numLinha}'>\n <td class='col1_linha${numLinha}'>${i} |--- ${i + intClasse}</td>\n <td class='calcFreq${numLinha}'>${qtdIndexEntre(arrayOrdenado, i, ultElemento) + 1}</td>\n </tr>` // esse +1 serve para corrigir a falta\n\n valoresCol1.push(i)\n valoresCol1.push(i + intClasse)\n valoresCol2.push(qtdIndexEntre(arrayOrdenado, i, ultElemento) + 1)\n valoresCol2.push(0)\n } else {\n\n corpo += `<tr class='linha${numLinha}'>\n <td class='col1_linha${numLinha}'>${i} |--- ${i + intClasse}</td>\n <td class='calcFreq${numLinha}'>${qtdIndexEntre(arrayOrdenado, i, i + intClasse)}</td>\n </tr>`\n\n valoresCol1.push(i)\n valoresCol1.push(i + intClasse)\n valoresCol2.push(qtdIndexEntre(arrayOrdenado, i, i + intClasse))\n valoresCol2.push(0)\n }\n }\n\n corpo += `<tr class='linhaTotal'>\n <td>Total:</td>\n <td class='totalFreq'>${totalCol2}</td>\n </tr>`\n\n // depois do for, o qtd de Classes (qtd de lihas da tabela)\n const qtdLinhas = qtdClasses\n\n return [corpo, qtdLinhas, valoresCol1, valoresCol2]\n}", "title": "" }, { "docid": "a3c5bf4b1197589766b040001677d40a", "score": "0.5343172", "text": "function sumTablePortion(htmlPath, category){\n let counter = 0; //counter variable to count the points in this part of the table\n let rows = Array.from(TABLE.rows); //Array object from the rows in the table element\n rows.forEach(tr => {\n let rowName = tr.className; //get the class of the current html row element\n //If the assignment is graded or the assignment has a what-if score in it, do stuff with it. Otherwise, it's a formatting element\n //so it should be ignored\n if(rowName === \"student_assignment assignment_graded editable\" || (rowName === \"student_assignment editable\" && wasChanged(tr))) {\n //It's an assignment not a formatting row and we should be counting it\n //countThisAssignment: whether or not we should count this assignment (is it the right category). Starts as true for when it's total points.\n let countThisAssignment = true;\n if (weighted) {\n //If it's a weighted class, check the assignment against the desired category\n //path: local variable to find the category of the given assignment\n let path = \"#\" + tr.id + \" > th > div\";\n //Gets the category of this assignment and compares it to inputted category\n countThisAssignment = document.querySelector(path).textContent === category;\n }\n if (countThisAssignment) {\n //If it's something we should count, count it!\n //Assemble full HTML path:\n let fullPath = \"#\" + tr.id + htmlPath;\n //Convert points into number and add to counter:\n //Also removes any commas so that you can input scores over 1000 if you want to LOL\n let DCAULF_WHY_ARE_YOU_TERRIBLE = parseFloat(document.querySelector(fullPath).textContent.replaceAll(',', ''));\n if(isNaN(DCAULF_WHY_ARE_YOU_TERRIBLE)){\n DCAULF_WHY_ARE_YOU_TERRIBLE = 0;\n }\n counter += DCAULF_WHY_ARE_YOU_TERRIBLE;\n }\n }\n });\n return counter; //Return statement.\n}", "title": "" }, { "docid": "3c318715963e449d0efcba8e4ead53b2", "score": "0.53360415", "text": "function loopInRows(rows, textarea) {\n\tconst formulas = []\n\tlet index = 0;\n\n\tfor (let row of rows) {\n\t\tlet formula = textarea;\n\n\t\tconst rowP = document.querySelectorAll('input.rowP')[index].value\n\t\tconst rowQ = document.querySelectorAll('input.rowQ')[index].value\n\t\tconst rowR = document.querySelectorAll('input.rowR')[index].value\n\n\t\tformula = transformInNumber(rowP, 'P', formula)\n\t\tformula = transformInNumber(rowQ, 'Q', formula)\n\t\tformula = transformInNumber(rowR, 'R', formula)\n\n\t\t// se o resultado for igual o inicial, ele não vai adicionar no array! (para evitar bug)\n\t\tif (formula != textarea) {\n\t\t\tformulas.push(formula)\n\t\t}\n\n\t\tindex++\n\t}\n\n\treturn formulas\n}", "title": "" }, { "docid": "5b6645e18a34266ab6dbd4931f0913af", "score": "0.53342956", "text": "function FormulaPage() {}", "title": "" }, { "docid": "da0266ad6e94fcdfc24fdbe670b3c0ae", "score": "0.53081393", "text": "function calculateGroupTotal(cellsToTotal, totalTd, groupTotalDiv, rowIndex, columnIndex) {\n\n var total = 0;\n var values = new Array();\n var hasInvalidValues = false;\n var extraData = groupTotalDiv.data(\"params\");\n var functionName = groupTotalDiv.data(\"function\");\n\n for (var i = 0; i < cellsToTotal.length; i++) {\n var currentCell = cellsToTotal[i];\n var isCellObject = currentCell != null && typeof currentCell === 'object';\n\n var value;\n\n //check if cell is a cellObject - using mData setting\n if (isCellObject) {\n value = currentCell.val;\n\n if (value == null) {\n value = \"\";\n }\n }\n\n var isAddLine = !isCellObject && currentCell\n && jQuery(currentCell).find(\":input[name^='newCollectionLines']\").length;\n\n // skip over add line\n if (!isAddLine) {\n value = coerceTableCellValue(currentCell, true);\n }\n else {\n continue;\n }\n\n value = convertComplexNumericValue(value);\n\n //set hasInvalidValues to true if value is undefined\n if (value == undefined || (value && !jQuery.isNumeric(value))) {\n hasInvalidValues = true;\n continue;\n }\n\n //skip over value when blank\n if (value != \"\") {\n value = parseFloat(value);\n values.push(value);\n }\n }\n\n if (!hasInvalidValues) {\n if (extraData != undefined) {\n total = window[functionName](values, extraData);\n }\n else {\n total = window[functionName](values);\n }\n }\n else {\n total = \"N/A\";\n }\n\n var groupTotalDisplay = totalTd.find(\"div[data-role='groupTotal'][data-function='\" + functionName + \"']\");\n //clone and append, if no place to display the total has been generated yet\n if (groupTotalDisplay.length == 0) {\n groupTotalDisplay = groupTotalDiv.clone();\n //resetting ids to unique ids on the clone\n groupTotalDisplay = groupTotalDisplay.attr(\"id\", groupTotalDisplay.attr(\"id\") + \"_\" + rowIndex + columnIndex);\n groupTotalDisplay.find(\"[id]\").each(function () {\n jQuery(this).attr(\"id\", jQuery(this).attr(\"id\") + \"_\" + rowIndex + columnIndex);\n });\n totalTd.append(groupTotalDisplay);\n groupTotalDisplay.show();\n }\n\n var totalValueSpan = groupTotalDisplay.find(\"span[data-role='totalValue']\");\n\n if (totalValueSpan.length) {\n totalValueSpan.html(total);\n }\n else {\n var newSpan = jQuery(\"<span data-role='totalValue'>\" + total + \"</span>\");\n groupTotalDisplay.append(newSpan);\n }\n\n}", "title": "" }, { "docid": "eea45921a8ce091ef4cb837db4b499c3", "score": "0.53073496", "text": "function addRow()\r\n{\r\n if(step<=11+len)\r\n {\r\n row=table.insertRow(-1);\r\n for(var j=1;j<=13;j++)\r\n {\r\n cell=row.insertCell(-1);\r\n if(j==1)\r\n {\r\n if(step<=len)\r\n cell.innerHTML=\"Пара \"+step+\"<br>А:\"+firstVector[step-1]+\"<br>В:\"+secondVector[step-1];\r\n }\r\n else\r\n {\r\n if(step-(j-1)>=0 && step-(j-1)<len)\r\n {\r\n var answer=\"\";\r\n var couple=step-(j-1);\r\n if(j%2==0)\r\n {\r\n var rank=6-j/2;\r\n answer+=\"Число:<br>\"+firstVector[couple]+\"<br>Разряд:<br>\"+secondVector[couple][rank]+\"<br>\";\r\n if(secondVector[couple][rank]=='1')\r\n for(var k=5;k>=0;k--)\r\n {\r\n var sum=Number(firstVector[couple][k])+Number(result[couple][k])+Number(buffer[couple][k+1]);\r\n if(sum==1)\r\n {\r\n result[couple][k]=1;\r\n buffer[couple][k+1]=0;\r\n }\r\n else if(sum==2)\r\n {\r\n result[couple][k]=0;\r\n buffer[couple][k+1]=0;\r\n buffer[couple][k]=1;\r\n }\r\n else if(sum==3)\r\n {\r\n result[couple][k]=1;\r\n buffer[couple][k+1]=0;\r\n buffer[couple][k]=1;\r\n }\r\n }\r\n }\r\n else\r\n {\r\n shift(result[couple]);\r\n }\r\n answer+=\"Результат:<br>\";\r\n for(var k=0;k<12;k++){\r\n answer += k % 4 == 0 ? \" \" : \"\";\r\n answer+=result[couple][k];\r\n }\r\n answer+=\"<br>Время:<br>\"+step*time;\r\n cell.innerHTML=answer;\r\n }\r\n }\r\n }\r\n step++;\r\n }\r\n else\r\n {\r\n\r\n var answer=\"Ответ: <\";\r\n for(var i=0;i<len;i++)\r\n {\r\n answer+=parseInt(result[i].join(''), 2) + \" \";\r\n }\r\n answer += \">\"+\"<br>\";\r\n\r\n createMessage(answer);\r\n }\r\n}", "title": "" }, { "docid": "b5c5f8d623fdac051d360234f5306223", "score": "0.5282122", "text": "function calculatePriznati() {\n var totalPriznati = 0;\n var totalDodati = 0;\n var steceniESPB = parseInt($('#steceniESPB').val());\n $(\"#target_table_id tbody input[type=checkbox]\").each(function (i, val) {\n var checkbox_cell_is_checked = $(this).is(':checked');\n // Is it checked?\n if (checkbox_cell_is_checked) {\n $(this).closest('tr').find('td:eq(5)').text(parseInt($(this).val()));\n $(this).closest('tr').find('td:eq(6)').text('');\n totalPriznati += parseInt($(this).val());\n $(this).parent().parent().addClass('selected').siblings().removeClass('selected');\n }\n else {\n $(this).closest('tr').find('td:eq(5)').text('');\n $(this).closest('tr').find('td:eq(6)').text(parseInt($(this).val()));\n var dodati = parseInt($(this).closest('tr').find('td:eq(6)').text());\n totalDodati += dodati;\n }\n $(\"#sum5\").text(totalPriznati);\n $(\"#sum6\").text(totalDodati);\n $(\"#0\").text(steceniESPB - parseInt($(\"#sum6\").text()) + parseInt($(\"#sum5\").text()));\n $(\"#1\").text($(\"#sum5\").text());\n $(\"#3\").text($(\"#sum6\").text());\n $(\"#4\").text(parseInt($(\"#0\").text()) + parseInt($(\"#1\").text()) + parseInt($(\"#3\").text()));\n $(\"#5\").text(parseInt(240 - $(\"#4\").text()));\n });\n}", "title": "" }, { "docid": "3a05f870b1c67fb3d69581e71973285d", "score": "0.52755374", "text": "function getTotalPoints(){\n let htmlPath = \" > td.possible.points_possible\"; //HTML path to get to the total points within the table data (td)\n return sumTablePortion(htmlPath);\n}", "title": "" }, { "docid": "1989a5bcf348d81b7c183f7326acd5dc", "score": "0.52645844", "text": "function calculateTotal(totalDiv, start, end, currentColumn, aaData, aiDisplay) {\n if (totalDiv.length && totalDiv.data(\"function\")) {\n var totalType = totalDiv.data(\"role\");\n var dataIndex = currentColumn;\n var functionName = totalDiv.data(\"function\");\n var extraData = totalDiv.data(\"params\");\n var total = 0;\n var values = new Array();\n var hasInvalidValues = false;\n\n // Calculate the total for all rows, even outside this page\n for (var i = start; i < end; i++) {\n var currentRow;\n var currentCell;\n\n if (totalType == \"total\") {\n currentRow = aaData[i];\n }\n else if (totalType = \"pageTotal\") {\n currentRow = aaData[aiDisplay[i]];\n }\n\n var value;\n //check if row is a rowObject - using mData setting\n if (currentRow != null && typeof currentRow === 'object' && !jQuery.isArray(currentRow)) {\n value = currentRow['c' + dataIndex].val;\n\n if (value == null) {\n value = \"\";\n }\n }\n else {\n currentCell = currentRow[dataIndex];\n }\n\n var isAddLine = currentCell && jQuery(currentCell).find(\":input[name^='newCollectionLines']\").length;\n\n //skip over cells which contain add line content\n if (!isAddLine) {\n value = coerceTableCellValue(currentCell, true);\n }\n else {\n continue;\n }\n\n value = convertComplexNumericValue(value);\n\n //set hasInvalidValues to true if value is undefined\n if (value == undefined || (value && !jQuery.isNumeric(value))) {\n hasInvalidValues = true;\n continue;\n }\n\n //skip over value when blank\n if (value != \"\") {\n value = parseFloat(value);\n values.push(value);\n }\n }\n\n if (!hasInvalidValues) {\n if (extraData != undefined) {\n total = window[functionName](values, extraData);\n }\n else {\n total = window[functionName](values);\n }\n }\n else {\n total = \"N/A\";\n }\n\n var totalValueSpan = totalDiv.find(\"span[data-role='totalValue']\");\n\n if (totalValueSpan.length) {\n totalValueSpan.html(total);\n }\n else {\n var newSpan = jQuery(\"<span data-role='totalValue'>\" + total + \"</span>\");\n totalDiv.append(newSpan);\n }\n }\n}", "title": "" }, { "docid": "1517e0233fb930ce483247ebb8a318b3", "score": "0.5255739", "text": "function scrapeTable(){\n\t\t\tvar colors = o.colors;\n\t\t\tvar textColors = o.textColors;\n\t\t\tvar tableData = {\n\t\t\t\tdataGroups: function(){\n\t\t\t\t\tvar dataGroups = [];\n\t\t\t\t\tif(o.parseDirection == 'x'){\n\t\t\t\t\t\tself.find('tr:gt(0)').filter(o.rowFilter).each(function(i){\n\t\t\t\t\t\t\tdataGroups[i] = {};\n\t\t\t\t\t\t\tdataGroups[i].points = [];\n\t\t\t\t\t\t\tdataGroups[i].color = colors[i];\n\t\t\t\t\t\t\tif(textColors[i]){ dataGroups[i].textColor = textColors[i]; }\n\t\t\t\t\t\t\t$(this).find('td').filter(o.colFilter).each(function(){\n\t\t\t\t\t\t\t\tdataGroups[i].points.push( parseFloat($(this).text()) );\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tvar cols = self.find('tr:eq(1) td').filter(o.colFilter).size();\n\t\t\t\t\t\tfor(var i=0; i<cols; i++){\n\t\t\t\t\t\t\tdataGroups[i] = {};\n\t\t\t\t\t\t\tdataGroups[i].points = [];\n\t\t\t\t\t\t\tdataGroups[i].color = colors[i];\n\t\t\t\t\t\t\tif(textColors[i]){ dataGroups[i].textColor = textColors[i]; }\n\t\t\t\t\t\t\tself.find('tr:gt(0)').filter(o.rowFilter).each(function(){\n\t\t\t\t\t\t\t\tdataGroups[i].points.push( $(this).find('td').filter(o.colFilter).eq(i).text()*1 );\n\t\t\t\t\t\t\t});\n\t\t\t\t\t\t};\n\t\t\t\t\t}\n\t\t\t\t\treturn dataGroups;\n\t\t\t\t},\n\t\t\t\tallData: function(){\n\t\t\t\t\tvar allData = [];\n\t\t\t\t\t$(this.dataGroups()).each(function(){\n\t\t\t\t\t\tallData.push(this.points);\n\t\t\t\t\t});\n\t\t\t\t\treturn allData;\n\t\t\t\t},\n\t\t\t\tdataSum: function(){\n\t\t\t\t\tvar dataSum = 0;\n\t\t\t\t\tvar allData = this.allData().join(',').split(',');\n\t\t\t\t\t$(allData).each(function(){\n\t\t\t\t\t\tdataSum += parseFloat(this);\n\t\t\t\t\t});\n\t\t\t\t\treturn dataSum\n\t\t\t\t},\t\n\t\t\t\ttopValue: function(){\n\t\t\t\t\t\tvar topValue = 0;\n\t\t\t\t\t\tvar allData = this.allData().join(',').split(',');\n\t\t\t\t\t\t$(allData).each(function(){\n\t\t\t\t\t\t\tif(parseFloat(this,10)>topValue) topValue = parseFloat(this);\n\t\t\t\t\t\t});\n\t\t\t\t\t\treturn topValue;\n\t\t\t\t},\n\t\t\t\tbottomValue: function(){\n\t\t\t\t\t\tvar bottomValue = 0;\n\t\t\t\t\t\tvar allData = this.allData().join(',').split(',');\n\t\t\t\t\t\t$(allData).each(function(){\n\t\t\t\t\t\t\tif(this<bottomValue) bottomValue = parseFloat(this);\n\t\t\t\t\t\t});\n\t\t\t\t\t\treturn bottomValue;\n\t\t\t\t},\n\t\t\t\tmemberTotals: function(){\n\t\t\t\t\tvar memberTotals = [];\n\t\t\t\t\tvar dataGroups = this.dataGroups();\n\t\t\t\t\t$(dataGroups).each(function(l){\n\t\t\t\t\t\tvar count = 0;\n\t\t\t\t\t\t$(dataGroups[l].points).each(function(m){\n\t\t\t\t\t\t\tcount +=dataGroups[l].points[m];\n\t\t\t\t\t\t});\n\t\t\t\t\t\tmemberTotals.push(count);\n\t\t\t\t\t});\n\t\t\t\t\treturn memberTotals;\n\t\t\t\t},\n\t\t\t\tyTotals: function(){\n\t\t\t\t\tvar yTotals = [];\n\t\t\t\t\tvar dataGroups = this.dataGroups();\n\t\t\t\t\tvar loopLength = this.xLabels().length;\n\t\t\t\t\tfor(var i = 0; i<loopLength; i++){\n\t\t\t\t\t\tyTotals[i] =[];\n\t\t\t\t\t\tvar thisTotal = 0;\n\t\t\t\t\t\t$(dataGroups).each(function(l){\n\t\t\t\t\t\t\tyTotals[i].push(this.points[i]);\n\t\t\t\t\t\t});\n\t\t\t\t\t\tyTotals[i].join(',').split(',');\n\t\t\t\t\t\t$(yTotals[i]).each(function(){\n\t\t\t\t\t\t\tthisTotal += parseFloat(this);\n\t\t\t\t\t\t});\n\t\t\t\t\t\tyTotals[i] = thisTotal;\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t\t\t\t\treturn yTotals;\n\t\t\t\t},\n\t\t\t\ttopYtotal: function(){\n\t\t\t\t\tvar topYtotal = 0;\n\t\t\t\t\t\tvar yTotals = this.yTotals().join(',').split(',');\n\t\t\t\t\t\t$(yTotals).each(function(){\n\t\t\t\t\t\t\tif(parseFloat(this,10)>topYtotal) topYtotal = parseFloat(this);\n\t\t\t\t\t\t});\n\t\t\t\t\t\treturn topYtotal;\n\t\t\t\t},\n\t\t\t\ttotalYRange: function(){\n\t\t\t\t\treturn this.topValue() - this.bottomValue();\n\t\t\t\t},\n\t\t\t\txLabels: function(){\n\t\t\t\t\tvar xLabels = [];\n\t\t\t\t\tif(o.parseDirection == 'x'){\n\t\t\t\t\t\tself.find('tr:eq(0) th').filter(o.colFilter).each(function(){\n\t\t\t\t\t\t\txLabels.push($(this).html());\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\tself.find('tr:gt(0) th').filter(o.rowFilter).each(function(){\n\t\t\t\t\t\t\txLabels.push($(this).html());\n\t\t\t\t\t\t});\n\t\t\t\t\t}\n\t\t\t\t\treturn xLabels;\n\t\t\t\t},\n\t\t\t\tyLabels: function(){\n\t\t\t\t\tvar yLabels = [];\n\t\t\t\t\tyLabels.push(bottomValue); \n\t\t\t\t\tvar numLabels = Math.round(o.height / o.yLabelInterval);\n\t\t\t\t\tvar loopInterval = Math.ceil(totalYRange / numLabels) || 1;\n\t\t\t\t\twhile( yLabels[yLabels.length-1] < topValue - loopInterval){\n\t\t\t\t\t\tyLabels.push(yLabels[yLabels.length-1] + loopInterval); \n\t\t\t\t\t}\n\t\t\t\t\tyLabels.push(topValue); \n\t\t\t\t\treturn yLabels;\n\t\t\t\t}\t\t\t\n\t\t\t};\n\t\t\t\n\t\t\treturn tableData;\n\t\t}", "title": "" }, { "docid": "b9d6295f5552f3db191c0c57c154dea3", "score": "0.5242395", "text": "function addFormulas(outline, sheetName, num) {\n let sheet = ss.getSheetByName(sheetName);\n let colour = findColour(ss.getSheets()[0]);\n let numOfSections = outline[16][0];\n let start = outline[16][6] + 2;\n let span = outline[15][6];\n let end = start + span;\n let sections = outline[15].slice(1, 5);\n let secPoints = outline[16].slice(1, 5);\n let secBonus = outline[17].slice(1, 5);\n let cl = [0,'A','B','C','D','E','F','G','H','I','J',\n 'K','L','M','N','O','P','Q','R','S','T','U',\n 'V','W','X','Y','Z','AA','AB','AC','AD','AE',\n 'AF','AG','AH','AI','AJ','AK','AL','AM','AN',\n 'AO','AP','AQ','AR','AS','AT','AU','AV','AW',\n 'AX','AY','AZ'];\n let cb = cl[start-1]; // checkbox column letter\n let cbRef = cb+'4'; // checkbox cell\n let columnIndex = 7;\n let formulae = [[]];\n let rules = sheet.getConditionalFormatRules();\n let range = sheet.getRange(4, start, sheet.getMaxRows()-3, span);\n let rule1 = SpreadsheetApp.newConditionalFormatRule()\n .whenFormulaSatisfied('=$'+cbRef+' = FALSE')\n .setBackground(colour.dark)\n .setFontColor(colour.dark)\n .setRanges([range])\n .build();\n let rule2 = SpreadsheetApp.newConditionalFormatRule()\n .whenCellNotEmpty()\n .setBackground(colour.dark)\n .setFontColor('white')\n .setRanges([range])\n .build();\n rules.push(rule1);\n rules.push(rule2);\n range.setHorizontalAlignment('center');\n formulae[0].push('=if('+cbRef+'=true; countif('+cl[start]+'4:'+cl[end]+'4; \\\"\\\") / F$3; \\\"\\\")');\n for (let i in sections) { // for each index in 'sections' array\n if (sections[i] == '') {\n break;\n } else {\n let col = cl[columnIndex];\n let secSpan = secPoints[i] + secBonus[i] - 1; // calc span of section\n end = cl[start + secSpan] + '4'; // create final cell ref string\n let calcRef = cl[start] + '4:' + end; // create range reference string\n let ifTrue = 'countif('+calcRef+ '; \\\"\\\") / '+col+'$3';\n formulae[0].push('=if('+cbRef+'=true; '+ifTrue+'; \\\"\\\")');\n start += secSpan + 1; // setup next section start\n columnIndex++;\n }\n }\n sheet.getRange(4, 6, 1, numOfSections+1).setFormulas(formulae);\n sheet.setConditionalFormatRules(rules);\n sheet.autoResizeColumns(1, sheet.getMaxColumns());\n if (numOfSections > 1) { // if more than one section, else overall is all we need\n let remainder = numOfSections % 2;\n if (remainder == 0) { // if an even # of sections\n sheet.getRange(1, (6+(numOfSections/2))).setValue('=Outline!e19'); // write 'SECTIONS' in first row\n } else { // if 3 sections\n sheet.getRange(1, 8).setValue('=Outline!e19');\n }\n }\n let rows = sheet.getMaxRows();\n let copyFrom = sheet.getRange(4, 6, 1, numOfSections+1);\n let copyTo = sheet.getRange(5, 6, rows-4, numOfSections+1)\n sheet.setColumnWidths(6, numOfSections+1, 60);\n sheet.getRange(4, 6, rows-3, numOfSections+1).setNumberFormat('0.00%');\n copyFrom.copyTo(copyTo);\n}", "title": "" }, { "docid": "8edda3f3f3c7bb9d625bce87869e345c", "score": "0.5241805", "text": "function generateMatrixTable(range,formatCellAnswers) \n{\n var table = document.querySelector(\"table\");\n\n FormatCellsInLine=formatCellAnswers;\n\n while(table.hasChildNodes())\n {\n // clear any previous table\n table.removeChild(table.firstChild);\n }\n\n var thead = table.createTHead();\n var row = thead.insertRow();\n var offset=0;\n\n var th = document.createElement(\"th\");\n row.appendChild(th);\n th.setAttribute('class','row-header')\n \n for (var key1 of range) \n {\n var th = document.createElement(\"th\");\n th.setAttribute('class','col-header')\n var text = document.createTextNode(key1);\n th.appendChild(text);\n row.appendChild(th);\n }\n\n for (var key1 of range) \n {\n rowIndex=key1\n var row = thead.insertRow();\n var th = document.createElement(\"th\");\n th.setAttribute('class','row-header')\n var text = document.createTextNode(key1);\n th.appendChild(text);\n row.appendChild(th);\n\n if (offset==0) {\n {offset=1};\n } \n else if (offset==1){\n {offset=0}\n }\n\n for (var key2 of range) \n {\n colIndex=key2\n var td = document.createElement(\"td\");\n\n if (key2%2==offset)\n td.setAttribute('class','editable-cell1')\n else\n td.setAttribute('class','editable-cell2')\n\n td.setAttribute('id', rowIndex + '-' + colIndex);\n td.setAttribute('contenteditable','true')\n td.setAttribute('inputmode','numeric');\n td.setAttribute('maxlength','3')\n td.onkeydown = function(event) { CellKeyDown(event);}\n row.appendChild(td);\n }\n }\n}", "title": "" }, { "docid": "3c66fa49c3d4e04e285fb33329c6b085", "score": "0.5237342", "text": "function create_table() {\n\n var lowcol = Math.floor(document.getElementById(\"form3\").elements[0].value);\n var highcol = Math.floor(document.getElementById(\"form3\").elements[1].value);\n var lowrow = Math.floor(document.getElementById(\"form3\").elements[2].value);\n var highrow = Math.floor(document.getElementById(\"form3\").elements[3].value);\n\n var num = Number(lowcol);\n var num2 = Number(lowrow);\n\n //html elements are imported\n var tablearea = document.getElementById('tablearea');\n var tbl = document.createElement('table');\n tbl.style.width = '100px';\n tbl.style.border = '2px solid black';\n\n //table is made based on template from stackoverflow\n for(var i = lowrow-1; i <= highrow; i++){\n var tr = tbl.insertRow();\n\n for(var j = lowcol-1; j <= highcol; j++) {\n\n var td = tr.insertCell();\n\n if(i == lowrow-1 && j == lowcol-1) {\n td.appendChild(document.createTextNode(''));\n }\n\n else if (i == (lowrow-1)) {\n td.appendChild(document.createTextNode((num)));\n num = num + 1;\n }\n\n else if (j == (lowcol-1)) {\n td.appendChild(document.createTextNode((num2)));\n num2 = num2 + 1;\n }\n\n else {\n td.appendChild(document.createTextNode(i*j));\n if (i == lowrow-1 && j != lowcol-1) {\n td.appendChild(document.createTextNode(i));\n }\n }\n td.style.border = '2px solid black';\n }\n }\n\n if (it > 0) { //replaces old table\n var table1 = document.getElementById('table1');\n tablearea.removeChild(table1);\n console.log(1);\n }\n\n tbl.setAttribute('id', 'table1');\n tablearea.appendChild(tbl);\n \n it++;\n}", "title": "" }, { "docid": "425f6ff346509e0e64f2273f218d6a06", "score": "0.5223388", "text": "function multiTable() {\n var table = \"\";\n var line = \"\\n\";\n var sum;\n for (var i = 1; i <= 12; i++) {\n for (var j = 1; j <= 12; j++) {\n sum = i * j;\n table += i + \" * \" + j + \" = \" + sum + \"\\n\";\n }\n table += line;\n }\n return table;\n }", "title": "" }, { "docid": "32b08cb101f5d063a0fb9e8a75f32f3c", "score": "0.5217902", "text": "function SE0201() {\n calculatefor(new Array(\n// 201 3 22\n1794553.577562, 2.0, -4.0, 4.0, 8589.3, 8589.3,\n -0.1399800, 0.5040102, 1.100e-06, -8.230e-06,\n 0.4127390, 0.2830716, -2.780e-05, -4.830e-06,\n 0.2397900, 0.0156350, 0.000e-00,\n 208.1773071, 15.0050621, 0.000e-00,\n 0.5353540, 0.0000560, -1.270e-05,\n -0.0107300, 0.0000557, -1.260e-05,\n 0.0046507, 0.0046276,\n// 201 9 15\n1794730.635190, 3.0, -4.0, 4.0, 8584.7, 8584.7,\n -0.3247990, 0.4400528, 2.700e-06, -4.810e-06,\n -0.3286910, -0.2458029, -4.300e-06, 2.860e-06,\n 3.5075099, -0.0158300, -1.000e-06,\n 226.2625580, 15.0041561, 0.000e-00,\n 0.5714430, 0.0000027, -9.800e-06,\n 0.0251790, 0.0000027, -9.700e-06,\n 0.0046910, 0.0046676,\n// 202 2 10\n1794878.885493, 9.0, -4.0, 4.0, 8580.8, 8580.8,\n 0.4819000, 0.5211712, -5.570e-05, -8.290e-06,\n -1.4155999, 0.2355097, 1.714e-04, -3.910e-06,\n -14.5750103, 0.0128740, 3.000e-06,\n 310.7402954, 15.0016975, 0.000e-00,\n 0.5407700, -0.0000813, -1.250e-05,\n -0.0053410, -0.0000809, -1.250e-05,\n 0.0047059, 0.0046825,\n// 202 3 11\n1794908.271452, 19.0, -4.0, 4.0, 8580.1, 8580.1,\n -0.2982750, 0.5093689, 1.250e-05, -8.480e-06,\n 1.1257540, 0.2806867, -3.930e-05, -4.890e-06,\n -3.8827400, 0.0155420, 1.000e-06,\n 102.2445602, 15.0046797, 0.000e-00,\n 0.5344910, -0.0000546, -1.290e-05,\n -0.0115890, -0.0000543, -1.280e-05,\n 0.0046650, 0.0046418,\n// 202 9 4\n1795084.657202, 4.0, -4.0, 4.0, 8575.5, 8575.5,\n -0.4359720, 0.4559337, -1.530e-05, -5.360e-06,\n -1.0672890, -0.2430555, 9.200e-06, 3.010e-06,\n 7.8315201, -0.0150590, -2.000e-06,\n 240.4672852, 15.0038834, 0.000e-00,\n 0.5642660, 0.0000884, -1.020e-05,\n 0.0180380, 0.0000880, -1.020e-05,\n 0.0046750, 0.0046517,\n// 203 1 30\n1795233.374975, 21.0, -4.0, 4.0, 8571.6, 8571.6,\n 0.3105700, 0.5019833, -4.000e-05, -6.740e-06,\n -0.7857370, 0.1981888, 1.516e-04, -2.810e-06,\n -17.7938595, 0.0109590, 4.000e-06,\n 130.8360748, 15.0000811, 0.000e-00,\n 0.5559170, -0.0001242, -1.120e-05,\n 0.0097300, -0.0001235, -1.110e-05,\n 0.0047203, 0.0046968,\n// 203 7 26\n1795409.530986, 1.0, -4.0, 4.0, 8567.0, 8567.0,\n 0.4040080, 0.5376033, -7.820e-05, -8.280e-06,\n 0.7635210, -0.1770214, -1.678e-04, 2.910e-06,\n 20.1580296, -0.0083850, -5.000e-06,\n 194.2796326, 15.0007114, 0.000e-00,\n 0.5391520, 0.0000970, -1.210e-05,\n -0.0069510, 0.0000965, -1.200e-05,\n 0.0046228, 0.0045998,\n// 204 1 20\n1795587.557300, 1.0, -4.0, 4.0, 8562.4, 8562.4,\n -0.1354660, 0.4856217, -2.580e-05, -5.550e-06,\n -0.2036290, 0.1565561, 1.369e-04, -1.940e-06,\n -20.4994602, 0.0084350, 5.000e-06,\n 191.3768921, 14.9984198, 0.000e-00,\n 0.5707480, -0.0000649, -1.010e-05,\n 0.0244870, -0.0000645, -1.000e-05,\n 0.0047336, 0.0047100,\n// 204 7 14\n1795764.202630, 17.0, -4.0, 4.0, 8557.8, 8557.8,\n 0.1015730, 0.5654520, -4.710e-05, -9.600e-06,\n 0.0737950, -0.1458050, -1.566e-04, 2.640e-06,\n 22.0589294, -0.0057730, -5.000e-06,\n 74.5619507, 14.9998980, 0.000e-00,\n 0.5310140, 0.0000133, -1.280e-05,\n -0.0150490, 0.0000132, -1.280e-05,\n 0.0046126, 0.0045896,\n// 205 1 8\n1795941.528139, 1.0, -4.0, 4.0, 8553.2, 8553.2,\n 0.0341220, 0.4905921, -3.940e-05, -5.450e-06,\n 0.5619170, 0.1173015, 1.213e-04, -1.440e-06,\n -22.4614105, 0.0053550, 6.000e-06,\n 192.3440857, 14.9970503, 0.000e-00,\n 0.5741330, 0.0000246, -9.900e-06,\n 0.0278550, 0.0000245, -9.900e-06,\n 0.0047444, 0.0047208,\n// 205 7 4\n1796118.905739, 10.0, -4.0, 4.0, 8548.6, 8548.6,\n 0.0333790, 0.5645004, -1.850e-05, -9.100e-06,\n -0.6642140, -0.1015926, -1.269e-04, 1.790e-06,\n 23.2423592, -0.0029640, -6.000e-06,\n 330.0357361, 14.9993134, 0.000e-00,\n 0.5348240, -0.0000863, -1.240e-05,\n -0.0112570, -0.0000859, -1.230e-05,\n 0.0046049, 0.0045819,\n// 205 12 28\n1796295.598235, 2.0, -4.0, 4.0, 8544.0, 8544.0,\n -0.3630820, 0.5205248, -2.610e-05, -6.560e-06,\n 1.1561270, 0.0777060, 1.105e-04, -1.090e-06,\n -23.5099602, 0.0019150, 7.000e-06,\n 208.6213226, 14.9962740, 0.000e-00,\n 0.5635950, 0.0001180, -1.080e-05,\n 0.0173700, 0.0001174, -1.070e-05,\n 0.0047522, 0.0047285,\n// 206 5 25\n1796443.981072, 12.0, -4.0, 4.0, 8540.2, 8540.2,\n 0.1106950, 0.5240488, 2.550e-05, -6.600e-06,\n 1.2568671, 0.0539918, -1.823e-04, -6.300e-07,\n 20.8260098, 0.0077850, -5.000e-06,\n 1.7926500, 15.0007868, 0.000e-00,\n 0.5553360, -0.0001163, -1.040e-05,\n 0.0091530, -0.0001158, -1.040e-05,\n 0.0045971, 0.0045742,\n// 206 6 23\n1796473.447805, 23.0, -4.0, 4.0, 8539.4, 8539.4,\n -0.0050870, 0.5399510, 2.800e-06, -7.400e-06,\n -1.4658130, -0.0526556, -8.970e-05, 8.600e-07,\n 23.6715794, 0.0000030, -6.000e-06,\n 165.6131897, 14.9990807, 0.000e-00,\n 0.5479100, -0.0001239, -1.110e-05,\n 0.0017640, -0.0001233, -1.100e-05,\n 0.0045996, 0.0045767,\n// 206 11 17\n1796620.474523, 23.0, -4.0, 4.0, 8535.6, 8535.6,\n -0.3597280, 0.5690012, 2.850e-05, -9.320e-06,\n -0.9015720, -0.0845787, 1.917e-04, 1.280e-06,\n -19.2779903, -0.0100640, 5.000e-06,\n 167.9919281, 14.9988928, 0.000e-00,\n 0.5417660, 0.0000836, -1.280e-05,\n -0.0043500, 0.0000832, -1.270e-05,\n 0.0047547, 0.0047310,\n// 207 5 14\n1796798.095748, 14.0, -4.0, 4.0, 8531.0, 8531.0,\n -0.2311360, 0.4996929, 3.010e-05, -5.630e-06,\n 0.4691790, 0.0832765, -1.253e-04, -8.700e-07,\n 18.3631191, 0.0102230, -4.000e-06,\n 31.7807503, 15.0018930, 0.000e-00,\n 0.5652960, -0.0000218, -9.700e-06,\n 0.0190630, -0.0000216, -9.700e-06,\n 0.0046015, 0.0045786,\n// 207 11 7\n1796975.125800, 15.0, -4.0, 4.0, 8526.4, 8526.4,\n -0.0657500, 0.5698714, 3.130e-05, -9.650e-06,\n -0.2632580, -0.1176411, 1.279e-04, 1.910e-06,\n -16.3626499, -0.0123370, 4.000e-06,\n 48.4543800, 15.0003786, 0.000e-00,\n 0.5386250, -0.0000274, -1.310e-05,\n -0.0074750, -0.0000273, -1.300e-05,\n 0.0047488, 0.0047251,\n// 208 5 2\n1797152.127237, 15.0, -4.0, 4.0, 8521.8, 8521.8,\n 0.0302340, 0.5011866, 8.200e-06, -5.870e-06,\n -0.2624880, 0.1116721, -8.020e-05, -1.240e-06,\n 15.2692404, 0.0122560, -3.000e-06,\n 46.4508514, 15.0030632, 0.000e-00,\n 0.5622200, 0.0000721, -1.000e-05,\n 0.0160030, 0.0000717, -9.900e-06,\n 0.0046081, 0.0045851,\n// 208 10 27\n1797329.724938, 5.0, -4.0, 4.0, 8517.2, 8517.2,\n -0.1123030, 0.5425284, 4.080e-05, -8.190e-06,\n 0.4611730, -0.1389713, 5.400e-05, 2.010e-06,\n -12.8877697, -0.0141130, 3.000e-06,\n 258.5408936, 15.0017424, 0.000e-00,\n 0.5476820, -0.0000980, -1.210e-05,\n 0.0015370, -0.0000975, -1.200e-05,\n 0.0047408, 0.0047172,\n// 209 4 21\n1797506.372141, 21.0, -4.0, 4.0, 8512.6, 8512.6,\n 0.2973410, 0.5239431, -1.140e-05, -7.180e-06,\n -0.9613260, 0.1410399, -2.950e-05, -1.880e-06,\n 11.7418003, 0.0138120, -3.000e-06,\n 135.8347321, 15.0040951, 0.000e-00,\n 0.5489850, 0.0001158, -1.110e-05,\n 0.0028330, 0.0001152, -1.110e-05,\n 0.0046166, 0.0045936,\n// 209 10 16\n1797684.090595, 14.0, -4.0, 4.0, 8508.0, 8508.0,\n 0.2437130, 0.5046044, 1.900e-05, -6.360e-06,\n 1.1493800, -0.1489702, -4.100e-06, 1.790e-06,\n -8.9387302, -0.0153800, 2.000e-06,\n 33.2712708, 15.0028791, 0.000e-00,\n 0.5626900, -0.0001035, -1.070e-05,\n 0.0164700, -0.0001030, -1.060e-05,\n 0.0047305, 0.0047069,\n// 210 3 13\n1797831.570000, 2.0, -4.0, 4.0, 8504.1, 8504.1,\n -0.0963360, 0.5539088, -4.300e-06, -9.360e-06,\n 0.9050790, 0.1787084, -3.280e-05, -2.930e-06,\n -3.3556199, 0.0158220, 1.000e-06,\n 207.3608856, 15.0048552, 0.000e-00,\n 0.5342820, 0.0000245, -1.290e-05,\n -0.0117970, 0.0000244, -1.280e-05,\n 0.0046634, 0.0046402,\n// 210 9 5\n1798008.424351, 22.0, -4.0, 4.0, 8499.6, 8499.6,\n -0.4028270, 0.4829403, -2.000e-07, -5.400e-06,\n -1.0016280, -0.1472894, 2.400e-06, 1.580e-06,\n 7.1459298, -0.0154440, -2.000e-06,\n 150.5875244, 15.0040312, 0.000e-00,\n 0.5701910, 0.0000314, -9.800e-06,\n 0.0239330, 0.0000312, -9.700e-06,\n 0.0046774, 0.0046541,\n// 211 3 2\n1798186.258084, 18.0, -4.0, 4.0, 8494.9, 8494.9,\n -0.1622450, 0.5522328, 3.900e-06, -9.100e-06,\n 0.1492550, 0.1674087, 4.130e-05, -2.680e-06,\n -7.4244599, 0.0153520, 1.000e-06,\n 86.5486374, 15.0041180, 0.000e-00,\n 0.5371530, -0.0000639, -1.270e-05,\n -0.0089400, -0.0000636, -1.260e-05,\n 0.0046782, 0.0046549,\n// 211 8 26\n1798362.504379, 0.0, -4.0, 4.0, 8490.3, 8490.3,\n -0.1383850, 0.5064208, -2.710e-05, -6.330e-06,\n -0.2975110, -0.1381939, -4.580e-05, 1.650e-06,\n 11.2280998, -0.0142710, -3.000e-06,\n 179.9029388, 15.0034628, 0.000e-00,\n 0.5596250, 0.0001121, -1.050e-05,\n 0.0134200, 0.0001115, -1.050e-05,\n 0.0046616, 0.0046384,\n// 212 2 20\n1798540.811710, 7.0, -4.0, 4.0, 8485.7, 8485.7,\n -0.1105260, 0.5287219, 2.000e-06, -7.480e-06,\n -0.5962920, 0.1442077, 1.043e-04, -1.950e-06,\n -11.3537598, 0.0144130, 2.000e-06,\n 280.9754333, 15.0029488, 0.000e-00,\n 0.5507100, -0.0001126, -1.150e-05,\n 0.0045490, -0.0001120, -1.140e-05,\n 0.0046937, 0.0046703,\n// 212 8 14\n1798716.882047, 9.0, -4.0, 4.0, 8481.1, 8481.1,\n 0.0051870, 0.5443964, -3.840e-05, -8.150e-06,\n 0.4431290, -0.1254522, -1.104e-04, 1.810e-06,\n 14.8323803, -0.0126710, -3.000e-06,\n 314.4354553, 15.0026674, 0.000e-00,\n 0.5434840, 0.0001187, -1.180e-05,\n -0.0026400, 0.0001181, -1.180e-05,\n 0.0046466, 0.0046235,\n// 213 2 8\n1798895.075294, 14.0, -4.0, 4.0, 8476.5, 8476.5,\n 0.3917040, 0.5029832, -2.370e-05, -6.000e-06,\n -1.2604980, 0.1155956, 1.474e-04, -1.300e-06,\n -15.0405197, 0.0129210, 3.000e-06,\n 25.7333202, 15.0014439, 0.000e-00,\n 0.5665210, -0.0000955, -1.030e-05,\n 0.0202810, -0.0000950, -1.020e-05,\n 0.0047091, 0.0046856,\n// 213 7 5\n1799042.217077, 17.0, -4.0, 4.0, 8472.7, 8472.7,\n -0.1160770, 0.5836358, 8.500e-06, -9.930e-06,\n -1.3840070, 0.0027370, -8.710e-05, -1.500e-07,\n 23.1322594, -0.0035930, -6.000e-06,\n 74.9678268, 14.9994154, 0.000e-00,\n 0.5305410, -0.0000071, -1.280e-05,\n -0.0155190, -0.0000070, -1.280e-05,\n 0.0046056, 0.0045827,\n// 213 8 4\n1799071.512787, 0.0, -4.0, 4.0, 8471.9, 8471.9,\n 0.0256190, 0.5730021, -3.010e-05, -9.690e-06,\n 1.1474280, -0.1033528, -1.845e-04, 1.670e-06,\n 17.8883209, -0.0107030, -4.000e-06,\n 179.2314148, 15.0017214, 0.000e-00,\n 0.5327600, 0.0000476, -1.280e-05,\n -0.0133110, 0.0000473, -1.270e-05,\n 0.0046331, 0.0046100,\n// 213 12 29\n1799219.303068, 19.0, -4.0, 4.0, 8468.1, 8468.1,\n -0.1031820, 0.5077880, 0.000e-00, -5.800e-06,\n 1.0089860, -0.0181496, 1.162e-04, 3.100e-07,\n -23.4071808, 0.0027210, 6.000e-06,\n 103.4113464, 14.9963341, 0.000e-00,\n 0.5725290, 0.0000654, -1.010e-05,\n 0.0262600, 0.0000650, -1.000e-05,\n 0.0047513, 0.0047277,\n// 214 6 25\n1799396.896311, 10.0, -4.0, 4.0, 8463.5, 8463.5,\n 0.3328970, 0.5641158, 1.250e-05, -8.770e-06,\n -0.6539080, 0.0476094, -1.313e-04, -8.500e-07,\n 23.6565399, -0.0006720, -6.000e-06,\n 330.5311890, 14.9991407, 0.000e-00,\n 0.5376950, -0.0001105, -1.200e-05,\n -0.0084010, -0.0001099, -1.200e-05,\n 0.0045998, 0.0045769,\n// 214 12 18\n1799573.448654, 23.0, -4.0, 4.0, 8458.9, 8458.9,\n 0.1577640, 0.5322345, -3.900e-06, -7.070e-06,\n 0.2621290, -0.0654103, 1.556e-04, 9.900e-07,\n -23.6350193, -0.0008070, 6.000e-06,\n 164.7998047, 14.9961319, 0.000e-00,\n 0.5593480, 0.0001143, -1.120e-05,\n 0.0131440, 0.0001138, -1.110e-05,\n 0.0047564, 0.0047327,\n// 215 6 14\n1799751.364839, 21.0, -4.0, 4.0, 8454.3, 8454.3,\n 0.1142340, 0.5263646, 3.740e-05, -6.860e-06,\n 0.1067480, 0.0868428, -1.562e-04, -1.260e-06,\n 23.3967896, 0.0023410, -6.000e-06,\n 136.1119232, 14.9992790, 0.000e-00,\n 0.5521680, -0.0001192, -1.070e-05,\n 0.0060010, -0.0001186, -1.060e-05,\n 0.0045967, 0.0045738,\n// 215 12 8\n1799927.897170, 10.0, -4.0, 4.0, 8449.7, 8449.7,\n 0.1755540, 0.5574547, 1.360e-05, -8.810e-06,\n -0.4647620, -0.1156066, 1.949e-04, 1.970e-06,\n -22.9262009, -0.0041940, 6.000e-06,\n 331.1243591, 14.9966326, 0.000e-00,\n 0.5445710, 0.0000792, -1.250e-05,\n -0.0015590, 0.0000788, -1.250e-05,\n 0.0047584, 0.0047347,\n// 216 6 3\n1800105.533586, 1.0, -4.0, 4.0, 8445.0, 8445.0,\n -0.1145610, 0.4944647, 4.510e-05, -5.620e-06,\n 0.8816800, 0.1211879, -1.690e-04, -1.510e-06,\n 22.3079891, 0.0053120, -5.000e-06,\n 196.5823975, 14.9998894, 0.000e-00,\n 0.5638030, -0.0000512, -9.800e-06,\n 0.0175780, -0.0000510, -9.700e-06,\n 0.0045962, 0.0045733,\n// 216 11 27\n1800282.529519, 1.0, -4.0, 4.0, 8440.4, 8440.4,\n -0.1301860, 0.5607643, 5.370e-05, -9.510e-06,\n -1.0729250, -0.1603456, 2.167e-04, 2.900e-06,\n -21.3668499, -0.0073010, 5.000e-06,\n 197.2460938, 14.9976387, 0.000e-00,\n 0.5385410, -0.0000119, -1.320e-05,\n -0.0075590, -0.0000119, -1.310e-05,\n 0.0047577, 0.0047340,\n// 217 4 23\n1800429.979464, 12.0, -4.0, 4.0, 8436.6, 8436.6,\n 0.7491710, 0.4676527, -1.130e-05, -5.590e-06,\n -0.9547890, 0.2273401, -2.860e-05, -2.890e-06,\n 12.3120804, 0.0133870, -3.000e-06,\n 0.9423200, 15.0038261, 0.000e-00,\n 0.5594310, 0.0000812, -1.020e-05,\n 0.0132270, 0.0000808, -1.020e-05,\n 0.0046155, 0.0045925,\n// 217 10 18\n1800607.641222, 3.0, -4.0, 4.0, 8432.0, 8432.0,\n 0.2646400, 0.4886721, 2.990e-05, -6.920e-06,\n 0.9761710, -0.2533329, 0.000e-00, 3.760e-06,\n -9.5390501, -0.0149730, 2.000e-06,\n 228.3372345, 15.0026808, 0.000e-00,\n 0.5514730, -0.0001074, -1.170e-05,\n 0.0053090, -0.0001069, -1.160e-05,\n 0.0047316, 0.0047080,\n// 218 4 12\n1800784.307426, 19.0, -4.0, 4.0, 8427.4, 8427.4,\n -0.0086140, 0.4884730, 7.800e-06, -6.970e-06,\n -0.4312760, 0.2578042, -3.120e-05, -3.870e-06,\n 8.4781799, 0.0145580, -2.000e-06,\n 105.1265030, 15.0046206, 0.000e-00,\n 0.5451220, 0.0001235, -1.150e-05,\n -0.0010100, 0.0001229, -1.150e-05,\n 0.0046256, 0.0046026,\n// 218 10 7\n1800961.922865, 10.0, -4.0, 4.0, 8422.8, 8422.8,\n 0.0790890, 0.4536373, 2.390e-05, -5.360e-06,\n 0.3032360, -0.2499146, 9.700e-06, 3.130e-06,\n -5.3202500, -0.0157990, 1.000e-06,\n 332.8162231, 15.0035410, 0.000e-00,\n 0.5661660, -0.0000875, -1.040e-05,\n 0.0199280, -0.0000870, -1.030e-05,\n 0.0047196, 0.0046961,\n// 219 4 2\n1801138.903419, 10.0, -4.0, 4.0, 8418.2, 8418.2,\n -0.0199750, 0.5070643, 8.800e-06, -8.330e-06,\n 0.4171070, 0.2800171, -5.120e-05, -4.800e-06,\n 4.5030198, 0.0152850, -1.000e-06,\n 329.1876526, 15.0050545, 0.000e-00,\n 0.5342020, 0.0000461, -1.270e-05,\n -0.0118770, 0.0000459, -1.260e-05,\n 0.0046373, 0.0046142,\n// 219 9 26\n1801315.942292, 11.0, -4.0, 4.0, 8413.6, 8413.6,\n -0.0310280, 0.4387847, 4.200e-06, -4.790e-06,\n -0.4497960, -0.2474623, 2.170e-05, 2.870e-06,\n -0.8591400, -0.0160780, 0.000e-00,\n 347.0781250, 15.0040522, 0.000e-00,\n 0.5724010, -0.0000038, -9.800e-06,\n 0.0261330, -0.0000038, -9.800e-06,\n 0.0047055, 0.0046821,\n// 220 2 21\n1801464.229697, 18.0, -4.0, 4.0, 8409.7, 8409.7,\n 0.9299470, 0.5099577, -6.800e-05, -8.050e-06,\n -1.2339150, 0.2559495, 1.360e-04, -4.210e-06,\n -10.8110399, 0.0143200, 2.000e-06,\n 86.0408783, 15.0030756, 0.000e-00,\n 0.5405210, -0.0001039, -1.240e-05,\n -0.0055880, -0.0001033, -1.240e-05,\n 0.0046915, 0.0046681,\n// 220 3 22\n1801493.603764, 2.0, -4.0, 4.0, 8408.9, 8408.9,\n -0.7777850, 0.5073372, 5.030e-05, -8.410e-06,\n 0.8090150, 0.2832198, -4.620e-05, -4.910e-06,\n 0.3969000, 0.0156310, 0.000e-00,\n 208.2056732, 15.0050678, 0.000e-00,\n 0.5340690, -0.0000351, -1.280e-05,\n -0.0120080, -0.0000349, -1.270e-05,\n 0.0046507, 0.0046275,\n// 220 9 14\n1801669.967473, 11.0, -4.0, 4.0, 8404.3, 8404.3,\n -0.6348310, 0.4527169, 2.600e-06, -5.360e-06,\n -0.9081010, -0.2516885, 2.580e-05, 3.140e-06,\n 3.6154699, -0.0157980, -1.000e-06,\n 346.2428894, 15.0041914, 0.000e-00,\n 0.5644370, 0.0001017, -1.030e-05,\n 0.0182080, 0.0001012, -1.030e-05,\n 0.0046898, 0.0046665,\n// 221 2 10\n1801818.709788, 5.0, -4.0, 4.0, 8400.5, 8400.5,\n 0.3458410, 0.4891900, -3.730e-05, -6.490e-06,\n -0.8011750, 0.2237684, 1.274e-04, -3.130e-06,\n -14.5023699, 0.0129390, 3.000e-06,\n 250.7478790, 15.0016441, 0.000e-00,\n 0.5559970, -0.0001229, -1.110e-05,\n 0.0098100, -0.0001222, -1.100e-05,\n 0.0047067, 0.0046832,\n// 221 8 5\n1801994.846494, 8.0, -4.0, 4.0, 8395.9, 8395.9,\n 0.1696820, 0.5273851, -6.770e-05, -8.190e-06,\n 0.9107460, -0.2098949, -1.531e-04, 3.460e-06,\n 17.5151806, -0.0107390, -4.000e-06,\n 299.2359619, 15.0017519, 0.000e-00,\n 0.5389980, 0.0001078, -1.220e-05,\n -0.0071040, 0.0001072, -1.210e-05,\n 0.0046347, 0.0046116,\n// 222 1 30\n1802172.881591, 9.0, -4.0, 4.0, 8391.3, 8391.3,\n -0.0107150, 0.4736324, -3.140e-05, -5.380e-06,\n -0.1917660, 0.1875637, 1.143e-04, -2.290e-06,\n -17.8248501, 0.0109610, 4.000e-06,\n 310.8503723, 14.9999838, 0.000e-00,\n 0.5704780, -0.0000648, -1.000e-05,\n 0.0242190, -0.0000645, -1.000e-05,\n 0.0047215, 0.0046980,\n// 222 7 26\n1802349.521138, 1.0, -4.0, 4.0, 8386.7, 8386.7,\n 0.3240000, 0.5539946, -6.300e-05, -9.390e-06,\n 0.0617950, -0.1850518, -1.372e-04, 3.320e-06,\n 20.0697193, -0.0084620, -5.000e-06,\n 194.2574158, 15.0007973, 0.000e-00,\n 0.5314570, -0.0000019, -1.290e-05,\n -0.0146080, -0.0000019, -1.280e-05,\n 0.0046226, 0.0045996,\n// 223 1 19\n1802526.854138, 8.0, -4.0, 4.0, 8382.1, 8382.1,\n -0.3993520, 0.4811435, -3.130e-05, -5.360e-06,\n 0.4200760, 0.1539323, 1.079e-04, -1.860e-06,\n -20.5671101, 0.0083570, 5.000e-06,\n 296.4117737, 14.9983568, 0.000e-00,\n 0.5731880, 0.0000457, -9.900e-06,\n 0.0269150, 0.0000455, -9.900e-06,\n 0.0047344, 0.0047108,\n// 223 7 15\n1802704.215434, 17.0, -4.0, 4.0, 8377.5, 8377.5,\n -0.2401880, 0.5536284, -1.410e-05, -8.830e-06,\n -0.5368720, -0.1437853, -1.216e-04, 2.450e-06,\n 21.9975700, -0.0058850, -5.000e-06,\n 74.5345764, 14.9999008, 0.000e-00,\n 0.5359430, -0.0000799, -1.230e-05,\n -0.0101430, -0.0000795, -1.230e-05,\n 0.0046129, 0.0045899,\n// 224 1 8\n1802880.941804, 11.0, -4.0, 4.0, 8372.8, 8372.8,\n -0.0675190, 0.5140759, -4.780e-05, -6.510e-06,\n 1.2030040, 0.1209007, 9.540e-05, -1.660e-06,\n -22.4874001, 0.0052860, 6.000e-06,\n 342.3761597, 14.9970884, 0.000e-00,\n 0.5623940, 0.0001030, -1.080e-05,\n 0.0161760, 0.0001025, -1.080e-05,\n 0.0047443, 0.0047207,\n// 224 6 4\n1803029.258705, 18.0, -4.0, 4.0, 8369.0, 8369.0,\n -0.1518770, 0.5247174, 2.550e-05, -6.540e-06,\n 1.3205740, 0.0168254, -1.998e-04, -1.500e-07,\n 22.5343399, 0.0050830, -5.000e-06,\n 91.5143967, 14.9998274, 0.000e-00,\n 0.5562200, -0.0000986, -1.040e-05,\n 0.0100320, -0.0000982, -1.030e-05,\n 0.0045960, 0.0045731,\n// 224 7 4\n1803058.737854, 6.0, -4.0, 4.0, 8368.2, 8368.2,\n -0.0892990, 0.5318701, -5.100e-06, -7.190e-06,\n -1.3951091, -0.0950910, -8.940e-05, 1.430e-06,\n 23.2231503, -0.0030460, -6.000e-06,\n 270.0158386, 14.9992409, 0.000e-00,\n 0.5492390, -0.0001237, -1.100e-05,\n 0.0030860, -0.0001231, -1.090e-05,\n 0.0046055, 0.0045826,\n// 224 11 28\n1803205.842699, 8.0, -4.0, 4.0, 8364.4, 8364.4,\n -0.2004420, 0.5746696, 1.250e-05, -9.470e-06,\n -0.9314210, -0.0436097, 2.150e-04, 6.000e-07,\n -21.6088295, -0.0071940, 6.000e-06,\n 302.1206970, 14.9975290, 0.000e-00,\n 0.5414840, 0.0000744, -1.290e-05,\n -0.0046310, 0.0000740, -1.280e-05,\n 0.0047577, 0.0047340,\n// 225 5 24\n1803383.360778, 21.0, -4.0, 4.0, 8359.8, 8359.8,\n 0.1118380, 0.5036553, 1.240e-05, -5.670e-06,\n 0.6035430, 0.0515355, -1.487e-04, -5.100e-07,\n 20.7824001, 0.0078450, -5.000e-06,\n 136.7901764, 15.0007544, 0.000e-00,\n 0.5652420, -0.0000269, -9.700e-06,\n 0.0190100, -0.0000268, -9.600e-06,\n 0.0045978, 0.0045749,\n// 225 11 17\n1803560.493845, 0.0, -4.0, 4.0, 8355.2, 8355.2,\n 0.0459440, 0.5754666, 2.310e-05, -9.730e-06,\n -0.2842810, -0.0825770, 1.557e-04, 1.300e-06,\n -19.3838100, -0.0099600, 5.000e-06,\n 182.9679871, 14.9988546, 0.000e-00,\n 0.5391330, -0.0000377, -1.310e-05,\n -0.0069700, -0.0000375, -1.300e-05,\n 0.0047546, 0.0047309,\n// 226 5 13\n1803737.400778, 22.0, -4.0, 4.0, 8350.6, 8350.6,\n 0.2234540, 0.5078136, -6.000e-07, -5.990e-06,\n -0.1448650, 0.0852687, -1.056e-04, -9.400e-07,\n 18.2959003, 0.0102740, -4.000e-06,\n 151.7715149, 15.0019369, 0.000e-00,\n 0.5612060, 0.0000691, -1.000e-05,\n 0.0149930, 0.0000687, -1.000e-05,\n 0.0046017, 0.0045788,\n// 226 11 7\n1803915.082049, 14.0, -4.0, 4.0, 8345.9, 8345.9,\n 0.0998180, 0.5468934, 3.340e-05, -8.190e-06,\n 0.4014740, -0.1120409, 8.470e-05, 1.590e-06,\n -16.4675293, -0.0122800, 4.000e-06,\n 33.4506607, 15.0002728, 0.000e-00,\n 0.5488710, -0.0001113, -1.210e-05,\n 0.0027200, -0.0001108, -1.200e-05,\n 0.0047493, 0.0047257,\n// 227 5 3\n1804091.668223, 4.0, -4.0, 4.0, 8341.3, 8341.3,\n 0.1846890, 0.5315424, -4.500e-06, -7.380e-06,\n -0.9137700, 0.1195707, -5.450e-05, -1.600e-06,\n 15.2534800, 0.0122460, -3.000e-06,\n 241.4373627, 15.0031404, 0.000e-00,\n 0.5474870, 0.0001186, -1.120e-05,\n 0.0013420, 0.0001180, -1.110e-05,\n 0.0046076, 0.0045847,\n// 227 10 27\n1804269.427283, 22.0, -4.0, 4.0, 8336.7, 8336.7,\n 0.1598600, 0.5076976, 2.710e-05, -6.330e-06,\n 1.1573030, -0.1306507, 2.250e-05, 1.550e-06,\n -12.9213800, -0.0141170, 3.000e-06,\n 153.5493164, 15.0016451, 0.000e-00,\n 0.5641680, -0.0001000, -1.060e-05,\n 0.0179400, -0.0000995, -1.060e-05,\n 0.0047415, 0.0047178,\n// 228 3 23\n1804416.901924, 10.0, -4.0, 4.0, 8332.9, 8332.9,\n -0.0949160, 0.5539277, 5.100e-06, -9.400e-06,\n 0.9540350, 0.1810137, -6.150e-05, -2.980e-06,\n 0.9428800, 0.0158510, 0.000e-00,\n 328.3347473, 15.0051994, 0.000e-00,\n 0.5332680, 0.0000178, -1.290e-05,\n -0.0128060, 0.0000177, -1.280e-05,\n 0.0046488, 0.0046257,\n// 228 9 16\n1804593.726699, 5.0, -4.0, 4.0, 8328.3, 8328.3,\n -0.5543960, 0.4808125, 1.120e-05, -5.390e-06,\n -0.9956340, -0.1548017, 2.620e-05, 1.670e-06,\n 2.9012001, -0.0161070, -1.000e-06,\n 256.3800964, 15.0042734, 0.000e-00,\n 0.5709240, 0.0000423, -9.800e-06,\n 0.0246630, 0.0000421, -9.800e-06,\n 0.0046925, 0.0046691,\n// 229 3 13\n1804771.593463, 2.0, -4.0, 4.0, 8323.6, 8323.6,\n -0.2040040, 0.5484896, 1.430e-05, -8.990e-06,\n 0.1773720, 0.1760137, 1.350e-05, -2.800e-06,\n -3.1962800, 0.0158390, 0.000e-00,\n 207.3872070, 15.0048571, 0.000e-00,\n 0.5368400, -0.0000676, -1.260e-05,\n -0.0092510, -0.0000672, -1.250e-05,\n 0.0046632, 0.0046400,\n// 229 9 5\n1804947.813984, 8.0, -4.0, 4.0, 8319.1, 8319.1,\n 0.1265330, 0.5037539, -3.200e-05, -6.340e-06,\n -0.4247090, -0.1530249, -1.630e-05, 1.850e-06,\n 7.2156301, -0.0154100, -2.000e-06,\n 300.5774536, 15.0040789, 0.000e-00,\n 0.5597360, 0.0001031, -1.060e-05,\n 0.0135310, 0.0001026, -1.050e-05,\n 0.0046763, 0.0046530,\n// 230 3 2\n1805126.140734, 15.0, -4.0, 4.0, 8314.4, 8314.4,\n -0.0480320, 0.5225979, 4.900e-06, -7.320e-06,\n -0.5507860, 0.1589354, 7.620e-05, -2.140e-06,\n -7.3184900, 0.0153950, 1.000e-06,\n 41.5640984, 15.0040579, 0.000e-00,\n 0.5507420, -0.0001155, -1.140e-05,\n 0.0045820, -0.0001149, -1.130e-05,\n 0.0046790, 0.0046557,\n// 230 8 25\n1805302.203664, 17.0, -4.0, 4.0, 8309.8, 8309.8,\n 0.1613630, 0.5404789, -4.230e-05, -8.160e-06,\n 0.3516260, -0.1479700, -8.090e-05, 2.160e-06,\n 11.1877499, -0.0142560, -2.000e-06,\n 74.9057922, 15.0035639, 0.000e-00,\n 0.5434640, 0.0001099, -1.190e-05,\n -0.0026600, 0.0001094, -1.190e-05,\n 0.0046604, 0.0046372,\n// 231 2 19\n1805480.392477, 21.0, -4.0, 4.0, 8305.2, 8305.2,\n 0.1323660, 0.4965604, -1.260e-05, -5.870e-06,\n -1.2988310, 0.1361194, 1.232e-04, -1.530e-06,\n -11.3591995, 0.0144330, 2.000e-06,\n 130.9772339, 15.0028553, 0.000e-00,\n 0.5663650, -0.0000789, -1.020e-05,\n 0.0201270, -0.0000785, -1.010e-05,\n 0.0046951, 0.0046717,\n// 231 7 17\n1805627.532297, 1.0, -4.0, 4.0, 8301.3, 8301.3,\n 0.0279640, 0.5817913, -9.000e-06, -9.890e-06,\n -1.4548360, -0.0414335, -7.140e-05, 6.100e-07,\n 21.7830601, -0.0064950, -5.000e-06,\n 194.4848633, 15.0000820, 0.000e-00,\n 0.5310860, -0.0000242, -1.280e-05,\n -0.0149770, -0.0000241, -1.280e-05,\n 0.0046137, 0.0045907,\n// 231 8 15\n1805656.838537, 8.0, -4.0, 4.0, 8300.6, 8300.6,\n 0.1756040, 0.5672988, -3.800e-05, -9.620e-06,\n 1.0670450, -0.1330556, -1.558e-04, 2.180e-06,\n 14.7182398, -0.0127090, -3.000e-06,\n 299.4444275, 15.0027666, 0.000e-00,\n 0.5332050, 0.0000372, -1.290e-05,\n -0.0128690, 0.0000370, -1.280e-05,\n 0.0046460, 0.0046229,\n// 232 1 10\n1805804.635401, 3.0, -4.0, 4.0, 8296.7, 8296.7,\n -0.1737230, 0.5086907, -1.000e-05, -5.850e-06,\n 1.0071501, 0.0234217, 1.049e-04, -1.800e-07,\n -22.2444191, 0.0060370, 6.000e-06,\n 222.2104340, 14.9972544, 0.000e-00,\n 0.5715430, 0.0000689, -1.010e-05,\n 0.0252780, 0.0000686, -1.000e-05,\n 0.0047433, 0.0047197,\n// 232 7 5\n1805982.199954, 17.0, -4.0, 4.0, 8292.1, 8292.1,\n 0.1174790, 0.5641707, 1.020e-05, -8.680e-06,\n -0.7540590, 0.0029570, -1.229e-04, -1.400e-07,\n 23.0930309, -0.0037080, -6.000e-06,\n 74.9353409, 14.9993906, 0.000e-00,\n 0.5388550, -0.0001066, -1.200e-05,\n -0.0072460, -0.0001060, -1.190e-05,\n 0.0046059, 0.0045829,\n// 232 12 29\n1806158.799026, 7.0, -4.0, 4.0, 8287.5, 8287.5,\n -0.0844680, 0.5377688, -8.400e-06, -7.230e-06,\n 0.2866390, -0.0200350, 1.520e-04, 3.800e-07,\n -23.4109001, 0.0026880, 6.000e-06,\n 283.4386292, 14.9964056, 0.000e-00,\n 0.5581250, 0.0001234, -1.120e-05,\n 0.0119280, 0.0001228, -1.120e-05,\n 0.0047509, 0.0047273,\n// 233 6 25\n1806336.648740, 4.0, -4.0, 4.0, 8282.9, 8282.9,\n 0.2272770, 0.5294727, 2.060e-05, -6.830e-06,\n 0.0253570, 0.0446569, -1.572e-04, -6.900e-07,\n 23.6506405, -0.0007120, -6.000e-06,\n 240.5079956, 14.9990511, 0.000e-00,\n 0.5533280, -0.0001205, -1.060e-05,\n 0.0071550, -0.0001199, -1.060e-05,\n 0.0046005, 0.0045776,\n// 233 12 18\n1806513.262433, 18.0, -4.0, 4.0, 8278.3, 8278.3,\n -0.2190750, 0.5665783, 1.930e-05, -9.050e-06,\n -0.3926120, -0.0687089, 1.995e-04, 1.230e-06,\n -23.6352596, -0.0007420, 6.000e-06,\n 89.7910233, 14.9962244, 0.000e-00,\n 0.5437650, 0.0000941, -1.260e-05,\n -0.0023610, 0.0000936, -1.250e-05,\n 0.0047557, 0.0047320,\n// 234 6 14\n1806690.799864, 7.0, -4.0, 4.0, 8273.6, 8273.6,\n -0.2292620, 0.5013890, 3.860e-05, -5.680e-06,\n 0.7702670, 0.0833213, -1.756e-04, -1.060e-06,\n 23.3825703, 0.0023990, -5.000e-06,\n 286.1049500, 14.9992180, 0.000e-00,\n 0.5642930, -0.0000367, -9.800e-06,\n 0.0180650, -0.0000365, -9.700e-06,\n 0.0045974, 0.0045745,\n// 234 12 8\n1806867.900171, 10.0, -4.0, 4.0, 8269.0, 8269.0,\n 0.0151030, 0.5716398, 3.720e-05, -9.720e-06,\n -1.0907750, -0.1153281, 2.358e-04, 2.120e-06,\n -22.9630108, -0.0040730, 6.000e-06,\n 331.0936279, 14.9966459, 0.000e-00,\n 0.5386000, -0.0000208, -1.320e-05,\n -0.0075000, -0.0000207, -1.310e-05,\n 0.0047580, 0.0047343,\n// 235 5 4\n1807015.260359, 18.0, -4.0, 4.0, 8265.2, 8265.2,\n 0.3814710, 0.4787885, 7.100e-06, -5.800e-06,\n -1.2070640, 0.2074091, -3.970e-05, -2.680e-06,\n 15.7438698, 0.0117590, -4.000e-06,\n 91.5055084, 15.0028439, 0.000e-00,\n 0.5580250, 0.0001008, -1.030e-05,\n 0.0118290, 0.0001003, -1.020e-05,\n 0.0046071, 0.0045841,\n// 235 6 3\n1807044.826350, 8.0, -4.0, 4.0, 8264.4, 8264.4,\n -0.2840040, 0.4964699, 3.640e-05, -5.710e-06,\n 1.5177480, 0.1216850, -1.973e-04, -1.510e-06,\n 22.2642097, 0.0053900, -5.000e-06,\n 301.5767822, 14.9999161, 0.000e-00,\n 0.5628440, 0.0000564, -9.800e-06,\n 0.0166240, 0.0000561, -9.800e-06,\n 0.0045963, 0.0045734,\n// 235 10 29\n1807192.990558, 12.0, -4.0, 4.0, 8260.6, 8260.6,\n 0.5406710, 0.4959155, 2.870e-05, -6.970e-06,\n 0.8538280, -0.2341814, 3.190e-05, 3.460e-06,\n -13.4843197, -0.0136190, 3.000e-06,\n 3.5657699, 15.0014124, 0.000e-00,\n 0.5528420, -0.0001234, -1.160e-05,\n 0.0066710, -0.0001228, -1.160e-05,\n 0.0047421, 0.0047185,\n// 236 4 23\n1807369.611171, 3.0, -4.0, 4.0, 8255.9, 8255.9,\n 0.3598600, 0.4983879, 1.100e-06, -7.190e-06,\n -0.3180070, 0.2430414, -5.840e-05, -3.690e-06,\n 12.3184605, 0.0133460, -3.000e-06,\n 225.9369507, 15.0038939, 0.000e-00,\n 0.5436780, 0.0001059, -1.160e-05,\n -0.0024480, 0.0001054, -1.150e-05,\n 0.0046151, 0.0045921,\n// 236 10 17\n1807547.251277, 18.0, -4.0, 4.0, 8251.3, 8251.3,\n 0.1360200, 0.4578787, 3.300e-05, -5.370e-06,\n 0.2953300, -0.2385416, 3.380e-05, 2.980e-06,\n -9.5443401, -0.0150040, 2.000e-06,\n 93.3375168, 15.0026073, 0.000e-00,\n 0.5676190, -0.0000868, -1.030e-05,\n 0.0213740, -0.0000864, -1.030e-05,\n 0.0047320, 0.0047085,\n// 237 4 12\n1807724.223563, 17.0, -4.0, 4.0, 8246.7, 8246.7,\n -0.3339650, 0.5134074, 3.670e-05, -8.500e-06,\n 0.1787740, 0.2705700, -6.200e-05, -4.680e-06,\n 8.5905895, 0.0144990, -2.000e-06,\n 75.1489868, 15.0046587, 0.000e-00,\n 0.5331090, 0.0000581, -1.270e-05,\n -0.0129640, 0.0000578, -1.260e-05,\n 0.0046251, 0.0046021,\n// 237 10 6\n1807901.256504, 18.0, -4.0, 4.0, 8242.1, 8242.1,\n -0.2509900, 0.4408825, 2.260e-05, -4.810e-06,\n -0.2921240, -0.2433224, 3.840e-05, 2.830e-06,\n -5.2122202, -0.0158250, 1.000e-06,\n 92.7986069, 15.0035324, 0.000e-00,\n 0.5732650, 0.0000123, -9.800e-06,\n 0.0269920, 0.0000122, -9.800e-06,\n 0.0047193, 0.0046958,\n// 238 4 2\n1808078.930468, 10.0, -4.0, 4.0, 8237.5, 8237.5,\n -0.6660560, 0.5088624, 5.810e-05, -8.410e-06,\n 0.8148150, 0.2791057, -6.960e-05, -4.830e-06,\n 4.6543398, 0.0152670, -1.000e-06,\n 329.2200928, 15.0050430, 0.000e-00,\n 0.5336960, -0.0000447, -1.270e-05,\n -0.0123790, -0.0000444, -1.270e-05,\n 0.0046372, 0.0046141,\n// 238 9 25\n1808255.284539, 19.0, -4.0, 4.0, 8232.9, 8232.9,\n -0.4439330, 0.4527586, 7.700e-06, -5.400e-06,\n -0.9716010, -0.2543302, 5.080e-05, 3.200e-06,\n -0.7494800, -0.0160570, 0.000e-00,\n 107.0582581, 15.0040998, 0.000e-00,\n 0.5646470, 0.0000973, -1.040e-05,\n 0.0184170, 0.0000968, -1.030e-05,\n 0.0047044, 0.0046810,\n// 239 2 21\n1808404.039011, 13.0, -4.0, 4.0, 8229.0, 8229.0,\n 0.4399370, 0.4782571, -3.310e-05, -6.270e-06,\n -0.7923500, 0.2424297, 1.023e-04, -3.340e-06,\n -10.7435102, 0.0143740, 2.000e-06,\n 11.0485096, 15.0030127, 0.000e-00,\n 0.5560180, -0.0001241, -1.100e-05,\n 0.0098310, -0.0001235, -1.100e-05,\n 0.0046922, 0.0046689,\n// 239 8 16\n1808580.166843, 16.0, -4.0, 4.0, 8224.4, 8224.4,\n 0.3978450, 0.5174684, -7.400e-05, -8.080e-06,\n 0.8748530, -0.2368900, -1.277e-04, 3.910e-06,\n 14.2778196, -0.0126940, -3.000e-06,\n 59.4902382, 15.0027723, 0.000e-00,\n 0.5390380, 0.0000968, -1.230e-05,\n -0.0070640, 0.0000963, -1.220e-05,\n 0.0046479, 0.0046247,\n// 240 2 10\n1808758.200493, 17.0, -4.0, 4.0, 8219.7, 8219.7,\n 0.1713140, 0.4623124, -3.410e-05, -5.210e-06,\n -0.1437900, 0.2122267, 8.900e-05, -2.560e-06,\n -14.5348797, 0.0129520, 3.000e-06,\n 70.7435684, 15.0015554, 0.000e-00,\n 0.5700680, -0.0000670, -1.000e-05,\n 0.0238110, -0.0000667, -9.900e-06,\n 0.0047078, 0.0046844,\n// 240 8 5\n1808934.842536, 8.0, -4.0, 4.0, 8215.1, 8215.1,\n -0.0366910, 0.5418068, -4.410e-05, -9.170e-06,\n 0.2541790, -0.2181953, -1.252e-04, 3.880e-06,\n 17.4070492, -0.0107970, -4.000e-06,\n 299.2381287, 15.0018339, 0.000e-00,\n 0.5320430, 0.0000104, -1.290e-05,\n -0.0140250, 0.0000104, -1.280e-05,\n 0.0046344, 0.0046114,\n// 241 1 29\n1809112.176306, 16.0, -4.0, 4.0, 8210.5, 8210.5,\n -0.2922550, 0.4708416, -3.590e-05, -5.250e-06,\n 0.4224690, 0.1854339, 8.540e-05, -2.220e-06,\n -17.9109497, 0.0109000, 4.000e-06,\n 55.8636703, 14.9999237, 0.000e-00,\n 0.5721110, 0.0000453, -9.900e-06,\n 0.0258430, 0.0000450, -9.900e-06,\n 0.0047223, 0.0046988,\n// 241 7 26\n1809289.527781, 1.0, -4.0, 4.0, 8205.9, 8205.9,\n 0.0159780, 0.5406773, -3.060e-05, -8.540e-06,\n -0.5496850, -0.1815708, -1.032e-04, 3.040e-06,\n 19.9823704, -0.0085650, -5.000e-06,\n 194.2438354, 15.0008059, 0.000e-00,\n 0.5371270, -0.0000963, -1.230e-05,\n -0.0089660, -0.0000958, -1.220e-05,\n 0.0046230, 0.0046000,\n// 242 1 18\n1809466.281971, 19.0, -4.0, 4.0, 8201.3, 8201.3,\n -0.2356430, 0.5053440, -4.710e-05, -6.460e-06,\n 1.1537130, 0.1599215, 7.740e-05, -2.180e-06,\n -20.5990200, 0.0083020, 5.000e-06,\n 101.4319992, 14.9983931, 0.000e-00,\n 0.5609510, 0.0001078, -1.090e-05,\n 0.0147390, 0.0001072, -1.080e-05,\n 0.0047344, 0.0047108,\n// 242 6 16\n1809614.536348, 1.0, -4.0, 4.0, 8197.4, 8197.4,\n 0.1299610, 0.5226704, 2.400e-06, -6.450e-06,\n 1.4047650, -0.0235351, -2.114e-04, 3.600e-07,\n 23.4822903, 0.0021310, -5.000e-06,\n 196.0054474, 14.9992018, 0.000e-00,\n 0.5571210, -0.0001014, -1.030e-05,\n 0.0109280, -0.0001009, -1.020e-05,\n 0.0045974, 0.0045745,\n// 242 7 15\n1809644.030426, 13.0, -4.0, 4.0, 8196.6, 8196.6,\n -0.1905570, 0.5209561, -9.800e-06, -6.940e-06,\n -1.3164010, -0.1347991, -8.210e-05, 1.960e-06,\n 21.9608002, -0.0059690, -5.000e-06,\n 14.5143204, 14.9998407, 0.000e-00,\n 0.5506860, -0.0001219, -1.090e-05,\n 0.0045260, -0.0001213, -1.090e-05,\n 0.0046134, 0.0045904,\n// 242 12 9\n1809791.211048, 17.0, -4.0, 4.0, 8192.8, 8192.8,\n -0.0333040, 0.5773292, -8.600e-06, -9.550e-06,\n -0.9439350, 0.0026035, 2.300e-04, -1.700e-07,\n -23.0960102, -0.0039300, 6.000e-06,\n 75.9389496, 14.9965754, 0.000e-00,\n 0.5410790, 0.0000650, -1.290e-05,\n -0.0050340, 0.0000647, -1.280e-05,\n 0.0047579, 0.0047342,\n// 243 6 5\n1809968.625165, 3.0, -4.0, 4.0, 8188.2, 8188.2,\n -0.0230910, 0.5058192, 7.200e-06, -5.680e-06,\n 0.6769780, 0.0157564, -1.658e-04, -1.000e-07,\n 22.5070992, 0.0051420, -5.000e-06,\n 226.5040588, 14.9997959, 0.000e-00,\n 0.5652910, -0.0000129, -9.700e-06,\n 0.0190580, -0.0000128, -9.600e-06,\n 0.0045963, 0.0045734,\n// 243 11 29\n1810145.862845, 9.0, -4.0, 4.0, 8183.5, 8183.5,\n 0.1494420, 0.5793328, 1.000e-05, -9.760e-06,\n -0.2886300, -0.0408484, 1.781e-04, 5.800e-07,\n -21.6815300, -0.0070760, 6.000e-06,\n 317.0928955, 14.9974957, 0.000e-00,\n 0.5395350, -0.0000473, -1.310e-05,\n -0.0065700, -0.0000470, -1.300e-05,\n 0.0047577, 0.0047340,\n// 244 5 24\n1810322.673318, 4.0, -4.0, 4.0, 8178.9, 8178.9,\n -0.0721730, 0.5136811, 4.100e-06, -6.120e-06,\n -0.1028490, 0.0535421, -1.260e-04, -5.600e-07,\n 20.7238903, 0.0079110, -5.000e-06,\n 241.7807770, 15.0008078, 0.000e-00,\n 0.5602200, 0.0000855, -1.010e-05,\n 0.0140120, 0.0000850, -1.000e-05,\n 0.0045977, 0.0045748,\n// 244 11 17\n1810500.440933, 23.0, -4.0, 4.0, 8174.3, 8174.3,\n 0.2877290, 0.5509715, 2.260e-05, -8.190e-06,\n 0.3741460, -0.0779967, 1.120e-04, 1.070e-06,\n -19.4666309, -0.0098830, 5.000e-06,\n 167.9559784, 14.9987469, 0.000e-00,\n 0.5499120, -0.0001233, -1.200e-05,\n 0.0037560, -0.0001227, -1.190e-05,\n 0.0047550, 0.0047314,\n// 245 5 13\n1810676.961847, 11.0, -4.0, 4.0, 8169.7, 8169.7,\n 0.0976760, 0.5393103, -2.000e-06, -7.580e-06,\n -0.8499690, 0.0916805, -7.900e-05, -1.220e-06,\n 18.2815495, 0.0102700, -4.000e-06,\n 346.7623596, 15.0020161, 0.000e-00,\n 0.5461540, 0.0001199, -1.130e-05,\n 0.0000170, 0.0001193, -1.120e-05,\n 0.0046014, 0.0045785,\n// 245 11 7\n1810854.767377, 6.0, -4.0, 4.0, 8165.0, 8165.0,\n 0.0195460, 0.5116890, 3.390e-05, -6.320e-06,\n 1.1747270, -0.1054630, 4.850e-05, 1.220e-06,\n -16.4827709, -0.0122830, 4.000e-06,\n 273.4605408, 15.0001822, 0.000e-00,\n 0.5654610, -0.0000946, -1.060e-05,\n 0.0192270, -0.0000941, -1.050e-05,\n 0.0047497, 0.0047260,\n// 246 4 3\n1811002.228220, 17.0, -4.0, 4.0, 8161.2, 8161.2,\n -0.5641110, 0.5560815, 3.800e-05, -9.460e-06,\n 0.8581740, 0.1763533, -8.270e-05, -2.910e-06,\n 5.1696901, 0.0154320, -1.000e-06,\n 74.3443680, 15.0051212, 0.000e-00,\n 0.5323520, 0.0000332, -1.290e-05,\n -0.0137160, 0.0000331, -1.280e-05,\n 0.0046357, 0.0046126,\n// 246 9 27\n1811179.035901, 13.0, -4.0, 4.0, 8156.6, 8156.6,\n -0.2888440, 0.4807769, 9.200e-06, -5.400e-06,\n -1.1170460, -0.1559502, 5.440e-05, 1.680e-06,\n -1.4731700, -0.0162850, 0.000e-00,\n 17.1894398, 15.0041151, 0.000e-00,\n 0.5715990, 0.0000365, -9.900e-06,\n 0.0253350, 0.0000363, -9.800e-06,\n 0.0047068, 0.0046834,\n// 247 3 24\n1811356.922642, 10.0, -4.0, 4.0, 8151.9, 8151.9,\n -0.1646930, 0.5468715, 2.130e-05, -8.900e-06,\n 0.2405040, 0.1774078, -1.540e-05, -2.810e-06,\n 1.0995800, 0.0158540, 0.000e-00,\n 328.3701172, 15.0051765, 0.000e-00,\n 0.5365960, -0.0000747, -1.250e-05,\n -0.0094940, -0.0000744, -1.250e-05,\n 0.0046490, 0.0046258,\n// 247 9 16\n1811533.130866, 15.0, -4.0, 4.0, 8147.3, 8147.3,\n -0.1953960, 0.5028463, -1.290e-05, -6.400e-06,\n -0.3656490, -0.1613391, 6.500e-06, 1.980e-06,\n 2.9739699, -0.0160790, -1.000e-06,\n 46.3675499, 15.0043316, 0.000e-00,\n 0.5597270, 0.0001185, -1.070e-05,\n 0.0135210, 0.0001179, -1.060e-05,\n 0.0046913, 0.0046679,\n// 248 3 12\n1811711.461816, 23.0, -4.0, 4.0, 8142.7, 8142.7,\n 0.1008030, 0.5182947, 6.000e-06, -7.190e-06,\n -0.4623390, 0.1665844, 4.700e-05, -2.230e-06,\n -3.0890801, 0.0158700, 0.000e-00,\n 162.4113159, 15.0047903, 0.000e-00,\n 0.5507430, -0.0001222, -1.130e-05,\n 0.0045820, -0.0001215, -1.120e-05,\n 0.0046639, 0.0046406,\n// 248 9 5\n1811887.531442, 1.0, -4.0, 4.0, 8138.0, 8138.0,\n 0.2301060, 0.5376427, -3.940e-05, -8.180e-06,\n 0.2824500, -0.1636429, -5.200e-05, 2.420e-06,\n 7.1743398, -0.0153900, -2.000e-06,\n 195.5858154, 15.0041695, 0.000e-00,\n 0.5435250, 0.0001043, -1.200e-05,\n -0.0026000, 0.0001037, -1.200e-05,\n 0.0046755, 0.0046522,\n// 249 3 2\n1812065.702140, 5.0, -4.0, 4.0, 8133.4, 8133.4,\n 0.4384140, 0.4913433, -1.880e-05, -5.780e-06,\n -1.1737320, 0.1501302, 9.380e-05, -1.690e-06,\n -7.3271999, 0.0154150, 1.000e-06,\n 251.5704956, 15.0039740, 0.000e-00,\n 0.5660200, -0.0000859, -1.010e-05,\n 0.0197830, -0.0000854, -1.010e-05,\n 0.0046800, 0.0046567,\n// 249 7 27\n1812212.850338, 8.0, -4.0, 4.0, 8129.6, 8129.6,\n -0.4460770, 0.5770813, 8.600e-06, -9.790e-06,\n -1.4634120, -0.0811531, -5.230e-05, 1.290e-06,\n 19.6854591, -0.0091190, -5.000e-06,\n 299.2278748, 15.0010271, 0.000e-00,\n 0.5318300, -0.0000140, -1.280e-05,\n -0.0142370, -0.0000139, -1.280e-05,\n 0.0046241, 0.0046011,\n// 249 8 25\n1812242.169551, 16.0, -4.0, 4.0, 8128.8, 8128.8,\n 0.2364950, 0.5618062, -3.740e-05, -9.540e-06,\n 1.0036310, -0.1558100, -1.265e-04, 2.570e-06,\n 11.0596800, -0.0142800, -2.000e-06,\n 59.9217415, 15.0036440, 0.000e-00,\n 0.5337650, 0.0000299, -1.290e-05,\n -0.0123110, 0.0000298, -1.280e-05,\n 0.0046603, 0.0046371,\n// 250 1 20\n1812389.964425, 11.0, -4.0, 4.0, 8124.9, 8124.9,\n -0.1975870, 0.5067826, -1.800e-05, -5.860e-06,\n 1.0112690, 0.0613172, 8.620e-05, -6.300e-07,\n -20.2280903, 0.0089870, 5.000e-06,\n 341.3194275, 14.9986372, 0.000e-00,\n 0.5703750, 0.0000708, -1.010e-05,\n 0.0241170, 0.0000705, -1.010e-05,\n 0.0047329, 0.0047094,\n// 250 7 17\n1812567.505497, 0.0, -4.0, 4.0, 8120.3, 8120.3,\n -0.1316700, 0.5608054, 1.110e-05, -8.540e-06,\n -0.8192460, -0.0392078, -1.085e-04, 5.100e-07,\n 21.7217007, -0.0065940, -5.000e-06,\n 179.4630280, 15.0000610, 0.000e-00,\n 0.5401690, -0.0001013, -1.190e-05,\n -0.0059390, -0.0001008, -1.180e-05,\n 0.0046141, 0.0045912,\n// 251 1 9\n1812744.148264, 16.0, -4.0, 4.0, 8115.7, 8115.7,\n 0.2253480, 0.5395086, -3.380e-05, -7.320e-06,\n 0.2996060, 0.0242938, 1.395e-04, -2.400e-07,\n -22.2503605, 0.0060160, 6.000e-06,\n 57.2217293, 14.9973230, 0.000e-00,\n 0.5568860, 0.0001093, -1.130e-05,\n 0.0106950, 0.0001087, -1.120e-05,\n 0.0047431, 0.0047195,\n// 251 7 6\n1812921.932439, 10.0, -4.0, 4.0, 8111.0, 8111.0,\n -0.1999100, 0.5292093, 2.430e-05, -6.750e-06,\n -0.0749260, 0.0031428, -1.493e-04, -1.400e-07,\n 23.0790100, -0.0037400, -6.000e-06,\n 329.9172974, 14.9993124, 0.000e-00,\n 0.5546960, -0.0001004, -1.060e-05,\n 0.0085160, -0.0000999, -1.050e-05,\n 0.0046063, 0.0045834,\n// 251 12 30\n1813098.627588, 3.0, -4.0, 4.0, 8106.4, 8106.4,\n -0.0499710, 0.5717189, -3.600e-06, -9.200e-06,\n -0.4107880, -0.0200856, 1.983e-04, 4.300e-07,\n -23.3927002, 0.0027610, 6.000e-06,\n 223.4156799, 14.9965010, 0.000e-00,\n 0.5429440, 0.0000836, -1.270e-05,\n -0.0031780, 0.0000831, -1.260e-05,\n 0.0047505, 0.0047269,\n// 252 6 24\n1813276.065986, 14.0, -4.0, 4.0, 8101.8, 8101.8,\n 0.1496940, 0.5056587, 1.290e-05, -5.720e-06,\n 0.7266740, 0.0432548, -1.778e-04, -5.900e-07,\n 23.6493607, -0.0006570, -6.000e-06,\n 30.5078201, 14.9989939, 0.000e-00,\n 0.5648220, -0.0000417, -9.700e-06,\n 0.0185920, -0.0000415, -9.700e-06,\n 0.0046007, 0.0045778,\n// 252 12 18\n1813453.270363, 18.0, -4.0, 4.0, 8097.2, 8097.2,\n -0.4050420, 0.5791294, 4.490e-05, -9.850e-06,\n -1.0248170, -0.0670523, 2.409e-04, 1.290e-06,\n -23.6395397, -0.0006170, 6.000e-06,\n 89.7468338, 14.9962511, 0.000e-00,\n 0.5385590, -0.0000035, -1.310e-05,\n -0.0075410, -0.0000035, -1.310e-05,\n 0.0047555, 0.0047318,\n// 253 5 15\n1813600.539576, 1.0, -4.0, 4.0, 8093.3, 8093.3,\n 0.4871600, 0.4911484, 5.000e-06, -6.020e-06,\n -1.2429050, 0.1814355, -5.830e-05, -2.390e-06,\n 18.6915493, 0.0097140, -4.000e-06,\n 196.7787933, 15.0017214, 0.000e-00,\n 0.5568280, 0.0000989, -1.030e-05,\n 0.0106370, 0.0000984, -1.030e-05,\n 0.0046010, 0.0045781,\n// 253 6 13\n1813630.094525, 14.0, -4.0, 4.0, 8092.5, 8092.5,\n -0.3742970, 0.5053228, 2.910e-05, -5.860e-06,\n 1.4122289, 0.0841330, -2.041e-04, -1.070e-06,\n 23.3599396, 0.0024820, -5.000e-06,\n 31.1079807, 14.9992437, 0.000e-00,\n 0.5623340, 0.0000714, -9.900e-06,\n 0.0161160, 0.0000711, -9.800e-06,\n 0.0045971, 0.0045742,\n// 253 11 8\n1813778.342742, 20.0, -4.0, 4.0, 8088.7, 8088.7,\n 0.2719660, 0.5052251, 4.680e-05, -7.030e-06,\n 0.9841570, -0.2081520, 5.310e-05, 3.060e-06,\n -16.9690399, -0.0117000, 4.000e-06,\n 123.4192276, 14.9999371, 0.000e-00,\n 0.5541990, -0.0001143, -1.160e-05,\n 0.0080210, -0.0001137, -1.150e-05,\n 0.0047502, 0.0047265,\n// 254 5 4\n1813954.913585, 10.0, -4.0, 4.0, 8084.0, 8084.0,\n 0.2420610, 0.5104846, 1.260e-05, -7.460e-06,\n -0.4535500, 0.2219097, -7.440e-05, -3.430e-06,\n 15.7644100, 0.0117110, -3.000e-06,\n 331.4905701, 15.0029087, 0.000e-00,\n 0.5422640, 0.0001104, -1.170e-05,\n -0.0038540, 0.0001099, -1.160e-05,\n 0.0046067, 0.0045837,\n// 254 10 29\n1814132.582558, 2.0, -4.0, 4.0, 8079.4, 8079.4,\n 0.1552700, 0.4649855, 4.120e-05, -5.420e-06,\n 0.3046070, -0.2208269, 5.820e-05, 2.750e-06,\n -13.4716501, -0.0136520, 3.000e-06,\n 213.5735931, 15.0013447, 0.000e-00,\n 0.5689160, -0.0000846, -1.030e-05,\n 0.0226650, -0.0000841, -1.020e-05,\n 0.0047423, 0.0047187,\n// 255 4 24\n1814309.541200, 1.0, -4.0, 4.0, 8074.8, 8074.8,\n -0.1032910, 0.5226933, 3.550e-05, -8.700e-06,\n 0.2271160, 0.2543778, -8.800e-05, -4.430e-06,\n 12.4258299, 0.0132760, -3.000e-06,\n 195.9409180, 15.0039186, 0.000e-00,\n 0.5322130, 0.0000429, -1.270e-05,\n -0.0138550, 0.0000427, -1.270e-05,\n 0.0046147, 0.0045917,\n// 255 10 18\n1814486.575731, 2.0, -4.0, 4.0, 8070.1, 8070.1,\n -0.0819630, 0.4462787, 2.740e-05, -4.870e-06,\n -0.3552850, -0.2331086, 6.370e-05, 2.720e-06,\n -9.4370499, -0.0150410, 2.000e-06,\n 213.3362427, 15.0026121, 0.000e-00,\n 0.5739950, 0.0000109, -9.800e-06,\n 0.0277190, 0.0000109, -9.800e-06,\n 0.0047316, 0.0047081,\n// 256 4 12\n1814664.251504, 18.0, -4.0, 4.0, 8065.5, 8065.5,\n -0.4713420, 0.5136686, 6.040e-05, -8.460e-06,\n 0.8566840, 0.2684731, -9.490e-05, -4.630e-06,\n 8.7503996, 0.0144620, -2.000e-06,\n 90.1761780, 15.0046272, 0.000e-00,\n 0.5334310, -0.0000575, -1.270e-05,\n -0.0126440, -0.0000572, -1.260e-05,\n 0.0046251, 0.0046021,\n// 256 10 6\n1814840.608577, 3.0, -4.0, 4.0, 8060.9, 8060.9,\n -0.3186380, 0.4562340, 1.520e-05, -5.480e-06,\n -1.0051020, -0.2508897, 7.510e-05, 3.180e-06,\n -5.1165600, -0.0158130, 1.000e-06,\n 227.7927551, 15.0035906, 0.000e-00,\n 0.5647720, 0.0000958, -1.050e-05,\n 0.0185420, 0.0000954, -1.040e-05,\n 0.0047182, 0.0046947,\n// 257 3 3\n1814989.360112, 21.0, -4.0, 4.0, 8057.0, 8057.0,\n 0.6188750, 0.4700246, -2.960e-05, -6.100e-06,\n -0.7425980, 0.2543623, 7.650e-05, -3.460e-06,\n -6.6724300, 0.0152790, 1.000e-06,\n 131.6914978, 15.0040646, 0.000e-00,\n 0.5559920, -0.0001291, -1.090e-05,\n 0.0098050, -0.0001285, -1.090e-05,\n 0.0046774, 0.0046541,\n// 257 8 26\n1815165.493841, 0.0, -4.0, 4.0, 8052.4, 8052.4,\n 0.5290110, 0.5091563, -7.190e-05, -8.000e-06,\n 0.8598350, -0.2573492, -1.028e-04, 4.260e-06,\n 10.5647697, -0.0142110, -2.000e-06,\n 179.9953156, 15.0036173, 0.000e-00,\n 0.5391530, 0.0000893, -1.240e-05,\n -0.0069500, 0.0000889, -1.230e-05,\n 0.0046621, 0.0046389,\n// 258 2 21\n1815343.511399, 0.0, -4.0, 4.0, 8047.7, 8047.7,\n -0.0154820, 0.4528572, -2.080e-05, -5.070e-06,\n -0.2761790, 0.2302539, 7.040e-05, -2.750e-06,\n -10.7991199, 0.0143880, 2.000e-06,\n 176.0499725, 15.0029259, 0.000e-00,\n 0.5696300, -0.0000527, -9.900e-06,\n 0.0233750, -0.0000524, -9.900e-06,\n 0.0046935, 0.0046701,\n// 258 8 16\n1815520.169630, 16.0, -4.0, 4.0, 8043.1, 8043.1,\n 0.0781720, 0.5300440, -4.460e-05, -8.950e-06,\n 0.2679950, -0.2450891, -1.019e-04, 4.340e-06,\n 14.1481504, -0.0127370, -3.000e-06,\n 59.4945488, 15.0028467, 0.000e-00,\n 0.5327530, 0.0000006, -1.290e-05,\n -0.0133180, 0.0000005, -1.290e-05,\n 0.0046477, 0.0046246,\n// 259 2 9\n1815697.493012, 0.0, -4.0, 4.0, 8038.5, 8038.5,\n -0.1186690, 0.4611253, -3.800e-05, -5.150e-06,\n 0.4641570, 0.2108032, 5.990e-05, -2.520e-06,\n -14.6380701, 0.0129050, 3.000e-06,\n 175.7481384, 15.0014982, 0.000e-00,\n 0.5709060, 0.0000423, -9.900e-06,\n 0.0246450, 0.0000421, -9.900e-06,\n 0.0047087, 0.0046853,\n// 259 8 6\n1815874.842808, 8.0, -4.0, 4.0, 8033.8, 8033.8,\n -0.2908190, 0.5271063, -1.560e-05, -8.220e-06,\n -0.3740310, -0.2132368, -9.080e-05, 3.510e-06,\n 17.2961903, -0.0108880, -4.000e-06,\n 299.2336121, 15.0018415, 0.000e-00,\n 0.5385380, -0.0000864, -1.220e-05,\n -0.0075620, -0.0000860, -1.220e-05,\n 0.0046349, 0.0046118,\n// 260 1 30\n1816051.618791, 3.0, -4.0, 4.0, 8029.2, 8029.2,\n -0.3445160, 0.4956538, -4.310e-05, -6.380e-06,\n 1.1008580, 0.1934596, 5.540e-05, -2.640e-06,\n -17.9524307, 0.0108470, 4.000e-06,\n 220.8765869, 14.9999580, 0.000e-00,\n 0.5593670, 0.0001106, -1.090e-05,\n 0.0131630, 0.0001100, -1.090e-05,\n 0.0047222, 0.0046987,\n// 260 6 26\n1816199.812650, 8.0, -4.0, 4.0, 8025.3, 8025.3,\n 0.4416190, 0.5173884, -2.240e-05, -6.320e-06,\n 1.4506390, -0.0646960, -2.139e-04, 8.700e-07,\n 23.6115208, -0.0009280, -6.000e-06,\n 300.4052124, 14.9990311, 0.000e-00,\n 0.5581530, -0.0001045, -1.020e-05,\n 0.0119560, -0.0001040, -1.020e-05,\n 0.0046014, 0.0045784,\n// 260 7 25\n1816229.324418, 20.0, -4.0, 4.0, 8024.5, 8024.5,\n -0.2900140, 0.5082506, -1.040e-05, -6.680e-06,\n -1.2287019, -0.1700142, -6.960e-05, 2.400e-06,\n 19.9401302, -0.0086360, -5.000e-06,\n 119.2366409, 15.0007439, 0.000e-00,\n 0.5522710, -0.0001192, -1.090e-05,\n 0.0061030, -0.0001186, -1.080e-05,\n 0.0046237, 0.0046007,\n// 260 12 20\n1816376.579519, 2.0, -4.0, 4.0, 8020.7, 8020.7,\n 0.1370130, 0.5759794, -3.230e-05, -9.560e-06,\n -0.9353290, 0.0516839, 2.338e-04, -1.010e-06,\n -23.6570396, -0.0004450, 6.000e-06,\n 209.5738373, 14.9962444, 0.000e-00,\n 0.5405290, 0.0000556, -1.290e-05,\n -0.0055800, 0.0000553, -1.290e-05,\n 0.0047549, 0.0047312,\n// 261 6 15\n1816553.888477, 9.0, -4.0, 4.0, 8016.0, 8016.0,\n -0.1286340, 0.5053873, -1.700e-06, -5.670e-06,\n 0.7733110, -0.0228687, -1.775e-04, 3.500e-07,\n 23.4674702, 0.0022050, -6.000e-06,\n 316.0131226, 14.9991684, 0.000e-00,\n 0.5654590, 0.0000006, -9.700e-06,\n 0.0192250, 0.0000006, -9.600e-06,\n 0.0045977, 0.0045748,\n// 261 12 9\n1816731.232975, 18.0, -4.0, 4.0, 8011.4, 8011.4,\n 0.2397820, 0.5801019, -7.000e-06, -9.740e-06,\n -0.2761480, 0.0058787, 1.921e-04, -2.200e-07,\n -23.1348209, -0.0037990, 6.000e-06,\n 90.8939972, 14.9965591, 0.000e-00,\n 0.5398080, -0.0000560, -1.300e-05,\n -0.0062990, -0.0000557, -1.300e-05,\n 0.0047578, 0.0047341,\n// 262 6 4\n1816907.946031, 11.0, -4.0, 4.0, 8006.8, 8006.8,\n 0.1531770, 0.5177567, -1.350e-05, -6.210e-06,\n -0.0043070, 0.0168972, -1.438e-04, -1.100e-07,\n 22.4736195, 0.0052080, -5.000e-06,\n 346.5021057, 14.9998465, 0.000e-00,\n 0.5594210, 0.0000816, -1.010e-05,\n 0.0132170, 0.0000812, -1.010e-05,\n 0.0045961, 0.0045732,\n// 262 11 29\n1817085.800959, 7.0, -4.0, 4.0, 8002.1, 8002.1,\n -0.0953290, 0.5533583, 3.190e-05, -8.130e-06,\n 0.4177610, -0.0380242, 1.322e-04, 4.600e-07,\n -21.7328892, -0.0069930, 6.000e-06,\n 287.0700684, 14.9973936, 0.000e-00,\n 0.5509480, -0.0001105, -1.190e-05,\n 0.0047860, -0.0001099, -1.190e-05,\n 0.0047583, 0.0047346,\n// 263 5 24\n1817262.255553, 18.0, -4.0, 4.0, 7997.5, 7997.5,\n 0.0087410, 0.5462077, -3.400e-06, -7.770e-06,\n -0.7789120, 0.0577692, -1.012e-04, -7.500e-07,\n 20.7216301, 0.0079020, -5.000e-06,\n 91.7683868, 15.0008926, 0.000e-00,\n 0.5449380, 0.0001209, -1.130e-05,\n -0.0011940, 0.0001203, -1.130e-05,\n 0.0045970, 0.0045741,\n// 263 11 18\n1817440.109868, 15.0, -4.0, 4.0, 7992.8, 7992.8,\n 0.3500460, 0.5155513, 1.900e-05, -6.320e-06,\n 1.1134990, -0.0735605, 7.550e-05, 8.200e-07,\n -19.4789200, -0.0098810, 5.000e-06,\n 47.9626617, 14.9986458, 0.000e-00,\n 0.5665120, -0.0001090, -1.060e-05,\n 0.0202730, -0.0001085, -1.050e-05,\n 0.0047559, 0.0047322,\n// 264 4 14\n1817587.550204, 1.0, -4.0, 4.0, 7988.9, 7988.9,\n -0.4093960, 0.5602456, 3.770e-05, -9.550e-06,\n 0.9700770, 0.1644830, -1.141e-04, -2.720e-06,\n 9.2393503, 0.0145720, -2.000e-06,\n 195.2803345, 15.0046616, 0.000e-00,\n 0.5315620, 0.0000202, -1.290e-05,\n -0.0145030, 0.0000201, -1.280e-05,\n 0.0046235, 0.0046005,\n// 264 5 13\n1817616.845345, 8.0, -4.0, 4.0, 7988.2, 7988.2,\n 0.0855780, 0.5691651, 6.100e-06, -9.390e-06,\n -1.4798800, 0.0979088, -4.200e-05, -1.550e-06,\n 18.3523407, 0.0101950, -4.000e-06,\n 301.7535095, 15.0020618, 0.000e-00,\n 0.5328310, 0.0000710, -1.250e-05,\n -0.0132400, 0.0000706, -1.250e-05,\n 0.0046006, 0.0045777,\n// 264 10 7\n1817764.351313, 20.0, -4.0, 4.0, 7984.3, 7984.3,\n -0.5595330, 0.4828601, 2.500e-05, -5.440e-06,\n -1.0600040, -0.1507883, 7.720e-05, 1.630e-06,\n -5.8096900, -0.0159620, 1.000e-06,\n 122.8991470, 15.0035343, 0.000e-00,\n 0.5721490, 0.0000531, -9.900e-06,\n 0.0258810, 0.0000528, -9.900e-06,\n 0.0047206, 0.0046971,\n// 265 4 3\n1817942.246461, 18.0, -4.0, 4.0, 7979.7, 7979.7,\n -0.0535450, 0.5474002, 2.450e-05, -8.860e-06,\n 0.3333980, 0.1717637, -4.540e-05, -2.700e-06,\n 5.3395200, 0.0154170, -1.000e-06,\n 89.3779373, 15.0050821, 0.000e-00,\n 0.5364330, -0.0000849, -1.240e-05,\n -0.0096560, -0.0000844, -1.240e-05,\n 0.0046357, 0.0046126,\n// 265 9 26\n1818118.454649, 23.0, -4.0, 4.0, 7975.1, 7975.1,\n -0.0904840, 0.5039814, -9.200e-06, -6.470e-06,\n -0.4318090, -0.1630538, 3.420e-05, 2.010e-06,\n -1.3981700, -0.0162640, 0.000e-00,\n 167.1793823, 15.0041847, 0.000e-00,\n 0.5597610, 0.0001158, -1.080e-05,\n 0.0135550, 0.0001152, -1.070e-05,\n 0.0047056, 0.0046821,\n// 266 3 24\n1818296.776744, 7.0, -4.0, 4.0, 7970.4, 7970.4,\n 0.3152040, 0.5160726, 5.100e-06, -7.100e-06,\n -0.3419800, 0.1674104, 1.720e-05, -2.220e-06,\n 1.2088500, 0.0158750, 0.000e-00,\n 283.3905945, 15.0050964, 0.000e-00,\n 0.5507970, -0.0001316, -1.120e-05,\n 0.0046360, -0.0001310, -1.110e-05,\n 0.0046499, 0.0046267,\n// 266 9 16\n1818472.866233, 9.0, -4.0, 4.0, 7965.7, 7965.7,\n 0.2047470, 0.5365675, -3.030e-05, -8.240e-06,\n 0.2497170, -0.1723467, -2.450e-05, 2.570e-06,\n 2.9153099, -0.0160520, -1.000e-06,\n 316.3803101, 15.0044231, 0.000e-00,\n 0.5435740, 0.0001023, -1.210e-05,\n -0.0025510, 0.0001018, -1.210e-05,\n 0.0046902, 0.0046668,\n// 267 3 13\n1818651.005311, 12.0, -4.0, 4.0, 7961.1, 7961.1,\n 0.3082860, 0.4879327, -7.900e-06, -5.700e-06,\n -1.1684999, 0.1573873, 6.900e-05, -1.760e-06,\n -3.1095800, 0.0158940, 0.000e-00,\n 357.4012756, 15.0047016, 0.000e-00,\n 0.5657400, -0.0000754, -1.010e-05,\n 0.0195050, -0.0000750, -1.000e-05,\n 0.0046653, 0.0046421,\n// 267 9 6\n1818827.505686, 0.0, -4.0, 4.0, 7956.4, 7956.4,\n 0.2142030, 0.5574827, -2.950e-05, -9.490e-06,\n 0.9676180, -0.1713506, -9.820e-05, 2.830e-06,\n 7.0373001, -0.0153960, -1.000e-06,\n 180.6084900, 15.0042410, 0.000e-00,\n 0.5343850, 0.0000258, -1.300e-05,\n -0.0116950, 0.0000257, -1.290e-05,\n 0.0046750, 0.0046517,\n// 268 1 31\n1818975.288945, 19.0, -4.0, 4.0, 7952.6, 7952.6,\n -0.1591760, 0.5031583, -2.360e-05, -5.860e-06,\n 1.0351410, 0.0939108, 6.230e-05, -1.020e-06,\n -17.4755306, 0.0114500, 4.000e-06,\n 100.8347626, 15.0002308, 0.000e-00,\n 0.5690650, 0.0000706, -1.010e-05,\n 0.0228130, 0.0000702, -1.010e-05,\n 0.0047208, 0.0046973,\n// 268 7 27\n1819152.813725, 8.0, -4.0, 4.0, 7947.9, 7947.9,\n 0.1380810, 0.5548051, -8.200e-06, -8.370e-06,\n -0.9215880, -0.0771695, -8.670e-05, 1.090e-06,\n 19.5910702, -0.0092200, -5.000e-06,\n 299.2151489, 15.0010157, 0.000e-00,\n 0.5415230, -0.0001181, -1.180e-05,\n -0.0045920, -0.0001175, -1.180e-05,\n 0.0046246, 0.0046016,\n// 269 1 19\n1819329.493231, 0.0, -4.0, 4.0, 7943.3, 7943.3,\n 0.0516770, 0.5382331, -3.580e-05, -7.390e-06,\n 0.3091070, 0.0644924, 1.192e-04, -8.000e-07,\n -20.2402706, 0.0089610, 5.000e-06,\n 176.3344574, 14.9987049, 0.000e-00,\n 0.5553760, 0.0001151, -1.130e-05,\n 0.0091920, 0.0001146, -1.130e-05,\n 0.0047326, 0.0047090,\n// 269 7 16\n1819507.218336, 17.0, -4.0, 4.0, 7938.6, 7938.6,\n -0.1365850, 0.5258890, 1.080e-05, -6.640e-06,\n -0.1407660, -0.0363028, -1.358e-04, 3.700e-07,\n 21.6992397, -0.0066310, -5.000e-06,\n 74.4466171, 14.9999828, 0.000e-00,\n 0.5561050, -0.0001002, -1.050e-05,\n 0.0099180, -0.0000997, -1.040e-05,\n 0.0046148, 0.0045918,\n// 270 1 9\n1819683.989620, 12.0, -4.0, 4.0, 7934.0, 7934.0,\n 0.1615670, 0.5727582, -2.720e-05, -9.280e-06,\n -0.3975630, 0.0268470, 1.853e-04, -3.400e-07,\n -22.2151394, 0.0060730, 6.000e-06,\n 357.2147522, 14.9974308, 0.000e-00,\n 0.5419850, 0.0000709, -1.270e-05,\n -0.0041320, 0.0000706, -1.260e-05,\n 0.0047424, 0.0047188,\n// 270 7 5\n1819861.333861, 20.0, -4.0, 4.0, 7929.3, 7929.3,\n -0.0108970, 0.5067911, 5.300e-06, -5.720e-06,\n 0.6270620, 0.0036238, -1.702e-04, -1.300e-07,\n 23.0906105, -0.0036920, -5.000e-06,\n 119.9111023, 14.9992466, 0.000e-00,\n 0.5654980, -0.0000263, -9.700e-06,\n 0.0192640, -0.0000262, -9.700e-06,\n 0.0046066, 0.0045837,\n// 270 12 30\n1820038.638550, 3.0, -4.0, 4.0, 7924.7, 7924.7,\n -0.2208030, 0.5825083, 2.010e-05, -9.900e-06,\n -1.0548960, -0.0173905, 2.406e-04, 4.200e-07,\n -23.3637695, 0.0028770, 6.000e-06,\n 223.3851166, 14.9965506, 0.000e-00,\n 0.5383930, -0.0000138, -1.310e-05,\n -0.0077060, -0.0000138, -1.310e-05,\n 0.0047502, 0.0047265,\n// 271 5 26\n1820185.817982, 8.0, -4.0, 4.0, 7920.8, 7920.8,\n 0.5879550, 0.5036354, -1.300e-06, -6.240e-06,\n -1.2975580, 0.1497623, -7.400e-05, -2.010e-06,\n 21.0324097, 0.0072870, -5.000e-06,\n 301.7447815, 15.0006208, 0.000e-00,\n 0.5557450, 0.0000962, -1.040e-05,\n 0.0095600, 0.0000958, -1.040e-05,\n 0.0045972, 0.0045743,\n// 271 6 24\n1820215.364259, 21.0, -4.0, 4.0, 7920.0, 7920.0,\n 0.0144110, 0.5115282, 2.500e-06, -5.980e-06,\n 1.3743750, 0.0439708, -2.064e-04, -6.000e-07,\n 23.6495705, -0.0005710, -6.000e-06,\n 135.5146484, 14.9990110, 0.000e-00,\n 0.5619940, 0.0000671, -9.900e-06,\n 0.0157770, 0.0000668, -9.900e-06,\n 0.0046004, 0.0045775,\n// 271 11 20\n1820363.697460, 5.0, -4.0, 4.0, 7916.1, 7916.1,\n 0.4629890, 0.5155317, 4.060e-05, -7.130e-06,\n 0.9203070, -0.1752329, 8.170e-05, 2.580e-06,\n -19.8662605, -0.0092160, 5.000e-06,\n 257.8575134, 14.9984312, 0.000e-00,\n 0.5553010, -0.0001267, -1.150e-05,\n 0.0091170, -0.0001261, -1.140e-05,\n 0.0047558, 0.0047321,\n// 272 5 14\n1820540.212562, 17.0, -4.0, 4.0, 7911.5, 7911.5,\n 0.1507220, 0.5238146, 1.910e-05, -7.760e-06,\n -0.5691410, 0.1944101, -9.030e-05, -3.060e-06,\n 18.7051392, 0.0096680, -4.000e-06,\n 76.7722778, 15.0017939, 0.000e-00,\n 0.5409900, 0.0001128, -1.170e-05,\n -0.0051220, 0.0001123, -1.170e-05,\n 0.0046004, 0.0045775,\n// 272 11 8\n1820717.918197, 10.0, -4.0, 4.0, 7906.8, 7906.8,\n 0.1176900, 0.4741914, 4.800e-05, -5.500e-06,\n 0.3330840, -0.1966109, 8.220e-05, 2.450e-06,\n -16.9585094, -0.0117310, 4.000e-06,\n 333.4243469, 14.9998646, 0.000e-00,\n 0.5700630, -0.0000802, -1.030e-05,\n 0.0238060, -0.0000798, -1.020e-05,\n 0.0047507, 0.0047270,\n// 273 5 4\n1820894.854773, 9.0, -4.0, 4.0, 7902.2, 7902.2,\n 0.1876990, 0.5341372, 2.800e-05, -8.930e-06,\n 0.2775010, 0.2314703, -1.141e-04, -4.060e-06,\n 15.8655100, 0.0116270, -3.000e-06,\n 316.5024109, 15.0029259, 0.000e-00,\n 0.5314620, 0.0000251, -1.270e-05,\n -0.0146030, 0.0000250, -1.270e-05,\n 0.0046063, 0.0045834,\n// 273 10 28\n1821071.900455, 10.0, -4.0, 4.0, 7897.6, 7897.6,\n 0.0325850, 0.4545525, 3.180e-05, -4.980e-06,\n -0.3869250, -0.2166161, 8.870e-05, 2.540e-06,\n -13.3755598, -0.0137020, 3.000e-06,\n 333.5742493, 15.0013571, 0.000e-00,\n 0.5745660, 0.0000119, -9.900e-06,\n 0.0282870, 0.0000119, -9.800e-06,\n 0.0047421, 0.0047185,\n// 274 4 24\n1821249.568332, 2.0, -4.0, 4.0, 7892.9, 7892.9,\n -0.2101670, 0.5212721, 5.740e-05, -8.550e-06,\n 0.9154370, 0.2512757, -1.214e-04, -4.330e-06,\n 12.5698404, 0.0132240, -3.000e-06,\n 210.9643860, 15.0038719, 0.000e-00,\n 0.5332910, -0.0000727, -1.260e-05,\n -0.0127820, -0.0000723, -1.250e-05,\n 0.0046147, 0.0045917,\n// 274 10 17\n1821425.939261, 11.0, -4.0, 4.0, 7888.3, 7888.3,\n -0.2553250, 0.4630615, 2.380e-05, -5.620e-06,\n -1.0073130, -0.2411486, 9.910e-05, 3.090e-06,\n -9.3464403, -0.0150420, 2.000e-06,\n 348.3330078, 15.0026808, 0.000e-00,\n 0.5647910, 0.0000973, -1.050e-05,\n 0.0185600, 0.0000968, -1.050e-05,\n 0.0047307, 0.0047072,\n// 275 3 15\n1821574.675305, 4.0, -4.0, 4.0, 7884.3, 7884.3,\n 0.3892960, 0.4649957, -9.000e-06, -5.960e-06,\n -0.9230470, 0.2598115, 6.090e-05, -3.490e-06,\n -2.4342999, 0.0156830, 0.000e-00,\n 237.5490417, 15.0047283, 0.000e-00,\n 0.5560660, -0.0001150, -1.080e-05,\n 0.0098790, -0.0001145, -1.080e-05,\n 0.0046625, 0.0046393,\n// 275 9 7\n1821750.825811, 8.0, -4.0, 4.0, 7879.7, 7879.7,\n 0.5866860, 0.5034071, -6.340e-05, -7.960e-06,\n 0.8716630, -0.2711539, -7.950e-05, 4.510e-06,\n 6.5070100, -0.0152690, -1.000e-06,\n 300.7082520, 15.0041647, 0.000e-00,\n 0.5393310, 0.0000845, -1.250e-05,\n -0.0067720, 0.0000841, -1.240e-05,\n 0.0046770, 0.0046537,\n// 276 3 3\n1821928.816797, 8.0, -4.0, 4.0, 7875.0, 7875.0,\n 0.3116500, 0.4459414, -2.250e-05, -4.970e-06,\n -0.1518640, 0.2422022, 4.330e-05, -2.870e-06,\n -6.7259898, 0.0153000, 1.000e-06,\n 296.6746216, 15.0039902, 0.000e-00,\n 0.5690450, -0.0000605, -9.900e-06,\n 0.0227940, -0.0000602, -9.800e-06,\n 0.0046784, 0.0046551,\n// 276 8 27\n1822105.500969, 0.0, -4.0, 4.0, 7870.4, 7870.4,\n 0.1354930, 0.5200384, -3.820e-05, -8.770e-06,\n 0.2956650, -0.2650985, -7.880e-05, 4.670e-06,\n 10.4240103, -0.0142360, -2.000e-06,\n 180.0181274, 15.0036736, 0.000e-00,\n 0.5335650, -0.0000067, -1.300e-05,\n -0.0125100, -0.0000067, -1.290e-05,\n 0.0046620, 0.0046388,\n// 277 2 20\n1822282.804058, 7.0, -4.0, 4.0, 7865.7, 7865.7,\n -0.3317630, 0.4532057, -2.360e-05, -5.080e-06,\n 0.3201110, 0.2297927, 4.130e-05, -2.750e-06,\n -10.9101295, 0.0143560, 2.000e-06,\n 281.0334167, 15.0028839, 0.000e-00,\n 0.5695540, 0.0000566, -9.900e-06,\n 0.0233000, 0.0000563, -9.900e-06,\n 0.0046943, 0.0046709,\n// 277 8 16\n1822460.162204, 16.0, -4.0, 4.0, 7861.1, 7861.1,\n -0.1138650, 0.5141712, -1.880e-05, -7.940e-06,\n -0.3896980, -0.2385564, -6.710e-05, 3.880e-06,\n 14.0203104, -0.0128130, -3.000e-06,\n 59.5067596, 15.0028477, 0.000e-00,\n 0.5399640, -0.0000982, -1.220e-05,\n -0.0061430, -0.0000977, -1.210e-05,\n 0.0046481, 0.0046250,\n// 278 2 9\n1822636.951235, 11.0, -4.0, 4.0, 7856.4, 7856.4,\n -0.3815650, 0.4864516, -3.680e-05, -6.320e-06,\n 1.0614500, 0.2206789, 3.140e-05, -3.030e-06,\n -14.6858997, 0.0128590, 3.000e-06,\n 340.7506409, 15.0015297, 0.000e-00,\n 0.5577130, 0.0001110, -1.100e-05,\n 0.0115180, 0.0001104, -1.090e-05,\n 0.0047090, 0.0046855,\n// 278 8 6\n1822814.621838, 3.0, -4.0, 4.0, 7851.8, 7851.8,\n -0.4101570, 0.4950344, -5.800e-06, -6.410e-06,\n -1.1252480, -0.1996660, -5.430e-05, 2.770e-06,\n 17.2423401, -0.0109550, -4.000e-06,\n 224.2284088, 15.0017910, 0.000e-00,\n 0.5539230, -0.0001144, -1.080e-05,\n 0.0077470, -0.0001138, -1.080e-05,\n 0.0046352, 0.0046121,\n// 278 12 31\n1822961.945746, 11.0, -4.0, 4.0, 7847.9, 7847.9,\n 0.3366360, 0.5703775, -5.660e-05, -9.490e-06,\n -0.9023130, 0.1006353, 2.256e-04, -1.840e-06,\n -23.2612705, 0.0030380, 6.000e-06,\n 343.2254639, 14.9966040, 0.000e-00,\n 0.5398840, 0.0000447, -1.300e-05,\n -0.0062230, 0.0000445, -1.290e-05,\n 0.0047495, 0.0047258,\n// 279 6 26\n1823139.153667, 16.0, -4.0, 4.0, 7843.2, 7843.2,\n 0.2626390, 0.5018879, -2.810e-05, -5.620e-06,\n 0.8271990, -0.0629645, -1.801e-04, 8.100e-07,\n 23.6167297, -0.0008580, -6.000e-06,\n 60.4046097, 14.9989967, 0.000e-00,\n 0.5657000, -0.0000043, -9.700e-06,\n 0.0194660, -0.0000043, -9.600e-06,\n 0.0046012, 0.0045782,\n// 279 12 21\n1823316.601699, 2.0, -4.0, 4.0, 7838.6, 7838.6,\n -0.2276640, 0.5768368, 1.700e-06, -9.630e-06,\n -0.3039650, 0.0546448, 1.984e-04, -1.040e-06,\n -23.6581802, -0.0003250, 6.000e-06,\n 209.5366516, 14.9962454, 0.000e-00,\n 0.5400070, -0.0000395, -1.300e-05,\n -0.0061000, -0.0000393, -1.290e-05,\n 0.0047549, 0.0047312,\n// 280 6 14\n1823493.219318, 17.0, -4.0, 4.0, 7833.9, 7833.9,\n -0.1335200, 0.5191772, -1.530e-05, -6.290e-06,\n 0.0822930, -0.0227097, -1.552e-04, 3.800e-07,\n 23.4528904, 0.0022780, -6.000e-06,\n 76.0129395, 14.9992170, 0.000e-00,\n 0.5586660, 0.0000980, -1.020e-05,\n 0.0124660, 0.0000975, -1.010e-05,\n 0.0045972, 0.0045743,\n// 280 12 9\n1823671.160839, 16.0, -4.0, 4.0, 7829.2, 7829.2,\n 0.0724000, 0.5528764, 1.260e-05, -8.050e-06,\n 0.4110780, 0.0066796, 1.470e-04, -2.100e-07,\n -23.1606007, -0.0037050, 6.000e-06,\n 60.8728485, 14.9964685, 0.000e-00,\n 0.5516950, -0.0001214, -1.190e-05,\n 0.0055290, -0.0001208, -1.180e-05,\n 0.0047582, 0.0047345,\n// 281 6 4\n1823847.549310, 1.0, -4.0, 4.0, 7824.6, 7824.6,\n -0.0774500, 0.5511052, -8.600e-06, -7.930e-06,\n -0.6984780, 0.0187962, -1.193e-04, -1.900e-07,\n 22.4716091, 0.0052060, -5.000e-06,\n 196.4898682, 14.9999266, 0.000e-00,\n 0.5439070, 0.0001216, -1.140e-05,\n -0.0022190, 0.0001210, -1.140e-05,\n 0.0045957, 0.0045729,\n// 281 11 28\n1824025.452925, 23.0, -4.0, 4.0, 7819.9, 7819.9,\n 0.1471950, 0.5179314, 1.900e-05, -6.290e-06,\n 1.1427881, -0.0360677, 9.520e-05, 3.400e-07,\n -21.7404404, -0.0069830, 6.000e-06,\n 167.0799255, 14.9973001, 0.000e-00,\n 0.5674410, -0.0001018, -1.050e-05,\n 0.0211970, -0.0001012, -1.040e-05,\n 0.0047587, 0.0047350,\n// 282 4 25\n1824172.868122, 9.0, -4.0, 4.0, 7816.0, 7816.0,\n -0.1828310, 0.5658596, 3.130e-05, -9.660e-06,\n 1.0977780, 0.1455269, -1.463e-04, -2.400e-06,\n 13.0152998, 0.0132840, -3.000e-06,\n 316.0434265, 15.0038633, 0.000e-00,\n 0.5309340, 0.0000047, -1.280e-05,\n -0.0151270, 0.0000047, -1.280e-05,\n 0.0046136, 0.0045906,\n// 282 5 24\n1824202.153854, 16.0, -4.0, 4.0, 7815.3, 7815.3,\n 0.3260820, 0.5753791, -1.030e-05, -9.540e-06,\n -1.3730670, 0.0616105, -6.740e-05, -9.400e-07,\n 20.7829800, 0.0078160, -5.000e-06,\n 61.7535400, 15.0009289, 0.000e-00,\n 0.5321890, 0.0000509, -1.260e-05,\n -0.0138790, 0.0000506, -1.250e-05,\n 0.0045968, 0.0045739,\n// 282 10 19\n1824349.673438, 4.0, -4.0, 4.0, 7811.4, 7811.4,\n -0.4076860, 0.4869610, 2.520e-05, -5.500e-06,\n -1.1296550, -0.1388896, 1.048e-04, 1.500e-06,\n -10.0038900, -0.0151050, 2.000e-06,\n 243.3972931, 15.0025606, 0.000e-00,\n 0.5725900, 0.0000527, -9.900e-06,\n 0.0263200, 0.0000524, -9.900e-06,\n 0.0047326, 0.0047091,\n// 283 4 15\n1824527.564517, 2.0, -4.0, 4.0, 7806.7, 7806.7,\n 0.1383740, 0.5498138, 2.240e-05, -8.840e-06,\n 0.4513740, 0.1591857, -7.640e-05, -2.480e-06,\n 9.3989201, 0.0145410, -2.000e-06,\n 210.3089752, 15.0046024, 0.000e-00,\n 0.5363640, -0.0000981, -1.240e-05,\n -0.0097250, -0.0000976, -1.230e-05,\n 0.0046237, 0.0046007,\n// 283 10 8\n1824703.785419, 7.0, -4.0, 4.0, 7802.1, 7802.1,\n -0.0613130, 0.5072999, -2.800e-06, -6.570e-06,\n -0.4647940, -0.1579728, 6.100e-05, 1.970e-06,\n -5.7526202, -0.0159480, 1.000e-06,\n 287.8927917, 15.0036106, 0.000e-00,\n 0.5597440, 0.0001161, -1.090e-05,\n 0.0135380, 0.0001155, -1.080e-05,\n 0.0047194, 0.0046959,\n// 284 4 3\n1824882.084440, 14.0, -4.0, 4.0, 7797.4, 7797.4,\n 0.0957780, 0.5159124, 2.160e-05, -7.010e-06,\n -0.3537680, 0.1616247, -7.100e-06, -2.120e-06,\n 5.4282198, 0.0154270, -1.000e-06,\n 29.3965702, 15.0049953, 0.000e-00,\n 0.5509950, -0.0001222, -1.110e-05,\n 0.0048330, -0.0001216, -1.100e-05,\n 0.0046364, 0.0046133,\n// 284 9 26\n1825058.207544, 17.0, -4.0, 4.0, 7792.7, 7792.7,\n 0.0936160, 0.5376283, -1.630e-05, -8.330e-06,\n 0.2545520, -0.1739541, 1.600e-06, 2.620e-06,\n -1.4587899, -0.0162340, 0.000e-00,\n 77.1875534, 15.0042639, 0.000e-00,\n 0.5436440, 0.0001039, -1.220e-05,\n -0.0024820, 0.0001033, -1.220e-05,\n 0.0047049, 0.0046814,\n// 285 3 23\n1825236.300327, 19.0, -4.0, 4.0, 7788.1, 7788.1,\n 0.2559530, 0.4865597, 7.000e-07, -5.650e-06,\n -1.1300600, 0.1583374, 4.380e-05, -1.760e-06,\n 1.1691200, 0.0158990, -1.000e-06,\n 103.3818588, 15.0050192, 0.000e-00,\n 0.5654270, -0.0000684, -1.000e-05,\n 0.0191940, -0.0000681, -9.900e-06,\n 0.0046509, 0.0046277,\n// 285 9 16\n1825412.847936, 8.0, -4.0, 4.0, 7783.4, 7783.4,\n 0.0989430, 0.5549856, -1.490e-05, -9.450e-06,\n 0.9694430, -0.1796005, -7.160e-05, 2.980e-06,\n 2.7728801, -0.0160450, -1.000e-06,\n 301.4053955, 15.0044727, 0.000e-00,\n 0.5350650, 0.0000254, -1.300e-05,\n -0.0110180, 0.0000253, -1.290e-05,\n 0.0046900, 0.0046667,\n// 286 2 11\n1825560.609227, 3.0, -4.0, 4.0, 7779.5, 7779.5,\n -0.0620280, 0.4990269, -2.700e-05, -5.850e-06,\n 1.0866700, 0.1203089, 3.530e-05, -1.340e-06,\n -14.1241198, 0.0133740, 3.000e-06,\n 220.7718048, 15.0017996, 0.000e-00,\n 0.5676350, 0.0000682, -1.020e-05,\n 0.0213900, 0.0000679, -1.010e-05,\n 0.0047072, 0.0046837,\n// 286 8 7\n1825738.124631, 15.0, -4.0, 4.0, 7774.8, 7774.8,\n -0.1823700, 0.5472821, 3.300e-06, -8.160e-06,\n -0.9394730, -0.1091781, -6.450e-05, 1.560e-06,\n 16.8058796, -0.0114770, -4.000e-06,\n 44.2517395, 15.0020761, 0.000e-00,\n 0.5430970, -0.0001094, -1.180e-05,\n -0.0030250, -0.0001089, -1.170e-05,\n 0.0046365, 0.0046134,\n// 287 1 31\n1825914.835471, 8.0, -4.0, 4.0, 7770.2, 7770.2,\n -0.0851230, 0.5350235, -3.430e-05, -7.430e-06,\n 0.3059400, 0.0992071, 9.470e-05, -1.300e-06,\n -17.4898396, 0.0114250, 4.000e-06,\n 295.8375854, 15.0002947, 0.000e-00,\n 0.5537830, 0.0001194, -1.140e-05,\n 0.0076070, 0.0001188, -1.130e-05,\n 0.0047206, 0.0046971,\n// 287 7 28\n1826092.505990, 0.0, -4.0, 4.0, 7765.5, 7765.5,\n -0.1051610, 0.5202061, 1.900e-06, -6.500e-06,\n -0.2104090, -0.0715756, -1.164e-04, 8.200e-07,\n 19.5726299, -0.0092460, -5.000e-06,\n 179.2101746, 15.0009432, 0.000e-00,\n 0.5575900, -0.0000988, -1.040e-05,\n 0.0113960, -0.0000984, -1.040e-05,\n 0.0046249, 0.0046019,\n// 288 1 20\n1826269.349135, 20.0, -4.0, 4.0, 7760.8, 7760.8,\n -0.1688400, 0.5704929, -2.030e-05, -9.310e-06,\n -0.4169570, 0.0692438, 1.657e-04, -1.040e-06,\n -20.1867695, 0.0090080, 5.000e-06,\n 116.3207932, 14.9988127, 0.000e-00,\n 0.5408670, 0.0000820, -1.270e-05,\n -0.0052450, 0.0000816, -1.270e-05,\n 0.0047322, 0.0047086,\n// 288 7 16\n1826446.603550, 2.0, -4.0, 4.0, 7756.1, 7756.1,\n -0.2083320, 0.5050310, 6.000e-07, -5.680e-06,\n 0.5603350, -0.0339433, -1.566e-04, 3.000e-07,\n 21.7317696, -0.0065760, -5.000e-06,\n 209.4493408, 14.9999199, 0.000e-00,\n 0.5662470, -0.0000101, -9.700e-06,\n 0.0200090, -0.0000101, -9.700e-06,\n 0.0046146, 0.0045917,\n// 289 1 9\n1826624.004477, 12.0, -4.0, 4.0, 7751.5, 7751.5,\n -0.0076320, 0.5816740, -4.500e-06, -9.880e-06,\n -1.0569390, 0.0302410, 2.284e-04, -4.000e-07,\n -22.1543102, 0.0061800, 6.000e-06,\n 357.1859436, 14.9974918, 0.000e-00,\n 0.5381230, -0.0000255, -1.310e-05,\n -0.0079750, -0.0000254, -1.300e-05,\n 0.0047423, 0.0047186,\n// 289 6 5\n1826771.097274, 14.0, -4.0, 4.0, 7747.6, 7747.6,\n 0.1470270, 0.5150194, 8.400e-06, -6.480e-06,\n -1.4904730, 0.1132779, -7.990e-05, -1.570e-06,\n 22.6671295, 0.0045500, -5.000e-06,\n 31.4253101, 14.9997187, 0.000e-00,\n 0.5546940, 0.0001146, -1.050e-05,\n 0.0085130, 0.0001140, -1.040e-05,\n 0.0045961, 0.0045732,\n// 289 7 5\n1826800.637500, 3.0, -4.0, 4.0, 7746.8, 7746.8,\n -0.1639290, 0.5145869, -4.500e-06, -6.060e-06,\n 1.2832659, 0.0039448, -1.989e-04, -1.200e-07,\n 23.1135292, -0.0036080, -5.000e-06,\n 224.9146271, 14.9992580, 0.000e-00,\n 0.5616850, 0.0000841, -1.000e-05,\n 0.0154700, 0.0000837, -9.900e-06,\n 0.0046060, 0.0045831,\n// 289 11 30\n1826949.052150, 13.0, -4.0, 4.0, 7742.9, 7742.9,\n 0.1259210, 0.5251483, 5.040e-05, -7.200e-06,\n 1.0277870, -0.1364650, 9.910e-05, 2.010e-06,\n -22.0083103, -0.0062540, 6.000e-06,\n 16.9238605, 14.9971504, 0.000e-00,\n 0.5563580, -0.0001159, -1.140e-05,\n 0.0101690, -0.0001153, -1.140e-05,\n 0.0047584, 0.0047347,\n// 290 5 26\n1827125.512481, 0.0, -4.0, 4.0, 7738.3, 7738.3,\n 0.0279880, 0.5372097, 2.270e-05, -8.070e-06,\n -0.6797300, 0.1607483, -1.041e-04, -2.580e-06,\n 21.0436897, 0.0072410, -5.000e-06,\n 181.7255402, 15.0006971, 0.000e-00,\n 0.5398820, 0.0001155, -1.180e-05,\n -0.0062240, 0.0001149, -1.170e-05,\n 0.0045967, 0.0045738,\n// 290 11 19\n1827303.255501, 18.0, -4.0, 4.0, 7733.6, 7733.6,\n 0.0530750, 0.4843524, 5.080e-05, -5.600e-06,\n 0.3633130, -0.1660619, 1.051e-04, 2.070e-06,\n -19.8454800, -0.0092560, 5.000e-06,\n 92.8746185, 14.9983625, 0.000e-00,\n 0.5710100, -0.0000749, -1.020e-05,\n 0.0247490, -0.0000745, -1.020e-05,\n 0.0047562, 0.0047325,\n// 291 5 15\n1827480.166709, 16.0, -4.0, 4.0, 7728.9, 7728.9,\n -0.0380600, 0.5466791, 4.230e-05, -9.190e-06,\n 0.1012180, 0.2021360, -1.276e-04, -3.580e-06,\n 18.7919197, 0.0095710, -4.000e-06,\n 61.7579308, 15.0018082, 0.000e-00,\n 0.5308400, 0.0000317, -1.280e-05,\n -0.0152210, 0.0000316, -1.270e-05,\n 0.0046001, 0.0045772,\n// 291 11 8\n1827657.229011, 17.0, -4.0, 4.0, 7724.3, 7724.3,\n -0.3545970, 0.4648747, 4.940e-05, -5.110e-06,\n -0.2010150, -0.1938921, 1.063e-04, 2.290e-06,\n -16.8602791, -0.0118030, 4.000e-06,\n 78.4448318, 14.9998903, 0.000e-00,\n 0.5749320, 0.0000343, -9.900e-06,\n 0.0286500, 0.0000341, -9.800e-06,\n 0.0047504, 0.0047268,\n// 292 5 4\n1827834.880984, 9.0, -4.0, 4.0, 7719.6, 7719.6,\n -0.4112560, 0.5307940, 7.380e-05, -8.670e-06,\n 0.7481320, 0.2277860, -1.363e-04, -3.920e-06,\n 15.9808598, 0.0115650, -3.000e-06,\n 316.5072937, 15.0028706, 0.000e-00,\n 0.5333680, -0.0000650, -1.250e-05,\n -0.0127050, -0.0000646, -1.250e-05,\n 0.0046064, 0.0045835,\n// 292 10 27\n1828011.275563, 19.0, -4.0, 4.0, 7714.9, 7714.9,\n -0.2441960, 0.4728516, 3.210e-05, -5.790e-06,\n -0.9844620, -0.2248154, 1.230e-04, 2.910e-06,\n -13.2917500, -0.0137150, 3.000e-06,\n 108.5801010, 15.0014381, 0.000e-00,\n 0.5646550, 0.0001011, -1.060e-05,\n 0.0184250, 0.0001006, -1.060e-05,\n 0.0047412, 0.0047176,\n// 293 3 25\n1828159.981916, 12.0, -4.0, 4.0, 7711.0, 7711.0,\n 0.7153750, 0.4632560, -9.600e-06, -5.890e-06,\n -0.8064140, 0.2593056, 3.400e-05, -3.460e-06,\n 1.8582400, 0.0156180, -1.000e-06,\n 358.5488892, 15.0049744, 0.000e-00,\n 0.5560450, -0.0001266, -1.070e-05,\n 0.0098590, -0.0001259, -1.070e-05,\n 0.0046484, 0.0046252,\n// 293 9 17\n1828336.165162, 16.0, -4.0, 4.0, 7706.4, 7706.4,\n 0.5414200, 0.5008396, -4.820e-05, -7.970e-06,\n 0.9316430, -0.2783376, -5.870e-05, 4.650e-06,\n 2.2207601, -0.0158560, -1.000e-06,\n 61.5120811, 15.0043488, 0.000e-00,\n 0.5395290, 0.0000839, -1.250e-05,\n -0.0065760, 0.0000835, -1.250e-05,\n 0.0046918, 0.0046684,\n// 294 3 14\n1828514.114386, 15.0, -4.0, 4.0, 7701.6, 7701.6,\n 0.2762110, 0.4421153, -1.080e-05, -4.910e-06,\n -0.2283650, 0.2480843, 2.430e-05, -2.920e-06,\n -2.4930201, 0.0157110, 0.000e-00,\n 42.5377007, 15.0046568, 0.000e-00,\n 0.5684920, -0.0000518, -9.800e-06,\n 0.0222430, -0.0000515, -9.800e-06,\n 0.0046638, 0.0046405,\n// 294 9 7\n1828690.837841, 8.0, -4.0, 4.0, 7697.0, 7697.0,\n 0.1196530, 0.5127150, -2.530e-05, -8.620e-06,\n 0.3527890, -0.2782341, -5.750e-05, 4.890e-06,\n 6.3539100, -0.0152770, -1.000e-06,\n 300.7307739, 15.0042086, 0.000e-00,\n 0.5344420, -0.0000105, -1.300e-05,\n -0.0116370, -0.0000105, -1.290e-05,\n 0.0046768, 0.0046535,\n// 295 3 3\n1828868.109189, 15.0, -4.0, 4.0, 7692.3, 7692.3,\n -0.0168680, 0.4477693, -2.460e-05, -5.040e-06,\n 0.4367170, 0.2427236, 1.420e-05, -2.900e-06,\n -6.8467999, 0.0152810, 1.000e-06,\n 41.6556587, 15.0039577, 0.000e-00,\n 0.5681910, 0.0000483, -1.000e-05,\n 0.0219430, 0.0000480, -9.900e-06,\n 0.0046794, 0.0046561,\n// 295 8 27\n1829045.485824, 0.0, -4.0, 4.0, 7687.6, 7687.6,\n 0.0106860, 0.5030823, -1.570e-05, -7.690e-06,\n -0.4015390, -0.2570913, -4.320e-05, 4.130e-06,\n 10.2822104, -0.0142990, -2.000e-06,\n 180.0393829, 15.0036631, 0.000e-00,\n 0.5414860, -0.0001072, -1.210e-05,\n -0.0046290, -0.0001067, -1.210e-05,\n 0.0046626, 0.0046394,\n// 296 2 20\n1829222.278375, 19.0, -4.0, 4.0, 7682.9, 7682.9,\n -0.3379950, 0.4789653, -2.990e-05, -6.280e-06,\n 1.0511080, 0.2413312, 6.400e-06, -3.330e-06,\n -10.9493303, 0.0143170, 2.000e-06,\n 101.0333786, 15.0029278, 0.000e-00,\n 0.5559690, 0.0001085, -1.100e-05,\n 0.0097820, 0.0001079, -1.100e-05,\n 0.0046942, 0.0046709,\n// 296 8 16\n1829399.922635, 10.0, -4.0, 4.0, 7678.2, 7678.2,\n -0.5481570, 0.4825508, 3.700e-06, -6.160e-06,\n -1.0038300, -0.2231634, -3.800e-05, 3.040e-06,\n 13.9730501, -0.0128710, -3.000e-06,\n 329.5112305, 15.0027866, 0.000e-00,\n 0.5556880, -0.0001077, -1.070e-05,\n 0.0095030, -0.0001072, -1.070e-05,\n 0.0046487, 0.0046256,\n// 297 1 10\n1829547.310216, 19.0, -4.0, 4.0, 7674.4, 7674.4,\n -0.0093420, 0.5613054, -4.970e-05, -9.370e-06,\n -0.9871280, 0.1462293, 2.141e-04, -2.620e-06,\n -21.9448509, 0.0062940, 6.000e-06,\n 102.0598984, 14.9975929, 0.000e-00,\n 0.5390590, 0.0000585, -1.300e-05,\n -0.0070440, 0.0000582, -1.290e-05,\n 0.0047411, 0.0047175,\n// 297 7 6\n1829724.420595, 22.0, -4.0, 4.0, 7669.7, 7669.7,\n 0.1420800, 0.4954499, -3.610e-05, -5.530e-06,\n 0.9282930, -0.1017821, -1.771e-04, 1.260e-06,\n 22.9416199, -0.0038800, -5.000e-06,\n 149.8231049, 14.9992971, 0.000e-00,\n 0.5660600, 0.0000108, -9.700e-06,\n 0.0198240, 0.0000107, -9.600e-06,\n 0.0046074, 0.0045844,\n// 297 12 31\n1829901.968797, 11.0, -4.0, 4.0, 7665.0, 7665.0,\n -0.0919440, 0.5693716, -1.890e-05, -9.460e-06,\n -0.3069070, 0.1033330, 1.922e-04, -1.870e-06,\n -23.2289009, 0.0031550, 6.000e-06,\n 343.1856689, 14.9966269, 0.000e-00,\n 0.5400440, -0.0000500, -1.290e-05,\n -0.0060640, -0.0000497, -1.290e-05,\n 0.0047493, 0.0047257,\n// 298 6 25\n1830078.495498, 0.0, -4.0, 4.0, 7660.3, 7660.3,\n 0.0755010, 0.5173669, -3.590e-05, -6.310e-06,\n 0.1513970, -0.0640771, -1.582e-04, 9.000e-07,\n 23.6217098, -0.0007810, -6.000e-06,\n 180.4063263, 14.9990377, 0.000e-00,\n 0.5581130, 0.0000952, -1.020e-05,\n 0.0119160, 0.0000947, -1.020e-05,\n 0.0046006, 0.0045777,\n// 298 12 21\n1830256.520381, 0.0, -4.0, 4.0, 7655.6, 7655.6,\n -0.3080510, 0.5485759, 1.490e-05, -7.890e-06,\n 0.3821460, 0.0532161, 1.534e-04, -8.900e-07,\n -23.6581993, -0.0002200, 7.000e-06,\n 179.5037689, 14.9961662, 0.000e-00,\n 0.5524180, -0.0001085, -1.180e-05,\n 0.0062490, -0.0001079, -1.170e-05,\n 0.0047556, 0.0047319,\n// 299 6 15\n1830432.844031, 8.0, -4.0, 4.0, 7651.0, 7651.0,\n -0.1684550, 0.5530558, -1.640e-05, -8.040e-06,\n -0.6087570, -0.0237378, -1.312e-04, 4.400e-07,\n 23.4537601, 0.0022700, -6.000e-06,\n 300.9961853, 14.9993067, 0.000e-00,\n 0.5430000, 0.0001226, -1.150e-05,\n -0.0031220, 0.0001219, -1.150e-05,\n 0.0045964, 0.0045735,\n// 299 12 10\n1830610.796717, 7.0, -4.0, 4.0, 7646.3, 7646.3,\n -0.0753190, 0.5176722, 1.550e-05, -6.230e-06,\n 1.1493250, 0.0056315, 1.089e-04, -1.700e-07,\n -23.1608791, -0.0036980, 6.000e-06,\n 285.8791809, 14.9963713, 0.000e-00,\n 0.5681960, -0.0000940, -1.040e-05,\n 0.0219480, -0.0000936, -1.040e-05,\n 0.0047592, 0.0047355,\n// 300 5 5\n1830758.183129, 16.0, -4.0, 4.0, 7642.4, 7642.4,\n -0.4668280, 0.5720948, 4.770e-05, -9.780e-06,\n 1.1027761, 0.1199172, -1.717e-04, -1.960e-06,\n 16.3703709, 0.0115750, -3.000e-06,\n 61.5473213, 15.0028343, 0.000e-00,\n 0.5304310, 0.0000130, -1.280e-05,\n -0.0156280, 0.0000129, -1.280e-05,\n 0.0046053, 0.0045824,\n// 300 6 3\n1830787.461821, 23.0, -4.0, 4.0, 7641.6, 7641.6,\n -0.0021950, 0.5793734, -2.400e-06, -9.660e-06,\n -1.3264550, 0.0202615, -8.530e-05, -2.500e-07,\n 22.5109501, 0.0051150, -5.000e-06,\n 166.4671173, 14.9999781, 0.000e-00,\n 0.5316500, 0.0000554, -1.260e-05,\n -0.0144150, 0.0000551, -1.260e-05,\n 0.0045951, 0.0045722,\n// 300 10 29\n1830935.000621, 12.0, -4.0, 4.0, 7637.7, 7637.7,\n -0.2946260, 0.4925518, 2.420e-05, -5.590e-06,\n -1.1754920, -0.1201967, 1.319e-04, 1.290e-06,\n -13.8886499, -0.0136920, 3.000e-06,\n 3.5897200, 15.0012589, 0.000e-00,\n 0.5728800, 0.0000544, -1.000e-05,\n 0.0266080, 0.0000541, -9.900e-06,\n 0.0047430, 0.0047193\n));\n}", "title": "" }, { "docid": "4bc3f649fa69434d2cd6c1a873356120", "score": "0.51966864", "text": "function validSolution(board){\n// return \"false\" if the table contains any 0's\nvar stringboard = board.join(\"\");\nvar zeroCheck = stringboard.search(\"0\");\nif (zeroCheck != -1) {\n\treturn false;\n} else {\n\tboard = board;\n}\n// if there are no 0's, let's turn the data into something more manageable\nvar arrayVals = [];\nfor(var i = 0; i < board.length; i++){\n\tfor(var j = 0; j < board[i].length; j++){\n\t\tarrayVals.push(board[i][j]);\n\t}\n// remove commas from each string and replace with +'s\nvar regex = new RegExp(',', 'g');\nvar row1 = arrayVals.slice(0, 9).toString().replace(regex, '+');\nvar row2 = arrayVals.slice(9, 18).toString().replace(regex, '+');\nvar row3 = arrayVals.slice(18, 27).toString().replace(regex, '+');\nvar row4 = arrayVals.slice(27, 36).toString().replace(regex, '+');\nvar row5 = arrayVals.slice(36, 45).toString().replace(regex, '+');\nvar row6 = arrayVals.slice(45, 54).toString().replace(regex, '+');\nvar row7 = arrayVals.slice(54, 63).toString().replace(regex, '+');\nvar row8 = arrayVals.slice(63, 72).toString().replace(regex, '+');\nvar row9 = arrayVals.slice(72, 81).toString().replace(regex, '+');\n} // end for loop\n// evaluate the expression. numbers 1-9 will = 45\nvar rows = [eval(row1), eval(row2), eval(row3), eval(row4), eval(row5), eval(row6), eval(row7), eval(row8), eval(row9)];\nvar wrong = [];\nvar right = [];\nfor(var i = 0; i < rows.length; i++){\n\tif(rows[i] != 45) {\n\t\treturn false;\n\t} else {\n\t\tright.push(rows[i]);\n\t}\n} // end for loop\nif (right.length > 8) {\n\trows = rows;\n} else {\n\treturn false;\n}\n// check if all arrays are in a different order\nvar arrS = [row1, row2, row3, row4, row5, row6, row7, row8, row9];\n// return rawRows;\nvar sorted_arr = arrS.slice().sort(); \nvar results = [];\nfor (var i = 0; i < arrS.length + 1 - 1; i++) {\n\tif (sorted_arr[i + 1] == sorted_arr[i]) {\n\t\tresults.push(sorted_arr[i]);\n\t}\n}\nif (results.length > 0) {\n\treturn false;\n} else {\n\tarrS = arrS;\n}\n// if vertical \"column\" numbers = 9, they are also uniquely ordered!\nvar vertOne = (eval(row1.charAt(0) + \"+\" + row2.charAt(0) + \"+\" + row3.charAt(0) + \"+\" + row4.charAt(0) + \"+\" + row5.charAt(0) + \"+\" + row6.charAt(0) + \"+\" + row7.charAt(0) + \"+\" + row8.charAt(0) + \"+\" + row9.charAt(0)));\nvar vertTwo = (eval(row1.charAt(2) + \"+\" + row2.charAt(2) + \"+\" + row3.charAt(2) + \"+\" + row4.charAt(2) + \"+\" + row5.charAt(2) + \"+\" + row6.charAt(2) + \"+\" + row7.charAt(2) + \"+\" + row8.charAt(2) + \"+\" + row9.charAt(2)));\nvar vertThree = (eval(row1.charAt(4) + \"+\" + row2.charAt(4) + \"+\" + row3.charAt(4) + \"+\" + row4.charAt(4) + \"+\" + row5.charAt(4) + \"+\" + row6.charAt(4) + \"+\" + row7.charAt(4) + \"+\" + row8.charAt(4) + \"+\" + row9.charAt(4)));\nvar vertFour = (eval(row1.charAt(6) + \"+\" + row2.charAt(6) + \"+\" + row3.charAt(6) + \"+\" + row4.charAt(6) + \"+\" + row5.charAt(6) + \"+\" + row6.charAt(6) + \"+\" + row7.charAt(6) + \"+\" + row8.charAt(6) + \"+\" + row9.charAt(6)));\nvar vertFive = (eval(row1.charAt(8) + \"+\" + row2.charAt(8) + \"+\" + row3.charAt(8) + \"+\" + row4.charAt(8) + \"+\" + row5.charAt(8) + \"+\" + row6.charAt(8) + \"+\" + row7.charAt(8) + \"+\" + row8.charAt(8) + \"+\" + row9.charAt(8)));\nvar vertSix = (eval(row1.charAt(10) + \"+\" + row2.charAt(10) + \"+\" + row3.charAt(10) + \"+\" + row4.charAt(10) + \"+\" + row5.charAt(10) + \"+\" + row6.charAt(10) + \"+\" + row7.charAt(10) + \"+\" + row8.charAt(10) + \"+\" + row9.charAt(10)));\nvar vertSeven = (eval(row1.charAt(12) + \"+\" + row2.charAt(12) + \"+\" + row3.charAt(12) + \"+\" + row4.charAt(12) + \"+\" + row5.charAt(12) + \"+\" + row6.charAt(12) + \"+\" + row7.charAt(12) + \"+\" + row8.charAt(12) + \"+\" + row9.charAt(12)));\nvar vertEight = (eval(row1.charAt(14) + \"+\" + row2.charAt(14) + \"+\" + row3.charAt(14) + \"+\" + row4.charAt(14) + \"+\" + row5.charAt(14) + \"+\" + row6.charAt(14) + \"+\" + row7.charAt(14) + \"+\" + row8.charAt(14) + \"+\" + row9.charAt(14)));\nvar vertNine = (eval(row1.charAt(16) + \"+\" + row2.charAt(16) + \"+\" + row3.charAt(16) + \"+\" + row4.charAt(16) + \"+\" + row5.charAt(16) + \"+\" + row6.charAt(16) + \"+\" + row7.charAt(16) + \"+\" + row8.charAt(16) + \"+\" + row9.charAt(16)));\nvar vertRow = vertOne + \" \" + vertTwo + \" \" + vertThree + \" \" + vertFour + \" \" + vertFive + \" \" + vertSix + \" \" + vertSeven + \" \" + vertEight + \" \" + vertNine;\n// convert vertRow to an array of integers\nvar change = vertRow.split(\" \");\nvar vertRowIntegers = [];\nvar result = change.map(function (z) { \n\tvertRowIntegers.push(parseInt(z, 10)); \n});\n// finally, evaluate the expression. numbers 1-9 will = 45\nfor(var i = 0; i < vertRowIntegers.length; i++){\n\tif(vertRowIntegers[i] != 45) {\n\t\treturn false;\n\t} else {\n\t\treturn true\n\t\t}\t\n\t}\n}", "title": "" }, { "docid": "77451ade94a9a8f07acf1ee1c2b12911", "score": "0.5185983", "text": "function calculateGroupTotal(cellsToTotal, totalTd, groupTotalDiv, rowIndex, columnIndex){\r\n\r\n var total = 0;\r\n var values = new Array();\r\n var hasInvalidValues = false;\r\n var extraData = groupTotalDiv.data(\"params\");\r\n var functionName = groupTotalDiv.data(\"function\");\r\n\r\n for(var i = 0; i < cellsToTotal.length; i++){\r\n var currentCell = cellsToTotal[i];\r\n\r\n if (currentCell && jQuery(currentCell).find(\":input[name^='newCollectionLines']\").length == 0) {\r\n var value = coerceTableCellValue(currentCell);\r\n //set hasInvalidValues to true if value is undefined\r\n if (value == undefined) {\r\n hasInvalidValues = true;\r\n break;\r\n }\r\n\r\n //skip over value when blank\r\n if (value != \"\") {\r\n value = parseFloat(value);\r\n values.push(value);\r\n }\r\n }\r\n }\r\n\r\n if (!hasInvalidValues) {\r\n if(extraData != undefined){\r\n total = window[functionName](values, extraData);\r\n }\r\n else{\r\n total = window[functionName](values);\r\n }\r\n }\r\n else {\r\n total = \"N/A\";\r\n }\r\n\r\n var groupTotalDisplay = totalTd.find(\"div[data-role='groupTotal'][data-function='\" + functionName + \"']\");\r\n //clone and append, if no place to display the total has been generated yet\r\n if(groupTotalDisplay.length == 0){\r\n groupTotalDisplay = groupTotalDiv.clone();\r\n //resetting ids to unique ids on the clone\r\n groupTotalDisplay = groupTotalDisplay.attr(\"id\", groupTotalDisplay.attr(\"id\") + \"_\" + rowIndex + columnIndex);\r\n groupTotalDisplay.find(\"[id]\").each(function(){\r\n jQuery(this).attr(\"id\", jQuery(this).attr(\"id\") + \"_\" + rowIndex + columnIndex);\r\n });\r\n totalTd.append(groupTotalDisplay);\r\n groupTotalDisplay.show();\r\n }\r\n\r\n var totalValueSpan = groupTotalDisplay.find(\"span[data-role='totalValue']\");\r\n\r\n if (totalValueSpan.length) {\r\n totalValueSpan.html(total);\r\n }\r\n else {\r\n var newSpan = jQuery(\"<span data-role='totalValue'>\" + total + \"</span>\");\r\n groupTotalDisplay.append(newSpan);\r\n }\r\n\r\n}", "title": "" }, { "docid": "da234d010c6d0e2ed92d45f204a19c77", "score": "0.51788783", "text": "function calcTotal() {\n\tvar table = document.getElementById('tb');\n var body = table.tBodies[0]\n var rows = body.rows\n\t\n\tvar total = 0;\n\t\n\tfor(var i = 2; i < rows.length-1;i++) {\n\t\tif(rows[i].cells[1].innerHTML == \"Income\") {\n\t\t\ttotal += parseFloat(rows[i].cells[2].innerHTML.replace(\"$\", \"\"));\n\t\t} else {\n\t\t\ttotal -= parseFloat(rows[i].cells[2].innerHTML.replace(\"$\", \"\"));\n\t\t}\n\t}\n\t\n\tvar htotal = document.getElementById('total');\n\thtotal.innerHTML = '$' + Math.round(total * 100) / 100;\n}", "title": "" }, { "docid": "2888d98a77e49568b307e64cb2f0d64e", "score": "0.51768225", "text": "function agregarLineaDet() {\n var tabla = document.getElementById(\"tablaDetalle\");\n var i = (document.getElementsByName(\"boxNmbItem[]\").length) + 1;\n var row1 = tabla.insertRow(i);\n\n var cell1 = row1.insertCell(0);\n var cell2 = row1.insertCell(1);\n var cell3 = row1.insertCell(2);\n var cell4 = row1.insertCell(3);\n var cell5 = row1.insertCell(4);\n var cell6 = row1.insertCell(5);\n var cell7 = row1.insertCell(6);\n var cell8 = row1.insertCell(7);\n var cell9 = row1.insertCell(8);\n\n cell1.innerHTML = '<input type=\"text\" name=\"boxNmbItem[]\" id=\"boxNmbItem[]\" class=\"js-example-basic-single js-states form-control\">';\n cell2.innerHTML = '<input type=\"text\" name=\"boxQtyItem[]\" id=\"boxQtyItem[]\" step=\"0.01\" class=\"js-example-basic-single js-states form-control\">';\n cell3.innerHTML = '<input type=\"text\" name=\"boxUnmdItem[]\" id=\"boxUnmdItem[]\" class=\"js-example-basic-single js-states form-control\">';\n cell4.innerHTML = '<input type=\"text\" name=\"boxPrcItem[]\" id=\"boxPrcItem[]\" step=\"0.01\" class=\"js-example-basic-single js-states form-control\">';\n cell5.innerHTML = '<input type=\"text\" name=\"boxDescuentoPct[]\" id=\"boxDescuentoPct[]\" step=\"0.01\" class=\"js-example-basic-single js-states form-control\" value=\"0\">'+\n '<input type=\"hidden\" name=\"boxDescuentoMonto[]\" id=\"boxDescuentoMonto[]\" step=\"0.01\">'+\n '<input type=\"text\" name=\"boxRecargoPct[]\" id=\"boxRecargoPct[]\" step=\"0.01\"class=\"js-example-basic-single js-states form-control\" value=\"0\">'+\n '<input type=\"hidden\" name=\"boxRecargoMonto[]\" id=\"boxRecargoMonto[]\" step=\"0.01\">';\n cell6.innerHTML = '<select name=\"ddlTipoRecDesc\" id=\"ddlTipoRecDesc\" class=\"js-example-basic-single js-states form-control\" style=\"width: 56px\">'+\n '<option value=\"D\">D</option>'+\n '<option value=\"R\">R</option></select>';\n cell7.innerHTML = '<input type=\"text\" name=\"boxMontoItem[]\" id=\"boxMontoItem[]\" readonly=\"yes\" step=\"0.01\" class=\"js-example-basic-single js-states form-control\">';\n cell8.innerHTML = '<select id=\"boxIndExe[]\" name=\"boxIndExe[]\" class=\"js-example-basic-single js-states form-control\" style=\"width: 66px\">'+ \n '<option value=\"1\" selected=\"selected\">SÍ</option>'+\n '<option value=\"0\">NO</option></select>';\n cell9.innerHTML = '<button type=\"button\" id=\"btnEliminaLineaDet\" class=\"btn btn-primary\" onclick=\"eliminarLineaDet(this);\">-</button>';\n \n var desc = document.getElementsByName(\"boxDescuentoPct[]\");\n var rec = document.getElementsByName(\"boxRecargoPct[]\");\n $(desc[i-1]).show();\n $(rec[i-1]).hide();\n}", "title": "" }, { "docid": "52e35d711d51ade29709711f0c2bbc08", "score": "0.51721746", "text": "function calcAll() {\n let rows = document.getElementsByClassName('product') //Returns me an Array with how many rows I have\n //how many prodcuts I have\n let finalTotal = 0;\n\n for (let i = 0; i < rows.length; i++) {\n let current = rows[i]; // shows me each element inside the row <tr class='product'>\n //(<td>class='name', class='pu', class='qty', class='subtot' class='remove')\n\n //get the quantity\n let quantityInput = current.querySelector('.qty input');\n let qty = quantityInput.value;\n console.log(qty)\n //show the value/quantity that we give to the form in the column of quantity \n\n //get the price\n let price = current.querySelector('.pu span').innerText;\n console.log(price)\n\n //multiply them together\n let result = price * qty\n //it works due to is a multiplication, risk operation if in the future we want to change\n\n let sub = current.querySelector('.subtot') //We acces to <td class='subtot'>\n\n sub.innerText = '$' + result.toFixed(2); //Put the result in the subtotal spot\n finalTotal += result //here!\n\n }\n\n //after the loop add up the totals and put the real totl at the bottom\n\n document.querySelector('h2 > span').innerText = finalTotal.toFixed(2)\n}", "title": "" }, { "docid": "434fa1471de0a29ebb26e4adb295257b", "score": "0.5171947", "text": "function generateHtmlTableValidation(body_id, data, calc_data) {\n\n init_val = 2\n\n for (var i = init_val; i < data.length; i++) {\n\n var result = \"<tr>\";\n for(var j = 0; j < data[i].length; j++){\n // THE SIZE OF INPUT DATA IS LESS THAN THE TOTAL VALIDATION DATA\n if(i < calc_data.length){\n // WE SHOW BOTH DATA, VALIDATION AND CALCULATED DATA, AND USE GREEN TO\n // TO DIFFERENTIATE THE CALCULATED DATA\n result += \"<td><p>\"+data[i][j]+\"</p> <p style='color: #007F00'>\" + calc_data[i-init_val][j] +\"</p></td>\";\n }\n // IF NOT EXISTS MORE INPUT DATA ONLY ADD VALIDATION DATA ON HMTL PAGE\n else{\n result += \"<td>\"+data[i][j]+\"</td>\"\n }\n }\n\n // THE SIZE OF INPUT DATA IS LESS THAN THE TOTAL VALIDATION DATA\n if(i < calc_data.length){\n result += \"<td><p style='color: #007F00'>\" + calc_data[i-init_val][j] +\"</p></td>\";\n }\n document.getElementById(body_id).innerHTML += result\n }\n}", "title": "" }, { "docid": "0b7d7a9e80478fb61f522b4a42dded5a", "score": "0.51709396", "text": "function readInput()\r\n{\r\n removeTable();\r\n firstVector=document.getElementById('FirstLine').value.replace(/\\s+/g, '');\r\n secondVector=document.getElementById('SecondLine').value.replace(/\\s+/g, '');\r\n time=document.getElementById('Time').value.replace(/\\s+/g, '');\r\n\r\n firstVector = firstVector.replace(/,+$/g, '');\r\n secondVector = secondVector.replace(/,+$/g, '');\r\n\r\n firstVector = firstVector.split(',');\r\n secondVector = secondVector.split(',');\r\n\r\n time= +time;\r\n\r\n if(firstVector.length!=0 && \r\n secondVector.length!=0 && \r\n time!=0 && \r\n firstVector.length==secondVector.length)\r\n {\r\n len=firstVector.length;\r\n\r\n for(var i = 0; i < firstVector.length; i++)\r\n\t\t\tif (firstVector[i].match(/^\\d+$/)){\r\n\t\t\t\tfirstVector[i] = +firstVector[i];\r\n firstVector[i]=lengthcheck(firstVector[i].toString(2));\r\n }\r\n\r\n\t\tfor(var i = 0; i < secondVector.length; i++)\r\n\t\t\tif (secondVector[i].match(/^\\d+$/)){\r\n\t\t\t\tsecondVector[i] = +secondVector[i];\r\n secondVector[i]=lengthcheck(secondVector[i].toString(2));\r\n\r\n }\r\n\r\n for(var i=0;i<firstVector.length;i++)\r\n {\r\n result[i]=[];\r\n for(var j=0;j<12;j++)\r\n result[i][j]=0;\r\n buffer[i]=[];\r\n for(var j=0;j<7;j++)\r\n buffer[i][j]=0;\r\n }\r\n \r\n table=document.getElementById(\"Table\");\r\n row=table.insertRow(-1);\r\n cell=row.insertCell(-1);\r\n cell.innerHTML=\"Пара<br>Действие\";\r\n for(var i=1;i<=12;i++)\r\n {\r\n cell=row.insertCell(-1);\r\n if(i%2!=0)\r\n cell.innerHTML=\"Этап \"+i+\":<br>произведение\";\r\n else\r\n cell.innerHTML=\"Этап \"+i+\":<br>сдвиг\";\r\n }\r\n step=1;\r\n }\r\n else\r\n createMessage(\"Данные введены неверно.\");\r\n}", "title": "" }, { "docid": "85fff81526734cc13f5f73e85ce04ba6", "score": "0.51599514", "text": "function totalHours() {\n\n var row3 = document.createElement('tr');\n table.appendChild(row3);\n var Header3 = document.createElement('th');\n Header3.textContent = 'Totals';\n row3.appendChild(Header3);\n\n var totalOfTotals = 0;\n\n for (var i = 0; i < hoursArr.length; i++) {\n var totalLocationPerHour = 0;\n\n var tableHeader3 = document.createElement('td');\n for (let index = 0; index < locationArrays.length; index++) {\n totalLocationPerHour += locationArrays[index].resultPerHourArr[i];\n\n }\n\n tableHeader3.textContent = totalLocationPerHour;\n\n row3.appendChild(tableHeader3);\n totalOfTotals = totalOfTotals + totalLocationPerHour;\n\n\n }\n\n var tableHeader3 = document.createElement('td');\n tableHeader3.textContent = totalOfTotals;\n row3.appendChild(tableHeader3);\n}", "title": "" }, { "docid": "d03fe5c3aa057a4c6172cdd90f8570e0", "score": "0.5146383", "text": "function finalize_numbers() {\n // Calculator will always have 1 initial row.\n // Insert second last row.\n let last_row = calc.rows[calc.rows.length-1];\n let save_row = calc.insertRow(calc.rows.length-1);\n\n // make 4 cells for the 3 representations to show and operation\n for (let i = 0; i < last_row.cells.length; i++) {\n let save_cell = save_row.insertCell();\n let input_cell = last_row.cells[i];\n if (input_cell.childElementCount === 0) {\n // tr > td > text\n save_cell.textContent = input_cell.textContent;\n input_cell.textContent = \"\";\n } else {\n // tr > td > input > value\n save_cell.textContent = input_cell.children[0].value;\n input_cell.children[0].value = \"\";\n }\n }\n }", "title": "" }, { "docid": "0ebd713ea1b3cf14ef57f313585d5f54", "score": "0.51459557", "text": "function clickCell(ref) {\r\n // Check if the selected cell changed\r\n if (lastSelectedCell) {\r\n //remove cellSelected class of the last selected cell...\r\n let element = document.getElementById(lastSelectedCell);\r\n element.classList.remove(\"cellSelected\");\r\n // Assign new name to the cell\r\n element.className = \"cell\";\r\n }\r\n\r\n tableCellDisplay.innerHTML = ref.id\r\n ref.className = \"cellSelected\";\r\n\r\n // If there is a value in the cell display the value in the input\r\n var rcArray = ref.id.split('_');\r\n selectedRow = rcArray[0];\r\n selectedColumn = rcArray[1];\r\n input.value = tblArray[selectedRow - 1][selectedColumn - 1];\r\n // If it is not a formula display the the value on the cell\r\n if (!input.value.startsWith(\"=SUM\")) {\r\n document.getElementById(tableCellDisplay.textContent).innerHTML = input.value;\r\n }\r\n \r\n // Assign this as the last selected cell\r\n lastSelectedCell = tableCellDisplay.textContent;\r\n\r\n // Assign the value on table array\r\n var rcArray = ref.id.split('_');\r\n selectedRow = rcArray[0];\r\n selectedColumn = rcArray[1];\r\n\r\n // focus and able on input\r\n input.disabled = false;\r\n input.focus();\r\n\r\n // Able the button clean cell\r\n document.getElementById(\"btn-clear-cell\").disabled = false;\r\n}", "title": "" }, { "docid": "29507221505968f531d167113295b00d", "score": "0.51203", "text": "function footerTotal() {\n var totalFill = hourlyTotals;\n // console.log(`array is: ${totalFill}`);\n var title = 'Hourly Totals';\n var massTotal = 0;\n var tableFooter = document.getElementById('table-foot');\n var tableFooterEl = document.createElement('tr');\n var tableTitle = document.createElement('td');\n // console.log('row created');\n var tableFooterFinalCell = document.createElement('td');\n // console.log('Final cell created');\n\n\n tableFooter.appendChild(tableFooterEl);\n tableFooterEl.appendChild(tableTitle);\n tableTitle.textContent = title;\n // console.log(tableTitle.textContent);\n // console.log(`The row is: ${title}`);\n\n\n for (var i = 0; i < hours.length; i++) {\n var tf = document.createElement('td');\n // console.log(`fill is this: ${totalFill[i]}`);\n tf.textContent = totalFill[i];\n // console.log(`fill inserted: ${totalFill[i]}`);\n\n\n massTotal = massTotal + totalFill[i];\n // console.log(`total calculated to be ${massTotal}`);\n\n\n hourlyTotals[i] = hourlyTotals[i] + totalFill[i];\n // console.log(`Total for ${hours[i]}: is ${hourlyTotals[i]}`);\n tableFooterEl.appendChild(tf);\n // console.log(`child created`);\n }\n\n // console.log(`final total: ${massTotal}`);\n\n tableFooterEl.appendChild(tableFooterFinalCell);\n tableFooterFinalCell.textContent = massTotal;\n // console.log(`total: ${massTotal}`);\n}", "title": "" }, { "docid": "43f22fae9527738d1406a156c9524f3b", "score": "0.5119991", "text": "function fillTable(){ // Creates the basic table with the array\n\t\t\t\tfor(x = 0 ; x < total_x ; x++){\n\t\t\t\t\tvar extra = '';\n\t\t\t\t\textra += '<div class=\"row\">';\n\t\t\t\t\tfor(y = 0 ; y < total_y ; y++){\n\t\t\t\t\t\textra += '<div class=\"col element empty\" x=\"' + (x+1) + '\" y=\"' + (y+1) + '\" id=\"space_' + (x+1) + '-' + (y+1) + '\"></div>';\n\t\t\t\t\t\tmap_empty.push((x+1)+\",\"+(y+1));\n\t\t\t\t\t}\n\t\t\t\t\textra += '</div>';\n\t\t\t\t\tprint_row_table(extra);\n\t\t\t\t}\t\n\t\t}", "title": "" }, { "docid": "16231ea0a88f24112a9be5c9e54e2e68", "score": "0.5119909", "text": "function getTheSelectedCol(obj) {\n //get the selected column index\n var selcolumnindex=obj.parentNode.cellIndex;\n //console.log(selcolumnindex);\n\n //Get the cell of this index of each row\n\n //get all the rows in the table\n var rows=document.getElementsByTagName(\"tr\");\n\n //create an array to sum\n var sumarraycol=new Array();\n\n //get the cell of row\n for (var i=1; i <rows.length; i++ ){\n var eachcell = rows[i].cells[selcolumnindex];\n var eachinput=eachcell.getElementsByTagName(\"input\")[0];\n var iputvalue=eachinput.value;\n\n if(iputvalue===\"\"){\n //console.log(\"this is null\");\n }else{\n sumarraycol.push(iputvalue);\n }\n }\n\n //console.log(sumarraycol);\n\n //caluculate the sum\n\n var sum=0;\n var lengthofarray=sumarraycol.length;\n\n for (var i=0; i <lengthofarray; i++ ){\n //console.log(sumarray[i]);\n var intsum=parseInt(sumarraycol[i]);\n sum=sum+intsum;\n }\n\n //get the number of rows\n var numberrows=rows.length;\n\n\n //console.log(sumiput);\n\n if(lengthofarray>numberrows-2){\n addRowFunction();\n\n //get the specific cell input\n var sumiput=rows[lengthofarray+1].cells[selcolumnindex].getElementsByTagName(\"input\")[0];\n sumiput.value=sum;\n }else{\n\n //get the specific cell input\n var sumiput=rows[lengthofarray+1].cells[selcolumnindex].getElementsByTagName(\"input\")[0];\n\n sumiput.value=sum;\n }\n\n sumarraycol=[];\n}", "title": "" }, { "docid": "1a386ea23dbb6594dc5ca08774516341", "score": "0.51126486", "text": "function calculate_stats() {\r\n script = \"\";\r\n for (var i = 0; i < institute_list.length; i = i + 1) {\r\n var fail_case = 0;\r\n var border_case = 0;\r\n var pass_case = 0;\r\n var empty_case = 0;\r\n var first_case = false;\r\n var first_case_index = 0;\r\n var last_case_index = 0;\r\n var total_case = 0;\r\n for (var j = cur_start_index; j <= cur_end_index; j = j + 1) {\r\n if (value_data[i][j] == null) {\r\n empty_case += 1;\r\n }\r\n else {\r\n if (first_case == false) {\r\n first_case_index = j - cur_start_index;\r\n first_case = true;\r\n }\r\n if (parseFloat(value_data[i][j]) < fail_theshold) {\r\n fail_case += 1;\r\n last_case_index = j - cur_start_index;\r\n }\r\n else if (parseFloat(value_data[i][j]) >= fail_theshold && parseFloat(value_data[i][j]) < pass_theshold) {\r\n border_case += 1;\r\n last_case_index = j - cur_start_index;\r\n }\r\n else {\r\n pass_case += 1;\r\n last_case_index = j - cur_start_index;\r\n }\r\n }\r\n total_case = total_case + 1;\r\n }\r\n script += \"<tr><td>\" + institute_list[i] + \"</td><td>\" + fail_case + \"</td><td>\" + border_case + \"</td><td>\" + pass_case + \"</td><td>\" + total_case + \"</td>\";\r\n if (empty_case === total_case) {\r\n script += \"<td>No data available</td>\";\r\n }\r\n else if (empty_case === 0) {\r\n script += \"<td>Full range available</td>\";\r\n }\r\n else {\r\n script += \"<td>Partial range available</td>\";\r\n }\r\n if (empty_case === total_case) {\r\n script += \"<td></td></tr>\";\r\n }\r\n else {\r\n if ((empty_case + (last_case_index - first_case_index + 1)) === total_case) {\r\n script += \"<td>No</td></tr>\";\r\n }\r\n else {\r\n script += \"<td>Yes</td></tr>\";\r\n }\r\n }\r\n\r\n //var dict = {};\r\n //dict.fail = fail_case;\r\n //dict.border = border_case;\r\n //dict.pass = pass_case;\r\n //dict.empty = empty_case;\r\n //dict.total_case = total_case;\r\n //data_result.push(dict);\r\n }\r\n}", "title": "" }, { "docid": "18894b2efb78d9f645000b05c3c87494", "score": "0.51096904", "text": "function getTheSelectedRow(obj) {\n var selectedelEmentIndex=obj.parentNode.parentNode.rowIndex;\n //console.log(obj.parentNode);\n\n //get all the rows in the table\n var rows=document.getElementsByTagName(\"tr\");\n\n //get all the columns of this row\n var thiscolumns=document.getElementById(\"table\").rows[selectedelEmentIndex].getElementsByTagName(\"input\");\n console.log(thiscolumns);\n\n //get the number of columns\n var numberofcolumns=document.getElementById(\"table\").rows[0].cells.length;\n\n //create an array to sum\n var sumarray=new Array();\n\n //get each cell input of this row\n for (var i=1; i <numberofcolumns; i++ ){\n\n var inputofcell=thiscolumns[i].value;\n\n if(inputofcell===\"\"){\n //console.log(\"this is null\");\n }else{\n sumarray.push(inputofcell);\n }\n }\n\n //console.log(sumarray);\n\n //caluculate the sum\n\n var sum=0;\n var lengthofarray=sumarray.length;\n\n for (var i=0; i <lengthofarray; i++ ){\n //console.log(sumarray[i]);\n var intsum=parseInt(sumarray[i]);\n sum=sum+intsum;\n }\n\n //get the number of rows\n var numberrows=rows.length;\n\n if(lengthofarray>numberrows-2){\n addColumnFunction();\n thiscolumns[lengthofarray+1].value=sum;\n }else{\n thiscolumns[lengthofarray+1].value=sum;\n }\n\n sumarray=[];\n}", "title": "" }, { "docid": "375a102c96e9b8aa6b82a4c307d67ac0", "score": "0.5105173", "text": "function SE1801() {\n calculatefor(new Array(\n// 1801 3 14\n2378934.156652, 16.0, -4.0, 4.0, 13.0, 13.0,\n 0.8100150, 0.4830337, -6.270e-05, -6.820e-06,\n -1.2019800, 0.2648827, 6.670e-05, -3.970e-06,\n -2.5304899, 0.0157840, 0.000e-00,\n 57.6363487, 15.0041323, 0.000e-00,\n 0.5495640, 0.0001101, -1.160e-05,\n 0.0034090, 0.0001095, -1.160e-05,\n 0.0046985, 0.0046751,\n// 1801 4 13\n2378963.672294, 4.0, -4.0, 4.0, 13.0, 13.0,\n -0.6694200, 0.4738215, 3.900e-05, -6.130e-06,\n 1.1344150, 0.2457214, -1.050e-04, -3.330e-06,\n 8.8514404, 0.0145630, -2.000e-06,\n 239.8324127, 15.0039158, 0.000e-00,\n 0.5553760, 0.0001158, -1.080e-05,\n 0.0091920, 0.0001152, -1.080e-05,\n 0.0046593, 0.0046361,\n// 1801 9 8\n2379111.746291, 6.0, -4.0, 4.0, 12.9, 12.9,\n 0.7361610, 0.4573229, -3.470e-05, -5.460e-06,\n 1.2682600, -0.2465284, -8.860e-05, 3.090e-06,\n 5.8899498, -0.0150820, -1.000e-06,\n 270.5756531, 15.0046072, 0.000e-00,\n 0.5613070, -0.0000925, -1.030e-05,\n 0.0150940, -0.0000921, -1.020e-05,\n 0.0046451, 0.0046220,\n// 1801 10 7\n2379141.321227, 20.0, -4.0, 4.0, 12.9, 12.9,\n -0.5056660, 0.4708725, 5.560e-05, -6.100e-06,\n -1.2668420, -0.2534780, 8.040e-05, 3.490e-06,\n -5.5502100, -0.0153760, 1.000e-06,\n 123.0362091, 15.0040665, 0.000e-00,\n 0.5561520, -0.0001204, -1.090e-05,\n 0.0099650, -0.0001198, -1.090e-05,\n 0.0046836, 0.0046603,\n// 1802 3 4\n2379288.718393, 5.0, -4.0, 4.0, 12.8, 12.8,\n 0.2042810, 0.5100489, -4.110e-05, -8.360e-06,\n -0.6780480, 0.2727424, 7.380e-05, -4.690e-06,\n -6.7044802, 0.0153230, 1.000e-06,\n 251.9541168, 15.0035343, 0.000e-00,\n 0.5382340, 0.0000624, -1.280e-05,\n -0.0078640, 0.0000621, -1.280e-05,\n 0.0047116, 0.0046882,\n// 1802 8 28\n2379465.799998, 7.0, -4.0, 4.0, 12.6, 12.6,\n 0.2543930, 0.4498334, -3.640e-05, -4.950e-06,\n 0.7199510, -0.2297725, -7.840e-05, 2.690e-06,\n 9.9799404, -0.0141190, -2.000e-06,\n 284.6983643, 15.0040531, 0.000e-00,\n 0.5677130, 0.0000045, -9.700e-06,\n 0.0214680, 0.0000045, -9.700e-06,\n 0.0046326, 0.0046095,\n// 1803 2 21\n2379643.388034, 21.0, -4.0, 4.0, 12.5, 12.5,\n -0.1588410, 0.5185325, -1.800e-05, -8.600e-06,\n -0.0882930, 0.2608243, 7.160e-05, -4.540e-06,\n -10.6549301, 0.0144100, 2.000e-06,\n 131.4983978, 15.0025368, 0.000e-00,\n 0.5380070, -0.0000385, -1.300e-05,\n -0.0080900, -0.0000383, -1.290e-05,\n 0.0047240, 0.0047005,\n// 1803 8 17\n2379819.850732, 8.0, -4.0, 4.0, 12.4, 12.4,\n -0.1983710, 0.4702003, -4.010e-05, -5.590e-06,\n 0.0869530, -0.2186644, -7.250e-05, 2.760e-06,\n 13.7350998, -0.0126740, -3.000e-06,\n 299.0085449, 15.0032454, 0.000e-00,\n 0.5604640, 0.0001017, -1.020e-05,\n 0.0142550, 0.0001012, -1.010e-05,\n 0.0046209, 0.0045979,\n// 1804 2 11\n2379997.969821, 11.0, -4.0, 4.0, 12.4, 12.4,\n -0.4307500, 0.5056624, -1.800e-06, -7.350e-06,\n 0.5791170, 0.2293097, 6.310e-05, -3.540e-06,\n -14.3266697, 0.0130020, 3.000e-06,\n 341.3434753, 15.0011911, 0.000e-00,\n 0.5495080, -0.0001112, -1.190e-05,\n 0.0033540, -0.0001107, -1.180e-05,\n 0.0047354, 0.0047118,\n// 1804 8 5\n2380174.164739, 16.0, -4.0, 4.0, 12.3, 12.3,\n -0.2633840, 0.5098733, -4.460e-05, -7.230e-06,\n -0.7157390, -0.2072178, -6.070e-05, 3.090e-06,\n 16.9557590, -0.0108290, -4.000e-06,\n 58.5992317, 15.0022945, 0.000e-00,\n 0.5452180, 0.0001189, -1.140e-05,\n -0.0009150, 0.0001183, -1.130e-05,\n 0.0046112, 0.0045882,\n// 1805 1 1\n2380322.552045, 1.0, -4.0, 4.0, 12.3, 12.3,\n 0.1415040, 0.5012597, -2.390e-05, -5.730e-06,\n -1.5302300, 0.0884176, 2.156e-04, -1.120e-06,\n -23.0645103, 0.0030580, 6.000e-06,\n 194.0721436, 14.9963732, 0.000e-00,\n 0.5727400, -0.0000588, -1.010e-05,\n 0.0264690, -0.0000585, -1.000e-05,\n 0.0047567, 0.0047330,\n// 1805 1 30\n2380352.289593, 19.0, -4.0, 4.0, 12.2, 12.2,\n -0.5065840, 0.4857881, -4.000e-06, -5.890e-06,\n 1.3749280, 0.1888219, 5.150e-05, -2.470e-06,\n -17.6171093, 0.0110190, 4.000e-06,\n 101.5598602, 14.9996271, 0.000e-00,\n 0.5657050, -0.0001061, -1.050e-05,\n 0.0194690, -0.0001055, -1.050e-05,\n 0.0047451, 0.0047215,\n// 1805 6 26\n2380499.477543, 23.0, -4.0, 4.0, 12.2, 12.2,\n -0.1289060, 0.5793614, -1.850e-05, -9.880e-06,\n 1.0725690, -0.0769953, -2.291e-04, 1.450e-06,\n 23.3763008, -0.0012520, -5.000e-06,\n 164.4108734, 14.9993210, 0.000e-00,\n 0.5301310, 0.0000248, -1.280e-05,\n -0.0159270, 0.0000247, -1.270e-05,\n 0.0045979, 0.0045750,\n// 1805 7 26\n2380528.759937, 6.0, -4.0, 4.0, 12.2, 12.2,\n -0.5965630, 0.5478196, -1.920e-05, -9.010e-06,\n -1.3365340, -0.1848461, -5.020e-05, 3.190e-06,\n 19.5766602, -0.0086570, -5.000e-06,\n 268.4798584, 15.0012999, 0.000e-00,\n 0.5327320, 0.0000685, -1.260e-05,\n -0.0133390, 0.0000682, -1.250e-05,\n 0.0046041, 0.0045811,\n// 1805 12 21\n2380676.512242, 0.0, -4.0, 4.0, 12.2, 12.2,\n -0.0689400, 0.5033308, -1.860e-05, -5.650e-06,\n -0.8849180, 0.0454730, 1.923e-04, -6.200e-07,\n -23.4567509, -0.0005110, 6.000e-06,\n 180.4690857, 14.9961357, 0.000e-00,\n 0.5744300, 0.0000469, -1.000e-05,\n 0.0281510, 0.0000467, -9.900e-06,\n 0.0047554, 0.0047317,\n// 1806 6 16\n2380854.183643, 16.0, -4.0, 4.0, 12.2, 12.2,\n -0.2143080, 0.5723435, 1.260e-05, -9.220e-06,\n 0.3335400, -0.0336367, -1.833e-04, 6.500e-07,\n 23.3583298, 0.0016640, -6.000e-06,\n 59.9729805, 14.9992676, 0.000e-00,\n 0.5348860, -0.0000731, -1.230e-05,\n -0.0111950, -0.0000727, -1.230e-05,\n 0.0046006, 0.0045777,\n// 1806 12 10\n2381030.596986, 2.0, -4.0, 4.0, 12.1, 12.1,\n -0.1723940, 0.5289593, -1.170e-05, -6.780e-06,\n -0.1636570, 0.0028846, 1.683e-04, -1.400e-07,\n -22.8654404, -0.0040020, 6.000e-06,\n 211.8148956, 14.9966936, 0.000e-00,\n 0.5624760, 0.0001231, -1.090e-05,\n 0.0162570, 0.0001225, -1.080e-05,\n 0.0047503, 0.0047267,\n// 1807 6 6\n2381208.721194, 5.0, -4.0, 4.0, 12.1, 12.1,\n -0.1595670, 0.5418690, 2.650e-05, -7.400e-06,\n -0.4604440, 0.0091802, -1.269e-04, -3.000e-08,\n 22.5641804, 0.0045660, -5.000e-06,\n 255.4950409, 14.9996014, 0.000e-00,\n 0.5487700, -0.0001140, -1.110e-05,\n 0.0026200, -0.0001135, -1.100e-05,\n 0.0046059, 0.0045830,\n// 1807 11 29\n2381384.987603, 12.0, -4.0, 4.0, 12.1, 12.1,\n 0.2062090, 0.5613169, -1.430e-05, -8.600e-06,\n 0.5240500, -0.0409630, 1.296e-04, 5.400e-07,\n -21.3997993, -0.0071320, 6.000e-06,\n 2.9140601, 14.9978380, 0.000e-00,\n 0.5464990, 0.0000994, -1.220e-05,\n 0.0003590, 0.0000989, -1.220e-05,\n 0.0047426, 0.0047190,\n// 1808 5 25\n2381562.960131, 11.0, -4.0, 4.0, 12.2, 12.2,\n 0.0931370, 0.5105016, 1.840e-05, -5.950e-06,\n -1.2632900, 0.0466205, -7.640e-05, -4.600e-07,\n 20.9689102, 0.0073630, -5.000e-06,\n 345.8636169, 15.0003204, 0.000e-00,\n 0.5627570, -0.0000724, -1.000e-05,\n 0.0165370, -0.0000721, -9.900e-06,\n 0.0046137, 0.0045907,\n// 1808 10 19\n2381710.205208, 17.0, -4.0, 4.0, 12.2, 12.2,\n -0.3523310, 0.5598183, 4.350e-05, -9.460e-06,\n -1.4013910, -0.1588496, 1.435e-04, 2.620e-06,\n -10.1007996, -0.0146720, 2.000e-06,\n 78.7442932, 15.0031910, 0.000e-00,\n 0.5360970, -0.0000339, -1.300e-05,\n -0.0099910, -0.0000337, -1.290e-05,\n 0.0046987, 0.0046753,\n// 1808 11 18\n2381739.604206, 3.0, -4.0, 4.0, 12.2, 12.2,\n 0.4579900, 0.5763395, -7.700e-06, -9.780e-06,\n 1.1334471, -0.0834845, 7.300e-05, 1.330e-06,\n -19.1936398, -0.0098060, 5.000e-06,\n 228.6669617, 14.9992781, 0.000e-00,\n 0.5374480, 0.0000081, -1.310e-05,\n -0.0086460, 0.0000080, -1.300e-05,\n 0.0047330, 0.0047094,\n// 1809 4 14\n2381887.338325, 20.0, -4.0, 4.0, 12.2, 12.2,\n -0.2986950, 0.4937996, 1.720e-05, -5.790e-06,\n 0.8238570, 0.1407165, -9.070e-05, -1.580e-06,\n 9.4773703, 0.0146320, -2.000e-06,\n 119.9422607, 15.0038624, 0.000e-00,\n 0.5649890, 0.0000744, -1.010e-05,\n 0.0187570, 0.0000740, -1.000e-05,\n 0.0046577, 0.0046345,\n// 1809 10 9\n2382064.818538, 8.0, -4.0, 4.0, 12.2, 12.2,\n -0.0417790, 0.5345544, 2.950e-05, -8.020e-06,\n -0.8139320, -0.1637422, 7.200e-05, 2.400e-06,\n -6.1473298, -0.0155050, 1.000e-06,\n 303.1470337, 15.0041075, 0.000e-00,\n 0.5452320, -0.0001164, -1.190e-05,\n -0.0009010, -0.0001158, -1.190e-05,\n 0.0046851, 0.0046617,\n// 1810 4 4\n2382241.570360, 2.0, -4.0, 4.0, 12.2, 12.2,\n 0.1311400, 0.5189954, -1.160e-05, -7.150e-06,\n 0.1484590, 0.1603805, -4.470e-05, -2.130e-06,\n 5.3903399, 0.0155420, -1.000e-06,\n 209.1757812, 15.0043888, 0.000e-00,\n 0.5517240, 0.0001101, -1.120e-05,\n 0.0055590, 0.0001096, -1.120e-05,\n 0.0046717, 0.0046484,\n// 1810 9 28\n2382419.192652, 17.0, -4.0, 4.0, 12.3, 12.3,\n 0.1673760, 0.5008574, 1.130e-05, -6.280e-06,\n -0.1263510, -0.1593870, 9.700e-06, 1.930e-06,\n -1.9429300, -0.0158770, 0.000e-00,\n 77.3247604, 15.0046492, 0.000e-00,\n 0.5598120, -0.0001114, -1.060e-05,\n 0.0136060, -0.0001109, -1.050e-05,\n 0.0046709, 0.0046477,\n// 1811 3 24\n2382596.091821, 14.0, -4.0, 4.0, 12.3, 12.3,\n 0.0777140, 0.5464874, -1.300e-05, -8.860e-06,\n -0.6250940, 0.1752594, 2.230e-05, -2.770e-06,\n 1.2141000, 0.0159770, -1.000e-06,\n 28.3484802, 15.0045366, 0.000e-00,\n 0.5388320, 0.0000805, -1.260e-05,\n -0.0072690, 0.0000801, -1.250e-05,\n 0.0046857, 0.0046624,\n// 1811 9 17\n2382773.280387, 19.0, -4.0, 4.0, 12.3, 12.3,\n 0.3362120, 0.4818311, -1.370e-05, -5.410e-06,\n 0.6064560, -0.1530579, -3.830e-05, 1.650e-06,\n 2.4037299, -0.0157630, -1.000e-06,\n 106.3625107, 15.0048170, 0.000e-00,\n 0.5687820, -0.0000271, -9.800e-06,\n 0.0225310, -0.0000270, -9.700e-06,\n 0.0046564, 0.0046332,\n// 1812 2 12\n2382921.353244, 20.0, -4.0, 4.0, 12.3, 12.3,\n -0.5861740, 0.5590120, 1.900e-05, -9.130e-06,\n 1.2516440, 0.1354636, 2.560e-05, -2.150e-06,\n -13.8569298, 0.0134600, 3.000e-06,\n 116.3504562, 15.0015097, 0.000e-00,\n 0.5405710, -0.0000606, -1.280e-05,\n -0.0055390, -0.0000603, -1.270e-05,\n 0.0047338, 0.0047103,\n// 1812 3 13\n2382950.763547, 6.0, -4.0, 4.0, 12.3, 12.3,\n 0.2148170, 0.5549987, -1.650e-05, -9.440e-06,\n -1.2873640, 0.1783805, 9.360e-05, -2.940e-06,\n -2.9576399, 0.0159690, 0.000e-00,\n 267.5634460, 15.0042505, 0.000e-00,\n 0.5356770, -0.0000150, -1.300e-05,\n -0.0104080, -0.0000150, -1.290e-05,\n 0.0046997, 0.0046763,\n// 1812 8 7\n2383097.719327, 5.0, -4.0, 4.0, 12.4, 12.4,\n -0.4181730, 0.5159149, -1.760e-05, -6.490e-06,\n -1.3646719, -0.1044987, -3.430e-05, 1.230e-06,\n 16.5126705, -0.0113730, -4.000e-06,\n 253.6378326, 15.0024729, 0.000e-00,\n 0.5561140, 0.0001143, -1.050e-05,\n 0.0099270, 0.0001137, -1.040e-05,\n 0.0046128, 0.0045898,\n// 1812 9 5\n2383127.294565, 19.0, -4.0, 4.0, 12.4, 12.4,\n 0.3720500, 0.4907845, -3.720e-05, -5.730e-06,\n 1.3438230, -0.1494888, -8.680e-05, 1.700e-06,\n 6.6829801, -0.0151540, -1.000e-06,\n 105.3970108, 15.0046196, 0.000e-00,\n 0.5643050, 0.0000790, -1.000e-05,\n 0.0180770, 0.0000786, -1.000e-05,\n 0.0046423, 0.0046192,\n// 1813 2 1\n2383275.873920, 9.0, -4.0, 4.0, 12.4, 12.4,\n -0.1172090, 0.5358966, 2.500e-06, -7.480e-06,\n 0.7056320, 0.0999346, 8.460e-05, -1.330e-06,\n -17.1563892, 0.0115820, 4.000e-06,\n 311.5108643, 14.9999819, 0.000e-00,\n 0.5544690, -0.0001240, -1.150e-05,\n 0.0082900, -0.0001233, -1.140e-05,\n 0.0047436, 0.0047199,\n// 1813 7 27\n2383452.121930, 15.0, -4.0, 4.0, 12.4, 12.4,\n -0.0434840, 0.5542921, -3.120e-05, -8.330e-06,\n -0.6004520, -0.0786121, -9.170e-05, 1.090e-06,\n 19.2538109, -0.0092290, -4.000e-06,\n 43.4783401, 15.0014601, 0.000e-00,\n 0.5407650, 0.0001097, -1.180e-05,\n -0.0053460, 0.0001091, -1.170e-05,\n 0.0046052, 0.0045823,\n// 1814 1 21\n2383630.100540, 14.0, -4.0, 4.0, 12.4, 12.4,\n -0.2136300, 0.5100157, 4.600e-06, -6.000e-06,\n -0.0000800, 0.0609776, 1.322e-04, -6.400e-07,\n -19.9577808, 0.0090920, 5.000e-06,\n 27.0887699, 14.9983950, 0.000e-00,\n 0.5699920, -0.0000768, -1.030e-05,\n 0.0237350, -0.0000764, -1.020e-05,\n 0.0047511, 0.0047274,\n// 1814 7 17\n2383806.771172, 7.0, -4.0, 4.0, 12.4, 12.4,\n 0.2981830, 0.5809073, -3.170e-05, -9.830e-06,\n 0.1418300, -0.0443476, -1.571e-04, 6.500e-07,\n 21.3305607, -0.0068040, -5.000e-06,\n 283.5931702, 15.0005121, 0.000e-00,\n 0.5309740, 0.0000233, -1.270e-05,\n -0.0150880, 0.0000232, -1.270e-05,\n 0.0046003, 0.0045774,\n// 1815 1 10\n2383984.081324, 14.0, -4.0, 4.0, 12.4, 12.4,\n 0.0531330, 0.5029050, -1.060e-05, -5.590e-06,\n -0.6609040, 0.0219611, 1.706e-04, -1.600e-07,\n -22.0364304, 0.0060450, 6.000e-06,\n 28.0678196, 14.9970751, 0.000e-00,\n 0.5754240, 0.0000141, -9.900e-06,\n 0.0291400, 0.0000140, -9.800e-06,\n 0.0047554, 0.0047317,\n// 1815 7 6\n2384161.488280, 0.0, -4.0, 4.0, 12.3, 12.3,\n 0.1695520, 0.5782805, -4.000e-07, -9.570e-06,\n 0.9048930, -0.0045180, -2.130e-04, -5.000e-08,\n 22.7299595, -0.0041210, -5.000e-06,\n 178.9429626, 14.9997215, 0.000e-00,\n 0.5326730, -0.0000717, -1.250e-05,\n -0.0133970, -0.0000713, -1.250e-05,\n 0.0045981, 0.0045752,\n// 1815 12 30\n2384338.110173, 15.0, -4.0, 4.0, 12.3, 12.3,\n 0.1368420, 0.5213545, -1.450e-05, -6.410e-06,\n -1.3188940, -0.0191893, 2.162e-04, 3.100e-07,\n -23.2105694, 0.0026480, 6.000e-06,\n 44.3324890, 14.9963293, 0.000e-00,\n 0.5664560, 0.0000962, -1.060e-05,\n 0.0202170, 0.0000957, -1.050e-05,\n 0.0047563, 0.0047326,\n// 1816 5 27\n2384486.634303, 3.0, -4.0, 4.0, 12.3, 12.3,\n 0.1440750, 0.5121213, 4.710e-05, -6.600e-06,\n -0.9457240, 0.1449430, -8.730e-05, -2.000e-06,\n 21.2692108, 0.0066960, -5.000e-06,\n 225.8190765, 15.0001774, 0.000e-00,\n 0.5534550, -0.0001115, -1.070e-05,\n 0.0072810, -0.0001109, -1.060e-05,\n 0.0046122, 0.0045892,\n// 1816 11 19\n2384662.928734, 10.0, -4.0, 4.0, 12.2, 12.2,\n 0.1153390, 0.5402968, 2.490e-05, -8.580e-06,\n 0.8490800, -0.1846492, 8.930e-05, 3.130e-06,\n -19.5126400, -0.0092330, 5.000e-06,\n 333.5927124, 14.9989939, 0.000e-00,\n 0.5424270, 0.0000958, -1.260e-05,\n -0.0036930, 0.0000953, -1.250e-05,\n 0.0047345, 0.0047109,\n// 1817 5 16\n2384840.790441, 7.0, -4.0, 4.0, 12.2, 12.2,\n 0.0832680, 0.4782221, 4.270e-05, -5.380e-06,\n -0.1878280, 0.1715646, -9.960e-05, -2.080e-06,\n 19.0361500, 0.0092820, -4.000e-06,\n 285.9892273, 15.0010996, 0.000e-00,\n 0.5656230, -0.0000491, -9.800e-06,\n 0.0193880, -0.0000489, -9.800e-06,\n 0.0046219, 0.0045989,\n// 1817 11 9\n2385017.579082, 2.0, -4.0, 4.0, 12.1, 12.1,\n 0.1115770, 0.5392761, 4.040e-05, -9.100e-06,\n 0.1149230, -0.2217027, 1.029e-04, 3.940e-06,\n -16.7456493, -0.0114890, 4.000e-06,\n 214.0065155, 15.0005131, 0.000e-00,\n 0.5368380, -0.0000113, -1.310e-05,\n -0.0092540, -0.0000112, -1.300e-05,\n 0.0047234, 0.0046999,\n// 1818 5 5\n2385194.802655, 7.0, -4.0, 4.0, 12.0, 12.0,\n -0.3365330, 0.4689728, 4.290e-05, -5.310e-06,\n 0.4480390, 0.1994576, -1.088e-04, -2.410e-06,\n 16.1006298, 0.0115100, -4.000e-06,\n 285.8676453, 15.0021782, 0.000e-00,\n 0.5655400, 0.0000581, -9.900e-06,\n 0.0193050, 0.0000579, -9.800e-06,\n 0.0046333, 0.0046103,\n// 1818 10 29\n2385372.213305, 17.0, -4.0, 4.0, 11.9, 11.9,\n -0.2949910, 0.5127599, 6.700e-05, -7.880e-06,\n -0.4719130, -0.2395608, 1.019e-04, 3.890e-06,\n -13.4342098, -0.0132780, 3.000e-06,\n 79.0324783, 15.0019255, 0.000e-00,\n 0.5436050, -0.0000942, -1.230e-05,\n -0.0025200, -0.0000938, -1.220e-05,\n 0.0047111, 0.0046876,\n// 1819 3 25\n2385519.489231, 0.0, -4.0, 4.0, 11.8, 11.8,\n 0.8340650, 0.4845751, -5.110e-05, -6.920e-06,\n -1.2215610, 0.2662227, 4.490e-05, -4.020e-06,\n 1.7990100, 0.0157250, -1.000e-06,\n 178.4597931, 15.0043964, 0.000e-00,\n 0.5479010, 0.0001082, -1.170e-05,\n 0.0017550, 0.0001076, -1.160e-05,\n 0.0046844, 0.0046610,\n// 1819 4 24\n2385548.980542, 12.0, -4.0, 4.0, 11.8, 11.8,\n -0.3157920, 0.4837316, 3.360e-05, -6.330e-06,\n 1.2430060, 0.2306703, -1.322e-04, -3.160e-06,\n 12.6759996, 0.0132510, -3.000e-06,\n 0.4600200, 15.0031910, 0.000e-00,\n 0.5537420, 0.0001042, -1.090e-05,\n 0.0075670, 0.0001037, -1.080e-05,\n 0.0046458, 0.0046227,\n// 1819 9 19\n2385697.044292, 13.0, -4.0, 4.0, 11.7, 11.7,\n 0.7104050, 0.4529691, -2.300e-05, -5.350e-06,\n 1.3507650, -0.2507225, -7.010e-05, 3.110e-06,\n 1.6982100, -0.0155840, 0.000e-00,\n 16.5198097, 15.0047474, 0.000e-00,\n 0.5628660, -0.0000854, -1.020e-05,\n 0.0166450, -0.0000850, -1.020e-05,\n 0.0046583, 0.0046351,\n// 1819 10 19\n2385726.643945, 3.0, -4.0, 4.0, 11.7, 11.7,\n -0.8157130, 0.4747475, 7.810e-05, -6.080e-06,\n -1.0689310, -0.2416982, 9.540e-05, 3.300e-06,\n -9.6487198, -0.0145960, 2.000e-06,\n 228.6870880, 15.0031223, 0.000e-00,\n 0.5579500, -0.0001029, -1.090e-05,\n 0.0117540, -0.0001024, -1.080e-05,\n 0.0046976, 0.0046742,\n// 1820 3 14\n2385874.067538, 14.0, -4.0, 4.0, 11.6, 11.6,\n 0.5405650, 0.5070069, -4.390e-05, -8.340e-06,\n -0.5237780, 0.2803686, 4.100e-05, -4.830e-06,\n -2.4088900, 0.0157540, 0.000e-00,\n 27.6611996, 15.0041924, 0.000e-00,\n 0.5371710, 0.0000411, -1.280e-05,\n -0.0089220, 0.0000409, -1.280e-05,\n 0.0046983, 0.0046749,\n// 1820 9 7\n2386051.083308, 14.0, -4.0, 4.0, 11.4, 11.4,\n 0.3931030, 0.4439874, -3.250e-05, -4.870e-06,\n 0.7254080, -0.2403887, -5.760e-05, 2.800e-06,\n 5.9897499, -0.0150730, -1.000e-06,\n 30.5482292, 15.0045748, 0.000e-00,\n 0.5684730, 0.0000073, -9.700e-06,\n 0.0222240, 0.0000072, -9.700e-06,\n 0.0046445, 0.0046214,\n// 1821 3 4\n2386228.743204, 6.0, -4.0, 4.0, 11.3, 11.3,\n 0.0967330, 0.5107297, -1.820e-05, -8.440e-06,\n 0.0197710, 0.2745044, 4.010e-05, -4.750e-06,\n -6.5385499, 0.0153490, 1.000e-06,\n 266.9833374, 15.0035601, 0.000e-00,\n 0.5376350, -0.0000562, -1.290e-05,\n -0.0084610, -0.0000559, -1.280e-05,\n 0.0047116, 0.0046882,\n// 1821 8 27\n2386405.138680, 15.0, -4.0, 4.0, 11.1, 11.1,\n -0.1215650, 0.4631887, -3.590e-05, -5.540e-06,\n 0.1373730, -0.2362899, -5.260e-05, 3.000e-06,\n 10.0721998, -0.0140690, -2.000e-06,\n 44.6725807, 15.0040779, 0.000e-00,\n 0.5603670, 0.0001045, -1.030e-05,\n 0.0141590, 0.0001040, -1.020e-05,\n 0.0046314, 0.0046083,\n// 1822 2 21\n2386583.319911, 20.0, -4.0, 4.0, 10.9, 10.9,\n -0.1513020, 0.4946110, -5.100e-06, -7.130e-06,\n 0.6978130, 0.2487663, 3.260e-05, -3.790e-06,\n -10.5302896, 0.0144780, 2.000e-06,\n 116.5192795, 15.0025110, 0.000e-00,\n 0.5496120, -0.0001273, -1.180e-05,\n 0.0034570, -0.0001267, -1.170e-05,\n 0.0047244, 0.0047009,\n// 1822 8 16\n2386759.468450, 23.0, -4.0, 4.0, 10.8, 10.8,\n -0.4121130, 0.5011347, -3.320e-05, -7.170e-06,\n -0.5699530, -0.2323392, -4.410e-05, 3.490e-06,\n 13.7242298, -0.0126440, -3.000e-06,\n 163.9997253, 15.0033283, 0.000e-00,\n 0.5447800, 0.0001249, -1.150e-05,\n -0.0013510, 0.0001243, -1.150e-05,\n 0.0046200, 0.0045970,\n// 1823 1 12\n2386907.889030, 9.0, -4.0, 4.0, 10.6, 10.6,\n 0.2230090, 0.4917369, -3.740e-05, -5.580e-06,\n -1.5346570, 0.1279671, 2.023e-04, -1.570e-06,\n -21.7512207, 0.0063340, 6.000e-06,\n 312.8882751, 14.9972305, 0.000e-00,\n 0.5730670, -0.0000532, -1.000e-05,\n 0.0267950, -0.0000529, -1.000e-05,\n 0.0047548, 0.0047311,\n// 1823 2 11\n2386937.627108, 3.0, -4.0, 4.0, 10.6, 10.6,\n -0.6222530, 0.4738824, 4.300e-06, -5.680e-06,\n 1.3150320, 0.2138333, 3.040e-05, -2.750e-06,\n -14.3093700, 0.0130480, 3.000e-06,\n 221.3549652, 15.0011158, 0.000e-00,\n 0.5659010, -0.0001014, -1.050e-05,\n 0.0196650, -0.0001009, -1.040e-05,\n 0.0047362, 0.0047126,\n// 1823 7 8\n2387084.789208, 7.0, -4.0, 4.0, 10.4, 10.4,\n 0.2663940, 0.5718407, -4.980e-05, -9.740e-06,\n 1.0865860, -0.1216642, -2.208e-04, 2.220e-06,\n 22.5879097, -0.0042170, -5.000e-06,\n 283.8804016, 14.9997873, 0.000e-00,\n 0.5300810, 0.0000055, -1.280e-05,\n -0.0159770, 0.0000055, -1.270e-05,\n 0.0045983, 0.0045754,\n// 1823 8 6\n2387114.073398, 14.0, -4.0, 4.0, 10.4, 10.4,\n -0.3919000, 0.5369847, -2.750e-05, -8.860e-06,\n -1.3377250, -0.2171335, -2.770e-05, 3.750e-06,\n 16.8656693, -0.0108670, -4.000e-06,\n 28.5942802, 15.0023966, 0.000e-00,\n 0.5326920, 0.0000514, -1.260e-05,\n -0.0133790, 0.0000511, -1.260e-05,\n 0.0046109, 0.0045879,\n// 1824 1 1\n2387261.848020, 8.0, -4.0, 4.0, 10.2, 10.2,\n -0.0226020, 0.4983251, -3.390e-05, -5.600e-06,\n -0.8996410, 0.0876530, 1.878e-04, -1.110e-06,\n -23.0883598, 0.0029560, 6.000e-06,\n 299.1255493, 14.9963503, 0.000e-00,\n 0.5741910, 0.0000524, -1.000e-05,\n 0.0279140, 0.0000521, -9.900e-06,\n 0.0047566, 0.0047329,\n// 1824 6 26\n2387439.490659, 0.0, -4.0, 4.0, 10.0, 10.0,\n 0.1814300, 0.5664260, -1.910e-05, -9.050e-06,\n 0.3745800, -0.0787127, -1.846e-04, 1.380e-06,\n 23.3588104, -0.0013770, -5.000e-06,\n 179.3756409, 14.9992962, 0.000e-00,\n 0.5353480, -0.0000927, -1.230e-05,\n -0.0107350, -0.0000922, -1.220e-05,\n 0.0045983, 0.0045754,\n// 1824 12 20\n2387615.944856, 11.0, -4.0, 4.0, 9.8, 9.8,\n 0.1859490, 0.5284474, -3.970e-05, -6.810e-06,\n -0.1525450, 0.0473851, 1.718e-04, -7.400e-07,\n -23.4540596, -0.0005670, 6.000e-06,\n 345.5025024, 14.9962111, 0.000e-00,\n 0.5620060, 0.0001100, -1.090e-05,\n 0.0157890, 0.0001095, -1.090e-05,\n 0.0047546, 0.0047309,\n// 1825 6 16\n2387794.013227, 12.0, -4.0, 4.0, 9.6, 9.6,\n -0.1942170, 0.5389308, 1.590e-05, -7.270e-06,\n -0.3701530, -0.0326672, -1.384e-04, 5.500e-07,\n 23.3661003, 0.0015930, -6.000e-06,\n 359.9535217, 14.9991770, 0.000e-00,\n 0.5494490, -0.0001127, -1.100e-05,\n 0.0032950, -0.0001121, -1.090e-05,\n 0.0046012, 0.0045783,\n// 1825 12 9\n2387970.348434, 20.0, -4.0, 4.0, 9.4, 9.4,\n -0.2076300, 0.5642805, -6.900e-06, -8.730e-06,\n 0.5283930, 0.0032223, 1.432e-04, -1.500e-07,\n -22.8778591, -0.0039580, 6.000e-06,\n 121.8056030, 14.9967833, 0.000e-00,\n 0.5461280, 0.0001123, -1.230e-05,\n -0.0000090, 0.0001117, -1.230e-05,\n 0.0047494, 0.0047258,\n// 1826 6 5\n2388148.235470, 18.0, -4.0, 4.0, 9.1, 9.1,\n 0.2002540, 0.5114601, 5.300e-06, -5.930e-06,\n -1.1852070, 0.0093582, -9.300e-05, -2.000e-08,\n 22.5569496, 0.0045810, -5.000e-06,\n 90.4945602, 14.9995241, 0.000e-00,\n 0.5628760, -0.0000743, -9.900e-06,\n 0.0166550, -0.0000739, -9.900e-06,\n 0.0046067, 0.0045838,\n// 1826 10 31\n2388295.556001, 1.0, -4.0, 4.0, 8.9, 8.9,\n -0.5410710, 0.5648154, 5.770e-05, -9.520e-06,\n -1.3808880, -0.1372697, 1.704e-04, 2.250e-06,\n -13.8923502, -0.0133120, 3.000e-06,\n 199.0481110, 15.0018711, 0.000e-00,\n 0.5370930, -0.0000287, -1.300e-05,\n -0.0089990, -0.0000286, -1.290e-05,\n 0.0047124, 0.0046889,\n// 1826 11 29\n2388324.968150, 11.0, -4.0, 4.0, 8.9, 8.9,\n -0.0508120, 0.5809398, 1.140e-05, -9.880e-06,\n 1.1833030, -0.0426569, 9.240e-05, 6.300e-07,\n -21.4595509, -0.0070270, 6.000e-06,\n 347.8871460, 14.9978542, 0.000e-00,\n 0.5378180, 0.0000214, -1.310e-05,\n -0.0082780, 0.0000213, -1.310e-05,\n 0.0047422, 0.0047186,\n// 1827 4 26\n2388472.632806, 3.0, -4.0, 4.0, 8.7, 8.7,\n -0.3176130, 0.4999134, 2.080e-05, -5.910e-06,\n 0.8810770, 0.1238572, -1.162e-04, -1.390e-06,\n 13.2290297, 0.0132560, -3.000e-06,\n 225.5388184, 15.0030899, 0.000e-00,\n 0.5635080, 0.0000806, -1.010e-05,\n 0.0172840, 0.0000802, -1.000e-05,\n 0.0046444, 0.0046212,\n// 1827 10 20\n2388650.154225, 16.0, -4.0, 4.0, 8.5, 8.5,\n -0.0613020, 0.5366996, 3.720e-05, -7.980e-06,\n -0.8395080, -0.1495393, 9.960e-05, 2.160e-06,\n -10.2293901, -0.0146540, 2.000e-06,\n 63.7604904, 15.0031013, 0.000e-00,\n 0.5468360, -0.0001175, -1.190e-05,\n 0.0006950, -0.0001169, -1.180e-05,\n 0.0046993, 0.0046759,\n// 1828 4 14\n2388826.888633, 9.0, -4.0, 4.0, 8.2, 8.2,\n -0.2126450, 0.5245852, 9.000e-06, -7.320e-06,\n 0.0952670, 0.1492903, -6.720e-05, -2.000e-06,\n 9.4568796, 0.0146190, -2.000e-06,\n 314.9369202, 15.0039330, 0.000e-00,\n 0.5499210, 0.0001244, -1.130e-05,\n 0.0037650, 0.0001238, -1.130e-05,\n 0.0046576, 0.0046344,\n// 1828 10 9\n2389004.505400, 0.0, -4.0, 4.0, 8.0, 8.0,\n -0.0981050, 0.5009548, 2.830e-05, -6.210e-06,\n -0.0892040, -0.1525627, 3.300e-05, 1.830e-06,\n -6.1716700, -0.0155240, 1.000e-06,\n 183.1540070, 15.0040283, 0.000e-00,\n 0.5615630, -0.0000981, -1.050e-05,\n 0.0153480, -0.0000976, -1.050e-05,\n 0.0046854, 0.0046621,\n// 1829 4 3\n2389181.429582, 22.0, -4.0, 4.0, 7.8, 7.8,\n 0.0011910, 0.5495575, -5.000e-07, -8.980e-06,\n -0.6070480, 0.1700675, -4.400e-06, -2.700e-06,\n 5.4822998, 0.0155040, -1.000e-06,\n 149.1866150, 15.0044508, 0.000e-00,\n 0.5375020, 0.0000785, -1.260e-05,\n -0.0085930, 0.0000781, -1.250e-05,\n 0.0046711, 0.0046479,\n// 1829 9 28\n2389358.574222, 2.0, -4.0, 4.0, 7.6, 7.6,\n 0.2945400, 0.4811242, -5.800e-06, -5.380e-06,\n 0.5614610, -0.1531163, -1.340e-05, 1.650e-06,\n -1.8550700, -0.0158900, 0.000e-00,\n 212.3073730, 15.0046167, 0.000e-00,\n 0.5698830, -0.0000200, -9.800e-06,\n 0.0236270, -0.0000199, -9.700e-06,\n 0.0046706, 0.0046474,\n// 1830 2 23\n2389506.711262, 5.0, -4.0, 4.0, 7.4, 7.4,\n -0.4129480, 0.5524750, 1.540e-05, -8.980e-06,\n 1.3086150, 0.1566313, -4.300e-06, -2.490e-06,\n -10.0060701, 0.0148570, 2.000e-06,\n 251.5627441, 15.0028048, 0.000e-00,\n 0.5404250, -0.0000758, -1.270e-05,\n -0.0056840, -0.0000754, -1.260e-05,\n 0.0047227, 0.0046992,\n// 1830 3 24\n2389536.110225, 15.0, -4.0, 4.0, 7.4, 7.4,\n 0.5856600, 0.5542642, -2.580e-05, -9.410e-06,\n -1.1370710, 0.1796608, 5.920e-05, -2.960e-06,\n 1.3893200, 0.0159570, -1.000e-06,\n 43.3804512, 15.0045538, 0.000e-00,\n 0.5350580, -0.0000384, -1.300e-05,\n -0.0110240, -0.0000382, -1.290e-05,\n 0.0046853, 0.0046620,\n// 1830 8 18\n2389683.009438, 12.0, -4.0, 4.0, 7.2, 7.2,\n -0.4790110, 0.5121905, -1.420e-05, -6.510e-06,\n -1.4123740, -0.1289648, -8.800e-06, 1.550e-06,\n 13.2112703, -0.0131250, -3.000e-06,\n 359.0813293, 15.0034962, 0.000e-00,\n 0.5557780, 0.0001169, -1.060e-05,\n 0.0095920, 0.0001163, -1.050e-05,\n 0.0046218, 0.0045987,\n// 1830 9 17\n2389712.589033, 2.0, -4.0, 4.0, 7.2, 7.2,\n 0.3384580, 0.4896579, -3.000e-05, -5.750e-06,\n 1.2906690, -0.1563901, -6.170e-05, 1.790e-06,\n 2.5201399, -0.0157410, -1.000e-06,\n 211.3305664, 15.0048409, 0.000e-00,\n 0.5645160, 0.0000855, -1.010e-05,\n 0.0182860, 0.0000851, -1.000e-05,\n 0.0046555, 0.0046323,\n// 1831 2 12\n2389861.223432, 17.0, -4.0, 4.0, 7.0, 7.0,\n -0.3616180, 0.5284468, 1.290e-05, -7.300e-06,\n 0.6627410, 0.1268126, 6.100e-05, -1.690e-06,\n -13.7659197, 0.0135230, 3.000e-06,\n 71.3583069, 15.0014629, 0.000e-00,\n 0.5548250, -0.0001158, -1.140e-05,\n 0.0086440, -0.0001152, -1.130e-05,\n 0.0047345, 0.0047109,\n// 1831 8 7\n2390037.427769, 22.0, -4.0, 4.0, 6.8, 6.8,\n -0.2784650, 0.5507208, -2.270e-05, -8.370e-06,\n -0.6265450, -0.1105422, -6.750e-05, 1.590e-06,\n 16.4761295, -0.0113780, -4.000e-06,\n 148.6290588, 15.0025740, 0.000e-00,\n 0.5402720, 0.0001157, -1.190e-05,\n -0.0058360, 0.0001151, -1.180e-05,\n 0.0046120, 0.0045890,\n// 1832 2 1\n2390215.437666, 23.0, -4.0, 4.0, 6.6, 6.6,\n 0.2435750, 0.5040444, -1.640e-05, -5.900e-06,\n 0.0810630, 0.0931847, 1.075e-04, -1.020e-06,\n -17.1616707, 0.0115930, 4.000e-06,\n 161.5239563, 14.9998903, 0.000e-00,\n 0.5700990, -0.0000919, -1.020e-05,\n 0.0238420, -0.0000915, -1.020e-05,\n 0.0047446, 0.0047209,\n// 1832 7 27\n2390392.084098, 14.0, -4.0, 4.0, 6.4, 6.4,\n 0.0024140, 0.5772567, -2.320e-05, -9.800e-06,\n 0.0924970, -0.0825572, -1.349e-04, 1.310e-06,\n 19.1655998, -0.0093000, -4.000e-06,\n 28.4628792, 15.0015621, 0.000e-00,\n 0.5309540, 0.0000305, -1.280e-05,\n -0.0151080, 0.0000304, -1.270e-05,\n 0.0046047, 0.0045817,\n// 1833 1 20\n2390569.414530, 22.0, -4.0, 4.0, 6.3, 6.3,\n 0.1021810, 0.5002168, -2.190e-05, -5.570e-06,\n -0.6454570, 0.0590487, 1.525e-04, -5.900e-07,\n -20.0162601, 0.0090240, 5.000e-06,\n 147.1217651, 14.9983301, 0.000e-00,\n 0.5750490, 0.0000186, -9.900e-06,\n 0.0287670, 0.0000185, -9.800e-06,\n 0.0047516, 0.0047279,\n// 1833 7 17\n2390746.797251, 7.0, -4.0, 4.0, 6.1, 6.1,\n -0.0099560, 0.5751518, -1.900e-06, -9.450e-06,\n 0.8383160, -0.0463432, -1.959e-04, 6.500e-07,\n 21.2582703, -0.0069010, -5.000e-06,\n 283.5708008, 15.0005379, 0.000e-00,\n 0.5333340, -0.0000661, -1.250e-05,\n -0.0127400, -0.0000658, -1.240e-05,\n 0.0046003, 0.0045774,\n// 1834 1 9\n2390923.455216, 23.0, -4.0, 4.0, 6.0, 6.0,\n 0.0967270, 0.5227157, -2.650e-05, -6.480e-06,\n -1.3012660, 0.0231438, 2.048e-04, -2.300e-07,\n -22.0673504, 0.0059700, 6.000e-06,\n 163.1033936, 14.9971037, 0.000e-00,\n 0.5656190, 0.0001041, -1.060e-05,\n 0.0193840, 0.0001036, -1.060e-05,\n 0.0047550, 0.0047314,\n// 1834 6 7\n2391071.922667, 10.0, -4.0, 4.0, 5.9, 5.9,\n 0.1318860, 0.5194983, 4.010e-05, -6.650e-06,\n -1.0234710, 0.1065415, -9.880e-05, -1.480e-06,\n 22.7377701, 0.0038750, -6.000e-06,\n 330.4114685, 14.9994450, 0.000e-00,\n 0.5539660, -0.0001105, -1.060e-05,\n 0.0077900, -0.0001099, -1.060e-05,\n 0.0046057, 0.0045827,\n// 1834 11 30\n2391248.289292, 19.0, -4.0, 4.0, 5.8, 5.8,\n 0.2477920, 0.5532928, 1.490e-05, -8.860e-06,\n 0.8134790, -0.1455919, 1.122e-04, 2.510e-06,\n -21.6896191, -0.0063800, 6.000e-06,\n 107.7690506, 14.9976254, 0.000e-00,\n 0.5423810, 0.0000827, -1.260e-05,\n -0.0037380, 0.0000823, -1.260e-05,\n 0.0047433, 0.0047196,\n// 1835 5 27\n2391426.066458, 14.0, -4.0, 4.0, 5.6, 5.6,\n 0.2758480, 0.4879301, 3.240e-05, -5.490e-06,\n -0.2171290, 0.1394212, -1.165e-04, -1.700e-06,\n 21.2423801, 0.0067450, -5.000e-06,\n 30.8169003, 15.0001173, 0.000e-00,\n 0.5654140, -0.0000499, -9.800e-06,\n 0.0191810, -0.0000497, -9.700e-06,\n 0.0046133, 0.0045903,\n// 1835 11 20\n2391602.938864, 11.0, -4.0, 4.0, 5.5, 5.5,\n 0.3109580, 0.5516188, 3.230e-05, -9.320e-06,\n 0.0682610, -0.1879111, 1.312e-04, 3.360e-06,\n -19.6087303, -0.0091150, 5.000e-06,\n 348.5763550, 14.9989738, 0.000e-00,\n 0.5374870, -0.0000268, -1.310e-05,\n -0.0086070, -0.0000266, -1.300e-05,\n 0.0047341, 0.0047105,\n// 1836 5 15\n2391780.084476, 14.0, -4.0, 4.0, 5.5, 5.5,\n -0.1724970, 0.4805633, 3.770e-05, -5.490e-06,\n 0.4373850, 0.1731702, -1.286e-04, -2.120e-06,\n 18.9617290, 0.0093470, -4.000e-06,\n 30.9846001, 15.0011272, 0.000e-00,\n 0.5643880, 0.0000594, -9.900e-06,\n 0.0181590, 0.0000591, -9.900e-06,\n 0.0046226, 0.0045996,\n// 1836 11 9\n2391957.562101, 1.0, -4.0, 4.0, 5.4, 5.4,\n -0.4574610, 0.5223757, 8.070e-05, -7.970e-06,\n -0.3886490, -0.2133057, 1.241e-04, 3.460e-06,\n -16.8437405, -0.0114360, 4.000e-06,\n 199.0034027, 15.0004282, 0.000e-00,\n 0.5450290, -0.0000887, -1.220e-05,\n -0.0011030, -0.0000882, -1.220e-05,\n 0.0047236, 0.0047001,\n// 1837 4 5\n2392104.816316, 8.0, -4.0, 4.0, 5.4, 5.4,\n 0.9097230, 0.4895794, -4.220e-05, -7.060e-06,\n -1.2239209, 0.2611872, 2.260e-05, -3.990e-06,\n 6.0451002, 0.0151850, -2.000e-06,\n 299.3027344, 15.0042620, 0.000e-00,\n 0.5462280, 0.0001029, -1.170e-05,\n 0.0000900, 0.0001024, -1.170e-05,\n 0.0046697, 0.0046464,\n// 1837 5 4\n2392134.283661, 19.0, -4.0, 4.0, 5.3, 5.3,\n -0.3697050, 0.4956581, 4.080e-05, -6.580e-06,\n 1.1394240, 0.2095987, -1.504e-04, -2.920e-06,\n 16.0692692, 0.0115050, -3.000e-06,\n 105.8611374, 15.0022469, 0.000e-00,\n 0.5520460, 0.0001114, -1.100e-05,\n 0.0058790, 0.0001109, -1.090e-05,\n 0.0046333, 0.0046102,\n// 1837 10 29\n2392311.971804, 11.0, -4.0, 4.0, 5.3, 5.3,\n -0.7011840, 0.4814964, 8.190e-05, -6.120e-06,\n -1.1041950, -0.2233805, 1.212e-04, 3.040e-06,\n -13.4799700, -0.0132920, 3.000e-06,\n 349.0354614, 15.0018339, 0.000e-00,\n 0.5596260, -0.0001045, -1.080e-05,\n 0.0134210, -0.0001040, -1.080e-05,\n 0.0047116, 0.0046881,\n// 1838 3 25\n2392459.411296, 22.0, -4.0, 4.0, 5.3, 5.3,\n 0.4299030, 0.5076729, -2.420e-05, -8.390e-06,\n -0.6220690, 0.2810835, 2.210e-05, -4.870e-06,\n 1.9179900, 0.0156800, -1.000e-06,\n 148.4902954, 15.0044489, 0.000e-00,\n 0.5360300, 0.0000421, -1.290e-05,\n -0.0100570, 0.0000419, -1.280e-05,\n 0.0046837, 0.0046604,\n// 1838 9 18\n2392636.372178, 21.0, -4.0, 4.0, 5.3, 5.3,\n 0.4610310, 0.4410486, -2.470e-05, -4.840e-06,\n 0.7582890, -0.2454070, -3.790e-05, 2.860e-06,\n 1.8019400, -0.0155870, 0.000e-00,\n 136.4918671, 15.0047207, 0.000e-00,\n 0.5692820, 0.0000124, -9.700e-06,\n 0.0230300, 0.0000123, -9.700e-06,\n 0.0046581, 0.0046349,\n// 1839 3 15\n2392814.092845, 14.0, -4.0, 4.0, 5.3, 5.3,\n -0.0885390, 0.5063641, 4.900e-06, -8.330e-06,\n -0.1129120, 0.2810115, 2.220e-05, -4.830e-06,\n -2.2552400, 0.0157580, 0.000e-00,\n 27.6947098, 15.0042038, 0.000e-00,\n 0.5372710, -0.0000514, -1.280e-05,\n -0.0088230, -0.0000511, -1.280e-05,\n 0.0046979, 0.0046745,\n// 1839 9 7\n2392990.432943, 22.0, -4.0, 4.0, 5.3, 5.3,\n -0.1160730, 0.4585671, -2.680e-05, -5.530e-06,\n 0.2134330, -0.2481671, -3.380e-05, 3.170e-06,\n 6.0889502, -0.0150320, -1.000e-06,\n 150.5201569, 15.0046062, 0.000e-00,\n 0.5603360, 0.0001100, -1.030e-05,\n 0.0141280, 0.0001094, -1.030e-05,\n 0.0046436, 0.0046205,\n// 1840 3 4\n2393168.665533, 4.0, -4.0, 4.0, 5.3, 5.3,\n -0.3049700, 0.4863629, 1.290e-05, -6.930e-06,\n 0.5998450, 0.2610993, 1.270e-05, -3.930e-06,\n -6.4184198, 0.0154010, 1.000e-06,\n 237.0015564, 15.0035200, 0.000e-00,\n 0.5497560, -0.0001219, -1.170e-05,\n 0.0036000, -0.0001213, -1.160e-05,\n 0.0047120, 0.0046886,\n// 1840 8 27\n2393344.776068, 7.0, -4.0, 4.0, 5.3, 5.3,\n -0.0973210, 0.4939884, -3.830e-05, -7.120e-06,\n -0.6487690, -0.2514090, -1.730e-05, 3.800e-06,\n 10.0478897, -0.0140370, -2.000e-06,\n 284.6725159, 15.0041628, 0.000e-00,\n 0.5445590, 0.0001097, -1.160e-05,\n -0.0015710, 0.0001092, -1.150e-05,\n 0.0046305, 0.0046074,\n// 1841 1 22\n2393493.225179, 17.0, -4.0, 4.0, 5.4, 5.4,\n 0.3043890, 0.4804606, -4.580e-05, -5.410e-06,\n -1.5351340, 0.1628987, 1.827e-04, -1.970e-06,\n -19.5948296, 0.0092470, 5.000e-06,\n 71.9920273, 14.9985218, 0.000e-00,\n 0.5732130, -0.0000478, -1.000e-05,\n 0.0269400, -0.0000475, -1.000e-05,\n 0.0047507, 0.0047270,\n// 1841 2 21\n2393522.961066, 11.0, -4.0, 4.0, 5.4, 5.4,\n -0.6752550, 0.4638104, 1.390e-05, -5.510e-06,\n 1.2730401, 0.2321570, 8.400e-06, -2.950e-06,\n -10.5216503, 0.0145220, 2.000e-06,\n 341.5186157, 15.0024309, 0.000e-00,\n 0.5659590, -0.0000982, -1.040e-05,\n 0.0197220, -0.0000977, -1.040e-05,\n 0.0047255, 0.0047020,\n// 1841 7 18\n2393670.100862, 14.0, -4.0, 4.0, 5.4, 5.4,\n 0.0945920, 0.5616738, -4.830e-05, -9.550e-06,\n 1.2117550, -0.1623394, -2.118e-04, 2.920e-06,\n 21.0233898, -0.0069660, -5.000e-06,\n 28.5406494, 15.0006266, 0.000e-00,\n 0.5301710, 0.0000119, -1.280e-05,\n -0.0158870, 0.0000118, -1.280e-05,\n 0.0046006, 0.0045777,\n// 1841 8 16\n2393699.389166, 21.0, -4.0, 4.0, 5.4, 5.4,\n -0.7317840, 0.5268152, -4.500e-06, -8.730e-06,\n -1.1153020, -0.2430369, -1.540e-05, 4.200e-06,\n 13.6230898, -0.0126630, -3.000e-06,\n 134.0131378, 15.0034237, 0.000e-00,\n 0.5327330, 0.0000608, -1.270e-05,\n -0.0133370, 0.0000605, -1.260e-05,\n 0.0046195, 0.0045964,\n// 1842 1 11\n2393847.184504, 16.0, -4.0, 4.0, 5.5, 5.5,\n 0.0138050, 0.4903779, -4.560e-05, -5.520e-06,\n -0.9141890, 0.1274735, 1.747e-04, -1.580e-06,\n -21.8002110, 0.0062430, 6.000e-06,\n 57.9246597, 14.9971905, 0.000e-00,\n 0.5737480, 0.0000581, -1.000e-05,\n 0.0274730, 0.0000578, -9.900e-06,\n 0.0047552, 0.0047315,\n// 1842 7 8\n2394024.796147, 7.0, -4.0, 4.0, 5.6, 5.6,\n 0.0409550, 0.5571388, -2.310e-05, -8.810e-06,\n 0.4748700, -0.1216534, -1.809e-04, 2.060e-06,\n 22.5422707, -0.0043270, -5.000e-06,\n 283.8561401, 14.9997787, 0.000e-00,\n 0.5360630, -0.0000883, -1.220e-05,\n -0.0100240, -0.0000879, -1.210e-05,\n 0.0045984, 0.0045755,\n// 1842 12 31\n2394201.294723, 19.0, -4.0, 4.0, 5.6, 5.6,\n -0.0086520, 0.5242829, -4.570e-05, -6.810e-06,\n -0.1768460, 0.0918190, 1.671e-04, -1.330e-06,\n -23.0993309, 0.0028950, 6.000e-06,\n 104.1567612, 14.9964123, 0.000e-00,\n 0.5612450, 0.0001195, -1.100e-05,\n 0.0150320, 0.0001189, -1.090e-05,\n 0.0047561, 0.0047324,\n// 1843 6 27\n2394379.303510, 19.0, -4.0, 4.0, 5.7, 5.7,\n -0.1937330, 0.5326442, 3.500e-06, -7.100e-06,\n -0.2794490, -0.0749018, -1.420e-04, 1.120e-06,\n 23.3498802, -0.0014440, -6.000e-06,\n 104.3486023, 14.9992151, 0.000e-00,\n 0.5502590, -0.0001119, -1.090e-05,\n 0.0041010, -0.0001114, -1.080e-05,\n 0.0045988, 0.0045759,\n// 1843 12 21\n2394555.710716, 5.0, -4.0, 4.0, 5.8, 5.8,\n -0.0789730, 0.5634655, -2.680e-05, -8.770e-06,\n 0.5177170, 0.0505870, 1.478e-04, -9.100e-07,\n -23.4543896, -0.0005310, 6.000e-06,\n 255.4997711, 14.9963074, 0.000e-00,\n 0.5457430, 0.0001012, -1.240e-05,\n -0.0003930, 0.0001007, -1.230e-05,\n 0.0047538, 0.0047301,\n// 1844 6 16\n2394733.509277, 0.0, -4.0, 4.0, 5.9, 5.9,\n -0.1791160, 0.5096350, 6.700e-06, -5.860e-06,\n -1.1005180, -0.0301683, -1.033e-04, 4.500e-07,\n 23.3621807, 0.0016110, -6.000e-06,\n 179.9387665, 14.9991026, 0.000e-00,\n 0.5631480, -0.0000568, -9.900e-06,\n 0.0169260, -0.0000565, -9.800e-06,\n 0.0046019, 0.0045790,\n// 1844 11 10\n2394880.910942, 10.0, -4.0, 4.0, 6.0, 6.0,\n -0.1985000, 0.5704451, 4.090e-05, -9.590e-06,\n -1.4790310, -0.1078102, 2.027e-04, 1.740e-06,\n -17.2464104, -0.0113990, 4.000e-06,\n 333.9724426, 15.0003452, 0.000e-00,\n 0.5380170, -0.0000468, -1.300e-05,\n -0.0080800, -0.0000466, -1.290e-05,\n 0.0047247, 0.0047012,\n// 1844 12 9\n2394910.334478, 20.0, -4.0, 4.0, 6.0, 6.0,\n -0.0228630, 0.5825805, -1.300e-06, -9.910e-06,\n 1.1680990, 0.0034121, 1.077e-04, -1.700e-07,\n -22.9125710, -0.0038370, 6.000e-06,\n 121.7760468, 14.9968081, 0.000e-00,\n 0.5381160, 0.0000101, -1.310e-05,\n -0.0079820, 0.0000100, -1.310e-05,\n 0.0047491, 0.0047255,\n// 1845 5 6\n2395057.922921, 10.0, -4.0, 4.0, 6.1, 6.1,\n -0.2699750, 0.5067473, 1.890e-05, -6.050e-06,\n 0.9602920, 0.1007866, -1.417e-04, -1.120e-06,\n 16.5501709, 0.0114450, -4.000e-06,\n 330.8908081, 15.0021057, 0.000e-00,\n 0.5620680, 0.0000846, -1.010e-05,\n 0.0158510, 0.0000842, -1.010e-05,\n 0.0046321, 0.0046091,\n// 1845 10 30\n2395235.494416, 0.0, -4.0, 4.0, 6.2, 6.2,\n -0.1248390, 0.5402083, 4.410e-05, -7.950e-06,\n -0.8478550, -0.1282285, 1.268e-04, 1.830e-06,\n -14.0058403, -0.0132760, 3.000e-06,\n 184.0599976, 15.0017700, 0.000e-00,\n 0.5484250, -0.0001158, -1.180e-05,\n 0.0022760, -0.0001152, -1.180e-05,\n 0.0047128, 0.0046894,\n// 1846 4 25\n2395412.201739, 17.0, -4.0, 4.0, 6.3, 6.3,\n 0.0352620, 0.5316264, 2.500e-06, -7.500e-06,\n 0.2186120, 0.1313163, -9.670e-05, -1.770e-06,\n 13.2229795, 0.0132420, -3.000e-06,\n 75.5380783, 15.0031605, 0.000e-00,\n 0.5482950, 0.0001131, -1.140e-05,\n 0.0021460, 0.0001125, -1.130e-05,\n 0.0046443, 0.0046211,\n// 1846 10 20\n2395589.823745, 8.0, -4.0, 4.0, 6.4, 6.4,\n 0.0755830, 0.5029578, 2.750e-05, -6.180e-06,\n -0.1771640, -0.1391380, 6.150e-05, 1.650e-06,\n -10.2531099, -0.0146670, 2.000e-06,\n 303.7628784, 15.0030203, 0.000e-00,\n 0.5631670, -0.0001029, -1.050e-05,\n 0.0169450, -0.0001024, -1.040e-05,\n 0.0046995, 0.0046761,\n// 1847 4 15\n2395766.761262, 6.0, -4.0, 4.0, 6.5, 6.5,\n -0.0038750, 0.5545852, 7.100e-06, -9.120e-06,\n -0.5561360, 0.1577246, -3.250e-05, -2.510e-06,\n 9.5541801, 0.0145700, -2.000e-06,\n 269.9571838, 15.0039816, 0.000e-00,\n 0.5362470, 0.0000727, -1.260e-05,\n -0.0098410, 0.0000723, -1.260e-05,\n 0.0046572, 0.0046340,\n// 1847 10 9\n2395943.875262, 9.0, -4.0, 4.0, 6.6, 6.6,\n 0.1652660, 0.4824471, 4.900e-06, -5.380e-06,\n 0.5532080, -0.1470206, 1.080e-05, 1.580e-06,\n -6.0880198, -0.0155430, 1.000e-06,\n 318.1337891, 15.0040102, 0.000e-00,\n 0.5709350, -0.0000098, -9.800e-06,\n 0.0246740, -0.0000097, -9.700e-06,\n 0.0046848, 0.0046615,\n// 1848 3 5\n2396092.063601, 14.0, -4.0, 4.0, 6.7, 6.7,\n -0.1546090, 0.5474329, 1.040e-05, -8.860e-06,\n 1.4127140, 0.1700306, -3.620e-05, -2.690e-06,\n -5.8508000, 0.0157060, 1.000e-06,\n 27.0919704, 15.0037746, 0.000e-00,\n 0.5402140, -0.0000940, -1.260e-05,\n -0.0058950, -0.0000935, -1.250e-05,\n 0.0047100, 0.0046866,\n// 1848 4 3\n2396121.450771, 23.0, -4.0, 4.0, 6.7, 6.7,\n 0.4662630, 0.5558042, -1.060e-05, -9.410e-06,\n -1.1392250, 0.1734813, 3.270e-05, -2.850e-06,\n 5.6497402, 0.0154680, -1.000e-06,\n 164.2224274, 15.0044451, 0.000e-00,\n 0.5345020, -0.0000396, -1.290e-05,\n -0.0115770, -0.0000394, -1.280e-05,\n 0.0046710, 0.0046477,\n// 1848 8 28\n2396268.304418, 19.0, -4.0, 4.0, 6.8, 6.8,\n -0.5861190, 0.5090680, -6.000e-06, -6.540e-06,\n -1.4413300, -0.1473858, 1.680e-05, 1.800e-06,\n 9.4939203, -0.0144510, -2.000e-06,\n 104.7781906, 15.0042973, 0.000e-00,\n 0.5555250, 0.0001216, -1.060e-05,\n 0.0093410, 0.0001209, -1.060e-05,\n 0.0046325, 0.0046095,\n// 1848 9 27\n2396297.889804, 9.0, -4.0, 4.0, 6.8, 6.8,\n 0.2154690, 0.4905046, -1.900e-05, -5.800e-06,\n 1.2722790, -0.1571227, -3.760e-05, 1.810e-06,\n -1.7383000, -0.0158780, 0.000e-00,\n 317.2744446, 15.0046577, 0.000e-00,\n 0.5647360, 0.0000947, -1.020e-05,\n 0.0185050, 0.0000942, -1.010e-05,\n 0.0046695, 0.0046462,\n// 1849 2 23\n2396446.568164, 2.0, -4.0, 4.0, 6.8, 6.8,\n -0.0121000, 0.5216536, 2.300e-06, -7.150e-06,\n 0.7729540, 0.1464554, 3.060e-05, -1.950e-06,\n -9.9078798, 0.0149100, 2.000e-06,\n 206.5837555, 15.0027504, 0.000e-00,\n 0.5549290, -0.0001325, -1.130e-05,\n 0.0087480, -0.0001319, -1.130e-05,\n 0.0047233, 0.0046998,\n// 1849 8 18\n2396622.736683, 6.0, -4.0, 4.0, 6.9, 6.9,\n -0.0031090, 0.5466882, -3.370e-05, -8.380e-06,\n -0.7560880, -0.1364859, -3.700e-05, 2.000e-06,\n 13.1589499, -0.0131270, -3.000e-06,\n 269.0856628, 15.0035954, 0.000e-00,\n 0.5400340, 0.0000993, -1.200e-05,\n -0.0060730, 0.0000988, -1.190e-05,\n 0.0046211, 0.0045981,\n// 1850 2 12\n2396800.770566, 6.0, -4.0, 4.0, 7.0, 7.0,\n -0.2573020, 0.4976791, 6.000e-07, -5.780e-06,\n -0.0095620, 0.1184443, 8.590e-05, -1.310e-06,\n -13.7858200, 0.0135320, 3.000e-06,\n 266.3670349, 15.0013752, 0.000e-00,\n 0.5701560, -0.0000680, -1.010e-05,\n 0.0238990, -0.0000677, -1.010e-05,\n 0.0047353, 0.0047117,\n// 1850 8 7\n2396977.398542, 22.0, -4.0, 4.0, 7.0, 7.0,\n 0.2530660, 0.5720018, -3.810e-05, -9.730e-06,\n -0.0290560, -0.1152971, -1.058e-04, 1.870e-06,\n 16.3606606, -0.0114390, -4.000e-06,\n 148.6393433, 15.0026684, 0.000e-00,\n 0.5311540, 0.0000131, -1.280e-05,\n -0.0149090, 0.0000131, -1.270e-05,\n 0.0046119, 0.0045889,\n// 1851 2 1\n2397154.746144, 6.0, -4.0, 4.0, 7.1, 7.1,\n 0.1614420, 0.4958622, -2.910e-05, -5.530e-06,\n -0.6223630, 0.0908602, 1.294e-04, -9.500e-07,\n -17.2489204, 0.0115300, 4.000e-06,\n 266.5445557, 14.9998264, 0.000e-00,\n 0.5744520, 0.0000224, -9.900e-06,\n 0.0281730, 0.0000223, -9.800e-06,\n 0.0047449, 0.0047213,\n// 1851 7 28\n2397332.106737, 15.0, -4.0, 4.0, 7.1, 7.1,\n 0.3608230, 0.5694867, -2.680e-05, -9.310e-06,\n 0.7194830, -0.0838950, -1.709e-04, 1.270e-06,\n 19.0595493, -0.0093940, -4.000e-06,\n 43.4566002, 15.0015888, 0.000e-00,\n 0.5340940, -0.0000851, -1.240e-05,\n -0.0119840, -0.0000846, -1.240e-05,\n 0.0046050, 0.0045821,\n// 1852 1 21\n2397508.800184, 7.0, -4.0, 4.0, 7.1, 7.1,\n 0.0463850, 0.5211434, -3.450e-05, -6.520e-06,\n -1.2984411, 0.0618976, 1.863e-04, -7.200e-07,\n -20.0641594, 0.0089560, 5.000e-06,\n 282.1456909, 14.9983530, 0.000e-00,\n 0.5646120, 0.0001118, -1.070e-05,\n 0.0183820, 0.0001113, -1.060e-05,\n 0.0047514, 0.0047277,\n// 1852 6 17\n2397657.208218, 17.0, -4.0, 4.0, 7.2, 7.2,\n 0.1391620, 0.5243314, 2.910e-05, -6.650e-06,\n -1.1023620, 0.0654868, -1.037e-04, -9.300e-07,\n 23.4158192, 0.0008790, -6.000e-06,\n 74.8450089, 14.9991150, 0.000e-00,\n 0.5545690, -0.0001105, -1.050e-05,\n 0.0083890, -0.0001100, -1.050e-05,\n 0.0046010, 0.0045781,\n// 1852 12 11\n2397833.653288, 4.0, -4.0, 4.0, 7.2, 7.2,\n 0.3320920, 0.5642474, 1.600e-06, -9.110e-06,\n 0.8091740, -0.1010932, 1.271e-04, 1.790e-06,\n -23.0319500, -0.0031430, 6.000e-06,\n 241.6179657, 14.9966631, 0.000e-00,\n 0.5422510, 0.0000715, -1.270e-05,\n -0.0038680, 0.0000711, -1.270e-05,\n 0.0047501, 0.0047264,\n// 1853 6 6\n2398011.338443, 20.0, -4.0, 4.0, 7.2, 7.2,\n 0.0142750, 0.4962633, 3.320e-05, -5.580e-06,\n -0.3734850, 0.1033664, -1.241e-04, -1.280e-06,\n 22.7169495, 0.0039310, -5.000e-06,\n 120.4077301, 14.9993954, 0.000e-00,\n 0.5652940, -0.0000328, -9.700e-06,\n 0.0190620, -0.0000327, -9.700e-06,\n 0.0046062, 0.0045833,\n// 1853 11 30\n2398188.302534, 19.0, -4.0, 4.0, 7.2, 7.2,\n -0.1022170, 0.5633146, 4.940e-05, -9.520e-06,\n 0.2090840, -0.1477311, 1.459e-04, 2.670e-06,\n -21.7484798, -0.0062620, 6.000e-06,\n 107.7421799, 14.9976091, 0.000e-00,\n 0.5381140, -0.0000136, -1.310e-05,\n -0.0079840, -0.0000135, -1.300e-05,\n 0.0047433, 0.0047197,\n// 1854 5 26\n2398365.363111, 21.0, -4.0, 4.0, 7.1, 7.1,\n 0.0320890, 0.4921144, 2.680e-05, -5.680e-06,\n 0.4168780, 0.1415110, -1.454e-04, -1.760e-06,\n 21.1874504, 0.0068160, -5.000e-06,\n 135.8156281, 15.0001507, 0.000e-00,\n 0.5632970, 0.0000590, -9.900e-06,\n 0.0170740, 0.0000587, -9.900e-06,\n 0.0046136, 0.0045906,\n// 1854 11 20\n2398542.914563, 10.0, -4.0, 4.0, 7.1, 7.1,\n -0.1387550, 0.5330173, 6.730e-05, -8.090e-06,\n -0.4997690, -0.1799350, 1.549e-04, 2.920e-06,\n -19.6855793, -0.0090460, 5.000e-06,\n 333.5605164, 14.9988832, 0.000e-00,\n 0.5462890, -0.0001052, -1.220e-05,\n 0.0001500, -0.0001047, -1.210e-05,\n 0.0047345, 0.0047110,\n// 1855 5 16\n2398719.584164, 2.0, -4.0, 4.0, 7.1, 7.1,\n -0.3896080, 0.5087011, 4.270e-05, -6.850e-06,\n 1.0552770, 0.1823063, -1.682e-04, -2.580e-06,\n 18.9370708, 0.0093460, -4.000e-06,\n 210.9736176, 15.0012016, 0.000e-00,\n 0.5504550, 0.0001171, -1.100e-05,\n 0.0042960, 0.0001166, -1.100e-05,\n 0.0046225, 0.0045995,\n// 1855 11 9\n2398897.304067, 19.0, -4.0, 4.0, 7.1, 7.1,\n -0.6249920, 0.4902232, 8.370e-05, -6.180e-06,\n -1.1242870, -0.1985747, 1.468e-04, 2.700e-06,\n -16.8807201, -0.0114400, 4.000e-06,\n 109.0067520, 15.0003347, 0.000e-00,\n 0.5612010, -0.0001037, -1.080e-05,\n 0.0149880, -0.0001032, -1.070e-05,\n 0.0047240, 0.0047004,\n// 1856 4 5\n2399044.750703, 6.0, -4.0, 4.0, 7.1, 7.1,\n 0.3656330, 0.5118973, -7.500e-06, -8.500e-06,\n -0.7010700, 0.2750957, 2.500e-06, -4.780e-06,\n 6.1646600, 0.0151320, -2.000e-06,\n 269.3199768, 15.0042944, 0.000e-00,\n 0.5349460, 0.0000403, -1.290e-05,\n -0.0111360, 0.0000401, -1.280e-05,\n 0.0046695, 0.0046462,\n// 1856 9 29\n2399221.666481, 4.0, -4.0, 4.0, 7.0, 7.0,\n 0.4590090, 0.4412687, -1.410e-05, -4.840e-06,\n 0.8226170, -0.2448451, -1.910e-05, 2.850e-06,\n -2.4595699, -0.0156450, 0.000e-00,\n 242.4299316, 15.0044689, 0.000e-00,\n 0.5700650, 0.0000198, -9.800e-06,\n 0.0238080, 0.0000197, -9.700e-06,\n 0.0046720, 0.0046487,\n// 1857 3 25\n2399399.437243, 22.0, -4.0, 4.0, 7.0, 7.0,\n -0.2063630, 0.5056010, 2.480e-05, -8.270e-06,\n -0.2166570, 0.2807285, 3.400e-06, -4.800e-06,\n 2.0732801, 0.0156710, -1.000e-06,\n 148.5197601, 15.0044346, 0.000e-00,\n 0.5369160, -0.0000498, -1.280e-05,\n -0.0091750, -0.0000495, -1.270e-05,\n 0.0046838, 0.0046604,\n// 1857 9 18\n2399575.733389, 6.0, -4.0, 4.0, 7.0, 7.0,\n 0.2751280, 0.4568107, -3.030e-05, -5.540e-06,\n 0.0656880, -0.2543270, -6.700e-06, 3.260e-06,\n 1.8906699, -0.0155550, -1.000e-06,\n 271.4706421, 15.0047674, 0.000e-00,\n 0.5604410, 0.0000974, -1.040e-05,\n 0.0142320, 0.0000969, -1.040e-05,\n 0.0046569, 0.0046337,\n// 1858 3 15\n2399754.003794, 12.0, -4.0, 4.0, 7.1, 7.1,\n -0.3569370, 0.4814123, 2.770e-05, -6.790e-06,\n 0.5408990, 0.2667006, -8.100e-06, -3.970e-06,\n -2.1340799, 0.0157980, 0.000e-00,\n 357.7216492, 15.0041504, 0.000e-00,\n 0.5498290, -0.0001203, -1.160e-05,\n 0.0036730, -0.0001197, -1.150e-05,\n 0.0046984, 0.0046750,\n// 1858 9 7\n2399930.089917, 14.0, -4.0, 4.0, 7.1, 7.1,\n -0.3438510, 0.4893571, -1.670e-05, -7.130e-06,\n -0.4517740, -0.2642760, -3.200e-06, 4.030e-06,\n 6.0633302, -0.0149940, -1.000e-06,\n 30.5208607, 15.0046892, 0.000e-00,\n 0.5443260, 0.0001208, -1.170e-05,\n -0.0018020, 0.0001202, -1.170e-05,\n 0.0046426, 0.0046195,\n// 1859 2 3\n2400078.557435, 1.0, -4.0, 4.0, 7.2, 7.2,\n 0.4161330, 0.4688727, -4.990e-05, -5.240e-06,\n -1.5216660, 0.1919289, 1.592e-04, -2.290e-06,\n -16.7168503, 0.0116670, 4.000e-06,\n 191.4917755, 15.0000153, 0.000e-00,\n 0.5731370, -0.0000440, -1.000e-05,\n 0.0268650, -0.0000438, -9.900e-06,\n 0.0047437, 0.0047200,\n// 1859 3 4\n2400108.288070, 19.0, -4.0, 4.0, 7.2, 7.2,\n -0.6295450, 0.4564123, 2.230e-05, -5.380e-06,\n 1.2727530, 0.2439137, -1.450e-05, -3.070e-06,\n -6.4145999, 0.0154450, 1.000e-06,\n 102.0130920, 15.0034409, 0.000e-00,\n 0.5658850, -0.0000980, -1.030e-05,\n 0.0196490, -0.0000975, -1.030e-05,\n 0.0047131, 0.0046897,\n// 1859 7 29\n2400255.414550, 22.0, -4.0, 4.0, 7.3, 7.3,\n 0.4553560, 0.5498688, -6.920e-05, -9.330e-06,\n 1.1750360, -0.1983365, -1.894e-04, 3.540e-06,\n 18.7402802, -0.0094190, -4.000e-06,\n 148.4573364, 15.0016804, 0.000e-00,\n 0.5304560, -0.0000062, -1.280e-05,\n -0.0156040, -0.0000062, -1.280e-05,\n 0.0046056, 0.0045826,\n// 1859 8 28\n2400284.709726, 5.0, -4.0, 4.0, 7.3, 7.3,\n -0.5850900, 0.5183311, -2.200e-06, -8.610e-06,\n -1.1125751, -0.2624461, 8.400e-06, 4.550e-06,\n 9.9323397, -0.0140430, -2.000e-06,\n 254.6822052, 15.0042477, 0.000e-00,\n 0.5329700, 0.0000477, -1.280e-05,\n -0.0131020, 0.0000474, -1.270e-05,\n 0.0046300, 0.0046069,\n// 1860 1 23\n2400432.519112, 0.0, -4.0, 4.0, 7.5, 7.5,\n 0.0677180, 0.4806303, -5.280e-05, -5.410e-06,\n -0.9241260, 0.1629060, 1.552e-04, -1.990e-06,\n -19.6694298, 0.0091640, 5.000e-06,\n 177.0300140, 14.9984770, 0.000e-00,\n 0.5730890, 0.0000628, -1.000e-05,\n 0.0268160, 0.0000625, -1.000e-05,\n 0.0047510, 0.0047273,\n// 1860 7 18\n2400610.101671, 14.0, -4.0, 4.0, 7.7, 7.7,\n -0.0846020, 0.5453255, -2.420e-05, -8.520e-06,\n 0.5970870, -0.1608579, -1.718e-04, 2.660e-06,\n 20.9494896, -0.0070690, -5.000e-06,\n 28.5200195, 15.0006247, 0.000e-00,\n 0.5369460, -0.0000838, -1.210e-05,\n -0.0091460, -0.0000834, -1.210e-05,\n 0.0046010, 0.0045780,\n// 1861 1 11\n2400786.645406, 3.0, -4.0, 4.0, 7.8, 7.8,\n -0.2087910, 0.5169370, -4.790e-05, -6.770e-06,\n -0.2366250, 0.1339574, 1.549e-04, -1.910e-06,\n -21.8242092, 0.0061800, 6.000e-06,\n 222.9545135, 14.9972448, 0.000e-00,\n 0.5602930, 0.0001292, -1.110e-05,\n 0.0140850, 0.0001286, -1.100e-05,\n 0.0047547, 0.0047310,\n// 1861 7 8\n2400964.590575, 2.0, -4.0, 4.0, 7.9, 7.9,\n -0.1389660, 0.5232762, -9.300e-06, -6.890e-06,\n -0.1977970, -0.1153041, -1.375e-04, 1.650e-06,\n 22.5189896, -0.0043950, -5.000e-06,\n 208.8380280, 14.9997072, 0.000e-00,\n 0.5512130, -0.0001125, -1.080e-05,\n 0.0050510, -0.0001119, -1.070e-05,\n 0.0045990, 0.0045761,\n// 1861 12 31\n2401141.075764, 14.0, -4.0, 4.0, 7.8, 7.8,\n 0.0117170, 0.5585895, -4.430e-05, -8.740e-06,\n 0.5286680, 0.0982055, 1.409e-04, -1.680e-06,\n -23.0847397, 0.0029370, 6.000e-06,\n 29.1444798, 14.9965172, 0.000e-00,\n 0.5452120, 0.0000914, -1.250e-05,\n -0.0009220, 0.0000910, -1.240e-05,\n 0.0047552, 0.0047316,\n// 1862 6 27\n2401318.779408, 7.0, -4.0, 4.0, 7.6, 7.6,\n 0.0071350, 0.5047102, -1.180e-05, -5.770e-06,\n -1.0360600, -0.0703272, -1.052e-04, 9.200e-07,\n 23.3524494, -0.0014280, -6.000e-06,\n 284.3471680, 14.9991369, 0.000e-00,\n 0.5634750, -0.0000606, -9.800e-06,\n 0.0172510, -0.0000603, -9.800e-06,\n 0.0045996, 0.0045767,\n// 1862 11 21\n2401466.270690, 18.0, -4.0, 4.0, 7.4, 7.4,\n -0.4709790, 0.5753088, 5.020e-05, -9.620e-06,\n -1.4582371, -0.0715950, 2.269e-04, 1.130e-06,\n -19.9944897, -0.0089560, 5.000e-06,\n 93.4696198, 14.9988022, 0.000e-00,\n 0.5389320, -0.0000359, -1.290e-05,\n -0.0071700, -0.0000357, -1.290e-05,\n 0.0047354, 0.0047118,\n// 1862 12 21\n2401495.703501, 5.0, -4.0, 4.0, 7.4, 7.4,\n -0.0369880, 0.5802902, -1.420e-05, -9.860e-06,\n 1.1646920, 0.0522563, 1.128e-04, -1.020e-06,\n -23.4563103, -0.0004060, 7.000e-06,\n 255.4532776, 14.9963541, 0.000e-00,\n 0.5382970, 0.0000004, -1.320e-05,\n -0.0078020, 0.0000004, -1.310e-05,\n 0.0047533, 0.0047296,\n// 1863 5 17\n2401643.208851, 17.0, -4.0, 4.0, 7.2, 7.2,\n -0.1535980, 0.5133848, 1.080e-05, -6.180e-06,\n 1.0516080, 0.0718125, -1.657e-04, -7.800e-07,\n 19.3243694, 0.0092280, -4.000e-06,\n 75.9646683, 15.0010462, 0.000e-00,\n 0.5606960, 0.0000866, -1.020e-05,\n 0.0144860, 0.0000861, -1.010e-05,\n 0.0046215, 0.0045985,\n// 1863 11 11\n2401820.839619, 8.0, -4.0, 4.0, 6.8, 6.8,\n -0.2401250, 0.5442161, 4.930e-05, -7.920e-06,\n -0.8465220, -0.0998674, 1.533e-04, 1.400e-06,\n -17.3329601, -0.0113510, 4.000e-06,\n 303.9656677, 15.0002384, 0.000e-00,\n 0.5499700, -0.0001111, -1.180e-05,\n 0.0038130, -0.0001106, -1.170e-05,\n 0.0047253, 0.0047017,\n// 1864 5 6\n2401997.511665, 0.0, -4.0, 4.0, 6.5, 6.5,\n -0.2018930, 0.5393541, 1.330e-05, -7.700e-06,\n 0.2272790, 0.1068185, -1.207e-04, -1.440e-06,\n 16.5467300, 0.0114330, -4.000e-06,\n 180.8829346, 15.0021820, 0.000e-00,\n 0.5466090, 0.0001225, -1.140e-05,\n 0.0004690, 0.0001219, -1.140e-05,\n 0.0046318, 0.0046088,\n// 1864 10 30\n2402175.146193, 16.0, -4.0, 4.0, 6.1, 6.1,\n 0.2071500, 0.5062816, 2.600e-05, -6.170e-06,\n -0.2353240, -0.1190571, 8.920e-05, 1.390e-06,\n -14.0256100, -0.0132850, 3.000e-06,\n 64.0643311, 15.0016832, 0.000e-00,\n 0.5647400, -0.0001055, -1.040e-05,\n 0.0185100, -0.0001049, -1.040e-05,\n 0.0047133, 0.0046898,\n// 1865 4 25\n2402352.089286, 14.0, -4.0, 4.0, 5.6, 5.6,\n 0.0352770, 0.5610445, 1.010e-05, -9.280e-06,\n -0.4883500, 0.1382168, -6.120e-05, -2.200e-06,\n 13.3145905, 0.0131820, -3.000e-06,\n 30.5418701, 15.0032072, 0.000e-00,\n 0.5350450, 0.0000645, -1.260e-05,\n -0.0110370, 0.0000641, -1.260e-05,\n 0.0046435, 0.0046204,\n// 1865 10 19\n2402529.181406, 16.0, -4.0, 4.0, 5.2, 5.2,\n -0.0284250, 0.4855709, 1.640e-05, -5.400e-06,\n 0.5647080, -0.1346403, 3.480e-05, 1.440e-06,\n -10.1555300, -0.0147030, 2.000e-06,\n 63.7543793, 15.0030098, 0.000e-00,\n 0.5719510, 0.0000028, -9.800e-06,\n 0.0256840, 0.0000028, -9.800e-06,\n 0.0046992, 0.0046758,\n// 1866 3 16\n2402677.410703, 22.0, -4.0, 4.0, 4.8, 4.8,\n -0.3602070, 0.5443925, 2.910e-05, -8.750e-06,\n 1.3802700, 0.1759947, -6.080e-05, -2.770e-06,\n -1.5496800, 0.0160310, 0.000e-00,\n 147.8241425, 15.0043535, 0.000e-00,\n 0.5400460, -0.0000899, -1.250e-05,\n -0.0060610, -0.0000895, -1.250e-05,\n 0.0046962, 0.0046728,\n// 1866 4 15\n2402706.785880, 7.0, -4.0, 4.0, 4.7, 4.7,\n 0.4036880, 0.5592786, 3.000e-07, -9.440e-06,\n -1.1165930, 0.1601082, 5.200e-06, -2.610e-06,\n 9.7142496, 0.0145150, -2.000e-06,\n 284.9795227, 15.0039635, 0.000e-00,\n 0.5339910, -0.0000441, -1.290e-05,\n -0.0120860, -0.0000438, -1.280e-05,\n 0.0046567, 0.0046336,\n// 1866 10 8\n2402883.197482, 17.0, -4.0, 4.0, 4.2, 4.2,\n 0.4896010, 0.4933536, -2.220e-05, -5.870e-06,\n 1.1359160, -0.1515818, -9.100e-06, 1.750e-06,\n -5.9851499, -0.0155440, 1.000e-06,\n 78.1185303, 15.0040617, 0.000e-00,\n 0.5650240, 0.0000865, -1.020e-05,\n 0.0187930, 0.0000861, -1.020e-05,\n 0.0046839, 0.0046605,\n// 1867 3 6\n2403031.907495, 10.0, -4.0, 4.0, 3.8, 3.8,\n -0.1130910, 0.5163139, 1.280e-05, -7.010e-06,\n 0.7724710, 0.1587282, 5.000e-06, -2.100e-06,\n -5.7609701, 0.0157480, 1.000e-06,\n 327.1098938, 15.0037060, 0.000e-00,\n 0.5550760, -0.0001291, -1.120e-05,\n 0.0088940, -0.0001285, -1.120e-05,\n 0.0047109, 0.0046874,\n// 1867 8 29\n2403208.050774, 13.0, -4.0, 4.0, 3.3, 3.3,\n -0.3377190, 0.5432759, -1.340e-05, -8.410e-06,\n -0.7291750, -0.1558583, -1.260e-05, 2.320e-06,\n 9.4357595, -0.0144430, -2.000e-06,\n 14.7821302, 15.0043964, 0.000e-00,\n 0.5397850, 0.0001095, -1.210e-05,\n -0.0063210, 0.0001090, -1.200e-05,\n 0.0046316, 0.0046085,\n// 1868 2 23\n2403386.098272, 14.0, -4.0, 4.0, 2.8, 2.8,\n -0.1953330, 0.4919299, 1.400e-06, -5.690e-06,\n 0.0188510, 0.1370924, 5.990e-05, -1.520e-06,\n -9.9459200, 0.0149230, 2.000e-06,\n 26.5888004, 15.0026560, 0.000e-00,\n 0.5700150, -0.0000668, -1.010e-05,\n 0.0237580, -0.0000664, -1.000e-05,\n 0.0047246, 0.0047011,\n// 1868 8 18\n2403562.716779, 5.0, -4.0, 4.0, 2.2, 2.2,\n -0.1255510, 0.5664073, -1.690e-05, -9.650e-06,\n -0.0143720, -0.1413512, -8.140e-05, 2.320e-06,\n 13.0380297, -0.0131640, -3.000e-06,\n 254.0970612, 15.0036831, 0.000e-00,\n 0.5314620, 0.0000237, -1.280e-05,\n -0.0146030, 0.0000235, -1.280e-05,\n 0.0046206, 0.0045976,\n// 1869 2 11\n2403740.074067, 14.0, -4.0, 4.0, 1.7, 1.7,\n 0.2533810, 0.4910482, -3.290e-05, -5.490e-06,\n -0.5823880, 0.1164406, 1.035e-04, -1.240e-06,\n -13.8754797, 0.0134940, 3.000e-06,\n 26.3777409, 15.0013151, 0.000e-00,\n 0.5736770, 0.0000245, -9.900e-06,\n 0.0274020, 0.0000244, -9.800e-06,\n 0.0047361, 0.0047125,\n// 1869 8 7\n2403917.417416, 22.0, -4.0, 4.0, 1.3, 1.3,\n 0.1295300, 0.5624554, -1.790e-05, -9.120e-06,\n 0.6839040, -0.1151958, -1.463e-04, 1.770e-06,\n 16.2422791, -0.0115110, -3.000e-06,\n 148.6414032, 15.0026932, 0.000e-00,\n 0.5350950, -0.0000782, -1.240e-05,\n -0.0109870, -0.0000778, -1.230e-05,\n 0.0046119, 0.0045889,\n// 1870 1 31\n2404094.143347, 15.0, -4.0, 4.0, 0.8, 0.8,\n 0.0046630, 0.5177645, -3.800e-05, -6.540e-06,\n -1.3036150, 0.0953251, 1.633e-04, -1.160e-06,\n -17.3130493, 0.0114680, 4.000e-06,\n 41.5650902, 14.9998465, 0.000e-00,\n 0.5634110, 0.0001185, -1.070e-05,\n 0.0171870, 0.0001179, -1.070e-05,\n 0.0047448, 0.0047212,\n// 1870 6 28\n2404242.490774, 0.0, -4.0, 4.0, 0.4, 0.4,\n 0.1705160, 0.5259710, 1.580e-05, -6.610e-06,\n -1.1884140, 0.0237755, -1.008e-04, -3.800e-07,\n 23.2727909, -0.0021530, -6.000e-06,\n 179.2522430, 14.9992437, 0.000e-00,\n 0.5553210, -0.0001117, -1.050e-05,\n 0.0091370, -0.0001111, -1.040e-05,\n 0.0045992, 0.0045763,\n// 1870 7 28\n2404271.960085, 11.0, -4.0, 4.0, 0.3, 0.3,\n 0.2032460, 0.5374827, -1.150e-05, -7.420e-06,\n 1.4907579, -0.0815987, -1.955e-04, 1.020e-06,\n 18.9997292, -0.0094520, -4.000e-06,\n 343.4455566, 15.0015345, 0.000e-00,\n 0.5480960, -0.0001172, -1.110e-05,\n 0.0019490, -0.0001166, -1.100e-05,\n 0.0046057, 0.0045828,\n// 1870 12 22\n2404419.019128, 12.0, -4.0, 4.0, -0.1, -0.1,\n -0.1825310, 0.5718303, 1.380e-05, -9.310e-06,\n 0.8793580, -0.0536312, 1.287e-04, 1.020e-06,\n -23.4566002, 0.0002920, 6.000e-06,\n 0.2933100, 14.9963236, 0.000e-00,\n 0.5418980, 0.0000866, -1.280e-05,\n -0.0042190, 0.0000862, -1.270e-05,\n 0.0047538, 0.0047301,\n// 1871 6 18\n2404596.607656, 3.0, -4.0, 4.0, -0.5, -0.5,\n 0.2670020, 0.5023298, 1.360e-05, -5.640e-06,\n -0.4245120, 0.0643473, -1.295e-04, -8.300e-07,\n 23.4075794, 0.0009320, -6.000e-06,\n 224.8463898, 14.9990530, 0.000e-00,\n 0.5652590, -0.0000364, -9.700e-06,\n 0.0190270, -0.0000362, -9.700e-06,\n 0.0046019, 0.0045790,\n// 1871 12 12\n2404773.669191, 4.0, -4.0, 4.0, -1.0, -1.0,\n -0.0025220, 0.5729116, 3.480e-05, -9.680e-06,\n 0.1869110, -0.1020480, 1.628e-04, 1.880e-06,\n -23.0590706, -0.0030180, 6.000e-06,\n 241.5844269, 14.9966688, 0.000e-00,\n 0.5386120, -0.0000247, -1.310e-05,\n -0.0074880, -0.0000245, -1.300e-05,\n 0.0047498, 0.0047261,\n// 1872 6 6\n2404950.638925, 3.0, -4.0, 4.0, -1.4, -1.4,\n -0.2315560, 0.5023846, 2.780e-05, -5.860e-06,\n 0.2675990, 0.1056895, -1.529e-04, -1.350e-06,\n 22.6829109, 0.0040080, -5.000e-06,\n 225.4105072, 14.9994221, 0.000e-00,\n 0.5622260, 0.0000771, -1.000e-05,\n 0.0160090, 0.0000767, -9.900e-06,\n 0.0046065, 0.0045836,\n// 1872 11 30\n2405128.270525, 18.0, -4.0, 4.0, -1.8, -1.8,\n -0.3947420, 0.5429074, 7.430e-05, -8.180e-06,\n -0.4226540, -0.1406699, 1.730e-04, 2.300e-06,\n -21.7998104, -0.0061770, 6.000e-06,\n 92.7166824, 14.9975252, 0.000e-00,\n 0.5475680, -0.0000952, -1.210e-05,\n 0.0014230, -0.0000947, -1.210e-05,\n 0.0047436, 0.0047200,\n// 1873 5 26\n2405304.881202, 9.0, -4.0, 4.0, -2.1, -2.1,\n -0.3667190, 0.5216814, 3.830e-05, -7.120e-06,\n 0.9885390, 0.1492519, -1.840e-04, -2.160e-06,\n 21.1674900, 0.0068220, -5.000e-06,\n 315.8120422, 15.0002317, 0.000e-00,\n 0.5489520, 0.0001209, -1.110e-05,\n 0.0028000, 0.0001203, -1.100e-05,\n 0.0046132, 0.0045902,\n// 1873 11 20\n2405482.640883, 3.0, -4.0, 4.0, -2.5, -2.5,\n -0.5911390, 0.4998185, 8.240e-05, -6.260e-06,\n -1.1334209, -0.1673970, 1.710e-04, 2.280e-06,\n -19.7058506, -0.0090490, 5.000e-06,\n 228.5554047, 14.9987869, 0.000e-00,\n 0.5626900, -0.0001004, -1.070e-05,\n 0.0164700, -0.0000999, -1.070e-05,\n 0.0047351, 0.0047115,\n// 1874 4 16\n2405630.083945, 14.0, -4.0, 4.0, -2.7, -2.7,\n 0.3695350, 0.5193665, 4.300e-06, -8.670e-06,\n -0.7503690, 0.2623946, -1.870e-05, -4.590e-06,\n 10.1943197, 0.0141190, -2.000e-06,\n 30.0654392, 15.0037804, 0.000e-00,\n 0.5339010, 0.0000347, -1.290e-05,\n -0.0121750, 0.0000345, -1.280e-05,\n 0.0046552, 0.0046320,\n// 1874 10 10\n2405806.967745, 11.0, -4.0, 4.0, -3.0, -3.0,\n 0.3671320, 0.4446712, -7.000e-07, -4.880e-06,\n 0.9252840, -0.2386046, -1.100e-06, 2.790e-06,\n -6.6747499, -0.0152300, 1.000e-06,\n 348.2396851, 15.0038042, 0.000e-00,\n 0.5708350, 0.0000302, -9.800e-06,\n 0.0245750, 0.0000301, -9.800e-06,\n 0.0046865, 0.0046632,\n// 1875 4 6\n2405984.775996, 7.0, -4.0, 4.0, -3.3, -3.3,\n 0.2524480, 0.5084245, 1.580e-05, -8.290e-06,\n -0.0107660, 0.2737373, -3.110e-05, -4.670e-06,\n 6.3285599, 0.0151030, -1.000e-06,\n 284.3533325, 15.0042639, 0.000e-00,\n 0.5365190, -0.0000769, -1.270e-05,\n -0.0095710, -0.0000765, -1.260e-05,\n 0.0046693, 0.0046461,\n// 1875 9 29\n2406161.040383, 13.0, -4.0, 4.0, -3.6, -3.6,\n 0.1320170, 0.4583244, -1.380e-05, -5.610e-06,\n 0.2043490, -0.2546514, 9.600e-06, 3.300e-06,\n -2.3704700, -0.0156200, 0.000e-00,\n 17.4089909, 15.0045261, 0.000e-00,\n 0.5604520, 0.0001084, -1.050e-05,\n 0.0142430, 0.0001079, -1.050e-05,\n 0.0046709, 0.0046476,\n// 1876 3 25\n2406339.336879, 20.0, -4.0, 4.0, -3.8, -3.8,\n -0.3384660, 0.4799440, 3.970e-05, -6.710e-06,\n 0.5146980, 0.2658574, -2.980e-05, -3.920e-06,\n 2.1957800, 0.0156990, -1.000e-06,\n 118.5422211, 15.0043669, 0.000e-00,\n 0.5498770, -0.0001212, -1.150e-05,\n 0.0037210, -0.0001206, -1.140e-05,\n 0.0046843, 0.0046610,\n// 1876 9 17\n2406515.409203, 22.0, -4.0, 4.0, -4.0, -4.0,\n -0.1580740, 0.4877136, -1.250e-05, -7.170e-06,\n -0.4903070, -0.2709663, 2.140e-05, 4.170e-06,\n 1.8662000, -0.0155120, -1.000e-06,\n 151.4748535, 15.0048475, 0.000e-00,\n 0.5442750, 0.0001112, -1.180e-05,\n -0.0018540, 0.0001107, -1.180e-05,\n 0.0046559, 0.0046327,\n// 1877 3 15\n2406693.609827, 3.0, -4.0, 4.0, -4.2, -4.2,\n -0.5079580, 0.4521719, 2.910e-05, -5.300e-06,\n 1.3100410, 0.2494116, -3.800e-05, -3.110e-06,\n -2.1241100, 0.0158420, 0.000e-00,\n 222.7177734, 15.0040722, 0.000e-00,\n 0.5656980, -0.0001000, -1.030e-05,\n 0.0194630, -0.0000995, -1.020e-05,\n 0.0046995, 0.0046761,\n// 1877 8 9\n2406840.729441, 6.0, -4.0, 4.0, -4.4, -4.4,\n 0.7834820, 0.5378820, -8.350e-05, -9.100e-06,\n 1.1099110, -0.2281470, -1.631e-04, 4.040e-06,\n 15.8412399, -0.0114940, -3.000e-06,\n 268.6845093, 15.0027742, 0.000e-00,\n 0.5308880, -0.0000235, -1.280e-05,\n -0.0151730, -0.0000234, -1.280e-05,\n 0.0046127, 0.0045897,\n// 1877 9 7\n2406870.033824, 13.0, -4.0, 4.0, -4.4, -4.4,\n -0.4706860, 0.5124272, 4.000e-06, -8.540e-06,\n -1.1076460, -0.2752363, 3.180e-05, 4.780e-06,\n 5.9291801, -0.0149880, -1.000e-06,\n 15.5481901, 15.0047626, 0.000e-00,\n 0.5333280, 0.0000365, -1.280e-05,\n -0.0127460, 0.0000363, -1.270e-05,\n 0.0046421, 0.0046190,\n// 1878 2 2\n2407017.852685, 8.0, -4.0, 4.0, -4.6, -4.6,\n 0.1255820, 0.4704674, -5.480e-05, -5.310e-06,\n -0.9288610, 0.1927238, 1.321e-04, -2.350e-06,\n -16.8084602, 0.0116020, 4.000e-06,\n 296.5071106, 14.9999685, 0.000e-00,\n 0.5722340, 0.0000670, -1.000e-05,\n 0.0259660, 0.0000667, -1.000e-05,\n 0.0047442, 0.0047205,\n// 1878 7 29\n2407195.407845, 22.0, -4.0, 4.0, -4.7, -4.7,\n 0.3271940, 0.5321238, -4.570e-05, -8.240e-06,\n 0.5438320, -0.1951580, -1.495e-04, 3.180e-06,\n 18.6418400, -0.0095120, -4.000e-06,\n 148.4487152, 15.0016804, 0.000e-00,\n 0.5379020, -0.0001029, -1.210e-05,\n -0.0081950, -0.0001024, -1.200e-05,\n 0.0046060, 0.0045830,\n// 1879 1 22\n2407371.995233, 12.0, -4.0, 4.0, -4.9, -4.9,\n 0.1165780, 0.5074642, -6.550e-05, -6.680e-06,\n -0.1531040, 0.1719248, 1.302e-04, -2.440e-06,\n -19.6947498, 0.0091130, 5.000e-06,\n 357.0483093, 14.9985304, 0.000e-00,\n 0.5593010, 0.0001162, -1.110e-05,\n 0.0130980, 0.0001156, -1.110e-05,\n 0.0047506, 0.0047269,\n// 1879 7 19\n2407549.878148, 9.0, -4.0, 4.0, -5.0, -5.0,\n -0.0796860, 0.5116371, -1.870e-05, -6.650e-06,\n -0.1264710, -0.1521409, -1.265e-04, 2.120e-06,\n 20.9116592, -0.0071400, -5.000e-06,\n 313.5000916, 15.0005598, 0.000e-00,\n 0.5522960, -0.0001124, -1.070e-05,\n 0.0061280, -0.0001119, -1.070e-05,\n 0.0046016, 0.0045787,\n// 1880 1 11\n2407726.440566, 23.0, -4.0, 4.0, -5.1, -5.1,\n 0.1053940, 0.5502405, -5.830e-05, -8.650e-06,\n 0.5581130, 0.1431920, 1.238e-04, -2.420e-06,\n -21.7890205, 0.0062210, 6.000e-06,\n 162.9462128, 14.9973555, 0.000e-00,\n 0.5445540, 0.0000812, -1.250e-05,\n -0.0015760, 0.0000808, -1.240e-05,\n 0.0047540, 0.0047303,\n// 1880 7 7\n2407904.048933, 13.0, -4.0, 4.0, -5.2, -5.2,\n -0.2879150, 0.4969432, -1.220e-05, -5.640e-06,\n -0.8998700, -0.1088056, -1.026e-04, 1.360e-06,\n 22.5316906, -0.0043760, -5.000e-06,\n 13.8238001, 14.9996338, 0.000e-00,\n 0.5639370, -0.0000448, -9.800e-06,\n 0.0177100, -0.0000446, -9.700e-06,\n 0.0045994, 0.0045765,\n// 1880 12 2\n2408051.633016, 3.0, -4.0, 4.0, -5.3, -5.3,\n -0.1866630, 0.5781853, 2.620e-05, -9.640e-06,\n -1.5097470, -0.0288755, 2.494e-04, 4.000e-07,\n -22.0133705, -0.0060280, 6.000e-06,\n 227.5825043, 14.9974670, 0.000e-00,\n 0.5397360, -0.0000492, -1.290e-05,\n -0.0063700, -0.0000490, -1.290e-05,\n 0.0047441, 0.0047205,\n// 1880 12 31\n2408081.072934, 14.0, -4.0, 4.0, -5.3, -5.3,\n -0.0574690, 0.5738307, -2.600e-05, -9.740e-06,\n 1.1667660, 0.1009352, 1.070e-04, -1.870e-06,\n -23.0533791, 0.0030530, 6.000e-06,\n 29.1112404, 14.9965801, 0.000e-00,\n 0.5383770, -0.0000091, -1.320e-05,\n -0.0077220, -0.0000090, -1.310e-05,\n 0.0047549, 0.0047312,\n// 1881 5 27\n2408228.492136, 0.0, -4.0, 4.0, -5.3, -5.3,\n 0.0157600, 0.5187871, -3.300e-06, -6.300e-06,\n 1.1386490, 0.0375973, -1.859e-04, -3.600e-07,\n 21.4489594, 0.0066520, -5.000e-06,\n 180.7558899, 15.0000811, 0.000e-00,\n 0.5594030, 0.0000870, -1.020e-05,\n 0.0131990, 0.0000866, -1.020e-05,\n 0.0046127, 0.0045897,\n// 1881 11 21\n2408406.188307, 17.0, -4.0, 4.0, -5.4, -5.4,\n 0.1583550, 0.5476418, 2.740e-05, -7.910e-06,\n -0.9179510, -0.0645650, 1.805e-04, 8.700e-07,\n -20.0693893, -0.0088820, 5.000e-06,\n 78.4560013, 14.9986877, 0.000e-00,\n 0.5513120, -0.0001278, -1.170e-05,\n 0.0051490, -0.0001272, -1.170e-05,\n 0.0047359, 0.0047124,\n// 1882 5 17\n2408582.816979, 8.0, -4.0, 4.0, -5.5, -5.5,\n 0.1697030, 0.5467934, -5.900e-06, -7.890e-06,\n 0.3535410, 0.0757325, -1.473e-04, -1.000e-06,\n 19.3297901, 0.0092130, -4.000e-06,\n 300.9613037, 15.0011225, 0.000e-00,\n 0.5451620, 0.0001063, -1.150e-05,\n -0.0009710, 0.0001058, -1.140e-05,\n 0.0046212, 0.0045982,\n// 1882 11 10\n2408760.473853, 23.0, -4.0, 4.0, -5.5, -5.5,\n -0.2266860, 0.5100774, 4.150e-05, -6.150e-06,\n -0.1678500, -0.0926010, 1.121e-04, 1.050e-06,\n -17.3372192, -0.0113610, 4.000e-06,\n 168.9716644, 15.0001583, 0.000e-00,\n 0.5662920, -0.0000846, -1.040e-05,\n 0.0200530, -0.0000842, -1.030e-05,\n 0.0047255, 0.0047019,\n// 1883 5 6\n2408937.412372, 22.0, -4.0, 4.0, -5.6, -5.6,\n 0.1405590, 0.5680952, 6.300e-06, -9.450e-06,\n -0.4055240, 0.1116906, -8.970e-05, -1.770e-06,\n 16.6349792, 0.0113620, -4.000e-06,\n 150.8878326, 15.0022144, 0.000e-00,\n 0.5339730, 0.0000531, -1.270e-05,\n -0.0121040, 0.0000528, -1.260e-05,\n 0.0046315, 0.0046084,\n// 1883 10 30\n2409114.493681, 0.0, -4.0, 4.0, -5.6, -5.6,\n 0.1899470, 0.4900740, 1.190e-05, -5.450e-06,\n 0.4719910, -0.1157287, 6.250e-05, 1.220e-06,\n -13.9373598, -0.0133300, 3.000e-06,\n 184.0635223, 15.0016899, 0.000e-00,\n 0.5728500, -0.0000017, -9.800e-06,\n 0.0265790, -0.0000016, -9.800e-06,\n 0.0047126, 0.0046892,\n// 1884 3 27\n2409262.751512, 6.0, -4.0, 4.0, -5.6, -5.6,\n -0.4665270, 0.5435652, 4.310e-05, -8.670e-06,\n 1.3838511, 0.1747088, -8.680e-05, -2.730e-06,\n 2.7712801, 0.0158640, -1.000e-06,\n 268.6594543, 15.0045147, 0.000e-00,\n 0.5398810, -0.0000895, -1.240e-05,\n -0.0062250, -0.0000890, -1.240e-05,\n 0.0046821, 0.0046588,\n// 1884 4 25\n2409292.115476, 15.0, -4.0, 4.0, -5.7, -5.7,\n 0.4020250, 0.5641081, 5.700e-06, -9.490e-06,\n -1.0712990, 0.1396257, -2.320e-05, -2.260e-06,\n 13.4571400, 0.0131140, -3.000e-06,\n 45.5603790, 15.0031681, 0.000e-00,\n 0.5335680, -0.0000518, -1.280e-05,\n -0.0125070, -0.0000516, -1.270e-05,\n 0.0046435, 0.0046203,\n// 1884 10 19\n2409468.512295, 0.0, -4.0, 4.0, -5.7, -5.7,\n 0.1736880, 0.4980922, -5.500e-06, -5.970e-06,\n 1.1863220, -0.1394809, 1.340e-05, 1.620e-06,\n -10.0584698, -0.0147150, 2.000e-06,\n 183.7436523, 15.0030785, 0.000e-00,\n 0.5651790, 0.0001018, -1.030e-05,\n 0.0189460, 0.0001013, -1.020e-05,\n 0.0046981, 0.0046747,\n// 1885 3 16\n2409617.240076, 18.0, -4.0, 4.0, -5.7, -5.7,\n -0.1223440, 0.5129434, 2.080e-05, -6.900e-06,\n 0.8039680, 0.1639571, -2.140e-05, -2.150e-06,\n -1.4592700, 0.0160630, 0.000e-00,\n 87.8469086, 15.0042782, 0.000e-00,\n 0.5551220, -0.0001290, -1.110e-05,\n 0.0089390, -0.0001283, -1.110e-05,\n 0.0046970, 0.0046736,\n// 1885 9 8\n2409793.369352, 21.0, -4.0, 4.0, -5.8, -5.8,\n -0.1790950, 0.5411537, -1.360e-05, -8.450e-06,\n -0.8333460, -0.1685533, 1.780e-05, 2.540e-06,\n 5.4013300, -0.0153330, -1.000e-06,\n 135.6653748, 15.0048704, 0.000e-00,\n 0.5397730, 0.0000980, -1.220e-05,\n -0.0063330, 0.0000975, -1.210e-05,\n 0.0046441, 0.0046210,\n// 1886 3 5\n2409971.420435, 22.0, -4.0, 4.0, -5.8, -5.8,\n -0.0724550, 0.4876250, 2.400e-06, -5.610e-06,\n 0.0793380, 0.1489602, 3.300e-05, -1.650e-06,\n -5.8022699, 0.0157650, 1.000e-06,\n 147.1133728, 15.0036249, 0.000e-00,\n 0.5696990, -0.0000678, -1.000e-05,\n 0.0234440, -0.0000674, -1.000e-05,\n 0.0047118, 0.0046883,\n// 1886 8 29\n2410148.038458, 13.0, -4.0, 4.0, -5.9, -5.9,\n 0.0140920, 0.5613682, -1.880e-05, -9.570e-06,\n -0.1141570, -0.1606898, -5.070e-05, 2.650e-06,\n 9.2898397, -0.0144710, -2.000e-06,\n 14.8077002, 15.0044651, 0.000e-00,\n 0.5319550, 0.0000106, -1.290e-05,\n -0.0141120, 0.0000105, -1.280e-05,\n 0.0046316, 0.0046085,\n// 1887 2 22\n2410325.397958, 22.0, -4.0, 4.0, -5.9, -5.9,\n 0.3803920, 0.4868415, -3.440e-05, -5.460e-06,\n -0.5211030, 0.1354336, 7.630e-05, -1.460e-06,\n -10.0444698, 0.0148970, 2.000e-06,\n 146.5876312, 15.0026131, 0.000e-00,\n 0.5727290, 0.0000249, -9.900e-06,\n 0.0264580, 0.0000247, -9.800e-06,\n 0.0047251, 0.0047016,\n// 1887 8 19\n2410502.730616, 6.0, -4.0, 4.0, -5.9, -5.9,\n 0.4127160, 0.5551194, -3.000e-05, -8.930e-06,\n 0.5468430, -0.1402108, -1.153e-04, 2.160e-06,\n 12.8901501, -0.0132280, -3.000e-06,\n 269.1158142, 15.0036964, 0.000e-00,\n 0.5361650, -0.0000944, -1.240e-05,\n -0.0099230, -0.0000939, -1.230e-05,\n 0.0046210, 0.0045980,\n// 1888 2 11\n2410679.484892, 0.0, -4.0, 4.0, -6.0, -6.0,\n 0.4807120, 0.5137118, -5.650e-05, -6.530e-06,\n -1.1893120, 0.1227014, 1.334e-04, -1.520e-06,\n -13.9348602, 0.0134490, 3.000e-06,\n 176.3813019, 15.0013418, 0.000e-00,\n 0.5621840, 0.0001027, -1.080e-05,\n 0.0159660, 0.0001022, -1.070e-05,\n 0.0047361, 0.0047125,\n// 1888 7 9\n2410827.771432, 7.0, -4.0, 4.0, -6.0, -6.0,\n 0.2145710, 0.5243915, 2.800e-06, -6.540e-06,\n -1.2871070, -0.0165217, -8.990e-05, 1.400e-07,\n 22.3189697, -0.0050800, -5.000e-06,\n 283.7579651, 14.9998293, 0.000e-00,\n 0.5561600, -0.0001134, -1.040e-05,\n 0.0099730, -0.0001128, -1.030e-05,\n 0.0045993, 0.0045764,\n// 1888 8 7\n2410857.254007, 18.0, -4.0, 4.0, -6.0, -6.0,\n 0.2430690, 0.5299285, -1.610e-05, -7.230e-06,\n 1.4171120, -0.1107525, -1.704e-04, 1.410e-06,\n 16.1709595, -0.0115620, -3.000e-06,\n 88.6410904, 15.0026407, 0.000e-00,\n 0.5494560, -0.0001152, -1.100e-05,\n 0.0033020, -0.0001146, -1.100e-05,\n 0.0046124, 0.0045894,\n// 1889 1 1\n2411004.386691, 21.0, -4.0, 4.0, -6.1, -6.1,\n -0.1534580, 0.5753707, -1.300e-06, -9.430e-06,\n 0.8617830, -0.0054037, 1.245e-04, 2.200e-07,\n -22.9374504, 0.0037420, 6.000e-06,\n 133.9537048, 14.9966564, 0.000e-00,\n 0.5415350, 0.0000772, -1.280e-05,\n -0.0045800, 0.0000768, -1.280e-05,\n 0.0047552, 0.0047316,\n// 1889 6 28\n2411181.875005, 9.0, -4.0, 4.0, -6.1, -6.1,\n 0.0264520, 0.5054299, 9.200e-06, -5.670e-06,\n -0.5424850, 0.0246975, -1.248e-04, -3.700e-07,\n 23.2799702, -0.0020930, -6.000e-06,\n 314.2546692, 14.9991875, 0.000e-00,\n 0.5653210, -0.0000212, -9.700e-06,\n 0.0190880, -0.0000211, -9.600e-06,\n 0.0045995, 0.0045766,\n// 1889 12 22\n2411359.037668, 13.0, -4.0, 4.0, -6.2, -6.2,\n 0.0729160, 0.5789851, 1.760e-05, -9.780e-06,\n 0.1828920, -0.0533955, 1.694e-04, 1.040e-06,\n -23.4503899, 0.0004330, 6.000e-06,\n 15.2482100, 14.9963417, 0.000e-00,\n 0.5390140, -0.0000346, -1.310e-05,\n -0.0070890, -0.0000344, -1.300e-05,\n 0.0047538, 0.0047302,\n// 1890 6 17\n2411535.913254, 10.0, -4.0, 4.0, -6.2, -6.2,\n 0.0127660, 0.5104226, 8.000e-06, -6.000e-06,\n 0.2282090, 0.0664997, -1.582e-04, -8.900e-07,\n 23.3957996, 0.0010130, -6.000e-06,\n 329.8519897, 14.9990788, 0.000e-00,\n 0.5613310, 0.0000745, -1.000e-05,\n 0.0151170, 0.0000741, -1.000e-05,\n 0.0046018, 0.0045789,\n// 1890 12 12\n2411713.628795, 3.0, -4.0, 4.0, -6.3, -6.3,\n -0.1365390, 0.5507914, 5.260e-05, -8.260e-06,\n -0.4853290, -0.0963126, 1.915e-04, 1.600e-06,\n -23.0819702, -0.0029220, 6.000e-06,\n 226.5563049, 14.9965944, 0.000e-00,\n 0.5486270, -0.0001079, -1.210e-05,\n 0.0024770, -0.0001074, -1.200e-05,\n 0.0047502, 0.0047265,\n// 1891 6 6\n2411890.177503, 16.0, -4.0, 4.0, -6.3, -6.3,\n -0.3377570, 0.5333236, 2.920e-05, -7.380e-06,\n 0.9259970, 0.1112758, -1.951e-04, -1.650e-06,\n 22.6749401, 0.0040060, -5.000e-06,\n 60.3954506, 14.9995012, 0.000e-00,\n 0.5475840, 0.0001239, -1.120e-05,\n 0.0014390, 0.0001233, -1.110e-05,\n 0.0046062, 0.0045832,\n// 1891 12 1\n2412067.979958, 12.0, -4.0, 4.0, -6.3, -6.3,\n -0.0656280, 0.5090219, 5.730e-05, -6.350e-06,\n -1.2749830, -0.1301498, 1.973e-04, 1.790e-06,\n -21.8170395, -0.0061610, 6.000e-06,\n 2.7163401, 14.9974279, 0.000e-00,\n 0.5639230, -0.0001172, -1.070e-05,\n 0.0176960, -0.0001166, -1.060e-05,\n 0.0047440, 0.0047204,\n// 1892 4 26\n2412215.413426, 22.0, -4.0, 4.0, -6.4, -6.4,\n 0.4109880, 0.5294864, 1.150e-05, -8.880e-06,\n -0.7873000, 0.2428765, -4.070e-05, -4.270e-06,\n 13.8921404, 0.0126590, -3.000e-06,\n 150.6109924, 15.0029631, 0.000e-00,\n 0.5329630, 0.0000266, -1.290e-05,\n -0.0131090, 0.0000264, -1.280e-05,\n 0.0046421, 0.0046190,\n// 1892 10 20\n2412392.275070, 19.0, -4.0, 4.0, -6.4, -6.4,\n 0.6412120, 0.4510711, -4.000e-07, -4.960e-06,\n 0.8290590, -0.2264520, 2.470e-05, 2.660e-06,\n -10.7218304, -0.0143080, 2.000e-06,\n 108.8266907, 15.0027609, 0.000e-00,\n 0.5715520, 0.0000236, -9.800e-06,\n 0.0252880, 0.0000235, -9.800e-06,\n 0.0047006, 0.0046772,\n// 1893 4 16\n2412570.108462, 15.0, -4.0, 4.0, -6.4, -6.4,\n 0.2837570, 0.5143971, 2.600e-05, -8.350e-06,\n -0.0541100, 0.2601342, -5.290e-05, -4.420e-06,\n 10.3486795, 0.0140750, -2.000e-06,\n 45.0875816, 15.0037289, 0.000e-00,\n 0.5362320, -0.0000821, -1.260e-05,\n -0.0098570, -0.0000817, -1.260e-05,\n 0.0046553, 0.0046321,\n// 1893 10 9\n2412746.354424, 21.0, -4.0, 4.0, -6.4, -6.4,\n 0.3644330, 0.4630799, -1.130e-05, -5.710e-06,\n 0.1294870, -0.2489858, 3.470e-05, 3.250e-06,\n -6.6010399, -0.0152110, 1.000e-06,\n 138.2300568, 15.0038729, 0.000e-00,\n 0.5605620, 0.0001016, -1.060e-05,\n 0.0143530, 0.0001011, -1.050e-05,\n 0.0046853, 0.0046619,\n// 1894 4 6\n2412924.662281, 4.0, -4.0, 4.0, -6.3, -6.3,\n -0.2208370, 0.4818591, 4.660e-05, -6.670e-06,\n 0.5329420, 0.2587269, -5.340e-05, -3.790e-06,\n 6.4279399, 0.0151210, -1.000e-06,\n 239.3769531, 15.0041828, 0.000e-00,\n 0.5499090, -0.0001260, -1.140e-05,\n 0.0037520, -0.0001254, -1.130e-05,\n 0.0046700, 0.0046467,\n// 1894 9 29\n2413100.735443, 6.0, -4.0, 4.0, -6.3, -6.3,\n -0.0508160, 0.4894251, -4.300e-06, -7.260e-06,\n -0.4947810, -0.2713831, 4.470e-05, 4.210e-06,\n -2.4132700, -0.0155730, 0.000e-00,\n 272.4101868, 15.0046053, 0.000e-00,\n 0.5442700, 0.0001051, -1.190e-05,\n -0.0018580, 0.0001046, -1.190e-05,\n 0.0046698, 0.0046466,\n// 1895 3 26\n2413278.923300, 10.0, -4.0, 4.0, -6.2, -6.2,\n -0.7271800, 0.4511697, 4.800e-05, -5.250e-06,\n 1.1480280, 0.2489810, -5.370e-05, -3.090e-06,\n 2.1835999, 0.0157410, -1.000e-06,\n 328.5476379, 15.0042896, 0.000e-00,\n 0.5655410, -0.0000852, -1.020e-05,\n 0.0193070, -0.0000848, -1.010e-05,\n 0.0046854, 0.0046621,\n// 1895 8 20\n2413426.048104, 13.0, -4.0, 4.0, -6.1, -6.1,\n 0.5169070, 0.5271188, -6.330e-05, -8.890e-06,\n 1.2946841, -0.2510795, -1.491e-04, 4.420e-06,\n 12.4420204, -0.0131560, -2.000e-06,\n 14.1857796, 15.0037422, 0.000e-00,\n 0.5315040, -0.0000128, -1.280e-05,\n -0.0145600, -0.0000127, -1.280e-05,\n 0.0046220, 0.0045989,\n// 1895 9 18\n2413455.363899, 21.0, -4.0, 4.0, -6.1, -6.1,\n -0.4187390, 0.5096700, 1.490e-05, -8.520e-06,\n -1.0789599, -0.2814748, 5.380e-05, 4.900e-06,\n 1.7247400, -0.0154910, -1.000e-06,\n 136.4962006, 15.0049067, 0.000e-00,\n 0.5337830, 0.0000289, -1.290e-05,\n -0.0122930, 0.0000288, -1.280e-05,\n 0.0046554, 0.0046322,\n// 1896 2 13\n2413603.182791, 16.0, -4.0, 4.0, -6.0, -6.0,\n 0.2130840, 0.4612570, -5.320e-05, -5.220e-06,\n -0.9184140, 0.2162812, 1.074e-04, -2.630e-06,\n -13.3614502, 0.0134910, 3.000e-06,\n 56.3936501, 15.0014324, 0.000e-00,\n 0.5711970, 0.0000696, -1.010e-05,\n 0.0249340, 0.0000692, -1.000e-05,\n 0.0047350, 0.0047114,\n// 1896 8 9\n2413780.714586, 5.0, -4.0, 4.0, -5.8, -5.8,\n 0.1970630, 0.5190105, -3.730e-05, -7.940e-06,\n 0.6732440, -0.2230061, -1.337e-04, 3.570e-06,\n 15.7336397, -0.0115690, -3.000e-06,\n 253.6848450, 15.0027647, 0.000e-00,\n 0.5391040, -0.0000972, -1.200e-05,\n -0.0069980, -0.0000967, -1.190e-05,\n 0.0046132, 0.0045902,\n// 1897 2 1\n2413957.343924, 20.0, -4.0, 4.0, -5.5, -5.5,\n -0.0543200, 0.4975594, -5.780e-05, -6.600e-06,\n -0.2279140, 0.2037676, 1.086e-04, -2.890e-06,\n -16.8407497, 0.0115510, 4.000e-06,\n 116.5213928, 15.0000200, 0.000e-00,\n 0.5580230, 0.0001245, -1.120e-05,\n 0.0118260, 0.0001239, -1.110e-05,\n 0.0047437, 0.0047201,\n// 1897 7 29\n2414135.164561, 16.0, -4.0, 4.0, -5.2, -5.2,\n 0.0030780, 0.4988819, -2.460e-05, -6.400e-06,\n -0.0693240, -0.1839646, -1.106e-04, 2.510e-06,\n 18.6043701, -0.0095700, -4.000e-06,\n 58.4454117, 15.0016136, 0.000e-00,\n 0.5535180, -0.0001127, -1.070e-05,\n 0.0073440, -0.0001121, -1.060e-05,\n 0.0046067, 0.0045837,\n// 1898 1 22\n2414311.804999, 7.0, -4.0, 4.0, -4.9, -4.9,\n -0.3359200, 0.5397963, -4.140e-05, -8.540e-06,\n 0.4223760, 0.1830896, 1.082e-04, -3.070e-06,\n -19.6515198, 0.0091300, 5.000e-06,\n 282.0413513, 14.9986410, 0.000e-00,\n 0.5436640, 0.0000957, -1.260e-05,\n -0.0024620, 0.0000952, -1.250e-05,\n 0.0047497, 0.0047260,\n// 1898 7 18\n2414489.317287, 20.0, -4.0, 4.0, -4.5, -4.5,\n -0.0549810, 0.4870131, -2.720e-05, -5.490e-06,\n -0.8750280, -0.1442076, -8.980e-05, 1.760e-06,\n 20.9359894, -0.0071230, -5.000e-06,\n 118.5001678, 15.0004854, 0.000e-00,\n 0.5644780, -0.0000491, -9.800e-06,\n 0.0182490, -0.0000488, -9.700e-06,\n 0.0046021, 0.0045791,\n// 1898 12 13\n2414636.998762, 12.0, -4.0, 4.0, -4.1, -4.1,\n 0.0649970, 0.5777186, -1.000e-07, -9.580e-06,\n -1.5239620, 0.0181431, 2.620e-04, -4.000e-07,\n -23.1797695, -0.0027390, 6.000e-06,\n 1.3833300, 14.9965868, 0.000e-00,\n 0.5404380, -0.0000603, -1.290e-05,\n -0.0056720, -0.0000600, -1.280e-05,\n 0.0047504, 0.0047267,\n// 1899 1 11\n2414666.443083, 23.0, -4.0, 4.0, -4.0, -4.0,\n -0.0844270, 0.5638495, -3.370e-05, -9.550e-06,\n 1.1723320, 0.1466527, 9.150e-05, -2.660e-06,\n -21.7256203, 0.0063260, 6.000e-06,\n 162.9145050, 14.9974327, 0.000e-00,\n 0.5383330, -0.0000181, -1.320e-05,\n -0.0077660, -0.0000180, -1.310e-05,\n 0.0047536, 0.0047299,\n// 1899 6 8\n2414813.773417, 7.0, -4.0, 4.0, -3.5, -3.5,\n 0.2297810, 0.5219483, -2.240e-05, -6.390e-06,\n 1.2086360, -0.0006785, -2.000e-04, 1.200e-07,\n 22.8365993, 0.0038020, -5.000e-06,\n 285.3164368, 14.9993849, 0.000e-00,\n 0.5582050, 0.0000863, -1.030e-05,\n 0.0120080, 0.0000859, -1.020e-05,\n 0.0046058, 0.0045829,\n// 1899 12 3\n2414991.539904, 1.0, -4.0, 4.0, -2.9, -2.9,\n -0.0164420, 0.5490307, 2.550e-05, -7.850e-06,\n -0.9062820, -0.0240451, 1.993e-04, 2.700e-07,\n -22.0569897, -0.0059480, 6.000e-06,\n 197.5598755, 14.9973602, 0.000e-00,\n 0.5526830, -0.0001192, -1.170e-05,\n 0.0065130, -0.0001186, -1.160e-05,\n 0.0047447, 0.0047211,\n// 1900 5 28\n2415168.120783, 15.0, -4.0, 4.0, -2.2, -2.2,\n 0.0280090, 0.5528179, -7.200e-06, -8.070e-06,\n 0.3972630, 0.0392476, -1.670e-04, -4.700e-07,\n 21.4537201, 0.0066390, -5.000e-06,\n 45.7447586, 15.0001631, 0.000e-00,\n 0.5437020, 0.0001120, -1.160e-05,\n -0.0024240, 0.0001114, -1.150e-05,\n 0.0046121, 0.0045891,\n// 1900 11 22\n2415345.805357, 7.0, -4.0, 4.0, -1.5, -1.5,\n -0.1946160, 0.5133811, 3.550e-05, -6.140e-06,\n -0.2033740, -0.0597809, 1.364e-04, 6.500e-07,\n -20.0626392, -0.0088990, 5.000e-06,\n 288.4667053, 14.9986048, 0.000e-00,\n 0.5676560, -0.0000826, -1.030e-05,\n 0.0214110, -0.0000822, -1.030e-05,\n 0.0047365, 0.0047129\n));\n}", "title": "" }, { "docid": "eb2afa47deb98311f996986c446816d3", "score": "0.5098608", "text": "function calc(data)\n{\nvar stringData=data.toString();\nvar rows= stringData.split('\\r\\n');\n\n\nvar header=rows[0].split(',');\n\nvar cnt_age,cnt_code,cnt_lit,cnt_total;\ncnt_area = header.indexOf('Area Name');\ncnt_age = header.indexOf('Age-group');\ncnt_lit = header.indexOf('Literate - Persons');\ncnt_total = header.indexOf('Total/ Rural/ Urban');\n\nvar final_obj={};\nfor (var i = 1; i < rows.length - 1; i++) {\n\n var line=rows[i].split(',');\n\n if(line[cnt_age]=!'0-6' && line[cnt_age] !='All ages' && line[cnt_total]=='Total' )\n {\n if(line[cnt_area]=='State - JAMMU & KASHMIR')\n {\n final_obj[header[cnt_age]]=line[cnt_age];\n final_obj[header[cnt_lit]]=line[cnt_lit];\n }\n }\n};\n\nreturn console.log(final_obj);\n}//function", "title": "" }, { "docid": "3bc2b2bd058fc9fced911a25cfadf3ad", "score": "0.50974715", "text": "function compile() {\r\n var sum = 0;\r\n var locationRow = document.getElementById('locations-and-data');\r\n var locationName = document.createElement('tr');\r\n locationName.textContent = this.loc;\r\n locationName.className = 'column1';\r\n\r\n // adds an array to the object with all numbers per hour\r\n for (var i = 6; i <= 20; i++) {\r\n var averageCookies = getAvrgCookies(this);\r\n sum += averageCookies;\r\n this.totalPerHour.push(averageCookies);\r\n var locationData = document.createElement('td');\r\n locationData.textContent = averageCookies;\r\n locationName.appendChild(locationData);\r\n locationRow.appendChild(locationName);\r\n }\r\n\r\n var showTotal = document.createElement('td');\r\n showTotal.textContent = sum;\r\n locationName.appendChild(showTotal);\r\n console.log(`${this.loc}'s total is ${sum}`);\r\n finalCompiler();\r\n}", "title": "" }, { "docid": "c444360069199c56f90a09bfd04e1bb2", "score": "0.5097344", "text": "function getFormula(tbValue) {\r\n var pattern = /[:|\\(|\\)]/;\r\n var ar = tbValue.split(pattern);\r\n var sum = ar[0].toUpperCase();\r\n\r\n if (ar.length < 3) {\r\n return null;\r\n }\r\n else if (sum !== \"=SUM\") {\r\n return null;\r\n }\r\n else {\r\n return ar;\r\n }\r\n}", "title": "" }, { "docid": "9327df4210c04462adf1aa722e2fae5a", "score": "0.5089265", "text": "function calResult() {\n\n if (expressionView.value.length == 1) return resultView.value;\n console.log(\"Now the arr is: \", exprArr);\n\n // Calculate bracket first\n var leftIndex = exprArr.lastIndexOf(\"(\");\n var rightIndex = exprArr.indexOf(\")\");\n while (leftIndex != -1 && rightIndex != -1) {\n calInsideBracket(leftIndex, rightIndex);\n leftIndex = exprArr.lastIndexOf(\"(\");\n rightIndex = exprArr.indexOf(\")\");\n }\n // console.log(\"Remove bracket to get: \", exprArr);\n\n // Calculate simple arr\n var result = calSimpleArr(exprArr);\n // console.log(result, \" calculated!\");\n\n return result;\n }", "title": "" }, { "docid": "cab62dadd3ed7565d991c6e7d56376df", "score": "0.5088605", "text": "function parse(formula){formula=formula.trim().toLowerCase();if(formula===\"even\"){return[2,0];}else if(formula===\"odd\"){return[2,1];}else{var parsed=formula.match(re_nthElement);if(!parsed){throw new SyntaxError(\"n-th rule couldn't be parsed ('\"+formula+\"')\");}var a;if(parsed[1]){a=parseInt(parsed[1],10);if(isNaN(a)){if(parsed[1].charAt(0)===\"-\")a=-1;else a=1;}}else a=0;return[a,parsed[3]?parseInt((parsed[2]||\"\")+parsed[3],10):0];}}", "title": "" }, { "docid": "b43e390d9fa363dd193b9575db7e13cb", "score": "0.5085316", "text": "function Calculator(id) {\n const OP_INDEX = 0;\n const DECICMAL_INDEX = 1;\n const HEXADECICMAL_INDEX = 2;\n const BINARY_INDEX = 3;\n const calc = document.getElementById('calculator');\n var storedOp = \"\";\n\n // The last row of the table always has input text, so you can edit the values.\n\n function finalize_numbers() {\n // Calculator will always have 1 initial row.\n // Insert second last row.\n let last_row = calc.rows[calc.rows.length-1];\n let save_row = calc.insertRow(calc.rows.length-1);\n\n // make 4 cells for the 3 representations to show and operation\n for (let i = 0; i < last_row.cells.length; i++) {\n let save_cell = save_row.insertCell();\n let input_cell = last_row.cells[i];\n if (input_cell.childElementCount === 0) {\n // tr > td > text\n save_cell.textContent = input_cell.textContent;\n input_cell.textContent = \"\";\n } else {\n // tr > td > input > value\n save_cell.textContent = input_cell.children[0].value;\n input_cell.children[0].value = \"\";\n }\n }\n }\n\n /// [1] => 1 => 1 => 1\n // + [ ] + [2] + 2\n // 3\n // + [ ]\n\n function set_last_row(i32, op) {\n let last_row = calc.rows[calc.rows.length-1];\n\n if (typeof(op) !== \"undefined\") {\n last_row.cells[OP_INDEX].textContent = op;\n }\n\n if (typeof(i32) === \"undefined\") {\n // Adding a new row to show operation, no numbers yet.\n return;\n }\n\n last_row.cells[DECICMAL_INDEX].children[0].value = i32.decimal;\n last_row.cells[HEXADECICMAL_INDEX].children[0].value = i32.hexadecimal;\n last_row.cells[BINARY_INDEX].children[0].value = i32.binary;\n }\n\n function performOperation(op, inputs) {\n if (inputs.length < 2) {\n throw 'List wrong size';\n }\n let lhs = inputs[inputs.length-2];\n let rhs = inputs[inputs.length-1];\n if (storedOp == '+') {\n console.log(`${lhs.asi32} + ${rhs.asi32}`);\n return Number32(lhs.asi32 + rhs.asi32);\n } else if (storedOp == '-') {\n console.log(`${lhs.asi32} - ${rhs.asi32}`);\n return Number32(lhs.asi32 - rhs.asi32);\n } else {\n throw `Unsupported operation ${storedOp}`;\n }\n }\n\n function storeOp(op) {\n storedOp = op;\n }\n\n\n return {\n finalize_numbers,\n set_last_row,\n performOperation,\n storeOp,\n }\n}", "title": "" }, { "docid": "47c84a487a2209347ca8d7ac032d1e55", "score": "0.50831175", "text": "function isolateNumber () {\n//there is a scenario where some entries in column are string number and other entries are already a number!\nfor (i =0;i <tableTitle.length;i++) {\nif(!isNaN(tableArray[i][totalFieldNameIndex])) {\n//this scenario won't happen here because function is only called if in last coloumn and it contains rowSumTxt\n\tstrippedOff = tableArray[i][totalFieldNameIndex];\n\t\n\t//alertxy(\"this entry is a number so we use it! strippedOff = \" + strippedOff);\n\n\t} else if (tableArray[i][totalFieldNameIndex] === undefined) {\n\t\tstrippedOff = 0;\n\t\n\t} else {\n\n//for (i =0;i <tableTitle.length;i++) {\n\tlet parseString = tableArray[i][totalFieldNameIndex];\n//TypeError: undefined is not an object (evaluating 'parseString.length')\n//?need to adjust tableArray[i][0].length for a load fronTableOptions db??\t\n//In simple contacts a space is added at end of tableArray[i][totalFieldNameIndex] that I don't think .length takes into account so maybe need to strip tableArray[i][totalFieldNameIndex] of spaces?\n//let trimElement = tableArray[i][0].trim();\n\nlet deleteCount = tableArray[i][0].length + 2 + sumRowTxt.length;\n//a main table and a new table have record field 0 formatted with spacing differently by 1 space - not sure why? Probably something to do with adding the #> to the first record field ? because to display the data in the td cell I added a space after #> ???.Should be able to use trim() to fix but so far not successful so line below is temporary fudged fix!\n//alertxy(\"loadFromTableOptions = \" + loadFromTableOptions);\n\nif(makeContactsTable || loadFromTableOptions) { \n\t deleteCount = tableArray[i][0].length + 1 + sumRowTxt.length;\n\t}//end if(makeContactsTable || loadFromTableOptions) { \n\t//let deleteCount = trimElement.length + 2 + sumRowTxt.length;\n\t\n\tlet start = deleteCount;\n\t\n\t//alertxy(\"tableArray[i][0] = \" + tableArray[i][0] + \" tableArray[i][0].length = \" + tableArray[i][0].length + \" deleteCount = \" + deleteCount);\n\t\n\t//alertxy(\"sumRowTxt = \" + sumRowTxt + \" sumRowTxt.length = \" + sumRowTxt.length);\n\t\n\t//alertxy(\"totalFieldNameIndex = \" + totalFieldNameIndex + \" tableArray[i][\" +totalFieldNameIndex +\"] = \" + tableArray[i][totalFieldNameIndex] + \" parseString = \" + parseString + \" start = \" + start);\n\t\n\tlet removeNumber = parseString.length - deleteCount;\n\t\n strippedOff = parseString.slice(start);\n \n//alertxy(\"After isolating number strippedOff = \" + strippedOff);\n\t\n\tif ( isNaN( Number(strippedOff) )) {\n \n\t\tif(calculationAlerts) {\n\t\talert(\"Addition column in record \" + (i+1) + \" contains a non number!\");\n\t\t}//end if(calculationAlerts) \n\t\t\n\t\t\n\t\ti++;\n\t\t//break;\n\t\tcontinue;//should this be here????\n\t\t}//end if ( isNaN( Number(tableArray[i][totalFieldNameIndex])) || Number(tableArray[i][totalFieldNameIndex]) === 0) {\n\t}//end if else\n\t\t\n\tfieldSUM = fieldSUM + Number(strippedOff);\n\t\n\t//alertxy(\"fieldSUM = \" + fieldSUM);\n\t//fieldSUM = fieldSUM.toFixed(2);\n\t//TypeError: fieldSUM.toFixed is not a function. (In 'fieldSUM.toFixed(2)', 'fieldSUM.toFixed' is undefined)\n\t//ReferenceError: Can't find variable: strippedOff\n}//end for loop\t\t\t\n}//end function isolateNumber", "title": "" }, { "docid": "44c8dca136f35c59a381e5152f3fcac7", "score": "0.5076371", "text": "function processData(input) {\n //Enter your code here\n input = input.split('\\n');\n var [rows, columns, product] = input[0].split(' ').map(Number);\n // console.log(\"rows, columns, product\", rows, columns, product);\n\n var matrix = [];\n\n for (var i = 1; i <= rows; i++) {\n matrix.push(input[i].split(' ').map(Number));\n }\n\n // console.log(\"matrix\", matrix);\n\n var count = 0;\n\n for (var i = 0; i < rows; i++) {\n for (var j = 0; j < columns; j++) {\n\n if (columns - j >= 3) {\n if (matrix[i][j] * matrix[i][j + 1] * matrix[i][j + 2] === product) {\n count = count + 1;\n }\n }\n\n if (rows - i >= 3) {\n if (matrix[i][j] * matrix[i + 1][j] * matrix[i + 2][j] === product) {\n count = count + 1;\n }\n }\n\n if (columns - j >= 3 && rows - i >= 3) {\n if (matrix[i][j] * matrix[i + 1][j + 1] * matrix[i + 2][j + 2] === product) {\n count = count + 1;\n }\n }\n\n if (columns - j >= 3 && i >= 3 - 1) {\n if (matrix[i][j] * matrix[i - 1][j + 1] * matrix[i - 2][j + 2] === product) {\n count = count + 1;\n }\n }\n }\n }\n\n console.log(count);\n\n}", "title": "" }, { "docid": "454d092e8bbff862b0889f454d5bb753", "score": "0.50724494", "text": "function calcRow(row){\n\n //Variables containing numeric values from the travel, lodge, and meal row elements\n var travel = parseFloat(document.forms[0].elements[\"travel\" + row].value);\n var lodge = parseFloat(document.forms[0].elements[\"lodge\" + row].value);\n var meal = parseFloat(document.forms[0].elements[\"meal\" + row].value);\n\n return travel + lodge + meal;\n}", "title": "" }, { "docid": "05997b0860e6227a3b24b95d3c6696fb", "score": "0.5070707", "text": "function EstimateTableUnits(){\r\n\tconst tables = document.querySelectorAll('table');\r\n\r\n\t//for each table...\r\n\tfor(let index=0; index < tables.length; index++){\r\n\t\t//make sure the table doesn't have lab-values in it\r\n\t\tif (tables[index].id.toLowerCase().includes(\"lab-values\")){\r\n\t\t\tcontinue;\r\n\t\t}\r\n\r\n\t\t//iterate over every row in the table\r\n\t\tfor( let i = 0, row; row = tables[index].rows[i]; i++ ){\r\n\t\t\tlet category = \"\";\r\n\r\n\t\t\t//handling those one-value rows\r\n\t\t\tif(row.cells.length === 1){\r\n\t\t\t\tcategory = row.cells[0];\r\n\t\t\t\tcontinue;\r\n\t\t\t}\r\n\r\n\t\t\t//get a sample of the values here\r\n\t\t\tif(row.cells.length === 2 && row.cells[1].innerText !== \"\"){\r\n\r\n\t\t\t\tlet matches = findPotentialKeys(row.cells[0].innerText, data_keys);\r\n\r\n\t\t\t\t//no changes to be made, carry on\r\n\t\t\t\tif(matches.length === 0){\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\r\n\t\t\t\tlet output = RU_to_SI_Parser(data[\"data\"], matches, row.cells[1].innerText.toLowerCase());\r\n\r\n\t\t\t\t//if our output is empty for whever reason, continue\r\n\t\t\t\tif(output === \"\"){\r\n\t\t\t\t\tcontinue;\r\n\t\t\t\t}\r\n\r\n\t\t\t\t//console.log(output);\r\n\r\n\t\t\t\trow.cells[1].innerHTML = row.cells[1].innerHTML + \"<span class=\\\"unit-est\\\" style= \\\"background-color:\" + highlight_col + \";\\\"> ( ~\"+ output + \" )\" + \"</span>\"\r\n\t\t\t}\r\n\r\n\t\t}\r\n\t}\r\n}", "title": "" }, { "docid": "40f8fab71b05cc31826dc04f9171636d", "score": "0.50695556", "text": "function calculadorAreasGetResult(index){\n var count = index;\n var $txtInstallationTypeVal = $('#txtInstallationType_' + count).val();\n var $numHeightVal = Number($('#numHeight_' + count).val());\n var $numWidthVal = Number($('#numWidth_' + count).val());\n var $numEqualInstallationsVal = Number($('#numEqualInstallations_' + count).val());\n var $numExtraTubosVal = Number($('#numExtraTubos_' + count).val());\n\n $('#lblReqInstallationType_' + count).css('display', 'none');\n $('#lblReqNumHeight_' + count).css('display', 'none');\n $('#lblReqNumWidth_' + count).css('display', 'none');\n $('#lblReqNumEqualInstallations_' + count).css('display', 'none');\n $('#lblReqNumExtraTubos_' + count).css('display', 'none');\n\n if($txtInstallationTypeVal.trim() == \"\") {\n $('#lblReqInstallationType_' + count).css('display', 'inline-block');\n }\n if($numHeightVal <= 0) {\n $('#lblReqNumHeight_' + count).css('display', 'inline-block');\n } \n if($numWidthVal <= 0) {\n $('#lblReqNumWidth_' + count).css('display', 'inline-block');\n } \n if($numEqualInstallationsVal <= 0) {\n $('#lblReqNumEqualInstallations_' + count).css('display', 'inline-block');\n } \n if($numExtraTubosVal <= 0) {\n $('#lblReqNumExtraTubos_' + count).css('display', 'inline-block');\n }\n\n if($txtInstallationTypeVal.trim() != \"\" && $numHeightVal > 0 && $numWidthVal > 0 && $numEqualInstallationsVal > 0 && $numExtraTubosVal > 0) {\n \n var auxPer = $numExtraTubosVal / Number(100);\n \n var result = ($numHeightVal*$numWidthVal*$numEqualInstallationsVal) + (($numHeightVal*$numWidthVal*$numEqualInstallationsVal)*auxPer);\n \n var _modifiedTr = '';\n\n _modifiedTr = '<td>'\n + '<label id=\"lblInstallationType_' + count + '\">' + $txtInstallationTypeVal + '</label>'\n + '</td>'\n + '<td>'\n + '<label id=\"lblHeight_' + count + '\">' + $numHeightVal + '</label>'\n + '</td>'\n + '<td>'\n + '<label id=\"lblWidth_' + count + '\">' + $numWidthVal + '</label>'\n + '</td>'\n + '<td>'\n + '<label id=\"lblEqualInstallations_' + count + '\">' + $numEqualInstallationsVal + '</label>'\n + '</td>'\n + '<td>'\n + '<label id=\"lblExtraTubos_' + count + '\">' + $numExtraTubosVal + '</label>'\n + '</td>'\n + '<td>'\n + '<label>' + result + '</label>'\n + '</td>'\n + '<td>'\n + '<div data-role=\"controlgroup\" data-type=\"horizontal\" data-mini=\"true\">'\n + '<a href=\"#\" class=\"ui-btn ui-shadow ui-corner-all ui-icon-edit ui-btn-icon-notext\" onclick=\"calculadorAreasModifyResult(' + count + ')\">Edit</a>'\n + '<a href=\"#\" class=\"ui-btn ui-shadow ui-corner-all ui-icon-delete ui-btn-icon-notext\" onclick=\"calculadorAreasDeleteResult(' + count + ')\">Delete</a>'\n + '</div>'\n + '</td>'\n\n $('#resultRow_' + count).html(_modifiedTr);\n \n count = count + 1;\n\n var _newTr = '<tr id=\"resultRow_' + count + '\">'\n + '<td>'\n + '<div class=\"divInternalForInputs\">'\n + '<input data-clear-btn=\"true\" required=\"true\" name=\"txtInstallationType\" id=\"txtInstallationType_' + count + '\" value=\"\" type=\"text\">'\n + '<span class=\"lblReqInstallationType\" id=\"lblReqInstallationType_' + count + '\">*</span>'\n + '</div>'\n + '</td>'\n + '<td>'\n + '<div class=\"divInternalForInputs\">'\n + '<input data-wrapper-class=\"numHeight\" data-clear-btn=\"true\" required=\"true\" name=\"numHeight\" id=\"numHeight_' + count + '\" type=\"number\" step=\"0.1\">'\n + '<span class=\"lblReqNumHeight\" id=\"lblReqNumHeight_' + count + '\">*</span>'\n + '</div>'\n + '</td>'\n + '<td>'\n + '<div class=\"divInternalForInputs\">'\n + '<input data-wrapper-class=\"numWidth\" data-clear-btn=\"true\" required=\"true\" name=\"numWidth\" id=\"numWidth_' + count + '\" type=\"number\" step=\"0.1\">'\n + '<span class=\"lblReqNumWidth\" id=\"lblReqNumWidth_' + count + '\">*</span>'\n + '</div>'\n + '</td>'\n + '<td>'\n + '<div class=\"divInternalForInputs\">'\n + '<input data-wrapper-class=\"numEqualInstallations\" data-clear-btn=\"true\" required=\"true\" name=\"numEqualInstallations\" id=\"numEqualInstallations_' + count + '\" type=\"number\">'\n + '<span class=\"lblReqNumEqualInstallations\" id=\"lblReqNumEqualInstallations_' + count + '\">*</span>'\n + '</div>'\n + '</td>'\n + '<td>'\n + '<div class=\"divInternalForInputs\">'\n + '<input data-wrapper-class=\"numExtraTubos\" data-clear-btn=\"true\" required=\"true\" name=\"numExtraTubos\" id=\"numExtraTubos_' + count + '\" type=\"number\">'\n + '<span class=\"lblReqNumExtraTubos\" id=\"lblReqNumExtraTubos_' + count + '\">*</span>'\n + '</div>'\n + '</td>'\n + '<td><label></label></td>'\n + '<td>'\n + '<div data-role=\"controlgroup\" data-type=\"horizontal\" data-mini=\"true\">'\n + '<a href=\"#\" class=\"ui-btn ui-shadow ui-corner-all ui-icon-plus ui-btn-icon-notext\" onclick=\"calculadorAreasGetResult(' + count + ')\">Add</a>'\n + '</div>'\n + '</td>'\n + '</tr>';\n \n //$('#resultsTable').append(_newTr);\n $('#resultsTable').append(_newTr).enhanceWithin();\n }\n}", "title": "" }, { "docid": "b1a6a2cc2aa0e92c36219f08871b41d5", "score": "0.50685877", "text": "function tablegenerate (arreglo,temperatureArray, pamArray, fcArray, frArray, o2Array, phArray, naArray, kArray, crArray, hctoArray, leucArray, glasgowArray, arreglo_score) {\r\n for(i=0; i<arreglo.length;i++)\r\n {\r\n var $formrow = '<tr><td>'+arreglo[i]+'</td><td class=\"variable\">'+temperatureArray[i]+'</td><td class=\"variable\">'+pamArray[i]+'</td><td class=\"variable\">'+fcArray[i]+'</td><td class=\"variable\">'+frArray[i]+'</td><td class=\"variable\">'+o2Array[i]+'</td><td class=\"variable\">'+phArray[i]+'</td><td class=\"variable\">'+naArray[i]+'</td><td class=\"variable\">'+kArray[i]+'</td><td class=\"variable\">'+crArray[i]+'</td><td class=\"variable\">'+hctoArray[i]+'</td><td class=\"variable\">'+leucArray[i]+'</td><td class=\"variable\">'+glasgowArray[i]+'</td><td>'+arreglo_score[i]+'</td><td class=\"variableMortalidad\">'+scoreMortalidad[i]+'</td></tr>';\r\n $('.myTable').append($formrow);\r\n }\r\n}", "title": "" }, { "docid": "1e73bf2c03bdbcce332f85e7d2e07c71", "score": "0.5050455", "text": "function createCells(){\n\t\tvar opt = ret.options;\n\t\tvar def = opt.def;\n\t\tvar table = \"\", row = \"\";\n\t\tfor(var r=0;r<def.rows.length;r++){\n\t\t\trow = \"\";\n\t\t\tfor(var c=0;c<def.cols.length;c++){\n\t\t\t\tvar cell = {}; //should force new variable on each loop\n\t\t\t\tcell.ref = def.name + \"_r\" + r + \"c\" + c; //to be used for binding\n\t\t\t\tcell.css = def.cols[c].css || opt.cell.css || opt.css.cell;\n\t\t\t\tcell.value = \"\"; //Default to blank\n\n\t\t\t\tif(c===0){ //reserved for row headings\n\t\t\t\t\tcell.value = def.rows[r].display;\n\t\t\t\t}\n\t\t\t\telse if(r===0){ //reserved for column headings\n\t\t\t\t\tcell.value = def.cols[c].display;\n\t\t\t\t\tcell.css = def.cols[0].css; //override\n\t\t\t\t\tcell.css += \" header\";\n\t\t\t\t}\n\t\t\t\telse if(def.rows[r].css===\"blank\" || def.cols[c].css===\"blank\"){\n\t\t\t\t\tcell.css=\"blank\";\n\t\t\t\t\tcell.value=\" \";\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tcell.key = {};\n\t\t\t\t\t$.extend(cell.key, def.key, def.rows[r].key, def.cols[c].key); //used to query datasource\n\t\t\t\t\tcell.formula = def.cols[c].type; //should there be a recalc aspect - can we get data at this point?\n\t\t\t\t\tcell.index = def.cols[c].index || def.rows[r].index || opt[cell.css].index;\n\t\t\t\t\tcell.type = def.cols[c].type || def.rows[r].type || opt[cell.css].type;\n\t\t\t\t\tcell.format = def.cols[c].format || def.rows[r].format || opt[cell.css].format;\n\t\t\t\t\tcell.chartType = def.cols[c].chartType || def.rows[r].chartType || opt[cell.css].chartType;\n\t\t\t\t\tcell.series = cellSeries; //see below - could be anonymous\n\t\t\t\t}\n\t\t\t\trow = row += \"<td id='\" + cell.ref + \"' class='\"+ cell.css + \"'>\" + cell.value + \"</td>\";\n\t\t\t\tret.cells.push(cell); //might push to linear and 2d array\n\t\t\t\tret.cellsByRef[cell.ref]=cell;\n\t\t\t}\n\t\t\ttable += \"<tr id='r\" + r + \"' class='\" + opt.css.row + \"'>\" + row + \"</tr>\";\n\t\t}\n\t\tret.table = \"<table id='\" + def.name + \"' class='\" + opt.css.table + \"'>\" + table + \"</table>\"\n\t\t//Populate table\n\t\t$('#'+def.container).html(ret.table);\n\t\t//Handlers\n\t\tvar hdl = def.eventHandlers;\n\t\tif(hdl){\n\t\t\tfor(k in hdl){\n\t\t\t\tfor(l in hdl[k]){\n\t\t\t\t\td3.selectAll('#'+def.name+' '+k)\n\t\t\t\t\t\t.on(l,hdl[k][l])\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "c3345a5d60d52dbc19e10a9a72e539d7", "score": "0.50466025", "text": "function prepareLoanRepaymentTable() {\n\n var amt = parseInt($('.calc-homeloan-repayment .principal-amount').val().replace(/,/g, ''), 10)\n var loanTenure = $('.calc-homeloan-repayment .loan-tenure').val()\n var rate = $('.calc-homeloan-repayment .interest-yr1').val()\n var month = 1\n\n // Write Data\n var amtSeparated = amt.toLocaleString().split('.')[0]\n // toolsSetCalculatedValue('.calc-homeloan-repayment .loan-amt', parseFloat(amtSeparated).toFixed(0))\n\n toolsSetCalculatedValue('.calc-homeloan-repayment .loan-amt', (amtSeparated).toLocaleString().split('.')[0])\n\n // .toLocaleString().split('.')[0]\n\n // For every month, generate a row of data\n // First row\n var outstandingPrincipal = amt\n var monthlyInstallment = (getMonthlyInstallment(outstandingPrincipal, rate, 0))\n var paymentInterest = (amt * rate / 100 / 12)\n // var paymentInterest = (round_number((amt*rate/100/12), 2)).toFixed(2);\n var paymentPrincipal = (monthlyInstallment - paymentInterest)\n var endPrincipal = (outstandingPrincipal - paymentPrincipal)\n\n var rowData = \"<tr><td>\" + month + \"</td><td>\" + rate + \"</td><td>\" + outstandingPrincipal + \"</td><td>\" + monthlyInstallment + \"</td><td>\" + paymentInterest + \"</td><td>\" + paymentPrincipal + \"</td><td>\" + endPrincipal + \"</td><td></td><td></td><td></td></tr>\"\n\n $(\".loandata\").append(rowData);\n\n // Second Row onwards\n for (i = 2; i <= loanTenure * 12; i++) {\n var outstandingPrincipal = endPrincipal\n var paymentInterest = (outstandingPrincipal * rate / 100 / 12)\n // var paymentInterestRound = (round_number(paymentInterest, 2)).toFixed(2);\n var paymentPrincipal = (monthlyInstallment - paymentInterest)\n var endPrincipal = (outstandingPrincipal - paymentPrincipal)\n // var endPrincipalRound = (round_number(endPrincipal, 2)).toFixed(2);\n var rowData = \"<tr><td>\" + i + \"</td><td>\" + rate + \"</td><td>\" + outstandingPrincipal + \"</td><td>\" + monthlyInstallment + \"</td><td>\" + paymentInterest + \"</td><td>\" + paymentPrincipal + \"</td><td>\" + endPrincipal + \"</td><td></td><td></td><td></td></tr>\"\n\n if (i == 12) {\n // var rate = 3.5;\n var rate = $('.calc-homeloan-repayment .interest-yr2').val()\n var outstandingPrincipal = endPrincipal\n var monthlyInstallment = (getMonthlyInstallment(outstandingPrincipal, rate, i))\n var paymentInterest = (amt * rate / 100 / 12)\n var paymentPrincipal = (monthlyInstallment - paymentInterest)\n } else if (i == 24) {\n // var rate = 3.75;\n var rate = $('.calc-homeloan-repayment .interest-yr3').val()\n var outstandingPrincipal = endPrincipal\n var monthlyInstallment = (getMonthlyInstallment(outstandingPrincipal, rate, i))\n } else if (i == 36) {\n // var rate = 3.75;\n var rate = $('.calc-homeloan-repayment .interest-yr4').val()\n var outstandingPrincipal = endPrincipal\n var monthlyInstallment = (getMonthlyInstallment(outstandingPrincipal, rate, i))\n } else if (i == 48) {\n // var rate = 3.75;\n var rate = $('.calc-homeloan-repayment .interest-yr5').val()\n var outstandingPrincipal = endPrincipal\n var monthlyInstallment = (getMonthlyInstallment(outstandingPrincipal, rate, i))\n }\n $(\".loandata\").append(rowData);\n }\n\n}", "title": "" }, { "docid": "8608d224ba186eb001c3b18ce9ae8aef", "score": "0.5046581", "text": "function display(obj, sum){\r\n\t//var desc = document.getElementById('description')\r\n\tvar tb = document.createElement('table')\r\n\tvar tr = document.createElement('tr')\r\n\tvar th1 = document.createElement('th')\r\n\tvar th2 = document.createElement('th')\r\n\tvar th3 = document.createElement('th')\r\n\tvar th4 = document.createElement('th')\r\n\tvar th5 = document.createElement('th')\r\n\tth1.innerHTML = 'Element'\r\n\tth2.innerHTML = 'Name'\r\n\tth3.innerHTML = 'Atomic Mass'\r\n\tth4.innerHTML = 'Multiplier'\r\n\tth5.innerHTML = 'Total Mass'\r\n\ttr.appendChild(th1)\r\n\ttr.appendChild(th2)\r\n\ttr.appendChild(th3)\r\n\ttr.appendChild(th4)\r\n\ttr.appendChild(th5)\r\n\ttb.appendChild(tr)\r\n\r\n\tfor(var i =0; i<obj.length; i++){\r\n\t\tif(!obj[i].group){\r\n\t\t\tvar tr1 = document.createElement('tr')\r\n\t\t\tvar td1 = document.createElement('td')\r\n\t\t\tvar td2 = document.createElement('td')\r\n\t\t\tvar td3 = document.createElement('td')\r\n\t\t\tvar td4 = document.createElement('td')\r\n\t\t\tvar td5 = document.createElement('td')\r\n\t\t\t//var td = document.createElement('td')\r\n\t\t\ttd1.innerHTML = obj[i].symbol\r\n\t\t\ttd2.innerHTML = obj[i].name\r\n\t\t\ttd3.innerHTML = parseFloat(obj[i].atomicMass).toFixed(3)\r\n\t\t\ttd4.innerHTML = obj[i].multiplier\r\n\t\t\ttd5.innerHTML = (parseFloat(obj[i].atomicMass)* parseFloat(obj[i].multiplier)).toFixed(3)\r\n\t\t\ttr1.appendChild(td1)\r\n\t\t\ttr1.appendChild(td2)\r\n\t\t\ttr1.appendChild(td3)\r\n\t\t\ttr1.appendChild(td4)\r\n\t\t\ttr1.appendChild(td5)\r\n\t\t\ttb.appendChild(tr1)\r\n\t\t}\r\n\t}\r\n\t//create the last row\r\n\tvar tr2 = document.createElement('tr')\r\n\tvar td6 = document.createElement('td')\r\n\t//td6.setAttribute('id','last_row')\r\n\ttd6.colSpan = 4\r\n\tvar td7 = document.createElement('td')\r\n\ttd6.innerHTML = 'Total Atomic Mass'\r\n\ttd7.innerHTML = sum.toFixed(3)\r\n\ttr2.appendChild(td6)\r\n\ttr2.appendChild(td7)\r\n\ttb.appendChild(tr2)\r\n\tdescription.appendChild(tb)\r\n\r\n}", "title": "" }, { "docid": "b76ed27c27f520d9848094aa518c21d6", "score": "0.50425875", "text": "function calculate_area(row) {\n var lenFt = parseInt(row.closest('tr').find(\"input.lenFt\").val());\n var lenIn = parseFloat(row.closest('tr').find(\"input.lenIn\").val() / 12);\n var widFt = parseFloat(row.closest('tr').find(\"input.widFt\").val());\n var widIn = parseFloat(row.closest('tr').find(\"input.widIn\").val() / 12);\n\n //Try lenFt or if its nan change it to zero then add to lenIn\n //Then round it to two digits\n var totLen = (lenFt || 0) + lenIn;\n totLen = Math.round(totLen * 100) / 100;\n\n var totWid = (widFt || 0) + widIn;\n totWid = Math.round(totWid * 100) / 100;\n\n //Find square footage and then round, if other values haven't been entered\n //Use one in the meantime\n var sqFootage = Math.round(((totLen || 1) * (totWid || 1)) * 100) / 100;\n if (totLen === 0 & totWid === 0) {\n sqFootage = 0;\n }\n\n //If the value is still 0 after the previous calculations it means\n //that square footage must have already been calculated\n //So just get that value and return it\n if (sqFootage === 0) {\n sqFootage = row.closest('tr').find('.sqFt').val();\n }\n return sqFootage;\n}", "title": "" }, { "docid": "445823fcc7ba395dbf433229823bc23f", "score": "0.5034016", "text": "function createMatrix() {\r\n //VIIDE: https://developer.mozilla.org/en-US/docs/Web/API/Document_Object_Model/Traversing_an_HTML_table_with_JavaScript_and_DOM_Interfaces\r\n var matrixFirstContainer = document.getElementById(\"matrixFirstContainer\");\r\n var matrixFirst = document.getElementById(\"matrixFirst\");\r\n var tableBody = document.createElement(\"tbody\");\r\n\r\n for (var i = 0; i < mFirstX; i++) {\r\n var row = document.createElement(\"tr\");\r\n\r\n for (var j = 0; j < mFirstY; j++) {\r\n var rowId = i + 1;\r\n var colId = j + 1;\r\n var cell = document.createElement(\"input\");\r\n cell.setAttribute(\"id\", \"a\" + rowId + colId);\r\n cell.setAttribute(\"type\", \"text\");\r\n cell.setAttribute(\"onkeypress\", \"validate(event)\");\r\n cell.setAttribute(\"oninput\", \"checkInputSequence()\");\r\n cell.setAttribute(\"maxlength\", \"10\");\r\n row.appendChild(cell);\r\n }\r\n tableBody.appendChild(row);\r\n }\r\n matrixFirst.appendChild(tableBody);\r\n\r\n var matrixSecondContainer = document.getElementById(\"matrixSecondContainer\");\r\n var matrixSecond = document.getElementById(\"matrixSecond\");\r\n var tableBody = document.createElement(\"tbody\");\r\n\r\n for (var i = 0; i < mSecondX; i++) {\r\n var row = document.createElement(\"tr\");\r\n\r\n for (var j = 0; j < mSecondY; j++) {\r\n var rowId = i + 1;\r\n var colId = j + 1;\r\n var cell = document.createElement(\"input\");\r\n cell.setAttribute(\"id\", \"b\" + rowId + colId);\r\n cell.setAttribute(\"type\", \"text\");\r\n cell.setAttribute(\"onkeypress\", \"validate(event)\");\r\n cell.setAttribute(\"oninput\", \"checkInputSequence()\");\r\n cell.setAttribute(\"maxlength\", \"10\");\r\n row.appendChild(cell);\r\n }\r\n tableBody.appendChild(row);\r\n }\r\n matrixSecond.appendChild(tableBody);\r\n}", "title": "" }, { "docid": "2e7bbe925c42031c4f51a40bd4823178", "score": "0.5028369", "text": "function Calculate() {\n const form = document.getElementById(\"calculator\"),\n container = document.getElementById('container'),\n findInputs = form.querySelectorAll(\"input\"),\n first = Math.floor(findInputs[0].value),\n second = Math.floor(findInputs[1].value),\n third = Math.floor(findInputs[2].value),\n fourth = Math.floor(findInputs[3].value),\n fifth = Math.floor(findInputs[4].value);\n\n\n // https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Array/filter\n const array = new Array;\n\n array.push(first, second, third, fourth, fifth);\n\n const greaterThan = array.filter(array => array > 0).length,\n lessThan = array.filter(array => array < 0).length,\n equalToZero = array.filter(array => array == 0).length;\n\n // Template Strings\n const result = `\n <table class=\"calculation-table\">\n <tr>\n <td>Negative</td>\n <td></td>\n <td>${lessThan}</td>\n </tr>\n <tr>\n <td>Positive</td>\n <td></td>\n <td>${greaterThan}</td>\n </tr>\n <tr>\n <td>Zeros</td>\n <td></td>\n <td>${equalToZero}</td>\n </tr>\n </table>\n `;\n\n container.insertAdjacentHTML('afterend', result)\n}", "title": "" }, { "docid": "2e8767ec8146a978f56fe0e449b27ade", "score": "0.50273716", "text": "function get_matrix_from_dom() {\n var matrix = {}\n $('.scratch text').each(function() {\n var value = parseInt($(this).text())\n var cell = parseInt($(this).parent('g').attr('data-cell'))\n matrix[value] = cell\n })\n return matrix\n }", "title": "" }, { "docid": "87b52b3dce814c0ce5d46be3a21b99a0", "score": "0.50267977", "text": "function fillTableDetalle(rows)\n{ \n let content= '';\n let label = '';\n let totalVenta = 0;\n rows.forEach(function(row){ \n var subtotal=parseFloat(row.Total).toFixed(2);\n console.log(subtotal); \n content +=`\n <tr>\n <td>${row.idDetalle}</td>\n <td>${row.nombre}</td>\n <td>${row.cantidad}</td>\n <td>${row.precio}</td>\n <td>${subtotal}</td> \n </tr>\n `;\n totalVenta= parseFloat(subtotal)+ parseFloat(totalVenta);\n \n });\n label = `<h5 id=\"labelTotal\">Total: $${parseFloat(totalVenta).toFixed(2)}</h5>`; \n $('#detalle').html(content);\n $('#total').html(label); \n console.log(totalVenta);\n\n}", "title": "" }, { "docid": "e04c69564dd568e1ee07dabeb1b9bae9", "score": "0.502624", "text": "function createTableBody(location, inputArray, totals) {\n var trEl = document.createElement('tr'); \n var tdEl = document.createElement('td'); \n\n // add the first cell (location name)\n tdEl.textContent = location;\n trEl.appendChild(tdEl);\n tableEl.appendChild(trEl); \n\n for (var i = 0; i < inputArray.length; i++) {\n var tdEl = document.createElement('td'); \n tdEl.textContent = inputArray[i];\n trEl.appendChild(tdEl);\n tableEl.appendChild(trEl); \n }\n\n // add last cell (the totals)\n var tdEl = document.createElement('td'); \n tdEl.textContent = totals;\n trEl.appendChild(tdEl);\n tableEl.appendChild(trEl); \n}", "title": "" }, { "docid": "71927784178aaa1715779d6b965ba18e", "score": "0.5018909", "text": "function getdataforcolrows() {\n var cols = $(\"#col\").val();\n var rows = $(\"#rows\").val();\n var colstart = $(\"#colstart\").val();\n var rowstart = $(\"#rowstart\").val();\n console.log(\"rows\", rows)\n console.log(\"cols\", cols)\n console.log(\"colstart\", colstart)\n console.log(\"rowstart\", rowstart)\n var tr = '';\n var table = \"\";\n var ab = 0;\n var cd = 0;\n\n //Creating the rows and columns according to userinput\n\n if (!isNaN(parseInt(cols)) && cols < 1000 && !isNaN(parseInt(rows)) && rows < 1000 && !isNaN(parseInt(colstart)) && !isNaN(parseInt(rowstart))) {\n if ( cols < 1000 && rows < 1000 ) {\n $(\"#tabled\").html('');\n var flag = false;\n var colflag = false;\n var hideflag = false;\n for (var i = 0; i < rows; i++) {\n table += '<tr>';\n var rowcount = i + parseInt(rowstart);\n if (flag == true) {\n table += '<td style=\"border: 1px solid #dddddd;text-align: left;padding: 8px;background-color: black;color: white;\">' + rowcount + '</td>';\n }\n else\n table += '<td style=\"color:white;\">' + i + '</td>';\n\n for (var j = 0; j < cols; j++) {\n var jcol = j + parseInt(colstart);\n if (hideflag == false) {\n if (j == 0 && colflag == false) {\n //table+='<td style=\"border: 1px solid #dddddd;text-align: left;padding: 8px;color:white\">'+jcol+'</td>';\n\n table += '<td style=\"border: 1px solid #dddddd;text-align: left;padding: 8px;background-color: black;color: white;\">' + jcol + '</td>';\n flag = true;\n colflag = true;\n i = -1;\n }\n else\n table += '<td style=\"border: 1px solid #dddddd;text-align: left;padding: 8px;background-color: black;color: white;\">' + jcol + '</td>';\n }\n else {\n var tmp = (j + parseInt(colstart)) * (i + parseInt(rowstart));\n console.log(tmp)\n table += '<td style=\"border: 1px solid #dddddd;text-align: left;padding: 8px;color:black\">' + tmp + '</td>';\n }\n\n }\n hideflag = true;\n table += '</tr>';\n\n }\n\n $(\"#tabled\").append(table);\n }\n else {\n\n $(\"#tabled\").html('');\n var table = '<tr><td>Please enter numeric value.</td></tr>';\n\n $(\"#tabled\").append(table);\n }\n\n}\n else {\n\n $(\"#tabled\").html('');\n var table = '<tr><td>Please enter value less than 1000 value.</td></tr>';\n\n $(\"#tabled\").append(table);\n }\n\n}", "title": "" }, { "docid": "cb4e60eac48e129a2f5ef73364f274a6", "score": "0.5018656", "text": "function Pivot(rawData,columnX,columnY_List,sortX_Asc,sortY_Asc,isTotalLeft,Calfunc,CalCol)\n{\n//convert json to Array: [0] is the column array, from [1] is the data -result is the converted data array\n\n//column list of rawData\nvar columns = Object.keys(rawData[0]);\n// final table\nvar Result=[];\n//distinct X axis values\nlet X_axis_values=[];\n\n//key-value pair of Y axis\n//key is column name\n//value is distinct column value\nlet Y_axis_Pairs=[];\n\n//converted data\nlet data = rawData.map(function(obj) {\nreturn columns.map(function(key) {\n return obj[key];\n});\n});\ndata.unshift(columns);\n\n//fill X_axis_values\nlet columnXValue = [];\ndata.forEach(x => {if(data.indexOf(x)!=0) {columnXValue.push(x[columns.indexOf(columnX)])}});\ncolumnXValue = SortDistinctValue(sortX_Asc,columnXValue);\n\n//fill Y_axis_Pairs\nfor(let y=0; y<columnY_List.length; y++)\n{\nlet _columnName=columnY_List[y];\n\nlet _columnValue=(function()\n{ \n let _index=columns.indexOf(_columnName);\n let columnvalue=[];\n data.forEach(x=> {if(data.indexOf(x)!=0) {columnvalue.push(x[_index])}})\n \n return SortDistinctValue(sortY_Asc,columnvalue);\n})(); \nlet pair={columnName:_columnName,columnValues:_columnValue};\nY_axis_Pairs.push(pair);\n}\n//add first row - Columns\nlet FirstRow = [];\ncolumnY_List.forEach(x => {FirstRow.push(x);})\ncolumnXValue.forEach(x => {FirstRow.push(x);})\n\nisTotalLeft? FirstRow.splice(columnY_List.length,0,\"Total\") : FirstRow.push(\"Total\");\n\nResult.push(FirstRow);\n\n//add value rows\n//set the y-axis pivot values\nlet pivot_list=Axis_Value_List(Y_axis_Pairs,0); \n\n//add cell values then add rows\nfor(let i = 0; i < pivot_list.length; i++)\n{\nlet CellRow=[];\nlet TotalCell=0;//the total cell value\n\n//push axis values\nfor(let j = 0; j < pivot_list[i].length; j++)\n{\n CellRow.push(pivot_list[i][j]);\n}\n\n//push cell value \nfor(let k = 0; k < columnXValue.length; k++)\n{\n let filter=[] //key is column name (index), value is column value\n //y-axis filters\n for(let l=0;l< columnY_List.length;l++)\n {\n filter.push({[`${columnY_List[l]}`] : pivot_list[i][l]});\n }\n //x-axis filter\n filter.push({[`${columnX}`] : columnXValue[k]});\n \n let rows = rawData.filter(function(row)\n {\n for(let m=0; m < filter.length; m++)\n { \n if(row[Object.keys(filter[m])[0]] === undefined || Object.values(filter[m])[0] != row[Object.keys(filter[m])[0]])\n {return false;}\n } \n return true;\n });\n\n //calculate these rows if they exist\n let Cal_result= \"-\"\n if(rows.length > 0)\n {\n switch(Calfunc)\n {\n /* \n Cal Func Code: \n 0. Count\n 1. Sum\n 2. Avg\n 3. Max\n 4. Min\n */\n case 0:\n Cal_result = rows.length;\n TotalCell +=Cal_result;\n break;\n case 1:\n if(CalCol != \"\" && CalCol != undefined)\n {\n Cal_result = rows.sum(CalCol);\n TotalCell +=Cal_result;\n }\n break;\n case 2:\n if(CalCol != \"\" && CalCol != undefined)\n {\n Cal_result = rows.avg(CalCol);\n }\n break;\n case 3:\n if(CalCol != \"\" && CalCol != undefined)\n {\n Cal_result = Math.max.apply(Math,rows.map(function(o){ return o[CalCol];}))\n }\n break;\n case 4:\n if(CalCol != \"\" && CalCol != undefined)\n {\n Cal_result = Math.min.apply(Math,rows.map(function(o){ return o[CalCol];}))\n }\n break;\n }\n } \n CellRow.push(Cal_result);\n}\n//push total value to the row base on where the total will be\nisTotalLeft? CellRow.splice(pivot_list[0].length,0,TotalCell) : CellRow.push(TotalCell);\n//CellRow.splice((isTotalLeft ? pivot_list[0].length : (pivot_list[0].length + columnXValue.length-1)),0,TotalCell); \nResult.push(CellRow);\n}\n\n//add total last row\nlet TotalRow =[];\nfor(let i=0; i< Y_axis_Pairs.length-1;i++){TotalRow.push(\"-\");/*null values to fill the bottom cell under y-axis-column value*/}\nTotalRow.push(\"Total\");\n\n//fill total row\nfor(let i =Y_axis_Pairs.length;i < Result[0].length;i++)\n{\nlet total_result =0;\n\nfor(let j = 1 ; j < Result.length;j++)\n{\n //let testoneeee=Result[j][i];\n \n total_result += ((isNaN(Result[j][i]))? 0 : Result[j][i]);\n}\n\nTotalRow.push(total_result);\n}\n\nResult.push(TotalRow);\nreturn Result;\n}", "title": "" }, { "docid": "d4ab0bb4a5744abda41bc892360df8ce", "score": "0.5015746", "text": "function generateMatrixRow(n, row, col, myMatrix) {\n\n /* Create <div class=\"wrap\"> item */\n const wrapDiv = document.createElement(\"div\");\n wrapDiv.className = \"wrap\";\n\n /* Create <div class=\"wrap__row\"> item */\n const rowDiv = document.createElement(\"div\");\n rowDiv.className = \"wrap__row\";\n\n /* Create <span class=\"wrap__span\"> item */\n const span = document.createElement(\"span\");\n span.className = `wrap__span js-span-n${n+1}`;\n span.innerText = \"100\";\n\n for (let m = 0; m < col; m++) {\n\n /* Create <input class=\"wrap__row__col type=\"text\"\"> item */\n const input = document.createElement(\"input\");\n input.className = \"wrap__row__col\";\n input.type = \"text\";\n input.dataset.row = n + 1;\n input.dataset.col = m + 1;\n\n rowDiv.appendChild(input);\n\n // adding input event listeners.\n input.addEventListener('input', (event)=> {\n\n if ( evalRegExp1_100(event) ) {\n\n let activeRow = Number(event.target.dataset.row);\n let activeCol = Number(event.target.dataset.col);\n \n myMatrix[activeRow][activeCol] = Number(event.target.value);\n updateSumColLabel(col, activeRow, myMatrix);\n updateSumRowLabel(row, activeCol, myMatrix);\n\n }\n\n });\n\n }\n\n wrapDiv.appendChild(rowDiv);\n wrapDiv.appendChild(span);\n\n return wrapDiv;\n\n}", "title": "" }, { "docid": "c26f00bf04d350d4e3e8d4998022ba33", "score": "0.5011148", "text": "function InputToRowCellHtml(MyinputID,MyrowID)\n{\n var InputValor=document.getElementById(MyinputID).value;\n \n //alert(MyinputID);\n //alert('el id de la fila'+MyrowID.getAttribute('id'));\n MyrowID=MyrowID.getAttribute('id');\n \n if (MyinputID==='concepto')\n {\n var oCelda=document.getElementById(MyrowID.toString());\n \n \n // pasar el foco al campo importe\n var myString=MyrowID.toString();\n var numFila=myString.substring(9);\n //alert(numFila);\n var oPrecio=document.getElementById('oPrecio'+numFila);\n var pID = oPrecio.getAttribute('id');\n\n if (oCelda.innerHTML.toString().substring(0,6) ==='<input')\n oCelda.innerHTML=InputValor;\n \n campo='<input name=\"precio\" onblur=\"InputToRowCellHtml(this.id,'+pID+');\" value=\"'+\n oPrecio.innerHTML+'\" type=\"text\" id=\"precio\" size=\"10\" maxlength=\"10\" onkeypress=\"detectar_tecla(event, this.id,'+\n pID+')\" />';\n\n oPrecio.innerHTML=campo;\n\n \n //oPrecio.focus();\n document.getElementById('precio').focus();\n \n }\n \n if (MyinputID==='Unidades')\n {\n var oCelda=document.getElementById(MyrowID.toString());\n oCelda.innerHTML=InputValor;\n \n \n var myString=MyrowID.toString();\n //alert(myString);\n var numFila=myString.substring(9);\n //alert('fila: '+numFila);\n \n var importe=parseFloat(InputValor);\n \n var oCeldaTotal=document.getElementById('oTotal'+numFila);\n var oPrecio=document.getElementById('oPrecio'+numFila);\n var String_precio = oPrecio.innerHTML;\n var precio=parseFloat(String_precio);\n var unidades=parseFloat(InputValor);\n //alert(unidades);\n var resultado = precio * unidades;\n \n resultado = resultado.toFixed(2);\n //alert(resultado);\n oCeldaTotal.innerHTML= resultado.toString();\n \n }\n \n // IVA\n if (MyinputID==='IVA')\n {\n var oCelda=document.getElementById(MyrowID.toString());\n \n oCelda.innerHTML=InputValor;\n \n \n var myString=MyrowID.toString();\n //alert(myString); oIVA\n var numFila=myString.substring(4);\n //alert('fila: '+numFila);\n \n var importe=parseFloat(InputValor);\n \n var oCeldaIVA=document.getElementById('oIVA'+numFila).value;\n \n //alert(resultado);\n oCeldaIVA.innerHTML= oCeldaIVA;\n \n }\n \n if (MyinputID==='precio')\n {\n var oCelda=document.getElementById(MyrowID.toString());\n oCelda.innerHTML=InputValor;\n \n //oPrecio\n var myString=MyrowID.toString();\n //alert(myString);\n var numFila=myString.substring(7);\n //alert('fila: '+numFila);\n \n var oCeldaTotal=document.getElementById('oTotal'+numFila);\n var oCeldaUnidades=document.getElementById('oUnidades'+numFila);\n \n \n var importe=parseFloat(InputValor);\n //alert(importe);\n var vUnidades = oCeldaUnidades.innerHTML;\n //alert(oUnidades);\n var unidades=parseFloat(vUnidades);\n //alert(unidades);\n var resultado = importe * unidades;\n \n resultado = resultado.toFixed(2);\n //alert(resultado);\n oCeldaTotal.innerHTML= resultado.toString();\n \n \n }\n \n}", "title": "" }, { "docid": "c91e97b7193dddaeb508ec43b9a77776", "score": "0.50099844", "text": "function TotalAndTolalOfTotalsRow(){\n trtag = document.createElement('tr');\n tabletag.appendChild(trtag);\n tdtag = document.createElement('td');\n trtag.appendChild(tdtag);\n tdtag.textContent = 'Total';\n var sumcookieperhour;\n var Totaloftotals = 0;\n for (var y = 0; y < workhours.length; y++) {\n sumcookieperhour = 0;\n for (var z = 0; z < StoreArray.length; z++) {\n sumcookieperhour = StoreArray[z].numcookiepurch[y] + sumcookieperhour\n }\n Totaloftotals = Totaloftotals + sumcookieperhour;\n tdtag = document.createElement('td');\n trtag.appendChild(tdtag);\n tdtag.textContent = sumcookieperhour;\n }\n tdtag = document.createElement('td');\n trtag.appendChild(tdtag);\n tdtag.textContent = Totaloftotals;\n }", "title": "" }, { "docid": "ef465686484bea0ef7033c6e1ffcbc20", "score": "0.49974486", "text": "function calculateTotal(totalDiv, start, end, currentColumn, aaData, aiDisplay) {\r\n if (totalDiv.length && totalDiv.is(\":visible\") && totalDiv.data(\"function\")) {\r\n var totalType = totalDiv.data(\"role\");\r\n var dataIndex = currentColumn;\r\n var functionName = totalDiv.data(\"function\");\r\n var extraData = totalDiv.data(\"params\");\r\n var total = 0;\r\n var values = new Array();\r\n var hasInvalidValues = false;\r\n\r\n // Calculate the total for all rows, even outside this page\r\n for (var i = start; i < end; i++) {\r\n var currentCell;\r\n if(totalType == \"total\"){\r\n currentCell = aaData[i][dataIndex];\r\n }\r\n else if (totalType = \"pageTotal\"){\r\n currentCell = aaData[aiDisplay[i]][dataIndex];\r\n }\r\n //skip over cells which contain add line content\r\n if (currentCell && jQuery(currentCell).find(\":input[name^='newCollectionLines']\").length == 0) {\r\n var value = coerceTableCellValue(currentCell);\r\n //set hasInvalidValues to true if value is undefined\r\n if (value == undefined) {\r\n hasInvalidValues = true;\r\n break;\r\n }\r\n\r\n //skip over value when blank\r\n if (value != \"\") {\r\n value = parseFloat(value);\r\n values.push(value);\r\n }\r\n }\r\n }\r\n\r\n if (!hasInvalidValues) {\r\n if (extraData != undefined) {\r\n total = window[functionName](values, extraData);\r\n }\r\n else {\r\n total = window[functionName](values);\r\n }\r\n }\r\n else {\r\n total = \"N/A\";\r\n }\r\n\r\n var totalValueSpan = totalDiv.find(\"span[data-role='totalValue']\");\r\n\r\n if (totalValueSpan.length) {\r\n totalValueSpan.html(total);\r\n }\r\n else {\r\n var newSpan = jQuery(\"<span data-role='totalValue'>\" + total + \"</span>\");\r\n totalDiv.append(newSpan);\r\n }\r\n }\r\n}", "title": "" }, { "docid": "ef03d41887a731005546455bb06abafc", "score": "0.498591", "text": "calc() {\n var tf = this.tf;\n if (!tf.isInitialized()) {\n return;\n }\n\n if (this.onBeforeOperation) {\n this.onBeforeOperation.call(null, tf);\n }\n\n var opts = this.opts,\n labelId = opts.id,\n colIndex = opts.col,\n operation = opts.operation,\n outputType = opts.write_method,\n totRowIndex = opts.tot_row_index,\n excludeRow = opts.exclude_row,\n decimalPrecision = isUndef(opts.decimal_precision) ?\n 2 : opts.decimal_precision;\n\n //nuovella: determine unique list of columns to operate on\n var ucolIndex = [],\n ucolMax = 0;\n ucolIndex[ucolMax] = colIndex[0];\n\n for (var ii = 1; ii < colIndex.length; ii++) {\n var saved = 0;\n //see if colIndex[ii] is already in the list of unique indexes\n for (var jj = 0; jj <= ucolMax; jj++) {\n if (ucolIndex[jj] === colIndex[ii]) {\n saved = 1;\n }\n }\n //if not saved then, save the index;\n if (saved === 0) {\n ucolMax++;\n ucolIndex[ucolMax] = colIndex[ii];\n }\n }\n\n if (isArray(labelId) && isArray(colIndex) && isArray(operation)) {\n var rows = tf.tbl.rows,\n colvalues = [];\n\n for (var ucol = 0; ucol <= ucolMax; ucol++) {\n //this retrieves col values\n //use ucolIndex because we only want to pass through this loop\n //once for each column get the values in this unique column\n colvalues.push(\n tf.getColValues(ucolIndex[ucol], false, true, excludeRow));\n\n //next: calculate all operations for this column\n var result,\n nbvalues = 0,\n temp,\n meanValue = 0,\n sumValue = 0,\n minValue = null,\n maxValue = null,\n q1Value = null,\n medValue = null,\n q3Value = null,\n meanFlag = 0,\n sumFlag = 0,\n minFlag = 0,\n maxFlag = 0,\n q1Flag = 0,\n medFlag = 0,\n q3Flag = 0,\n theList = [],\n opsThisCol = [],\n decThisCol = [],\n labThisCol = [],\n oTypeThisCol = [],\n mThisCol = -1;\n\n for (var k = 0; k < colIndex.length; k++) {\n if (colIndex[k] === ucolIndex[ucol]) {\n mThisCol++;\n opsThisCol[mThisCol] = operation[k].toLowerCase();\n decThisCol[mThisCol] = decimalPrecision[k];\n labThisCol[mThisCol] = labelId[k];\n oTypeThisCol = isArray(outputType) ?\n outputType[k] : null;\n\n switch (opsThisCol[mThisCol]) {\n case 'mean':\n meanFlag = 1;\n break;\n case 'sum':\n sumFlag = 1;\n break;\n case 'min':\n minFlag = 1;\n break;\n case 'max':\n maxFlag = 1;\n break;\n case 'median':\n medFlag = 1;\n break;\n case 'q1':\n q1Flag = 1;\n break;\n case 'q3':\n q3Flag = 1;\n break;\n }\n }\n }\n\n for (var j = 0; j < colvalues[ucol].length; j++) {\n //sort the list for calculation of median and quartiles\n if ((q1Flag === 1) || (q3Flag === 1) || (medFlag === 1)) {\n if (j < colvalues[ucol].length - 1) {\n for (k = j + 1; k < colvalues[ucol].length; k++) {\n /* eslint-disable */\n if (eval(colvalues[ucol][k]) <\n eval(colvalues[ucol][j])) {\n /* eslint-enable */\n temp = colvalues[ucol][j];\n colvalues[ucol][j] = colvalues[ucol][k];\n colvalues[ucol][k] = temp;\n }\n }\n }\n }\n var cvalue = parseFloat(colvalues[ucol][j]);\n theList[j] = parseFloat(cvalue);\n\n if (!isNaN(cvalue)) {\n nbvalues++;\n if (sumFlag === 1 || meanFlag === 1) {\n sumValue += parseFloat(cvalue);\n }\n if (minFlag === 1) {\n if (minValue === null) {\n minValue = parseFloat(cvalue);\n } else {\n minValue = parseFloat(cvalue) < minValue ?\n parseFloat(cvalue) : minValue;\n }\n }\n if (maxFlag === 1) {\n if (maxValue === null) {\n maxValue = parseFloat(cvalue);\n } else {\n maxValue = parseFloat(cvalue) > maxValue ?\n parseFloat(cvalue) : maxValue;\n }\n }\n }\n }//for j\n if (meanFlag === 1) {\n meanValue = sumValue / nbvalues;\n }\n if (medFlag === 1) {\n var aux = 0;\n if (nbvalues % 2 === 1) {\n aux = Math.floor(nbvalues / 2);\n medValue = theList[aux];\n } else {\n medValue = (theList[nbvalues / 2] +\n theList[((nbvalues / 2) - 1)]) / 2;\n }\n }\n var posa;\n if (q1Flag === 1) {\n posa = 0.0;\n posa = Math.floor(nbvalues / 4);\n if (4 * posa === nbvalues) {\n q1Value = (theList[posa - 1] + theList[posa]) / 2;\n } else {\n q1Value = theList[posa];\n }\n }\n if (q3Flag === 1) {\n posa = 0.0;\n var posb = 0.0;\n posa = Math.floor(nbvalues / 4);\n if (4 * posa === nbvalues) {\n posb = 3 * posa;\n q3Value = (theList[posb] + theList[posb - 1]) / 2;\n } else {\n q3Value = theList[nbvalues - posa - 1];\n }\n }\n\n for (var i = 0; i <= mThisCol; i++) {\n switch (opsThisCol[i]) {\n case 'mean':\n result = meanValue;\n break;\n case 'sum':\n result = sumValue;\n break;\n case 'min':\n result = minValue;\n break;\n case 'max':\n result = maxValue;\n break;\n case 'median':\n result = medValue;\n break;\n case 'q1':\n result = q1Value;\n break;\n case 'q3':\n result = q3Value;\n break;\n }\n\n var precision = !isNaN(decThisCol[i]) ? decThisCol[i] : 2;\n\n //if outputType is defined\n if (oTypeThisCol && result) {\n result = result.toFixed(precision);\n\n if (elm(labThisCol[i])) {\n switch (oTypeThisCol.toLowerCase()) {\n case 'innerhtml':\n if (isNaN(result) || !isFinite(result) ||\n nbvalues === 0) {\n elm(labThisCol[i]).innerHTML = '.';\n } else {\n elm(labThisCol[i]).innerHTML = result;\n }\n break;\n case 'setvalue':\n elm(labThisCol[i]).value = result;\n break;\n case 'createtextnode':\n var oldnode =\n elm(labThisCol[i]).firstChild;\n var txtnode = createText(result);\n elm(labThisCol[i])\n .replaceChild(txtnode, oldnode);\n break;\n }//switch\n }\n } else {\n try {\n if (isNaN(result) || !isFinite(result) ||\n nbvalues === 0) {\n elm(labThisCol[i]).innerHTML = '.';\n } else {\n elm(labThisCol[i]).innerHTML =\n result.toFixed(precision);\n }\n } catch (e) { }//catch\n }//else\n }//for i\n\n // row(s) with result are always visible\n var totRow = totRowIndex && totRowIndex[ucol] ?\n rows[totRowIndex[ucol]] : null;\n if (totRow) {\n totRow.style.display = '';\n }\n }//for ucol\n }//if typeof\n\n if (this.onAfterOperation) {\n this.onAfterOperation.call(null, tf);\n }\n }", "title": "" }, { "docid": "72fa979c8397621d4daaf2384f31bc1d", "score": "0.49855188", "text": "function createValues() {\r\n var mathDiv = document.getElementById('math');\r\n var displayDiv = document.getElementById('display');\r\n\r\n MathJax.Hub.Queue([\"Typeset\", MathJax.Hub, \"math\"]);\r\n MathJax.Hub.Queue(function() {\r\n var math = MathJax.Hub.getAllJax(\"MathDiv\")[0];\r\n var i = matrixFirstValues();\r\n var j = matrixSecondValues();\r\n var k = calculateMatrixSum();\r\n var l = calculateMatrixFinalSum();\r\n\r\n MathJax.Hub.Queue([\"Text\", math, \"\\\\begin{bmatrix}\" + i + \"\\\\end{bmatrix} \\\\times \\\\begin{bmatrix}\" + j + \"\\\\end{bmatrix} = \\\\begin{bmatrix}\" + k + \"\\\\end{bmatrix} = \\\\begin{bmatrix}\" + l + \"\\\\end{bmatrix}\"]);\r\n MathJax.Hub.Queue(function() {\r\n displayDiv.innerHTML = mathDiv.innerHTML;\r\n });\r\n });\r\n}", "title": "" }, { "docid": "5f3bfc488d5911948c899dfacac61b6e", "score": "0.49845898", "text": "function getTable() {\n\n var table;\n var msrpHigh = getInput(\"msrp_high\");\n var msrpLow = getInput(\"msrp_low\");\n var columns = getInput(\"msrp_interval\");\n var mpgHigh = getInput(\"mpg_high\");\n var mpgLow = getInput(\"mpg_low\");\n var rows = getInput(\"mpg_interval\");\n var columnScale, rowScale;\n\n // this fixes a crash that occured during these cases\n if(msrpHigh-msrpLow < 1 || mpgHigh-mpgLow < 1){\n return;\n }\n\n columnScale = (msrpHigh - msrpLow) / columns;\n rowScale = (mpgHigh - mpgLow) / rows;\n\n table = ('<table>' +\n '<tr>' +\n '<th> Price/Fuel <br> consumption </th>');\n\n for(var msrpScale = msrpLow; msrpScale <= msrpHigh; msrpScale += columnScale){\n table += ('<th>' + '$' + msrpScale.toFixed(2) + '</th>');\n }\n table+='</tr>';\n\n for(var mpgScale = mpgLow; mpgScale <= mpgHigh; mpgScale += rowScale){\n table += ('<tr>' +\n '<th>' + mpgScale.toFixed(2) + ' mpg</th>');\n\n for (var msrpScale = msrpLow; msrpScale <= msrpHigh; msrpScale += columnScale) {\n table += ('<td>$' + costMonth(msrpScale).toFixed(2) + ' month <br>' +\n '$' + costMile(mpgScale).toFixed(2) + ' mile</td>');\n }\n\n table += '</tr>';\n }\n table += '</table>';\n\n $('#info_table').html(table);\n \n return;\n}", "title": "" }, { "docid": "47ef2989cc7db67311f675b919006511", "score": "0.498028", "text": "function getTotal(){\n totalString = inputs.join(\"\");\n $(\"#output\").html(eval(totalString));\n $(\"#equation\").html(eval(totalString));\n }", "title": "" }, { "docid": "f9f8785144978744bebd63a8ae1ca39f", "score": "0.49764174", "text": "function reformatJSJobs(oldJobs) {\n var j;\n var qty;\n var thisLine;\n var jobsTable = \"\";\n var unitCost;\n var unitPrice;\n var total;\n \n var newJobs = oldJobs.replace(/\\n/gmi, \"~\"); // First convert all the newlines /n into single character so we can use 'split'\n var jobsArray = newJobs.split(\"~\"); // Now split into an array (of jobs lines)\n \n for (var i=0; i<jobsArray.length; i++) { // Now parse all lines\n thisLine = jobsArray[i].split(\" \"); // Now break line into 'words'\n if (thisLine[0] != \"\") { // Don't process empty lines\n j = 0;\n jobsTable += \"<tr>\";\n if (thisLine[j] == \"Engine\") { // If the this line is an 'Engine' heading then store that in table row and move on\n jobsTable += \"<td colspan='5'>\"+thisLine[j++] + \" \" + thisLine[j] + \"</td>\";\n } else {\n if ($.isNumeric(thisLine[j])) { // Check first 'word' is the quantity\n qty = thisLine[j++];\n } else {\n qty = 1; // If not specified assume Qty 1\n }\n jobsTable += \"<td style='padding:0px;width:50px'>\";\n jobsTable += \"<input type='text' id='editlabqty-\" + i + \"' class='jsPart' size='3' disable='true' value='\" + qty + \"'/></td>\";\n if (thisLine[j] == \"x\") { j++; } // Skip the 'x' if there is one\n \n jobsTable += \"<td>\"; // We can't safely unpack the Make, Model & Partno so now get everything up to the cost\n for (j; j<thisLine.length; j++) {\n if (thisLine[j].substr(0,1) == \"£\") { // Now add the £xx\n if (thisLine[j] == \"£\") { // Check to see if they left a space after the £ \n j++; // In which case we have to get the actual price from the next word.\n unitCost = thisLine[j];\n } else { // Oterwise we skip the £ and get the actual value\n unitCost = thisLine[j].substr(1); // Just get the actual value\n }\n thisLine[j] = thisLine[j].replace(/ea/gi, \"\"); // Drop the 'ea' as in £23.45ea\n \n unitPrice = \"<td class='priceCol' id = 'editlabunit-\" + i + \"'>£\" + unitCost + \"</td>\";\n break;\n }\n jobsTable += (thisLine[j] + \" \"); \n }\n jobsTable += \"</td>\";\n jobsTable += unitPrice;\n total = (qty * parseFloat(unitCost)) + \" \";\n jobsTable += \"<td class='display:none;' id = 'editlabdiscount-\" + i + \"' >0</td>\"; \n jobsTable += \"<td class='priceCol' id = 'editlabtotal-\" + i + \"' style='text-align:right;'>£\"+numberStringToCurrencyString(total)+\"</td>\";\n }\n jobsTable += \"</tr>\";\n }\n }\n jobsTable = \"<table id='JSLabour' style='width:100%'>\" + jobsTable + \"</table>\"; // Now load into table format.\n alert(\"Jobs data updated\");\n return (jobsTable);\n}", "title": "" }, { "docid": "408573b046963c56f625336796f192a9", "score": "0.49758467", "text": "function getGridData(rows, cell_width, cell_height, Fmodel_geneMap, setOfSignatures, LD) {\n var data = new Array();\n var xpos = 10; //starting xpos and ypos at 1 so the stroke will show when we make the grid below\n var ypos = 1;\n\n var geneSet = new Set();\n for (var i = 0; i < rows; i++) {\n temparr = setOfSignatures[i].gene.split(\";\");\n temparr.forEach(item => geneSet.add(item));\n }\n console.log(\"GENESET\", geneSet);\n geneArray = Array.from(geneSet)\n var columns = geneArray.length;\n\n if (!LD) {\n Fmodel_geneMap.clear();\n }\n\n // iterate for rows \n for (var row = 0; row < rows; row++) {\n data.push(new Array());\n var geneSignature;\n if (LD) {\n /**\n geneSignature = returnGenesFromSignature(setOfSignatures[row])\n getGenes(geneSignature, LD_geneMap);\n **/\n } else {\n geneSignature = setOfSignatures[row].gene.split(\";\");\n getGenes(geneSignature, Fmodel_geneMap);\n }\n\n // iterate for cells/columns inside rows\n for (var column = 0; column < columns; column++) {\n var present = false;\n if (geneSignature.includes(geneArray[column])) {\n present = true;\n }\n\n data[row].push({\n x: xpos,\n y: ypos,\n width: cell_width,\n height: cell_height,\n label_gene: geneArray[column],\n gene_present: present,\n text_Colour: \"black\",\n text_weight: 400,\n pathways: pathwayMap.get(geneArray[column])\n })\n // increment the x position. I.e. move it over by 50 (width variable)\n xpos += cell_width;\n }\n // reset the x position after a row is complete\n xpos = 10;\n // increment the y position for the next row. Move it down 50 (height variable)\n ypos += cell_height;\n }\n return [data, columns];\n}", "title": "" }, { "docid": "a8bad79c20471533ef1809383aa0cd48", "score": "0.49678165", "text": "function createTable(rows) {\r\n var body = document.querySelector(\"body\"),\r\n table = document.querySelector(\"table\"),\r\n height = 60,\r\n width = 1500,\r\n columns = 10,\r\n rows = BinaryComputing.STEPS + rows,\r\n firstTable = document.querySelector(\"table\");\r\n\r\n table = document.createElement(\"table\");\r\n table.setAttribute(\"width\", width);\r\n table.setAttribute(\"border\", \"1px\");\r\n table.setAttribute(\"bordercolor\", \"black\");\r\n table.setAttribute(\"cellpadding\", \"6\");\r\n table.setAttribute(\"align\", \"center\");\r\n\r\n var tableRow = document.createElement(\"tr\");\r\n var tableHeader = document.createElement(\"th\");\r\n var text = document.createTextNode('Number');\r\n tableHeader.appendChild(text);\r\n tableRow.appendChild(tableHeader);\r\n\r\n for (var countTable = 0; countTable < BinaryComputing.DIGITS; countTable++) {\r\n tableHeader = document.createElement(\"th\");\r\n text = document.createTextNode('A * b[' + countTable + ']');\r\n tableHeader.appendChild(text);\r\n tableRow.appendChild(tableHeader);\r\n\r\n\r\n tableHeader = document.createElement(\"th\");\r\n tableHeader.innerHTML = 'Right shift.</br> Step ' + (countTable + 1);\r\n tableRow.appendChild(tableHeader);\r\n }\r\n\r\n tableHeader = document.createElement(\"th\");\r\n text = document.createTextNode('Result');\r\n tableHeader.appendChild(text);\r\n tableRow.appendChild(tableHeader);\r\n table.appendChild(tableRow);\r\n\r\n for (var i = 0; i < rows; i++) {\r\n tableRow = document.createElement(\"tr\");\r\n for (var j = 0; j < columns; j++) {\r\n var tableData = document.createElement(\"td\");\r\n tableData.id = ((i + 1) + \".\" + (j + 1));\r\n tableRow.appendChild(tableData);\r\n tableData.setAttribute(\"height\", height);\r\n }\r\n table.appendChild(tableRow);\r\n }\r\n\r\n if (firstTable == null) {\r\n return body.appendChild(table);\r\n } else {\r\n var newTable = body.appendChild(table);\r\n return document.body.replaceChild(newTable, firstTable);\r\n }\r\n}", "title": "" }, { "docid": "a59c7d02bf413dc393cf25927b5dbb97", "score": "0.49643046", "text": "getMolecularFormula() {\n let atomListwithCnt = new Array(5);\n let len = this.atomList.length;\n let mass = 0;\n for (let i = 0; i < len; i++) {\n let count = 0;\n if (this.atomList[i] == \"C\") {\n count = Math.floor(this.eachAtomCount * this.carbonCnt);\n mass = mass + count * getIsotopicMassOfAtom(this.atomList[i])[0].mass;\n }\n else if (this.atomList[i] == \"H\") {\n count = Math.floor(this.eachAtomCount * this.hydrogenCnt);\n mass = mass + count * getIsotopicMassOfAtom(this.atomList[i])[0].mass;\n }\n else if (this.atomList[i] == \"N\") {\n count = Math.floor(this.eachAtomCount * this.nitrogenCnt);\n mass = mass + count * getIsotopicMassOfAtom(this.atomList[i])[0].mass;\n }\n else if (this.atomList[i] == \"O\") {\n count = Math.floor(this.eachAtomCount * this.oxygenCnt);\n mass = mass + count * getIsotopicMassOfAtom(this.atomList[i])[0].mass;\n }\n else if (this.atomList[i] == \"S\") {\n count = Math.floor(this.eachAtomCount * this.sulphurCnt);\n mass = mass + count * getIsotopicMassOfAtom(this.atomList[i])[0].mass;\n }\n atomListwithCnt[i] = { atom: this.atomList[i], count: count };\n }\n return [atomListwithCnt, mass];\n }", "title": "" }, { "docid": "f8de966c3c369a2e9975abd51e8b2e94", "score": "0.49632144", "text": "function displayFormula() {\n\n var plotting_canvas = document.getElementById(\"plot\");\n var plotting_context = plotting_canvas.getContext(\"2d\");\n plotting_context.clearRect(0, 0, plotting_canvas.width, plotting_canvas.height);\n\n drawAxes();\n\n // Fill in the grid.\n for (var i = 0; i < 106; i++){\n for (var j = 0; j < 17; j++){\n if (draw_grid_colored[i][j]){\n plotting_context.fillRect(60 + i*6, 30 + j*6, 6, 6);\n }\n }\n }\n}", "title": "" }, { "docid": "05ad543b277d300e80b66d4ed437765e", "score": "0.49585757", "text": "function makeSumValues(expression){\n\tvar result = expression;\n\tif(expression != null && expression != ''){\n\t\tvar first_value = '';\n\t\tvar second_value = '';\n\t\tvar count_sum = (expression.match(/\\+/g) || []).length;\n\t\tvar sum;\n\t\tvar position_initial_number = 0;\n\t\tvar position_final_number = 0;\n\t\tvar expression_initial;\n\t\tvar expression_final;\n\t\tvar expression_temp;\n\t\tvar sum_text = '';\n\t\tif(count_sum > 0){\n\t\t\tfor(var i = 0; i < expression.length; i++){\n\t\t\t\t// Encontrando sinal de soma\n\t\t\t\tif(expression[i] == '+'){\n\t\t\t\t\t// Pesquisando o primeiro valor\n\t\t\t\t\tfor(var j = (i-1); j >= 0; j--){\n\t\t\t\t\t\tif(checkIsValidValueNumber(expression[j])){\n\t\t\t\t\t\t\tfirst_value = first_value.concat(expression[j]);\n\t\t\t\t\t\t\tposition_initial_number = j;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\tfor(var j = (i+1); j < expression.length; j++){\n\t\t\t\t\t\tif(checkIsValidValueNumber(expression[j])){\n\t\t\t\t\t\t\tsecond_value = second_value.concat(expression[j]);\n\t\t\t\t\t\t\tposition_final_number = j;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t\t// invertendo o primeiro valor\n\t\t\t\t\tfirst_value = first_value.split('').reverse().join('');\n\t\t\t\t\tif($.isNumeric(first_value) && $.isNumeric(second_value)){\n\t\t\t\t\t\tsum_text = sum_text.concat(first_value).concat('+').concat(second_value);\n\t\t\t\t\t\tsum = Number(first_value) + Number(second_value);\n\t\t\t\t\t\texpression_initial = expression.substring(0,position_initial_number);\n\t\t\t\t\t\texpression_final = expression.substring((position_final_number+1),expression.length);\n\t\t\t\t\t\texpression_temp = expression_initial + String(sum) + expression_final;\n\t\t\t\t\t\texpression = expression_temp;\n\t\t\t\t\t\tsum = String(sum);\n\t\t\t\t\t\t// Atualizando posicao do ponteiro i do loop\n\t\t\t\t\t\tif(sum.length > sum_text.length){\n\t\t\t\t\t\t\tcount = sum.length - sum_text.length;\n\t\t\t\t\t\t\ti = i + count;\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tcount = sum_text.length - sum.length;\n\t\t\t\t\t\t\ti = i - count;\n\t\t\t\t\t\t}\n\t\t\t\t\t\tfirst_value = '';\n\t\t\t\t\t\tsecond_value = '';\n\t\t\t\t\t\tsum_text = '';\n\t\t\t\t\t\tresult = expression;\n\t\t\t\t\t} else {\n\t\t\t\t\t\tresult = CONST_INVALID;\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\tif(result == CONST_INVALID){\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t} else {\n\t\tresult = CONST_INVALID;\n\t}\n\treturn result;\n}", "title": "" }, { "docid": "e72fa6abc3313e53d6f722c951089009", "score": "0.49583992", "text": "function totalMangosRecolectados(){\n var total = 0;\n resultadoPr.innerHTML = '';\n // recorre la matriz en posición 4\n for (var y = 0; y < datos[4].length; y++){\n // formula que suma los mangos por la cnatidad\n total = total+Number(datos[4][y]);\n }\n resultadoPr.innerHTML = '<h5>La cantidad total vendida es de: </h5>' +total;\n }", "title": "" }, { "docid": "6e0d48b7737caae55a17c56293489866", "score": "0.49562794", "text": "function calculate_totals() {\n\tconst item_rows = document.querySelectorAll(\".calculator .row[data-type]\"); // grab all of the rows that are not the totals row\n\n\t/**\n\t * Iterate through each row\n\t */\n\titem_rows.forEach(function (row) {\n\t\t// capture the quantity value\n\t\tlet qty = row.querySelector(\"[name='qty']\").value;\n\n\t\t//if the quantity on this row is blank, skip the row\n\t\tif (qty === \"\") {\n\t\t\treturn false;\n\t\t}\n\n\t\tqty = parseInt(qty); //convert quantity to an integer\n\n\t});\n}", "title": "" }, { "docid": "e013297f54967653e92ba23f7fe20330", "score": "0.4951188", "text": "function calcData() {\r\n\r\n var pO = CurProgObj; // needed for eval()\r\n\r\n var mO = CurModObj;\r\n var sO = CurStepObj;\r\n var fO = CurFuncObj;\r\n\r\n var oGId = sO.allGridIds[0];\r\n var ogO = fO.allGrids[oGId]; // output grid\r\n\r\n\r\n // Create the grid for starup args. Function Main() referes to this\r\n // startup arg array (as a parameter)\r\n // IMPORTANT: The name of the following variable MUST be same as\r\n // the DefStartupGridName\r\n //\r\n var StartUpGrid = new GridObj(0, DefStartupGridName, 1, 10,\r\n 1, 4, false, false, false, true);\r\n createArrays(StartUpGrid);\r\n\r\n\r\n if (CurStepObj.stageInStep >= StageInStep.GridSelectDone) {\r\n\r\n updateStepObj(CurStepObj); // record any updated formula etc.\r\n\r\n // create data arrays for all grids in the prog (except for in args)\r\n //\r\n allocOrClearDataArrays4Prog();\r\n\r\n } else {\r\n showTip(TipId.SelectGrids);\r\n return;\r\n }\r\n\r\n\r\n // Get the java script code corresponding to the step\r\n //\r\n var code = getJavaScriptStr();\r\n\r\n\r\n // evaluate java script code using 'eval()'. This will put proper\r\n // values in to 'data' arrays in output grid object.\r\n //\r\n try {\r\n eval(code);\r\n } catch (ex) {\r\n\r\n if (ex instanceof SyntaxError) {\r\n alert(\"Syntax Error: \" + ex.message);\r\n } else {\r\n\r\n // We reached the breakpoint that we inserted manually for the\r\n // current step. Nothing else to be done\r\n //\r\n if (ex.message) {\r\n alert(\"Error: \" + ex.message);\r\n }\r\n\r\n //var msg = (ex.message)? \"Msg: \" + ex.message : \"\";\r\n //alert(\"Breakpoint for current step reached \" + msg);\r\n }\r\n }\r\n\r\n\r\n // set the maximum data value and draw the grids again\r\n //\r\n sO.maxDataVal = getMaxDataVal(ogO.numDims - 1, ogO.data, MININT);\r\n //\r\n drawStep(CurStepObj);\r\n\r\n}", "title": "" } ]
cb645c59a99abe19b4956c32777c4a2e
Class processing on untap / hover
[ { "docid": "7885d466f7a4bb90a238a1e94fa82622", "score": "0.7687513", "text": "tapEventOn(e){if(typeof this.hoverClass!==typeof void 0&&!this.disabled){// break class into array\nvar classes=this.hoverClass.split(\" \");// run through each and add or remove classes\nclasses.forEach((item,index)=>{if(\"\"!=item){this.$.button.classList.add(item);if(-1!=item.indexOf(\"-\")){this.$.icon.classList.add(item)}}})}}", "title": "" } ]
[ { "docid": "4f6fcafd5562d9bdb549a73293d02f9c", "score": "0.8044573", "text": "tapEventOff(e){if(typeof this.hoverClass!==typeof void 0&&!this.disabled){// break class into array\nvar classes=this.hoverClass.split(\" \");// run through each and add or remove classes\nclasses.forEach((item,index)=>{if(\"\"!=item){this.$.button.classList.remove(item);if(-1!=item.indexOf(\"-\")){this.$.icon.classList.remove(item)}}})}}", "title": "" }, { "docid": "f043e1b9ff7f225d22cc3d7bf72f9d4e", "score": "0.6891679", "text": "handleClickAreaUnhover() {\n clearTimeout(this.highlightTimeout);\n this.clickArea?.classList.remove('cd-thread-clickArea-hovered');\n }", "title": "" }, { "docid": "03160797cfed3bfef1eab6cc67b25310", "score": "0.6448224", "text": "function unhover() {\r\n this.classList.remove(\"hovered\");\r\n }", "title": "" }, { "docid": "c55c2add557063d6a6d10b911cc19290", "score": "0.62878937", "text": "focusToggle(e){// weird but reality... focus event is the button inside of here\nif(typeof this.hoverClass!==typeof void 0&&!this.disabled){// break class into array\nvar classes=this.hoverClass.split(\" \");// run through each and add or remove classes\nclasses.forEach((item,index)=>{if(\"\"!=item){if(!this.focusState){this.$.button.classList.add(item);if(-1!=item.indexOf(\"-\")){this.$.icon.classList.add(item)}}else{this.$.button.classList.remove(item);if(-1!=item.indexOf(\"-\")){this.$.icon.classList.remove(item)}}}})}this.focusState=!this.focusState}", "title": "" }, { "docid": "43a49fef93f1e72076c60f78d4dde30a", "score": "0.6226061", "text": "function hover_mobile() {\n \"use strict\";\n if (jQuery(\"div.mobile_tap_hover\").length > 0) {\n jQuery('.taphover').on(\"touchstart\", function(e) {\n var link = jQuery(this); //preselect the link\n if (link.hasClass('hover')) {\n return true;\n } else {\n link.addClass(\"hover\");\n //$(this).parent().css({'z-index': 1});\n jQuery('.taphover').not(this).removeClass(\"hover\");\n e.preventDefault();\n return false; //extra, and to make sure the function has consistent return points\n }\n });\n }\n\n}", "title": "" }, { "docid": "f7c8191a4696cf973629f438e4964e47", "score": "0.62222725", "text": "function deselectedHoverClassStart(ref) {\n const { $top, $bottom, $topBack, $bottomBack } = ref;\n if (ref.getSelectedState() === 'TRUE' || ref.getHoverState() === 'TRUE') {\n $bottom.addClass('activeMenuHover__bottom');\n }\n\n $top.removeAttr('style');\n $bottomBack.removeAttr('style');\n ref.setAnimState('INIT');\n flipDeselectedMenuStart(ref);\n}", "title": "" }, { "docid": "8777569e8ba8ac9621db06dd485ab430", "score": "0.61410123", "text": "handleMouseOut(event) {\n if (Control.active == null) {\n event.target.classList.remove('highlight');\n }\n }", "title": "" }, { "docid": "9b16eccf2b1c6ba04090819b8628185a", "score": "0.60984087", "text": "function mouseOut() {\n\t\tthis.classList.remove(\"moveable\");\n\t}", "title": "" }, { "docid": "6741eb37da975992f72df628a94b7771", "score": "0.6078665", "text": "function rmClass(){\r\n\t\t$(\"#top_left\").removeClass(\"clicked\");\r\n\t\t$(\"#top_right\").removeClass(\"clicked\");\r\n\t\t$(\"#bottom_left\").removeClass(\"clicked\");\r\n\t\t$(\"#bottom_right\").removeClass(\"clicked\");\r\n\t}", "title": "" }, { "docid": "f2d1b6de1947801ec7c327471afa7860", "score": "0.6049177", "text": "function hoverOff() {\n svgStates.forEach((el) => {\n el.classList.remove(\"on\");\n el.classList.remove(\"faded-state\");\n });\n}", "title": "" }, { "docid": "3192ae37b70841da8b50061fc029310f", "score": "0.6017522", "text": "function onDeselect() {\n const icon = document.getElementById(\"desktop-icon\");\n icon.classList.remove(\"blue-overlay\");\n}", "title": "" }, { "docid": "aa659ba3e25d54d4c2e37eec4a5168aa", "score": "0.6015606", "text": "onTap_() {}", "title": "" }, { "docid": "65c13d1b3887e5a900974624c0777b91", "score": "0.5949043", "text": "onHover(evt) {\n\t\t\tif (!evt.target.classList.contains('active')) {\n\t\t\t\tevt.target.classList.toggle('hover');\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "fdd159c45cc7ab1fac169b13b86dbaf0", "score": "0.59445864", "text": "function off() {\r\n\t\tthis.className = \"tiles\";\r\n\t}", "title": "" }, { "docid": "9853d61212c7ca767e6e6c49ce30f62c", "score": "0.59334207", "text": "function unPress(id) {\n\t$(id).removeClass('active');\n}", "title": "" }, { "docid": "8041487263b363d721dd3cbf91767e3a", "score": "0.5895383", "text": "function hovering(thisCard) {\n lastIdTag = \"#\" + lastId;\n thisCard.addClass(\"hover\");\n $(lastIdTag).addClass(\"hover\");\n thisCard.off('click');\n $(lastIdTag).off('click');\n thisCard.css('cursor', 'default');\n $(lastIdTag).css('cursor', 'default');\n}", "title": "" }, { "docid": "ce934d6e1dcdde43a2f3e5a8888c9f55", "score": "0.5869344", "text": "dehighlight() {\r\n this.$dropZone.attr('aria-disabled', 'true').children('.h5p-inner').removeClass('h5p-active');\r\n }", "title": "" }, { "docid": "7f86570e98e0fb5c04e345bdb59dacc2", "score": "0.5857331", "text": "_discardKeyboardHover(overrideCheck) {\n const that = this;\n\n if (!that._focusedViaKeyboard) {\n return;\n }\n\n if (!overrideCheck &&\n that._focusedViaKeyboard instanceof Smart.MenuItemsGroup &&\n that._isContainerOpened(that._focusedViaKeyboard.level + 1, that._focusedViaKeyboard.container)) {\n return;\n }\n\n that._focusedViaKeyboard.$.removeClass('focus');\n that._focusedViaKeyboard.removeAttribute('focus');\n that._focusedViaKeyboard.$.removeClass('hover');\n that._focusedViaKeyboard.removeAttribute('hover');\n\n that._focusedViaKeyboard = undefined;\n }", "title": "" }, { "docid": "a8bf66d1ace6e6eae9a7327218c35b00", "score": "0.58457994", "text": "function removeActiveClassLoop() {\n\t\t\t\tvar dTime = Date.now() - anchorHighlight._startRemoveTime;\n\n\t\t\t\tif (dTime > anchorHighlight.options.keepActiveClassDelay) {\n\t\t\t\t\t// after touchend\n\t\t\t\t\tclearActiveClass();\n\t\t\t\t} else {\n\t\t\t\t\tanchorHighlight._requestAnimationFrame(removeActiveClassLoop);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "388b5402228e5ee94907eff2e80e16e7", "score": "0.5838054", "text": "function unhighlight(e) {\n dropArea.classList.remove('highlight')\n}", "title": "" }, { "docid": "f517fa01f9946394cbbf163a5516d574", "score": "0.58374673", "text": "_unselect() {\n\t\tconst items = this.container.querySelectorAll('.img-box');\n\n\t\t[...items].forEach((item) => {\n\t\t\titem.classList.remove('active');\n\t\t});\n\t}", "title": "" }, { "docid": "627431da356b5699b3397f0fa3c0bfec", "score": "0.58129287", "text": "function drain(){\r\n stars.removeClass(\"on hover\");\r\n }", "title": "" }, { "docid": "7ab55a1643e6cc32e7ae230a09059f65", "score": "0.58118427", "text": "onMouseUp() { return null; }", "title": "" }, { "docid": "44522a51ab9632f6aefc015c2b593f2a", "score": "0.5797224", "text": "function setTouchFlag() {\n TOUCH_FLAG = true // Set flag to prevent needless function calls\n hoverLayer = [] // Drop hover layer references, kills events\n svg.removeChild(hoverGroup) // Remove hover group from SVG\n // Remove self when done\n container.removeEventListener('touchstart', setTouchFlag)\n }", "title": "" }, { "docid": "41e6b73ba48dfed0335426158d0e6957", "score": "0.5771263", "text": "function dehighlight(mouseout) {\n\t\tthis.className = \"box\";\n\t}", "title": "" }, { "docid": "dfab1b61fca4bec1b5d2ef7eddcd6b7f", "score": "0.5748002", "text": "function E(){z.props.touchHold&&!z.props.target&&(k(\"touchstart\",s,ji),k(\"touchend\",d,ji)),z.props.trigger.trim().split(\" \").forEach(function(e){\"manual\"===e||(z.props.target?\"mouseenter\"===e?(k(\"mouseover\",m),k(\"mouseout\",f)):\"focus\"===e?(k(\"focusin\",m),k(\"focusout\",f)):\"click\"===e?k(e,m):void 0:(k(e,s),\"mouseenter\"===e?k(\"mouseleave\",d):\"focus\"===e?k(Oi?\"focusout\":\"blur\",c):void 0))})}", "title": "" }, { "docid": "3b88ffb602a0cd3619bbc0851e373672", "score": "0.57404053", "text": "function menuHoverRemove() {\n $(this).removeClass('has-focus');\n }", "title": "" }, { "docid": "1ea8a56da4472eee66fd6a686ad98dcb", "score": "0.5732916", "text": "function testRemoveDragItemHoverClasses() {\n dlg.handleDragItemMouseover_(event);\n dlg.handleDragItemMouseout_(event);\n\n assertFalse('Should have no cursor_move class after MOUSEOUT',\n goog.dom.classlist.contains(event.currentTarget, 'cursor_move'));\n assertFalse('Should have no cursor_pointer class after MOUSEOUT',\n goog.dom.classlist.contains(event.currentTarget, 'cursor_pointer'));\n assertFalse('Should have no opacity_40 class after MOUSEOUT',\n goog.dom.classlist.contains(event.currentTarget, 'opacity_40'));\n assertFalse('Should have no blue_bg class after MOUSEOUT',\n goog.dom.classlist.contains(event.currentTarget, 'blue_bg'));\n}", "title": "" }, { "docid": "36dee956a3775396fea3f21e02235e90", "score": "0.57163525", "text": "function lightUp(e) {\n e.target.classList.add(\"clicked\");\n}", "title": "" }, { "docid": "b79fdda8cd627090d507e35f79a51772", "score": "0.57158905", "text": "mouseUp(event){event.preventDefault();\n this.setState({colored : false})}", "title": "" }, { "docid": "97a894a673427e070d0d5a4756617155", "score": "0.5714891", "text": "mouseUpHandler(event)\n {\n if (this._mouseMode == MouseMode.SELECT || this._mouseMode == MouseMode.RESIZE)\n {\n cursorTypes.forEach((t) => {this._canvas.classList.remove(\"select-\"+t);});\n }\n }", "title": "" }, { "docid": "f5493cff2c4574d8748d0d5a19e91db3", "score": "0.570655", "text": "function dehighlight() {\r\n\r\n if ($(this).hasClass(\"movablepiece\")) {\r\n $(this).removeClass(\"movablepiece\");\r\n }\r\n }", "title": "" }, { "docid": "b036b579a5d66ba2a844acf7ee58b067", "score": "0.5704987", "text": "function initCustomHover() {\n jQuery(\".main-nav__item\").touchHover({ hoverClass: \"hover\" });\n}", "title": "" }, { "docid": "fe764ace65c8abb79b0230ebf3fcbd29", "score": "0.569166", "text": "function clickList() {\n if (this.className === 'highlighted') {\n this.className = null;\n }\n else {\n this.className = 'highlighted';\n }\n}", "title": "" }, { "docid": "9ec92b29af348f18d46de203b9db577e", "score": "0.56915027", "text": "function handelActive(ev) {\n ev.target.parentElement.querySelectorAll(\".active\").forEach(element => {\n element.classList.remove(\"active\")\n });\n ev.target.classList.add(\"active\");\n}", "title": "" }, { "docid": "9da6e0b7e7467168fd92934ddfe4e9c3", "score": "0.5676908", "text": "function bindOuterNavClick() {\n\t\t\t$( 'body' ).on( 'touchstart', function ( e ) {\n\t\t\t\tvar container = $( '.menu-wrapper' );\n\n\t\t\t\tif ( ! container.is( e.target ) // if the target of the click isn't the container...\n\t\t\t\t && container.has( e.target ).length === 0 ) // ... nor a descendant of the container\n\t\t\t\t{\n\t\t\t\t\t$theUsualSuspects.removeClass( 'hover' ).removeClass( 'active' );\n\t\t\t\t}\n\t\t\t} );\n\t\t}", "title": "" }, { "docid": "aa1507c3d8ebd395d028cbeaa7bfa0e3", "score": "0.56763726", "text": "function undoRed(clicked){\n clicked.classList.remove('unmatch');\n}", "title": "" }, { "docid": "10706d2c7df5f00c58497c1f70c0d3ea", "score": "0.56754476", "text": "handleClickAreaHover() {\n this.highlightTimeout = setTimeout(() => {\n this.clickArea?.classList.add('cd-thread-clickArea-hovered');\n }, 75);\n }", "title": "" }, { "docid": "b39c437cc1731767abdd0dbd817142cd", "score": "0.5674946", "text": "function clearClickedClass(e) {\n let element = document.getElementsByClassName(\"clicked\");\n if (element[0] != undefined) {\n element[0].classList.remove(\"clicked\");\n }\n }", "title": "" }, { "docid": "61cd3a99aa766d5423e2ae896746153d", "score": "0.56722087", "text": "unselectCurrent() {\n if ( this.activeControl && this.activeControl.getClassName() == \"HolographicButton\") {\n this.activeControl.pointerOutAnimation();\n } else if (this.activeControl && this.activeControl.getClassName() == \"Form\") {\n this.activeControl.unselectCurrent();\n }\n }", "title": "" }, { "docid": "635cb7c63cf8daeeadb04eee236faca1", "score": "0.5667766", "text": "onMouseUp(e) {// Implemeneted by subclasses.\n }", "title": "" }, { "docid": "59d054720bd896e26be0004a4e0fa748", "score": "0.564809", "text": "function simonPress(element) {\n $(element).addClass(\"pressed\");\n setTimeout(function() {\n $(element).removeClass(\"pressed\");\n }, 300);\n}", "title": "" }, { "docid": "8dda5ea4d3a3f4ae66aad0b54876c798", "score": "0.5641707", "text": "function unhighlightHover(id) {\n var clickedTab = document.getElementById(id);\n clickedTab.setAttribute(\"class\", \"\");\n}", "title": "" }, { "docid": "0a898e5bfe772463a09bd0249e703e5e", "score": "0.5621276", "text": "function mouseDownCB() {\n $(this).addClass(\"mouseDown\");\n}", "title": "" }, { "docid": "4f1089309162a1fa0253fabe7f383f09", "score": "0.561791", "text": "function hoverEvent() {\n this.classList += \" black\";\n }", "title": "" }, { "docid": "7a322e87502dd122f745baf070acb80d", "score": "0.5616693", "text": "function mouseout() {\n svg.selectAll(\".active\").classed(\"active\", false);\n // info.text(defaultInfo);\n }", "title": "" }, { "docid": "721a219b5c0258f73706c43230b83199", "score": "0.55981433", "text": "function disableOp() {\n $( this ).css(\"color\", \"\"); // Remove added colors.\n $( this ).removeClass(opEnabled);\n $( this ).addClass(opDisabled);\n $( this ).off(\"mouseup\").off(\"mousedown\");\n $( this ).off(\"touchstart\").off(\"touchend\");\n }", "title": "" }, { "docid": "f4a3e56acff12eddb11c7a3eeaa57dbe", "score": "0.5592092", "text": "function handFun() {\n hand.classList.remove(\"active\");\n }", "title": "" }, { "docid": "ea1d39fdbf8f4d7518cc30e9ca81e628", "score": "0.5587807", "text": "function activeClass(ev){\n ev.target.parentElement.querySelectorAll(\".active\").forEach(element =>{\n element.classList.remove(\"active\")\n })\n ev.target.classList.add(\"active\");\n}", "title": "" }, { "docid": "06abb288df6b5b1f258ccfa94d6931bb", "score": "0.5569358", "text": "function hideCardSymbol(e){\n $(e.currentTarget).attr('class', 'card');\n }", "title": "" }, { "docid": "fc06b0f378a05953439872ca953818f6", "score": "0.5568471", "text": "function mouseoutFunction(event) {\n GS.triggerEvent(event.target.parentNode, evt.mouseout);\n event.target.parentNode.classList.remove('hover');\n }", "title": "" }, { "docid": "f96d14af468539754293b0c3e6b4c6ef", "score": "0.5559213", "text": "function handleActiveClass(ev) {\n\t//remove Active class from all children\n\tev.target.parentElement.querySelectorAll('.active').forEach((element) => {\n\t\t//remove active class from all spans\n\t\telement.classList.remove('active');\n\t\t//add active class to clicked span\n\t\tev.target.classList.add('active');\n\t});\n}", "title": "" }, { "docid": "46cf5701d87c52b658945223017e8f88", "score": "0.5557266", "text": "function mouseOut()\n{\n\tif(swapCheck(this))\n\t{\n\t\t// removing the class once mouse moves out of the box which can be moved to empty space\n\t\tthis.removeClassName(\"movablepiece\");\n\t}\n}", "title": "" }, { "docid": "3b124484552a2aa3da3998a6814e9cd0", "score": "0.5555368", "text": "function classClearStandard($el, options) {\n $el.removeClass(options.hoverClass + \" \" + options.focusClass + \" \" + options.activeClass);\n }", "title": "" }, { "docid": "a0f50245e3ab825304f85e6dfe840b24", "score": "0.555225", "text": "onUnhighlight() {\n this.props.onChangeHighlight(null);\n }", "title": "" }, { "docid": "e77abeb69e4add238c0d6574a3e2ee9e", "score": "0.55489075", "text": "function\thandleDragEnter(e){\n\te.target.classList.remove(\"over\");\n}", "title": "" }, { "docid": "1df8a749a8a839bf23f8091d2adf5dc5", "score": "0.55460846", "text": "_mouseEventsHandler(event) {\n const that = this;\n\n event.type === 'mouseenter' ? that.setAttribute('hover', '') : that.removeAttribute('hover');\n }", "title": "" }, { "docid": "fe8d833649ff3089122bbd4e5d98dfb1", "score": "0.55454177", "text": "function mouseoutFunction(event) {\n var gsace = GS.findParentElement(event.target, 'gs-ace');\n GS.triggerEvent(gsace, evt.mouseout);\n gsace.classList.remove('hover');\n }", "title": "" }, { "docid": "a6e2eb335295b56ad16f984d05b3a971", "score": "0.55368334", "text": "function mouseOut() {\n this.className = this.className.replace(\"movablepiece\", '');\n}", "title": "" }, { "docid": "b7ee93e36962d0f9954aee753d3ebf09", "score": "0.5535302", "text": "function bindMouseTouchHover() {\n \n // Elements with desired hover effect\n $hoverElements = $(\"figure.portfolio-fig, a.btn-block, button.btn-block\");\n \n // Bind elements to beginning of hover/touch\n $hoverElements.on('touchstart, mouseenter', function() {\n $(this).addClass('js-hover');\n });\n \n // Bind elements to end of hover/touch\n $hoverElements.on('touchend, mouseleave', function() {\n $(this).removeClass('js-hover');\n });\n}", "title": "" }, { "docid": "4f22665765e9b61a20107b52c0ef5eb1", "score": "0.55263275", "text": "changeColor(e) {\n $(e.target).removeClass('untouched')\n }", "title": "" }, { "docid": "3c00d374358cff99a642f28f86cfddb0", "score": "0.5520226", "text": "highlight() {\n this.html.addClass(\"Highlited\");\n this.frontArrow.html.removeClass(\"disable\");\n this.backArrow.html.removeClass(\"disable\");\n }", "title": "" }, { "docid": "c103f0762633e361448b7c04b9047228", "score": "0.5518598", "text": "clean() {\n if(this.selEl)\n this.selEl.removeClass(this.hoverClass);\n }", "title": "" }, { "docid": "cbaf5f53fc88455ac2b8fa005995f7a2", "score": "0.5518074", "text": "function hover() {\n jQuery(this).toggleClass(\"ui-state-hover\");\n return false;\n }", "title": "" }, { "docid": "d46896320d56b22849c771acf52424b2", "score": "0.5506873", "text": "function btnUp(){\n this.classList.remove('active')\n}", "title": "" }, { "docid": "5ce4f2c79c23204102fae163de871b4e", "score": "0.54958093", "text": "function clickedBtn() {\n this.style.backgroundColor = '#fff3d37c';\n this.style.color = 'rgba(0, 0, 0, 0.493)';\n this.classList.remove('hoverClass');\n }", "title": "" }, { "docid": "6d27b57728cac4502f2bbd895b555e80", "score": "0.54935896", "text": "unhighlightFocused() {\n if (!this.#underlay) return;\n\n this.#underlay.classList.remove('cd-commentUnderlay-focused');\n this.#overlay.classList.remove('cd-commentOverlay-focused');\n this.#overlay.style.display = '';\n }", "title": "" }, { "docid": "c5f79a179c0de8c24a8bc3eca071d2f7", "score": "0.5492761", "text": "function _handleLureMouseMovement() {\n $(this).find('coral-quick-actions').toggleClass('is-open');\n }", "title": "" }, { "docid": "4032e913995c47315918ddd0fc4efcda", "score": "0.54886323", "text": "function unhighlightMouseoutElement(event) {\n highlight_1.Highlight.clearHighlight(window.helenaContent.highlightedElement);\n }", "title": "" }, { "docid": "ef7f2fe9dffda1e134bb84b36147e83b", "score": "0.5484941", "text": "function cellMouseOut() {\r\n /*\r\n var parts = this.className.split(\" \");\r\n var newClass = parts[0];\r\n if (parts.length > 2) {\r\n newClass = newClass + \" \" + parts[1];\r\n }\r\n this.className = newClass;\r\n */\r\n }", "title": "" }, { "docid": "5da49eb12bd1a9d8d7bebac8610e5af6", "score": "0.5484934", "text": "function classClearStandard($el, options) {\n\t\t$el.removeClass(options.hoverClass + \" \" + options.focusClass + \" \" + options.activeClass);\n\t}", "title": "" }, { "docid": "5da49eb12bd1a9d8d7bebac8610e5af6", "score": "0.5484934", "text": "function classClearStandard($el, options) {\n\t\t$el.removeClass(options.hoverClass + \" \" + options.focusClass + \" \" + options.activeClass);\n\t}", "title": "" }, { "docid": "df8449a7d6b48a48cfcf9c1093d8cdd5", "score": "0.5484649", "text": "function convertClickToTap() {\n $('#aMainAccountMenuOpener').removeAttr('onclick')\n .bind(\"tap\", function (e) { openOrCloseAccountMainMenu(); });\n\n $('aside ul.level1 li .aMenuItem').removeAttr('onclick')\n .bind(\"tap\", function (e) { openOrCloseAccountSubMenu(this); });\n}", "title": "" }, { "docid": "ad9ef7d7ca0159b867a12d156eb9880f", "score": "0.5478466", "text": "function removeAddClass(ev){\r\n ev.target.parentElement.querySelectorAll('.active').forEach(element => {\r\n element.classList.remove('active');\r\n });\r\n ev.target.classList.add('active');\r\n}", "title": "" }, { "docid": "d73866702dc6a3ce55c59a0c3dfaf14a", "score": "0.5472166", "text": "removeHover() {\n let icons = document.querySelector(`.${this.buttonClasses.buttons}`);\n\n //Thank you Qb and DB\n if (icons)\n icons.removeEventListener(\"mouseleave\", this.mouseleaveFunc);\n }", "title": "" }, { "docid": "35358312691e67f569cabd80e537bff7", "score": "0.5470914", "text": "function setNone ( elt, baseClass ) {\n\n\t\tCL.remove( touchClass );\n\n\t}", "title": "" }, { "docid": "4ae7ed386518e5c0d29f4f4f589fe982", "score": "0.5466594", "text": "function fixHoverOnMobile() {\r\n $('.fix-hover').on({\r\n 'touchstart': function () {\r\n $(this).trigger('hover');\r\n },\r\n 'touchend': function () {\r\n $(this).trigger('hover');\r\n }\r\n });\r\n}", "title": "" }, { "docid": "3262647e1ad1b6cd6729784c2276aa2a", "score": "0.54642165", "text": "handleMouseUp() {\n this.setState({\n mousePressed: false\n });\n for (let i = 0; i < this.currentUtility.length; i++) {\n this.currentUtility[i].active = false;\n }\n this.props.passUtilityUp(this.currentUtility);\n }", "title": "" }, { "docid": "6c16e3407f2440c6a84df5ec70251ccc", "score": "0.54614496", "text": "function removeHighlight(e){\n\t\tconsole.log(e);\n\n\t\t//if this isn't the transform transition, then quit.\n\t\tif(e.propertyName !== 'transform'){\n\t\t\treturn;\n\t\t} else { //it IS the transform transition! do stuff!\n\t\t\te.target.classList.remove('playing'); //take highlight back off\n\t\t}\n\t}", "title": "" }, { "docid": "2d6c2f22e9b5def4239413e32f9e063b", "score": "0.54594785", "text": "function mouseOUT(){\n\t$(this).removeClass('liShow');\n}", "title": "" }, { "docid": "bd16ce9abd3b942bd0df07bd5b23a7db", "score": "0.54528815", "text": "function limpar() {\n $(\".imgblur, .content\").removeClass(\"active\");\n}", "title": "" }, { "docid": "554036a691b4a1365ab02c626e205c99", "score": "0.5451859", "text": "function handleActiveClass(event) {\n event.target.parentElement.querySelectorAll(\".active\").forEach((el) => {\n el.classList.remove(\"active\");\n });\n event.target.classList.add(\"active\");\n}", "title": "" }, { "docid": "d4b8899a56bfdeb31deb85dab2b9bfc8", "score": "0.54428184", "text": "function unpressed (dom) {dom.style.boxShadow = \"0px 3px 10px 0px rgba(0,0,0,0.5)\";}", "title": "" }, { "docid": "34351763ce12a1fd5a717eb21c04c7e6", "score": "0.5436678", "text": "function hover() {\r\n\t\tif (changable(this.id)) {\r\n\t\t\tthis.className = \"tilesHover\";\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "1122047707abd9d2a8a1217d78d7cd85", "score": "0.5433719", "text": "function handleCardHover(event) {\r\n event.target[\"className\"] = \"\";\r\n setEditId(\"\");\r\n }", "title": "" }, { "docid": "ac98bac29a24005c3e35041a6f8a627c", "score": "0.5429665", "text": "function unbindMainHover () {\r\n\t\t\ts.mainPage.unbind('mouseenter.hoverIntent mouseleave.hoverIntent');\r\n\t\t}", "title": "" }, { "docid": "8fdb671e8637a60ea3e52485727a0485", "score": "0.5428905", "text": "function mouseup() {\n element.css({\n position: 'relative',\n backgroundColor: bg,\n cursor: curs,\n\t\t\t\t\tborder: brd,\n\t\t\t\t\topacity: op\n });\n $document.unbind('mousemove', mousemove);\n $document.unbind('mouseup', mouseup);\n }", "title": "" }, { "docid": "2e9f6c1775736f87e84586a923f564a2", "score": "0.5425209", "text": "onMouseUp(e) {}", "title": "" }, { "docid": "0dcf4f06ab68c0466b0e701751888d05", "score": "0.5425087", "text": "_styleTargetElementForStep(e){const t=ho(e);t&&(co(t),e.options.highlightClass&&t.classList.add(e.options.highlightClass),!1===e.options.canClickTarget&&(t.style.pointerEvents=\"none\"))}", "title": "" }, { "docid": "48a8aa0f42c8b3c95204665ecf5f661b", "score": "0.5423694", "text": "function selectedHoverClassStart(ref) {\n const { $top, $bottom, $topBack, $bottomBack } = ref;\n $bottom.addClass('hover-menu__bottom');\n $top.removeAttr('style');\n $bottomBack.removeAttr('style');\n ref.setAnimState('INIT');\n flipSelectedMenuStart(ref);\n}", "title": "" }, { "docid": "eed4e66b50c207b9c633065acc3c77c6", "score": "0.5419497", "text": "function taptouch() {\n $('.form li, .button').live('touchstart', function(e) {\n $(this).addClass('active');\n });\n $('.form li, .button').live('touchend', function(e) {\n $('li, .button').removeClass('active');\n });\n}", "title": "" }, { "docid": "308e4f6cae505158d4a1a7af81322c8a", "score": "0.5418643", "text": "dragLeave(event) {\n event.target.classList.remove(\"over-top\");\n event.target.classList.remove(\"over-bottom\");\n }", "title": "" }, { "docid": "a7c54c538b97581ea044b95412271e48", "score": "0.5418399", "text": "function paint(evt) {\r\n \treset();\r\n \tevt.currentTarget.className += \" active\";\r\n}", "title": "" }, { "docid": "abca7eb01be332b3a8f05fe55281d0f4", "score": "0.54088706", "text": "function onClassDropped() {\n console.log('onClassDropped was called');\n }", "title": "" }, { "docid": "e137f9d84a5e539aa2214ca1fad2fc2f", "score": "0.5406945", "text": "dragEnd(event) {\n event.target.classList.remove(\"over-top\");\n event.target.classList.remove(\"over-bottom\");\n }", "title": "" }, { "docid": "daec02f9af20067958702a866b566c8d", "score": "0.54063493", "text": "function mouseUp(event) {\n mouseIsDown = false;\n }", "title": "" }, { "docid": "ca0d02c97f58e7fd031e6654187631f8", "score": "0.5403364", "text": "function ActClick(){\n\t\t \n\t\t$('.speed-dial-opened').removeClass('speed-dial-opened');\n\t\t \n}", "title": "" }, { "docid": "684761997169c8d1b1b608736d5e19cb", "score": "0.5402084", "text": "function mouseEnter() {\n $(this).addClass('page-hover');\n }", "title": "" }, { "docid": "9df1a43d82f973c019251a702db86d94", "score": "0.5400677", "text": "clearHighlights() {\n $('.square-55d63').removeClass(`highlight1-32417`);\n }", "title": "" }, { "docid": "a96a7f093770a436e7cf99d8f92afbac", "score": "0.5399072", "text": "function breadCrumbMouseOut(element) {\r\n $(element).removeClass(\"breadcrumb-hover\");\r\n }", "title": "" } ]
16d834e7e3c0fae7eb82cc91d49a17ce
Query an element selector if it's not an element already.
[ { "docid": "e395eb75ec4fde10ccc6cfda5173a214", "score": "0.6697689", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n true && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" } ]
[ { "docid": "9e1237c4fdbceb5aab8865bdf90c29bb", "score": "0.68671334", "text": "function query (el) {\n\t if (typeof el === 'string') {\n\t var selector = el;\n\t el = document.querySelector(el);\n\t if (!el) {\n\t \"development\" !== 'production' && warn(\n\t 'Cannot find element: ' + selector\n\t );\n\t return document.createElement('div')\n\t }\n\t }\n\t return el\n\t}", "title": "" }, { "docid": "761bb604f81717f8e08323f775f405c1", "score": "0.68607736", "text": "function query (el) {\n\t if (typeof el === 'string') {\n\t var selected = document.querySelector(el);\n\t if (!selected) {\n\t process.env.NODE_ENV !== 'production' && warn(\n\t 'Cannot find element: ' + el\n\t );\n\t return document.createElement('div')\n\t }\n\t return selected\n\t } else {\n\t return el\n\t }\n\t}", "title": "" }, { "docid": "2a10904cc3d7cf8d460fde78f2a5b1d2", "score": "0.6858537", "text": "function query (el) {\n if (typeof el === 'string') {\n var selector = el;\n el = document.querySelector(el);\n if (!el) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + selector\n );\n return document.createElement('div')\n }\n }\n return el\n}", "title": "" }, { "docid": "2a10904cc3d7cf8d460fde78f2a5b1d2", "score": "0.6858537", "text": "function query (el) {\n if (typeof el === 'string') {\n var selector = el;\n el = document.querySelector(el);\n if (!el) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + selector\n );\n return document.createElement('div')\n }\n }\n return el\n}", "title": "" }, { "docid": "5c9d4723b5cd4f4feba36f1a42a76af3", "score": "0.6813305", "text": "function query(el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"none\" !== 'production' && Object(core_util_index__WEBPACK_IMPORTED_MODULE_0__[\"warn\"])('Cannot find element: ' + el);\n return document.createElement('div');\n }\n return selected;\n } else {\n return el;\n }\n}", "title": "" }, { "docid": "ccc2189c47980912498ca42c8e8ba51d", "score": "0.68086815", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n window.process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "3b51aa006251fd26ad244f7d929bd341", "score": "0.6798179", "text": "function query (el) {\r\n\t if (typeof el === 'string') {\r\n\t var selector = el;\r\n\t el = document.querySelector(el);\r\n\t if (!el) {\r\n\t (\"development\") !== 'production' && warn(\r\n\t 'Cannot find element: ' + selector\r\n\t );\r\n\t return document.createElement('div')\r\n\t }\r\n\t }\r\n\t return el\r\n\t}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "61e7c101b6b5a8ee6fc0ab00096446aa", "score": "0.6797346", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "f782532de74582e1ee848ac0080008b1", "score": "0.6793922", "text": "function query(el) {\n\t if (typeof el === 'string') {\n\t var selected = document.querySelector(el);\n\t if (!selected) {\n\t process.env.NODE_ENV !== 'production' && warn('Cannot find element: ' + el);\n\t return document.createElement('div');\n\t }\n\t return selected;\n\t } else {\n\t return el;\n\t }\n\t}", "title": "" }, { "docid": "9891e0242d4558657bb916b60096538c", "score": "0.67809474", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n process.env.NODE_ENV !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n }", "title": "" }, { "docid": "f772f44740d4ee0bbd4a7bdb28e56bf3", "score": "0.6725382", "text": "function query (el) {\n\t if (typeof el === 'string') {\n\t var selected = document.querySelector(el);\n\t if (!selected) {\n\t (\"development\") !== 'production' && warn(\n\t 'Cannot find element: ' + el\n\t );\n\t return document.createElement('div')\n\t }\n\t return selected\n\t } else {\n\t return el\n\t }\n\t}", "title": "" }, { "docid": "00569b3530b8ca594235d71ce196103c", "score": "0.67104435", "text": "function query(el){if(typeof el==='string'){var selector=el;el=document.querySelector(el);if(!el){\"development\"!=='production'&&warn('Cannot find element: '+selector);return document.createElement('div');}}return el;}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "023d5b85b0fcfb89d423859a2d4f93ff", "score": "0.6701253", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"development\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" }, { "docid": "243264c9c3a743e5842e189d050d62eb", "score": "0.66968733", "text": "function query (el) {\n if (typeof el === 'string') {\n var selected = document.querySelector(el);\n if (!selected) {\n \"production\" !== 'production' && warn(\n 'Cannot find element: ' + el\n );\n return document.createElement('div')\n }\n return selected\n } else {\n return el\n }\n}", "title": "" } ]
fc35c42e6433b5390fb45937148f3d22
This function initially draws the "game level", it then calls the renderEntities function. This function is called every game tick (or loop of the game engine) because that's how games work they are flipbooks creating the illusion of animation but in reality they are just drawing the entire screen over and over.
[ { "docid": "2d545af3f544344776c76b8827b9692a", "score": "0.7223969", "text": "function render() {\n /* This array holds the relative URL to the image used\n * for that particular row of the game level.\n */\n var rowImages = [\n 'images/score-board.png',\n 'images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png'\n ],\n numRows = 7,\n numCols = 5,\n row, col;\n\n /* Loop through the number of rows and columns defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n for (row = 1; row < numRows; row++) {\n for (col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n * We're using Resources helpers to refer to images to\n * get the benefits of caching these images, since\n * we're using them over and over.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 82);\n }\n }\n\n renderEntities();\n }", "title": "" } ]
[ { "docid": "af7552f56c06e11da62d4664cc026073", "score": "0.7807664", "text": "function render() {\n\n renderGameSurface();\n renderEntities();\n }", "title": "" }, { "docid": "f9eed01699bf5bd95817844e376a4e3e", "score": "0.75378346", "text": "function render() {\n\n if(gameState.current==='menu') {\n renderMenu();\n }\n else if(gameState.current==='game') {\n if(!complete) {\n renderSteps();\n renderWalls();\n renderLivesAndItems();\n renderEntities();\n }\n }\n else if(gameState.current==='end') {\n renderLivesAndItems();\n renderEnd();\n }\n }", "title": "" }, { "docid": "5a9e34418fc27270e7ee8ad7dad980f9", "score": "0.7427605", "text": "function renderEntities() {\n ctx.clearRect ( 0 , 0 , canvas.width, canvas.height);\n\n /* Loop through all of the objects within the allGirls array and call\n * the render function you have defined.\n */\n allGirls.forEach(function(girl) {\n girl.render();\n });\n //player.render();\n\n if (reset){\n canvas.addEventListener('click', init, false);\n Screen.gameover();\n //play();\n\n }\n }", "title": "" }, { "docid": "ce976ac725120838a5f56cf87a1360cf", "score": "0.73319995", "text": "function renderEntities() {\n //Rendering the enemies\n allEnemies.forEach(function(enemy) {\n if (enemy.position_x > 0 && enemy.position_y > 0 &&\n enemy.position_y < 10.1 && enemy.position_x < 10.1)\n enemy.onTopDraw();\n });\n //Rendering the pickups\n allPickUps.forEach(function(pickUp) {\n if (pickUp.type != -1)\n pickUp.onTopDraw();\n });\n //Rendering the player\n player.onTopDraw(player.position_x, player.position_y);\n }", "title": "" }, { "docid": "0a7d077b3036758d1f02a12ccb723250", "score": "0.73228914", "text": "function render() {\n\trenderID = requestAnimationFrame(render);\n\tif (loaded === 6) {\n\t\t// rotate the test cube\n\t\t//cube.rotation.x += 0.1;\n\t\t//cube.rotation.y += 0.1;\n\t\t\n\t\t//load the player & push him into 1st spot of entity array if needed\n\t\tif (!playerLoaded) {\n\t\t\tentities.push(initPlayer());\t\t//\tplayer object\n\t\t\tplayerLoaded = true;\n\t\t}\n\t\t\n\t\t// check for a levelup\n\t\tvar dateObj = new Date();\n\t\tvar currentTime = dateObj.getTime();\n\t\tif (currentTime > nextLevelTime) {\n\t\t\tlevel++;\n\t\t\tlevelDiv.innerHTML = level;\n\t\t\tlevelup = true;\n\t\t}\n\t\t\n\t\t// handle a levelup (or start of the game)\n\t\tif (levelup) {\n\t\t\tfor (var i = 0; i < snakesToGen(); i++) {\n\t\t\t\tentities.push(makeSnake(0));\n\t\t\t}\n\t\t\tnextLevelTime = currentTime + levelDuration * 1000;\n\t\t\tlevelup = false;\n\t\t}\n\t\t\n\t\t// handle player and snake turns\n\t\tplayerHandler();\n\t\tfor (var i = 1; i < entities.length; i++) {\n\t\t\tsnakeHandler(i);\n\t\t}\n\t}\n\trenderer.render(scene, camera);\n}", "title": "" }, { "docid": "c74879d5adb903a5e9ec0b394644f87c", "score": "0.7274496", "text": "function rendering(ctx) {\n render.renderGameGrid(ctx);\n render.renderEntities();\n render.renderGameInformation();\n // If game is over, will continue render grid, entities, and information,\n // but the end screen information will overlay it\n if (stateChecks.isGameOver() === true) {\n render.renderGameOverScreen(ctx);\n }\n}", "title": "" }, { "docid": "80cfe2d4486e3f79d85f95372a45b3b9", "score": "0.7211782", "text": "draw() {\n this.drawSide(true);\n this.drawSide(false);\n this.drawMain();\n this.tick = this.tick + 0.01;\n this.levelStats();\n }", "title": "" }, { "docid": "d10f639213e740615493982a6f9a4d46", "score": "0.71756494", "text": "function RenderFrame()\n{\n // Background\n background.Update();\n background.Draw(canvas);\n \n // Fighter. If the user is not currently moving the figher, make sure it\n // rolls back to it's centre position\n if(!fighterMoving)\n {\n fighter.RollToCentre();\n }\n fighter.Draw(canvas);\n \n // Bullets\n UpdateBullets();\n for(var i = 0; i < bullets.length; i++)\n {\n bullets[i].Draw(canvas);\n }\n \n // Enemies\n UpdateEnemies();\n if(enemies.length > 0)\n {\n for(var i = 0; i < enemies.length; i++)\n {\n enemies[i].Draw(canvas);\n }\n }\n else if(!fighter.destroyed)\n {\n // Create the next wave of enemies if the current wave has been destroyed\n StartNextLevel(); \n }\n\n TestForCollisions();\n \n // Explosions\n UpdateExplosions();\n for(var i = 0; i < explosions.length; ++i)\n {\n explosions[i].Draw(canvas);\n }\n\n // Update the canvas.\n canvas.Update();\n}", "title": "" }, { "docid": "27655023cf4f7b234042114d0cbcc874", "score": "0.7147025", "text": "function render() {\n //Clear out\n ctx.clearRect(0, 0, canvas.width, canvas.height);\n /* This array holds the relative URL to the image used\n * for that particular row of the game level.\n */\n var rowImages = [\n 'images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png' // Row 2 of 2 of grass\n ],\n numRows = 6,\n numCols = 5,\n row, col;\n\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the 'grid'\n */\n for (row = 0; row < numRows; row++) {\n for (col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 83 - 50);\n }\n }\n\n renderEntities();\n }", "title": "" }, { "docid": "079ab35b50610bf426f362c9b60ee134", "score": "0.7134701", "text": "function render() {\n /* This array holds the relative URL to the image used\n * for that particular row of the game level.\n */\n const rowImages = [\n 'images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png' // Row 2 of 2 of grass\n ];\n const numRows = 6;\n const numCols = 5;\n\n // Before drawing, clear existing canvas\n ctx.clearRect(0, 0, canvas.width, canvas.height);\n\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n for (let row = 0; row < numRows; row++) {\n for (let col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n * We're using our Resources helpers to refer to our images\n * so that we get the benefits of caching these images, since\n * we're using them over and over.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 83 + 15);\n }\n }\n\n // Draw components\n renderEntities();\n\n // update Player postion in case of collision or winning\n player.update();\n }", "title": "" }, { "docid": "2150721533726a540530db349062466a", "score": "0.7124615", "text": "function render() {\n /* This array holds the relative URL to the image used\n * for that particular row of the game level.\n */\n var rowImages = ['images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n\n /*'images/stone-block.png' this will add another row when ready*/\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png' // Row 2 of 2 of grass\n ],\n numRows = 6,\n numCols = 5,\n row,\n col; // Before drawing, clear existing canvas\n\n ctx.clearRect(0, 0, canvas.width, canvas.height);\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n\n for (row = 0; row < numRows; row++) {\n for (col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n * We're using our Resources helpers to refer to our images\n * so that we get the benefits of caching these images, since\n * we're using them over and over.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 83);\n }\n }\n\n renderEntities();\n }", "title": "" }, { "docid": "3ab7775de4c76aa2c6b565ccf9194bd1", "score": "0.708566", "text": "function draw() {\n Engine.update(engine);\n switch (gameState) {\n case START_GAME:\n startmenu.draw();\n break;\n case LEVEL_0:\n background(lvl0bgn);\n level0.draw();\n if (levelCompleted) {\n level0 = null;\n farmSFX.stop();\n level1 = new Level(canvas, level1data);\n gameState = LEVEL_1;\n levelCompleted = false;\n lvlStartSFX.play();\n spaceSFX.loop();\n }\n break;\n\n case LEVEL_1:\n background(lvl1bgn);\n level1.draw();\n if (levelCompleted) {\n level1 = null;\n spaceSFX.stop();\n level2 = new Level(canvas, level2data);\n gameState = LEVEL_2;\n levelCompleted = false;\n lvlStartSFX.play();\n beachSFX.loop();\n }\n break;\n case LEVEL_2:\n background(lvl2bgn);\n level2.draw();\n if (levelCompleted) {\n level2 = null;\n gameState = END_GAME;\n endSFX.play();\n }\n break;\n case END_GAME:\n textSize(100);\n stroke(255);\n fill(162, 86, 0);\n text('Game Over!', (width / 2) - 200, height / 2 - 140);\n break;\n }\n}", "title": "" }, { "docid": "45f589c24a83decc1d116f7e256ea493", "score": "0.708411", "text": "function render() {\n // Number of Columns and Rows that will be in the game.\n var numRows = 7,\n numCols = 11,\n row, col;\n\n gameWorld = [];\n for (row = 0; row < numRows; row++) {\n gameWorld.push([]);\n for (col = 0; col < numCols; col++) {\n var gameObject = new GameObject(matrix[row][col]);\n gameObject.baseDraw(col, row);\n gameWorld[row].push(gameObject);\n }\n\n }\n obs = [];\n for (row = 0; row < numRows; row++) {\n obs.push([]);\n for (col = 0; col < numCols; col++) {\n var gameObject = new GameObject(matrix_obs[row][col]);\n gameObject.onTopDraw(col, row);\n obs[row].push(gameObject);\n }\n\n }\n renderEntities();\n ctx.clearRect(0, 0, canvas.width, 50);\n }", "title": "" }, { "docid": "b6426f7fd84941a78697bcc089ae6750", "score": "0.707646", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n player.render();\n }", "title": "" }, { "docid": "1625d0dc89012f9fa089d4eeb54fee38", "score": "0.70695937", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n\n player.render();\n }", "title": "" }, { "docid": "222f4c5ad372d4e541190b200ebaf545", "score": "0.70644975", "text": "function render() {\n /* This array holds the relative URL to the image used\n * for that particular row of the game level.\n */\n var rowImages = [\n 'images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png' // Row 2 of 2 of grass\n ],\n numRows = 6,\n numCols = 5,\n row, col;\n\n // Before drawing, clear existing canvas\n ctx.clearRect(0,0,canvas.width,canvas.height);\n\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n for (row = 0; row < numRows; row++) {\n for (col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n * We're using our Resources helpers to refer to our images\n * so that we get the benefits of caching these images, since\n * we're using them over and over.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 83);\n }\n }\n\n ctx.drawImage(Resources.get('images/Selector.png'), 404, 321);\n\n renderEntities();\n }", "title": "" }, { "docid": "8ccdf5e38876b7eddcd69d09ecc4a692", "score": "0.7032428", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n player.render();\n if ((player.score > 10 && player.score % 5 === 0) && player.lives < 10) {\n heart.render();\n }\n if (player.score > 10 && isPrime(player.score)) {\n gem.render();\n }\n }", "title": "" }, { "docid": "c1e6b5c6d96f64aa4122b34a5ba899b3", "score": "0.7023067", "text": "function renderEntities() {\n\n allEnemies.forEach(function(enemy) { // loop through allEnemies array\n enemy.render();\n });\n\n player.render();\n\n gemBlue.render();\n gemGreen.render();\n gemOrange.render();\n\n }", "title": "" }, { "docid": "af094de9611a01b7428b6819947067d5", "score": "0.70011747", "text": "function render() {\n\n // flat background that changes color based on player state\n renderBackground();\n\n // show amount of life left in seconds\n var lifeString = clockString(Math.round(player.life));\n renderCountdown(lifeString);\n\n // render accumulated points\n renderPlayerPoints();\n\n // terrain assets from Udacity\n renderTerrain();\n\n // character assets\n renderEntities();\n }", "title": "" }, { "docid": "1f8d1f1b318e2ab2040e62cecbc4f4d5", "score": "0.6999829", "text": "function main_render()\r\n{\r\n\t// This is a hack screen clear.\r\n\t// When the canvas dimensions are changed the canvas will be instantly cleared. This\r\n\t// implementation was used due to it being faster than other methods.\r\n\t_canvas.width = SCREEN_WIDTH;\r\n\r\n\t// Call the render methods of all active game states.\r\n\tfor(let i = 0; i < activeGameStates.length; i++) {\r\n\t\tactiveGameStates[i].render.call(activeGameStates[i]);\r\n\t}\r\n}", "title": "" }, { "docid": "80cd56aba000ffa280e167409a525ac8", "score": "0.69895965", "text": "function render()\r\n {\r\n context.clearRect(0, 0, canvas.width, canvas.height);\r\n tileMap.render();\r\n playerSprite.render();\r\n }", "title": "" }, { "docid": "47ba0dabaebf3a61852e5f5b908c0234", "score": "0.69817483", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n\n allGems.forEach(function(gem) {\n gem.render();\n });\n\n player.render();\n }", "title": "" }, { "docid": "958776fda638be4c7210a446ffde77c9", "score": "0.6978642", "text": "render() {\r\n ASSERT(mainContext != this.context); // must call redrawEnd() after drawing tiles\r\n\r\n // flush and copy gl canvas because tile canvas does not use gl\r\n this.flushGLBeforeRender && glEnable && glCopyToContext(mainContext);\r\n\r\n // draw the entire cached level onto the main canvas\r\n const pos = worldToScreen(this.pos.add(vec2(0, this.size.y * this.scale.y)));\r\n mainContext.drawImage\r\n (\r\n this.canvas, pos.x, pos.y,\r\n cameraScale * this.size.x * this.scale.x, cameraScale * this.size.y * this.scale.y\r\n );\r\n }", "title": "" }, { "docid": "f9213e37cdbf451f3fa3c0e979232348", "score": "0.697846", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n ns.allEnemies.forEach(function (enemy) {\n enemy.render();\n });\n\n ns.rock.render();\n ns.reward.render();\n ns.player.render();\n\n }", "title": "" }, { "docid": "3995a39474b59e298dde95ee21a97c4f", "score": "0.69759554", "text": "draw()\n {\n // normal draw function for each entity. We didn't make this.\n this.ctx.clearRect(0, 0, this.surfaceWidth, this.surfaceHeight);\n this.ctx.save();\n for (let i = 0; i < this.entities.length; i++)\n {\n this.entities[i].draw(this.ctx);\n }\n this.ctx.restore();\n }", "title": "" }, { "docid": "1ee5a75a929c3fa7c6c20dbdaecff9ce", "score": "0.6962871", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function (enemy) {\n enemy.render();\n });\n player.render();\n }", "title": "" }, { "docid": "cf77a4c0909aa1195ee0bfedad8fd218", "score": "0.69550854", "text": "function Render() {\n\t\tList.foreach(states, function(state) { state.render.execute(); });\n\t\tList.foreach(persisting, function(state) { state.render.execute(); });\n\t\tStateManager.postRender();\n\t\tDebug.renderConsole();\n\t\t\n\t\tif (Debug.open) Debug.track(\"States: \" + states.length);\n\t\t\t\t\n\t\tif (alpha.value > 0) {\n\t\t\tif (alpha.value == 1) alpha.setup(1, 0, 500);\n\t\t\tcolor.alpha = alpha.value * 255;\n\t\t\tLib.font.drawText(0, 0, screenshot, color);\n\t\t}\n\t\t\n\t\tif (IsMapEngineRunning() && request_s) {\n\t\t\tSaveScreen();\n\t\t\trequest_s = false;\n\t\t}\n\n\t\tif (mouse) Mouse.draw(Lib.cursor);\n\t}", "title": "" }, { "docid": "fbdf593e073fa00bfa6977a75cbd430f", "score": "0.69493634", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n\n /* Add an event listener to the canvas element to listen for click events.\n * On start of game, user can select player displayed on canvas. Selection\n * is handled using canvas click event.\n */\n canvas.addEventListener(\"click\", checkCanvasClickPosition, false);\n\n // Render player only if user has selected player in this case if imageUrl has value.\n if(imageUrl !== null) {\n player.render(imageUrl);\n }\n\n /* To update score on each tick and display on canvas menu.\n */\n ctx.drawImage(Resources.get('images/gap-filler.jpg'), 202, 50);\n\n ctx.font = \"bold 24pt Arial\";\n ctx.textAlign = \"center\";\n ctx.fillStyle = \"#4A4A4A\";\n ctx.fillText(\"FROGGER\",248,40);\n\n ctx.font = \"bold 12pt Arial\";\n ctx.textAlign = \"center\";\n ctx.fillStyle = \"black\";\n ctx.fillText('SCORE',250,80);\n\n ctx.font = \"bold 14pt Arial\";\n ctx.fillText(score,250,125);\n }", "title": "" }, { "docid": "1b6d3b120a89c2182b482068f0109102", "score": "0.694236", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n\n player.render();\n }", "title": "" }, { "docid": "406a98a6be99b8bdd1f41ce8d3a8a5d4", "score": "0.6925983", "text": "le_render() {\n\t\t// clear entire game area to start a new frame\n\t\tthis.ctx.clearRect(0, 0, canvasWidth, canvasHeight);\n\t\t// scroll map\n\t\tthis.wrapper.scrollLeft = this.editor.getComponent(\"transform\").pos.x;\n\t\tthis.wrapper.scrollTop = this.editor.getComponent(\"transform\").pos.y - 20;\n\t\t// draw all entities at their position given by CTransform\n\t\tlet decs = this.entityManager.getEntities(\"dec\");\n\t\tfor (let i in decs) {\n\t\t\tlet d = decs[i];\n\t\t\tlet x = d.getComponent(\"transform\").pos.x;\n\t\t\tlet y = d.getComponent(\"transform\").pos.y;\n\t\t\tlet sX = d.getComponent(\"boundingBox\").size.x;\n\t\t\tlet sY = d.getComponent(\"boundingBox\").size.y;\n\t\t\tlet img = assets.getMap(d.getComponent(\"id\").id);\n\t\t\tthis.ctx.drawImage(img, x, y, sX, sY);;\n\t\t}\n\t\tlet tiles = this.entityManager.getEntities(\"tile\");\n\t\tfor (let i in tiles) {\n\t\t\tlet t = tiles[i];\n\t\t\tlet x = t.getComponent(\"transform\").pos.x;\n\t\t\tlet y = t.getComponent(\"transform\").pos.y;\n\t\t\tlet sX = t.getComponent(\"boundingBox\").size.x;\n\t\t\tlet sY = t.getComponent(\"boundingBox\").size.y;\n\t\t\tlet img = assets.getTexture(t.getComponent(\"id\").id);\n\t\t\tthis.ctx.drawImage(img, x, y, sX, sY);\n\t\t}\n\t\tlet enemies = this.entityManager.getEntities(\"enemy\");\n\t\tfor (let i in enemies) {\n\t\t\tlet e = enemies[i];\n\t\t\tlet x = e.getComponent(\"transform\").pos.x;\n\t\t\tlet y = e.getComponent(\"transform\").pos.y;\n\t\t\tlet img = assets.getEnemy(e.getComponent(\"id\").id).idle[0];\n\t\t\tthis.ctx.drawImage(img, x - 80, y - 60, 78 * 3, 49 * 3);\n\t\t}\n\t\t// draw player spawn point and finish point\n\t\tlet sPos = this.entityManager.getEntities(\"spawn\")[0].getComponent(\"transform\").pos;\n\t\tlet ePos = this.entityManager.getEntities(\"end\")[0].getComponent(\"transform\").pos;\n\t\tthis.ctx.drawImage(assets.getPlayer(\"idle\")[0], 55, 85, 85, 25, sPos.x, sPos.y - 13, 255, 75);\n\t\tthis.ctx.drawImage(assets.getFinish()[0], ePos.x, ePos.y, 100, 200);\n\t\t// draw level editor UI\n\t\tif (this.tileUI.getComponent(\"status\").status) {\n\t\t\tthis.ctx.fillStyle = \"black\";\n\t\t\tthis.ctx.fillRect(this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y - 10, 840, 80);\n\t\t\tlet editUIs = this.entityManager.getEntities(\"editUI\");\n\t\t\tthis.ctx.fillStyle = \"orange\";\n\t\t\tfor (let i in editUIs) {\n\t\t\t\tlet e = editUIs[i];\n\t\t\t\tlet x = e.getComponent(\"transform\").pos.x;\n\t\t\t\tlet y = e.getComponent(\"transform\").pos.y;\n\t\t\t\tlet sX = e.getComponent(\"boundingBox\").size.x;\n\t\t\t\tlet sY = e.getComponent(\"boundingBox\").size.y;\n\t\t\t\tthis.ctx.fillRect(x, y, sX, sY);\n\t\t\t}\n\t\t\tthis.ctx.fillStyle = \"#DE1212\";\n\t\t\tthis.ctx.font = \"10px Arial\";\n\t\t\tlet sText = (this.pSpawnPointSet) ? \"Finish Point\" : \"Spawn Point\";\n\t\t\tthis.ctx.fillText(\"Tile\", this.tileUI.getComponent(\"transform\").pos.x, this.tileUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Background\", this.decUI.getComponent(\"transform\").pos.x, this.decUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Enemy\", this.enemyUI.getComponent(\"transform\").pos.x, this.enemyUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Moving Enemy\", this.mEnemyUI.getComponent(\"transform\").pos.x, this.mEnemyUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(sText, this.spawnUI.getComponent(\"transform\").pos.x, this.spawnUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Delete\", this.deleteUI.getComponent(\"transform\").pos.x, this.deleteUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Save\", this.saveUI.getComponent(\"transform\").pos.x, this.saveUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Load\", this.loadUI.getComponent(\"transform\").pos.x, this.loadUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Snap to Grid\", this.snapUI.getComponent(\"transform\").pos.x, this.snapUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Moving Tile\", this.mTileUI.getComponent(\"transform\").pos.x, this.mTileUI.getComponent(\"transform\").pos.y + 60);\n\t\t\tthis.ctx.fillText(\"Instructions\", this.instructionUI.getComponent(\"transform\").pos.x, this.instructionUI.getComponent(\"transform\").pos.y + 60);\n\t\t}\n\t\t// draw currently active asset at mouse pointer\n\t\tlet x = this.editor.getComponent(\"mouse\").current.x - 25;\n\t\tlet y = this.editor.getComponent(\"mouse\").current.y - 25;\n\t\tlet sX = 50;\n\t\tlet sY = 50;\n\t\tlet aPos = (this.snapUI.getComponent(\"status\").status) ? this.getSnapLocation(x, y) : { x: x, y: y };\n\t\tlet img = assets.getTexture(1);\n\t\tif (this.editor.getComponent(\"state\").state === \"tile\" || this.editor.getComponent(\"state\").state === \"mTile\") {\n\t\t\timg = assets.getTexture(this.editor.getComponent(\"id\").id);\n\t\t\tthis.ctx.drawImage(img, aPos.x, aPos.y, sX, sY);\n\t\t}\n\t\telse if (this.editor.getComponent(\"state\").state === \"dec\") {\n\t\t\timg = assets.getMap(this.editor.getComponent(\"id\").id)\n\t\t\tsX = canvasWidth;\n\t\t\tsY = canvasHeight;\n\t\t\tthis.ctx.drawImage(img, aPos.x, aPos.y, sX, sY);\n\t\t}\n\t\telse if (this.editor.getComponent(\"state\").state === \"enemy\" || this.editor.getComponent(\"state\").state === \"mEnemy\") {\n\t\t\timg = assets.getEnemy(this.editor.getComponent(\"id\").id).idle[0];\n\t\t\tthis.ctx.drawImage(img, aPos.x - 80, aPos.y - 60, 78 * 3, 49 * 3);\n\t\t}\n\t\telse if (this.editor.getComponent(\"state\").state === \"spawn\") {\n\t\t\tif (!this.pSpawnPointSet) {\n\t\t\t\timg = assets.getPlayer(\"idle\")[0];\n\t\t\t\tthis.ctx.drawImage(img, 55, 85, 85, 25, aPos.x, aPos.y - 13, 255, 75);\n\t\t\t}\n\t\t\telse {\n\t\t\t\timg = assets.getFinish()[0];\n\t\t\t\tthis.ctx.drawImage(img, aPos.x, aPos.y, 100, 200);\n\t\t\t}\n\t\t}\n\t\t// draw instructions if their display is toggled on\n\t\tif (this.instructionUI.getComponent(\"status\").status) {\n\t\t\tthis.ctx.font = \"20px Arial\";\n\t\t\tthis.ctx.fillStyle = \"black\";\n\t\t\tthis.ctx.fillRect(this.editor.getComponent(\"transform\").pos.x, this.editor.getComponent(\"transform\").pos.y + 70, 1000, 520);\n\t\t\tthis.ctx.fillStyle = \"white\";\n\t\t\tthis.ctx.fillText(\"- Click Tile/Background/Enemy to select an asset (shown at cursor position)\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 100);\n\t\t\tthis.ctx.fillText(\"- Click the Delete box then click an asset on the map to delete it\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 140);\n\t\t\tthis.ctx.fillText(\"- Click on Save to save your level and load to load a previously created level\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 180);\n\t\t\tthis.ctx.fillText(\"- Click on snap to grid to toggle the snap to grid setting\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 220);\n\t\t\tthis.ctx.fillText(\"- To place a moving tile/enemy, first click on the moving tile then click somewhere on the\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 260);\n\t\t\tthis.ctx.fillText(\" map to set the first position then another place to set the second position\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 300);\n\t\t\tthis.ctx.fillText(\"- use the scroll wheel to change assets for each category (tiles, backgrounds, enemies, moving tiles)\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 340);\n\t\t\tthis.ctx.fillText(\"- press the 'q' key to remove selected asset from cursor and press 'Esc' key to go back to the main menu\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 380);\n\t\t\tthis.ctx.fillText(\"- press WASD keys to move around the map\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 420);\n\t\t\tthis.ctx.fillText(\"- Click on instructions to toggle instructions display\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 460);\n\t\t\tthis.ctx.fillText(\"- press the 'r' key to hide the UI\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 500);\t\t\n\t\t\tthis.ctx.fillText(\"- click spawn point, then on the map to set the position where the player will first spawn,\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 540);\n\t\t\tthis.ctx.fillText(\" then use finish point to set the position the player needs to reach to beat the level!\", this.editor.getComponent(\"transform\").pos.x + 30, this.editor.getComponent(\"transform\").pos.y + 580);\n\t\t}\n\t}", "title": "" }, { "docid": "3144ce58e99bbcec28f68d24d71bd417", "score": "0.68975586", "text": "function render() {\n\t\t// Order of Load Determines the Layer Order\n\n\t\t// Clear Canvas\n\t\tctx.clearRect(0,0, canvas.width, canvas.height);\n\t\t// Check for Collision Events for All Objects and Map\n\t\tcollisionCheck();\n\n\n\t\t// Loop render function via requestAnimationFrame\n\t\t// Animates Map Movement\n\t\tmoveMap();\n\t\t// collisionMapMove();\n\n\t\t// Checks if character is in jump state and begins jump animation\n\t\tcharJump();\n\n\t\t// Move State Updates into Collison JS File\n\n\t\t// Check if Character Hits Map FLoor, if true, stop the jump physics\n\t\tif (rogueBot.positionY >= gMO.mapFloor && !(keyPressState == true)) {\n\t\t\trogueBot.state = \"idle\"\n\t\t\trogueBot.positionY = gMO.mapFloor;\n\t\t}\n\n\t\tupdateTime();\t\n\t\tupdateKills();\n\t\tdebugTable();\n healthBarUpdate();\n \n\n\n\t\t// Initiates Animation Render Loop\n\t\trenderAnim();\t\n\n\t\t// Check Enemy Deaths\n\t\tenemyCheck()\n\n\t\t// Check if Game Ends\n\t\tcheckGameEnd();\n\t\tif (gameRun) {\n\t\t\trequestAnimationFrame(render);\n\t\t}\n\t\t\n\t}", "title": "" }, { "docid": "429d087d0ac3562cedece4bc2fa9a262", "score": "0.6888278", "text": "function drawEverything() {\n if (level !== 5) {\n // draw bg\n drawCustomImage(cxt, \"./images/background.png\", 0, 0, 800, 600)\n\n // iterate through lasers\n for( var laser in laserPos){\n drawLaser(laserPos[laser].x1, laserPos[laser].y1, laserPos[laser].x2, laserPos[laser].y2)\n }\n\n // iterate through obstacles\n for (var obstacle in obstaclePos) {\n drawObstacle(obstaclePos[obstacle].x, obstaclePos[obstacle].y, obstaclePos[obstacle].width, obstaclePos[obstacle].height)\n }\n\n // render goal\n drawCustomImage(cxt, \"./images/microchip.png\", goalPos.x, goalPos.y, goalSize, goalSize)\n\n\n // render character\n drawCustomImage(cxt, \"./images/robot.png\", spyPos.x, spyPos.y, spySize, spySize)\n } else {\n drawCustomImage(cxt, \"./images/winScreen.png\", 0, 0, 800, 600)\n\n }\n\n}", "title": "" }, { "docid": "20d25dccdde31b3f3d6d9341690b6d15", "score": "0.6884801", "text": "function render() {\n renderBlocks();\n /* Clear Hearts and Score to prevent overlapping */\n ctx.clearRect(0, -5, 505, 55);\n renderEntities();\n }", "title": "" }, { "docid": "7edf88e7bad13cbee0a1987987ae25b4", "score": "0.6848708", "text": "function renderSimulation(ctx) {\n\n if (g_useDeveloper) {\n if (eatKey(KEY_LINE_UP)) {\n ctx.lineWidth++;\n }\n if (eatKey(KEY_LINE_DOWN)) {\n ctx.lineWidth--;\n }\n }\n\n mapManager.render(ctx);\n if (!g_startGame) menuManager.render(ctx);\n stateManager.render(ctx);\n minigameManager.render(ctx);\n entityManager.render(ctx);\n eventManager.render(ctx);\n audioManager.render(ctx);\n\n // Max priority, options and messages\n stateManager.priorityRender(ctx);\n\n if (g_renderSpatialDebug) spatialManager.render(ctx);\n}", "title": "" }, { "docid": "9f63ef24536b9f967e57deb71efd137f", "score": "0.6843144", "text": "function render() {\n /* This array holds the relative URL to the image used\n * for that particular row of the game level.\n */\n var rowImages = [\n 'images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png' // Row 2 of 2 of grass\n ],\n numRows = 6,\n numCols = 5,\n row, col;\n\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n for (row = 0; row < numRows; row++) {\n for (col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n * We're using our Resources helpers to refer to our images\n * so that we get the benefits of caching these images, since\n * we're using them over and over.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 83);\n }\n }\n\n renderEntities();\n renderText();\n }", "title": "" }, { "docid": "8f21a5f9a614260472bca6b723416a21", "score": "0.6815458", "text": "function renderEntities() {\n allTombs.forEach(function(tomb) {\n tomb.render();\n });\n\n allEnemies.forEach(function(enemy) {\n enemy.render();\n }); \n\n player.render();\n }", "title": "" }, { "docid": "d22e1d7383cc69536d3e7cec0b418321", "score": "0.6794987", "text": "function render()\n{\n renderBackground();\n renderObstacles();\n renderCharacter();\n renderForeground();\n}", "title": "" }, { "docid": "202ffaac51aa61aae55ba8442472e4e6", "score": "0.67913616", "text": "function render()\n {\n map.drawBaseLayerSection( ctx, map.x, map.y, size.w, size.h, 0, 0, size.w, size.h );\n map.drawObjectsAnimated( ctx, map.x, map.y, size.w, size.h );\n \n player.render();\n \n enimy.render( map );\n \n enimy2.render( map );\n \n map.drawMiddleLayerSection( ctx, map.x, map.y, size.w, size.h, 0, 0, size.w, size.h );\n \n GUI.drawGUI( ctx );\n }", "title": "" }, { "docid": "221581ed2f272f5739204cf10d971b99", "score": "0.67833954", "text": "function paint()\n {\n\tif(gameRunning == 1)\n\t{\n\t RenderMyGame(ctx);\n\t}else{\n\t RenderMain();\n\t}\n }", "title": "" }, { "docid": "105164dd7637d21be0b55e3b982e9357", "score": "0.67800725", "text": "function renderGame() {\n if (updatesToPaint == 0) {\n console.log(\"ERROR: render called but not ready to paint\");\n } else {\n if (updatesToPaint > 1) {\n console.log(\"WARNING: render missed \" + (updatesToPaint - 1) + \" frame(s)\");\n }\n renderBackground();\n ctx.fillStyle = '#000';\n ball.render();\n slimeLeft.render();\n slimeRight.render();\n updatesToPaint = 0;\n }\n}", "title": "" }, { "docid": "6f1d3eb01d16a0c15131173e7d071915", "score": "0.6760929", "text": "function render() {\n\t if(stopped || scene.contextLost) {\n\t return\n\t }\n\t requestAnimationFrame(render)\n\t redraw()\n\t }", "title": "" }, { "docid": "04986060de1c91a1846b9a22ebedb924", "score": "0.67583203", "text": "function render() {\n gl.clearColor(1.0, 1.0, 1.0, 1.0);\n gl.enable(gl.DEPTH_TEST);\n gl.clear(gl.COLOR_BUFFER_BIT | gl.DEPTH_BUFFER_BIT);\n\n drawScene(gl, app.models.box);\n drawScene(gl, app.models.monkey);\n\n requestAnimationFrame(render);\n }", "title": "" }, { "docid": "2f35f62756c0b63a8fc9fc1068ad27d9", "score": "0.67545074", "text": "function render() {\n\t// Clear screen\n\tctx.clearRect ( 0 , 0 , canvas.width , canvas.height );\n\n\t// Draw player color/pattern\n\tdrawPlayerColor();\n\n\t// Draw mode-specific elements\n\tswitch (currentMode) {\n\t\tcase 'main':\n\t\t\tdrawTimeDots();\n\t\t\tdrawStageCounter();\n\t\t\tdrawPlayerColorScales();\n\t\t\tbreak;\n\t\tcase 'menu':\n\t\t\tdrawMenu();\n\t\t\tbreak;\n\t\tcase 'results':\n\t\t\tdrawResults();\n\t\t\tbreak;\n\t}\n\n\t// Draw touch guides if player is on mobile\n\tif (onMobile) {\n\t\tdrawTouchGuides();\n\t}\n\n\t// Draw fade\n\tif (fadePattern) {\n\t\tctx.fillStyle = 'rgba(255,255,255,' + screenAlpha + ')';\n\t\tctx.fillRect(0,0,canvas.width, canvas.height);\n\t}\n}", "title": "" }, { "docid": "9ac253e2f7e0c1b87e5ad81857b1d424", "score": "0.67380697", "text": "draw() {\n this.ctx.clearRect(0, 0, window.innerWidth, window.innerHeight);\n this.cometAnimator.draw(this.ctx);\n this.cometFastAnimator.draw(this.ctx);\n }", "title": "" }, { "docid": "52bea1663ea0a09b0d8f584133fb3645", "score": "0.6737428", "text": "function render() {\n if(stopped || scene.contextLost) {\n return\n }\n requestAnimationFrame(render)\n redraw()\n }", "title": "" }, { "docid": "599715b9f307ef268b5bfc85737c3379", "score": "0.6723707", "text": "function draw() {\n drawBackground();\n drawFinalBoss();\n animateGameStartNFinish();\n updateCharacter();\n requestAnimationFrame(draw);\n }", "title": "" }, { "docid": "5be4e16c5d2b795f1204e8de89ab924d", "score": "0.6711995", "text": "function render(){\n\t\t\tgame.contextBackground.clearRect(0, 0, game.width, game.height);\n\t\t\tgame.frames++;\n\t\t}", "title": "" }, { "docid": "cb03300ebda34f5ea9060c1a3fcbe608", "score": "0.66954535", "text": "function draw() {\n\t\tctx.clearRect(0, 0, canvas.width, canvas.height);\n\t\tdrawEntities();\n\t\tspawnEnemies();\n\t\tspawnPowerUp();\n\t\tdrawPowerUps();\n\t\t//checks for a gameOver\n\t\tcheckGameOver();\n\t\t//check for collision between player and enemies\n\t\tfor(var i = 1; i < listOfEntities.length;i++){\n\t\t\tcollisionDetection(listOfEntities[0],listOfEntities[i]);\n\t\t}\n\t\t//move entities\n\t\tfor(var i = 1; i < listOfEntities.length;i++){\n\t\t\tmoveTowardsPlayer(listOfEntities[i]);\n\t\t}\n\t\t//movement\n\t\tif(rightPressed && player.x < canvas.width-player.width) {\n\t\t\tplayer.x += player.speed;\n\t\t\tlastPlayerMove = \"Left\";\n\t\t}\n\t\telse if(leftPressed && player.x > 5) {\n\t\t\tplayer.x -= player.speed;\n\t\t\tlastPlayerMove = \"Right\";\n\t\t}\n\t\telse if(upPressed && player.y > 5) {\n\t\t\tplayer.y -= player.speed;\n\t\t\tlastPlayerMove = \"Up\";\n\t\t}\n\t\telse if(downPressed && player.y < canvas.height-player.height) {\n\t\t\tplayer.y += player.speed;\n\t\t\tlastPlayerMove = \"Down\";\n\t\t}\n\t\telse{\n\t\t\t//no other options\n\t\t}\n\t\tpowerUpTimer++;\n\t\tif(!gameOver)\n\t\t\tseconds += .01;\n\t}", "title": "" }, { "docid": "f154090ae5b0f70394eff9432862e005", "score": "0.6689696", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allEnemies.forEach(function(enemy) {\n enemy.render();\n });\n\n if (player.state === \"collide\" || player.state ===\"success\") {\n //balloon.update(player.state, player.x, player.y);\n balloon.render();\n }\n\n player.render();\n\n\n // speech balloons here?\n }", "title": "" }, { "docid": "9f5d498d895dc6e850a85e84c52e428a", "score": "0.668029", "text": "function render() {\n graphics.clear();\n\n renderer.Tiles.render();\n\n renderer.Manager.render(myParticles);\n\n for (let i = 0; i < multiAsteroids.length; i++) {\n renderer.Asteroid.render(multiAsteroids[i].model, multiAsteroids[i].texture);\n }\n\n for (let i = 0; i < multiUfoLasers.length; i++) {\n renderer.Laser.render(multiUfoLasers[i].model, multiUfoLasers[i].texture);\n }\n\n for (let i = 0; i < multiUfos.length; i++) {\n renderer.Ufo.render(multiUfos[i].model, multiUfos[i].texture);\n }\n\n for (let i = 0; i < multiLasers.length; i++) {\n renderer.Laser.render(multiLasers[i].model, multiLasers[i].texture);\n }\n\n for (let i = 0; i < multiPowerups.length; i++) {\n renderer.Powerup.render(multiPowerups[i].model, multiPowerups[i].texture);\n }\n\n renderer.Player.render(playerSelf.model, playerSelf.texture);\n for (let id in playerOthers) {\n let player = playerOthers[id];\n if(player.model.state.name != '' && player.model.state.name != undefined && player.model.state.playerNumber != null) {\n renderer.PlayerRemote.render(player.model, player.texture);\n }\n }\n renderer.Player.render(playerSelf.model, playerSelf.texture);\n\n var c = document.getElementById(\"canvas-main\");\n var ctx = c.getContext(\"2d\");\n\n ctx.save();\n\n ctx.fillStyle = 'lightblue'\n ctx.fillRect(250, 10, hyperspaceTime / 30, 20);\n\n ctx.fillStyle = 'black';\n ctx.font = '12pt Arial';\n ctx.lineWidth = .2;\n ctx.textBaseline = 'top';\n ctx.fillText(\"Hyperspace\", 260, 12);\n ctx.restore();\n }", "title": "" }, { "docid": "6a811e25ffb221f904b7183b6966fe37", "score": "0.66801786", "text": "function drawScene(){\n\tctx.clearRect(0, 0, 1000, 640);\n\tdrawHUD();\n\tdrawSpaceShip();\n\tdrawPlatforms();\n\n\t//draw the thruster flames\n\tif(up){\n\t\tdrawFlame();\n\t}\n\tif(left){\n\t\tdrawRightFlame();\n\t}\n\tif(right){\n\t\tdrawLeftFlame();\n\t}\n\n\tdrawVector();\n}", "title": "" }, { "docid": "156503c598a9097a167c5d1bd9b99b96", "score": "0.6674355", "text": "renderScene() {\n // Before drawing, clear existing canvas\n this.renderCtx.clearRect(0, 0, Resources.getConstants().world.size.width, Resources.getConstants().world.size.height);\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n for (let row = 0; row < GUIRenderer.numRows; row++) {\n for (let col = 0; col < GUIRenderer.numCols; col++) {\n this.renderCtx.drawImage(Resources.getFromCache(GUIRenderer.rowImages[row]), col * Resources.getConstants().world.moveOffset.x, row * Resources.getConstants().world.moveOffset.y);\n }\n }\n this.renderEntities();\n }", "title": "" }, { "docid": "1dcf6c0b247ac4fa388016483e001fe8", "score": "0.6670318", "text": "function draw() {\n // draws background rooms and handles movement from one to another\n adventureManager.draw();\n\n // drawCharacters();\n\n // don't draw them on first few screens\n if( adventureManager.getStateName() === \"Splash\" ||\n adventureManager.getStateName() === \"Instructions\" ||\n adventureManager.getStateName() === \"Characters\" ) {\n ;\n }\n // else {\n // drawCharacters();\n // }\n \n // draw the p5.clickables, in front of the mazes but behind the sprites \n clickablesManager.draw();\n}", "title": "" }, { "docid": "e7f5517fb8f41c853f220a1e7e0c50d8", "score": "0.6669293", "text": "function draw() {\n drawScene();\n setTimeout(draw, 16.7);\n }", "title": "" }, { "docid": "f7dd3c3e095aa6e13c5d4fa877e613e5", "score": "0.6663631", "text": "render() {\n ctx.drawImage(Resources.get(this.sprite), this.x, this.y);\n this.displayGemCount();\n this.displayLivesCount();\n this.displayScoreCount();\n\n //if the game is over, game over message is displayed\n if(this.lives <= 0) {\n this.win = true;\n this.displayGameWin();\n } else {\n this.win = false;\n }\n }", "title": "" }, { "docid": "5f9db9f280474e9c11ed5c517cc022f9", "score": "0.6660119", "text": "function renderEntities() {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined.\n */\n allTreasures.forEach(function(Treasure) {\n Treasure.render();\n });\n allEnemies.forEach(function(Enemy) {\n Enemy.render();\n });\n\n player.render();\n if (pWin) { //attaching winning text to the player\n winText.x = player.centerX;\n winText.y = player.centerY - 40;\n winText.render(0, 0, wStyle);\n };\n if (pDie) { //attaching dying text to the player\n dieText.x = player.centerX;\n dieText.y = player.centerY - 40;\n dieText.render(0, 0, dieStyle);\n };\n }", "title": "" }, { "docid": "d7c0160d4584dc784e0713f2ec73d8e3", "score": "0.66255814", "text": "function render() {\n requestAnimationFrame(render);\n detectCollision(scene.getCamera());\n stats.update();\n scene.animate();\n renderer.render(scene, scene.getCamera());\n scene.simulate();\n}", "title": "" }, { "docid": "8883d56ed36b11fbe0051b3985215a7e", "score": "0.6622345", "text": "function gameTick()\n{\n\tticks++;\n\tprocessKeyboard();\n\tupdateLogic();\n\n\t// Need to look into seperating the Render off into using updateAnimation\n\tdrawScene();\n}", "title": "" }, { "docid": "32ab2eb52ebb98d768384507d93471ee", "score": "0.6617342", "text": "function renderSimulation(ctx) {\n bricksRender(ctx);\n powerRender(ctx);\n g_ball.render(ctx);\n if(g_p2Enable){g_ball2.render(ctx);}\n /* for some reason in the first render the g_player1Sprite is not loaded\n eventhough it is forced in the preloader talked to t.a about this\n we thought it was wierd */\n //if(!g_player1Sprite){ return; }\n g_paddle1.render(ctx);\n if(g_p2Enable){g_paddle2.render(ctx);}\n}", "title": "" }, { "docid": "8377338b0bee9d64c0990267d5007432", "score": "0.66160697", "text": "function render () {\n if(gameMode == 0){\n //game.debug.renderText(game.time.fps, 100, 100)\n }\n if(gameMode == 1){\n\n }\n}", "title": "" }, { "docid": "3d99475d37f258355f20d92d533dae70", "score": "0.66118103", "text": "function render() {\n\n // Draw background color\n renderingContext.fillRect(0, 0, width, height);\n\n // Draw background sprites\n backgroundSprite.draw(renderingContext, 0, height - backgroundSprite.height);\n backgroundSprite.draw(renderingContext, backgroundSprite.width, height - backgroundSprite.height);\n\n corals.draw(renderingContext);\n fish.draw(renderingContext);\n\n if (currentState === states.Score) {\n okButtonSprite.draw(renderingContext, okButton.x, okButton.y);\n }\n\n // Draw foreground sprites\n foregroundSprite.draw(renderingContext, foregroundPosition, height - foregroundSprite.height);\n foregroundSprite.draw(renderingContext, foregroundPosition + foregroundSprite.width, height - foregroundSprite.height);\n}", "title": "" }, { "docid": "7c65c96dc4b7813751b4af4fa9c4f00d", "score": "0.6608928", "text": "function render() {\r\n\t// draw back to front\r\n\tcontext.fillStyle = \"black\";\r\n\tcontext.fillRect(0,0,canvas.width,canvas.height);\r\n\tbg_layer.draw();\r\n\thealth_indicator.draw();\r\n\tplayer.draw();\r\n\tfor (a = 0; a < col_list.length; a++) {\r\n\t\tcol_list[a].draw();\r\n\t}\r\n\tball.draw();\r\n\tfor (a = 0; a < hazard_list.length; a++) {\r\n\t\thazard_list[a].draw();\r\n\t}\r\n\tcontext.fillStyle = \"white\";\r\n\tcontext.textAlign = \"start\";\r\n\tcontext.fillText(\"Score: \" + score, 20, 20);\r\n}", "title": "" }, { "docid": "6a3c113116fc0e673ef93a0e6e5389e9", "score": "0.660536", "text": "function renderSimulation(ctx) {\n if (gameFlowManager.getStatus() === 'menu')\n menuManager.render(ctx);\n else if (gameFlowManager.getStatus() === 'levelOne')\n entityManager.render(ctx);\n else if (gameFlowManager.getStatus() === 'levelTwo')\n entityManager.render(ctx);\n\n if (g_renderSpatialDebug) spatialManager.render(ctx);\n}", "title": "" }, { "docid": "1b1991e878a1895b5fd4950aa6e3b191", "score": "0.65973324", "text": "function drawLevelScene(context){\r\n\t\t//se pinta el fondo y el caldero\t\t\r\n\t\tdrawBackground();\t\t\r\n\t\t\r\n\t\t//pinta los elementos de la escena\r\n\t\tfor(var i = 0; i < sceneElements.length; i++){ \r\n\t\t\tsceneElements[i].draw(context);\r\n\t\t}\r\n\t\t\t\r\n\t\t//pinta el nivel en el que nos encontramos y las vidas.\r\n\t\tdrawHUD();\t\t\t\r\n\t\t\r\n\t\t//pinta las comidas que del suelo\t\t\r\n\t\tfor(var i = 0; i < foods.length; i++){ \r\n\t\t\tfoods[i].draw(context);\r\n\t\t}\t\t\t\r\n\t\t\r\n\t\t//pinta los las comidas que han sido lanzadas\r\n\t\tfor(var i = 0; i < fThrown.length; i++){ \r\n\t\t\tfThrown[i].draw(context);\r\n\t\t}\r\n\t\t\r\n\t\t//pinta las recetas y la cantidad de ingredientes\r\n\t\tcurrentRecipe.draw(context); \r\n\t\tdrawQuantity();\r\n\t\t\r\n\t\t//pinta el numero de recetas restantes y el contador de tiempo\r\n\t\tUIController.drawRecipesLeft(10,160, recipesLeft);\t\t\r\n\t\tUIController.drawTime(1150,450,timeLimit-Math.floor(crono));\r\n\t\t\r\n\t\t//pinta la barra de separacion del cielo y la tierra\r\n\t\tanimatorM.play(animMiddle, context, 640, 340);\r\n\t\t\r\n\t\t//*************\r\n\t\t//Pinta el suelo por encima de todo\r\n\t\t\r\n\t\tvar m = 640 - floorSpr.width/2;\r\n var n = 740 - floorSpr.height/2;\r\n\t\t\r\n context.drawImage(floorSpr,m,n);\t\r\n\t\t\r\n\t\t//Si has perdido o ganado pinta sus respectivos menus\r\n\t\tif(win){\r\n\t\t\tdrawWin();\r\n\t\t}else if (lose){\r\n\t\t\tdrawGameOver();\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "f47217477533577003be04edd3071892", "score": "0.65936244", "text": "renderEntities(dt) {\n /* Loop through all of the objects within the allEnemies array and call\n * the render function you have defined2.\n */\n [this.player, ...this.enemies].forEach((entity) => {\n // changes entity position if needed\n entity.render(dt);\n // draws entity\n this.renderCtx.drawImage(Resources.getFromCache(entity.getImgPath()), entity.getX(), entity.getY());\n // this.renderCtx.strokeRect(\n // entity.getX(),\n // entity.getY(),\n // 101,\n // 171\n // );\n // this.renderCtx.strokeRect(\n // entity.getX()+entity.getSX(),\n // entity.getY()+entity.getSY(),\n // entity.getWidth(),\n // entity.getHeight(),\n // );\n });\n }", "title": "" }, { "docid": "dc41537bade819336ac75958e2d65829", "score": "0.6592652", "text": "function mainLoop(t) {\n\t\t\t// ---REQUEING PART!!\n\t\t\trequestAnimationFrame(mainLoop); // queue this method again\t\t\n\t\t\t// ---RENDERING PART!! First clear with black then redraw everything\n\t\t\tctx.fillStyle = \"rgba(0, 0, 0, 0.3)\";\n\t\t\tctx.clearRect(0, 0, canvas.width, canvas.height);\n\t\t\tctx.fillRect(0, 0, canvas.width, canvas.height);\n\t\t\tcurrentLevel.draw(ctx);\n\t\t}", "title": "" }, { "docid": "5d7629efb91055bbbd1344b7dd3881ef", "score": "0.6586044", "text": "function drawGame() {\n context.clearRect(0, 0, canvas.width, canvas.height);\n\n drawMap();\n drawObjectRange();\n drawObstacles();\n drawBullets();\n drawPlayerObjects();\n drawEnemies();\n drawSideMenu();\n drawPlayerStats();\n drawInfoText();\n drawProhibited();\n drawSpecialEffects();\n drawRemoveConfirmation();\n context.fill();\n}", "title": "" }, { "docid": "f99af79fd9b28c00d42bb83d65e46d0a", "score": "0.6583381", "text": "_render(){\n this._renderBackground(); // render background\n this.render(); // override render\n for(let i=0; i<this._gameObjects.length; i++) this._gameObjects[i]._render(this);\n this.renderGameUI(); // render UI\n }", "title": "" }, { "docid": "09bd04e168c944244e65fdba4deb508a", "score": "0.65679485", "text": "function render() {\n // Before drawing, clear existing canvas\n ctx.clearRect(0,0,canvas.width,canvas.height)\n\n /* Loop through the number of rows and columns we've defined above\n * and, using the rowImages array, draw the correct image for that\n * portion of the \"grid\"\n */\n for (var row = 0; row < numRows; row++) {\n for (var col = 0; col < numCols; col++) {\n /* The drawImage function of the canvas' context element\n * requires 3 parameters: the image to draw, the x coordinate\n * to start drawing and the y coordinate to start drawing.\n * We're using our Resources helpers to refer to our images\n * so that we get the benefits of caching these images, since\n * we're using them over and over.\n */\n ctx.drawImage(Resources.get(rowImages[row]), col * cellWidth, row * cellHeight);\n }\n }\n\n renderEntities();\n }", "title": "" }, { "docid": "4f9a83b4cb06ce8c039693261110e69d", "score": "0.6567684", "text": "function draw() {\n //CHECK DARK MODE\n if (darkMode === false) {\n background(255);\n }\n else if (darkMode === true) {\n background(0);\n }\n\n //DISPLAY OBJECTS\n player.display();\n player.move();\n goal.display();\n for (let i = 0; i < walls.length; i++) {\n walls[i].display();\n }\n for (let d = 0; d < particleArray.length; d++) {\n particleArray[d].display();\n particleArray[d].move();\n }\n\n //EVERY FRAME CHECK COLLISIONS\n windowWallCollsion();\n objectCollision();\n\n //EVERY FRAME CHECK FOR THE GOAL\n goalCheck();\n\n //EVERY FRAME DRAW THE ANGLE PREDICTOR\n if (airborn === false) {\n trajectory();\n }\n\n //ON SCREEN TEXT\n push();\n noStroke();\n fill(50, 50, 50);\n if (darkMode === false) {\n fill(0, 0, 0, 50);\n }\n //FIRST LEVEL TUTORIAL\n if (levelCount === 1) {\n text('Up Arrow: Dark Mode', width - 120, 45);\n text('Down Arrow: Reset Level', width - 140, 45 / 2);\n }\n //LEVEL COUNTER\n textSize(50);\n text(str(levelCount), 0, 40);\n\n pop();\n}", "title": "" }, { "docid": "8da0997129b1a441562591475f5a8ffe", "score": "0.6564315", "text": "function render() {\n drawBoard();\n drawScore();\n drawNet();\n drawPlayer();\n drawBall();\n}", "title": "" }, { "docid": "a2ad47de449550decdcc2a59d49efc05", "score": "0.6563838", "text": "function drawGame() {\n if (!player.isGameOver) {\n context.clearRect(0, 0, canvas.width, canvas.height);\n drawPlayer();\n drawScore();\n drawRockets();\n playerShooting();\n rocketShotCollision();\n if (player.level == 1) {\n drawEnemies()\n shotEnemyCollision()\n rocketEnemyCollision()\n playerEnemyCollision()\n }\n else if (player.level == 2) {\n drawBigEnemy();\n printBigEnemyShots();\n bigEnemyShotsCollisions();\n }\n requestAnimationFrame(drawGame);\n }\n else {\n if (player.hasWon) printMessage(\" Victory\", 'rgba(255, 255, 0, 0.7)',\"blue\");\n else printMessage(\"Game Over\", \"red\", \"black\");\n }\n}", "title": "" }, { "docid": "ad375fe133151343ef246a3d9646d968", "score": "0.65474015", "text": "function renderGame() {\n\n ctx.clearRect(0, 0, canvas.width, canvas.height); // clear canvas to title\n\n var rowImages = [ // generate game background\n 'images/water-block.png', // Top row is water\n 'images/stone-block.png', // Row 1 of 3 of stone\n 'images/stone-block.png', // Row 2 of 3 of stone\n 'images/stone-block.png', // Row 3 of 3 of stone\n 'images/grass-block.png', // Row 1 of 2 of grass\n 'images/grass-block.png' // Row 2 of 2 of grass\n ],\n numRows = 6,\n numCols = 5,\n row, col;\n\n /* \n Loop through of rows and columns defined above\n Use rowImages array to draw the correct image for that portion of the 'grid'\n */\n for (row = 0; row < numRows; row++) {\n for (col = 0; col < numCols; col++) {\n ctx.drawImage(Resources.get(rowImages[row]), col * 101, row * 83);\n }\n }\n\n renderEntities();\n renderScore();\n }", "title": "" }, { "docid": "7594fc54fe7089314b67a03c5fce49e7", "score": "0.6544283", "text": "function main() {\n\n /*\n Get time delta information, used to smooth animations and ensure\n consistent performance across devices\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* \n Switch for gameState\n This is only place where this var is used\n */\n if (gameState === 'play') {\n\n /* \n Call update()/render(), pass time delta to update function \n as used for smooth animation\n */\n updateEntities(dt); // needs to be invoked before render functions for smooth animations\n renderGame();\n\n /*\n Check to see if score has been achieved\n If yes, set gameState to 'starter' - in effect break the game loop\n Also increase level/reset score\n */\n if (score >= maxScore) {\n score = 0;\n level += 1;\n countdownTimer = 250;\n gameState = 'starter';\n }\n\n else if (lives === -1) {\n gameState = 'gameover';\n }\n }\n\n /*\n Call functions used to generate starter scree\n */\n else if (gameState === 'starter') {\n updateStarter(dt);\n renderStarter();\n }\n\n else if (gameState === 'gameover') {\n renderGameOver();\n }\n\n /* \n Set lastTime variable used to determine the time delta for the next\n function call\n */\n lastTime = now;\n\n\n\n /*\n Use the browser's requestAnimationFrame function to call this\n function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "af701a3f9aeb47056f34f680b3da4783", "score": "0.6538998", "text": "function render()\n{\n\tdrawPlayer();\n}", "title": "" }, { "docid": "0eb0b177257793bab9434148c21a7aa8", "score": "0.65367454", "text": "function render(now) {\n document.getElementById('scorev').innerHTML=\"Score:\"+frames.toString()+\"&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Level:\"+level.toString();\n // if(textured)\n // {\n // change_shader(gl);\n // }\n if(speedy>-1)\n {\n if(!out)\n {\n if(posY>=-0.9)\n {\n posY+=speedy;\n speedy+=accy;\n if(posY>=0.5)\n {\n speedy=0;\n accy=0;\n }\n }\n else\n {\n posY+=0.01; \n }\n }\n if(out)\n {\n if(posYo>=-3.0)\n {\n posYo+=speedy;\n speedy+=accy;\n if(posYo>=(-1.5))\n {\n speedy=0;\n accy=0;\n }\n }\n else\n {\n posYo+=0.01; \n }\n }\n }\n // requestAnimationFrame(render);\n now *= 0.001; // convert to seconds\n const deltaTime = now - then;\n if(start_game==1 && pause)\n {\n frames++;\n if(frames % level_change_number == 0){\n level = Math.min(level + 1, max_level);\n shapes[0].speed=7+speed_level_horizontal[level-1];\n level_change_number*=2;\n }\n }\n if(level>=6)\n out=1;\n // if(!pause)\n // change_shader(gl,shining,ambix,ambiy,ambiz);\n // // if(level==1)\n // bw+=2;\n // else\n // bw=0;\n if((Math.floor(Math.random()*15)%15)==2 && bw==0 && frames%100==0)\n bw=8;\n // console.log(\"deltaTime\");\n // console.log(deltaTime);\n then = now;\n refresh_tunnel(gl, shapes, buffer_shapes);\n refresh_obstacles(gl, obstacles, buffer_obstacles);\n handleKeys(shapes, obstacles);\n const projectionMatrix = clearScene(gl);\n for (var i = 0; i < count_shapes; i++){\n shapes[i].position[2] += pause * shapes[i].speed * deltaTime; \n if(!textured)\n drawScene(gl, projectionMatrix, shapes[i], programInfo, buffer_shapes[i], deltaTime);\n else\n drawSceneTextured(gl, projectionMatrix, shapes[i], programInfo, buffer_shapes[i], deltaTime,texture);\n }\n if(start_game && !ended)\n {\n for (var i = 0; i < count_obstacles; i++){\n obstacles[i].position[2] += pause * obstacles[i].speed * deltaTime;\n obstacles[i].rotationZ += obstacles[i].rotation * deltaTime;\n if(!textured)\n\n drawScene(gl, projectionMatrix, obstacles[i], programInfo, buffer_obstacles[i], deltaTime);\n else\n drawSceneTextured(gl, projectionMatrix, shapes[i], programInfo, buffer_shapes[i], deltaTime,texture);\n }\n }\n if(!detect_collision(shapes, obstacles)){\n requestAnimationFrame(render);\n }\n else if(start_game==1 || allow==1)\n {\n ended=1;\n allow=0;\n frames=0;\n level=1;\n // start_game=0;\n document.getElementById('playag').style.display=\"block\";\n requestAnimationFrame(render);\n }\n }", "title": "" }, { "docid": "6f881e80c587257c794e140e23720d03", "score": "0.65325356", "text": "function render(){\n\t\tdrawImage(\"background\");\n\t\tif(rocket.engine == 0){\n\t\t\tdrawImage(\"rocketOff\");\n\t\t} else {\n\t\t\tdrawImage(\"rocketOn\");\t\n\t\t}\t\n\t\tif(game == \"explosion\"){\n\t\t\tdrawImage(\"rocketExplosion\");\n\t\t}\t\t\n\t\tif(game == \"win\"){\n\t\t\tdrawImage(\"satellite\");\n\t\t}\t\t\n\t\tdrawImage(\"sky\");\n\t\tdrawImage(\"space\");\n\t\tdrawText();\n\t\tmove();\t\t\n\t}", "title": "" }, { "docid": "d9f852cf983780c1add935b37fcab3f9", "score": "0.65288794", "text": "function render() {\r\n\t\t//clear screan and draw frame\r\n\t\tctx.fillStyle = frameColor;\r\n\t\tctx.fillRect(0, 0, canvas.width, canvas.height);\r\n\t\tctx.clearRect(canvasBox.x, canvasBox.y, canvasBox.width, canvasBox.height);\r\n\t\tpause.Draw(ctx);\r\n\r\n\t\t//draw upgrades\r\n\t\tfor(var i = 0; i<upgrades.length; i++) {\r\n\t\t\tupgrades[i].Draw(ctx);\r\n\t\t}\r\n\r\n\t\t//draw bullets\r\n\t\tfor(var i = 0; i<shots.length; i++) {\r\n\t\t\tshots[i].Draw(ctx);\r\n\t\t}\r\n\t\t\r\n\t\t//draw enemies\r\n\t\tfor(var i = 0; i<enemies.length; i++) {\r\n\t\t\tenemies[i].Draw(ctx);\r\n\t\t}\r\n\r\n\t\t//draw texts\r\n\t\tfor(var i = 0; i<texts.length; i++) {\r\n\t\t\ttexts[i].Draw(ctx);\r\n\t\t}\r\n\r\n\t\t//draw player\r\n\t\t//ctx.drawImage(img, 0, 0, 32, 32, player.x, player.y, player.width, player.height);\r\n\t\tplayer.Draw(ctx);\r\n\t\t\r\n\t\t//reset text alignment\r\n\t\tctx.textAlign = 'left';\r\n\r\n\t\t//draw score\r\n\t\tctx.fillStyle = \"white\";\r\n\t\tctx.font = \"10px sans-serif\";\r\n\t\tctx.fillText(\"Score: \"+score, 10, 15);\r\n\t\t\r\n\t\t//draw current wave\r\n\t\tctx.fillStyle = \"white\";\r\n\t\tctx.font = \"10px sans-serif\";\r\n\t\tctx.fillText(\"Current wave: \"+wave, 10, 30);\r\n\t\t\r\n\t\t//draw upgrades\r\n\t\tctx.fillStyle = \"white\";\r\n\t\tctx.font = \"10px sans-serif\";\r\n\t\tctx.fillText(\"Shot dmg: \"+shotDmg, canvas.width-100, 15);\r\n\t\tctx.fillStyle = \"white\";\r\n\t\tctx.font = \"10px sans-serif\";\r\n\t\tctx.fillText(\"Shot cooldown: \"+cooldownSpeed/1000, canvas.width-100, 30);\r\n\t\tctx.fillStyle = \"white\";\r\n\t\tctx.font = \"10px sans-serif\";\r\n\t\tctx.fillText(\"Shot speed: \"+shotsVy, canvas.width-200, 15);\r\n\t\tctx.fillStyle = \"white\";\r\n\t\tctx.font = \"10px sans-serif\";\r\n\t\tctx.fillText(\"Ship speed: \"+player.vx, canvas.width-200, 30);\r\n\r\n\t\t//render win/loss screen.\r\n\t\tif(death) {\r\n\t\t\t//clear screan and draw frame\r\n\t\t\tctx.fillStyle = \"black\";\r\n\t\t\tctx.fillRect(0, 0, canvas.width, canvas.height);\r\n\r\n\t\t\t//draw Restart text\r\n\t\t\tctx.fillStyle = \"white\";\r\n\t\t\tctx.font = \"15px sans-serif\";\r\n\t\t\tctx.textAlign = 'center';\r\n\t\t\tctx.fillText(\"Your score: \" + score, canvas.width/2, canvas.height/2-100);\r\n\t\t\t\r\n\t\t\t//draw Restart text\r\n\t\t\tvar x = canvas.width / 2;\r\n\t\t\tvar y = canvas.height / 2;\r\n\r\n\t\t\tctx.font = '30pt Calibri';\r\n\t\t\tctx.textAlign = 'center';\r\n\t\t\tctx.fillStyle = 'white';\r\n\t\t\tctx.fillText('Click to restart!', x, y);\r\n\t\t\tctx.textAlign = 'left';\r\n\t\t}\r\n\r\n\t\t\r\n\t}", "title": "" }, { "docid": "a0564ef57dbfd72eaec4a53e292e336d", "score": "0.65173334", "text": "function draw() {\n if (state === \"start\") {\n startScreen();\n } \n else if (state === \"play\") {\n clear();\n displayBackground();\n \n // Uncomment next 2 lines to show character and ground hitbox.\n // rect(character.x, character.y, height/hitboxScale, height/hitboxScale);\n // line(0 - 10, height * 0.63, width + 10, height * 0.63);\n \n // Draws and moves sprite.\n character.displaySprite();\n character.handleMovement();\n character.applyGravity();\n character.nextScreen();\n \n\n handleEnemies();\n\n handleSidebar();\n\n }\n else if (state === \"dead\") {\n deathScreen();\n }\n}", "title": "" }, { "docid": "1698af9375e9876221051b474ef16474", "score": "0.6511963", "text": "function render() {\n renderEntities();\n }", "title": "" }, { "docid": "8ef4e5e158c84161a5f471ac160e71c5", "score": "0.65003717", "text": "function draw() {\n render();\n update();\n}", "title": "" }, { "docid": "d41f7a41c37d188128c7b3793445d286", "score": "0.6498201", "text": "function render() {\n\n\t/*---------- Contain canvas ----------*/\n\t//background\n\tctx.drawImage(bgImage, 0, 0);\n\n\t//boom no\n\tif(explosionReady) {\n\t\tctx.drawImage(explosionImage, 100, 100, 300, 300);\n\t}\n\n\t//list blood\n\tif (bloodList.length > 0) {\n\t\tfor (bi = 0; bi < bloodList.length; bi++) {\n\t\t\tctx.drawImage(bloodImage, bloodList[bi].x - 50, bloodList[bi].y - 50);\n\t\t}\n\t}\n\n\t//level\n\tctx.fillStyle = \"#F1F1F1\";\n\tctx.font = \"24px Arial\";\n\tctx.fillText(\"Level: \" + (level + 1), 25, 32);\n\n\t//monster\n\tfor(var i = 0; i < 8; i++){\n\t\tif (monster[i].visible)\n\t\t\tctx.drawImage(monsterImage, monster[i].x, monster[i].y, 100, 100);\n\t}\n\n\t/*---------- End Contain canvas ----------*/\n\n\t/*---------- Menu canvas ----------*/\n\t//background menu\n\tctxMenu.drawImage(mnImage, 0, 0);\n\t//Boom\n\tctxMenu.drawImage(boomImage, 430, 25, 55, 55);\n\t//Pause\n\tctxMenu.drawImage(pauseImage, 380, 35, 40, 40);\t\n\t//Restart\n\tctxMenu.drawImage(restartImage, 320, 35, 40, 40);\n\t//heart img\n\tvar xH = 90;\n\tfor(h = 1; h <= heart; h++) {\n\t\tctxMenu.drawImage(heartImage, xH, 15);\n\t\txH += 34;\n\t}\n\tctxMenu.font = \"25px Arial\";\n\tctxMenu.fillStyle = \"#FFF\";\n\t//Heart\n\tctxMenu.fillText(\"Heart:\", 10, 35);\n\t//Score\n\tctxMenu.fillText(\"Score: \" + score, 10, 70);\n\t//Number Boom\n\tctxMenu.fillText(boomNum, 465, 40);\n\n\t/*---------- End Menu canvas ----------*/\n}", "title": "" }, { "docid": "4bc49d92551d24346e9a4a8f8b6d88f5", "score": "0.649312", "text": "function render() {\n\t// Here we control how the camera looks around the scene.\n\tcontrols.activeLook = false;\n\tif (mouseOverCanvas) {\n\t\tif (mouseDown) {\n\t\t\tcontrols.activeLook = true;\n\t\t}\n\t}\n\tcheckCollision();\n\t// Get the time since this method was called.\n\tvar deltaTime = clock.getDelta();\n\n\t// Update the controls.\n\tcontrols.update(deltaTime);\n\n\t// Render the scene.\n\trenderer.render(scene, camera);\n\n\t// Update the stats.\n\tstats.update();\n\n\t// Request the next frame.\n\t/* The \"requestAnimationFrame()\" method tells the browser that you\n\t wish to perform an animation and requests that the browser call a specified\n\t function to update an animation before the next repaint. The method takes\n\t as an argument a callback to be invoked before the repaint. */\n\trequestAnimationFrame(render);\n}", "title": "" }, { "docid": "6d96cfc3d836543ed64d68c65fc975a8", "score": "0.6479085", "text": "function render() {\n //update necessary variables\n update();\n requestAnimFrame(render);\n\n now = Date.now();\n delta = now - then;\n\n if(delta > interval){\n then = now - (delta % interval);\n\n ctx.clearRect(0, 0, canvas.width, canvas.height);\n\n // //Platform\n for(var i=0;i<=canvas.width;i+=16){\n ctx.drawImage(ground,i,canvas.height-platform-25);\n }\n\n //Avatar\n //if avatar not on the ground, trigger jump animation\n if(avatar.onGround == false){\n jump.update();\n jump.draw(avatar.x_pos,avatar.y_pos);\n }\n //if avatar on the ground\n else if(avatar.onGround == true){ \n run.update(); \n run.draw(avatar.x_pos,avatar.y_pos);\n }\n\n //obstacles\n kitty.update();\n kitty.draw(obstacles[0].x_pos,obstacles[0].y_pos);\n\n //scoreBoard\n ctx.font = \"14px Arial\";\n ctx.fillStyle = \"white\";\n ctx.fillText(\"Score: \" + Math.floor(score/10),100,50);\n } \n}", "title": "" }, { "docid": "dd5a273b97171a613fb4eef32dab564b", "score": "0.6476944", "text": "render() {\n for (let gameObject of this.level.content.gameObjects) {\n gameObject.render(Physics.RAD_2_DEG);\n }\n }", "title": "" }, { "docid": "276d832a1db75f14c606f4cb339a3442", "score": "0.646896", "text": "function drawEntities()\n{\n\tGameCanvasCtx.imageSmoothingEnabled = false;\n\tfor (var i = 0; i < Entities.length; i++)\n\t{\n\t\t//Check if the entity should be emmitting light or not.\n\t\tif (Entities[i].LightingMod == \"Light\")\n\t\t{\n\t\t\t//GameCanvasCtx.globalCompositeOperation = \"source-over\";\n\t\t\t_LightSrc = GameCanvasCtx.createRadialGradient(Entities[i].XLoc, Entities[i].YLoc, 16, Entities[i].XLoc, Entities[i].YLoc, 24);\n\t\t\t_LightSrc.addColorStop(0.5, \"yellow\");\n\t\t\tGameCanvasCtx.globalAlpha = Math.random() * 0.8;\n\t\t\tGameCanvasCtx.beginPath();\n\t\t\tGameCanvasCtx.fillStyle = _LightSrc;\n\t\t\tGameCanvasCtx.arc(Entities[i].XLoc + (Entities[i].EntityWidth / 2), Entities[i].YLoc + Entities[i].EntityHeight, 32, 32, 64);\n\t\t\tGameCanvasCtx.fill();\n\t\t\tGameCanvasCtx.closePath();\n\t\t\tGameCanvasCtx.globalAlpha = 1.0;\n\t\t}\n\t\t//GameCanvasCtx.fillStyle = \"#000000\";\n\t\tGameCanvasCtx.drawImage(Entities[i].EntitySpr, Entities[i].ClipX, Entities[i].ClipY, Entities[i].EntityWidth, Entities[i].EntityHeight, Entities[i].XLoc, Entities[i].YLoc, Entities[i].EntityWidth, Entities[i].EntityHeight);\n\t\t//GameCanvasCtx.globalCompositeOperation = \"normal\";\n\t}\n}", "title": "" }, { "docid": "9a802ecf0f3b70344fffda8a59af6520", "score": "0.64686054", "text": "function render() {\n\t\tdrawMainBackground();\n\t\tupdateScore();\n\t\tdrawBricks();\n\t\tball.drawBall();\n\t\tpaddle.drawPaddle();\n\t}", "title": "" }, { "docid": "0ccab96962bb436feccb0a5701fba063", "score": "0.64666325", "text": "function render() {\n // TODO: look into stop running when browser on blur https://developer.mozilla.org/en-US/docs/Web/API/Page_Visibility_API\n // FrameRequestCallback. calls the render when window is active\n requestAnimationFrame(render);\n devTools.stats.update();\n // renders the frame and updates the controls and sceneSubjects\n sceneManager.update();\n }", "title": "" }, { "docid": "d6d2b83bb51ef435b91e8f7183e15e87", "score": "0.64638275", "text": "function draw() {\n clearCanvas();\n context.beginPath();\n drawContent();\n drawEnemies();\n drawCharacter();\n}", "title": "" }, { "docid": "0fa93ad305711ec458a7d6fa171608fc", "score": "0.6458925", "text": "function renderLevel() {\n context.clearRect(0, 0, canvas.width, canvas.height);\n context.fillStyle = '#000000';\n for (var i = 0; i < levelRow; i++) {\n for (var j = 0; j < levelColumn; j++) {\n if (levelMap[i][j] === 1) {\n context.fillRect(j * tileSize, i * tileSize, tileSize, tileSize);\n }\n }\n }\n }", "title": "" }, { "docid": "2120dc5dc8d4da139a812eccaed43b70", "score": "0.6457374", "text": "static draw() {\n if (window.GLM_CONFIG.debug) window.dataManager.stats.begin();\n let start = Date.now();\n // Render blocks\n window.dataManager.eventManager.dispatchEvent(new Event('preTerrainRender'));\n window.dataManager.texturePack.renderBlocks(window.dataManager.selectedWorld.camera, window.dataManager.selectedWorld.chunkMap);\n window.dataManager.eventManager.dispatchEvent(new Event('postTerrainRender', {elapsedTime: Date.now() - start}));\n // Render players\n window.dataManager.eventManager.dispatchEvent(new Event('prePlayersRender', {elapsedTime: Date.now() - start}));\n window.dataManager.texturePack.renderPlayers(window.dataManager.selectedWorld.camera, window.dataManager.selectedWorld);\n window.dataManager.eventManager.dispatchEvent(new Event('postPlayersRender', {elapsedTime: Date.now() - start}));\n\n if (window.GLM_CONFIG.debug) window.dataManager.stats.end();\n\n window._requestAnimationFrameId = requestAnimationFrame(DataManager.draw);\n }", "title": "" }, { "docid": "1cd9ad57696ba4a87414b9547816d585", "score": "0.64572877", "text": "function drawLevel() {\n var startX = initialStartX;\n var startY = initialStartY;\n for (i=0;i<level.length;i++) {\n if (i%10 === 0 && i!=0) {\n startY+=tileSize;\n startX = initialStartX;\n }\n\n level[i].draw(startX,startY,tileSize,tileSize);\n level[i].pos=[startX,startY];\n\n if (roads[i] != 0) {\n roads[i].draw(startX,startY,tileSize,tileSize,roads[i].rotation);\n roads[i].pos=[startX,startY];\n }\n\n if (buildings[i] !=0){\n buildings[i].draw(startX,startY-((buildings[i].image.height*stretchRatio)-tileSize),tileSize,buildings[i].image.height*stretchRatio);\n buildings[i].pos=[startX,startY];\n }\n\n if (power[i] !=0){\n power[i].draw(startX,startY-((power[i].image.height*stretchRatio)-tileSize),tileSize,power[i].image.height*stretchRatio);\n power[i].pos=[startX,startY];\n }\n\n startX+=tileSize;\n }\n}", "title": "" }, { "docid": "40153c0c3c0926db4b5a5dbcd36bedfa", "score": "0.6455583", "text": "function draw() {\n\n if (state === \"WELCOME\"){\n welcomePage(); //shows our welcome screen\n }\n\n else if (state === \"GAME\"){\n mainGame(); //loads in the main game once left mouse click\n }\n\n if (state === \"END\"){\n endPage();//will bring up the victory screen once all prey are eaten\n }\n\n if (state === \"TIGERLOSE\"){\n tigerLoss();//enables the loss screen for the tiger dying\n }\n\n if (state === \"CATLOSE\"){\n catLoss();//enables the loss screen for if the cat dies first\n }\n}", "title": "" }, { "docid": "4c216878a45c866b01232830d668863a", "score": "0.644694", "text": "function drawWorld(){\n\tdrawScore();\n\tdrawAllBricks();\n\tdrawBall();\n\tdrawPaddle();\n\tdrawMessage(\"LEVEL_MESSAGE\", \"Level: \" + level, LEVEL_MESSAGE_FONT);\n\tdrawMessage(\"PAUSE_MESSAGE\", \"Hit SPACE to begin\", PAUSE_MESSAGE_FONT);\n\t\n\tif(level == 1){\n\t\tdrawMessage(\"ALERT_MESSAGE\", \"Hit/hold LEFT/RIGHT to move\", ALERT_MESSAGE_FONT);\n\t\tdrawMessage(\"ALERT_MESSAGE2\", \"Hit ESC to pause\", ALERT_MESSAGE_FONT);\n\t}\t\n\tif(level == 2){\n\t\tdrawMessage(\"ALERT_MESSAGE\", \"-- Bullets unlocked --\", ALERT_MESSAGE_FONT);\n\t\tdrawMessage(\"ALERT_MESSAGE2\", \"(Hit/hold SPACE to fire/auto-fire)\", ALERT_MESSAGE_FONT);\n\t\tpowerUpsUnlocked++;\n\t\tcurrentPowerUp++;\n\t}\n\tif(level == 3){\n\t\tdrawMessage(\"ALERT_MESSAGE\", \"-- Lasers unlocked --\", ALERT_MESSAGE_FONT);\n\t\tdrawMessage(\"ALERT_MESSAGE2\", \"(Hit TAB to change weapon)\", ALERT_MESSAGE_FONT);\n\t\tpowerUpsUnlocked++;\n\t}\n\t\n\tdrawPowerStrip();\n}", "title": "" }, { "docid": "2880ee2fb47dbf353ed421453d1bb11e", "score": "0.6436841", "text": "function main() {\n\n\n all_enemies.forEach(function (Enemy) {\n Enemy.update();\n });\n\n render();\n\n player.checkCollision();\n\n $('.level').text('Level:' + level);\n\n this.window.requestAnimationFrame(main);\n\n}", "title": "" }, { "docid": "4cf48b51bc6f1b4afaf53af229da580a", "score": "0.64352494", "text": "function render() {\n\n world.tick();\n\n // actually display the scene in the Dom element\n renderer.render(scene, world.camera().object());\n}", "title": "" }, { "docid": "71f0873b38f091d2951a3e97558c141d", "score": "0.64320153", "text": "function update(){\n /**\n This state occures when the levels are chaninging or when the game first starts.\n */\n if(gameState == GameState.PreStart){\n currentLevel = levelList.pop();\n if(currentLevel == null){\n currentLevel = new LevelInfinity(infiniteIterationCount++);\n if(!isLevelInfinity)\n timeRemaining = currentLevel.time;\n isLevelInfinity = true;\n }\n renderList = [];\n gameState = GameState.PreAnimation;\n gameOverString = \"\";\n animationTimer = isLevelInfinity ? 70 : 100;\n currentIndex = 0;\n }\n /**\n This state occurs during the Level Name animation.\n */\n else if(gameState == GameState.PreAnimation){\n animationTimer -= deltaTime;\n if(currentIndex < currentLevel.name.length){\n if(animationTimer < 0){\n gameOverString += currentLevel.name[currentIndex];\n currentIndex++;\n animationTimer = 150;\n }\n }\n resetMatrix();\n textSize(50);\n fill(0,0,0);\n noStroke();\n text(gameOverString, width/2-120, height/2);\n if(currentIndex >= currentLevel.name.length && animationTimer < 0){\n setupLevel(currentLevel);\n if(!isLevelInfinity)\n timeRemaining = currentLevel.time;\n gameState = GameState.InGame;\n }\n }\n /**\n This state handles all game actions.\n */\n else if(gameState == GameState.InGame){\n timeRemaining -= deltaTime/1000;\n currentLevel.update();\n if(compare(currentLevel.uPPoly, currentLevel.uWinPoly) && !isPlayerClicked){\n gameState = GameState.WinAnimation;\n gameOverString = \"\";\n animationTimer = 100;\n currentIndex = 0;\n \n passSound.play();\n \n if(isLevelInfinity){\n timeRemaining += 3;\n if(timeRemaining > currentLevel.time) timeRemaining = currentLevel.time;\n }\n }\n if(timeRemaining <= 0){\n gameOver = true;\n gameState = GameState.End;\n animationTimer = 100;\n currentIndex = 0;\n gameOverString = \"\";\n failSound.play();\n }\n if(keyIsDown(RIGHT_ARROW)){\n currentLevel.getPlayerMesh().rotation += radians(isLevelInfinity ? 0.2 : 0.1) * deltaTime;\n }\n if(keyIsDown(LEFT_ARROW)){\n currentLevel.getPlayerMesh().rotation -= radians(isLevelInfinity ? 0.2 : 0.1) * deltaTime;\n }\n }\n /**\n This state handles the level cleared animation.\n */\n else if(gameState == GameState.WonAnimation){\n animationTimer -= deltaTime;\n if(currentIndex < \"Level Cleared\".length){\n if(animationTimer < 0){\n gameOverString += \"Level Cleared\"[currentIndex];\n currentIndex++;\n animationTimer = 150;\n }\n }\n resetMatrix();\n textSize(50);\n fill(0,255,0);\n noStroke();\n text(gameOverString, width/2-120, height/2);\n if(currentIndex >= \"Level Cleared\".length && animationTimer < 0){\n gameState = GameState.PreStart;\n }\n }\n /**\n This state handles the game over animation.\n */\n else if(gameState == GameState.End){\n if(currentIndex < \"Game Over\".length){\n animationTimer -= deltaTime;\n if(animationTimer < 0){\n gameOverString += \"Game Over\"[currentIndex];\n currentIndex++;\n animationTimer = 100;\n }\n }\n resetMatrix();\n textSize(50);\n fill(255,0,0);\n noStroke();\n text(gameOverString, width/2-120, height/2);\n }\n}", "title": "" }, { "docid": "9a30eefd7ffdb54417a18a8c5782f747", "score": "0.6431019", "text": "function cw_drawScreen() {\n ctx.clearRect(0,0,canvas.width,canvas.height);\n ctx.save();\n cw_setCameraPosition();\n ctx.translate(200-(camera_x*vm.zoom), 200+(camera_y*vm.zoom));\n ctx.scale(vm.zoom, -vm.zoom);\n\n cw_drawFloor();\n ghost_draw_frame(ctx, ghost);\n cw_drawCars();\n ctx.restore();\n drawLeader();\n}", "title": "" }, { "docid": "2b21138e10ccaa9a0bcfd27e05a04a41", "score": "0.64151615", "text": "function render()\n\t{\n\t\t// only render\n\t\tif(renderer) {\n\t\t\trenderer.render(scene, camera);\n\t\t}\n\t\t\n\t\t// set up the next frame\n\t\tupdate();\n\t}", "title": "" }, { "docid": "2b21138e10ccaa9a0bcfd27e05a04a41", "score": "0.64151615", "text": "function render()\n\t{\n\t\t// only render\n\t\tif(renderer) {\n\t\t\trenderer.render(scene, camera);\n\t\t}\n\t\t\n\t\t// set up the next frame\n\t\tupdate();\n\t}", "title": "" } ]
d96dc0973f4226b5d4baa2a0058de982
Language: Haxe Description: Haxe is an open source toolkit based on a modern, high level, strictly typed programming language.
[ { "docid": "2c9a9e153647f93aae605002540b9b5a", "score": "0.80083954", "text": "function haxe(hljs) {\n\n const HAXE_BASIC_TYPES = 'Int Float String Bool Dynamic Void Array ';\n\n return {\n name: 'Haxe',\n aliases: ['hx'],\n keywords: {\n keyword: 'break case cast catch continue default do dynamic else enum extern ' +\n 'for function here if import in inline never new override package private get set ' +\n 'public return static super switch this throw trace try typedef untyped using var while ' +\n HAXE_BASIC_TYPES,\n built_in:\n 'trace this',\n literal:\n 'true false null _'\n },\n contains: [\n {\n className: 'string', // interpolate-able strings\n begin: '\\'',\n end: '\\'',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n {\n className: 'subst', // interpolation\n begin: '\\\\$\\\\{',\n end: '\\\\}'\n },\n {\n className: 'subst', // interpolation\n begin: '\\\\$',\n end: /\\W\\}/\n }\n ]\n },\n hljs.QUOTE_STRING_MODE,\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.C_NUMBER_MODE,\n {\n className: 'meta', // compiler meta\n begin: '@:',\n end: '$'\n },\n {\n className: 'meta', // compiler conditionals\n begin: '#',\n end: '$',\n keywords: {\n 'meta-keyword': 'if else elseif end error'\n }\n },\n {\n className: 'type', // function types\n begin: ':[ \\t]*',\n end: '[^A-Za-z0-9_ \\t\\\\->]',\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type', // types\n begin: ':[ \\t]*',\n end: '\\\\W',\n excludeBegin: true,\n excludeEnd: true\n },\n {\n className: 'type', // instantiation\n begin: 'new *',\n end: '\\\\W',\n excludeBegin: true,\n excludeEnd: true\n },\n {\n className: 'class', // enums\n beginKeywords: 'enum',\n end: '\\\\{',\n contains: [hljs.TITLE_MODE]\n },\n {\n className: 'class', // abstracts\n beginKeywords: 'abstract',\n end: '[\\\\{$]',\n contains: [\n {\n className: 'type',\n begin: '\\\\(',\n end: '\\\\)',\n excludeBegin: true,\n excludeEnd: true\n },\n {\n className: 'type',\n begin: 'from +',\n end: '\\\\W',\n excludeBegin: true,\n excludeEnd: true\n },\n {\n className: 'type',\n begin: 'to +',\n end: '\\\\W',\n excludeBegin: true,\n excludeEnd: true\n },\n hljs.TITLE_MODE\n ],\n keywords: {\n keyword: 'abstract from to'\n }\n },\n {\n className: 'class', // classes\n begin: '\\\\b(class|interface) +',\n end: '[\\\\{$]',\n excludeEnd: true,\n keywords: 'class interface',\n contains: [\n {\n className: 'keyword',\n begin: '\\\\b(extends|implements) +',\n keywords: 'extends implements',\n contains: [\n {\n className: 'type',\n begin: hljs.IDENT_RE,\n relevance: 0\n }\n ]\n },\n hljs.TITLE_MODE\n ]\n },\n {\n className: 'function',\n beginKeywords: 'function',\n end: '\\\\(',\n excludeEnd: true,\n illegal: '\\\\S',\n contains: [hljs.TITLE_MODE]\n }\n ],\n illegal: /<\\//\n };\n}", "title": "" } ]
[ { "docid": "d4b94da5852130d2852b230d5505e004", "score": "0.80432385", "text": "function haxe(hljs) {\n\n var HAXE_BASIC_TYPES = 'Int Float String Bool Dynamic Void Array ';\n\n return {\n name: 'Haxe',\n aliases: ['hx'],\n keywords: {\n keyword: 'break case cast catch continue default do dynamic else enum extern ' +\n 'for function here if import in inline never new override package private get set ' +\n 'public return static super switch this throw trace try typedef untyped using var while ' +\n HAXE_BASIC_TYPES,\n built_in:\n 'trace this',\n literal:\n 'true false null _'\n },\n contains: [\n { className: 'string', // interpolate-able strings\n begin: '\\'', end: '\\'',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n { className: 'subst', // interpolation\n begin: '\\\\$\\\\{', end: '\\\\}'\n },\n { className: 'subst', // interpolation\n begin: '\\\\$', end: '\\\\W}'\n }\n ]\n },\n hljs.QUOTE_STRING_MODE,\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.C_NUMBER_MODE,\n { className: 'meta', // compiler meta\n begin: '@:', end: '$'\n },\n { className: 'meta', // compiler conditionals\n begin: '#', end: '$',\n keywords: {'meta-keyword': 'if else elseif end error'}\n },\n { className: 'type', // function types\n begin: ':[ \\t]*', end: '[^A-Za-z0-9_ \\t\\\\->]',\n excludeBegin: true, excludeEnd: true,\n relevance: 0\n },\n { className: 'type', // types\n begin: ':[ \\t]*', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'type', // instantiation\n begin: 'new *', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'class', // enums\n beginKeywords: 'enum', end: '\\\\{',\n contains: [\n hljs.TITLE_MODE\n ]\n },\n { className: 'class', // abstracts\n beginKeywords: 'abstract', end: '[\\\\{$]',\n contains: [\n { className: 'type',\n begin: '\\\\(', end: '\\\\)',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'type',\n begin: 'from +', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'type',\n begin: 'to +', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n hljs.TITLE_MODE\n ],\n keywords: {\n keyword: 'abstract from to'\n }\n },\n { className: 'class', // classes\n begin: '\\\\b(class|interface) +', end: '[\\\\{$]', excludeEnd: true,\n keywords: 'class interface',\n contains: [\n { className: 'keyword',\n begin: '\\\\b(extends|implements) +',\n keywords: 'extends implements',\n contains: [\n {\n className: 'type',\n begin: hljs.IDENT_RE,\n relevance: 0\n }\n ]\n },\n hljs.TITLE_MODE\n ]\n },\n { className: 'function',\n beginKeywords: 'function', end: '\\\\(', excludeEnd: true,\n illegal: '\\\\S',\n contains: [\n hljs.TITLE_MODE\n ]\n }\n ],\n illegal: /<\\//\n };\n}", "title": "" }, { "docid": "d4b94da5852130d2852b230d5505e004", "score": "0.80432385", "text": "function haxe(hljs) {\n\n var HAXE_BASIC_TYPES = 'Int Float String Bool Dynamic Void Array ';\n\n return {\n name: 'Haxe',\n aliases: ['hx'],\n keywords: {\n keyword: 'break case cast catch continue default do dynamic else enum extern ' +\n 'for function here if import in inline never new override package private get set ' +\n 'public return static super switch this throw trace try typedef untyped using var while ' +\n HAXE_BASIC_TYPES,\n built_in:\n 'trace this',\n literal:\n 'true false null _'\n },\n contains: [\n { className: 'string', // interpolate-able strings\n begin: '\\'', end: '\\'',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n { className: 'subst', // interpolation\n begin: '\\\\$\\\\{', end: '\\\\}'\n },\n { className: 'subst', // interpolation\n begin: '\\\\$', end: '\\\\W}'\n }\n ]\n },\n hljs.QUOTE_STRING_MODE,\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.C_NUMBER_MODE,\n { className: 'meta', // compiler meta\n begin: '@:', end: '$'\n },\n { className: 'meta', // compiler conditionals\n begin: '#', end: '$',\n keywords: {'meta-keyword': 'if else elseif end error'}\n },\n { className: 'type', // function types\n begin: ':[ \\t]*', end: '[^A-Za-z0-9_ \\t\\\\->]',\n excludeBegin: true, excludeEnd: true,\n relevance: 0\n },\n { className: 'type', // types\n begin: ':[ \\t]*', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'type', // instantiation\n begin: 'new *', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'class', // enums\n beginKeywords: 'enum', end: '\\\\{',\n contains: [\n hljs.TITLE_MODE\n ]\n },\n { className: 'class', // abstracts\n beginKeywords: 'abstract', end: '[\\\\{$]',\n contains: [\n { className: 'type',\n begin: '\\\\(', end: '\\\\)',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'type',\n begin: 'from +', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n { className: 'type',\n begin: 'to +', end: '\\\\W',\n excludeBegin: true, excludeEnd: true\n },\n hljs.TITLE_MODE\n ],\n keywords: {\n keyword: 'abstract from to'\n }\n },\n { className: 'class', // classes\n begin: '\\\\b(class|interface) +', end: '[\\\\{$]', excludeEnd: true,\n keywords: 'class interface',\n contains: [\n { className: 'keyword',\n begin: '\\\\b(extends|implements) +',\n keywords: 'extends implements',\n contains: [\n {\n className: 'type',\n begin: hljs.IDENT_RE,\n relevance: 0\n }\n ]\n },\n hljs.TITLE_MODE\n ]\n },\n { className: 'function',\n beginKeywords: 'function', end: '\\\\(', excludeEnd: true,\n illegal: '\\\\S',\n contains: [\n hljs.TITLE_MODE\n ]\n }\n ],\n illegal: /<\\//\n };\n}", "title": "" }, { "docid": "bc270c5f3a7e71a3708e0dca0bd29d07", "score": "0.5739412", "text": "function swift(hljs) {\n var SWIFT_KEYWORDS = {\n keyword: '#available #colorLiteral #column #else #elseif #endif #file ' +\n '#fileLiteral #function #if #imageLiteral #line #selector #sourceLocation ' +\n '_ __COLUMN__ __FILE__ __FUNCTION__ __LINE__ Any as as! as? associatedtype ' +\n 'associativity break case catch class continue convenience default defer deinit didSet do ' +\n 'dynamic dynamicType else enum extension fallthrough false fileprivate final for func ' +\n 'get guard if import in indirect infix init inout internal is lazy left let ' +\n 'mutating nil none nonmutating open operator optional override postfix precedence ' +\n 'prefix private protocol Protocol public repeat required rethrows return ' +\n 'right self Self set static struct subscript super switch throw throws true ' +\n 'try try! try? Type typealias unowned var weak where while willSet',\n literal: 'true false nil',\n built_in: 'abs advance alignof alignofValue anyGenerator assert assertionFailure ' +\n 'bridgeFromObjectiveC bridgeFromObjectiveCUnconditional bridgeToObjectiveC ' +\n 'bridgeToObjectiveCUnconditional c compactMap contains count countElements countLeadingZeros ' +\n 'debugPrint debugPrintln distance dropFirst dropLast dump encodeBitsAsWords ' +\n 'enumerate equal fatalError filter find getBridgedObjectiveCType getVaList ' +\n 'indices insertionSort isBridgedToObjectiveC isBridgedVerbatimToObjectiveC ' +\n 'isUniquelyReferenced isUniquelyReferencedNonObjC join lazy lexicographicalCompare ' +\n 'map max maxElement min minElement numericCast overlaps partition posix ' +\n 'precondition preconditionFailure print println quickSort readLine reduce reflect ' +\n 'reinterpretCast reverse roundUpToAlignment sizeof sizeofValue sort split ' +\n 'startsWith stride strideof strideofValue swap toString transcode ' +\n 'underestimateCount unsafeAddressOf unsafeBitCast unsafeDowncast unsafeUnwrap ' +\n 'unsafeReflect withExtendedLifetime withObjectAtPlusZero withUnsafePointer ' +\n 'withUnsafePointerToObject withUnsafeMutablePointer withUnsafeMutablePointers ' +\n 'withUnsafePointer withUnsafePointers withVaList zip'\n };\n\n var TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*',\n relevance: 0\n };\n // slightly more special to swift\n var OPTIONAL_USING_TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*[!?]'\n };\n var BLOCK_COMMENT = hljs.COMMENT(\n '/\\\\*',\n '\\\\*/',\n {\n contains: ['self']\n }\n );\n var SUBST = {\n className: 'subst',\n begin: /\\\\\\(/, end: '\\\\)',\n keywords: SWIFT_KEYWORDS,\n contains: [] // assigned later\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /\"\"\"/, end: /\"\"\"/},\n {begin: /\"/, end: /\"/},\n ]\n };\n var NUMBERS = {\n className: 'number',\n begin: '\\\\b([\\\\d_]+(\\\\.[\\\\deE_]+)?|0x[a-fA-F0-9_]+(\\\\.[a-fA-F0-9p_]+)?|0b[01_]+|0o[0-7_]+)\\\\b',\n relevance: 0\n };\n SUBST.contains = [NUMBERS];\n\n return {\n name: 'Swift',\n keywords: SWIFT_KEYWORDS,\n contains: [\n STRING,\n hljs.C_LINE_COMMENT_MODE,\n BLOCK_COMMENT,\n OPTIONAL_USING_TYPE,\n TYPE,\n NUMBERS,\n {\n className: 'function',\n beginKeywords: 'func', end: '{', excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {\n begin: /[A-Za-z$_][0-9A-Za-z$_]*/\n }),\n {\n begin: /</, end: />/\n },\n {\n className: 'params',\n begin: /\\(/, end: /\\)/, endsParent: true,\n keywords: SWIFT_KEYWORDS,\n contains: [\n 'self',\n NUMBERS,\n STRING,\n hljs.C_BLOCK_COMMENT_MODE,\n {begin: ':'} // relevance booster\n ],\n illegal: /[\"']/\n }\n ],\n illegal: /\\[|%/\n },\n {\n className: 'class',\n beginKeywords: 'struct protocol class extension enum',\n keywords: SWIFT_KEYWORDS,\n end: '\\\\{',\n excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: /[A-Za-z$_][\\u00C0-\\u02B80-9A-Za-z$_]*/})\n ]\n },\n {\n className: 'meta', // @attributes\n begin: '(@discardableResult|@warn_unused_result|@exported|@lazy|@noescape|' +\n '@NSCopying|@NSManaged|@objc|@objcMembers|@convention|@required|' +\n '@noreturn|@IBAction|@IBDesignable|@IBInspectable|@IBOutlet|' +\n '@infix|@prefix|@postfix|@autoclosure|@testable|@available|' +\n '@nonobjc|@NSApplicationMain|@UIApplicationMain|@dynamicMemberLookup|' +\n '@propertyWrapper)\\\\b'\n\n },\n {\n beginKeywords: 'import', end: /$/,\n contains: [hljs.C_LINE_COMMENT_MODE, BLOCK_COMMENT]\n }\n ]\n };\n}", "title": "" }, { "docid": "bc270c5f3a7e71a3708e0dca0bd29d07", "score": "0.5739412", "text": "function swift(hljs) {\n var SWIFT_KEYWORDS = {\n keyword: '#available #colorLiteral #column #else #elseif #endif #file ' +\n '#fileLiteral #function #if #imageLiteral #line #selector #sourceLocation ' +\n '_ __COLUMN__ __FILE__ __FUNCTION__ __LINE__ Any as as! as? associatedtype ' +\n 'associativity break case catch class continue convenience default defer deinit didSet do ' +\n 'dynamic dynamicType else enum extension fallthrough false fileprivate final for func ' +\n 'get guard if import in indirect infix init inout internal is lazy left let ' +\n 'mutating nil none nonmutating open operator optional override postfix precedence ' +\n 'prefix private protocol Protocol public repeat required rethrows return ' +\n 'right self Self set static struct subscript super switch throw throws true ' +\n 'try try! try? Type typealias unowned var weak where while willSet',\n literal: 'true false nil',\n built_in: 'abs advance alignof alignofValue anyGenerator assert assertionFailure ' +\n 'bridgeFromObjectiveC bridgeFromObjectiveCUnconditional bridgeToObjectiveC ' +\n 'bridgeToObjectiveCUnconditional c compactMap contains count countElements countLeadingZeros ' +\n 'debugPrint debugPrintln distance dropFirst dropLast dump encodeBitsAsWords ' +\n 'enumerate equal fatalError filter find getBridgedObjectiveCType getVaList ' +\n 'indices insertionSort isBridgedToObjectiveC isBridgedVerbatimToObjectiveC ' +\n 'isUniquelyReferenced isUniquelyReferencedNonObjC join lazy lexicographicalCompare ' +\n 'map max maxElement min minElement numericCast overlaps partition posix ' +\n 'precondition preconditionFailure print println quickSort readLine reduce reflect ' +\n 'reinterpretCast reverse roundUpToAlignment sizeof sizeofValue sort split ' +\n 'startsWith stride strideof strideofValue swap toString transcode ' +\n 'underestimateCount unsafeAddressOf unsafeBitCast unsafeDowncast unsafeUnwrap ' +\n 'unsafeReflect withExtendedLifetime withObjectAtPlusZero withUnsafePointer ' +\n 'withUnsafePointerToObject withUnsafeMutablePointer withUnsafeMutablePointers ' +\n 'withUnsafePointer withUnsafePointers withVaList zip'\n };\n\n var TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*',\n relevance: 0\n };\n // slightly more special to swift\n var OPTIONAL_USING_TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*[!?]'\n };\n var BLOCK_COMMENT = hljs.COMMENT(\n '/\\\\*',\n '\\\\*/',\n {\n contains: ['self']\n }\n );\n var SUBST = {\n className: 'subst',\n begin: /\\\\\\(/, end: '\\\\)',\n keywords: SWIFT_KEYWORDS,\n contains: [] // assigned later\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /\"\"\"/, end: /\"\"\"/},\n {begin: /\"/, end: /\"/},\n ]\n };\n var NUMBERS = {\n className: 'number',\n begin: '\\\\b([\\\\d_]+(\\\\.[\\\\deE_]+)?|0x[a-fA-F0-9_]+(\\\\.[a-fA-F0-9p_]+)?|0b[01_]+|0o[0-7_]+)\\\\b',\n relevance: 0\n };\n SUBST.contains = [NUMBERS];\n\n return {\n name: 'Swift',\n keywords: SWIFT_KEYWORDS,\n contains: [\n STRING,\n hljs.C_LINE_COMMENT_MODE,\n BLOCK_COMMENT,\n OPTIONAL_USING_TYPE,\n TYPE,\n NUMBERS,\n {\n className: 'function',\n beginKeywords: 'func', end: '{', excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {\n begin: /[A-Za-z$_][0-9A-Za-z$_]*/\n }),\n {\n begin: /</, end: />/\n },\n {\n className: 'params',\n begin: /\\(/, end: /\\)/, endsParent: true,\n keywords: SWIFT_KEYWORDS,\n contains: [\n 'self',\n NUMBERS,\n STRING,\n hljs.C_BLOCK_COMMENT_MODE,\n {begin: ':'} // relevance booster\n ],\n illegal: /[\"']/\n }\n ],\n illegal: /\\[|%/\n },\n {\n className: 'class',\n beginKeywords: 'struct protocol class extension enum',\n keywords: SWIFT_KEYWORDS,\n end: '\\\\{',\n excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: /[A-Za-z$_][\\u00C0-\\u02B80-9A-Za-z$_]*/})\n ]\n },\n {\n className: 'meta', // @attributes\n begin: '(@discardableResult|@warn_unused_result|@exported|@lazy|@noescape|' +\n '@NSCopying|@NSManaged|@objc|@objcMembers|@convention|@required|' +\n '@noreturn|@IBAction|@IBDesignable|@IBInspectable|@IBOutlet|' +\n '@infix|@prefix|@postfix|@autoclosure|@testable|@available|' +\n '@nonobjc|@NSApplicationMain|@UIApplicationMain|@dynamicMemberLookup|' +\n '@propertyWrapper)\\\\b'\n\n },\n {\n beginKeywords: 'import', end: /$/,\n contains: [hljs.C_LINE_COMMENT_MODE, BLOCK_COMMENT]\n }\n ]\n };\n}", "title": "" }, { "docid": "6764e336b341388d9fa0909c1b985516", "score": "0.5509269", "text": "function cpp() {\n return new LanguageSupport(cppLanguage);\n}", "title": "" }, { "docid": "f042e547e78b939f05b333ea29a08543", "score": "0.5468602", "text": "function Xh(a,b){this.h=a;this.A=null;this.type=b;this.qa=this.gc=0;this.bc=a.t.Js;this.ci=!this.bc;this.rc=!1}", "title": "" }, { "docid": "354016224ee191eaf20cc9eaf37c1d75", "score": "0.53938127", "text": "function py()\n{\n\tvar arr = arrayfromargs(arguments);\n\t// post(arr + \"\\n\");\n\tvar res = pyjs.code(arr)\n\tif (res)\n\t\toutlet(0, res);\n}", "title": "" }, { "docid": "ed38fa56d71503fa0a835fb8ccd4b15c", "score": "0.5364773", "text": "function Z(){this.name=\"Python Framework\";this.c=new V;this.a=\"\"}", "title": "" }, { "docid": "e1e7094aeebce60d80892c15a25e6b8c", "score": "0.5336358", "text": "function julia(hljs) {\n // Since there are numerous special names in Julia, it is too much trouble\n // to maintain them by hand. Hence these names (i.e. keywords, literals and\n // built-ins) are automatically generated from Julia v0.6 itself through\n // the following scripts for each.\n\n // ref: http://julia.readthedocs.org/en/latest/manual/variables/#allowed-variable-names\n var VARIABLE_NAME_RE = '[A-Za-z_\\\\u00A1-\\\\uFFFF][A-Za-z_0-9\\\\u00A1-\\\\uFFFF]*';\n\n var KEYWORDS = {\n $pattern: VARIABLE_NAME_RE,\n // # keyword generator, multi-word keywords handled manually below\n // foreach(println, [\"in\", \"isa\", \"where\"])\n // for kw in Base.REPLCompletions.complete_keyword(\"\")\n // if !(contains(kw, \" \") || kw == \"struct\")\n // println(kw)\n // end\n // end\n keyword:\n 'in isa where ' +\n 'baremodule begin break catch ccall const continue do else elseif end export false finally for function ' +\n 'global if import importall let local macro module quote return true try using while ' +\n // legacy, to be deprecated in the next release\n 'type immutable abstract bitstype typealias ',\n\n // # literal generator\n // println(\"true\")\n // println(\"false\")\n // for name in Base.REPLCompletions.completions(\"\", 0)[1]\n // try\n // v = eval(Symbol(name))\n // if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)\n // println(name)\n // end\n // end\n // end\n literal:\n 'true false ' +\n 'ARGS C_NULL DevNull ENDIAN_BOM ENV I Inf Inf16 Inf32 Inf64 InsertionSort JULIA_HOME LOAD_PATH MergeSort ' +\n 'NaN NaN16 NaN32 NaN64 PROGRAM_FILE QuickSort RoundDown RoundFromZero RoundNearest RoundNearestTiesAway ' +\n 'RoundNearestTiesUp RoundToZero RoundUp STDERR STDIN STDOUT VERSION catalan e|0 eu|0 eulergamma golden im ' +\n 'nothing pi γ π φ ',\n\n // # built_in generator:\n // for name in Base.REPLCompletions.completions(\"\", 0)[1]\n // try\n // v = eval(Symbol(name))\n // if v isa Type || v isa TypeVar\n // println(name)\n // end\n // end\n // end\n built_in:\n 'ANY AbstractArray AbstractChannel AbstractFloat AbstractMatrix AbstractRNG AbstractSerializer AbstractSet ' +\n 'AbstractSparseArray AbstractSparseMatrix AbstractSparseVector AbstractString AbstractUnitRange AbstractVecOrMat ' +\n 'AbstractVector Any ArgumentError Array AssertionError Associative Base64DecodePipe Base64EncodePipe Bidiagonal '+\n 'BigFloat BigInt BitArray BitMatrix BitVector Bool BoundsError BufferStream CachingPool CapturedException ' +\n 'CartesianIndex CartesianRange Cchar Cdouble Cfloat Channel Char Cint Cintmax_t Clong Clonglong ClusterManager ' +\n 'Cmd CodeInfo Colon Complex Complex128 Complex32 Complex64 CompositeException Condition ConjArray ConjMatrix ' +\n 'ConjVector Cptrdiff_t Cshort Csize_t Cssize_t Cstring Cuchar Cuint Cuintmax_t Culong Culonglong Cushort Cwchar_t ' +\n 'Cwstring DataType Date DateFormat DateTime DenseArray DenseMatrix DenseVecOrMat DenseVector Diagonal Dict ' +\n 'DimensionMismatch Dims DirectIndexString Display DivideError DomainError EOFError EachLine Enum Enumerate ' +\n 'ErrorException Exception ExponentialBackOff Expr Factorization FileMonitor Float16 Float32 Float64 Function ' +\n 'Future GlobalRef GotoNode HTML Hermitian IO IOBuffer IOContext IOStream IPAddr IPv4 IPv6 IndexCartesian IndexLinear ' +\n 'IndexStyle InexactError InitError Int Int128 Int16 Int32 Int64 Int8 IntSet Integer InterruptException ' +\n 'InvalidStateException Irrational KeyError LabelNode LinSpace LineNumberNode LoadError LowerTriangular MIME Matrix ' +\n 'MersenneTwister Method MethodError MethodTable Module NTuple NewvarNode NullException Nullable Number ObjectIdDict ' +\n 'OrdinalRange OutOfMemoryError OverflowError Pair ParseError PartialQuickSort PermutedDimsArray Pipe ' +\n 'PollingFileWatcher ProcessExitedException Ptr QuoteNode RandomDevice Range RangeIndex Rational RawFD ' +\n 'ReadOnlyMemoryError Real ReentrantLock Ref Regex RegexMatch RemoteChannel RemoteException RevString RoundingMode ' +\n 'RowVector SSAValue SegmentationFault SerializationState Set SharedArray SharedMatrix SharedVector Signed ' +\n 'SimpleVector Slot SlotNumber SparseMatrixCSC SparseVector StackFrame StackOverflowError StackTrace StepRange ' +\n 'StepRangeLen StridedArray StridedMatrix StridedVecOrMat StridedVector String SubArray SubString SymTridiagonal ' +\n 'Symbol Symmetric SystemError TCPSocket Task Text TextDisplay Timer Tridiagonal Tuple Type TypeError TypeMapEntry ' +\n 'TypeMapLevel TypeName TypeVar TypedSlot UDPSocket UInt UInt128 UInt16 UInt32 UInt64 UInt8 UndefRefError UndefVarError ' +\n 'UnicodeError UniformScaling Union UnionAll UnitRange Unsigned UpperTriangular Val Vararg VecElement VecOrMat Vector ' +\n 'VersionNumber Void WeakKeyDict WeakRef WorkerConfig WorkerPool '\n };\n\n // placeholder for recursive self-reference\n var DEFAULT = {\n keywords: KEYWORDS, illegal: /<\\//\n };\n\n // ref: http://julia.readthedocs.org/en/latest/manual/integers-and-floating-point-numbers/\n var NUMBER = {\n className: 'number',\n // supported numeric literals:\n // * binary literal (e.g. 0x10)\n // * octal literal (e.g. 0o76543210)\n // * hexadecimal literal (e.g. 0xfedcba876543210)\n // * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)\n // * decimal literal (e.g. 9876543210, 100_000_000)\n // * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)\n begin: /(\\b0x[\\d_]*(\\.[\\d_]*)?|0x\\.\\d[\\d_]*)p[-+]?\\d+|\\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\\b\\d[\\d_]*(\\.[\\d_]*)?|\\.\\d[\\d_]*)([eEfF][-+]?\\d+)?/,\n relevance: 0\n };\n\n var CHAR = {\n className: 'string',\n begin: /'(.|\\\\[xXuU][a-zA-Z0-9]+)'/\n };\n\n var INTERPOLATION = {\n className: 'subst',\n begin: /\\$\\(/, end: /\\)/,\n keywords: KEYWORDS\n };\n\n var INTERPOLATED_VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + VARIABLE_NAME_RE\n };\n\n // TODO: neatly escape normal code in string literal\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n variants: [\n { begin: /\\w*\"\"\"/, end: /\"\"\"\\w*/, relevance: 10 },\n { begin: /\\w*\"/, end: /\"\\w*/ }\n ]\n };\n\n var COMMAND = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n begin: '`', end: '`'\n };\n\n var MACROCALL = {\n className: 'meta',\n begin: '@' + VARIABLE_NAME_RE\n };\n\n var COMMENT = {\n className: 'comment',\n variants: [\n { begin: '#=', end: '=#', relevance: 10 },\n { begin: '#', end: '$' }\n ]\n };\n\n DEFAULT.name = 'Julia';\n DEFAULT.contains = [\n NUMBER,\n CHAR,\n STRING,\n COMMAND,\n MACROCALL,\n COMMENT,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'keyword',\n begin:\n '\\\\b(((abstract|primitive)\\\\s+)type|(mutable\\\\s+)?struct)\\\\b'\n },\n {begin: /<:/} // relevance booster\n ];\n INTERPOLATION.contains = DEFAULT.contains;\n\n return DEFAULT;\n}", "title": "" }, { "docid": "e1e7094aeebce60d80892c15a25e6b8c", "score": "0.5336358", "text": "function julia(hljs) {\n // Since there are numerous special names in Julia, it is too much trouble\n // to maintain them by hand. Hence these names (i.e. keywords, literals and\n // built-ins) are automatically generated from Julia v0.6 itself through\n // the following scripts for each.\n\n // ref: http://julia.readthedocs.org/en/latest/manual/variables/#allowed-variable-names\n var VARIABLE_NAME_RE = '[A-Za-z_\\\\u00A1-\\\\uFFFF][A-Za-z_0-9\\\\u00A1-\\\\uFFFF]*';\n\n var KEYWORDS = {\n $pattern: VARIABLE_NAME_RE,\n // # keyword generator, multi-word keywords handled manually below\n // foreach(println, [\"in\", \"isa\", \"where\"])\n // for kw in Base.REPLCompletions.complete_keyword(\"\")\n // if !(contains(kw, \" \") || kw == \"struct\")\n // println(kw)\n // end\n // end\n keyword:\n 'in isa where ' +\n 'baremodule begin break catch ccall const continue do else elseif end export false finally for function ' +\n 'global if import importall let local macro module quote return true try using while ' +\n // legacy, to be deprecated in the next release\n 'type immutable abstract bitstype typealias ',\n\n // # literal generator\n // println(\"true\")\n // println(\"false\")\n // for name in Base.REPLCompletions.completions(\"\", 0)[1]\n // try\n // v = eval(Symbol(name))\n // if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)\n // println(name)\n // end\n // end\n // end\n literal:\n 'true false ' +\n 'ARGS C_NULL DevNull ENDIAN_BOM ENV I Inf Inf16 Inf32 Inf64 InsertionSort JULIA_HOME LOAD_PATH MergeSort ' +\n 'NaN NaN16 NaN32 NaN64 PROGRAM_FILE QuickSort RoundDown RoundFromZero RoundNearest RoundNearestTiesAway ' +\n 'RoundNearestTiesUp RoundToZero RoundUp STDERR STDIN STDOUT VERSION catalan e|0 eu|0 eulergamma golden im ' +\n 'nothing pi γ π φ ',\n\n // # built_in generator:\n // for name in Base.REPLCompletions.completions(\"\", 0)[1]\n // try\n // v = eval(Symbol(name))\n // if v isa Type || v isa TypeVar\n // println(name)\n // end\n // end\n // end\n built_in:\n 'ANY AbstractArray AbstractChannel AbstractFloat AbstractMatrix AbstractRNG AbstractSerializer AbstractSet ' +\n 'AbstractSparseArray AbstractSparseMatrix AbstractSparseVector AbstractString AbstractUnitRange AbstractVecOrMat ' +\n 'AbstractVector Any ArgumentError Array AssertionError Associative Base64DecodePipe Base64EncodePipe Bidiagonal '+\n 'BigFloat BigInt BitArray BitMatrix BitVector Bool BoundsError BufferStream CachingPool CapturedException ' +\n 'CartesianIndex CartesianRange Cchar Cdouble Cfloat Channel Char Cint Cintmax_t Clong Clonglong ClusterManager ' +\n 'Cmd CodeInfo Colon Complex Complex128 Complex32 Complex64 CompositeException Condition ConjArray ConjMatrix ' +\n 'ConjVector Cptrdiff_t Cshort Csize_t Cssize_t Cstring Cuchar Cuint Cuintmax_t Culong Culonglong Cushort Cwchar_t ' +\n 'Cwstring DataType Date DateFormat DateTime DenseArray DenseMatrix DenseVecOrMat DenseVector Diagonal Dict ' +\n 'DimensionMismatch Dims DirectIndexString Display DivideError DomainError EOFError EachLine Enum Enumerate ' +\n 'ErrorException Exception ExponentialBackOff Expr Factorization FileMonitor Float16 Float32 Float64 Function ' +\n 'Future GlobalRef GotoNode HTML Hermitian IO IOBuffer IOContext IOStream IPAddr IPv4 IPv6 IndexCartesian IndexLinear ' +\n 'IndexStyle InexactError InitError Int Int128 Int16 Int32 Int64 Int8 IntSet Integer InterruptException ' +\n 'InvalidStateException Irrational KeyError LabelNode LinSpace LineNumberNode LoadError LowerTriangular MIME Matrix ' +\n 'MersenneTwister Method MethodError MethodTable Module NTuple NewvarNode NullException Nullable Number ObjectIdDict ' +\n 'OrdinalRange OutOfMemoryError OverflowError Pair ParseError PartialQuickSort PermutedDimsArray Pipe ' +\n 'PollingFileWatcher ProcessExitedException Ptr QuoteNode RandomDevice Range RangeIndex Rational RawFD ' +\n 'ReadOnlyMemoryError Real ReentrantLock Ref Regex RegexMatch RemoteChannel RemoteException RevString RoundingMode ' +\n 'RowVector SSAValue SegmentationFault SerializationState Set SharedArray SharedMatrix SharedVector Signed ' +\n 'SimpleVector Slot SlotNumber SparseMatrixCSC SparseVector StackFrame StackOverflowError StackTrace StepRange ' +\n 'StepRangeLen StridedArray StridedMatrix StridedVecOrMat StridedVector String SubArray SubString SymTridiagonal ' +\n 'Symbol Symmetric SystemError TCPSocket Task Text TextDisplay Timer Tridiagonal Tuple Type TypeError TypeMapEntry ' +\n 'TypeMapLevel TypeName TypeVar TypedSlot UDPSocket UInt UInt128 UInt16 UInt32 UInt64 UInt8 UndefRefError UndefVarError ' +\n 'UnicodeError UniformScaling Union UnionAll UnitRange Unsigned UpperTriangular Val Vararg VecElement VecOrMat Vector ' +\n 'VersionNumber Void WeakKeyDict WeakRef WorkerConfig WorkerPool '\n };\n\n // placeholder for recursive self-reference\n var DEFAULT = {\n keywords: KEYWORDS, illegal: /<\\//\n };\n\n // ref: http://julia.readthedocs.org/en/latest/manual/integers-and-floating-point-numbers/\n var NUMBER = {\n className: 'number',\n // supported numeric literals:\n // * binary literal (e.g. 0x10)\n // * octal literal (e.g. 0o76543210)\n // * hexadecimal literal (e.g. 0xfedcba876543210)\n // * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)\n // * decimal literal (e.g. 9876543210, 100_000_000)\n // * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)\n begin: /(\\b0x[\\d_]*(\\.[\\d_]*)?|0x\\.\\d[\\d_]*)p[-+]?\\d+|\\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\\b\\d[\\d_]*(\\.[\\d_]*)?|\\.\\d[\\d_]*)([eEfF][-+]?\\d+)?/,\n relevance: 0\n };\n\n var CHAR = {\n className: 'string',\n begin: /'(.|\\\\[xXuU][a-zA-Z0-9]+)'/\n };\n\n var INTERPOLATION = {\n className: 'subst',\n begin: /\\$\\(/, end: /\\)/,\n keywords: KEYWORDS\n };\n\n var INTERPOLATED_VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + VARIABLE_NAME_RE\n };\n\n // TODO: neatly escape normal code in string literal\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n variants: [\n { begin: /\\w*\"\"\"/, end: /\"\"\"\\w*/, relevance: 10 },\n { begin: /\\w*\"/, end: /\"\\w*/ }\n ]\n };\n\n var COMMAND = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n begin: '`', end: '`'\n };\n\n var MACROCALL = {\n className: 'meta',\n begin: '@' + VARIABLE_NAME_RE\n };\n\n var COMMENT = {\n className: 'comment',\n variants: [\n { begin: '#=', end: '=#', relevance: 10 },\n { begin: '#', end: '$' }\n ]\n };\n\n DEFAULT.name = 'Julia';\n DEFAULT.contains = [\n NUMBER,\n CHAR,\n STRING,\n COMMAND,\n MACROCALL,\n COMMENT,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'keyword',\n begin:\n '\\\\b(((abstract|primitive)\\\\s+)type|(mutable\\\\s+)?struct)\\\\b'\n },\n {begin: /<:/} // relevance booster\n ];\n INTERPOLATION.contains = DEFAULT.contains;\n\n return DEFAULT;\n}", "title": "" }, { "docid": "ea4eec3d26184ef2086e5c103bdb4b73", "score": "0.5322614", "text": "function h(){}", "title": "" }, { "docid": "ea4eec3d26184ef2086e5c103bdb4b73", "score": "0.5322614", "text": "function h(){}", "title": "" }, { "docid": "945ef8627dc851419f101ab8854e2c55", "score": "0.5297731", "text": "enterTypeDeclaration(ctx) {\n\t}", "title": "" }, { "docid": "5cedbd1badfd199fadbd6590d7595f62", "score": "0.5290078", "text": "function scala(hljs) {\n\n var ANNOTATION = { className: 'meta', begin: '@[A-Za-z]+' };\n\n // used in strings for escaping/interpolation/substitution\n var SUBST = {\n className: 'subst',\n variants: [\n {begin: '\\\\$[A-Za-z0-9_]+'},\n {begin: '\\\\${', end: '}'}\n ]\n };\n\n var STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"', end: '\"',\n illegal: '\\\\n',\n contains: [hljs.BACKSLASH_ESCAPE]\n },\n {\n begin: '\"\"\"', end: '\"\"\"',\n relevance: 10\n },\n {\n begin: '[a-z]+\"', end: '\"',\n illegal: '\\\\n',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST]\n },\n {\n className: 'string',\n begin: '[a-z]+\"\"\"', end: '\"\"\"',\n contains: [SUBST],\n relevance: 10\n }\n ]\n\n };\n\n var SYMBOL = {\n className: 'symbol',\n begin: '\\'\\\\w[\\\\w\\\\d_]*(?!\\')'\n };\n\n var TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][A-Za-z0-9_]*',\n relevance: 0\n };\n\n var NAME = {\n className: 'title',\n begin: /[^0-9\\n\\t \"'(),.`{}\\[\\]:;][^\\n\\t \"'(),.`{}\\[\\]:;]+|[^0-9\\n\\t \"'(),.`{}\\[\\]:;=]/,\n relevance: 0\n };\n\n var CLASS = {\n className: 'class',\n beginKeywords: 'class object trait type',\n end: /[:={\\[\\n;]/,\n excludeEnd: true,\n contains: [\n {\n beginKeywords: 'extends with',\n relevance: 10\n },\n {\n begin: /\\[/,\n end: /\\]/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [TYPE]\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [TYPE]\n },\n NAME\n ]\n };\n\n var METHOD = {\n className: 'function',\n beginKeywords: 'def',\n end: /[:={\\[(\\n;]/,\n excludeEnd: true,\n contains: [NAME]\n };\n\n return {\n name: 'Scala',\n keywords: {\n literal: 'true false null',\n keyword: 'type yield lazy override def with val var sealed abstract private trait object if forSome for while throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n STRING,\n SYMBOL,\n TYPE,\n METHOD,\n CLASS,\n hljs.C_NUMBER_MODE,\n ANNOTATION\n ]\n };\n}", "title": "" }, { "docid": "810ef888b13bbd3f377664c813c6b2f7", "score": "0.5276051", "text": "function o0(stdlib,o1,Module) {\n try {\n\"use asm\";\n}catch(e){}\n function add(o2,o3) {\n try {\nthis;\n}catch(e){}\n try {\no56.prototype = +e;\n}catch(e){}\n try {\nreturn +(o2+o3);\n}catch(\"TextMetrics\"){}\n }\n \n var o263 = 4096\n \n var o7 = [add,add,add,add];\n \n \n try {\nreturn { \n o4 : o4\n };\n}catch(e){}\n}", "title": "" }, { "docid": "6ebb9a8aba4cea853c53db35fdaf3e3f", "score": "0.5269743", "text": "function sayHello() {\n console.log(\"Hello to TypeScript beginners\");\n}", "title": "" }, { "docid": "1608b654114a13aae83adb8fcc812d61", "score": "0.52665746", "text": "function swift(hljs){var WHITESPACE={match:/\\s+/,relevance:0};// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID411\nvar BLOCK_COMMENT=hljs.COMMENT('/\\\\*','\\\\*/',{contains:['self']});var COMMENTS=[hljs.C_LINE_COMMENT_MODE,BLOCK_COMMENT];// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID413\n// https://docs.swift.org/swift-book/ReferenceManual/zzSummaryOfTheGrammar.html\nvar DOT_KEYWORD={match:[/\\./,either$1.apply(void 0,_toConsumableArray(dotKeywords).concat(_toConsumableArray(optionalDotKeywords)))],className:{2:\"keyword\"}};var KEYWORD_GUARD={// Consume .keyword to prevent highlighting properties and methods as keywords.\nmatch:concat$1(/\\./,either$1.apply(void 0,keywords)),relevance:0};var PLAIN_KEYWORDS=keywords.filter(function(kw){return typeof kw==='string';}).concat([\"_|0\"]);// seems common, so 0 relevance\nvar REGEX_KEYWORDS=keywords.filter(function(kw){return typeof kw!=='string';})// find regex\n.concat(keywordTypes).map(keywordWrapper);var KEYWORD={variants:[{className:'keyword',match:either$1.apply(void 0,_toConsumableArray(REGEX_KEYWORDS).concat(_toConsumableArray(optionalDotKeywords)))}]};// find all the regular keywords\nvar KEYWORDS={$pattern:either$1(/\\b\\w+/,// regular keywords\n/#\\w+/ // number keywords\n),keyword:PLAIN_KEYWORDS.concat(numberSignKeywords),literal:literals};var KEYWORD_MODES=[DOT_KEYWORD,KEYWORD_GUARD,KEYWORD];// https://github.com/apple/swift/tree/main/stdlib/public/core\nvar BUILT_IN_GUARD={// Consume .built_in to prevent highlighting properties and methods.\nmatch:concat$1(/\\./,either$1.apply(void 0,builtIns)),relevance:0};var BUILT_IN={className:'built_in',match:concat$1(/\\b/,either$1.apply(void 0,builtIns),/(?=\\()/)};var BUILT_INS=[BUILT_IN_GUARD,BUILT_IN];// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID418\nvar OPERATOR_GUARD={// Prevent -> from being highlighting as an operator.\nmatch:/->/,relevance:0};var OPERATOR={className:'operator',relevance:0,variants:[{match:operator},{// dot-operator: only operators that start with a dot are allowed to use dots as\n// characters (..., ...<, .*, etc). So there rule here is: a dot followed by one or more\n// characters that may also include dots.\nmatch:\"\\\\.(\\\\.|\".concat(operatorCharacter,\")+\")}]};var OPERATORS=[OPERATOR_GUARD,OPERATOR];// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#grammar_numeric-literal\n// TODO: Update for leading `-` after lookbehind is supported everywhere\nvar decimalDigits='([0-9]_*)+';var hexDigits='([0-9a-fA-F]_*)+';var NUMBER={className:'number',relevance:0,variants:[// decimal floating-point-literal (subsumes decimal-literal)\n{match:\"\\\\b(\".concat(decimalDigits,\")(\\\\.(\").concat(decimalDigits,\"))?\")+\"([eE][+-]?(\".concat(decimalDigits,\"))?\\\\b\")},// hexadecimal floating-point-literal (subsumes hexadecimal-literal)\n{match:\"\\\\b0x(\".concat(hexDigits,\")(\\\\.(\").concat(hexDigits,\"))?\")+\"([pP][+-]?(\".concat(decimalDigits,\"))?\\\\b\")},// octal-literal\n{match:/\\b0o([0-7]_*)+\\b/},// binary-literal\n{match:/\\b0b([01]_*)+\\b/}]};// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#grammar_string-literal\nvar ESCAPED_CHARACTER=function ESCAPED_CHARACTER(){var rawDelimiter=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"\";return{className:'subst',variants:[{match:concat$1(/\\\\/,rawDelimiter,/[0\\\\tnr\"']/)},{match:concat$1(/\\\\/,rawDelimiter,/u\\{[0-9a-fA-F]{1,8}\\}/)}]};};var ESCAPED_NEWLINE=function ESCAPED_NEWLINE(){var rawDelimiter=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"\";return{className:'subst',match:concat$1(/\\\\/,rawDelimiter,/[\\t ]*(?:[\\r\\n]|\\r\\n)/)};};var INTERPOLATION=function INTERPOLATION(){var rawDelimiter=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"\";return{className:'subst',label:\"interpol\",begin:concat$1(/\\\\/,rawDelimiter,/\\(/),end:/\\)/};};var MULTILINE_STRING=function MULTILINE_STRING(){var rawDelimiter=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"\";return{begin:concat$1(rawDelimiter,/\"\"\"/),end:concat$1(/\"\"\"/,rawDelimiter),contains:[ESCAPED_CHARACTER(rawDelimiter),ESCAPED_NEWLINE(rawDelimiter),INTERPOLATION(rawDelimiter)]};};var SINGLE_LINE_STRING=function SINGLE_LINE_STRING(){var rawDelimiter=arguments.length>0&&arguments[0]!==undefined?arguments[0]:\"\";return{begin:concat$1(rawDelimiter,/\"/),end:concat$1(/\"/,rawDelimiter),contains:[ESCAPED_CHARACTER(rawDelimiter),INTERPOLATION(rawDelimiter)]};};var STRING={className:'string',variants:[MULTILINE_STRING(),MULTILINE_STRING(\"#\"),MULTILINE_STRING(\"##\"),MULTILINE_STRING(\"###\"),SINGLE_LINE_STRING(),SINGLE_LINE_STRING(\"#\"),SINGLE_LINE_STRING(\"##\"),SINGLE_LINE_STRING(\"###\")]};// https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#ID412\nvar QUOTED_IDENTIFIER={match:concat$1(/`/,identifier,/`/)};var IMPLICIT_PARAMETER={className:'variable',match:/\\$\\d+/};var PROPERTY_WRAPPER_PROJECTION={className:'variable',match:\"\\\\$\".concat(identifierCharacter,\"+\")};var IDENTIFIERS=[QUOTED_IDENTIFIER,IMPLICIT_PARAMETER,PROPERTY_WRAPPER_PROJECTION];// https://docs.swift.org/swift-book/ReferenceManual/Attributes.html\nvar AVAILABLE_ATTRIBUTE={match:/(@|#)available/,className:\"keyword\",starts:{contains:[{begin:/\\(/,end:/\\)/,keywords:availabilityKeywords,contains:[].concat(OPERATORS,[NUMBER,STRING])}]}};var KEYWORD_ATTRIBUTE={className:'keyword',match:concat$1(/@/,either$1.apply(void 0,keywordAttributes))};var USER_DEFINED_ATTRIBUTE={className:'meta',match:concat$1(/@/,identifier)};var ATTRIBUTES=[AVAILABLE_ATTRIBUTE,KEYWORD_ATTRIBUTE,USER_DEFINED_ATTRIBUTE];// https://docs.swift.org/swift-book/ReferenceManual/Types.html\nvar TYPE={match:lookahead$1(/\\b[A-Z]/),relevance:0,contains:[{// Common Apple frameworks, for relevance boost\nclassName:'type',match:concat$1(/(AV|CA|CF|CG|CI|CL|CM|CN|CT|MK|MP|MTK|MTL|NS|SCN|SK|UI|WK|XC)/,identifierCharacter,'+')},{// Type identifier\nclassName:'type',match:typeIdentifier,relevance:0},{// Optional type\nmatch:/[?!]+/,relevance:0},{// Variadic parameter\nmatch:/\\.\\.\\./,relevance:0},{// Protocol composition\nmatch:concat$1(/\\s+&\\s+/,lookahead$1(typeIdentifier)),relevance:0}]};var GENERIC_ARGUMENTS={begin:/</,end:/>/,keywords:KEYWORDS,contains:[].concat(COMMENTS,KEYWORD_MODES,ATTRIBUTES,[OPERATOR_GUARD,TYPE])};TYPE.contains.push(GENERIC_ARGUMENTS);// https://docs.swift.org/swift-book/ReferenceManual/Expressions.html#ID552\n// Prevents element names from being highlighted as keywords.\nvar TUPLE_ELEMENT_NAME={match:concat$1(identifier,/\\s*:/),keywords:\"_|0\",relevance:0};// Matches tuples as well as the parameter list of a function type.\nvar TUPLE={begin:/\\(/,end:/\\)/,relevance:0,keywords:KEYWORDS,contains:['self',TUPLE_ELEMENT_NAME].concat(COMMENTS,KEYWORD_MODES,BUILT_INS,OPERATORS,[NUMBER,STRING],IDENTIFIERS,ATTRIBUTES,[TYPE])};var GENERIC_PARAMETERS={begin:/</,end:/>/,contains:[].concat(COMMENTS,[TYPE])};var FUNCTION_PARAMETER_NAME={begin:either$1(lookahead$1(concat$1(identifier,/\\s*:/)),lookahead$1(concat$1(identifier,/\\s+/,identifier,/\\s*:/))),end:/:/,relevance:0,contains:[{className:'keyword',match:/\\b_\\b/},{className:'params',match:identifier}]};var FUNCTION_PARAMETERS={begin:/\\(/,end:/\\)/,keywords:KEYWORDS,contains:[FUNCTION_PARAMETER_NAME].concat(COMMENTS,KEYWORD_MODES,OPERATORS,[NUMBER,STRING],ATTRIBUTES,[TYPE,TUPLE]),endsParent:true,illegal:/[\"']/};// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID362\nvar FUNCTION={match:[/func/,/\\s+/,either$1(QUOTED_IDENTIFIER.match,identifier,operator)],className:{1:\"keyword\",3:\"title.function\"},contains:[GENERIC_PARAMETERS,FUNCTION_PARAMETERS,WHITESPACE],illegal:[/\\[/,/%/]};// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID375\n// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID379\nvar INIT_SUBSCRIPT={match:[/\\b(?:subscript|init[?!]?)/,/\\s*(?=[<(])/],className:{1:\"keyword\"},contains:[GENERIC_PARAMETERS,FUNCTION_PARAMETERS,WHITESPACE],illegal:/\\[|%/};// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID380\nvar OPERATOR_DECLARATION={match:[/operator/,/\\s+/,operator],className:{1:\"keyword\",3:\"title\"}};// https://docs.swift.org/swift-book/ReferenceManual/Declarations.html#ID550\nvar PRECEDENCEGROUP={begin:[/precedencegroup/,/\\s+/,typeIdentifier],className:{1:\"keyword\",3:\"title\"},contains:[TYPE],keywords:[].concat(precedencegroupKeywords,literals),end:/}/};// Add supported submodes to string interpolation.\nvar _iterator=_createForOfIteratorHelper(STRING.variants),_step;try{for(_iterator.s();!(_step=_iterator.n()).done;){var variant=_step.value;var interpolation=variant.contains.find(function(mode){return mode.label===\"interpol\";});// TODO: Interpolation can contain any expression, so there's room for improvement here.\ninterpolation.keywords=KEYWORDS;var submodes=[].concat(KEYWORD_MODES,BUILT_INS,OPERATORS,[NUMBER,STRING],IDENTIFIERS);interpolation.contains=[].concat(_toConsumableArray(submodes),[{begin:/\\(/,end:/\\)/,contains:['self'].concat(_toConsumableArray(submodes))}]);}}catch(err){_iterator.e(err);}finally{_iterator.f();}return{name:'Swift',keywords:KEYWORDS,contains:[].concat(COMMENTS,[FUNCTION,INIT_SUBSCRIPT,{beginKeywords:'struct protocol class extension enum actor',end:'\\\\{',excludeEnd:true,keywords:KEYWORDS,contains:[hljs.inherit(hljs.TITLE_MODE,{className:\"title.class\",begin:/[A-Za-z$_][\\u00C0-\\u02B80-9A-Za-z$_]*/})].concat(KEYWORD_MODES)},OPERATOR_DECLARATION,PRECEDENCEGROUP,{beginKeywords:'import',end:/$/,contains:[].concat(COMMENTS),relevance:0}],KEYWORD_MODES,BUILT_INS,OPERATORS,[NUMBER,STRING],IDENTIFIERS,ATTRIBUTES,[TYPE,TUPLE])};}", "title": "" }, { "docid": "263af154d02111c491ff42b10aa57213", "score": "0.52538127", "text": "function h() {\n }", "title": "" }, { "docid": "2ee426686d8597af8e34c951e627f004", "score": "0.5252791", "text": "function kotlin(hljs) {\n var KEYWORDS = {\n keyword:\n 'abstract as val var vararg get set class object open private protected public noinline ' +\n 'crossinline dynamic final enum if else do while for when throw try catch finally ' +\n 'import package is in fun override companion reified inline lateinit init ' +\n 'interface annotation data sealed internal infix operator out by constructor super ' +\n 'tailrec where const inner suspend typealias external expect actual',\n built_in:\n 'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',\n literal:\n 'true false null'\n };\n var KEYWORDS_WITH_LABEL = {\n className: 'keyword',\n begin: /\\b(break|continue|return|this)\\b/,\n starts: {\n contains: [\n {\n className: 'symbol',\n begin: /@\\w+/\n }\n ]\n }\n };\n var LABEL = {\n className: 'symbol', begin: hljs.UNDERSCORE_IDENT_RE + '@'\n };\n\n // for string templates\n var SUBST = {\n className: 'subst',\n begin: '\\\\${', end: '}', contains: [hljs.C_NUMBER_MODE]\n };\n var VARIABLE = {\n className: 'variable', begin: '\\\\$' + hljs.UNDERSCORE_IDENT_RE\n };\n var STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"', end: '\"\"\"(?=[^\"])',\n contains: [VARIABLE, SUBST]\n },\n // Can't use built-in modes easily, as we want to use STRING in the meta\n // context as 'meta-string' and there's no syntax to remove explicitly set\n // classNames in built-in modes.\n {\n begin: '\\'', end: '\\'',\n illegal: /\\n/,\n contains: [hljs.BACKSLASH_ESCAPE]\n },\n {\n begin: '\"', end: '\"',\n illegal: /\\n/,\n contains: [hljs.BACKSLASH_ESCAPE, VARIABLE, SUBST]\n }\n ]\n };\n SUBST.contains.push(STRING);\n\n var ANNOTATION_USE_SITE = {\n className: 'meta', begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'\n };\n var ANNOTATION = {\n className: 'meta', begin: '@' + hljs.UNDERSCORE_IDENT_RE,\n contains: [\n {\n begin: /\\(/, end: /\\)/,\n contains: [\n hljs.inherit(STRING, {className: 'meta-string'})\n ]\n }\n ]\n };\n\n // https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n // According to the doc above, the number mode of kotlin is the same as java 8,\n // so the code below is copied from java.js\n var KOTLIN_NUMBER_RE = '\\\\b' +\n '(' +\n '0[bB]([01]+[01_]+[01]+|[01]+)' + // 0b...\n '|' +\n '0[xX]([a-fA-F0-9]+[a-fA-F0-9_]+[a-fA-F0-9]+|[a-fA-F0-9]+)' + // 0x...\n '|' +\n '(' +\n '([\\\\d]+[\\\\d_]+[\\\\d]+|[\\\\d]+)(\\\\.([\\\\d]+[\\\\d_]+[\\\\d]+|[\\\\d]+))?' +\n '|' +\n '\\\\.([\\\\d]+[\\\\d_]+[\\\\d]+|[\\\\d]+)' +\n ')' +\n '([eE][-+]?\\\\d+)?' + // octal, decimal, float\n ')' +\n '[lLfF]?';\n var KOTLIN_NUMBER_MODE = {\n className: 'number',\n begin: KOTLIN_NUMBER_RE,\n relevance: 0\n };\n var KOTLIN_NESTED_COMMENT = hljs.COMMENT(\n '/\\\\*', '\\\\*/',\n { contains: [ hljs.C_BLOCK_COMMENT_MODE ] }\n );\n var KOTLIN_PAREN_TYPE = {\n variants: [\n\t { className: 'type',\n\t begin: hljs.UNDERSCORE_IDENT_RE\n\t },\n\t { begin: /\\(/, end: /\\)/,\n\t contains: [] //defined later\n\t }\n\t]\n };\n var KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;\n KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];\n KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];\n\n return {\n name: 'Kotlin',\n aliases: ['kt'],\n keywords: KEYWORDS,\n contains : [\n hljs.COMMENT(\n '/\\\\*\\\\*',\n '\\\\*/',\n {\n relevance : 0,\n contains : [{\n className : 'doctag',\n begin : '@[A-Za-z]+'\n }]\n }\n ),\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n KEYWORDS_WITH_LABEL,\n LABEL,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n {\n className: 'function',\n beginKeywords: 'fun', end: '[(]|$',\n returnBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n illegal: /fun\\s+(<.*>)?[^\\s\\(]+(\\s+[^\\s\\(]+)\\s*=/,\n relevance: 5,\n contains: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE + '\\\\s*\\\\(', returnBegin: true,\n relevance: 0,\n contains: [hljs.UNDERSCORE_TITLE_MODE]\n },\n {\n className: 'type',\n begin: /</, end: />/, keywords: 'reified',\n relevance: 0\n },\n {\n className: 'params',\n begin: /\\(/, end: /\\)/,\n endsParent: true,\n keywords: KEYWORDS,\n relevance: 0,\n contains: [\n {\n begin: /:/, end: /[=,\\/]/, endsWithParent: true,\n contains: [\n KOTLIN_PAREN_TYPE,\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT\n ],\n relevance: 0\n },\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n STRING,\n hljs.C_NUMBER_MODE\n ]\n },\n KOTLIN_NESTED_COMMENT\n ]\n },\n {\n className: 'class',\n beginKeywords: 'class interface trait', end: /[:\\{(]|$/, // remove 'trait' when removed from KEYWORDS\n excludeEnd: true,\n illegal: 'extends implements',\n contains: [\n {beginKeywords: 'public protected internal private constructor'},\n hljs.UNDERSCORE_TITLE_MODE,\n {\n className: 'type',\n begin: /</, end: />/, excludeBegin: true, excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type',\n begin: /[,:]\\s*/, end: /[<\\(,]|$/, excludeBegin: true, returnEnd: true\n },\n ANNOTATION_USE_SITE,\n ANNOTATION\n ]\n },\n STRING,\n {\n className: 'meta',\n begin: \"^#!/usr/bin/env\", end: '$',\n illegal: '\\n'\n },\n KOTLIN_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "41cd2ef7ce2340374efbeddb8dba08e9", "score": "0.5223104", "text": "function kotlin(hljs) {\n var KEYWORDS = {\n keyword:\n 'abstract as val var vararg get set class object open private protected public noinline ' +\n 'crossinline dynamic final enum if else do while for when throw try catch finally ' +\n 'import package is in fun override companion reified inline lateinit init ' +\n 'interface annotation data sealed internal infix operator out by constructor super ' +\n 'tailrec where const inner suspend typealias external expect actual ' +\n // to be deleted soon\n 'trait volatile transient native default',\n built_in:\n 'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',\n literal:\n 'true false null'\n };\n var KEYWORDS_WITH_LABEL = {\n className: 'keyword',\n begin: /\\b(break|continue|return|this)\\b/,\n starts: {\n contains: [\n {\n className: 'symbol',\n begin: /@\\w+/\n }\n ]\n }\n };\n var LABEL = {\n className: 'symbol', begin: hljs.UNDERSCORE_IDENT_RE + '@'\n };\n\n // for string templates\n var SUBST = {\n className: 'subst',\n begin: '\\\\${', end: '}', contains: [hljs.C_NUMBER_MODE]\n };\n var VARIABLE = {\n className: 'variable', begin: '\\\\$' + hljs.UNDERSCORE_IDENT_RE\n };\n var STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"', end: '\"\"\"(?=[^\"])',\n contains: [VARIABLE, SUBST]\n },\n // Can't use built-in modes easily, as we want to use STRING in the meta\n // context as 'meta-string' and there's no syntax to remove explicitly set\n // classNames in built-in modes.\n {\n begin: '\\'', end: '\\'',\n illegal: /\\n/,\n contains: [hljs.BACKSLASH_ESCAPE]\n },\n {\n begin: '\"', end: '\"',\n illegal: /\\n/,\n contains: [hljs.BACKSLASH_ESCAPE, VARIABLE, SUBST]\n }\n ]\n };\n SUBST.contains.push(STRING);\n\n var ANNOTATION_USE_SITE = {\n className: 'meta', begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'\n };\n var ANNOTATION = {\n className: 'meta', begin: '@' + hljs.UNDERSCORE_IDENT_RE,\n contains: [\n {\n begin: /\\(/, end: /\\)/,\n contains: [\n hljs.inherit(STRING, {className: 'meta-string'})\n ]\n }\n ]\n };\n\n // https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n // According to the doc above, the number mode of kotlin is the same as java 8,\n // so the code below is copied from java.js\n var KOTLIN_NUMBER_RE = '\\\\b' +\n '(' +\n '0[bB]([01]+[01_]+[01]+|[01]+)' + // 0b...\n '|' +\n '0[xX]([a-fA-F0-9]+[a-fA-F0-9_]+[a-fA-F0-9]+|[a-fA-F0-9]+)' + // 0x...\n '|' +\n '(' +\n '([\\\\d]+[\\\\d_]+[\\\\d]+|[\\\\d]+)(\\\\.([\\\\d]+[\\\\d_]+[\\\\d]+|[\\\\d]+))?' +\n '|' +\n '\\\\.([\\\\d]+[\\\\d_]+[\\\\d]+|[\\\\d]+)' +\n ')' +\n '([eE][-+]?\\\\d+)?' + // octal, decimal, float\n ')' +\n '[lLfF]?';\n var KOTLIN_NUMBER_MODE = {\n className: 'number',\n begin: KOTLIN_NUMBER_RE,\n relevance: 0\n };\n var KOTLIN_NESTED_COMMENT = hljs.COMMENT(\n '/\\\\*', '\\\\*/',\n { contains: [ hljs.C_BLOCK_COMMENT_MODE ] }\n );\n var KOTLIN_PAREN_TYPE = {\n variants: [\n\t { className: 'type',\n\t begin: hljs.UNDERSCORE_IDENT_RE\n\t },\n\t { begin: /\\(/, end: /\\)/,\n\t contains: [] //defined later\n\t }\n\t]\n };\n var KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;\n KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];\n KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];\n\n return {\n name: 'Kotlin',\n aliases: ['kt'],\n keywords: KEYWORDS,\n contains : [\n hljs.COMMENT(\n '/\\\\*\\\\*',\n '\\\\*/',\n {\n relevance : 0,\n contains : [{\n className : 'doctag',\n begin : '@[A-Za-z]+'\n }]\n }\n ),\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n KEYWORDS_WITH_LABEL,\n LABEL,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n {\n className: 'function',\n beginKeywords: 'fun', end: '[(]|$',\n returnBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n illegal: /fun\\s+(<.*>)?[^\\s\\(]+(\\s+[^\\s\\(]+)\\s*=/,\n relevance: 5,\n contains: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE + '\\\\s*\\\\(', returnBegin: true,\n relevance: 0,\n contains: [hljs.UNDERSCORE_TITLE_MODE]\n },\n {\n className: 'type',\n begin: /</, end: />/, keywords: 'reified',\n relevance: 0\n },\n {\n className: 'params',\n begin: /\\(/, end: /\\)/,\n endsParent: true,\n keywords: KEYWORDS,\n relevance: 0,\n contains: [\n {\n begin: /:/, end: /[=,\\/]/, endsWithParent: true,\n contains: [\n KOTLIN_PAREN_TYPE,\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT\n ],\n relevance: 0\n },\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n STRING,\n hljs.C_NUMBER_MODE\n ]\n },\n KOTLIN_NESTED_COMMENT\n ]\n },\n {\n className: 'class',\n beginKeywords: 'class interface trait', end: /[:\\{(]|$/, // remove 'trait' when removed from KEYWORDS\n excludeEnd: true,\n illegal: 'extends implements',\n contains: [\n {beginKeywords: 'public protected internal private constructor'},\n hljs.UNDERSCORE_TITLE_MODE,\n {\n className: 'type',\n begin: /</, end: />/, excludeBegin: true, excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type',\n begin: /[,:]\\s*/, end: /[<\\(,]|$/, excludeBegin: true, returnEnd: true\n },\n ANNOTATION_USE_SITE,\n ANNOTATION\n ]\n },\n STRING,\n {\n className: 'meta',\n begin: \"^#!/usr/bin/env\", end: '$',\n illegal: '\\n'\n },\n KOTLIN_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "532be7dfe9f2ef4ce1f1a834c0e537d3", "score": "0.52097374", "text": "function lua(hljs){var OPENING_LONG_BRACKET='\\\\[=*\\\\[';var CLOSING_LONG_BRACKET='\\\\]=*\\\\]';var LONG_BRACKETS={begin:OPENING_LONG_BRACKET,end:CLOSING_LONG_BRACKET,contains:['self']};var COMMENTS=[hljs.COMMENT('--(?!'+OPENING_LONG_BRACKET+')','$'),hljs.COMMENT('--'+OPENING_LONG_BRACKET,CLOSING_LONG_BRACKET,{contains:[LONG_BRACKETS],relevance:10})];return{name:'Lua',keywords:{$pattern:hljs.UNDERSCORE_IDENT_RE,literal:\"true false nil\",keyword:\"and break do else elseif end for goto if in local not or repeat return then until while\",built_in:// Metatags and globals:\n'_G _ENV _VERSION __index __newindex __mode __call __metatable __tostring __len '+'__gc __add __sub __mul __div __mod __pow __concat __unm __eq __lt __le assert '+// Standard methods and properties:\n'collectgarbage dofile error getfenv getmetatable ipairs load loadfile loadstring '+'module next pairs pcall print rawequal rawget rawset require select setfenv '+'setmetatable tonumber tostring type unpack xpcall arg self '+// Library methods and properties (one line per library):\n'coroutine resume yield status wrap create running debug getupvalue '+'debug sethook getmetatable gethook setmetatable setlocal traceback setfenv getinfo setupvalue getlocal getregistry getfenv '+'io lines write close flush open output type read stderr stdin input stdout popen tmpfile '+'math log max acos huge ldexp pi cos tanh pow deg tan cosh sinh random randomseed frexp ceil floor rad abs sqrt modf asin min mod fmod log10 atan2 exp sin atan '+'os exit setlocale date getenv difftime remove time clock tmpname rename execute package preload loadlib loaded loaders cpath config path seeall '+'string sub upper len gfind rep find match char dump gmatch reverse byte format gsub lower '+'table setn insert getn foreachi maxn foreach concat sort remove'},contains:COMMENTS.concat([{className:'function',beginKeywords:'function',end:'\\\\)',contains:[hljs.inherit(hljs.TITLE_MODE,{begin:'([_a-zA-Z]\\\\w*\\\\.)*([_a-zA-Z]\\\\w*:)?[_a-zA-Z]\\\\w*'}),{className:'params',begin:'\\\\(',endsWithParent:true,contains:COMMENTS}].concat(COMMENTS)},hljs.C_NUMBER_MODE,hljs.APOS_STRING_MODE,hljs.QUOTE_STRING_MODE,{className:'string',begin:OPENING_LONG_BRACKET,end:CLOSING_LONG_BRACKET,contains:[LONG_BRACKETS],relevance:5}])};}", "title": "" }, { "docid": "2c6283ad491d46dbeb4803f22aedb669", "score": "0.5189687", "text": "function topLevelCode() {\n\n return {\n interpret: function () {\n switch (tokens[0]) {\n case \"HAI\":\n version = tokens[++t];\n console.log(\"Program started! version: \" + version + '\\n');\n return false;\n\n case \"KTHXBYE\":\n process.exit();\n break;\n\n case \"VISIBLE\":\n\n while (tokens[t + 1] != '!') {\n //if(t <= (tokens.length )) break;\n\n var msg = evalExpr();\n\n process.stdout.write(msg.toYarn().val);\n if (t >= (tokens.length - 1)) break;\n\n }\n\n if (tokens[t + 1] != '!') process.stdout.write('\\n');\n t++;\n return false;\n case \"GIMMEH\":\n t++;\n var idf = identify(tokens.slice(1));\n\n\n vars.setSlot(idf, new Yarn(prompt()))\n t = global.idfIdx;\n return false;\n case \"CAN HAS\":\n t = 1;\n var name = tokens[1];\n try {\n vars.val[name] = require(\"../ext/\" + name)\n }\n catch (e) {console.log(e);throw new Maus(\"NO HAS \" + name, 501)}\n t=2;\n return false;\n case \"HOW IZ\":\n t++;\n var func = new FunctionDeclaraition()\n\n if (tokens[1] == \"I\" && !defContext.length) {\n func.global = true;\n t++;\n }\n else {\n func.idf = identify(tokens.slice(1));\n t = global.idfIdx + 1;\n\n }\n var name = tokens[t];\n\n validate(name, true);\n func.name = name;\n\n t++;\n\n while (t < tokens.length - 1) {\n if (func.args.length) expect(\"AN\");\n expect(\"YR\");\n var arg = tokens[t];\n validate(arg);\n if (func.args.includes(arg)) throw new Maus(\"GOT ALREADY \" + arg, 209);\n func.args.push(arg);\n t++;\n }\n func.length = func.args.length;\n layers.unshift(func);\n\n return false;\n case \"FOUND YR\":\n if (stack.length) {\n returnVal = evalExpr();\n return false;\n }\n throw new Maus(\"FOUND YR, WTF?\", 202);\n\n case \"GTFO\":\n if (this.isLoop) {\n loopBreak = true;\n return false;\n }\n\n if (stack.length) {\n returnVal = new Noob();\n return false;\n }\n throw new Maus(\"GTFO, WTF?\", 202);\n\n case \"O RLY?\":\n\n layers.unshift(new IfLayer(vars.val.IT.toTroof().val));\n return false;\n\n case \"WTF?\":\n layers.unshift(new SwitchLayer(vars.val.IT));\n return false;\n\n case \"IM IN YR\":\n var label = tokens[1];\n if (!label) throw new Maus(\"IM IN YR WHAT\", 213);\n t = 1;\n layers.unshift(new LoopLayer(label));\n\n if (tokens.length < 3) return false;\n\n t = 3;\n layers[0].count = true;\n if (tokens[2] === \"UPPIN\") layers[0].by = 1;\n else if (tokens[2] === \"NERFIN\") layers[0].b = -1;\n else throw new Maus(\"SHALL I UPPIN OR NERFIN?\", 214);\n expect(\"YR\");\n t = 4;\n var counter = tokens[4];\n validate(counter);\n layers[0].counter = counter;\n\n if (tokens.length < 6) return false;\n\n t = 5\n layers[0].conditional = true;\n if (tokens[5] === \"TIL\") layers[0].condition = true;\n else if (tokens[5] === \"WILE\") layers[0].condition = false;\n else throw new Maus(\"TIL OR WILE?\", 215);\n layers[0].expression = tokens.slice(6);\n t = tokens.length;\n\n if (global.extErr) {\n layers[0].metahead.textline = global.textline;\n layers[0].metahead.tokensPos = global.tokensPos.slice(6);\n }\n return false;\n\n case \"O HAI IM\":\n\n t = 1;\n var name = tokens[1];\n validate(name);\n global.defContext.unshift(name)\n vars.val[name] = new Bukkit();\n layers.unshift(new BukkitLayer());\n return false;\n\n\n\n }\n\n var idf = identify(tokens);\n\n if (global.idfIdx < tokens.length) {\n //t=global.idfIdx;\n switch (tokens[global.idfIdx]) {\n\n case \"HAS A\":\n\n t = global.idfIdx;\n var name = identify(tokens.slice(++t))[0];\n\n t = global.idfIdx + 1;\n validate(name);\n\n\n\n if (tokens[t + 1] == \"ITZ\") {\n t++;\n var val = evalExpr();\n }\n else if (tokens[t + 1] == \"ITZ A\") {\n t += 2;\n var val = cast(new Noob(), tokens[t]);\n t++;\n\n }\n else if (tokens[t + 1] == \"ITZ LIEK A\") {\n t++;\n var v = evalExpr();\n if (!(v instanceof Bukkit)) throw new Maus(\"IZ LIEK BUKKIT\", 216)\n var val = v;\n }\n else { var val = new Noob(); }\n\n\n idf.push(name);\n global.vars.setSlot(idf, val, true);\n return false;\n\n case \"R\":\n t = global.idfIdx;\n //var name = identify(tokens.slice(++t));\n\n global.vars.setSlot(idf, evalExpr());\n return false;\n\n case \"IS NOW A\":\n t = global.idfIdx;\n\n var to = cast(global.vars.getSlot(idf), tokens[++t]);\n //var name = identify(tokens.slice(++t));\n\n t = 2;\n global.vars.setSlot(idf, to);\n return false;\n\n }\n\n }\n\n\n t = -1;\n global.vars.val.IT = evalExpr();\n\n\n },\n isFunction: false\n }\n}", "title": "" }, { "docid": "6ad3032a5ee361407cce784b580ee401", "score": "0.51782334", "text": "function julia(hljs) {\n // Since there are numerous special names in Julia, it is too much trouble\n // to maintain them by hand. Hence these names (i.e. keywords, literals and\n // built-ins) are automatically generated from Julia 1.5.2 itself through\n // the following scripts for each.\n\n // ref: https://docs.julialang.org/en/v1/manual/variables/#Allowed-Variable-Names\n var VARIABLE_NAME_RE = '[A-Za-z_\\\\u00A1-\\\\uFFFF][A-Za-z_0-9\\\\u00A1-\\\\uFFFF]*';\n\n // # keyword generator, multi-word keywords handled manually below (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"in\", \"isa\", \"where\"]\n // for kw in collect(x.keyword for x in REPLCompletions.complete_keyword(\"\"))\n // if !(contains(kw, \" \") || kw == \"struct\")\n // push!(res, kw)\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var KEYWORD_LIST = [\n 'baremodule',\n 'begin',\n 'break',\n 'catch',\n 'ccall',\n 'const',\n 'continue',\n 'do',\n 'else',\n 'elseif',\n 'end',\n 'export',\n 'false',\n 'finally',\n 'for',\n 'function',\n 'global',\n 'if',\n 'import',\n 'in',\n 'isa',\n 'let',\n 'local',\n 'macro',\n 'module',\n 'quote',\n 'return',\n 'true',\n 'try',\n 'using',\n 'where',\n 'while',\n ];\n\n // # literal generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"true\", \"false\"]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var LITERAL_LIST = [\n 'ARGS',\n 'C_NULL',\n 'DEPOT_PATH',\n 'ENDIAN_BOM',\n 'ENV',\n 'Inf',\n 'Inf16',\n 'Inf32',\n 'Inf64',\n 'InsertionSort',\n 'LOAD_PATH',\n 'MergeSort',\n 'NaN',\n 'NaN16',\n 'NaN32',\n 'NaN64',\n 'PROGRAM_FILE',\n 'QuickSort',\n 'RoundDown',\n 'RoundFromZero',\n 'RoundNearest',\n 'RoundNearestTiesAway',\n 'RoundNearestTiesUp',\n 'RoundToZero',\n 'RoundUp',\n 'VERSION|0',\n 'devnull',\n 'false',\n 'im',\n 'missing',\n 'nothing',\n 'pi',\n 'stderr',\n 'stdin',\n 'stdout',\n 'true',\n 'undef',\n 'π',\n 'ℯ',\n ];\n\n // # built_in generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if (v isa Type || v isa TypeVar) && (compl.mod != \"=>\")\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var BUILT_IN_LIST = [\n 'AbstractArray',\n 'AbstractChannel',\n 'AbstractChar',\n 'AbstractDict',\n 'AbstractDisplay',\n 'AbstractFloat',\n 'AbstractIrrational',\n 'AbstractMatrix',\n 'AbstractRange',\n 'AbstractSet',\n 'AbstractString',\n 'AbstractUnitRange',\n 'AbstractVecOrMat',\n 'AbstractVector',\n 'Any',\n 'ArgumentError',\n 'Array',\n 'AssertionError',\n 'BigFloat',\n 'BigInt',\n 'BitArray',\n 'BitMatrix',\n 'BitSet',\n 'BitVector',\n 'Bool',\n 'BoundsError',\n 'CapturedException',\n 'CartesianIndex',\n 'CartesianIndices',\n 'Cchar',\n 'Cdouble',\n 'Cfloat',\n 'Channel',\n 'Char',\n 'Cint',\n 'Cintmax_t',\n 'Clong',\n 'Clonglong',\n 'Cmd',\n 'Colon',\n 'Complex',\n 'ComplexF16',\n 'ComplexF32',\n 'ComplexF64',\n 'CompositeException',\n 'Condition',\n 'Cptrdiff_t',\n 'Cshort',\n 'Csize_t',\n 'Cssize_t',\n 'Cstring',\n 'Cuchar',\n 'Cuint',\n 'Cuintmax_t',\n 'Culong',\n 'Culonglong',\n 'Cushort',\n 'Cvoid',\n 'Cwchar_t',\n 'Cwstring',\n 'DataType',\n 'DenseArray',\n 'DenseMatrix',\n 'DenseVecOrMat',\n 'DenseVector',\n 'Dict',\n 'DimensionMismatch',\n 'Dims',\n 'DivideError',\n 'DomainError',\n 'EOFError',\n 'Enum',\n 'ErrorException',\n 'Exception',\n 'ExponentialBackOff',\n 'Expr',\n 'Float16',\n 'Float32',\n 'Float64',\n 'Function',\n 'GlobalRef',\n 'HTML',\n 'IO',\n 'IOBuffer',\n 'IOContext',\n 'IOStream',\n 'IdDict',\n 'IndexCartesian',\n 'IndexLinear',\n 'IndexStyle',\n 'InexactError',\n 'InitError',\n 'Int',\n 'Int128',\n 'Int16',\n 'Int32',\n 'Int64',\n 'Int8',\n 'Integer',\n 'InterruptException',\n 'InvalidStateException',\n 'Irrational',\n 'KeyError',\n 'LinRange',\n 'LineNumberNode',\n 'LinearIndices',\n 'LoadError',\n 'MIME',\n 'Matrix',\n 'Method',\n 'MethodError',\n 'Missing',\n 'MissingException',\n 'Module',\n 'NTuple',\n 'NamedTuple',\n 'Nothing',\n 'Number',\n 'OrdinalRange',\n 'OutOfMemoryError',\n 'OverflowError',\n 'Pair',\n 'PartialQuickSort',\n 'PermutedDimsArray',\n 'Pipe',\n 'ProcessFailedException',\n 'Ptr',\n 'QuoteNode',\n 'Rational',\n 'RawFD',\n 'ReadOnlyMemoryError',\n 'Real',\n 'ReentrantLock',\n 'Ref',\n 'Regex',\n 'RegexMatch',\n 'RoundingMode',\n 'SegmentationFault',\n 'Set',\n 'Signed',\n 'Some',\n 'StackOverflowError',\n 'StepRange',\n 'StepRangeLen',\n 'StridedArray',\n 'StridedMatrix',\n 'StridedVecOrMat',\n 'StridedVector',\n 'String',\n 'StringIndexError',\n 'SubArray',\n 'SubString',\n 'SubstitutionString',\n 'Symbol',\n 'SystemError',\n 'Task',\n 'TaskFailedException',\n 'Text',\n 'TextDisplay',\n 'Timer',\n 'Tuple',\n 'Type',\n 'TypeError',\n 'TypeVar',\n 'UInt',\n 'UInt128',\n 'UInt16',\n 'UInt32',\n 'UInt64',\n 'UInt8',\n 'UndefInitializer',\n 'UndefKeywordError',\n 'UndefRefError',\n 'UndefVarError',\n 'Union',\n 'UnionAll',\n 'UnitRange',\n 'Unsigned',\n 'Val',\n 'Vararg',\n 'VecElement',\n 'VecOrMat',\n 'Vector',\n 'VersionNumber',\n 'WeakKeyDict',\n 'WeakRef',\n ];\n\n var KEYWORDS = {\n $pattern: VARIABLE_NAME_RE,\n keyword: KEYWORD_LIST.join(\" \"),\n literal: LITERAL_LIST.join(\" \"),\n built_in: BUILT_IN_LIST.join(\" \"),\n };\n\n // placeholder for recursive self-reference\n var DEFAULT = {\n keywords: KEYWORDS, illegal: /<\\//\n };\n\n // ref: https://docs.julialang.org/en/v1/manual/integers-and-floating-point-numbers/\n var NUMBER = {\n className: 'number',\n // supported numeric literals:\n // * binary literal (e.g. 0x10)\n // * octal literal (e.g. 0o76543210)\n // * hexadecimal literal (e.g. 0xfedcba876543210)\n // * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)\n // * decimal literal (e.g. 9876543210, 100_000_000)\n // * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)\n begin: /(\\b0x[\\d_]*(\\.[\\d_]*)?|0x\\.\\d[\\d_]*)p[-+]?\\d+|\\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\\b\\d[\\d_]*(\\.[\\d_]*)?|\\.\\d[\\d_]*)([eEfF][-+]?\\d+)?/,\n relevance: 0\n };\n\n var CHAR = {\n className: 'string',\n begin: /'(.|\\\\[xXuU][a-zA-Z0-9]+)'/\n };\n\n var INTERPOLATION = {\n className: 'subst',\n begin: /\\$\\(/, end: /\\)/,\n keywords: KEYWORDS\n };\n\n var INTERPOLATED_VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + VARIABLE_NAME_RE\n };\n\n // TODO: neatly escape normal code in string literal\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n variants: [\n { begin: /\\w*\"\"\"/, end: /\"\"\"\\w*/, relevance: 10 },\n { begin: /\\w*\"/, end: /\"\\w*/ }\n ]\n };\n\n var COMMAND = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n begin: '`', end: '`'\n };\n\n var MACROCALL = {\n className: 'meta',\n begin: '@' + VARIABLE_NAME_RE\n };\n\n var COMMENT = {\n className: 'comment',\n variants: [\n { begin: '#=', end: '=#', relevance: 10 },\n { begin: '#', end: '$' }\n ]\n };\n\n DEFAULT.name = 'Julia';\n DEFAULT.contains = [\n NUMBER,\n CHAR,\n STRING,\n COMMAND,\n MACROCALL,\n COMMENT,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'keyword',\n begin:\n '\\\\b(((abstract|primitive)\\\\s+)type|(mutable\\\\s+)?struct)\\\\b'\n },\n {begin: /<:/} // relevance booster\n ];\n INTERPOLATION.contains = DEFAULT.contains;\n\n return DEFAULT;\n}", "title": "" }, { "docid": "ff4ef44c005e6edd08e05881276363f5", "score": "0.51782334", "text": "function julia(hljs) {\n // Since there are numerous special names in Julia, it is too much trouble\n // to maintain them by hand. Hence these names (i.e. keywords, literals and\n // built-ins) are automatically generated from Julia 1.5.2 itself through\n // the following scripts for each.\n\n // ref: https://docs.julialang.org/en/v1/manual/variables/#Allowed-Variable-Names\n var VARIABLE_NAME_RE = '[A-Za-z_\\\\u00A1-\\\\uFFFF][A-Za-z_0-9\\\\u00A1-\\\\uFFFF]*';\n\n // # keyword generator, multi-word keywords handled manually below (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"in\", \"isa\", \"where\"]\n // for kw in collect(x.keyword for x in REPLCompletions.complete_keyword(\"\"))\n // if !(contains(kw, \" \") || kw == \"struct\")\n // push!(res, kw)\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var KEYWORD_LIST = [\n 'baremodule',\n 'begin',\n 'break',\n 'catch',\n 'ccall',\n 'const',\n 'continue',\n 'do',\n 'else',\n 'elseif',\n 'end',\n 'export',\n 'false',\n 'finally',\n 'for',\n 'function',\n 'global',\n 'if',\n 'import',\n 'in',\n 'isa',\n 'let',\n 'local',\n 'macro',\n 'module',\n 'quote',\n 'return',\n 'true',\n 'try',\n 'using',\n 'where',\n 'while',\n ];\n\n // # literal generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"true\", \"false\"]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var LITERAL_LIST = [\n 'ARGS',\n 'C_NULL',\n 'DEPOT_PATH',\n 'ENDIAN_BOM',\n 'ENV',\n 'Inf',\n 'Inf16',\n 'Inf32',\n 'Inf64',\n 'InsertionSort',\n 'LOAD_PATH',\n 'MergeSort',\n 'NaN',\n 'NaN16',\n 'NaN32',\n 'NaN64',\n 'PROGRAM_FILE',\n 'QuickSort',\n 'RoundDown',\n 'RoundFromZero',\n 'RoundNearest',\n 'RoundNearestTiesAway',\n 'RoundNearestTiesUp',\n 'RoundToZero',\n 'RoundUp',\n 'VERSION|0',\n 'devnull',\n 'false',\n 'im',\n 'missing',\n 'nothing',\n 'pi',\n 'stderr',\n 'stdin',\n 'stdout',\n 'true',\n 'undef',\n 'π',\n 'ℯ',\n ];\n\n // # built_in generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if (v isa Type || v isa TypeVar) && (compl.mod != \"=>\")\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var BUILT_IN_LIST = [\n 'AbstractArray',\n 'AbstractChannel',\n 'AbstractChar',\n 'AbstractDict',\n 'AbstractDisplay',\n 'AbstractFloat',\n 'AbstractIrrational',\n 'AbstractMatrix',\n 'AbstractRange',\n 'AbstractSet',\n 'AbstractString',\n 'AbstractUnitRange',\n 'AbstractVecOrMat',\n 'AbstractVector',\n 'Any',\n 'ArgumentError',\n 'Array',\n 'AssertionError',\n 'BigFloat',\n 'BigInt',\n 'BitArray',\n 'BitMatrix',\n 'BitSet',\n 'BitVector',\n 'Bool',\n 'BoundsError',\n 'CapturedException',\n 'CartesianIndex',\n 'CartesianIndices',\n 'Cchar',\n 'Cdouble',\n 'Cfloat',\n 'Channel',\n 'Char',\n 'Cint',\n 'Cintmax_t',\n 'Clong',\n 'Clonglong',\n 'Cmd',\n 'Colon',\n 'Complex',\n 'ComplexF16',\n 'ComplexF32',\n 'ComplexF64',\n 'CompositeException',\n 'Condition',\n 'Cptrdiff_t',\n 'Cshort',\n 'Csize_t',\n 'Cssize_t',\n 'Cstring',\n 'Cuchar',\n 'Cuint',\n 'Cuintmax_t',\n 'Culong',\n 'Culonglong',\n 'Cushort',\n 'Cvoid',\n 'Cwchar_t',\n 'Cwstring',\n 'DataType',\n 'DenseArray',\n 'DenseMatrix',\n 'DenseVecOrMat',\n 'DenseVector',\n 'Dict',\n 'DimensionMismatch',\n 'Dims',\n 'DivideError',\n 'DomainError',\n 'EOFError',\n 'Enum',\n 'ErrorException',\n 'Exception',\n 'ExponentialBackOff',\n 'Expr',\n 'Float16',\n 'Float32',\n 'Float64',\n 'Function',\n 'GlobalRef',\n 'HTML',\n 'IO',\n 'IOBuffer',\n 'IOContext',\n 'IOStream',\n 'IdDict',\n 'IndexCartesian',\n 'IndexLinear',\n 'IndexStyle',\n 'InexactError',\n 'InitError',\n 'Int',\n 'Int128',\n 'Int16',\n 'Int32',\n 'Int64',\n 'Int8',\n 'Integer',\n 'InterruptException',\n 'InvalidStateException',\n 'Irrational',\n 'KeyError',\n 'LinRange',\n 'LineNumberNode',\n 'LinearIndices',\n 'LoadError',\n 'MIME',\n 'Matrix',\n 'Method',\n 'MethodError',\n 'Missing',\n 'MissingException',\n 'Module',\n 'NTuple',\n 'NamedTuple',\n 'Nothing',\n 'Number',\n 'OrdinalRange',\n 'OutOfMemoryError',\n 'OverflowError',\n 'Pair',\n 'PartialQuickSort',\n 'PermutedDimsArray',\n 'Pipe',\n 'ProcessFailedException',\n 'Ptr',\n 'QuoteNode',\n 'Rational',\n 'RawFD',\n 'ReadOnlyMemoryError',\n 'Real',\n 'ReentrantLock',\n 'Ref',\n 'Regex',\n 'RegexMatch',\n 'RoundingMode',\n 'SegmentationFault',\n 'Set',\n 'Signed',\n 'Some',\n 'StackOverflowError',\n 'StepRange',\n 'StepRangeLen',\n 'StridedArray',\n 'StridedMatrix',\n 'StridedVecOrMat',\n 'StridedVector',\n 'String',\n 'StringIndexError',\n 'SubArray',\n 'SubString',\n 'SubstitutionString',\n 'Symbol',\n 'SystemError',\n 'Task',\n 'TaskFailedException',\n 'Text',\n 'TextDisplay',\n 'Timer',\n 'Tuple',\n 'Type',\n 'TypeError',\n 'TypeVar',\n 'UInt',\n 'UInt128',\n 'UInt16',\n 'UInt32',\n 'UInt64',\n 'UInt8',\n 'UndefInitializer',\n 'UndefKeywordError',\n 'UndefRefError',\n 'UndefVarError',\n 'Union',\n 'UnionAll',\n 'UnitRange',\n 'Unsigned',\n 'Val',\n 'Vararg',\n 'VecElement',\n 'VecOrMat',\n 'Vector',\n 'VersionNumber',\n 'WeakKeyDict',\n 'WeakRef',\n ];\n\n var KEYWORDS = {\n $pattern: VARIABLE_NAME_RE,\n keyword: KEYWORD_LIST,\n literal: LITERAL_LIST,\n built_in: BUILT_IN_LIST,\n };\n\n // placeholder for recursive self-reference\n var DEFAULT = {\n keywords: KEYWORDS, illegal: /<\\//\n };\n\n // ref: https://docs.julialang.org/en/v1/manual/integers-and-floating-point-numbers/\n var NUMBER = {\n className: 'number',\n // supported numeric literals:\n // * binary literal (e.g. 0x10)\n // * octal literal (e.g. 0o76543210)\n // * hexadecimal literal (e.g. 0xfedcba876543210)\n // * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)\n // * decimal literal (e.g. 9876543210, 100_000_000)\n // * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)\n begin: /(\\b0x[\\d_]*(\\.[\\d_]*)?|0x\\.\\d[\\d_]*)p[-+]?\\d+|\\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\\b\\d[\\d_]*(\\.[\\d_]*)?|\\.\\d[\\d_]*)([eEfF][-+]?\\d+)?/,\n relevance: 0\n };\n\n var CHAR = {\n className: 'string',\n begin: /'(.|\\\\[xXuU][a-zA-Z0-9]+)'/\n };\n\n var INTERPOLATION = {\n className: 'subst',\n begin: /\\$\\(/, end: /\\)/,\n keywords: KEYWORDS\n };\n\n var INTERPOLATED_VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + VARIABLE_NAME_RE\n };\n\n // TODO: neatly escape normal code in string literal\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n variants: [\n { begin: /\\w*\"\"\"/, end: /\"\"\"\\w*/, relevance: 10 },\n { begin: /\\w*\"/, end: /\"\\w*/ }\n ]\n };\n\n var COMMAND = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n begin: '`', end: '`'\n };\n\n var MACROCALL = {\n className: 'meta',\n begin: '@' + VARIABLE_NAME_RE\n };\n\n var COMMENT = {\n className: 'comment',\n variants: [\n { begin: '#=', end: '=#', relevance: 10 },\n { begin: '#', end: '$' }\n ]\n };\n\n DEFAULT.name = 'Julia';\n DEFAULT.contains = [\n NUMBER,\n CHAR,\n STRING,\n COMMAND,\n MACROCALL,\n COMMENT,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'keyword',\n begin:\n '\\\\b(((abstract|primitive)\\\\s+)type|(mutable\\\\s+)?struct)\\\\b'\n },\n {begin: /<:/} // relevance booster\n ];\n INTERPOLATION.contains = DEFAULT.contains;\n\n return DEFAULT;\n}", "title": "" }, { "docid": "ff4ef44c005e6edd08e05881276363f5", "score": "0.51782334", "text": "function julia(hljs) {\n // Since there are numerous special names in Julia, it is too much trouble\n // to maintain them by hand. Hence these names (i.e. keywords, literals and\n // built-ins) are automatically generated from Julia 1.5.2 itself through\n // the following scripts for each.\n\n // ref: https://docs.julialang.org/en/v1/manual/variables/#Allowed-Variable-Names\n var VARIABLE_NAME_RE = '[A-Za-z_\\\\u00A1-\\\\uFFFF][A-Za-z_0-9\\\\u00A1-\\\\uFFFF]*';\n\n // # keyword generator, multi-word keywords handled manually below (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"in\", \"isa\", \"where\"]\n // for kw in collect(x.keyword for x in REPLCompletions.complete_keyword(\"\"))\n // if !(contains(kw, \" \") || kw == \"struct\")\n // push!(res, kw)\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var KEYWORD_LIST = [\n 'baremodule',\n 'begin',\n 'break',\n 'catch',\n 'ccall',\n 'const',\n 'continue',\n 'do',\n 'else',\n 'elseif',\n 'end',\n 'export',\n 'false',\n 'finally',\n 'for',\n 'function',\n 'global',\n 'if',\n 'import',\n 'in',\n 'isa',\n 'let',\n 'local',\n 'macro',\n 'module',\n 'quote',\n 'return',\n 'true',\n 'try',\n 'using',\n 'where',\n 'while',\n ];\n\n // # literal generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"true\", \"false\"]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var LITERAL_LIST = [\n 'ARGS',\n 'C_NULL',\n 'DEPOT_PATH',\n 'ENDIAN_BOM',\n 'ENV',\n 'Inf',\n 'Inf16',\n 'Inf32',\n 'Inf64',\n 'InsertionSort',\n 'LOAD_PATH',\n 'MergeSort',\n 'NaN',\n 'NaN16',\n 'NaN32',\n 'NaN64',\n 'PROGRAM_FILE',\n 'QuickSort',\n 'RoundDown',\n 'RoundFromZero',\n 'RoundNearest',\n 'RoundNearestTiesAway',\n 'RoundNearestTiesUp',\n 'RoundToZero',\n 'RoundUp',\n 'VERSION|0',\n 'devnull',\n 'false',\n 'im',\n 'missing',\n 'nothing',\n 'pi',\n 'stderr',\n 'stdin',\n 'stdout',\n 'true',\n 'undef',\n 'π',\n 'ℯ',\n ];\n\n // # built_in generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if (v isa Type || v isa TypeVar) && (compl.mod != \"=>\")\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var BUILT_IN_LIST = [\n 'AbstractArray',\n 'AbstractChannel',\n 'AbstractChar',\n 'AbstractDict',\n 'AbstractDisplay',\n 'AbstractFloat',\n 'AbstractIrrational',\n 'AbstractMatrix',\n 'AbstractRange',\n 'AbstractSet',\n 'AbstractString',\n 'AbstractUnitRange',\n 'AbstractVecOrMat',\n 'AbstractVector',\n 'Any',\n 'ArgumentError',\n 'Array',\n 'AssertionError',\n 'BigFloat',\n 'BigInt',\n 'BitArray',\n 'BitMatrix',\n 'BitSet',\n 'BitVector',\n 'Bool',\n 'BoundsError',\n 'CapturedException',\n 'CartesianIndex',\n 'CartesianIndices',\n 'Cchar',\n 'Cdouble',\n 'Cfloat',\n 'Channel',\n 'Char',\n 'Cint',\n 'Cintmax_t',\n 'Clong',\n 'Clonglong',\n 'Cmd',\n 'Colon',\n 'Complex',\n 'ComplexF16',\n 'ComplexF32',\n 'ComplexF64',\n 'CompositeException',\n 'Condition',\n 'Cptrdiff_t',\n 'Cshort',\n 'Csize_t',\n 'Cssize_t',\n 'Cstring',\n 'Cuchar',\n 'Cuint',\n 'Cuintmax_t',\n 'Culong',\n 'Culonglong',\n 'Cushort',\n 'Cvoid',\n 'Cwchar_t',\n 'Cwstring',\n 'DataType',\n 'DenseArray',\n 'DenseMatrix',\n 'DenseVecOrMat',\n 'DenseVector',\n 'Dict',\n 'DimensionMismatch',\n 'Dims',\n 'DivideError',\n 'DomainError',\n 'EOFError',\n 'Enum',\n 'ErrorException',\n 'Exception',\n 'ExponentialBackOff',\n 'Expr',\n 'Float16',\n 'Float32',\n 'Float64',\n 'Function',\n 'GlobalRef',\n 'HTML',\n 'IO',\n 'IOBuffer',\n 'IOContext',\n 'IOStream',\n 'IdDict',\n 'IndexCartesian',\n 'IndexLinear',\n 'IndexStyle',\n 'InexactError',\n 'InitError',\n 'Int',\n 'Int128',\n 'Int16',\n 'Int32',\n 'Int64',\n 'Int8',\n 'Integer',\n 'InterruptException',\n 'InvalidStateException',\n 'Irrational',\n 'KeyError',\n 'LinRange',\n 'LineNumberNode',\n 'LinearIndices',\n 'LoadError',\n 'MIME',\n 'Matrix',\n 'Method',\n 'MethodError',\n 'Missing',\n 'MissingException',\n 'Module',\n 'NTuple',\n 'NamedTuple',\n 'Nothing',\n 'Number',\n 'OrdinalRange',\n 'OutOfMemoryError',\n 'OverflowError',\n 'Pair',\n 'PartialQuickSort',\n 'PermutedDimsArray',\n 'Pipe',\n 'ProcessFailedException',\n 'Ptr',\n 'QuoteNode',\n 'Rational',\n 'RawFD',\n 'ReadOnlyMemoryError',\n 'Real',\n 'ReentrantLock',\n 'Ref',\n 'Regex',\n 'RegexMatch',\n 'RoundingMode',\n 'SegmentationFault',\n 'Set',\n 'Signed',\n 'Some',\n 'StackOverflowError',\n 'StepRange',\n 'StepRangeLen',\n 'StridedArray',\n 'StridedMatrix',\n 'StridedVecOrMat',\n 'StridedVector',\n 'String',\n 'StringIndexError',\n 'SubArray',\n 'SubString',\n 'SubstitutionString',\n 'Symbol',\n 'SystemError',\n 'Task',\n 'TaskFailedException',\n 'Text',\n 'TextDisplay',\n 'Timer',\n 'Tuple',\n 'Type',\n 'TypeError',\n 'TypeVar',\n 'UInt',\n 'UInt128',\n 'UInt16',\n 'UInt32',\n 'UInt64',\n 'UInt8',\n 'UndefInitializer',\n 'UndefKeywordError',\n 'UndefRefError',\n 'UndefVarError',\n 'Union',\n 'UnionAll',\n 'UnitRange',\n 'Unsigned',\n 'Val',\n 'Vararg',\n 'VecElement',\n 'VecOrMat',\n 'Vector',\n 'VersionNumber',\n 'WeakKeyDict',\n 'WeakRef',\n ];\n\n var KEYWORDS = {\n $pattern: VARIABLE_NAME_RE,\n keyword: KEYWORD_LIST,\n literal: LITERAL_LIST,\n built_in: BUILT_IN_LIST,\n };\n\n // placeholder for recursive self-reference\n var DEFAULT = {\n keywords: KEYWORDS, illegal: /<\\//\n };\n\n // ref: https://docs.julialang.org/en/v1/manual/integers-and-floating-point-numbers/\n var NUMBER = {\n className: 'number',\n // supported numeric literals:\n // * binary literal (e.g. 0x10)\n // * octal literal (e.g. 0o76543210)\n // * hexadecimal literal (e.g. 0xfedcba876543210)\n // * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)\n // * decimal literal (e.g. 9876543210, 100_000_000)\n // * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)\n begin: /(\\b0x[\\d_]*(\\.[\\d_]*)?|0x\\.\\d[\\d_]*)p[-+]?\\d+|\\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\\b\\d[\\d_]*(\\.[\\d_]*)?|\\.\\d[\\d_]*)([eEfF][-+]?\\d+)?/,\n relevance: 0\n };\n\n var CHAR = {\n className: 'string',\n begin: /'(.|\\\\[xXuU][a-zA-Z0-9]+)'/\n };\n\n var INTERPOLATION = {\n className: 'subst',\n begin: /\\$\\(/, end: /\\)/,\n keywords: KEYWORDS\n };\n\n var INTERPOLATED_VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + VARIABLE_NAME_RE\n };\n\n // TODO: neatly escape normal code in string literal\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n variants: [\n { begin: /\\w*\"\"\"/, end: /\"\"\"\\w*/, relevance: 10 },\n { begin: /\\w*\"/, end: /\"\\w*/ }\n ]\n };\n\n var COMMAND = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n begin: '`', end: '`'\n };\n\n var MACROCALL = {\n className: 'meta',\n begin: '@' + VARIABLE_NAME_RE\n };\n\n var COMMENT = {\n className: 'comment',\n variants: [\n { begin: '#=', end: '=#', relevance: 10 },\n { begin: '#', end: '$' }\n ]\n };\n\n DEFAULT.name = 'Julia';\n DEFAULT.contains = [\n NUMBER,\n CHAR,\n STRING,\n COMMAND,\n MACROCALL,\n COMMENT,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'keyword',\n begin:\n '\\\\b(((abstract|primitive)\\\\s+)type|(mutable\\\\s+)?struct)\\\\b'\n },\n {begin: /<:/} // relevance booster\n ];\n INTERPOLATION.contains = DEFAULT.contains;\n\n return DEFAULT;\n}", "title": "" }, { "docid": "ff4ef44c005e6edd08e05881276363f5", "score": "0.51782334", "text": "function julia(hljs) {\n // Since there are numerous special names in Julia, it is too much trouble\n // to maintain them by hand. Hence these names (i.e. keywords, literals and\n // built-ins) are automatically generated from Julia 1.5.2 itself through\n // the following scripts for each.\n\n // ref: https://docs.julialang.org/en/v1/manual/variables/#Allowed-Variable-Names\n var VARIABLE_NAME_RE = '[A-Za-z_\\\\u00A1-\\\\uFFFF][A-Za-z_0-9\\\\u00A1-\\\\uFFFF]*';\n\n // # keyword generator, multi-word keywords handled manually below (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"in\", \"isa\", \"where\"]\n // for kw in collect(x.keyword for x in REPLCompletions.complete_keyword(\"\"))\n // if !(contains(kw, \" \") || kw == \"struct\")\n // push!(res, kw)\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var KEYWORD_LIST = [\n 'baremodule',\n 'begin',\n 'break',\n 'catch',\n 'ccall',\n 'const',\n 'continue',\n 'do',\n 'else',\n 'elseif',\n 'end',\n 'export',\n 'false',\n 'finally',\n 'for',\n 'function',\n 'global',\n 'if',\n 'import',\n 'in',\n 'isa',\n 'let',\n 'local',\n 'macro',\n 'module',\n 'quote',\n 'return',\n 'true',\n 'try',\n 'using',\n 'where',\n 'while',\n ];\n\n // # literal generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[\"true\", \"false\"]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if !(v isa Function || v isa Type || v isa TypeVar || v isa Module || v isa Colon)\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var LITERAL_LIST = [\n 'ARGS',\n 'C_NULL',\n 'DEPOT_PATH',\n 'ENDIAN_BOM',\n 'ENV',\n 'Inf',\n 'Inf16',\n 'Inf32',\n 'Inf64',\n 'InsertionSort',\n 'LOAD_PATH',\n 'MergeSort',\n 'NaN',\n 'NaN16',\n 'NaN32',\n 'NaN64',\n 'PROGRAM_FILE',\n 'QuickSort',\n 'RoundDown',\n 'RoundFromZero',\n 'RoundNearest',\n 'RoundNearestTiesAway',\n 'RoundNearestTiesUp',\n 'RoundToZero',\n 'RoundUp',\n 'VERSION|0',\n 'devnull',\n 'false',\n 'im',\n 'missing',\n 'nothing',\n 'pi',\n 'stderr',\n 'stdin',\n 'stdout',\n 'true',\n 'undef',\n 'π',\n 'ℯ',\n ];\n\n // # built_in generator (Julia 1.5.2)\n // import REPL.REPLCompletions\n // res = String[]\n // for compl in filter!(x -> isa(x, REPLCompletions.ModuleCompletion) && (x.parent === Base || x.parent === Core),\n // REPLCompletions.completions(\"\", 0)[1])\n // try\n // v = eval(Symbol(compl.mod))\n // if (v isa Type || v isa TypeVar) && (compl.mod != \"=>\")\n // push!(res, compl.mod)\n // end\n // catch e\n // end\n // end\n // sort!(unique!(res))\n // foreach(x -> println(\"\\'\", x, \"\\',\"), res)\n var BUILT_IN_LIST = [\n 'AbstractArray',\n 'AbstractChannel',\n 'AbstractChar',\n 'AbstractDict',\n 'AbstractDisplay',\n 'AbstractFloat',\n 'AbstractIrrational',\n 'AbstractMatrix',\n 'AbstractRange',\n 'AbstractSet',\n 'AbstractString',\n 'AbstractUnitRange',\n 'AbstractVecOrMat',\n 'AbstractVector',\n 'Any',\n 'ArgumentError',\n 'Array',\n 'AssertionError',\n 'BigFloat',\n 'BigInt',\n 'BitArray',\n 'BitMatrix',\n 'BitSet',\n 'BitVector',\n 'Bool',\n 'BoundsError',\n 'CapturedException',\n 'CartesianIndex',\n 'CartesianIndices',\n 'Cchar',\n 'Cdouble',\n 'Cfloat',\n 'Channel',\n 'Char',\n 'Cint',\n 'Cintmax_t',\n 'Clong',\n 'Clonglong',\n 'Cmd',\n 'Colon',\n 'Complex',\n 'ComplexF16',\n 'ComplexF32',\n 'ComplexF64',\n 'CompositeException',\n 'Condition',\n 'Cptrdiff_t',\n 'Cshort',\n 'Csize_t',\n 'Cssize_t',\n 'Cstring',\n 'Cuchar',\n 'Cuint',\n 'Cuintmax_t',\n 'Culong',\n 'Culonglong',\n 'Cushort',\n 'Cvoid',\n 'Cwchar_t',\n 'Cwstring',\n 'DataType',\n 'DenseArray',\n 'DenseMatrix',\n 'DenseVecOrMat',\n 'DenseVector',\n 'Dict',\n 'DimensionMismatch',\n 'Dims',\n 'DivideError',\n 'DomainError',\n 'EOFError',\n 'Enum',\n 'ErrorException',\n 'Exception',\n 'ExponentialBackOff',\n 'Expr',\n 'Float16',\n 'Float32',\n 'Float64',\n 'Function',\n 'GlobalRef',\n 'HTML',\n 'IO',\n 'IOBuffer',\n 'IOContext',\n 'IOStream',\n 'IdDict',\n 'IndexCartesian',\n 'IndexLinear',\n 'IndexStyle',\n 'InexactError',\n 'InitError',\n 'Int',\n 'Int128',\n 'Int16',\n 'Int32',\n 'Int64',\n 'Int8',\n 'Integer',\n 'InterruptException',\n 'InvalidStateException',\n 'Irrational',\n 'KeyError',\n 'LinRange',\n 'LineNumberNode',\n 'LinearIndices',\n 'LoadError',\n 'MIME',\n 'Matrix',\n 'Method',\n 'MethodError',\n 'Missing',\n 'MissingException',\n 'Module',\n 'NTuple',\n 'NamedTuple',\n 'Nothing',\n 'Number',\n 'OrdinalRange',\n 'OutOfMemoryError',\n 'OverflowError',\n 'Pair',\n 'PartialQuickSort',\n 'PermutedDimsArray',\n 'Pipe',\n 'ProcessFailedException',\n 'Ptr',\n 'QuoteNode',\n 'Rational',\n 'RawFD',\n 'ReadOnlyMemoryError',\n 'Real',\n 'ReentrantLock',\n 'Ref',\n 'Regex',\n 'RegexMatch',\n 'RoundingMode',\n 'SegmentationFault',\n 'Set',\n 'Signed',\n 'Some',\n 'StackOverflowError',\n 'StepRange',\n 'StepRangeLen',\n 'StridedArray',\n 'StridedMatrix',\n 'StridedVecOrMat',\n 'StridedVector',\n 'String',\n 'StringIndexError',\n 'SubArray',\n 'SubString',\n 'SubstitutionString',\n 'Symbol',\n 'SystemError',\n 'Task',\n 'TaskFailedException',\n 'Text',\n 'TextDisplay',\n 'Timer',\n 'Tuple',\n 'Type',\n 'TypeError',\n 'TypeVar',\n 'UInt',\n 'UInt128',\n 'UInt16',\n 'UInt32',\n 'UInt64',\n 'UInt8',\n 'UndefInitializer',\n 'UndefKeywordError',\n 'UndefRefError',\n 'UndefVarError',\n 'Union',\n 'UnionAll',\n 'UnitRange',\n 'Unsigned',\n 'Val',\n 'Vararg',\n 'VecElement',\n 'VecOrMat',\n 'Vector',\n 'VersionNumber',\n 'WeakKeyDict',\n 'WeakRef',\n ];\n\n var KEYWORDS = {\n $pattern: VARIABLE_NAME_RE,\n keyword: KEYWORD_LIST,\n literal: LITERAL_LIST,\n built_in: BUILT_IN_LIST,\n };\n\n // placeholder for recursive self-reference\n var DEFAULT = {\n keywords: KEYWORDS, illegal: /<\\//\n };\n\n // ref: https://docs.julialang.org/en/v1/manual/integers-and-floating-point-numbers/\n var NUMBER = {\n className: 'number',\n // supported numeric literals:\n // * binary literal (e.g. 0x10)\n // * octal literal (e.g. 0o76543210)\n // * hexadecimal literal (e.g. 0xfedcba876543210)\n // * hexadecimal floating point literal (e.g. 0x1p0, 0x1.2p2)\n // * decimal literal (e.g. 9876543210, 100_000_000)\n // * floating pointe literal (e.g. 1.2, 1.2f, .2, 1., 1.2e10, 1.2e-10)\n begin: /(\\b0x[\\d_]*(\\.[\\d_]*)?|0x\\.\\d[\\d_]*)p[-+]?\\d+|\\b0[box][a-fA-F0-9][a-fA-F0-9_]*|(\\b\\d[\\d_]*(\\.[\\d_]*)?|\\.\\d[\\d_]*)([eEfF][-+]?\\d+)?/,\n relevance: 0\n };\n\n var CHAR = {\n className: 'string',\n begin: /'(.|\\\\[xXuU][a-zA-Z0-9]+)'/\n };\n\n var INTERPOLATION = {\n className: 'subst',\n begin: /\\$\\(/, end: /\\)/,\n keywords: KEYWORDS\n };\n\n var INTERPOLATED_VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + VARIABLE_NAME_RE\n };\n\n // TODO: neatly escape normal code in string literal\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n variants: [\n { begin: /\\w*\"\"\"/, end: /\"\"\"\\w*/, relevance: 10 },\n { begin: /\\w*\"/, end: /\"\\w*/ }\n ]\n };\n\n var COMMAND = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, INTERPOLATION, INTERPOLATED_VARIABLE],\n begin: '`', end: '`'\n };\n\n var MACROCALL = {\n className: 'meta',\n begin: '@' + VARIABLE_NAME_RE\n };\n\n var COMMENT = {\n className: 'comment',\n variants: [\n { begin: '#=', end: '=#', relevance: 10 },\n { begin: '#', end: '$' }\n ]\n };\n\n DEFAULT.name = 'Julia';\n DEFAULT.contains = [\n NUMBER,\n CHAR,\n STRING,\n COMMAND,\n MACROCALL,\n COMMENT,\n hljs.HASH_COMMENT_MODE,\n {\n className: 'keyword',\n begin:\n '\\\\b(((abstract|primitive)\\\\s+)type|(mutable\\\\s+)?struct)\\\\b'\n },\n {begin: /<:/} // relevance booster\n ];\n INTERPOLATION.contains = DEFAULT.contains;\n\n return DEFAULT;\n}", "title": "" }, { "docid": "5cb7e3c57f986f6a0ba8012b90236a55", "score": "0.5146942", "text": "function scala(hljs) {\n\n var ANNOTATION = { className: 'meta', begin: '@[A-Za-z]+' };\n\n // used in strings for escaping/interpolation/substitution\n var SUBST = {\n className: 'subst',\n variants: [\n {begin: '\\\\$[A-Za-z0-9_]+'},\n {begin: '\\\\${', end: '}'}\n ]\n };\n\n var STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"', end: '\"',\n illegal: '\\\\n',\n contains: [hljs.BACKSLASH_ESCAPE]\n },\n {\n begin: '\"\"\"', end: '\"\"\"',\n relevance: 10\n },\n {\n begin: '[a-z]+\"', end: '\"',\n illegal: '\\\\n',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST]\n },\n {\n className: 'string',\n begin: '[a-z]+\"\"\"', end: '\"\"\"',\n contains: [SUBST],\n relevance: 10\n }\n ]\n\n };\n\n var SYMBOL = {\n className: 'symbol',\n begin: '\\'\\\\w[\\\\w\\\\d_]*(?!\\')'\n };\n\n var TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][A-Za-z0-9_]*',\n relevance: 0\n };\n\n var NAME = {\n className: 'title',\n begin: /[^0-9\\n\\t \"'(),.`{}\\[\\]:;][^\\n\\t \"'(),.`{}\\[\\]:;]+|[^0-9\\n\\t \"'(),.`{}\\[\\]:;=]/,\n relevance: 0\n };\n\n var CLASS = {\n className: 'class',\n beginKeywords: 'class object trait type',\n end: /[:={\\[\\n;]/,\n excludeEnd: true,\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n {\n beginKeywords: 'extends with',\n relevance: 10\n },\n {\n begin: /\\[/,\n end: /\\]/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [TYPE]\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [TYPE]\n },\n NAME\n ]\n };\n\n var METHOD = {\n className: 'function',\n beginKeywords: 'def',\n end: /[:={\\[(\\n;]/,\n excludeEnd: true,\n contains: [NAME]\n };\n\n return {\n name: 'Scala',\n keywords: {\n literal: 'true false null',\n keyword: 'type yield lazy override def with val var sealed abstract private trait object if forSome for while throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n STRING,\n SYMBOL,\n TYPE,\n METHOD,\n CLASS,\n hljs.C_NUMBER_MODE,\n ANNOTATION\n ]\n };\n}", "title": "" }, { "docid": "492e37acfb7024ca9ce256b693ff5907", "score": "0.5099951", "text": "_function(parentSource) {\n var source;\n var linedefined;\n var lastlinedefined;\n var nups;\n var numparams;\n var varargByte;\n var vararg;\n var maxstacksize;\n var code; //int[] \n var constant; //Slot[] \n var proto; //Proto[] \n source = this.string();\n if (null == source) {\n source = parentSource;\n }\n linedefined = this.intLoad();\n lastlinedefined = this.intLoad();\n nups = this.byteLoad();\n numparams = this.byteLoad();\n varargByte = this.byteLoad();\n // \"is_vararg\" is a 3-bit field, with the following bit meanings\n // (see \"lobject.h\"):\n // 1 - VARARG_HASARG\n // 2 - VARARG_ISVARARG\n // 4 - VARARG_NEEDSARG\n // Values 1 and 4 (bits 0 and 2) are only used for 5.0\n // compatibility.\n // HASARG indicates that a function was compiled in 5.0\n // compatibility mode and is declared to have ... in its parameter\n // list.\n // NEEDSARG indicates that a function was compiled in 5.0\n // compatibility mode and is declared to have ... in its parameter\n // list and does _not_ use the 5.1 style of vararg access (using ...\n // as an expression). It is assumed to use 5.0 style vararg access\n // (the local 'arg' variable). This is not supported in Jill.\n // ISVARARG indicates that a function has ... in its parameter list\n // (whether compiled in 5.0 compatibility mode or not).\n //\n // At runtime NEEDSARG changes the protocol for calling a vararg\n // function. We don't support this, so we check that it is absent\n // here in the loader.\n //\n // That means that the legal values for this field ar 0,1,2,3.\n if (varargByte < 0 || varargByte > 3) {\n throw new IOException_1.IOException();\n }\n vararg = (0 != varargByte);\n maxstacksize = this.byteLoad();\n code = this.code();\n constant = this.constant();\n proto = this.proto(source);\n var newProto = new Proto_1.Proto();\n newProto.init1(constant, code, proto, nups, numparams, vararg, maxstacksize); //TODO:\n newProto.source = source;\n newProto.linedefined = linedefined;\n newProto.lastlinedefined = lastlinedefined;\n this.debug(newProto);\n // :todo: call code verifier\n return newProto;\n }", "title": "" }, { "docid": "4351b1d0f49bd0b7b5130535f8b650f9", "score": "0.50931203", "text": "function python(hljs) {\n const RESERVED_WORDS = [\n 'and',\n 'as',\n 'assert',\n 'async',\n 'await',\n 'break',\n 'class',\n 'continue',\n 'def',\n 'del',\n 'elif',\n 'else',\n 'except',\n 'finally',\n 'for',\n 'from',\n 'global',\n 'if',\n 'import',\n 'in',\n 'is',\n 'lambda',\n 'nonlocal|10',\n 'not',\n 'or',\n 'pass',\n 'raise',\n 'return',\n 'try',\n 'while',\n 'with',\n 'yield'\n ];\n\n const BUILT_INS = [\n '__import__',\n 'abs',\n 'all',\n 'any',\n 'ascii',\n 'bin',\n 'bool',\n 'breakpoint',\n 'bytearray',\n 'bytes',\n 'callable',\n 'chr',\n 'classmethod',\n 'compile',\n 'complex',\n 'delattr',\n 'dict',\n 'dir',\n 'divmod',\n 'enumerate',\n 'eval',\n 'exec',\n 'filter',\n 'float',\n 'format',\n 'frozenset',\n 'getattr',\n 'globals',\n 'hasattr',\n 'hash',\n 'help',\n 'hex',\n 'id',\n 'input',\n 'int',\n 'isinstance',\n 'issubclass',\n 'iter',\n 'len',\n 'list',\n 'locals',\n 'map',\n 'max',\n 'memoryview',\n 'min',\n 'next',\n 'object',\n 'oct',\n 'open',\n 'ord',\n 'pow',\n 'print',\n 'property',\n 'range',\n 'repr',\n 'reversed',\n 'round',\n 'set',\n 'setattr',\n 'slice',\n 'sorted',\n 'staticmethod',\n 'str',\n 'sum',\n 'super',\n 'tuple',\n 'type',\n 'vars',\n 'zip'\n ];\n\n const LITERALS = [\n '__debug__',\n 'Ellipsis',\n 'False',\n 'None',\n 'NotImplemented',\n 'True'\n ];\n\n // https://docs.python.org/3/library/typing.html\n // TODO: Could these be supplemented by a CamelCase matcher in certain\n // contexts, leaving these remaining only for relevance hinting?\n const TYPES = [\n \"Any\",\n \"Callable\",\n \"Coroutine\",\n \"Dict\",\n \"List\",\n \"Literal\",\n \"Generic\",\n \"Optional\",\n \"Sequence\",\n \"Set\",\n \"Tuple\",\n \"Type\",\n \"Union\"\n ];\n\n const KEYWORDS = {\n $pattern: /[A-Za-z]\\w+|__\\w+__/,\n keyword: RESERVED_WORDS,\n built_in: BUILT_INS,\n literal: LITERALS,\n type: TYPES\n };\n\n const PROMPT = {\n className: 'meta',\n begin: /^(>>>|\\.\\.\\.) /\n };\n\n const SUBST = {\n className: 'subst',\n begin: /\\{/,\n end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n\n const LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n\n const STRING = {\n className: 'string',\n contains: [ hljs.BACKSLASH_ESCAPE ],\n variants: [\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([uU]|[rR])'/,\n end: /'/,\n relevance: 10\n },\n {\n begin: /([uU]|[rR])\"/,\n end: /\"/,\n relevance: 10\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])'/,\n end: /'/\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])\"/,\n end: /\"/\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'/,\n end: /'/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"/,\n end: /\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n\n // https://docs.python.org/3.9/reference/lexical_analysis.html#numeric-literals\n const digitpart = '[0-9](_?[0-9])*';\n const pointfloat = `(\\\\b(${digitpart}))?\\\\.(${digitpart})|\\\\b(${digitpart})\\\\.`;\n const NUMBER = {\n className: 'number',\n relevance: 0,\n variants: [\n // exponentfloat, pointfloat\n // https://docs.python.org/3.9/reference/lexical_analysis.html#floating-point-literals\n // optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n // Note: no leading \\b because floats can start with a decimal point\n // and we don't want to mishandle e.g. `fn(.5)`,\n // no trailing \\b for pointfloat because it can end with a decimal point\n // and we don't want to mishandle e.g. `0..hex()`; this should be safe\n // because both MUST contain a decimal point and so cannot be confused with\n // the interior part of an identifier\n {\n begin: `(\\\\b(${digitpart})|(${pointfloat}))[eE][+-]?(${digitpart})[jJ]?\\\\b`\n },\n {\n begin: `(${pointfloat})[jJ]?`\n },\n\n // decinteger, bininteger, octinteger, hexinteger\n // https://docs.python.org/3.9/reference/lexical_analysis.html#integer-literals\n // optionally \"long\" in Python 2\n // https://docs.python.org/2.7/reference/lexical_analysis.html#integer-and-long-integer-literals\n // decinteger is optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: '\\\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?\\\\b'\n },\n {\n begin: '\\\\b0[bB](_?[01])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[oO](_?[0-7])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[xX](_?[0-9a-fA-F])+[lL]?\\\\b'\n },\n\n // imagnumber (digitpart-based)\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: `\\\\b(${digitpart})[jJ]\\\\b`\n }\n ]\n };\n const COMMENT_TYPE = {\n className: \"comment\",\n begin: lookahead(/# type:/),\n end: /$/,\n keywords: KEYWORDS,\n contains: [\n { // prevent keywords from coloring `type`\n begin: /# type:/\n },\n // comment within a datatype comment includes no keywords\n {\n begin: /#/,\n end: /\\b\\B/,\n endsWithParent: true\n }\n ]\n };\n const PARAMS = {\n className: 'params',\n variants: [\n // Exclude params in functions without params\n {\n className: \"\",\n begin: /\\(\\s*\\)/,\n skip: true\n },\n {\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n 'self',\n PROMPT,\n NUMBER,\n STRING,\n hljs.HASH_COMMENT_MODE\n ]\n }\n ]\n };\n SUBST.contains = [\n STRING,\n NUMBER,\n PROMPT\n ];\n\n return {\n name: 'Python',\n aliases: [\n 'py',\n 'gyp',\n 'ipython'\n ],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n {\n // very common convention\n begin: /\\bself\\b/\n },\n {\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string\n beginKeywords: \"if\",\n relevance: 0\n },\n STRING,\n COMMENT_TYPE,\n hljs.HASH_COMMENT_MODE,\n {\n variants: [\n {\n className: 'function',\n beginKeywords: 'def'\n },\n {\n className: 'class',\n beginKeywords: 'class'\n }\n ],\n end: /:/,\n illegal: /[${=;\\n,]/,\n contains: [\n hljs.UNDERSCORE_TITLE_MODE,\n PARAMS,\n {\n begin: /->/,\n endsWithParent: true,\n keywords: KEYWORDS\n }\n ]\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/,\n end: /(?=#)|$/,\n contains: [\n NUMBER,\n PARAMS,\n STRING\n ]\n }\n ]\n };\n}", "title": "" }, { "docid": "4351b1d0f49bd0b7b5130535f8b650f9", "score": "0.50931203", "text": "function python(hljs) {\n const RESERVED_WORDS = [\n 'and',\n 'as',\n 'assert',\n 'async',\n 'await',\n 'break',\n 'class',\n 'continue',\n 'def',\n 'del',\n 'elif',\n 'else',\n 'except',\n 'finally',\n 'for',\n 'from',\n 'global',\n 'if',\n 'import',\n 'in',\n 'is',\n 'lambda',\n 'nonlocal|10',\n 'not',\n 'or',\n 'pass',\n 'raise',\n 'return',\n 'try',\n 'while',\n 'with',\n 'yield'\n ];\n\n const BUILT_INS = [\n '__import__',\n 'abs',\n 'all',\n 'any',\n 'ascii',\n 'bin',\n 'bool',\n 'breakpoint',\n 'bytearray',\n 'bytes',\n 'callable',\n 'chr',\n 'classmethod',\n 'compile',\n 'complex',\n 'delattr',\n 'dict',\n 'dir',\n 'divmod',\n 'enumerate',\n 'eval',\n 'exec',\n 'filter',\n 'float',\n 'format',\n 'frozenset',\n 'getattr',\n 'globals',\n 'hasattr',\n 'hash',\n 'help',\n 'hex',\n 'id',\n 'input',\n 'int',\n 'isinstance',\n 'issubclass',\n 'iter',\n 'len',\n 'list',\n 'locals',\n 'map',\n 'max',\n 'memoryview',\n 'min',\n 'next',\n 'object',\n 'oct',\n 'open',\n 'ord',\n 'pow',\n 'print',\n 'property',\n 'range',\n 'repr',\n 'reversed',\n 'round',\n 'set',\n 'setattr',\n 'slice',\n 'sorted',\n 'staticmethod',\n 'str',\n 'sum',\n 'super',\n 'tuple',\n 'type',\n 'vars',\n 'zip'\n ];\n\n const LITERALS = [\n '__debug__',\n 'Ellipsis',\n 'False',\n 'None',\n 'NotImplemented',\n 'True'\n ];\n\n // https://docs.python.org/3/library/typing.html\n // TODO: Could these be supplemented by a CamelCase matcher in certain\n // contexts, leaving these remaining only for relevance hinting?\n const TYPES = [\n \"Any\",\n \"Callable\",\n \"Coroutine\",\n \"Dict\",\n \"List\",\n \"Literal\",\n \"Generic\",\n \"Optional\",\n \"Sequence\",\n \"Set\",\n \"Tuple\",\n \"Type\",\n \"Union\"\n ];\n\n const KEYWORDS = {\n $pattern: /[A-Za-z]\\w+|__\\w+__/,\n keyword: RESERVED_WORDS,\n built_in: BUILT_INS,\n literal: LITERALS,\n type: TYPES\n };\n\n const PROMPT = {\n className: 'meta',\n begin: /^(>>>|\\.\\.\\.) /\n };\n\n const SUBST = {\n className: 'subst',\n begin: /\\{/,\n end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n\n const LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n\n const STRING = {\n className: 'string',\n contains: [ hljs.BACKSLASH_ESCAPE ],\n variants: [\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([uU]|[rR])'/,\n end: /'/,\n relevance: 10\n },\n {\n begin: /([uU]|[rR])\"/,\n end: /\"/,\n relevance: 10\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])'/,\n end: /'/\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])\"/,\n end: /\"/\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'/,\n end: /'/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"/,\n end: /\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n\n // https://docs.python.org/3.9/reference/lexical_analysis.html#numeric-literals\n const digitpart = '[0-9](_?[0-9])*';\n const pointfloat = `(\\\\b(${digitpart}))?\\\\.(${digitpart})|\\\\b(${digitpart})\\\\.`;\n const NUMBER = {\n className: 'number',\n relevance: 0,\n variants: [\n // exponentfloat, pointfloat\n // https://docs.python.org/3.9/reference/lexical_analysis.html#floating-point-literals\n // optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n // Note: no leading \\b because floats can start with a decimal point\n // and we don't want to mishandle e.g. `fn(.5)`,\n // no trailing \\b for pointfloat because it can end with a decimal point\n // and we don't want to mishandle e.g. `0..hex()`; this should be safe\n // because both MUST contain a decimal point and so cannot be confused with\n // the interior part of an identifier\n {\n begin: `(\\\\b(${digitpart})|(${pointfloat}))[eE][+-]?(${digitpart})[jJ]?\\\\b`\n },\n {\n begin: `(${pointfloat})[jJ]?`\n },\n\n // decinteger, bininteger, octinteger, hexinteger\n // https://docs.python.org/3.9/reference/lexical_analysis.html#integer-literals\n // optionally \"long\" in Python 2\n // https://docs.python.org/2.7/reference/lexical_analysis.html#integer-and-long-integer-literals\n // decinteger is optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: '\\\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?\\\\b'\n },\n {\n begin: '\\\\b0[bB](_?[01])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[oO](_?[0-7])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[xX](_?[0-9a-fA-F])+[lL]?\\\\b'\n },\n\n // imagnumber (digitpart-based)\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: `\\\\b(${digitpart})[jJ]\\\\b`\n }\n ]\n };\n const COMMENT_TYPE = {\n className: \"comment\",\n begin: lookahead(/# type:/),\n end: /$/,\n keywords: KEYWORDS,\n contains: [\n { // prevent keywords from coloring `type`\n begin: /# type:/\n },\n // comment within a datatype comment includes no keywords\n {\n begin: /#/,\n end: /\\b\\B/,\n endsWithParent: true\n }\n ]\n };\n const PARAMS = {\n className: 'params',\n variants: [\n // Exclude params in functions without params\n {\n className: \"\",\n begin: /\\(\\s*\\)/,\n skip: true\n },\n {\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n 'self',\n PROMPT,\n NUMBER,\n STRING,\n hljs.HASH_COMMENT_MODE\n ]\n }\n ]\n };\n SUBST.contains = [\n STRING,\n NUMBER,\n PROMPT\n ];\n\n return {\n name: 'Python',\n aliases: [\n 'py',\n 'gyp',\n 'ipython'\n ],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n {\n // very common convention\n begin: /\\bself\\b/\n },\n {\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string\n beginKeywords: \"if\",\n relevance: 0\n },\n STRING,\n COMMENT_TYPE,\n hljs.HASH_COMMENT_MODE,\n {\n variants: [\n {\n className: 'function',\n beginKeywords: 'def'\n },\n {\n className: 'class',\n beginKeywords: 'class'\n }\n ],\n end: /:/,\n illegal: /[${=;\\n,]/,\n contains: [\n hljs.UNDERSCORE_TITLE_MODE,\n PARAMS,\n {\n begin: /->/,\n endsWithParent: true,\n keywords: KEYWORDS\n }\n ]\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/,\n end: /(?=#)|$/,\n contains: [\n NUMBER,\n PARAMS,\n STRING\n ]\n }\n ]\n };\n}", "title": "" }, { "docid": "4351b1d0f49bd0b7b5130535f8b650f9", "score": "0.50931203", "text": "function python(hljs) {\n const RESERVED_WORDS = [\n 'and',\n 'as',\n 'assert',\n 'async',\n 'await',\n 'break',\n 'class',\n 'continue',\n 'def',\n 'del',\n 'elif',\n 'else',\n 'except',\n 'finally',\n 'for',\n 'from',\n 'global',\n 'if',\n 'import',\n 'in',\n 'is',\n 'lambda',\n 'nonlocal|10',\n 'not',\n 'or',\n 'pass',\n 'raise',\n 'return',\n 'try',\n 'while',\n 'with',\n 'yield'\n ];\n\n const BUILT_INS = [\n '__import__',\n 'abs',\n 'all',\n 'any',\n 'ascii',\n 'bin',\n 'bool',\n 'breakpoint',\n 'bytearray',\n 'bytes',\n 'callable',\n 'chr',\n 'classmethod',\n 'compile',\n 'complex',\n 'delattr',\n 'dict',\n 'dir',\n 'divmod',\n 'enumerate',\n 'eval',\n 'exec',\n 'filter',\n 'float',\n 'format',\n 'frozenset',\n 'getattr',\n 'globals',\n 'hasattr',\n 'hash',\n 'help',\n 'hex',\n 'id',\n 'input',\n 'int',\n 'isinstance',\n 'issubclass',\n 'iter',\n 'len',\n 'list',\n 'locals',\n 'map',\n 'max',\n 'memoryview',\n 'min',\n 'next',\n 'object',\n 'oct',\n 'open',\n 'ord',\n 'pow',\n 'print',\n 'property',\n 'range',\n 'repr',\n 'reversed',\n 'round',\n 'set',\n 'setattr',\n 'slice',\n 'sorted',\n 'staticmethod',\n 'str',\n 'sum',\n 'super',\n 'tuple',\n 'type',\n 'vars',\n 'zip'\n ];\n\n const LITERALS = [\n '__debug__',\n 'Ellipsis',\n 'False',\n 'None',\n 'NotImplemented',\n 'True'\n ];\n\n // https://docs.python.org/3/library/typing.html\n // TODO: Could these be supplemented by a CamelCase matcher in certain\n // contexts, leaving these remaining only for relevance hinting?\n const TYPES = [\n \"Any\",\n \"Callable\",\n \"Coroutine\",\n \"Dict\",\n \"List\",\n \"Literal\",\n \"Generic\",\n \"Optional\",\n \"Sequence\",\n \"Set\",\n \"Tuple\",\n \"Type\",\n \"Union\"\n ];\n\n const KEYWORDS = {\n $pattern: /[A-Za-z]\\w+|__\\w+__/,\n keyword: RESERVED_WORDS,\n built_in: BUILT_INS,\n literal: LITERALS,\n type: TYPES\n };\n\n const PROMPT = {\n className: 'meta',\n begin: /^(>>>|\\.\\.\\.) /\n };\n\n const SUBST = {\n className: 'subst',\n begin: /\\{/,\n end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n\n const LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n\n const STRING = {\n className: 'string',\n contains: [ hljs.BACKSLASH_ESCAPE ],\n variants: [\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([uU]|[rR])'/,\n end: /'/,\n relevance: 10\n },\n {\n begin: /([uU]|[rR])\"/,\n end: /\"/,\n relevance: 10\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])'/,\n end: /'/\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])\"/,\n end: /\"/\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'/,\n end: /'/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"/,\n end: /\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n\n // https://docs.python.org/3.9/reference/lexical_analysis.html#numeric-literals\n const digitpart = '[0-9](_?[0-9])*';\n const pointfloat = `(\\\\b(${digitpart}))?\\\\.(${digitpart})|\\\\b(${digitpart})\\\\.`;\n const NUMBER = {\n className: 'number',\n relevance: 0,\n variants: [\n // exponentfloat, pointfloat\n // https://docs.python.org/3.9/reference/lexical_analysis.html#floating-point-literals\n // optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n // Note: no leading \\b because floats can start with a decimal point\n // and we don't want to mishandle e.g. `fn(.5)`,\n // no trailing \\b for pointfloat because it can end with a decimal point\n // and we don't want to mishandle e.g. `0..hex()`; this should be safe\n // because both MUST contain a decimal point and so cannot be confused with\n // the interior part of an identifier\n {\n begin: `(\\\\b(${digitpart})|(${pointfloat}))[eE][+-]?(${digitpart})[jJ]?\\\\b`\n },\n {\n begin: `(${pointfloat})[jJ]?`\n },\n\n // decinteger, bininteger, octinteger, hexinteger\n // https://docs.python.org/3.9/reference/lexical_analysis.html#integer-literals\n // optionally \"long\" in Python 2\n // https://docs.python.org/2.7/reference/lexical_analysis.html#integer-and-long-integer-literals\n // decinteger is optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: '\\\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?\\\\b'\n },\n {\n begin: '\\\\b0[bB](_?[01])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[oO](_?[0-7])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[xX](_?[0-9a-fA-F])+[lL]?\\\\b'\n },\n\n // imagnumber (digitpart-based)\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: `\\\\b(${digitpart})[jJ]\\\\b`\n }\n ]\n };\n const COMMENT_TYPE = {\n className: \"comment\",\n begin: lookahead(/# type:/),\n end: /$/,\n keywords: KEYWORDS,\n contains: [\n { // prevent keywords from coloring `type`\n begin: /# type:/\n },\n // comment within a datatype comment includes no keywords\n {\n begin: /#/,\n end: /\\b\\B/,\n endsWithParent: true\n }\n ]\n };\n const PARAMS = {\n className: 'params',\n variants: [\n // Exclude params in functions without params\n {\n className: \"\",\n begin: /\\(\\s*\\)/,\n skip: true\n },\n {\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n 'self',\n PROMPT,\n NUMBER,\n STRING,\n hljs.HASH_COMMENT_MODE\n ]\n }\n ]\n };\n SUBST.contains = [\n STRING,\n NUMBER,\n PROMPT\n ];\n\n return {\n name: 'Python',\n aliases: [\n 'py',\n 'gyp',\n 'ipython'\n ],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n {\n // very common convention\n begin: /\\bself\\b/\n },\n {\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string\n beginKeywords: \"if\",\n relevance: 0\n },\n STRING,\n COMMENT_TYPE,\n hljs.HASH_COMMENT_MODE,\n {\n variants: [\n {\n className: 'function',\n beginKeywords: 'def'\n },\n {\n className: 'class',\n beginKeywords: 'class'\n }\n ],\n end: /:/,\n illegal: /[${=;\\n,]/,\n contains: [\n hljs.UNDERSCORE_TITLE_MODE,\n PARAMS,\n {\n begin: /->/,\n endsWithParent: true,\n keywords: KEYWORDS\n }\n ]\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/,\n end: /(?=#)|$/,\n contains: [\n NUMBER,\n PARAMS,\n STRING\n ]\n }\n ]\n };\n}", "title": "" }, { "docid": "9dd1d666624b01bc5ad316e23e29d65d", "score": "0.5091389", "text": "function kotlin(hljs) {\n const KEYWORDS = {\n keyword:\n 'abstract as val var vararg get set class object open private protected public noinline ' +\n 'crossinline dynamic final enum if else do while for when throw try catch finally ' +\n 'import package is in fun override companion reified inline lateinit init ' +\n 'interface annotation data sealed internal infix operator out by constructor super ' +\n 'tailrec where const inner suspend typealias external expect actual',\n built_in:\n 'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',\n literal:\n 'true false null'\n };\n const KEYWORDS_WITH_LABEL = {\n className: 'keyword',\n begin: /\\b(break|continue|return|this)\\b/,\n starts: {\n contains: [\n {\n className: 'symbol',\n begin: /@\\w+/\n }\n ]\n }\n };\n const LABEL = {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '@'\n };\n\n // for string templates\n const SUBST = {\n className: 'subst',\n begin: /\\$\\{/,\n end: /\\}/,\n contains: [ hljs.C_NUMBER_MODE ]\n };\n const VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + hljs.UNDERSCORE_IDENT_RE\n };\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"(?=[^\"])',\n contains: [\n VARIABLE,\n SUBST\n ]\n },\n // Can't use built-in modes easily, as we want to use STRING in the meta\n // context as 'meta-string' and there's no syntax to remove explicitly set\n // classNames in built-in modes.\n {\n begin: '\\'',\n end: '\\'',\n illegal: /\\n/,\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '\"',\n end: '\"',\n illegal: /\\n/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n VARIABLE,\n SUBST\n ]\n }\n ]\n };\n SUBST.contains.push(STRING);\n\n const ANNOTATION_USE_SITE = {\n className: 'meta',\n begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'\n };\n const ANNOTATION = {\n className: 'meta',\n begin: '@' + hljs.UNDERSCORE_IDENT_RE,\n contains: [\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [\n hljs.inherit(STRING, {\n className: 'meta-string'\n })\n ]\n }\n ]\n };\n\n // https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n // According to the doc above, the number mode of kotlin is the same as java 8,\n // so the code below is copied from java.js\n const KOTLIN_NUMBER_MODE = NUMERIC;\n const KOTLIN_NESTED_COMMENT = hljs.COMMENT(\n '/\\\\*', '\\\\*/',\n {\n contains: [ hljs.C_BLOCK_COMMENT_MODE ]\n }\n );\n const KOTLIN_PAREN_TYPE = {\n variants: [\n {\n className: 'type',\n begin: hljs.UNDERSCORE_IDENT_RE\n },\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [] // defined later\n }\n ]\n };\n const KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;\n KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];\n KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];\n\n return {\n name: 'Kotlin',\n aliases: [ 'kt' ],\n keywords: KEYWORDS,\n contains: [\n hljs.COMMENT(\n '/\\\\*\\\\*',\n '\\\\*/',\n {\n relevance: 0,\n contains: [\n {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n }\n ]\n }\n ),\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n KEYWORDS_WITH_LABEL,\n LABEL,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n {\n className: 'function',\n beginKeywords: 'fun',\n end: '[(]|$',\n returnBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n relevance: 5,\n contains: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE + '\\\\s*\\\\(',\n returnBegin: true,\n relevance: 0,\n contains: [ hljs.UNDERSCORE_TITLE_MODE ]\n },\n {\n className: 'type',\n begin: /</,\n end: />/,\n keywords: 'reified',\n relevance: 0\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n endsParent: true,\n keywords: KEYWORDS,\n relevance: 0,\n contains: [\n {\n begin: /:/,\n end: /[=,\\/]/,\n endsWithParent: true,\n contains: [\n KOTLIN_PAREN_TYPE,\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT\n ],\n relevance: 0\n },\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n STRING,\n hljs.C_NUMBER_MODE\n ]\n },\n KOTLIN_NESTED_COMMENT\n ]\n },\n {\n className: 'class',\n beginKeywords: 'class interface trait', // remove 'trait' when removed from KEYWORDS\n end: /[:\\{(]|$/,\n excludeEnd: true,\n illegal: 'extends implements',\n contains: [\n {\n beginKeywords: 'public protected internal private constructor'\n },\n hljs.UNDERSCORE_TITLE_MODE,\n {\n className: 'type',\n begin: /</,\n end: />/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type',\n begin: /[,:]\\s*/,\n end: /[<\\(,]|$/,\n excludeBegin: true,\n returnEnd: true\n },\n ANNOTATION_USE_SITE,\n ANNOTATION\n ]\n },\n STRING,\n {\n className: 'meta',\n begin: \"^#!/usr/bin/env\",\n end: '$',\n illegal: '\\n'\n },\n KOTLIN_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "1c46e9a7742b555e41adfa13a581e000", "score": "0.5091389", "text": "function kotlin(hljs) {\n const KEYWORDS = {\n keyword:\n 'abstract as val var vararg get set class object open private protected public noinline ' +\n 'crossinline dynamic final enum if else do while for when throw try catch finally ' +\n 'import package is in fun override companion reified inline lateinit init ' +\n 'interface annotation data sealed internal infix operator out by constructor super ' +\n 'tailrec where const inner suspend typealias external expect actual',\n built_in:\n 'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',\n literal:\n 'true false null'\n };\n const KEYWORDS_WITH_LABEL = {\n className: 'keyword',\n begin: /\\b(break|continue|return|this)\\b/,\n starts: {\n contains: [\n {\n className: 'symbol',\n begin: /@\\w+/\n }\n ]\n }\n };\n const LABEL = {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '@'\n };\n\n // for string templates\n const SUBST = {\n className: 'subst',\n begin: /\\$\\{/,\n end: /\\}/,\n contains: [ hljs.C_NUMBER_MODE ]\n };\n const VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + hljs.UNDERSCORE_IDENT_RE\n };\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"(?=[^\"])',\n contains: [\n VARIABLE,\n SUBST\n ]\n },\n // Can't use built-in modes easily, as we want to use STRING in the meta\n // context as 'meta-string' and there's no syntax to remove explicitly set\n // classNames in built-in modes.\n {\n begin: '\\'',\n end: '\\'',\n illegal: /\\n/,\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '\"',\n end: '\"',\n illegal: /\\n/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n VARIABLE,\n SUBST\n ]\n }\n ]\n };\n SUBST.contains.push(STRING);\n\n const ANNOTATION_USE_SITE = {\n className: 'meta',\n begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'\n };\n const ANNOTATION = {\n className: 'meta',\n begin: '@' + hljs.UNDERSCORE_IDENT_RE,\n contains: [\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [\n hljs.inherit(STRING, {\n className: 'meta-string'\n })\n ]\n }\n ]\n };\n\n // https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n // According to the doc above, the number mode of kotlin is the same as java 8,\n // so the code below is copied from java.js\n const KOTLIN_NUMBER_MODE = NUMERIC;\n const KOTLIN_NESTED_COMMENT = hljs.COMMENT(\n '/\\\\*', '\\\\*/',\n {\n contains: [ hljs.C_BLOCK_COMMENT_MODE ]\n }\n );\n const KOTLIN_PAREN_TYPE = {\n variants: [\n {\n className: 'type',\n begin: hljs.UNDERSCORE_IDENT_RE\n },\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [] // defined later\n }\n ]\n };\n const KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;\n KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];\n KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];\n\n return {\n name: 'Kotlin',\n aliases: [ 'kt', 'kts' ],\n keywords: KEYWORDS,\n contains: [\n hljs.COMMENT(\n '/\\\\*\\\\*',\n '\\\\*/',\n {\n relevance: 0,\n contains: [\n {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n }\n ]\n }\n ),\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n KEYWORDS_WITH_LABEL,\n LABEL,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n {\n className: 'function',\n beginKeywords: 'fun',\n end: '[(]|$',\n returnBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n relevance: 5,\n contains: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE + '\\\\s*\\\\(',\n returnBegin: true,\n relevance: 0,\n contains: [ hljs.UNDERSCORE_TITLE_MODE ]\n },\n {\n className: 'type',\n begin: /</,\n end: />/,\n keywords: 'reified',\n relevance: 0\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n endsParent: true,\n keywords: KEYWORDS,\n relevance: 0,\n contains: [\n {\n begin: /:/,\n end: /[=,\\/]/,\n endsWithParent: true,\n contains: [\n KOTLIN_PAREN_TYPE,\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT\n ],\n relevance: 0\n },\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n STRING,\n hljs.C_NUMBER_MODE\n ]\n },\n KOTLIN_NESTED_COMMENT\n ]\n },\n {\n className: 'class',\n beginKeywords: 'class interface trait', // remove 'trait' when removed from KEYWORDS\n end: /[:\\{(]|$/,\n excludeEnd: true,\n illegal: 'extends implements',\n contains: [\n {\n beginKeywords: 'public protected internal private constructor'\n },\n hljs.UNDERSCORE_TITLE_MODE,\n {\n className: 'type',\n begin: /</,\n end: />/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type',\n begin: /[,:]\\s*/,\n end: /[<\\(,]|$/,\n excludeBegin: true,\n returnEnd: true\n },\n ANNOTATION_USE_SITE,\n ANNOTATION\n ]\n },\n STRING,\n {\n className: 'meta',\n begin: \"^#!/usr/bin/env\",\n end: '$',\n illegal: '\\n'\n },\n KOTLIN_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "1c46e9a7742b555e41adfa13a581e000", "score": "0.5091389", "text": "function kotlin(hljs) {\n const KEYWORDS = {\n keyword:\n 'abstract as val var vararg get set class object open private protected public noinline ' +\n 'crossinline dynamic final enum if else do while for when throw try catch finally ' +\n 'import package is in fun override companion reified inline lateinit init ' +\n 'interface annotation data sealed internal infix operator out by constructor super ' +\n 'tailrec where const inner suspend typealias external expect actual',\n built_in:\n 'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',\n literal:\n 'true false null'\n };\n const KEYWORDS_WITH_LABEL = {\n className: 'keyword',\n begin: /\\b(break|continue|return|this)\\b/,\n starts: {\n contains: [\n {\n className: 'symbol',\n begin: /@\\w+/\n }\n ]\n }\n };\n const LABEL = {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '@'\n };\n\n // for string templates\n const SUBST = {\n className: 'subst',\n begin: /\\$\\{/,\n end: /\\}/,\n contains: [ hljs.C_NUMBER_MODE ]\n };\n const VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + hljs.UNDERSCORE_IDENT_RE\n };\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"(?=[^\"])',\n contains: [\n VARIABLE,\n SUBST\n ]\n },\n // Can't use built-in modes easily, as we want to use STRING in the meta\n // context as 'meta-string' and there's no syntax to remove explicitly set\n // classNames in built-in modes.\n {\n begin: '\\'',\n end: '\\'',\n illegal: /\\n/,\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '\"',\n end: '\"',\n illegal: /\\n/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n VARIABLE,\n SUBST\n ]\n }\n ]\n };\n SUBST.contains.push(STRING);\n\n const ANNOTATION_USE_SITE = {\n className: 'meta',\n begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'\n };\n const ANNOTATION = {\n className: 'meta',\n begin: '@' + hljs.UNDERSCORE_IDENT_RE,\n contains: [\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [\n hljs.inherit(STRING, {\n className: 'meta-string'\n })\n ]\n }\n ]\n };\n\n // https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n // According to the doc above, the number mode of kotlin is the same as java 8,\n // so the code below is copied from java.js\n const KOTLIN_NUMBER_MODE = NUMERIC;\n const KOTLIN_NESTED_COMMENT = hljs.COMMENT(\n '/\\\\*', '\\\\*/',\n {\n contains: [ hljs.C_BLOCK_COMMENT_MODE ]\n }\n );\n const KOTLIN_PAREN_TYPE = {\n variants: [\n {\n className: 'type',\n begin: hljs.UNDERSCORE_IDENT_RE\n },\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [] // defined later\n }\n ]\n };\n const KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;\n KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];\n KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];\n\n return {\n name: 'Kotlin',\n aliases: [ 'kt', 'kts' ],\n keywords: KEYWORDS,\n contains: [\n hljs.COMMENT(\n '/\\\\*\\\\*',\n '\\\\*/',\n {\n relevance: 0,\n contains: [\n {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n }\n ]\n }\n ),\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n KEYWORDS_WITH_LABEL,\n LABEL,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n {\n className: 'function',\n beginKeywords: 'fun',\n end: '[(]|$',\n returnBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n relevance: 5,\n contains: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE + '\\\\s*\\\\(',\n returnBegin: true,\n relevance: 0,\n contains: [ hljs.UNDERSCORE_TITLE_MODE ]\n },\n {\n className: 'type',\n begin: /</,\n end: />/,\n keywords: 'reified',\n relevance: 0\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n endsParent: true,\n keywords: KEYWORDS,\n relevance: 0,\n contains: [\n {\n begin: /:/,\n end: /[=,\\/]/,\n endsWithParent: true,\n contains: [\n KOTLIN_PAREN_TYPE,\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT\n ],\n relevance: 0\n },\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n STRING,\n hljs.C_NUMBER_MODE\n ]\n },\n KOTLIN_NESTED_COMMENT\n ]\n },\n {\n className: 'class',\n beginKeywords: 'class interface trait', // remove 'trait' when removed from KEYWORDS\n end: /[:\\{(]|$/,\n excludeEnd: true,\n illegal: 'extends implements',\n contains: [\n {\n beginKeywords: 'public protected internal private constructor'\n },\n hljs.UNDERSCORE_TITLE_MODE,\n {\n className: 'type',\n begin: /</,\n end: />/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type',\n begin: /[,:]\\s*/,\n end: /[<\\(,]|$/,\n excludeBegin: true,\n returnEnd: true\n },\n ANNOTATION_USE_SITE,\n ANNOTATION\n ]\n },\n STRING,\n {\n className: 'meta',\n begin: \"^#!/usr/bin/env\",\n end: '$',\n illegal: '\\n'\n },\n KOTLIN_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "1c46e9a7742b555e41adfa13a581e000", "score": "0.5091389", "text": "function kotlin(hljs) {\n const KEYWORDS = {\n keyword:\n 'abstract as val var vararg get set class object open private protected public noinline ' +\n 'crossinline dynamic final enum if else do while for when throw try catch finally ' +\n 'import package is in fun override companion reified inline lateinit init ' +\n 'interface annotation data sealed internal infix operator out by constructor super ' +\n 'tailrec where const inner suspend typealias external expect actual',\n built_in:\n 'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',\n literal:\n 'true false null'\n };\n const KEYWORDS_WITH_LABEL = {\n className: 'keyword',\n begin: /\\b(break|continue|return|this)\\b/,\n starts: {\n contains: [\n {\n className: 'symbol',\n begin: /@\\w+/\n }\n ]\n }\n };\n const LABEL = {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '@'\n };\n\n // for string templates\n const SUBST = {\n className: 'subst',\n begin: /\\$\\{/,\n end: /\\}/,\n contains: [ hljs.C_NUMBER_MODE ]\n };\n const VARIABLE = {\n className: 'variable',\n begin: '\\\\$' + hljs.UNDERSCORE_IDENT_RE\n };\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"(?=[^\"])',\n contains: [\n VARIABLE,\n SUBST\n ]\n },\n // Can't use built-in modes easily, as we want to use STRING in the meta\n // context as 'meta-string' and there's no syntax to remove explicitly set\n // classNames in built-in modes.\n {\n begin: '\\'',\n end: '\\'',\n illegal: /\\n/,\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '\"',\n end: '\"',\n illegal: /\\n/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n VARIABLE,\n SUBST\n ]\n }\n ]\n };\n SUBST.contains.push(STRING);\n\n const ANNOTATION_USE_SITE = {\n className: 'meta',\n begin: '@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*' + hljs.UNDERSCORE_IDENT_RE + ')?'\n };\n const ANNOTATION = {\n className: 'meta',\n begin: '@' + hljs.UNDERSCORE_IDENT_RE,\n contains: [\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [\n hljs.inherit(STRING, {\n className: 'meta-string'\n })\n ]\n }\n ]\n };\n\n // https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n // According to the doc above, the number mode of kotlin is the same as java 8,\n // so the code below is copied from java.js\n const KOTLIN_NUMBER_MODE = NUMERIC;\n const KOTLIN_NESTED_COMMENT = hljs.COMMENT(\n '/\\\\*', '\\\\*/',\n {\n contains: [ hljs.C_BLOCK_COMMENT_MODE ]\n }\n );\n const KOTLIN_PAREN_TYPE = {\n variants: [\n {\n className: 'type',\n begin: hljs.UNDERSCORE_IDENT_RE\n },\n {\n begin: /\\(/,\n end: /\\)/,\n contains: [] // defined later\n }\n ]\n };\n const KOTLIN_PAREN_TYPE2 = KOTLIN_PAREN_TYPE;\n KOTLIN_PAREN_TYPE2.variants[1].contains = [ KOTLIN_PAREN_TYPE ];\n KOTLIN_PAREN_TYPE.variants[1].contains = [ KOTLIN_PAREN_TYPE2 ];\n\n return {\n name: 'Kotlin',\n aliases: [ 'kt', 'kts' ],\n keywords: KEYWORDS,\n contains: [\n hljs.COMMENT(\n '/\\\\*\\\\*',\n '\\\\*/',\n {\n relevance: 0,\n contains: [\n {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n }\n ]\n }\n ),\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n KEYWORDS_WITH_LABEL,\n LABEL,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n {\n className: 'function',\n beginKeywords: 'fun',\n end: '[(]|$',\n returnBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n relevance: 5,\n contains: [\n {\n begin: hljs.UNDERSCORE_IDENT_RE + '\\\\s*\\\\(',\n returnBegin: true,\n relevance: 0,\n contains: [ hljs.UNDERSCORE_TITLE_MODE ]\n },\n {\n className: 'type',\n begin: /</,\n end: />/,\n keywords: 'reified',\n relevance: 0\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n endsParent: true,\n keywords: KEYWORDS,\n relevance: 0,\n contains: [\n {\n begin: /:/,\n end: /[=,\\/]/,\n endsWithParent: true,\n contains: [\n KOTLIN_PAREN_TYPE,\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT\n ],\n relevance: 0\n },\n hljs.C_LINE_COMMENT_MODE,\n KOTLIN_NESTED_COMMENT,\n ANNOTATION_USE_SITE,\n ANNOTATION,\n STRING,\n hljs.C_NUMBER_MODE\n ]\n },\n KOTLIN_NESTED_COMMENT\n ]\n },\n {\n className: 'class',\n beginKeywords: 'class interface trait', // remove 'trait' when removed from KEYWORDS\n end: /[:\\{(]|$/,\n excludeEnd: true,\n illegal: 'extends implements',\n contains: [\n {\n beginKeywords: 'public protected internal private constructor'\n },\n hljs.UNDERSCORE_TITLE_MODE,\n {\n className: 'type',\n begin: /</,\n end: />/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0\n },\n {\n className: 'type',\n begin: /[,:]\\s*/,\n end: /[<\\(,]|$/,\n excludeBegin: true,\n returnEnd: true\n },\n ANNOTATION_USE_SITE,\n ANNOTATION\n ]\n },\n STRING,\n {\n className: 'meta',\n begin: \"^#!/usr/bin/env\",\n end: '$',\n illegal: '\\n'\n },\n KOTLIN_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "0f775b76eb1828bc68d4557d985bdda5", "score": "0.5071832", "text": "function Main() {\n\n }", "title": "" }, { "docid": "cd3103ec7ca548c69205f04727e3be46", "score": "0.506927", "text": "function python(hljs) {\n var KEYWORDS = {\n keyword:\n 'and elif is global as in if from raise for except finally print import pass return ' +\n 'exec else break not with class assert yield try while continue del or def lambda ' +\n 'async await nonlocal|10',\n built_in:\n 'Ellipsis NotImplemented',\n literal: 'False None True'\n };\n var PROMPT = {\n className: 'meta', begin: /^(>>>|\\.\\.\\.) /\n };\n var SUBST = {\n className: 'subst',\n begin: /\\{/, end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n var LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE],\n variants: [\n {\n begin: /(u|b)?r?'''/, end: /'''/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT],\n relevance: 10\n },\n {\n begin: /(u|b)?r?\"\"\"/, end: /\"\"\"/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT],\n relevance: 10\n },\n {\n begin: /(fr|rf|f)'''/, end: /'''/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /(fr|rf|f)\"\"\"/, end: /\"\"\"/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /(u|r|ur)'/, end: /'/,\n relevance: 10\n },\n {\n begin: /(u|r|ur)\"/, end: /\"/,\n relevance: 10\n },\n {\n begin: /(b|br)'/, end: /'/\n },\n {\n begin: /(b|br)\"/, end: /\"/\n },\n {\n begin: /(fr|rf|f)'/, end: /'/,\n contains: [hljs.BACKSLASH_ESCAPE, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /(fr|rf|f)\"/, end: /\"/,\n contains: [hljs.BACKSLASH_ESCAPE, LITERAL_BRACKET, SUBST]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n var NUMBER = {\n className: 'number', relevance: 0,\n variants: [\n {begin: hljs.BINARY_NUMBER_RE + '[lLjJ]?'},\n {begin: '\\\\b(0o[0-7]+)[lLjJ]?'},\n {begin: hljs.C_NUMBER_RE + '[lLjJ]?'}\n ]\n };\n var PARAMS = {\n className: 'params',\n variants: [\n // Exclude params at functions without params\n {begin: /\\(\\s*\\)/, skip: true, className: null },\n {\n begin: /\\(/, end: /\\)/, excludeBegin: true, excludeEnd: true,\n contains: ['self', PROMPT, NUMBER, STRING, hljs.HASH_COMMENT_MODE],\n },\n ],\n };\n SUBST.contains = [STRING, NUMBER, PROMPT];\n return {\n name: 'Python',\n aliases: ['py', 'gyp', 'ipython'],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string as in:\n { beginKeywords: \"if\", relevance: 0 },\n STRING,\n hljs.HASH_COMMENT_MODE,\n {\n variants: [\n {className: 'function', beginKeywords: 'def'},\n {className: 'class', beginKeywords: 'class'}\n ],\n end: /:/,\n illegal: /[${=;\\n,]/,\n contains: [\n hljs.UNDERSCORE_TITLE_MODE,\n PARAMS,\n {\n begin: /->/, endsWithParent: true,\n keywords: 'None'\n }\n ]\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/, end: /$/\n },\n {\n begin: /\\b(print|exec)\\(/ // don’t highlight keywords-turned-functions in Python 3\n }\n ]\n };\n}", "title": "" }, { "docid": "80d14f0149559a974e5997f8d53d27d6", "score": "0.505344", "text": "function swift(hljs) {\n var SWIFT_KEYWORDS = {\n // override the pattern since the default of of /\\w+/ is not sufficient to\n // capture the keywords that start with the character \"#\"\n $pattern: /[\\w#]+/,\n keyword: '#available #colorLiteral #column #else #elseif #endif #file ' +\n '#fileLiteral #function #if #imageLiteral #line #selector #sourceLocation ' +\n '_ __COLUMN__ __FILE__ __FUNCTION__ __LINE__ Any as as! as? associatedtype ' +\n 'associativity break case catch class continue convenience default defer deinit didSet do ' +\n 'dynamic dynamicType else enum extension fallthrough false fileprivate final for func ' +\n 'get guard if import in indirect infix init inout internal is lazy left let ' +\n 'mutating nil none nonmutating open operator optional override postfix precedence ' +\n 'prefix private protocol Protocol public repeat required rethrows return ' +\n 'right self Self set some static struct subscript super switch throw throws true ' +\n 'try try! try? Type typealias unowned var weak where while willSet',\n literal: 'true false nil',\n built_in: 'abs advance alignof alignofValue anyGenerator assert assertionFailure ' +\n 'bridgeFromObjectiveC bridgeFromObjectiveCUnconditional bridgeToObjectiveC ' +\n 'bridgeToObjectiveCUnconditional c compactMap contains count countElements countLeadingZeros ' +\n 'debugPrint debugPrintln distance dropFirst dropLast dump encodeBitsAsWords ' +\n 'enumerate equal fatalError filter find getBridgedObjectiveCType getVaList ' +\n 'indices insertionSort isBridgedToObjectiveC isBridgedVerbatimToObjectiveC ' +\n 'isUniquelyReferenced isUniquelyReferencedNonObjC join lazy lexicographicalCompare ' +\n 'map max maxElement min minElement numericCast overlaps partition posix ' +\n 'precondition preconditionFailure print println quickSort readLine reduce reflect ' +\n 'reinterpretCast reverse roundUpToAlignment sizeof sizeofValue sort split ' +\n 'startsWith stride strideof strideofValue swap toString transcode ' +\n 'underestimateCount unsafeAddressOf unsafeBitCast unsafeDowncast unsafeUnwrap ' +\n 'unsafeReflect withExtendedLifetime withObjectAtPlusZero withUnsafePointer ' +\n 'withUnsafePointerToObject withUnsafeMutablePointer withUnsafeMutablePointers ' +\n 'withUnsafePointer withUnsafePointers withVaList zip'\n };\n\n var TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*',\n relevance: 0\n };\n // slightly more special to swift\n var OPTIONAL_USING_TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][\\\\w\\u00C0-\\u02B8\\']*[!?]'\n };\n var BLOCK_COMMENT = hljs.COMMENT(\n '/\\\\*',\n '\\\\*/',\n {\n contains: ['self']\n }\n );\n var SUBST = {\n className: 'subst',\n begin: /\\\\\\(/, end: '\\\\)',\n keywords: SWIFT_KEYWORDS,\n contains: [] // assigned later\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /\"\"\"/, end: /\"\"\"/},\n {begin: /\"/, end: /\"/},\n ]\n };\n\n // https://docs.swift.org/swift-book/ReferenceManual/LexicalStructure.html#grammar_numeric-literal\n // TODO: Update for leading `-` after lookbehind is supported everywhere\n var decimalDigits = '([0-9]_*)+';\n var hexDigits = '([0-9a-fA-F]_*)+';\n var NUMBER = {\n className: 'number',\n relevance: 0,\n variants: [\n // decimal floating-point-literal (subsumes decimal-literal)\n { begin: `\\\\b(${decimalDigits})(\\\\.(${decimalDigits}))?` +\n `([eE][+-]?(${decimalDigits}))?\\\\b` },\n\n // hexadecimal floating-point-literal (subsumes hexadecimal-literal)\n { begin: `\\\\b0x(${hexDigits})(\\\\.(${hexDigits}))?` +\n `([pP][+-]?(${decimalDigits}))?\\\\b` },\n\n // octal-literal\n { begin: /\\b0o([0-7]_*)+\\b/ },\n\n // binary-literal\n { begin: /\\b0b([01]_*)+\\b/ },\n ]\n };\n SUBST.contains = [NUMBER];\n\n return {\n name: 'Swift',\n keywords: SWIFT_KEYWORDS,\n contains: [\n STRING,\n hljs.C_LINE_COMMENT_MODE,\n BLOCK_COMMENT,\n OPTIONAL_USING_TYPE,\n TYPE,\n NUMBER,\n {\n className: 'function',\n beginKeywords: 'func', end: /\\{/, excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {\n begin: /[A-Za-z$_][0-9A-Za-z$_]*/\n }),\n {\n begin: /</, end: />/\n },\n {\n className: 'params',\n begin: /\\(/, end: /\\)/, endsParent: true,\n keywords: SWIFT_KEYWORDS,\n contains: [\n 'self',\n NUMBER,\n STRING,\n hljs.C_BLOCK_COMMENT_MODE,\n {begin: ':'} // relevance booster\n ],\n illegal: /[\"']/\n }\n ],\n illegal: /\\[|%/\n },\n {\n className: 'class',\n beginKeywords: 'struct protocol class extension enum',\n keywords: SWIFT_KEYWORDS,\n end: '\\\\{',\n excludeEnd: true,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: /[A-Za-z$_][\\u00C0-\\u02B80-9A-Za-z$_]*/})\n ]\n },\n {\n className: 'meta', // @attributes\n begin: '(@discardableResult|@warn_unused_result|@exported|@lazy|@noescape|' +\n '@NSCopying|@NSManaged|@objc|@objcMembers|@convention|@required|' +\n '@noreturn|@IBAction|@IBDesignable|@IBInspectable|@IBOutlet|' +\n '@infix|@prefix|@postfix|@autoclosure|@testable|@available|' +\n '@nonobjc|@NSApplicationMain|@UIApplicationMain|@dynamicMemberLookup|' +\n '@propertyWrapper|@main)\\\\b'\n\n },\n {\n beginKeywords: 'import', end: /$/,\n contains: [hljs.C_LINE_COMMENT_MODE, BLOCK_COMMENT],\n relevance: 0\n }\n ]\n };\n}", "title": "" }, { "docid": "207460b01ac8d6e7859de333120aa0cb", "score": "0.5049196", "text": "function kotlin(hljs){var KEYWORDS={keyword:'abstract as val var vararg get set class object open private protected public noinline '+'crossinline dynamic final enum if else do while for when throw try catch finally '+'import package is in fun override companion reified inline lateinit init '+'interface annotation data sealed internal infix operator out by constructor super '+'tailrec where const inner suspend typealias external expect actual',built_in:'Byte Short Char Int Long Boolean Float Double Void Unit Nothing',literal:'true false null'};var KEYWORDS_WITH_LABEL={className:'keyword',begin:/\\b(break|continue|return|this)\\b/,starts:{contains:[{className:'symbol',begin:/@\\w+/}]}};var LABEL={className:'symbol',begin:hljs.UNDERSCORE_IDENT_RE+'@'};// for string templates\nvar SUBST={className:'subst',begin:/\\$\\{/,end:/\\}/,contains:[hljs.C_NUMBER_MODE]};var VARIABLE={className:'variable',begin:'\\\\$'+hljs.UNDERSCORE_IDENT_RE};var STRING={className:'string',variants:[{begin:'\"\"\"',end:'\"\"\"(?=[^\"])',contains:[VARIABLE,SUBST]},// Can't use built-in modes easily, as we want to use STRING in the meta\n// context as 'meta-string' and there's no syntax to remove explicitly set\n// classNames in built-in modes.\n{begin:'\\'',end:'\\'',illegal:/\\n/,contains:[hljs.BACKSLASH_ESCAPE]},{begin:'\"',end:'\"',illegal:/\\n/,contains:[hljs.BACKSLASH_ESCAPE,VARIABLE,SUBST]}]};SUBST.contains.push(STRING);var ANNOTATION_USE_SITE={className:'meta',begin:'@(?:file|property|field|get|set|receiver|param|setparam|delegate)\\\\s*:(?:\\\\s*'+hljs.UNDERSCORE_IDENT_RE+')?'};var ANNOTATION={className:'meta',begin:'@'+hljs.UNDERSCORE_IDENT_RE,contains:[{begin:/\\(/,end:/\\)/,contains:[hljs.inherit(STRING,{className:'string'})]}]};// https://kotlinlang.org/docs/reference/whatsnew11.html#underscores-in-numeric-literals\n// According to the doc above, the number mode of kotlin is the same as java 8,\n// so the code below is copied from java.js\nvar KOTLIN_NUMBER_MODE=NUMERIC;var KOTLIN_NESTED_COMMENT=hljs.COMMENT('/\\\\*','\\\\*/',{contains:[hljs.C_BLOCK_COMMENT_MODE]});var KOTLIN_PAREN_TYPE={variants:[{className:'type',begin:hljs.UNDERSCORE_IDENT_RE},{begin:/\\(/,end:/\\)/,contains:[]// defined later\n}]};var KOTLIN_PAREN_TYPE2=KOTLIN_PAREN_TYPE;KOTLIN_PAREN_TYPE2.variants[1].contains=[KOTLIN_PAREN_TYPE];KOTLIN_PAREN_TYPE.variants[1].contains=[KOTLIN_PAREN_TYPE2];return{name:'Kotlin',aliases:['kt','kts'],keywords:KEYWORDS,contains:[hljs.COMMENT('/\\\\*\\\\*','\\\\*/',{relevance:0,contains:[{className:'doctag',begin:'@[A-Za-z]+'}]}),hljs.C_LINE_COMMENT_MODE,KOTLIN_NESTED_COMMENT,KEYWORDS_WITH_LABEL,LABEL,ANNOTATION_USE_SITE,ANNOTATION,{className:'function',beginKeywords:'fun',end:'[(]|$',returnBegin:true,excludeEnd:true,keywords:KEYWORDS,relevance:5,contains:[{begin:hljs.UNDERSCORE_IDENT_RE+'\\\\s*\\\\(',returnBegin:true,relevance:0,contains:[hljs.UNDERSCORE_TITLE_MODE]},{className:'type',begin:/</,end:/>/,keywords:'reified',relevance:0},{className:'params',begin:/\\(/,end:/\\)/,endsParent:true,keywords:KEYWORDS,relevance:0,contains:[{begin:/:/,end:/[=,\\/]/,endsWithParent:true,contains:[KOTLIN_PAREN_TYPE,hljs.C_LINE_COMMENT_MODE,KOTLIN_NESTED_COMMENT],relevance:0},hljs.C_LINE_COMMENT_MODE,KOTLIN_NESTED_COMMENT,ANNOTATION_USE_SITE,ANNOTATION,STRING,hljs.C_NUMBER_MODE]},KOTLIN_NESTED_COMMENT]},{className:'class',beginKeywords:'class interface trait',// remove 'trait' when removed from KEYWORDS\nend:/[:\\{(]|$/,excludeEnd:true,illegal:'extends implements',contains:[{beginKeywords:'public protected internal private constructor'},hljs.UNDERSCORE_TITLE_MODE,{className:'type',begin:/</,end:/>/,excludeBegin:true,excludeEnd:true,relevance:0},{className:'type',begin:/[,:]\\s*/,end:/[<\\(,]|$/,excludeBegin:true,returnEnd:true},ANNOTATION_USE_SITE,ANNOTATION]},STRING,{className:'meta',begin:\"^#!/usr/bin/env\",end:'$',illegal:'\\n'},KOTLIN_NUMBER_MODE]};}", "title": "" }, { "docid": "c8eb13277c443e55ecfbdc4d32776610", "score": "0.5048404", "text": "function Main()\n {\n \n }", "title": "" }, { "docid": "f6117ee6fe9268339a9a05db27d6c9b1", "score": "0.50452405", "text": "function python(hljs) {\n const RESERVED_WORDS = [\n 'and',\n 'as',\n 'assert',\n 'async',\n 'await',\n 'break',\n 'class',\n 'continue',\n 'def',\n 'del',\n 'elif',\n 'else',\n 'except',\n 'finally',\n 'for',\n 'from',\n 'global',\n 'if',\n 'import',\n 'in',\n 'is',\n 'lambda',\n 'nonlocal|10',\n 'not',\n 'or',\n 'pass',\n 'raise',\n 'return',\n 'try',\n 'while',\n 'with',\n 'yield'\n ];\n\n const BUILT_INS = [\n '__import__',\n 'abs',\n 'all',\n 'any',\n 'ascii',\n 'bin',\n 'bool',\n 'breakpoint',\n 'bytearray',\n 'bytes',\n 'callable',\n 'chr',\n 'classmethod',\n 'compile',\n 'complex',\n 'delattr',\n 'dict',\n 'dir',\n 'divmod',\n 'enumerate',\n 'eval',\n 'exec',\n 'filter',\n 'float',\n 'format',\n 'frozenset',\n 'getattr',\n 'globals',\n 'hasattr',\n 'hash',\n 'help',\n 'hex',\n 'id',\n 'input',\n 'int',\n 'isinstance',\n 'issubclass',\n 'iter',\n 'len',\n 'list',\n 'locals',\n 'map',\n 'max',\n 'memoryview',\n 'min',\n 'next',\n 'object',\n 'oct',\n 'open',\n 'ord',\n 'pow',\n 'print',\n 'property',\n 'range',\n 'repr',\n 'reversed',\n 'round',\n 'set',\n 'setattr',\n 'slice',\n 'sorted',\n 'staticmethod',\n 'str',\n 'sum',\n 'super',\n 'tuple',\n 'type',\n 'vars',\n 'zip'\n ];\n\n const LITERALS = [\n '__debug__',\n 'Ellipsis',\n 'False',\n 'None',\n 'NotImplemented',\n 'True'\n ];\n\n // https://docs.python.org/3/library/typing.html\n // TODO: Could these be supplemented by a CamelCase matcher in certain\n // contexts, leaving these remaining only for relevance hinting?\n const TYPES = [\n \"Any\",\n \"Callable\",\n \"Coroutine\",\n \"Dict\",\n \"List\",\n \"Literal\",\n \"Generic\",\n \"Optional\",\n \"Sequence\",\n \"Set\",\n \"Tuple\",\n \"Type\",\n \"Union\"\n ];\n\n const KEYWORDS = {\n $pattern: /[A-Za-z]\\w+|__\\w+__/,\n keyword: RESERVED_WORDS,\n built_in: BUILT_INS,\n literal: LITERALS,\n type: TYPES\n };\n\n const PROMPT = {\n className: 'meta',\n begin: /^(>>>|\\.\\.\\.) /\n };\n\n const SUBST = {\n className: 'subst',\n begin: /\\{/,\n end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n\n const LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n\n const STRING = {\n className: 'string',\n contains: [ hljs.BACKSLASH_ESCAPE ],\n variants: [\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT\n ],\n relevance: 10\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'''/,\n end: /'''/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"\"\"/,\n end: /\"\"\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n PROMPT,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([uU]|[rR])'/,\n end: /'/,\n relevance: 10\n },\n {\n begin: /([uU]|[rR])\"/,\n end: /\"/,\n relevance: 10\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])'/,\n end: /'/\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])\"/,\n end: /\"/\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'/,\n end: /'/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"/,\n end: /\"/,\n contains: [\n hljs.BACKSLASH_ESCAPE,\n LITERAL_BRACKET,\n SUBST\n ]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n\n // https://docs.python.org/3.9/reference/lexical_analysis.html#numeric-literals\n const digitpart = '[0-9](_?[0-9])*';\n const pointfloat = `(\\\\b(${digitpart}))?\\\\.(${digitpart})|\\\\b(${digitpart})\\\\.`;\n const NUMBER = {\n className: 'number',\n relevance: 0,\n variants: [\n // exponentfloat, pointfloat\n // https://docs.python.org/3.9/reference/lexical_analysis.html#floating-point-literals\n // optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n // Note: no leading \\b because floats can start with a decimal point\n // and we don't want to mishandle e.g. `fn(.5)`,\n // no trailing \\b for pointfloat because it can end with a decimal point\n // and we don't want to mishandle e.g. `0..hex()`; this should be safe\n // because both MUST contain a decimal point and so cannot be confused with\n // the interior part of an identifier\n {\n begin: `(\\\\b(${digitpart})|(${pointfloat}))[eE][+-]?(${digitpart})[jJ]?\\\\b`\n },\n {\n begin: `(${pointfloat})[jJ]?`\n },\n\n // decinteger, bininteger, octinteger, hexinteger\n // https://docs.python.org/3.9/reference/lexical_analysis.html#integer-literals\n // optionally \"long\" in Python 2\n // https://docs.python.org/2.7/reference/lexical_analysis.html#integer-and-long-integer-literals\n // decinteger is optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: '\\\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?\\\\b'\n },\n {\n begin: '\\\\b0[bB](_?[01])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[oO](_?[0-7])+[lL]?\\\\b'\n },\n {\n begin: '\\\\b0[xX](_?[0-9a-fA-F])+[lL]?\\\\b'\n },\n\n // imagnumber (digitpart-based)\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n {\n begin: `\\\\b(${digitpart})[jJ]\\\\b`\n }\n ]\n };\n const COMMENT_TYPE = {\n className: \"comment\",\n begin: lookahead(/# type:/),\n end: /$/,\n keywords: KEYWORDS,\n contains: [\n { // prevent keywords from coloring `type`\n begin: /# type:/\n },\n // comment within a datatype comment includes no keywords\n {\n begin: /#/,\n end: /\\b\\B/,\n endsWithParent: true\n }\n ]\n };\n const PARAMS = {\n className: 'params',\n variants: [\n // Exclude params in functions without params\n {\n className: \"\",\n begin: /\\(\\s*\\)/,\n skip: true\n },\n {\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n keywords: KEYWORDS,\n contains: [\n 'self',\n PROMPT,\n NUMBER,\n STRING,\n hljs.HASH_COMMENT_MODE\n ]\n }\n ]\n };\n SUBST.contains = [\n STRING,\n NUMBER,\n PROMPT\n ];\n\n return {\n name: 'Python',\n aliases: [\n 'py',\n 'gyp',\n 'ipython'\n ],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n {\n // very common convention\n begin: /\\bself\\b/\n },\n {\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string\n beginKeywords: \"if\",\n relevance: 0\n },\n STRING,\n COMMENT_TYPE,\n hljs.HASH_COMMENT_MODE,\n {\n match: [\n /def/, /\\s+/,\n UNDERSCORE_IDENT_RE\n ],\n scope: {\n 1: \"keyword\",\n 3: \"title.function\"\n },\n contains: [ PARAMS ]\n },\n {\n variants: [\n {\n match: [\n /class/, /\\s+/,\n UNDERSCORE_IDENT_RE, /\\s*/,\n /\\(\\s*/, UNDERSCORE_IDENT_RE,/\\s*\\)/\n ],\n },\n {\n match: [\n /class/, /\\s+/,\n UNDERSCORE_IDENT_RE\n ],\n }\n ],\n scope: {\n 1: \"keyword\",\n 3: \"title.class\",\n 6: \"title.class.inherited\",\n }\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/,\n end: /(?=#)|$/,\n contains: [\n NUMBER,\n PARAMS,\n STRING\n ]\n }\n ]\n };\n }", "title": "" }, { "docid": "319a1e521665e41775627c30d3a6a989", "score": "0.50322163", "text": "function python(hljs) {\n const RESERVED_WORDS = [\n 'and',\n 'as',\n 'assert',\n 'async',\n 'await',\n 'break',\n 'class',\n 'continue',\n 'def',\n 'del',\n 'elif',\n 'else',\n 'except',\n 'finally',\n 'for',\n '',\n 'from',\n 'global',\n 'if',\n 'import',\n 'in',\n 'is',\n 'lambda',\n 'nonlocal|10',\n 'not',\n 'or',\n 'pass',\n 'raise',\n 'return',\n 'try',\n 'while',\n 'with',\n 'yield',\n ];\n\n const BUILT_INS = [\n '__import__',\n 'abs',\n 'all',\n 'any',\n 'ascii',\n 'bin',\n 'bool',\n 'breakpoint',\n 'bytearray',\n 'bytes',\n 'callable',\n 'chr',\n 'classmethod',\n 'compile',\n 'complex',\n 'delattr',\n 'dict',\n 'dir',\n 'divmod',\n 'enumerate',\n 'eval',\n 'exec',\n 'filter',\n 'float',\n 'format',\n 'frozenset',\n 'getattr',\n 'globals',\n 'hasattr',\n 'hash',\n 'help',\n 'hex',\n 'id',\n 'input',\n 'int',\n 'isinstance',\n 'issubclass',\n 'iter',\n 'len',\n 'list',\n 'locals',\n 'map',\n 'max',\n 'memoryview',\n 'min',\n 'next',\n 'object',\n 'oct',\n 'open',\n 'ord',\n 'pow',\n 'print',\n 'property',\n 'range',\n 'repr',\n 'reversed',\n 'round',\n 'set',\n 'setattr',\n 'slice',\n 'sorted',\n 'staticmethod',\n 'str',\n 'sum',\n 'super',\n 'tuple',\n 'type',\n 'vars',\n 'zip',\n ];\n\n const LITERALS = [\n '__debug__',\n 'Ellipsis',\n 'False',\n 'None',\n 'NotImplemented',\n 'True',\n ];\n\n const KEYWORDS = {\n keyword: RESERVED_WORDS.join(' '),\n built_in: BUILT_INS.join(' '),\n literal: LITERALS.join(' ')\n };\n\n const PROMPT = {\n className: 'meta', begin: /^(>>>|\\.\\.\\.) /\n };\n\n const SUBST = {\n className: 'subst',\n begin: /\\{/, end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n\n const LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n\n const STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE],\n variants: [\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/, end: /'''/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT],\n relevance: 10\n },\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?\"\"\"/, end: /\"\"\"/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT],\n relevance: 10\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'''/, end: /'''/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"\"\"/, end: /\"\"\"/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /([uU]|[rR])'/, end: /'/,\n relevance: 10\n },\n {\n begin: /([uU]|[rR])\"/, end: /\"/,\n relevance: 10\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])'/, end: /'/\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])\"/, end: /\"/\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'/, end: /'/,\n contains: [hljs.BACKSLASH_ESCAPE, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"/, end: /\"/,\n contains: [hljs.BACKSLASH_ESCAPE, LITERAL_BRACKET, SUBST]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n\n const NUMBER = {\n className: 'number', relevance: 0,\n variants: [\n {begin: hljs.BINARY_NUMBER_RE + '[lLjJ]?'},\n {begin: '\\\\b(0o[0-7]+)[lLjJ]?'},\n {begin: hljs.C_NUMBER_RE + '[lLjJ]?'}\n ]\n };\n\n const PARAMS = {\n className: 'params',\n variants: [\n // Exclude params at functions without params\n {begin: /\\(\\s*\\)/, skip: true, className: null },\n {\n begin: /\\(/, end: /\\)/, excludeBegin: true, excludeEnd: true,\n keywords: KEYWORDS,\n contains: ['self', PROMPT, NUMBER, STRING, hljs.HASH_COMMENT_MODE],\n },\n ],\n };\n SUBST.contains = [STRING, NUMBER, PROMPT];\n\n return {\n name: 'Python',\n aliases: ['py', 'gyp', 'ipython'],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string as in:\n { beginKeywords: \"if\", relevance: 0 },\n STRING,\n hljs.HASH_COMMENT_MODE,\n {\n variants: [\n {className: 'function', beginKeywords: 'def'},\n {className: 'class', beginKeywords: 'class'}\n ],\n end: /:/,\n illegal: /[${=;\\n,]/,\n contains: [\n hljs.UNDERSCORE_TITLE_MODE,\n PARAMS,\n {\n begin: /->/, endsWithParent: true,\n keywords: 'None'\n }\n ]\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/, end: /$/\n },\n {\n begin: /\\b(print|exec)\\(/ // don’t highlight keywords-turned-functions in Python 3\n }\n ]\n };\n}", "title": "" }, { "docid": "50153a3270c10b5a30463176e7c99e31", "score": "0.50322163", "text": "function python(hljs) {\n const RESERVED_WORDS = [\n 'and',\n 'as',\n 'assert',\n 'async',\n 'await',\n 'break',\n 'class',\n 'continue',\n 'def',\n 'del',\n 'elif',\n 'else',\n 'except',\n 'finally',\n 'for',\n '',\n 'from',\n 'global',\n 'if',\n 'import',\n 'in',\n 'is',\n 'lambda',\n 'nonlocal|10',\n 'not',\n 'or',\n 'pass',\n 'raise',\n 'return',\n 'try',\n 'while',\n 'with',\n 'yield',\n ];\n\n const BUILT_INS = [\n '__import__',\n 'abs',\n 'all',\n 'any',\n 'ascii',\n 'bin',\n 'bool',\n 'breakpoint',\n 'bytearray',\n 'bytes',\n 'callable',\n 'chr',\n 'classmethod',\n 'compile',\n 'complex',\n 'delattr',\n 'dict',\n 'dir',\n 'divmod',\n 'enumerate',\n 'eval',\n 'exec',\n 'filter',\n 'float',\n 'format',\n 'frozenset',\n 'getattr',\n 'globals',\n 'hasattr',\n 'hash',\n 'help',\n 'hex',\n 'id',\n 'input',\n 'int',\n 'isinstance',\n 'issubclass',\n 'iter',\n 'len',\n 'list',\n 'locals',\n 'map',\n 'max',\n 'memoryview',\n 'min',\n 'next',\n 'object',\n 'oct',\n 'open',\n 'ord',\n 'pow',\n 'print',\n 'property',\n 'range',\n 'repr',\n 'reversed',\n 'round',\n 'set',\n 'setattr',\n 'slice',\n 'sorted',\n 'staticmethod',\n 'str',\n 'sum',\n 'super',\n 'tuple',\n 'type',\n 'vars',\n 'zip',\n ];\n\n const LITERALS = [\n '__debug__',\n 'Ellipsis',\n 'False',\n 'None',\n 'NotImplemented',\n 'True',\n ];\n\n const KEYWORDS = {\n keyword: RESERVED_WORDS.join(' '),\n built_in: BUILT_INS.join(' '),\n literal: LITERALS.join(' ')\n };\n\n const PROMPT = {\n className: 'meta', begin: /^(>>>|\\.\\.\\.) /\n };\n\n const SUBST = {\n className: 'subst',\n begin: /\\{/, end: /\\}/,\n keywords: KEYWORDS,\n illegal: /#/\n };\n\n const LITERAL_BRACKET = {\n begin: /\\{\\{/,\n relevance: 0\n };\n\n const STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE],\n variants: [\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?'''/, end: /'''/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT],\n relevance: 10\n },\n {\n begin: /([uU]|[bB]|[rR]|[bB][rR]|[rR][bB])?\"\"\"/, end: /\"\"\"/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT],\n relevance: 10\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'''/, end: /'''/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"\"\"/, end: /\"\"\"/,\n contains: [hljs.BACKSLASH_ESCAPE, PROMPT, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /([uU]|[rR])'/, end: /'/,\n relevance: 10\n },\n {\n begin: /([uU]|[rR])\"/, end: /\"/,\n relevance: 10\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])'/, end: /'/\n },\n {\n begin: /([bB]|[bB][rR]|[rR][bB])\"/, end: /\"/\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])'/, end: /'/,\n contains: [hljs.BACKSLASH_ESCAPE, LITERAL_BRACKET, SUBST]\n },\n {\n begin: /([fF][rR]|[rR][fF]|[fF])\"/, end: /\"/,\n contains: [hljs.BACKSLASH_ESCAPE, LITERAL_BRACKET, SUBST]\n },\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE\n ]\n };\n\n // https://docs.python.org/3.9/reference/lexical_analysis.html#numeric-literals\n const digitpart = '[0-9](_?[0-9])*';\n const pointfloat = `(\\\\b(${digitpart}))?\\\\.(${digitpart})|\\\\b(${digitpart})\\\\.`;\n const NUMBER = {\n className: 'number', relevance: 0,\n variants: [\n // exponentfloat, pointfloat\n // https://docs.python.org/3.9/reference/lexical_analysis.html#floating-point-literals\n // optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n // Note: no leading \\b because floats can start with a decimal point\n // and we don't want to mishandle e.g. `fn(.5)`,\n // no trailing \\b for pointfloat because it can end with a decimal point\n // and we don't want to mishandle e.g. `0..hex()`; this should be safe\n // because both MUST contain a decimal point and so cannot be confused with\n // the interior part of an identifier\n { begin: `(\\\\b(${digitpart})|(${pointfloat}))[eE][+-]?(${digitpart})[jJ]?\\\\b` },\n { begin: `(${pointfloat})[jJ]?` },\n\n // decinteger, bininteger, octinteger, hexinteger\n // https://docs.python.org/3.9/reference/lexical_analysis.html#integer-literals\n // optionally \"long\" in Python 2\n // https://docs.python.org/2.7/reference/lexical_analysis.html#integer-and-long-integer-literals\n // decinteger is optionally imaginary\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n { begin: '\\\\b([1-9](_?[0-9])*|0+(_?0)*)[lLjJ]?\\\\b' },\n { begin: '\\\\b0[bB](_?[01])+[lL]?\\\\b' },\n { begin: '\\\\b0[oO](_?[0-7])+[lL]?\\\\b' },\n { begin: '\\\\b0[xX](_?[0-9a-fA-F])+[lL]?\\\\b' },\n\n // imagnumber (digitpart-based)\n // https://docs.python.org/3.9/reference/lexical_analysis.html#imaginary-literals\n { begin: `\\\\b(${digitpart})[jJ]\\\\b` },\n ]\n };\n\n const PARAMS = {\n className: 'params',\n variants: [\n // Exclude params at functions without params\n {begin: /\\(\\s*\\)/, skip: true, className: null },\n {\n begin: /\\(/, end: /\\)/, excludeBegin: true, excludeEnd: true,\n keywords: KEYWORDS,\n contains: ['self', PROMPT, NUMBER, STRING, hljs.HASH_COMMENT_MODE],\n },\n ],\n };\n SUBST.contains = [STRING, NUMBER, PROMPT];\n\n return {\n name: 'Python',\n aliases: ['py', 'gyp', 'ipython'],\n keywords: KEYWORDS,\n illegal: /(<\\/|->|\\?)|=>/,\n contains: [\n PROMPT,\n NUMBER,\n // eat \"if\" prior to string so that it won't accidentally be\n // labeled as an f-string as in:\n { begin: /\\bself\\b/, }, // very common convention\n { beginKeywords: \"if\", relevance: 0 },\n STRING,\n hljs.HASH_COMMENT_MODE,\n {\n variants: [\n {className: 'function', beginKeywords: 'def'},\n {className: 'class', beginKeywords: 'class'}\n ],\n end: /:/,\n illegal: /[${=;\\n,]/,\n contains: [\n hljs.UNDERSCORE_TITLE_MODE,\n PARAMS,\n {\n begin: /->/, endsWithParent: true,\n keywords: 'None'\n }\n ]\n },\n {\n className: 'meta',\n begin: /^[\\t ]*@/, end: /(?=#)|$/,\n contains: [NUMBER, PARAMS, STRING]\n },\n {\n begin: /\\b(print|exec)\\(/ // don’t highlight keywords-turned-functions in Python 3\n }\n ]\n };\n}", "title": "" }, { "docid": "20e7761e7e6cc489984b2fe4a82b9368", "score": "0.502479", "text": "function AST( obj ){\n \n}", "title": "" }, { "docid": "e3c6115869c0a5119fa949724923b037", "score": "0.5021933", "text": "function Main() {\n\n}", "title": "" }, { "docid": "2cb978a1d86676d5977e94b9b15d7b25", "score": "0.49692535", "text": "function initViz(){\n /*** Original ActionScript ***\n \n #include \"../../../AS2Bridge/AS2Bridge.as\"\n *** End Original ActionScript ***/\n }", "title": "" }, { "docid": "2cb978a1d86676d5977e94b9b15d7b25", "score": "0.49692535", "text": "function initViz(){\n /*** Original ActionScript ***\n \n #include \"../../../AS2Bridge/AS2Bridge.as\"\n *** End Original ActionScript ***/\n }", "title": "" }, { "docid": "47ab8516583f92ec3581c46459773ff4", "score": "0.4952955", "text": "function load(scene, source){\n var object = evalcx(source, runtime);\n if (typeof object != 'function')\n throw \"return value of script must be function(also an object)\";\n var fc = 0;\n for(var n in object){\n if (n == 'prototype') continue;\n if (typeof object[n] != 'function')\n\t throw \"return value of script the property \"+n+\" must be function\";\n else\n\t fc++;\n }\n if (fc == 0)\n throw \"return value of script does not defined any property\";\n code[scene] = object;\n }", "title": "" }, { "docid": "1b76eeda477659a97ec1bfe7bd97e92a", "score": "0.49318248", "text": "function Example() {}", "title": "" }, { "docid": "0f4c5d2e3da2920bed9ecd34a05ac19a", "score": "0.4898242", "text": "function clojure(hljs) {\n var SYMBOLSTART = 'a-zA-Z_\\\\-!.?+*=<>&#\\'';\n var SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';\n var globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';\n var keywords = {\n $pattern: SYMBOL_RE,\n 'builtin-name':\n // Clojure keywords\n globals + ' ' +\n 'cond apply if-not if-let if not not= = < > <= >= == + / * - rem ' +\n 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? ' +\n 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? ' +\n 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? ' +\n 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . ' +\n 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last ' +\n 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate ' +\n 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext ' +\n 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends ' +\n 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler ' +\n 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter ' +\n 'monitor-exit macroexpand macroexpand-1 for dosync and or ' +\n 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert ' +\n 'peek pop doto proxy first rest cons cast coll last butlast ' +\n 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import ' +\n 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! ' +\n 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger ' +\n 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline ' +\n 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking ' +\n 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! ' +\n 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ' +\n 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty ' +\n 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list ' +\n 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer ' +\n 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate ' +\n 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta ' +\n 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'\n };\n\n var SIMPLE_NUMBER_RE = '[-+]?\\\\d+(\\\\.\\\\d+)?';\n\n var SYMBOL = {\n begin: SYMBOL_RE,\n relevance: 0\n };\n var NUMBER = {\n className: 'number', begin: SIMPLE_NUMBER_RE,\n relevance: 0\n };\n var STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {illegal: null});\n var COMMENT = hljs.COMMENT(\n ';',\n '$',\n {\n relevance: 0\n }\n );\n var LITERAL = {\n className: 'literal',\n begin: /\\b(true|false|nil)\\b/\n };\n var COLLECTION = {\n begin: '[\\\\[\\\\{]', end: '[\\\\]\\\\}]'\n };\n var HINT = {\n className: 'comment',\n begin: '\\\\^' + SYMBOL_RE\n };\n var HINT_COL = hljs.COMMENT('\\\\^\\\\{', '\\\\}');\n var KEY = {\n className: 'symbol',\n begin: '[:]{1,2}' + SYMBOL_RE\n };\n var LIST = {\n begin: '\\\\(', end: '\\\\)'\n };\n var BODY = {\n endsWithParent: true,\n relevance: 0\n };\n var NAME = {\n keywords: keywords,\n className: 'name', begin: SYMBOL_RE,\n starts: BODY\n };\n var DEFAULT_CONTAINS = [LIST, STRING, HINT, HINT_COL, COMMENT, KEY, COLLECTION, NUMBER, LITERAL, SYMBOL];\n\n var GLOBAL = {\n beginKeywords: globals,\n lexemes: SYMBOL_RE,\n end: '(\\\\[|\\\\#|\\\\d|\"|:|\\\\{|\\\\)|\\\\(|$)',\n contains: [\n {\n className: 'title',\n begin: SYMBOL_RE,\n relevance: 0,\n excludeEnd: true,\n // we can only have a single title\n endsParent: true\n },\n ].concat(DEFAULT_CONTAINS)\n };\n\n LIST.contains = [hljs.COMMENT('comment', ''), GLOBAL, NAME, BODY];\n BODY.contains = DEFAULT_CONTAINS;\n COLLECTION.contains = DEFAULT_CONTAINS;\n HINT_COL.contains = [COLLECTION];\n\n return {\n name: 'Clojure',\n aliases: ['clj'],\n illegal: /\\S/,\n contains: [LIST, STRING, HINT, HINT_COL, COMMENT, KEY, COLLECTION, NUMBER, LITERAL]\n };\n}", "title": "" }, { "docid": "0f4c5d2e3da2920bed9ecd34a05ac19a", "score": "0.4898242", "text": "function clojure(hljs) {\n var SYMBOLSTART = 'a-zA-Z_\\\\-!.?+*=<>&#\\'';\n var SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';\n var globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';\n var keywords = {\n $pattern: SYMBOL_RE,\n 'builtin-name':\n // Clojure keywords\n globals + ' ' +\n 'cond apply if-not if-let if not not= = < > <= >= == + / * - rem ' +\n 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? ' +\n 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? ' +\n 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? ' +\n 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . ' +\n 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last ' +\n 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate ' +\n 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext ' +\n 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends ' +\n 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler ' +\n 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter ' +\n 'monitor-exit macroexpand macroexpand-1 for dosync and or ' +\n 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert ' +\n 'peek pop doto proxy first rest cons cast coll last butlast ' +\n 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import ' +\n 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! ' +\n 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger ' +\n 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline ' +\n 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking ' +\n 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! ' +\n 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ' +\n 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty ' +\n 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list ' +\n 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer ' +\n 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate ' +\n 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta ' +\n 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'\n };\n\n var SIMPLE_NUMBER_RE = '[-+]?\\\\d+(\\\\.\\\\d+)?';\n\n var SYMBOL = {\n begin: SYMBOL_RE,\n relevance: 0\n };\n var NUMBER = {\n className: 'number', begin: SIMPLE_NUMBER_RE,\n relevance: 0\n };\n var STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {illegal: null});\n var COMMENT = hljs.COMMENT(\n ';',\n '$',\n {\n relevance: 0\n }\n );\n var LITERAL = {\n className: 'literal',\n begin: /\\b(true|false|nil)\\b/\n };\n var COLLECTION = {\n begin: '[\\\\[\\\\{]', end: '[\\\\]\\\\}]'\n };\n var HINT = {\n className: 'comment',\n begin: '\\\\^' + SYMBOL_RE\n };\n var HINT_COL = hljs.COMMENT('\\\\^\\\\{', '\\\\}');\n var KEY = {\n className: 'symbol',\n begin: '[:]{1,2}' + SYMBOL_RE\n };\n var LIST = {\n begin: '\\\\(', end: '\\\\)'\n };\n var BODY = {\n endsWithParent: true,\n relevance: 0\n };\n var NAME = {\n keywords: keywords,\n className: 'name', begin: SYMBOL_RE,\n starts: BODY\n };\n var DEFAULT_CONTAINS = [LIST, STRING, HINT, HINT_COL, COMMENT, KEY, COLLECTION, NUMBER, LITERAL, SYMBOL];\n\n var GLOBAL = {\n beginKeywords: globals,\n lexemes: SYMBOL_RE,\n end: '(\\\\[|\\\\#|\\\\d|\"|:|\\\\{|\\\\)|\\\\(|$)',\n contains: [\n {\n className: 'title',\n begin: SYMBOL_RE,\n relevance: 0,\n excludeEnd: true,\n // we can only have a single title\n endsParent: true\n },\n ].concat(DEFAULT_CONTAINS)\n };\n\n LIST.contains = [hljs.COMMENT('comment', ''), GLOBAL, NAME, BODY];\n BODY.contains = DEFAULT_CONTAINS;\n COLLECTION.contains = DEFAULT_CONTAINS;\n HINT_COL.contains = [COLLECTION];\n\n return {\n name: 'Clojure',\n aliases: ['clj'],\n illegal: /\\S/,\n contains: [LIST, STRING, HINT, HINT_COL, COMMENT, KEY, COLLECTION, NUMBER, LITERAL]\n };\n}", "title": "" }, { "docid": "efed3ef69bfacd90a1fe445ee337a1f9", "score": "0.48906437", "text": "function clojure(hljs) {\n var SYMBOLSTART = 'a-zA-Z_\\\\-!.?+*=<>&#\\'';\n var SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';\n var globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';\n var keywords = {\n $pattern: SYMBOL_RE,\n 'builtin-name':\n // Clojure keywords\n globals + ' ' +\n 'cond apply if-not if-let if not not= =|0 <|0 >|0 <=|0 >=|0 ==|0 +|0 /|0 *|0 -|0 rem ' +\n 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? ' +\n 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? ' +\n 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? ' +\n 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . ' +\n 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last ' +\n 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate ' +\n 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext ' +\n 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends ' +\n 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler ' +\n 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter ' +\n 'monitor-exit macroexpand macroexpand-1 for dosync and or ' +\n 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert ' +\n 'peek pop doto proxy first rest cons cast coll last butlast ' +\n 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import ' +\n 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! ' +\n 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger ' +\n 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline ' +\n 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking ' +\n 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! ' +\n 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ' +\n 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty ' +\n 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list ' +\n 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer ' +\n 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate ' +\n 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta ' +\n 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'\n };\n\n var SIMPLE_NUMBER_RE = '[-+]?\\\\d+(\\\\.\\\\d+)?';\n\n var SYMBOL = {\n begin: SYMBOL_RE,\n relevance: 0\n };\n var NUMBER = {\n className: 'number', begin: SIMPLE_NUMBER_RE,\n relevance: 0\n };\n var STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {illegal: null});\n var COMMENT = hljs.COMMENT(\n ';',\n '$',\n {\n relevance: 0\n }\n );\n var LITERAL = {\n className: 'literal',\n begin: /\\b(true|false|nil)\\b/\n };\n var COLLECTION = {\n begin: '[\\\\[\\\\{]', end: '[\\\\]\\\\}]'\n };\n var HINT = {\n className: 'comment',\n begin: '\\\\^' + SYMBOL_RE\n };\n var HINT_COL = hljs.COMMENT('\\\\^\\\\{', '\\\\}');\n var KEY = {\n className: 'symbol',\n begin: '[:]{1,2}' + SYMBOL_RE\n };\n var LIST = {\n begin: '\\\\(', end: '\\\\)'\n };\n var BODY = {\n endsWithParent: true,\n relevance: 0\n };\n var NAME = {\n keywords: keywords,\n className: 'name',\n begin: SYMBOL_RE,\n relevance: 0,\n starts: BODY\n };\n var DEFAULT_CONTAINS = [LIST, STRING, HINT, HINT_COL, COMMENT, KEY, COLLECTION, NUMBER, LITERAL, SYMBOL];\n\n var GLOBAL = {\n beginKeywords: globals,\n lexemes: SYMBOL_RE,\n end: '(\\\\[|#|\\\\d|\"|:|\\\\{|\\\\)|\\\\(|$)',\n contains: [\n {\n className: 'title',\n begin: SYMBOL_RE,\n relevance: 0,\n excludeEnd: true,\n // we can only have a single title\n endsParent: true\n },\n ].concat(DEFAULT_CONTAINS)\n };\n\n LIST.contains = [hljs.COMMENT('comment', ''), GLOBAL, NAME, BODY];\n BODY.contains = DEFAULT_CONTAINS;\n COLLECTION.contains = DEFAULT_CONTAINS;\n HINT_COL.contains = [COLLECTION];\n\n return {\n name: 'Clojure',\n aliases: ['clj'],\n illegal: /\\S/,\n contains: [LIST, STRING, HINT, HINT_COL, COMMENT, KEY, COLLECTION, NUMBER, LITERAL]\n };\n}", "title": "" }, { "docid": "d7453e529fb2cd268c0aa80c7b54e615", "score": "0.48811245", "text": "function clojure(hljs) {\n const SYMBOLSTART = 'a-zA-Z_\\\\-!.?+*=<>&#\\'';\n const SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';\n const globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';\n const keywords = {\n $pattern: SYMBOL_RE,\n 'builtin-name':\n // Clojure keywords\n globals + ' ' +\n 'cond apply if-not if-let if not not= =|0 <|0 >|0 <=|0 >=|0 ==|0 +|0 /|0 *|0 -|0 rem ' +\n 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? ' +\n 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? ' +\n 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? ' +\n 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . ' +\n 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last ' +\n 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate ' +\n 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext ' +\n 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends ' +\n 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler ' +\n 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter ' +\n 'monitor-exit macroexpand macroexpand-1 for dosync and or ' +\n 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert ' +\n 'peek pop doto proxy first rest cons cast coll last butlast ' +\n 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import ' +\n 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! ' +\n 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger ' +\n 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline ' +\n 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking ' +\n 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! ' +\n 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ' +\n 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty ' +\n 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list ' +\n 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer ' +\n 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate ' +\n 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta ' +\n 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'\n };\n\n const SIMPLE_NUMBER_RE = '[-+]?\\\\d+(\\\\.\\\\d+)?';\n\n const SYMBOL = {\n begin: SYMBOL_RE,\n relevance: 0\n };\n const NUMBER = {\n className: 'number',\n begin: SIMPLE_NUMBER_RE,\n relevance: 0\n };\n const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {\n illegal: null\n });\n const COMMENT = hljs.COMMENT(\n ';',\n '$',\n {\n relevance: 0\n }\n );\n const LITERAL = {\n className: 'literal',\n begin: /\\b(true|false|nil)\\b/\n };\n const COLLECTION = {\n begin: '[\\\\[\\\\{]',\n end: '[\\\\]\\\\}]'\n };\n const HINT = {\n className: 'comment',\n begin: '\\\\^' + SYMBOL_RE\n };\n const HINT_COL = hljs.COMMENT('\\\\^\\\\{', '\\\\}');\n const KEY = {\n className: 'symbol',\n begin: '[:]{1,2}' + SYMBOL_RE\n };\n const LIST = {\n begin: '\\\\(',\n end: '\\\\)'\n };\n const BODY = {\n endsWithParent: true,\n relevance: 0\n };\n const NAME = {\n keywords: keywords,\n className: 'name',\n begin: SYMBOL_RE,\n relevance: 0,\n starts: BODY\n };\n const DEFAULT_CONTAINS = [\n LIST,\n STRING,\n HINT,\n HINT_COL,\n COMMENT,\n KEY,\n COLLECTION,\n NUMBER,\n LITERAL,\n SYMBOL\n ];\n\n const GLOBAL = {\n beginKeywords: globals,\n lexemes: SYMBOL_RE,\n end: '(\\\\[|#|\\\\d|\"|:|\\\\{|\\\\)|\\\\(|$)',\n contains: [\n {\n className: 'title',\n begin: SYMBOL_RE,\n relevance: 0,\n excludeEnd: true,\n // we can only have a single title\n endsParent: true\n }\n ].concat(DEFAULT_CONTAINS)\n };\n\n LIST.contains = [\n hljs.COMMENT('comment', ''),\n GLOBAL,\n NAME,\n BODY\n ];\n BODY.contains = DEFAULT_CONTAINS;\n COLLECTION.contains = DEFAULT_CONTAINS;\n HINT_COL.contains = [ COLLECTION ];\n\n return {\n name: 'Clojure',\n aliases: [ 'clj' ],\n illegal: /\\S/,\n contains: [\n LIST,\n STRING,\n HINT,\n HINT_COL,\n COMMENT,\n KEY,\n COLLECTION,\n NUMBER,\n LITERAL\n ]\n };\n}", "title": "" }, { "docid": "d7453e529fb2cd268c0aa80c7b54e615", "score": "0.48811245", "text": "function clojure(hljs) {\n const SYMBOLSTART = 'a-zA-Z_\\\\-!.?+*=<>&#\\'';\n const SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';\n const globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';\n const keywords = {\n $pattern: SYMBOL_RE,\n 'builtin-name':\n // Clojure keywords\n globals + ' ' +\n 'cond apply if-not if-let if not not= =|0 <|0 >|0 <=|0 >=|0 ==|0 +|0 /|0 *|0 -|0 rem ' +\n 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? ' +\n 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? ' +\n 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? ' +\n 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . ' +\n 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last ' +\n 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate ' +\n 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext ' +\n 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends ' +\n 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler ' +\n 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter ' +\n 'monitor-exit macroexpand macroexpand-1 for dosync and or ' +\n 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert ' +\n 'peek pop doto proxy first rest cons cast coll last butlast ' +\n 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import ' +\n 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! ' +\n 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger ' +\n 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline ' +\n 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking ' +\n 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! ' +\n 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ' +\n 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty ' +\n 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list ' +\n 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer ' +\n 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate ' +\n 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta ' +\n 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'\n };\n\n const SIMPLE_NUMBER_RE = '[-+]?\\\\d+(\\\\.\\\\d+)?';\n\n const SYMBOL = {\n begin: SYMBOL_RE,\n relevance: 0\n };\n const NUMBER = {\n className: 'number',\n begin: SIMPLE_NUMBER_RE,\n relevance: 0\n };\n const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {\n illegal: null\n });\n const COMMENT = hljs.COMMENT(\n ';',\n '$',\n {\n relevance: 0\n }\n );\n const LITERAL = {\n className: 'literal',\n begin: /\\b(true|false|nil)\\b/\n };\n const COLLECTION = {\n begin: '[\\\\[\\\\{]',\n end: '[\\\\]\\\\}]'\n };\n const HINT = {\n className: 'comment',\n begin: '\\\\^' + SYMBOL_RE\n };\n const HINT_COL = hljs.COMMENT('\\\\^\\\\{', '\\\\}');\n const KEY = {\n className: 'symbol',\n begin: '[:]{1,2}' + SYMBOL_RE\n };\n const LIST = {\n begin: '\\\\(',\n end: '\\\\)'\n };\n const BODY = {\n endsWithParent: true,\n relevance: 0\n };\n const NAME = {\n keywords: keywords,\n className: 'name',\n begin: SYMBOL_RE,\n relevance: 0,\n starts: BODY\n };\n const DEFAULT_CONTAINS = [\n LIST,\n STRING,\n HINT,\n HINT_COL,\n COMMENT,\n KEY,\n COLLECTION,\n NUMBER,\n LITERAL,\n SYMBOL\n ];\n\n const GLOBAL = {\n beginKeywords: globals,\n lexemes: SYMBOL_RE,\n end: '(\\\\[|#|\\\\d|\"|:|\\\\{|\\\\)|\\\\(|$)',\n contains: [\n {\n className: 'title',\n begin: SYMBOL_RE,\n relevance: 0,\n excludeEnd: true,\n // we can only have a single title\n endsParent: true\n }\n ].concat(DEFAULT_CONTAINS)\n };\n\n LIST.contains = [\n hljs.COMMENT('comment', ''),\n GLOBAL,\n NAME,\n BODY\n ];\n BODY.contains = DEFAULT_CONTAINS;\n COLLECTION.contains = DEFAULT_CONTAINS;\n HINT_COL.contains = [ COLLECTION ];\n\n return {\n name: 'Clojure',\n aliases: [ 'clj' ],\n illegal: /\\S/,\n contains: [\n LIST,\n STRING,\n HINT,\n HINT_COL,\n COMMENT,\n KEY,\n COLLECTION,\n NUMBER,\n LITERAL\n ]\n };\n}", "title": "" }, { "docid": "d7453e529fb2cd268c0aa80c7b54e615", "score": "0.48811245", "text": "function clojure(hljs) {\n const SYMBOLSTART = 'a-zA-Z_\\\\-!.?+*=<>&#\\'';\n const SYMBOL_RE = '[' + SYMBOLSTART + '][' + SYMBOLSTART + '0-9/;:]*';\n const globals = 'def defonce defprotocol defstruct defmulti defmethod defn- defn defmacro deftype defrecord';\n const keywords = {\n $pattern: SYMBOL_RE,\n 'builtin-name':\n // Clojure keywords\n globals + ' ' +\n 'cond apply if-not if-let if not not= =|0 <|0 >|0 <=|0 >=|0 ==|0 +|0 /|0 *|0 -|0 rem ' +\n 'quot neg? pos? delay? symbol? keyword? true? false? integer? empty? coll? list? ' +\n 'set? ifn? fn? associative? sequential? sorted? counted? reversible? number? decimal? ' +\n 'class? distinct? isa? float? rational? reduced? ratio? odd? even? char? seq? vector? ' +\n 'string? map? nil? contains? zero? instance? not-every? not-any? libspec? -> ->> .. . ' +\n 'inc compare do dotimes mapcat take remove take-while drop letfn drop-last take-last ' +\n 'drop-while while intern condp case reduced cycle split-at split-with repeat replicate ' +\n 'iterate range merge zipmap declare line-seq sort comparator sort-by dorun doall nthnext ' +\n 'nthrest partition eval doseq await await-for let agent atom send send-off release-pending-sends ' +\n 'add-watch mapv filterv remove-watch agent-error restart-agent set-error-handler error-handler ' +\n 'set-error-mode! error-mode shutdown-agents quote var fn loop recur throw try monitor-enter ' +\n 'monitor-exit macroexpand macroexpand-1 for dosync and or ' +\n 'when when-not when-let comp juxt partial sequence memoize constantly complement identity assert ' +\n 'peek pop doto proxy first rest cons cast coll last butlast ' +\n 'sigs reify second ffirst fnext nfirst nnext meta with-meta ns in-ns create-ns import ' +\n 'refer keys select-keys vals key val rseq name namespace promise into transient persistent! conj! ' +\n 'assoc! dissoc! pop! disj! use class type num float double short byte boolean bigint biginteger ' +\n 'bigdec print-method print-dup throw-if printf format load compile get-in update-in pr pr-on newline ' +\n 'flush read slurp read-line subvec with-open memfn time re-find re-groups rand-int rand mod locking ' +\n 'assert-valid-fdecl alias resolve ref deref refset swap! reset! set-validator! compare-and-set! alter-meta! ' +\n 'reset-meta! commute get-validator alter ref-set ref-history-count ref-min-history ref-max-history ensure sync io! ' +\n 'new next conj set! to-array future future-call into-array aset gen-class reduce map filter find empty ' +\n 'hash-map hash-set sorted-map sorted-map-by sorted-set sorted-set-by vec vector seq flatten reverse assoc dissoc list ' +\n 'disj get union difference intersection extend extend-type extend-protocol int nth delay count concat chunk chunk-buffer ' +\n 'chunk-append chunk-first chunk-rest max min dec unchecked-inc-int unchecked-inc unchecked-dec-inc unchecked-dec unchecked-negate ' +\n 'unchecked-add-int unchecked-add unchecked-subtract-int unchecked-subtract chunk-next chunk-cons chunked-seq? prn vary-meta ' +\n 'lazy-seq spread list* str find-keyword keyword symbol gensym force rationalize'\n };\n\n const SIMPLE_NUMBER_RE = '[-+]?\\\\d+(\\\\.\\\\d+)?';\n\n const SYMBOL = {\n begin: SYMBOL_RE,\n relevance: 0\n };\n const NUMBER = {\n className: 'number',\n begin: SIMPLE_NUMBER_RE,\n relevance: 0\n };\n const STRING = hljs.inherit(hljs.QUOTE_STRING_MODE, {\n illegal: null\n });\n const COMMENT = hljs.COMMENT(\n ';',\n '$',\n {\n relevance: 0\n }\n );\n const LITERAL = {\n className: 'literal',\n begin: /\\b(true|false|nil)\\b/\n };\n const COLLECTION = {\n begin: '[\\\\[\\\\{]',\n end: '[\\\\]\\\\}]'\n };\n const HINT = {\n className: 'comment',\n begin: '\\\\^' + SYMBOL_RE\n };\n const HINT_COL = hljs.COMMENT('\\\\^\\\\{', '\\\\}');\n const KEY = {\n className: 'symbol',\n begin: '[:]{1,2}' + SYMBOL_RE\n };\n const LIST = {\n begin: '\\\\(',\n end: '\\\\)'\n };\n const BODY = {\n endsWithParent: true,\n relevance: 0\n };\n const NAME = {\n keywords: keywords,\n className: 'name',\n begin: SYMBOL_RE,\n relevance: 0,\n starts: BODY\n };\n const DEFAULT_CONTAINS = [\n LIST,\n STRING,\n HINT,\n HINT_COL,\n COMMENT,\n KEY,\n COLLECTION,\n NUMBER,\n LITERAL,\n SYMBOL\n ];\n\n const GLOBAL = {\n beginKeywords: globals,\n lexemes: SYMBOL_RE,\n end: '(\\\\[|#|\\\\d|\"|:|\\\\{|\\\\)|\\\\(|$)',\n contains: [\n {\n className: 'title',\n begin: SYMBOL_RE,\n relevance: 0,\n excludeEnd: true,\n // we can only have a single title\n endsParent: true\n }\n ].concat(DEFAULT_CONTAINS)\n };\n\n LIST.contains = [\n hljs.COMMENT('comment', ''),\n GLOBAL,\n NAME,\n BODY\n ];\n BODY.contains = DEFAULT_CONTAINS;\n COLLECTION.contains = DEFAULT_CONTAINS;\n HINT_COL.contains = [ COLLECTION ];\n\n return {\n name: 'Clojure',\n aliases: [ 'clj' ],\n illegal: /\\S/,\n contains: [\n LIST,\n STRING,\n HINT,\n HINT_COL,\n COMMENT,\n KEY,\n COLLECTION,\n NUMBER,\n LITERAL\n ]\n };\n}", "title": "" }, { "docid": "ea11f4995ec49b1227adbeee39ffc627", "score": "0.4875857", "text": "function setup() {\n\n\n}", "title": "" }, { "docid": "b0d9b742a0c4825129b48bc271f2cf70", "score": "0.48716357", "text": "function Me (){\n\tthis.name = \"harry\";\n\tthis.syntax = s.getInstance();\n\tthis.gram = g.getInstance();\n}", "title": "" }, { "docid": "2bc9f218c1636860ee755af149c317a3", "score": "0.4863758", "text": "function scala(hljs) {\n const ANNOTATION = {\n className: 'meta',\n begin: '@[A-Za-z]+'\n };\n\n // used in strings for escaping/interpolation/substitution\n const SUBST = {\n className: 'subst',\n variants: [\n {\n begin: '\\\\$[A-Za-z0-9_]+'\n },\n {\n begin: /\\$\\{/,\n end: /\\}/\n }\n ]\n };\n\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"'\n },\n {\n begin: '\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '[a-z]+\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ]\n },\n {\n className: 'string',\n begin: '[a-z]+\"\"\"',\n end: '\"\"\"',\n contains: [ SUBST ],\n relevance: 10\n }\n ]\n\n };\n\n const SYMBOL = {\n className: 'symbol',\n begin: '\\'\\\\w[\\\\w\\\\d_]*(?!\\')'\n };\n\n const TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][A-Za-z0-9_]*',\n relevance: 0\n };\n\n const NAME = {\n className: 'title',\n begin: /[^0-9\\n\\t \"'(),.`{}\\[\\]:;][^\\n\\t \"'(),.`{}\\[\\]:;]+|[^0-9\\n\\t \"'(),.`{}\\[\\]:;=]/,\n relevance: 0\n };\n\n const CLASS = {\n className: 'class',\n beginKeywords: 'class object trait type',\n end: /[:={\\[\\n;]/,\n excludeEnd: true,\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n {\n beginKeywords: 'extends with',\n relevance: 10\n },\n {\n begin: /\\[/,\n end: /\\]/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n NAME\n ]\n };\n\n const METHOD = {\n className: 'function',\n beginKeywords: 'def',\n end: /[:={\\[(\\n;]/,\n excludeEnd: true,\n contains: [ NAME ]\n };\n\n return {\n name: 'Scala',\n keywords: {\n literal: 'true false null',\n keyword: 'type yield lazy override def with val var sealed abstract private trait object if forSome for while throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n STRING,\n SYMBOL,\n TYPE,\n METHOD,\n CLASS,\n hljs.C_NUMBER_MODE,\n ANNOTATION\n ]\n };\n}", "title": "" }, { "docid": "2bc9f218c1636860ee755af149c317a3", "score": "0.4863758", "text": "function scala(hljs) {\n const ANNOTATION = {\n className: 'meta',\n begin: '@[A-Za-z]+'\n };\n\n // used in strings for escaping/interpolation/substitution\n const SUBST = {\n className: 'subst',\n variants: [\n {\n begin: '\\\\$[A-Za-z0-9_]+'\n },\n {\n begin: /\\$\\{/,\n end: /\\}/\n }\n ]\n };\n\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"'\n },\n {\n begin: '\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '[a-z]+\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ]\n },\n {\n className: 'string',\n begin: '[a-z]+\"\"\"',\n end: '\"\"\"',\n contains: [ SUBST ],\n relevance: 10\n }\n ]\n\n };\n\n const SYMBOL = {\n className: 'symbol',\n begin: '\\'\\\\w[\\\\w\\\\d_]*(?!\\')'\n };\n\n const TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][A-Za-z0-9_]*',\n relevance: 0\n };\n\n const NAME = {\n className: 'title',\n begin: /[^0-9\\n\\t \"'(),.`{}\\[\\]:;][^\\n\\t \"'(),.`{}\\[\\]:;]+|[^0-9\\n\\t \"'(),.`{}\\[\\]:;=]/,\n relevance: 0\n };\n\n const CLASS = {\n className: 'class',\n beginKeywords: 'class object trait type',\n end: /[:={\\[\\n;]/,\n excludeEnd: true,\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n {\n beginKeywords: 'extends with',\n relevance: 10\n },\n {\n begin: /\\[/,\n end: /\\]/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n NAME\n ]\n };\n\n const METHOD = {\n className: 'function',\n beginKeywords: 'def',\n end: /[:={\\[(\\n;]/,\n excludeEnd: true,\n contains: [ NAME ]\n };\n\n return {\n name: 'Scala',\n keywords: {\n literal: 'true false null',\n keyword: 'type yield lazy override def with val var sealed abstract private trait object if forSome for while throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n STRING,\n SYMBOL,\n TYPE,\n METHOD,\n CLASS,\n hljs.C_NUMBER_MODE,\n ANNOTATION\n ]\n };\n}", "title": "" }, { "docid": "2bc9f218c1636860ee755af149c317a3", "score": "0.4863758", "text": "function scala(hljs) {\n const ANNOTATION = {\n className: 'meta',\n begin: '@[A-Za-z]+'\n };\n\n // used in strings for escaping/interpolation/substitution\n const SUBST = {\n className: 'subst',\n variants: [\n {\n begin: '\\\\$[A-Za-z0-9_]+'\n },\n {\n begin: /\\$\\{/,\n end: /\\}/\n }\n ]\n };\n\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"\"\"',\n end: '\"\"\"'\n },\n {\n begin: '\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '[a-z]+\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [\n hljs.BACKSLASH_ESCAPE,\n SUBST\n ]\n },\n {\n className: 'string',\n begin: '[a-z]+\"\"\"',\n end: '\"\"\"',\n contains: [ SUBST ],\n relevance: 10\n }\n ]\n\n };\n\n const SYMBOL = {\n className: 'symbol',\n begin: '\\'\\\\w[\\\\w\\\\d_]*(?!\\')'\n };\n\n const TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][A-Za-z0-9_]*',\n relevance: 0\n };\n\n const NAME = {\n className: 'title',\n begin: /[^0-9\\n\\t \"'(),.`{}\\[\\]:;][^\\n\\t \"'(),.`{}\\[\\]:;]+|[^0-9\\n\\t \"'(),.`{}\\[\\]:;=]/,\n relevance: 0\n };\n\n const CLASS = {\n className: 'class',\n beginKeywords: 'class object trait type',\n end: /[:={\\[\\n;]/,\n excludeEnd: true,\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n {\n beginKeywords: 'extends with',\n relevance: 10\n },\n {\n begin: /\\[/,\n end: /\\]/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n NAME\n ]\n };\n\n const METHOD = {\n className: 'function',\n beginKeywords: 'def',\n end: /[:={\\[(\\n;]/,\n excludeEnd: true,\n contains: [ NAME ]\n };\n\n return {\n name: 'Scala',\n keywords: {\n literal: 'true false null',\n keyword: 'type yield lazy override def with val var sealed abstract private trait object if forSome for while throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n STRING,\n SYMBOL,\n TYPE,\n METHOD,\n CLASS,\n hljs.C_NUMBER_MODE,\n ANNOTATION\n ]\n };\n}", "title": "" }, { "docid": "413f7cef4af093574675fc3d24e7acdf", "score": "0.48597383", "text": "function Clazz() {}", "title": "" }, { "docid": "615bcc151e2e33f7dfb2c5ff264a5dd3", "score": "0.48573828", "text": "function HelpAssistant() {\n}", "title": "" }, { "docid": "96cb1e6737d74a3efeb98d60520726cb", "score": "0.4851623", "text": "enterTypeArguments(ctx) {\n\t}", "title": "" }, { "docid": "1b4cb8d98392f0f1d64dae20759206f1", "score": "0.48393697", "text": "function scala(hljs) {\n const ANNOTATION = {\n className: 'meta',\n begin: '@[A-Za-z]+'\n };\n\n // used in strings for escaping/interpolation/substitution\n const SUBST = {\n className: 'subst',\n variants: [\n {\n begin: '\\\\$[A-Za-z0-9_]+'\n },\n {\n begin: /\\$\\{/,\n end: /\\}/\n }\n ]\n };\n\n const STRING = {\n className: 'string',\n variants: [\n {\n begin: '\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [ hljs.BACKSLASH_ESCAPE ]\n },\n {\n begin: '\"\"\"',\n end: '\"\"\"',\n relevance: 10\n },\n {\n begin: '[a-z]+\"',\n end: '\"',\n illegal: '\\\\n',\n contains: [ hljs.BACKSLASH_ESCAPE,\n SUBST ]\n },\n {\n className: 'string',\n begin: '[a-z]+\"\"\"',\n end: '\"\"\"',\n contains: [ SUBST ],\n relevance: 10\n }\n ]\n\n };\n\n const SYMBOL = {\n className: 'symbol',\n begin: '\\'\\\\w[\\\\w\\\\d_]*(?!\\')'\n };\n\n const TYPE = {\n className: 'type',\n begin: '\\\\b[A-Z][A-Za-z0-9_]*',\n relevance: 0\n };\n\n const NAME = {\n className: 'title',\n begin: /[^0-9\\n\\t \"'(),.`{}\\[\\]:;][^\\n\\t \"'(),.`{}\\[\\]:;]+|[^0-9\\n\\t \"'(),.`{}\\[\\]:;=]/,\n relevance: 0\n };\n\n const CLASS = {\n className: 'class',\n beginKeywords: 'class object trait type',\n end: /[:={\\[\\n;]/,\n excludeEnd: true,\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n {\n beginKeywords: 'extends with',\n relevance: 10\n },\n {\n begin: /\\[/,\n end: /\\]/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n {\n className: 'params',\n begin: /\\(/,\n end: /\\)/,\n excludeBegin: true,\n excludeEnd: true,\n relevance: 0,\n contains: [ TYPE ]\n },\n NAME\n ]\n };\n\n const METHOD = {\n className: 'function',\n beginKeywords: 'def',\n end: /[:={\\[(\\n;]/,\n excludeEnd: true,\n contains: [ NAME ]\n };\n\n return {\n name: 'Scala',\n keywords: {\n literal: 'true false null',\n keyword: 'type yield lazy override def with val var sealed abstract private trait object if forSome for while throw finally protected extends import final return else break new catch super class case package default try this match continue throws implicit'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n STRING,\n SYMBOL,\n TYPE,\n METHOD,\n CLASS,\n hljs.C_NUMBER_MODE,\n ANNOTATION\n ]\n };\n}", "title": "" }, { "docid": "fc7eec0226947637ff55043d57a38645", "score": "0.4835092", "text": "initDef() {\n }", "title": "" }, { "docid": "98b47b6532f1f3ff7bf47ed972875757", "score": "0.4831034", "text": "function Type() {\n }", "title": "" }, { "docid": "de160b6f98ea1070bef0c6bf5180f2f6", "score": "0.48261145", "text": "function objectCode(){}", "title": "" }, { "docid": "d995b0eb74d0eb3588497e35ff41556b", "score": "0.48187852", "text": "function ruby(hljs) {\n var RUBY_METHOD_RE = '[a-zA-Z_]\\\\w*[!?=]?|[-+~]\\\\@|<<|>>|=~|===?|<=>|[<>]=?|\\\\*\\\\*|[-/+%^&*~`|]|\\\\[\\\\]=?';\n var RUBY_KEYWORDS = {\n keyword:\n 'and then defined module in return redo if BEGIN retry end for self when ' +\n 'next until do begin unless END rescue else break undef not super class case ' +\n 'require yield alias while ensure elsif or include attr_reader attr_writer attr_accessor',\n literal:\n 'true false nil'\n };\n var YARDOCTAG = {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n };\n var IRB_OBJECT = {\n begin: '#<', end: '>'\n };\n var COMMENT_MODES = [\n hljs.COMMENT(\n '#',\n '$',\n {\n contains: [YARDOCTAG]\n }\n ),\n hljs.COMMENT(\n '^\\\\=begin',\n '^\\\\=end',\n {\n contains: [YARDOCTAG],\n relevance: 10\n }\n ),\n hljs.COMMENT('^__END__', '\\\\n$')\n ];\n var SUBST = {\n className: 'subst',\n begin: '#\\\\{', end: '}',\n keywords: RUBY_KEYWORDS\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /'/, end: /'/},\n {begin: /\"/, end: /\"/},\n {begin: /`/, end: /`/},\n {begin: '%[qQwWx]?\\\\(', end: '\\\\)'},\n {begin: '%[qQwWx]?\\\\[', end: '\\\\]'},\n {begin: '%[qQwWx]?{', end: '}'},\n {begin: '%[qQwWx]?<', end: '>'},\n {begin: '%[qQwWx]?/', end: '/'},\n {begin: '%[qQwWx]?%', end: '%'},\n {begin: '%[qQwWx]?-', end: '-'},\n {begin: '%[qQwWx]?\\\\|', end: '\\\\|'},\n {\n // \\B in the beginning suppresses recognition of ?-sequences where ?\n // is the last character of a preceding identifier, as in: `func?4`\n begin: /\\B\\?(\\\\\\d{1,3}|\\\\x[A-Fa-f0-9]{1,2}|\\\\u[A-Fa-f0-9]{4}|\\\\?\\S)\\b/\n },\n { // heredocs\n begin: /<<[-~]?'?(\\w+)(?:.|\\n)*?\\n\\s*\\1\\b/,\n returnBegin: true,\n contains: [\n { begin: /<<[-~]?'?/ },\n hljs.END_SAME_AS_BEGIN({\n begin: /(\\w+)/, end: /(\\w+)/,\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n })\n ]\n }\n ]\n };\n var PARAMS = {\n className: 'params',\n begin: '\\\\(', end: '\\\\)', endsParent: true,\n keywords: RUBY_KEYWORDS\n };\n\n var RUBY_DEFAULT_CONTAINS = [\n STRING,\n IRB_OBJECT,\n {\n className: 'class',\n beginKeywords: 'class module', end: '$|;',\n illegal: /=/,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: '[A-Za-z_]\\\\w*(::\\\\w+)*(\\\\?|\\\\!)?'}),\n {\n begin: '<\\\\s*',\n contains: [{\n begin: '(' + hljs.IDENT_RE + '::)?' + hljs.IDENT_RE\n }]\n }\n ].concat(COMMENT_MODES)\n },\n {\n className: 'function',\n beginKeywords: 'def', end: '$|;',\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: RUBY_METHOD_RE}),\n PARAMS\n ].concat(COMMENT_MODES)\n },\n {\n // swallow namespace qualifiers before symbols\n begin: hljs.IDENT_RE + '::'\n },\n {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '(\\\\!|\\\\?)?:',\n relevance: 0\n },\n {\n className: 'symbol',\n begin: ':(?!\\\\s)',\n contains: [STRING, {begin: RUBY_METHOD_RE}],\n relevance: 0\n },\n {\n className: 'number',\n begin: '(\\\\b0[0-7_]+)|(\\\\b0x[0-9a-fA-F_]+)|(\\\\b[1-9][0-9_]*(\\\\.[0-9_]+)?)|[0_]\\\\b',\n relevance: 0\n },\n {\n begin: '(\\\\$\\\\W)|((\\\\$|\\\\@\\\\@?)(\\\\w+))' // variables\n },\n {\n className: 'params',\n begin: /\\|/, end: /\\|/,\n keywords: RUBY_KEYWORDS\n },\n { // regexp container\n begin: '(' + hljs.RE_STARTERS_RE + '|unless)\\\\s*',\n keywords: 'unless',\n contains: [\n IRB_OBJECT,\n {\n className: 'regexp',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n illegal: /\\n/,\n variants: [\n {begin: '/', end: '/[a-z]*'},\n {begin: '%r{', end: '}[a-z]*'},\n {begin: '%r\\\\(', end: '\\\\)[a-z]*'},\n {begin: '%r!', end: '![a-z]*'},\n {begin: '%r\\\\[', end: '\\\\][a-z]*'}\n ]\n }\n ].concat(COMMENT_MODES),\n relevance: 0\n }\n ].concat(COMMENT_MODES);\n\n SUBST.contains = RUBY_DEFAULT_CONTAINS;\n PARAMS.contains = RUBY_DEFAULT_CONTAINS;\n\n var SIMPLE_PROMPT = \"[>?]>\";\n var DEFAULT_PROMPT = \"[\\\\w#]+\\\\(\\\\w+\\\\):\\\\d+:\\\\d+>\";\n var RVM_PROMPT = \"(\\\\w+-)?\\\\d+\\\\.\\\\d+\\\\.\\\\d(p\\\\d+)?[^>]+>\";\n\n var IRB_DEFAULT = [\n {\n begin: /^\\s*=>/,\n starts: {\n end: '$', contains: RUBY_DEFAULT_CONTAINS\n }\n },\n {\n className: 'meta',\n begin: '^('+SIMPLE_PROMPT+\"|\"+DEFAULT_PROMPT+'|'+RVM_PROMPT+')',\n starts: {\n end: '$', contains: RUBY_DEFAULT_CONTAINS\n }\n }\n ];\n\n return {\n name: 'Ruby',\n aliases: ['rb', 'gemspec', 'podspec', 'thor', 'irb'],\n keywords: RUBY_KEYWORDS,\n illegal: /\\/\\*/,\n contains: COMMENT_MODES.concat(IRB_DEFAULT).concat(RUBY_DEFAULT_CONTAINS)\n };\n}", "title": "" }, { "docid": "d995b0eb74d0eb3588497e35ff41556b", "score": "0.48187852", "text": "function ruby(hljs) {\n var RUBY_METHOD_RE = '[a-zA-Z_]\\\\w*[!?=]?|[-+~]\\\\@|<<|>>|=~|===?|<=>|[<>]=?|\\\\*\\\\*|[-/+%^&*~`|]|\\\\[\\\\]=?';\n var RUBY_KEYWORDS = {\n keyword:\n 'and then defined module in return redo if BEGIN retry end for self when ' +\n 'next until do begin unless END rescue else break undef not super class case ' +\n 'require yield alias while ensure elsif or include attr_reader attr_writer attr_accessor',\n literal:\n 'true false nil'\n };\n var YARDOCTAG = {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n };\n var IRB_OBJECT = {\n begin: '#<', end: '>'\n };\n var COMMENT_MODES = [\n hljs.COMMENT(\n '#',\n '$',\n {\n contains: [YARDOCTAG]\n }\n ),\n hljs.COMMENT(\n '^\\\\=begin',\n '^\\\\=end',\n {\n contains: [YARDOCTAG],\n relevance: 10\n }\n ),\n hljs.COMMENT('^__END__', '\\\\n$')\n ];\n var SUBST = {\n className: 'subst',\n begin: '#\\\\{', end: '}',\n keywords: RUBY_KEYWORDS\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /'/, end: /'/},\n {begin: /\"/, end: /\"/},\n {begin: /`/, end: /`/},\n {begin: '%[qQwWx]?\\\\(', end: '\\\\)'},\n {begin: '%[qQwWx]?\\\\[', end: '\\\\]'},\n {begin: '%[qQwWx]?{', end: '}'},\n {begin: '%[qQwWx]?<', end: '>'},\n {begin: '%[qQwWx]?/', end: '/'},\n {begin: '%[qQwWx]?%', end: '%'},\n {begin: '%[qQwWx]?-', end: '-'},\n {begin: '%[qQwWx]?\\\\|', end: '\\\\|'},\n {\n // \\B in the beginning suppresses recognition of ?-sequences where ?\n // is the last character of a preceding identifier, as in: `func?4`\n begin: /\\B\\?(\\\\\\d{1,3}|\\\\x[A-Fa-f0-9]{1,2}|\\\\u[A-Fa-f0-9]{4}|\\\\?\\S)\\b/\n },\n { // heredocs\n begin: /<<[-~]?'?(\\w+)(?:.|\\n)*?\\n\\s*\\1\\b/,\n returnBegin: true,\n contains: [\n { begin: /<<[-~]?'?/ },\n hljs.END_SAME_AS_BEGIN({\n begin: /(\\w+)/, end: /(\\w+)/,\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n })\n ]\n }\n ]\n };\n var PARAMS = {\n className: 'params',\n begin: '\\\\(', end: '\\\\)', endsParent: true,\n keywords: RUBY_KEYWORDS\n };\n\n var RUBY_DEFAULT_CONTAINS = [\n STRING,\n IRB_OBJECT,\n {\n className: 'class',\n beginKeywords: 'class module', end: '$|;',\n illegal: /=/,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: '[A-Za-z_]\\\\w*(::\\\\w+)*(\\\\?|\\\\!)?'}),\n {\n begin: '<\\\\s*',\n contains: [{\n begin: '(' + hljs.IDENT_RE + '::)?' + hljs.IDENT_RE\n }]\n }\n ].concat(COMMENT_MODES)\n },\n {\n className: 'function',\n beginKeywords: 'def', end: '$|;',\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: RUBY_METHOD_RE}),\n PARAMS\n ].concat(COMMENT_MODES)\n },\n {\n // swallow namespace qualifiers before symbols\n begin: hljs.IDENT_RE + '::'\n },\n {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '(\\\\!|\\\\?)?:',\n relevance: 0\n },\n {\n className: 'symbol',\n begin: ':(?!\\\\s)',\n contains: [STRING, {begin: RUBY_METHOD_RE}],\n relevance: 0\n },\n {\n className: 'number',\n begin: '(\\\\b0[0-7_]+)|(\\\\b0x[0-9a-fA-F_]+)|(\\\\b[1-9][0-9_]*(\\\\.[0-9_]+)?)|[0_]\\\\b',\n relevance: 0\n },\n {\n begin: '(\\\\$\\\\W)|((\\\\$|\\\\@\\\\@?)(\\\\w+))' // variables\n },\n {\n className: 'params',\n begin: /\\|/, end: /\\|/,\n keywords: RUBY_KEYWORDS\n },\n { // regexp container\n begin: '(' + hljs.RE_STARTERS_RE + '|unless)\\\\s*',\n keywords: 'unless',\n contains: [\n IRB_OBJECT,\n {\n className: 'regexp',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n illegal: /\\n/,\n variants: [\n {begin: '/', end: '/[a-z]*'},\n {begin: '%r{', end: '}[a-z]*'},\n {begin: '%r\\\\(', end: '\\\\)[a-z]*'},\n {begin: '%r!', end: '![a-z]*'},\n {begin: '%r\\\\[', end: '\\\\][a-z]*'}\n ]\n }\n ].concat(COMMENT_MODES),\n relevance: 0\n }\n ].concat(COMMENT_MODES);\n\n SUBST.contains = RUBY_DEFAULT_CONTAINS;\n PARAMS.contains = RUBY_DEFAULT_CONTAINS;\n\n var SIMPLE_PROMPT = \"[>?]>\";\n var DEFAULT_PROMPT = \"[\\\\w#]+\\\\(\\\\w+\\\\):\\\\d+:\\\\d+>\";\n var RVM_PROMPT = \"(\\\\w+-)?\\\\d+\\\\.\\\\d+\\\\.\\\\d(p\\\\d+)?[^>]+>\";\n\n var IRB_DEFAULT = [\n {\n begin: /^\\s*=>/,\n starts: {\n end: '$', contains: RUBY_DEFAULT_CONTAINS\n }\n },\n {\n className: 'meta',\n begin: '^('+SIMPLE_PROMPT+\"|\"+DEFAULT_PROMPT+'|'+RVM_PROMPT+')',\n starts: {\n end: '$', contains: RUBY_DEFAULT_CONTAINS\n }\n }\n ];\n\n return {\n name: 'Ruby',\n aliases: ['rb', 'gemspec', 'podspec', 'thor', 'irb'],\n keywords: RUBY_KEYWORDS,\n illegal: /\\/\\*/,\n contains: COMMENT_MODES.concat(IRB_DEFAULT).concat(RUBY_DEFAULT_CONTAINS)\n };\n}", "title": "" }, { "docid": "248b692d984f4b5f1009b6d9ac9f9b93", "score": "0.48184082", "text": "function Tool(){}", "title": "" }, { "docid": "649aa668f2281a17941d15f01e657e68", "score": "0.48169744", "text": "function HelloWorldCommand() {\n }", "title": "" }, { "docid": "3ec756bcdca2e9467f46dfbdc5a68884", "score": "0.48152465", "text": "function Hx(t,e,n,i,r,o,a,s){var c=(\"function\"===typeof n?n.options:n)||{};return c.__file=\"source.vue\",c.render||(c.render=t.render,c.staticRenderFns=t.staticRenderFns,c._compiled=!0,r&&(c.functional=!0)),c._scopeId=i,c}", "title": "" }, { "docid": "2110654ebc22e30ed2642041b35869fc", "score": "0.48110494", "text": "function type_header(string_array){\n if(type_out_header){\n var typed = new Typed('.headerh1', {\n strings: string_array,\n typeSpeed: 100,\n backSpeed: 50,\n showCursor: false,\n smartBackspace: true\n });\n }\n}", "title": "" }, { "docid": "480656b81c0541606c5554b73148a984", "score": "0.48096743", "text": "function langClass() {\n }", "title": "" }, { "docid": "598e41557d1aa868ea3f7cb6c69f85f8", "score": "0.48029244", "text": "function processing(hljs) {\n return {\n name: 'Processing',\n keywords: {\n keyword: 'BufferedReader PVector PFont PImage PGraphics HashMap boolean byte char color ' +\n 'double float int long String Array FloatDict FloatList IntDict IntList JSONArray JSONObject ' +\n 'Object StringDict StringList Table TableRow XML ' +\n // Java keywords\n 'false synchronized int abstract float private char boolean static null if const ' +\n 'for true while long throw strictfp finally protected import native final return void ' +\n 'enum else break transient new catch instanceof byte super volatile case assert short ' +\n 'package default double public try this switch continue throws protected public private',\n literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI',\n title: 'setup draw',\n built_in: 'displayHeight displayWidth mouseY mouseX mousePressed pmouseX pmouseY key ' +\n 'keyCode pixels focused frameCount frameRate height width ' +\n 'size createGraphics beginDraw createShape loadShape PShape arc ellipse line point ' +\n 'quad rect triangle bezier bezierDetail bezierPoint bezierTangent curve curveDetail curvePoint ' +\n 'curveTangent curveTightness shape shapeMode beginContour beginShape bezierVertex curveVertex ' +\n 'endContour endShape quadraticVertex vertex ellipseMode noSmooth rectMode smooth strokeCap ' +\n 'strokeJoin strokeWeight mouseClicked mouseDragged mouseMoved mousePressed mouseReleased ' +\n 'mouseWheel keyPressed keyPressedkeyReleased keyTyped print println save saveFrame day hour ' +\n 'millis minute month second year background clear colorMode fill noFill noStroke stroke alpha ' +\n 'blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ' +\n 'screenZ ambient emissive shininess specular add createImage beginCamera camera endCamera frustum ' +\n 'ortho perspective printCamera printProjection cursor frameRate noCursor exit loop noLoop popStyle ' +\n 'pushStyle redraw binary boolean byte char float hex int str unbinary unhex join match matchAll nf ' +\n 'nfc nfp nfs split splitTokens trim append arrayCopy concat expand reverse shorten sort splice subset ' +\n 'box sphere sphereDetail createInput createReader loadBytes loadJSONArray loadJSONObject loadStrings ' +\n 'loadTable loadXML open parseXML saveTable selectFolder selectInput beginRaw beginRecord createOutput ' +\n 'createWriter endRaw endRecord PrintWritersaveBytes saveJSONArray saveJSONObject saveStream saveStrings ' +\n 'saveXML selectOutput popMatrix printMatrix pushMatrix resetMatrix rotate rotateX rotateY rotateZ scale ' +\n 'shearX shearY translate ambientLight directionalLight lightFalloff lights lightSpecular noLights normal ' +\n 'pointLight spotLight image imageMode loadImage noTint requestImage tint texture textureMode textureWrap ' +\n 'blend copy filter get loadPixels set updatePixels blendMode loadShader PShaderresetShader shader createFont ' +\n 'loadFont text textFont textAlign textLeading textMode textSize textWidth textAscent textDescent abs ceil ' +\n 'constrain dist exp floor lerp log mag map max min norm pow round sq sqrt acos asin atan atan2 cos degrees ' +\n 'radians sin tan noise noiseDetail noiseSeed random randomGaussian randomSeed'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n hljs.C_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "598e41557d1aa868ea3f7cb6c69f85f8", "score": "0.48029244", "text": "function processing(hljs) {\n return {\n name: 'Processing',\n keywords: {\n keyword: 'BufferedReader PVector PFont PImage PGraphics HashMap boolean byte char color ' +\n 'double float int long String Array FloatDict FloatList IntDict IntList JSONArray JSONObject ' +\n 'Object StringDict StringList Table TableRow XML ' +\n // Java keywords\n 'false synchronized int abstract float private char boolean static null if const ' +\n 'for true while long throw strictfp finally protected import native final return void ' +\n 'enum else break transient new catch instanceof byte super volatile case assert short ' +\n 'package default double public try this switch continue throws protected public private',\n literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI',\n title: 'setup draw',\n built_in: 'displayHeight displayWidth mouseY mouseX mousePressed pmouseX pmouseY key ' +\n 'keyCode pixels focused frameCount frameRate height width ' +\n 'size createGraphics beginDraw createShape loadShape PShape arc ellipse line point ' +\n 'quad rect triangle bezier bezierDetail bezierPoint bezierTangent curve curveDetail curvePoint ' +\n 'curveTangent curveTightness shape shapeMode beginContour beginShape bezierVertex curveVertex ' +\n 'endContour endShape quadraticVertex vertex ellipseMode noSmooth rectMode smooth strokeCap ' +\n 'strokeJoin strokeWeight mouseClicked mouseDragged mouseMoved mousePressed mouseReleased ' +\n 'mouseWheel keyPressed keyPressedkeyReleased keyTyped print println save saveFrame day hour ' +\n 'millis minute month second year background clear colorMode fill noFill noStroke stroke alpha ' +\n 'blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ' +\n 'screenZ ambient emissive shininess specular add createImage beginCamera camera endCamera frustum ' +\n 'ortho perspective printCamera printProjection cursor frameRate noCursor exit loop noLoop popStyle ' +\n 'pushStyle redraw binary boolean byte char float hex int str unbinary unhex join match matchAll nf ' +\n 'nfc nfp nfs split splitTokens trim append arrayCopy concat expand reverse shorten sort splice subset ' +\n 'box sphere sphereDetail createInput createReader loadBytes loadJSONArray loadJSONObject loadStrings ' +\n 'loadTable loadXML open parseXML saveTable selectFolder selectInput beginRaw beginRecord createOutput ' +\n 'createWriter endRaw endRecord PrintWritersaveBytes saveJSONArray saveJSONObject saveStream saveStrings ' +\n 'saveXML selectOutput popMatrix printMatrix pushMatrix resetMatrix rotate rotateX rotateY rotateZ scale ' +\n 'shearX shearY translate ambientLight directionalLight lightFalloff lights lightSpecular noLights normal ' +\n 'pointLight spotLight image imageMode loadImage noTint requestImage tint texture textureMode textureWrap ' +\n 'blend copy filter get loadPixels set updatePixels blendMode loadShader PShaderresetShader shader createFont ' +\n 'loadFont text textFont textAlign textLeading textMode textSize textWidth textAscent textDescent abs ceil ' +\n 'constrain dist exp floor lerp log mag map max min norm pow round sq sqrt acos asin atan atan2 cos degrees ' +\n 'radians sin tan noise noiseDetail noiseSeed random randomGaussian randomSeed'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n hljs.C_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "598e41557d1aa868ea3f7cb6c69f85f8", "score": "0.48029244", "text": "function processing(hljs) {\n return {\n name: 'Processing',\n keywords: {\n keyword: 'BufferedReader PVector PFont PImage PGraphics HashMap boolean byte char color ' +\n 'double float int long String Array FloatDict FloatList IntDict IntList JSONArray JSONObject ' +\n 'Object StringDict StringList Table TableRow XML ' +\n // Java keywords\n 'false synchronized int abstract float private char boolean static null if const ' +\n 'for true while long throw strictfp finally protected import native final return void ' +\n 'enum else break transient new catch instanceof byte super volatile case assert short ' +\n 'package default double public try this switch continue throws protected public private',\n literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI',\n title: 'setup draw',\n built_in: 'displayHeight displayWidth mouseY mouseX mousePressed pmouseX pmouseY key ' +\n 'keyCode pixels focused frameCount frameRate height width ' +\n 'size createGraphics beginDraw createShape loadShape PShape arc ellipse line point ' +\n 'quad rect triangle bezier bezierDetail bezierPoint bezierTangent curve curveDetail curvePoint ' +\n 'curveTangent curveTightness shape shapeMode beginContour beginShape bezierVertex curveVertex ' +\n 'endContour endShape quadraticVertex vertex ellipseMode noSmooth rectMode smooth strokeCap ' +\n 'strokeJoin strokeWeight mouseClicked mouseDragged mouseMoved mousePressed mouseReleased ' +\n 'mouseWheel keyPressed keyPressedkeyReleased keyTyped print println save saveFrame day hour ' +\n 'millis minute month second year background clear colorMode fill noFill noStroke stroke alpha ' +\n 'blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ' +\n 'screenZ ambient emissive shininess specular add createImage beginCamera camera endCamera frustum ' +\n 'ortho perspective printCamera printProjection cursor frameRate noCursor exit loop noLoop popStyle ' +\n 'pushStyle redraw binary boolean byte char float hex int str unbinary unhex join match matchAll nf ' +\n 'nfc nfp nfs split splitTokens trim append arrayCopy concat expand reverse shorten sort splice subset ' +\n 'box sphere sphereDetail createInput createReader loadBytes loadJSONArray loadJSONObject loadStrings ' +\n 'loadTable loadXML open parseXML saveTable selectFolder selectInput beginRaw beginRecord createOutput ' +\n 'createWriter endRaw endRecord PrintWritersaveBytes saveJSONArray saveJSONObject saveStream saveStrings ' +\n 'saveXML selectOutput popMatrix printMatrix pushMatrix resetMatrix rotate rotateX rotateY rotateZ scale ' +\n 'shearX shearY translate ambientLight directionalLight lightFalloff lights lightSpecular noLights normal ' +\n 'pointLight spotLight image imageMode loadImage noTint requestImage tint texture textureMode textureWrap ' +\n 'blend copy filter get loadPixels set updatePixels blendMode loadShader PShaderresetShader shader createFont ' +\n 'loadFont text textFont textAlign textLeading textMode textSize textWidth textAscent textDescent abs ceil ' +\n 'constrain dist exp floor lerp log mag map max min norm pow round sq sqrt acos asin atan atan2 cos degrees ' +\n 'radians sin tan noise noiseDetail noiseSeed random randomGaussian randomSeed'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n hljs.C_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "598e41557d1aa868ea3f7cb6c69f85f8", "score": "0.48029244", "text": "function processing(hljs) {\n return {\n name: 'Processing',\n keywords: {\n keyword: 'BufferedReader PVector PFont PImage PGraphics HashMap boolean byte char color ' +\n 'double float int long String Array FloatDict FloatList IntDict IntList JSONArray JSONObject ' +\n 'Object StringDict StringList Table TableRow XML ' +\n // Java keywords\n 'false synchronized int abstract float private char boolean static null if const ' +\n 'for true while long throw strictfp finally protected import native final return void ' +\n 'enum else break transient new catch instanceof byte super volatile case assert short ' +\n 'package default double public try this switch continue throws protected public private',\n literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI',\n title: 'setup draw',\n built_in: 'displayHeight displayWidth mouseY mouseX mousePressed pmouseX pmouseY key ' +\n 'keyCode pixels focused frameCount frameRate height width ' +\n 'size createGraphics beginDraw createShape loadShape PShape arc ellipse line point ' +\n 'quad rect triangle bezier bezierDetail bezierPoint bezierTangent curve curveDetail curvePoint ' +\n 'curveTangent curveTightness shape shapeMode beginContour beginShape bezierVertex curveVertex ' +\n 'endContour endShape quadraticVertex vertex ellipseMode noSmooth rectMode smooth strokeCap ' +\n 'strokeJoin strokeWeight mouseClicked mouseDragged mouseMoved mousePressed mouseReleased ' +\n 'mouseWheel keyPressed keyPressedkeyReleased keyTyped print println save saveFrame day hour ' +\n 'millis minute month second year background clear colorMode fill noFill noStroke stroke alpha ' +\n 'blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ' +\n 'screenZ ambient emissive shininess specular add createImage beginCamera camera endCamera frustum ' +\n 'ortho perspective printCamera printProjection cursor frameRate noCursor exit loop noLoop popStyle ' +\n 'pushStyle redraw binary boolean byte char float hex int str unbinary unhex join match matchAll nf ' +\n 'nfc nfp nfs split splitTokens trim append arrayCopy concat expand reverse shorten sort splice subset ' +\n 'box sphere sphereDetail createInput createReader loadBytes loadJSONArray loadJSONObject loadStrings ' +\n 'loadTable loadXML open parseXML saveTable selectFolder selectInput beginRaw beginRecord createOutput ' +\n 'createWriter endRaw endRecord PrintWritersaveBytes saveJSONArray saveJSONObject saveStream saveStrings ' +\n 'saveXML selectOutput popMatrix printMatrix pushMatrix resetMatrix rotate rotateX rotateY rotateZ scale ' +\n 'shearX shearY translate ambientLight directionalLight lightFalloff lights lightSpecular noLights normal ' +\n 'pointLight spotLight image imageMode loadImage noTint requestImage tint texture textureMode textureWrap ' +\n 'blend copy filter get loadPixels set updatePixels blendMode loadShader PShaderresetShader shader createFont ' +\n 'loadFont text textFont textAlign textLeading textMode textSize textWidth textAscent textDescent abs ceil ' +\n 'constrain dist exp floor lerp log mag map max min norm pow round sq sqrt acos asin atan atan2 cos degrees ' +\n 'radians sin tan noise noiseDetail noiseSeed random randomGaussian randomSeed'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n hljs.C_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "598e41557d1aa868ea3f7cb6c69f85f8", "score": "0.48029244", "text": "function processing(hljs) {\n return {\n name: 'Processing',\n keywords: {\n keyword: 'BufferedReader PVector PFont PImage PGraphics HashMap boolean byte char color ' +\n 'double float int long String Array FloatDict FloatList IntDict IntList JSONArray JSONObject ' +\n 'Object StringDict StringList Table TableRow XML ' +\n // Java keywords\n 'false synchronized int abstract float private char boolean static null if const ' +\n 'for true while long throw strictfp finally protected import native final return void ' +\n 'enum else break transient new catch instanceof byte super volatile case assert short ' +\n 'package default double public try this switch continue throws protected public private',\n literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI',\n title: 'setup draw',\n built_in: 'displayHeight displayWidth mouseY mouseX mousePressed pmouseX pmouseY key ' +\n 'keyCode pixels focused frameCount frameRate height width ' +\n 'size createGraphics beginDraw createShape loadShape PShape arc ellipse line point ' +\n 'quad rect triangle bezier bezierDetail bezierPoint bezierTangent curve curveDetail curvePoint ' +\n 'curveTangent curveTightness shape shapeMode beginContour beginShape bezierVertex curveVertex ' +\n 'endContour endShape quadraticVertex vertex ellipseMode noSmooth rectMode smooth strokeCap ' +\n 'strokeJoin strokeWeight mouseClicked mouseDragged mouseMoved mousePressed mouseReleased ' +\n 'mouseWheel keyPressed keyPressedkeyReleased keyTyped print println save saveFrame day hour ' +\n 'millis minute month second year background clear colorMode fill noFill noStroke stroke alpha ' +\n 'blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ' +\n 'screenZ ambient emissive shininess specular add createImage beginCamera camera endCamera frustum ' +\n 'ortho perspective printCamera printProjection cursor frameRate noCursor exit loop noLoop popStyle ' +\n 'pushStyle redraw binary boolean byte char float hex int str unbinary unhex join match matchAll nf ' +\n 'nfc nfp nfs split splitTokens trim append arrayCopy concat expand reverse shorten sort splice subset ' +\n 'box sphere sphereDetail createInput createReader loadBytes loadJSONArray loadJSONObject loadStrings ' +\n 'loadTable loadXML open parseXML saveTable selectFolder selectInput beginRaw beginRecord createOutput ' +\n 'createWriter endRaw endRecord PrintWritersaveBytes saveJSONArray saveJSONObject saveStream saveStrings ' +\n 'saveXML selectOutput popMatrix printMatrix pushMatrix resetMatrix rotate rotateX rotateY rotateZ scale ' +\n 'shearX shearY translate ambientLight directionalLight lightFalloff lights lightSpecular noLights normal ' +\n 'pointLight spotLight image imageMode loadImage noTint requestImage tint texture textureMode textureWrap ' +\n 'blend copy filter get loadPixels set updatePixels blendMode loadShader PShaderresetShader shader createFont ' +\n 'loadFont text textFont textAlign textLeading textMode textSize textWidth textAscent textDescent abs ceil ' +\n 'constrain dist exp floor lerp log mag map max min norm pow round sq sqrt acos asin atan atan2 cos degrees ' +\n 'radians sin tan noise noiseDetail noiseSeed random randomGaussian randomSeed'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n hljs.C_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "598e41557d1aa868ea3f7cb6c69f85f8", "score": "0.48029244", "text": "function processing(hljs) {\n return {\n name: 'Processing',\n keywords: {\n keyword: 'BufferedReader PVector PFont PImage PGraphics HashMap boolean byte char color ' +\n 'double float int long String Array FloatDict FloatList IntDict IntList JSONArray JSONObject ' +\n 'Object StringDict StringList Table TableRow XML ' +\n // Java keywords\n 'false synchronized int abstract float private char boolean static null if const ' +\n 'for true while long throw strictfp finally protected import native final return void ' +\n 'enum else break transient new catch instanceof byte super volatile case assert short ' +\n 'package default double public try this switch continue throws protected public private',\n literal: 'P2D P3D HALF_PI PI QUARTER_PI TAU TWO_PI',\n title: 'setup draw',\n built_in: 'displayHeight displayWidth mouseY mouseX mousePressed pmouseX pmouseY key ' +\n 'keyCode pixels focused frameCount frameRate height width ' +\n 'size createGraphics beginDraw createShape loadShape PShape arc ellipse line point ' +\n 'quad rect triangle bezier bezierDetail bezierPoint bezierTangent curve curveDetail curvePoint ' +\n 'curveTangent curveTightness shape shapeMode beginContour beginShape bezierVertex curveVertex ' +\n 'endContour endShape quadraticVertex vertex ellipseMode noSmooth rectMode smooth strokeCap ' +\n 'strokeJoin strokeWeight mouseClicked mouseDragged mouseMoved mousePressed mouseReleased ' +\n 'mouseWheel keyPressed keyPressedkeyReleased keyTyped print println save saveFrame day hour ' +\n 'millis minute month second year background clear colorMode fill noFill noStroke stroke alpha ' +\n 'blue brightness color green hue lerpColor red saturation modelX modelY modelZ screenX screenY ' +\n 'screenZ ambient emissive shininess specular add createImage beginCamera camera endCamera frustum ' +\n 'ortho perspective printCamera printProjection cursor frameRate noCursor exit loop noLoop popStyle ' +\n 'pushStyle redraw binary boolean byte char float hex int str unbinary unhex join match matchAll nf ' +\n 'nfc nfp nfs split splitTokens trim append arrayCopy concat expand reverse shorten sort splice subset ' +\n 'box sphere sphereDetail createInput createReader loadBytes loadJSONArray loadJSONObject loadStrings ' +\n 'loadTable loadXML open parseXML saveTable selectFolder selectInput beginRaw beginRecord createOutput ' +\n 'createWriter endRaw endRecord PrintWritersaveBytes saveJSONArray saveJSONObject saveStream saveStrings ' +\n 'saveXML selectOutput popMatrix printMatrix pushMatrix resetMatrix rotate rotateX rotateY rotateZ scale ' +\n 'shearX shearY translate ambientLight directionalLight lightFalloff lights lightSpecular noLights normal ' +\n 'pointLight spotLight image imageMode loadImage noTint requestImage tint texture textureMode textureWrap ' +\n 'blend copy filter get loadPixels set updatePixels blendMode loadShader PShaderresetShader shader createFont ' +\n 'loadFont text textFont textAlign textLeading textMode textSize textWidth textAscent textDescent abs ceil ' +\n 'constrain dist exp floor lerp log mag map max min norm pow round sq sqrt acos asin atan atan2 cos degrees ' +\n 'radians sin tan noise noiseDetail noiseSeed random randomGaussian randomSeed'\n },\n contains: [\n hljs.C_LINE_COMMENT_MODE,\n hljs.C_BLOCK_COMMENT_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n hljs.C_NUMBER_MODE\n ]\n };\n}", "title": "" }, { "docid": "d8f8ef4d767b83bbe0d76184658d1014", "score": "0.47847614", "text": "function MyClassDesc() {}", "title": "" }, { "docid": "1257baf2e49c9d0be3fd9b702346e184", "score": "0.47814667", "text": "function helloWorld() {\n return 'Hello world !';\n}", "title": "" }, { "docid": "bec7a4ff847aff6a72b5cf4a18195a67", "score": "0.47772726", "text": "function helloWorld() {\n return (\"Hello World\");\n}", "title": "" }, { "docid": "e48bb12563dc39564e64d7904a7392d7", "score": "0.47750401", "text": "function Main() {}", "title": "" }, { "docid": "55ac90d3e8c22391242659ef3807e6dc", "score": "0.47668365", "text": "function sayHi() {\n \n}", "title": "" }, { "docid": "431f8274ba1915078fac154d4f016289", "score": "0.476682", "text": "function Compile() {\n}", "title": "" }, { "docid": "c2a7d244f4d992f39de67db83251f6a8", "score": "0.47616714", "text": "function Main(){}", "title": "" }, { "docid": "606e8a4c92537f3cd29e5ff61f1e5f6b", "score": "0.47510898", "text": "static type(cw, desc) {\r\n let t;\r\n let index = desc.charAt(0) === \"(\" ? desc.indexOf(\")\") + 1 : 0;\r\n switch ((desc.charAt(index))) {\r\n case \"V\":\r\n return 0;\r\n case \"Z\":\r\n case \"C\":\r\n case \"B\":\r\n case \"S\":\r\n case \"I\":\r\n return Frame.INTEGER_$LI$();\r\n case \"F\":\r\n return Frame.FLOAT_$LI$();\r\n case \"J\":\r\n return Frame.LONG_$LI$();\r\n case \"D\":\r\n return Frame.DOUBLE_$LI$();\r\n case \"L\":\r\n t = desc.substring(index + 1, desc.length - 1);\r\n return Frame.OBJECT_$LI$() | cw.addType(t);\r\n default:\r\n let data;\r\n let dims = index + 1;\r\n while ((desc.charAt(dims) === \"[\")) {\r\n ++dims;\r\n }\r\n switch ((desc.charAt(dims))) {\r\n case \"Z\":\r\n data = Frame.BOOLEAN_$LI$();\r\n break;\r\n case \"C\":\r\n data = Frame.CHAR_$LI$();\r\n break;\r\n case \"B\":\r\n data = Frame.BYTE_$LI$();\r\n break;\r\n case \"S\":\r\n data = Frame.SHORT_$LI$();\r\n break;\r\n case \"I\":\r\n data = Frame.INTEGER_$LI$();\r\n break;\r\n case \"F\":\r\n data = Frame.FLOAT_$LI$();\r\n break;\r\n case \"J\":\r\n data = Frame.LONG_$LI$();\r\n break;\r\n case \"D\":\r\n data = Frame.DOUBLE_$LI$();\r\n break;\r\n default:\r\n t = desc.substring(dims + 1, desc.length - 1);\r\n data = Frame.OBJECT_$LI$() | cw.addType(t);\r\n }\r\n return (dims - index) << 28 | data;\r\n }\r\n }", "title": "" }, { "docid": "85effb23e38b25816b2c9d84466a7060", "score": "0.4747178", "text": "function love4() {}", "title": "" }, { "docid": "fae394dcf813f3d2d80270044013855b", "score": "0.474572", "text": "function lua(hljs) {\n var OPENING_LONG_BRACKET = '\\\\[=*\\\\[';\n var CLOSING_LONG_BRACKET = '\\\\]=*\\\\]';\n var LONG_BRACKETS = {\n begin: OPENING_LONG_BRACKET, end: CLOSING_LONG_BRACKET,\n contains: ['self']\n };\n var COMMENTS = [\n hljs.COMMENT('--(?!' + OPENING_LONG_BRACKET + ')', '$'),\n hljs.COMMENT(\n '--' + OPENING_LONG_BRACKET,\n CLOSING_LONG_BRACKET,\n {\n contains: [LONG_BRACKETS],\n relevance: 10\n }\n )\n ];\n return {\n name: 'Lua',\n keywords: {\n $pattern: hljs.UNDERSCORE_IDENT_RE,\n literal: \"true false nil\",\n keyword: \"and break do else elseif end for goto if in local not or repeat return then until while\",\n built_in:\n //Metatags and globals:\n '_G _ENV _VERSION __index __newindex __mode __call __metatable __tostring __len ' +\n '__gc __add __sub __mul __div __mod __pow __concat __unm __eq __lt __le assert ' +\n //Standard methods and properties:\n 'collectgarbage dofile error getfenv getmetatable ipairs load loadfile loadstring ' +\n 'module next pairs pcall print rawequal rawget rawset require select setfenv ' +\n 'setmetatable tonumber tostring type unpack xpcall arg self ' +\n //Library methods and properties (one line per library):\n 'coroutine resume yield status wrap create running debug getupvalue ' +\n 'debug sethook getmetatable gethook setmetatable setlocal traceback setfenv getinfo setupvalue getlocal getregistry getfenv ' +\n 'io lines write close flush open output type read stderr stdin input stdout popen tmpfile ' +\n 'math log max acos huge ldexp pi cos tanh pow deg tan cosh sinh random randomseed frexp ceil floor rad abs sqrt modf asin min mod fmod log10 atan2 exp sin atan ' +\n 'os exit setlocale date getenv difftime remove time clock tmpname rename execute package preload loadlib loaded loaders cpath config path seeall ' +\n 'string sub upper len gfind rep find match char dump gmatch reverse byte format gsub lower ' +\n 'table setn insert getn foreachi maxn foreach concat sort remove'\n },\n contains: COMMENTS.concat([\n {\n className: 'function',\n beginKeywords: 'function', end: '\\\\)',\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: '([_a-zA-Z]\\\\w*\\\\.)*([_a-zA-Z]\\\\w*:)?[_a-zA-Z]\\\\w*'}),\n {\n className: 'params',\n begin: '\\\\(', endsWithParent: true,\n contains: COMMENTS\n }\n ].concat(COMMENTS)\n },\n hljs.C_NUMBER_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n {\n className: 'string',\n begin: OPENING_LONG_BRACKET, end: CLOSING_LONG_BRACKET,\n contains: [LONG_BRACKETS],\n relevance: 5\n }\n ])\n };\n}", "title": "" }, { "docid": "fae394dcf813f3d2d80270044013855b", "score": "0.474572", "text": "function lua(hljs) {\n var OPENING_LONG_BRACKET = '\\\\[=*\\\\[';\n var CLOSING_LONG_BRACKET = '\\\\]=*\\\\]';\n var LONG_BRACKETS = {\n begin: OPENING_LONG_BRACKET, end: CLOSING_LONG_BRACKET,\n contains: ['self']\n };\n var COMMENTS = [\n hljs.COMMENT('--(?!' + OPENING_LONG_BRACKET + ')', '$'),\n hljs.COMMENT(\n '--' + OPENING_LONG_BRACKET,\n CLOSING_LONG_BRACKET,\n {\n contains: [LONG_BRACKETS],\n relevance: 10\n }\n )\n ];\n return {\n name: 'Lua',\n keywords: {\n $pattern: hljs.UNDERSCORE_IDENT_RE,\n literal: \"true false nil\",\n keyword: \"and break do else elseif end for goto if in local not or repeat return then until while\",\n built_in:\n //Metatags and globals:\n '_G _ENV _VERSION __index __newindex __mode __call __metatable __tostring __len ' +\n '__gc __add __sub __mul __div __mod __pow __concat __unm __eq __lt __le assert ' +\n //Standard methods and properties:\n 'collectgarbage dofile error getfenv getmetatable ipairs load loadfile loadstring ' +\n 'module next pairs pcall print rawequal rawget rawset require select setfenv ' +\n 'setmetatable tonumber tostring type unpack xpcall arg self ' +\n //Library methods and properties (one line per library):\n 'coroutine resume yield status wrap create running debug getupvalue ' +\n 'debug sethook getmetatable gethook setmetatable setlocal traceback setfenv getinfo setupvalue getlocal getregistry getfenv ' +\n 'io lines write close flush open output type read stderr stdin input stdout popen tmpfile ' +\n 'math log max acos huge ldexp pi cos tanh pow deg tan cosh sinh random randomseed frexp ceil floor rad abs sqrt modf asin min mod fmod log10 atan2 exp sin atan ' +\n 'os exit setlocale date getenv difftime remove time clock tmpname rename execute package preload loadlib loaded loaders cpath config path seeall ' +\n 'string sub upper len gfind rep find match char dump gmatch reverse byte format gsub lower ' +\n 'table setn insert getn foreachi maxn foreach concat sort remove'\n },\n contains: COMMENTS.concat([\n {\n className: 'function',\n beginKeywords: 'function', end: '\\\\)',\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: '([_a-zA-Z]\\\\w*\\\\.)*([_a-zA-Z]\\\\w*:)?[_a-zA-Z]\\\\w*'}),\n {\n className: 'params',\n begin: '\\\\(', endsWithParent: true,\n contains: COMMENTS\n }\n ].concat(COMMENTS)\n },\n hljs.C_NUMBER_MODE,\n hljs.APOS_STRING_MODE,\n hljs.QUOTE_STRING_MODE,\n {\n className: 'string',\n begin: OPENING_LONG_BRACKET, end: CLOSING_LONG_BRACKET,\n contains: [LONG_BRACKETS],\n relevance: 5\n }\n ])\n };\n}", "title": "" }, { "docid": "daeb83836fbfb44645482330b666fcbf", "score": "0.47407952", "text": "function type() {}", "title": "" }, { "docid": "7191a1df43e30279b1999e813679c04d", "score": "0.47370383", "text": "function ruby(hljs) {\n var RUBY_METHOD_RE = '([a-zA-Z_]\\\\w*[!?=]?|[-+~]@|<<|>>|=~|===?|<=>|[<>]=?|\\\\*\\\\*|[-/+%^&*~`|]|\\\\[\\\\]=?)';\n var RUBY_KEYWORDS = {\n keyword:\n 'and then defined module in return redo if BEGIN retry end for self when ' +\n 'next until do begin unless END rescue else break undef not super class case ' +\n 'require yield alias while ensure elsif or include attr_reader attr_writer attr_accessor ' +\n '__FILE__',\n built_in: 'proc lambda',\n literal:\n 'true false nil'\n };\n var YARDOCTAG = {\n className: 'doctag',\n begin: '@[A-Za-z]+'\n };\n var IRB_OBJECT = {\n begin: '#<', end: '>'\n };\n var COMMENT_MODES = [\n hljs.COMMENT(\n '#',\n '$',\n {\n contains: [YARDOCTAG]\n }\n ),\n hljs.COMMENT(\n '^=begin',\n '^=end',\n {\n contains: [YARDOCTAG],\n relevance: 10\n }\n ),\n hljs.COMMENT('^__END__', '\\\\n$')\n ];\n var SUBST = {\n className: 'subst',\n begin: /#\\{/, end: /\\}/,\n keywords: RUBY_KEYWORDS\n };\n var STRING = {\n className: 'string',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n variants: [\n {begin: /'/, end: /'/},\n {begin: /\"/, end: /\"/},\n {begin: /`/, end: /`/},\n {begin: /%[qQwWx]?\\(/, end: /\\)/},\n {begin: /%[qQwWx]?\\[/, end: /\\]/},\n {begin: /%[qQwWx]?\\{/, end: /\\}/},\n {begin: /%[qQwWx]?</, end: />/},\n {begin: /%[qQwWx]?\\//, end: /\\//},\n {begin: /%[qQwWx]?%/, end: /%/},\n {begin: /%[qQwWx]?-/, end: /-/},\n {begin: /%[qQwWx]?\\|/, end: /\\|/},\n {\n // \\B in the beginning suppresses recognition of ?-sequences where ?\n // is the last character of a preceding identifier, as in: `func?4`\n begin: /\\B\\?(\\\\\\d{1,3}|\\\\x[A-Fa-f0-9]{1,2}|\\\\u[A-Fa-f0-9]{4}|\\\\?\\S)\\b/\n },\n { // heredocs\n begin: /<<[-~]?'?(\\w+)\\n(?:[^\\n]*\\n)*?\\s*\\1\\b/,\n returnBegin: true,\n contains: [\n { begin: /<<[-~]?'?/ },\n hljs.END_SAME_AS_BEGIN({\n begin: /(\\w+)/, end: /(\\w+)/,\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n })\n ]\n }\n ]\n };\n\n // Ruby syntax is underdocumented, but this grammar seems to be accurate\n // as of version 2.7.2 (confirmed with (irb and `Ripper.sexp(...)`)\n // https://docs.ruby-lang.org/en/2.7.0/doc/syntax/literals_rdoc.html#label-Numbers\n var decimal = '[1-9](_?[0-9])*|0';\n var digits = '[0-9](_?[0-9])*';\n var NUMBER = {\n className: 'number', relevance: 0,\n variants: [\n // decimal integer/float, optionally exponential or rational, optionally imaginary\n { begin: `\\\\b(${decimal})(\\\\.(${digits}))?([eE][+-]?(${digits})|r)?i?\\\\b` },\n\n // explicit decimal/binary/octal/hexadecimal integer,\n // optionally rational and/or imaginary\n { begin: \"\\\\b0[dD][0-9](_?[0-9])*r?i?\\\\b\" },\n { begin: \"\\\\b0[bB][0-1](_?[0-1])*r?i?\\\\b\" },\n { begin: \"\\\\b0[oO][0-7](_?[0-7])*r?i?\\\\b\" },\n { begin: \"\\\\b0[xX][0-9a-fA-F](_?[0-9a-fA-F])*r?i?\\\\b\" },\n\n // 0-prefixed implicit octal integer, optionally rational and/or imaginary\n { begin: \"\\\\b0(_?[0-7])+r?i?\\\\b\" },\n ]\n };\n\n var PARAMS = {\n className: 'params',\n begin: '\\\\(', end: '\\\\)', endsParent: true,\n keywords: RUBY_KEYWORDS\n };\n\n var RUBY_DEFAULT_CONTAINS = [\n STRING,\n {\n className: 'class',\n beginKeywords: 'class module', end: '$|;',\n illegal: /=/,\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: '[A-Za-z_]\\\\w*(::\\\\w+)*(\\\\?|!)?'}),\n {\n begin: '<\\\\s*',\n contains: [{\n begin: '(' + hljs.IDENT_RE + '::)?' + hljs.IDENT_RE\n }]\n }\n ].concat(COMMENT_MODES)\n },\n {\n className: 'function',\n // def method_name(\n // def method_name;\n // def method_name (end of line)\n begin: concat(/def\\s*/, lookahead(RUBY_METHOD_RE + \"\\\\s*(\\\\(|;|$)\")),\n keywords: \"def\",\n end: '$|;',\n contains: [\n hljs.inherit(hljs.TITLE_MODE, {begin: RUBY_METHOD_RE}),\n PARAMS\n ].concat(COMMENT_MODES)\n },\n {\n // swallow namespace qualifiers before symbols\n begin: hljs.IDENT_RE + '::'\n },\n {\n className: 'symbol',\n begin: hljs.UNDERSCORE_IDENT_RE + '(!|\\\\?)?:',\n relevance: 0\n },\n {\n className: 'symbol',\n begin: ':(?!\\\\s)',\n contains: [STRING, {begin: RUBY_METHOD_RE}],\n relevance: 0\n },\n NUMBER,\n {\n // negative-look forward attemps to prevent false matches like:\n // @ident@ or $ident$ that might indicate this is not ruby at all\n className: \"variable\",\n begin: '(\\\\$\\\\W)|((\\\\$|@@?)(\\\\w+))(?=[^@$?])' + `(?![A-Za-z])(?![@$?'])`\n },\n {\n className: 'params',\n begin: /\\|/,\n end: /\\|/,\n relevance:0, // this could be a lot of things (in other languages) other than params\n keywords: RUBY_KEYWORDS\n },\n { // regexp container\n begin: '(' + hljs.RE_STARTERS_RE + '|unless)\\\\s*',\n keywords: 'unless',\n contains: [\n {\n className: 'regexp',\n contains: [hljs.BACKSLASH_ESCAPE, SUBST],\n illegal: /\\n/,\n variants: [\n {begin: '/', end: '/[a-z]*'},\n {begin: /%r\\{/, end: /\\}[a-z]*/},\n {begin: '%r\\\\(', end: '\\\\)[a-z]*'},\n {begin: '%r!', end: '![a-z]*'},\n {begin: '%r\\\\[', end: '\\\\][a-z]*'}\n ]\n }\n ].concat(IRB_OBJECT, COMMENT_MODES),\n relevance: 0\n }\n ].concat(IRB_OBJECT, COMMENT_MODES);\n\n SUBST.contains = RUBY_DEFAULT_CONTAINS;\n PARAMS.contains = RUBY_DEFAULT_CONTAINS;\n\n // >>\n // ?>\n var SIMPLE_PROMPT = \"[>?]>\";\n // irb(main):001:0>\n var DEFAULT_PROMPT = \"[\\\\w#]+\\\\(\\\\w+\\\\):\\\\d+:\\\\d+>\";\n var RVM_PROMPT = \"(\\\\w+-)?\\\\d+\\\\.\\\\d+\\\\.\\\\d+(p\\\\d+)?[^\\\\d][^>]+>\";\n\n var IRB_DEFAULT = [\n {\n begin: /^\\s*=>/,\n starts: {\n end: '$', contains: RUBY_DEFAULT_CONTAINS\n }\n },\n {\n className: 'meta',\n begin: '^('+SIMPLE_PROMPT+\"|\"+DEFAULT_PROMPT+'|'+RVM_PROMPT+')(?=[ ])',\n starts: {\n end: '$', contains: RUBY_DEFAULT_CONTAINS\n }\n }\n ];\n\n COMMENT_MODES.unshift(IRB_OBJECT);\n\n return {\n name: 'Ruby',\n aliases: ['rb', 'gemspec', 'podspec', 'thor', 'irb'],\n keywords: RUBY_KEYWORDS,\n illegal: /\\/\\*/,\n contains: [\n hljs.SHEBANG({binary:\"ruby\"}),\n ]\n .concat(IRB_DEFAULT)\n .concat(COMMENT_MODES)\n .concat(RUBY_DEFAULT_CONTAINS)\n };\n}", "title": "" }, { "docid": "82fb28f767f0e30e1d272840f8f6e4c2", "score": "0.47337794", "text": "function sayHello(name: string){\n return `Hello, ${name}!`;\n }", "title": "" }, { "docid": "8fa38c9e256ee837878642cf47cf215c", "score": "0.47334984", "text": "function LoadBasicExternalObject() \n{\n\t/**\n\t The context in which this snippet can run.\n\t*/\n\tthis.requiredContext = \"\\tNeed to be running in context of Bridge and the external library needs to be available\\n\";\t\n}", "title": "" }, { "docid": "e48a9097f337b9d18e65ba084f7b6125", "score": "0.4729453", "text": "exitTypeDeclaration(ctx) {\n\t}", "title": "" }, { "docid": "141849ef6a0f61532a96893ca2c437e8", "score": "0.47263598", "text": "function start() {\n\n\t// call our native method\n\tvar answer = NativePlugin.getAnswer();\n\tprint(\"The answer is: \", answer, \" which is \" , NativePlugin.checkAnswer(answer) ? \"correct\" : \"incorrect\"); \n\tvar game = Atomic.game;\n\n\t// create a 2D scene\n\tgame.createScene2D();\n\n var spaceNode = game.scene.createChild(\"Star\");\n spaceNode.createJSComponent(\"Star\");\n\n}", "title": "" } ]
37902068f7fd9420cb9112f593037c7c
0 is PROD, 1 is DEV. Might add PROFILE later.
[ { "docid": "7789c492439240024f0cc8f0f094ef91", "score": "0.0", "text": "function getContextForSubtree(parentComponent) {\n if (!parentComponent) {\n return emptyObject;\n }\n\n var fiber = get(parentComponent);\n var parentContext = findCurrentUnmaskedContext(fiber);\n return isContextProvider(fiber) ? processChildContext(fiber, parentContext) : parentContext;\n}", "title": "" } ]
[ { "docid": "534be9c1800ce1aed20c3776f394d0bc", "score": "0.64701986", "text": "get isProduction() { return !!this.settings['IS_PRODUCTION']; }", "title": "" }, { "docid": "ad05efcdffc6bf4eb8e9aab414b6cb5e", "score": "0.63477314", "text": "inProduction() {\n return Config.production;\n }", "title": "" }, { "docid": "80cb7c64a0ff8c349bc9f3ddc782923c", "score": "0.62221706", "text": "static defaultProfile() {\n const profileName = process.env.ASK_DEFAULT_PROFILE ? process.env.ASK_DEFAULT_PROFILE : \"default\";\n return profileName; \n }", "title": "" }, { "docid": "ecac033e8d1152ffb3a3e09fc027e57c", "score": "0.6167201", "text": "function isDevelopment(){\n\treturn process.env.DEV === \"true\";\n}", "title": "" }, { "docid": "71efaf780715bfb3fd23591f853bf414", "score": "0.61145216", "text": "get Development() {}", "title": "" }, { "docid": "c4640ce8b4dafc21c4a090d57bd38acb", "score": "0.60881704", "text": "function IsEnvironmentDEV() {\n return (_targetEnvironment == 'DEV');\n}", "title": "" }, { "docid": "a2aaec38f38dd16bff09b02befa9456d", "score": "0.6036602", "text": "static profile() {\n vc.profile(new PlayerModel('debug'));\n }", "title": "" }, { "docid": "311815019f05f8999beda6f0cccf4b6a", "score": "0.60276425", "text": "function enableProdMode() {\n _devMode = false;\n}", "title": "" }, { "docid": "43e1be9544187e77b9813dbb54d01502", "score": "0.59974754", "text": "constructor(opts = {}) {\n this.mode = opts.mode || \"production\";\n }", "title": "" }, { "docid": "490ec0a68a6f741ea523ca69226d3509", "score": "0.59972537", "text": "function isProd() {\n return process.env.NODE_ENV === 'production';\n}", "title": "" }, { "docid": "c6763b37cb02e06cd7ea1d58a3a5f12c", "score": "0.5984039", "text": "function isDev() {\n return gistId === \"DEV\"\n}", "title": "" }, { "docid": "816d4ada9f4cf2cfb31a6e98abc35561", "score": "0.59724355", "text": "function setProd(flag){Object.defineProperty(window,\"productionCode\",{value:flag,configurable:false,enumerable:false,writable:false})}", "title": "" }, { "docid": "1c70f9e458c5b79a416046a6aa3d4828", "score": "0.59120554", "text": "function environment() {\n return location.pathname.search(/^\\/services\\/.*?\\/preview\\/$/) >= 0 ? ENVIRONMENT_PREVIEW : ENVIRONMENT_RUNNER;\n}", "title": "" }, { "docid": "f207694bd9a8c70f917339a5832ad478", "score": "0.58894265", "text": "function isDev() {\n return process.env.NODE_ENV !== 'production';\n }", "title": "" }, { "docid": "27802943591b5d1b181ff17f374fe3c7", "score": "0.5805423", "text": "profiles() { }", "title": "" }, { "docid": "e30bb1a48d0487f9d465f81b00b03d48", "score": "0.5797923", "text": "function isDev() {\n return process.env.NODE_ENV === 'development';\n}", "title": "" }, { "docid": "1479185045aecbf21f0a969691832c11", "score": "0.574592", "text": "function setProductionMode(done) {\n production = true;\n done();\n}", "title": "" }, { "docid": "1479185045aecbf21f0a969691832c11", "score": "0.574592", "text": "function setProductionMode(done) {\n production = true;\n done();\n}", "title": "" }, { "docid": "df098d664590c9717c6962c0bdff83bc", "score": "0.5695724", "text": "function isDev() {\n const env = global.process.env.NODE_ENV || '';\n return env.toLowerCase().indexOf('dev') !== -1;\n}", "title": "" }, { "docid": "f693e55ec55ad9be17d4883c53708824", "score": "0.5663672", "text": "function getEnv(){\n\tvar env = ''\n\tvar hostName = window.location.hostname; /*full URL\"*/\n\tif(hostName == \"localhost\" || hostName == 'dev.tuten.cl')\n\t\treturn 'dev.'; /*If we are using a localhost, return dev server*/\n\tif(hostName == 'cert.tuten.cl')\n\t\treturn 'cert.';\n\treturn env;/*Return production*/\n}", "title": "" }, { "docid": "7cef71568a6917e66a8e7abfd80bb533", "score": "0.56485206", "text": "isDevelopment() {\n return this.get('api/settings');\n }", "title": "" }, { "docid": "91570c24d335585be16be3f51d2a719c", "score": "0.5607076", "text": "function WMCacheProfile() {\n}", "title": "" }, { "docid": "736479ccdde55a90a8e7a9ac7749c101", "score": "0.55906016", "text": "get DEBUG() { return 'debug' }", "title": "" }, { "docid": "4fb32c0773b9a0625cadd9a4d8a628df", "score": "0.5564161", "text": "set Development(value) {}", "title": "" }, { "docid": "1700a698ef42bd05572fe6ccf6414d94", "score": "0.55600965", "text": "function getDevMode() {\n return (window.location.hostname.indexOf(\"localhost\") != -1);\n}", "title": "" }, { "docid": "3b9ec4c86219d2950b2f42c67819abf6", "score": "0.5517836", "text": "function LodLiveProfile() {\n\n }", "title": "" }, { "docid": "194a036ea3d71af6e38f1369ddcd0e57", "score": "0.5481199", "text": "isDev() {\n const isEnv = 'ELECTRON_IS_DEV' in this.env;\n const getEnv = parseInt(this.env.ELECTRON_IS_DEV, 10) === 1;\n return isEnv ? getEnv : !app.isPackaged;\n }", "title": "" }, { "docid": "e7034190a45ac78a3c3a22d26c26844d", "score": "0.54237163", "text": "function switchDevModeOn() {\n isDevMode = true;\n log.printAll('', isDevMode);\n }", "title": "" }, { "docid": "5b961390989d68334510826daab69dec", "score": "0.54079425", "text": "getProduction() {\r\n return this.production;\r\n }", "title": "" }, { "docid": "c3614b245843946a0a532817812ef9c5", "score": "0.5364116", "text": "get profile () {\n\t\treturn this._profile;\n\t}", "title": "" }, { "docid": "c3614b245843946a0a532817812ef9c5", "score": "0.5364116", "text": "get profile () {\n\t\treturn this._profile;\n\t}", "title": "" }, { "docid": "c3614b245843946a0a532817812ef9c5", "score": "0.5364116", "text": "get profile () {\n\t\treturn this._profile;\n\t}", "title": "" }, { "docid": "eb873b8c0bfd9a41fe215c2005f27c8a", "score": "0.5360657", "text": "function isDevelopment() {\n return app.get('env') === 'development';\n}", "title": "" }, { "docid": "d47f2e2173312841b867f673945ac8fe", "score": "0.5358559", "text": "function initProfile() {\r\n\r\n \r\n}", "title": "" }, { "docid": "6d8342b3f8f411754b4af7597f5e6f81", "score": "0.5345137", "text": "function isProduction() {\n var host = window.location.hostname;\n var query = window.location.search;\n if (window.location.search.toLowerCase().indexOf('synthetic=true') > -1 || window.location.search.toLowerCase().indexOf('supert=test') > -1 || superT.getCookie('synthetic') === 'true') {\n superT.setCookie('synthetic', 'true');\n return false;\n } else {\n return (/\\.anz\\.com/.test(host));\n }\n}", "title": "" }, { "docid": "7eb7c03da2a904bf698877437021527b", "score": "0.52968806", "text": "function profile_start(name) {\n if (!debugmode) return;\n profile_starts[name] = new Date().valueOf();\n }", "title": "" }, { "docid": "b3778fe16652be5e27de589ba5c2e359", "score": "0.5285687", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new platform_browser_AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "fad5609ce838569018ec9c4a59a70926", "score": "0.52065504", "text": "function getEnvironment() {\n\tif (process.env.NODE_ENV === 'development') {\n\t\treturn 'debug'\n\t} else if (process.env.NODE_ENV === 'verbose') {\n\t\treturn 'verbose'\n\t} else {\n\t\treturn 'info'\n\t}\n}", "title": "" }, { "docid": "4647f9d391fbd23e3438e08ceace917c", "score": "0.5195911", "text": "function environment() {\n let clientId = process.env.PP_CLIENT_ID || 'PP_CLIENT_ID';\n let clientSecret = process.env.PP_CLIENT_SECRET || 'PP__CLIENT_SECRET';\n if (process.env.PP_SANDBOX_LIVE == \"Live\") {\n return new paypal.core.LiveEnvironment(\n clientId, clientSecret\n );\n }\n else {\n return new paypal.core.SandboxEnvironment(\n clientId, clientSecret\n );\n\n }\n}", "title": "" }, { "docid": "5d6d7585cd4f8146edeaefd02f643c27", "score": "0.51902884", "text": "constructor(opts = {}) {\n this.mode = opts.mode || \"production\";\n this.collection = opts.collection;\n }", "title": "" }, { "docid": "3283d1e61881089f68277c2e45ab70c1", "score": "0.51782244", "text": "consoleLogEnv(s, o) {\n const processEnv = this.$root.$options.components.App.props.processEnv.default;\n if (!this.isEmpty(processEnv) && processEnv != 'production') {\n if (!this.isEmpty(o)) {\n console.log(s, o);\n } else {\n console.log(s);\n }\n }\n }", "title": "" }, { "docid": "cd0caa6cce0a2bf916a4a0b2821539e4", "score": "0.5175191", "text": "function devMode() {\n return false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "48d0666202b29aa625d5ee78ff774257", "score": "0.5164233", "text": "function enableProdMode() {\n if (_runModeLocked) {\n throw new Error('Cannot enable prod mode after platform setup.');\n }\n _devMode = false;\n}", "title": "" }, { "docid": "9caf6fe5ead6285036520cdbd86e5c2a", "score": "0.5138286", "text": "function NEW_DEV_ENV(vars)\n {\n return `{\n \"mlproj\": {\n \"format\": \"0.1\",\n \"import\": \"base.json\",\n \"connect\": {\n \"host\": \"localhost\",\n \"user\": \"admin\",\n \"password\": \"admin\"\n }\n }\n}\n`;\n }", "title": "" }, { "docid": "2dee8568e35301d2223fe56d0fc01a51", "score": "0.5135272", "text": "static get Alias () {\n return ('dev');\n }", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d314f18996b0b852f99f00822d931fbc", "score": "0.5133803", "text": "function isDevMode() {\n _runModeLocked = true;\n return _devMode;\n}", "title": "" }, { "docid": "d212c78f2f1ffe4e6f1d26f61468c42b", "score": "0.513317", "text": "function mainOnLoad() {\n setProfile()\n}", "title": "" }, { "docid": "b667cbbb8ec3fef97bc9b02b972bff36", "score": "0.5133026", "text": "function NEW_PROD_ENV(vars)\n {\n return `{\n \"mlproj\": {\n \"format\": \"0.1\",\n \"import\": \"base.json\",\n \"connect\": {\n \"host\": \"prod.server\",\n \"user\": \"admin\"\n },\n \"databases\": [{\n \"id\": \"modules\",\n \"name\": \"@{code}-modules\"\n }],\n \"servers\": [{\n \"id\": \"app\",\n \"modules\": {\n \"idref\": \"modules\"\n },\n \"root\": \"/\"\n }]\n }\n}\n`;\n }", "title": "" }, { "docid": "c1c4b439daec0e0ff9e60f36c6557f54", "score": "0.5132731", "text": "set ConnectWithProfiler(value) {}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "67548cd8c6cd034e8e0fe7b0cbba3f71", "score": "0.5132236", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "befc59ed9852b8a7e7f8ca6f3464c5e0", "score": "0.5124276", "text": "function environmentSetup() {\n gulp.src(conf.environment.config.file)\n .pipe(gulpNgConfig(conf.environment.config.module , {\n environment: argv.profile ? argv.profile : 'local'\n }))\n .pipe(gulp.dest(conf.environment.config.dest))\n}", "title": "" }, { "docid": "017690d7c741ad7ebf4bd9f9f67fd4a9", "score": "0.51085615", "text": "get ConnectWithProfiler() {}", "title": "" }, { "docid": "e4fe2b82e484b12721c4aa6b8ea014bf", "score": "0.50973046", "text": "function getEnvironment() {\n return stats.environment;\n}", "title": "" }, { "docid": "46e92a5d4c035104f9e772ec7c6d219f", "score": "0.5095071", "text": "function enableDebugTools(ref) {\n exportNgVar(PROFILER_GLOBAL_NAME, new AngularProfiler(ref));\n return ref;\n}", "title": "" }, { "docid": "efcaf1c9192cc201c61de0e50e514594", "score": "0.5073509", "text": "function getProfileUser() {\n\tif (globalUserdata[\"browser\"])\n\t\treturn \"browser\";\n\treturn \"current\";\n}", "title": "" }, { "docid": "a55ce0d4cfcd810a2f988b6927f69ec1", "score": "0.5071029", "text": "execute() {\n if (com_Config.serverMode == com_Config.MODE_TYPE.DEVELOP) {\n\n } else {\n \n }\n }", "title": "" }, { "docid": "4f1dafd100e4f376173c9ad3c13a7d37", "score": "0.50710154", "text": "getEnvironment() {\n return process.env.NODE_ENV || \"development\";\n }", "title": "" }, { "docid": "4348d2dddf6c270428319a97a5f73ab1", "score": "0.5065156", "text": "function parseProfile (options) {\n\t var staticOptions = options.static\n\t var dynamicOptions = options.dynamic\n\n\t var profileEnable\n\t if (S_PROFILE in staticOptions) {\n\t var value = !!staticOptions[S_PROFILE]\n\t profileEnable = createStaticDecl(function (env, scope) {\n\t return value\n\t })\n\t profileEnable.enable = value\n\t } else if (S_PROFILE in dynamicOptions) {\n\t var dyn = dynamicOptions[S_PROFILE]\n\t profileEnable = createDynamicDecl(dyn, function (env, scope) {\n\t return env.invoke(scope, dyn)\n\t })\n\t }\n\n\t return profileEnable\n\t }", "title": "" }, { "docid": "8250714fed6b46ae3711a28a8d0f6774", "score": "0.506173", "text": "function getUrlPrefix() {\n return ENV === 'production' ? PROD_URL : DEV_URL;\n}", "title": "" }, { "docid": "c6d3c9b77cad5261df982caa1fbd1cfa", "score": "0.5058807", "text": "getProfile (options, cb) {\n //Check if a custom repo exists and contains a custom profile path\n if(options && options.config && options.config.setup && options.config.setup[process.env.SOAJS_ENV]\n && options.config.setup[process.env.SOAJS_ENV].service && options.config.setup[process.env.SOAJS_ENV].service.profile\n && options.config.setup[process.env.SOAJS_ENV].service.profile.path){\n\n let profilePath = options.paths.configRepo.path + options.config.setup[process.env.SOAJS_ENV].service.profile.path;\n //Copy the custom profile to the destined profile location\n\n fs.readFile(profilePath, 'utf8', (error, customProfile) => {\n if(error) {\n util.log(error);\n throw new Error(\"Could not access the following custom profile: \" + profilePath);\n } else {\n fs.writeFile(profileLocation + \"profile.js\", customProfile, (error1) => {\n if(error1){\n util.log(error1)\n throw new Error(\"Error while copying the custom profile to: \" + profileLocation);\n }\n util.log(\"Successfully copied the custom profile from \" + profilePath + \" to \" + profileLocation);\n return cb(null, true);\n });\n }\n });\n }\n //Generate a new profile based on available environment variables\n else {\n //Single instance mongo\n if (mongoNb === 1) {\n util.log(\"Generating a profile for a single mongo instance.\");\n utils.generateProfile({\n \"driver\": \"single.js\",\n \"profileFileName\": 'profile.js',\n \"loc\": profileLocation,\n \"count\": mongoNb,\n \"ipEnvName\": \"SOAJS_MONGO_IP_\",\n \"portEnvName\": \"SOAJS_MONGO_PORT_\",\n \"portDefault\": 27017,\n \"ssl\": process.env.SOAJS_MONGO_SSL || false\n }, (err) => {\n if(err){\n throw new Error(err);\n }\n util.log(\"Successfully generated a profile for a single mongo instance.\");\n return cb(null, true);\n });\n } else if (mongoNb > 1 && mongoRsName) {\n util.log(\"Generating a profile for a mongo replica set.\");\n utils.generateProfile({\n \"driver\": \"replica.js\",\n \"profileFileName\": 'profile.js',\n \"loc\": profileLocation,\n \"count\": mongoNb,\n \"ipEnvName\": \"SOAJS_MONGO_IP_\",\n \"portEnvName\": \"SOAJS_MONGO_PORT_\",\n \"portDefault\": 27017,\n \"ssl\": process.env.SOAJS_MONGO_SSL || false,\n \"rsName\": mongoRsName\n }, (err) => {\n if(err){\n throw new Error(err);\n }\n util.log(\"Successfully generated a profile for a mongo replica set.\");\n return cb(null, true);\n });\n } else if (mongoNb > 1 && !mongoRsName) {\n util.log(\"Generating a profile for a mongo sharded cluster.\");\n utils.generateProfile({\n \"driver\": \"mongos.js\",\n \"profileFileName\": 'profile.js',\n \"loc\": profileLocation,\n \"count\": mongoNb,\n \"ipEnvName\": \"SOAJS_MONGO_IP_\",\n \"portEnvName\": \"SOAJS_MONGO_PORT_\",\n \"portDefault\": 27017,\n \"ssl\": process.env.SOAJS_MONGO_SSL || false,\n }, (err) => {\n if(err){\n throw new Error(err);\n }\n util.log(\"Successfully generated a profile for a mongo sharded cluster.\");\n return cb(null, true);\n });\n }\n\n else {\n throw new Error(\"ERROR: PROFILE CREATION FAILED. Environment variable SOAJS_MONGO_NB must be a strict positive integer (greater than 0). [\" + mongoNb + \"] is invalid.\");\n }\n }\n }", "title": "" }, { "docid": "124efb9d4c13089ca9ba6b6eda488344", "score": "0.5045992", "text": "getPlaybackProfileEqual() {\n\t \treturn this.playbackProfileEqual;\n\t }", "title": "" }, { "docid": "0700e60deee0189eb4c953d568ae2198", "score": "0.50453484", "text": "function isInProduction(){ return process.cwd() == \"/dmt/DO-MY-TASK/backend\";} //DMT is installed in this directory on the production server.", "title": "" }, { "docid": "cb16c0372c92a3cfb3e25a12023df521", "score": "0.5043349", "text": "function profiles2device(pros, device) {\n var ret = false;\n profiles(pros, ['devices']).forEach(function(pid){\n if(pid.indexOf(device+'.') === 0) ret = pid;\n });\n return ret;\n}", "title": "" }, { "docid": "0b5f73d82a2725ca0c89118996a5f1c3", "score": "0.5035067", "text": "isInDevStudio() {}", "title": "" }, { "docid": "56e9cbdbc8e2bbf0c68d4c89fa84e61d", "score": "0.50179815", "text": "function shouldAddPt(settings) {\n return [PRODUCER_MODE, STANDALONE_MODE].indexOf(settings.mode) > -1 ? true : false;\n}", "title": "" }, { "docid": "2bac70568804357f6f3ef64558e6dcd9", "score": "0.5001084", "text": "function log( data )\n{\n\tif ( ENV == 'dev' ) console.log( data ) ; \n}", "title": "" } ]
2d05b949acd6a90f9ec291d6467854e5
Only WeeklySchedule field will be used
[ { "docid": "3527c9217432dfa01fc73e9113e14b7f", "score": "0.57065123", "text": "get Schedule() {\n return this.getOrNull(this._schedule);\n }", "title": "" } ]
[ { "docid": "f1c008b98d4b2f3bd78ea8d13897559d", "score": "0.6424256", "text": "function renderSchedule() {\n setSchedule(getSchedule(viewingDate));\n const day = viewingDate.getUTCDay();\n const weekSchedules = [];\n for (let i = 0; i < 7; i++) {\n weekSchedules.push(getSchedule(new Date(viewingDate.getTime() - (day - i) * 86400000)));\n }\n showWeekPreview(weekSchedules, day);\n}", "title": "" }, { "docid": "b6ff5f574e40cbed517042aa05e3b783", "score": "0.61833334", "text": "function Schedule(){/**\n * `Optional` unique id for various use.\n * @type {string}\n */this.id='';/**\n * title for schedule.\n * @type {string}\n */this.title='';/**\n * is schedule is all day schedule?\n * @type {boolean}\n */this.isAllDay=false;/**\n * schedule start\n * @type {TZDate}\n */this.start=null;/**\n * schedule end\n * @type {TZDate}\n */this.end=null;/**\n * schedule text color\n * @type {string}\n */this.color='#000';/**\n * schedule block visibility\n * @type {boolean}\n */this.isVisible=true;/**\n * schedule background color\n * @type {string}\n */this.bgColor='#a1b56c';/**\n * schedule background color when dragging it\n * @type {string}\n */this.dragBgColor='#a1b56c';/**\n * schedule left border color\n * @type {string}\n */this.borderColor='#000';/**\n * calendar ID\n * @type {string}\n */this.calendarId='';/**\n * Schedule category(milestone, task, allday, time)\n * @type {string}\n */this.category='';/**\n * Classification of work schedules (before work, before lunch, before work)\n * @type {string}\n */this.dueDateClass='';/**\n * Custom style for schedule element\n * @type {string}\n */this.customStyle='';/**\n * in progress flag to do something\n * @type {boolean}\n */this.isPending=false;/**\n * focused schedule flag\n * @type {boolean}\n */this.isFocused=false;/**\n * read-only schedule flag\n * @type {boolean}\n */this.isReadOnly=false;/**\n * private schedule\n * @type {boolean}\n */this.isPrivate=false;/**\n * location\n * @type {string}\n */this.location='';/**\n * attendees\n * @type {Array.<string>}\n */this.attendees=[];/**\n * recurrence rule\n * @type {any}\n */this.recurrenceRule='';/**\n * state. 'Busy' is default.\n * @type {string}\n */this.state='';/**\n * travelTime: going-Duration minutes\n * @type {number}\n */this.goingDuration=0;/**\n * travelTime: coming-Duration minutes\n * @type {number}\n */this.comingDuration=0;/**\n * Separate data storage space independent of rendering.\n * @type {object}\n */this.raw=null;// initialize model id\nutil.stamp(this);}", "title": "" }, { "docid": "ae3755a81f08a57c4ec15652191fc5f0", "score": "0.60771656", "text": "function Schedule() {\n\t /**\n\t * `Optional` unique id for various use.\n\t * @type {string}\n\t */\n\t this.id = '';\n\t\n\t /**\n\t * title for schedule.\n\t * @type {string}\n\t */\n\t this.title = '';\n\t\n\t /**\n\t * is schedule is all day schedule?\n\t * @type {boolean}\n\t */\n\t this.isAllDay = false;\n\t\n\t /**\n\t * schedule start\n\t * @type {TZDate}\n\t */\n\t this.start = null;\n\t\n\t /**\n\t * schedule end\n\t * @type {TZDate}\n\t */\n\t this.end = null;\n\t\n\t /**\n\t * schedule text color\n\t * @type {string}\n\t */\n\t this.color = '#000';\n\t\n\t /**\n\t * schedule block visibility\n\t * @type {boolean}\n\t */\n\t this.isVisible = true;\n\t\n\t /**\n\t * schedule background color\n\t * @type {string}\n\t */\n\t this.bgColor = '#a1b56c';\n\t\n\t /**\n\t * schedule background color when dragging it\n\t * @type {string}\n\t */\n\t this.dragBgColor = '#a1b56c';\n\t\n\t /**\n\t * schedule left border color\n\t * @type {string}\n\t */\n\t this.borderColor = '#000';\n\t\n\t /**\n\t * calendar ID\n\t * @type {string}\n\t */\n\t this.calendarId = '';\n\t\n\t /**\n\t * Schedule category(milestone, task, allday, time)\n\t * @type {string}\n\t */\n\t this.category = '';\n\t\n\t /**\n\t * Classification of work schedules (before work, before lunch, before work)\n\t * @type {string}\n\t */\n\t this.dueDateClass = '';\n\t\n\t /**\n\t * Custom style for schedule element\n\t * @type {string}\n\t */\n\t this.customStyle = '';\n\t\n\t /**\n\t * in progress flag to do something\n\t * @type {boolean}\n\t */\n\t this.isPending = false;\n\t\n\t /**\n\t * focused schedule flag\n\t * @type {boolean}\n\t */\n\t this.isFocused = false;\n\t\n\t /**\n\t * read-only schedule flag\n\t * @type {boolean}\n\t */\n\t this.isReadOnly = false;\n\t\n\t /**\n\t * private schedule\n\t * @type {boolean}\n\t */\n\t this.isPrivate = false;\n\t\n\t /**\n\t * location\n\t * @type {string}\n\t */\n\t this.location = '';\n\t\n\t /**\n\t * attendees\n\t * @type {Array.<string>}\n\t */\n\t this.attendees = [];\n\t\n\t /**\n\t * recurrence rule\n\t * @type {any}\n\t */\n\t this.recurrenceRule = '';\n\t\n\t /**\n\t * Separate data storage space independent of rendering.\n\t * @type {object}\n\t */\n\t this.raw = null;\n\t\n\t // initialize model id\n\t util.stamp(this);\n\t}", "title": "" }, { "docid": "71e8839af645457b96df175d798865a6", "score": "0.5953895", "text": "function Schedule() {\n /**\n * `Optional` unique id for various use.\n * @type {string}\n */\n this.id = '';\n\n /**\n * title for schedule.\n * @type {string}\n */\n this.title = '';\n\n /**\n * body for schedule.\n * @type {string}\n */\n this.body = '';\n\n /**\n * is schedule is all day schedule?\n * @type {boolean}\n */\n this.isAllDay = false;\n\n /**\n * schedule start\n * @type {TZDate}\n */\n this.start = null;\n\n /**\n * schedule end\n * @type {TZDate}\n */\n this.end = null;\n\n /**\n * schedule text color\n * @type {string}\n */\n this.color = '#000';\n\n /**\n * schedule block visibility\n * @type {boolean}\n */\n this.isVisible = true;\n\n /**\n * schedule background color\n * @type {string}\n */\n this.bgColor = '#a1b56c';\n\n /**\n * schedule background color when dragging it\n * @type {string}\n */\n this.dragBgColor = '#a1b56c';\n\n /**\n * schedule left border color\n * @type {string}\n */\n this.borderColor = '#000';\n\n /**\n * calendar ID\n * @type {string}\n */\n this.calendarId = '';\n\n /**\n * Schedule category(milestone, task, allday, time)\n * @type {string}\n */\n this.category = '';\n\n /**\n * Classification of work schedules (before work, before lunch, before work)\n * @type {string}\n */\n this.dueDateClass = '';\n\n /**\n * Custom style for schedule element\n * @type {string}\n */\n this.customStyle = '';\n\n /**\n * in progress flag to do something\n * @type {boolean}\n */\n this.isPending = false;\n\n /**\n * focused schedule flag\n * @type {boolean}\n */\n this.isFocused = false;\n\n /**\n * read-only schedule flag\n * @type {boolean}\n */\n this.isReadOnly = false;\n\n /**\n * private schedule\n * @type {boolean}\n */\n this.isPrivate = false;\n\n /**\n * location\n * @type {string}\n */\n this.location = '';\n\n /**\n * attendees\n * @type {Array.<string>}\n */\n this.attendees = [];\n\n /**\n * recurrence rule\n * @type {any}\n */\n this.recurrenceRule = '';\n\n /**\n * state. 'Busy' is default.\n * @type {string}\n */\n this.state = '';\n\n /**\n * travelTime: going-Duration minutes\n * @type {number}\n */\n this.goingDuration = 0;\n\n /**\n * travelTime: coming-Duration minutes\n * @type {number}\n */\n this.comingDuration = 0;\n\n /**\n * Separate data storage space independent of rendering.\n * @type {object}\n */\n this.raw = null;\n\n // initialize model id\n util.stamp(this);\n}", "title": "" }, { "docid": "14ed0c87aa38d0d51a816a14d623871c", "score": "0.59101945", "text": "function beforeCalWeekly(times) {\n $('#make_weekly_salary_'+times).prop( \"disabled\", false );\n $('#make_weekly_salary_'+times).show();\n $('#weekly_status_text_'+times).hide();\n $('#delete_weekly_salary_'+times).hide();\n $('#delete_weekly_salary_'+times).prop( \"disabled\", true );\n}", "title": "" }, { "docid": "096910c5b6b9bca051cef864f04b8ff3", "score": "0.5768993", "text": "function bounds_this_week() {\n\n\tconst start_picker_initial_date = getSunday(new Date());\n\tsetSpanDaysForward(start_picker_initial_date, 7)\n\n\tconst start_timestamp = start_picker.getDate().toISOString();\n\tconst query_args_dict = {\n\t\t\"start-timestamp\": start_timestamp,\n\t};\n\n\trequery_tables(query_args_dict);\n}", "title": "" }, { "docid": "d032088840b03f61eb5436982efe1430", "score": "0.5731657", "text": "function WorkWeek(par) {\n var _this = _super.call(this, par) || this;\n _this.viewClass = 'e-work-week-view';\n return _this;\n }", "title": "" }, { "docid": "fdb5d2ef0a77820651da8241aa96046b", "score": "0.5638314", "text": "static get __resourceType() {\n\t\treturn 'Schedule';\n\t}", "title": "" }, { "docid": "8db69a02b1298d464ccd5c6307f13a11", "score": "0.5589119", "text": "get scheduleInput() {\n return this._schedule;\n }", "title": "" }, { "docid": "27f0688fa6e46d551e499c1cceac4cec", "score": "0.55668783", "text": "function forAScheduleId(){\r\n\treturn \"\";\r\n}", "title": "" }, { "docid": "87e5a9153b5b10c3a5546ce3a2faa9f4", "score": "0.5562318", "text": "get workWeekStart() {\n throw new latte.Ex();\n }", "title": "" }, { "docid": "3e6d7c087cfb78de4d313590af639af3", "score": "0.55577964", "text": "static getThisWeek() {\n const endDate = new Date(Date.now());\n const dayOfWeek = endDate.getDay() - 1;\n const startDate = new Date(Date.now() - dayOfWeek * 24 * 60 * 60 * 1000);\n\n this.setStartDate(startDate);\n this.setEndDate(endDate);\n\n return { startDate, endDate };\n }", "title": "" }, { "docid": "cd11184dbeb2cdbd903aca8e5389168f", "score": "0.5540885", "text": "function setWeek() {\n ctrl.week = [\n ctrl.now.clone().day(0).toDate(),\n ctrl.now.clone().day(1).toDate(),\n ctrl.now.clone().day(2).toDate(),\n ctrl.now.clone().day(3).toDate(),\n ctrl.now.clone().day(4).toDate(),\n ctrl.now.clone().day(5).toDate(),\n ctrl.now.clone().day(6).toDate(),\n ]\n }", "title": "" }, { "docid": "7d6112205395ca61d8a98da9ee38793e", "score": "0.55350465", "text": "static fixSchedulesMinion(pData) {\n if(typeof pData !== \"object\") return pData;\n\n const ret = { \"schedules\": {}, \"enabled\": true };\n\n for(const k in pData) {\n // \"enabled\" is always a boolean (when present)\n if(k === \"enabled\") {\n ret.enabled = pData.enabled;\n continue;\n }\n\n // correct for empty list that returns this dummy value\n if(k === \"schedule\" && JSON.stringify(pData[k]) === \"{}\") {\n continue;\n }\n\n ret.schedules[k] = pData[k];\n\n // Since 2019.02, splay is always added, even when not set\n // so remove it when it has an empty value\n if(ret.schedules[k][\"splay\"] === null)\n delete ret.schedules[k][\"splay\"];\n }\n\n return ret;\n }", "title": "" }, { "docid": "dbc1615ca4ac899bc2078c9c458217c9", "score": "0.55338365", "text": "get schedule() {\n\t\treturn this.__schedule;\n\t}", "title": "" }, { "docid": "a5c61889cb69539eb52450ed0dd549a4", "score": "0.551445", "text": "get workWeekEnd() {\n throw new latte.Ex();\n }", "title": "" }, { "docid": "d9c3e8d662a3d34ba7a0df71546a9594", "score": "0.54941106", "text": "addPhWeekday() {\n\t\tthis.addWeekday(Constants.PH_WEEKDAY);\n\t}", "title": "" }, { "docid": "429ee774411b83eb651db3a876b60918", "score": "0.54936445", "text": "function generateWeekDays() {\n\n var byDay = [];\n var byDayDisplay = [];\n\n var isMonday = $('#monday').is(':checked');\n var isTuesday = $('#tuesday').is(':checked');\n var isWednesday = $('#wednesday').is(':checked');\n var isThursday = $('#thursday').is(':checked');\n var isFriday = $('#friday').is(':checked');\n var isSaturday = $('#saturday').is(':checked');\n var isSunday = $('#sunday').is(':checked');\n\n if (isMonday) {\n byDay.push(0);\n byDayDisplay.push('Mon');\n $scope.activity.recurrence.byDay.push('MO');\n }\n if (isTuesday) {\n byDay.push(1);\n byDayDisplay.push('Tue');\n $scope.activity.recurrence.byDay.push('TU');\n }\n if (isWednesday) {\n byDay.push(2);\n byDayDisplay.push('Wed');\n $scope.activity.recurrence.byDay.push('WE');\n }\n if (isThursday) {\n byDay.push(3);\n byDayDisplay.push('Thu');\n $scope.activity.recurrence.byDay.push('TH');\n }\n if (isFriday) {\n byDay.push(4);\n byDayDisplay.push('Fri');\n $scope.activity.recurrence.byDay.push('FR');\n }\n if (isSaturday) {\n byDay.push(5);\n byDayDisplay.push('Sat');\n $scope.activity.recurrence.byDay.push('SA');\n }\n if (isSunday) {\n byDay.push(6);\n byDayDisplay.push('Sun');\n $scope.activity.recurrence.byDay.push('SU');\n }\n\n // if no days entered when frequency is weekly\n if (!byDay.length) {\n byDay = [0, 1, 2, 3, 4, 5, 6];\n }\n\n $scope.byDay = byDay;\n $scope.activity.recurrence.byDay = $scope.activity.recurrence.byDay.join(',');\n\n generateRRule();\n }", "title": "" }, { "docid": "7cf45535e46bcc1b249522a349387ddd", "score": "0.54916346", "text": "weekStart() {\n return 1;\n }", "title": "" }, { "docid": "7cf45535e46bcc1b249522a349387ddd", "score": "0.54916346", "text": "weekStart() {\n return 1;\n }", "title": "" }, { "docid": "2d5a7e24e6a89338222a6f8dbee115e2", "score": "0.5484009", "text": "set workWeekStart(value) {\n throw new latte.Ex();\n }", "title": "" }, { "docid": "698b7bcb7d826d49c091882b3c6d6713", "score": "0.54800534", "text": "get SupportsRideSchedules() {\n return true;\n }", "title": "" }, { "docid": "1c46fac8fffb985dab64a3079fe321ea", "score": "0.5475159", "text": "function beforeCal7Day(times) {\n $('#make_day_salary_'+times).prop( \"disabled\", false );\n $('#make_day_salary_'+times).show();\n $('#day_status_text_'+times).hide();\n $('#delete_day_salary_'+times).hide();\n $('#delete_day_salary_'+times).prop( \"disabled\", true );\n}", "title": "" }, { "docid": "fa3378fca417a13637ff6e005fa8b5e4", "score": "0.54510134", "text": "get weekRangeSelect() {\n return this._mode === 'week' || this._weekRangeSelect;\n }", "title": "" }, { "docid": "c5d6415fcefdd9ff2c8b844689eb02b6", "score": "0.5437234", "text": "function createSchedule(tutors, dayOfWeek) {\n var schedule = [];\n for (var i = 0; i < ALL_SHIFTS.length; i++) {\n schedule[i] = [];\n // no more active shifts after Friday, 1-2 pm \n if (dayOfWeek === 'friday' && i > LAST_SHIFT) {\n break;\n }\n tutors.forEach(function(tutor) {\n if (tutor.shifts[dayOfWeek].indexOf(ALL_SHIFTS[i]) != -1) {\n schedule[i].push(tutor); \n }\n });\n }\n return schedule;\n}", "title": "" }, { "docid": "86c0c10e07390819915af83753bfd625", "score": "0.543304", "text": "getDayOfWeekFilter({ dayOfWeek }) {\n // days of the week are expressed a an int in SQL, Sunday(0)-Saturday(6)\n if (typeof dayOfWeek == \"undefined\" || dayOfWeek[0] == undefined) {\n return;\n } else {\n // using column of pre-extracted dow instead of extracting on the fly\n // this.addClause(`EXTRACT(DOW FROM departure_local_time) IN ${this.getTags(dayOfWeek)}`);\n this.addClause(`dow IN ${this.getTags(dayOfWeek)}`);\n }\n }", "title": "" }, { "docid": "0ece0136712eba33281c3e9bfa32ff3b", "score": "0.54228956", "text": "function watchSched() {\n $('.schedule-type').change(function formatOnSchedChange(event) {\n formatSchedule($(event.target).parent().parent(), false);\n });\n\n $(function initDatePicker() {\n $('.schedule-date-picker').datetimepicker({\n format: 'HH:mm',\n });\n\n // watch for schedule removal\n $('.destroy-button').click(function removeScheduleOnDestroy(event) {\n var scheduleGroup = $(event.target).parents('.schedule-group');\n removeSchedule(scheduleGroup);\n scheduleGroup.slideUp();\n });\n });\n}", "title": "" }, { "docid": "7fce753d9b31988a61bee98d4b6cddef", "score": "0.5412902", "text": "function unbookDate(date, schedule)\r\n{\r\n var index = findDate(date, schedule);\r\n if(index == -1 || schedule[index].status === \"available\") return false;\r\n schedule[index].status = \"available\";\r\n return true;\r\n}", "title": "" }, { "docid": "23c79cff55cce004354873fe6e5f1ef7", "score": "0.5409031", "text": "function refreshScheduleVisibility() {\n var calendarElements = Array.prototype.slice.call(document.querySelectorAll('#calendarList input'));\n\n CalendarList.forEach(function (calendar) {\n cal.toggleSchedules(calendar.id, !calendar.checked, false);\n });\n\n cal.render(true);\n\n calendarElements.forEach(function (input) {\n var span = input.nextElementSibling;\n span.style.backgroundColor = input.checked ? span.style.borderColor : 'transparent';\n });\n }", "title": "" }, { "docid": "6017714a400cb95948d0bbfee3d358ab", "score": "0.54077387", "text": "function parseScheduleDates(schedule,type,year) {\n\tvar result = [];\n\t//---DAILY----------------------------------|\n\tif (type == \"Daily\") {\n\t\tvar d = new Date();\n\t\td.setFullYear(year); d.setMonth(0); d.setDate(1); d.setHours(0,0,0,0);\n\t\tif (dojo.date.isLeapYear(d)) { var numDays = 366;}\n\t\telse {var numDays = 365;}\n\t\tfor (i = 0; i<numDays; i++) {\n\t\t\tresult.push(dojo.date.add(d,\"day\",i));\n\t\t}\n\t}\n\n\t//---WEEKLY CYCLES--------------------------|\n\telse if (type == \"Weekly\" || type == \"2 Week\" || type == \"3 Week\" || type == \"4 Week\" || type == \"5 Week\") {\n\t\tvar d;\n\t\tvar dates = [];\n\t\tvar weekdays = schedule.split('');\n\t\t//Set cycle\n\t\tswitch(type) {\n\t\t\tcase \"Weekly\": cycle = 1; break;\n\t\t\tcase \"2 Week\": cycle = 2; break;\n\t\t\tcase \"3 Week\": cycle = 3; break;\n\t\t\tcase \"4 Week\": cycle = 4; break;\n\t\t\tcase \"5 Week\": cycle = 5; break;\n\t\t\tdefault: cycle = 1; break;\n\t\t}\n\t\tdojo.forEach(weekdays, function(item,idx) {\n\t\t\tif (item == \"0\") {return;} //Move to next day if not scheduled\n\t\t\td = new Date();\n\t\t\td.setFullYear(year); d.setMonth(0); d.setDate(1); d.setHours(0,0,0,0);\n\t\t\t\n\t\t\t//Determine first date of cycle\n\t\t\tvar gap = idx - d.getDay();\n\t\t\tif (gap < 0 && item == 1) {d = dojo.date.add(d,\"week\",cycle);}\n\t\t\td = dojo.date.add(d,\"day\",gap);\n\t\t\td = dojo.date.add(d,\"week\",parseInt(item) - 1);\n\t\t\t\n\t\t\t//Create all dates\n\t\t\tfor (var i=0; i<=52; i += cycle) {\n\t\t\t\tvar nd = dojo.date.add(d,\"week\",i);\n\t\t\t\tif (nd.getFullYear() == year) {dates.push(new Date(nd));}\n\t\t\t}\n\t\t});\n\t\tresult = sortDateArray(dates);\n\t}\n\t\n\t//---MONTHLY--------------------------------|\n\telse if (type == \"Monthly\") {\n\t\tfor (var i=0; i<12; i++) {\n\t\t\tvar d = new Date();\n\t\t\td.setFullYear(year); d.setMonth(i); d.setDate(1); d.setHours(0,0,0,0);\n\t\t\tif (schedule.length > 2) { //nth weekday of the month\n\t\t\t\tvar weekdays = schedule.split('');\n\t\t\t\tdojo.forEach(weekdays, function(item,idx) {\n\t\t\t\t\tif (item == \"0\") {return;} //Move to next day if not scheduled\n\t\t\t\t\telse if (item == \"9\") { //Look for last day of the week in month\n\t\t\t\t\t\td.setDate(dojo.date.getDaysInMonth(d));\n\t\t\t\t\t\tvar gap = d.getDay() - idx;\n\t\t\t\t\t\tif (gap < 0) {gap += 7}\n\t\t\t\t\t\td = dojo.date.add(d,\"day\",gap * -1);\n\t\t\t\t\t\tresult.push(new Date(d));\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t//Determine first occurence of weekday\n\t\t\t\t\t\td.setDate(1);\n\t\t\t\t\t\tvar gap = idx - d.getDay();\n\t\t\t\t\t\tif (gap < 0) {gap += 7;}\n\t\t\t\t\t\td = dojo.date.add(d,\"day\",gap);\n\t\t\t\t\t\td = dojo.date.add(d,\"week\",parseInt(item) - 1);\n\t\t\t\t\t\tresult.push(new Date(d));\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t}\n\t\t\telse { //nth day of the month\n\t\t\t\td.setDate(parseInt(schedule));\n\t\t\t\tresult.push(new Date(d));\n\t\t\t}\n\t\t}\n\t}\n\t//---ANNUAL/IRREGULAR/SEASONALLY------------|\n\telse if (type == \"Annually\" || type == \"Irregularly\" || type == \"Seasonally\") {\n\t\tvar breakdown = schedule.split(\",\");\n\t\tdojo.forEach(breakdown, function(item, i) {\n\t\t\tvar d = new Date(); d.setHours(0,0,0,0);\n\t\t\tvar dates = item.split(\"-\");\n\t\t\td.setFullYear(parseInt(dates[0]));\n\t\t\td.setMonth(parseInt(dates[1])-1);\n\t\t\td.setDate(parseInt(dates[2]));\n\t\t\tresult.push(new Date(d));\n\t\t});\n\t}\n\treturn result;\n}", "title": "" }, { "docid": "5fd9ff0033087c60188e618e200e7877", "score": "0.5391264", "text": "function generateSchedule() {\n var spreadsheet = SpreadsheetApp.getActiveSpreadsheet();\n try {\n spreadsheet.setActiveSheet(spreadsheet.getSheetByName(SCHEDULE_SHEET));\n } catch(e) {\n // insert after form responses\n spreadsheet.insertSheet(SCHEDULE_SHEET, 1);\n spreadsheet.setActiveSheet(spreadsheet.getSheetByName(SCHEDULE_SHEET));\n }\n writeBlankSchedule(SCHEDULE_SHEET);\n fetchSurveyData();\n tutors = sortByGivenHours_(tutors);\n // construct schedule\n for (var i = 0; i < DAYS_OF_THE_WEEK.length; i++) {\n var currentDayTutors = createSchedule(tutors, DAYS_OF_THE_WEEK[i]);\n var shiftRow = STARTING_ROW;\n for (var j = 0; j < currentDayTutors.length; j++) {\n var dayColumn = columns[i];\n var currentShift = currentDayTutors[j];\n writeToSchedule(currentShift, dayColumn, shiftRow);\n shiftRow += MAX_TUTORS;\n } \n }\n // ensure that there is no invalid data\n clearNonActiveShifts();\n // display table of available and assigned hours\n listNumberOfHours('givenHours', tutors, SCHEDULE_SHEET, 'I', 'J');\n listNumberOfHours('assignedHours', tutors, SCHEDULE_SHEET, 'L', 'M');\n}", "title": "" }, { "docid": "7ffbf8ec639ca17291e5b3ea188ea9aa", "score": "0.5381778", "text": "function getScheduleTable(data, tech, date) {\n tableOfWork = \"\";\n tableMondayAM = \"<td></td>\";\n tableMondayPM = \"<td></td>\";\n tableTuesdayAM = \"<td></td>\";\n tableTuesdayPM = \"<td></td>\";\n tableWednesdayAM = \"<td></td>\";\n tableWednesdayPM = \"<td></td>\";\n tableThursdayAM = \"<td></td>\";\n tableThursdayPM = \"<td></td>\";\n tableFridayAM = \"<td></td>\";\n tableFridayPM = \"<td></td>\";\n for (let i = 0; i < data.length; i++) {\n let dateFormatted = changeDateFormat(data[i][6]);\n dateFrom = changeDateFormat(date);\n dateTo = addDays(dateFrom, 7);\n if (data[i][5] === tech && dateFormatted >= dateFrom && dateFormatted < dateTo) {\n if (data[i][7] === \"AM\") {\n dateFormatted.getDay();\n makeTableAM(data[i], dateFormatted.getDay());\n }\n else {\n makeTablePM(data[i], dateFormatted.getDay());\n }\n }\n };\n tableOfWork = '<tr><th scope=\"row\">AM</th>' + tableMondayAM + tableTuesdayAM + tableWednesdayAM + tableThursdayAM + tableFridayAM + '</tr><tr><th scope=\"row\">PM</th>' + tableMondayPM + tableTuesdayPM + tableWednesdayPM + tableThursdayPM + tableFridayPM + '</tr>'\n \n $('#weekly-scheduler').append(tableOfWork);\n $('#active-tech').html(\"\").html(\"Technician: \" + tech);\n $('#active-date').html(\"\").html(\"Week Commencing: \" + date);\n $('#active-tech2').html(\"\").html(\"Technician: \" + tech);\n $('#active-date2').html(\"\").html(\"Week Commencing: \" + date);\n}", "title": "" }, { "docid": "85b9b713f183a27bcc3ee7bb8ec03bf4", "score": "0.5379551", "text": "set workWeekEnd(value) {\n throw new latte.Ex();\n }", "title": "" }, { "docid": "3ad8ef7d84f4838c9ad478b28cd83449", "score": "0.5379271", "text": "getSchedule() {\r\n var self = this;\r\n var playlist = self.playlists[self.pindex];\r\n var query = \"SELECT playlist_schedule_id AS id, schedule_type AS playalways, start_date, end_date, time_day_selection AS timedays, start_time, end_time, repeated_days AS weekdays \";\r\n query = query + \"FROM playlist_schedule_r WHERE playlist_id = $1;\";\r\n self.db.query(query, [playlist.id], function (err, results) {\r\n if (err) {\r\n self.handler(err, self.player);\r\n }\r\n else {\r\n if (results && results.rows && (results.rows.length > 0)) {\r\n var playtimes = [];\r\n for (var i = 0; i < results.rows.length; i++) {\r\n var playtime = results.rows[i];\r\n playtime.playalways = !playtime.playalways; // Convert to a boolean\r\n playtime.timedays = !playtime.timedays; // Convert to a inverted boolean\r\n if (playtime.playalways) {\r\n playtime.start_date = null;\r\n playtime.end_date = null;\r\n playtime.timedays = null;\r\n playtime.start_time = null;\r\n playtime.end_time = null;\r\n playtime.weekdays = null;\r\n }\r\n else if (!playtime.timedays) {\r\n playtime.start_time = null;\r\n playtime.end_time = null;\r\n playtime.weekdays = null;\r\n }\r\n playtimes.push(self.sweep(playtime));\r\n }\r\n playlist.playtimes = playtimes;\r\n }\r\n self.getLayoutItems();\r\n }\r\n });\r\n }", "title": "" }, { "docid": "ba991a9ed510204f985d6c298484af05", "score": "0.53721637", "text": "function Weekday(name, traffic) {\n this.name = name;\n this.traffic = traffic;\n}", "title": "" }, { "docid": "fce02d4f2033a71a10003f38c4283bec", "score": "0.5371338", "text": "function getSchedule(day) {\n return timetable[day];\n}", "title": "" }, { "docid": "e9a0e61bbfbf31407ec7cde0144a7fb6", "score": "0.5369484", "text": "function Schedule() {\n var _this = this;\n\n _classCallCheck(this, Schedule);\n\n this.render = window.app.render;\n this.limit = 10; // How many pastAppointments to load\n this.recycler = {\n remove: function remove(doc, type) {\n (0, _jquery2.default)(_this.main).find('[id=\"' + doc.id + '\"][type=\"' + type + '\"]').remove();\n _this.refresh();\n },\n display: function display(doc, type) {\n try {\n switch (type) {\n case 'appointments':\n var listItem = Schedule.renderApptListItem(doc);\n break;\n case 'pastAppointments':\n var listItem = Schedule.renderPastApptListItem(doc);\n break;\n case 'activeAppointments':\n var listItem = Schedule.renderActiveApptListItem(doc);\n break;\n case 'modifiedAppointments':\n var listItem = Schedule.renderModifiedApptListItem(doc);\n break;\n case 'canceledAppointments':\n var listItem = Schedule.renderCanceledApptListItem(doc);\n break;\n };\n _this.viewAppt(listItem);\n } catch (e) {\n console.warn('[ERROR] Could not render ' + type + ' (' + doc.id + ') b/c of', e);\n }\n },\n empty: function empty(type) {\n (0, _jquery2.default)(_this.main).find('[type=\"' + type + '\"]').remove();\n _this.refresh();\n }\n };\n this.renderSelf();\n }", "title": "" }, { "docid": "9b8938799196b08c55640b62e8793b97", "score": "0.5369192", "text": "function Weekday (name, traffic) {\n this.name = name;\n this.traffic = traffic;\n}", "title": "" }, { "docid": "9b8938799196b08c55640b62e8793b97", "score": "0.5369192", "text": "function Weekday (name, traffic) {\n this.name = name;\n this.traffic = traffic;\n}", "title": "" }, { "docid": "9b8938799196b08c55640b62e8793b97", "score": "0.5369192", "text": "function Weekday (name, traffic) {\n this.name = name;\n this.traffic = traffic;\n}", "title": "" }, { "docid": "9b8938799196b08c55640b62e8793b97", "score": "0.5369192", "text": "function Weekday (name, traffic) {\n this.name = name;\n this.traffic = traffic;\n}", "title": "" }, { "docid": "6c33ef52715958d25d55ff76710c53f6", "score": "0.53671664", "text": "callOnRenderWeek() {\n const self = this;\n\n function response(events, eventTypes) {\n if (eventTypes && eventTypes.length > 0) {\n self.settings.eventTypes = eventTypes;\n }\n if (events && events.length > 0) {\n self.settings.events = events;\n self.renderAllEvents(true);\n }\n }\n\n this.settings.onRenderWeek(this.element, response, {\n api: self,\n settings: this.settings\n });\n }", "title": "" }, { "docid": "f0739d638a30ac4939a604c8fd6490fd", "score": "0.53624386", "text": "function updateUpcomingEvents() {\n $scope.upcomingEvents = storageService.getIncomingEvents();\n\n var currentTime = new Date();\n\n // if next day began update week panel\n if (currentTime.getHours() == 0 && currentTime.getMinutes() == 0) {\n updateWeekPanel();\n }\n }", "title": "" }, { "docid": "c270a5677453bb6d34891c6ecf9bee93", "score": "0.5361631", "text": "getSchedule() {\r\n var self = this;\r\n var playlist = self.playlists[self.pIndex];\r\n var playtimes = [];\r\n playlist.playtimes = playtimes;\r\n var query = \"SELECT inview_campaign_schedule_id AS id, schedule_type AS playalways, start_date, end_date, time_day_selection AS timedays, start_time, end_time, repeated_days AS weekdays \";\r\n query = query + \"FROM inview_campaign_schedule_r WHERE inview_campaign_id = $1;\";\r\n //console.info('Playlist.id: ' + playlist.id);\r\n self.db.query(query, [playlist.id], function (err, results) {\r\n if (err) {\r\n self.handler(err, self.inview);\r\n }\r\n else {\r\n if (results && results.rows && (results.rows.length > 0)) {\r\n for (var i = 0; i < results.rows.length; i++) {\r\n var playtime = results.rows[i];\r\n playtime.playalways = !playtime.playalways; // Convert to a boolean\r\n playtime.timedays = !playtime.timedays; // Convert to a inverted boolean\r\n if (playtime.playalways) {\r\n playtime.start_date = null;\r\n playtime.end_date = null;\r\n playtime.timedays = null;\r\n playtime.start_time = null;\r\n playtime.end_time = null;\r\n playtime.weekdays = null;\r\n }\r\n else if (!playtime.timedays) {\r\n playtime.start_time = null;\r\n playtime.end_time = null;\r\n playtime.weekdays = null;\r\n }\r\n playtimes.push(self.sweep(playtime));\r\n }\r\n }\r\n self.getMessageItems();\r\n }\r\n });\r\n }", "title": "" }, { "docid": "2c775e9094b22bb0287b41f972865c51", "score": "0.536069", "text": "updateRecurring() {\n if(this.get('isRecurring')) {\n var _this = this;\n\n // get frequency and declare interval\n var freq = this.get('recurringFreq'), interval;\n\n // get interval base on frequency\n if (freq === \"weekly\") {\n interval = 1;\n } else if (freq === \"bi-weekly\") {\n interval = 2;\n }\n\n // get start and end dates\n var startDate = moment(this.get('appointment.scheduledStartTime')).toDate();\n var endDate = this.get('recurringEndDate');\n\n // setup basic rule object\n var ruleObject = {\n freq: RRule.WEEKLY,\n interval: interval,\n dtstart: startDate\n };\n\n // add until date\n if (!_.isNull(endDate)) {\n ruleObject.until = moment(endDate).toDate();\n }\n // get weekdays in rrule format\n var ruleDay;\n var daysArray = this.get('recurringDays').map(function(day) {\n ruleDay = _this.get('rruleDaysString').split(',')[day.id];\n return RRule[ruleDay];\n });\n\n // add weekdays to rrule\n ruleObject.byweekday = daysArray;\n\n // create and save rule\n var rule = new RRule(ruleObject).toString();\n this.get('appointment').set('recurrencePattern', rule);\n } else {\n if(!_.isUndefined(this.get('appointment'))) {\n this.get('appointment').set('recurrencePattern', null);\n }\n }\n }", "title": "" }, { "docid": "6029bd4252ff53766886767387d42d8f", "score": "0.53529954", "text": "function getTimesheet( week ) {\n app.debug( 'Dispatcher.getTimesheet( '+week+' )' );\n\n var timesheet = STIBO.Timesheet.timesheetFactory( application, week.employee.id, week.id, week.week, week.historyVersion );\n\n if ( timesheet.timesheet !== null && timesheet.employee !== null ) {\n app.debug( 'publish - notification.timesheet.loaded' );\n $.Topic( 'notification.timesheet.loaded' ).publish( timesheet.employee, timesheet.timesheet );\n }\n\n }", "title": "" }, { "docid": "4af2782cc4b3480a780d40336a209b53", "score": "0.53510505", "text": "function resetRoutesOnSchedule() {\r\n var localTime = getCurrentTime();\r\n //Have to add a day to get to the Day Of Week that this passes back\r\n var currentDayOfWeek = (localTime).getDay() + 1;\r\n //Set whether the route is on schedule\r\n for (var x = 0; x < _routes.length; x++) {\r\n //Set all routes as off schedule\r\n _routes[x].OnSchedule = false;\r\n if (_inheritActiveRouteTimesFromSchedules) {\r\n //Get schedules for this day of week\r\n var dayOfWeekRoutes = $.grep(_dayOfWeekScheduleRouteTimes, function (obj) { return obj.DayOfWeek === currentDayOfWeek; });\r\n if (dayOfWeekRoutes.length > 0) {\r\n dayOfWeekRoutes = dayOfWeekRoutes[0];\r\n var routes = $.grep(dayOfWeekRoutes.Routes, function (obj) { return obj.RouteID === _routes[x].RouteID; });\r\n if (routes.length > 0) {\r\n var route = routes[0];\r\n for (var y = 0; y < route.ActiveTimeSpans.length; y++) {\r\n var startSeconds = route.ActiveTimeSpans[y].StartSeconds;\r\n var endSeconds = route.ActiveTimeSpans[y].EndSeconds;\r\n var startDateTime = new Date(Date.UTC(localTime.getFullYear(), localTime.getMonth(), localTime.getDate(), 0, 0, startSeconds));\r\n var startUtcDateTime = new Date(Date.UTC(localTime.getUTCFullYear(), localTime.getUTCMonth(), localTime.getUTCDate(), 0, 0, startSeconds));\r\n var endDateTime = new Date(Date.UTC(localTime.getFullYear(), localTime.getMonth(), localTime.getDate(), 0, 0, endSeconds));\r\n var endUtcDateTime = new Date(Date.UTC(localTime.getUTCFullYear(), localTime.getUTCMonth(), localTime.getUTCDate(), 0, 0, endSeconds));\r\n if (localTime >= startDateTime && localTime <= endDateTime) {\r\n _routes[x].OnSchedule = true;\r\n break;;\r\n }\r\n if (localTime >= startUtcDateTime && localTime <= endUtcDateTime) {\r\n _routes[x].OnSchedule = true;\r\n break;;\r\n }\r\n }\r\n }\r\n }\r\n } else {\r\n var routeSchedules = $.grep(_routeSchedules, function (a, b) { return a.RouteID === _routes[x].RouteID; });\r\n if (routeSchedules !== null && routeSchedules.length > 0) {\r\n $.each(routeSchedules, function (index, routeSchedule) {\r\n var startTime = new Date(routeSchedule.StartTimeUTC); //<--ISSUE: The StartTime/EndTime properity isn't a valid date string so JS can't use it to create a Date.\r\n var endTime = new Date(routeSchedule.EndTimeUTC);\r\n //Make the Start Time and End Time have the current date\r\n appendCurrentDate(localTime, startTime);\r\n appendCurrentDate(localTime, endTime);\r\n //Check that the End Time is after the Start Time\r\n if (startTime >= endTime) {\r\n endTime.setDate(endTime.getDate() + 1);\r\n }\r\n if (localTime > startTime && localTime < endTime) {\r\n _routes[x].OnSchedule = true;\r\n return false;\r\n }\r\n });\r\n }\r\n }\r\n //If we are showing a specific route, then always show it, reguardless of schedule\r\n if (_specificRoutes.filter(function (n) { return n == _routes[x].RouteID; }).length > 0) {\r\n _routes[x].OnSchedule = true;\r\n }\r\n }\r\n}", "title": "" }, { "docid": "d09a507a741966cd4b1ade5ddb38d4c9", "score": "0.534996", "text": "isDayOfWeek(daysPast, daysOfWeek) {\n var date = new Date(this.props.startDate.getTime()); // Copy date\n date.setDate(date.getDate() + daysPast);\n let dayOfWeek = date.getDay();\n return (daysOfWeek.indexOf(dayOfWeek) !== -1);\n }", "title": "" }, { "docid": "83cb5ce4dd1c00689048a275dd38290e", "score": "0.5347171", "text": "get ScheduleDays() {\n return this[s_scheduleDaysToReturn];\n }", "title": "" }, { "docid": "320cd9cf42334b4b145c318540d71a88", "score": "0.5337756", "text": "function changeWeekSchedule(period, action) {\n const lastSelectedDays = calendar.betweenPeriods.start;\n\n let start = null;\n let end = null;\n\n if (action === 'forward') {\n start = moment(lastSelectedDays).isoWeekday(\"monday\").add(7, 'day').format('YYYY-MM-DD');\n end = moment(lastSelectedDays).isoWeekday(\"sunday\").add(7, 'day').format('YYYY-MM-DD');\n } else if (action === 'back') {\n start = moment(lastSelectedDays).isoWeekday(\"monday\").subtract(7, 'day').format('YYYY-MM-DD');\n end = moment(lastSelectedDays).isoWeekday(\"sunday\").subtract(7, 'day').format('YYYY-MM-DD');\n } else {\n start = moment().isoWeekday(\"monday\").format('YYYY-MM-DD');\n end = moment().isoWeekday(\"sunday\").format('YYYY-MM-DD');\n }\n\n calendar.betweenPeriods = { start, end };\n\n const diff = moment(start).diff(lastSelectedDateOnCalendar, 'weeks');\n if (diff !== 0 ) {\n updateDatepicker(start);\n }\n}", "title": "" }, { "docid": "0713fd2149869205cba1a52c8b4581cd", "score": "0.53353333", "text": "function displayTimetable(week) {\n\n if (week === undefined) {\n week = currentWeek();\n }\n\n if (week < 1) {\n alert(\"Uni hasn't started yet!\");\n window.location = \"index.html\";\n } else if (week > 13) {\n window.location = \"exam\";\n }\n\n document.getElementById('prev').disabled = (week <= 1);\n document.getElementById('this').disabled = (week == currentWeek());\n document.getElementById('next').disabled = (week >= 13);\n\n if (getWeek() !== null) {\n removeCSSRule(\".notWk\"+getWeek());\n }\n addCSSRule(\".notWk\"+week, \"display: none\");\n\n // Make sure we do this last!\n setWeek(week);\n}", "title": "" }, { "docid": "cb601ea29a8309e17dbbf8887236903e", "score": "0.53346974", "text": "function getSchedule(dayName) {\n // seu código aqui\n const hoursArray = Object.entries(hours);\n\n const hoursObject = hoursArray.reduce((accumulator, item) => {\n const { open, close } = item[1];\n accumulator[item[0]] = `Open from ${open}am until ${close - 12}pm`;\n\n if (item[0] === 'Monday') {\n accumulator[item[0]] = 'CLOSED';\n }\n return accumulator;\n }, {});\n if (!dayName) return hoursObject;\n\n const daySchedule = { [dayName]: hoursObject[dayName] };\n return daySchedule;\n}", "title": "" }, { "docid": "62e58f36093878fba8699fe6a1ad41ca", "score": "0.53261477", "text": "get dayOfWeek() {\n return (this._span.days + 1) % 7;\n }", "title": "" }, { "docid": "897b5f544511a0a190da14729468e17e", "score": "0.5314476", "text": "function w(b,c,d){var e,f,g,h,i,j,k,l,m,n=[];if(c=c||I,d=d||M,b)if(b._recurring){\n// make a boolean hash as to whether the event occurs on each day-of-week\nif(f=b.dow)for(e={},g=0;g<f.length;g++)e[f[g]]=!0;// holds the date of the current day\nfor(\n// iterate through every day in the current range\nh=c.clone().stripTime();h.isBefore(d);)e&&!e[h.day()]||(i=b.start,j=b.end,k=h.clone(),l=null,i&&(k=k.time(i)),j&&(l=h.clone().time(j)),m=a.extend({},b),t(k,l,!i&&!j,m),n.push(m)),h.add(1,\"days\")}else n.push(b);return n}", "title": "" }, { "docid": "6aaec5703c497c2988df0df4186d093b", "score": "0.53000623", "text": "function CP_setDisabledWeekDays() {\r\n\tthis.disabledWeekDays = new Object();\r\n\tfor (var i=0; i<arguments.length; i++) { this.disabledWeekDays[arguments[i]] = true; }\r\n\t}", "title": "" }, { "docid": "50d1c82273e7ea341ce778767371d889", "score": "0.5299168", "text": "async function getWeekInfo() {\n try {\n const week = await Week.findOne({});\n\n console.log(`week: ${week}`);\n const dates = Object.keys(week._doc)\n .filter(key => ['monday', 'tuesday', 'wednesday', 'thursday', 'friday', 'saturday', 'sunday'].includes(key))\n .map(key => week[key])\n .filter(dayOfWeek => dayOfWeek)\n .map(dayOfWeek => dayOfWeek.date)\n .filter(date => date)\n .map(date => moment(date));\n console.log(`dates from week: ${JSON.stringify(dates)}`);\n\n const scheduleByEmployee = await getEmployeeInfo(dates);\n console.log(`scheduleByEmployee: ${scheduleByEmployee}`);\n\n } catch (err) {\n console.log(err);\n }\n}", "title": "" }, { "docid": "b8dc38e78e37f04e3a8162826ac2c715", "score": "0.5294845", "text": "function getWeekDataSchedule(currentByState){\n\n getClassData();\n function getClassData(){\n for(let i = 0;i< dataF.campuses.length;i++){\n for(let j = 0;j<dataF.campuses[i].classes.length;j++){\n if (dataF.campuses[i].classes[j].name === currentByState.class){\n currentByState.classId = dataF.campuses[i].classes[j]._id;\n return;\n }\n }\n }\n }\n console.log(currentByState);\n // console.log(dataF.weeks);\n for(let i = 0;i<dataF.weeks.length;i++){\n for(let j = 0;j<dataF.weeks[i].length;j++) {\n if (dataF.weeks[i][j].class === currentByState.classId) {\n dataF.weeks[i][j].name = currentByState.name;\n return dataF.weeks[i][j];\n }\n }\n }\n }", "title": "" }, { "docid": "af3d0f3bc1f7842f0f133212157d31e6", "score": "0.52852243", "text": "isNewWeek() {\n if (data.weekUse >= 12 && data.yearUse === (data.yearCurrent + 1)) {\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "696eeee6a700549e189f92addbe6ec7e", "score": "0.5271772", "text": "renderScheduledTasks() {\n // Getting an array of scheduled tasks\n const { tasks } = this.props;\n\n const sched = tasks.filter(item => moment(item.taskDate).isAfter(moment(), 'day') === true);\n // Mapping through our future, INACTIVE tasks\n if (sched) {\n return sched.map(item => (\n <ScheduleItem \n item={item}\n key={item._id}\n />\n )) \n } else {\n return (\n <p>nothing yet</p>\n );\n }\n }", "title": "" }, { "docid": "2de731f082a2750c068eb01e4dbdaf86", "score": "0.526471", "text": "function fitMinicalDate() {\n if (minifcViewSwitch) {\n mfc.fullCalendar('gotoDate', hfc.fullCalendar('getDate'));\n mTitle.html(mfc.fullCalendar('getView').title);\n }\n $('td.fc-today').siblings().addClass('fc-thisweek');\n }", "title": "" }, { "docid": "1b17a16e2b542071649b68d29e844e00", "score": "0.5251393", "text": "handleNextWeek(event) {\n \n // console.log('className.handleNextWeek event received');\n \n // var value = event.detail; // for captured events\n // var value = event.target.value; // for field values\n // console.log('className.handleNextWeek: value: ', JSON.stringify(value));\n\n try {\n\n // console.log('bookCalendar.handleNextWeek: startDateTime: ', JSON.stringify(this.startDateTime));\n\n // change the start date\n this.startDateTime.setDate(this.startDateTime.getDate() + 7);\n\n // refresh dates\n this.refreshDates();\n // console.log('bookCalendar.handleNextWeek: dates: ', JSON.stringify(this.dates));\n\n // refresh headers\n this.refreshHeaders();\n // console.log('bookCalendar.handleNextWeek: headers: ', JSON.stringify(this.headers));\n\n // refresh headers\n this.refreshTimeSlots();\n // console.log('bookCalendar.handleNextWeek: timeSlots: ', JSON.stringify(this.timeSlots));\n\n // refresh data\n this.refreshData();\n\n } catch (error) {\n toastError(this, 'Error', errorMessage(error));\n }\n }", "title": "" }, { "docid": "1a5dbb5f745b907c0befdd525b20c5cf", "score": "0.52512777", "text": "function getBusinessHoursEvents(wholeDay) { // 10697\n\t\tvar optionVal = options.businessHours; // 10698\n\t\tvar defaultVal = { // 10699\n\t\t\tclassName: 'fc-nonbusiness', // 10700\n\t\t\tstart: '09:00', // 10701\n\t\t\tend: '17:00', // 10702\n\t\t\tdow: [ 1, 2, 3, 4, 5 ], // monday - friday // 10703\n\t\t\trendering: 'inverse-background' // 10704\n\t\t}; // 10705\n\t\tvar view = t.getView(); // 10706\n\t\tvar eventInput; // 10707\n // 10708\n\t\tif (optionVal) { // `true` (which means \"use the defaults\") or an override object // 10709\n\t\t\teventInput = $.extend( // 10710\n\t\t\t\t{}, // copy to a new object in either case // 10711\n\t\t\t\tdefaultVal, // 10712\n\t\t\t\ttypeof optionVal === 'object' ? optionVal : {} // override the defaults // 10713\n\t\t\t); // 10714\n\t\t} // 10715\n // 10716\n\t\tif (eventInput) { // 10717\n // 10718\n\t\t\t// if a whole-day series is requested, clear the start/end times // 10719\n\t\t\tif (wholeDay) { // 10720\n\t\t\t\teventInput.start = null; // 10721\n\t\t\t\teventInput.end = null; // 10722\n\t\t\t} // 10723\n // 10724\n\t\t\treturn expandEvent( // 10725\n\t\t\t\tbuildEventFromInput(eventInput), // 10726\n\t\t\t\tview.start, // 10727\n\t\t\t\tview.end // 10728\n\t\t\t); // 10729\n\t\t} // 10730\n // 10731\n\t\treturn []; // 10732\n\t} // 10733", "title": "" }, { "docid": "f30f22d467469ab189dbefd3377629cf", "score": "0.5223798", "text": "printRemainingAgendaForTheWeek() {\n const today = Date.now();\n const startPosition = Math.floor((today - this.initiated) / 8.64e+7);\n for (let i = startPosition; i < startPosition + 7; i += 1) {\n if (this.schedule[i]) {\n const eventsForToday = Object.entries(this.schedule[i]);\n for (let j = 0; j < eventsForToday.length; j += 1) {\n const details = Object.entries(eventsForToday[j][1]);\n for (let k = 0; k < details.length; k += 1) {\n console.log(`${details[k][0]}: ${details[k][1]}`);\n }\n console.log('\\n');\n }\n }\n }\n }", "title": "" }, { "docid": "3854016c553a73585842b00ed500b6db", "score": "0.5221138", "text": "function isWorkingDay(idx) {\n return wHrs[idx] && wHrs[idx].isWorkingDay;\n }", "title": "" }, { "docid": "1113ee0f3e500c4be41c1e6c71e10d13", "score": "0.5220116", "text": "async setAllScheduling()\n {\n let schedule = await Data.getWeekScheduleData();\n let {periods} = schedule.shift();\n\n let time = moment();\n \n // correct all startTimes to current day and set to a momentjs object\n periods.map(per => per.startTime = moment(per.startTime).set('dayOfYear', time.dayOfYear()));\n\n // filter out any passed periods, only leave future periods\n periods = periods.filter(per => per.startTime.isAfter(time));\n periods.sort(per => per.startTime);\n const nextClass = periods.shift();\n \n \n this.setState({\n nextClass: nextClass != undefined && nextClass != null ? {\n start: toTimeString(nextClass.startTime),\n name: nextClass.name.toUpperCase()\n } : {start: 'School', name: null},\n remainingClasses: periods,\n nextDays: schedule.slice(0, 3) // is this obsolete? dependant on implementation of ScheduleScreen\n })\n }", "title": "" }, { "docid": "3a24ef9ede8b0fb96f76072380c14332", "score": "0.52190495", "text": "static _getWeek(dynamoDb) {\n const params = {\n TableName: process.env.GLOBAL_TABLE,\n Key: {\n key: 'TimelineWeek'\n }\n };\n return dynamoDb.get(params).promise();\n }", "title": "" }, { "docid": "30e90452c210a9298187885a8ac28cd8", "score": "0.520791", "text": "function removeIntervalWeekly(interval) {\r\n for (let i = 0; i < 4; i++) {\r\n removeInterval(addDaysToInterval(interval, i * 7), schedule);\r\n }\r\n}", "title": "" }, { "docid": "2ab010a1a90b8307eba0bedd6d3ca75e", "score": "0.5199255", "text": "function writeBlankSchedule(sheetName) {\n var sheet = SpreadsheetApp.getActiveSpreadsheet().getSheetByName(sheetName);\n sheet.clear();\n // top row\n sheet.getRange('B1:G1')\n .setValues([['Sunday','Monday', 'Tuesday', 'Wednesday', 'Thursday', 'Friday']])\n .setFontWeight('bold')\n // left column\n var leftColumn = 'A';\n var shiftRow = STARTING_ROW;\n ALL_SHIFTS.forEach(function(shift) {\n sheet.getRange(leftColumn+shiftRow)\n .setValue(shift)\n .setNumberFormat('@STRING@') // to avoid reading shift hours as dates\n .setFontWeight('bold')\n .setHorizontalAlignment('right');\n shiftRow += MAX_TUTORS; \n });\n // per shift per day\n var shiftBlocks = getAllShiftRanges();\n shiftBlocks.forEach(function(block) {\n sheet.getRange(block.range)\n .setBorder(true, true, true, true, false, false, \"black\", SpreadsheetApp.BorderStyle.SOLID);\n });\n}", "title": "" }, { "docid": "10c34092590349f66275eb1186935e35", "score": "0.51847523", "text": "function weekSchedulerUpdateHTML(weekSchedule) {\n for (i = 0; i < 7; i++) {\n for (j = 0; j < 24; j++) {\n hour_id = \"#\" + \"hour_\" + i + \"-\" + j;\n $(hour_id).prop(\"checked\", weekSchedule[i][j]);\n }\n }\n}", "title": "" }, { "docid": "6c7d42ec158f661be11448e870f583e0", "score": "0.5170489", "text": "getDaySchedule (date, cb) {\n var self = this;\n\n var start = moment(date).startOf('day').format('x');\n var end = moment(date).endOf('day').format('x');\n var params = self._processCustomMatchingParams({\n _custom: [{\n key: 'time',\n op: 'gte',\n value: start\n }, {\n key: 'time',\n op: 'lt',\n value: end\n }]\n });\n\n // Get all events of the day\n self._getFromCollectionSorted(util.COLLECTION_TYPE.EVENTS, params, {\n time: 1\n }, cb);\n }", "title": "" }, { "docid": "b83a961356bfa44232c3800c1593a5ed", "score": "0.5169611", "text": "function getAllSchedules() {\n globals.logger.debug('SCHEDULER: Getting all schedules');\n\n return globals.configSchedule;\n}", "title": "" }, { "docid": "2c8eb5928b1e80a0ffdfd5c9cd3b394f", "score": "0.51605964", "text": "get start() {\n const { showFixedNumberOfWeeks, showNeighboringMonth } = this.props;\n\n if (showFixedNumberOfWeeks || showNeighboringMonth) {\n const { activeStartDate, calendarType } = this.props;\n return -getDayOfWeek(activeStartDate, calendarType) + 1;\n }\n\n return 1;\n }", "title": "" }, { "docid": "f1ea32651693fcd1ae557fa579adf9c5", "score": "0.5156487", "text": "function getSchedule() {\n \n return 'footer';\n }", "title": "" }, { "docid": "b37db924329ba280cec7b7f12d44d65f", "score": "0.5155311", "text": "function isWeekDay(dateObject) {\n\treturn !isWeekend(dateObject)\n}", "title": "" }, { "docid": "d8bcafdc7cfab307c7ffa420c9a09adf", "score": "0.51511514", "text": "function onRunSchedule () {\n scheduleService().update();\n}", "title": "" }, { "docid": "e3c46f96286a5c6efc67afe6741cd742", "score": "0.51443523", "text": "function toggleHour(subject, schedule) {\n const name = subject.name;\n // Parse string format in data to the form\n const prsclass = parseSchedule(subject.sched);\n // For every period the class takes\n Object.keys(prsclass).forEach(function(day) {\n // For every hour the class takes\n prsclass[day].forEach(function(hour) {\n\n schedule[day][hour] = subject.name;\n })\n })\n\n return schedule;\n}", "title": "" }, { "docid": "26b3d6268399b6e3cca52dc40e07afa1", "score": "0.5143255", "text": "async weekly(workspaceId, params) {\n return await this.requestReport('weekly', workspaceId, params);\n }", "title": "" }, { "docid": "20fac1db5238b58cb3fc8dffbab97872", "score": "0.5141833", "text": "function getSetWeek (input) { // 2547\n var week = this.localeData().week(this); // 2548\n return input == null ? week : this.add((input - week) * 7, 'd'); // 2549\n } // 2550", "title": "" }, { "docid": "2f5b79402f371a1f0d6fc106e68839fb", "score": "0.51372385", "text": "function initScheduleOptionToggle() {\n\n // Show or hide schedule datetime option when page load.\n if (jQuery('#wpcd_compose_email_schedule_email_enable').is(\":checked\")) {\n jQuery('#wpcd_compose_email_schedule_email_datetime').parent().parent().show();\n jQuery('#wpcd-compose-email-save-draft').text(emailaddressesparams.i10n.schedule_later_btn);\n } else {\n jQuery('#wpcd_compose_email_schedule_email_datetime').parent().parent().hide();\n jQuery('#wpcd-compose-email-save-draft').text(emailaddressesparams.i10n.save_draft_btn);\n }\n\n // Show or hide schedule datetime option on enable or disable.\n jQuery('#wpcd_compose_email_schedule_email_enable').on('click', function (e) {\n if (jQuery(this).is(\":checked\")) {\n jQuery('#wpcd_compose_email_schedule_email_datetime').parent().parent().show();\n jQuery('#wpcd-compose-email-save-draft').text(emailaddressesparams.i10n.schedule_later_btn);\n } else {\n jQuery('#wpcd_compose_email_schedule_email_datetime').parent().parent().hide();\n jQuery('#wpcd-compose-email-save-draft').text(emailaddressesparams.i10n.save_draft_btn);\n }\n });\n }", "title": "" }, { "docid": "af80a95bc2a24e304afec0c83562bf49", "score": "0.5135852", "text": "function createSchedule()\n{\n\tgapi.client.load('calendar','v3',startScheduling);\n}", "title": "" }, { "docid": "db82bd63f362723ff67b5b1c3f2226ae", "score": "0.5133248", "text": "function scheduleTimeBasedJobs() {\n for (var i = 0; i < config.rules.length; i++) {\n if (config.rules[i].if.schedule) {\n scheduleTimeBasedJob(config.rules[i]);\n }\n }\n console.log(' -- All time based schedule jobs set.');\n}", "title": "" }, { "docid": "3503825348fcab8ad3572582f7c2ec75", "score": "0.51324767", "text": "function Schedule() {\n const Appointment = ({ children, style, ...restProps }) => (\n <Appointments.Appointment\n {...restProps}\n style={{\n ...style,\n backgroundColor: theme.primary[1],\n borderRadius: 8,\n }}>\n {children}\n </Appointments.Appointment>\n );\n\n // const schedule = [{\n // \"date\": \"2021-10-16\",\n // \"events\": [\n // { startDate: \"2021-10-16T10:00\", endDate: \"2021-10-16T11:30\", title: \"Check-in\" },\n // { startDate: \"2021-10-16T11:30\", endDate: \"2021-10-16T13:00\", title: \"Opening Ceremony\" },\n // { startDate: \"2021-10-16T13:00\", endDate: \"2021-10-17T12:00\", title: \"Hacking\"},\n // { startDate: \"2021-10-16T15:00\", endDate: \"2021-10-16T15:30\", title: \"MLH CTF\"},\n // { startDate: \"2021-10-16T15:30\", endDate: \"2021-10-16T16:30\", title: \"MLH Mini-Event\"},\n // { startDate: \"2021-10-16T17:00\", endDate: \"2021-10-16T18:00\", title: \"WiCS Kahoot + Discussion\"},\n // { startDate: \"2021-10-16T18:30\", endDate: \"2021-10-16T19:30\", title: \"RnD Workshop\"},\n // { startDate: \"2021-10-16T19:30\", endDate: \"2021-10-16T20:30\", title: \"Blueprint Workshop\"},\n // ]\n // }, {\n // \"date\": \"2021-10-17\",\n // \"events\": [\n // { startDate: \"2021-10-17T10:00\", endDate: \"2021-10-17T10:00\", title: \"Submission Reminder\"},\n // { startDate: \"2021-10-16T13:00\", endDate: \"2021-10-17T12:00\", title: \"Hacking\"},\n // { startDate: \"2021-10-17T13:00\", endDate: \"2021-10-17T15:00\", title: \"Judging\"},\n // { startDate: \"2021-10-17T15:30\", endDate: \"2021-10-17T16:00\", title: \"Closing Ceremony\"},\n // ]\n // }];\n const schedule = [\n {\"date\": \"2022-04-02\"},\n {\"date\": \"2022-04-03\"}\n ];\n return (\n <Card backgroundColor={\"white\"}\n sideBar={theme.primary[1]}>\n <h1 style={{color: \"black\"}}\n className=\"display-4 theme-font\">Schedule</h1>\n <div className=\"row mb-3\"\n style={{ marginLeft: -50, marginRight: -50, paddingLeft: 25 }}>\n <Grid container\n spacing={3}>\n {schedule.map((item) => \n <Grid item\n key={item[\"date\"]}\n md={6}\n xs={12}>\n <Scheduler\n data={item[\"events\"]}>\n <ViewState\n currentDate={item[\"date\"]}\n />\n <DayView\n startDayHour={9}\n endDayHour={23}\n />\n <Appointments\n appointmentComponent={Appointment}\n />\n </Scheduler>\n </Grid>\n )}\n </Grid>\n </div>\n </Card>\n );\n}", "title": "" }, { "docid": "3858fb1946a56fbd0e16b054785fd54a", "score": "0.5114129", "text": "async initNazarWeeklySetTask() {\n\t\tconst { tasks } = this.client.schedule,\n\t\t\tnazarTaskName = 'fetchNazarWeeklySet';\n\n\t\tif (!tasks.some((task) => task.taskName === nazarTaskName)) {\n\t\t\tawait this.client.schedule.create(nazarTaskName, '30 6 * * 2', {});\n\t\t}\n\t}", "title": "" }, { "docid": "974a6cc91c1be7c28d26cf0fa1402b14", "score": "0.51069576", "text": "updateWeek(event) {\n let clickedWeek = event.detail.week;\n this.currentWeek = clickedWeek;\n this.dates = new Date().getDatesFromWeekNumber(clickedWeek);\n clickedWeek == this.now.getCurrentWeekNumber() ? \n this.currentMonth = this.now.getMonth() + 1 :\n this.currentMonth = this.dates[0].getMonth() + 1;\n this.fetchNotes();\n }", "title": "" }, { "docid": "56f3e2aafec8775bc56f1494d58d1aa0", "score": "0.51028854", "text": "function bounds_last_week() {\n\n\tconst end_picker_initial_date = getSunday(new Date());\n\tsetSpanDaysBackward(end_picker_initial_date, 7);\n\n\n\tconst start_timestamp = start_picker.getDate().toISOString();\n\tconst end_timestamp = end_picker.getDate().toISOString();\n\n\tconst query_args_dict = {\n\t\t\"start-timestamp\": start_timestamp,\n\t\t\"end-timestamp\": end_timestamp,\n\t};\n\n\trequery_tables(query_args_dict);\n}", "title": "" }, { "docid": "799ff6d3da7673a7b8d6062a1fae7403", "score": "0.50947505", "text": "handlePreviousWeek(event) {\n \n // console.log('className.handlePreviousWeek event received');\n \n // var value = event.detail; // for captured events\n // var value = event.target.value; // for field values\n // console.log('className.handlePreviousWeek: value: ', JSON.stringify(value));\n\n try {\n\n // console.log('bookCalendar.handlePreviousWeek: startDateTime: ', JSON.stringify(this.startDateTime));\n\n // change the start date\n this.startDateTime.setDate(this.startDateTime.getDate() - 7);\n\n // refresh dates\n this.refreshDates();\n // console.log('bookCalendar.handlePreviousWeek: dates: ', JSON.stringify(this.dates));\n\n // refresh headers\n this.refreshHeaders();\n // console.log('bookCalendar.handlePreviousWeek: headers: ', JSON.stringify(this.headers));\n\n // refresh headers\n this.refreshTimeSlots();\n // console.log('bookCalendar.handlePreviousWeek: timeSlots: ', JSON.stringify(this.timeSlots));\n\n // refresh physicians list based on specialtyId\n // this will trigger an appointment/google event data refresh\n this.refreshData();\n\n } catch (error) {\n toastError(this, 'Error', errorMessage(error));\n }\n }", "title": "" }, { "docid": "22bf1381fe58bd20fe10c36571e35480", "score": "0.5089027", "text": "function dateAvailable(date, schedule) {\r\n const temp = largestIndex(date, schedule);\r\n if (temp == -1) return false;\r\n return date >= schedule[temp].start && date < schedule[temp].end && schedule[temp].status == \"available\";\r\n}", "title": "" }, { "docid": "1be289da3e9773edb879da729420285b", "score": "0.5086786", "text": "function showCalendar (schedule){\r\n\t\tvar cal = {\r\n\t\t\theader: {\r\n\t\t left: '',\r\n\t\t center: '',\r\n\t\t right: '',\r\n\t\t },\r\n\t\t minTime: \"08:00:00\",\r\n\t\t maxTime: \"22:00:00\",\r\n\t\t\tviews: {\r\n\t\t \tsettimana: {\r\n\t\t\t \ttype: 'agendaWeek',\r\n\t\t\t \tduration: {days: 7},\r\n\t\t\t \tcolumnFormat: 'dddd',\r\n\t\t\t \thiddenDays: [0]\r\n\t\t\t },\r\n\t\t },\r\n\t\t defaultView: 'settimana',\r\n\t\t events: []\r\n\t\t};\r\n\r\n\t\tfor(var key in schedule){\r\n\t\t\tfor(var i = 0; i < schedule[key].meeting.length; i++){\r\n\t\t\t\tvar event = {\r\n\t\t\t\t\ttitle: key,\r\n\t\t\t\t\teditable: false\r\n\t\t\t\t};\r\n\r\n\t\t\t\t// break meeting day\r\n\t\t\t\tvar day = schedule[key].meeting[i].day.match(/(M)|(W)|(Th|T)|(F)|(Sat\\.)/g);\r\n\t\t\t\tfor(var s = 0; s < day.length; s++){\r\n\t\t\t\t\tswitch(day[s]){\r\n\t\t\t\t\t\tcase \"M\":\r\n\t\t\t\t\t\t\tday[s] = 1;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"T\":\r\n\t\t\t\t\t\t\tday[s] = 2;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"W\":\r\n\t\t\t\t\t\t\tday[s] = 3;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"Th\":\r\n\t\t\t\t\t\t\tday[s] = 4;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"F\":\r\n\t\t\t\t\t\t\tday[s] = 5;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\tcase \"Sat.\":\r\n\t\t\t\t\t\t\tday[s] = 6;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\t\t\t\tevent.dow = day;\r\n\r\n\t\t\t\t// break down meeting time\r\n\t\t\t\tvar time = schedule[key].meeting[i].time.match(/[0-9]{1,2}[0-9]{2}/g);\r\n\t\t\t\tfor(var s = 0; s < time.length; s++){\r\n\t\t\t\t\tvar breakDown = time[s].split(/^([0-9]{1,2})([0-9]{2})$/);\r\n\t\t\t\t\tif(Number(breakDown[1]) < 8){\r\n\t\t\t\t\t\tbreakDown[1] = Number(breakDown[1]) + 12 + \"\";\r\n\t\t\t\t\t}\r\n\r\n\t\t\t\t\tif(s == 0){\r\n\t\t\t\t\t\tevent.start = breakDown[1] + \":\" + breakDown[2] + \":00\";\r\n\t\t\t\t\t}else{\r\n\t\t\t\t\t\tevent.end = breakDown[1] + \":\" + breakDown[2] + \":00\";\r\n\t\t\t\t\t}\r\n\t\t\t\t}\r\n\r\n\r\n\t\t\t\tcal.events.push(event);\r\n\t\t\t}\r\n\t\t}\r\n\r\n\t\t$('#calendar').fullCalendar('destroy');\r\n\t\t$('#calendar').fullCalendar('render');\r\n\t\t$('#calendar').fullCalendar(cal);\r\n\t}", "title": "" }, { "docid": "8a1fee90b65ae49a05c609e2327e3182", "score": "0.5075129", "text": "function quarantineSchedule(day) {\n // sanitize the input\n let dayLowerCase = day.toLowerCase();\n\n // use a switch\n switch (dayLowerCase) {\n case 'monday': \n return \"Read\";\n case 'wednesday': \n return \"Puzzles\";\n case 'friday': \n return \"Netflix\";\n case 'sunday': \n return \"Exercise\";\n default: \n return \"Code\";\n }\n}", "title": "" }, { "docid": "4adfc6b51edf8fd321d72a411586c720", "score": "0.50727135", "text": "function weekSchedulerJSONFromHTML(weekSchedule) {\n var hour_id;\n for (i = 0; i < 7; i++) {\n for (j = 0; j < 24; j++) {\n hour_id = \"#\" + \"hour_\" + i + \"-\" + j;\n weekSchedule[i][j] = $(hour_id).is(\":checked\");\n }\n }\n return JSON.stringify(weekSchedule);\n}", "title": "" }, { "docid": "d3c1921a038037111fe2d0372cf60970", "score": "0.5071918", "text": "function setSelectedWeek() {\n\t\tif (!that.managerMode) {\n\t\t\tthat.saveEnabled = false;\n\t\t\tloadTimeSheet();\n\t\t}\n\t}", "title": "" }, { "docid": "1b1f4342cf6693c9d2bf05eb52fc2bb7", "score": "0.5070509", "text": "function z(b){var d,e=c.businessHours,f={className:\"fc-nonbusiness\",start:\"09:00\",end:\"17:00\",dow:[1,2,3,4,5],// monday - friday\nrendering:\"inverse-background\"},g=H.getView();// `true` (which means \"use the defaults\") or an override object\n// copy to a new object in either case\n// if a whole-day series is requested, clear the start/end times\nreturn e&&(d=a.extend({},f,\"object\"==typeof e?e:{})),d?(b&&(d.start=null,d.end=null),w(s(d),g.start,g.end)):[]}", "title": "" }, { "docid": "6f654eafd2fe0ef9c605f2ccfb999d80", "score": "0.5066361", "text": "getSchedulesByRoomName() {\n const spreadsheet = getSpreadsheet();\n return {\n office: spreadsheet.getSheetByName('Office Schedule'),\n bedroom: spreadsheet.getSheetByName('Bedroom Schedule'),\n bathroom: spreadsheet.getSheetByName('Bathroom Schedule'),\n living_room: spreadsheet.getSheetByName('Living Room Schedule'),\n game_room: spreadsheet.getSheetByName('Game Room Schedule'),\n guest_room: spreadsheet.getSheetByName('Guest Room Schedule'),\n guest_bathroom: spreadsheet.getSheetByName('Guest Bathroom Schedule'),\n };\n }", "title": "" }, { "docid": "d53ec0a6f5190e78f941cf2a77c277e8", "score": "0.50663364", "text": "function loadScheduleDates(committeeElementId, protocolElementId, scheduleElementId) {\n reviewersElement = document.getElementById(\"reviewers\");\n if (reviewersElement != null) {\n reviewersElement.style.display = 'none';\n }\n onlyLoadScheduleDates(committeeElementId, protocolElementId, scheduleElementId);\n}", "title": "" }, { "docid": "becdb6a04b780a7127f87c421f36d0dc", "score": "0.50658447", "text": "function calculateSchedule(awakeHour, sleepHour, count, date, current) {\n //The current is the affected day time, if current is in this date, then thisd date will partially schedule\n var selected = []; var selected1 = []; var str = '';\n if (current == null) current = new Date(2020, 1, 1, 0, 0, 0, 0);\n var current1 = new Date(current); current1.setHours(0); current1.setMinutes(0); current1.setSeconds(0); current1.setMilliseconds(0);\n // if (date < current1) return { Selected: selected, LogInfo: str }; //if date is early than current date time, return empty directly, because go through will also return empty,but will affect nightshift\n var isWeekend = isWeekendDay(date);\n //Step 1: Specify awake interval\n str += '<h2>Step 1: Specify awake interval</h2>';\n\n var awakeInterval = sleepHour - awakeHour; if (awakeHour > sleepHour) awakeInterval += 24;\n if (count > awakeInterval) count = awakeInterval;\n str += '<p>Date:' + date + ' Is Weekend:' + isWeekend + '</p>';\n str += '<p>Ping Num:' + count + '</p>';\n str += '<p>awakeHour:' + awakeHour+ '</p>';\n str += '<p>sleepHour:' +sleepHour + '</p>';\n str += '<p>Awake interval:' + awakeInterval + '</p>';\n //Step 2:Specify awake interval probability(including specify, adjust, second adjust)\n str += '<h2>Step 2:Specify awake interval probability(including specify, adjust, second adjust)</h2>';\n var intervals = [];\n str += '<h3>Intervals:</h3>';\n var totalPrimary = 0; var totalPrimaryWeekend = 0; var countNonPrimary = 0; var excessUnit = 0; var excessUnitWeekend = 0; var minPrimary = 100; var minPrimaryWeekend = 100;\n if (awakeHour <= sleepHour) {\n for (var i = awakeHour; i < sleepHour; i++) {\n var dt = new Date(date); dt.setMinutes(0); dt.setSeconds(0); dt.setMilliseconds(0); dt.setHours(i);\n if (dt < current) continue; //if this interval has already passed, no neeed to schedule\n var found = primeTimeAwakeIntervals.find(function (element) {\n return element.awakeHour == i;\n });\n if (found != null) {\n if (isWeekend) {\n if (found.weekendPercentage < minPrimary) minPrimary = found.weekendPercentage;\n totalPrimary += found.weekendPercentage;\n var e = {DateTime:dt, Hour: i, Percentage: found.weekendPercentage, isPrimary: true, acculative: 0, isSelected: false,Over:0 };\n intervals.push(e);\n }\n else {\n if (found.weekDayPercentage < minPrimary) minPrimary = found.weekDayPercentage;\n totalPrimary += found.weekDayPercentage;\n var e = { DateTime: dt, Hour: i, Percentage: found.weekDayPercentage, isPrimary: true, acculative: 0, isSelected: false,Over:0 };\n intervals.push(e);\n }\n\n }\n else {\n countNonPrimary++;\n var e = { DateTime: dt, Hour: i, Percentage: 0, isPrimary: false, acculative: 0, isSelected: false,Over:0 };\n intervals.push(e);\n }\n }\n }\n else { //Night shift\n for (var i = awakeHour; i < 24; i++) {\n var dt = new Date(date); dt.setMinutes(0); dt.setSeconds(0); dt.setMilliseconds(0);dt.setHours(i);\n if (dt < current) continue;\n var found = primeTimeAwakeIntervals.find(function (element) {\n return element.awakeHour == i;\n });\n if (found != null) {\n if (isWeekend) {\n if (found.weekendPercentage < minPrimary) minPrimary = found.weekendPercentage;\n totalPrimary += found.weekendPercentage;\n var e = { DateTime: dt, Hour: i, Percentage: found.weekendPercentage, isPrimary: true, acculative: 0, isSelected: false,Over:0 };\n intervals.push(e);\n }\n else {\n if (found.weekDayPercentage < minPrimary) minPrimary = found.weekDayPercentage;\n totalPrimary += found.weekDayPercentage;\n var e = { DateTime: dt, Hour: i, Percentage: found.weekDayPercentage, isPrimary: true, acculative: 0, isSelected: false,Over:0 };\n intervals.push(e);\n }\n }\n else {\n countNonPrimary++;\n var e = { DateTime: dt, Hour: i, Percentage: 0, isPrimary: false, acculative: 0, isSelected: false,Over:0 };\n intervals.push(e);\n }\n }\n for (var i = 0; i < sleepHour; i++) {\n var dt = new Date(date); dt.setDate(date.getDate() + 1); dt.setHours(i); dt.setMinutes(0); dt.setSeconds(0); dt.setMilliseconds(0);\n if (dt < current) continue;\n var found = primeTimeAwakeIntervals.find(function (element) {\n return element.awakeHour == i;\n });\n if (found != null) {\n if (isWeekend) {\n if (found.weekendPercentage < minPrimary) minPrimary = found.weekendPercentage;\n totalPrimary += found.weekendPercentage;\n var e = { DateTime: dt, Hour: i, Percentage: found.weekendPercentage, isPrimary: true, acculative: 0, isSelected: false,Over:1 };\n intervals.push(e);\n }\n else {\n if (found.weekDayPercentage < minPrimary) minPrimary = found.weekDayPercentage;\n totalPrimary += found.weekDayPercentage;\n var e = { DateTime: dt, Hour: i, Percentage: found.weekDayPercentage, isPrimary: true, acculative: 0, isSelected: false,Over:1 };\n intervals.push(e);\n }\n }\n else {\n countNonPrimary++;\n var e = { DateTime: dt, Hour: i, Percentage: 0, isPrimary: false, acculative: 0, isSelected: false,Over:1 };\n intervals.push(e);\n }\n }\n }\n if (countNonPrimary > 0) {\n excessUnit = (100 - totalPrimary) / countNonPrimary;\n }\n intervals.forEach(function (e) {\n str += '<p>Date:' + e.DateTime+' Hour: ' + e.Hour + ' Percentage: ' + e.Percentage + ' IsPrimary: ' + e.isPrimary + '</p > ';\n });\n if (100 - totalPrimary > 0 && countNonPrimary > 0) {\n str += '<h3>We have to do First time adjust for non primary interval, since total 100 - totalPrimary > 0 and count of NonPrimary interval > 0</h3>';\n intervals.forEach(function (e) {\n if (!e.isPrimary) {\n e.Percentage = excessUnit;\n }\n });\n }\n str += '<h3>Intervals after adjust:</h3>';\n intervals.forEach(function (e) {\n str += '<p>Date:' + e.DateTime +' Hour:' + e.Hour + ' Percentage:' + e.Percentage.toFixed(2) + ' IsPrimary:' + e.isPrimary + '</p>';\n });\n if (excessUnit > minPrimary) {\n str += '<h3>We have to do Second time adjust for non primary interval, since some non primary probability > minimum of primary probability</h3>';\n }\n if (excessUnit > minPrimary) {\n var x1 = 100 - totalPrimary;\n var y1 = x1 - minPrimary * countNonPrimary;\n intervals.forEach(function (e) {\n if (e.isPrimary) {\n e.Percentage = e.Percentage + y1 * e.Percentage / totalPrimary;\n }\n else {\n e.Percentage = minPrimary;\n }\n });\n }\n str += '<h3>Intervals after second adjust:</h3>';\n intervals.forEach(function (e) {\n str += '<p>Date:' + e.DateTime +' Hour:' + e.Hour + ' Percentage:' + e.Percentage.toFixed(2) + ' IsPrimary:' + e.isPrimary + '</p>';\n });\n //Step 3:Pick distribution\n str += '<h2>Step 3:Pick distribution</h2>';\n var acculative = 0;\n intervals.forEach(function (e) {\n acculative += e.Percentage;\n e.acculative = acculative;\n });\n count = Math.min(count, intervals.length);\n do {\n var rnd = Math.random() * acculative;\n var found = intervals.find(function (e) {\n return e.acculative > rnd;\n });\n if(found!=null){\n if (!selected1.includes(found.Hour)) { selected.push({ Datetime: found.DateTime, Hour: found.Hour,Over:found.Over,Day:date }); selected1.push(found.Hour); }\n }\n } while (selected.length < count);\n intervals.forEach(function (e) {\n if (selected1.includes(e.Hour)) e.isSelected = true;\n });\n str += '<h3>Intervals list:</h3>';\n intervals.forEach(function (e) {\n str += '<p> Hour:' + e.Hour + ' Percentage:' + e.Percentage.toFixed(2) + ' IsPrimary:' + e.isPrimary;\n if (e.isSelected) str += ' Is selected:<input type=\"checkbox\" checked/>';\n str += '</p>';\n });\n\n //Step 4:Setup alarm\n str += '<h2>Step 4:Setup alarm(omitted)</h2>';\n\n selected.sort(function (a, b) {\n var dateA = new Date(a.Datetime), dateB = new Date(b.Datetime); return dateA - dateB;\n });\n return { Selected: selected, LogInfo: str };\n\n }", "title": "" }, { "docid": "0d662a65ab0d3773be9ea71dcaec0774", "score": "0.50604725", "text": "showScheduleType(event){\n this.setState({ schedule_type: !this.state.schedule_type })\n }", "title": "" }, { "docid": "b2d4c415f7f07da8612e51831425d365", "score": "0.5058278", "text": "function getScheduledItems(items, beginWeek) {\n return items.filter(item => {\n // Check if the item has a schedule planned\n if (item.frequency) {\n // Construct a moment recurring object based on the starting date and frequency from schedule\n const interval = utc(item.startDate).recur()\n .every(item.frequency).days()\n // Return true only if the current week matches one of the recurring dates\n return interval.matches(beginWeek)\n }\n })\n}", "title": "" }, { "docid": "616d96baab5858071e95cc44f133cf29", "score": "0.5041604", "text": "isNonWorkday(aDay) {\n return (aDay.day() === 0 || aDay.day() === 3 || aDay.day() === 6);\n }", "title": "" }, { "docid": "55d54249cd044c3729232e28f5ab6d00", "score": "0.504062", "text": "function schedule() {\n const id = schedule.id;\n Tick.cancelSchedule(isNaN(id) ? -1 : id);\n schedule.id = Tick.schedule(onschedule);\n }", "title": "" }, { "docid": "3868a320eb3b06ea34ec4f7fd9f913a8", "score": "0.50367916", "text": "function fn_showrepeatweek(sdayoreday)\n{\n \n var sweekday=$('#sweekday').val();\n var eweekday=$('#eweekday').val();\n \n var dataparam = \"oper=showrepeatweek&sweekday=\"+sweekday+\"&eweekday=\"+eweekday+\"&sdayoreday=\"+sdayoreday;\n $.ajax({\n type: 'post',\n url: \"class/newclass/class-newclass-lockclassautomation-ajax.php\",\n data: dataparam,\n beforeSend: function(){\n },\n success:function(data) {\n $('#repeatweekday').html(data);\n\n }\n });\n \n \n}", "title": "" } ]
488a57e4bc921d01ae7c0a235fbf2de2
Runs the actual game.
[ { "docid": "0d3668115beed0693714a59e00255fca", "score": "0.69064766", "text": "function runGame() {\r\n setInterval(drawScreen, 10);\r\n }", "title": "" } ]
[ { "docid": "d1003bc91605dd390d079ec51989d9d3", "score": "0.76636523", "text": "function runGame() {\n\tgameTimer();\n\tmoleAnimation();\t\n\tcheckIfMatch();\n\tendOfAnimation();\n}", "title": "" }, { "docid": "1837dcfdb7ef907ce314b3d257f0cf81", "score": "0.7559957", "text": "runGame() {\n this.gameMessage()\n this.multiplayer()\n this.outcome()\n this.restart()\n }", "title": "" }, { "docid": "c67d45de83518115f52c86faf782f6e6", "score": "0.7478165", "text": "run() {\n\t\t// Event polling\n\t\tlet e = new sdl.SDL_Event()\n\n\t\t// Calculate the amount of time that has passed since last tick.\n\t\tlet currentTime = sdl.SDL_GetTicks()\n\t\tlet oldTime = currentTime\n\t\tlet deltaTime = 0;\n\n\t\t// Create the event loop.\n\t\twhile (!this.quit) {\n\t\t\t// Calculate the delta time.\n\t\t\toldTime = currentTime\n\t\t\tcurrentTime = sdl.SDL_GetTicks()\n\t\t\tdeltaTime = (currentTime - oldTime) / 1000\n\n\t\t\t// Check for any incoming events.\n\t\t\twhile (sdl.SDL_PollEvent(e.ref()) != 0) {\n\t\t\t\t// Call the event handler.\n\t\t\t\tthis.event(e)\n\t\t\t}\n\n\t\t\t// Update the game elements.\n\t\t\tthis.update(deltaTime)\n\n\t\t\t// Display the game on the screen.\n\t\t\tthis.render()\n\t\t}\n\n\t\t// Event loop is complete, so close the game.\n\t\tthis.destroy()\n\t}", "title": "" }, { "docid": "3990bba3f709b55dc61236a7d2799233", "score": "0.7422756", "text": "function run()\n{\n\tupdate(); // updates object values\n\tautoPlay(); // control red paddle in single player mode\n\trefresh(); // updates components on screen\n\twin(detectWin()); // detect if there was a win and perform appropiate action\n}", "title": "" }, { "docid": "ca77ba79759b783731104d73ce875ac8", "score": "0.7228846", "text": "run() {\n this.moveSceneObjects();\n\n // user-loop: put user interaction here\n // move map, and sprites found onto the map\n if (this.map) {\n this.map.move();\n this.map.checkCollisions();\n }\n }", "title": "" }, { "docid": "f460fdc5df368ba4661f22510cf9d75e", "score": "0.7154969", "text": "function main()\n{\n console.log(\"main\");\n\n gfx.startup();\n gGame = gameCreate();\n\n gGameLoop = new GameLoop();\n gGameLoop.start();\n}", "title": "" }, { "docid": "7a7d2a9cf39438b7dc97831db9d026a9", "score": "0.71391785", "text": "function main()\n{\n\tcontext.fillStyle = \"#ccc\";\n\tcontext.fillRect(0, 0, canvas.width, canvas.height);\n\t\n\tvar deltaTime = getDeltaTime();\n\t\n\tswitch(gameState) {\n\t\tcase STATE_SPLASH:\n\t\t\trunSplash(deltaTime);\n\t\t\tbreak;\n\t\tcase STATE_GAME:\n\t\t\trunGame(deltaTime);\n\t\t\tbreak;\n\t\tcase STATE_GAMEOVER:\n\t\t\trunGameOver(deltaTime);\n\t\t\tbreak;\n\t}\n\tdrawFPS(deltaTime)\n}", "title": "" }, { "docid": "aafdc391949b14cca432faac1d0fa984", "score": "0.70652604", "text": "run() {\n\t\t\tif (this.setup) this.setup()\n\t\t\tif (this.loop) this.loop()\n\t}", "title": "" }, { "docid": "4c34938fc5e9eb0c3d188b4d62ae9747", "score": "0.7063223", "text": "function run() {\n\t\t\n\t\tdefineViews();\n\t\tstartAudio();\n\t\tloadIndex();\n\n\t}", "title": "" }, { "docid": "986f4fc9ea9fc09adbeed88c25ecb24f", "score": "0.7020349", "text": "function main() {\n // If the game shouldn't reset and shouldn't progress to the next level...\n if (!shouldReset && !nextLevel) {\n // The time when this function is called is recorded, subtracted from the last time this\n // function was called, and divided into seconds. This value is used to update the game's\n // entities.\n now = Date.now(), dt = (now - lastTime) / 1005.0;\n update(dt);\n // If the game isn't currently counting down, render the game.\n !countdown ? render() : null;\n // lastTime now holds the 'current' time, so it can be subtracted the next time the function\n // is called.\n lastTime = now;\n // The browser now knows we want to preform an animation, and it will call this function\n // every time te animation is to be updated,\n win.requestAnimationFrame(main);\n } else {\n // If the game should reset do so, if not, check if it should progress on to the next\n // level. If it should, do so, if not, do nothing.\n shouldReset ? endGame() : nextLevel ? levelUp() : null;\n }\n }", "title": "" }, { "docid": "5a6cde40857f8d85bfa3d6ba3ffc54eb", "score": "0.70161057", "text": "function gameplay() {\n\n simulation();\n gameDisplay();\n}", "title": "" }, { "docid": "0f829d4049faedb9b8efe4cb21bb784d", "score": "0.70069987", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n\n if(start){\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt); //set start to false in collision, already done\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n /* Check if game over, then show game over window and wait for\n * player to hit reset. This guarantees that the background animation\n * will still be playing while game over window is showed up.\n */\n if(gameOver){\n gameOverWindow();\n document.addEventListener(\"keydown\", function space(event){\n if(event.keyCode == 32){\n reset();\n //unbind the space listener\n document.removeEventListener(\"keydown\", space);\n }\n });\n\n }\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n\n }\n else{ //frame is stopped\n\n if(collideHeart || collideGem){\n delay = 0; // if player collides with items, then no need to\n //pause.\n }\n else{\n delay = 200; // if player wins or lose, then need to pause.\n }\n setTimeout(refresh, delay);\n //start running program by getting next frame\n win.requestAnimationFrame(main);\n }\n }", "title": "" }, { "docid": "f87f7d2bdf683eb65f1232c6c7fd54a1", "score": "0.6981801", "text": "function game() {\n dessineSerpent();\n dessinerPomme();\n detectionCollision();\n virifMangerPomme();\n gestionVieSerpent();\n }", "title": "" }, { "docid": "43be373bd848e5572df5ae26024ec75a", "score": "0.6980831", "text": "function run () {\n drawBg(gameSettings.bgColor, gameContext);\n ball.move(game.width, game.height, player);\n ball.draw();\n player.draw();\n}", "title": "" }, { "docid": "ea5dafa382643ecd5cb59c54dc85f2d7", "score": "0.6966859", "text": "function runProgram(){\n ////////////////////////////////////////////////////////////////////////////////\n //////////////////////////// SETUP /////////////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n // Constant Variables\n var FRAME_RATE = 60;\n var FRAMES_PER_SECOND_INTERVAL = 1000 / FRAME_RATE;\n \n // Game Item Objects\n\n\n // one-time setup\n var interval = setInterval(newFrame, FRAMES_PER_SECOND_INTERVAL); // execute newFrame every 0.0166 seconds (60 Frames per second)\n $(document).on('eventType', handleEvent); // change 'eventType' to the type of event you want to handle\n\n ////////////////////////////////////////////////////////////////////////////////\n ///////////////////////// CORE LOGIC ///////////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n /* \n On each \"tick\" of the timer, a new frame is dynamically drawn using JavaScript\n by calling this function and executing the code inside.\n */\n function newFrame() {\n \n\n }\n \n /* \n Called in response to events.\n */\n function handleEvent(event) {\n\n }\n\n ////////////////////////////////////////////////////////////////////////////////\n ////////////////////////// HELPER FUNCTIONS ////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n \n function endGame() {\n // stop the interval timer\n clearInterval(interval);\n\n // turn off event handlers\n $(document).off();\n }\n \n}", "title": "" }, { "docid": "95814a29bd231a148874823a6b9c84c6", "score": "0.69345516", "text": "startGame (){\n\n }", "title": "" }, { "docid": "4370d9b2afc12de11360c14459da30e3", "score": "0.69339675", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n\n /* the animation goes on unless gameOver = true from the gameEnd function\n */\n if (!gameOver) {\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.*/\n\n win.requestAnimationFrame(main);\n }\n }", "title": "" }, { "docid": "bc9da20dc5e46406cc934eb17f40ecb2", "score": "0.69237363", "text": "function main() { \n \n \n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "05523bbb3c03477672bca52628b053d8", "score": "0.6919226", "text": "function playGame(evt) {\n resetArrays();\n startGame(currentRound);\n printResults();\n}", "title": "" }, { "docid": "dd9c37bb9a33a6717cf4a0793e3157e1", "score": "0.69091624", "text": "function run() {\n\tgame.step();\n\t$(\"#round span\").text(game.round);\n}", "title": "" }, { "docid": "71fbb3fa4e1efea4eda8359f7f5e521f", "score": "0.69012845", "text": "function main() {\n\n // Get time delta information which is required if the game requires smooth animation\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n // Call update/render functions, pass along the time delta to our update function\n update(dt);\n render();\n\n // Set lastTime variable which is used to determine the time delta for the next time this function is called\n lastTime = now;\n\n // Browser's requestAnimationFrame function to call this function again as soon as the browser is able to draw another frame.\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "80601ee9f176a6a3a35168d2019c2fdb", "score": "0.6886601", "text": "mainLoop()\n\t{\n\t\t// save context\n\t\tContext.context.save();\n\t\t\n\t\t// check if canvas has been resized\n\t\tContext.resize();\n\t\t\n\t\t//clear screen before drawing\n\t\tself.clearScreen(\"#0f0000\");\n\t\t\n\t\t// update main collision rect\n\t\tself.mainRect.update(-(self.camX + 25), -(self.camY + 25));\n\t\t\n\t\t// move meteors\n\t\tself.updateMeteors();\n\t\t\n\t\t// move player on canvas\n\t\tself.movePlayer();\n\t\t\n\t\t// check for collision\n\t\tif (self.checkCollision())\n\t\t{\n\t\t\tself.player.takeDamage();\n\t\t}\n\t\t\n\t\t// draw to canvas\n\t\tself.drawGame();\t\n\t\t\n\t\t// update game timer\n\t\tself.gameTimer += 1/30;\n\n\t}", "title": "" }, { "docid": "5584661b3748eb9a31e0d8d3764a8755", "score": "0.68627614", "text": "function startGame() {}", "title": "" }, { "docid": "99060571ae1e33d0e7c84539f0f7bb76", "score": "0.68507314", "text": "function main() {\r\n /* Get our time delta information which is required if your game\r\n * requires smooth animation. Because everyone's computer processes\r\n * instructions at different speeds we need a constant value that\r\n * would be the same for everyone (regardless of how fast their\r\n * computer is) - hurray time!\r\n */\r\n var now = Date.now(),\r\n dt = (now - lastTime) / 1000.0;\r\n\r\n /* Call our update/render functions, pass along the time delta to\r\n * our update function since it may be used for smooth animation.\r\n */\r\n update(dt);\r\n render();\r\n\r\n /* Set our lastTime variable which is used to determine the time delta\r\n * for the next time this function is called.\r\n */\r\n lastTime = now;\r\n\r\n /* Use the browser's requestAnimationFrame function to call this\r\n * function again as soon as the browser is able to draw another frame.\r\n */\r\n\r\n if(!(victory || lose))\r\n requestID = win.requestAnimationFrame(main);\r\n else {\r\n win.cancelAnimationFrame(requestID);\r\n reset()\r\n }\r\n }", "title": "" }, { "docid": "3318810daeb32873dd477fdbb4651bf6", "score": "0.6833325", "text": "function game() {\n\tupdate();\n\trender();\n}", "title": "" }, { "docid": "26807dfebad0a07f364c3589920d89d4", "score": "0.68270427", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "26807dfebad0a07f364c3589920d89d4", "score": "0.68270427", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "26807dfebad0a07f364c3589920d89d4", "score": "0.68270427", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "f985926c56a619a0309df0797e2ee0ab", "score": "0.68264675", "text": "execute() {\n let pos = this.emptyRandomPosition;\n this._game.playAt(pos.row, pos.column);\n }", "title": "" }, { "docid": "459ee516362cab212d275c94499eaeb4", "score": "0.680548", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n timer += dt;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n\n if (!paused) {\n update(dt);\n }\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "e6c181fd8015a8c5fa7b976dedf450d7", "score": "0.68003446", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render();\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "1f3157f43dfd783b7313be86587f8e11", "score": "0.6798074", "text": "run() {\n this.canvas.clearCanvas();\n\n this.updateGameWindow();\n this.drawGameWindow();\n\n requestAnimationFrame(this.run.bind(this));\n }", "title": "" }, { "docid": "47bab744234cba1873a3dda2c3c37c9b", "score": "0.67942595", "text": "StartGame() {\n this.game.StartGame();\n this.Draw();\n }", "title": "" }, { "docid": "7b01dfa7e9422dea7dc22aa51452d1b2", "score": "0.67785573", "text": "function startGame() {\n//INITIALISATION\n\tconsole.clear();\n\tinitializeGame();\n\n//JEUX\n\tshowGameState();\n\tgameLoop();\n\t\n//AFFICHAGE RESULTAT\n\tshowGameWinner();\n}", "title": "" }, { "docid": "04477f44e3581dfa73beffe7b573a01a", "score": "0.6774135", "text": "static run() {\n gameIntervalReference = setInterval(function gameTick() {\n if (!GlobalGameState.current.paused) {\n Debug.log('[Game] Execute tick...');\n\n // update the global game run time\n Time.updateDeltaTime();\n\n // process the game tick through all systems\n // 1. process all user input first\n FoodSpawnSystem.tick();\n MovementSystem.tick();\n\n // 2. run all systems that require collisions after movement\n PlayerStateSystem.tick();\n TileBreakingSystem.tick();\n ScoreSystem.tick();\n\n // 3. always run render and gc last\n RenderSystem.tick();\n GarbageCollectorSystem.tick();\n\n LevelSystem.completeLoopRun();\n }\n\n // update debug info\n Debug.printDebugInfo();\n }, GlobalConfig.SLOW_MODE ? 1000 : GlobalConfig.IDEAL_TICK_TIME);\n }", "title": "" }, { "docid": "9c25565e81ed3d034668a67ac60475a7", "score": "0.6771413", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n global.dt = dt; //EN: to be used for animations in app.js\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render(dt);\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "0e846b47a3d10fc60faf41e57a97d30a", "score": "0.67490155", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation.\n */\n // var now = Date.now();\n\n // var dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n monsterWorld.player.setSprite();\n\n // update();\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n // lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "e405ba4627907d48cba667f3e192d72a", "score": "0.6743084", "text": "run(){\n if(!this.gameOver){ //Si no ha terminado el juego, entonces sigue corriendo\n this.checkSnakeState(); //Función que te permite validar si la snake come o no\n this.move(); //Ejecutamos la lógica del movimiento\n }\n }", "title": "" }, { "docid": "c2d75378ee3b9e3afcac783dfcdfa7cb", "score": "0.6738631", "text": "function main() {\n /*\n * Get our time delta information which is required if your game requires\n * smooth animation. Because everyone's computer processes instructions at\n * different speeds we need a constant value that would be the same for\n * everyone (regardless of how fast their computer is) - hurray time!\n */\n var now = Date.now(), dt = (now - lastTime) / 1000.0;\n\n /*\n * Call our update/render functions, pass along the time delta to our update\n * function since it may be used for smooth animation.\n */\n update(dt);\n render();\n\n /*\n * Set our lastTime variable which is used to determine the time delta for\n * the next time this function is called.\n */\n lastTime = now;\n\n /*\n * Use the browser's requestAnimationFrame function to call this function\n * again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "4524983080d2cc701f0fb840dde70b0e", "score": "0.6736981", "text": "function main() {\n if (gamePaused) return;\n\n if (gameOver) {\n gameOverScreen.classList = 'lose';\n gameOverScreen.querySelector('#result').textContent = 'game over!';\n return;\n }\n\n if (getBrickTotal() === 0) {\n gameOverScreen.classList = 'win';\n gameOverScreen.querySelector('#result').textContent = 'you won!';\n return;\n }\n\n window.requestAnimationFrame(main);\n update();\n draw();\n}", "title": "" }, { "docid": "5c1e1eb3bfc811a06315fb672aa737ea", "score": "0.67355025", "text": "function run(){\n\t\t\n\t\t//show tiles\n\t\tg_objWrapper.children(\".ug-tile\").show();\n\n\t\tif(g_temp.isFirstTimeRun == true){\n\t\t\tinitEvents();\n\t\t}\n\t\t\n\t\tg_objTileDesign.run();\n\t\t\t\t\n\t\tswitch(g_options.tiles_type){\n\t\t\tdefault:\n\t\t\tcase \"columns\":\n\t\t\t\trunColumnsType();\n\t\t\tbreak;\n\t\t\tcase \"justified\":\n\t\t\t\trunJustifiedType();\n\t\t\tbreak;\n\t\t\tcase \"nested\":\n\t\t\t\trunNestedType();\n\t\t\tbreak;\n\t\t}\n\t\t\n\t\t\n\t\tg_temp.isFirstTimeRun = false;\n\t}", "title": "" }, { "docid": "3493d1542379fc8ea8282543efd7699f", "score": "0.6734674", "text": "function main() {\r\n /* Get our time delta information which is required if your game\r\n * requires smooth animation. Because everyone's computer processes\r\n * instructions at different speeds we need a constant value that\r\n * would be the same for everyone (regardless of how fast their\r\n * computer is) - hurray time!\r\n */\r\n var now = Date.now(),\r\n dt = (now - lastTime) / 1000.0;\r\n\r\n /* Call our update/render functions, pass along the time delta to\r\n * our update function since it may be used for smooth animation.\r\n */\r\n update(dt);\r\n render();\r\n\r\n /* Set our lastTime variable which is used to determine the time delta\r\n * for the next time this function is called.\r\n */\r\n lastTime = now;\r\n\r\n /* Use the browser's requestAnimationFrame function to call this\r\n * function again as soon as the browser is able to draw another frame.\r\n */\r\n win.requestAnimationFrame(main);\r\n }", "title": "" }, { "docid": "08187161c1ff58e65d0b5b9b46e8ebd4", "score": "0.6733912", "text": "function main() {\n /* Get our time delta information which is required if your game\n * requires smooth animation. Because everyone's computer processes\n * instructions at different speeds we need a constant value that\n * would be the same for everyone (regardless of how fast their\n * computer is) - hurray time!\n */\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n /* Call our update/render functions, pass along the time delta to\n * our update function since it may be used for smooth animation.\n */\n update(dt);\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n /* Use the browser's requestAnimationFrame function to call this\n * function again as soon as the browser is able to draw another frame.\n */\n win.requestAnimationFrame(main);\n }", "title": "" }, { "docid": "ccc02b96d5cf2e3558eef77701f09514", "score": "0.67318916", "text": "function game_main_loop(){\r\n\t\t//resets the screen to prevent smearing\r\n\t\tctx.clearRect(0,0,canvas.width, canvas.height);\r\n\r\n\t\t//player\r\n\t\tdrawball();\r\n\t\ty += coordY;\r\n\t\trestart();\r\n\r\n\t\t//cpu 1\r\n\t\tcpu();\r\n\t\tccx += cpuX;\r\n\t\tccy += cpuY;\r\n\t\tcheck_bounce();\t\r\n\t\tcheck_collision();\r\n\r\n\t\t//cpu 2\r\n\t\tif(level_up >= 10){\r\n\t\t\tenemy_spawn();\r\n\t\t\tconsole.log(\"New Enemy Spawned\");\r\n\t\t\tenemy_bounce();\r\n\t\t\tXpos += espdX;\r\n\t\t\tYpos += espdY;\r\n\t\t}\r\n\t\t//cpu 3\r\n\t\tif(level_up >= 20){\r\n\t\t\tenemy_spawn1();\r\n\t\t\tenemy_bounce1();\r\n\t\t\tconsole.log(\"New Enemy Spawned\");\r\n\t\t\tXpos1 += espdX1;\r\n\t\t\tYpos1 += espdY1;\r\n\t\t}\r\n\t\t//game completion notification\r\n\t\tif(level_up >= 30){\r\n\t\t\talert(\"You have Successfully Completed The Possible Game\");\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "f06356d099a869b17906ed0f0358ad5d", "score": "0.6721102", "text": "function main() {\n // get time delta info\n var now = Date.now(),\n dt = (now - lastTime) / 1000.0;\n\n // update needs the time delta\n update(dt);\n render();\n\n /* Set our lastTime variable which is used to determine the time delta\n * for the next time this function is called.\n */\n lastTime = now;\n\n if (player.howManyLives() > 0) {\n win.requestAnimationFrame(main);\n } else {\n // stop animation, play sound, update lives shown,\n // and show reset button\n gameoverSound.play();\n updateLives();\n player.showReset().onclick = init;\n }\n }", "title": "" }, { "docid": "4b62aa3163a75f6b292324f753d5a21b", "score": "0.6709934", "text": "function startGame() {\n resetGame();\n buildGrid();\n generateMines();\n smileyAlive();\n displayFlagCount();\n}", "title": "" }, { "docid": "ecc051a1e342cd898c4e05aa9f096851", "score": "0.66977733", "text": "function main() {\n\n /**\n * The variables now and lastTime are used to measure a \"time delta\"\n * (dt) which is used to provide consistent movement speeds regardless of\n * hardware and platform. We update them here.\n */\n now = Date.now();\n dt = (now - lastTime) / 1000;\n\n\n /**\n * update is the function responsible for updating the properties of\n * Sprites; render is responsible for drawing them according to their\n * current properties.\n */\n update(dt);\n render();\n\n lastTime = now;\n\n if (!player.paused) {\n win.requestAnimationFrame(main);\n }\n }", "title": "" }, { "docid": "3bb6ea3e9c480129c1c63e66cc4b7aac", "score": "0.6694947", "text": "function main() {\n if (has_game_ended()) {\n restart();\n return;\n }\n hideButtons();\n changing_direction = false;\n setTimeout(function onTick() {\n clear_board();\n drawFood();\n move_snake();\n drawSnake();\n // Call main again\n main();\n }, ticks / mult)\n}", "title": "" }, { "docid": "48b408867b3b1550bd640f02cc911031", "score": "0.6689286", "text": "function run(){\n\t\t\t\t\n\t\t//show tiles\n\t\tg_objWrapper.children(\".ug-tile\").show();\n\n\t\tif(g_temp.isFirstTimeRun == true){\n\t\t\tinitEvents();\n\t\t}\n\t\t\n\t\tg_objTileDesign.run();\n\t\t\t\t\n\t\tswitch(g_options.tiles_type){\n\t\t\tdefault:\n\t\t\tcase \"columns\":\n\t\t\t\trunColumnsType();\n\t\t\tbreak;\n\t\t\tcase \"justified\":\n\t\t\t\trunJustifiedType();\n\t\t\tbreak;\n\t\t\tcase \"nested\":\n\t\t\t\trunNestedType();\n\t\t\tbreak;\n\t\t}\n\t\t\n\t\t\n\t\tg_temp.isFirstTimeRun = false;\n\t}", "title": "" }, { "docid": "bc8d07da2666541f5a9a71c59296fcf2", "score": "0.66889614", "text": "function main() {\r\n // i. Call the Start Game Function \r\n startFreeFall();\r\n }", "title": "" }, { "docid": "c2f78460f72c1d0b9bf740de40ae4ff2", "score": "0.66846395", "text": "function rungame(ctx) {\n\tvars = new Object();\n\tvars.highscore = 0;\n\tadd_audio();\n\tinitialize();\n\t\n var ONE_FRAME_TIME = 1000 / 60 ;\n\tvar mainloop = function() {\n\t\tupdate();\n\t\tdraw(ctx);\n\t}\n\tkeypress();\n\trestartGame();\n\tsetInterval( mainloop, ONE_FRAME_TIME );\n}", "title": "" }, { "docid": "c726d51a743f7841cef82d6cf5404d8f", "score": "0.66809714", "text": "function startGame() {\n init();\n generatedElements(\"foe\");\n inGame = true;\n foesInMovement();\n }", "title": "" }, { "docid": "2c2f364c609ba3382b7279f31d1677fc", "score": "0.66723955", "text": "function gameLoop(){\n console.log('gameLoop is running!');\n displayWorld();\n displayPacman();\n displayGhosts();\n displayScore();\n checkCollisions();\n moveInky();\n moveClyde();\n moveBlinky();\n movePinky();\n setTimeout(gameLoop, 150);\n}", "title": "" }, { "docid": "b8e3a882cc4478a6819c4e4662be054f", "score": "0.66548723", "text": "function run() {\n printGreeting();\n chooseStartingPlayer();\n switchPlayer();\n printStones(10);\n removeStones();\n sayWhoWon();\n}", "title": "" }, { "docid": "4b3bd143f13e38879d8cd996c377dfc7", "score": "0.66463125", "text": "function main(){\r\n if (gameOn) {\r\n if (gameCounter < 300) {\r\n gameCounter ++;\r\n }\r\n ctx.clearRect(0,0,w,h);\r\n starsUpdate();\r\n playerUpdate();\r\n } else if (startScreen) {\r\n if (doStartScreen) {\r\n ctx.clearRect(0,0,w,h);\r\n ctx.font = \"54px Roboto\";\r\n ctx.fillStyle = \"white\";\r\n ctx.fillText(\"Asteriods\", 300, 100);\r\n ctx.fillStyle = \"red\";\r\n ctx.font = \"36px Roboto\";\r\n startScreenCycle = 0;\r\n doStartScreen = false;\r\n } else {\r\n if (startScreenCycle == 51) {\r\n ctx.fillText(\"Press Enter to Start\", 250, 250);\r\n } else if (startScreenCycle == 101) {\r\n doStartScreen = true;\r\n }\r\n }\r\n if (13 in keysDown) {\r\n startScreen = false;\r\n gameOn = true;\r\n }\r\n startScreenCycle ++;\r\n } else if (gameEnd) {\r\n ctx.font = \"54px Roboto\";\r\n ctx.fillText(playerLost, 300, 100);\r\n ctx.fillStyle = \"red\";\r\n }\r\n requestAnimationFrame(main); //TODO: figure out how to reference main function in toggleGame, then only request Animationframe if gameOn is true.\r\n }", "title": "" }, { "docid": "166743ac47e8b32fe3f7737b6603a050", "score": "0.6641141", "text": "function actualRun(){\n\t\t\n\t\t//set preloader mode\n\t\tif(g_objPreloader){\n\t\t\tg_objPreloader.fadeTo(0,1);\n\t\t\tg_objWrapper.height(g_options.theme_preloading_height);\n\t\t\tg_functions.placeElement(g_objPreloader, \"center\", g_options.theme_preloader_vertpos);\n\t\t}\n\t\t\n\t\tinitEvents();\n\t\t\n\t\tg_tiles.run();\n\t\tg_lightbox.run();\n\t\t\n\t}", "title": "" }, { "docid": "f4e981504d17275a03e3df3e30a7869d", "score": "0.6613208", "text": "function MainLoop() {\n\tgame.update();\n\tgame.draw();\n\t// Call main loop at 30 fps\n\tsetTimeout(MainLoop, 33.33);\n}", "title": "" }, { "docid": "acdc74c5e532398a78aa64d7e0298024", "score": "0.66086894", "text": "function run() {\n easterBunnyHQ.viewController.render();\n }", "title": "" }, { "docid": "5056009764113bcf5c94a9e87ae90c51", "score": "0.6600456", "text": "function startGame() {\n startTimer();\n renderQuestion();\n }", "title": "" }, { "docid": "789355e5c4c517e128f07bf272cb30cd", "score": "0.659409", "text": "function runFunctions() {\n CoinToss();\n winner();\n }", "title": "" }, { "docid": "7c70a4b430c31994e74b3e443a8c6561", "score": "0.6593313", "text": "function game(){\n\tupdate();\n\tcollision();\n\trender();\n}", "title": "" }, { "docid": "627bed3088f44b2fdcc96238d036dc85", "score": "0.6585714", "text": "start() {\n\t\tthis.app.ticker.add(delta => this.gameLoop(delta));\n\t\tthis.gameRunning = true;\n\t}", "title": "" }, { "docid": "c220a09f799b288382c118feda557534", "score": "0.6577155", "text": "function execGameLogic() {\n var roll = dieRoll();\n var type = updatePositionAndGetType(roll);\n \n if (position === 100) {\n clearInterval(intervalID);\n }\n else if (position > 100) {\n position = position - roll;\n }\n \n renderGameResults(roll + \"-\" + type + position);\n}", "title": "" }, { "docid": "ead62f122bc77ac7da961656c07d6a0e", "score": "0.65738386", "text": "function run(){\n game_over = false;\n tiles = new Tiles(ctx);\n side_bar = new Sidebar();\n piece = new Piece( middle, no_step, random_color(), bkColor, bkColor, logged); \n next_piece = new Piece( middle, no_step, random_color(), bkColor, bkColor, logged); \n side_bar.show_next(next_piece);\n side_bar.show_score(tiles.score);\n side_bar.show_level(tiles.level);\n}", "title": "" }, { "docid": "777436e6420ba2c4ab0770c0b586a492", "score": "0.65673995", "text": "function run () {\n\n\t}", "title": "" }, { "docid": "3c5b78362f187e4f8e12918d75d8aea0", "score": "0.65610564", "text": "function main() {\n initWebGL(); // set up the webGL environment\n initInterface(); // setup the scoring interface\n initShaders(); // setup the webGL shaders\n initGrid(); // setup the play grid\n initSnakes(); // setup the snake\n initObjects(); // setup food and other items\n\n requestAnimationFrame(renderFrame); // render frame\n}", "title": "" }, { "docid": "d82f25809392d3f7c53bb75dd55d9d9d", "score": "0.6549771", "text": "function game() {\n // setBodyHeight();\n initScoreAndTimer();\n setColAndRowAmounts();\n createRow(rowAmount);\n createCol(colAmount);\n createImageCollection(rowAmount, colAmount);\n assignCards(rowAmount, colAmount);\n createCardListeners();\n}", "title": "" }, { "docid": "7dbbc4799f435eebf5dd93b685fb3505", "score": "0.6539294", "text": "startGame() {\n console.log(\"Game started !\")\n }", "title": "" }, { "docid": "3286e5220c5a1dc246e9c08d1e932539", "score": "0.6535421", "text": "function gameLoop() {\n moveShape();\n displayTetris();\n displayScore();\n}", "title": "" }, { "docid": "ff7f8e25b9d009718797f37ba1e43932", "score": "0.65341085", "text": "function runThis(){\n // thatPokemon.display(sketchRand);\n }", "title": "" }, { "docid": "2cbc30f28aad36ee3a88d676e9e39a2b", "score": "0.65254045", "text": "startGame() {\n this.nextFrame();\n this.draw();\n }", "title": "" }, { "docid": "0a30fdf3dee7b252fe302096573736cd", "score": "0.6522643", "text": "function main() {\r\n setScreen();\r\n showTimestamp();\r\n runTests();\r\n}", "title": "" }, { "docid": "a550fe733070258ff1b3d862f987b9fa", "score": "0.6517687", "text": "function gameLoop() {\n\n // if we are getting ready to start a new game, then just draw once.\n switch (state) {\n case 'gameLoading':\n doGameLoading();\n break;\n case 'gamePaused':\n case 'gameReady':\n break;\n case 'gameRunning':\n setTimeout(function () {\n requestAnimationFrame(gameLoop);\n updateGameBoard();\n }, 1000 / fps);\n break;\n case 'gameOver':\n doGameOver();\n break;\n }\n }", "title": "" }, { "docid": "6b890baf9201eb68f0c1424eae4a523a", "score": "0.65173393", "text": "function setUpGame() {\n \n // Add listener to new game button\n addNewGame();\n\n // Add listeners to difficulty button\n initDiffBtns();\n\n // Add listeners to the squares\n initSquareEvents();\n \n // Run the game\n runGame();\n}", "title": "" }, { "docid": "f38773ab98e0340626b0308bbf091e0f", "score": "0.65138954", "text": "function startGame () {\n\n gameSetup();\n randomizeTiles();\n createGameBoard();\n\n timeStarted = timeAssignment();\n\n}", "title": "" }, { "docid": "3287141887370e8ff2991edbb09a37ff", "score": "0.64968204", "text": "function HostGame() {\n\t// Your code goes here for hosting a game\n\tprint(\"Complete this method in Multiplayer.js\");\n}", "title": "" }, { "docid": "ceab710ad87478980c975fc3cae36654", "score": "0.6495235", "text": "run() {\n try {\n const start = time.now();\n\n inputs.pollGamepads();\n\n preUpdate.fire();\n\n framesToRun += config.framesPerUpdate;\n while(framesToRun >= 1) {\n if(canRunGame // mod fully loaded\n && !ig.loading // game is not loading\n && (ig.game.teleporting.timer <= 0 || ig.game.teleporting.levelData !== null) // game is not preloading\n && time.frames() < config.pauseOnFrame // tas is not paused\n && time.now() - start < MAX_UPDATE_TIME // more time left in the update cycle\n ) {\n framesToRun -= 1;\n\n\n preFrame.fire();\n\n inputs.inject();\n\n // update time\n time.step();\n this.rawTick = this.clock.tick();\n this.actualTick = this.hasFocusLost() ? 0 : this.rawTick;\n this.tick = this.actualTick * this.timeFactor;\n if(this.skipMode) {\n this.actualTick *= 8;\n this.tick *= 8;\n }\n // supposedly timeOffset could be non-zero, but im not sure what circumstances that would actually happen in\n // perhaps when sound is paused, but when the sound is resumed it will get set back to 0 anyway\n // if sound is ever patched then this will probably be obsolete or make more sense\n ig.soundManager.context.timeOffset = 0;\n\n // update the game\n // this ends up drawing multiple times when fastforwarding...\n ig.game.run();\n\n postFrame.fire();\n\n if(willLoad()) {\n reload.serialize(reload.LOAD_MAP);\n }\n } else {\n framesToRun = 0;\n }\n }\n\n postUpdate.fire();\n\n inputs.user.update();\n inputs.user.release(keys.WHEEL_X);\n inputs.user.release(keys.WHEEL_Y);\n\n window.requestAnimationFrame(this.run.bind(this));\n } catch(e) {\n this.error(e);\n }\n }", "title": "" }, { "docid": "1c8601459b56adae1440543fc3cd9237", "score": "0.64831185", "text": "startGame() {\n this.addNewGameGrid();\n this.resetGameStatus();\n this.updateStatus(\"\");\n this.addCurrentMoveSymbol();\n this.removeDraggedSymbolsFromDOM();\n }", "title": "" }, { "docid": "92cedb784f540b866a0945a3ce95b21a", "score": "0.64823353", "text": "function runGame(){\n $('#playX').on('click', () =>{\n playingAs = 'X';\n computer = 'O';\n var xWins = 0;\n var oWins = 0;\n turn();\n });\n $('#playO').on('click', () =>{\n playingAs = 'O';\n computer = 'X';\n var xWins = 0;\n var oWins = 0;\n computerTurn(randomId());\n });\n}", "title": "" }, { "docid": "146607eb23573eeb2b084038a36d5e4f", "score": "0.6480973", "text": "function main() {\n if (has_game_ended()) {\n snakeboard_ctx.font = '50px serif';\n snakeboard_ctx.textAlign = 'center';\n snakeboard_ctx.textBaseline = 'middle';\n snakeboard_ctx.fillStyle = 'red';\n snakeboard_ctx.fillText(\n 'GAME OVER',\n snakeboard.width / 2,\n snakeboard.height / 2\n );\n snakeboard_ctx.strokeText(\n 'GAME OVER',\n snakeboard.width / 2,\n snakeboard.height / 2\n );\n if (score > bestScore) {\n bestScore = score;\n document.getElementById(\n 'best-score'\n ).innerHTML = `Best score: ${bestScore}`;\n }\n return;\n }\n\n changing_direction = false;\n setTimeout(function onTick() {\n clear_board();\n drawFood();\n move_snake();\n drawSnake();\n drawTraps();\n // Repeat\n main();\n }, tickRate);\n}", "title": "" }, { "docid": "91cbeeff5924858913e491d4a8ad1d77", "score": "0.6474776", "text": "step() {\n this.gamepad.refresh()\n if (this.player.status === 0) { // If player is alive\n this.mentalDanger = 0;\n this.pathfinding();\n this.playerControl();\n this.monstersControl();\n this.setLight();\n //this.generate();\n this.spawnSubjects();\n this.manageAnimations();\n this.cooldowns();\n }\n if (this.keyboard.keyPressedOnce(\"Enter\")) {\n this.RELOAD = 1;\n }\n\n // If game is winned\n if (this.player.pos.y < MARGIN * 8 - 8)\n this.player.status = 3;\n }", "title": "" }, { "docid": "411b85e83867e5650f9182689227406d", "score": "0.6469922", "text": "startGame() {\n this.board.drawHTMLBoard();\n this.activePlayer.activeToken.drawHTMLToken();\n this.ready = true;\n }", "title": "" }, { "docid": "52ccda3e2ea1abc69fea82a16d5bc04b", "score": "0.646665", "text": "function main(){\r\n ctx.clearRect(0,0,w,h);\r\n starsUpdate();\r\n playerUpdate();\r\n laserBeam();\r\n if (gameOn) {requestAnimationFrame(main);}\r\n if (pause) {paused();}\r\n if (gameStart) {starter();}\r\n\r\n }", "title": "" }, { "docid": "512f6affbe9a61ed6076637a2052e434", "score": "0.6459139", "text": "function runProgram(){\n ////////////////////////////////////////////////////////////////////////////////\n //////////////////////////// SETUP /////////////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n // Constant Variables\n var FRAME_RATE = 60;\n var FRAMES_PER_SECOND_INTERVAL = 1000 / FRAME_RATE;\n\n var keys = {\n \"A\": 65,\n \"D\": 68,\n\n \"left\": 37,\n \"right\": 39,\n };\n\n var boardWidth = $('#board').width();\n var boardHeight = $('#board').height();\n \n // Game Item Objects\n function makeItem(x, y, velX, velY, id) {\n var itemInstance = {\n x: x,\n y: y,\n width: $(id).width(),\n originalW: $(id).width(),\n height: $(id).height(),\n left: x,\n right: x + $(id).width(),\n top: y,\n bottom: y + $(id).height(),\n speedX: velX,\n speedY: velY,\n id: id\n };\n return itemInstance;\n }\n\n var bottomPaddle = makeItem(((boardWidth / 2) - ($(\"#bottomPad\").width() / 2)), boardHeight - 50, 0, 0, \"#bottomPad\");\n\n var topPaddle = makeItem(((boardWidth / 2) - ($(\"#topPad\").width() / 2)), 20, 0, 0, \"#topPad\");\n\n var ball = makeItem(boardWidth / 2, boardHeight / 2, (Math.random() > 0.5 ? -3 : 3), (Math.random() > 0.5 ? -1 : 1), \"#ball\");\n\n //game vars\n var score1 = 0;\n var score2 = 0;\n var winningScore = prompt(\"How many points should be required to win?\")\n checkWinCount();\n var oneWin = \"Player One wins!\";\n var twoWin = \"Player Two wins!\";\n var challenge = false;\n\n // one-time setup\n var interval = setInterval(newFrame, FRAMES_PER_SECOND_INTERVAL); // execute newFrame every 0.0166 seconds (60 Frames per second)\n $(document).on('keydown', handleKeyD); // change 'eventType' to the type of event you want to handle\n $(document).on('keyup', handleKeyU);\n $(\"#oldSchool\").on('click', applyFilter);\n $(\"#challenge\").on('click', challengeMode);\n\n ////////////////////////////////////////////////////////////////////////////////\n ///////////////////////// CORE LOGIC ///////////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n /* \n On each \"tick\" of the timer, a new frame is dynamically drawn using JavaScript\n by calling this function and executing the code inside.\n */\n function newFrame() {\n drawItem(bottomPaddle);\n drawItem(topPaddle);\n drawItem(ball);\n paddleBounds(bottomPaddle);\n paddleBounds(topPaddle);\n ballBounds(ball);\n\n }\n \n /* \n Called in response to events.\n */\n function handleKeyD(event) {\n event.which == keys.A ? topPaddle.speedX = -5 : 0;\n event.which == keys.D ? topPaddle.speedX = 5 : 0;\n event.which == keys.left ? bottomPaddle.speedX = -5 : 0;\n event.which == keys.right ? bottomPaddle.speedX = 5 : 0;\n }\n\n function handleKeyU(event) {\n event.which == keys.A ? (topPaddle.speedX < 0 ? topPaddle.speedX = 0 : 0) : 0;\n event.which == keys.D ? (topPaddle.speedX > 0 ? topPaddle.speedX = 0 : 0) : 0;\n event.which == keys.left ? (bottomPaddle.speedX < 0 ? bottomPaddle.speedX = 0 : 0) : 0;\n event.which == keys.right ? (bottomPaddle.speedX > 0 ? bottomPaddle.speedX = 0 : 0) : 0;\n }\n\n ////////////////////////////////////////////////////////////////////////////////\n ////////////////////////// HELPER FUNCTIONS ////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n function drawItem(obj) {\n obj.y += obj.speedY; // update the position of paddleLeft along the y-axis\n obj.x += obj.speedX;\n $(obj.id).css(\"top\", obj.y); // draw paddleLeft in the new location, positionY pixels away from the \"top\"\n $(obj.id).css(\"left\", obj.x);\n\n redrawBounds(obj);\n }\n\n function redrawBounds(obj) {\n obj.left = obj.x;\n obj.right = obj.x + obj.width;\n obj.top = obj.y;\n obj.bottom = obj.y + obj.height;\n }\n\n function paddleBounds(obj) {\n if (obj.left < 0) {\n $(obj.id).css(\"left\", 0)\n obj.x = 0;\n }\n if (obj.right > boardWidth) {\n $(obj.id).css(\"left\", (boardWidth - obj.width))\n obj.x = (boardWidth - obj.width);\n }\n }\n\n function ballBounds(obj) {\n //wall collisions\n if (obj.left < 0) {\n $(obj.id).css(\"left\", 0)\n obj.x = 0;\n obj.speedX = -obj.speedX;\n }\n if (obj.right > boardWidth) {\n $(obj.id).css(\"left\", (boardWidth - obj.width))\n obj.x = (boardWidth - obj.width);\n obj.speedX = -obj.speedX;\n }\n\n //paddle collisions\n if (obj.top <= topPaddle.bottom && obj.left > topPaddle.left && obj.right < topPaddle.right && obj.top >= topPaddle.top && obj.speedY < 0) {\n obj.speedY = -obj.speedY;\n if (challenge == true) {\n changePaddle(topPaddle);\n }\n }\n if (obj.bottom >= bottomPaddle.top && obj.left > bottomPaddle.left && obj.right < bottomPaddle.right && obj.bottom <= bottomPaddle.bottom && obj.speedY > 0) {\n obj.speedY = -obj.speedY;\n if (challenge == true) {\n changePaddle(bottomPaddle);\n }\n }\n //paddle sides\n if (obj.left <= topPaddle.right && obj.left >= topPaddle.right - 15) {\n if (obj.top < topPaddle.bottom && obj.bottom > topPaddle.top) {\n obj.speedX = 3;\n }\n }\n if (obj.right >= topPaddle.left && obj.right <= topPaddle.left + 15) {\n if (obj.top < topPaddle.bottom && obj.bottom > topPaddle.top) {\n obj.speedX = -3;\n }\n }\n if (obj.left <= bottomPaddle.right && obj.left >= bottomPaddle.right - 15) {\n if (obj.bottom < bottomPaddle.bottom && obj.top > bottomPaddle.top) {\n obj.speedX = 3;\n }\n }\n if (obj.right >= bottomPaddle.left && obj.right <= bottomPaddle.left + 15) {\n if (obj.bottom < bottomPaddle.bottom && obj.top > bottomPaddle.top) {\n obj.speedX = -3;\n }\n }\n\n //victory triggers\n if (obj.y <= 0) {\n score2 ++;\n ball = makeItem(boardWidth / 2, boardHeight / 2, (Math.random() > 0.5 ? -3 : 3), 1, \"#ball\");\n updateScore(score2, \"#score2\");\n changePaddle(topPaddle, \"reset\");\n }\n if (obj.y >= boardHeight - obj.height) {\n score1 ++;\n ball = makeItem(boardWidth / 2, boardHeight / 2, (Math.random() > 0.5 ? -3 : 3), -1, \"#ball\");\n updateScore(score1, \"#score1\");\n changePaddle(bottomPaddle, \"reset\");\n }\n }\n\n function updateScore (newScore, tag) {\n $(tag).text(newScore);\n if (newScore == parseInt(winningScore)) {\n handleVictory(tag)\n }\n }\n\n function handleVictory (scoreTag) {\n if (scoreTag == \"#score1\") {\n $(\"#winner\").text(oneWin);\n }\n else {\n $(\"#winner\").text(twoWin);\n }\n $(\"#winner\").css(\"left\", (boardWidth / 2) - ($(\"#winner\").width() / 2));\n $(\"#winner\").css(\"top\", (boardHeight / 2) - ($(\"#winner\").height() / 2));\n $(\"#playAgain\").css(\"left\", (boardWidth / 2) - ($(\"#playAgain\").width() / 2) - 15);\n $(\"#playAgain\").css(\"top\", (boardHeight * 0.66) - ($(\"#playAgain\").height() / 2));\n setInterval(function() {\n endGame();\n }, 10);\n }\n\n function applyFilter() {\n $(\".game\").css(\"z-index\") == 3 ? $(\".game\").css(\"z-index\", -1) : $(\".game\").css(\"z-index\", 3);\n }\n\n function challengeMode() {\n challenge = true\n }\n\n function changePaddle(obj, action) {\n if (action == \"reset\") {\n $(obj.id).css(\"width\", obj.originalW);\n obj.width = obj.originalW;\n } else {\n $(obj.id).css(\"width\", (Math.random() * (2 * $(obj.id).width())));\n obj.width = $(obj.id).width();\n }\n }\n\n function checkWinCount() {\n if (Number.isInteger(parseInt(winningScore)) == false) {\n winningScore = prompt(\"Must be an integer\");\n checkWinCount();\n }\n else{}\n }\n \n function endGame() { \n // stop the interval timer\n clearInterval(interval);\n\n // turn off event handlers\n $(document).off();\n\n $(\"#ball\").css(\"left\", boardWidth * 4);\n }\n \n}", "title": "" }, { "docid": "11bdfcd080e6a675b04dc69db87f9fe3", "score": "0.6455069", "text": "function startNewGame() {\n\tsetUpGame(NUMROWS, NUMCOLS, NUMMINES);\n}", "title": "" }, { "docid": "0a2e18e059d92f69d7e2c37340afba03", "score": "0.6447646", "text": "function main(){\n // Repeatedly loop and update the game & draw the result on the screen\nlet loop=function(){\n update();\n draw();\n\n if(!gameOver){\nwindow.requestAnimationFrame(loop,screen.canvas);\n }else{\n GameOver(screen,win);\n }\n}\nwindow.requestAnimationFrame(loop, screen.canvas)\n }", "title": "" }, { "docid": "98cdeb5e4f474fda75b837b0934f3229", "score": "0.6444677", "text": "function startGame() {\n assert(HEAD.x === CONSENSUS.x && CONSENSUS.x === MAIN.x && MAIN.x === BANK.x,\n \"Error: panels are not horizontally aligned.\");\n Crafty.init(GAME.width, GAME.height);\n makeUI();\n startVideo();\n}", "title": "" }, { "docid": "3e2193a40dc58b3acdfa1a505454af0a", "score": "0.6435172", "text": "function playGame() {\n _clearGame();\n _startNextRound();\n}", "title": "" }, { "docid": "3ea65e863f14e274f0dabf2514345225", "score": "0.64295816", "text": "function C012_AfterClass_Sarah_Run() {\n\n\t// Build the regular interactions\n\tBuildInteraction(C012_AfterClass_Sarah_CurrentStage);\n\n\t// Draw the watching actors for ceremonies\n\tif ((C012_AfterClass_Sarah_CurrentStage >= 250) && (C012_AfterClass_Sarah_CurrentStage < 300)) C012_AfterClass_Dorm_DrawOtherActors();\n\n\t// Draw the actor alone or with the player depending on the stage\n\tif ((C012_AfterClass_Sarah_CurrentStage != 150) && (C012_AfterClass_Sarah_CurrentStage != 151)) {\n\t\tif ((C012_AfterClass_Sarah_CurrentStage != 410) && (C012_AfterClass_Sarah_CurrentStage != 3932) && (C012_AfterClass_Sarah_CurrentStage != 633) && (C012_AfterClass_Sarah_CurrentStage != 634) && (C012_AfterClass_Sarah_CurrentStage != 791) && (C012_AfterClass_Sarah_CurrentStage != 194)) {\n\t\t\tif (((C012_AfterClass_Sarah_CurrentStage >= 3090) && (C012_AfterClass_Sarah_CurrentStage <= 3099)) || ((C012_AfterClass_Sarah_CurrentStage >= 3901) && (C012_AfterClass_Sarah_CurrentStage <= 3999))) {\n\t\t\t\tDrawActor(\"Player\", 475, 0, 1);\n\t\t\t\tDrawActor(CurrentActor, 750, 0, 1);\n\t\t\t} else {\n\t\t\t\tDrawInteractionActor();\n\t\t\t\tif ((C012_AfterClass_Sarah_CurrentStage >= 392) && (C012_AfterClass_Sarah_CurrentStage < 400)) DrawActor(\"Player\", 600, 100, 1);\n\t\t\t}\t\t\n\t\t}\n\t} else {\n\t\tDrawActor(\"Sarah\", 500, 0, 1);\n\t\tDrawActor(\"Amanda\", 800, 0, 0.8);\n\t}\n\n}", "title": "" }, { "docid": "d9b106278d3523002c048dd4da9097ca", "score": "0.6427701", "text": "function runProgram(){\n ////////////////////////////////////////////////////////////////////////////////\n //////////////////////////// SETUP /////////////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n // Constant Variables\n var FRAME_RATE = 60;\n var FRAMES_PER_SECOND_INTERVAL = 1000 / FRAME_RATE;\n\n var KEY = {\n UP: 38,\n DOWN: 40,\n W: 87,\n S: 83,\n ENTER: 13,\n };\n\n var boardWidth = $('#board').width();\n var boardHeight = $('#board').height();\n\n // Game Item Objects\n function factory ($id){\n var object = {};\n \n object.id = $id; \n object.x = parseFloat($($id).css('left'));\n object.y = parseFloat($($id).css('top'));\n object.width = $($id).width();\n object.height = $($id).height();\n object.speedX = 0\n object.speedY = 0\n return object;\n\n return newObject;\n }\n \n // creating objects //\n var paddle1 = factory(\"#paddle1\");\n var paddle2 = factory(\"#paddle2\");\n var ball = factory(\"#ball\");\n var score1 = 0\n var score2 = 0\n\n // assigning default speeds //\n ball.speedY = (Math.round(Math.random()) * 6) - 3;\n ball.speedX = (Math.round(Math.random()) * 6) - 3;\n \n\n console.log(ball);\n // one-time setup\n var interval = setInterval(newFrame, FRAMES_PER_SECOND_INTERVAL); // execute newFrame every 0.0166 seconds (60 Frames per second)\n $(document).on('keydown', handleKeyDown); \n $(document).on('keyup', handleKeyUp); \n // change 'eventType' to the type of event you want to handle\n\n ////////////////////////////////////////////////////////////////////////////////\n ///////////////////////// CORE LOGIC ///////////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n\n /* \n On each \"tick\" of the timer, a new frame is dynamically drawn using JavaScript\n by calling this function and executing the code inside.\n */\n // makes it move but does not redraw\n function moveObject(objects){\n \n objects.y += objects.speedY\n objects.x += objects.speedX\n }\n // redraws the object after being moved\n function updatePosition(objects) {\n $(ball.id).css(\"left\", ball.x)\n $(ball.id).css('top', ball.y)\n $(paddle1.id).css(\"top\", paddle1.y)\n $(paddle2.id).css(\"top\", paddle2.y)\n }\n \n function newFrame() {\n //updateposition\n// paddle1 \n moveObject(paddle1);\n updatePosition(paddle1);\n //paddle2\n moveObject(paddle2);\n updatePosition(paddle2);\n //ball\n moveObject(ball);\n updatePosition(ball);\n // handle paddle/wall collisions\n if (checkPaddleColliion(paddle1)) {\n paddle1.y -= paddle1.speedY \n paddle1.speedY = 0\n }\n if(checkPaddleColliion(paddle2)) {\n paddle2.y -= paddle2.speedY \n paddle1.speedY = 0\n }\n // tracks whether ball is touching paddles\n if (doCollide(ball, paddle1)) {\n ball.speedX += 1.05\n ball.speedY = (Math.round(Math.random()) * 6) - 3;\n } else {\n ball.speedX = ball.speedX\n }\n if (doCollide(ball, paddle2)) {\n ball.speedX += -1.05\n ball.speedY = (Math.round(Math.random()) * 6) - 3;\n } else {\n ball.speedX = ball.speedX\n }\n // track ball/floor collisions //\n if (ball.y > boardHeight) {\n ball.speedY = -ball.speedY\n }\n if (ball.y < 0) {\n ball.speedY = -ball.speedY\n }\n // scoring + ball reset // \n if (ball.x > boardWidth) {\n ball.x = 400;\n ball.y = 200;\n score1 = score1 + 1;\n $('#scorebox1').text(score1);\n }\n if (ball.x < 0) {\n ball.x = 400;\n ball.y = 200;\n score2 = score2 + 1;\n $('#scorebox2').text(score2);\n }\n // Game ending //\n if (score1 > 10) {\n ball.speedY = 0\n ball.speedX = 0\n $('#board').text(\"Game Over, Player 1 Wins\");\n }\n if (score2 > 10) {\n ball.speedY = 0\n ball.speedX = 0\n $('#board').text(\"Game Over, Player 2 Wins\");\n }\n }\n\n /* \n Called in response to events.\n */\n //paddle controls//\n function handleKeyDown(event) {\n if (event.which === KEY.S) {\n console.log(\"S\");\n paddle1.speedY = 5;\n }\n if (event.which === KEY.W) {\n console.log(\"W\");\n paddle1.speedY = -5;\n }\n if (event.which === KEY.DOWN) {\n console.log(\"DOWN\");\n paddle2.speedY = 5;\n }\n if (event.which === KEY.UP) {\n console.log(\"UP\");\n paddle2.speedY = -5;\n }\n }\n function handleKeyUp(event) {\n if (event.which === KEY.S) {\n paddle1.speedY = 0;\n }\n if (event.which === KEY.W) {\n paddle1.speedY = 0\n }\n if (event.which === KEY.DOWN) {\n paddle2.speedY = 0\n }\n if (event.which === KEY.UP) {\n paddle2.speedY = 0\n }\n }\n \n\n ////////////////////////////////////////////////////////////////////////////////\n ////////////////////////// HELPER FUNCTIONS ////////////////////////////////////\n ////////////////////////////////////////////////////////////////////////////////\n \n // collision functions\n function doCollide(obj1, obj2) {\n // sides of the square1\n obj1.leftX = obj1.x;\n obj1.topY = obj1.y;\n obj1.rightX = obj1.x + obj1.width;\n obj1.bottomY = obj1.y + obj1.height; \n \n // sides of the square2\n obj2.leftX = obj2.x;\n obj2.topY = obj2.y;\n obj2.rightX = obj2.x + obj2.width;\n obj2.bottomY = obj2.y + obj2.height\n \n // TODO: Return true if they are overlapping, false otherwise\n if (obj1.leftX < obj2.rightX &&\n obj1.rightX > obj2.leftX && \n obj1.topY < obj2.bottomY &&\n obj1.bottomY > obj2.topY) {\n return(true);\n }\n else {\n return(false);\n }\n }\n // check for paddle collision //\n function checkPaddleColliion (obj) {\n // top and bottom of paddle //\n obj.topY = obj.y;\n obj.bottomY = obj.y + obj.height; \n // return true if overlapping with border \n if (obj.topY < 0 || obj.bottomY > boardHeight){\n return true;\n }\n else {\n return false;\n }\n }\n\n\n\n\n\n\n function endGame() {\n // stop the interval timer\n clearInterval(interval);\n\n // turn off event handlers\n $(document).off();\n }\n \n}", "title": "" }, { "docid": "71b1052dc301fc5e86c000a2929ac6cc", "score": "0.6423135", "text": "function run() {\n // current time\n var time = (new Date()).getMilliseconds();\n // run if scene is selected\n if (runningScene) {\n // running scene object\n var scene = scenes[runningScene];\n // execute app defined action - on frame\n if (scene.onFrame) {\n scene.onFrame();\n }\n // run default scene frame action - defined by framework\n scene.frame();\n }\n // continue \"thread\" only if it was stoped\n if (runThread) {\n // run again function after frameTime (minus processing frame time)\n setTimeout(run, Math.max(1,frameTime - (new Date()).getMilliseconds() + time));\n }\n }", "title": "" }, { "docid": "0f24eeb24b4142d9ef13dcffea78b66c", "score": "0.640299", "text": "function run() {\n nextGeneration();\n redrawGrid();\n}", "title": "" }, { "docid": "2f06e9c5c5c52d827578bb3efdea4721", "score": "0.6382778", "text": "function MainLoop() {\n\t// Update active game states.\n\tif(game.active)\n\t\tgame.update();\n\tif(leftGame.active)\n\t\tleftGame.update();\n\tif(rightGame.active)\n\t\trightGame.update();\n\tif(bottomGame.active)\n\t\tbottomGame.update();\n\t\n\t// Draw active game states.\n\tif(game.active)\n\t\tgame.draw();\n\tif(leftGame.active)\n\t\tleftGame.draw();\n\tif(rightGame.active)\n\t\trightGame.draw();\n\tif(bottomGame.active)\n\t\tbottomGame.draw();\n\t\n\t// Request next frame.\n\trequestAnimationFrame(MainLoop);\n\t\n\tframes++;\n}", "title": "" }, { "docid": "214961d6ea51790dd77b4cf303a77d5b", "score": "0.6380085", "text": "function playgame() {\n render();\n}", "title": "" }, { "docid": "5bdde45c673d595a39f6643a9c47215d", "score": "0.6374187", "text": "function launchGame(){\n\tvar x = new GameWindow();\n\tx.generate();\n\t/*\n\t$(\"body\").append(\n\t\t$(\"<div />\",{id:\"gamescreen\"}).append(\n\t\t\t$(\"<div />\",{id:\"gs_display\"}),\n\t\t\t$(\"<div />\",{id:\"gs_control\"}),\n\t\t\t$(\"<div />\",{id:\"counter\"})\n\t\t)\n\t);\n\t*/\n\tstartGame();\n}", "title": "" }, { "docid": "08cc9aeaefa80bb68b270545c7ce8034", "score": "0.6371324", "text": "run(){\n this.gameInterval = setInterval( this.gameLoop , this.timeInterval );\n }", "title": "" }, { "docid": "9fcd2304e98f54ff59dcde7e58e59f54", "score": "0.6360853", "text": "function mainGameLoop() {\n addPlayerToMap()\n addEnemy1ToMap()\n addEnemy2ToMap()\n addEnemy3ToMap()\n updateMap()\n drawBars()\n displayHP()\n displayMessages() \n updateStats()\n checkforBuff()\n floorInformation()\n updateWeaponsAndItems()\n}", "title": "" }, { "docid": "83f9ba78c8b1970dc1596a8781206689", "score": "0.636011", "text": "function game() {\r\n start();\r\n // control();\r\n}", "title": "" }, { "docid": "02aeb293e96d959ee8e70433861355e5", "score": "0.63563806", "text": "function play(){\r\n\tGAME.start();\r\n}", "title": "" }, { "docid": "9ed6df445ceae7ae147ad5094b4648e1", "score": "0.6351074", "text": "function game(){\n update();\n render();\n}", "title": "" } ]
12ab63802a5158ddf765e5bccb49a22a
34Century From Year /Introduction The first century spans from the year 1 up to and including the year 100, The second from the year 101 up to and including the year 200, etc. Task : Given a year, return the century it is in. Input , Output Examples : 1705 > 18 1900 > 19 1601 > 17 2000 > 20 Hope you enjoy it .. Awaiting for Best Practice Codes Enjoy Learning !!!
[ { "docid": "f1556fd4d0575c97e1a59d5e6b9d07ea", "score": "0.7865393", "text": "function century(year) {\n return Math.ceil(year / 100);\n}", "title": "" } ]
[ { "docid": "2a5cf7e2faf7392938a6ab61fa06a5a5", "score": "0.85345197", "text": "function centuryFromYear(year) {\n\n if (year % 100 === 0){\n console.log( year / 100);\n }else {\n \n var x= (year/100) + 1;\n console.log( Math.floor(x));\n }\n\n\n}", "title": "" }, { "docid": "2b183cfadf79165389749de5ea673f60", "score": "0.83057094", "text": "function centuryFromYear(year) {\n let century;\n let numStr = year.toString();\n\n if (numStr.length == 1) {\n let century = 1;\n console.log(century);\n } else if (numStr.length == 2 && numStr[1] == 0) {\n let first = numStr.substring(0,1);\n let num = parseInt(first);\n let century = num + 1;\n console.log(century);\n } else if (numStr.length == 2) {\n let first = numStr.substring(0,1);\n let num = parseInt(first);\n let century = num + 1;\n console.log(century);\n } else if (numStr.length == 3 && numStr[-1] == 0 && numStr[-2] == 0) {\n let first = numStr.substring(0,1);\n let num = parseInt(first);\n let century = num + 1;\n console.log(century);\n } else if (numStr.length == 4 && numStr[-1] == 0 && numStr[-2] == 0) {\n let first = numStr.substring(0,1);\n let num = parseInt(first);\n let century = num;\n console.log(century);\n } else if (numStr.length == 4) {\n let firstTwo = numStr.substring(0,2);\n let num = parseInt(firstTwo);\n let century = num + 1;\n console.log(century);\n }\n}", "title": "" }, { "docid": "c7c251cf0cfb1f75551b4dd2566558fe", "score": "0.8225616", "text": "function centuryFromYear(year) { \n \n if (year % 100 == 0) {\n \n var year = year; \n var century = Math.floor(year / 100);\n \n return century;\n \n } else {\n \n var year = year; \n var century = Math.floor(year / 100) + 1;\n \n return century;\n } \n \n}", "title": "" }, { "docid": "e338c049c74c57563aa67a7f5fccd865", "score": "0.81861615", "text": "function centuryFromYear(year) {\n \n var valueToCheck = year/100; // variable that will divide our year we pass in by 100\n \n if(year % 100 === 0) { // if statement that will check if our year is evenly divisible by 100 with no remainders \n return valueToCheck; //if the statement is true our varibale value will be returned \n }\n \n return Math.floor(valueToCheck) + 1; // if the statement is not evenly divisble by 100 the Math.floor will return a variable value \n // less than the largest integer & a value of one will be added to return the integer to the correct century \n}", "title": "" }, { "docid": "48783a17f4526a6f02dccdfd9dc580e1", "score": "0.81659627", "text": "function centuryFromYear(year){\n if (year % 100 === 0){\n return year/100\n }\n else {\n return Math.floor(year/100)+1\n }\n}", "title": "" }, { "docid": "6754bda3d955ae4bb7ea3b8efdff3df6", "score": "0.8125599", "text": "function century(year) {\n let century = 0;\n for(let i = 0; i < year; i++) {\n if(i % 100 == 0) {\n century++;\n }\n }\n return century;\n}", "title": "" }, { "docid": "7ba18c7218778ef5cecbf57491cfeaf2", "score": "0.8116553", "text": "function century(year) {\n for (let i = 0; i < 2021; i++) {\n if (year % 100 === 0) {\n return year / 100\n } else {\n return Math.floor(year / 100) + 1\n }\n }\n}", "title": "" }, { "docid": "6081a37d83b8225d97364b78d335ff0e", "score": "0.80713844", "text": "function century(year) {\n \n return Math.ceil(year/100);\n}", "title": "" }, { "docid": "66d0c011a0c8d71e6bcfb8705fa2c192", "score": "0.80264246", "text": "function century(year){\n\treturn Math.ceil(year/100)\n}", "title": "" }, { "docid": "4ca3afa073d3894fd1b41cd17fdb0117", "score": "0.8017886", "text": "function century(year) {\r\n // Finish this :)\r\n return Math.ceil(year / 100);\r\n}", "title": "" }, { "docid": "ad15bbb723b4ae25a21ca71eefe1172c", "score": "0.79637915", "text": "function century(year) {\n // each century is 1-100\n let century = 100;\n let date = year/century;\n\n if(year <= century) {\n return 1;\n } else if (date > Math.floor(date)){\n return Math.floor(date) +1;\n } else if (year > (date)){\n return date;\n }\n}", "title": "" }, { "docid": "12ae3f7e3b69571e86e6754ab229d681", "score": "0.7947284", "text": "function century(year) {\r\n return Math.ceil(year / 100);\r\n}", "title": "" }, { "docid": "02f47b2952fbc9910e9101bf4651bab0", "score": "0.7883071", "text": "function century(year) {\n let century = +String(year).slice(0, -2);\n let remainder = year % 100;\n if (remainder !== 0) century += 1;\n\n let last2Digits = century % 100;\n let lastDigit = century % 10;\n\n if ([11, 12, 13].includes(last2Digits)) {\n century += 'th';\n } else if (lastDigit === 1) {\n century += 'st';\n } else if (lastDigit === 2) {\n century += 'nd';\n } else if (lastDigit === 3) {\n century += 'rd';\n } else {\n century += 'th';\n }\n\n console.log(century);\n return century;\n}", "title": "" }, { "docid": "988b03fbe07a9943b301bec08624976e", "score": "0.7874989", "text": "function centuryFromYear(year) {\n return Math.floor((year - 1) / 100) + 1;\n}", "title": "" }, { "docid": "903ef5592b807256d46ac1bba5cf0832", "score": "0.7867322", "text": "function centuryFromYear(year) {\n return Math.floor((year - 1) / 100) + 1;\n}", "title": "" }, { "docid": "903ef5592b807256d46ac1bba5cf0832", "score": "0.7867322", "text": "function centuryFromYear(year) {\n return Math.floor((year - 1) / 100) + 1;\n}", "title": "" }, { "docid": "8a4e0bda7fa244fdeb2a7be8773e5cf7", "score": "0.78539485", "text": "function century(year) {\n\tvar x = Math.floor(year / 100);\n\tif (year % 100 === 0) return x;\n\telse return x + 1;\n}", "title": "" }, { "docid": "ea56d8bc435b089a7d4b17f3cbb4cab8", "score": "0.78096455", "text": "function century(year) {\n\treturn Math.ceil(year / 100); //using ceiling method to round up to nearest century (100)\n}", "title": "" }, { "docid": "87570ea5c4abcd9834961d638cc4ff9f", "score": "0.77671677", "text": "function century(year) {\n\treturn Math.floor((year - 1) / 100) + 1;\n}", "title": "" }, { "docid": "e31a88a546e9b8661777a2ca1dc15cad", "score": "0.7719958", "text": "function whatCentury(year) {\n let century = Math.ceil(year / 100);\n return century + (century < 20 ? \"th\" : [\"th\", \"st\", \"nd\", \"rd\"][century % 10] || \"th\")\n}", "title": "" }, { "docid": "52b7eb968200ffe7d929b2511203edd7", "score": "0.759195", "text": "function centuryFromYear(year) {\n\tlet cent = 0;\n\tlet remainder = 0;\n\tif (typeof year == \"number\") {\n\t\tcent = year / 100;\n\t\tremainder = year % 100;\n\n\t\tif (remainder === 0) {\n\t\t\treturn cent;\n\t\t} else {\n\t\t\tcent = (year - remainder) / 100;\n\t\t\treturn cent + 1;\n\t\t}\n\t} else {\n\t\tconsole.log(\"This is not a number\");\n\t}\n}", "title": "" }, { "docid": "f4bbcf81e0fd0990bed2ba220ceb4a01", "score": "0.7520742", "text": "function century(year) {\n let centuryNumber = Math.floor(year / 100) + 1;\n\n if (year % 100 === 0) {\n centuryNumber -= 1;\n }\n\n return String(centuryNumber) + centurySuffix(centuryNumber);\n}", "title": "" }, { "docid": "13443c46da58a38d6d19111c4512a470", "score": "0.7393607", "text": "function century(year) {\n let centuryCount = 0;\n while (year > 0){\n year = year - 100;\n centuryCount = centuryCount + 1;\n }\n return centuryCount;\n }", "title": "" }, { "docid": "6ce823af6ef44bd4575bcbda599b9b17", "score": "0.7040956", "text": "getFullYear(year) {\n let currentYear = (new Date()).getYear()\n let century = parseInt((new Date()).getFullYear() / 100, 10)\n\n if (this.preferPast && (year + 100) > currentYear) {\n century -= 1\n }\n\n return year + (century * 100)\n }", "title": "" }, { "docid": "57e9df120024875b4892192960bc9254", "score": "0.6961311", "text": "function getLeapYears(startYear, endYear) {}", "title": "" }, { "docid": "5eb8ee14813d5d9d47d7ef136ae685e2", "score": "0.6713398", "text": "function silly_years(year) {\n let result = [];\n\n while (result.length < 10){\n year += 1;\n \n let digits = year.toString().split(''); // ['1', '9', '7', '8']\n let firstNumStr = digits[0] + digits[1] //'19'\n let firstNum = Number(firstNumStr) //19\n\n let lastNumStr = digits[2] + digits[3]; //'78'\n let lastNum = Number(lastNumStr); //78\n\n let midNumStr = digits[1] + digits[2]; //'97'\n let midNum = Number(midNumStr);//97\n\n if (firstNum + lastNum === midNum) result.push(year)\n }\n\n return result;\n}", "title": "" }, { "docid": "0c134f318db7572ffceb70a981995d8e", "score": "0.66927266", "text": "function YearsBetween() {\n return(PerformedAt - OriginalYear)\n}", "title": "" }, { "docid": "12e51315e659f4327ebbb84b341aab28", "score": "0.6687788", "text": "function LeapyearCovert(year){\r\n let leapYear= year;\r\n let remainder = leapYear%4;\r\n if (remainder==0){\r\n console.log(\"this is leap year\");\r\n }else{\r\n console.log(\"this is not leapYear\");\r\n }\r\n \r\n}", "title": "" }, { "docid": "447116c975dee3939863ab27896afb3f", "score": "0.6666182", "text": "function getInterval(year) {\n if (year <= 1967)\n return 0;\n else if (year <= 1980)\n return 1;\n else if (year <= 1997)\n return 2;\n else return 3;\n}", "title": "" }, { "docid": "9ce71f7abe6a97a519cb2f17ededebce", "score": "0.6658747", "text": "function next_decade_year(temp_year){\r\n\tview_year(temp_year);\r\n}", "title": "" }, { "docid": "1c2919f67101d82778346cdb80b255c7", "score": "0.66296655", "text": "function leapYear(year) {\n // before Gregorian Calendar\n if (year < 1752) {\n console.log(year, year % 4 == 0);\n \n // after Gregorian Calendar\n } else {\n let res = (year % 400 == 0) || (year % 100 != 0 && year % 4 == 0);\n console.log(year, res);\n }\n}", "title": "" }, { "docid": "f1ee8dfbf0ea82e0b92e60ee2b9e943d", "score": "0.66249114", "text": "function getIslamicYearStart(year) {\n return (year - 1) * 354 + Math.floor((3 + 11 * year) / 30.0);\n}", "title": "" }, { "docid": "e06487145d3fd53b4f0035491dbf1893", "score": "0.66154003", "text": "function calAge1(birthYear){\n return 2040-birthYear;\n}", "title": "" }, { "docid": "b0e3e89d2b25d5bf97c90d194a3e17a7", "score": "0.6607618", "text": "function calAge(year){\n\tconsole.log(2020- year);\n}", "title": "" }, { "docid": "d1550d5734ac9a2a0366cb97e9de003a", "score": "0.6587649", "text": "function leapYears(num) {\n\t// Set i to the current year. \n\t// Set year to be i plus the number of years provided.\n\t// Create an array to store the results.\n\tvar i = new Date().getFullYear(), year = i + num, results = [];\n\t// Loop from the current year to the year provided. \n\tfor(i; i <= year; i++) {\n\t\t// If the year is evenly divisible by four and not evenly divisible by 100 push it in the resluts.\n\t\t// If the year is evenly divisible by four hundred, push it in the results array.\n\t\tif((!(i % 4) && (i % 100)) || !(i % 400)) results.push(i);\n\t}\t\n\t//return the results array;\n\treturn results;\n}", "title": "" }, { "docid": "ef71de57a3dcf20808e44df04f055d57", "score": "0.6583149", "text": "function getYear4(){\n\nvar today = new Date();\nvar yyyy = today.getFullYear();\nvar yyyy = yyyy+\"0\"; // array conversion\nreturn yyyy[3];\n\n}", "title": "" }, { "docid": "63ce4a19ff08343e8fedbbb35d8144ef", "score": "0.6575682", "text": "function years()\n {\n let result=\"\";\n let today=new Date();\n let yyyy = today.getFullYear();\n today=yyyy;\n let i=0;\n while(i<20)\n {\n if (today%4==0)\n {\n result=`${result}, ${today}`;\n i++;\n today++;\n }\n else\n today++;\n }\n return result;\n }", "title": "" }, { "docid": "bc071b0899689b7421f42b3b82bd0d92", "score": "0.6551332", "text": "function calcAge(year) {\n console.log(2018-year);\n}", "title": "" }, { "docid": "07bc1550fda8d788a5e71c6023ad2141", "score": "0.6534353", "text": "function yearConverter(twoDigitString){\n\tlet twoDigitNum = parseInt(twoDigitString.trim());\n\tlet fourDigitString;\n\tif(twoDigitNum <= 50){\n\t\tfourDigitString = \"20\" + twoDigitString;\n\t}else{\n\t\tfourDigitString = \"19\" + twoDigitString;\n\t}\n\treturn fourDigitString;\n}", "title": "" }, { "docid": "9e47343b217f36ed9a1b1d5fd39d4f05", "score": "0.65283644", "text": "function getYear( str ){\n\nvar year=\"\";\nvar posIni=0;\n\nposIni=str.lastIndexOf(\"/\");\nyear=str.substring(posIni+1,str.length+1);\n\nreturn (year);\n\n }", "title": "" }, { "docid": "74b0d0d0ddc94a2ff97d05675bbbcb41", "score": "0.65209824", "text": "function calcAge1(birthYear){\r\n return 2021 - birthYear;\r\n}", "title": "" }, { "docid": "a3cbde78894da059819da6aaef923a30", "score": "0.6514372", "text": "function getYearFromAbbreviation(year) {\n return round(callDateGet(getNewDate(), 'FullYear') / 100) * 100 - round(year / 100) * 100 + year;\n }", "title": "" }, { "docid": "e647d8c36eae2a938f41abf3a7682892", "score": "0.6500876", "text": "function getYear3(){\n\nvar today = new Date();\nvar yyyy = today.getFullYear();\nvar yyyy = yyyy+\"0\"; // array conversion\nreturn yyyy[2];\n\n}", "title": "" }, { "docid": "4f081cdb44337f959b8334b4d48dc11d", "score": "0.64962673", "text": "function getYearFromAbbreviation(year) {\n return round(new date().getFullYear() / 100) * 100 - round(year / 100) * 100 + year;\n }", "title": "" }, { "docid": "96ff3989ce411861de4ab4198d724240", "score": "0.6482313", "text": "yearLeft(birthday, expectedAge, planet){\n let today = new Date();\n let dd = today.getDate();\n let mm = today.getMonth()+1;\n let yyyy = today.getFullYear();\n\n let age = this.getAge(birthday);\n let yearsLeft = expectedAge - age;\n const birthdate = new Date(birthday);\n let deathYear = ((birthdate.getFullYear())+yearsLeft);\n\n if (yyyy > deathYear) {\n let yearsLivedOver = (yyyy-deathYear)-age;\n yearsLeft=0-yearsLivedOver;\n }\n\n if (planet == \"mercury\") {deathYear = yearsLeft*.24}\n else if (planet == \"venus\") {deathYear = yearsLeft*.62}\n else if (planet == \"mars\") {deathYear = yearsLeft*1.88}\n else if (planet == \"jupiter\") {deathYear = yearsLeft*11.86}\n\n return deathYear;\n }", "title": "" }, { "docid": "648b39ff218ecf4b6388bfc4e3d2f8d9", "score": "0.6470423", "text": "function fl4() {\n\nvar startRange = 1000;\nvar endRange = 5000;\nvar leapYears = [];\n\n for (var i = startRange; i < endRange; i++) {\n\n if ( (i % 100 === 0) && (i % 400 === 0) ) {\n leapYears.push(i);\n } else if ( (i % 4 === 0) && (i % 100 !== 0) ) {\n leapYears.push(i);\n }\n }\n console.log(leapYears);\n}", "title": "" }, { "docid": "e9a075e2b56f6adf75ef3465325b1d62", "score": "0.6437912", "text": "function dayOfProgrammer(year) {\n if (year >= 1700 && year <= 1917) {\n if (year % 4 == 0) {\n let dayCount = 12;\n let monthCount = 9;\n return `${dayCount}.0${monthCount}.${year}`\n\n } else {\n let dayCount = 13;\n let monthCount = 9;\n return `${dayCount}.0${monthCount}.${year}`\n }\n } else if (year == 1918) {\n let dayCount = 26;\n let monthCount = 9;\n return `${dayCount}.0${monthCount}.${year}`\n }\n else if (year >= 1919 && year <= 2700) {\n if ((year % 4 == 0 && year % 100 != 0) || year % 400 == 0) {\n let dayCount = 12;\n let monthCount = 9;\n return `${dayCount}.0${monthCount}.${year}`\n } else {\n let dayCount = 13;\n let monthCount = 9;\n return `${dayCount}.0${monthCount}.${year}`\n }\n }\n}", "title": "" }, { "docid": "fc2852ec400647890900e599dfe95c3a", "score": "0.64210397", "text": "function calculateAge(year){\n console.log(2019 - year);\n}", "title": "" }, { "docid": "79f158a5ac1ea220c2a6aa88551ebeee", "score": "0.6411", "text": "function calculateAge(year) {\n\tconsole.log(2016 - year);\n}", "title": "" }, { "docid": "85d39fb2eca51f097e15cf804175d985", "score": "0.6410009", "text": "function calculateBirthYear(birthYear) {\r\n\r\n return 2018 - birthYear; // grabs birthyears once the argument is called later in the code and is held \r\n}", "title": "" }, { "docid": "86baa041e1cce0345dbf46316b126fab", "score": "0.63889617", "text": "function printLeapYears(n) {\n var nextLeapYear = 2016;\n for (var i=0; i<n; ++i) {\n if (nextLeapYear%4===0 && !(nextLeapYear%100===0 && nextLeapYear%400!==0)) {\n console.log(nextLeapYear);\n }\n }\n}", "title": "" }, { "docid": "d0975f84fced91c50d8dd47213fd36cc", "score": "0.6388214", "text": "function personYearsInYear(startPopulation, endPopulation)\n{\n return (startPopulation + endPopulation) * 0.5\n}", "title": "" }, { "docid": "630ace4f96785d1ad19d0fb98532efad", "score": "0.6385045", "text": "function leap_year_range(st_year, end_year) {\n var year_range = [];\n for (var i = st_year; i <= end_year; i++)\n {\n year_range.push(i);\n }\n var new_array = [];\n\n year_range.forEach(\n function(year)\n { \n if (test_LeapYear(year)) \n new_array.push(year);\n });\n\n return new_array;\n }", "title": "" }, { "docid": "c6d223549cc731e2b414c9160edc738e", "score": "0.6356027", "text": "function dayOfProgrammer(year) {\n // Write your code here\n let day = 13;\n if(!(year%4) && (year < 1918 || year%100 || !(year%400))) day--;\n if(year == 1918) day = 26;\n return `${day}.09.${year}`;\n}", "title": "" }, { "docid": "61d93cf44979ac24b05beb638f173f65", "score": "0.6350857", "text": "function checkLeapYear() {\n var yearInput = document.getElementById(\"inputYear\").value;\n var yearOutput = document.getElementById(\"outputYear\");\n\n if ((0 == yearInput % 4) && (0 !== yearInput % 100) || (0 == yearInput % 400)) {\n yearOutput.innerHTML = `${yearInput} is a leap Year`\n }\n else {\n yearOutput.innerHTML = `${yearInput} is not a leap Year`\n\n }\n}", "title": "" }, { "docid": "0fe8bac555a1bc6be858c640f48d56ad", "score": "0.63415664", "text": "function Bisiesto(year)\n{\n return (year % 4 == 0 && (year % 100 != 0 || year % 400 == 0));\n}", "title": "" }, { "docid": "3d88759a8a23cc7eadb30effca76b1bc", "score": "0.63299567", "text": "function getYear(year) {\n if (year) {\n return year.match(/[\\d]{4}/);\n }\n}", "title": "" }, { "docid": "813688bdb3d49fe4563659fbc138a82a", "score": "0.6325002", "text": "function calAgeRetirement(year){\n const age = new\n Date().getFullYear() - year;\n return [age, 65 - age];\n\n}", "title": "" }, { "docid": "8d439f4cffa8e14eada7ab7954807c37", "score": "0.6322826", "text": "function isLeapYear(iYear)\n{//是否是闰年\n if (iYear % 4 == 0 && iYear % 100 != 0)\n {\n return true;\n }\n else\n {\n if(iYear % 400 == 0)\n {\n return true;\n }\n else\n {\n return false;\n }\n }\n}", "title": "" }, { "docid": "e5f14911b87bab82d04d112ef1890808", "score": "0.6319986", "text": "function calculateAge(year) {\n console.log(2018 - year);\n}", "title": "" }, { "docid": "b981c03335000bda1df8f34e932337ee", "score": "0.63190794", "text": "function task5(year){\n if (year % 4 == 0 && year % 100 != 0){\n console.log(\"yes\");\n }\n else if(year % 4 == 0 || year % 400 == 0){\n console.log(\"yes\");\n }\n else console.log(\"no\");\n}", "title": "" }, { "docid": "68b99ffdadc2b6de5c8609bd367fd39c", "score": "0.6312523", "text": "function nextYear() {}", "title": "" }, { "docid": "6d9316ec8e47bc319de9e43cf1ea7f80", "score": "0.63037986", "text": "function get_year_between_filter() {\n\tlet year = [undefined, undefined];\n\tlet before = document.querySelector(\"#search #filters #year_filters #before\");\n\tlet after = document.querySelector(\"#search #filters #year_filters #after\");\n\tlet between = document.querySelector(\"#search #filters #year_filters #between\");\n\n\tif (before.checked) {\n\t\tyear[1] = document.querySelector(\"#search #filters #year_filters #before_year\").value;\n\t\tyear[1] = parseInt(year[1]);\n\t} else if (after.checked) {\n\t\tyear[0] = document.querySelector(\"#search #filters #year_filters #after_year\").value;\n\t\tyear[0] = parseInt(year[0]);\n\t} else if (between.checked) {\n\t\tyear[0] = document.querySelector(\"#search #filters #year_filters #between_start\").value;\n\t\tyear[1] = document.querySelector(\"#search #filters #year_filters #between_end\").value;\n\t\tyear = [parseInt(year[0]), parseInt(year[1])];\n\t\tyear[1] += 1;\n\t}\n\n\tif (year[0] === \"\")\n\t\tyear[0] = undefined;\n\tif (year[1] === \"\")\n\t\tyear[1] = undefined;\n\n\treturn year;\n}", "title": "" }, { "docid": "39aad77e5bf097d36e1c9c658a441a76", "score": "0.6303013", "text": "static daysInYear( year : number ) : number {\n\t\treturn ( DateTime.isLeapYear( year ) ) ? 366 : 365;\n\t}", "title": "" }, { "docid": "460193c5941219f3a4864f9d689dfacc", "score": "0.63028693", "text": "function getYear2(){\n\nvar today = new Date();\nvar yyyy = today.getFullYear();\nvar yyyy = yyyy+\"0\"; // array conversion\nreturn yyyy[1];\n\n}", "title": "" }, { "docid": "dcd7eb883fa5cec92a4946ce040b1d9b", "score": "0.63019097", "text": "function calculateAge(year) {\n console.log(2018 - year);\n}", "title": "" }, { "docid": "981378950beb20ddc743e9a4accf8b6f", "score": "0.6297377", "text": "function getYearRange() {\r\n var today, year, month, day, range, startYear, endYear;\r\n startYear = \"1900\";\r\n today = new Date();\r\n year = today.getFullYear();\r\n month = today.getMonth() + 1;\r\n day = today.getDate();\r\n endYear = year;\r\n if (month === 12 && day === 31) {\r\n endYear = year + 1;\r\n }\r\n range = startYear + ':' + endYear;\r\n return range;\r\n}", "title": "" }, { "docid": "4fbb1eae686b85aad14a866c0c10f416", "score": "0.6296237", "text": "function generateDecade() {\n\n const minYear = 1900\n const currentYear = new Date().getFullYear()\n const currentYearStr = currentYear.toString()\n const currentDecadeStart = currentYearStr.slice(0, 3) + 0\n const generatedYear = Math.floor(Math.random() * (currentDecadeStart - minYear + 1)) + minYear\n const genereatedYearStr = generatedYear.toString()\n const decadeStart = genereatedYearStr.slice(0, 3) + 0;\n const decadeEnd = genereatedYearStr.slice(0, 3) + 9;\n console.log(decadeStart)\n console.log(decadeEnd)\n return [decadeStart, decadeEnd]\n\n}", "title": "" }, { "docid": "d24a94c7eb22e6c0067603115aa6f478", "score": "0.6290396", "text": "function year(inputYear) {\n if (inputYear % 400 === 0) {\n return true;\n }\n else if (inputYear % 100 === 0) {\n return false;\n }\n else if (inputYear % 4 === 0) {\n return true;\n }\n else if (!inputYear) {\n throw new Error('Must provide an argument!')\n }\n else {\n return false;\n }\n}", "title": "" }, { "docid": "8ce832b1beae6fb4b09c5a3f6d3aea22", "score": "0.6286686", "text": "function days_of_a_year(year) \n{\n \n return isLeapYear(year) ? 366 : 365;\n}", "title": "" }, { "docid": "519714848638003a4c079525be46b357", "score": "0.62684155", "text": "function checkLeapYear(year) {\n\n //three conditions to find out the leap year\n if ((0 == year % 4) && (0 != year % 100) || (0 == year % 400)) {\n console.log(year + ' is a leap year');\n } else {\n console.log(year + ' is not a leap year');\n }\n}", "title": "" }, { "docid": "519714848638003a4c079525be46b357", "score": "0.62684155", "text": "function checkLeapYear(year) {\n\n //three conditions to find out the leap year\n if ((0 == year % 4) && (0 != year % 100) || (0 == year % 400)) {\n console.log(year + ' is a leap year');\n } else {\n console.log(year + ' is not a leap year');\n }\n}", "title": "" }, { "docid": "e8bc7e2443055bdcdc6aca89370a53e4", "score": "0.62682563", "text": "function daysInYear(year) \n{ \n\treturn isLeapYear(year) ? 366 : 365;\n}", "title": "" }, { "docid": "50708a8d507c78a0f3f937153cd601bf", "score": "0.62632424", "text": "leapYear(input){\n //varifies input year should be of 4 digit\n if(input.length==4){\n //Logic to check the input year is leap year or not\n if ((input%4==0 && input%100!=0)|| input%400==0) {\n return true;\n }\n else{\n return false;\n }\n }\n else{\n return false\n }\n }", "title": "" }, { "docid": "10a5a4717caaa3521ce465593a1b9a30", "score": "0.62619674", "text": "function birthYear(currentYear) {\n return currentYear - age;\n}", "title": "" }, { "docid": "7136c6b54eafd469dc989d15c5d651a5", "score": "0.6260777", "text": "function calculateAge(year) {\n return 2020 - year\n}", "title": "" }, { "docid": "3d0d3235d68b796fe38ed91ea063e28d", "score": "0.626057", "text": "function leapYear() {\n var year = +prompt(\"Enter a year between 1582 to onwords to find the leap year\")\n var leapYear = year % 4;\n if (leapYear === 0) {\n document.write(year + \" is leap year! <br>\");\n }else {\n document.write(year + \" is not leap year! <br>\");\n }\n}", "title": "" }, { "docid": "8ce2e14a8d896f312357c2c5ab470529", "score": "0.6248851", "text": "function leapYear(){\n a = new Date();\n y = a.getFullYear();\n if (y % 4 == 0){\n let result = \"Its a leap year\"\n document.getElementById(\"ly\").innerHTML = result;\n console.log(result);\n }else{\n let result = \"No its not a leap year\";\n document.getElementById(\"ly\").innerHTML = result;\n console.log(result)\n }\n \n}", "title": "" }, { "docid": "1142e8874640de35e8bf80846c5d469a", "score": "0.6246548", "text": "function gendate(c, year) {\n let startDate, endDate;\n switch (c) {\n case 1:\n {\n startDate = new Date(year + \"-06-01\");\n endDate = new Date(year + \"-06-30\");\n }\n break;\n case 2:\n {\n startDate = new Date(year + \"-07-01\");\n endDate = new Date(year + \"-07-31\");\n }\n break;\n case 3:\n {\n startDate = new Date(year + \"-08-01\");\n endDate = new Date(year + \"-08-31\");\n }\n break;\n case 4:\n {\n startDate = new Date(year + \"-09-01\");\n endDate = new Date(year + \"-09-30\");\n }\n break;\n case 5:\n {\n startDate = new Date(year + \"-10-01\");\n endDate = new Date(year + \"-10-31\");\n }\n break;\n case 6:\n {\n startDate = new Date(year + \"-11-01\");\n endDate = new Date(year + \"-11-30\");\n }\n break;\n case 7:\n {\n startDate = new Date(year + \"-12-01\");\n endDate = new Date(year + \"-12-31\");\n }\n break;\n case 8:\n {\n startDate = new Date(year + \"-01-01\");\n endDate = new Date(year + \"-01-31\");\n }\n break;\n case 9:\n {\n startDate = new Date(year + \"-02-01\");\n endDate = new Date(year + \"-02-28\");\n }\n break;\n case 10:\n {\n startDate = new Date(year + \"-03-01\");\n endDate = new Date(year + \"-03-31\");\n }\n break;\n case 11:\n {\n startDate = new Date(year + \"-04-01\");\n endDate = new Date(year + \"-04-30\");\n }\n break;\n }\n str = [];\n sun = [];\n let date = Array.from(datesBetween(startDate, endDate));\n return date;\n}", "title": "" }, { "docid": "acf97fd28fb5568b3a2e1364cc560322", "score": "0.624471", "text": "function whatAge(birthyear){\n return 2018 - birthyear;\n}", "title": "" }, { "docid": "d1e08817938da56ca0d1553c71dbb268", "score": "0.62432", "text": "function yearOf(date) { return 1900 + date.getYear(); }", "title": "" }, { "docid": "43612675d4e59ae7da4e4ef07feb0399", "score": "0.62414527", "text": "function getYear(d){\n return(parseInt(d));\n}", "title": "" }, { "docid": "07451ee92bc92fa25630ef761e5423a5", "score": "0.62367064", "text": "getYearNumerals(year) {\n return `${year}`;\n }", "title": "" }, { "docid": "9dd77c4775cec27330cacd471110db00", "score": "0.6235192", "text": "function leapYear(year) {\r\n if (((year % 400) !== 0) && ((year % 100) === 0)) {\r\n console.log(year + \" isn't a leap year because of that 400 rule.\");\r\n }\r\n else if ((year % 4) === 0) {\r\n console.log(year + \" is a leap year!\");\r\n }\r\n else {\r\n console.log(year + \" is not a leap year.\");\r\n }\r\n}", "title": "" }, { "docid": "9de202e3d969e6e3323851f34148aedd", "score": "0.6234784", "text": "function nextHappyYear(year){\n let set = new Set\n for (let i = year + 1; i < (year + 1000); i++){\n let arr = i.toString().split('')\n set = new Set\n arr.forEach(element => set.add(element))\n if (set.size === 4){\n break\n }\n }\n let happyYear = Number([...set].join(''))\n return happyYear\n\n}", "title": "" }, { "docid": "cb69f459307d5dbab7d73a9bed9e4a80", "score": "0.6212108", "text": "function centuryGrouping(person) {\n return (Math.ceil(person.died / 100));\n}", "title": "" }, { "docid": "db484f05e117534f62220fc2a0b532c1", "score": "0.6205158", "text": "function leapYear(year) {\n if (year % 4 == 0) {\n if (year % 100 == 0) {\n if (year % 400 == 0) {\n year = \"Leap Year\";\n } else year = \"Not a Leap Year\";\n } else year = \"Leap Year\";\n } else year = \"Not a Leap Year\";\n return year;\n}", "title": "" }, { "docid": "dac61bf8164a8114e80dbfe4fe53abb9", "score": "0.62038016", "text": "function isleapyr(year) {\n if (year%400===0) {\n console.log(year + \" is a leap year!\")\n }\n else if (year%100===0) {\n console.log(year + \" is not a leap year.\")\n }\n else if (year%4===0) {\n console.log(year + \" is a leap year!\")\n }\n else {\n console.log(year + \" is not a leap year.\")\n }\n}", "title": "" }, { "docid": "ae269414bdab02927093a11a104bffa2", "score": "0.6202293", "text": "function computeYearly () {\n let annuity = Math.round(A * (Math.pow(1 + i, n) - 1)/ i)\n let yearlyResult = Math.round(PV * Math.pow(1 + i, n)) + annuity;\n let interestValue = yearlyResult - document.getElementById('base-amount').value;\n \n //Display results and use Regex to include commas in numbers\n document.getElementById('total-value').textContent = \"GH₵\" + yearlyResult.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\"); //\n document.getElementById('interest-earned').textContent = \"GH₵\" + interestValue.toString().replace(/\\B(?=(\\d{3})+(?!\\d))/g, \",\");;\n \n }", "title": "" }, { "docid": "a1680a4c3d44d64c2cd4043b7fe948fc", "score": "0.6200696", "text": "function dayOfProgrammer(year) {\n if (year == 1918) {\n // Corner case\n return `26.09.${year}`; \n } else if (year > 1918) {\n // Calculating Leap year in Gregorian Calendar\n const isLeapYear = (year % 4 == 0) && (year % 100 != 0) || year % 400 == 0;\n return `${isLeapYear ? 12 : 13}.09.${year}`;\n } else {\n // Calculating Leap year in Julian Calendar\n return `${year % 4 == 0 ? 12 : 13}.09.${year}`;\n }\n}", "title": "" }, { "docid": "78612287ef8473fd25a02e12061d94c3", "score": "0.6197593", "text": "function nbYear(p0, percent, aug, p) {\n let years = 0\n while ( p0 < p){\n p0 += (p0 * ( percent / 100)) + aug;\n years++;\n }\n return years\n}", "title": "" }, { "docid": "82c1fe253e042725d5329c7210a86677", "score": "0.6193905", "text": "findLeapYear(year)\n {\n try\n {\n if(year>999 && year<10000)//check if the year is a four digit number\n {\n if((year%400==0) || (year%4==0) || (year%100==0))//condition for checking leap year\n console.log(year+\" is a leap year\");//display leap year message\n else\n console.log(year+\" is not a leap year\");//display not a leap year message\n }\n else\n {\n console.log(\"Enter a four digit number\");//display invalid input message\n }\n }\n catch(err)\n {\n console.log(err.message);//display error message\n }\n }", "title": "" }, { "docid": "36444ad66587080448045dbf9f05c89b", "score": "0.6185446", "text": "function prev_decade_year(temp_year){\r\n\tview_year(temp_year);\r\n}", "title": "" }, { "docid": "103446edcbc8d50f3c68a8175aa729ce", "score": "0.6183159", "text": "function determineZodiac(year){\n if (year % 12 == 0){\n return 0;\n }\n if (year % 12 == 1){\n return 1;\n }\n if (year % 12 == 2){\n return 2;\n }\n if (year % 12 == 3){\n return 3;\n }\n if (year % 12 == 4){\n return 4;\n }\n if (year % 12 == 5){\n return 5;\n }\n if (year % 12 == 6){\n return 6;\n }\n if (year % 12 == 7){\n return 7;\n }\n if (year % 12 == 8){\n return 8;\n }\n if (year % 12 == 9){\n return 9;\n }\n if (year % 12 == 10){\n return 10;\n }\n if (year % 12 == 11){\n return 11;\n }\n}", "title": "" }, { "docid": "dbf798a88e4192ffbde9988789523a25", "score": "0.61818004", "text": "function intermediateYearsToDays () {\n if (birthYear === currentYear) {\n return 0;\n } else if (birthYear !== currentYear) {\n return ((currentYear - 1) - (birthYear)) * 365;\n }\n}", "title": "" }, { "docid": "bf99f42eb1ce971da0052c34cec87384", "score": "0.61806387", "text": "function calcAge1(birthYear) {\n return 2037 - birthYear;\n}", "title": "" }, { "docid": "970a75fb4e04189aab2f2770d84869a3", "score": "0.61795473", "text": "function getYear1(){\n\nvar today = new Date();\nvar yyyy = today.getFullYear();\nvar yyyy = yyyy+\"0\"; // array conversion\nreturn yyyy[0];\n\n}", "title": "" }, { "docid": "30e971f6a5638349ea30e32b394a4e00", "score": "0.6177646", "text": "function getYearRange() {\n\tyearRange = parseInt(rangeYearInput.value);\n}", "title": "" }, { "docid": "5d135bd841306d40055ecc7d56fbf92c", "score": "0.6167566", "text": "function fullDate2(dayNum){\n var dayRem = dayNum % 365;\n var addYear = Math.floor(dayNum / 365);\n var year = 2017 + addYear;\n var month;\n var day;\n var date;\n var leapYears = 0;\n\n\n // Edge Cases - make sure input is within 1-365 range\n if (dayNum < 1) {\n return \"Day number must be a positive integer.\"\n }\n\n // Count leap years\n for(var j = 2020; j <= year; j += 4){\n leapYears ++;\n }\n\n console.log(leapYears);\n\n // Find Month\n function dayToMonth(dayRem) {\n\n if (dayRem <= 31) {\n date = dayRem;\n month = \"January\";\n } else if (dayRem <= 59) {\n date = dayRem - 31;\n month = \"February\";\n } else if (dayRem <= 90) {\n date = dayRem - 59;\n month = \"March\";\n } else if (dayRem <= 120) {\n date = dayRem - 90;\n month = \"April\";\n } else if (dayRem <= 151) {\n date = dayRem - 120;\n month = \"May\";\n } else if (dayRem <= 181) {\n date = dayRem - 151;\n month = \"June\";\n } else if (dayRem <= 212) {\n date = dayRem - 181;\n month = \"July\";\n } else if (dayRem <= 243) {\n date = dayRem - 212;\n month = \"August\";\n } else if (dayRem <= 273) {\n date = dayRem - 243;\n month = \"September\";\n } else if (dayRem <= 304) {\n date = dayRem - 273;\n month = \"October\";\n } else if (dayRem <= 334) {\n date = dayRem - 304;\n month = \"November\";\n } else {\n date = dayRem - 334;\n month = \"December\"\n }\n return month;\n }\n\n // Find Day\n function dayName(dayRem) {\n var dayModulo = dayRem % 7;\n\n switch (dayModulo) {\n case 1:\n day = \"Sunday\"\n break;\n case 2:\n day = \"Monday\"\n break;\n case 3:\n day = \"Tuesday\"\n break;\n case 4:\n day = \"Wednesday\"\n break;\n case 5:\n day = \"Thursday\"\n break;\n case 6:\n day = \"Friday\"\n break;\n case 0:\n day = \"Saturday\"\n break;\n }\n return day;\n }\n\n // Adjust for leap years\n\n\n // Log Results\n dayToMonth(dayRem);\n dayName(dayRem);\n console.log(day + \", \" + month, date + \", \" + year + \".\");\n}", "title": "" }, { "docid": "c1220ce48250336c28c83affb5ddc7a1", "score": "0.61644244", "text": "function findLeapYear() {\r\nvar year = +document.getElementById('get_leapYear').value;\r\nvar x = (year % 100 === 0) ? (year % 400 === 0) : (year % 4 === 0);\r\ndocument.getElementById('leap').innerHTML = x;\r\ndocument.getElementById('year').innerHTML = \"Is the year \" + year + \" a leap year?\";\r\n}", "title": "" } ]
16ed3dacfd4fb5b00669e541f5eba487
Return promise with int with 0 or 1 on whether skipping is allowed in current station at this time.
[ { "docid": "c7f049f3efc8c303b8f5de7e312f74ce", "score": "0.53448856", "text": "get canSkip() {\n return RNFMAudioPlayer.canSkip();\n }", "title": "" } ]
[ { "docid": "83fb0a573544379c7d8ed261bba8efd4", "score": "0.55544907", "text": "get isSkipped() { return (this.flags & 2 /* Skipped */) > 0; }", "title": "" }, { "docid": "863d87731b2f998442e6686b960a6d4a", "score": "0.5539083", "text": "skip() {\n const skipNotifier = Q.defer();\n\n try {\n return skipNotifier.promise;\n } finally {\n this._voiceSupport.skip();\n this._doneNotifier.resolve();\n skipNotifier.resolve();\n }\n }", "title": "" }, { "docid": "87e5154a966770223f272ca74091e96f", "score": "0.53389794", "text": "checkNode(){\n this.noFreeSlots = true;\n this._NetworkRequests.getUnlockedInfo(this.harvestingNode).then((data) => {\n if (data[\"max-unlocked\"] === data[\"num-unlocked\"]) {\n this.noFreeSlots = true;\n } else {\n this.noFreeSlots = false;\n }\n },\n (err) => {\n console.error(err)\n this._Alert.unlockedInfoError(err.data.message);\n });\n }", "title": "" }, { "docid": "1cb6378c4b99e2c9164cd44c89ebf0c9", "score": "0.5314861", "text": "isRunned(workflow, action, resource) {\n const result = 0\n\n return Promise.resolve(result > 0)\n }", "title": "" }, { "docid": "441ef4d18c875f7c8094214414091a6e", "score": "0.5282441", "text": "function shouldContinue() {\n // Check one: pending setTimeout, setInterval, setImmediate?\n // Check two: pending OS tasks?\n // Check three: pending long-running operations? \n return pendTimers.length || pendingOSTasks.length || pendingOperations.length;\n \n}", "title": "" }, { "docid": "8360efe36abc8ddb956b97da879fc9ae", "score": "0.5229587", "text": "get pending() {\n return this._timeoutId != null;\n }", "title": "" }, { "docid": "0275b6f783110f65ad940561953f355e", "score": "0.5213357", "text": "get skippable() {\n if (this.flagged) return false;\n if (this.missing && Agenda.meeting_day) return this._to === \"president\";\n\n if (this._approved && this._approved.length < 5 && Agenda.meeting_day) {\n return false\n };\n\n return true\n }", "title": "" }, { "docid": "5ce20467667c973bf155d6bda72ec5f8", "score": "0.52030367", "text": "waitUntilStop() {\n // Could happen that shouldWait doesn't change if program is at rest\n // so numberChecked is used to ensure modifications are done.\n let numberChecked = 0;\n this.shouldWait = true;\n\n return new Promise((resolve) => {\n const checkIfReady = () => {\n if (!this.shouldWait) {\n resolve();\n } else if (numberChecked === 10) {\n this.shouldWait = false;\n checkIfReady();\n // resolve();\n } else {\n numberChecked++;\n setTimeout(checkIfReady, 100);\n }\n };\n checkIfReady();\n });\n }", "title": "" }, { "docid": "a9a0a0ffb4aed099c1c409f634708d56", "score": "0.5184145", "text": "function shouldContinue() {\n // 1st check: Any pending 'setTimeout', 'setInterval', 'setImmediate'?\n // 2nd check: Any pending OS tasks? (Like server listening to port)\n // 3rd check: Any pending long running operations? (fs module)\n return (\n pendingTimers.length || pendingOSTasks.length || pendingOperations.length\n );\n}", "title": "" }, { "docid": "6c06e37d11b7e27101f579f5e46eaa26", "score": "0.5153839", "text": "function CNDisnotdone()\n{\n\treturn !CNDisdone();\n}", "title": "" }, { "docid": "3fcf53258b626cbeecea99cc53505628", "score": "0.51237017", "text": "isPendingRequest() {\n return !!this.observer.length;\n }", "title": "" }, { "docid": "d20f32e5b969d4e77c9c9f5bf5f7dc29", "score": "0.50542057", "text": "async cancelCondition() {\n let dsa = new DefiSmartAccount();\n let dsaContract = await dsa.DSA();\n let dsaBalance = await EthereumConnexion.GetInstance().getBalanceBigNb(dsaContract.address);\n let providerFunds = await dsa.getProviderFunds();\n if(dsaBalance.isZero() && providerFunds.isZero()) {\n window.alert('Already cancelled.');\n return false;\n }\n return true;\n }", "title": "" }, { "docid": "35c9ce8e46fc914d2f18d28e58083c87", "score": "0.50364256", "text": "async isDelayed() {\n return (await isDelayed(this.id)) === 1;\n }", "title": "" }, { "docid": "dd9a4bb773543a72a4b21db084cad745", "score": "0.499049", "text": "async function checkSystemRequest(exitTCompare,emptyS) {\n var blockedRow;\n var flagSystemReq;\n var outPutCheckSystemReq=[];\n\n for (var k = 0; k < Config.x; k++) {\n for (var p = 0; p < Config.y; p++) {\n if (k == 1 || k == 3 || k == 6 || k == 8) {//just if it is a blocking row\n if (k == 1) blockedRow = 0;\n else if (k == 3) blockedRow = 4;\n else if (k == 6) blockedRow = 5;\n else if (k == 8) blockedRow = 9;\n\n var idblocking = await getIDDB(k * 10 + p);\n var exitTblocking = await getexitTDB(k * 10 + p);\n var exitTblocked = await getexitTDB(blockedRow * 10 + p);\n\n if (idblocking != -1 && exitTblocking > exitTblocked) //if parking slot is not empty, and blockingcar's exitT > blockedcar's exitT\n if ((exitTCompare != null && exitTblocking <= exitTCompare) || exitTCompare == null) //if blockingcar's exitTime<=exitTCompare\n flagSystemReq = 1; \n }\n if (flagSystemReq == 1) break;\n }\n if (flagSystemReq == 1) break;\n }\n //the output is only used in systemRequest function\n if (flagSystemReq != 1) return false;//no need system request\n else {//need system request\n outPutCheckSystemReq.push(idblocking);//the driver we want to moving to the empty slot\n outPutCheckSystemReq.push(k * 10 + p); //the slot of the car we want to move\n outPutCheckSystemReq.push(emptyS);//the empty slot\n return outPutCheckSystemReq;\n }\n}", "title": "" }, { "docid": "ba3601f5785dbe29759cdf38deef95f6", "score": "0.49308258", "text": "async function isStatusOkay() {\n const currentProbeTime = new Date()\n currentProbeTime.setHours(new Date().getHours() - 1)\n\n log.debug('AGENDA: currentProbeTime: ', currentProbeTime)\n log.debug('AGENDA: lastAgendaProbeTime: ', lastAgendaProbeTime)\n if (lastAgendaProbeTime < currentProbeTime) {\n await showCurrentSchedule()\n await isAgendaOk()\n }\n\n return worker.isFine\n}", "title": "" }, { "docid": "3562eb26de456313c0bd7ff2fd341d3c", "score": "0.49299917", "text": "function getFirstAvailableSlot() {\n for (let i = 0; i < battleData.UI.bottom[battleData.selStage].length; i++) {\n if (!battleData.UI.bottom[battleData.selStage][i].disabled) {\n return i;\n }\n }\n}", "title": "" }, { "docid": "a131175f20be764dfddf1a91490572f2", "score": "0.49170494", "text": "hasPending() {\n return this.pending.length > 0;\n }", "title": "" }, { "docid": "4eafec7ac738f161ded5f6151fa55b2c", "score": "0.49167153", "text": "async getPendingTransactionCount() {\n\t\tconst {\n\t\t\tdata: {\n\t\t\t\ttransactions: { ready, verified, pending, validated },\n\t\t\t},\n\t\t} = await this.call().getNodeStatus();\n\n\t\treturn ready + verified + pending + validated;\n\t}", "title": "" }, { "docid": "3188d5cc6af563fe62300abaad65ba17", "score": "0.49076897", "text": "function countDnaNotMutation() {\n return new Promise((resolve, reject) => {\n let sql = \"SELECT COUNT(mutation) AS dnaCount FROM dna WHERE mutation = 0\";\n cxn.query(sql, function (err, result) {\n if (err) throw err;\n resolve(result[0].dnaCount);\n })\n })\n}", "title": "" }, { "docid": "9710d02fce7bdccc3400d3dc62df777f", "score": "0.4902474", "text": "async retrieveCondition() {\n var dsa = new DefiSmartAccount();\n let dsaContract = await dsa.DSA();\n var balance = await EthereumConnexion.GetInstance().getTokenBalanceBigNb(dsaContract.address, DAI_TOKEN_ADDRESS);\n if(balance.isZero()) {\n window.alert(\"DeFi Smart Account DAI balance is equal to zero. No need to do retrieve action.\");\n return false;\n }\n return true;\n }", "title": "" }, { "docid": "9e449b96d9d2aadeeca861bcf38d2914", "score": "0.48871604", "text": "static isAvailable() {\n return __awaiter(this, void 0, void 0, function* () {\n return Promise.resolve(false);\n });\n }", "title": "" }, { "docid": "66b17f2d5286d72d5bcc64eb45ebf2a4", "score": "0.48733363", "text": "skipWaiting() {}", "title": "" }, { "docid": "ebd89296f15ff05ed41fd8ebef0b3a98", "score": "0.48721677", "text": "static waitForPortStatusEx(opts) {\n opts.startTimeMs = Date.now();\n const functor = opts.checkLocalHostAliases ? TcpPortScanner.isPortInUseEx : TcpPortScanner.isPortInUse;\n return new Promise(function tryAgain(resolve, reject) {\n functor(opts.port, opts.host)\n .then((inUse) => {\n // console.log(`${functor.name} returned ${inUse}`)\n if (inUse === opts.desiredStatus) { // status match\n return resolve();\n }\n else {\n throw new Error('tryagain');\n }\n }).catch((e) => {\n if (e.message !== 'tryagain') {\n return reject(e);\n }\n else {\n const t = Date.now() - opts.startTimeMs;\n if (t < opts.timeOutMs) {\n // console.log(`Setting timeout for ${opts.retryTimeMs}ms, curTime = ${t}ms`);\n setTimeout(() => {\n tryAgain(resolve, reject);\n }, opts.retryTimeMs);\n }\n else {\n return reject(new Error('timeout'));\n }\n }\n });\n });\n }", "title": "" }, { "docid": "184c8bd24785c633d5cf5a354ef05f8b", "score": "0.48634285", "text": "incrementSkipped() {\n this.skipped_++;\n }", "title": "" }, { "docid": "3a0dc01a1bd862ed330f621d99fa081b", "score": "0.48596364", "text": "addRequestAndCheckIfRateLimited() {\n return __awaiter(this, void 0, void 0, function* () {\n const now = new Date().getTime();\n this.requestCounter = this.requestCounter.filter((date) => date + this.rateLimitWindowInSeconds * 1000 > now);\n this.requestCounter.push(now);\n return this.requestCounter.length > this.rateLimit;\n });\n }", "title": "" }, { "docid": "01f1d04c4eb9edd7ae4e8d4d93669eaa", "score": "0.48531282", "text": "function _haveFreeSlot() {\n var res = $rootScope.recordFlowControl.occupiedSlots < $rootScope.recordFlowControl.maxRequests;\n if (!res) {\n $log.debug(\"No free slot available.\");\n }\n return res;\n }", "title": "" }, { "docid": "47e0be3e75cfbf834efa3bf04a08b8d2", "score": "0.48519742", "text": "async getNextTrainAtStation(stationCode) {\n const res = await axios.get(NEXT_TRAIN + stationCode, {\n headers: {\n 'api_key': API_KEY,\n }\n });\n\n //anytime the user changes one of the fields, the app checks for the travel time\n //between selected stations\n this.getTravelTime();\n\n return res.data.Trains; \n }", "title": "" }, { "docid": "b0eab2ad3ee1ce6b8932816ca34d6cc7", "score": "0.4850997", "text": "async getStatusAndWait() {\n const status = await this.getStatus();\n if (status.state !== DFU_DEVICE_STATE_DFU_DNBUSY) {\n throw Error('eraseAll - expected DNBusy state in DFU_GET_STATUS response, got: ' +\n status.state);\n }\n\n await new Promise((resolve, reject) => {\n setTimeout(resolve, status.delay);\n });\n\n return this.getStatus();\n }", "title": "" }, { "docid": "711ad8f3307f27a043428df008ebb2de", "score": "0.48482555", "text": "function isIntvNumWaiting (tstUserId, tstIntvNum, tstStageNo) {\n let xhr;\n let intvNum = -1;\n window.console.log(\"isIntvNumWaiting(\" + tstUserId + \", \" + tstIntvNum + \", \" + tstStageNo + \")\");\n if (!phpIsWorking) {\n intvNum = noPhpIntvNum;\n window.console.log(\"isINW: \" + warningPHPisNotWorking + intvNum);\n } else {\n xhr = new window.XMLHttpRequest();\n if (intvNumAuto || intvNumGiven) {\n xhr.open(\"GET\", \"../php/isAutoIntvNumWaiting.php?survey_id=\" + surveyId + \"&user_id=\" + tstUserId + \"&int_no=\" + tstIntvNum, false);//SYNCHRONICZNIE\n } else {\n if (stagesNum == 1) { //tstStageNo == -1)\n xhr.open(\"GET\", \"../php/isTableIntvNumWaiting.php?survey_id=\" + surveyId + \"&user_id=\" + tstUserId + \"&int_no=\" + tstIntvNum, false);//SYNCHRONICZNIE\n } else {\n xhr.open(\"GET\", \"../php/isM_TabIntvNumWaiting.php?survey_id=\" + surveyId + \"&user_id=\" + tstUserId + \"&int_no=\" + tstIntvNum + \"&stage_no=\" + tstStageNo, false);//SYNCHRONICZNIE\n }//else\n }//else\n xhr.send();\n if (xhr.status == 200) {\n intvNum = xhr.responseText;\n } else {\n window.console.error(\"isINW: \" + errorReadingINfile + xhr.status);\n }//else\n if (intvNum.indexOf(\"<?php\") != -1 || intvNum.indexOf(\"Warning:\") != -1) {\n window.console.error(\"isINW: \" + errorNoPHPorINfile);\n intvNum = -1;\n }//if\n }//else\n window.console.log(\"isINW: intvNum=\" + intvNum);\n return intvNum;\n}//isIntvNumWaiting", "title": "" }, { "docid": "3c5e60aa3cfe774521f50c627d20ddb7", "score": "0.4843106", "text": "isPending() {\n if (this.module != null) {\n return this.module.state === STATE_PENDING\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "7c35356504edaf0d32f09f97230e9d63", "score": "0.48380297", "text": "async checkAvailableDataWait() {\n const value = (await this.readWait(this.commands.addresses.CCS811_STATUS, 1))[0];\n return Boolean(value & (1 << 3));\n }", "title": "" }, { "docid": "995e8dc94bc6d2af3ef3c68332902560", "score": "0.48224226", "text": "_pendingRequests () {\n if (this._requestMap.size > 0) {\n return true\n }\n }", "title": "" }, { "docid": "b138ae0a7525e0504d0d1da23b3fd99e", "score": "0.48161912", "text": "getSkipStatus(sourcePath) {\n if (this._skipFileStatuses.has(sourcePath)) {\n return this._skipFileStatuses.get(sourcePath);\n }\n return undefined;\n }", "title": "" }, { "docid": "b138ae0a7525e0504d0d1da23b3fd99e", "score": "0.48161912", "text": "getSkipStatus(sourcePath) {\n if (this._skipFileStatuses.has(sourcePath)) {\n return this._skipFileStatuses.get(sourcePath);\n }\n return undefined;\n }", "title": "" }, { "docid": "4745388bf300855603af881566b0639e", "score": "0.48149508", "text": "async function systemRequest(slotEmpty)\n{\n var exitTCompare;\n var flagEmptyIsBlocking = 0;\n var resCheck = [];\n\n var tempParkingSNum2 = slotEmpty;\n var kEmpty = Math.floor(tempParkingSNum2 / 10);\n var pEmpty = tempParkingSNum2 % 10;\n\n //call to checkSystemRequest function:\n //find exitT to compare:\n if (kEmpty == 0 || kEmpty == 4 || kEmpty == 5 || kEmpty == 9)//when the row is 'isParking' row\n exitTCompare = null; \n else if (kEmpty == 1 || kEmpty == 3 || kEmpty == 6 || kEmpty == 8) {//if it is a blocking row\n flagEmptyIsBlocking = 1;\n if (kEmpty == 1) blockedRow = 0;\n else if (kEmpty == 3) blockedRow = 4;\n else if (kEmpty == 6) blockedRow = 5;\n else if (kEmpty == 8) blockedRow = 9;\n exitTCompare = await getexitTDB(blockedRow * 10 + pEmpty);\n \n }\n resCheck = await checkSystemRequest(exitTCompare, slotEmpty);\n var rowResFrom = Math.floor(resCheck[1] / 10);\n var colResFrom = resCheck[1] % 10;\n\n if (resCheck!=false) //if the valet need to move car to the empty parking slot\n {\n //save details of the user we move from\n var tempUserID = await getIDDB(resCheck[1]);\n var tempExitT = await getexitTDB(resCheck[1]);\n //update at db that the slot is empty:\n slot.exitT = -1;\n slot.userID = -1;\n setSlot(resCheck[1], slot);\n //update in DB the flag of the blocked car:\n if (rowResFrom == 1) blockedRow2 = 0;\n else if (rowResFrom == 3) blockedRow2 = 4;\n else if (rowResFrom == 6) blockedRow2 = 5;\n else if (rowResFrom == 8) blockedRow2 = 9;\n\n var idBlocked = await getIDDB(blockedRow2 * 10 + colResFrom);\n var driver = await getDriver(idBlocked);\n driver.isBlock = false;\n updateDriver(idBlocked, driver);\n\n //move to the empty parking slot:\n slot.exitT = tempExitT;\n slot.userID = tempUserID;\n setSlot(resCheck[2], slot);\n\n var tempUserID = await getIDDB(slotEmpty);\n var driver = await getDriver(tempUserID);\n var outPutRequest = {\n carNumber: driver.carNumber,\n current: resCheck[1],\n future: resCheck[2]\n };\n setOutPutRequest(outPutRequest);\n }\n else if (resCheck == false) return false; //return false=there is not car to move to the empty parking slot\n}//end of systemRequest func", "title": "" }, { "docid": "409e70ee366cfb6d1f2a72414d8ec504", "score": "0.48111206", "text": "function skip(skipURL, curr_device_id, playPauseBtn, player) {\n /* function skip(skipURL, headers, curr_device_id, playPauseBtn, playerURL, player) { */\n $.ajax({\n method: 'POST',\n url: '/skip',\n data: {\n 'skip_form': skipURL,\n 'device_id': curr_device_id\n },\n // Needs to wait a second, otherwise return the same state\n success: setTimeout(function () {\n checkIfPlaying(player, playPauseBtn);\n /* checkIfPlaying(playerURL, headers, player, playPauseBtn); */\n }, 1000)\n })\n}", "title": "" }, { "docid": "37690c0891b7271f8ac737f3e3fce9f9", "score": "0.47868598", "text": "getStatus() {\n if (this.iterationNumber == this.songArray.length - 1) {\n return 1;\n }\n else {\n return 0;\n }\n }", "title": "" }, { "docid": "ebd83376657d9dfdd1c35df45d65a2da", "score": "0.47821215", "text": "checkForMoves (danceChart, beat = this.songManager.nearestBeat) {\n if (danceChart.moves.length === 0) {\n return -1\n } else {\n for (let i = 0; i < danceChart.moves.length; i++) {\n let move = danceChart.moves[i]\n if (move[0] === beat) {\n return i\n } else if (i === danceChart.moves.length - 1) {\n return -1\n }\n }\n }\n }", "title": "" }, { "docid": "b3e6eaff1366cad8b522284a11f1375f", "score": "0.47721776", "text": "function First_Available(){\n\tfor(i = 0; i < 9; i++){\n\t\tif(board_state[i] === empty){\n\t\t\treturn i;\n\t\t}\n\t}\n}", "title": "" }, { "docid": "585af1df60fa358a0d9ed2a1eb758252", "score": "0.4769439", "text": "function skip() {\n return that._source.slice(4).then(function(chunk) {\n if (chunk == null) return {done: true, value: undefined};\n header = view(array = concat$1(array.slice(4), chunk));\n return header.getInt32(0, false) !== that._index ? skip() : read();\n });\n }", "title": "" }, { "docid": "1df48daf868dced2af8cc691e763e670", "score": "0.47599387", "text": "getTaskNum() {\n // eslint-disable-line\n const tasks = this.client.tasks;\n let taskNum = 0;\n for (let i = 0; i < tasks.length; i++) {\n if (!tasks[i].recurring) {\n taskNum = i + 1;\n }\n if (tasks[i].status === STATUS.ACTIVE && !tasks[i].recurring) {\n break;\n }\n }\n return taskNum;\n }", "title": "" }, { "docid": "194614da48ffdf10273704516e97b7d9", "score": "0.47473776", "text": "function refreshPageAndCheckIsPending() {\n var timeNow = new Date();\n console.log('Trial still pending, refreshing page ' + partner.pendingCount + ' time elapsed: ' + ((timeNow - partner.timeStart) / 60000) + ' minutes');\n partner.pendingCount++;\n\n browser.refresh();\n\n // There is a bug in the trial view where entering search text\n // too soon results in the search being ignored, so let's wait until a\n // known trial shows up in the list...\n utils.waitIsDisplayed(element(by.cssContainingText('.ui-grid-cell', \n 'Atlas Test Partner Organization')));\n\n utils.search(partner.newTrial.customerName, -1);\n utils.waitIsDisplayed(partner.newTrialRow);\n\n utils.click(partner.newTrialRow);\n utils.waitIsDisplayed(partner.previewPanel);\n utils.click(partner.openMeetingSidePanelLink);\n\n return utils.waitIsDisplayed(partner.trialPending, 55000).then(function () {\n return true;\n }, function () {\n return false;\n });\n }", "title": "" }, { "docid": "aca6b78a2628364f43c58e2ec6aa8209", "score": "0.4743212", "text": "static trySkip() {\n if (novelData.novel.currentScene.skipEnabled) {\n this.complete();\n }\n }", "title": "" }, { "docid": "534a590a37989fa5129ce6922d231019", "score": "0.47382602", "text": "async function advanceToNoneSaftyPeriod() {\n let currentTimeStamp = (await web3.eth.getBlock(\"latest\")).timestamp;\n let withdrawPeriod = (await hatVaults.generalParameters()).withdrawPeriod.toNumber();\n let safetyPeriod = (await hatVaults.generalParameters()).safetyPeriod.toNumber();\n if (currentTimeStamp % (withdrawPeriod + safetyPeriod) >= withdrawPeriod) {\n await utils.increaseTime((currentTimeStamp % (withdrawPeriod + safetyPeriod) )+ safetyPeriod - withdrawPeriod);\n }\n\n }", "title": "" }, { "docid": "a0739c10eb5fbbf20b353388f7662b97", "score": "0.4722334", "text": "function checkPending() {\n remaining--;\n if (!remaining) {\n promise.resolve.call(context, resolutions);\n }\n }", "title": "" }, { "docid": "81c3b53d9620be4d027c5bce22fae71f", "score": "0.47148737", "text": "done()\n\t{\n\t\tif(scene.index === this.station)\n\t\t{\n\t\t\treturn true;\n\t\t}\n\t\t\n\t\treturn false;\n\t}", "title": "" }, { "docid": "c5363c1b778ed68393d45a6ff711d603", "score": "0.47086635", "text": "async cancel() {\n if (!this.scanning && !this.scanLoop) return;\n \n this.scanLoop = false;\n return this.scanPromise;\n }", "title": "" }, { "docid": "c84e28e2acc0b5172084ced628924aed", "score": "0.4703653", "text": "function Skip() { return Skip }", "title": "" }, { "docid": "6b4071e2f187f79600750f6137f1ca84", "score": "0.46993804", "text": "function rejectAsync()\n {\n if(store('var_async_fn_gate_open'))\n {\n //increment async function counter\n storeIncrement('var_async_fn_counter');\n }\n }", "title": "" }, { "docid": "4ed4625535b06408008f38f23e27fc8b", "score": "0.46990067", "text": "function checkIfExists() {\n return __awaiter(this, void 0, void 0, function () {\n return __generator(this, function (_a) {\n return [2 /*return*/, new Promise(function (resolve) {\n var checkExist = setInterval(function () {\n if (Graph.getInstance().ready == true) {\n clearInterval(checkExist);\n resolve(\"done!\");\n }\n }, 200);\n })];\n });\n });\n}", "title": "" }, { "docid": "bdb68014526516f78e8a210bb3623f56", "score": "0.46958742", "text": "function CNDisnotresp()\n{\n\treturn !in_response;\t\n}", "title": "" }, { "docid": "de016e54031beee9d1164c0f98fdccd0", "score": "0.46921825", "text": "function checkForDisconnects(reptCounter) {\n\n return new Promise((fulfill, reject) => {\n\n // Examine for interfaces that have been quiet and track how long they have been quiet\n // using quietForHowLong[interfaceUid] = millis-since-last-non-zero-sampling\n // Thereby determining if any need to run netstat to determine disconnect states\n existingConnections.forEach(conn => {\n const interfaceUid = conn.interfaceUid;\n const sample = samplesIndex[interfaceUid];\n // Keep track of how long since we last had characters measured on this interface\n if (!sample || !sample.charCount) {\n if (!quietForHowLong[interfaceUid]) { // undefined or 0\n quietForHowLong[interfaceUid] = state.monitor.samplePeriod; // no charCount for last (samplePeriod) millis\n } else {\n quietForHowLong[interfaceUid] += state.monitor.samplePeriod; // additional (samplePeriod) seconds with no charCount\n }\n // Has it been quiet long enough to include this interface for disconnect detection?\n if (quietForHowLong[interfaceUid] >= state.monitor.waitBeforeDiscCheck) {\n // add to list of those interfaces we should check if still working\n if (!state.checkForDisc.includes(interfaceUid)) {\n state.checkForDisc.push(interfaceUid);\n }\n }\n } else {\n // We have measured some volume, so interface is NOT quiet enough to warrant running netstat\n let i = state.checkForDisc.includes(interfaceUid);\n if (i > -1) {\n state.checkForDisc.splice(i, 1); // remove the entry\n }\n quietForHowLong[interfaceUid] = 0; // had a non-zero charCount this sampling period, so not quiet\n }\n });\n // clear object that measures how long from zero detect to disconnect detect\n state.quietToDisconnect = {};\n const now = Date.now();\n // quietForHowLong is a duration, create state.quietToDisconnect as an actual time\n Object.keys(quietForHowLong).forEach(uid => {\n if (quietForHowLong[uid]) {\n state.quietToDisconnect[uid] = now - quietForHowLong[uid]; // roughly time when first went quiet\n }\n });\n if (!state.checkForDisc.length) {\n return fulfill(); // all monitored interfaces reported some volume\n }\n\n // @param conn is a connection specification from sensor configuration. Has kind, src, dst, port\n // @param nsData one result from netstat, has local:{port,address},remote:{port,address},state,pid\n // @return true if match, else undefined\n function isMatch(conn, nsData) {\n // netstat returns data in relation to the machine that the sensor is running on\n // So this works to detect the estistance of a connection if run on one of the two machines\n // involved with a connection: either as client or server side.\n // The connection's dst and port is always the server side of the connection\n // while the connection's src is always the client side of the connection\n // If running the sensor on the server, match the connection destination to the local.address and local.port\n // If running the sensor on the client, match the connection destination to the remote.address and remote.port\n if (conn.src[0] === nsData.local.address && conn.dst[0] === nsData.remote.address && conn.port === nsData.remote.port) {\n return true;\n }\n return conn.src[0] === nsData.remote.address && conn.dst[0] === nsData.local.address && conn.port === nsData.local.port;\n }\n\n // Gathering stats on how long from a zero characterCount until disconnect is detected by netstat.\n\n // Note that interfaces may often have zero character count without being disconnected.\n // If any one interface has zero character count, then we do a full netstat and then detect\n // if any of the interfaces are down. The cost of detecting disconnect is essentially the same if we do all\n // verses doing just those with zero character count.\n\n\n // const candidates = existingConnections.filter(conn => state.checkForDisc.includes(conn.interfaceUid));\n // can only use netstat to determine if connection is established for connections whose kind is 'TCP/IP'\n // because they have persistent socket. Thos of kind 'WEB' are transient socket connections, for which\n // netstat is not an appropriate measure of disconnected (an alternative would be an ping-like api call).\n const tcpipCandidates = existingConnections.filter(conn => conn.kind === 'TCP/IP' && conn.measure.includes('disc'));\n\n // Track which connections that we are monitoring have been detected as ESTABLISHED by netstat\n const established = {}; // interfaceUid = true if 'ESTABLISHED' detected\n //\n // logger.verbose(`netstat candidates with 0 charCount: ${candidates.map(cn => cn.interfaceUid)}`);\n logger.verbose(`netstat monitored for disconnect tcpipCandidates: ${tcpipCandidates.map(cn => cn.interfaceUid)}`);\n // can use netstat to look for matching connections\n if (!tcpipCandidates.length) {\n logger.verbose(`netstat There are NO tcpipCandidates monitored for disconnect probing`);\n return fulfill();\n }\n\n if (state.netstat.performing) {\n logger.warning(`netstat Calling netstat when it is already running for ${Date.now() - state.netstat.performing} millis, skipping this report period`);\n return fulfill();\n }\n\n state.netstat.performing = Date.now();\n logger.verbose(`netstat starting`);\n netstat({\n filter: {\n protocol: 'tcp'\n },\n sync: false,\n watch: false,\n // Called when finished, maybe because of error\n done: function (err) {\n\n const disconnects = []; // accumulate disconnects for potential check with pings\n const connects = []; // accumulate established connections for stats\n\n // We have examined all netstat sockets and compiled a establish[connectionUid] = true map.\n // The setting of disconnected property in samples is performed here *synchronously*\n // and affects the current reporting period, even though the netstat theorectically\n // may have started in the prior (or earlier) reporting period, depending on how long it took to finish.\n // Practical measures showed 67-134 ms, so it is much smaller than the 10,000 ms reporting period\n logger.verbose(`netstat done, started @${reptCounter} finished @${state.report.counter}, found ${Object.keys(established).length} established monitored connections out of ${tcpipCandidates.length} tcpip candidates`);\n if (err) {\n console.error(`netstat error occurred ${err}`);\n state.netstat.performing = undefined;\n return reject(err);\n }\n const now = Date.now();\n tcpipCandidates.forEach(conn => {\n sample = ensureSample(conn.interfaceUid);\n\n if (established[conn.interfaceUid]) {\n sample.disconnected = false;\n state.disconnected[conn.interfaceUid] = false;\n connects.push(conn.interfaceUid);\n } else {\n // if this is a change in disconnect status?\n const wasDisc = state.disconnected[conn.interfaceUid];\n logger.verbose(`netstat setting ${conn.interfaceUid} as disconnected`);\n sample.disconnected = true;\n state.disconnected[conn.interfaceUid] = true;\n disconnects.push(conn.interfaceUid);\n if (!wasDisc) {\n const howLong = now - state.quietToDisconnect[conn.interfaceUid];\n state.netstat.minQuietToDisconnect = Math.min(state.netstat.minQuietToDisconnect || Number.MAX_SAFE_INTEGER, howLong);\n state.netstat.maxQuietToDisconnect = Math.max(state.netstat.maxQuietToDisconnect, howLong);\n }\n }\n });\n try {\n const elapsed = (now - state.netstat.performing) / 1000; // seconds with 3 decimal places\n state.netstat.time += elapsed; // seconds\n state.netstat.maxTime = Math.max(state.netstat.maxTime || 0, elapsed);\n state.netstat.minTime = Math.min(state.netstat.minTime || Number.MAX_SAFE_INTEGER, elapsed);\n state.netstat.ran++;\n state.netstat.avgTime = Math.round(state.netstat.time / state.netstat.ran * 1000) / 1000; // seconds with 3 decimal places\n state.netstat.disconnects += disconnects.length;\n state.netstat.connects += connects.length;\n logger.verbose(`netstat stats ${JSON.stringify(state.netstat)}`);\n state.netstat.error = undefined;\n } catch (ex) {\n state.netstat.error = `netstat error updating netstat stats and computing avg time it takes to run ${err}`;\n logger.error(state.netstat.error);\n }\n\n state.netstat.performing = undefined;\n fulfill();\n }\n }, function (data) { // called for each TCP/IP connection\n logger.debug(`netstat data ${JSON.stringify(data)}`);\n const connection = tcpipCandidates.find(conn => isMatch(conn, data));\n if (connection) {\n state.report.inReport++; // found a moitored connection in the netstat report\n if (data.state === 'ESTABLISHED') {\n established[connection.interfaceUid] = true;\n }\n }\n });\n });\n}", "title": "" }, { "docid": "e9743c80af5ec2431d6dbbc5a06f5adf", "score": "0.46763352", "text": "function checkCounter() {\n if (counter === 0) {\n return console.log(\"i am working\");\n }\n }", "title": "" }, { "docid": "ebd57f7a1a85c5b5505790f7d42db2f8", "score": "0.46740624", "text": "function getNextSlideNumberExcludingSkipped(slideNumber) {\n var nextSlideNumber = slideNumber\n do {\n nextSlideNumber++\n } while (nextSlideNumber < SLIDE_INFO.length && \n (SLIDE_INFO[nextSlideNumber].skipInCompanion || \n (SLIDE_INFO[nextSlideNumber].skipIfPressedOnTime && skipIfPressedOnTime)))\n\n if (nextSlideNumber >= SLIDE_INFO.length) {\n return NO_SLIDE_AVAILABLE\n } else {\n return nextSlideNumber\n }\n}", "title": "" }, { "docid": "8ca54fee55be1d9957493c083be51386", "score": "0.4670124", "text": "function checkNoOhioPolicyNbr() {\n gso.getCrudService().execute(constants.get, globalUrlConfig.globalApi + globalUrlConfig.globalBase + globalUrlConfig.resources.company + \"/\" +\n gso.getAppConfig().companyId + globalUrlConfig.resources.workersCompPolicies, null, function (wcPolicies) {\n if (wcPolicies.length === 0 || wcPolicies[0].policyNumber === \" \") {\n noOhioPolicyNumber = true;\n } else {\n noOhioPolicyNumber = false;\n }\n });\n }", "title": "" }, { "docid": "4e45c2626ad5f661f290fcc108957deb", "score": "0.4667184", "text": "getNonRejectedPreferenceIndex() {\n for (let index = 0; index < this.preferences.length; ++index) {\n if (this.rejects.indexOf(this.preferences[index]) == -1) return this.preferences[index];\n }\n return -1;\n }", "title": "" }, { "docid": "e87a4a0da9110ae76b1bdb84da97ff8c", "score": "0.46669433", "text": "static getNumOfJobsPending(stationId) {\n var jobs = getGlobalJobs();\n var res = 0;\n var qty = 0;\n var val = 0;\n if (stationId === undefined) {\n jobs.map(job => {\n if (job.status != \"Confirmed\") {\n res += 1;\n qty += job.drink.quantity;\n val += job.drink.quantity * job.drink.pricePerUnit;\n }\n });\n } else {\n var station = globalStations[stationId];\n if (station != undefined) {\n //console.log(station.key)\n jobs.map(job => {\n if (job.stationKey == station.key && job.status != \"Confirmed\") {\n res += 1;\n qty += job.drink.quantity;\n val += job.drink.quantity * job.drink.pricePerUnit;\n }\n });\n }\n }\n return [res, qty, val];\n }", "title": "" }, { "docid": "e10d1170f5c88f31a8804c955da6ae8e", "score": "0.4660506", "text": "skipPlayer() {\n const { activeSeat } = this.public;\n\n logger.debug(`skipping ${this.seats[activeSeat].public.name}'s turn`);\n\n if (this.lastPlayerToAct === activeSeat) {\n this.endPhase();\n } else {\n this.actionToNextPlayer();\n }\n }", "title": "" }, { "docid": "0cd15a5cb2f4fe9bcbc5ea0f1a4ed186", "score": "0.46554402", "text": "async function getAllProjectEntryInProgress() {\n return await ProjectEntry.find({ \"statusOfPilling\": { $ne: 6 } }).sort({ $natural: -1 });\n}", "title": "" }, { "docid": "06d2bfe74a0e483449742639e6143014", "score": "0.46544197", "text": "async function check () {\n try {\n const { access_token } = await login()\n const params = new URLSearchParams({\n timeOfDay: 'ALL_DAY',\n lastDate: DateTime.now().toISODate(),\n lastTime: '00:00'\n })\n const resp = await nodeFetch(`https://impfzentren.bayern/api/v1/citizens/${citizen}/appointments/next?` + params.toString(), {\n headers: {\n ...headers,\n 'Authorization': `Bearer ${access_token}`\n }\n })\n\n if (resp.status === 404) {\n console.log('Keine Impftermine verfügbar ... ')\n } else {\n console.log('Es wurde ein Impftermin reserviert!')\n await notify('Es wurde ein Impftermin reserviert!')\n }\n } catch (e) {\n console.error(e)\n await notify(`Es ist ein Fehler aufgetreten: ${e.message}`)\n }\n}", "title": "" }, { "docid": "0b09293d97da7cd1e1311b4fbf06c3e1", "score": "0.46503705", "text": "async checkConditions() {\n let currentPlayer = this.controller.currentPlayer;\n this.controller.waiting = true;\n await this.checkSwamp(currentPlayer);\n await this.checkEnd(currentPlayer);\n this.controller.waiting = false;\n }", "title": "" }, { "docid": "58cbfbae43be687d3c88cffeea65dc76", "score": "0.46468866", "text": "static determineCurrentPlayer(gameId) {\n return new Promise((resolve, reject) => {\n // Get the game\n Game.get(gameId)\n .then((game) => {\n // Get the last played card to determine if next player is skipped or\n // direction changes.\n GameDeck.getLastPlayedCard(game.id)\n .then((lastPlayedCard) => {\n BaseDeck.getCard(lastPlayedCard.card)\n .then((lastPlayedBaseCard) => {\n const isClockwise = game.direction_clockwise;\n const nextPlayerSkipped = lastPlayedBaseCard.value === BaseDeck.SKIP || lastPlayedBaseCard.value === BaseDeck.DRAW2 || lastPlayedBaseCard.value === BaseDeck.WILDDRAW4;\n \n // Get all of the game users\n GameUser.getGameUsers(gameId)\n .then((gameUsers) => {\n const currentPlayer = gameUsers.filter((i) => i.current_player == true)[0];\n\n // If there is no current player, assign one at random.\n if(!currentPlayer) {\n let randomPlayerNum = Math.floor(Math.random() * GameUser.MAX_GAME_USERS_PER_GAME) + 1;\n let randomPlayer = gameUsers.filter((i) => i.player_num == randomPlayerNum)[0];\n \n GameUser.setCurrentPlayer(gameId, randomPlayer.user, true)\n .then(() => {\n return resolve(randomPlayer);\n })\n .catch((err) => {\n return reject(err);\n })\n \n } else {\n // If there is a current player, determine the next player\n // and update current player status for both players.\n var promises = [];\n let nextPlayerNum;\n let nextPlayer;\n\n if(isClockwise) {\n\n if(currentPlayer.player_num === GameUser.MAX_GAME_USERS_PER_GAME) {\n \n if(nextPlayerSkipped) {\n nextPlayerNum = 2\n } else {\n nextPlayerNum = 1;\n }\n\n } else {\n\n if(nextPlayerSkipped) {\n if(currentPlayer.player_num + 2 > GameUser.MAX_GAME_USERS_PER_GAME) {\n nextPlayerNum = 1;\n } else {\n nextPlayerNum = currentPlayer.player_num + 2;\n }\n } else {\n nextPlayerNum = currentPlayer.player_num + 1;\n }\n\n }\n\n } else {\n\n if(currentPlayer.player_num === 1) {\n\n if(nextPlayerSkipped) {\n nextPlayerNum = GameUser.MAX_GAME_USERS_PER_GAME - 1;\n } else {\n nextPlayerNum = GameUser.MAX_GAME_USERS_PER_GAME;\n }\n\n } else {\n\n if(nextPlayerSkipped) {\n if(currentPlayer.player_num - 2 < 1) {\n nextPlayerNum = GameUser.MAX_GAME_USERS_PER_GAME;\n } else {\n nextPlayerNum = currentPlayer.player_num - 2;\n }\n } else {\n nextPlayerNum = currentPlayer.player_num - 1;\n }\n\n }\n\n }\n\n // Set the nextPlayer based off the computed nextPlayerNum\n nextPlayer = gameUsers.filter((i) => i.player_num == nextPlayerNum)[0];\n \n // Create promises for updating current and next player.\n promises.push(\n GameUser.setCurrentPlayer(gameId, currentPlayer.user, false),\n GameUser.setCurrentPlayer(gameId, nextPlayer.user, true)\n );\n\n // Execute promises\n Promise.all(promises)\n .then(() => {\n return resolve(nextPlayer);\n })\n .catch((err) => {\n return reject(err);\n })\n }\n })\n .catch((err) => reject(err));\n })\n .catch((err) => reject(err));\n })\n .catch((err) => reject(err));\n })\n .catch((err) => reject(err));\n });\n }", "title": "" }, { "docid": "cd15972fae29da1a271ff26a9bf17db1", "score": "0.4643771", "text": "function genShouldSkipDocument(documentData) {\n return Promise.resolve(false);\n}", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "cfa867d7139c953236b0ed9172967f61", "score": "0.46415192", "text": "increasePendingRequestCount() {\n this._pendingCount += 1;\n this._didWork = true;\n return this._pendingCount;\n }", "title": "" }, { "docid": "2ab78f8c01f800eb019fadc4fa2ad038", "score": "0.46397907", "text": "get STATE_AWAIT() { return 5; }", "title": "" }, { "docid": "2887ac2e66e0f732bdf7ab16bde4bf0b", "score": "0.46358153", "text": "getAreGamesInProgressPromise(){\n return this.GetPromise('/v3/nhl/stats/{format}/AreAnyGamesInProgress');\n }", "title": "" }, { "docid": "d64e85e41ce9763bf5bfe3cc38666243", "score": "0.46294254", "text": "async existsIdState(id) {\n aux = await STATE.findByPk(id).catch(function() {\n console.log(\"Promise Rejected\");\n });\n if (aux == null) {\n return false;\n } else {\n return true;\n }\n }", "title": "" }, { "docid": "d5cf96ab2f6235ee29e85e40e10d393f", "score": "0.46161398", "text": "function incrementExpectedAwaits() {\n if (!task.id)\n task.id = ++taskCounter;\n ++task.awaits;\n task.echoes += ZONE_ECHO_LIMIT;\n return task.id;\n}", "title": "" }, { "docid": "3ae6c78095c2d7f79575e2ad19e8d274", "score": "0.46123785", "text": "availableQuantity() {\n return Sequelize.models.Response.sum('quantity', { \n where: {\n TierId: this.id,\n confirmedAt: { $ne: null }\n }\n })\n .then(usedQuantity => {\n if (this.maxQuantity && usedQuantity) {\n return this.maxQuantity - usedQuantity;\n } else if (this.maxQuantity) {\n return this.maxQuantity;\n } else {\n return Infinity;\n }\n })\n }", "title": "" }, { "docid": "3f1b5ecebd32492bc0c12971fe5e5c5c", "score": "0.46027055", "text": "function checkOddNumberHandler(input) {\n\n var defer = $q.defer(); //instantiating a promise obj.\n\n //$timeout() method to delay 1 second.\n $timeout(function() {\n if (isNumberOdd(input)) {\n defer.resolve('Yes, an odd number');\n } else {\n defer.reject('Not an odd number');\n }\n }, 1000);\n return defer.promise;\n }", "title": "" }, { "docid": "a30a051b692f6a671e2e34b65800e301", "score": "0.46021983", "text": "get pending() {\n return this._pendingCount;\n }", "title": "" }, { "docid": "a30a051b692f6a671e2e34b65800e301", "score": "0.46021983", "text": "get pending() {\n return this._pendingCount;\n }", "title": "" }, { "docid": "ac98e955e2ca2a1e7b5d31da2132b2d9", "score": "0.46017888", "text": "succeed() {\n this.cancel();\n this._fails = 0;\n this._current = this.min;\n }", "title": "" }, { "docid": "16ed11cb3b051f261004ce20bd108ea0", "score": "0.45964795", "text": "function m_pingBooleanResult(th, deviceName) {\n var deferred = $.Deferred();\n\n m_ping(th, deviceName, 'normal').done(function(result) {\n if (result.indexOf('0 packets received') >= 0) {\n deferred.resolve(false);\n } else {\n deferred.resolve(true);\n }\n }).fail(function(err) {\n deferred.reject(err);\n });\n\n return deferred.promise();\n}", "title": "" }, { "docid": "c04ff07d9a169cecca523ddc1a21ef95", "score": "0.45956054", "text": "function getPrevSlideNumberExcludingSkipped(slideNumber) {\n var prevSlideNumber = slideNumber\n do {\n prevSlideNumber--\n } while (prevSlideNumber >= 0 && \n (SLIDE_INFO[prevSlideNumber].skipInCompanion || \n (SLIDE_INFO[prevSlideNumber].skipIfPressedOnTime && skipIfPressedOnTime)))\n\n if (prevSlideNumber < 0) {\n return NO_SLIDE_AVAILABLE\n } else {\n return prevSlideNumber\n }\n}", "title": "" }, { "docid": "026df7c2a6428aface1036c014eb9226", "score": "0.45839503", "text": "function isNotComplete(value) {\n return splitTask(value).filter(number => number).length < 3 ? true : false;\n }", "title": "" }, { "docid": "2ae971831c2a987be158df6f5279f666", "score": "0.4574698", "text": "checkBettingComplete(nextPlayer){\n var didBetCount=0;\n var activePlayer=0;\n\n for(var index=0; index<this.players.length; index++){\n if(this.players[index].folded == false && this.players[index].allIn == false){\n activePlayer++;\n }\n if(this.players[index].didBet == true){\n didBetCount++;\n }\n }\n if(didBetCount==activePlayer){\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "aba1f9fe46e4354a66e17ad4509cfce7", "score": "0.45726666", "text": "function checkMinimumTokensRequiredToChallenge() {\n return new Promise(resolve => {\n ParameterizerContract.methods.get(\"minDeposit\").call((error, result) => {\n if (!error) {\n console.log(result.toString());\n resolve(result);\n } else {\n resolve(error);\n }\n });\n });\n}", "title": "" }, { "docid": "d65a9a2db9aaacd614c79cc10cdd6af7", "score": "0.45699638", "text": "determineNextStatus() {\n for (let i = 0; i < this.state.errors.length; i++) {\n if (this.state.errors[i] === 1)\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "8da9a89bb676c7c3ac2ce903a774df47", "score": "0.45642242", "text": "static getNumOfRunnerJobsPending(stationId) {\n var jobs = getGlobalJobs();\n var res = 0;\n var qty = 0;\n var val = 0;\n if (stationId === undefined) {\n jobs.map(job => {\n if (job.status == \"In transit\" || job.status == \"Unstarted\") {\n res += 1;\n qty += job.drink.quantity;\n val += job.drink.quantity * job.drink.pricePerUnit;\n }\n });\n } else {\n var station = globalStations[stationId];\n if (station != undefined) {\n jobs.map(job => {\n if (job.stationKey == station.key && (job.status == \"In transit\" || job.status == \"Unstarted\")) {\n res += 1;\n qty += job.drink.quantity;\n val += job.drink.quantity * job.drink.pricePerUnit;\n }\n });\n }\n }\n return [res, qty, val];\n }", "title": "" }, { "docid": "44ce34f25923340a908f0346bd863a4e", "score": "0.4564072", "text": "get violationsOfPreference2() {\n let count = new Number(0);\n let lastPlanned=this.schedule[0];\n for (let day=0; day<this.schedule.length; day++) {\n if (this.schedule[day]!=lastPlanned) {\n if(this.schedule[day]=='x' || lastPlanned=='x') {\n count++;\n }\n else {\n count+=2;\n }\n }\n lastPlanned=this.schedule[day];\n }\n return count;\n }", "title": "" }, { "docid": "a66115392d5db30fa78ab4c9c129483b", "score": "0.45607904", "text": "gameInProgress() {\r\n if (this.gamestate === GAMESTATE.ONGOING) {\r\n return true;\r\n } else {\r\n return false;\r\n }\r\n }", "title": "" }, { "docid": "e6430dc06ca44bab3da9d755eb80a1f0", "score": "0.45602107", "text": "verifyTransaction() {\n return Promise.resolve(true);\n }", "title": "" }, { "docid": "ab1a909d7cf4fef323f91aaa2ebb6a19", "score": "0.4555775", "text": "function skipMission() {\n //hide the modal, update the game, and start next round\n $(\".modal\").modal('hide');\n gameInfo.numRejectedMissionsIAR += 1;//increment this\n gameInfo.currentLeaderIndex = (gameInfo.currentLeaderIndex + 1) % gameInfo.players.length\n gameInfo.missionMembers = [];\n gameInfo.startNewRound = true;\n\n socket.emit('updateGame', gameInfo);\n}", "title": "" }, { "docid": "067f9e0d35300fb1013b6e7feeb79521", "score": "0.45514262", "text": "isSuccess(result) {\n return tslib_1.__awaiter(this, void 0, void 0, function* () {\n if (result.success !== true) {\n // request wasnt successful\n if (result.status >= 400 && result.status <= 403) {\n this.banCount++;\n utils_1.Utils.writeLog('Request ended with status: ' +\n result.status +\n ', Ban-Count is now on: ' +\n this.banCount +\n ' of total: ' +\n this.banCountToBeBanned +\n ', when reached, then bot will sleep for ' +\n this.banSleepTime / 3600 +\n ' hours');\n yield this.startBanSleep();\n return Promise.resolve(false);\n }\n else {\n yield utils_1.Utils.sleep();\n return Promise.resolve(false);\n }\n }\n else {\n // successful request\n return Promise.resolve(true);\n }\n });\n }", "title": "" }, { "docid": "e4f20a0459baff0003edac4e64dd4128", "score": "0.45463598", "text": "function checkActiveScan(){\n window.setTimeout(function(){\n $.ajax({\n url: '/fullScanStatusDB',\n type: 'GET'\n }).done(function(response){\n if(response.status == -1){\n //init\n $('#startScan').removeClass('disabled');\n $('#cancelButton').addClass('disabled');\n $('#scanningmessage').css('display','none');\n $('#message').css('display','none');\n }else if(response.status == 100 && response.scanType=='Active scan'){\n\n showScanning('Active scan... 100%','It takes a few seconds to minutes to scan your website.');\n ascanFinish(100).then(() => {\n showMessage('Scan task has finished successfully.','You can downlaod report below','successful');\n\n });\n\n }else{\n showScanning(response.scanType+'... '+response.status+'%','It takes a few seconds to minutes to scan your website.');\n //console.log(response.scanType+' '+ response.status);\n checkActiveScan();\n }\n }).fail(function(){\n //console.log('Ajax /pscanStatus error from checkActiveScan');\n });\n },1000);\n }", "title": "" }, { "docid": "e77300d94240c46d0b5a302562bc14de", "score": "0.4545834", "text": "getUserWonToken() {\n return new Promise((resolve, reject) => {\n this.state.shitCoinGrabBagInstance.getContractAddressOfTransferredToken.call(this.state.account)\n .then((tokenWonByUser) => {\n if (!web3.toBigNumber(tokenWonByUser).isZero())\n {\n resolve(tokenWonByUser);\n } else {\n resolve(null);\n }\n });\n })\n }", "title": "" }, { "docid": "48ff1901225cc2ee18360965e4abc5c7", "score": "0.45393363", "text": "function canCompleteCircuit(gas, cost) {\n /* Instantiate a variable to track the sum of the difference\n between the gas and cost from a given index */\n let currentSum = 0;\n /* Instantiate a variable to track the sum of the difference\n between the gas and cost from index 0 */\n let total = 0;\n /* Instantiate a variable to keep track of the index\n the currentSum is counting from */\n let start = 0;\n for (let i = 0; i < gas.length; i++) {\n currentSum += gas[i] - cost[i];\n total += gas[i] - cost[i];\n /* If the currentSum is less than 0, \n we want to start the currentSum back at 0\n since that's the amount of gas we're meant to start\n with at whatever station we start with.\n We also want to change the start index to reflect\n that we can't have started from any gas stations\n we've previously looked at because the currentSum \n dropped below 0. */\n if (currentSum < 0) {\n currentSum = 0;\n start = i + 1;\n }\n }\n /* If the value of the total sum is greater than or equal\n to 0, we know we were able to make a complete circuit\n and we can return the index of the station we started \n counting from the last.\n If the value of the total sum is less than 0, return -1 */\n return total >= 0 ? start : -1;\n}", "title": "" }, { "docid": "c5cef9cb458a468168d1041160ddcea8", "score": "0.45310253", "text": "findNextFreeServer() {\n const { serverList } = this.state;\n\n for (let i = 0; i < serverList.length; i += 1) {\n if (serverList[i].isEmpty) {\n return i;\n }\n\n if (serverList[i].apps.length === 1) {\n return i;\n }\n }\n return -1;\n }", "title": "" } ]
6d95878081d8143bb873d1ee36adb65c
Create matchers by actual (ineffect) filter keys.
[ { "docid": "8839c4115d7a4738b27f8d62fdd5ed0c", "score": "0.7642376", "text": "function filter_matchers(filter, fkeys) {\n var matchers = {};\n if (!Array.isArray(fkeys)) { return null; }\n fkeys.forEach((fk) => {\n var fval = filter[fk];\n if (!fval) { return; }\n var re = new RegExp(fval);\n matchers[fk] = re;\n // matchers[fk] = new RegExp(filter[fk]);\n });\n return matchers;\n }", "title": "" } ]
[ { "docid": "60ba1edc33033c631f91bbfd9d724d6d", "score": "0.5837303", "text": "function buildAttributeMatcher(match) {\n var keys = Object.keys(match);\n var jskey, i, l;\n\n var transform = '';\n var bool = '';\n\n transform = 'transform = {\\n';\n for (i = 0, l = keys.length; i < l; i++) {\n jskey = JSON.stringify(keys[i]);\n\n transform += ' ' + jskey + ': attr.hasOwnProperty(' + jskey + ') ? attr[' + jskey + '].toLowerCase() : false';\n if (i !== l - 1) transform += ',';\n transform += '\\n';\n }\n transform += '};\\n';\n\n bool = 'return !!(';\n for (i = 0, l = keys.length; i < l; i++) {\n jskey = JSON.stringify(keys[i]);\n\n if (i > 0) bool += ' || ';\n bool += ' ( transform[' + jskey + ']';\n\n if (Array.isArray(match[keys[i]])) {\n bool += ' && ( ';\n\n for (var j = 0, s = match[keys[i]].length; j < s; j++) {\n if (j > 0) bool += ' || ';\n\n if (typeof match[keys[i]][j] === 'string') {\n bool += 'transform[' + jskey + '] === \\'' + match[keys[i]][j].toLowerCase() + '\\'';\n } else if (util.isRegExp(match[keys[i]][j])) {\n bool += 'match[' + jskey + '][' + j + '].test(transform[' + jskey + '])';\n }\n }\n\n bool += ' )';\n }\n\n bool += ' ) \\n';\n }\n\n bool += ' );';\n\n var anonymous = new Function('attr', 'match', transform + '\\n' + bool);\n return function (attr) {\n return anonymous(attr, match);\n };\n}", "title": "" }, { "docid": "3dfc3f6a3bc872caacef7c6244f16a6a", "score": "0.57050806", "text": "function createFilter(filter, keys) {\n // This must go first because _.isObject(fn) === true\n if (_.isFunction(filter)) {\n return createFilterObject(filter, keys);\n }\n\n // If the filter is an object describing a filter, generate the\n // appropriate function.\n if (_.isObject(filter)) {\n return createFilterFromObject(filter);\n }\n}", "title": "" }, { "docid": "3dfc3f6a3bc872caacef7c6244f16a6a", "score": "0.57050806", "text": "function createFilter(filter, keys) {\n // This must go first because _.isObject(fn) === true\n if (_.isFunction(filter)) {\n return createFilterObject(filter, keys);\n }\n\n // If the filter is an object describing a filter, generate the\n // appropriate function.\n if (_.isObject(filter)) {\n return createFilterFromObject(filter);\n }\n}", "title": "" }, { "docid": "e5846433568d7fe7a66acb2920cbb680", "score": "0.5427693", "text": "function generateFilters() {\n const filtersCollision = generateFiltersCollision();\n const filtersCommon = generateFiltersCommon();\n const filtersStudy = generateFiltersStudy();\n return {\n filtersCollision,\n filtersCommon,\n filtersStudy,\n };\n}", "title": "" }, { "docid": "582230030d7cd30eae4d9232b3285fa0", "score": "0.5337695", "text": "static generateFiltersFunction(filters) {\n if (!filters || !filters.length && !filters.count) {\n return FunctionHelper.returnTrue;\n }\n\n return function (candidate) {\n let match = true;\n\n for (const filter of filters) {\n // Skip disabled filters\n if (!filter.disabled) {\n match = filter.filter(candidate);\n }\n\n if (!match) {\n break;\n }\n }\n\n return match;\n };\n }", "title": "" }, { "docid": "ccd029ba4f387c3b464997b278a4d529", "score": "0.5236843", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(attrName) {\n return attrName.value.indexOf(lowercaseQuery)=== 0;\n };\n }", "title": "" }, { "docid": "6aacfb838633ae1bbaeee9e87049ca80", "score": "0.5206038", "text": "function kFilter(key){\n return function(obj,i,a){\n return ret.objInKey(obj,key);\n }\n }", "title": "" }, { "docid": "f3e42093b2b578d68a54ee394b9be86d", "score": "0.5142645", "text": "function reconstructFilters(filters) {\n return filters.map((filter) => ({ args: filter, name: 'metric' }))\n}", "title": "" }, { "docid": "d6fbcee7568557d58093f5a7b55fc478", "score": "0.5069738", "text": "_createFilterFor(query) {\n \tlet uppercaseQuery = angular.uppercase(query);\n \treturn function filterFn(rate) {\n\t\t\treturn (rate.name.indexOf(uppercaseQuery) === 0);\n \t};\n }", "title": "" }, { "docid": "606b17f85a2f980017b7c771a9f51d6d", "score": "0.505285", "text": "_compileFilter(filter) {\n let filters;\n switch (filter != null ? filter[0] : void 0) {\n case 'all':\n filter = filter.slice(1);\n filters = (() => {\n return filter.map((sub) => this._compileFilter(sub));\n }).call(this);\n return (feature) => !!filters.find((appliesTo) => {\n return !appliesTo(feature);\n });\n case 'any':\n filter = filter.slice(1);\n filters = (() => {\n return filter.map((sub) => this._compileFilter(sub));\n }).call(this);\n return (feature) => !!filters.find((appliesTo) => {\n return appliesTo(feature);\n });\n case 'none':\n filter = filter.slice(1);\n filters = (() => {\n return filter.map((sub) => this._compileFilter(sub));\n }).call(this);\n return (feature) => !filters.find((appliesTo) => {\n return !appliesTo(feature);\n });\n case '==':\n return (feature) => feature.properties[filter[1]] === filter[2];\n case '!=':\n return (feature) => feature.properties[filter[1]] !== filter[2];\n case 'in':\n return (feature) => !!filter.slice(2).find((value) => {\n return feature.properties[filter[1]] === value;\n });\n case '!in':\n return (feature) => !filter.slice(2).find((value) => {\n return feature.properties[filter[1]] === value;\n });\n case 'has':\n return (feature) => !!feature.properties[filter[1]];\n case '!has':\n return (feature) => !feature.properties[filter[1]];\n case '>':\n return (feature) => feature.properties[filter[1]] > filter[2];\n case '>=':\n return (feature) => feature.properties[filter[1]] >= filter[2];\n case '<':\n return (feature) => feature.properties[filter[1]] < filter[2];\n case '<=':\n return (feature) => feature.properties[filter[1]] <= filter[2];\n default:\n return () => true;\n }\n }", "title": "" }, { "docid": "7a1d291c1d8a162c275518263e1a9997", "score": "0.5044878", "text": "function createFilterFor(query) {\n\t\t\tvar lowercaseQuery = angular.lowercase(query);\n\t\t\treturn function filterFn(item) {\n\t\t\t\treturn (item.name.indexOf(lowercaseQuery) != -1);\n\t\t\t};\n\t\t}", "title": "" }, { "docid": "b26ad98ca452de8b6f3d829fa5acd76d", "score": "0.50413805", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(item) {\n return (angular.lowercase(item.name).indexOf(lowercaseQuery) >= 0);\n }; \n }", "title": "" }, { "docid": "5a0c02f26d6b98b3e804881fce807e30", "score": "0.50374454", "text": "function createFilterForTreatments(query) {\n var lcQuery = angular.lowercase(query);\n return function filterFn(item) {\n return (angular.lowercase(item.name).indexOf(lcQuery) === 0);\n }\n }", "title": "" }, { "docid": "9e2e6ac363672a7bdc4825af2a807fa9", "score": "0.5026761", "text": "function asPredicate(filters) {\n const { falsePositive } = filters;\n return (match) =>\n falsePositive == null ||\n (match.falsePositive == null && !falsePositive) || // treat falsePositive = null as false by default\n match.falsePositive === falsePositive;\n}", "title": "" }, { "docid": "a0d4b7bac07ed93bd36eff6eb93e2fa1", "score": "0.50231457", "text": "function testFilter(filter, expectedStrings) {\n var template = filterTemplateService.getFilterTemplate(filter, 'id', filter.label),\n i;\n for (i = 0; i < expectedStrings.length; i++) {\n expect(template.indexOf(expectedStrings[i])).toBeGreaterThan(-1);\n }\n }", "title": "" }, { "docid": "1a93acf0d3724b413acb90d43bb1add8", "score": "0.50183934", "text": "function _createRegexFilters() {\n _.each(relations, function(list) {\n filters.push(list.pattern)\n });\n\n\n }", "title": "" }, { "docid": "ef2f815c0f6e2b00c5bb68e5a254dfa6", "score": "0.5009931", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(item) {\n return (item.name.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "89906b517162a87f089df51309f53487", "score": "0.49995255", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(chord) {\n return\n (chord.title.toLowerCase().indexOf(lowercaseQuery) > -1)\n || (chord.titleEnChar.toLowerCase().indexOf(lowercaseQuery) > -1)\n };\n }", "title": "" }, { "docid": "89906b517162a87f089df51309f53487", "score": "0.49995255", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(chord) {\n return\n (chord.title.toLowerCase().indexOf(lowercaseQuery) > -1)\n || (chord.titleEnChar.toLowerCase().indexOf(lowercaseQuery) > -1)\n };\n }", "title": "" }, { "docid": "df6b18736c337e4a615992a0ff89ad8d", "score": "0.49759242", "text": "function preparePredictiveFilters() {\n var\n activeFilterRegExp = getActiveFilterExpression(),\n activeMultiplier = getActiveMultiplier(),\n relaxedFilterExpressions = {},\n // map of filter name -> map of filter value -> number of authors\n predictiveFiltersRoot = {};\n\n forEach(CONTRIBUTION_CODE_FILTERS, function(filterName) {\n relaxedFilterExpressions[filterName] =\n getRelaxedFilterExpression(filterName);\n predictiveFiltersRoot[filterName] = {};\n });\n predictiveFiltersRoot[TOTAL_CONTRIBUTIONS_FILTER] = {};\n\n // Get predictive filters for a given author\n //\n // Parameter:\n // author - array, author record\n //\n // Returns:\n // object, the set of predictive filters,\n // a map of filter name -> array of filter values:\n // for each filter including the TOTAL_CONTRIBUTIONS_FILTER,\n // the property contains an array with the list of filter values\n // for which the author would match as string values.\n function getPredictiveFilters(author) {\n var\n predictiveFilters = {},\n totalContributionsSelected,\n totalContributionsList = [],\n i;\n\n forEach(CONTRIBUTION_CODE_FILTERS, function(filterName) {\n var relaxedFilterRegExp = relaxedFilterExpressions[filterName];\n predictiveFilters[filterName] =\n getMatchingValues(author, relaxedFilterRegExp, activeMultiplier);\n });\n\n totalContributionsSelected =\n getTotalMatchingContributions(author, activeFilterRegExp);\n for ( i=1; i<=totalContributionsSelected; i++ ) {\n totalContributionsList.push( String(i) );\n }\n predictiveFilters[TOTAL_CONTRIBUTIONS_FILTER] = totalContributionsList;\n\n return predictiveFilters;\n }\n\n publish(\"predictive-filters-root\", predictiveFiltersRoot);\n publish(\"predictive-filter-function\", getPredictiveFilters);\n publish(\"active-and-predictive-filters-ready\");\n }", "title": "" }, { "docid": "f60fcd88dcb1abc2df5141515c12e45f", "score": "0.4970789", "text": "function createKeywordMatcher(arr, caseInsensitive) {\n if (caseInsensitive === void 0) {\n caseInsensitive = false;\n }\n\n if (caseInsensitive) {\n arr = arr.map(function (x) {\n return x.toLowerCase();\n });\n }\n\n var hash = arrayToHash(arr);\n\n if (caseInsensitive) {\n return function (word) {\n return hash[word.toLowerCase()] !== undefined && hash.hasOwnProperty(word.toLowerCase());\n };\n } else {\n return function (word) {\n return hash[word] !== undefined && hash.hasOwnProperty(word);\n };\n }\n}", "title": "" }, { "docid": "d3d0cff571e92335f0aded94b214cf6e", "score": "0.4955198", "text": "function createKeywordMatcher(arr, caseInsensitive) {\n if (caseInsensitive === void 0) { caseInsensitive = false; }\n if (caseInsensitive) {\n arr = arr.map(function (x) { return x.toLowerCase(); });\n }\n var hash = arrayToHash(arr);\n if (caseInsensitive) {\n return function (word) {\n return hash[word.toLowerCase()] !== undefined && hash.hasOwnProperty(word.toLowerCase());\n };\n }\n else {\n return function (word) {\n return hash[word] !== undefined && hash.hasOwnProperty(word);\n };\n }\n}", "title": "" }, { "docid": "155379d5bad782e6daf1d333958e0205", "score": "0.49462277", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(name) {\n return (name.value.indexOf(lowercaseQuery) > -1)\n\n //return (name.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "7314e0152ad58f1274a62d7389391cb6", "score": "0.49451944", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(item) {\n return (item.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "7f25e7a8cb2e6d61626fa927e78dd504", "score": "0.4944156", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(item) {\n return (item.value.indexOf(lowercaseQuery) != -1);\n };\n }", "title": "" }, { "docid": "fda10dedf9851358c3388be71698a308", "score": "0.49341795", "text": "_filterData(data, conditions) {\n let filterOnAnyAttribute = false;\n if(typeof conditions === 'string'){\n filterOnAnyAttribute = true;\n }\n // function return bool whether subtring is found or not\n const searchForSubstring = function(searchIn, searchFor){\n // for case-insensitive match, convert both string to lower case and then search\n return this.useCaseSensitiveFilter?\n searchIn.indexOf(searchFor) > -1 :\n searchIn.toLocaleLowerCase().indexOf(searchFor.toLocaleLowerCase()) > -1;\n }.bind(this);\n\n const filterOnAny = function(item, index, array){\n let res = false;\n for (let p in item) {\n if (typeof p === 'string') {\n // convert both string to lowercase to perform case-insensitive matching\n if(searchForSubstring(item[p].toString(), conditions)) {\n res = true;\n break;\n }\n }\n }\n\n return res;\n\n }\n\n const filterOnSomePredicateAny = function(item, index, array){\n let res = false;\n const keys = Object.keys(conditions);\n let aVal, aKey;\n for (let i = 0; i < keys.length; i++) {\n aKey = keys[i];\n aVal = conditions[aKey];\n if (aVal && item[aKey] && searchForSubstring(item[aKey].toString(), aVal.toString())) {\n res = true;\n break;\n } else {\n res = false;\n }\n }\n\n return res;\n }.bind(this);\n\n\n const filterOnSomePredicateAll = function(item, index, array){\n let res = false;\n const keys = Object.keys(conditions);\n let aVal, aKey;\n for (let i = 0; i < keys.length; i++) {\n aKey = keys[i];\n aVal = conditions[aKey];\n if (aVal && item[aKey] && searchForSubstring(item[aKey].toString(), aVal.toString())) {\n res = true;\n } else {\n res = false;\n break;\n }\n }\n\n return res;\n }.bind(this);\n\n\n let filteredData = [];\n\n if(filterOnAnyAttribute){\n filteredData = data.filter(filterOnAny);\n } else {\n if(this.headerFilterPredicate === 'AND'){\n filteredData = data.filter(filterOnSomePredicateAll);\n } else {\n filteredData = data.filter(filterOnSomePredicateAny);\n }\n }\n\n return filteredData;\n\n }", "title": "" }, { "docid": "b7e860a199ef20f1b6cc38f9e38674a4", "score": "0.49308708", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(item) {\n return (item.value.indexOf(lowercaseQuery) != -1);\n };\n }", "title": "" }, { "docid": "e6d3d67f447eeae9178e556463a61468", "score": "0.49279383", "text": "grok(filters, line) {\n let parsedObject = {}\n _.each(filters, (filter, key) => {\n const pattern = grok.loadDefaultSync().createPattern(filter)\n const parsed = pattern.parseSync(line)\n if (parsed) {\n debug.log('Grok filter', key, 'matched!')\n parsedObject = _.merge(parsedObject, parsed)\n } else {\n debug.warn('Grok filter', key, 'no match!')\n }\n })\n\n return parsedObject\n }", "title": "" }, { "docid": "b477e2a3df6cdb057ed302910c528a4f", "score": "0.49255252", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(item) {\n return (item.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "b477e2a3df6cdb057ed302910c528a4f", "score": "0.49255252", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(item) {\n return (item.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "b477e2a3df6cdb057ed302910c528a4f", "score": "0.49255252", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(item) {\n return (item.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "f968e4ae69492bd5245d81805d4f7311", "score": "0.49238968", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(vegetable) {\n return (vegetable._lowername.indexOf(lowercaseQuery) === 0);\n // (vegetable._lowertype.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "ae38df7dc93e94558e76c2f518a16f47", "score": "0.49238083", "text": "function dataFilter(key, value, filters) {\n return { value: { key: key, value: value, filters: filters }, type: ActionTypes.DATA_FILTER };\n}", "title": "" }, { "docid": "8dcf5b22571294d2427ff398e403bf15", "score": "0.49194077", "text": "function createFilterFor(query) {\r\n var lowercaseQuery = angular.lowercase(query);\r\n return function filterFn(item) {\r\n return (item.value.indexOf(lowercaseQuery) === 0);\r\n };\r\n }", "title": "" }, { "docid": "4596fa0339fcaf0d9364145fe026f376", "score": "0.4918096", "text": "constructor(match, filter, handler) {\n this.filter = filter\n this.match = match\n this.handler = handler\n }", "title": "" }, { "docid": "3aa2255e3dc7e769c5e4435a0ea63ca6", "score": "0.4896677", "text": "function createFilters(category, record) {\n recordText = record.get(category);\n var text = recordText.join(\", \");\n var filter = recordText\n .map((str) => str.replace(/\\s/g, \"\"))\n .join(\" \")\n .replace(\"/\", \"\")\n .toLowerCase();\n return [renameFilters(text), filter];\n }", "title": "" }, { "docid": "61c59ce53efc04d3ee32580a9c54772d", "score": "0.48950762", "text": "function matchesFactory(test) {\n return matches;\n\n function matches(node) {\n var key;\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false;\n }\n }\n\n return true;\n }\n}", "title": "" }, { "docid": "61c59ce53efc04d3ee32580a9c54772d", "score": "0.48950762", "text": "function matchesFactory(test) {\n return matches;\n\n function matches(node) {\n var key;\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false;\n }\n }\n\n return true;\n }\n}", "title": "" }, { "docid": "a070a3ab3f1cd4f2fcf802fa84c7c852", "score": "0.48933882", "text": "matchAny(items) {\n assert(\n this.key,\n 'Missing key on BlockFilter. Use deriveKey w/ block hash first'\n );\n return super.matchAny(this.key, items);\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.48871076", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "a5bb890eea8f8f2d2b6e96e51040330a", "score": "0.48848447", "text": "function createFilterForElement(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function (elementList) {\n return (elementList.name.toLowerCase().indexOf(lowercaseQuery) >= 0);\n\n };\n }", "title": "" }, { "docid": "0e6db97b11bc9b0e0284d59f94b09c15", "score": "0.48829716", "text": "filterItems(item, key) {\n if (key) {\n return item[key] === true;\n } else {\n return (\n item.title\n .toUpperCase()\n .includes(this.state.searchQuery.toUpperCase()) ||\n item.year.toString().includes(this.state.searchQuery) ||\n item.imdbRating.toString().includes(this.state.searchQuery)\n );\n }\n }", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "c3879671f1c16061d14ae163ebea7b64", "score": "0.4880053", "text": "function matchesFactory(test) {\n return matches\n\n function matches(node) {\n var key\n\n for (key in test) {\n if (node[key] !== test[key]) {\n return false\n }\n }\n\n return true\n }\n}", "title": "" }, { "docid": "1c9b6d66b07bf558a332e3ea13074326", "score": "0.4879468", "text": "function createFilterFor (query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(user) {\n //Create lowercase versions of all searcheable data\n var firstName = angular.lowercase(user.firstname);\n var lastName = angular.lowercase(user.lastname);\n var userName = angular.lowercase(user.username);\n\n // return an array of objects that include the query\n return (firstName.includes(lowercaseQuery) || \n lastName.includes(lowercaseQuery) ||\n userName.includes(lowercaseQuery));\n };\n }", "title": "" }, { "docid": "dc22b330027a0527c5975b7ef6f7a2fa", "score": "0.4879206", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "dc22b330027a0527c5975b7ef6f7a2fa", "score": "0.4879206", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "dc22b330027a0527c5975b7ef6f7a2fa", "score": "0.4879206", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "1d0016e94bf39e88041aa6e0978f4310", "score": "0.48670548", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function (obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "77ca14a7e0aa760978974790d3100f52", "score": "0.48664734", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "b282b93cc9bb7e8377ff9594268a3afe", "score": "0.48660725", "text": "function createFilterFor(query) {\n\t\t\tvar lowercaseQuery = angular.lowercase(query);\n\t\t\treturn function filterFn(state) {\n\t\t\t\treturn (state.value.indexOf(lowercaseQuery) === 0);\n\t\t\t};\n\t\t}", "title": "" }, { "docid": "2de976c26c5204a1eeea3bf99c5efe4d", "score": "0.48634163", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "cba41d4245ab88fda108d9239b516223", "score": "0.48600316", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) > -1);\n };\n }", "title": "" }, { "docid": "348565f543eb8edc1de588cb303fcb59", "score": "0.4859593", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n \n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n \n }", "title": "" }, { "docid": "c9a929574066c374b8327431c7d0f5a0", "score": "0.48557177", "text": "function makeFilter() {\r\n return function (value, index) {\r\n return filters.reduce(function (previousValue, currentValue) {\r\n if (previousValue === false) {\r\n return false;\r\n } else if (previousValue === true) {\r\n return currentValue[index];\r\n } else {\r\n return previousValue[index] && currentValue[index];\r\n }\r\n });\r\n };\r\n }", "title": "" }, { "docid": "3d283ba8bcede4d535240915525a2c22", "score": "0.48551607", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "3d283ba8bcede4d535240915525a2c22", "score": "0.48551607", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "3d283ba8bcede4d535240915525a2c22", "score": "0.48551607", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "3d283ba8bcede4d535240915525a2c22", "score": "0.48551607", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "3d283ba8bcede4d535240915525a2c22", "score": "0.48551607", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "8902ec82d6ac62fb4bda6e7546c358ac", "score": "0.4853712", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(movie) {\n return (movie.brutLabel.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "683d848f26565b2a218e4e6b468f6d6b", "score": "0.4851066", "text": "getFilters(){\n let filters = {\n active: false,//one or more of the filters is active?\n text: '',//original one (although trimmed)\n textRegExp: null, //RegExp object (or null) - prepared for actual regex test.\n //in future versions here we'll have maybe mimetype etc.\n }\n\n filters.text = document.querySelector('#filter-text').value;\n filters.text = filters.text.trim();\n\n \n if( filters.text != ''){\n filters.active = true;\n //is it wrapped in // ? Like '/blah.*/' - then user wants to treat it as a regex. \n if(utils.hasRegexDelimeters(filters.text)){\n //we'll use only what's inside the / and / - just like it is.\n filters.textRegExp = new RegExp(filters.text.substring(1, filters.text.length-1), \"i\"); \n }else{//otherwise we'll escape things like ? or * to do literal matching.\n filters.textRegExp = new RegExp(utils.escapeRegExp(filters.text), \"i\");\n }\n }\n\n return filters;\n }", "title": "" }, { "docid": "f9b2862cf2b8e7e3ddcefd7c5a96738e", "score": "0.4850746", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "3d8a741068f5b13d43a4c99322eff811", "score": "0.48483914", "text": "function createPredicateFn(expression, comparator, anyPropertyKey, matchAgainstAnyProp) {\n var shouldMatchPrimitives = isObject(expression) && (anyPropertyKey in expression);\n var predicateFn;\n\n if (comparator === true) {\n comparator = equals;\n } else if (!isFunction(comparator)) {\n comparator = function(actual, expected) {\n if (isUndefined(actual)) {\n // No substring matching against `undefined`\n return false;\n }\n if ((actual === null) || (expected === null)) {\n // No substring matching against `null`; only match against `null`\n return actual === expected;\n }\n if (isObject(expected) || (isObject(actual) && !hasCustomToString(actual))) {\n // Should not compare primitives against objects, unless they have custom `toString` method\n return false;\n }\n\n actual = lowercase('' + actual);\n expected = lowercase('' + expected);\n return actual.indexOf(expected) !== -1;\n };\n }\n\n predicateFn = function(item) {\n if (shouldMatchPrimitives && !isObject(item)) {\n return deepCompare(item, expression[anyPropertyKey], comparator, anyPropertyKey, false);\n }\n return deepCompare(item, expression, comparator, anyPropertyKey, matchAgainstAnyProp);\n };\n\n return predicateFn;\n}", "title": "" }, { "docid": "0e952efa51083f6206a3d9d8889941f3", "score": "0.48478058", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "0e952efa51083f6206a3d9d8889941f3", "score": "0.48478058", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "0e952efa51083f6206a3d9d8889941f3", "score": "0.48478058", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "321c9046430590ae520fabf5af109c55", "score": "0.48453104", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n }", "title": "" }, { "docid": "1031ebcd258400bfa304391e4420882d", "score": "0.4842627", "text": "function processFilters(filters) {\n const res = [];\n filters.forEach(i => {\n let key = Object.keys(i)[0];\n const value = Object.values(i)[0];\n switch (key) {\n case 'AgeRange':\n res.push({\n $nor: [\n {'details.AgeRange.Low': {$gt: parseInt(value.High)}},\n {'details.AgeRange.High': {$lt: parseInt(value.Low)}}\n ]\n });\n break;\n case 'Gender':\n res.push({'details.Gender.Value': value});\n break;\n default:\n const obj = {};\n obj['details.' + key + '.Value'] = value;\n res.push(obj);\n }\n });\n return res;\n}", "title": "" }, { "docid": "fbb1835fb853b9d001377c902f4502ac", "score": "0.48415077", "text": "function createFilterFor(query)\n {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(team) {\n\n return (team._lowername.indexOf(lowercaseQuery) === 0) ||\n (team.id === query.id);\n };\n\n }", "title": "" }, { "docid": "49c0f41b34a343ed2fc739635452b0e0", "score": "0.48409584", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(vegetable) {\n return (vegetable.name.indexOf(lowercaseQuery) === 0)\n };\n\n }", "title": "" }, { "docid": "5b668ae11b269cf0e24c3d28a38324de", "score": "0.4834662", "text": "function createFilterFor(query) \n {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(brand) \n {\n return (angular.lowercase(brand.name).indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "751ce2860d8f6ade54f6bbc511d45e74", "score": "0.4834371", "text": "getFiltered(entries){\n const filters = this.getFilters();\n\n //no filtering at all, we return *now* with no further processing (for performance reasons, we just have\n //nothing to do here)\n if (!filters.active){\n return entries;\n }\n\n //ok, there is at least one filter active\n const resultEntries = new Map();\n\n var t0 = performance.now();\n entries.forEach((entry, key) => {\n \n if(this.matches(entry, filters)){\n resultEntries.set(key, entry);\n }\n });\n var t1 = performance.now();\n //console.log(\"Call to do regex filtering took \" + (t1 - t0) + \" milliseconds.\");\n\n return resultEntries;\n }", "title": "" }, { "docid": "332d7c44faf2801c3734d27eacc53e96", "score": "0.48315486", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "332d7c44faf2801c3734d27eacc53e96", "score": "0.48315486", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "615058b9aacd2d2b844431bcb1ee068c", "score": "0.4830023", "text": "function createFilterFor(query) {\n\t\t\tvar lowercaseQuery = angular.lowercase(query);\n\n\t\t\treturn function filterFn(state) {\n\t\t\t\treturn (state.value.indexOf(lowercaseQuery) === 0);\n\t\t\t};\n\n\t\t}", "title": "" }, { "docid": "ff9bce034d146dd1221d9c4d26e6c9ee", "score": "0.48285335", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" }, { "docid": "24cee702486fdce64d14e2587ec284fd", "score": "0.48259062", "text": "function buildFilterInputs(filters) {\n function createFilterName(inputFilters) {\n var name = loDash.map(inputFilters, 'title').join(', ');\n return name || 'new filter';\n }\n\n function mapFilter(filter) {\n\n filter.inputFilters = getData(filter.filter);\n filter.name = createFilterName(filter.inputFilters);\n\n return filter.inputFilters;\n }\n\n return loDash.reduce(filters, function(acc, filter) {\n return acc.concat(mapFilter(filter));\n }, []);\n }", "title": "" }, { "docid": "edfdb674bc42cf76617026b962c17a75", "score": "0.4825457", "text": "function createFilterFor(query) {\n var lowercaseQuery = angular.lowercase(query);\n\n return function filterFn(state) {\n return (state.value.indexOf(lowercaseQuery) === 0);\n };\n\n }", "title": "" } ]
9ee9c4699a5334a8f1ea03d49efe2e3c
This is the actual method that sends event to server via HTTP request.
[ { "docid": "6a9c05dbc56b1e5d799a7fe83eb662d8", "score": "0.0", "text": "async sendBillingEventAggregateToServer(aggregateJson) {\n\n const headers = {\n 'Content-Type': 'application/json',\n Accept: 'application/json',\n Authorization: 'Bearer ' + Config.APP_KEY\n };\n \n console.log('BillingAggregateEvent: URL =', Config.BILLING_SERVICE, aggregateJson);\n \n try {\n const response = await axios.post(Config.BILLING_SERVICE, aggregateJson, {headers});\n let jResponse = response.data;\n console.log(\"BillingAggregateEvent RESPONSE = \",jResponse);\n return jResponse;\n \n } catch (error) {\n console.log('Network Error while performing billing aggregate event request => ', error);\n return {status: 'FAIL', error: error.message, reason: error.response.data.message};\n } \n }", "title": "" } ]
[ { "docid": "f5811a10c52742bbf4187c5c0f7e734f", "score": "0.77258575", "text": "function HttpSentEvent(){}", "title": "" }, { "docid": "85e15c12654b324998cf3817e5268a99", "score": "0.77057076", "text": "function HttpSentEvent() { }", "title": "" }, { "docid": "85e15c12654b324998cf3817e5268a99", "score": "0.77057076", "text": "function HttpSentEvent() { }", "title": "" }, { "docid": "980546db04a50b54e40d58baa63d8ef1", "score": "0.7397166", "text": "function sendEvent(uri) {\n\tnew Ajax.Request(uri, {\n\t\tmethod:\"post\",\n\t\trequestHeaders: [\"Accept\", \"application/json\"],\n\t\tonSuccess: logResponse,\n\t\tonFailure: logResponse\n\t});\n}", "title": "" }, { "docid": "c8e47b1442f7cfd3c59bd28238829499", "score": "0.6744587", "text": "function requestevent() {\r\n\t\t\t\t\t\r\n\t\t\t\t\t// HTTP Post Request XML for oadr 2a Request Event\r\n\t\t\t\t\tvar myXMLrequesteventa = '<oadr:oadrRequestEvent xmlns:ei=\"http://docs.oasis-open.org/ns/energyinterop/201110\" xmlns:emix=\"http://docs.oasis-open.org/ns/emix/2011/06\" xmlns:oadr=\"http://openadr.org/oadr-2.0a/2012/07\" xmlns:pyld=\"http://docs.oasis-open.org/ns/energyinterop/201110/payloads\" xmlns:strm=\"urn:ietf:params:xml:ns:icalendar-2.0:stream\" xmlns:xcal=\"urn:ietf:params:xml:ns:icalendar-2.0\"> <pyld:eiRequestEvent> <ei:requestID/> <ei:venID>'+node.ven_id+'</ei:venID> <pyld:replyLimit>99</pyld:replyLimit> </pyld:eiRequestEvent> </oadr:oadrRequestEvent>'\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\trequest({\r\n\t\t\t\t\turl: node.url+'/OpenADR2/Simple/EiEvent',\r\n\t\t\t\t\tmethod: \"POST\",\r\n\t\t\t\t\theaders: {\r\n\t\t\t\t\t\t\t\t\"content-type\": \"application/xml\", // <--Very important!!!\r\n\t\t\t\t\t\t\t},\r\n\t\t\t\t\t\t\tbody: myXMLrequesteventa\r\n\t\t\t\t\t\t}, function (error, response, body){\r\n\t\t\t\t\t\t// Error Handling\r\n\t\t\t\t\t\tif (body==undefined){\r\n\t\t\t\t\t\t\t//console.log(response);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if (response.statusCode==503){\r\n\t\t\t\t\t\t\trequestevent();\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if (response.statusCode==500){\r\n\t\t\t\t\t\t\trequestevent();\r\n\t\t\t\t\t\t}\t\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\t\r\n\t\t\t\t\tvar msg = { payload:body }\r\n\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\tnode.send(msg);\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}", "title": "" }, { "docid": "0781cbfa9c793219f8efed09dc467bc8", "score": "0.6718418", "text": "sendRequest(request, response) {\n this.executeHook('request', request, response);\n }", "title": "" }, { "docid": "9cc720949e7db4399f47a478142d1b5e", "score": "0.66880566", "text": "function sendEvent(){\n event = testJson.events.shift();\n if(event){\n function doSend(){\n console.log(\"sending event\",event.event);\n request.post(\n {\n url : url,\n json : {\n event : event.event,\n sessionToken : sessionToken \n }\n },\n handleResponse);\n }\n\n if(event.after){\n console.log(\"waiting to send\",event.after);\n setTimeout(doSend,event.after);\n }else{\n doSend();\n }\n }else{\n console.log(\"done with test\",testName);\n testsPassed.push(testName); \n done();\n }\n }", "title": "" }, { "docid": "7cbdf9b2557a9c750361579efdbcc730", "score": "0.6659342", "text": "function subscribeToHttpEvents(){\n //format (example):\n /*{\n name: \"remote-button\",\n data: {\n deviceId: \"o1\",\n button: \"mic\" //mic, back, ao, next, prev\n }\n }*/\n ClexiJS.subscribeTo('clexi-http-events', function(e){\n //console.log('HTTP-Event: ' + JSON.stringify(e));\n var event = new CustomEvent('clexi-http-events-msg', {detail: e});\n document.dispatchEvent(event);\n }, \n //This is actually not used by the HTTP-Events extension\n function(e){\n console.log('HTTP-Event response: ' + e);\n }, function(e){\n console.error('HTTP-Event error: ' + JSON.stringify(e));\n });\n }", "title": "" }, { "docid": "52049b0fe5595a8cd0cc13be5305b1e9", "score": "0.6658803", "text": "function subscribeToHttpEvents(){\n //format (example):\n /*{\n name: \"remote-button\",\n data: {\n deviceId: \"o1\",\n button: \"mic\" //mic, back, ao, next, prev\n }\n }*/\n ClexiJS.subscribeTo('clexi-http-events', function(e){\n //console.log('HTTP-Event: ' + JSON.stringify(e));\n var event = new CustomEvent('clexi-http-events-msg', {detail: e});\n document.dispatchEvent(event);\n }, \n //This is actually not used by the HTTP-Events extension\n function(e){\n console.log('HTTP-Event response: ' + JSON.stringify(e));\n }, function(e){\n console.log('HTTP-Event error: ' + JSON.stringify(e));\n });\n }", "title": "" }, { "docid": "715ffef8fc05aa7134c6198e22d01fb1", "score": "0.6613057", "text": "setToEventHub( msg){\n \n \n // do the POST call\n var reqPost = http.request(optionspost, function(res) {\n // This is the call back\n console.log('POSTed TO event Hub log API completed with status code ' + res.statusCode);\n });\n\n reqPost.on('error', function(e) {\n console.error('problem with request: ' + e.message);\n });\n \n console.log(this.log_info,'body string is ' + msg);\n \n reqPost.write(msg);\n reqPost.end(); \n }", "title": "" }, { "docid": "6da5138af866387f2dbc0d1c70df9616", "score": "0.65108144", "text": "function onRequest(request, response) {\n var beat = request.path.slice(1)\n log(\"beat \" + beat)\n\n response.send(\"beat queued\")\n\n Request('https://www.ibm.com/' + beat, function (error, response, body) {\n // log(error, response, body)\n log(\"forwarded status: \" + response.statusCode)\n })\n\n}", "title": "" }, { "docid": "f4ab6bb997a920570a8c0b18967e15ec", "score": "0.64814496", "text": "send() {\n this._libhoney.sendEvent(this);\n }", "title": "" }, { "docid": "ca2a830ef1445d8904aeab6b174107cb", "score": "0.64696306", "text": "function HttpUserEvent() { }", "title": "" }, { "docid": "ca2a830ef1445d8904aeab6b174107cb", "score": "0.64696306", "text": "function HttpUserEvent() { }", "title": "" }, { "docid": "c1318c5b92ec02de92790a0829497ca9", "score": "0.6362315", "text": "onRequestWillBeSent(data) {\n this._rawEvents.push({method: 'Network.requestWillBeSent', params: data});\n // NOTE: data.timestamp -> time, data.type -> resourceType\n this.networkManager._dispatcher.requestWillBeSent(data.requestId,\n data.frameId, data.loaderId, data.documentURL, data.request,\n data.timestamp, data.wallTime, data.initiator, data.redirectResponse,\n data.type);\n }", "title": "" }, { "docid": "3f203b8298060ac9206261dc78fbb78f", "score": "0.627871", "text": "Request() {\n console.log(\"RealSubject handles request\");\n }", "title": "" }, { "docid": "1978ba3331aca5db2c56c57abb7af1bf", "score": "0.62744594", "text": "function onRequest() {\n\tlog(\"New request\")\n}", "title": "" }, { "docid": "77c6cfbc318b3051fcdc8becc7cfbd6c", "score": "0.6268994", "text": "function sendEventData(eventAction, eventLabel){\n var tsNew = new Date().getTime()\n var refUrl = (document.referrer == \"\") ? \"https://www.google.co.kr\": document.referrer;\n var data = JSON.stringify({\n \"$class\": \"org.platform.data.EventData\",\n \"eventId\": \"E-\"+getCookie('uid')+\"-\"+tsNew.toString(),\n \"uid\": getCookie('uid'),\n \"sid\": getCookie('sid'),\n \"gender\": true,\n \"age\": 23,\n \"url\": document.URL,\n \"referer\": refUrl,\n \"width\": window.outerWidth,\n \"height\": window.outerHeight,\n \"time\": tsNew,\n \"title\": player.getVideoData()['title'],\n \"channel\": \"JTBC\",\n \"duration\": player.getDuration(),\n \"uptime\": player.getCurrentTime(),\n \"action\": eventAction,\n \"label\": eventLabel\n });\n console.log(data);\n apiName = \"EventData\"; \n sendData(data, apiName);\n}", "title": "" }, { "docid": "4bdc56a038eb0c6923066e5164bd2b2f", "score": "0.62300986", "text": "onRequestWillBeSent(data) {\n // NOTE: data.timestamp -> time, data.type -> resourceType\n this.networkManager._dispatcher.requestWillBeSent(data.requestId,\n data.frameId, data.loaderId, data.documentURL, data.request,\n data.timestamp, data.wallTime, data.initiator, data.redirectResponse,\n data.type);\n }", "title": "" }, { "docid": "01c041cfbd0db86475cfc61bf768fbd5", "score": "0.6219295", "text": "function NewEvent( eventName, eventDesc, deviceName, uDeviceName) {\n \n // const Http = new XMLHttpRequest();\n const api = 'http://'+ip+'/api/addevent.php?eventname=' + eventName + \"&description=\" + eventDesc + \"&devicename=\" + deviceName + \"&userdevicename=\"+ uDeviceName;\n \n console.log(api);\n \n // Http.open(\"GET\",api);\n // Http.send();\n}", "title": "" }, { "docid": "10af6ea422977fa4c475dce43a53fa94", "score": "0.61717385", "text": "function requestEvent( id, upcoming, index, index2 ){\n\n\t\tvar endpoint = base + id + token;\n\t\t//console.log(endpoint);\n\n\t\t$.ajax({\n\t\t\turl: endpoint,\n\t\t\tdataType: 'json'\n\t\t})\n\t\t.done(function( data ) {\n\t\t\t//console.log(\"success loading events\");\n\t\t\taddEvent( data, upcoming, index, index2 );\n\t\t})\n\t\t.fail(function( ) {\n\t\t\tconsole.log(\"error loading events\");\n\t\t})\n\t\t.always(function() {\n\n\t\t});\n\t}", "title": "" }, { "docid": "c9aeb06feae5dc85c4fd3d55f94e6cba", "score": "0.61396766", "text": "function eventReqListener () {\n var jsonResponse = JSON.parse(this.responseText);\n EventActions.createAll(jsonResponse.results);\n}", "title": "" }, { "docid": "178322c994b015b6877813ec91dc00e5", "score": "0.609731", "text": "function HttpUserEvent(){}", "title": "" }, { "docid": "d707aa98d497d9500e366a789c9fbc45", "score": "0.60936", "text": "function sendRequest() {\n var http = createRequestObject();\n const getURL = `${ivcPathToSrc}api/videos/progress.php`;\n http.open(\"GET\", getURL, true);\n http.onreadystatechange = function () { handleResponse(http); };\n http.send(null);\n}", "title": "" }, { "docid": "b6750ee818e8c065dfc7999209690528", "score": "0.60845107", "text": "sendEvent(id, eventName, message) {\n let responses = this.sseContainer.sseResponses[id];\n if (responses) {\n // message = {\n // event: eventName,\n // payload: message\n // };\n let result = `event: ${eventName}\\ndata: ${JSON.stringify(message)}\\n\\n\\n`;\n responses.forEach((response) => {\n response.write(result);\n });\n }\n }", "title": "" }, { "docid": "003718de8f6c099dfedcd382a1fc0795", "score": "0.6032628", "text": "get request() {\n\t\t\t\tthrow new Error('request in handle has been replaced with event' + details);\n\t\t\t}", "title": "" }, { "docid": "2242c2a020e1761113edb295fdc4b12b", "score": "0.60311913", "text": "reply() {\n this.events.emit(new ResponseBeforeSendEvent(this.connnection))\n this.response.send()\n this.events.emit(new ResponseAfterSendEvent(this.connnection))\n }", "title": "" }, { "docid": "36818c8a0fc439541c6e837f567e4d69", "score": "0.6008307", "text": "function requestevent2(ven_ID) {\r\n\t\t\t\t\t\r\n\t\t\t\t\t// HTTP Post Request XML for oadr 2b Request Event\r\n\t\t\t\t\tvar myXMLrequesteventb = '<?xml version=\"1.0\" encoding=\"utf-8\"?> <oadrPayload xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns=\"http://openadr.org/oadr-2.0b/2012/07\"> <oadrSignedObject> <oadrRequestEvent d3p1:schemaVersion=\"2.0b\" xmlns:d3p1=\"http://docs.oasis-open.org/ns/energyinterop/201110\"> <eiRequestEvent xmlns=\"http://docs.oasis-open.org/ns/energyinterop/201110/payloads\"> <requestID></requestID> <d3p1:venID>'+ven_ID+'</d3p1:venID> </eiRequestEvent> </oadrRequestEvent> </oadrSignedObject> </oadrPayload>'\r\n\t\t\t\t\t\r\n\t\t\t\t\trequest({\r\n\t\t\t\t\turl: node.url+'/OpenADR2/Simple/2.0b/EiEvent',\r\n\t\t\t\t\tmethod: \"POST\",\r\n\t\t\t\t\theaders: {\r\n\t\t\t\t\t\t\t\t\"content-type\": \"application/xml\", // <--Very important!!!\r\n\t\t\t\t\t\t\t},\r\n\t\t\t\t\t\t\tbody: myXMLrequesteventb\r\n\t\t\t\t\t\t}, function (error, response, body){\r\n\t\t\t\t\t\tconsole.log(\"\\n VEN ----oadrRequestEvent-----> VTN \\n\")\r\n\t\t\t\t\t\tconsole.log(new Date().toISOString())\r\n\t\t\t\t\t\tconsole.log(myXMLrequesteventb)\r\n\r\n\t\t\t\t\t\t// Grab data from response xml\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tvar doc = new dom().parseFromString(body)\r\n\t\t\t\t\t\tvar requestID = xpath.select(\"//*[local-name(.)='requestID']/text()\", doc)[0]\r\n\t\t\t\t\t\tvar eventID = xpath.select(\"//*[local-name(.)='eventID']/text()\", doc)[0]\r\n\t\t\t\t\t\tvar modificationNumber = xpath.select(\"//*[local-name(.)='modificationNumber']/text()\", doc)[0]\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t// HTTP Post Request XML for createdEvent\r\n\t\t\t\t\t\tvar myXMLcreatedevent = '<?xml version=\"1.0\" encoding=\"utf-8\"?> <oadrPayload xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\" xmlns=\"http://openadr.org/oadr-2.0b/2012/07\"> <oadrSignedObject> <oadrCreatedEvent d3p1:schemaVersion=\"2.0b\" xmlns:d3p1=\"http://docs.oasis-open.org/ns/energyinterop/201110\"> <eiCreatedEvent xmlns=\"http://docs.oasis-open.org/ns/energyinterop/201110/payloads\"> <d3p1:eiResponse> <d3p1:responseCode>200</d3p1:responseCode> <d3p1:responseDescription>OK</d3p1:responseDescription> <requestID /> </d3p1:eiResponse> <d3p1:eventResponses> <d3p1:eventResponse> <d3p1:responseCode>200</d3p1:responseCode> <d3p1:responseDescription>OK</d3p1:responseDescription> <requestID>'+requestID+'</requestID> <d3p1:qualifiedEventID> <d3p1:eventID>'+eventID+'</d3p1:eventID> <d3p1:modificationNumber>'+modificationNumber+'</d3p1:modificationNumber> </d3p1:qualifiedEventID> <d3p1:optType>optIn</d3p1:optType> </d3p1:eventResponse> </d3p1:eventResponses> <d3p1:venID>'+ven_ID+'</d3p1:venID> </eiCreatedEvent> </oadrCreatedEvent> </oadrSignedObject> </oadrPayload>'\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t// Error Handling\r\n\t\t\t\t\t\tif (body==undefined){\r\n\t\t\t\t\t\t\tconsole.log(response);\r\n\t\t\t\t\t\t\trequestevent2(ven_ID);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\telse if(body.indexOf(\"oadrDistributeEvent\") > -1) {\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif(body.indexOf(\"oadrResponseRequired>always<\") > -1){\r\n\t\t\t\t\t\toadrCreatedEvent(myXMLcreatedevent);\t\r\n\t\t\t\t\t\t} \r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tvar array_signalID = [];\r\n\t\t\t\t\t\tvar array_value=[];\r\n\t\t\t\t\t\tfor(var i=0;i<50;i++){\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tvar signalID = xpath.select(\"//*[local-name(.)='eiEvent']/*[local-name(.)='eiEventSignals']/*[local-name(.)='eiEventSignal']/*[local-name(.)='signalID']/text()\", doc)[i]\r\n\t\t\t\t\t\tvar value = xpath.select(\"//*[local-name(.)='eiEvent']/*[local-name(.)='eiEventSignals']/*[local-name(.)='eiEventSignal']/*[local-name(.)='currentValue']/*[local-name(.)='payloadFloat']/*[local-name(.)='value']/text()\", doc)[i]\r\n\t\t\t\t\t\tarray_signalID.push('\"'+ signalID +'\"');\r\n\t\t\t\t\t\tarray_value.push('\"' + value + '\"');\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\tif(value!==undefined){\r\n\t\t\t\t\t\t\r\n\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tif (value===undefined){ break;}\r\n\t\t\t\t\t\t//console.log(value.nodeValue)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tvar msg = { payload:body, all_data: '{\"signalID\":['+array_signalID +'], \"CurrentValue\":['+array_value +']}', value:array_value}\r\n\t\t\t\t\t\tnode.send(msg);\r\n\t\t\t\t\t\t\t\t\t\t\t\t\r\n\t\t\t\t\t\tconsole.log(\"\\n VTN ----oadrDistributeEvent-----> VEN \\n\")\r\n\t\t\t\t\t\tconsole.log(new Date().toISOString())\r\n\t\t\t\t\t\tconsole.log(body)\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t//console.log(body)\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t}\r\n\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\t\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\telse if(body.indexOf(\"oadrResponse\") > -1) {\r\n\t\t\t\t\t\tconsole.log(\"\\n VTN ----oadrResponse-----> VEN \\n\")\r\n\t\t\t\t\t\tconsole.log(new Date().toISOString())\r\n\t\t\t\t\t\tconsole.log(body)\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\telse if (response.statusCode==500){\r\n\t\t\t\t\t\t\trequestevent2(ven_ID);\r\n\t\t\t\t\t\t}\t\t\t\t\t\t\r\n\t\t\t\t\t\telse if (response.statusCode==503){\r\n\t\t\t\t\t\t\trequestevent2(ven_ID);\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}", "title": "" }, { "docid": "70b00a8d81c46e2ebc818055331d085e", "score": "0.60031366", "text": "function onRequest(request, response){\r\n\tvar command = request.headers.command\r\n\tvar data = request.headers.data\r\n\tvar url = request.headers.url\r\n\tvar cmdRcvd = \"\\n\\rCommand Data = \" + command + \" | \" + data + \" | \" + url + \" | \" + wsDeviceStatus\r\n//\tlogResponse(\" \")\r\n\tlogResponse(cmdRcvd)\r\n//\tconsole.log(\" \")\r\n\tconsole.log(cmdRcvd)\r\n\tcmdResponse = {}\r\n\tif (wsDeviceStatus == \"closed\" && command != \"hubCheck\") {\r\n\t\tcommand = \"connect\"\r\n\t}\r\n\tresponse.setHeader(\"command\", command)\r\n\tresponse.setHeader(\"hubStatus\", \"OK\")\r\n\tswitch(command) {\r\n\t\tcase \"hubCheck\":\r\n\t\t\tendResponse()\r\n\t\t\tbreak\r\n\t\tcase \"connect\":\r\n\t\t\tsetTimeout(endResponse, 9000)\r\n\t\t\twsDeviceOpen(url, data, response)\r\n\t\t\tbreak\r\n\t\tcase \"sendMessage\":\r\n\t\t\tsetTimeout(endResponse, 1000)\r\n\t\t\twsDevice.send(data)\r\n\t\t\tbreak\r\n\t\tcase \"close\":\r\n\t\t\tsetTimeout(endResponse, 1000)\r\n\t\t\twsDevice.close()\r\n\t\t\tbreak\r\n\t\tdefault:\r\n\t\t\tvar respMsg = \"#### Invalid Command \" + command + \" ####\"\r\n\t\t\tconsole.log(respMsg)\r\n\t\t\tlogResponse(respMsg)\r\n\t\t\tendResponse()\r\n\t}\r\n\tfunction endResponse() {\r\n\t\tresponse.setHeader(\"wsDeviceStatus\", wsDeviceStatus)\r\n\t\tresponse.setHeader(\"cmdResponse\", JSON.stringify(cmdResponse))\r\n\t\tresponse.end()\r\n\t}\r\n}", "title": "" }, { "docid": "d22fe44122f2cd99328ceb3dcfe78545", "score": "0.5998053", "text": "function send(event, data) {\n\tif (socket.intf === null) return;\n\n\tconst message = {\n\t\tintf : status.system.intf,\n\t\tevent,\n\t\tdata,\n\t};\n\n\t// Not ready quite yet\n\tif (socket.conn === null) return;\n\tif (typeof socket.conn.sendMessage !== 'function') return;\n\n\t// Send message over socket\n\tsocket.conn.sendMessage(message);\n} // send(event, data)", "title": "" }, { "docid": "df459470257e37b7a10c2d3978401c86", "score": "0.5994671", "text": "function HttpProgressEvent() { }", "title": "" }, { "docid": "df459470257e37b7a10c2d3978401c86", "score": "0.5994671", "text": "function HttpProgressEvent() { }", "title": "" }, { "docid": "fa358e19bc61d88e902f48dea2d8a012", "score": "0.5968469", "text": "function send(event, data) {\n\tif (socket.intf === null) return;\n\n\tlet message = {\n\t\tintf : status.system.intf,\n\t\tevent : event,\n\t\tdata : data,\n\t};\n\n\t// Encode object as AMP message\n\tlet amp_message = new amp();\n\tamp_message.push(message);\n\n\t// Not ready quite yet\n\tif (socket.conn === null) return;\n\tif (typeof socket.conn.write !== 'function') return;\n\n\t// Send AMP message over socket\n\tsocket.conn.write(amp_message.toBuffer());\n}", "title": "" }, { "docid": "802b3a6193ca5a01ea5893028aeb86ae", "score": "0.5963161", "text": "function onRequest(request, response)\n\t{\n\t\tvar postData = \"\";\n\t\tconnection.connect();\n\t\tvar pathname = url.parse(request.url).pathname;\n\t\trequest.addListener(\"data\", function(postDataChunk){\n\t\t\tpostData+=postDataChunk;\n\t\t});\n\t\trequest.addListener(\"end\", function()\n\t\t{\n\t\t\troute(handle ,connection, pathname, postData, response);\n\t\t});\n\n\t}", "title": "" }, { "docid": "ae85ce0bb0a1713fa141e06ee57d3e58", "score": "0.59584785", "text": "function sendRequest() {\n Magicaster.console.log(\"[Server] sendRequest\");\n if (sessionConfirmed || firstRequest) {\n // create empty request if nothing is pending\n if (!requestStarted) {\n startRequest();\n }\n send(endRequest());\n }\n }", "title": "" }, { "docid": "c6f4fbc3aa4800911f9c90315939bec1", "score": "0.5952019", "text": "function sendResponse(event, context, status, data, err) {\n var responseBody = {\n StackId: event.StackId,\n RequestId: event.RequestId,\n LogicalResourceId: event.LogicalResourceId,\n PhysicalResourceId: context.logStreamName,\n Status: status,\n Reason: getReason(err) + \" See details in CloudWatch Log: \" + context.logStreamName,\n\n };\n\n console.log(\"RESPONSE:\\n\", responseBody);\n var json = JSON.stringify(responseBody);\n\n var https = require(\"https\");\n var url = require(\"url\");\n\n var parsedUrl = url.parse(event.ResponseURL);\n var options = {\n hostname: parsedUrl.hostname,\n port: 443,\n path: parsedUrl.path,\n method: \"PUT\",\n headers: {\n \"content-type\": \"\",\n \"content-length\": json.length\n }\n };\n\n var request = https.request(options, function(response) {\n console.log(\"STATUS: \" + response.statusCode);\n console.log(\"HEADERS: \" + JSON.stringify(response.headers));\n context.done(null, data);\n });\n\n request.on(\"error\", function(error) {\n console.log(\"sendResponse Error:\\n\", error);\n context.done(error);\n });\n\n request.on(\"end\", function() {\n console.log(\"end\");\n });\n request.write(json);\n request.end();\n}", "title": "" }, { "docid": "e541c42620637244a88c5789bee50272", "score": "0.593041", "text": "function sendNotifiedEvent(userName,remoteMethodName,data)\n\t{\n\t // create the JSON object\n\t\t\tjsonObject = JSON.stringify({'userName':userName,'remoteMethodName':remoteMethodName,'data':data\n\t\t\t});\n\t\t\t \n\t\t\t// prepare the header\n\t\t\tvar postheaders = {\n\t\t\t\t'Content-Type' : 'application/json',\n\t\t\t\t'Content-Length' : Buffer.byteLength(jsonObject, 'utf8')\n\t\t\t};\n\t\t\t \n\t\t\t// the post options\n\t\t\tvar optionspost = {\n\t\t\t\tmethod : 'POST',\n\t\t\t\theaders : postheaders,\n\t\t\t\thost: 'localhost',\n\t\t\t\tport: 8090, \n path: '/api/users/sendnotification/'\n\t\t\t};\n\t\t\t\n\t\t\t// do the POST call\n\t\t\tvar reqPost = http.request(optionspost, function(res) {\n\t\t\t res.on('data', function(d) {\n\t\t\t\t});\n\t\t\t}).end(jsonObject);\n\t\n\t}", "title": "" }, { "docid": "f7b5ad09205c7d3b735d04f201593856", "score": "0.59115887", "text": "testNetworkEvents() {\n createChannelRequest();\n\n channelRequest.xmlHttpPost(new Uri('some_uri'), 'some_postdata', true);\n checkReachabilityEvents(1, 0, 0, 0);\n if (ChannelRequest.supportsXhrStreaming()) {\n xhrIo.simulatePartialResponse('17\\nI am a BC Message');\n checkReachabilityEvents(1, 0, 0, 1);\n xhrIo.simulatePartialResponse('23\\nI am another BC Message');\n checkReachabilityEvents(1, 0, 0, 2);\n xhrIo.simulateResponse(200, '16Final BC Message');\n checkReachabilityEvents(1, 1, 0, 2);\n } else {\n xhrIo.simulateResponse(200, '16Final BC Message');\n checkReachabilityEvents(1, 1, 0, 0);\n }\n }", "title": "" }, { "docid": "da6370770f533e8601c73d476c42e191", "score": "0.5910287", "text": "function dispatchEvent(eventType, data) {}", "title": "" }, { "docid": "a56f054a00a29b08a3ca9dd43b5f4b04", "score": "0.5897796", "text": "function sendEvent(action, xcoor, ycoor)\n\t\t{\n\t\t\t//If its your turn and you are not waiting on a server response already.\n\t\t\tif(! events_locked )\n\t\t\t{\n\t\t\t\t//Then prevent new events until server response (confirmation) and...\n\t\t\t\tevents_locked = true;\n\t\t\t\ttry\n\t\t\t\t{\n\t\t\t\t\t//Send event to server with the parameters.\n\t\t\t\t\tvar client_event = \n\t\t\t\t\t{\n\t\t\t\t\t\t\"type\":\"Event\",\n\t\t\t\t\t\t\"action\":action,\n\t\t\t\t\t\t\"xcoor\":xcoor,\n\t\t\t\t\t\t\"ycoor\":ycoor,\n\t\t\t\t\t\t\"who\":this_player_name,\n\t\t\t\t\t\t\"dragged_num\":inventory_dragged_unit\n\t\t\t\t\t};\n\t\t\t\t\tsocket.emit('Event_received', JSON.stringify(client_event));\n\t\t\t\t}\n\t\t\t\tcatch(err)\n\t\t\t\t{\n\t\t\t\t\talert(err);\n\t\t\t\t\tevents_locked = false;\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "87fd6e85313055a9b81ed6f547a7e250", "score": "0.58875203", "text": "function request(payload) {\n s.emit(\"req\", payload);\n}", "title": "" }, { "docid": "d84ed79b977e042073915e7830cc94ba", "score": "0.58870536", "text": "__http() {\n let queryString = this.__getQueryString(this.data);\n\n let request = this.__getRequest();\n\n if (this.__isValidRequestObject(request)) {\n\n this.__setupRequest(request);\n\n request.send(queryString);\n }\n }", "title": "" }, { "docid": "5f4bbd6ad8698620285a75b185875ab2", "score": "0.5885377", "text": "function ajaxEventTrigger(event) {\n var ajaxEvent = new CustomEvent(event, { detail: this });\n// console.log(\"call event!\" + event);\n // times++;\n window.dispatchEvent(ajaxEvent);\n }", "title": "" }, { "docid": "92f83bd99f123f7870c8c2fedb274c2a", "score": "0.58784777", "text": "function _xhrRequest(){\n\t\t\tconsole.log('[ network_module.js ] : ' + 'creating XHR request ..');\n\t\t}", "title": "" }, { "docid": "a4cadcd711d8b6ecfc5bf11b1abb7194", "score": "0.5873624", "text": "function etSend() {\n var xhr = new window.XMLHttpRequest(), cbs = etSendCallbacks;\n xhr.withCredentials = true; // make sure to include agent-id cookie\n xhr.open(\"POST\", etUrl);\n xhr.onreadystatechange = function () {\n var err, cb;\n if (xhr.readyState == 4) {\n if (xhr.status == 200) {\n err = null;\n } else {\n err = new Error(xhr.statusText);\n }\n while (cb = cbs.shift()) {\n cb(err);\n }\n }\n }\n xhr.send(etSendData);\n etSendData = \"\";\n etSendCallbacks = [];\n etSendThrottle = null;\n }", "title": "" }, { "docid": "a7b9de6b3cb75c18c45acb3a147c5341", "score": "0.58568245", "text": "pushEvent(evt) {\n this.ws.send(JSON.stringify(evt));\n }", "title": "" }, { "docid": "f962aec581f79fb5cb366869c89b92bf", "score": "0.585255", "text": "function requestHandler(request, response) {\n response.send(200,\"Agent responding to web request\");\n agentlog(true,\"Request came from web\");\n}", "title": "" }, { "docid": "aec1707be4b9b63369b6f5aa6fa10030", "score": "0.58333236", "text": "function onJoystickData(event) {\n\n\tvar message = new Buffer(JSON.stringify(event));\n\n\tclient.send(message, 0, message.length, 5000, \"localhost\", function(err) {\n\t\tif (err) {\n\t\t\tconsole.log(\"Problem with sending data!!!\");\n\t\t}\n\t\telse {\n\t\t\tconsole.log(\"Sent the data!!!\")\n\t\t}\n\t\t//client.close();\n\t});\n}", "title": "" }, { "docid": "34756031e69ba3242537a4d59359869e", "score": "0.5825141", "text": "static makeRequest(event, callback){\n //This should contain data on the request\n const request = new AlexaRequest(event);\n // this.emit(\":tell\", \"PERFORM_ACTION was called\");\n request.post('/otto-request', response => {\n let gm_response = '';\n response.on('data', (chunk) => gm_response += chunk);\n response.on('end', () => {\n const alexa_response = new AlexaResponse(request, gm_response);\n callback(alexa_response.getResponse());\n });\n\n });\n }", "title": "" }, { "docid": "f2443d3a3166fdf4737cffec18060ea7", "score": "0.58211696", "text": "function onRequest(request, response){\n console.log('A user made a request' + request.url);\n response.writeHead(200, {\"Context-Type\":\"text/plain\"});\n response.write(\"Here is the response data\");\n response.end();\n}", "title": "" }, { "docid": "a983efc01c4224648ee53ce0cc60b776", "score": "0.58171684", "text": "run(e) {\n var request = new XMLHttpRequest();\n var thiz = this;\n request.responseType = \"json\";\n request.onreadystatechange = function () {\n if (request.readyState == 4 && request.status == 200) {\n //if (request.response) display(ctx, request.response);\n //console.log(request.response);\n console.log(thiz);\n var to_server = thiz.do_frame(request)\n\n var str = JSON.stringify(to_server);\n request.open(\"PUT\", \"/data\", true);\n request.send(str);\n }\n }\n\n var to_server = thiz.do_frame(request)\n\n var str = JSON.stringify(to_server);\n request.open(\"PUT\", \"/data\", true);\n request.send(str);\n }", "title": "" }, { "docid": "e99a7ea501f4b7f4cb23cfaa87ea5b42", "score": "0.5806214", "text": "function onRequest(request, response) {\n\t\tvar postData = \"\";\n\t\tvar pathname = url.parse(request.url).pathname;\n\t\tconsole.log(\"Request for \" + pathname + \" received\");\n\t\t\n\t\trequest.setEncoding(\"utf8\");\n\t\t\n\t\t// Data listener\n\t\trequest.addListener(\"data\", function(postDataChunk) {\n\t\t\tpostData += postDataChunk;\n\t\t\tconsole.log(\"Received POST data chunk '\" + postDataChunk + \"'.\");\n\t\t});\n\n\t\t// End listener\n\t\trequest.addListener(\"end\", function() {\n\t\t\tvar authToken = request.headers[\"authorization\"];\n\t\t\tif (request.method == \"GET\") {\n\t\t\t\troute(handle, pathname, response, request);\n\t\t\t} else {\n\t\t\t\troute(handle, pathname, response, postData, authToken);\n\t\t\t}\n\t\t});\n\t}", "title": "" }, { "docid": "72d6ccf88d7b83bb421af8f6d36a49b4", "score": "0.5800838", "text": "function sendData(event, data) {\n socket.emit(event, data);\n}", "title": "" }, { "docid": "0be48b1db8c608f9187794531afddc4a", "score": "0.5790602", "text": "_send() {\n clearTimeout(this._conn._idleTimeout);\n\n this._throttledRequestHandler();\n\n this._conn._idleTimeout = setTimeout(() => this._conn._onIdle(), 100);\n }", "title": "" }, { "docid": "0be48b1db8c608f9187794531afddc4a", "score": "0.5790602", "text": "_send() {\n clearTimeout(this._conn._idleTimeout);\n\n this._throttledRequestHandler();\n\n this._conn._idleTimeout = setTimeout(() => this._conn._onIdle(), 100);\n }", "title": "" }, { "docid": "9f20f8e40627e3923e9671dc8c108983", "score": "0.5772494", "text": "function sendRequest(_query, _callback) {\n let xhr = new XMLHttpRequest();\n xhr.open(\"GET\", serverAddress + \"?\" + _query, true);\n xhr.addEventListener(\"readystatechange\", _callback);\n xhr.send();\n }", "title": "" }, { "docid": "ba3a526dd359a036ba020be21f73edaf", "score": "0.57692206", "text": "enviaEvento(evento, ok, err) {\n let xhttp = new XMLHttpRequest();\n xhttp.onreadystatechange = function () {\n if (xhttp.readyState === 4) {\n if (xhttp.status === 201) {\n ok();\n } else {\n const msg = xhttp.statusText;\n err(msg);\n }\n }\n };\n xhttp.open(\"POST\", EventoHttpService.URI, true);\n xhttp.setRequestHeader(\"content-type\", \"application/json\");\n xhttp.send(JSON.stringify(evento));\n }", "title": "" }, { "docid": "d6db2e882bbcb12dcd619b15d338d558", "score": "0.57680076", "text": "function WbBackGround_request(elm)\n {\n logDebug(\"WbBackGround_request: \", elm.source) ;\n if ( elm.source )\n {\n var def = doTimedXMLHttpRequest(elm.source, pollerTimeout);\n def.addBoth(WbBackGround_receive, elm) ;\n }\n else\n {\n logError(\"WbBackGround_request (no source)\") ;\n }\n return;\n }", "title": "" }, { "docid": "ac98faa81288244f5c06dca89ee7afd0", "score": "0.57651013", "text": "function sendResponse(event, context, responseStatus, responseData) {\n\n var responseBody = JSON.stringify({\n Status: responseStatus,\n Reason: \"See the details in CloudWatch Log Stream: \" + context.logStreamName,\n PhysicalResourceId: context.logStreamName,\n StackId: event.StackId,\n RequestId: event.RequestId,\n LogicalResourceId: event.LogicalResourceId,\n Data: responseData\n });\n\n console.log(\"RESPONSE BODY:\\n\", responseBody);\n\n var https = require(\"https\");\n var url = require(\"url\");\n\n var parsedUrl = url.parse(event.ResponseURL);\n var options = {\n hostname: parsedUrl.hostname,\n port: 443,\n path: parsedUrl.path,\n method: \"PUT\",\n headers: {\n \"content-type\": \"\",\n \"content-length\": responseBody.length\n }\n };\n\n console.log(\"SENDING RESPONSE...\\n\");\n\n var request = https.request(options, function(response) {\n console.log(\"STATUS: \" + response.statusCode);\n console.log(\"HEADERS: \" + JSON.stringify(response.headers));\n // Tell AWS Lambda that the function execution is done\n context.done();\n });\n\n request.on(\"error\", function(error) {\n console.log(\"sendResponse Error:\" + error);\n // Tell AWS Lambda that the function execution is done\n context.done();\n });\n\n // write data to request body\n request.write(responseBody);\n request.end();\n}", "title": "" }, { "docid": "b8afa99766aa8f01e44025d15360fb67", "score": "0.5758174", "text": "function sendStart()\n{\n requestStart();\n}", "title": "" }, { "docid": "7602b634531c7b583757652852432d43", "score": "0.5752734", "text": "function sendEvent(action) {\n var statsUrl = \"http://fvdspeeddial.com/a/?a=\"\n + encodeURIComponent(action) + \"&from=chrome_addon\";\n fvdSpeedDial.Utils.getUrlContent(statsUrl, function() {\n });\n }", "title": "" }, { "docid": "a310d600b13c7b9a116597f39aa76a86", "score": "0.5751154", "text": "async function sendRequestToEndCall(self) {\n const reqData = {\n roomName: self.state.roomName\n };\n await axios.post(\n `${global.config.backendURL}/api/room/exitstreamsimple`,\n reqData,\n {\n headers: {\n 'milaap-auth-token': localStorage.getItem('milaap-auth-token')\n }\n }\n );\n}", "title": "" }, { "docid": "d8c8b6dfb08c05f1ca316d5f9d4218c9", "score": "0.57395643", "text": "function dispatchRequestEvent(targetElem, request) {\n\tvar re = new CustomEvent('request', { bubbles:true, cancelable:true, detail:request });\n\ttargetElem.dispatchEvent(re);\n}", "title": "" }, { "docid": "baa660dd246174f7a539ab058fc307f8", "score": "0.5736423", "text": "function HttpProgressEvent(){}", "title": "" }, { "docid": "84a76cab9821f874b915e3515196fdf0", "score": "0.57342535", "text": "function sendResponse(event, context, responseStatus, responseData) {\n \n var responseBody = JSON.stringify({\n Status: responseStatus,\n Reason: \"See the details in CloudWatch Log Stream: \" + context.logStreamName,\n PhysicalResourceId: context.logStreamName,\n StackId: event.StackId,\n RequestId: event.RequestId,\n LogicalResourceId: event.LogicalResourceId,\n Data: responseData\n });\n \n console.log(\"RESPONSE BODY:\\n\", responseBody);\n \n var https = require(\"https\");\n var url = require(\"url\");\n \n var parsedUrl = url.parse(event.ResponseURL);\n var options = {\n hostname: parsedUrl.hostname,\n port: 443,\n path: parsedUrl.path,\n method: \"PUT\",\n headers: {\n \"content-type\": \"\",\n \"content-length\": responseBody.length\n }\n };\n \n console.log(\"SENDING RESPONSE...\\n\");\n \n var request = https.request(options, function(response) {\n console.log(\"STATUS: \" + response.statusCode);\n console.log(\"HEADERS: \" + JSON.stringify(response.headers));\n // Tell AWS Lambda that the function execution is done \n context.done();\n });\n \n request.on(\"error\", function(error) {\n console.log(\"sendResponse Error:\" + error);\n // Tell AWS Lambda that the function execution is done \n context.done();\n });\n \n // write data to request body\n request.write(responseBody);\n request.end();\n}", "title": "" }, { "docid": "84a76cab9821f874b915e3515196fdf0", "score": "0.57342535", "text": "function sendResponse(event, context, responseStatus, responseData) {\n \n var responseBody = JSON.stringify({\n Status: responseStatus,\n Reason: \"See the details in CloudWatch Log Stream: \" + context.logStreamName,\n PhysicalResourceId: context.logStreamName,\n StackId: event.StackId,\n RequestId: event.RequestId,\n LogicalResourceId: event.LogicalResourceId,\n Data: responseData\n });\n \n console.log(\"RESPONSE BODY:\\n\", responseBody);\n \n var https = require(\"https\");\n var url = require(\"url\");\n \n var parsedUrl = url.parse(event.ResponseURL);\n var options = {\n hostname: parsedUrl.hostname,\n port: 443,\n path: parsedUrl.path,\n method: \"PUT\",\n headers: {\n \"content-type\": \"\",\n \"content-length\": responseBody.length\n }\n };\n \n console.log(\"SENDING RESPONSE...\\n\");\n \n var request = https.request(options, function(response) {\n console.log(\"STATUS: \" + response.statusCode);\n console.log(\"HEADERS: \" + JSON.stringify(response.headers));\n // Tell AWS Lambda that the function execution is done \n context.done();\n });\n \n request.on(\"error\", function(error) {\n console.log(\"sendResponse Error:\" + error);\n // Tell AWS Lambda that the function execution is done \n context.done();\n });\n \n // write data to request body\n request.write(responseBody);\n request.end();\n}", "title": "" }, { "docid": "84a76cab9821f874b915e3515196fdf0", "score": "0.57342535", "text": "function sendResponse(event, context, responseStatus, responseData) {\n \n var responseBody = JSON.stringify({\n Status: responseStatus,\n Reason: \"See the details in CloudWatch Log Stream: \" + context.logStreamName,\n PhysicalResourceId: context.logStreamName,\n StackId: event.StackId,\n RequestId: event.RequestId,\n LogicalResourceId: event.LogicalResourceId,\n Data: responseData\n });\n \n console.log(\"RESPONSE BODY:\\n\", responseBody);\n \n var https = require(\"https\");\n var url = require(\"url\");\n \n var parsedUrl = url.parse(event.ResponseURL);\n var options = {\n hostname: parsedUrl.hostname,\n port: 443,\n path: parsedUrl.path,\n method: \"PUT\",\n headers: {\n \"content-type\": \"\",\n \"content-length\": responseBody.length\n }\n };\n \n console.log(\"SENDING RESPONSE...\\n\");\n \n var request = https.request(options, function(response) {\n console.log(\"STATUS: \" + response.statusCode);\n console.log(\"HEADERS: \" + JSON.stringify(response.headers));\n // Tell AWS Lambda that the function execution is done \n context.done();\n });\n \n request.on(\"error\", function(error) {\n console.log(\"sendResponse Error:\" + error);\n // Tell AWS Lambda that the function execution is done \n context.done();\n });\n \n // write data to request body\n request.write(responseBody);\n request.end();\n}", "title": "" }, { "docid": "e14ded021bcbeeacef6adfd6dd8935ac", "score": "0.5729565", "text": "send(pred, args, onSuccess, onError, asyncr = true, timeout = 3000, onTimeout) {\n let request = new XMLHttpRequest();\n request.open(\n \"GET\",\n \"http://localhost:\" + this.port + \"/\" + pred + \"-\" + args,\n asyncr\n );\n\n request.onload =\n onSuccess ||\n function (data) {\n // console.log(\"Request successful. Reply: \", JSON.parse(data.target.response));\n request.result = JSON.parse(data.target.response);\n };\n\n request.onerror =\n onError ||\n function () {\n console.log(\"Error waiting for response\");\n };\n\n if (asyncr)\n request.timeout = timeout;\n\n request.ontimeout =\n onTimeout ||\n function () {\n console.log(\"Timeout for response. Sending again\");\n request.send();\n };\n\n request.setRequestHeader(\n \"Content-Type\",\n \"application/x-www-form-urlencoded; charset=UTF-8\"\n );\n\n request.send();\n this.request = request;\n\n return request;\n }", "title": "" }, { "docid": "e8f5a8368cc4f5b656d415fa6efb4e6b", "score": "0.5729305", "text": "request(req, event, context) {\n req.event = event;\n req.context = context;\n }", "title": "" }, { "docid": "37914ce36c7977da53269f7770fbbfd3", "score": "0.57288337", "text": "function onRequest(request, response) {\n\n console.log(\"Received request\\n\");\n\n var postData = '';\n\n request.setEncoding(\"utf8\"); // post data encoding is now UTF8\n\n request.addListener(\"data\", function(postDataChunk) { // listens for the data\n postData += postDataChunk; // when a new chunk ('part') of the sent data arrives it's appended to \"postData\"\n console.log(\"Received POST data chunk:\\n'\" + postDataChunk + \"'\\n\");\n });\n\n request.addListener(\"end\", function() { // when the whole data has arrived:\n var name, message, time;\n name = querystring.parse(postData).name, // name is now the content of name (from the sent string)\n message = querystring.parse(postData).message,\n time = querystring.parse(postData).time;\n console.log(\"Received POST data:\\nname='\" + name + \"'\\nmessage='\" + message + \"'\\ntime='\" + time + \"'\\n\");\n write(name, message, time);\n });\n\n}", "title": "" }, { "docid": "37cb99afaa7d8d85d824c88f86a728e8", "score": "0.57118094", "text": "send(eventName, ...eventData) {\n if (!this._processor.sendEvent) {\n throw new ExternalZenatonError(\n `Sorry, you can not use \"send\" syntax from here`,\n );\n }\n\n return this._processor.sendEvent(this._getQuery(), eventName, eventData);\n }", "title": "" }, { "docid": "71ad664bc43e5cb8be39bcb88bb034bf", "score": "0.5709045", "text": "function robot_data_send() {\n\t\tvar xmlhttp = new XMLHttpRequest();\n\t\txmlhttp.onreadystatechange = function() {\n\t\t\tif (this.readyState == 4 && this.status == 200) {\n\t\t\t}\n\t\t};\n\n\t\tif (b0_1000 != b0_1000_last_frame) {\n\t\t\txmlhttp.open(\"GET\", \"bosch2.html/query?b0_1000=\" + b0_1000, true);\n\t\t\txmlhttp.send();\n\t\t};\n\n\t\t// Data sending to robot server\n\t}", "title": "" }, { "docid": "192d05d18045c4f5275978b4ee76635e", "score": "0.570535", "text": "fetchEvents() {\n const subscribeURL = \"/app/getEvents\";\n console.log();\n this.stompClient.send(subscribeURL, \"Fetch Events\", {});\n }", "title": "" }, { "docid": "32b3bf76980e062ce368746ee42bd083", "score": "0.57015485", "text": "function onRequest(request, response) \n\t{\n\t\thttpRoute(request, response);\n\t}", "title": "" }, { "docid": "48422fb57eb5a0aedc9fa26065959c2f", "score": "0.56998134", "text": "function sendEvents(parsedEvents) {\n\n // get all the events, stringify them and join them\n // with the new line character which can be sent\n var allevents = parsedEvents.map(JSON.stringify).join('\\n');\n\n // create connection to send logs\n try {\n\n var nc = net.createConnection(cfg.host, cfg.port);\n //console.log('Socket created.');\n //s.on('data', function(data) {\n // Log the response from the HTTP server.\n // console.log('RESPONSE: ' + data);\n //})\n nc.on('end', function() {\n //console.log('client closed');\n //context.succeed('all events are sent');\n context.done();\n });\n nc.on('error', function (e) {\n console.log('problem with request: ' + e.toString());\n context.fail(e);\n });\n nc.on('connect', function() {\n // write data to socket\n nc.write(allevents);\n nc.end();\n });\n\n } catch (ex) {\n console.log(ex.message);\n context.fail(ex.message);\n }\n }", "title": "" }, { "docid": "d0674c83506cec3549aa255f8f523dbb", "score": "0.56900793", "text": "function emit(eventName) {\n\n\t\t// Calculate the data\n\t\tvar data = JSON.stringify([].slice.apply(arguments).slice(1));\n\n\t\t// Notify backend\n\t\tvar message = {\n\t\t\ttype: 'event',\n\t\t\tpayload: {\n\t\t\t\tname: eventName,\n\t\t\t\tdata: data,\n\t\t\t}\n\t\t};\n\t\texternal.invoke(JSON.stringify(message));\n\t}", "title": "" }, { "docid": "86a03b50a0adf73b8b11772fa4e459b3", "score": "0.56884813", "text": "function doPost(req) {\n\tvar reqJson = JSON.parse(req); // parse request string to json object\n\tvar eventId = reqJson.eventId; // get eventId from json object\n\tvar params = reqJson.params; // get params from json object\n\tvar lang = reqJson.lang; // get lang from json object\n\tvar service = null;\n\tvar semaphore = null;// the semmaphore to control event maxrequests\n\tvar semaphoreNeedRelease=false;// the flag about semmaphore release\n\tvar currentAuthBean=Packages.efw.efwCorsFilter.getCurrentAuthBean();\n\t\n\t//イベント維持の呼び出しならからを戻す\n\tif (eventId==\"efw_keepConnectionAlive\") return JSON.stringify(new Result());\n\n\t//イベント取得できない場合、エラーを画面に出す。該当エラーはよく発生する。\n\tvar ev=event._get(eventId);\n\t//if event is not loaded or it is in debug mode\n\tif (ev==null||(ev.from==\"file\" && _isdebug)){\n\t\tev=event._load(eventId);\n\t}\n\tif (ev==null){\n\t\tvar result=(new Result())\n\t\t.error(\"RuntimeErrorException\", {\"eventId\":eventId,\"message\":\"\"+messages.get(\"EventIsNotExistsMessage\",lang)});\n\t\tvar systemErrorUrl=\"\"+currentAuthBean.systemErrorUrl;\n\t\tif (systemErrorUrl!=\"\"){\n\t\t\tresult.navigate(systemErrorUrl);\n\t\t}\n\t\treturn messages.translate(JSON.stringify(result),lang);\n\t}else{\n\t\tservice=ev.service;\n\t\tsemaphore=ev.semaphore;\n\t}\n\n\ttry{\n\t\tif (params == null) {\n\t\t\treturn messages.translate(JSON.stringify(JSON.clone(ev.paramsFormat,true)),lang);\n\t\t} else {\n\t\t\t//login check\n\t\t\tvar ret = efw.server.checkLogin(eventId, lang);\n\t\t\tif (ret==null){\n\t\t\t\t// auth check\n\t\t\t\tret = efw.server.checkAuth(eventId, lang);\n\t\t\t\tif (ret == null){\n\t\t\t\t\tret = efw.server.checkStyle(ev, params, lang);\n\t\t\t\t\tif (ret == null){\n\t\t\t\t\t\tif (semaphore==null){\n\t\t\t\t\t\t\tPackages.efw.framework.accessLog(session.get(currentAuthBean.loginKey),req);//操作履歴のため。\n\t\t\t\t\t\t\tret = efw.server.fire(ev, params);\n\t\t\t\t\t\t}else if(semaphore.tryAcquire()){\n\t\t\t\t\t\t\tsemaphoreNeedRelease=true;\n\t\t\t\t\t\t\tPackages.efw.framework.accessLog(session.get(currentAuthBean.loginKey),req);//操作履歴のため。\n\t\t\t\t\t\t\tret = efw.server.fire(ev, params);\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\tret=(new Result()).error(\"EventIsBusyException\",service);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t} \n\t\t\t}\n\t\t\t// if it is null, return blank array to client as a success\n\t\t\tif (ret == null) ret=new Result();\n\t\t\t\n\t\t\tvar arylst=Packages.efw.framework.getThreadLogs();\n\t\t\tret.threadLogs=[];\n\t\t\tif(arylst!=null){\n\t\t\t\tfor(var i=0;i<arylst.size();i++){\n\t\t\t\t\tret.threadLogs.push(arylst.get(i));\n\t\t\t\t}\n\t\t\t}\n\t\t\t// change data to string and return it to client\n\t\t\treturn messages.translate(JSON.stringify(ret),lang);\n\t\t}\n\t}catch(e){\n\t\tPackages.efw.framework.runtimeSLog(e);\n\t\tvar errorMsg=\"\"+Packages.efw.framework.getUsefulInfoFromException(e);\n\t\terrorMsg=errorMsg.replace(/</g,\"&lt;\").replace(/>/g,\"&gt;\");//to encode the error message for showing in alert dialog.\n\t\tvar result=(new Result())\n\t\t.error(\"RuntimeErrorException\", {\"eventId\":eventId,\"message\":errorMsg});\n\t\tvar systemErrorUrl=\"\"+currentAuthBean.systemErrorUrl;\n\t\tif (systemErrorUrl!=\"\"){\n\t\t\tresult.navigate(systemErrorUrl);\n\t\t}\n\t\tvar arylst=Packages.efw.framework.getThreadLogs();\n\t\tresult.threadLogs=[];\n\t\tif(arylst!=null){\n\t\t\tfor(var i=0;i<arylst.size();i++){\n\t\t\t\tresult.threadLogs.push(arylst.get(i));\n\t\t\t}\n\t\t}\n\t\treturn messages.translate(JSON.stringify(result),lang);\n\t}finally{\n\t\tif(semaphoreNeedRelease){\n\t\t\tsemaphore.release();\n\t\t}\n\t\t//remove all uploaded files when event over\n\t\tPackages.efw.file.FileManager.removeUploadFiles();\n\t\t// to find javascript global pollution when debug mode and second calling.\n\t\tif (_isdebug && params!=null){\n\t\t\tvar g = new Function('return this')();\n\t\t\tfor(var i in g){\n\t\t\t\tif ( efw.contains(i)\n\t\t\t\t\t||typeof g[i]==\"function\"//common function\n\t\t\t\t\t||(g[i]!=null&&g[i].fire!=null)//event js\n\t\t\t\t\t||(g[i]!=null&&(g[i].PUT!=null||g[i].GET!=null||g[i].POST!=null||g[i].DELETE!=null))//restAPI js\n\t\t\t\t){\n\t\t\t\t\t//default global object is ok\n\t\t\t\t}else{\n\t\t\t\t\t// you should do something if the comment is printed out.\n\t\t\t\t\tPackages.efw.framework.runtimeWLog(\"[\" + i + \"] is a variable without var keyword.It is Not Recommended.\");\n\t\t\t\t}\n\t\t\t}\t\t\t\t\n\t\t}\n\t}\n}", "title": "" }, { "docid": "514ffc00f577e30c18371d62d76e40dc", "score": "0.5680835", "text": "function submitEvent(data) {\n\t console.log(data);\n\t $.post(\"/api/event\", data, function() {\n\t window.location.href = \"/home\";\n\t });\n \t}", "title": "" }, { "docid": "2a8bbc1359cea6d400f4ee75f265e97f", "score": "0.5679091", "text": "sendAsHTTP(deviceId, state) {\n const options = {\n method: 'POST',\n url: IOT_AGENT_URL,\n qs: { k: getAPIKey(deviceId), i: deviceId },\n headers: this.headers,\n body: ultralightToJSON(state)\n };\n const debugText =\n 'POST ' + IOT_AGENT_URL + '?i=' + options.qs.i + '&k=' + options.qs.k;\n\n request(options, error => {\n if (error) {\n debug(debugText + ' ' + error.code);\n }\n });\n SOCKET_IO.emit('http', debugText + ' ' + ultralightToJSON(state));\n }", "title": "" }, { "docid": "d0a17ef81461d2aaab05e4dd2364dab5", "score": "0.5678745", "text": "post(newEventObject) {\n return fetch(`${remoteURL}/events`, {\n method: \"POST\",\n headers: {\n \"Content-Type\": \"application/json\"\n },\n body: JSON.stringify(newEventObject)\n }).then(data => data.json())\n }", "title": "" }, { "docid": "98fb5502e51e99de1e9253b07f90a207", "score": "0.5677057", "text": "function kn_lwws_Client__Request_onSuccess(anEvent)\n{\n // invoke the user status handler\n kn_doStatus(anEvent, this._statusHandler);\n}", "title": "" }, { "docid": "9bbcb2e2d84e6a4c8ac0f4b4756f0752", "score": "0.56731397", "text": "execute() {\n let xhr = new XMLHttpRequest();\n xhr.open(this.methodType, this.requestURL, this.async);\n xhr.setRequestHeader(\"content-type\", \"application/json\");\n xhr.onreadystatechange = () => {\n if (xhr.readyState === XMLHttpRequest.DONE) {\n let status = xhr.status;\n if (status >= 200 && status < 400) {\n this.successCallback(this.#parseJSON(xhr.responseText));\n } else {\n this.errorCallback(this.#parseJSON(xhr.responseText));\n }\n }\n };\n xhr.send(this.requestBody);\n }", "title": "" }, { "docid": "a8935be1a4954637e993458175bd2832", "score": "0.56588393", "text": "function sendRequest(callURL){\n\trequest.open('GET', callURL, true);\n\trequest.onload = callbackWeather;\n\trequest.send();\n}", "title": "" }, { "docid": "f39332533402c10c08519b9f75f9bbb8", "score": "0.5656668", "text": "function sendRequest(cmd, url)\n\t{\n\t\tvar target = \"https://\" + window.location.hostname + \"/actionctl\"; \n\t\t\n\t\tvar data = \"command=\" + encodeURIComponent(cmd) + \"&url=\" + encodeURIComponent(url) + \n\t\t \"&csrf=\" + getCSRFToken();\n\t\t\n\t\tvar req = new XMLHttpRequest();\n\t\treq.onreadystatechange = handleResponse(req, cmd, url);\n\t\t\n\t\treq.open(\"POST\", target);\n\t\treq.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded;charset=UTF-8');\n\t\treq.send(data);\n\t\t\n\t}", "title": "" }, { "docid": "cab81c31d8bfe43cdd24d50a6abea8b9", "score": "0.56550646", "text": "listen(){\n this.bizNetworkConnection.on('event',(evt)=>{\n console.log(chalk.blue.bold('New Event'));\n console.log(evt);\n\n let options = {\n properties: { key:'value'}\n };\n // let text = evt.title['$identifier'];\n // console.log('Sending ' +text);\n // this.sendClient.send('digitalproperty-network/sale', text, options,function (err, topic,data,options) {\n // console.log('Topic: %s', topic);\n // console.log('Data: %s', data);\n // \t\t console.log('Options: %s', JSON.stringify(options));\n // console.log(err);\n //\n // });\n\n });\n }", "title": "" }, { "docid": "ca5bc45ed6852aeb92f21f22eff4a80c", "score": "0.5618264", "text": "_requestHandler() {\n console.debug(\"Game Client is going to send a message to the server, the clock tick'd!\");\n if(this._wsRequests.length > 0) {\n console.debug(\"Game Client's request queue is not empty.\");\n let msg = this._wsRequests.shift();\n console.debug(\"Game Client is going to actually send the message \" + msg);\n this._ws.send(msg + \"\\n\");\n console.debug(\"Game Client actually sent \" + msg);\n }\n // Repeat endlessly\n let timeframe = model.connectionTimeframe;\n console.debug(\"Game Client is going to set the timer to fire again in \" + timeframe + \"ms.\");\n window.setTimeout(function(){ this._requestHandler() }.bind(this), timeframe);\n console.debug(\"Game Client has set the timer for its queue.\");\n }", "title": "" }, { "docid": "25e6433dc7b3bef031e650913276de0b", "score": "0.56178856", "text": "function logger_api_call(sessionId, event)\n{\n let event_type = event[\"type\"];\n \n let event_details = {};\n event_details[\"app_details\"] = sessions.getAppSession(sessionId);\n event_details[\"event\"] = event;\n\n logger.info(event_details);\n\n let options = {\n method: 'POST',\n url: 'https://www.prodx.in/update_events/app_'+event_type,\n headers: \n {\n 'content-type': 'application/json'\n },\n body: event_details,\n json: true\n };\n request(options, function (error, response, body) {\n if (error)\n {\n console.log(\"\\n\\nError in events updating ===============\");\n console.log(error);\n }\n //console.log(response.body);\n });\n}", "title": "" }, { "docid": "ffadd08f661cfb2f621c5ae478e22ab5", "score": "0.5612762", "text": "function ajaxSendAction(id, type)\r\n{\r\n\t// type: hello, remove_event, accept/reject friend\r\n\t// id can be uid, evId, or showingId\r\n\tif (window.XMLHttpRequest) {\r\n\t\treqSendAct = new XMLHttpRequest();\r\n\t} else if (window.ActiveXObject) {\r\n\t\treqSendAct = new ActiveXObject(\"Microsoft.XMLHTTP\");\r\n\t}\r\n\tif (bDisplaySearch && bGroupAction) id = 999;\r\n\r\n\tvar url = \"../servlet/OmfEventAjax\";\r\n\treqSendAct.open(\"POST\", url, true);\r\n\treqSendAct.setRequestHeader(\"Content-Type\", \"application/x-www-form-urlencoded\");\r\n\treqSendAct.send(\"uid=\" + id + \"&type=\" + type);\r\n}", "title": "" }, { "docid": "125d26ec1c3b8faf53d95b52bfec4396", "score": "0.5609151", "text": "function sendEvent(type, data) {\n log('rtc-event', type, data);\n socket.emit('rtc-event', {type, data})\n}", "title": "" }, { "docid": "6ceec118f5ba43981906d51f3ff4a1df", "score": "0.5607209", "text": "function send_rfid_event(tag) {\n\n client.sendEvent('RFID_RECEIVED' , {tag: tag});\n console.log(\"RFID RECEIVED : \" + tag);\n}", "title": "" }, { "docid": "c2a62148b2b5c2ed75c31b647d6ad443", "score": "0.560556", "text": "function WbEnableEntry_request(elm)\r\n {\r\n logDebug(\"WbEnableEntry_request: \", elm.request, \", \", elm.source) ;\r\n if ( elm.source )\r\n {\r\n var def = doTimedXMLHttpRequest(elm.source, pollerTimeout) ;\r\n def.addBoth(WbEnableEntry_receive, elm) ;\r\n }\r\n else\r\n {\r\n logError(\"WbEnableEntry_request (no source)\") ;\r\n }\r\n return ;\r\n }", "title": "" }, { "docid": "2dfd16b286e76a2b155b70a4118d29fe", "score": "0.5605099", "text": "send(request) {\n return __awaiter(this, void 0, void 0, function* () {\n return this._protocolAdapter.sendRequest(request);\n });\n }", "title": "" }, { "docid": "701f6bf7d43c52b7108d8ad881d1c609", "score": "0.56021017", "text": "function onRequest(request, response) {\n\tO.t(\"HTTPVersion: '\" + request.httpVersion + \"'\");\n\tvar requestUrl = request.url;\n\tO.d(\"Responding to '\" + requestUrl + \"'\");\n\tO.d(\" pathname '\" + url.parse(requestUrl).pathname + \"'\");\n\tO.d(\" query '\" + url.parse(requestUrl).query + \"'\");\n\n\tif (requestUrl.startsWith('/Diffusion')) {\n\t\tO.d('Found Diffusion request: ' + requestUrl);\n\t\tdiffusionRequest(request, response);\n\t} else if (requestUrl.startsWith('/var')) {\n\t\tO.d('Found variation request: ' + requestUrl);\n\t\tvariationRequest(request, response);\n\t} else {\n\t\tO.d('Simple file based request: ' + requestUrl);\n\t\tsimpleFileBasedWebServer(request, response);\n\t}\n}", "title": "" }, { "docid": "e0003eee73ff435874d7000d3b5794e0", "score": "0.55946904", "text": "async function updateEvent(data){\n\n}", "title": "" }, { "docid": "f83ed7c91dd2b3ad2419778160d47a73", "score": "0.558802", "text": "sendData() {\n debug('Http2Session::sendData');\n if (this._handle)\n checkSuccessOrEmitError(this, this._handle.sendData());\n }", "title": "" }, { "docid": "d7f3b66c70d274ee07f0fdbae8093756", "score": "0.55815774", "text": "function led_on()\n{\n\tvar params = \"__SL_P_U00\";\n\tparams = params +\"LED_ON\";//pass the turn led on message to server\n\tHTTPrequest.open(\"POST\",\"No_content\", true);\n\tHTTPrequest.setRequestHeader(\"Content-type\", \"application/x-www-form-urlencoded\");\n\tHTTPrequest.onreadystatechange = function()\n\t{\n\t\tif (HTTPrequest.readyState==4 && HTTPrequest.status==200)\n\t\t{\n\t\t}\n\t}\n\tHTTPrequest.send(params);\n}", "title": "" }, { "docid": "89799fa0c33ba8a6d488f371ffb69f3c", "score": "0.55795705", "text": "function _notify(request) {\n log.debug(\"Notification Received: \" + request.responseText);\n }", "title": "" }, { "docid": "10ac592afe930b5dd66b71b7b48e867f", "score": "0.5578599", "text": "function sendRequest() {\n if (window.XMLHttpRequest) {\n req = new XMLHttpRequest();\n } else {\n req = new ActiveXObject(\"Microsoft.XMLHTTP\");\n }\n req.onreadystatechange = handleResponse;\n req.open(\"GET\", \"/guru/get-dates\", true);\n req.send(); \n}", "title": "" }, { "docid": "07a9725d01360706fc5289519ea07f44", "score": "0.5575006", "text": "function phpSend(action) {\n http.open('get', 'index.php?action='+action);\n http.onreadystatechange = handleResponse;\n http.send(null);\n}", "title": "" }, { "docid": "c6a2260d937dc8b9228bc9089814be8d", "score": "0.55740607", "text": "function onRequest(request, response) { //request and response are two objects we use in our code.\n\n let pathname = url.parse(request.url).pathname;\n console.log(`Request for ${pathname} recieved.`);\n route(handle, pathname, response, request);\n }", "title": "" }, { "docid": "2ca66cd99d30d327e55d5a5efa28dfd5", "score": "0.5567342", "text": "function initialEventRequest () {\n var req = new XMLHttpRequest();\n req.onload = eventReqListener;\n req.open('get', 'pptq1st16.json', true);\n req.send();\n}", "title": "" } ]
438c20c0fa6e353115be2118d6f3605c
Restore persisted information about what columns to display for the folder. If we have no persisted information, we leave/set _savedColumnStates null. The column states will be set to default values in onDisplayingFolder in that case.
[ { "docid": "c43cf5e5c73d7300472a2051f3a34161", "score": "0.6395168", "text": "onLoadingFolder(aDbFolderInfo) {\n this._savedColumnStates = this._depersistColumnStatesFromDbFolderInfo(\n aDbFolderInfo\n );\n\n FolderDisplayListenerManager._fireListeners(\"onLoadingFolder\", [\n this,\n aDbFolderInfo,\n ]);\n }", "title": "" } ]
[ { "docid": "09645aa518aa10356673d0ba2673d754", "score": "0.71333706", "text": "_restoreColumnStates() {\n if (this._savedColumnStates) {\n this.setColumnStates(this._savedColumnStates);\n this._savedColumnStates = null;\n }\n }", "title": "" }, { "docid": "7f8dc4fb472d3af8545e75d0aadde861", "score": "0.64284617", "text": "_saveColumnStates() {\n // In the actual TreeColumn, the index property indicates the column\n // number. This column number is a 0-based index with no gaps; it only\n // increments the number each time it sees a column.\n // However, this is subservient to the 'ordinal' property which\n // defines the _apparent content sequence_ provided by GetNextSibling.\n // The underlying content ordering is still the same, which is how\n // _ensureColumnOrder() can reset things to their XUL definition sequence.\n // The 'ordinal' stuff works because nsBoxFrame::RelayoutChildAtOrdinal\n // messes with the sibling relationship.\n // Ordinals are 1-based. _ensureColumnOrder() apparently is dumb and does\n // not know this, although the ordering is relative so it doesn't actually\n // matter. The annoying splitters do have ordinals, and live between\n // tree columns. The splitters adjacent to a tree column do not need to\n // have any 'ordinal' relationship, although it would appear user activity\n // tends to move them around in a predictable fashion with oddness involved\n // at the edges.\n // Changes to the ordinal attribute should take immediate effect in terms of\n // sibling relationship, but will merely invalidate the columns rather than\n // cause a re-computation of column relationships every time.\n // _ensureColumnOrder() invalidates the tree when it is done re-ordering;\n // I'm not sure that's entirely necessary...\n this._savedColumnStates = this.getColumnStates();\n }", "title": "" }, { "docid": "2742f6a53cdffd2042e89d438515f7a2", "score": "0.63747156", "text": "_persistColumnStates(aState) {\n if (this.view.isSynthetic) {\n let syntheticView = this.view._syntheticView;\n if (\"setPersistedSetting\" in syntheticView) {\n syntheticView.setPersistedSetting(\"columns\", aState);\n }\n return;\n }\n\n if (!this.view.displayedFolder || !this.view.displayedFolder.msgDatabase) {\n return;\n }\n\n let msgDatabase = this.view.displayedFolder.msgDatabase;\n let dbFolderInfo = msgDatabase.dBFolderInfo;\n dbFolderInfo.setCharProperty(\n this.PERSISTED_COLUMN_PROPERTY_NAME,\n JSON.stringify(aState)\n );\n msgDatabase.Commit(Ci.nsMsgDBCommitType.kLargeCommit);\n }", "title": "" }, { "docid": "835a6ea29ce7f5b26e246d068e8d604e", "score": "0.62272674", "text": "onDisplayingFolder() {\n let displayedFolder = this.view.displayedFolder;\n let msgDatabase = displayedFolder && displayedFolder.msgDatabase;\n if (msgDatabase) {\n msgDatabase.resetHdrCacheSize(this.PERF_HEADER_CACHE_SIZE);\n }\n\n // makeActive will restore the folder state\n if (!this._savedColumnStates) {\n if (\n this.view.isSynthetic &&\n \"getPersistedSetting\" in this.view._syntheticView\n ) {\n let columns = this.view._syntheticView.getPersistedSetting(\"columns\");\n this._savedColumnStates = columns;\n } else {\n // get the default for this folder\n this._savedColumnStates = this._getDefaultColumnsForCurrentFolder();\n // and save it so it doesn't wiggle if the inbox/prototype changes\n this._persistColumnStates(this._savedColumnStates);\n }\n }\n\n FolderDisplayListenerManager._fireListeners(\"onDisplayingFolder\", [this]);\n\n if (this.active) {\n this.makeActive();\n }\n }", "title": "" }, { "docid": "48dc5006508f5caf54a9cb1414788eda", "score": "0.56613296", "text": "setColumnStates(aColumnStates, aPersistChanges) {\n // If we are not active, just overwrite our current state with the provided\n // state and bail.\n if (!this._active) {\n this._savedColumnStates = aColumnStates;\n return;\n }\n\n this._touchingColumns = true;\n\n try {\n let cols = document.getElementById(\"threadCols\");\n let colChildren = cols.children;\n\n for (let iKid = 0; iKid < colChildren.length; iKid++) {\n let colChild = colChildren[iKid];\n if (colChild == null) {\n continue;\n }\n\n // We only care about treecols. The splitters do not need to be marked\n // hidden or un-hidden.\n if (colChild.tagName == \"treecol\") {\n // if it doesn't have preserved state it should be hidden\n let shouldBeHidden = true;\n // restore state\n if (colChild.id in aColumnStates) {\n let colState = aColumnStates[colChild.id];\n if (\"visible\" in colState) {\n shouldBeHidden = !colState.visible;\n }\n if (\"ordinal\" in colState && colChild.ordinal != colState.ordinal) {\n colChild.ordinal = colState.ordinal;\n }\n }\n let isHidden = colChild.hidden;\n if (isHidden != shouldBeHidden) {\n if (shouldBeHidden) {\n colChild.setAttribute(\"hidden\", \"true\");\n } else {\n colChild.removeAttribute(\"hidden\");\n }\n }\n }\n }\n } finally {\n this._touchingColumns = false;\n }\n\n if (aPersistChanges) {\n this.hintColumnsChanged();\n }\n }", "title": "" }, { "docid": "19a629077def101225d4bb692ca70b7a", "score": "0.5625486", "text": "@action\n restoreDefaultVisibility() {\n this.processedColumns.forEach(c => {\n set(c, 'isHidden', !get(c, 'defaultVisible'));\n this._sendColumnsVisibilityChangedAction();\n });\n }", "title": "" }, { "docid": "48c5e194680234c4dc925913f8fe1b84", "score": "0.5552406", "text": "_depersistColumnStatesFromDbFolderInfo(aDbFolderInfo) {\n let columnJsonString = aDbFolderInfo.getCharProperty(\n this.PERSISTED_COLUMN_PROPERTY_NAME\n );\n if (!columnJsonString) {\n return null;\n }\n\n return JSON.parse(columnJsonString);\n }", "title": "" }, { "docid": "bc3a714238ecc2a4cf87a2cd0808ec2d", "score": "0.54101694", "text": "_getDefaultColumnsForCurrentFolder(aDoNotInherit) {\n // If the view is synthetic, try asking it for its default columns. If it\n // fails, just return nothing, since most synthetic views don't care about\n // columns anyway.\n if (this.view.isSynthetic) {\n if (\"getDefaultSetting\" in this.view._syntheticView) {\n return this.view._syntheticView.getDefaultSetting(\"columns\");\n }\n return {};\n }\n\n // do not inherit from the inbox if:\n // - It's an outgoing folder; these have a different use-case and there\n // should be a small number of these, so it's okay to have no defaults.\n // - It's a virtual folder (single or multi-folder backed). Who knows what\n // the intent of the user is in this case. This should also be bounded\n // in number and our default heuristics should be pretty good.\n // - It's a multiple folder; this is either a search view (which has no\n // displayed folder) or a virtual folder (which we eliminated above).\n // - News folders. There is no inbox so there's nothing to inherit from.\n // (Although we could try and see if they have opened any other news\n // folders in the same account. But it's not all that important to us.)\n // - It's an inbox!\n let doNotInherit =\n aDoNotInherit ||\n this.view.isOutgoingFolder ||\n this.view.isVirtual ||\n this.view.isMultiFolder ||\n this.view.isNewsFolder ||\n this.displayedFolder.getFlag(Ci.nsMsgFolderFlags.Inbox);\n\n // Try and grab the inbox for this account's settings. we may not be able\n // to, in which case we just won't inherit. (It ends up the same since the\n // inbox is obviously not customized in this case.)\n if (!doNotInherit) {\n let inboxFolder = this.displayedFolder.rootFolder.getFolderWithFlags(\n Ci.nsMsgFolderFlags.Inbox\n );\n if (inboxFolder) {\n let state = this._depersistColumnStatesFromDbFolderInfo(\n inboxFolder.msgDatabase.dBFolderInfo\n );\n // inbox message databases don't get closed as a matter of policy.\n\n if (state) {\n return state;\n }\n }\n }\n\n // if we are still here, use the defaults and helper functions\n let state = {};\n for (let colId of this.DEFAULT_COLUMNS) {\n let shouldShowColumn = true;\n if (colId in this.COLUMN_DEFAULT_TESTERS) {\n // This is potentially going to be used by extensions; avoid them\n // killing us.\n try {\n shouldShowColumn = this.COLUMN_DEFAULT_TESTERS[colId](this.view);\n } catch (ex) {\n shouldShowColumn = false;\n Cu.reportError(ex);\n }\n }\n state[colId] = { visible: shouldShowColumn };\n }\n return state;\n }", "title": "" }, { "docid": "d70ae36a444981291981ae8fd5c01a29", "score": "0.53948104", "text": "function getSavedColumns() {\n if (localStorage.getItem('backlogItems')) {\n backlogListArray = JSON.parse(localStorage.backlogItems);\n progressListArray = JSON.parse(localStorage.progressItems);\n completeListArray = JSON.parse(localStorage.completeItems);\n onHoldListArray = JSON.parse(localStorage.onHoldItems);\n } \n else {\n arrayList(0).push('Release the course', 'Sit back and relax');\n arrayList(1).push('Work on projects', 'Listen to music') \n arrayList(2).push('Being cool', 'Getting stuff done') \n arrayList(3).push('Being uncool') \n }\n onLoad = true\n}", "title": "" }, { "docid": "3c738a970b6566ec1d747256cb402795", "score": "0.5253448", "text": "restoreInternalState () {\n const folders = this.store.getState().tree.folders;\n const categoryId = this.store.getState().categoryId;\n const states = this.states;\n\n let folder = find(folders, {'id': categoryId});\n\n while (folder && folder.parent !== 'root') {\n states[folder.parent] = true;\n folder = find(folders, {'id': folder.parent});\n }\n }", "title": "" }, { "docid": "a4a44ee3bc2707bb85cd8868385db077", "score": "0.5251202", "text": "showOrHideColumns() {\n let cloneColumns = cloneDeep(this.columns);\n\n const { hiddenColumns } = this;\n\n if (!isEmptyArray(hiddenColumns)) {\n // recursive remove column key\n hiddenColumns.forEach((key) => {\n cloneColumns = recursiveRemoveColumnByKey(\n cloneColumns,\n key,\n );\n });\n }\n\n this.cloneColumns = cloneColumns;\n }", "title": "" }, { "docid": "2b5060946f7080053b9f36622469832e", "score": "0.52373564", "text": "applyPreferences() {\n\n let preferredState = localStorage.getItem(Constants.STORAGE_KEY);\n\n // Restore the last known state\n if (preferredState === Constants.STATE_COLLAPSED) {\n this.hideAllBodies();\n }\n }", "title": "" }, { "docid": "923a843e8d045f10866ea6c42956441c", "score": "0.51786625", "text": "function getSavedColumns() {\n if (localStorage.getItem(\"kanbanBoard\"))\n listArrays = JSON.parse(localStorage.kanbanBoard);\n //set array's DOM elements\n listArrays[0].el = backlogList;\n listArrays[1].el = progressList;\n listArrays[2].el = completeList;\n listArrays[3].el = onHoldList;\n}", "title": "" }, { "docid": "452054893770acdda810a6670e6c764c", "score": "0.5176471", "text": "function onChangeColumns() {\n // Update selected rows\n if (component.initialized) {\n component.reportChangedColumns();\n // Reposition save buttons\n component.repositionSaveButton();\n }\n }", "title": "" }, { "docid": "1e80e191de06853461e9c85e42111669", "score": "0.50674146", "text": "getColumnStates() {\n if (!this._active) {\n return this._savedColumnStates;\n }\n\n let columnStates = {};\n\n let cols = document.getElementById(\"threadCols\");\n let colChildren = cols.children;\n for (let iKid = 0; iKid < colChildren.length; iKid++) {\n let colChild = colChildren[iKid];\n if (colChild.tagName != \"treecol\") {\n continue;\n }\n columnStates[colChild.id] = {\n visible: !colChild.hidden,\n ordinal: colChild.ordinal,\n };\n }\n\n return columnStates;\n }", "title": "" }, { "docid": "375cf4f42cebb78dca29782ae4fcf952", "score": "0.5054644", "text": "save() {\n\tthis.props.updateRow(this.state.newRow);\t\n\tthis.setMode(RowMode.View);\n\tthis.setState({\n\t columns: this.state.newRow.slice()\n\t});\n }", "title": "" }, { "docid": "6927310fdd4ea5de69d444eacab3c671", "score": "0.495307", "text": "function loadSavedState() {\n var storedCollection = persistence.loadSavedState();\n if (storedCollection) {\n clear();\n loadCollection(storedCollection);\n }\n}", "title": "" }, { "docid": "102068895a01dd503e132fc738715850", "score": "0.49512964", "text": "rollback() {\n if (this.lastLoadedConfig) {\n log.debug('loading last loading config', this.lastLoadedConfig);\n const {\n advancedFilters,\n customColumns,\n quickFilters,\n reverseType,\n searchFilter,\n sorts,\n } = this.lastLoadedConfig;\n this.lastLoadedConfig = null;\n this.setState({\n advancedFilters,\n customColumns,\n quickFilters,\n reverseType,\n searchFilter,\n sorts,\n });\n } else {\n log.debug('remove all sorts, filters, and custom columns');\n this.setState({\n advancedFilters: new Map(),\n quickFilters: new Map(),\n sorts: [],\n customColumns: [],\n reverseType: TableUtils.REVERSE_TYPE.NONE,\n });\n }\n }", "title": "" }, { "docid": "cbbaf36bb96add3cdedadbeed6c5e59d", "score": "0.48992822", "text": "function LineUpLocalStorage(data, columns, layout, primaryKey, storageConfig) {\n this.storageConfig = $.extend(true, {}, {\n colTypes: {\n 'number': LineUp.LineUpNumberColumn,\n 'string': LineUp.LineUpStringColumn,\n 'categorical': LineUp.LineUpCategoricalColumn\n },\n layoutColumnTypes: {\n 'number': LineUp.LayoutNumberColumn,\n 'single': LineUp.LayoutStringColumn,\n 'string': LineUp.LayoutStringColumn,\n 'categorical': LineUp.LayoutCategoricalColumn,\n 'categoricalcolor': LineUp.LayoutCategoricalColorColumn,\n 'stacked': LineUp.LayoutStackedColumn,\n 'rank': LineUp.LayoutRankColumn,\n 'actions': LineUp.LayoutActionColumn\n }\n }, storageConfig);\n this.config = null; //will be injected by lineup\n\n var colTypes = this.storageConfig.colTypes;\n var layoutColumnTypes = this.storageConfig.layoutColumnTypes;\n var that = this;\n\n function toColumn(desc) {\n return new colTypes[desc.type](desc, toColumn, data);\n }\n\n this.storageConfig.toColumn = toColumn;\n\n this.primaryKey = primaryKey;\n this.rawdata = data;\n this.selected = d3.set();\n this.rawcols = columns.map(toColumn);\n this.layout = layout || LineUpLocalStorage.generateDefaultLayout(this.rawcols);\n\n var colLookup = d3.map();\n this.rawcols.forEach(function (col) {\n colLookup.set(col.column, col);\n });\n function toLayoutColumn(desc) {\n var type = desc.type || 'single';\n if (type === 'single') {\n var col = colLookup.get(desc.column);\n if (col instanceof LineUp.LineUpNumberColumn) {\n type = 'number';\n } else if (col instanceof LineUp.LineUpCategoricalColumn) {\n type = 'categorical';\n }\n }\n return new layoutColumnTypes[type](desc, colLookup, toLayoutColumn, that);\n }\n\n this.storageConfig.toLayoutColumn = toLayoutColumn;\n\n var bundles = this.bundles = {};\n Object.keys(this.layout).forEach(function(l) {\n bundles[l] = {\n layoutColumns: [],\n needsLayout: true, // this triggers the layout generation at first access to \"getColumnLayout\"\n data: data,\n initialSort :true\n };\n });\n }", "title": "" }, { "docid": "cbbaf36bb96add3cdedadbeed6c5e59d", "score": "0.48992822", "text": "function LineUpLocalStorage(data, columns, layout, primaryKey, storageConfig) {\n this.storageConfig = $.extend(true, {}, {\n colTypes: {\n 'number': LineUp.LineUpNumberColumn,\n 'string': LineUp.LineUpStringColumn,\n 'categorical': LineUp.LineUpCategoricalColumn\n },\n layoutColumnTypes: {\n 'number': LineUp.LayoutNumberColumn,\n 'single': LineUp.LayoutStringColumn,\n 'string': LineUp.LayoutStringColumn,\n 'categorical': LineUp.LayoutCategoricalColumn,\n 'categoricalcolor': LineUp.LayoutCategoricalColorColumn,\n 'stacked': LineUp.LayoutStackedColumn,\n 'rank': LineUp.LayoutRankColumn,\n 'actions': LineUp.LayoutActionColumn\n }\n }, storageConfig);\n this.config = null; //will be injected by lineup\n\n var colTypes = this.storageConfig.colTypes;\n var layoutColumnTypes = this.storageConfig.layoutColumnTypes;\n var that = this;\n\n function toColumn(desc) {\n return new colTypes[desc.type](desc, toColumn, data);\n }\n\n this.storageConfig.toColumn = toColumn;\n\n this.primaryKey = primaryKey;\n this.rawdata = data;\n this.selected = d3.set();\n this.rawcols = columns.map(toColumn);\n this.layout = layout || LineUpLocalStorage.generateDefaultLayout(this.rawcols);\n\n var colLookup = d3.map();\n this.rawcols.forEach(function (col) {\n colLookup.set(col.column, col);\n });\n function toLayoutColumn(desc) {\n var type = desc.type || 'single';\n if (type === 'single') {\n var col = colLookup.get(desc.column);\n if (col instanceof LineUp.LineUpNumberColumn) {\n type = 'number';\n } else if (col instanceof LineUp.LineUpCategoricalColumn) {\n type = 'categorical';\n }\n }\n return new layoutColumnTypes[type](desc, colLookup, toLayoutColumn, that);\n }\n\n this.storageConfig.toLayoutColumn = toLayoutColumn;\n\n var bundles = this.bundles = {};\n Object.keys(this.layout).forEach(function(l) {\n bundles[l] = {\n layoutColumns: [],\n needsLayout: true, // this triggers the layout generation at first access to \"getColumnLayout\"\n data: data,\n initialSort :true\n };\n });\n }", "title": "" }, { "docid": "72dc33d81261f9fa7f6f2d749c28196a", "score": "0.48816028", "text": "function recordFlip() {\n\tflippedColumnsRight = curColumnsRight;\n\tflippedColumnsLeft = curColumnsLeft;\n\tflippedRowsBottom = curRowsBottom;\n\tflippedRowsTop = curRowsTop;\n\tsaveState();\n}", "title": "" }, { "docid": "3c31387c76b19b1d73b6c663b6011a4b", "score": "0.4806536", "text": "function reset_save_data() {\n window.save_data = {\n 'item_list': [],\n 'db_total_item_count': 0,\n 'db_return_item_count': 0,\n 'db_max_page_idx': 0,\n 'view_max_page_count': 5,\n 'view_item_count_per_page': 10,\n 'view_start_page_idx': 0,\n 'view_current_page_idx': 0,\n 'view_current_page_count': 0,\n 'operator_list': [],\n 'have_been_changed': false,\n };\n}", "title": "" }, { "docid": "26fcf063266457c3fb034bbc1008c44e", "score": "0.47990364", "text": "onRestore() {\n this._updateModels();\n\n this._updateCastShadow();\n\n this._updateReceiveShadow();\n }", "title": "" }, { "docid": "2d07b568b133ada3585b850d286ca16e", "score": "0.47765586", "text": "function restoreOrder() {\n if ($.cookie == null) { return; }\n $(\".column\").each(function(index, value) {\n var colid = value.id;\n var cookieName = \"cookie-\" + colid\n colid = colid.replace(/:/g, '\\\\:');\n var cookie = $.cookie(cookieName);\n if ( cookie == null ) { return; }\n var IDs = cookie.split(\",\");\n if ( IDs[0] == '' ) { return; }\n for (var i = 0, n = IDs.length; i < n; i++ ) {\n var toks = IDs[i].split(\":\");\n var portletID = toks.slice(0, toks.length-1).join('\\\\:');\n var visible = toks[toks.length-1]\n var portlet = $(\".column\")\n .find('#' + portletID)\n .appendTo($('#' + colid));\n if (visible === 'false') {\n portlet.find(\".ui-icon\").toggleClass(\"ui-icon-minus\");\n portlet.find(\".ui-icon\").toggleClass(\"ui-icon-plus\");\n portlet.find(\".portlet-content\").hide();\n }\n }\n });\n}", "title": "" }, { "docid": "46c5ef5f311415848cc5af3a3f1c695c", "score": "0.47543216", "text": "clearGridStateFromLocalStorage() {\n localStorage.removeItem(LOCAL_STORAGE_KEY);\n this.aureliaGrid.gridService.resetGrid(this.columnDefinitions);\n }", "title": "" }, { "docid": "7d48a293ce7b5097eab9de5ca44e7b3c", "score": "0.47285873", "text": "_restoreState() {\n // try to get the state from localStorage\n const state = localStorage.getItem('ck-pre-view-state');\n // check if we have a states\n if (state !== 'NaN') {\n // set the state in instance\n this._currentStateIndex = state;\n // apply the state\n this.applyState(this._currentStateIndex);\n } else {\n this._currentStateIndex = 0;\n }\n }", "title": "" }, { "docid": "94ed496908cb033c3ce57d4a3b1a1931", "score": "0.47265574", "text": "@action\n showAllColumns() {\n this.processedColumns.setEach('isHidden', false);\n this._sendColumnsVisibilityChangedAction();\n }", "title": "" }, { "docid": "7ee0374d7de61d672d3a8be5c3ea559f", "score": "0.47169867", "text": "function restore_options() {\n var hideColumns = localStorage[\"hideColumns\"];\n\n //Backward compatibility\n var marketType = localStorage[\"marketType\"];\n if(marketType!=null) {\n if(marketType==1)\n countries = americaStr;\n else if(marketType==2)\n countries = europeStr;\n else if(marketType==3)\n countries = asiaStr;\n else\n countries = americaStr+europeStr+asiaStr;\n } else {\n countries = localStorage[\"countries\"].split(',');\n }\n\n //countries.print();\n\n var select2 = document.getElementById(\"hideColumns\");\n for (var i = 0; i < select2.children.length; i++) {\n var child = select2.children[i];\n if (child.value == hideColumns) {\n child.selected = \"true\";\n break;\n }\n }\n highLightOptions();\n}", "title": "" }, { "docid": "4b5092ef4bf4059f11ee48df1d7645ba", "score": "0.46895114", "text": "function saveDataMainWindow() {\n var iframeSource = document.getElementById(\"mainFrame\").contentDocument.URL;\n var iframeInfotoSave = iframeSource.split(\"/\");\n pageToSave = iframeInfotoSave.pop();\n folderToSave = iframeInfotoSave.pop();\n var i = currentStateMainWindow.findIndex(\n (obj) => obj.folder === folderToSave\n );\n currentStateMainWindow[i].fileToView = pageToSave;\n localStorage.setItem(\n \"lastKnownStateMainWin\",\n JSON.stringify(currentStateMainWindow)\n );\n}", "title": "" }, { "docid": "9d80cd201eafce10bd9362df23bcbd91", "score": "0.46855944", "text": "hintColumnsChanged() {\n // ignore this if we are the ones doing things\n if (this._touchingColumns) {\n return;\n }\n this._persistColumnStates(this.getColumnStates());\n }", "title": "" }, { "docid": "1058f5cc10133828de22ad73d2ffd19b", "score": "0.46778578", "text": "function restoreOrder() {\n $(\".column\").each(function(index, value) {\n var columnId = value.id;\n var cookieName = \"listOrder\" + columnId;\n var cookie = $.cookie(cookieName);\n if ( cookie == null ) { return; }\n var IDs = cookie.split(\",\");\n for (var i = 0, n = IDs.length; i < n; i++ ) {\n var toks = IDs[i].split(\":\");\n if ( toks.length != 2 ) {\n continue;\n }\n var portletId = toks[0];\n var visible = toks[1];\n var portlet = $(\".column\")\n .find('#' + portletId)\n .appendTo($('#' + columnId));\n if (visible === 'false') {\n portlet.find(\".ui-icon\").toggleClass(\"ui-icon-minus\");\n portlet.find(\".ui-icon\").toggleClass(\"ui-icon-plus\");\n portlet.find(\".portlet-content\").hide();\n }\n }\n });\n}", "title": "" }, { "docid": "89102bfcbc31bb1bc9e7be9393f02321", "score": "0.46776617", "text": "function stateSaveCallback(settings, data) {\n var stado = $('#tablaConsultaBecariosInternos').DataTable().state();\n localStorage.setItem('tablaConsultaBecariosInternos' + window.location.pathname, JSON.stringify(stado))\n }", "title": "" }, { "docid": "67d5a44b670caa19fe2264495a8c6aaa", "score": "0.4667502", "text": "Restore() {\n this.db_restore();\n return this.opline_restore_all();\n }", "title": "" }, { "docid": "8c5f129e65d3795f221ccbd1b1c62d97", "score": "0.4659678", "text": "function hideColumns () {\r\n // hide columns that are hidden by default\r\n var csettings = my.columnSettings();\r\n my.columnOrder().forEach (function (key, i) {\r\n if (csettings[key]) {\r\n // OMG OMG. I used 'select' here instead of 'selectAll' and it passed on the whole table datum to every td cell in the last row\r\n // That's what it's meant to do in fairness, but it's an insidious side-effect when you're just wanting to access an element\r\n var lastRowCellSelect = selection.selectAll(\"tbody tr:last-child td:nth-child(\"+(i+1)+\")\");\r\n if (!lastRowCellSelect.empty()) {\r\n var currentState = lastRowCellSelect.style(\"display\") !== \"none\";\r\n var proposedState = csettings[key].visible;\r\n if (currentState !== proposedState) {\r\n displayColumn (i + 1, proposedState);\r\n }\r\n }\r\n }\r\n })\r\n }", "title": "" }, { "docid": "26fccd43c179bcf92d2e5f53ff46f90c", "score": "0.46554148", "text": "loadFromLocal (event) {\n \t\tvar localData = JSON.parse(localStorage.getItem('saved-data'));\n \t\tthis.setState({\n \t\t\tlocalData: localData,\n \t\t\tsearchView: false\n \t\t});\n \t}", "title": "" }, { "docid": "2430cbed23dff0996fb46bd6aba9ad51", "score": "0.46321097", "text": "reset() {\n this.forcedVisibleSearchInputs = [], this.visibleColumns = this.defaultVisibleToggleableColumns;\n let e = this.getCurrentQuery();\n e.columns = [], e.page = null, e.perPage = null, e.sort = null, te(e, (t, r) => {\n et(r, \"filter[\") && (e[r] = null);\n }), this.visitWithQueryObject(e, null, !0);\n }", "title": "" }, { "docid": "a1c22fbcc14a583d03262c7fc1358221", "score": "0.46142626", "text": "restoreThreadState() {\n if (!this._active || !this.tree || !this.view.dbView.viewFolder) {\n return;\n }\n\n if (\n this.view._threadExpandAll &&\n !(this.view.dbView.viewFlags & Ci.nsMsgViewFlagsType.kExpandAll)\n ) {\n this.view.dbView.doCommand(Ci.nsMsgViewCommandType.expandAll);\n }\n if (\n !this.view._threadExpandAll &&\n this.view.dbView.viewFlags & Ci.nsMsgViewFlagsType.kExpandAll\n ) {\n this.view.dbView.doCommand(Ci.nsMsgViewCommandType.collapseAll);\n }\n }", "title": "" }, { "docid": "67f41f89bed00ed5058f163f3f507bef", "score": "0.4609676", "text": "function stateSaveCallback(settings, data) {\n var stado = $('#GIcreafin').DataTable().state();\n localStorage.setItem('GIcreafin' + window.location.pathname, JSON.stringify(stado))\n }", "title": "" }, { "docid": "a6044d92af0150d0625677e894177d83", "score": "0.46082133", "text": "function saveData(){ // function for saving data into localStorage this function is called on every update on the app;\n localStorage.setItem('data',JSON.stringify(excel.data));\n localStorage.setItem('rows',String(excel.rows));\n localStorage.setItem('columns',String(excel.columns));\n}", "title": "" }, { "docid": "dbced5807ed46e5cee144963de59971f", "score": "0.45919287", "text": "restoreColOrder() {\n this.$el.find('.FeedsView-createdAt').addClass('FeedsView-listItem--' + this.classMappings[this.layoutSettings.createdAtIndex]);\n this.$el.find('.FeedsView-tweetText').addClass('FeedsView-listItem--' + this.classMappings[this.layoutSettings.textIndex]);\n this.$el.find('.FeedsView-tweetLink').addClass('FeedsView-listItem--' + this.classMappings[this.layoutSettings.linkIndex]);\n }", "title": "" }, { "docid": "c85fc9ae12aacb1b62fe06f4a2c929b1", "score": "0.45740974", "text": "resetState() {\n // In order to show the correct warning for the saved-object-save-as-check-box we have to store the unsaved\n // title on the dashboard object. We should fix this at some point, but this is how all the other object\n // save panels work at the moment.\n this.savedDashboard.title = this.savedDashboard.lastSavedTitle;\n\n // appState.reset uses the internal defaults to reset the state, but some of the default settings (e.g. the panels\n // array) point to the same object that is stored on appState and is getting modified.\n // The right way to fix this might be to ensure the defaults object stored on state is a deep\n // clone, but given how much code uses the state object, I determined that to be too risky of a change for\n // now. TODO: revisit this!\n this.stateDefaults = getStateDefaults(this.savedDashboard, this.dashboardConfig.getHideWriteControls());\n // The original query won't be restored by the above because the query on this.savedDashboard is applied\n // in place in order for it to affect the visualizations.\n this.stateDefaults.query = this.lastSavedDashboardFilters.query;\n // Need to make a copy to ensure they are not overwritten.\n this.stateDefaults.filters = Object.assign(new Array(), this.getLastSavedFilterBars());\n\n this.isDirty = false;\n this.appState.setDefaults(this.stateDefaults);\n this.appState.reset();\n this.stateMonitor.setInitialState(this.appState.toJSON());\n }", "title": "" }, { "docid": "9a4142f52fbc9b2911a319436070af93", "score": "0.45666113", "text": "function restoreOriginal() {\n if (!editOriginal) { return; }\n vm.editObj.name = editOriginal.name;\n vm.editObj.description = editOriginal.description;\n }", "title": "" }, { "docid": "03f4905a054aeec9e4ae6993b662a04f", "score": "0.45605415", "text": "makeInactive() {\n // - things to do before we mark ourselves inactive (because they depend on\n // us being active)\n\n // getColumnStates returns _savedColumnStates when we are inactive (and is\n // used by _saveColumnStates) so we must do this before marking inactive.\n this._saveColumnStates();\n\n // - mark us inactive\n this._active = false;\n\n // - (everything after this point doesn't care that we are marked inactive)\n // save the folder pane's state always\n this._folderPaneVisible = !document.getElementById(\"folderPaneBox\")\n .collapsed;\n\n if (this.view.dbView) {\n if (this.tree) {\n this._savedFirstVisibleRow = this.tree.getFirstVisibleRow();\n }\n\n // save the message pane's state only when it is potentially visible\n this.messagePaneCollapsed = document.getElementById(\n \"messagepaneboxwrapper\"\n ).collapsed;\n\n this.hookUpFakeTree(true);\n }\n\n this.messageDisplay.makeInactive();\n }", "title": "" }, { "docid": "6a5e0dd24f9eb3798e55b8dd59c88094", "score": "0.4551295", "text": "function revert() {\n $table.removeClass(defaults.loadedClass);\n\n var $wrap = $table.parents('.fixedCol-pepin-wrap');\n\n $wrap.after($table);\n $wrap.remove();\n }", "title": "" }, { "docid": "6bf8c2419f43a84c14e51b13030e3cc0", "score": "0.4511603", "text": "restoreData(favorites) {\n\t\tconst state = {\n\t\t\tfavorites: favorites,\n\t\t\ttimesFavorited: favorites.length\n\t\t};\n\t\tconst store = {\n\t\t\t_state: state,\n\t\t\t_version: 2\n\t\t};\n\t\tthis.objectStorage.impl.set(\"GIFFavoritesStore\", store);\n\t\tthis.gifStore.initialize(state);\n\t}", "title": "" }, { "docid": "2eb6801ccfc145423c0ac2a92c77913f", "score": "0.4507325", "text": "function resetColumns() {\r\n d3.selectAll(\"span\").each(function() {\r\n d3.select(this).style(\"position\", \"static\").style(\"left\", \"0%\");\r\n })\r\n\r\n d3.select(\"#text_container\").style(\"font-size\", \"1.6vw\");\r\n d3.select(\"#column_controls\").style(\"display\", \"none\");\r\n\r\n d3.select(\"#column-controls\").style(\"display\", \"none\");\r\n}", "title": "" }, { "docid": "1379223c790a16930a52727e96e2db8c", "score": "0.4485402", "text": "function migrate_state (cell) {\n if (cell.metadata.run_control !== undefined) {\n if (cell instanceof CodeCell || cell instanceof MarkdownCell) {\n if (cell.metadata.run_control.read_only === true) {\n cell.metadata.editable = false;\n }\n }\n else {\n // remove metadata irrelevant to non-code/markdown cells\n delete cell.metadata.run_control.frozen;\n }\n // remove old key replaced by metadata.editable\n delete cell.metadata.run_control.read_only;\n // remove whole object if it's now empty\n if (Object.keys(cell.metadata.run_control).length === 0) {\n delete cell.metadata.run_control;\n }\n }\n }", "title": "" }, { "docid": "6ab39f7ea176a06098f2e948550aa47d", "score": "0.4484255", "text": "@action\n hideAllColumns() {\n A(this.processedColumns.filterBy('mayBeHidden')).setEach('isHidden', true);\n this._sendColumnsVisibilityChangedAction();\n }", "title": "" }, { "docid": "5e2723743c3b96f8eb6771c097903f29", "score": "0.44798154", "text": "_set(iter, column, data) {\n\n const isDataColumn =\n column != 'DISPLAY_ICON' && column != 'DISPLAY_ANGLE' && column != 'DISPLAY_NAME';\n\n // First, store the given value.\n this._store.set_value(iter, this._store.columns[column], data);\n\n // If the icon, was set, update the \"DISPLAY_ICON\" as well.\n if (column == 'ICON') {\n let iconSize = this._isToplevel(iter) ? 24 : 16;\n const font = this._settings.get_string('font');\n const color = this._view.get_style_context().get_color(Gtk.StateFlags.NORMAL);\n this._set(iter, 'DISPLAY_ICON', utils.createIcon(data, iconSize, font, color));\n }\n\n // If the angle, was set, update the \"DISPLAY_ANGLE\" as well. For top-level menus,\n // this field contains the menu ID, so we update the DISPLAY_ANGLE only for\n // non-top-level menus.\n if (column == 'ANGLE') {\n if (!this._isToplevel(iter)) {\n this._set(iter, 'DISPLAY_ANGLE', data >= 0 ? data : '');\n }\n }\n\n // If the name, was set, update the \"DISPLAY_NAME\" as well. If iter refers to a\n // top-level menu, the display name contains the shortcut.\n if (column == 'NAME') {\n if (this._isToplevel(iter)) {\n let shortcut = _('Not bound.');\n const accelerator = this._get(iter, 'SHORTCUT');\n if (accelerator) {\n const [keyval, mods] = Gtk.accelerator_parse(accelerator);\n shortcut = Gtk.accelerator_get_label(keyval, mods);\n }\n this._set(\n iter, 'DISPLAY_NAME',\n '<b>' + GLib.markup_escape_text(data, -1) + '</b>\\n<small>' +\n GLib.markup_escape_text(shortcut, -1) + '</small>');\n } else {\n this._set(iter, 'DISPLAY_NAME', GLib.markup_escape_text(data, -1));\n }\n }\n\n // If the data column was set on a top-level menu, we need to update the\n // \"DISPLAY_NAME\" as well, as the shortcut is displayed in the cellrenderer.\n if (column == 'SHORTCUT') {\n if (this._isToplevel(iter)) {\n let shortcut = _('Not bound.');\n if (data != '') {\n const [keyval, mods] = Gtk.accelerator_parse(data);\n shortcut = Gtk.accelerator_get_label(keyval, mods);\n }\n const name = this._get(iter, 'NAME');\n this._set(\n iter, 'DISPLAY_NAME',\n '<b>' + GLib.markup_escape_text(name, -1) + '</b>\\n<small>' +\n GLib.markup_escape_text(shortcut, -1) + '</small>');\n }\n }\n\n // If loading has finished, any modifications to the tree store are directly committed\n // to the \"menu-configuration\" settings key.\n if (isDataColumn && this._menuSavingAllowed) {\n this._saveMenuConfiguration();\n }\n }", "title": "" }, { "docid": "327a9773033a3f15bf8c99a91657b4b0", "score": "0.44761884", "text": "function save() {\n var $e = $(this);\n $e.data(me + \"-visibility\", $e.css(\"visibility\"));\n $e.data(me + \"-display\", $e.css(\"display\"));\n }", "title": "" }, { "docid": "95af51b97f4ed5f53d3d41bbb3e34bc7", "score": "0.4467804", "text": "restoreCheckpoints() {\n if (localStorage.getItem('last-updates') !== null) {\n this.lastUpdates = new Map(JSON.parse(localStorage.getItem('last-updates')));\n }\n if (localStorage.getItem('last-syncs') !== null) {\n this.lastSyncs = new Map(JSON.parse(localStorage.getItem('last-syncs')));\n }\n }", "title": "" }, { "docid": "cb32559fee755d47aa717b67c6d59e42", "score": "0.446624", "text": "recalculateColumnWidths() {\n if (!this._columnTree) {\n return; // No columns\n }\n if (this._cache.isLoading()) {\n this._recalculateColumnWidthOnceLoadingFinished = true;\n } else {\n const cols = this._getColumns().filter((col) => !col.hidden && col.autoWidth);\n this._recalculateColumnWidths(cols);\n }\n }", "title": "" }, { "docid": "63566606eafded13a358429e8ba3ebc0", "score": "0.4443372", "text": "setConfig(state) {\n const config = state.config;\n state.tableName = config.tableName || state.tableName;\n state.pageSize = config.pageSize || state.pageSize;\n state.colOrder = config.colOrder || state.colOrder;\n state.colsToShow = config.colsToShow\n ? [...config.colsToShow]\n : state.rows.length > 0\n ? Object.keys(state.rows[0])\n .filter(col => col !== \".key\")\n .map(function(name) {\n return { name: name, visible: true, expr: \"\" };\n })\n : [];\n\n // sort the columns based on the column ordering in the config\n state.colsToShow.sort((a, b) => {\n if (\n state.colOrder.indexOf(a.name) === -1 &&\n state.colOrder.indexOf(b.name) === -1\n ) {\n return 0;\n }\n if (\n state.colOrder.indexOf(a.name) === -1 ||\n state.colOrder.indexOf(b.name) === -1\n ) {\n return state.colOrder.indexOf(a.name) === -1 ? 1 : -1;\n }\n if (state.colOrder.indexOf(a.name) < state.colOrder.indexOf(b.name)) {\n return -1;\n } else {\n // state.colOrder.indexOf(a.name) > state.colOrder.indexOf(b.name))\n return 1;\n }\n });\n }", "title": "" }, { "docid": "67bae59104596aa7725aa69c3be4387d", "score": "0.4441694", "text": "recalculateColumnWidths() {\n if (!this._columnTree) {\n return; // No columns\n }\n\n if (this._cache.isLoading()) {\n this._recalculateColumnWidthOnceLoadingFinished = true;\n } else {\n const cols = this._getColumns().filter(col => !col.hidden && col.autoWidth);\n\n this._recalculateColumnWidths(cols);\n }\n }", "title": "" }, { "docid": "0a53f275e60f801f685c1c7ad85b5a1a", "score": "0.4441325", "text": "function updateDOM() {\n // Check localStorage once\n if (!updatedOnLoad) getSavedColumns();\n //\n listArrays.forEach((arr, i) => {\n arr.el.textContent = \"\";\n arr.arr.forEach((item, j) => createItemEl(arr.el, i, item, j));\n });\n // Run getSavedColumns only once, Update Local Storage\n updatedOnLoad = true;\n updateSavedColumns();\n}", "title": "" }, { "docid": "53d50f0b82dee5a93ed8e038f094e16f", "score": "0.44286445", "text": "function restoreOriginal() {\n if (!editOriginal) { return; }\n vm.editObj.guid = editOriginal.guid;\n vm.editObj.name = editOriginal.name;\n }", "title": "" }, { "docid": "9ac22aea5ff57d7288cf973537298845", "score": "0.44152614", "text": "function reCreateTaskColumnsData() {\n const columnHeadersDetails = that.taskColumns,\n taskTreeSplitterItems = that.$.taskTreeSplitter.items,\n treeTasks = that._getTasksJSON();\n\n if (taskTreeSplitterItems.length !== columnHeadersDetails.length) {\n that._createTreeColumns(that.$.taskTreeSplitter);\n }\n else {\n for (let i = 0; i < columnHeadersDetails.length; i++) {\n that._createTreeColumnsData(taskTreeSplitterItems[i].closest('smart-splitter-item'), columnHeadersDetails[i], treeTasks);\n }\n }\n }", "title": "" }, { "docid": "8e190ca507cef2c14c2a156ff6d2a9a5", "score": "0.44142663", "text": "function undo_saved_list_print_layout()\n{\n // Remove table border\n var table = document.getElementsByClassName(\"saved_list_table\");\n table[0].style.border = \"none\";\n\n // Remove table entry borders\n var th = document.getElementsByClassName(\"saved_list_td\");\n for(var i = 0; i < th.length; i++)\n {\n th[i].style.border = \"none\";\n }\n\n // Erase current date and time\n document.getElementById(\"print_date\").innerHTML = \"\";\n}", "title": "" }, { "docid": "3d36966b946f4c73b7240ddd9c303f53", "score": "0.44128895", "text": "function metadata_loaded() {\n if (table_metadata) {\n other_columns = [];\n for (var i = 0; i != table_metadata[\"column-count\"] - 1; ++i) {\n if ($.inArray(i, input_columns) == -1 && $.inArray(i, output_columns) == -1) {\n other_columns.push(i);\n }\n }\n filter_manager.set_other_columns(other_columns);\n }\n\n setup_table();\n\n if (!indices && table_metadata) {\n var count = table_metadata[\"row-count\"];\n indices = new Int32Array(count);\n for (var i = 0; i != count; ++i) indices[i] = i;\n }\n\n setup_controls();\n filter_manager.set_table_statistics(table_statistics);\n\n if (table_metadata && bookmark) {\n // Choose some columns for the X and Y axes.\n var x_y_variables = [];\n\n // First add inputs and outputs to possible columns\n x_y_variables.push.apply(x_y_variables, input_columns);\n x_y_variables.push.apply(x_y_variables, output_columns);\n\n for (var i = 0; i < table_metadata[\"column-count\"] - 1; i++) {\n // Only use non-string columns\n if (table_metadata[\"column-types\"][i] != \"string\") x_y_variables.push(i);\n }\n\n x_index = x_y_variables[0];\n y_index = x_y_variables[1 % x_y_variables.length];\n if (\"x-selection\" in bookmark) x_index = Number(bookmark[\"x-selection\"]);\n if (\"y-selection\" in bookmark) y_index = Number(bookmark[\"y-selection\"]);\n\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to x and y indexes in Redux\n window.store.dispatch(setXIndex(x_index));\n window.store.dispatch(setYIndex(y_index));\n });\n\n auto_scale = true;\n if (\"auto-scale\" in bookmark) {\n auto_scale = bookmark[\"auto-scale\"];\n }\n video_sync = false;\n if (\"video-sync\" in bookmark) {\n video_sync = bookmark[\"video-sync\"];\n }\n video_sync_time = 0;\n if (\"video-sync-time\" in bookmark) {\n video_sync_time = bookmark[\"video-sync-time\"];\n }\n\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n threeD_sync = false;\n if (\"threeD_sync\" in window.store.getState()) {\n threeD_sync = window.store.getState().threeD_sync;\n }\n setSyncCameras(threeD_sync);\n setup_controls();\n });\n\n // Set state of selected and hidden simulations\n selected_simulations = [];\n if (\"simulation-selection\" in bookmark)\n selected_simulations = bookmark[\"simulation-selection\"];\n hidden_simulations = [];\n if (\"hidden-simulations\" in bookmark) hidden_simulations = bookmark[\"hidden-simulations\"];\n manually_hidden_simulations = [];\n if (\"manually-hidden-simulations\" in bookmark)\n manually_hidden_simulations = bookmark[\"manually-hidden-simulations\"];\n\n chunker.get_model_array_attribute({\n api_root: api_root,\n mid: model_id,\n aid: \"data-table\",\n array: 0,\n attribute: x_index,\n success: function (result) {\n x = result;\n if (table_metadata[\"column-types\"][x_index] == \"string\") {\n x = x[0];\n }\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to x values in Redux\n window.store.dispatch(setXValues(x));\n setup_scatterplot();\n setup_table();\n });\n },\n error: artifact_missing,\n });\n\n chunker.get_model_array_attribute({\n api_root: api_root,\n mid: model_id,\n aid: \"data-table\",\n array: 0,\n attribute: y_index,\n success: function (result) {\n y = result;\n if (table_metadata[\"column-types\"][y_index] == \"string\") {\n y = y[0];\n }\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to y values in Redux\n window.store.dispatch(setYValues(y));\n setup_scatterplot();\n setup_table();\n });\n },\n error: artifact_missing,\n });\n\n v_index = table_metadata[\"column-count\"] - 1;\n if (\"variable-selection\" in bookmark) {\n v_index = Number(bookmark[\"variable-selection\"]);\n }\n\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to v index in Redux\n window.store.dispatch(setVIndex(v_index));\n });\n\n if (v_index == table_metadata[\"column-count\"] - 1) {\n var count = table_metadata[\"row-count\"];\n v = new Float64Array(count);\n for (var i = 0; i != count; ++i) v[i] = i;\n\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to v values in Redux\n window.store.dispatch(setVValues(v));\n // console.log(`window.store.dispatch(setVValues(v));`);\n update_current_colorscale();\n setup_scatterplot();\n setup_table();\n });\n } else {\n chunker.get_model_array_attribute({\n api_root: api_root,\n mid: model_id,\n aid: \"data-table\",\n array: 0,\n attribute: v_index,\n success: function (result) {\n v = result;\n if (table_metadata[\"column-types\"][v_index] == \"string\") {\n v = v[0];\n }\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to v values in Redux\n window.store.dispatch(setVValues(v));\n update_current_colorscale();\n setup_scatterplot();\n setup_table();\n });\n },\n error: artifact_missing,\n });\n }\n\n images_index = -1;\n // Set images index from bookmark if it's there\n if (\"images-selection\" in bookmark) {\n images_index = bookmark[\"images-selection\"];\n }\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to media index in Redux\n window.store.dispatch(setMediaIndex(images_index));\n });\n // We don't want to set it to the first column because we have a\n // None option that users can select to get rid of media sets.\n // // Otherwise set it to the first images column if we have any\n // else if(image_columns.length > 0)\n // {\n // images_index = image_columns[0];\n // }\n setup_table();\n if (image_columns.length > 0 && images_index > -1) {\n $.ajax({\n type: \"GET\",\n url:\n api_root +\n \"models/\" +\n model_id +\n \"/arraysets/data-table/data?hyperchunks=0/\" +\n images_index +\n \"/0:\" +\n table_metadata[\"row-count\"],\n success: function (result) {\n images = result[0];\n // Wait until the redux store has been created\n createReduxStorePromise.then(() => {\n // Dispatch update to media values in Redux\n window.store.dispatch(setMediaValues(images));\n setup_scatterplot();\n //setup_table();\n });\n },\n error: artifact_missing,\n });\n } else {\n images = undefined;\n setup_scatterplot();\n }\n setup_controls();\n }\n }", "title": "" }, { "docid": "d9558985beef2f0051f18fdcd8f8b560", "score": "0.44127083", "text": "restoreRowPosition() {\n\t\t\tthis.swoosh.restore();\n\t\t}", "title": "" }, { "docid": "0709ca3d3d5f1ef9131d88246d7404e9", "score": "0.44079506", "text": "cleanScreen(){\n this.gridOptions.data = [];\n this.gridOptions.columnDefs = [];\n this.gridApi.core.notifyDataChange(this.uiGridConstants.dataChange.ALL);\n }", "title": "" }, { "docid": "712dd9180ab3bedb9ae9ab4e59550a8c", "score": "0.4402034", "text": "function setLocalStorage() {\n try {\n localStorage.setItem('fileTree', JSON.stringify(fileTree));\n Modal.open(\"save-confirm\");\n } catch (err) {\n Modal.open(\"save-fail\");\n }\n }", "title": "" }, { "docid": "b51f1f29c80a5102d953436044170b0e", "score": "0.4393112", "text": "restore() {\n\t\tif (this._backupData) {\n\t\t\tthis._changed = this._backupData.changed;\n\n\t\t\tlet aabb = this._backupData.aabb;\n\n\t\t\tlet nw = this._points[\"nw\"];\n\t\t\tlet ne = this._points[\"ne\"];\n\t\t\tlet sw = this._points[\"sw\"];\n\t\t\tlet se = this._points[\"se\"];\n\n\t\t\t// restore\n\t\t\tnw.x = aabb[0];\n\t\t\tnw.y = aabb[1];\n\t\t\tse.x = aabb[2];\n\t\t\tse.y = aabb[3];\n\n\t\t\tne.x = se.x;\n\t\t\tne.y = nw.y;\n\t\t\tsw.x = nw.x;\n\t\t\tsw.y = se.y;\n\n\t\t\tlet size = this._getSize();\n\n\t\t\tthis._dim.width = size.width;\n\t\t\tthis._dim.height = size.height;\n\n\t\t\tthis._redraw();\n\n\t\t\tthis._backupData = null;\n\t\t}\n\t}", "title": "" }, { "docid": "94152ea6ddd1ea2cca33ed2ef5f543b8", "score": "0.4391351", "text": "function stateSaveCallback(settings, data) {\n var stado = $('#CRcompetidoresGet').DataTable().state();\n localStorage.setItem('CRcompetidoresGet' + window.location.pathname, JSON.stringify(stado))\n }", "title": "" }, { "docid": "30f8a84a7623833f68ee373249c0207b", "score": "0.43905696", "text": "load() {\n var position = localStorage.getItem(\"save\")\n if (position)\n this.setState({ position, oldBranches: [] })\n }", "title": "" }, { "docid": "d7d16735bed7ab36f8e6da4ddaaa6026", "score": "0.4390029", "text": "retrieveState(){\n if(this.storePath()){\n this.state = getLocal(this.storePath(), this.state)\n }\n }", "title": "" }, { "docid": "07a40967ba416659bb7912d24bd6a834", "score": "0.4382424", "text": "getColumns(){\n\tconst columns = [\n\t { key: '_id', visible: false },\n\t { key: 'category', name: 'Category', visible: true },\n\t { key: 'subject', name: 'Subject', visible: true },\n\t { key: 'status', name: 'Status', visible: true },\n\t { key: 'damagedGood', name: 'Damage', visible: true },\n\t {\n\t\tkey: 'edit',\n\t\tgetRowMetaData: ( row ) => row,\n\t\tformatter: ( { dependentValues } ) => (\n\t\t <a\n\t\t href='javascript:;'\n\t\t onClick={ () => this.handleEditRow( dependentValues ) }\n\t\t >\n\t\t <FontAwesomeIcon icon={ 'pencil-alt' } />\n\t\t </a>\n\t\t),\n\t\twidth: 35, visible: true\n\t },\n\t {\n\t\tkey: 'delete',\n\t\tgetRowMetaData: ( row ) => row,\n\t\tformatter: ( { dependentValues } ) => (\n\t\t <a\n\t\t href='javascript:;'\n\t\t onClick={ () => this.openModalConfirmation( dependentValues ) }\n\t\t >\n\t\t <FontAwesomeIcon icon={ 'trash' } className='text-danger' />\n\t\t </a>\n\t\t),\n\t\twidth: 35,\n\t\tvisible: true\n\t }\n\t];\n\t// set columns in state\n\tthis.setState( { columns } );\n }", "title": "" }, { "docid": "3a5b65635a0a3dd3d03878f19448b5b9", "score": "0.43545437", "text": "function saveOrder() {\n if ($.cookie == null) { return; }\n $(\".column\").each(function(index, value){\n var colid = value.id;\n var cookieName = \"cookie-\" + colid;\n // Get the order for this column.\n var order = $('#' + colid.replace(/:/g, '\\\\:')).sortable(\"toArray\");\n // For each portlet in the column\n for ( var i = 0, n = order.length; i < n; i++ ) {\n // Determine if it is 'opened' or 'closed'\n var v = $('#' + order[i].replace(/:/g, '\\\\:'))\n .find('.portlet-content').is(':visible');\n // Modify the array we're saving to indicate what's open and\n // what's not.\n order[i] = order[i] + \":\" + v;\n }\n $.cookie(cookieName, order, { path: \"/\", expiry: new Date(2012, 1, 1)});\n });\n}", "title": "" }, { "docid": "c6cd3e9d9c9149f18aea7eef27f47f34", "score": "0.43453863", "text": "function parseColumnTiles() {\n $scope.$apply(function () {\n var layout = vm.layout;\n\n if (singleColumnMode) {\n layout.one_column_layout = parseTileOrder(column1);\n } else {\n layout.two_column_layout[0] = parseTileOrder(column1);\n layout.two_column_layout[1] = parseTileOrder(column2);\n }\n });\n }", "title": "" }, { "docid": "58c96ccdb6c7ecbb104a00216d7aa5d5", "score": "0.4342753", "text": "getDisplayColumns() {\r\n let displayColumns = [...this.livestockColumns]\r\n displayColumns = displayColumns.filter(column => {\r\n return (column.visible || this.ignoreColumns.includes(column.field));\r\n });\r\n return displayColumns;\r\n }", "title": "" }, { "docid": "8f3f369ea986098c82b89d24c7daf2e7", "score": "0.4342313", "text": "function restore() {\n // Use default value color = 'red' and likesColor = true.\n chrome.storage.sync.get({\n enableRotate: {\n type: 'checkbox',\n value: true\n },\n enableMap: {\n type: 'checkbox',\n value: true\n },\n zoomLevel: {\n type: 'number',\n value: 15\n },\n enableLargeThumbnails: {\n type: 'checkbox',\n value: true\n }\n }, function(items) {\n for(var value in items) {\n if (items[value].type === 'checkbox') {\n $('#' + value).prop('checked', items[value].value);\n } else {\n $('#' + value).val(items[value].value);\n }\n }\n });\n }", "title": "" }, { "docid": "d3968377f91a3f493c737f93f56f4933", "score": "0.4317954", "text": "function rememberLastState()\n {\n if ( lastState.layout !== \"sidebar\" )\n {\n lastState.position = $ui.position();\n lastState.size = {};\n lastState.size.uiWidth = $ui.outerWidth();\n lastState.size.uiHeight = $ui.outerHeight()\n }\n }", "title": "" }, { "docid": "1aec766f4e7a82b120639850df63b32e", "score": "0.43149027", "text": "saveWindowState () {\n clearTimeout(this.mailboxWindowSaver)\n this.mailboxWindowSaver = setTimeout(() => {\n const state = {\n fullscreen: this.mailboxWindow.isFullScreen(),\n maximized: this.mailboxWindow.isMaximized()\n }\n if (!this.mailboxWindow.isMaximized() && !this.mailboxWindow.isMinimized()) {\n const position = this.mailboxWindow.getPosition()\n const size = this.mailboxWindow.getSize()\n state.x = position[0]\n state.y = position[1]\n state.width = size[0]\n state.height = size[1]\n }\n\n this.localStorage.setItem('mailbox_window_state', JSON.stringify(state))\n }, 2000)\n }", "title": "" }, { "docid": "4cc9ee78177dc96e8d52054444695103", "score": "0.43111634", "text": "onAfterSaveCell(row, cellName, cellValue) {\n\t\tvar tempLocalData = this.state.localData.slice();\n\t\tvar rowObj = {};\n\t\tfor (const prop in row) {\n\t\t\trowObj[prop] = row[prop];\n\t\t}\n\t\tconsole.log(rowObj);\n\t\tvar removedRow = $.grep(tempLocalData, function(e){ return e.itemId != rowObj.itemId; });\n\t\tvar pushToLocal = removedRow.concat(rowObj);\n\t\tlocalStorage.setItem('saved-data', JSON.stringify(pushToLocal));\n\t\tthis.setState({\n\t\t\tlocalData: pushToLocal\n\t\t});\n\t}", "title": "" }, { "docid": "0e8a550f5e700d253ea22f8e77c26fb8", "score": "0.43085542", "text": "save() {\n this.overlayWrapper.classList.remove(`${this.selectors.activeClass}`);\n this.saveToLocalStorage();\n this.themeSwitch.displayCustomTheme();\n this.themeSwitch.saveThemeToLocalStorage(`${this.selectors.customTheme}`);\n this.modal.classList.remove(`${this.selectors.activeClass}`);\n }", "title": "" }, { "docid": "0d99e86639be35019132c57f717a148a", "score": "0.43075365", "text": "function columbusScreen() {\n stateActivitiesContainer.classList.add(\"hide\");\n localActivitiesContainer.classList.remove(\"hide\");\n localStorage.setItem(\"savedScreen\", \"Columbus\");\n}", "title": "" }, { "docid": "356daa55d333a8986c299213d6a64738", "score": "0.43067014", "text": "restore() {\n var names = [];\n var fields = Object.keys(extend({}, this._original, this._data));\n for (var field of fields) {\n if (this.modified(field)) {\n names.push(field);\n }\n }\n this._data = extend({}, this._original);\n for (var name of names) {\n this._applyWatch(name);\n }\n this.trigger('modified');\n return this;\n }", "title": "" }, { "docid": "ab80d305ddef6c1c653b74d63c9d15de", "score": "0.4303528", "text": "restore() {\n if (!this.original_) {\n return;\n }\n this.parentObject_[this.leafAttrName_] = this.original_;\n this.original_ = null;\n }", "title": "" }, { "docid": "61a8169d4062fe65201514ffe88b8ca8", "score": "0.43012255", "text": "function flush(){\n if(edi.readOptions.columns){\n if(state.count === 0 && edi.readOptions.columns === true){\n edi.readOptions.columns = state.line;\n state.line = [];\n state.lastC = '';\n return;\n }\n var line = {};\n for(var i=0; i<edi.readOptions.columns.length; i++){\n var column = edi.readOptions.columns[i];\n line[column] = state.line[i]||null;\n }\n state.line = line;\n line = null;\n }\n var line;\n if(edi.transformer){\n transforming = true;\n try{\n line = edi.transformer(state.line, state.count);\n }catch(e){\n error(e);\n // edi.emit('error', e);\n // // Destroy the input stream\n // if(edi.readStream) edi.readStream.destroy();\n }\n \n if (edi.writeOptions.newColumns && !edi.writeOptions.columns && typeof line === 'object' && !Array.isArray(line)) {\n Object.keys(line)\n .filter(function(column) { return edi.readOptions.columns.indexOf(column) === -1; })\n .forEach(function(column) { edi.readOptions.columns.push(column); });\n }\n\n transforming = false;\n }else{\n line = state.line;\n }\n if(state.count === 0 && edi.writeOptions.header === true){\n write(edi.writeOptions.columns || edi.readOptions.columns);\n }\n write(line);\n state.count++;\n state.line = [];\n state.lastC = '';\n }", "title": "" }, { "docid": "639e931d262454801f7c88fcd649d98a", "score": "0.42928123", "text": "function loadData() {\n var storageList = JSON.parse(localStorage.getItem(self.data.name));\n\n if (storageList) {\n if(storageList.length == 0 && self.data.name === ClusterConsoleConstants.LOCAL_STORAGE_DASHBOARD_PAGE_NAME) {\n self.setData(ClusterConsoleConstants.DASHBOARD_DEFAULT_WIDGETS);\n }\n else {\n self.setData(storageList);\n }\n }\n else if(self.data.name === ClusterConsoleConstants.LOCAL_STORAGE_DASHBOARD_PAGE_NAME) {\n self.setData(ClusterConsoleConstants.DASHBOARD_DEFAULT_WIDGETS);\n }\n }", "title": "" }, { "docid": "946dc08affe9d62a4207e60b98d4bb7f", "score": "0.4287513", "text": "reset() {\r\n this.save(this.default_data);\r\n this.cache = super.load();\r\n return this.cache;\r\n }", "title": "" }, { "docid": "3c895825e97cd2bc7bddd00da8f90698", "score": "0.42852807", "text": "revealAll() {\n this.#hiddenLevels.fill($f7b05997b0c3179b$export$f307752a90139b0e.#UNHIDDEN);\n this.#hiddenSize = 0;\n }", "title": "" }, { "docid": "24fbbd12e57cd0d724472774a6dabcc0", "score": "0.42830828", "text": "function displaySavedCalendar() {\n var savedCalendar = JSON.parse(localStorage.getItem(\"mealSchedule\"));\n if (savedCalendar !== null) {\n for (var i = 0; i < savedCalendar.length; i++) {\n var day = savedCalendar[i];\n $(\"#day-\" + day.name).text(day.text);\n $(\"#links-\" + day.name).empty().append(day.links);\n };\n };\n }", "title": "" }, { "docid": "4a8334ae14139a777d537d0634621c80", "score": "0.42824873", "text": "function restoreState(){\r\n\r\n\t//Clear current canvas\r\n\tvar row = document.getElementById(\"row\");\r\n\trow.removeChild(document.getElementById('canvas_container'));\r\n\tvar element = document.createElement('div');\r\n\telement.id = 'canvas_container';\r\n\tvar objBody = document.getElementById(\"row\");\r\n\tobjBody.appendChild(element);\r\n\t\r\n\t//Load\r\n\tvar tableListPresenter = new TableListPresenter([\r\n {\r\n name: '1. Person',\r\n columns: [\r\n 'id',\r\n 'name',\r\n 'fk_id_company',\r\n\t\t\t\t'fk_id_degree'\r\n ],\r\n\t\t\trelations: [2],\r\n\t\t\tx: 66,\r\n\t\t\ty: 171\r\n },\r\n {\r\n name: '2. Company',\r\n columns: [\r\n 'id',\r\n 'name',\r\n 'type',\r\n 'employees',\r\n 'average_salary',\r\n 'country',\r\n 'net_income'\r\n ],\r\n\t\t\trelations: [0, 2, 3],\r\n\t\t\tx: 400,\r\n\t\t\ty: 81\r\n },\r\n {\r\n name: '3. Degree',\r\n columns: [\r\n 'id',\r\n 'name',\r\n 'department'\r\n ],\r\n\t\t\trelations: [3],\r\n\t\t\tx: 239,\r\n\t\t\ty: 290\r\n },\r\n\t\t{\r\n name: '4. New',\r\n columns: [\r\n 'id',\r\n 'base',\r\n 'multiplier'\r\n ],\r\n\t\t\trelations: [],\r\n\t\t\tx: 696,\r\n\t\t\ty: 143\r\n }\r\n ]);\r\n\t\r\n\ttableListPresenter.draw(document.getElementById('canvas_container'));\r\n}", "title": "" }, { "docid": "bd62131601f0a322d7075a3474dafd9a", "score": "0.42763996", "text": "resetFolders(){\n // clear folder paths \n this._folderPaths = [];\n\n // update file\n return this.update();\n }", "title": "" }, { "docid": "4f800dc4893223c25de95d5807fafbfb", "score": "0.4275424", "text": "function displayFolder(folder) {\n\tif (folder[\"content\"] != null) {\n\t\t$(\"#displayTableBody\").empty(); // Empty Table first\n\t\t$(\"#displayTable\").css(\"display\", \"table\"); // Show Table\n\t\taddToTable(folder[\"content\"]);\n\t} else {\n\t\t$(\"#displayTable\").css(\"display\", \"none\");\n\t}\n\t$(\"#byFolderDisplay\").append(\"<div class='row folder-row'></div>\"); // add row to grid of folders\n\tfor (let attr in folder) { // iterate through JSON attributes\n\t\tif (folder.hasOwnProperty(attr) && attr != \"type\" && attr != \"content\" && attr != \"parent\") { // add folder to DOM\n\t\t\t$(\".folder-row\").append(\"\\\n\t\t\t\t<div class='folder-col col'>\\\n\t\t\t\t <img class='folderImage' src='folder.jpg' alt='folderImage'>\\\n\t\t\t\t <h3>\" + attr + \"</h3>\\\n\t\t\t\t</div>\"\n\t\t\t);\t\n\t\t}\n\t}\n\t\n\tRefreshButtonEventListener(folder); // Add event listener again\t(as dynamically created elements need event listener)\n}", "title": "" }, { "docid": "ee90910bbfbb00361d672b63936d6c6f", "score": "0.42719224", "text": "function saveState() {\n\tvar stackMaxPlusOne = 4;\n\tif(gameType == 'creator') {\n\t\tstackMaxPlusOne = 11;\n\t}\n\tstate = {\n\t\t'level': level,\n\t\t'dimensions': level.dimensions,\n\t\t'row': row,\n\t\t'col': col,\n\t\t'moves': moves,\n\t\t'tiles': tiles,\n\t\t'curColumnsRight': curColumnsRight,\n\t\t'curColumnsLeft': curColumnsLeft,\n\t\t'curRowsTop': curRowsTop,\n\t\t'curRowsBottom': curRowsBottom,\n\t\t'flippedColumnsRight': flippedColumnsRight,\n\t\t'flippedColumnsLeft': flippedColumnsLeft,\n\t\t'flippedRowsTop': flippedRowsTop,\n\t\t'flippedRowsBottom': flippedRowsBottom,\n\t\t'actionStack': actionStack.toString(),\n\t\t'matrix': []\n\t};\n\tfor(var i = 0; i < level.dimensions; i++) {\n\t\tstate.matrix[i] = matrix[i].slice();\n\t}\n\t// add as first element of the stack\n\t// note the first element of the stack matches the current state\n\tundoStack.unshift(state);\n\tif(undoStack.length > stackMaxPlusOne) {\n\t\tundoStack.splice(stackMaxPlusOne, 1);\n\t}\n}", "title": "" }, { "docid": "735e608633a10ec32ea11c01e251aab3", "score": "0.42564765", "text": "function restoreOriginal() {\n if (!editOriginal) { return; }\n vm.editObj.sensorTypeId = editOriginal.sensorTypeId;\n vm.editObj.operator = editOriginal.operator;\n vm.editObj.value = editOriginal.value;\n vm.editObj.message = editOriginal.message;\n }", "title": "" }, { "docid": "b3ef7bcaa7f4d0445b38cdebcbb94c96", "score": "0.42542082", "text": "function dataGridColumnRemoved(cm,columnIndex,hidden)\n{\n //We need to find out what column is being acted on.\n var columnNameFromHeader = Ext.getCmp(\"resultsGridPanel\").getColumnModel().getDataIndex(columnIndex);\n\n //Replace any spaces with an \"_\".\n columnNameFromHeader = columnNameFromHeader.replace(' ','_');\n\n //If the column is now hidden, remove it from list, otherwise add it back if it isn't there.\n if(hidden)\n {\n //Remove this column from our SearchJSON object.\n removeFromArray(columnNameFromHeader,GLOBAL.SearchJSON[\"GridColumnList\"]);\n }\n else\n {\n GLOBAL.SearchJSON[\"GridColumnList\"].push(columnNameFromHeader)\n }\n\n //Reload the title to the grid.\n GLOBAL.resultGridPanel.getStore().reload();\n GLOBAL.resultGridPanel.setTitle(createValuesString(GLOBAL.SearchJSON));\n}", "title": "" }, { "docid": "9456a8c3dd7961188f6c25669c7a1702", "score": "0.4248355", "text": "function restoreList() {\n resetList();\n saveList();\n refreshList();\n}", "title": "" }, { "docid": "ffb5ed6701e37a3a7de3f9b4732f558d", "score": "0.42456177", "text": "_onApplicationStoreChange (state) {\n this.setState({\n json: state.json,\n langs: state.langs,\n values: state.values,\n collapsed: state.collapsed,\n openscreen: state.openscreen,\n primarykeys: state.primarykeys,\n selectexport: state.selectexport\n });\n }", "title": "" }, { "docid": "77b0f61be733338fc16f7a0f4092fb95", "score": "0.42450944", "text": "reset() {\n if (this._params.isTermEditMode) {\n this._state.toTermMode(this._annotationData.relation.some)\n return\n }\n\n if (this._params.isBlockEditMode) {\n this._state.toBlockMode(this._annotationData.relation.some)\n return\n }\n\n if (this._params.isRelationEditMode) {\n this._state.toRelationMode()\n return\n }\n\n this._state.toViewMode(this._annotationData.relation.some)\n }", "title": "" }, { "docid": "28f29eeaba4d7190a91358ba189df63c", "score": "0.42444342", "text": "hideEditor(state) {\n state.rules = undefined;\n state.collectionID = undefined;\n state.loadedJoints = {};\n state.selectedJoints = [];\n state.suggestedArticulations = {};\n state.inVisualizationMode = false;\n }", "title": "" }, { "docid": "95594c7927ee10dc72f2035230197bb4", "score": "0.42375284", "text": "storeState(){\n if(this.storePath()){\n storeLocal(this.storePath(), this.state)\n }\n }", "title": "" }, { "docid": "ba87c7ce36e4a7d798b85272a35fc8b3", "score": "0.42306197", "text": "closeColumnsFromCurrent(){\n\t\tthis.closeColumnsFrom(this.state.currentColumn);\n\t}", "title": "" }, { "docid": "c58dd630efbd373b9865b6b0b23a233d", "score": "0.42269894", "text": "function folderReady(){\n $scope.groupEditForm = platformReportsService.getFolder($state.params.folder);\n\n if($scope.groupEditForm === undefined) return;\n\n _fallbackGroup = angular.copy($scope.groupEditForm);\n $scope.selectedRoles = $scope.groupEditForm.roles;\n setCurrenteIcon($scope.groupEditForm.icon);\n }", "title": "" }, { "docid": "905de3ed1d1f161703a6c8a4b0cc6b08", "score": "0.42266876", "text": "saveState() {\n const that = this;\n\n if (!that.id) {\n that.warn(that.localize('noId'));\n return;\n }\n\n //Save to LocalStorage\n window.localStorage.setItem('smartGanttChart' + that.id, JSON.stringify(that.getState()));\n }", "title": "" }, { "docid": "8a84428f3ba6265b60e2031fffb5e6dd", "score": "0.4224055", "text": "restoreTreeState () {\n const options = this.options;\n const $container = this.$container;\n const $active = $container.find('.' + options.activeClassName);\n const $lists = $active.parents('[' + options.instanceAttribute + '] ul, [' + options.instanceAttribute + ']');\n\n $lists.show();\n $lists.prev().addClass(options.toggledClassName);\n\n // Restore state\n const states = this.states;\n for (let id in states) {\n if (states[id]) {\n let $item = $container.find('[data-id=\"' + encodeURIComponent(id) + '\"]');\n $item.addClass(this.options.toggledClassName);\n $item.next('ul').show();\n }\n }\n // Restore toggled elements\n const $toggled = $container.find(options.toggledSelector);\n $toggled.addClass(options.toggledClassName);\n $toggled.next('ul').show();\n\n // Restore active element\n const categoryId = this.store.getState().categoryId;\n const $restoreActive = $container.find('[data-id=\"' + encodeURIComponent(categoryId) + '\"]');\n $active.removeClass(this.options.activeClassName);\n $restoreActive.addClass(this.options.activeClassName);\n\n // Enable drag and drop, file upload\n $container.find(options.itemSelector).each((index, item) => {\n this.setupItem($(item));\n });\n }", "title": "" }, { "docid": "bf4b18e1dbc07874bfe71004710b5edf", "score": "0.4223001", "text": "saveCurrentGridState() {\n const gridState = this.aureliaGrid.gridStateService.getCurrentGridState();\n console.log('Client sample, current Grid State:: ', gridState);\n localStorage[LOCAL_STORAGE_KEY] = JSON.stringify(gridState);\n }", "title": "" }, { "docid": "25bb06cde27fda288a4d79a234802ccb", "score": "0.42189077", "text": "function restoreState(){\t\t\t\n\t\t\tvar state = jQuery.parseQuery(parent.location.search);\n\t\t\tscope.day = state.day;\n\t\t\tscope.store = state.store;\n\t\t\tvar mapOptions = _.pick(state, ['showOrders', 'showDriverStops', 'showMaxSpeed', 'showReturn']);\n\t\t\t_.chain(mapOptions).keys().each(function(key){ mapOptions[key] = convertToBoolean(mapOptions[key]); });\n\t\t\t_.chain(scope.mapOptions).extend(mapOptions);\t\t\t\t\t\n\t\t\treturn state;\n\t\t}", "title": "" } ]
c4fd8a6d0816469e0f14487b3f852c7b
start the first FireTag in the array of tags, then repeat until disabled or destroyed
[ { "docid": "bb72a7f4f5b5a466b239ce6cc42ce6a1", "score": "0.5137115", "text": "function InitiateFire()\n{\n\tif(!started)\n\t\tyield WaitForSeconds(1.0);\n\n\tstarted = true;\n\t\n\twhile(true)\n\t{\n\t\tyield RunFire(0);\n\t\tyield WaitForSeconds(waitBeforeRepeating * BulletManager.use.timePerFrame);\n\t}\n}", "title": "" } ]
[ { "docid": "301946f48601cfea3b251768534c1356", "score": "0.54415613", "text": "startEventRandomly() {\n setInterval(() => {\n const maxNum = this.eventList.length;\n const eventID = Math.floor(Math.random() * maxNum);\n if (!this.eventList[eventID].active) this.startEvent(eventID);\n }, 20000);\n }", "title": "" }, { "docid": "726190ed5fc56b95beedbd8d9e467c77", "score": "0.5436154", "text": "enableItem (i) { this.toggDis(false, i); }", "title": "" }, { "docid": "5e5c66e9314f480008e7df2544d25d6c", "score": "0.5406922", "text": "function ProductTags(tagsid, freeinput) {\n if ($('#predefined-tags').length > 0) {\n var productDefinedTags = document.getElementById(\"predefined-tags\").value;\n productTags = productDefinedTags.split(',');\n\n\n var productTags = new Bloodhound({\n datumTokenizer: Bloodhound.tokenizers.whitespace,\n queryTokenizer: Bloodhound.tokenizers.whitespace,\n local: productTags\n });\n\n $('#' + tagsid).tagsinput({\n typeaheadjs: [{\n hint: true,\n highlight: true,\n minLength: 1\n },\n {\n name: 'productTags',\n source: productTags\n }],\n freeInput: freeinput,\n tagClass: 'badge',\n capitalize: function (item) {\n return item ? item.charAt(0).toUpperCase() + item.slice(1).toLowerCase() : item;\n }\n });\n\n\n $('#' + tagsid).on(\"beforeItemAdd\", function (e) {\n var name = e.item;\n var allow = true;\n $(this).prev().find(\".tag\").each(function (i, valor) {\n if ($(this).text().toLowerCase() == name.toString().toLowerCase()) {\n allow = false;\n return false;\n }\n })\n\n if (!allow) {\n console.log(\"repeat\");\n e.cancel = true;\n }\n });\n }\n}", "title": "" }, { "docid": "d71d9cad2a291c4fdfdcc95ac610a8a2", "score": "0.54031974", "text": "function RunFire(i) :IEnumerator\n{\n\tvar ft = fireTags[i];\n\tvar iw = new IndexWrapper();\n\t\n\tif(ft.actions.length == 0)\n\t\tFire(tform, ft.actions[iw.idx], ft.param, ft.prw);\n\telse\n\t{\n\t\tfor(iw.idx = 0;iw.idx < ft.actions.length; iw.idx++)\n\t\t{\n\t\t\tswitch(ft.actions[iw.idx].type)\n\t\t\t{\n\t\t\t\tcase(FireActionType.Wait):\n\t\t\t\t\tif(ft.actions[iw.idx].randomWait)\n\t\t\t\t\t\tvar waitT = Random.Range(ft.actions[iw.idx].waitTime.x, ft.actions[iw.idx].waitTime.y);\n\t\t\t\t\telse\n\t\t\t\t\t\twaitT = ft.actions[iw.idx].waitTime.x;\n\t\t\t\t\tif(ft.actions[iw.idx].rankWait)\n\t\t\t\t\t\twaitT += BulletManager.use.rank * ft.actions[iw.idx].waitTime.z;\n\t\t\t\t\twaitT *= BulletManager.use.timePerFrame;\n\t\t\t\t\tyield WaitForSeconds(waitT);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase(FireActionType.Fire):\n\t\t\t\t\tFire(tform, ft.actions[iw.idx], ft.param, ft.prw);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase(FireActionType.CallFireTag\t):\n\t\t\t\t\tvar idx = ft.actions[iw.idx].fireTagIndex - 1;\n\t\t\t\t\t\n\t\t\t\t\tif(ft.actions[iw.idx].passParam)\n\t\t\t\t\t\tfireTags[idx].param = Random.Range(ft.actions[iw.idx].paramRange.x, ft.actions[iw.idx].paramRange.y);\n\t\t\t\t\telse if(ft.actions[iw.idx].passPassedParam)\n\t\t\t\t\t\tfireTags[idx].param = ft.param;\n\t\t\t\t\t\n\t\t\t\t\tif(fireTags[idx].actions.length > 0)\n\t\t\t\t\t\tyield RunFire(idx);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase(FireActionType.StartRepeat\t):\n\t\t\t\t\tyield RunNestedFire(i, iw);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t}\n\t}\n}", "title": "" }, { "docid": "6475c06aa9cc4d838ab1a5cc7284986b", "score": "0.53719926", "text": "function processTags() {\n const tags = getTags();\n injectTags(tags);\n tagClickListener();\n}", "title": "" }, { "docid": "4ff2a9ecdc1d85e74b123117a0a38591", "score": "0.5345253", "text": "start() {\n if (_subscribers.length < 1 || _isRunning) return; // no elements or already running -> don't do anything\n _isRunning = true;\n _tick();\n }", "title": "" }, { "docid": "33f591524e4dd4223b6edf4b8c690d73", "score": "0.5258379", "text": "function initiate(){\n for(var i = 0; i < jobTags.length; i++){\n for(var j = 0; j < jobTags[i].children.length; j++)\n jobTags[i].children[j].addEventListener(\"click\", function(){\n document.querySelector(\".filter\").style.display = \"flex\"; // show the filter list div\n var jobProfile = this.textContent; \n clearJobLists(jobProfile); // function call\n var bool = true;\n filterTags.forEach(function(tag){\n if(jobProfile == tag)\n bool = false;\n });\n if(bool)\n addFilterTag(jobProfile); // function call\n });\n }\n}", "title": "" }, { "docid": "6726854fbca956fa4bf52c8f9dbffc16", "score": "0.52032775", "text": "function RunNestedFire(i, iw : IndexWrapper) : IEnumerator\n{\n\tvar ft = fireTags[i];\n\tvar startIndex = iw.idx;\n\tvar endIndex = 0;\n\t\n\tvar repeatC = ft.actions[iw.idx].repeatCount.x;\n\tif(ft.actions[iw.idx].rankRepeat)\n\t\trepeatC += ft.actions[iw.idx].repeatCount.y * BulletManager.use.rank;\n\trepeatC = Mathf.Floor(repeatC);\n\t\t\n\tiw.idx++;\n\n\tfor(var y = 0; y < repeatC; y++)\n\t{\n\t\twhile(ft.actions[iw.idx].type != 4)\n\t\t{\n\t\t\tswitch(ft.actions[iw.idx].type)\n\t\t\t{\n\t\t\t\tcase(FireActionType.Wait):\n\t\t\t\t\tif(ft.actions[iw.idx].randomWait)\n\t\t\t\t\t\tvar waitT = Random.Range(ft.actions[iw.idx].waitTime.x, ft.actions[iw.idx].waitTime.y);\n\t\t\t\t\telse\n\t\t\t\t\t\twaitT = ft.actions[iw.idx].waitTime.x;\n\t\t\t\t\tif(ft.actions[iw.idx].rankWait)\n\t\t\t\t\t\twaitT += BulletManager.use.rank * ft.actions[iw.idx].waitTime.z;\n\t\t\t\t\twaitT *= BulletManager.use.timePerFrame;\n\t\t\t\t\tyield WaitForSeconds(waitT);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase(FireActionType.Fire):\n\t\t\t\t\tFire(tform, ft.actions[iw.idx], ft.param, ft.prw);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase(FireActionType.CallFireTag\t):\n\t\t\t\t\tvar idx = ft.actions[iw.idx].fireTagIndex - 1;\n\t\t\t\t\t\n\t\t\t\t\tif(ft.actions[iw.idx].passParam)\n\t\t\t\t\t\tfireTags[idx].param = Random.Range(ft.actions[iw.idx].paramRange.x, ft.actions[iw.idx].paramRange.y);\n\t\t\t\t\telse if(ft.actions[iw.idx].passPassedParam)\n\t\t\t\t\t\tfireTags[idx].param = ft.param;\n\t\t\t\t\t\n\t\t\t\t\tif(fireTags[idx].actions.length > 0)\n\t\t\t\t\t\tyield RunFire(idx);\n\t\t\t\t\tbreak;\n\t\t\t\t\t\n\t\t\t\tcase(FireActionType.StartRepeat\t):\n\t\t\t\t\tyield RunNestedFire(i, iw);\n\t\t\t\t\tbreak;\n\t\t\t}\n\t\t\t\n\t\t\tiw.idx++;\n\t\t\n\t\t}\n\t\t\n\t\tendIndex = iw.idx;\n\t\tiw.idx = startIndex+1;\n\t}\n\t\n\tiw.idx = endIndex;\n}", "title": "" }, { "docid": "61cea5416f33b9cb1058a1bc62f297a0", "score": "0.51317734", "text": "syncTagsDisabledState() {\n if (this.tags) {\n this.tags.forEach((tag) => {\n tag.disabled = this._disabled;\n });\n }\n }", "title": "" }, { "docid": "2e3fcd49df0bedfc0e39718645e5fe31", "score": "0.51243573", "text": "function Fire2(){\n\n\t\tif(arrested){\n\t\t\tinactiveObj.Clear();\n\t\t\tarrested = false;\n\t\t\tfor(var g in GameObject.FindGameObjectsWithTag(\"Models\")){\n\n\t \t\tvar col = g.transform.GetChild(0).gameObject.GetComponent(TextMesh).color;\n\n\t \t\tif(col != Color.blue){\n\t \tg.SetActive(false);\t\n\t \tinactiveObj.push(g);\n\t }\n\t \t\t}\n\n\t\t}\n\t\telse{\n\t\t\tarrested = true;\n\t\t\tfor(var g in inactiveObj){\n\t\t\t\tg.SetActive(true);\n//\t\t\t\tFire3();\n//\t\t\t\tFire3();\n\t\t\t}\t\t\n\t\t}\n}", "title": "" }, { "docid": "1ef9f914f54ce2bba844c66999985db0", "score": "0.51018643", "text": "function randomSelection() {\r\n const timesRun = 30;\r\n\r\n const interval = setInterval(() => {\r\n\r\n const randomTag = randomTagPicker();\r\n tagHighlight(randomTag);\r\n\r\n setTimeout(() =>{\r\n\r\n tagUnHighlight(randomTag);\r\n\r\n }, 100);\r\n\r\n }, 100);\r\n\r\n setTimeout(() => {\r\n\r\n clearInterval(interval);\r\n\r\n setTimeout(() => {\r\n\r\n const randomTag = randomTagPicker();\r\n\r\n tagHighlight(randomTag);\r\n\r\n }, 100);\r\n\r\n }, timesRun * 100 );\r\n\r\n}", "title": "" }, { "docid": "e26b0c276c15af7185dcf13fec3b93b2", "score": "0.50879806", "text": "async function run() {\n await rAF(initialDelay);\n\n const initial = all.shift();\n initial.classList.remove('active');\n all.sort(() => Math.random() - 0.5);\n\n for (;;) {\n all[0].classList.add('active');\n await rAF(delay);\n\n all[0].classList.remove('active');\n all.push(all.shift());\n }\n}", "title": "" }, { "docid": "3f48840c12b0f0e6d70895eaa89504a8", "score": "0.50497967", "text": "function meet(){\n\tfor (var i=0;i<ghostArray.length;i++){\n\t\tif ((ghostArray[i].alive)&&((ghostArray[i].loc[0]==curPos[0])&&(ghostArray[i].loc[1]==curPos[1]))){\n\t\t\tif (this.strong){\n\t\t\t\tghostArray[i].alive=false;\n\t\t\t\tpageTimer[noOfTimer++]=setTimeout(\"ghostStart(\"+i+\")\",5000);\n\t\t\t\tghostInside++;\n\t\t\t\taudioNoLoop.src=\"eatGhost.wav\";\n\t\t\t}\n\t\t\telse {\n\t\t\t\tcheckGameOver();\n\t\t\t\t\n\t\t\t}\n\t\t\treturn true;\n\t\t}\n\t}\n\treturn false;\n}", "title": "" }, { "docid": "a0cf9ba46ecf36b260aee651a0f6c41f", "score": "0.5022384", "text": "function triggerMore(){\n if(!allCompleted()){\n let max = config.maxConcurrentRequests > avaiableQueue ? avaiableQueue : config.maxConcurrentRequests;\n for(let i=active.size; i < max; i++){\n triggerNext();\n }\n }\n}", "title": "" }, { "docid": "701198471f8d19f53f005f96b3ddb02c", "score": "0.50025177", "text": "function startPlay() {\n if (running) return;\n running = true;\n\n for (let i = 0; i < reels.length; i++) {\n const r = reels[i];\n const extra = Math.floor(Math.random() * 3);\n const target = r.position + 10 + i * 5 + extra;\n const time = 2500 + i * 600 + extra * 300;\n tweenTo(\n r,\n 'position',\n target,\n time,\n backout(0.5),\n null,\n i === reels.length - 1 ? reelsComplete : null,\n );\n }\n }", "title": "" }, { "docid": "3dd531bfa00a8af7326731c31e488f2a", "score": "0.50018495", "text": "disableItem (i) { this.toggDis(true, i); }", "title": "" }, { "docid": "956b548337aef2256092e54166a5b5f2", "score": "0.49741754", "text": "toogleLoop() {\n this.isLooped = !this.isLooped;\n }", "title": "" }, { "docid": "c637b617d0fa8ff26efbdc31ea4edd43", "score": "0.49518907", "text": "function evaluateTagFadeState(element) {\n var found = false;\n for (var i = 0; i < visibleArticles.length; i++) {\n if (visibleArticles[i].tags.indexOf(element.innerHTML) !== -1) {\n found = true;\n break;\n }\n }\n if (found) {\n element.classList.add('active');\n }\n }", "title": "" }, { "docid": "a95b12ef6b6f22429ddc98122c5dae9f", "score": "0.49508512", "text": "function allEnemiesFireAtWill() {\n //sorry Will!\n\n for (var i in assortedGameArrays.enemies) {\n var currentEnemy = assortedGameArrays.enemies[i];\n currentEnemy.gunCooldownTimer--;\n if (currentEnemy.gunCooldownTimer < 1) {\n new EnemyBullet(currentEnemy.xPosition, currentEnemy.yPosition, currentEnemy.type);\n currentEnemy.gunCooldownTimer = currentEnemy.gunCooldownTimerResetsTo;\n }\n }\n}", "title": "" }, { "docid": "f59311cb75cef7368077258dd7dac3b4", "score": "0.4925793", "text": "function addEventForEnabledTags () {\r\n for (let labelTag of Tag.getEnabledLabelTags()) {\r\n labelTag.addEventListener(\"keyup\", enterFilterByTag);\r\n }\r\n for (let inputTag of Tag.getEnabledInputTags()) {\r\n inputTag.addEventListener(\"click\", filterByTag);\r\n }\r\n}", "title": "" }, { "docid": "176a2523fb0fc92b0ae6d95afb66683e", "score": "0.49243292", "text": "async function Gr(t) {\n for (const e of t.Fr) await e(/* enabled= */ !1);\n}", "title": "" }, { "docid": "f14f672e9c6e6fe76d2a74f6f2756c8a", "score": "0.4919805", "text": "function mousePressed(){\n for(let i = 0; i < 100; i++){\n let f = new fireWork();\n fireWorks.push(f);\n }\n}", "title": "" }, { "docid": "7a05d8e3f3b4616cb2b11bd5233d3231", "score": "0.4903159", "text": "function Update () \n{\n\t//while the \"Fire1\" button is being held down\n\tif(Input.GetButton(\"Fire1\"))\n\t{\n\t\t//Start the DelayedShot method as a coroutine\n\t\tStartCoroutine(\"DelayedShot\",0.2);\n\t}\n}", "title": "" }, { "docid": "73e3ea8ccdb495f2138e473e92640639", "score": "0.4899665", "text": "function startLoop(){\n\n started = true;\n loop();\n}", "title": "" }, { "docid": "274558bdf48fd512ed52f026e53a4826", "score": "0.4894917", "text": "function checkTriggers() {\n var i = 0;\n while(i < triggers.length) {\n if(triggers[i].checkTrigger()) {\n triggers[i].behavior();\n if(triggers[i].oneTime) {\n triggers.splice(i, 1);\n continue;\n }\n }\n i++;\n }\n}", "title": "" }, { "docid": "6c075d5bf41080e4060a1b2a7a149de4", "score": "0.4885945", "text": "async startFoodLoops() {\n while (!this.gameOver) {\n let foodTime = 4000 + (Math.random() * 6000);\n await this.wait(foodTime)\n const ran = this.getRandomPosition();\n if (ran) {\n this.fruits.push(new Food(ran.x, ran.y));\n }\n }\n }", "title": "" }, { "docid": "985f4fb115039320ce5b7eac43bb793d", "score": "0.4883657", "text": "function oneAfterAnother() {\n var delay = 1;\n board.counter = 0;\n for (var i = 0; i < leds.length; i++) {\n var led = leds[i];\n\n board.wait(delay,function(){\n console.log(this.counter + \" on\")\n leds[this.counter].on();\n })\n board.wait(delay + 200,function(){\n console.log(this.counter + \" off\")\n leds[this.counter].off();\n this.counter = (this.counter + 1) % leds.length;\n })\n delay += 500;\n }\n }", "title": "" }, { "docid": "dad6c099ad8b3da120123081bf058324", "score": "0.4881959", "text": "function digest(){\n if (TASK_STACK.length>0){\n triggerStartLoop();\n }\n }", "title": "" }, { "docid": "acb21cb76785d1552f3e9c6ad9a490eb", "score": "0.48734352", "text": "function startStripTouchLoop(){\n\t\t\n\t\tif(g_temp.loop_active == true)\n\t\t\treturn(true);\n\t\t\t\n\t\tg_temp.loop_active = true;\n\t\tg_temp.handle = setInterval(storeTouchPortionData,10);\n\t}", "title": "" }, { "docid": "c546c609fbf89c8c9a8ffe0494f2fb41", "score": "0.48449394", "text": "function loop() {\n var humedad = Medir_Humedad();\n \n for (var x in sensorStates){\n if( isInStateRange(humedad, sensorStates[x]) ){\n prenderLed(x);\n doAction(sensorStates[x].triggersActuatorState, \"auto\");\n }\n }\n }", "title": "" }, { "docid": "873571de6b6ac4ffd9ae3b43f58cc43e", "score": "0.48413223", "text": "start() {\r\n let indexes = this._lives[0]\r\n for (var i = 0; i < indexes; i++) {\r\n this._parts[i].classList = 'pulse'\r\n }\r\n }", "title": "" }, { "docid": "a7b94d0836468b73a36c11d262583c1b", "score": "0.48316017", "text": "function playLoop(markers) {\n\n // Click a random marker once without delay\n markers[Math.floor(Math.random() * markers.length)].fire(\"click\")\n\n // Repeat every 20 seconds or so\n playInterval = setInterval(function () {\n let randomMarker = markers[Math.floor(Math.random() * markers.length)];\n randomMarker.fire(\"click\");\n\n }, 22000);\n\n}", "title": "" }, { "docid": "395c53964849cd67d0bd4944de36c920", "score": "0.48161575", "text": "function fastPlay() {\r\n document.querySelector(\"h1\").innerHTML = \"Game In Progress...\";\r\n document.querySelector(\"h1\").style.color = \"#4ECCF3\";\r\n\r\n x[1].disabled = true;\r\n for (i = 0; i <= 9; i++) {\r\n\r\n (function(i) {\r\n setTimeout(function() {\r\n play(i);\r\n }, 300 * i);\r\n })(i);\r\n }\r\n\r\n}", "title": "" }, { "docid": "e2895fc8fddce9542260e82fab612a3c", "score": "0.4806891", "text": "function start() {\n processArray();\n $(\"start\").disabled = true;\n $(\"stop\").disabled = false;\n changeTime();\n }", "title": "" }, { "docid": "08a773ce0046cc49f4d5f61812593ef4", "score": "0.4798835", "text": "function initBlockStatus(){\n for(var i=1;i<=9;i++) {\n $(\"#ttt\"+i).data(\"data-blocked\", false);\n }\n}", "title": "" }, { "docid": "d700b691ce50f002d200307a9d802baa", "score": "0.47982076", "text": "function startNewTag() {\n state = 1 /* TagOpen */;\n currentTag = new CurrentTag({ idx: charIdx });\n }", "title": "" }, { "docid": "7ceb5743d373fa38f0684a6931a9df8c", "score": "0.4787079", "text": "first() {\n if (this.count >= 1) {\n this.__fire(1);\n }\n }", "title": "" }, { "docid": "cc84d6e7caf465e8fa48e8174997bae9", "score": "0.47863784", "text": "function toggleTag(tagName, tagId) {\n\n if (selectedTagArr.includes(tagName)) {\n selectedTagArr.splice(selectedTagArr.indexOf(tagName), 1)\n } else {\n selectedTagArr.push(tagName);\n }\n\n document.getElementById(\"all_tag\").className = \"tag All\"\n document.getElementById(tagId).classList.toggle(\"active\")\n\n // console.log(selectedTagArr)\n\n if (selectedTagArr.length == 0) {\n selectAll();\n } else {\n refreshTable()\n }\n\n}", "title": "" }, { "docid": "300b40188cd60719936c9949a7fba852", "score": "0.47836906", "text": "listenToTagsFocus() {\n this.tagFocusSubscription = this.tagFocusChanges\n .subscribe((event) => {\n const tagIndex = this.tags.toArray().indexOf(event.tag);\n if (this.isValidIndex(tagIndex)) {\n this.keyManager.updateActiveItem(tagIndex);\n }\n this.stateChanges.next();\n });\n this.tagBlurSubscription = this.tagBlurChanges\n .subscribe(() => {\n this.blur();\n this.stateChanges.next();\n });\n }", "title": "" }, { "docid": "171dd893128377e1b8a256f0980ba1b4", "score": "0.47823608", "text": "start() {\n this.running = true;\n this.cancel();\n this.scheduleNext();\n }", "title": "" }, { "docid": "c92153850116ad8fab6660682316b7b2", "score": "0.4781636", "text": "function startGame() {\n start.disabled = true;\n status.innerText = \"Starting In ...\";\n timer = setInterval(countDown, 1000);\n for (let move of playerMoves) {\n move.addEventListener(\"click\", playerMove);\n move.disabled = true;\n }\n compMove.disabled = true;\n}", "title": "" }, { "docid": "c8f2a3f41eef73e1dc71710132e09520", "score": "0.4778419", "text": "function initCameraTags() {\n for (var i = 0; i < cameraCount; i++) {\n //Desktop camera tags\n var camera = $('<button></button>')\n .addClass('btn')\n .addClass('cameraOption')\n .attr('data-camera', i);\n\n if (i == 0) {\n camera.addClass('active');\n }\n\n var cameraImage = $('<img>')\n .addClass('cameraPhoto');\n\n cameraImage.appendTo(camera);\n\n camera.appendTo(cameraContainerSelect);\n\n camera.on('click', function () {\n $(this).addClass('active').siblings().removeClass('active');\n activeCamera = $(this).attr('data-camera');\n mainImgSelect.show();\n staticImgSelect.hide();\n updatePageAssets();\n });\n\n //Mobile carousel camera tags\n camera = $('<img>')\n .attr('data-camera', i);\n\n camera.on('click', function () {\n activeCamera = $(this).attr('data-camera');\n updatePageAssets();\n });\n\n camera.appendTo(mobileCarouselContainerSelect);\n }\n}", "title": "" }, { "docid": "26bcd871ff301f180daa21d8f4816082", "score": "0.47779062", "text": "function OnEnable()\n{\n\tif(started)\n\t\tInitiateFire();\n}", "title": "" }, { "docid": "bc8c41ead3c13b0ac8c21ade697339c3", "score": "0.47692582", "text": "function startLoop()\n {\n if(geoPos.isReady() == false)\n {\n console.log(\"geoLoc not ready Yet\");\n $timeout(function(){\n startLoop();\n },1000);\n }\n else\n {\n getPeople();\n }\n }", "title": "" }, { "docid": "689b6ee81275e244b452ad9e77505d2f", "score": "0.47278807", "text": "function repeater(){\n var self = this,\n wait = 2000, // time to wait before processing\n deviation = 80, // (milliseconds) max deviation from mean\n timestamps = [],\n timeout, \n paused;\n\n // api code\n self.pause = function(){\n paused = true;\n return self;\n }\n self.resume = function(){\n paused = false;\n return self;\n }\n self.when = function(n, fn){ \n bean.on(self, 'found', function(_n, mean){\n if(n == _n) fn.call(self, mean);\n });\n return self;\n }\n\n bean.on(document.body, 'keydown', handler)\n bean.on(window, 'touchstart', handler)\n \n return self;\n\n function handler(e){\n if(paused) return;\n\n timestamps.unshift(+new Date);\n clearTimeout(timeout);\n timeout = setTimeout(process, wait);\n\n // play a blank sound for iOS to start audio\n if(window.play){\n window.play();\n }\n }\n\n //check which handlers should be fired\n function process(){\n\n // find the gaps between each of the timestamps\n var gaps = [];\n for(var i = 1; i < timestamps.length; i++){\n gaps[i-1] = timestamps[i-1] - timestamps[i]\n }\n\n if(!gaps.length){\n // console.log(\"early exit\")\n return found(1);\n }\n \n // go through the gaps until we see a higher deviation\n for(var i = 1; i < gaps.length; i++){\n var s = stats(gaps.slice(0,i));\n if(s.sd > deviation){\n // console.log(\"loop\", gaps.slice(0,i), gaps);\n return found(i);\n }\n }\n\n // console.log('all cool')\n found(timestamps.length)\n\n }\n\n function found(n){\n\n // console.log(\">>>>\", n);\n\n var s = stats(timestamps.slice(0,n));\n\n bean.fire(self, 'found', [n,s.mean]);\n \n timestamps = [];\n\n }\n\n function stats(values){\n\n var count = values.length,\n mean = values.reduce(sum) / count,\n sd = Math.sqrt(\n values\n .map(diff(mean))\n .map(square)\n .reduce(sum) / count\n )\n\n return {\n count: count,\n mean: mean,\n sd: sd\n }\n\n function sum(a,b){\n return a + b;\n }\n\n function square(v){\n return Math.pow(v, 2)\n }\n\n function diff(a){\n return function(b){\n return a - b;\n }\n }\n }\n}", "title": "" }, { "docid": "37db36b14687aa42c28cbf7a51d7644b", "score": "0.47221485", "text": "start() {\n if (this._isStopped) {\n this._inst[this._listenersArray].push(this._obj);\n this._isStopped = false;\n }\n }", "title": "" }, { "docid": "336731c25c5602908dfd151806f87446", "score": "0.4721051", "text": "function startInterval(){\n for(i = 0; i < sliderWrap.length; i++){\n var slider = sliders[sliderWrap[i].id];\n\n slider.current == slider.nav.length ? slider.current = 1 : slider.current++;\n\n fillColor(slider.nav[slider.current-1], slider.nav);\n smoothScroll(slider.slider, slider.current, slider.width);\n }\n }", "title": "" }, { "docid": "f947aa846cedb1fb6bb9ab6ba3cc77f5", "score": "0.47201404", "text": "function timerFunction(){\n for(var i = 0; i < timerObjArray.length; i++){\n if(!timerObjArray[i].isStopped){\n timerObjArray[i].secs -= 1;\n //console.log($(timerObjArray[i].ref).text());\n $(timerObjArray[i].ref).text(showTimer(timerObjArray[i].secs));\n if(timerObjArray[i].secs <= 0){\n timerObjArray[i].isStopped=true;\n displayAlert(timerObjArray[i]);\n }\n console.log(timerObjArray[i].isStopped);\n }\n }\n }", "title": "" }, { "docid": "adaead0ad2fb98f947b5ff20b5a87920", "score": "0.4714474", "text": "function startButtons(){\n\tstart.disabled = true;\n\tstop.disabled = false;\n}", "title": "" }, { "docid": "bf76075b990246edd2b05908f7fa9985", "score": "0.47101638", "text": "function studentAI() {\n\n normalInterval = setInterval(function () {\n var choice = Math.floor(Math.random() * (frontStudents.length))\n while (!frontStudents[choice].alive) {\n choice = Math.floor(Math.random() * (frontStudents.length))\n }\n //console.log(frontStudents);\n //console.log('Chose student: ' + choice);\n //console.log('Selected student number: ' + choice);\n frontStudents[choice].fire();\n //console.log('Firing.')\n }, 2000)\n\n}", "title": "" }, { "docid": "45da6662a59921e6979a95cf5fd2dcd7", "score": "0.47035295", "text": "function touchStarted() {\n\n for (var i = 0; i < 10; i++) {\n var s = createSprite(random(0, totalWidth), random(0, totalHeight), 30, 30);\n s.velocity.x = random(-5, 5);\n s.velocity.y = random(-5, 5);\n s.scale = random(0.5, 1);\n s.mass = s.scale;\n s.count = 0;\n s.restitution = 1;\n cuadrados.add(s);\n }\n}", "title": "" }, { "docid": "c20077c899cf3c13045c44b781de4778", "score": "0.47015157", "text": "function runMe(){\n for (var i = 1; i <= 54; i++) {\n\tcreateEvent(i-1, links[i-1]);\n }\n}", "title": "" }, { "docid": "ed59d69d1b13b114228e58ce606168b1", "score": "0.46961188", "text": "start() {\n const ran = this.getRandomPosition();\n this.fruits = [new Food(ran.x, ran.y)];\n this.startLoops();\n }", "title": "" }, { "docid": "1f55c285d83b8f3476e3ab2f0f601075", "score": "0.46883097", "text": "function start() {\n va.start.addEventListener('click', function() {\n if(stateToggle() == 'on') {\n \n // clear timer before starting\n clearTimeout(va.timer);\n \n // reset counter before starting\n va.count.level = 1;\n \n // empty random array\n va.random_seq = [];\n randomTermFn();\n // wait a second!\n setTimeout(function() {\n // start playing\n play();\n }, 500);\n\n }\n else {\n clearTimeout(va.timer);\n }\n });\n}", "title": "" }, { "docid": "0ba7816e6b78a37df306994049fb2dda", "score": "0.46869603", "text": "function fire(ev)\n{\t\n\tconsole.log(\"cake\");\n\tx = \"NULL\"; \n\ty = \"NULL\";\n\n\tfired++;\n\tif(fired >= 100)\n\t{\n\t\tlocalStorage.gunNut = true;\n\t}\n\tfireSound.play();\n\t\t\n\tvar bullet = new bulletObj(x, y);\n\tbullets.push(bullet);\n}", "title": "" }, { "docid": "7b913b4f1056832773bfc8c0d92224db", "score": "0.46849304", "text": "parseTags() {\n for (var i=0;i<AllData.length;i++) {\n try { for (var j=0;j<AllData[i].Tags.length;j++) {\n var yy = this.tagsonly.findIndex(e=>e===AllData[i].Tags[j])\n if (yy<0) \n {this.tags.push({\"tag\":AllData[i].Tags[j], \"on\":true, \"cnt\":0, \"seen\":0})\n this.tagsonly.push(AllData[i].Tags[j]) } \n else {\n this.tags[yy].cnt = this.tags[yy].cnt + 1\n try {if (AllData[i].Status.visited) this.tags[yy].seen = this.tags[yy].seen+1} catch{}}\n }\n }\n catch {}\n }\n }", "title": "" }, { "docid": "27ed396a0143a759dab59c8518c3072c", "score": "0.46815947", "text": "function start() {\n run = true;\n forwards = true;\n skateSkills()\n}", "title": "" }, { "docid": "43af600da9d49aa7272eca4d4c952132", "score": "0.46757084", "text": "function beginSequence() {\n if (onOff) {\n $(\"#count\").html(count);\n random = Math.floor(Math.random() * 4);\n sequenceArr.push(buttons[random]);\n } \n else {\n count = 0;\n $(\"#count\").html(\"\");\n sequenceArr = [];\n playerSeqArr = [];\n return;\n }\n set = setInterval(playSequence, 1000);\n }", "title": "" }, { "docid": "b2ff394ee0b7a2704fdb41a93162b9ce", "score": "0.4672515", "text": "async function processArray(array) {\n for(let i = 0; i < array.length; i++){\n switch(array[i]) {\n case '':\n await delay(500)\n break;\n default:\n await highlightedKey(array[i], 500);\n break;\n }\n }\n }", "title": "" }, { "docid": "b6a2106bc93727941ef7e266f13f5441", "score": "0.46721587", "text": "function enableElements(elements) {\n\tfor (var i=0; i<elements.length; i++) {\n \telements[i].disabled = false;\n\t}\n}", "title": "" }, { "docid": "df854445b3a1fc2d4838f02bc3e2b134", "score": "0.46715426", "text": "function SoundPileStart() {\n var self = this;\n this.listSound = [];\n this.currentAudio = 0;\n\n this.play = function() {\n if (!soundEnabled) {\n return;\n }\n \n if (self.listSound[self.currentAudio - 1])\n self.listSound[self.currentAudio - 1].currentTime = 0;\n \n self.listSound[self.currentAudio].play();\n self.currentAudio = (self.currentAudio + 1) % self.listSound.length;\n }\n\n for(var i = 0; i < 10; i++) {\n var s = new Audio();\n s.src = 'app/assets/sound/click' + extSound;\n\n this.listSound.push(s);\n }\n }", "title": "" }, { "docid": "bb7e963f16d290aa42613a1b00002d7b", "score": "0.4668627", "text": "function start() {\n //console.log(\"started!\");\n document.getElementById(\"note\").remove();\n document.getElementById(\"button1\").disabled = false;\n document.getElementById(\"button2\").disabled = false;\n document.getElementById(\"startBtn\").disabled = true;\n reset();\n pollUser(items[0], randOpponent(items[0]));\n}", "title": "" }, { "docid": "ffea96ca873bd8b79f1783fe63b10769", "score": "0.4665254", "text": "function startGameAbility(){\n\t\t//Allows return if an interupt is called\n\t\tif( playerLoopIndex > players.length ){\n\t\t\tplayerLoopIndex = 0;\t\t\t\n\t\t} else {\n\t\t\tplayerLoopIndex++;\n\t\t}\n\t\t\t\n\t\tfor( ; playerLoopIndex < players.length; playerLoopIndex++ ){\n\t\t\tif( players[playerLoopIndex].startGameAbility() ) return true;\n\t\t}\n\t\t\n\t\tequipPhase = true;\n\t\tequipPlay( -1 );\n\t}", "title": "" }, { "docid": "7091f930a768bf3af1b5922b5e0ba4a1", "score": "0.46576238", "text": "function startMultiFingerRelease() {\n\t\t\tpreviousTouchEndTime = getTimeStamp();\n\t\t\tpreviousTouchFingerCount = event.touches.length+1;\n\t\t}", "title": "" }, { "docid": "ba7e7a7766472de0e6ff9f2c58fe1edd", "score": "0.4656977", "text": "function disableInput(index){\n\t\t\twhile(index < InputTagArr.length - 1){\n\t\t\t\t$(\"#\" + InputTagArr[index]).prop(\"disabled\", true);\n\t\t\t\tindex++;\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "24ee96d57cddb3f5e1a82bc4398015bc", "score": "0.46489528", "text": "function idalloc() {\n for (let i = 0; i < tags.length; i++) {\n tagid.push([tags[i].name, tags[i].id]);\n\n //Showing available tags\n document.getElementById(\"available-tags\").innerHTML += \"<span class='showtag'>\" + tags[i].name + \"</span>\";\n }\n}", "title": "" }, { "docid": "05ca37fd804bb34b67012d58a0a0eab6", "score": "0.4646591", "text": "async function hasTag(browser, page, isSingle, tag){\n\t\n}", "title": "" }, { "docid": "1d2ea1591444ee15176617b4cf7d1c4c", "score": "0.4639513", "text": "function playSequence(arr) {\n\t\tif (gameOn && isPlaying) {\n\t\t\t//console.log('playSequence started');\n\t\t\tvar i = 0;\n\t\t\tdelay = setInterval(function() {\n\t\t\t\tshowLights(arr[i]);\n\n\t\t\t\ti++;\n\t\t\t\tif (i >= arr.length) {\n\t\t\t\t\tclearInterval(delay);\n\t\t\t\t}\n\t\t\t}, 1000); \n\t\t}\t\n\t}", "title": "" }, { "docid": "1de2c0ff95c10091c2cf0712886f7b81", "score": "0.46391192", "text": "explode() {\n\n\t\tthis.time = 0.0;\n\t\tthis.active = true;\n\t\tthis.uniforms.get(\"active\").value = true;\n\n\t}", "title": "" }, { "docid": "9e8a3937fa4e578092968771cc0f2312", "score": "0.46368986", "text": "start() {\n this.isRunning = true;\n\n // Don't bother evaluating the loop if there are no items that can start\n if (this.isEmpty) { return; }\n\n // The maximum number of consumers is either the maximum concurrent\n // consumers option, or if smaller, the number of items\n const numberOfItems = this._unprocessed.length;\n const concurrent = this.options.concurrent - this.activeConsumerCount;\n for (let toStart = Math.min(concurrent, numberOfItems); toStart > 0; toStart -= 1) {\n this._consume();\n }\n }", "title": "" }, { "docid": "693702b55d5492077b4aa944f2082c97", "score": "0.46319616", "text": "function check_before_wait_end_reaction(){\n show_selector=0;\n show_buttons=0;\n show_icons=0;\n show_cursors=0;\n allow_movement_mouse=0;\n cam_mode=\"follow_reaction\";\n keep_inside_character=0;\n mouse_mode=\"none\";\n next_game_phase=\"init_next_player\";\n game_phase=\"wait_end_reaction\";\n for(pos=0;pos<particles.length;pos++) {\n if ((particles[pos].alive==1)&&(particles[pos].properties.type==\"dynamite\")) {\n particles[pos].alive=0;\n particles[pos].action=\"dead\";\n xx=particles[pos].x;\n yy=particles[pos].y;\n x=xx*zoom+xisland;\n y=yy*zoom+yisland;\n do_explosion(x,y,400);\n }\n }\n }", "title": "" }, { "docid": "4321d7998804bd69cbc093f782e6e4f1", "score": "0.4629006", "text": "function runClicks(){\n for(var i=clicks.length-1; i>=0; i--){\n clicks[i].show();\n if(!clicks[i].update()) clicks.splice(i,1);\n }\n}", "title": "" }, { "docid": "5305ba32f488bcbf2d938c7f0d7c2d3d", "score": "0.46245927", "text": "function start() {\n started = true;\n loop();\n}", "title": "" }, { "docid": "73ad6fdbb61b9b24343a8b7c2a3ffb61", "score": "0.4623195", "text": "function DelayedShot(delay:float)\n{\n\n\t//display how many bullets were shot\n\tDebug.Log(counter);\n\t//increase the number of fired bullets\n\tcounter++;\n\t//Play the fire audio from audio source\n\tGetComponent(AudioSource).Play();\n\t//wait for the time defined at the delay parameter\n\tyield new WaitForSeconds(delay);\n\t//Stop this coroutine\n\tStopCoroutine(\"DelayedShot\");\n}", "title": "" }, { "docid": "a2f423c28a85a99836342fd4b824d5aa", "score": "0.4622306", "text": "function startPiLoop() {\n db.collection('piConnection').doc('loopAvatars').set({\n isLooping: true\n })\n}", "title": "" }, { "docid": "0f8eb1ab0a0f555838844a9ca70ac8e5", "score": "0.46191844", "text": "function startPlay() {\n if (running) return;\n running = true;\n\n for (let i = 0; i < reels.length; i++) {\n const r = reels[i];\n const extra = 3;\n const target = r.position + 10 + i * 5 + extra;\n const time = 2500 + i * 600 + extra * 600;\n const tweenItem = tweenTo(\n r,\n \"position\",\n target,\n time,\n backout(0.5),\n null,\n i === reels.length - 1 ? reelsComplete : null\n );\n tweening.push(tweenItem);\n }\n showFPS();\n }", "title": "" }, { "docid": "47d92d0379e876362bac341b86c0f3d9", "score": "0.46178752", "text": "function runSequence() {\n highestScore();\n //timeout set up so that each ligth will go in sequence rather than lighting up together\n setTimeout(function() {\n lightUp(gameSequence.sequence[gameSequence.lighted]);\n gameSequence.lighted++;\n //keep track of how many have been lighted in sequence if less than total it runs function again\n if (gameSequence.lighted < gameSequence.sequence.length) {\n runSequence();\n //if the sequence has finished this starts the listening function\n } else {\n gameSequence.lighted = 0;\n setTimeout(function() {\n if (gameSequence.hard === true) {\n hardMode();\n }\n clickListener();\n }, 500);\n }\n }, gameSequence.seqSpeed);\n }", "title": "" }, { "docid": "accbbff64ce40b3c8a6d37c990ddc361", "score": "0.4615406", "text": "function update_tags() {\n update_room_tags();\n update_feature_tags();\n}", "title": "" }, { "docid": "136cb38d167885ad685856de18f2c3d2", "score": "0.46123978", "text": "function tagsAddStartUp() {\n tagCollection = \"\";\n //load all available tags for the comment\n for (var j = 0; j < currentCourse.feedback[i].exam.length; j++) {\n if (currentCourse.feedback[i].exam[j].status == true) {\n tagCollection += ('<div class=\"chip listView\"><div class=\"chip-media bg-blue\"><i class=\"fa fa-book\"></i></div><div class=\"chip-label\"><a href=\"#\" class=\"link color-black\">' + currentCourse.feedback[i].exam[j].name + '</a></div></div>');\n }\n };\n for (var j = 0; j < currentCourse.feedback[i].positive.length; j++) {\n if (currentCourse.feedback[i].positive[j].status == true) {\n tagCollection += ('<div class=\"chip listView\"><div class=\"chip-media bg-green\"><i class=\"fa fa-plus\"></i></div><div class=\"chip-label\"><a href=\"#\" class=\"link color-black\">' + currentCourse.feedback[i].positive[j].name + '</a></div></div>');\n }\n };\n for (var j = 0; j < currentCourse.feedback[i].negative.length; j++) {\n if (currentCourse.feedback[i].negative[j].status == true) {\n tagCollection += ('<div class=\"chip listView\"><div class=\"chip-media bg-red\"><i class=\"fa fa-minus\"></i></div><div class=\"chip-label\"><a href=\"#\" class=\"link color-black\">' + currentCourse.feedback[i].negative[j].name + '</a></div></div>');\n }\n }\n if (typeof tagCollection == 'undefined') {\n return \"\"\n }\n return tagCollection;\n}", "title": "" }, { "docid": "da9b9b432e38618900f67e81c7414a2a", "score": "0.46026114", "text": "fire() {\n if (this.beam && !this.onCD) {\n this.frame = numFrames;\n // fire sounds\n let reload = new Beam(this.x + (PADDLE.width + 1) / 3, this.y);\n beams.push(reload);\n this.onCD = true;\n }\n }", "title": "" }, { "docid": "8ce0bb8e05b4e8482ea5d5a981c64597", "score": "0.45993528", "text": "play() {\n this.#envelopes.forEach((envelope) => envelope.triggerAttack());\n }", "title": "" }, { "docid": "401c36a65d5d3c60bcb20f3af1454ca9", "score": "0.4599289", "text": "function first () {\n // post-increment and assert we are the first called\n t.equal(listenersTriggered++, 0, 'first is called first')\n }", "title": "" }, { "docid": "23e1faed245ed80b65f6812410cc3051", "score": "0.45942247", "text": "function makeFireWork(){\n for(let i = fireWorks.length - 1; i >= 0; i--){\n fireWorks[i].move();\n fireWorks[i].show();\n if(fireWorks[i].alpha === 1){\n fireWorks.splice(i, 1);\n }\n }\n}", "title": "" }, { "docid": "40a748c113849f7200e1ffd12619d7b6", "score": "0.45917013", "text": "runNotify() {\n Utils.logDebug(\"Notification happend in the system.\");\n\n for (let bridgeid in this.hue.instances) {\n if (!this.hue.instances[bridgeid].isConnected()) {\n continue;\n }\n\n if (this._notificationQueues[bridgeid] === undefined) {\n this._notificationQueues[bridgeid] = new Queue.Queue(Queue.handlerType.TIMED);\n }\n\n if (this._notificationQueues[bridgeid].getQueueLength() === 0 &&\n ! this._waitingNotification[bridgeid]) {\n\n this._waitingNotification[bridgeid] = true;\n this.hue.instances[bridgeid].getLights();\n } else {\n this.queueNotify(bridgeid);\n }\n }\n }", "title": "" }, { "docid": "4fe793fa0358544196be5e9e87279d65", "score": "0.45813105", "text": "function popolate(num) {\n for (var i = 0; i < num; i++) {\n setTimeout(function(x) {\n return function() {\n // Add particle\n particles.push(new Particle(canvas))\n };\n }(i), frequency * i);\n }\n return particles.length\n }", "title": "" }, { "docid": "dd7220138ab0abaf937cb9324d5b5545", "score": "0.45804474", "text": "function listenForceCycle() {\n ReSpeakerMicArrayHID.setLedOff();\n console.log(\"LISTENING mode, LEDs activated based FORCED direction\");\n for (var dir = 0; dir < 255; dir++) {\n console.log(dir);\n ReSpeakerMicArrayHID.setListeningForce(dir);\n sleep.msleep(500); // sleep for 5000 msec\n };\n console.log(\"All OFF\");\n ReSpeakerMicArrayHID.setLedOff();\n}", "title": "" }, { "docid": "5f36eeafa61791d392a46e2ef0a1ae12", "score": "0.45760256", "text": "function hook_event_started() {\n\trunning = true;\n}", "title": "" }, { "docid": "c1bf47571afebc3a80802f2c889c0f1d", "score": "0.4572891", "text": "start() {\n watches = [BTN1, BTN2, BTN3].map(function(button) {\n setWatch(\n function() {\n buttons.emit('press', { button })\n },\n button,\n { repeat: true, edge: 'rising' }\n )\n })\n }", "title": "" }, { "docid": "8aecef7841a06c0003cdfc7bb8058220", "score": "0.4568636", "text": "startRun() {\n\t\tlet obj = {\n\t\t\trun: true\n\t\t};\n\n\t\tif(this.ele.div.offsetWidth < this.ele.span.offsetWidth)\n\t\t\tobj['active'] = true;\n\n\t\tthis.setState(() => (obj));\n\t}", "title": "" }, { "docid": "ebbba21a082569dcf32a1b6a5ca3b8b0", "score": "0.45650068", "text": "function loopFunction () {\n \t if (i < len-1) {\n \t i++;\n \t diff=timeDiff(recData.jsonArray[i].timeStamp,recData.jsonArray[i-1].timeStamp);\n \t replicateEvent(i);\n \t timerLoop = setTimeout(loopFunction,diff);\n \t }\n \t }", "title": "" }, { "docid": "d29cd39f47b3178e7d289d96a7312fec", "score": "0.45646158", "text": "function updateTags() {\n elem.importTags(scope.tags.join(','));\n $('.tag').draggable({\n helper: \"clone\"\n });\n ////console.log(\"updating tags\");\n ////console.log(scope.tags);\n }", "title": "" }, { "docid": "69fde082d414522aea1cfe1710e6d44b", "score": "0.4563423", "text": "function onTick(fade) {\n // getting each span tag\n // if (fade === 'add') {\n const span = text.querySelectorAll('span')[char];\n span.classList.add('fade');\n char++;\n // }\n // else {\n // const span = text.querySelectorAll('span')[char];\n // span.classList.remove('fade');\n // char++;\n // }\n\n if (char === splitText.length) {\n complete();\n return;\n }\n}", "title": "" }, { "docid": "92012b1bfea9a509e23e1d1a77ad97e9", "score": "0.45629227", "text": "function script_nextingInLoop() {\n let state = { run: false };\n scriptStates.push(state);\n\n const keydowns$ = fromEvent(document, 'keydown').pipe(filter(e => e.keyCode === actionKeyCode));\n const keyups$ = fromEvent(document, 'keyup').pipe(filter(e => e.keyCode === actionKeyCode));\n const activityStart$ = merge(keydowns$, keyups$, rxjs.of({type: 'joker'})) // add a single emission observable for bufferCount initialization\n .pipe(pluck('type'), // all we need is the event type\n distinctUntilChanged(), // joker down down down up down down up ---> joker down up down up\n bufferCount(2)); // j d u d u d u d ---> [j,d] [u,d] [u,d] [u,d]\n const activityEnd$ = keyups$;\n\n let fire$ = new Subject();\n // const fireSub = fire$.pipe(take(100), observeOn(async))\n const firesub = fire$.pipe(observeOn(async))\n .subscribe(() => {\n // console.log('observed');\n f2();\n });\n subscriptions.push(firesub);\n\n function f1() {\n // console.log('fire: nexting');\n // debugger;\n fire$.next();\n // Promise.resolve().then(()=>console.log('stack empty'))\n }\n function f2() {\n if (state.run) {\n // console.log('updating text');\n updateText();\n f1();\n } else return; \n }\n\n const sub1 = activityStart$.subscribe((e) => {\n state.run = true;\n console.log('started');\n f1(); // start firing\n\n // for testing\n // requestAnimationFrame(() => {\n // console.log('========== painting 1');\n // requestAnimationFrame(() => {\n // console.log('========== painting 2');\n // })\n // });\n \n });\n subscriptions.push(sub1);\n\n const sub2 = keyups$.subscribe((e) => {\n state.run = false;\n console.log('stopped');\n });\n subscriptions.push(sub2);\n}", "title": "" }, { "docid": "fb9ec7d87c762b42aa8b1f91eea06bba", "score": "0.45606926", "text": "function onOpen(tag) {\n KumoApp.Log(\"Handling tag [\" + tag.name + \"] open.\");\n\n var state = {\n triggerTick: KumoApp.Tick,\n notificationTimer: null,\n beeperTimer: null,\n tag: tag,\n beeperEnabled: false,\n initialDelay: true\n };\n\n motionStates[tag.uuid] = state;\n\n switch (beeperMode) {\n case BEEPER_MODE_ON:\n state.beeperEnabled = state.tag.beep(1000) !== null;\n if (!state.beeperEnabled) {\n state.beeperTimer = KumoApp.setInterval(\n function() {\n onBeeperTimer(state);\n },\n 2000);\n }\n break;\n case BEEPER_MODE_ON_OFF:\n state.beeperEnabled = state.tag.beep(2) !== null;\n break;\n case BEEPER_MODE_ON_AFTER_DELAY:\n state.beeperTimer = KumoApp.setInterval(\n function() {\n onBeeperTimer(state);\n },\n initialMotionDelay);\n break;\n }\n\n state.notificationTimer = KumoApp.setInterval(\n function() {\n onMotionNotificationTimer(state);\n },\n initialMotionDelay);\n}", "title": "" }, { "docid": "3afe578a702eecf9f86c24a8e1cd270f", "score": "0.45603558", "text": "async beforeStartIteration() {}", "title": "" }, { "docid": "8bcabef1574bd727a193e80df4553a79", "score": "0.4558599", "text": "function generateEvents() {\n step1();\n setTimeout(generateEvents, r.integer(settings.order.min, settings.order.max));\n}", "title": "" }, { "docid": "b15178c825cdffb032544a7d93863a29", "score": "0.45579997", "text": "function fermerTagV2() {\n var unTagOuvert = document.querySelectorAll(\".far.fa-times-circle\");\n if (unTagOuvert.length > 0) {\n unTagOuvert.forEach(function (item) {\n item.addEventListener('click', function (event) {\n event.stopPropagation();\n var parent = item.parentElement;\n suppressionEnCours = 1;\n parent.remove();\n // si pas de tag selectionné et pas de recherche\n if (document.querySelectorAll(\".far.fa-times-circle\").length == 0 && rechGlobale.value.length < 3) {\n tableauRecetteRechercheGlobale = [];\n tableauRecetteFiltreeTag = [];\n creerListeCarteRecette(recipes);\n actualiserListeTag(recipes);\n tableauTagClicable = listeTagClicable();\n selectionnerTag();\n } else if (document.querySelectorAll(\".far.fa-times-circle\").length == 0 && rechGlobale.value.length >= 3) {\n tableauRecetteFiltreeTag = [];\n creerListeCarteRecette(tableauRecetteRechercheGlobale);\n actualiserListeTag(tableauRecetteRechercheGlobale);\n tableauTagClicable = listeTagClicable();\n selectionnerTag();\n } else if (document.querySelectorAll(\".far.fa-times-circle\").length > 0) {\n rechercheParTagV2();\n creerListeCarteRecette(tableauRecetteFiltreeTag);\n actualiserListeTag(tableauRecetteFiltreeTag);\n tableauTagClicable = listeTagClicable();\n selectionnerTag();\n }\n suppressionEnCours = 0;\n rechercherTag();\n fermerTagV2();\n });\n });\n }\n}", "title": "" }, { "docid": "dde134ca0defa810e072c4b7c5a80f6a", "score": "0.45549905", "text": "activeTagsHandler(element) {\n let clickedTagTxt = element.textContent;\n let clickedTagTLength = clickedTagTxt.length;\n // let getStorageItems = [];\n if (localStorage.getItem('activeTags')) {\n let getStorageItems = localStorage.getItem('activeTags');\n\n if (getStorageItems === clickedTagTxt) {\n localStorage.removeItem('activeTags');\n } else if (getStorageItems !== clickedTagTxt && getStorageItems.indexOf(clickedTagTxt) >= 0) {\n let clickedTagIndex = getStorageItems.indexOf(clickedTagTxt);\n let currentTags = getStorageItems;\n let firstNewPart = currentTags.slice(0, clickedTagIndex);\n let secondNewPart = currentTags.slice(clickedTagIndex + clickedTagTLength);\n let newActiveTags = firstNewPart.concat(secondNewPart);\n localStorage.setItem('activeTags', newActiveTags);\n } else if (getStorageItems.indexOf(clickedTagTxt) === -1) {\n localStorage.setItem('activeTags', getStorageItems + clickedTagTxt);\n }\n } else {\n localStorage.setItem('activeTags', clickedTagTxt);\n };\n this.checkSavedActiveTags();\n\n while (this.newsListDom.firstChild) {\n this.newsListDom.removeChild(this.newsListDom.firstChild);\n };\n\n this.postsToRender.sort((a, b) => this.sortWithTags(a, b));\n\n this.renderedPosts = 0;\n this.renderPosts(10, this.postsToRender);\n\n }", "title": "" }, { "docid": "32043f67e3c58e983b92c28665272821", "score": "0.45547843", "text": "function startStop(){\n $(\"body\").on('click', '.gif-img', function(event){\n var gifImg = $(this);\n var gifState = gifImg.attr('data-state');\n var gifAnimate = gifImg.attr('data-animate');\n var gifStill = gifImg.attr('data-still'); \n if(gifState === 'still'){\n gifImg.attr('src',gifAnimate);\n gifImg.attr('data-state', 'animate');\n } else {\n gifImg.attr('src', gifStill);\n gifImg.attr('data-state', 'still')\n }\n }) \n\n }", "title": "" }, { "docid": "f3ccee179dc99a65091920612d2fb3ad", "score": "0.45537344", "text": "function tag(value) {\n if (!tags) return\n setData('lastWasTag', true)\n buffers[buffers.length - 1].push(value)\n }", "title": "" } ]
634ba4e498c1911594522e142fc620e6
simple implementation of deep cloneNode required for nested templates in polyfilled browsers
[ { "docid": "668505eda19a0faf20fa8e70e26258f9", "score": "0.633373", "text": "static simpleCloneNode(node) {\n if (!node) {\n return null;\n }\n const clone = node.cloneNode(false);\n // tslint:disable-next-line:prefer-for-of\n for (let i = 0; i < node.childNodes.length; i++) {\n const childClone = this.simpleCloneNode(node.childNodes[i]);\n if (childClone) {\n clone.appendChild(childClone);\n }\n }\n return clone;\n }", "title": "" } ]
[ { "docid": "9e4212982b1e99a2ac24b28fe6c4af71", "score": "0.7333653", "text": "_clone(options) {\n var _a;\n const { el: { content }, parts: parts, } = this._$template;\n const fragment = ((_a = options === null || options === void 0 ? void 0 : options.creationScope) !== null && _a !== void 0 ? _a : d).importNode(content, true);\n walker.currentNode = fragment;\n let node = walker.nextNode();\n let nodeIndex = 0;\n let partIndex = 0;\n let templatePart = parts[0];\n while (templatePart !== undefined) {\n if (nodeIndex === templatePart.index) {\n let part;\n if (templatePart.type === CHILD_PART) {\n part = new ChildPart(node, node.nextSibling, this, options);\n }\n else if (templatePart.type === ATTRIBUTE_PART) {\n part = new templatePart.ctor(node, templatePart.name, templatePart.strings, this, options);\n }\n else if (templatePart.type === ELEMENT_PART) {\n part = new ElementPart(node, this, options);\n }\n this._parts.push(part);\n templatePart = parts[++partIndex];\n }\n if (nodeIndex !== (templatePart === null || templatePart === void 0 ? void 0 : templatePart.index)) {\n node = walker.nextNode();\n nodeIndex++;\n }\n }\n return fragment;\n }", "title": "" }, { "docid": "a82b5533c6ee7ed18af8aab02d07096c", "score": "0.71419877", "text": "function cloneVNode(vnode,deep){var cloned=new VNode(vnode.tag,vnode.data,vnode.children,vnode.text,vnode.elm,vnode.context,vnode.componentOptions,vnode.asyncFactory);cloned.ns=vnode.ns;cloned.isStatic=vnode.isStatic;cloned.key=vnode.key;cloned.isComment=vnode.isComment;cloned.isCloned=true;if(deep&&vnode.children){cloned.children=cloneVNodes(vnode.children);}return cloned;}", "title": "" }, { "docid": "dc0e3f0f1888c7376beaee551d7b2a49", "score": "0.7097652", "text": "function cloneVNode(vnode,deep){var cloned=new VNode(vnode.tag,vnode.data,vnode.children,vnode.text,vnode.elm,vnode.context,vnode.componentOptions,vnode.asyncFactory);cloned.ns = vnode.ns;cloned.isStatic = vnode.isStatic;cloned.key = vnode.key;cloned.isComment = vnode.isComment;cloned.isCloned = true;if(deep && vnode.children){cloned.children = cloneVNodes(vnode.children);}return cloned;}", "title": "" }, { "docid": "c6f5de0bdee8f04f781b49d3dd314781", "score": "0.70976084", "text": "function cloneNode(node,recursive){if(recursive===void 0){recursive=false;}var result;switch(node.type){case domelementtype_1.ElementType.Text:result=new Text(node.data);break;case domelementtype_1.ElementType.Directive:{var instr=node;result=new ProcessingInstruction(instr.name,instr.data);if(instr[\"x-name\"]!=null){result[\"x-name\"]=instr[\"x-name\"];result[\"x-publicId\"]=instr[\"x-publicId\"];result[\"x-systemId\"]=instr[\"x-systemId\"];}break;}case domelementtype_1.ElementType.Comment:result=new Comment(node.data);break;case domelementtype_1.ElementType.Tag:case domelementtype_1.ElementType.Script:case domelementtype_1.ElementType.Style:{var elem=node;var children=recursive?cloneChildren(elem.children):[];var clone_1=new Element(elem.name,__assign({},elem.attribs),children);children.forEach(function(child){return child.parent=clone_1;});if(elem[\"x-attribsNamespace\"]){clone_1[\"x-attribsNamespace\"]=__assign({},elem[\"x-attribsNamespace\"]);}if(elem[\"x-attribsPrefix\"]){clone_1[\"x-attribsPrefix\"]=__assign({},elem[\"x-attribsPrefix\"]);}result=clone_1;break;}case domelementtype_1.ElementType.CDATA:{var cdata=node;var children=recursive?cloneChildren(cdata.children):[];var clone_2=new NodeWithChildren(node.type,children);children.forEach(function(child){return child.parent=clone_2;});result=clone_2;break;}case domelementtype_1.ElementType.Root:{var doc=node;var children=recursive?cloneChildren(doc.children):[];var clone_3=new Document(children);children.forEach(function(child){return child.parent=clone_3;});if(doc[\"x-mode\"]){clone_3[\"x-mode\"]=doc[\"x-mode\"];}result=clone_3;break;}case domelementtype_1.ElementType.Doctype:{// This type isn't used yet.\nthrow new Error(\"Not implemented yet: ElementType.Doctype case\");}}result.startIndex=node.startIndex;result.endIndex=node.endIndex;return result;}", "title": "" }, { "docid": "17a8c69cbd51a9fd5a169b9c950381c9", "score": "0.7069282", "text": "function deepCloneVNode(vnode){const cloned=cloneVNode(vnode);if(isArray(vnode.children)){cloned.children=vnode.children.map(deepCloneVNode);}return cloned;}", "title": "" }, { "docid": "c78a1b947731af825ed34c75465370c2", "score": "0.70476574", "text": "function cloneNode(node, recursive) {\n if (recursive === void 0) {\n recursive = false;\n }\n\n var result;\n\n if (isText(node)) {\n result = new Text(node.data);\n } else if (isComment(node)) {\n result = new Comment(node.data);\n } else if (isTag(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_1 = new Element(node.name, __assign({}, node.attribs), children);\n children.forEach(function (child) {\n return child.parent = clone_1;\n });\n\n if (node[\"x-attribsNamespace\"]) {\n clone_1[\"x-attribsNamespace\"] = __assign({}, node[\"x-attribsNamespace\"]);\n }\n\n if (node[\"x-attribsPrefix\"]) {\n clone_1[\"x-attribsPrefix\"] = __assign({}, node[\"x-attribsPrefix\"]);\n }\n\n result = clone_1;\n } else if (isCDATA(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_2 = new NodeWithChildren(domelementtype_1.ElementType.CDATA, children);\n children.forEach(function (child) {\n return child.parent = clone_2;\n });\n result = clone_2;\n } else if (isDocument(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_3 = new Document(children);\n children.forEach(function (child) {\n return child.parent = clone_3;\n });\n\n if (node[\"x-mode\"]) {\n clone_3[\"x-mode\"] = node[\"x-mode\"];\n }\n\n result = clone_3;\n } else if (isDirective(node)) {\n var instruction = new ProcessingInstruction(node.name, node.data);\n\n if (node[\"x-name\"] != null) {\n instruction[\"x-name\"] = node[\"x-name\"];\n instruction[\"x-publicId\"] = node[\"x-publicId\"];\n instruction[\"x-systemId\"] = node[\"x-systemId\"];\n }\n\n result = instruction;\n } else {\n throw new Error(\"Not implemented yet: \" + node.type);\n }\n\n result.startIndex = node.startIndex;\n result.endIndex = node.endIndex;\n return result;\n}", "title": "" }, { "docid": "032a4dd1f0148a5ac6574e8875fa8447", "score": "0.7013334", "text": "function clone() {\n\t\tvar\n\t\t\ttemplates = this.querySelectorAll(\"template\"),\n\t\t\tfragments = [],\n\t\t\ttemplate,\n\t\t\ti = 0;\n\n\t\t// If the support is OK simply clone and return\n\t\tif (support) {\n\t\t\ttemplate = this.cloneNode(true);\n\t\t\ttemplates = template.content.querySelectorAll(\"template\");\n\n\t\t\t// Set the clone method for each nested <template> element\n\t\t\tfor (; templates[i]; i++) {\n\t\t\t\ttemplates[i].clone = clone;\n\t\t\t}\n\n\t\t\treturn template;\n\t\t}\n\n\t\t// Loop through nested <template> to retrieve the content property\n\t\tfor (; templates[i]; i++) {\n\t\t\tfragments.push(templates[i].content);\n\t\t}\n\n\t\t// Now, clone the document fragment\n\t\ttemplate = this.cloneNode(true);\n\n\t\t// Makes sure the clone have a \"content\" and \"clone\" properties\n\t\ttemplate.content = this.content;\n\t\ttemplate.clone = clone;\n\n\t\t/**\n\t\t * Retrieve the nested <template> once again\n\t\t * Since we just cloned the document fragment,\n\t\t * the content's property of the nested <template> might be undefined\n\t\t * We have to re-set it using the fragment array we previously got\n\t\t */\n\t\ttemplates = template.querySelectorAll(\"template\");\n\n\t\t// Loop to set the content property of each nested template\n\t\tfor (i = 0; templates[i]; i++) {\n\t\t\ttemplates[i].content = fragments[i];\n\t\t\ttemplates[i].clone = clone; // Makes sure to set the clone method as well\n\t\t}\n\n\t\treturn template;\n\t}", "title": "" }, { "docid": "242445cf617638f4a504d86fad348d97", "score": "0.70043296", "text": "function cloneVNode(vnode,deep){var componentOptions=vnode.componentOptions;var cloned=new VNode(vnode.tag,vnode.data,vnode.children,vnode.text,vnode.elm,vnode.context,componentOptions,vnode.asyncFactory);cloned.ns = vnode.ns;cloned.isStatic = vnode.isStatic;cloned.key = vnode.key;cloned.isComment = vnode.isComment;cloned.fnContext = vnode.fnContext;cloned.fnOptions = vnode.fnOptions;cloned.fnScopeId = vnode.fnScopeId;cloned.isCloned = true;if(deep){if(vnode.children){cloned.children = cloneVNodes(vnode.children,true);}if(componentOptions && componentOptions.children){componentOptions.children = cloneVNodes(componentOptions.children,true);}}return cloned;}", "title": "" }, { "docid": "a55ae9a1c80d82edbd661a169338adf3", "score": "0.69998574", "text": "function cloneNode(node, recursive) {\n if (recursive === void 0) { recursive = false; }\n var result;\n if (isText(node)) {\n result = new Text(node.data);\n }\n else if (isComment(node)) {\n result = new Comment(node.data);\n }\n else if (isTag(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_1 = new Element(node.name, __assign({}, node.attribs), children);\n children.forEach(function (child) { return (child.parent = clone_1); });\n if (node.namespace != null) {\n clone_1.namespace = node.namespace;\n }\n if (node[\"x-attribsNamespace\"]) {\n clone_1[\"x-attribsNamespace\"] = __assign({}, node[\"x-attribsNamespace\"]);\n }\n if (node[\"x-attribsPrefix\"]) {\n clone_1[\"x-attribsPrefix\"] = __assign({}, node[\"x-attribsPrefix\"]);\n }\n result = clone_1;\n }\n else if (isCDATA(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_2 = new CDATA(children);\n children.forEach(function (child) { return (child.parent = clone_2); });\n result = clone_2;\n }\n else if (isDocument(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_3 = new Document(children);\n children.forEach(function (child) { return (child.parent = clone_3); });\n if (node[\"x-mode\"]) {\n clone_3[\"x-mode\"] = node[\"x-mode\"];\n }\n result = clone_3;\n }\n else if (isDirective(node)) {\n var instruction = new ProcessingInstruction(node.name, node.data);\n if (node[\"x-name\"] != null) {\n instruction[\"x-name\"] = node[\"x-name\"];\n instruction[\"x-publicId\"] = node[\"x-publicId\"];\n instruction[\"x-systemId\"] = node[\"x-systemId\"];\n }\n result = instruction;\n }\n else {\n throw new Error(\"Not implemented yet: \".concat(node.type));\n }\n result.startIndex = node.startIndex;\n result.endIndex = node.endIndex;\n if (node.sourceCodeLocation != null) {\n result.sourceCodeLocation = node.sourceCodeLocation;\n }\n return result;\n}", "title": "" }, { "docid": "98ca49b0c79080c5c89733a5407e4f44", "score": "0.69788486", "text": "function cloneNode(node, recursive) {\n if (recursive === void 0) { recursive = false; }\n var result;\n if (isText(node)) {\n result = new Text(node.data);\n }\n else if (isComment(node)) {\n result = new Comment(node.data);\n }\n else if (isTag(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_1 = new Element$1(node.name, __assign$1({}, node.attribs), children);\n children.forEach(function (child) { return (child.parent = clone_1); });\n if (node[\"x-attribsNamespace\"]) {\n clone_1[\"x-attribsNamespace\"] = __assign$1({}, node[\"x-attribsNamespace\"]);\n }\n if (node[\"x-attribsPrefix\"]) {\n clone_1[\"x-attribsPrefix\"] = __assign$1({}, node[\"x-attribsPrefix\"]);\n }\n result = clone_1;\n }\n else if (isCDATA(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_2 = new NodeWithChildren(domelementtype_1$1.ElementType.CDATA, children);\n children.forEach(function (child) { return (child.parent = clone_2); });\n result = clone_2;\n }\n else if (isDocument(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_3 = new Document(children);\n children.forEach(function (child) { return (child.parent = clone_3); });\n if (node[\"x-mode\"]) {\n clone_3[\"x-mode\"] = node[\"x-mode\"];\n }\n result = clone_3;\n }\n else if (isDirective(node)) {\n var instruction = new ProcessingInstruction(node.name, node.data);\n if (node[\"x-name\"] != null) {\n instruction[\"x-name\"] = node[\"x-name\"];\n instruction[\"x-publicId\"] = node[\"x-publicId\"];\n instruction[\"x-systemId\"] = node[\"x-systemId\"];\n }\n result = instruction;\n }\n else {\n throw new Error(\"Not implemented yet: \" + node.type);\n }\n result.startIndex = node.startIndex;\n result.endIndex = node.endIndex;\n return result;\n}", "title": "" }, { "docid": "4b4b21f0d1dd6f984dfe0636ea8dd002", "score": "0.6916308", "text": "function cloneVNode(vnode, deep) {\n var cloned = new VNode(vnode.tag, vnode.data, vnode.children, vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned;\n }", "title": "" }, { "docid": "59a6d30398304ecc7eccca2d790f5a81", "score": "0.6892859", "text": "function cloneVNode(vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(vnode.tag, vnode.data, vnode.children, vnode.text, vnode.elm, vnode.context, componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned;\n}", "title": "" }, { "docid": "5cca7fe64398a13ec54f96bb548b8ec5", "score": "0.687808", "text": "function cloneNode(node, recursive) {\n if (recursive === void 0) { recursive = false; }\n var result;\n if (isText(node)) {\n result = new Text$2(node.data);\n }\n else if (isComment(node)) {\n result = new Comment$2(node.data);\n }\n else if (isTag$1(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_1 = new Element$2(node.name, __assign$1({}, node.attribs), children);\n children.forEach(function (child) { return (child.parent = clone_1); });\n if (node[\"x-attribsNamespace\"]) {\n clone_1[\"x-attribsNamespace\"] = __assign$1({}, node[\"x-attribsNamespace\"]);\n }\n if (node[\"x-attribsPrefix\"]) {\n clone_1[\"x-attribsPrefix\"] = __assign$1({}, node[\"x-attribsPrefix\"]);\n }\n result = clone_1;\n }\n else if (isCDATA(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_2 = new NodeWithChildren(domelementtype_1$1.ElementType.CDATA, children);\n children.forEach(function (child) { return (child.parent = clone_2); });\n result = clone_2;\n }\n else if (isDocument(node)) {\n var children = recursive ? cloneChildren(node.children) : [];\n var clone_3 = new Document$2(children);\n children.forEach(function (child) { return (child.parent = clone_3); });\n if (node[\"x-mode\"]) {\n clone_3[\"x-mode\"] = node[\"x-mode\"];\n }\n result = clone_3;\n }\n else if (isDirective(node)) {\n var instruction = new ProcessingInstruction(node.name, node.data);\n if (node[\"x-name\"] != null) {\n instruction[\"x-name\"] = node[\"x-name\"];\n instruction[\"x-publicId\"] = node[\"x-publicId\"];\n instruction[\"x-systemId\"] = node[\"x-systemId\"];\n }\n result = instruction;\n }\n else {\n throw new Error(\"Not implemented yet: \" + node.type);\n }\n result.startIndex = node.startIndex;\n result.endIndex = node.endIndex;\n return result;\n}", "title": "" }, { "docid": "f4c339e44396de421d4142ebc15b33dd", "score": "0.6875129", "text": "clone(){\n let clone = new ObjectNode();\n return clone;\n }", "title": "" }, { "docid": "7b38b3c6a1d0da289a1dbbb5542606a0", "score": "0.68631405", "text": "function cloneVNode(vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n }", "title": "" }, { "docid": "98c59bdf0802ba27d9ac2928d28164f8", "score": "0.6854316", "text": "function cloneVNode(vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(vnode.tag, vnode.data, vnode.children, vnode.text, vnode.elm, vnode.context, componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned;\n}", "title": "" }, { "docid": "a2d7770c376530aec1be4ad730aea027", "score": "0.68417376", "text": "function cloneVNode (vnode, deep) {\n\t var componentOptions = vnode.componentOptions;\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t componentOptions,\n\t vnode.asyncFactory\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isComment = vnode.isComment;\n\t cloned.fnContext = vnode.fnContext;\n\t cloned.fnOptions = vnode.fnOptions;\n\t cloned.fnScopeId = vnode.fnScopeId;\n\t cloned.isCloned = true;\n\t if (deep) {\n\t if (vnode.children) {\n\t cloned.children = cloneVNodes(vnode.children, true);\n\t }\n\t if (componentOptions && componentOptions.children) {\n\t componentOptions.children = cloneVNodes(componentOptions.children, true);\n\t }\n\t }\n\t return cloned\n\t}", "title": "" }, { "docid": "7b7c022dae55a3259ba967ddde52dd68", "score": "0.68230736", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "7b7c022dae55a3259ba967ddde52dd68", "score": "0.68230736", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "7b7c022dae55a3259ba967ddde52dd68", "score": "0.68230736", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "7b7c022dae55a3259ba967ddde52dd68", "score": "0.68230736", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "7b7c022dae55a3259ba967ddde52dd68", "score": "0.68230736", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "3867b122b6c27189c62510717e7ba2e7", "score": "0.6780392", "text": "function cloneVNode (vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned\n}", "title": "" }, { "docid": "78c0f0507648542b1822c39171d455f8", "score": "0.6764696", "text": "function cloneVNode(vnode, deep) {\n var componentOptions = vnode.componentOptions;\n var data = vnode.data;\n\n var listeners = {};\n if (componentOptions && componentOptions.listeners) {\n listeners = extends_default()({}, componentOptions.listeners);\n }\n\n var on = {};\n if (data && data.on) {\n on = extends_default()({}, data.on);\n }\n\n var cloned = new vnode.constructor(vnode.tag, data ? extends_default()({}, data, { on: on }) : data, vnode.children, vnode.text, vnode.elm, vnode.context, componentOptions ? extends_default()({}, componentOptions, { listeners: listeners }) : componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.isCloned = true;\n if (deep) {\n if (vnode.children) {\n cloned.children = cloneVNodes(vnode.children, true);\n }\n if (componentOptions && componentOptions.children) {\n componentOptions.children = cloneVNodes(componentOptions.children, true);\n }\n }\n return cloned;\n}", "title": "" }, { "docid": "bf949bc39b469fdf3af38123df2c0828", "score": "0.67579263", "text": "function cloneDeep(node) {\n\t\t var newNode = {};\n\t\n\t\t for (var key in node) {\n\t\t if (key[0] === \"_\") continue;\n\t\n\t\t var val = node[key];\n\t\n\t\t if (val) {\n\t\t if (val.type) {\n\t\t val = t.cloneDeep(val);\n\t\t } else if (Array.isArray(val)) {\n\t\t val = val.map(t.cloneDeep);\n\t\t }\n\t\t }\n\t\n\t\t newNode[key] = val;\n\t\t }\n\t\n\t\t return newNode;\n\t\t}", "title": "" }, { "docid": "bf949bc39b469fdf3af38123df2c0828", "score": "0.67579263", "text": "function cloneDeep(node) {\n\t\t var newNode = {};\n\t\n\t\t for (var key in node) {\n\t\t if (key[0] === \"_\") continue;\n\t\n\t\t var val = node[key];\n\t\n\t\t if (val) {\n\t\t if (val.type) {\n\t\t val = t.cloneDeep(val);\n\t\t } else if (Array.isArray(val)) {\n\t\t val = val.map(t.cloneDeep);\n\t\t }\n\t\t }\n\t\n\t\t newNode[key] = val;\n\t\t }\n\t\n\t\t return newNode;\n\t\t}", "title": "" }, { "docid": "bf949bc39b469fdf3af38123df2c0828", "score": "0.67579263", "text": "function cloneDeep(node) {\n\t\t var newNode = {};\n\t\n\t\t for (var key in node) {\n\t\t if (key[0] === \"_\") continue;\n\t\n\t\t var val = node[key];\n\t\n\t\t if (val) {\n\t\t if (val.type) {\n\t\t val = t.cloneDeep(val);\n\t\t } else if (Array.isArray(val)) {\n\t\t val = val.map(t.cloneDeep);\n\t\t }\n\t\t }\n\t\n\t\t newNode[key] = val;\n\t\t }\n\t\n\t\t return newNode;\n\t\t}", "title": "" }, { "docid": "bf949bc39b469fdf3af38123df2c0828", "score": "0.67579263", "text": "function cloneDeep(node) {\n\t\t var newNode = {};\n\t\n\t\t for (var key in node) {\n\t\t if (key[0] === \"_\") continue;\n\t\n\t\t var val = node[key];\n\t\n\t\t if (val) {\n\t\t if (val.type) {\n\t\t val = t.cloneDeep(val);\n\t\t } else if (Array.isArray(val)) {\n\t\t val = val.map(t.cloneDeep);\n\t\t }\n\t\t }\n\t\n\t\t newNode[key] = val;\n\t\t }\n\t\n\t\t return newNode;\n\t\t}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "414eb95198579d91ac26b8a8f0ed508d", "score": "0.6747989", "text": "function cloneVNode (vnode, deep) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n if (deep && vnode.children) {\n cloned.children = cloneVNodes(vnode.children);\n }\n return cloned\n}", "title": "" }, { "docid": "a6622d47ba9ffba83b279ed98f9b5ca8", "score": "0.6587961", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if (shared.isArray(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "8b02ffdedd8497e71222be10c3190e1a", "score": "0.6579962", "text": "function deepCloneVNode(vnode) {\n const cloned = cloneVNode(vnode);\n if ((0,_vue_shared__WEBPACK_IMPORTED_MODULE_1__.isArray)(vnode.children)) {\n cloned.children = vnode.children.map(deepCloneVNode);\n }\n return cloned;\n}", "title": "" }, { "docid": "f7ac8125d8e7895e3ef03c885658ea32", "score": "0.65793943", "text": "function cloneVNode(vnode){\nvar cloned=new VNode(\nvnode.tag,\nvnode.data,\n// #7975\n// clone children array to avoid mutating original in case of cloning\n// a child.\nvnode.children&&vnode.children.slice(),\nvnode.text,\nvnode.elm,\nvnode.context,\nvnode.componentOptions,\nvnode.asyncFactory);\n\ncloned.ns=vnode.ns;\ncloned.isStatic=vnode.isStatic;\ncloned.key=vnode.key;\ncloned.isComment=vnode.isComment;\ncloned.fnContext=vnode.fnContext;\ncloned.fnOptions=vnode.fnOptions;\ncloned.fnScopeId=vnode.fnScopeId;\ncloned.asyncMeta=vnode.asyncMeta;\ncloned.isCloned=true;\nreturn cloned;\n}", "title": "" }, { "docid": "dbc502c450771a3dcc40741190890e89", "score": "0.64856553", "text": "function deepCloneNode(node) {\n const clone = node.cloneNode(true);\n const descendantsWithId = clone.querySelectorAll('[id]');\n const descendantCanvases = node.querySelectorAll('canvas');\n // Remove the `id` to avoid having multiple elements with the same id on the page.\n clone.removeAttribute('id');\n for (let i = 0; i < descendantsWithId.length; i++) {\n descendantsWithId[i].removeAttribute('id');\n }\n // `cloneNode` won't transfer the content of `canvas` elements so we have to do it ourselves.\n // We match up the cloned canvas to their sources using their index in the DOM.\n if (descendantCanvases.length) {\n const cloneCanvases = clone.querySelectorAll('canvas');\n for (let i = 0; i < descendantCanvases.length; i++) {\n const correspondingCloneContext = cloneCanvases[i].getContext('2d');\n if (correspondingCloneContext) {\n // In some cases `drawImage` can throw (e.g. if the canvas size is 0x0).\n // We can't do much about it so just ignore the error.\n try {\n correspondingCloneContext.drawImage(descendantCanvases[i], 0, 0);\n }\n catch (_a) { }\n }\n }\n }\n return clone;\n}", "title": "" }, { "docid": "a2ce9a99e9cb63b00fb924008287f99e", "score": "0.6446691", "text": "function cloneDeep(node) {\n\t var newNode = {};\n\n\t for (var key in node) {\n\t if (key[0] === \"_\") continue;\n\n\t var val = node[key];\n\n\t if (val) {\n\t if (val.type) {\n\t val = t.cloneDeep(val);\n\t } else if (Array.isArray(val)) {\n\t val = val.map(t.cloneDeep);\n\t }\n\t }\n\n\t newNode[key] = val;\n\t }\n\n\t return newNode;\n\t}", "title": "" }, { "docid": "a2ce9a99e9cb63b00fb924008287f99e", "score": "0.6446691", "text": "function cloneDeep(node) {\n\t var newNode = {};\n\n\t for (var key in node) {\n\t if (key[0] === \"_\") continue;\n\n\t var val = node[key];\n\n\t if (val) {\n\t if (val.type) {\n\t val = t.cloneDeep(val);\n\t } else if (Array.isArray(val)) {\n\t val = val.map(t.cloneDeep);\n\t }\n\t }\n\n\t newNode[key] = val;\n\t }\n\n\t return newNode;\n\t}", "title": "" }, { "docid": "a2ce9a99e9cb63b00fb924008287f99e", "score": "0.6446691", "text": "function cloneDeep(node) {\n\t var newNode = {};\n\n\t for (var key in node) {\n\t if (key[0] === \"_\") continue;\n\n\t var val = node[key];\n\n\t if (val) {\n\t if (val.type) {\n\t val = t.cloneDeep(val);\n\t } else if (Array.isArray(val)) {\n\t val = val.map(t.cloneDeep);\n\t }\n\t }\n\n\t newNode[key] = val;\n\t }\n\n\t return newNode;\n\t}", "title": "" }, { "docid": "a2ce9a99e9cb63b00fb924008287f99e", "score": "0.6446691", "text": "function cloneDeep(node) {\n\t var newNode = {};\n\n\t for (var key in node) {\n\t if (key[0] === \"_\") continue;\n\n\t var val = node[key];\n\n\t if (val) {\n\t if (val.type) {\n\t val = t.cloneDeep(val);\n\t } else if (Array.isArray(val)) {\n\t val = val.map(t.cloneDeep);\n\t }\n\t }\n\n\t newNode[key] = val;\n\t }\n\n\t return newNode;\n\t}", "title": "" }, { "docid": "c017341a3d3fd066e7a151840f288793", "score": "0.6383181", "text": "clone() {\r\n\t\tconst cloneRoot = this.shallowClone();\r\n\t\tconst stack = [this];\r\n\t\tconst cloneStack = [cloneRoot];\r\n\t\twhile(stack.length > 0) {\r\n\t\t\tconst node = stack.pop();\r\n\t\t\tconst copy = cloneStack.pop();\r\n\t\t\tfor(let i = 0; i < node.children.length; i++) {\r\n\t\t\t\tcopy.children[i] = node.children[i].shallowClone();\r\n\t\t\t\tcopy.children[i].parent = copy;\r\n\t\t\t\tstack.push(node.children[i]);\r\n\t\t\t\tcloneStack.push(copy.children[i]);\r\n\t\t\t}\r\n\t\t}\r\n\t\treturn cloneRoot;\r\n\t}", "title": "" }, { "docid": "87394f10951af7b1be23ec5fecb68990", "score": "0.6374414", "text": "clone() {\n return new Tree(this.rootNode);\n }", "title": "" }, { "docid": "ff64a7c60d62755b93d913815e877b8f", "score": "0.63695675", "text": "function clone(/*attributes,children,handlers,storage*/) {\t// do specifics later\r\n\t\tvar element = this.cloneNode(false), attrs = {}, name, value;\r\n\t\tfor (var i=0,a; a=this.attributes[i]; i++) {\r\n\t\t\tname = a.nodeName;\r\n\t\t\tvalue = a.nodeValue;\r\n\t\t\tif (typeof value === \"string\" && element.attributes[name].nodeValue !== value) attrs[name] = value;\r\n\t\t};\r\n\t\telement.innerHTML = this.innerHTML;\r\n\t\tDOM.extend(element,element.query(\"*\"));\r\n\t\telement.__pseudoID = Pseudo.unique();\r\n\t\telement.writeAttributes(attrs);\r\n\t\t\r\n\t\t// events?\r\n\t\t// storage clone?\r\n\t\t\r\n\t\treturn element;\r\n\t}", "title": "" }, { "docid": "58fb397ead9320356ac8bb91d07d2f32", "score": "0.6361445", "text": "function cloneVNode(vnode) {\n var cloned = new VNode(vnode.tag, vnode.data, vnode.children, vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned;\n }", "title": "" }, { "docid": "58fb397ead9320356ac8bb91d07d2f32", "score": "0.6361445", "text": "function cloneVNode(vnode) {\n var cloned = new VNode(vnode.tag, vnode.data, vnode.children, vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned;\n }", "title": "" }, { "docid": "58fb397ead9320356ac8bb91d07d2f32", "score": "0.6361445", "text": "function cloneVNode(vnode) {\n var cloned = new VNode(vnode.tag, vnode.data, vnode.children, vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned;\n }", "title": "" }, { "docid": "08842faec0fcb5e607b80be5fd761da0", "score": "0.63529116", "text": "function cloneVNode(vnode) {\n var cloned = new VNode(vnode.tag, vnode.data, // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(), vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned;\n }", "title": "" }, { "docid": "10a38bac664eb50e099ca90fad84cecb", "score": "0.6344583", "text": "deepClone(data) {\n return JSON.parse(JSON.stringify(data));\n }", "title": "" }, { "docid": "fad757879dd7db7bb71734b80eee283b", "score": "0.6317344", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isComment = vnode.isComment;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "fad757879dd7db7bb71734b80eee283b", "score": "0.6317344", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isComment = vnode.isComment;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "1f8cfdca21fcb7ce4feeaea5f59015b6", "score": "0.6305547", "text": "function _clone(parent,depth){// cloning null always returns null\nif(parent===null)return null;if(depth==0)return parent;var child;var proto;if(_typeof4(parent)!='object'){return parent;}if(clone.__isArray(parent)){child=[];}else if(clone.__isRegExp(parent)){child=new RegExp(parent.source,__getRegExpFlags(parent));if(parent.lastIndex)child.lastIndex=parent.lastIndex;}else if(clone.__isDate(parent)){child=new Date(parent.getTime());}else if(useBuffer&&Buffer.isBuffer(parent)){if(Buffer.allocUnsafe){// Node.js >= 4.5.0\nchild=Buffer.allocUnsafe(parent.length);}else{// Older Node.js versions\nchild=new Buffer(parent.length);}parent.copy(child);return child;}else{if(typeof prototype=='undefined'){proto=Object.getPrototypeOf(parent);child=Object.create(proto);}else{child=Object.create(prototype);proto=prototype;}}if(circular){var index=allParents.indexOf(parent);if(index!=-1){return allChildren[index];}allParents.push(parent);allChildren.push(child);}for(var i in parent){var attrs;if(proto){attrs=Object.getOwnPropertyDescriptor(proto,i);}if(attrs&&attrs.set==null){continue;}child[i]=_clone(parent[i],depth-1);}return child;}", "title": "" }, { "docid": "12d44bcea512969aba311b8b974e393a", "score": "0.62867296", "text": "function cloneVNode(vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(),\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory,\n )\n cloned.ns = vnode.ns\n cloned.isStatic = vnode.isStatic\n cloned.key = vnode.key\n cloned.isComment = vnode.isComment\n cloned.fnContext = vnode.fnContext\n cloned.fnOptions = vnode.fnOptions\n cloned.fnScopeId = vnode.fnScopeId\n cloned.asyncMeta = vnode.asyncMeta\n cloned.isCloned = true\n return cloned\n }", "title": "" }, { "docid": "e231e5c888f2cd9a1aa0cf8153772372", "score": "0.62797874", "text": "cloneElement(element, deep) {\n var self = this;\n\n var newElement = etree.Element(element.tag, element.attrib);\n newElement.text = element.text;\n newElement.tail = element.tail;\n\n if (deep !== false) {\n element.getchildren().forEach(function (child) {\n newElement.append(self.cloneElement(child, deep));\n });\n }\n\n return newElement;\n }", "title": "" }, { "docid": "3fc1417f6a2ff98724980e8d5fe7497d", "score": "0.6279386", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "3fc1417f6a2ff98724980e8d5fe7497d", "score": "0.6279386", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "3fc1417f6a2ff98724980e8d5fe7497d", "score": "0.6279386", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "3fc1417f6a2ff98724980e8d5fe7497d", "score": "0.6279386", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "3df336333abded226275664831b3b545", "score": "0.62750727", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t // #7975\n\t // clone children array to avoid mutating original in case of cloning\n\t // a child.\n\t vnode.children && vnode.children.slice(),\n\t vnode.text,\n\t vnode.elm,\n\t vnode.context,\n\t vnode.componentOptions,\n\t vnode.asyncFactory\n\t );\n\t cloned.ns = vnode.ns;\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isComment = vnode.isComment;\n\t cloned.fnContext = vnode.fnContext;\n\t cloned.fnOptions = vnode.fnOptions;\n\t cloned.fnScopeId = vnode.fnScopeId;\n\t cloned.asyncMeta = vnode.asyncMeta;\n\t cloned.isCloned = true;\n\t return cloned\n\t }", "title": "" }, { "docid": "dcd22ae1ee4f08c8c2fafe7f3a508b48", "score": "0.6257338", "text": "function cloneVNode(vnode) {\n const cloned = new VNode(vnode.tag, vnode.data, \n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(), vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned;\n}", "title": "" }, { "docid": "dcd22ae1ee4f08c8c2fafe7f3a508b48", "score": "0.6257338", "text": "function cloneVNode(vnode) {\n const cloned = new VNode(vnode.tag, vnode.data, \n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(), vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned;\n}", "title": "" }, { "docid": "dcd22ae1ee4f08c8c2fafe7f3a508b48", "score": "0.6257338", "text": "function cloneVNode(vnode) {\n const cloned = new VNode(vnode.tag, vnode.data, \n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(), vnode.text, vnode.elm, vnode.context, vnode.componentOptions, vnode.asyncFactory);\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned;\n}", "title": "" }, { "docid": "b7a4895ad6159594f8ad05f72d68afbc", "score": "0.62484246", "text": "function clone(a) {if (!a) return a;var c, b = [Number, String, Boolean];if (b.forEach(function(b) { a instanceof b && (c = b(a)); }), \"undefined\" == typeof c) if (\"[object Array]\" === Object.prototype.toString.call(a)) c = [], a.forEach(function(a, b, d) { c[b] = clone(a); }); else if (\"object\" == typeof a) if (a.nodeType && \"function\" == typeof a.cloneNode) c = a.cloneNode(!0); else if (a.prototype) c = a; else if (a instanceof Date) c = new Date(a); else { c = {}; for (var d in a) c[d] = clone(a[d]); } else c = a; return c;}", "title": "" }, { "docid": "959e41378257c53f1f2a5ab482f86404", "score": "0.62422484", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}", "title": "" }, { "docid": "959e41378257c53f1f2a5ab482f86404", "score": "0.62422484", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}", "title": "" }, { "docid": "959e41378257c53f1f2a5ab482f86404", "score": "0.62422484", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}", "title": "" }, { "docid": "959e41378257c53f1f2a5ab482f86404", "score": "0.62422484", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}", "title": "" }, { "docid": "959e41378257c53f1f2a5ab482f86404", "score": "0.62422484", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}", "title": "" }, { "docid": "959e41378257c53f1f2a5ab482f86404", "score": "0.62422484", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n vnode.children,\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.isCloned = true;\n return cloned\n}", "title": "" }, { "docid": "833587786b308e20edb46bb3020a7a5b", "score": "0.6241982", "text": "function cloneVNode (vnode) {\n\t var cloned = new VNode(\n\t vnode.tag,\n\t vnode.data,\n\t vnode.children,\n\t vnode.text,\n\t vnode.elm,\n\t vnode.ns,\n\t vnode.context,\n\t vnode.componentOptions\n\t );\n\t cloned.isStatic = vnode.isStatic;\n\t cloned.key = vnode.key;\n\t cloned.isCloned = true;\n\t return cloned\n\t}", "title": "" }, { "docid": "f4a3f92f15953ccd99963f7bebed8744", "score": "0.62378967", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(),\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned\n }", "title": "" }, { "docid": "f4a3f92f15953ccd99963f7bebed8744", "score": "0.62378967", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(),\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned\n }", "title": "" }, { "docid": "f4a3f92f15953ccd99963f7bebed8744", "score": "0.62378967", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(),\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned\n }", "title": "" }, { "docid": "f4a3f92f15953ccd99963f7bebed8744", "score": "0.62378967", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(),\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned\n }", "title": "" }, { "docid": "f4a3f92f15953ccd99963f7bebed8744", "score": "0.62378967", "text": "function cloneVNode (vnode) {\n var cloned = new VNode(\n vnode.tag,\n vnode.data,\n // #7975\n // clone children array to avoid mutating original in case of cloning\n // a child.\n vnode.children && vnode.children.slice(),\n vnode.text,\n vnode.elm,\n vnode.context,\n vnode.componentOptions,\n vnode.asyncFactory\n );\n cloned.ns = vnode.ns;\n cloned.isStatic = vnode.isStatic;\n cloned.key = vnode.key;\n cloned.isComment = vnode.isComment;\n cloned.fnContext = vnode.fnContext;\n cloned.fnOptions = vnode.fnOptions;\n cloned.fnScopeId = vnode.fnScopeId;\n cloned.asyncMeta = vnode.asyncMeta;\n cloned.isCloned = true;\n return cloned\n }", "title": "" } ]
a174d91262c8d7eab866840401acc4d5
Changes the color of the rectangle editor.
[ { "docid": "ecbaa37a3d298cdc378310abd0409a46", "score": "0.66318446", "text": "function changeColorE()\n{\n var e = document.getElementById(\"edit-rect\");\n var r = document.getElementById(\"colorRedE\").value;\n var g = document.getElementById(\"colorGreenE\").value;\n var b = document.getElementById(\"colorBlueE\").value;\n e.style.backgroundColor = \"rgba(\" + r + \", \" + g + \", \" + b + \",0.7)\";\n}", "title": "" } ]
[ { "docid": "240c54625579291a86ed7fdd7c553ecc", "score": "0.6612574", "text": "drawRectangle(rect, color) {\n var viewPos = this.worldToView(rect);\n this.gContext.beginPath();\n this.gContext.lineWidth = \"2\";\n this.gContext.strokeStyle = color ? color : rect.color;\n this.gContext.rect(viewPos.x, viewPos.y, rect.width, rect.height);\n this.gContext.stroke();\n rect.color = \"red\"; // DEBUG\n }", "title": "" }, { "docid": "867ccf2b00de84cc74d64340c375a5df", "score": "0.650419", "text": "function changeColor() {\n var r = $(\"#red\").val();\n var g = $(\"#green\").val();\n var b = $(\"#blue\").val();\n $(\"#newColor\").css(\"background-color\", \"rgb(\" + r + \",\" + g + \", \" + b + \")\");\n $(\"#newBrushSize\").css(\"background-color\", \"rgb(\" + r + \",\" + g + \", \" + b + \")\");\n }", "title": "" }, { "docid": "ae0d76a553f76edc55e59bb56f7d2797", "score": "0.64728385", "text": "function changeColor() {\r\n\r\n }", "title": "" }, { "docid": "d451fd85641a705aa281132093e640e1", "score": "0.64317405", "text": "function changeColor(oldColor, newColor)\n\n {\n\n doc.selection = null;\n\n var oldSwatch = makeNewSwatch(oldColor);\n\n var newSwatch = makeNewSwatch(newColor);\n\n doc.defaultFillColor = oldSwatch.color;\n\n app.executeMenuCommand(\"Find Fill Color menu item\");\n\n doc.defaultFillColor = newSwatch.color;\n\n doc.selection = null;\n\n }", "title": "" }, { "docid": "d56027014a424e26110548e17929d8c5", "score": "0.63168794", "text": "function setColor(newcolor) {\n color = newcolor;\n drawsize = 3;\n}", "title": "" }, { "docid": "d839f9b6fd4cdf2608ea73e026d074d3", "score": "0.6310801", "text": "function setColor(color) {\n var curColor = state.color;\n\n // If the new color is different from current color\n if (color !== curColor) {\n // Update the state\n state.color = color;\n\n // Fire a colorchange event\n $retSquare.trigger('colorchange', color);\n\n // Render the shape\n render();\n }\n }", "title": "" }, { "docid": "a966bd450758caef8bfc89607dc7aaa8", "score": "0.62497294", "text": "function changeColor()\n{\n var e = document.getElementById(\"menu-rect\");\n var r = document.getElementById(\"colorRed\").value;\n var g = document.getElementById(\"colorGreen\").value;\n var b = document.getElementById(\"colorBlue\").value;\n e.style.backgroundColor = \"rgba(\" + r + \", \" + g + \", \" + b + \",0.7)\";\n}", "title": "" }, { "docid": "29504e42f7d282bc1c63ad6d1240ee38", "score": "0.624799", "text": "function colorChange() {\n\tmyColor = color.value;\n\tctx.strokeStyle = myColor;\n}", "title": "" }, { "docid": "ce154bcc0e959245bfbb3c9e6fd4a5e8", "score": "0.6183608", "text": "function _set_color(o, cv){\n\t\to.css(\"color\", cv);\n\t}", "title": "" }, { "docid": "cfa40483f46ed69badd9b0f1054b7a8e", "score": "0.6175048", "text": "function colorRect(xLeft, yTop, width, height, color) {\n canvasContext.fillStyle = color;\n canvasContext.fillRect(xLeft, yTop, width, height);\n}", "title": "" }, { "docid": "122cb810853d56e46e1a5a17645d9689", "score": "0.61733466", "text": "function ccRectColor() {\n //call rectangle with randomized index\n var newccRect = rectArray[ccRectIndex];\n newccRect.style.backgroundColor = ccColor;\n newccRect.style.boxShadow = \"0 0 50px 50px\" + ccColor;\n newccRect.style.display = \"block\";\n}", "title": "" }, { "docid": "5534b673dd188d5faecb048303bd894b", "score": "0.6124332", "text": "function changeColor() {\n this.style.background = color.value;\n}", "title": "" }, { "docid": "52147dd7418687dae5ab7f83fe02738b", "score": "0.6124152", "text": "function changeColor() {\n\tthis.style.backgroundColor = colorInput.value;\n\tconsole.log(\"say Hi\");\n}", "title": "" }, { "docid": "698e1a63235ecceab37abb415d6b1436", "score": "0.60925055", "text": "changeColor(color) {\n this.material.color.set(new Color(color))\n }", "title": "" }, { "docid": "661b803be2218f6a35a19e19ac0b49fb", "score": "0.6084544", "text": "function changeColor() {\r\n var color = GetColorPickerValue();\r\n if(color != null || color != undefined){\r\n this.style.backgroundColor = color; \r\n }\r\n}", "title": "" }, { "docid": "c1abf5daf513461a3bdcbc2d002e697c", "score": "0.6028157", "text": "function changeColor(){\n\t// Gets value from each input range and adds to the rgb()\n\tvar r=$('#red').val();\n\tvar g=$('#green').val();\n\tvar b=$('#blue').val();\n\t$('.color-block').css('background-color',\"rgb(\"+r+\",\"+g+\",\"+b+\")\");\n}", "title": "" }, { "docid": "a80283dd21a64a050df606806d56671f", "score": "0.6016621", "text": "function Right_Color(square){\n msg_display.textContent = \"Correct\";\n Change_Color(selected_color);\n game_name.style.backgroundColor = selected_color;\n btn_restart.textContent = \"Play again\";\n}", "title": "" }, { "docid": "d055223cc09807e7f4bea63f610a6984", "score": "0.60155", "text": "function colorRect(leftX, topY, width, height, color) {\n ctx.fillStyle = color;\n ctx.fillRect(leftX, topY, width, height);\n}", "title": "" }, { "docid": "6305a066abab60e351e626623e950723", "score": "0.59807533", "text": "function changeColorOver(e, line, column) {\n e.style.backgroundColor = \"#d4d4d4\";\n pyInputAceEditor.navigateTo(line, column);\n \n}", "title": "" }, { "docid": "1075c93d20a08f651ec61096adc17b29", "score": "0.59807444", "text": "function colorChange() {\r\n myColor = color.value;\r\n ctx.strokeStyle = myColor;\r\n}", "title": "" }, { "docid": "16c69a32e668b427e7e95d6cded0dd7f", "score": "0.597165", "text": "setColour(c){\n this.col = c;\n }", "title": "" }, { "docid": "0a4efad8ebf5280738c3435445e9efa9", "score": "0.59389603", "text": "setColor(color) {\n this.color = color;\n }", "title": "" }, { "docid": "0a4efad8ebf5280738c3435445e9efa9", "score": "0.59389603", "text": "setColor(color) {\n this.color = color;\n }", "title": "" }, { "docid": "dd6b9c0fa2c71fe586feacb6f185d61c", "score": "0.59356564", "text": "function setDrawingColor(event) {\n sketchController.color = this.value;\n}", "title": "" }, { "docid": "3de4c21df793051b764244cdc1760a6f", "score": "0.588836", "text": "function changeColor(color){\n //loop through square\n\n for(let i = 0; i < square.length; i++){\n square\n [i].style.backgroundColor = color;\n }\n //colorr();\n }", "title": "" }, { "docid": "3941a066fcd391ce5bb7c857bb800599", "score": "0.58836687", "text": "function setCurrentColor(color) {\n currentColor = color;\n}", "title": "" }, { "docid": "5c013e26b5e4a52c61a431950a109c6a", "score": "0.58817273", "text": "function updateColor(color) {\n document.querySelector(\"#colorpreview\").style.background = color;\n changeColor();\n}", "title": "" }, { "docid": "c61190745407a208a03171c7befbca19", "score": "0.5877988", "text": "function changeColor() { \t\t// This is our event handler function\n\tthis.style.backgroundColor = \"yellow\";\n}", "title": "" }, { "docid": "4b2aded5d754e2e39711d7e296c67d9f", "score": "0.5861282", "text": "function setDrawingColor(event){\n sketchController.color = this.value;\n}", "title": "" }, { "docid": "526c3bf2f976335300fc6ec99288a0c7", "score": "0.58610845", "text": "function changeColorE2()\n{\n var e = document.getElementById(\"edit-line\");\n var r = document.getElementById(\"colorRedE2\").value;\n var g = document.getElementById(\"colorGreenE2\").value;\n var b = document.getElementById(\"colorBlueE2\").value;\n e.style.backgroundColor = \"rgba(\" + r + \", \" + g + \", \" + b + \",0.7)\";\n}", "title": "" }, { "docid": "16cb7302d0f1433d75212c5c3345025d", "score": "0.5855266", "text": "function setCurrentColor(color) {\n currentColor = color;\n}", "title": "" }, { "docid": "261e66c24114a0bc8f62c6f3dd6c5288", "score": "0.58536917", "text": "function colorRect(leftX, topY, width, height, drawColor) {\n canvasContext.fillStyle = drawColor\n canvasContext.fillRect(leftX, topY, width, height,)\n}", "title": "" }, { "docid": "d4eb1cd62eb02224cf800ef73552273a", "score": "0.58484024", "text": "function updateColor(){\n var r = getNumber(\"red\");\n var g = getNumber(\"green\");\n var b = getNumber(\"blue\");\n setProperty(\"colorNew\",\"background-color\",rgb(r,g,b));\n penRGB(r,g,b,1);\n\n}", "title": "" }, { "docid": "e24eb248061af09aecd09d9bc0dfaf3c", "score": "0.5843676", "text": "function changeColor() {\n userCircle.style.backgroundColor = \"rgb(\" + red.value + \", \" + green.value + \", \" + blue.value + \")\";\n redValue.innerHTML = red.value;\n greenValue.innerHTML = green.value;\n blueValue.innerHTML = blue.value;\n mobileColorInfo.innerHTML = \"Red: \" + red.value + \", Green: \" + green.value + \", Blue: \" + blue.value;\n}", "title": "" }, { "docid": "b9c28f9cbe168cd1a54209bde2484fc5", "score": "0.58370936", "text": "function updateColors() {\n var r = rSlider.get('value'),\n g = gSlider.get('value'),\n b = bSlider.get('value'),\n rgbStr = Y.Color.fromArray([r,g,b], Y.Color.TYPES.RGB);\n\n color.setStyle('backgroundColor', rgbStr);\n }", "title": "" }, { "docid": "8e242dd1af79b4dcb9adf213681e155c", "score": "0.5814224", "text": "constructor (rectangle, color={ r: 255, g: 0, b: 0, a: 255 }) {\n super(color)\n\n this.rectangle = rectangle\n }", "title": "" }, { "docid": "7594a2d6cd20357848a84349a2e19974", "score": "0.58042574", "text": "function colorSelected(self) {\n const color = colorSelection.value;\n self.target.style.backgroundColor = color;\n}", "title": "" }, { "docid": "933c789590e4499563929d9c3fb64981", "score": "0.5790768", "text": "function changeColor() {\n this.style.background = selectedColor;\n var hexColor = rgb2hex(this.style.background);\n this.dataset.index = colorArry.indexOf(hexColor.toUpperCase());\n // console.log(this.style.background);\n }", "title": "" }, { "docid": "f85fe4d41ab4ba8f11ec093c7e0287d8", "score": "0.5789818", "text": "color(color, palette_name, onRect = true) {\n return this.style({ fill: this.getColor(color, palette_name) }, onRect);\n }", "title": "" }, { "docid": "f4fdb447e6ca44e14a8988626f2489bf", "score": "0.57873607", "text": "function draw() {\n let selectedColor = colorInput.val();\n $(this).css(\"background-color\") == hexToRgb(selectedColor) ?\n $(this).css('background-color', '') : $(this).css('background-color', selectedColor);\n}", "title": "" }, { "docid": "fe28f0d9672f7deb5cc6cdc045a94772", "score": "0.57807076", "text": "function changeColor(){\n\tvar r = $(\"#red\").val();\n\tvar g = $(\"#green\").val();\n\tvar b = $(\"#blue\").val();\n\t$(\"span\").css(\"backgroundColor\", \"rgb(\" + r + \",\" + g + \",\" + b + \")\");\n}", "title": "" }, { "docid": "1f49f8c1b2e7203290a1fb2f2fa6335a", "score": "0.5776304", "text": "function colorRect(leftX, topY, width, height, drawColor) {\n canvasContext.fillStyle = drawColor;\n canvasContext.fillRect (leftX, topY, width, height);\n}", "title": "" }, { "docid": "5a946cfe46bd34be5fe2bf789e6ea4d6", "score": "0.57620746", "text": "function changeColors(color){\n\t//percorrer todo o quadrado\n\tfor(var i = 0; i < squares.length; i++) {\n\t\t//mude cada cor para corresponder a determinada cor\n\t\tsquares[i].style.backgroundColor = color;\n\t}\n}", "title": "" }, { "docid": "af553f745645df50774db79340298ee9", "score": "0.576169", "text": "function colorRect(leftX, topY, width, height, drawColor) {\n canvasContext.fillStyle = drawColor;\n canvasContext.fillRect(leftX, topY, width, height);\n}", "title": "" }, { "docid": "f377d7618e69655c32e188943a9d452c", "score": "0.5760164", "text": "setColor(color) {\n this.context.fillStyle = color;\n this.context.strokeStyle = color;\n }", "title": "" }, { "docid": "6591ae15ce051beb7eed60efca6defca", "score": "0.5751217", "text": "function changeColors(color){\n\t\tfor(var i = 0; i < squares.length; i++){\n\t\t\t\tsquares[i].style.backgroundColor = pickedColor;\n\t\t\t}\n}", "title": "" }, { "docid": "71d0077b73807d75ab6d229cc3d996ef", "score": "0.57369125", "text": "function colorRect(leftX,topY,width,height,drawColor) {\n\tcanvasContext.fillStyle = drawColor;\n\tcanvasContext.fillRect(leftX, topY, width, height, drawColor);\n}", "title": "" }, { "docid": "7b624a15c0f8fca4fa4a9354aafa0fa1", "score": "0.57331115", "text": "function changeColor(event) {\n // get the clicked id\n var id = event.target.id;\n var idNum = parseInt(id.split(\"-\")[1]);\n\n // highlight that id\n highlight(idNum);\n\n // set the board\n board = require('./Board.js');\n board.changeColor(idNum);\n}", "title": "" }, { "docid": "03b8e6c5e41be78d038b674285e06619", "score": "0.57265294", "text": "function colorRect(X,Y,width,height,drawColor)\n{\n canvasContext.fillStyle = drawColor;\n canvasContext.fillRect(X,Y,width,height);\n}", "title": "" }, { "docid": "55283854615ef703a01bdcc1c30a6a89", "score": "0.57212985", "text": "function changeColor(color) {\n // TODO: fill this out\n}", "title": "" }, { "docid": "71f029263030452d5c2d44770cc7ddbd", "score": "0.5720183", "text": "set setColor(color){\n\t\tthis.color = color;\n\t}", "title": "" }, { "docid": "4b18b2996940812d71b370d5f226e7e1", "score": "0.5714237", "text": "setColor(string) {\n this.textBlock.color = string;\n }", "title": "" }, { "docid": "12c7e1f22eb5b0a44f51590ae41ca717", "score": "0.5693428", "text": "function setRegionColor() {\n\tvar reg = currentColorRegion;\n\tvar hexColor = $('#fillColorPicker').val();\n\tvar red = parseInt( hexColor.substring(1,3), 16 );\n\tvar green = parseInt( hexColor.substring(3,5), 16 );\n\tvar blue = parseInt( hexColor.substring(5,7), 16 );\n\n\treg.path.fillColor.red = red / 255;\n\treg.path.fillColor.green = green / 255;\n\treg.path.fillColor.blue = blue / 255;\n\treg.path.fillColor.alpha = $('#alphaSlider').val() / 100;\n\n\t// update region tag\n\t$(\".region-tag#\" + reg.uid + \">.region-color\").css('background-color','rgba('+red+','+green+','+blue+',0.67)');\n\n\t// update stroke color\n\tswitch( $('#selectStrokeColor')[0].selectedIndex ) {\n\t\tcase 0:\n\t\treg.path.strokeColor = \"black\";\n\t\tbreak;\n\t\tcase 1:\n\t\treg.path.strokeColor = \"white\";\n\t\tbreak;\n\t\tcase 2:\n\t\treg.path.strokeColor = \"red\";\n\t\tbreak;\n\t\tcase 3:\n\t\treg.path.strokeColor = \"green\";\n\t\tbreak;\n\t\tcase 4:\n\t\treg.path.strokeColor = \"blue\";\n\t\tbreak;\n\t\tcase 5:\n\t\treg.path.strokeColor = \"yellow\";\n\t\tbreak;\n\t}\n\t$('#colorSelector').css('display', 'none');\n}", "title": "" }, { "docid": "08629afc5b2fce5bc3e23931ba1ef026", "score": "0.5688612", "text": "function eraseColor() {\n selectedColor = \"#ffffff\";\n }", "title": "" }, { "docid": "a9205cb8343d566819614abbd160c35f", "score": "0.5679329", "text": "function drawColoredRectangle() {\n\nlet colorChoice= prompt(\"Please choose color.\");\n const canvas = document.getElementById('canvas3');\n const ctx = canvas.getContext('2d');\n ctx.clearRect(0, 0, canvas.width, canvas.height);\n\n let rectColor;\n if(colorChoice===\"black\"){\n rectColor=\"#000000\";\n }\n if(colorChoice===\"blue\"){\n rectColor=\"#0000FF\";\n }\n if(colorChoice===\"green\"){\n rectColor=\"#00FF40\";\n }\n if(colorChoice===\"orange\"){\n rectColor=\"#FF8000\";\n }\n if(colorChoice===\"purple\"){\n rectColor=\"#8000FF\";\n }\n if(colorChoice===\"red\"){\n rectColor=\"#FF0000\";\n }\n if(colorChoice===\"yellow\"){\n rectColor=\"#FFFF00\";\n }\n\n\n\n ctx.fillStyle = rectColor;\n ctx.fillRect(10, 10, 100, 50);\n\n}", "title": "" }, { "docid": "d7d5f2e7156d13cbb7cae1f499441b69", "score": "0.56721103", "text": "function changeColor () {\n newColor = getNewColor();\n $(\"#newColor\").css(\"background-color\", newColor);\n}", "title": "" }, { "docid": "4a03707f0cb7809b055c8c304a0a4d38", "score": "0.5668368", "text": "bgColorChanged(value){\n this.style['backgroundColor'] = value;\n }", "title": "" }, { "docid": "5652dc2e09aa3eb0e489f955987e49a7", "score": "0.5667724", "text": "function setColor(){\n var src = document.getElementById('color-picker');\n var r = document.querySelector(':root');\n r.style.setProperty('--color', src.value);\n }", "title": "" }, { "docid": "6981e1c18bf10407590aab170231e6c1", "score": "0.5664465", "text": "function changeColors(){\n\tfor(var i=0; i< squares.length; i++){\n\t\tsquares[i].style.backgroundColor= pickedColor;\n\t}\n}", "title": "" }, { "docid": "9689cbbcc46efc9e45184f10ddb7ba90", "score": "0.5659136", "text": "function drawColoredRectangle() {\n //Define variables\n let ctx = document.getElementById(\"canvas3\").getContext(\"2d\");\n let color = prompt(\"Enter a Color:\")\n let inval = 0;\n\n //Determine Color and Print Rectangle\n if(color == \"black\" || color ==\"blue\" || color == \"green\" || color == \"orange\" || color == \"purple\" || color == \"red\" || color == \"yellow\"){\n ctx.fillStyle = color;\n ctx.clearRect(0, 0, 1024, 128);\n ctx.fillRect(10, 10, 100, 50);\n }else{\n alert(color + \" is not a supported color\");\n ctx.clearRect(0, 0, 1024, 128);\n }\n}", "title": "" }, { "docid": "110dbc319a4d1d4f91e10ee9641e4603", "score": "0.5655761", "text": "function setColor(row, col, color) {\n var box = getBox(row, col);\n box.style.backgroundColor = color;\n}", "title": "" }, { "docid": "bdcf2a0530ce32c12fbd08966dadd41e", "score": "0.5652837", "text": "function showColor(){\n vtx.fillStyle = penColor;\n vtx.fillRect(0, 0, 100, 100);\n document.getElementById('textColor').value = penColor;\n}", "title": "" }, { "docid": "df07ee970dd57298756a9ebc9b5daf91", "score": "0.565242", "text": "function reflectColorChange(color){\ncolorPicker.val(color);\nhexBox.val(color);\nhexR.val(getRgb(color, r));\nhexG.val(getRgb(color, g));\nhexB.val(getRgb(color, b));\nrangeR.val(getRgb(color, r));\nrangeG.val(getRgb(color, g));\nrangeB.val(getRgb(color, b));\n}", "title": "" }, { "docid": "4f67ee520f810eb7f9d467794319a1e1", "score": "0.56493515", "text": "setColor(col){\n this.color = col\n console.log(`Color of the circle is changed to ${col}`)\n }", "title": "" }, { "docid": "c0059e7fcfb69f5670ef63632cc12081", "score": "0.5644659", "text": "function changeColor(color) {\n drawQ3(color);\n drawQ4(color);\n drawQ5(color);\n}", "title": "" }, { "docid": "6b21f275f4f1ae7a9810d8bb95f6d773", "score": "0.5637591", "text": "function changeColor(){\n var r = $('#red').val();\n var g = $('#green').val();\n var b = $('#blue').val();\n $('#newColor').css('background-color' , \"rgb(\" + r + \",\" + g + \",\" + b + \")\");\n}", "title": "" }, { "docid": "719b980df717f532fd9220493e761aac", "score": "0.5637471", "text": "function setColor() {\n // reset active colors\n var brushes = document.querySelectorAll(\".brush\");\n for ( var i = 0; i < brushes.length; i++ ) {\n brushes[i].classList.remove( \"active\" );\n }\n\n // add active color flag to the element that was clicked\n this.classList.add( \"active\" );\n }", "title": "" }, { "docid": "c60a0664e3d46a875312635dc0386bf8", "score": "0.5622346", "text": "function updateColour(selectedColour) {\n\tcolor = \"#\" + selectedColour;\n\tcanvas.freeDrawingBrush.color = color;\n\tlastPenColor = color;\n}", "title": "" }, { "docid": "823a95a1e570bccf9fedb273745bcfa3", "score": "0.5622065", "text": "function changeColor(eve){\r\n eve.target.style.backgroundColor = cellColor.value;\r\n}", "title": "" }, { "docid": "ae3a336fe79e074a7ab45f1ce668ace8", "score": "0.562004", "text": "function setColor(rgb) {\n if (rgb === undefined) {\n return;\n }\n\n $scope.color.r = rgb[0];\n $scope.color.g = rgb[1];\n $scope.color.b = rgb[2];\n }", "title": "" }, { "docid": "c67f4103241da3ed85b08c58e0a95a06", "score": "0.56186616", "text": "function functionBlue() {\n document.getElementById(\"tile-color-change\").style.backgroundColor = \"#0000ff\";\n }", "title": "" }, { "docid": "2bed727c8c16226e561834a966ffbccd", "score": "0.5618119", "text": "function changeColor(e){\n e.target.style.background = 'blue';\n }", "title": "" }, { "docid": "596138ac2797705a0efabbfbad2e3420", "score": "0.56127524", "text": "drawRect(rect) {\n this.context.fillStyle = '#ffffff';\n this.context.fillRect(rect.left, rect.top, rect.size.x, rect.size.y);\n }", "title": "" }, { "docid": "2c91bc33f5ec48c7098b36d287cb10a0", "score": "0.5612734", "text": "function changeColor(color) {\n\t// Loop through colors\n\tfor(var i = 0; i < squares.length; i++) {\n\t\tsquares[i].style.background = color;\n\t\t\n\t}\n}", "title": "" }, { "docid": "0aefff40ef48156a1eab52a11daf2531", "score": "0.5611726", "text": "function red_click() {\n\tcontext.strokeStyle = red;\n\tcolour = red;\n}", "title": "" }, { "docid": "a781a11e1a7b81dc19b06420ff1213c8", "score": "0.56056076", "text": "function changeColors(color){\n\t//loop through all squares\n\tfor(var i = 0; i < squares.length; i++)\n\t{\n\t\tsquares[i].style.background = color;\n\t}\n}", "title": "" }, { "docid": "82ff0f1c557469a5ca7abccdde2b4009", "score": "0.560552", "text": "boxcolor(val) {\n this._boxcolor = val;\n return this;\n }", "title": "" }, { "docid": "e7de1402104774be617ef6e5abd17855", "score": "0.5604231", "text": "function changeColors(color) {\n\tfor (var i = 0; i < squares.length; i++)\n\t\tsquares[i].style.backgroundColor = color;\n}", "title": "" }, { "docid": "225f95796a0c1dc8d3c035d801c96911", "score": "0.5591598", "text": "setBackgroundColor(valueNew){this.__combobox.setBackgroundColor(valueNew)}", "title": "" }, { "docid": "225f95796a0c1dc8d3c035d801c96911", "score": "0.5591598", "text": "setBackgroundColor(valueNew){this.__combobox.setBackgroundColor(valueNew)}", "title": "" }, { "docid": "d5e6842e574981f74b84df8e82a3d924", "score": "0.55882394", "text": "updateColor() {\n if(this.isConnected) {\n swimClient.downlinkValue().hostUri(this.swimUrl).nodeUri('/settings/color').laneUri('rgbw')\n .didSet((value)=> {\n const color = value.toAny();\n this.setColor(color);\n }).open();\n }\n }", "title": "" }, { "docid": "3429f9a97afadcfa14a1bb76c6f85774", "score": "0.55842614", "text": "function colorPickerValue(v)\n{ \n document.getElementById(\"storySectionArea\").style.background=v;\n colorValue=v;\n}", "title": "" }, { "docid": "5b92797af8db2e92fe6ac7b2e17523c0", "score": "0.5581213", "text": "function changeColor(color)\r\n{\r\n\t// loop through all squares\r\n\tfor(var i=0; i<colors.length; i++)\r\n\t{\r\n\t// change each color to match one\r\n\tsquares[i].style.backgroundColor=color;\r\n\t}\r\n}", "title": "" }, { "docid": "86ff6dec5dfa7d29760c43c6c1859a87", "score": "0.5578811", "text": "function changeColor() {\n // var sheet = document.createElement('style');\n // sheet.innerHTML = \"div {color: red}\";\n // document.body.appendChild(sheet);\n document.getElementById('color-div').style.color = \"red\";\n }", "title": "" }, { "docid": "ff1ee2225efffc7e376fb8741f9543f2", "score": "0.5578256", "text": "clickStyle() {\n if (this.inRect) {\n fill(this.bgColor);\n rect(this.posX, this.posY, this.width, this.height, this.CORNER_RADIUS);\n fill(255, 255, 255, 75);\n rect(this.posX, this.posY, this.width, this.height, this.CORNER_RADIUS);\n fill(this.textColor);\n } else {\n fill(this.textColor);\n }\n }", "title": "" }, { "docid": "4cc0097166130ef4f86832ede7875988", "score": "0.55745745", "text": "function changeColor() {\r\n context.strokeStyle = colorSelector.options[colorSelector.selectedIndex].value;\r\n}", "title": "" }, { "docid": "5c9ec8f31560582803cdf1d003e38f59", "score": "0.5573437", "text": "setColour(...args) {\r\n this.native.setColour.apply(this.native, args)\r\n }", "title": "" }, { "docid": "5c9ec8f31560582803cdf1d003e38f59", "score": "0.5573437", "text": "setColour(...args) {\r\n this.native.setColour.apply(this.native, args)\r\n }", "title": "" }, { "docid": "c17fa9fe44182a4b9e902eaeb46e16fd", "score": "0.55692405", "text": "function colorRect(topLeftX,topLeftY, boxWidth,boxHeight, fillColor) {\n\tcanvasContext.fillStyle = fillColor;\n\tcanvasContext.fillRect(topLeftX,topLeftY, boxWidth,boxHeight);\n}", "title": "" }, { "docid": "ec604f8a131a7ff536ad3dda40fcc836", "score": "0.5566554", "text": "drawRectangle(rectangle) {\n this.context.fillStyle = '#fff';\n this.context.fillRect(rectangle.left, rectangle.top,\n rectangle.size.x, rectangle.size.y);\n }", "title": "" }, { "docid": "199c7d013fb69ac25186bd9cfed0b664", "score": "0.55618495", "text": "function textChangeColor(rgba) {\n canvas.getActiveObject().set({\n fill: rgba\n });\n}", "title": "" }, { "docid": "7479f70c7ff9c7f7918ec29646f6a183", "score": "0.5557672", "text": "function colorChange() {\n this.style.backgroundColor = \"red\";\n}", "title": "" }, { "docid": "01d0dd3cb4ae50b365509c69fd4b1efb", "score": "0.55524415", "text": "update() {\n\n //plug in our colors here\n fill(this.color1, this.color2, this.color3);\n\n // this.counter++;\n\n //draw our rectangle\n rect(0, 250, 400, 50);\n\n\n }", "title": "" }, { "docid": "58d217e9a1fa25173d2acbd120476b2f", "score": "0.55516714", "text": "function changeBackground(e) {\n e.target.style.backgroundColor = color.value;\n}", "title": "" }, { "docid": "0de3b59ad5d7b3167f1ed1c5ad98f421", "score": "0.55511767", "text": "function changeColor_() {\n\n if (this.classList.contains(classes.circle.state.enabled)) {\n\n return dropColor_();\n\n }\n\n dropColor_();\n\n nodes.colorSwitchers.map(function (switcher, index) {\n\n switcher.classList.add(classes.circle.state.disabled);\n\n });\n\n this.classList.remove(classes.circle.state.disabled);\n\n this.classList.add(classes.circle.state.enabled);\n\n window.localStorage.setItem(localStorageBadges.color, this.dataset.style);\n\n document.body.classList.add(classes.colorSwitchers[this.dataset.style]);\n\n }", "title": "" }, { "docid": "a1bcf02b0da0803d7abb60428df03d48", "score": "0.55495644", "text": "function changeColor(color) {\r\n //loop through all the squares\r\n for (var i = 0; i < square.length; i++) {\r\n square[i].style.backgroundColor = color;\r\n }\r\n}", "title": "" }, { "docid": "429b7b64cdf6fe64cd35ea1c73aa6dff", "score": "0.5546599", "text": "function changeColors(color) {\n\tfor (var i = 0; i < numSquares; i++) {\n\t\tsquares[i].style.backgroundColor = color;\n\t}\n}", "title": "" }, { "docid": "5fef1992bcfa4cc6bf80dfff2b6daf8e", "score": "0.5546186", "text": "function changeColor(evt) {\n evt.target.style.backgroundColor = chosenColor;\n}", "title": "" }, { "docid": "b467741bb51f0b9d4a057c74fb1114c2", "score": "0.5543459", "text": "function changeColor(newColor){\n\t\t\t\tvar newElement = document.getElementById(\"profile__para\");\n\t\t\t\tnewElement.style.color = newColor;\n\t\t\t}", "title": "" }, { "docid": "ac199fb4d2c3ec4322afb0b1664fc01d", "score": "0.5542706", "text": "applyColor() {\n const color = this.formatColor(this.state.color);\n document.body.style.background = color;\n }", "title": "" } ]
a21ea6ca9405aee53d2014e12f165c2a
Checks at most 3 bytes at the end of a Buffer in order to detect an incomplete multibyte UTF8 character. The total number of bytes (2, 3, or 4) needed to complete the UTF8 character (if applicable) are returned.
[ { "docid": "a55003491e80ade915c7811e89e2ed49", "score": "0.0", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0; else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" } ]
[ { "docid": "9cc749e1b02573d2c656118d13028531", "score": "0.8211957", "text": "function utf8CheckIncomplete(self,buf,i){var j=buf.length-1;if(j<i)return 0;var nb=utf8CheckByte(buf[j]);if(nb>=0){if(nb>0)self.lastNeed=nb-1;return nb;}if(--j<i||nb===-2)return 0;nb=utf8CheckByte(buf[j]);if(nb>=0){if(nb>0)self.lastNeed=nb-2;return nb;}if(--j<i||nb===-2)return 0;nb=utf8CheckByte(buf[j]);if(nb>=0){if(nb>0){if(nb===2)nb=0;else self.lastNeed=nb-3;}return nb;}return 0;}// Validates as many continuation bytes for a multi-byte UTF-8 character as", "title": "" }, { "docid": "9cc749e1b02573d2c656118d13028531", "score": "0.8211957", "text": "function utf8CheckIncomplete(self,buf,i){var j=buf.length-1;if(j<i)return 0;var nb=utf8CheckByte(buf[j]);if(nb>=0){if(nb>0)self.lastNeed=nb-1;return nb;}if(--j<i||nb===-2)return 0;nb=utf8CheckByte(buf[j]);if(nb>=0){if(nb>0)self.lastNeed=nb-2;return nb;}if(--j<i||nb===-2)return 0;nb=utf8CheckByte(buf[j]);if(nb>=0){if(nb>0){if(nb===2)nb=0;else self.lastNeed=nb-3;}return nb;}return 0;}// Validates as many continuation bytes for a multi-byte UTF-8 character as", "title": "" }, { "docid": "07afa0c99e5e7dab784a443b1bc1153a", "score": "0.8134167", "text": "function utf8CheckByte(byte){if(byte<=0x7F)return 0;else if(byte>>5===0x06)return 2;else if(byte>>4===0x0E)return 3;else if(byte>>3===0x1E)return 4;return byte>>6===0x02?-1:-2;}// Checks at most 3 bytes at the end of a Buffer in order to detect an", "title": "" }, { "docid": "07afa0c99e5e7dab784a443b1bc1153a", "score": "0.8134167", "text": "function utf8CheckByte(byte){if(byte<=0x7F)return 0;else if(byte>>5===0x06)return 2;else if(byte>>4===0x0E)return 3;else if(byte>>3===0x1E)return 4;return byte>>6===0x02?-1:-2;}// Checks at most 3 bytes at the end of a Buffer in order to detect an", "title": "" }, { "docid": "8e197149990e2cec356641120b128773", "score": "0.8054132", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n\n return nb;\n }\n\n return 0;\n} // Validates as many continuation bytes for a multi-byte UTF-8 character as", "title": "" }, { "docid": "8e197149990e2cec356641120b128773", "score": "0.8054132", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n\n return nb;\n }\n\n return 0;\n} // Validates as many continuation bytes for a multi-byte UTF-8 character as", "title": "" }, { "docid": "8e197149990e2cec356641120b128773", "score": "0.8054132", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n\n return nb;\n }\n\n return 0;\n} // Validates as many continuation bytes for a multi-byte UTF-8 character as", "title": "" }, { "docid": "111b2d3fb78c10f0311704911e16c694", "score": "0.78436166", "text": "function utf8CheckByte(_byte) {\n if (_byte <= 0x7F) return 0;else if (_byte >> 5 === 0x06) return 2;else if (_byte >> 4 === 0x0E) return 3;else if (_byte >> 3 === 0x1E) return 4;\n return _byte >> 6 === 0x02 ? -1 : -2;\n} // Checks at most 3 bytes at the end of a Buffer in order to detect an", "title": "" }, { "docid": "111b2d3fb78c10f0311704911e16c694", "score": "0.78436166", "text": "function utf8CheckByte(_byte) {\n if (_byte <= 0x7F) return 0;else if (_byte >> 5 === 0x06) return 2;else if (_byte >> 4 === 0x0E) return 3;else if (_byte >> 3 === 0x1E) return 4;\n return _byte >> 6 === 0x02 ? -1 : -2;\n} // Checks at most 3 bytes at the end of a Buffer in order to detect an", "title": "" }, { "docid": "5791d455e948dc157ccc02735e0acb1c", "score": "0.7795907", "text": "function $393d8937d0a68c14$var$utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = $393d8937d0a68c14$var$utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = $393d8937d0a68c14$var$utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = $393d8937d0a68c14$var$utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;\n else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "8af38769ae2a3a3ce69cd05ab892bf01", "score": "0.77768767", "text": "function utf8CheckByte(byte) {\n if (byte <= 0x7F) return 0;else if (byte >> 5 === 0x06) return 2;else if (byte >> 4 === 0x0E) return 3;else if (byte >> 3 === 0x1E) return 4;\n return byte >> 6 === 0x02 ? -1 : -2;\n} // Checks at most 3 bytes at the end of a Buffer in order to detect an", "title": "" }, { "docid": "77dea71644e9766020a1585406d45410", "score": "0.7754668", "text": "function $0b4b8223d505c909$var$utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = $0b4b8223d505c909$var$utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = $0b4b8223d505c909$var$utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = $0b4b8223d505c909$var$utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;\n else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "db27efb4ffd81e1860edd823ff13793a", "score": "0.77503836", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "dd06fbd200a01dc9274448752db398c8", "score": "0.7706715", "text": "function utf8CheckExtraBytes(self, buf, p) {\n if ((buf[0] & 0xC0) !== 0x80) {\n self.lastNeed = 0;\n return '\\ufffd';\n }\n\n if (self.lastNeed > 1 && buf.length > 1) {\n if ((buf[1] & 0xC0) !== 0x80) {\n self.lastNeed = 1;\n return '\\ufffd';\n }\n\n if (self.lastNeed > 2 && buf.length > 2) {\n if ((buf[2] & 0xC0) !== 0x80) {\n self.lastNeed = 2;\n return '\\ufffd';\n }\n }\n }\n} // Attempts to complete a multi-byte UTF-8 character using bytes from a Buffer.", "title": "" }, { "docid": "dd06fbd200a01dc9274448752db398c8", "score": "0.7706715", "text": "function utf8CheckExtraBytes(self, buf, p) {\n if ((buf[0] & 0xC0) !== 0x80) {\n self.lastNeed = 0;\n return '\\ufffd';\n }\n\n if (self.lastNeed > 1 && buf.length > 1) {\n if ((buf[1] & 0xC0) !== 0x80) {\n self.lastNeed = 1;\n return '\\ufffd';\n }\n\n if (self.lastNeed > 2 && buf.length > 2) {\n if ((buf[2] & 0xC0) !== 0x80) {\n self.lastNeed = 2;\n return '\\ufffd';\n }\n }\n }\n} // Attempts to complete a multi-byte UTF-8 character using bytes from a Buffer.", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" }, { "docid": "526c7cc8b6d4f33a6ef9762b361f562c", "score": "0.7694404", "text": "function utf8CheckIncomplete(self, buf, i) {\n var j = buf.length - 1;\n if (j < i) return 0;\n var nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 1;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) self.lastNeed = nb - 2;\n return nb;\n }\n if (--j < i || nb === -2) return 0;\n nb = utf8CheckByte(buf[j]);\n if (nb >= 0) {\n if (nb > 0) {\n if (nb === 2) nb = 0;else self.lastNeed = nb - 3;\n }\n return nb;\n }\n return 0;\n}", "title": "" } ]
bb87e81e96d55d5b461ee54e0fc60834
Limpia formulario y elemento donde se muestra el resultado
[ { "docid": "a2f1e943ac1f637748c541cc6300294d", "score": "0.0", "text": "function cleanData (){\n document.getElementById(\"num\").value = \"\" ;\n }", "title": "" } ]
[ { "docid": "2f071424fcb25152d3b78eb1aeb6bb24", "score": "0.67638755", "text": "function ocultarFormulario() {\n\t\tget('nombresC').value = '';\n\t\tget('apellidosC').value = '';\n\t\tget('numeroCasaC').value = '';\n\t\tget('numeroTrabajoC').value = '';\n\t\tget('correoC').value = '';\n\t\tget(\"formulario\").style.display = 'none';\n\n\t}", "title": "" }, { "docid": "de82e734860a4734b7d0f70aaa36ca95", "score": "0.67336696", "text": "function limpiar_formulario(){\n //se limpian los campos del formulario\n $(\"#cliente\").empty();\n $(\"#producto\").empty();\n $(\"#detalle_venta .fila\").empty();\n\n }", "title": "" }, { "docid": "a9534301ad174ba15253055e1b10926b", "score": "0.6689471", "text": "function limpiarFormulario(){\n\t$('#id').val('');\n\t$('#tituloLabor').val('');\n\t$('#descripcionLabor').val('');\n\t$('#etiquetaLabor').val('');\n\t$('#letraLabor').val('');\n}", "title": "" }, { "docid": "5833d469738a95bca4b930429a121ea5", "score": "0.64680386", "text": "function Pagamento_limparForm()\n{\n\t$('#pagamento-id').val('');\n\t$('#pagamento-descricao').html('');\n\t$('#pagamento-parcelas').html('<option>1</option>');\n\t$('#pagamento-valor').val('');\n}", "title": "" }, { "docid": "9e562dcf55fcd96fe22f4ecdb6f53487", "score": "0.6421439", "text": "function limpiarFormulario() {\n document.getElementById(\"descripcion\").value = \"\";\n document.getElementById(\"monto\").value = \"\";\n document.getElementById(\"tipo\").value = \"\";\n document.getElementById(\"categoria\").value = \"\";\n document.getElementById(\"fecha\") ? document.getElementById(\"fecha\").value = \"\" : '';\n}", "title": "" }, { "docid": "378adfc2c2f81929811adfa7b32ef72c", "score": "0.63429457", "text": "function alumno_llenarFormaDetalles(result) {\n $(\"input#noMatricula\").val(result.noMatricula);\n }", "title": "" }, { "docid": "25a06c26a2c55fd8466b558857d87a7b", "score": "0.6333347", "text": "function limpiarForm(){\n productoItem.value = \"\";\n cantidadItem.value = \"\";\n precioItem.value = \"\";\n}", "title": "" }, { "docid": "669b0dff71a5db583dd9550042d3bca1", "score": "0.63212544", "text": "function limpiar_formulario(){\n\n //se limpian los campos del formulario\n $(\"#nombres_cliente\").val(\"\");\n $(\"#apellidos_cliente\").val(\"\");\n $(\"#telefono_cliente\").val(\"\");\n $(\".imagen\").attr('src', '');\n $(\"#celular_cliente\").val(\"\");\n $(\"#email_cliente\").val(\"\");\n $(\"#num_documento_cliente\").val(\"\");\n $(\"#foto_cliente\").val(\"\");\n $(\".imagen\").remove();\n }", "title": "" }, { "docid": "6ce44a59793d0681ba9b93f0f78e262a", "score": "0.6235826", "text": "function limpiarFormulario() {\n formulario.nombre.value = \"\";\n formulario.apellido.value = \"\";\n formulario.dni.value = \"\";\n cajasText.forEach((element) => {\n establecerBorde(element, \"controles__texto incompleto\");\n });\n}", "title": "" }, { "docid": "3269601b25c3748a9304ddd3644563d7", "score": "0.6188843", "text": "function limpia_formulario(){\n $(\"#UnidadNegocio\").val(\"\");\n $(\"#Laboratorio\").val(\"\"); \n}", "title": "" }, { "docid": "5dc52c18af716115695156951fb40c81", "score": "0.61800975", "text": "function fncLimpiarFormulario(frm,obj){ \n\tfrm.reset(); obj.focus(); \n}", "title": "" }, { "docid": "e92b780bfec02973a8e5dbe7a1123b2f", "score": "0.6125001", "text": "function handleOnLimpiarBusquedaPersona() {\n let busquedaNombre = document.getElementById(\"busquedaNombre\");\n recargarLista(personas);\n busquedaNombre.value = \"\";\n hasFilter=false;\n}", "title": "" }, { "docid": "d2a287c360d6bcb9c6fde9eeab749d58", "score": "0.6090416", "text": "function adaugaFormular(){\r\n\t\t\t adauga('nume').value = '';\r\n\t\t\t adauga('email').value = '';\r\n\t\t\t adauga('telefon').value = '';\r\n\t\t\t adauga('data').value = '';\r\n\t\t\t adauga('timp').value = '';\r\n\t\t\t adauga('evenimentul').value = '';\r\n\t\t\t adauga(\"formular\").style.display='none';\r\n\t\t\t}", "title": "" }, { "docid": "78fe07c847cb0cc5af3855be06b62f6c", "score": "0.6071378", "text": "function rellenarFormulario(){\n\n \n\n}", "title": "" }, { "docid": "a2e6ba755503143de89ff087ec797330", "score": "0.60124797", "text": "function limpaCampos() {\n limpaFormulario('formFatoObservado');\n}", "title": "" }, { "docid": "c2eac005fcb9b31c97cd458c6323a44f", "score": "0.6004783", "text": "function recetear_generico(tabla){\n $('#'+tabla)[0].reset();\n $('#'+tabla).find(':input[type=\"hidden\"]').each(function() {\n $(this).val('');\n });\n}", "title": "" }, { "docid": "05dbcd9c5ae2f1f943bc719571735f2f", "score": "0.6000407", "text": "function limpiarCampos(){\n $(\"#titulo\").val(\"\");\n $(\"#descripcion\").val(\"\");\n $(\"#fecha-inicio\").val(\"\");\n $(\"#hora-inicio\").val(\"\");\n $(\"#fecha-fin\").val(\"\");\n $(\"#hora-fin\").val(\"\");\n $('#tipo').val(\"1\");\n $('#tipo').material_select();\n}", "title": "" }, { "docid": "ca3022eeaf39c3b1bd62d8005639c804", "score": "0.59936637", "text": "function limpiarFormulario() {\n document.getElementById(\"resultado1\").innerHTML = \"\";\n document.getElementById(\"resultado2\").innerHTML = \"\";\n document.getElementById(\"resultado3\").innerHTML = \"\";\n document.getElementById(\"resultado4\").innerHTML = \"\";\n document.getElementById(\"resultado5\").innerHTML = \"\";\n document.getElementById(\"resultado6\").innerHTML = \"\";\n document.getElementById(\"resultado7\").innerHTML = \"\";\n document.getElementById(\"resultado8\").innerHTML = \"\";\n document.getElementById(\"resultado9\").innerHTML = \"\";\n document.getElementById(\"resultado10\").innerHTML = \"\";\n document.getElementById(\"resultado11\").innerHTML = \"\";\n document.getElementById(\"resultado12\").innerHTML = \"\";\n document.getElementById(\"resultado13\").innerHTML = \"\";\n document.getElementById(\"resultado14\").innerHTML = \"\";\n\n}", "title": "" }, { "docid": "f6e54be290cc569523fd0d7793d7c9ed", "score": "0.59933794", "text": "function LimpiarFormApoderado() {\n console.log(\"DATOS APODERADO PARA LIMPIAR\");\n console.log(correoAp.val());\n console.log(nombresAp.val());\n console.log(apellidosAp.val());\n let vacio = \"\";\n correoAp.val(vacio);\n nombresAp.val(vacio);\n apellidosAp.val(vacio);\n}", "title": "" }, { "docid": "c94257c894cfd2e0ef0d5342466da02a", "score": "0.59540087", "text": "function limpaCampo(){\n \n document.getElementById('field-id').value = '';\n document.getElementById('field-name').value = '';\n document.getElementById('field-pedido').value = '';\n document.getElementById('field-quantidade').value = '';\n\t document.getElementById('field-Detalhes').value = '';\n\t\n}", "title": "" }, { "docid": "49bc8917169972df5ddd42815456e828", "score": "0.5953726", "text": "function limpiarCamposForm(idForm){\n\n idForm.each (function(){\n \n this.reset();\n\n });\n\n }", "title": "" }, { "docid": "71982e714c6afb9fcdad1e6f7064a07b", "score": "0.5944582", "text": "function limpaCampoSemNome(){\n \n document.getElementById('field-id').value = '';\n document.getElementById('field-pedido').value = '';\n document.getElementById('field-quantidade').value = '';\n\t document.getElementById('field-Detalhes').value = '';\n\t\n}", "title": "" }, { "docid": "7495d7c5497d3444c8fd037ec58ae7a6", "score": "0.592926", "text": "function limpiarFormulario() {\n $('#codigo').val('');\n $('#codigo').prop(\"disabled\", false);\n $('#nombres').val('');\n $('#lugar_nacimiento').val('');\n $('#fecha_nacimiento').val('');\n $('#direccion').val('');\n $('#telefono').val('');\n $('#puesto').val('');\n $(\"#estado\").val($(\"#estado option:first\").val()); \n\n}", "title": "" }, { "docid": "94b5e49d1f927a901664eed4e06367bb", "score": "0.59223956", "text": "reset() {\n $(\"[name=narration]\", this.form).value = \"\";\n $(\"[name=payee]\", this.form).value = \"\";\n $$(\".metadata-row\", this.form).forEach(el => {\n el.remove();\n });\n $$(\".posting\", this.form).forEach(el => {\n el.remove();\n });\n this.addPosting();\n this.addPosting();\n this.form.focus();\n }", "title": "" }, { "docid": "920e2410257dfb2ba38fac03cdd0b563", "score": "0.5903477", "text": "resetForm(){\n document.getElementById('productoFormulario').reset();\n }", "title": "" }, { "docid": "c5ba9fc9b5591e6d6d408579e5875b75", "score": "0.58866334", "text": "function resetear(boton) {\n frm_elements = boton.form;\n for (i = 0; i < frm_elements.length; i++) {\n field_type = frm_elements[i].type.toLowerCase();\n switch (field_type) {\n case \"text\":\n case \"password\":\n case \"textarea\":\n case \"hidden\":\n frm_elements[i].value = \"\";\n break;\n case \"radio\":\n case \"checkbox\":\n if (frm_elements[i].checked) {\n frm_elements[i].checked = false;\n }\n break;\n case \"select-one\":\n case \"select-multi\":\n frm_elements[i].selectedIndex = 0;\n break;\n default:\n break;\n }\n }\n}", "title": "" }, { "docid": "dd8c224fab5a8e4b1337a5e8f0174b2a", "score": "0.5863766", "text": "function getObject(){\n\t\tvar formObject = domForm.toObject( 'formArchivo' + aleatorio );\n\t\tif (idDepto.item != null){\n\t\t\tformObject.idDepto = idDepto.item.idDepto;\n\t\t}\n\t\tif (idAbogado.item != null){\n\t\t\tformObject.idAbogado = idAbogado.item.idAbogado;\n\t\t}\n\t\treturn formObject;\n\t}", "title": "" }, { "docid": "2879d885e4f1a71b15082b4cf0f63c56", "score": "0.58567977", "text": "function RecarregaDadosFormulario() {\n RemoverNotificacaoEspecifica(notificacao_protocolo);\n disabledAllFields(false);\n\n TornarEditavel(ListStatusDaLinha, false);\n TornarEditavel(LookAssunto, false);\n TornarEditavel(LookDetalhe, false);\n\n PortoConecta.IdentificacaoPositiva.IdentificacaoPositiva();\n Form_onLoad();\n}", "title": "" }, { "docid": "848294f2e467f225d78612251c9fc715", "score": "0.5847955", "text": "function limparCampoPesquisa(nomeForm, nomeCampo) {\r\n var campo = document.forms[nomeForm].elements[nomeCampo];\r\n campo.value = \"\";\r\n}", "title": "" }, { "docid": "590e8025251938c27df78593dc269729", "score": "0.58412707", "text": "function limpiar() {\n\n\t\t\t//$('#idinputcantidad').val('');\t\n\t\t\t//$('#idinputpcompra').val('');\t\n\t\t\t//$('#idinputpventa').val('');\t\n\n\t\t}//fin del metodo limpiar", "title": "" }, { "docid": "e43daa2aecb79da0d4a54921f1ea19d5", "score": "0.58324885", "text": "function populateJs2Form(){\n\t//Primero determinamos el modo en el que estamos;\n\tvar mode = getMMGMode(get('pedTipoSolicViewFrm.accion'), \n\t\tget('pedTipoSolicViewFrm.origen'));\n\n\n\tset('pedTipoSolicViewFrm.id', jsPedTipoSolicViewId);\n\tset('pedTipoSolicViewFrm.codTipoSoli', jsPedTipoSolicViewCodTipoSoli);\n\tset('pedTipoSolicViewFrm.indCons', jsPedTipoSolicViewIndCons);\n\tset('pedTipoSolicViewFrm.indSoliNega', jsPedTipoSolicViewIndSoliNega);\n\tset('pedTipoSolicViewFrm.indDevo', jsPedTipoSolicViewIndDevo);\n\tset('pedTipoSolicViewFrm.indAnul', jsPedTipoSolicViewIndAnul);\n\tset('pedTipoSolicViewFrm.codGrupSoli', jsPedTipoSolicViewCodGrupSoli);\n\tif(mode == MMG_MODE_CREATE || mode == MMG_MODE_UPDATE_FORM){\n\t\tunbuildLocalizedString('pedTipoSolicViewFrm', 1, jsPedTipoSolicViewDescripcion)\n\t\tloadLocalizationWidget('pedTipoSolicViewFrm', 'Descripcion', 1);\n\t}else{\n\t\tset('pedTipoSolicViewFrm.Descripcion', jsPedTipoSolicViewDescripcion);\t\t\n\t}\n\t\n}", "title": "" }, { "docid": "10b6cd1b8ac87b9316343b21a0d18e80", "score": "0.58290493", "text": "function cloneField(){\n //duplica o campo .schedule-item\n const newFieldsContainer = document.querySelector('.schedule-item').cloneNode(true)\n\n //limpa os campos\n const fields = newFieldsContainer.querySelectorAll('input')\n\n fields.forEach(function(field) {\n field.value = \"\"\n });\n \n //e coloca na pagina\n document.querySelector('#schedule-items').appendChild(newFieldsContainer)\n}", "title": "" }, { "docid": "29fae3d0e420ba282ba4338f32d200e3", "score": "0.58174616", "text": "function limpiarFormulario() {\n\ttry{\n\t\t/*var iSeleccionadoP = new Array();\n\t\tset('frmGenerarCronograma2.cbPaises',iSeleccionadoP);*/\n\t\n\t\tvar iSeleccionadoM = new Array();\n\t\tset('frmGenerarCronograma2.cbMarcas',iSeleccionadoM);\n\t\n\t\tvar iSeleccionado = new Array();\n\t\tset('frmGenerarCronograma2.cbCanales',iSeleccionado);\n\t\n\t\tvar iSeleccionadoPER = new Array();\n\t\tset('frmGenerarCronograma2.cbCodigosDelPeriodo',iSeleccionadoPER);\n\t\t\n\t\t//focaliza('frmGenerarCronograma2.cbPaises');\n\t\tfocaliza('frmGenerarCronograma2.cbMarcas');\n\t\t\n\t\t\n\t\t//set('frmGenerarCronograma2.hPais','');\n\t\tset('frmGenerarCronograma2.hMarca','');\n\t\tset('frmGenerarCronograma2.hCanal','');\n\t\taccion('frmGenerarCronograma2.cbCodigosDelPeriodo','.disabled=true');\n\t\t\n\t\tdocument.all.tags(\"INPUT\")(\"btnBuscar\").disabled = true;\n\t\tvisibilidad('miscroll', 'O');\t\n\t}\n\tcatch(e){}\n\t\n\t\t\t\n}", "title": "" }, { "docid": "37d28c054b2d26435da4042317bd6e65", "score": "0.5816371", "text": "function LimpiarCampos(){\n $(\"#fecha_nacimiento\").html(\"\");\n $(\"#titulo\").html(\"\");\n $(\"#descripcion_reina\").html(\"\");\n $(\"#origen_reina\").html(\"\");\n $(\"#edad_reina\").html(\"\");\n $(\"#instalado\").html(\"\");\n $(\"#estado\").html(\"\");\n $(\"#raza\").html(\"\");\n}", "title": "" }, { "docid": "d4bcbc047d9f1dbf29996391ec42c663", "score": "0.5813212", "text": "function gestioneResetForm () {\n // Oltre al default, lego anche questo\n var attivitaIvaIntracomunitario = $(\"#attivitaIvaIntracomunitarioDocumento_aggiornamento\");\n var registroIvaIntracomunitario = $(\"#registroIvaIntracomunitarioDocumento_aggiornamento\");\n var campiConValoreOriginario = $(\"[data-original-value]\");\n\n // Se sono disabilitati, non li tocco. Altrimenti li cancello\n attivitaIvaIntracomunitario.prop(\"disabled\") || attivitaIvaIntracomunitario.val(\"\");\n registroIvaIntracomunitario.prop(\"disabled\") || registroIvaIntracomunitario.val(\"\");\n\n // Mantengo i valori originali\n campiConValoreOriginario.each(function(idx, el) {\n var $this = $(el);\n var isDate = $this.is(\"[data-date]\");\n var originalValue = $this.data(\"originalValue\");\n var derivedValue = originalValue;\n if(isDate) {\n // Sono una data. Dato che ci sono problemi di conversione con Java, prendo direttamente il time (come numero) dal campo e lo converto in data\n derivedValue = formatDate(new Date(parseInt(originalValue, 10)));\n }\n $this.val(derivedValue);\n });\n }", "title": "" }, { "docid": "ca228c752fd57091bb6fda207831205e", "score": "0.58128595", "text": "function limpiar(){\n $(\"#txtIdsorteo\").val(\"\")\n $(\"#txtnombresorteo\").val(\"\")\n $(\"#txtpreciosorteo\").val(\"\")\n $(\"#txtnumeroboletosorteo\").val(\"\")\n $(\"#txtcantidadboletos\").val(\"\")\n }", "title": "" }, { "docid": "060d9f95f2ebf7861939e0ddd2491636", "score": "0.58101004", "text": "function formBuscarMedico(){\n\t\t//El usuario puede elegir una especialidad y ver las consultas de esa especialidad\n\t\tvar listado = listadoEspecialidades(doctores);\n\t\tvar resultado = $(\"#buscarEspecialidad\");\n\t\tvar form \t= '<form>'\n\t\t\t\t\t\t+\t'<hr>'\n\t\t\t\t\t \t+ '<label for=\"BuscarPorEspecialidad1A\" >Buscar por Especialidad</label>';\n\t\t\t\t\t \t//listamos los id de cada consulta del paciente\n\t\t\t\tform += '<select class=\"form-control\" name=\"selEspecialidad\" id=\"BuscarPorEspecialidad1A\">'\n\t\t\t\t\t\t\t+ '<option selected=\"selected\" value=\"empty\">Sel. Especialidad</option>';\n\t\t\t\t\t\t//ofrecemos un listado de especialidades disponibles\n\t\t\t\t\t\tfor(var i = 0 ; i < listado.length ; i++ ){\n\t\t\t\tform += '<option value=' + '\\\"' + listado[i] + '\\\"' + '>' + listado[i] + '</option>';\t\n\t\t\t\t};\t\n\t\t\t\tform +=\t'</select>'\n\t\t\t\t+\t'<br >';\n\n\n\t\t\t\tform +=\t'<label for=\"BuscarPorEspecialidad1B\" >Descripcion</label>'\n\t\t\t\t\t\t+\t'<textarea class=\"form-control\" id=\"BuscarPorEspecialidad1B\" disabled ></textarea>'\n\t\t\t\t\t\t+\t'<br >'\n\t\t \t+\t'</form>';\n\t\t form \t+= '<div class=\"text-center\" id=\"resultadosBuscarEspecialidad\">'\t\n\t\t\t\t + '<p class=\"panel panel-default resultado\" id=\"presentarConsultaEspecialidad\"></p>'\n\t\t\t\t \n\t\t\t +\t'</div>';\n\t\tresultado.html(form);\n\t\t$(\"#BuscarPorEspecialidad1A\").on(\"change\",busquedadeEspecialidades);\n\n}", "title": "" }, { "docid": "a2243a8709fba284ee7f979124555f43", "score": "0.58097637", "text": "clearFields(){\n Form.description.value=\"\"\n Form.amount.value=\"\"\n Form.date.value=\"\"\n }", "title": "" }, { "docid": "0856ff674bf0ff7990dc7847aab25c5f", "score": "0.57990646", "text": "function cargarModalObjetivo(){\n \n //reset al formulario ->limpiar el form\n document.getElementById(\"formPersonal\").reset();\n //abrir modal\n $(\"#formPersonal\").modal('show');\n \n }", "title": "" }, { "docid": "f8f61de58aedb73e7ab29b37e9b536cf", "score": "0.5777474", "text": "function limpiarPedidos() {\n this.form.inputCodigoPedido = '';\n this.form.inputCodigoProducto = '';\n this.form.inputCantidad = '';\n this.form.inputValor = '';\n this.form.inputFecha = '';\n this.refrescarFormulario();\n\n}", "title": "" }, { "docid": "e62773bd5897dc4acd614509645f6873", "score": "0.5748012", "text": "function formCrearConsulta(){\n\tvar listado = listadoEspecialidades(doctores);\n\t//listamos las especialidades disponibles\n\n\t//formulario para crear consulta\n\tvar form = '<form>'\n\t\t\t+ '<hr>'\n\t\t \t+ '<label for=\"crear1A\" >Especialidad</label>';\n\tform += '<select class=\"form-control\" name=\"selEspecialidad\" id=\"crear1A\">'\n\t\t+ '<option selected=\"selected\" value=\"empty\">Sel. Especialidad</option>';\n\t//ofrecemos un listado de especialidades disponibles\n\tfor(var i = 0 ; i < listado.length ; i++ ){\n\t\tform += '<option value=' + '\\\"' + listado[i] + '\\\"' + '>' + listado[i] + '</option>';\t\n\t};\t\n\n\tform +=\t'</select>'\n\t\t+\t'<br >';\n\n\tform \t+='<label for=\"crear1B\" >Medico</label>'\n\t\t+ '<select class=\"form-control\" name=\"selEspecialidad\" id=\"crear1B\">'\n\t\t+ '<option selected=\"selected\" value=\"empty\">Sel. Medico</option>';\n//una vez que el paciente elige especialidad, la funcion buscarMedicos busca los medicos de esa especialidad y las presenta en el dropdown.\n\n\n\tform\t+=\t'</select>'\n\t\t+\t'<br >';\n\n\t\n\tform +=\t'<label for=\"crear1C\" >Descripcion</label>'\n\t\t+\t'<textarea class=\"form-control\" id=\"crear1C\"></textarea>'\n\t\t+\t'<br >'\n \t+ '<input type=\"button\" class=\"form-control btn-primary\" value=\"Ingresar\" id=\"btnCrear\">'\n \t+\t'</form>';\n form += '<div class=\"text-center\" id=\"resultadosCrearConsulta\">'\t\n + '<p class=\"panel panel-default resultado\" id=\"resultadoCrearConsulta\"></p>'\n +\t'</div>'; \t\n\n var crearConsulta = $(\"#crearConsulta\");\n crearConsulta.html(form);\n\n\n //eventos de los formularios crear Consulta\n\tvar especialidadCrear = $(\"#crear1A\");\n\t//una vez elegida la especialidad da los medicos de esa especialidad\n\tespecialidadCrear.on(\"change\", buscarMedicos);\n\n\tvar btnCrearConsulta = $(\"#btnCrear\");\n\tbtnCrearConsulta.on(\"click\", crearNuevaConsulta);\n\n\n\n}", "title": "" }, { "docid": "bf01ee1d1b194da5e72d3b69abc85fa2", "score": "0.57338965", "text": "function limparCampos()\n{\n $(\"input, select\").value('');\n}", "title": "" }, { "docid": "56bb99ab9e5bbe0340d78eec224a49e0", "score": "0.5729831", "text": "function restablecer(){\n $(\"#Codigo\").val(\"\");\n $(\"#Nombre\").val(\"\");\n $(\"#Nota\").val(\"\");\n }", "title": "" }, { "docid": "afe86c5d0d59f15f5a909c112a558bae", "score": "0.5726429", "text": "function limpiar(elemento) {\n elemento.value = \"\";\n}", "title": "" }, { "docid": "711976f2fe21f892486a07a94792034e", "score": "0.57236564", "text": "function cloneField(){\n const newFieldContainer = document.querySelector(\".schedule-item\").cloneNode(true)\n // cloneNode irá clonar o que estiver dentro do querySelector\n\n const fields = newFieldContainer.querySelectorAll(\"input\")\n fields.forEach(function(field){\n field.value = \"\"\n })\n\n\n document.querySelector(\"#schedule-itens\").appendChild(newFieldContainer)\n // appendChild irá adicionar um elemento filho ao elemento que estiver dentro do querySelector. Iremos adicionar o elemento que foi clonado no cloneNode acima.\n}", "title": "" }, { "docid": "7ab90067cfeb254bdb5ab2419040fb94", "score": "0.57177556", "text": "clearFormValues(){\n this[this.formObject].fields.forEach(val=>{\n // set modelds to their default value\n val.value = val.default\n })\n }", "title": "" }, { "docid": "f4af296538f2d523ac555076a456303b", "score": "0.5697427", "text": "function resetPresidentForm(){\n acField.setValue('');\n descripcionField.setValue('');\n }", "title": "" }, { "docid": "67751eccd5566908984f48bfda44fef9", "score": "0.5693958", "text": "function limpiezaGeneral(){\n document.form.reset();\n document.fnewdoct.reset();\n document.fnewpac.reset();\n}", "title": "" }, { "docid": "2b4b4cd70474b7f95b19dceebc1ccd7e", "score": "0.5686799", "text": "function returnObject(form, nome){\r\n\tvar retorno;\r\n\tfor(indice = 0; indice < form.elements.length; indice++){\r\n\t\tcampo = form.elements[indice];\r\n\t\tif (campo.name == nome){\r\n\t\t\tretorno = campo;\r\n\t\t\tbreak;\r\n\t\t}\r\n\t}\r\n\treturn retorno;\r\n}", "title": "" }, { "docid": "4e202587380260ef9a079dba1740b46e", "score": "0.5676596", "text": "function actualizaFormularioEntrada(tipo) {\n let form = document.querySelector(\"#\" + tipo + \"Entradas\");\n // Oculta o muestra el número de personas y quita las butacas seleccionadas\n form.querySelector(\"#personasGrupal\").closest(\".col-4\").style.display = form.querySelector(\"#tipoEntrada1\").checked ? \"block\" : \"none\";\n form.querySelectorAll(\".seleccionada\").forEach(sel => sel.classList.remove(\"seleccionada\"));\n form.querySelector(\"#totalEntrada\").value = 0; // Reinicia a 0 el precio si el usuario no ha selccionado ninguna butaca.\n form.querySelector(\"#personasGrupal\").value = 0; // Reinicia a 0 el numero de personas si el usuario no ha selccionado ninguna butaca.\n\n // Elimina las butacas o las muestra\n form.querySelectorAll(\".fila1, .fila2, .fila3, .fila4\").forEach(ap => { ap.children.length == 0 ? ap.style.display = \"none\" : ap.style.display = \"initial\" });\n form.querySelectorAll(\".platea, .anfiteatro, .paraiso, .palco\").forEach(ap => { representacionSeleccionada.value == \"0\" ? ap.style.display = \"none\" : ap.style.display = \"grid\" });\n}", "title": "" }, { "docid": "92822a0a5cdf205dca68c9e64f7fe2df", "score": "0.56760633", "text": "function limpiarAgregarEstudiante() {\n\n $(\"#documentoEstudiante\").val(\"\");\n $(\"#nombreEstudiante\").val(\"\");\n $(\"#apellidoEstudiante\").val(\"\");\n $(\"#fechaNacimiento\").val(\"\");\n $(\"#direccion\").val(\"\");\n $(\"#telefono\").val(\"\");\n $(\"#correo\").val(\"\");\n}", "title": "" }, { "docid": "edef8251e8cc7d96d6b31293ca94d179", "score": "0.5671748", "text": "function limpiarformularioproyecto(formulario){\n\tif(confirm('¿Desea borrar todo el contenido del formulario?')){\t\n\t\tformulario.localizacion_academia.value='';\n\t\tformulario.sociedad_constituida.value='';\n\t\tformulario.fecha_constitucion_sociedad.value='';\t\t\n\t\tformulario.sistemaproductivo.value='';\n\t\tformulario.tecnologiaaplicada.value='';\n\t\tformulario.telefono.value='';\n\t\tformulario.emailcontacto.value='';\n\t\tformulario.web.value='';\n\t\tformulario.url_linkedin.value='';\n\t\tformulario.url_twitter.value='';\n\t\tformulario.url_facebook.value='';\n\t\tformulario.url_googleplus.value='';\t\n\t\tformulario.alternativas_actuales.value='';\t\t\n\t\tformulario.alternativas_actuales.value='';\t\t\n\t\tformulario.alternativas_actuales.value='';\t\t\n\t\tformulario.nombreproyecto.value='';\n\t\tformulario.tuidea.value='';\n\t\tformulario.problema_cliente.value='';\n\t\tformulario.solucion_problema.value='';\n\t\tformulario.cliente_potencial.value='';\n\t\tformulario.propuesta_valor.value='';\n\t\tformulario.alternativas_actuales.value='';\n\t\tformulario.competidor.value='';\n\t\tformulario.modelonegocio.value='';\n\t\tformulario.producto.value='';\n\t\tformulario._keyancla.value='#subsubmit'; \n\t\tformulario._keycokey.value='bot_xestec_parcial';\n\t\tformulario.submit();\n\t}\n}", "title": "" }, { "docid": "a5eb99f25dd777f6ecc1f26694a87fcf", "score": "0.5662208", "text": "function limpiar(){\n $('#tarea_descripcionTarea').val('');\n $('#tarea_fechaCreacion').val('');\n $('#tarea_fechafinalizacion').val('');\n }", "title": "" }, { "docid": "f1e0d5806ce7cba00377c702dce8063d", "score": "0.56604797", "text": "function crear_fila(div_delete, ultimo){\n // Obtener campos\n lista = $($(\".item_estudios\")[0]).clone();\n $(\"#form_footer\").before(lista);\n // Limpiar los campos.\n limpiar = $(\".item_estudios\")[$(\".item_estudios\").length - 1];\n $(limpiar).find('.div_delete').html(div_delete);\n $(limpiar).find('input, select').each(function(i,v){\n nombre = $(v).attr('name');\n if(nombre != undefined){\n $(v).attr('name',nombre.replace('1', ultimo + 1));\n }\n $(v).val('').change();\n });\n}", "title": "" }, { "docid": "16afe602933d36cc16ede94f47426a5a", "score": "0.5657747", "text": "function setPessoaJuridicaForm(){\n\n //DOC\n $(\"#divCpf\").addClass(\"d-none\");\n $(\"#divCnpj\").removeClass(\"d-none\");\n\n //NOME\n $(\"#divNome\").addClass(\"d-none\");\n $(\"#divRazaoSocial\").removeClass(\"d-none\");\n\n\n}", "title": "" }, { "docid": "a327a9a2eaac3e10037e996f302af491", "score": "0.5657654", "text": "function imprimirEstudiante(estudiante) {\n let nombre = document.getElementById('nombre').value = estudiante.nombre_completo;\n let idetificacion = document.getElementById('idetificacion').value = estudiante.identificacion;\n let carrera = document.getElementById('carrera').value = estudiante.carrera;\n let semestre = document.getElementById('semestre').value = estudiante.semestre;\n}", "title": "" }, { "docid": "d6926493faa6d49d3585a906ebbec872", "score": "0.56543416", "text": "function populateJs2Form(){\n\t//Primero determinamos el modo en el que estamos;\n\tvar mode = getMMGMode(get('cobUsuarCobraViewFrm.accion'), \n\t\tget('cobUsuarCobraViewFrm.origen'));\n\n\n\tset('cobUsuarCobraViewFrm.id', jsCobUsuarCobraViewId);\n\tset('cobUsuarCobraViewFrm.fecUltiEsta', jsCobUsuarCobraViewFecUltiEsta);\n\tset('cobUsuarCobraViewFrm.indJefeCobr', jsCobUsuarCobraViewIndJefeCobr);\n\tset('cobUsuarCobraViewFrm.indUsuaSupe', jsCobUsuarCobraViewIndUsuaSupe);\n\tset('cobUsuarCobraViewFrm.indUsuaExte', jsCobUsuarCobraViewIndUsuaExte);\n\tset('cobUsuarCobraViewFrm.valTurnHoraEntr', jsCobUsuarCobraViewValTurnHoraEntr);\n\tset('cobUsuarCobraViewFrm.valTurnHoraSali', jsCobUsuarCobraViewValTurnHoraSali);\n\tset('cobUsuarCobraViewFrm.valObse', jsCobUsuarCobraViewValObse);\n\tset('cobUsuarCobraViewFrm.userOidUsuaCobr', [jsCobUsuarCobraViewUserOidUsuaCobr]);\n\tset('cobUsuarCobraViewFrm.paisOidPais', [jsCobUsuarCobraViewPaisOidPais]);\n\t\n}", "title": "" }, { "docid": "31d14b9bd614cbac5216a3bb0e7a031a", "score": "0.5653306", "text": "function Pagamento_setarNoForm(dadosPgto)\n{\n\t//Limpa o form\n\tPagamento_limparForm();\n\n\t$('#pagamento-id').val(dadosPgto.id);\n\t$('#pagamento-descricao').html(dadosPgto.descricao);\n\n\tvar optParc = '';\n\tfor (i=1; i <= dadosPgto.parcelas; i++){\n\t\toptParc += '<option>'+ i +'</option>';\n\t}\n\t$('#pagamento-parcelas').html(optParc);\n\n\t//Seta o Saldo a Pagar\n\tvar saldoPagar = accounting.unformat($('#lblSaldoPagar').html(), ',');\n\n\tif(!isNaN(saldoPagar)) {\n\t\t$('#pagamento-valor').val(saldoPagar.toFixed(2));\n\t}\n}", "title": "" }, { "docid": "72db6b493390acfa12003e8f66b6a425", "score": "0.56495005", "text": "function cloneField(){\n const newfield= document.querySelector('.schedule-item').cloneNode(true)//boolean: true or false\n const fields = newfield.querySelectorAll('input')\n \n fields.forEach(function(field){\n field.value=\"\"\n })\n document.querySelector('#schedele-items').appendChild(field)//colocar onde?\n\n}", "title": "" }, { "docid": "0f16c6e9938b188256271321ea1de16c", "score": "0.5647563", "text": "static limpliarCampos() {\n document.querySelector('#titulo').value = '';\n document.querySelector('#autor').value = '';\n document.querySelector('#id').value = '';\n }", "title": "" }, { "docid": "faa53b69823149d99af7f324646e466f", "score": "0.56462985", "text": "function clearFormData(object){\n object.searchTerm= \"\";\n object.recordLimit= 0;\n object.yearStart= 0;\n object.yearEnd= 0;\n\n // Uses the ID of our Default Option in our Select Element This Select Element should have it's first Option Element be empty text\n $(\"input\").empty();\n $(\"#default\").attr(\"selected\", \"selected\");\n}", "title": "" }, { "docid": "7dd765a4fa2d3cd7310f243fb30741a8", "score": "0.56448084", "text": "function obterDadosFormulario(formulario){\n\n cliente = {\n nome : formulario.nome.value,\n cidade : formulario.cidade.value,\n telefone : formulario.telefone.value,\n }\n\n return cliente\n\n }", "title": "" }, { "docid": "9fe1c979e34fde38ed131ac817476f02", "score": "0.56306154", "text": "function populateJs2Form(){\n\t//Primero determinamos el modo en el que estamos;\n\tvar mode = getMMGMode(get('cobEscalLiquiFrm.accion'), \n\t\tget('cobEscalLiquiFrm.origen'));\n\n\n\tset('cobEscalLiquiFrm.id', jsCobEscalLiquiId);\n\tset('cobEscalLiquiFrm.numOrdeEsca', jsCobEscalLiquiNumOrdeEsca);\n\tset('cobEscalLiquiFrm.impRangDesdImpo', jsCobEscalLiquiImpRangDesdImpo);\n\tset('cobEscalLiquiFrm.impRangHastImpo', jsCobEscalLiquiImpRangHastImpo);\n\tset('cobEscalLiquiFrm.valRangDesdPorc', jsCobEscalLiquiValRangDesdPorc);\n\tset('cobEscalLiquiFrm.valRangHastPorc', jsCobEscalLiquiValRangHastPorc);\n\tset('cobEscalLiquiFrm.impComiPorc', jsCobEscalLiquiImpComiPorc);\n\tset('cobEscalLiquiFrm.impComiImpo', jsCobEscalLiquiImpComiImpo);\n\tset('cobEscalLiquiFrm.valObse', jsCobEscalLiquiValObse);\n\tset('cobEscalLiquiFrm.melcOidMetoLiquCobr', [jsCobEscalLiquiMelcOidMetoLiquCobr]);\n\t\n}", "title": "" }, { "docid": "5cf2dce5637277c7282af4ea4135f6ec", "score": "0.5628621", "text": "function limpiarCampos() {\n document.getElementById(\"url\").value = \"\";\n document.getElementById(\"nombre\").value = \"\";\n document.getElementById(\"descripcion\").value = \"\";\n}", "title": "" }, { "docid": "ece143dccd1b2c9003ee87a87ad9a136", "score": "0.56237364", "text": "resetearForm() {\n document.querySelector(\"#nombreMascota\").value = \"\";\n document.querySelector(\"#nombrePropietario\").value = \"\";\n document.querySelector(\"#telefono\").value = \"\";\n document.querySelector(\"#fecha\").value = \"\";\n document.querySelector(\"#hora\").value = \"\";\n document.querySelector(\"#sintomas\").value = \"\";\n }", "title": "" }, { "docid": "658f88c3f6f2f29e6a334d44fd767442", "score": "0.5615177", "text": "@action\n addForm() {\n return super.addForm({ predicate: \"\", object: \"\", objType: \"\", predVocab: \"\", objVocab: \"\" });\n }", "title": "" }, { "docid": "60f29981ddad360a906fc793e8b56511", "score": "0.56138843", "text": "function formAsModel() {\n\t return { groups:[$('select[name=groups]').val()],\n\t\t stackgroups:[$('select[name=stackgroups]').val()],\n\t\t filters:[$('select[name=filters]').val()]\n\t\t };\n }", "title": "" }, { "docid": "8fde092f0608f2d8caf333c64244ce45", "score": "0.5605673", "text": "function afiseazaFormular(){//functia de adaugare eveniment si ascundere a formularului dupa adaugare\t\t\t\r\n\t\t\t evenim = new eveniment();\r\n\t\t\t evenim.nume = adauga('nume').value;\r\n\t\t\t evenim.email = adauga('email').value;\r\n\t\t\t evenim.telefon = adauga('telefon').value;\r\n\t\t\t evenim.data = adauga('data').value;\r\n\t\t\t evenim.timp = adauga('timp').value;\r\n\t\t\t evenim.evenimentul = adauga('evenimentul').value;\t\t\t \r\n\t\t\t if(evenim.nume != '' && evenim.email != '' && evenim.telefon != '' && evenim.data != '' && evenim.evenimentul != ''){\r\n\t\t\t\t evenimente[evenimente.length] = evenim;\r\n\t\t\t adaugaFormular();\r\n\t\t\t addEvenimente();\r\n\t\t\t\t }\r\n\t\t\t\telse\r\n\t\t\t\t{\r\n\t\t\t\t\talert(\"Toate campurile sunt obligatorii\");\r\n\t\t\t\t}\r\n\t\t\t}", "title": "" }, { "docid": "56bd055650bae70bfdca17f44d87505e", "score": "0.5598252", "text": "function populateJs2Form(){\n\n\t//Primero determinamos el modo en el que estamos;\n\n\tvar mode = getMMGMode(get('cobGuionArgumCabecFrm.accion'), \n\n\t\tget('cobGuionArgumCabecFrm.origen'));\n\n\n\n\n\n\tset('cobGuionArgumCabecFrm.id', jsCobGuionArgumCabecId);\n\n\tset('cobGuionArgumCabecFrm.codGuiaArgu', jsCobGuionArgumCabecCodGuiaArgu);\n\n\tif(mode == MMG_MODE_CREATE || mode == MMG_MODE_UPDATE_FORM){\n\n\t\tunbuildLocalizedString('cobGuionArgumCabecFrm', 1, jsCobGuionArgumCabecDescripcion)\n\n\t\tloadLocalizationWidget('cobGuionArgumCabecFrm', 'Descripcion', 1);\n\n\t}else{\n\n\t\tset('cobGuionArgumCabecFrm.Descripcion', jsCobGuionArgumCabecDescripcion);\t\t\n\n\t}\n\n\tset('cobGuionArgumCabecFrm.paisOidPais', [jsCobGuionArgumCabecPaisOidPais]);\n\n\tset('cobGuionArgumCabecFrm.valObse', jsCobGuionArgumCabecValObse);\n\n\t\n\n}", "title": "" }, { "docid": "d8d60b66481ac85f05bcb5f19d03365c", "score": "0.55965763", "text": "function crearNuevaConsulta(){\n\t//toma los valores de los inputs del formulario crear consulta\n\tvar valorEspecialidad = $(\"#crear1A\").val();\n\tvar valorMedico = $(\"#crear1B\").val();\n\tvar valorDescripcion = $(\"#crear1C\").val();\n\t//almacena el campo hmtl donde se presentara el resultado de la creacion de consult\n\tvar resultado =\t$(\"#resultadoCrear\");\n\t\t\n\t//Si el campo especialidad y medico no estan vacios\n\tif(valorEspecialidad !== \"empty\" && valorMedico !== \"empty\" ){\n\t//comienza a procesar los valores de los inputs.\n\n\t//El paciente ingresado es un objeto\n\t\tvar paciente = usuarioIngresado ;\n\t\t//buscamos el index del paciente dentro del array comparando la propiedad nombre completo \n\t\tvar pacienteIndex = buscarPacienteEnArray();\n\n\t\t//buscamos que medico es dentro del array de doctores mediate la propiedad nombre completo.\n\t\tvar medicoIndex = busquedaEnArrayObjetos(doctores,\"nombreCompleto\",valorMedico);\n\t\n\t\t//creamos una nueva consulta con el valor del index de pacientes, el index medico de doctores y una descripcion si la tiene.\n\t\tconsultas.push(new Consulta(pacienteIndex,medicoIndex,valorDescripcion));\n\t\t//muestra se actualizo las consultas\n\t\tmostrarTablaUsuarioConsultas();\n\n\t\t//luego de crear la consulta, vaciamos los inputs\n\t\t$('#crear1A, #crear1B, #crear1C ').val([])\n\t\t//Le damos un mensaje al usuario de que su consulta fue creada con exito.\n\t\t$(' #resultadoCrearConsulta ').html(\"Consulta creada \"+ valorMedico + \" lo atendera en unos momentos, gracias por su elecion\");\n\n\t}else{resultadoCrearConsulta\n\t\t//si no se eligio especialidad ni medico, se pide al usuario complete el formulario\n\t\t$(' #resultadoCrearConsulta ').html(\"Complete el formulario primero\");\n\t}\n}", "title": "" }, { "docid": "de03d92d85aef165fc5313e432b2bf03", "score": "0.5591051", "text": "function populateJs2Form(){\n\t//Primero determinamos el modo en el que estamos;\n\tvar mode = getMMGMode(get('preTipoOfertFrm.accion'), \n\t\tget('preTipoOfertFrm.origen'));\n\n\n\tset('preTipoOfertFrm.id', jsPreTipoOfertId);\n\tset('preTipoOfertFrm.canaOidCana', [jsPreTipoOfertCanaOidCana]);\n\tset('preTipoOfertFrm.codTipoOfer', jsPreTipoOfertCodTipoOfer);\n\tif(mode == MMG_MODE_CREATE || mode == MMG_MODE_UPDATE_FORM){\n\t\tunbuildLocalizedString('preTipoOfertFrm', 1, jsPreTipoOfertDescripcion)\n\t\tloadLocalizationWidget('preTipoOfertFrm', 'Descripcion', 1);\n\t}else{\n\t\tset('preTipoOfertFrm.Descripcion', jsPreTipoOfertDescripcion);\t\t\n\t}\n\t\n\t\t\t\n\t\t\tif(jsPreTipoOfertIndComi == \"true\") set('preTipoOfertFrm.indComi', 'S');\n\t\t\telse set('preTipoOfertFrm.indComi', 'N');\n\t\n\t\t\t\n\t\t\tif(jsPreTipoOfertIndPunt == \"true\") set('preTipoOfertFrm.indPunt', 'S');\n\t\t\telse set('preTipoOfertFrm.indPunt', 'N');\n\t\n\t\t\t\n\t\t\tif(jsPreTipoOfertIndEsta == \"true\") set('preTipoOfertFrm.indEsta', 'S');\n\t\t\telse set('preTipoOfertFrm.indEsta', 'N');\n\t\n\t\t\t\n\t\t\tif(jsPreTipoOfertIndMontMini == \"true\") set('preTipoOfertFrm.indMontMini', 'S');\n\t\t\telse set('preTipoOfertFrm.indMontMini', 'N');\n\t\n\t\t\t\n\t\t\tif(jsPreTipoOfertIndAporMontEsca == \"true\") set('preTipoOfertFrm.indAporMontEsca', 'S');\n\t\t\telse set('preTipoOfertFrm.indAporMontEsca', 'N');\n\t\n\t\t\t\n\t\t\tif(jsPreTipoOfertIndGrat == \"true\") set('preTipoOfertFrm.indGrat', 'S');\n\t\t\telse set('preTipoOfertFrm.indGrat', 'N');\n\t\n}", "title": "" }, { "docid": "37226f444876d4da665696248481a876", "score": "0.5589945", "text": "function limpiar()\r\n{\r\n\t$(\"#progra_id\").val(\"\");\r\n\t$(\"#progra_codigo\").val(\"\");\r\n\t$(\"#progra_nombre\").val(\"\");\r\n\t$(\"#progra_email\").val(\"\");\r\n}", "title": "" }, { "docid": "1558f76d3a5eaf00e18d3a7b90525f57", "score": "0.55859435", "text": "function TargetaFormulario() {\n\n\tthis.$clave = $('#clave')\n\n\tthis.$equipo= $(\"#id_equipo\")\n\tthis.$observaciones = $('#id_observaciones')\n\tthis.$motivo_cancelacion = $('#id_motivo_cancelacion')\n\tthis.$responsable = $('#id_responsable')\n\tthis.$solicitante = $('#id_solicitante')\n\n this.$estado = $('#id_estado')\n\n\tthis.$fecha_estimada_inicio = $('#id_fecha_estimada_inicio')\n\tthis.$fecha_estimada_fin = $('#id_fecha_estimada_fin')\n\tthis.$fecha_real_inicio = $('#id_fecha_real_inicio')\n\tthis.$fecha_real_fin = $('#id_fecha_real_fin')\n\n\tthis.$tab_actividades = $(\"#tab_actividades\")\n\tthis.$tab_materiales = $(\"#tab_materiales\")\n\tthis.$tab_servicios = $(\"#tab_servicios\")\n\tthis.$tab_mano_obra = $(\"#tab_mano_obra\")\n\n\tthis.$boton_arbol = $(\"#boton_arbol\")\n\t\n\tthis.init()\n}", "title": "" }, { "docid": "3d23c8f1fdc935cbf3e686acef675521", "score": "0.55823743", "text": "function BuscarMascota(id) {\n $(\"#indexModificar\").val(id.toString());\n var mascotasFiltradas;\n var mascotasString = localStorage.getItem(\"Mascotas\");\n var MascotasJSON = mascotasString == null ? [] : JSON.parse(mascotasString);\n mascotasFiltradas = MascotasJSON.filter(function (mascota) {\n return Number(mascota.id) === Number(id);\n })\n .map(function (mascota) {\n var m = new clases.Mascota(mascota.id, mascota.tipo, mascota.nombre, mascota.edad, mascota.patas);\n return m;\n });\n if (mascotasFiltradas.length < 2) {\n //Muestro los valores en los campos del form\n $(\"#txtId\").val(mascotasFiltradas[0].id);\n $(\"#txtNombre\").val(mascotasFiltradas[0].nombre);\n $(\"#txtEdad\").val(mascotasFiltradas[0].edad);\n $(\"#ddlTipo\").val(mascotasFiltradas[0].tipo);\n $(\"#txtPatas\").val(mascotasFiltradas[0].patas);\n //Pongo el ID readonly\n //$(\"#id_to_update\").val(mascotasFiltradas[0].id);\n $(\"#txtId\").prop('readonly', true);\n $(\"#txtNombre\").focus();\n }\n}", "title": "" }, { "docid": "29abcd02f09366232868038dd8c6b1a7", "score": "0.55782264", "text": "function formBuscarConsulta(){\n\tvar listado = listadoIdsConsultas(consultas);\n\t//listamos las ID de las consultas del usuario\n\n\t//formulario para buscar consulta\n\tvar form \t= '<form>'\n\t\t\t\t+\t'<hr>'\n\t\t\t \t+ '<label for=\"buscar1A\" >Consultas</label>';\n\t\t\t \t//listamos los id de cada consulta del paciente\n\t\tform \t+= '<select class=\"form-control\" name=\"Sel.Id\" id=\"buscar1A\">'\n\t\t\t\t+ '<option selected=\"selected\" value=\"Todas\">Todas Las consultas</option>'\n\t\t\t\t+ '<option value=\"Abiertas\">Abiertas</option>'\n\t\t\t\t+ '<option value=\"Finalizadas\">Finalizadas</option>';\n\t\tform\t+=\t'</select>'\n\t\t\t\t+\t'<br >';\n\n\t\tform +=\t'<label for=\"in1C\" >Descripcion</label>'\n\t\t\t\t+\t'<textarea class=\"form-control\" id=\"buscar1B\" disabled ></textarea>'\n\t\t\t\t+\t'<br >'\n \t+\t'</form>';\n form \t+= '<div class=\"text-center\" id=\"resultadosBuscarConsulta\">'\t\n \t\t+ '<p class=\"panel panel-default resultado\" id=\"resultadoBuscarConsulta\"></p>'\n\t\t + '<p class=\"panel panel-default resultado\" id=\"presentarConsultasUsuario\"></p>'\n\t\t \n\t +\t'</div>';\n\n\n\n var buscarConsulta = $(\"#buscarConsulta\");\n buscarConsulta.html(form);\n\t//mostramos las consultas generadas por el usuario;\n mostrarTablaUsuarioConsultas();\n\t//el usuario puede elegir que consultas quiere ver, todas, abiertas y finalizadas.\n\t$(\"#buscar1A\").on(\"change\",busquedaDeConsultas);\n\n\t \n}", "title": "" }, { "docid": "da18d2a8d7fc1f86d565396c6b19b940", "score": "0.5565195", "text": "function obtemInformacaoFormulario(form){\n //cria um objeto\n var paciente = {\n nome: form.nome.value,\n peso: form.peso.value,\n altura: form.altura.value,\n gordura: form.gordura.value,\n imc: calculaImc(form.peso.value, form.altura.value)\n }\n return paciente\n}", "title": "" }, { "docid": "7106f5a873800f215635582774c79c91", "score": "0.55513084", "text": "function limpiar(){\n $(\"#formparsley\")[0].reset();\n //Resetear las validaciones del formulario alta\n form = $(\"#formparsley\");\n form.parsley().reset();\n}", "title": "" }, { "docid": "9ad55baa6dcd229864568be904531f52", "score": "0.5551064", "text": "function TargetaFormulario() {\n\n this.$padre = $('#id_padre')\n this.$id = $('#id_equipo')\n this.$responsable = $('#id_responsable')\n this.$ubicacion = $(\"#id_ubicacion\")\n this.$contrato = $('#id_contrato')\n \n this.$imagen = $('#id_imagen')\n\tthis.$imagen_preview = $('#img_preview')\n\n this.$boton_editar_ubicacion = $(\"#btn_edit_ubicacion\")\n this.$boton_guardar = $('#boton_guardar')\n this.modal_ubicacion = new VentanaUbicacion()\n\n\tthis.init()\n}", "title": "" }, { "docid": "074cc8a099f6d8a33838f7304cb54285", "score": "0.5548659", "text": "function limpaFormaPagamentoFornecedor() {\n if ($scope.somaSubTotalFornecedores.length > 0 && $scope.StatusId == 23) {\n for (var i = 0; i < $scope.somaSubTotalFornecedores.length; i++) {\n $scope.somaSubTotalFornecedores[i].FormaPagtoId = null;\n }\n }\n }", "title": "" }, { "docid": "ece97755fdc69104d71b7b4bae817a22", "score": "0.55467755", "text": "function preencheFormulario(){\n if ((cadastro != undefined) && (cadastro != null)){\n dependentes = cadastro.Dependentes;\n preencheDependente();\n //Identificacao\n document.getElementById('txtCodigo').value = cadastro.CodigoCadastro;\n document.getElementById('txtChapa').value = cadastro.Chapa;\n document.getElementById('txtNome').value = cadastro.Nome;\n document.getElementById('txtDataNascimento').value = formataDataBrasileira(cadastro.DataNascimento);\n document.getElementById('txtEmail').value = cadastro.Email;\n document.getElementById('txtNomePai').value = cadastro.NomePai;\n document.getElementById('txtNomeMae').value = cadastro.NomeMae;\n document.getElementById('selEstadoNatal').value = cadastro.EstadoNatal;\n document.getElementById('selNaturalidade').value = cadastro.Naturalidade;\n document.getElementById('selNacionalidade').value = cadastro.Nacionalidade;\n document.getElementById('selEstadoCivil').value = cadastro.EstadoCivil;\n document.getElementById('selSexo').value = cadastro.Sexo;\n document.getElementById('selGrauInstrucao').value = cadastro.GrauInstrucao;\n document.getElementById('selCorRaca').value = cadastro.CorRaca;\n\n //Documento\n document.getElementById('txtCPF').value = formataCPF(cadastro.CPF);\n document.getElementById('txtIdentidade').value = cadastro.Identidade;\n document.getElementById('txtDataEmissaoIdentidade').value = formataDataBrasileira(cadastro.DataEmissaoIdentidade);\n document.getElementById('txtOrgaoEmissorIdentidade').value = cadastro.OrgaoEmissorIdentidade;\n document.getElementById('selUFIdentidade').value = cadastro.UFIdentidade;\n document.getElementById('txtNumeroCNH').value = cadastro.NumeroCNH;\n document.getElementById('selCategoriaCNH').value = cadastro.CategoriaCNH;\n document.getElementById('txtOrgaoEmissorCNH').value = cadastro.OrgaoEmissorCNH;\n document.getElementById('selEstadoCNH').value = cadastro.EstadoCNH;\n document.getElementById('txtDataEmissaoCNH').value = formataDataBrasileira(cadastro.DataEmissaoCNH);\n document.getElementById('txtDataVencimentoCNH').value = formataDataBrasileira(cadastro.DataVencimentoCNH);\n document.getElementById('txtNumeroCarteiraTrabalho').value = cadastro.NumeroCarteiraTrabalho;\n document.getElementById('txtSerieCarteiraTrabalho').value = cadastro.SerieCarteiraTrabalho;\n document.getElementById('selUFCarteiraTrabalho').value = cadastro.UFCarteiraTrabalho;\n document.getElementById('txtNumeroPIS').value = cadastro.NumeroPIS;\n document.getElementById('txtNumeroTituloEleitor').value = cadastro.NumeroTituloEleitor;\n document.getElementById('txtZona').value = cadastro.Zona;\n document.getElementById('txtSecao').value = cadastro.Secao;\n document.getElementById('txtDataEmissaoTituloEleitor').value = formataDataBrasileira(cadastro.DataEmissaoTituloEleitor);\n document.getElementById('txtOrgaoEmissaoRegistroEstrangeiro').value = cadastro.OrgaoEmissorRegistroEstrangeiro\n document.getElementById('txtDataEmissaoRegistroEstrangeiro').value = formataDataBrasileira(cadastro.DataEmissaoRegistroEstrangeiro);\n document.getElementById('txtDataChegada').value = formataDataBrasileira(cadastro.DataChegada);\n document.getElementById('txtDataNaturalizacaoEstrangeiro').value = formataDataBrasileira(cadastro.DataNaturalizacao);\n document.getElementById('txtPaisOrigem').value = cadastro.PaisOrigem;\n if (cadastro.ConjugeBrasil == 'S')\n document.getElementById('chbConjugeBrasil').checked = true;\n else\n document.getElementById('chbConjugeBrasil').checked = false;\n\n //Endereco\n document.getElementById('txtCep').value = formataCep(cadastro.Cep);\n document.getElementById('selTipoRua').value = cadastro.TipoRua;\n document.getElementById('txtRua').value = cadastro.Rua;\n document.getElementById('txtNumero').value = cadastro.Numero;\n document.getElementById('txtComplemento').value = cadastro.Complemento;\n // var tipoBairro = document.getElementById('selTipoBairro').value;\n document.getElementById('txtBairro').value = cadastro.Bairro;\n document.getElementById('txtCidade').value = cadastro.Cidade;\n document.getElementById('selEstado').value = cadastro.Estado;\n document.getElementById('selCodigoPaisEndereco').value = cadastro.CodigoPaisEndereco;\n document.getElementById('txtTelefoneContato1').value = formataTelefone(cadastro.TelefoneContato1);\n document.getElementById('txtTelefoneContato2').value = formataTelefone(cadastro.TelefoneContato2);\n document.getElementById('txtTelefoneContato3').value = formataTelefone(cadastro.TelefoneContato3);\n\n //Registro Profissional\n document.getElementById('txtNumeroRegistroProfissional').value = cadastro.NumeroRegistroProfissional;\n document.getElementById('txtCodigoOrgaoRegulamentador').value = cadastro.CodigoOrgaoRegulamentador;\n document.getElementById('selUFProfissao').value = cadastro.UFProfissao;\n document.getElementById('txtDataEmissaoProfissao').value = formataDataBrasileira(cadastro.DataEmissaoProfissao);\n }\n}", "title": "" }, { "docid": "6780adb2260d83431ac655b4610c82b6", "score": "0.55455023", "text": "function ocultarFormu(){\n $(\"#zonaPelicula\").hide();\n $(\"#zonaActuacion\").hide();\n $(\"#zonaDirectorActor\").hide();\n $(\"#selectDirector\").hide();\n $(\"#selectActor\").hide();\n $(\"#selectPelicula\").hide();\n $(\"#selectPeliculaActuacion\").hide();\n $(\"#anadirActuacion\").hide();\n $(\"#mas\").hide();\n }", "title": "" }, { "docid": "3e979cd3116d948824b2e4c0c9988778", "score": "0.5544474", "text": "function clearDatosContacto() {\n vm.contactoForm = {\n nombre:'',\n apellido: '',\n mail:'',\n consulta: ''\n }\n }", "title": "" }, { "docid": "bf9f14d55da94c552929b38485a3ce37", "score": "0.5539941", "text": "function limpar_campos()\n{\n\t$(\"input, select, textarea\").val('');\n}", "title": "" }, { "docid": "2fc1cb6f3dd26f3f4deee8a1ca9a82d7", "score": "0.5531916", "text": "function setPessoaFisicaForm(){\n //DOC\n $(\"#divCnpj\").addClass(\"d-none\");\n $(\"#divCpf\").removeClass(\"d-none\");\n \n //NOME\n $(\"#divRazaoSocial\").addClass(\"d-none\");\n $(\"#divNome\").removeClass(\"d-none\");\n \n}", "title": "" }, { "docid": "57b53c9d58aa7b9773550a7ad26fb0b4", "score": "0.5530789", "text": "function camposFormulario(){\n\tvar camposForm = [];\n\tif($('#nombres').length){\n\t\tvar nombres_field = $('#nombres');\n\t\tcamposForm.push(nombres_field);\n\t}\n\tif($('#apellidos').length){\n\t\tvar apellidos_field = $('#apellidos');\n\t\tcamposForm.push(apellidos_field);\n\t}\n\tif($('#fecha_nacimiento').length){\n\t\tvar fecha_nacimiento_field = $('#fecha_nacimiento');\n\t\tcamposForm.push(fecha_nacimiento_field);\n\t}\n\tif($('#genero').length){\n\t\tvar genero_field = $('#genero');\n\t\tcamposForm.push(genero_field);\n\t}\n\tif($('#pais').length){\n\t\tvar pais_field = $('#pais');\n\t\tcamposForm.push(pais_field);\n\t}\n\t// dependencias start\n\tif($('#provincia_content:visible').length == 1){\n\t\tif($('#provincia').length){\n\t\t\tvar provincia_field = $('#provincia');\n\t\t\tcamposForm.push(provincia_field);\n\t\t}\n\t}\n\tif($('#cantonnac_content:visible').length == 1){\n\t\tif($('#cantonnac').length){\n\t\t\tvar cantonnac_field = $('#cantonnac');\n\t\t\tcamposForm.push(cantonnac_field);\n\t\t}\n\t}\n\t// dependencias end\n\tif($('#estado_civil').length){\n\t\tvar estado_civil_field = $('#estado_civil');\n\t\tcamposForm.push(estado_civil_field);\n\t}\n\tif($('#nivel_instruccion').length){\n\t\tvar nivel_instruccion_field = $('#nivel_instruccion');\n\t\tcamposForm.push(nivel_instruccion_field);\n\t}\n\tif($('#profesion').length){\n\t\tvar profesion_field = $('#profesion');\n\t\tcamposForm.push(profesion_field);\n\t}\n\tif($('#ocupacion').length){\n\t\tvar ocupacion_field = $('#ocupacion');\n\t\tcamposForm.push(ocupacion_field);\n\t}\n\tif($('#provincia_res').length){\n\t\tvar provincia_res_field = $('#provincia_res');\n\t\tcamposForm.push(provincia_res_field);\n\t}\n\tif($('#canton_res').length){\n\t\tvar canton_res_field = $('#canton_res');\n\t\tcamposForm.push(canton_res_field);\n\t}\n\tif($('#parroquia_res').length){\n\t\tvar parroquia_res_field = $('#parroquia_res');\n\t\tcamposForm.push(parroquia_res_field);\n\t}\n\tif($('#correo').length){\n\t\tvar correo_field = $('#correo');\n\t\tcamposForm.push(correo_field);\n\t}\n\tif($('#aspiracion_salarial').length){\n\t\tvar aspiracion_salarial_field = $('#aspiracion_salarial');\n\t\tcamposForm.push(aspiracion_salarial_field);\n\t}\n\tif($('#terminos_condiciones').length){\n\t\tvar terminos_condiciones_field = $('#terminos_condiciones');\n\t\tcamposForm.push(terminos_condiciones_field);\n\t}\n\treturn camposForm;\n}", "title": "" }, { "docid": "bd4543c239f55798941b2d868b86245a", "score": "0.5522394", "text": "function reset(){\r\n //resetto l'input dell'utente\r\n $('input').val('');\r\n\r\n //svuoto il contenitore dei risultati\r\n $('.film-container.container').empty();\r\n\r\n }", "title": "" }, { "docid": "480780371052a409293dc9a970859edf", "score": "0.5518984", "text": "function borraCampos($scope) {\n\tdocument.getElementById(\"createForm\").reset();\n}", "title": "" }, { "docid": "f509d30c02f72dc642e9fe5b10d88042", "score": "0.5515934", "text": "function nuevoProyecto(cuadroOcultar, cuadroMostrar){\n\t\tcuadros(\"#cuadro1\", \"#cuadro2\");\n\t\t$(\"#form_proyecto_registrar\")[0].reset();\n\t\t$(\"#tableInmobiliariaRegistrar tbody tr\").remove(); \n\t\t$(\"#codigo_registrar\").focus();\n\t}", "title": "" }, { "docid": "86129566caf34690ced71ef26407d939", "score": "0.55006546", "text": "function resetEntrada() {\r\n numEntradas = 1;\r\n const object = document.querySelector('[data-entrada-box]');\r\n object.innerHTML = '<input type=\"text\" class=\"campo\" id=\"data-' + numEntradas + '\">';\r\n attEntrada();\r\n }", "title": "" }, { "docid": "b085e9038410d879d374bcd4cc31dcd7", "score": "0.550017", "text": "function resetPresidentForm(){\n calificacionField.setValue('');\n valorField.setValue('');\n periodoCombo.setValue(-1);\n }", "title": "" }, { "docid": "a1a29439d2ba9bddfbc06cdbb965b8b3", "score": "0.5495512", "text": "function limpiar_modal() {\n $('#formComision').val('');\n }", "title": "" }, { "docid": "0f1cbd0c8ab0d122197056bac1e186e8", "score": "0.54912484", "text": "function montaItem(formItem) {\n var item = {\n descricao: formItem.Descricao.value,\n rd: formItem.RD.value\n };\n\n return item\n}", "title": "" }, { "docid": "d056bf444158faa148791206bb206cd5", "score": "0.5491162", "text": "resetDataForm() {\n let me = this;\n\n // reset dữ liệu về rỗng\n me.form.find(\"[FieldName]\").val(\"\");\n\n me.form.find(\".notValidControl\").removeClass(\"notValidControl\");\n }", "title": "" }, { "docid": "cbe6ce77e1deed3781b42b0f4bdbf5f9", "score": "0.5490256", "text": "function rotioai_form_reset() {\n $('#advanced-search .form-item input').val('');\n}", "title": "" }, { "docid": "f05fd00af9cc4970fd2408937bbc08bb", "score": "0.5489996", "text": "function limpiar()\n{\n\t\n\t$('#formContacto input').val(\"\");\n\t$('#formContacto textarea').val(\"\");\n}", "title": "" }, { "docid": "b9b95b733ffad2439e1405c68323f2c0", "score": "0.54865694", "text": "function limpiar(){\n \t\t$(\"#txtIdgestor\").val(\"\") \n \t \t$(\"#txtnombregestor\").val(\"\") \n \t\t$(\"#txtcomisiongestor\").val(\"\") \n \t\t$(\"#txtappaternogestor\").val(\"\")\n \t\t$(\"#txtapmaternogestor\").val(\"\")\n \t\t$(\"#stlcanaldistribucion\").val(\"#\")\n }", "title": "" }, { "docid": "c1c0155daca438d349bd195d4731fc75", "score": "0.54823744", "text": "function limpiar(){\n $(\"#txtIdAvion\").val(\"\");\n $(\"#txtDescripcion\").val(\"\");\n $(\"#txtPlaca\").val(\"\");\n let select = document.getElementById(\"selMarca\");\n //Limpiar select\n while (select.length > 1) {\n select.remove(select.length - 1);\n }\n $(\"#selFabricante\").val(\"-1\");\n $(\"#selColor\").val(\"-1\");\n\n\n}", "title": "" }, { "docid": "983f0168807d580d20dfe7a6e8830f2f", "score": "0.5476086", "text": "function resetForm() {\n judul.value = '';\n deskripsi.value = '';\n tanggal.value = '';\n tanggalG1.value = '';\n tanggalG2.value = '';\n kategori.value = '';\n gambar.value = '';\n gambar2.value = '';\n lintang.value = '';\n bujur.value = '';\n id.value = '';\n}", "title": "" }, { "docid": "5495a55ae7de07bd97c122bde7922318", "score": "0.54648", "text": "function limpiar_campos_modal_editar() {\n $('.btn-edit-modal').val(\"\");\n $('.titulo').val(\"\");\n $('.user').val(\"\");\n $('.id').val(\"\");\n $('.text').html('');\n $('.select-estado').empty();\n $('.fecha_noticia').val(\"\");\n $('.select-estado').append('');\n $('#modalEdit').find(\".modal-body\").find('.imagen_noticia').append(\"\");\n}", "title": "" }, { "docid": "97c383b4d30cd1b6c6c0f79e0e017651", "score": "0.54638976", "text": "function crearContenidoRelaciones() {\n formHTML.innerHTML = '';\n\n let campoLUMatricula = document.createElement(\"input\");\n let labelLUMatricula = document.createElement(\"span\");\n labelLUMatricula.innerHTML = \"LU: \";\n campoLUMatricula.setAttribute('id', 'LUMatricula');\n campoLUMatricula.setAttribute('value', '');\n campoLUMatricula.setAttribute('type', 'number');\n formHTML.appendChild(labelLUMatricula);\n formHTML.appendChild(campoLUMatricula);\n let campoIDCarreraMatricula = document.createElement(\"input\");\n let labelIDCarreraMatricula = document.createElement(\"span\");\n labelIDCarreraMatricula.innerHTML = \"id carrera: \";\n campoIDCarreraMatricula.setAttribute('id', 'idCarreraMatricula');\n campoIDCarreraMatricula.setAttribute('value', '');\n campoIDCarreraMatricula.setAttribute('type', 'number');\n formHTML.appendChild(labelIDCarreraMatricula);\n formHTML.appendChild(campoIDCarreraMatricula);\n let campoFechaIngresoMatricula = document.createElement(\"input\");\n let labelFechaIngresoMatricula = document.createElement(\"span\");\n labelFechaIngresoMatricula.innerHTML = \"fecha ingreso: \";\n campoFechaIngresoMatricula.setAttribute('id', 'fechaIngresoMatricula');\n campoFechaIngresoMatricula.setAttribute('value', '');\n campoFechaIngresoMatricula.setAttribute('type', 'date');\n formHTML.appendChild(labelFechaIngresoMatricula);\n formHTML.appendChild(campoFechaIngresoMatricula);\n let campoFechaEgresoMatricula = document.createElement(\"input\");\n let labelFechaEgresoMatricula = document.createElement(\"span\");\n labelFechaEgresoMatricula.innerHTML = \"fecha egreso: \";\n campoFechaEgresoMatricula.setAttribute('id', 'fechaEgresoMatricula');\n campoFechaEgresoMatricula.setAttribute('value', '');\n campoFechaEgresoMatricula.setAttribute('type', 'date');\n formHTML.appendChild(labelFechaEgresoMatricula);\n formHTML.appendChild(campoFechaEgresoMatricula);\n\n let botonPost = document.createElement(\"button\");\n botonPost.setAttribute('class', 'btn-primary');\n botonPost.setAttribute('id', 'postMatricula');\n botonPost.addEventListener(\"click\", addMatricula);\n botonPost.textContent = 'agregar matricula';\n formHTML.appendChild(botonPost);\n\n let botonGet = document.createElement(\"button\");\n botonGet.setAttribute('class', 'btn-primary');\n botonGet.setAttribute('id', 'getMatriculas');\n botonGet.addEventListener(\"click\", getMatriculas);\n botonGet.textContent = 'listar matriculas';\n formHTML.appendChild(botonGet);\n\n let botonGetReporte = document.createElement(\"button\");\n botonGetReporte.setAttribute('class', 'btn-primary');\n botonGetReporte.setAttribute('id', 'getReporte');\n botonGetReporte.addEventListener(\"click\", getReporte);\n botonGetReporte.textContent = 'generar reporte';\n formHTML.appendChild(botonGetReporte);\n\n let colThead = document.createElement(\"thead\");\n let colTr = document.createElement(\"tr\");\n let colThCarreraMatricula = document.createElement(\"th\");\n let contenido = document.createTextNode(\"carrera\");\n colThCarreraMatricula.appendChild(contenido);\n colTr.appendChild(colThCarreraMatricula);\n\n let colThLUEstudianteMatricula = document.createElement(\"th\");\n contenido = document.createTextNode(\"LU estudiante\");\n colThLUEstudianteMatricula.appendChild(contenido);\n colTr.appendChild(colThLUEstudianteMatricula);\n\n let colThApellidoEstudianteMatricula = document.createElement(\"th\");\n contenido = document.createTextNode(\"apellido estudiante\");\n colThApellidoEstudianteMatricula.appendChild(contenido);\n colTr.appendChild(colThApellidoEstudianteMatricula);\n\n let colThIngreso = document.createElement(\"th\");\n contenido = document.createTextNode(\"ingreso\");\n colThIngreso.appendChild(contenido);\n colTr.appendChild(colThIngreso);\n\n let colThEgreso = document.createElement(\"th\");\n contenido = document.createTextNode(\"egreso\");\n colThEgreso.appendChild(contenido);\n colTr.appendChild(colThEgreso);\n\n let colThGraduado = document.createElement(\"th\");\n contenido = document.createTextNode(\"graduado\");\n colThGraduado.appendChild(contenido);\n colTr.appendChild(colThGraduado);\n\n colThead.appendChild(colTr);\n let colTbody = document.createElement(\"tbody\");\n tableHTML.innerHTML = '';\n tableHTML.appendChild(colThead);\n tableHTML.appendChild(colTbody);\n}", "title": "" }, { "docid": "81b522848ae4bed54dd5082d4fb84327", "score": "0.5457223", "text": "function populateForm2Js(){\n\t//Primero determinamos el modo en el que estamos;\n\tvar mode = getMMGMode(get('pedTipoSolicViewFrm.accion'), \n\t\tget('pedTipoSolicViewFrm.origen'));\n\t\n\tjsPedTipoSolicViewId = get('pedTipoSolicViewFrm.id').toString();\n\tjsPedTipoSolicViewCodTipoSoli = get('pedTipoSolicViewFrm.codTipoSoli').toString();\n\tjsPedTipoSolicViewIndCons = get('pedTipoSolicViewFrm.indCons').toString();\n\tjsPedTipoSolicViewIndSoliNega = get('pedTipoSolicViewFrm.indSoliNega').toString();\n\tjsPedTipoSolicViewIndDevo = get('pedTipoSolicViewFrm.indDevo').toString();\n\tjsPedTipoSolicViewIndAnul = get('pedTipoSolicViewFrm.indAnul').toString();\n\tjsPedTipoSolicViewCodGrupSoli = get('pedTipoSolicViewFrm.codGrupSoli').toString();\n\tif(mode == MMG_MODE_CREATE || mode == MMG_MODE_UPDATE_FORM){\n\t\tjsPedTipoSolicViewDescripcion = buildLocalizedString('pedTipoSolicViewFrm', 1);\n\t}else{\n\t\tjsPedTipoSolicViewDescripcion = get('pedTipoSolicViewFrm.Descripcion');\n\t}\n\t\n}", "title": "" } ]
60122b84c1969c6d44931a9959a79a4a
! Libre Module [StaticLike] controller set
[ { "docid": "b57ea641bf999986d95498731e1a7a90", "score": "0.62518454", "text": "set controller(controller) {\n if (grasppe.Libre.isLibreComponent(this)) return;\n this.hash.controller = controller;\n }", "title": "" } ]
[ { "docid": "a36edc1682cbf13eb3d586788f67f4c9", "score": "0.75722057", "text": "function controller() { }", "title": "" }, { "docid": "a36edc1682cbf13eb3d586788f67f4c9", "score": "0.75722057", "text": "function controller() { }", "title": "" }, { "docid": "a36edc1682cbf13eb3d586788f67f4c9", "score": "0.75722057", "text": "function controller() { }", "title": "" }, { "docid": "a36edc1682cbf13eb3d586788f67f4c9", "score": "0.75722057", "text": "function controller() { }", "title": "" }, { "docid": "f942b475e93c21315f984b9642037362", "score": "0.7542119", "text": "function Controller () {}", "title": "" }, { "docid": "2273e87d0544435ed211c4f9924f1e60", "score": "0.746941", "text": "function controller() {\n }", "title": "" }, { "docid": "5e15abf2fdcd3aac07c21a236c52b93f", "score": "0.7419388", "text": "function Controller(){\n\t\t\n\t}", "title": "" }, { "docid": "3a3345edaf6f7558cf6f9f245c3d48e0", "score": "0.7236774", "text": "initController () {\n this.handler = this.getInst(\"ControlMobileViewHandler\");\n\n // if (this.getService(\"GameSettingsService\").getLocalSettings(\"quick_spin\")) {\n // $_signal.goTo (\"-control.quickMode.enable\");\n // }\n }", "title": "" }, { "docid": "2298d5370fe77d4d9a1682db93f07cb9", "score": "0.7084159", "text": "function MainController(){}", "title": "" }, { "docid": "934e65f56c3b87ef812786f1766a6c0f", "score": "0.7040182", "text": "function DefaultController() {\n }", "title": "" }, { "docid": "e036fa18b724415055c8695a5b80d7b5", "score": "0.6996756", "text": "function Controller() {\n\n }", "title": "" }, { "docid": "ebc71649555d1f969ed8f1a27dbdcd26", "score": "0.6882038", "text": "function _controller (){\n\ttry {\n\t\t_buttons ();\n\t\t_laptop ();\n\t\t_related_pages ();\n\t}catch (err){\n\t\talert ('FREEmium _controller ()\\n\\n'+err);\n\t}\n}", "title": "" }, { "docid": "67a142ea002cb27c7d3831115d5d356d", "score": "0.68747574", "text": "setController(initController) {\n this.controller = initController;\n }", "title": "" }, { "docid": "a9ea5006b0ca23790b990bd9878dd1c3", "score": "0.6710791", "text": "function handleController( controller ){\n\n}", "title": "" }, { "docid": "31204bedecd177b66b5360490d1fe3d0", "score": "0.6683327", "text": "set controllers(controllers) {\n if (grasppe.Libre.isLibreComponent(this)) return;\n if (typeof controllers !== 'object') controllers = {};\n this.hash.controllers = controllers;\n }", "title": "" }, { "docid": "62a9e36cafbf51c29dbc14865d85807a", "score": "0.6643648", "text": "function init() {\n controller.title = 'Cats';\n }", "title": "" }, { "docid": "43aeff89ca666d48cf13c58610dbe5e7", "score": "0.6610432", "text": "function SetController(t : boolean)\r\n{\r\n\tif (t)\r\n\t{\r\n\t\tcontroller = true;\r\n\t}\r\n\telse\r\n\t{\r\n\t\tcontroller = false;\r\n\t}\r\n}", "title": "" }, { "docid": "3e655b159144643c062f37d8f2a52255", "score": "0.65325254", "text": "function BaseController(){}", "title": "" }, { "docid": "b008a85fd84b4c9b26e3c889d710c2d7", "score": "0.65094864", "text": "function BaseController() {\n}", "title": "" }, { "docid": "048eddad083043dc71684233893a4484", "score": "0.6497136", "text": "init() {\n\t\tthis.currentController_.init();\n\t}", "title": "" }, { "docid": "a2dce83241737d9d02cbe3bbae39ac48", "score": "0.64635974", "text": "function TestController() {}", "title": "" }, { "docid": "752329c6f4ab0b9b24300e206c1aa029", "score": "0.6430165", "text": "init() {\n this._controller = new Controller($('.js-app'));\n }", "title": "" }, { "docid": "526032df34cbcd93431294fa45289c6f", "score": "0.64063835", "text": "get controller() {\n return this.hash.module.controller || (this.getPrototype().hash && this.getPrototype().hash.module.controller);\n }", "title": "" }, { "docid": "ff003c1373dc9a59d6953fe0999ad584", "score": "0.63798404", "text": "function ShortsController() {}", "title": "" }, { "docid": "382be84db5ee78878ec382a5e7f52fc0", "score": "0.6358711", "text": "function SocialController() {}", "title": "" }, { "docid": "537bc63e8b0e94ff3816eaba24caff71", "score": "0.6342327", "text": "function ServiceController() {\n}", "title": "" }, { "docid": "72d0981315bfe14e8e27c154772fad61", "score": "0.629142", "text": "function module_init() {\n angular.module('nl.view_controllers', \n \t['nl.home', 'nl.auth', 'nl.course',\n \t 'nl.sco', 'nl.lessonlist',\n \t 'nl.resource', 'nl.resource_list',\n\t\t 'nl.lesson', 'nl.module']);\n}", "title": "" }, { "docid": "513c495f45b74aaa4be37fd097ac930d", "score": "0.6275232", "text": "function mainCalcAppController() {\n\n }", "title": "" }, { "docid": "996de14ddf73d26ba47e1c232f89c46a", "score": "0.6246655", "text": "getController(req, res) {\n res.send({\n message: 'Get Controller'\n })\n }", "title": "" }, { "docid": "686c383c3772c88be3df624f78a4369f", "score": "0.62130135", "text": "function Controller() {\n var controller = express(); // instantiate controller Express app\n\n\n var dataSourceArgs = [...globals.instanceConfiguration['data-sources']];\n dataSourceArgs.unshift(globals.baseDir); // push root Integration-Node directory to child process\n dataSourceController = cp.fork(`${globals.baseDir}/lib/data-source.js`, dataSourceArgs);\n\n\n // handle message from child Data Source Controller\n dataSourceController.on('message', (msg) => {\n if (msg.status === \"ERROR\") {\n globals.instanceLogger.error('Data Source Controller reported error: ' + JSON.stringify(msg.errorDetails));\n }\n else if (msg.status === \"INFO\") {\n globals.instanceLogger.info(msg.infoMsg);\n }\n else if (msg.status === \"VERBOSE\") {\n globals.instanceLogger.verbose(msg.infoMsg);\n }\n else if (msg.status === \"DEBUG\") {\n globals.instanceLogger.debug(msg.infoMsg);\n }\n\n });\n\n globals.instanceLogger.verbose('Setting up Integration-Node Controller UI ...');\n // set controller view engine and port\n controller.engine('handlebars', exphbs({defaultLayout: 'main'}));\n controller.set('view engine', 'handlebars');\n controller.set('port', globals.controllerPort);\n\n // static assets route\n controller.use(express.static(globals.baseDir + '/public'));\n\n // add page testing routes\n controller.use(function(req, res, next) {\n res.locals.showTests = globals.environment !== 'production' && req.query.test === '1';\n next();\n });\n\n\n //\n // define controller UI routes\n //\n controller.get('/', homePage);\n controller.get('/datasources/:dsname', singleDataSourcePage);\n controller.get('/datasources', dataSourcesPage);\n controller.get('/datasource/toggle', toggleDataSource);\n controller.get('/log', logPage);\n controller.get('/integration-groups/:igname', singleIntegrationGroupPage);\n controller.get('/integration-groups', integrationGroupsPage);\n controller.get('/integration-group/toggle', toggleIntegrationGroup);\n\n // 404 page\n controller.use(notFoundPage);\n // 500 page\n controller.use(serverErrorPage);\n\n var controllerServer = controller.listen(controller.get('port'), function afterControllerStart() {\n var host = controllerServer.address().address;\n var port = controllerServer.address().port;\n globals.instanceLogger.info('Integration-Node controller UI started at http://%s:%s. Type ctrl-C to quit.', host, port);\n })\n\n return controller;\n}", "title": "" }, { "docid": "2f377d185f19dc549d659e9fff1fb07b", "score": "0.61718947", "text": "function makeController() {\n return $controller(\"sageEdit\", {\n $location: $location,\n $scope: $scope,\n $routeParams: $routeParams_stub,\n common: common,\n datacontext: datacontext\n });\n }", "title": "" }, { "docid": "4b92ac52cd66371bcc0574f5cde4fdfb", "score": "0.6131862", "text": "function init() {\n common.logger.log(\"controller loaded\", null, controllerId);\n common.activateController([], controllerId);\n }", "title": "" }, { "docid": "b603bee4d34e4d46f2cbe18ce7c78384", "score": "0.610612", "text": "function initController() {\n // initialize to page 1\n vm.setPage(1);\n }", "title": "" }, { "docid": "524578ab422baccf1ea2b0be41bbba10", "score": "0.6098458", "text": "function makeController(){\n controller = $('.mosml-console').console({\n promptLabel: '\\u200b', // zero width space, hack.\n commandHandle: function(line){\n wsSendCommand(line);\n return '\\n';\n },\n autofocus: false,\n animateScroll: true,\n promptHistory: true,\n fadeOnReset: false\n // welcomeMessage: 'Type SML in here.',\n // continuedPromptLabel: ''\n });\n }", "title": "" }, { "docid": "a3e510c6b8f719d872ee39d66fdd9d42", "score": "0.60830563", "text": "function categoriaController() {}", "title": "" }, { "docid": "29859f2e434f0b1d366f61d69eca5482", "score": "0.6056273", "text": "set module(module) {\n if (!this.hash.module && module instanceof grasppe.Libre.Module) {\n var providers = this.$providers || [];\n if (typeof this.hash.$controller === 'function') {\n var modelID = this.id.replace(/(Controller|Module|Directive)$/, 'Model'),\n model = modelID && module.values[modelID];\n // console.log(modelID, providers);\n if (model)\n module.$module.controller(this.id, ['$scope', '$libreModule', modelID, '$element'].concat(providers).concat([this.hash.$controller]))\n else \n module.$module.controller(this.id, ['$scope', '$libreModule', '$element'].concat(providers).concat([this.hash.$controller]))\n // console.log(module.$module.controller(this.id));\n this.hash.module = module;\n } else if (Array.isArray(this.hash.$controller) && typeof this.hash.$controller.slice(-1) === 'function') {\n // console.log(this.id, providers);\n var parameters = this.hash.$controller.concat();\n this.hash.$controller = parameters.pop(), this.hash.$providers = parameters;\n module.$module.controller(this.id, ['$scope'].concat(providers).concat([this.hash.$controller])), this.hash.module = module;\n }\n }\n }", "title": "" }, { "docid": "2500050ec58fe7618ca066db5ff63921", "score": "0.6053502", "text": "function Controller(){\n var controllerIPs = ''\n for (i in controller){\n controllerIPs = controllerIPs + controller[i] + \" \";\n }\n require('child_process').exec(\"python \"+ __dirname + \"/Python/controller\" + controllerV + \".py \" + controllerIPs, function (err, stdout, stderr) {\n if (err) {\n return console.log(err);\n }\n console.log(stdout);\n });\n}", "title": "" }, { "docid": "15c973441237854d999c55abec621c5b", "score": "0.6042433", "text": "function PostsAdministrationController() {}", "title": "" }, { "docid": "a9e735ce6c43ecf2f0b82f327229e638", "score": "0.6031582", "text": "loadController() {\n fs.readdirSync(`${this.baseDir}/app/controller`).forEach((file) => {\n debug('bind controller %s', file);\n this.controller[utils.camelize(file.slice(0, -3))] = utils.loadFile(`${this.baseDir}/app/controller/${file}`);\n });\n utils.loadFile(`${this.baseDir}/app/router`)(this.router, this.controller);\n }", "title": "" }, { "docid": "6f1d1588541a0bcae1250fcfadccbd06", "score": "0.6022171", "text": "initKnack() {\r\n this.memberController = memberController.init();\r\n }", "title": "" }, { "docid": "0c314f0d82a191412ea5d0f814c66818", "score": "0.60036004", "text": "function CodeDemosController() {\n\n}", "title": "" }, { "docid": "3a52fb5b4c6114a84f202d026a19ba65", "score": "0.59779215", "text": "function AuthController() {}", "title": "" }, { "docid": "154a3b735d5b377ea1ebb67f1262499e", "score": "0.5950423", "text": "function initiateController(){\n $scope.namegroupcreate = true;\n $scope.currentYear = new Date().getFullYear();\n $scope.form = {};\n tasks = taskService.getTasks(\"groupmanagentController\");\n }", "title": "" }, { "docid": "0620da9dd3204ca92ac125e448273ffb", "score": "0.5931424", "text": "static get $controller() {\n if (!grasppe.Libre.hash.libreController) grasppe.Libre.hash.libreController = new grasppe.Libre.LibreController;\n if (!grasppe.Libre.hash.$controller) {\n grasppe.Libre.hash.$controller = grasppe.Libre.hash.libreController.$controller;\n this.$module.controller(grasppe.Libre.hash.LibreController.componentID, ['$scope', '$rootScope'].concat(this.$providers || []).concat([grasppe.Libre.hash.$controller]));\n }\n return grasppe.Libre.hash.$controller;\n }", "title": "" }, { "docid": "7e270995916be49f0546bd1ceda5250b", "score": "0.5926884", "text": "function initController() {\n\n console.log( { compID : $rootScope.company} );\n loadPerCompany( { compID : $rootScope.company} ); //rootSccope sirve para menatener variables\n loadNewCompany( { compID : $rootScope.company} ); //globales\n loadTotCompany( { compID : $rootScope.company} );\n loadGlobalSales();\n }", "title": "" }, { "docid": "94674e4daa166ba6c8fd63bb55a19dd3", "score": "0.59168863", "text": "function BorrowerController() {\n }", "title": "" }, { "docid": "3993976c806d1547052b2f19c498c9fa", "score": "0.5911672", "text": "constructor(name, controller) {\n this.name = name\n this.controller = controller\n }", "title": "" }, { "docid": "cf92ce09cd3039fcc7aefdcd04b9cd64", "score": "0.59048194", "text": "function ApiActionController() {\n\t}", "title": "" }, { "docid": "e1b6a8142e372fc22876b0c5b4d1dc41", "score": "0.5903426", "text": "function _Controller (map) {\r\n\r\n\t\t// \r\n\t\t// Loop through custom-defined functions and assign them to the Controller's prototype.\r\n\t\t//\r\n\r\n\t\tfor (var func in map) {\r\n\t\t\tif (map.hasOwnProperty(func)) {\r\n\t\t\t\t_Controller.prototype[func] = map[func];\r\n\t\t\t}\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "d3f070d5cd6b0473756af5e9361d224c", "score": "0.5895774", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "d3f070d5cd6b0473756af5e9361d224c", "score": "0.5895774", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "d3f070d5cd6b0473756af5e9361d224c", "score": "0.5895774", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `index` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "ad1f0db5907de4c153782e95ef037270", "score": "0.5873031", "text": "function MediaContentController() {\n\t}", "title": "" }, { "docid": "ea841a33c64b7c2ff1ae66129bf6f989", "score": "0.5871301", "text": "static create (state, options) {\n let appController = new AppController(state, options) // eslint-disable-line prefer-const\n\n // Register data modules\n appController.registerModule(L10nModule, {\n defaultLocale: Locales.en_US,\n messageBundles: Locales.bundleArr()\n })\n\n appController.registerModule(LexisModule, {\n arethusaTbRefreshRetryCount: appController._options.arethusaTbRefreshRetryCount,\n arethusaTbRefreshDelay: appController._options.arethusaTbRefreshDelay,\n adapters: appController._adapters\n })\n\n /*\n The second parameter of an AuthModule is environment specific.\n For webexetension it, for example, can be a messaging service.\n Some environments may not register an Auth module at all.\n That's why this registration shall be made not here,\n but from within an environment that creates an app controller\n (after a call to `create()` function, usually).\n */\n // appController.registerModule(AuthModule, undefined)\n\n // Register UI modules. This is environment specific and thus shall be done after a `create()` call.\n /* appController.registerModule(PanelModule, {\n mountPoint: '#alpheios-panel' // To what element a panel will be mounted\n })\n appController.registerModule(PopupModule, {\n mountPoint: '#alpheios-popup'\n })\n appController.registerModule(ActionPanelModule, {})\n */\n\n // Creates on configures an event listener\n appController._evc.registerListener('HandleEscapeKey', document, appController.handleEscapeKey.bind(appController), GenericEvt, 'keydown')\n SelectionController.evt.TEXT_SELECTED.sub(appController.onTextSelected.bind(appController))\n\n // Subscribe to LexicalQuery events\n LexicalQuery.evt.LEXICAL_QUERY_COMPLETE.sub(appController.onLexicalQueryComplete.bind(appController))\n LexicalQuery.evt.MORPH_DATA_NOTAVAILABLE.sub(appController.onMorphDataNotFound.bind(appController))\n LexicalQuery.evt.HOMONYM_READY.sub(appController.onHomonymReady.bind(appController))\n LexicalQuery.evt.LEMMA_TRANSL_READY.sub(appController.updateTranslations.bind(appController))\n LexicalQuery.evt.WORD_USAGE_EXAMPLES_READY.sub(appController.updateWordUsageExamples.bind(appController))\n LexicalQuery.evt.SHORT_DEFS_READY.sub(appController.onShortDefinitionsReady.bind(appController))\n LexicalQuery.evt.FULL_DEFS_READY.sub(appController.onFullDefinitionsReady.bind(appController))\n LexicalQuery.evt.SHORT_DEFS_NOT_FOUND.sub(appController.onDefinitionsNotFound.bind(appController))\n LexicalQuery.evt.FULL_DEFS_NOT_FOUND.sub(appController.onDefinitionsNotFound.bind(appController))\n\n // Subscribe to ResourceQuery events\n ResourceQuery.evt.RESOURCE_QUERY_COMPLETE.sub(appController.onResourceQueryComplete.bind(appController))\n ResourceQuery.evt.GRAMMAR_AVAILABLE.sub(appController.onGrammarAvailable.bind(appController))\n ResourceQuery.evt.GRAMMAR_NOT_FOUND.sub(appController.onGrammarNotFound.bind(appController))\n\n appController._wordlistC = new WordlistController(LanguageModelFactory.availableLanguages(), LexicalQuery.evt)\n WordlistController.evt.WORDLIST_UPDATED.sub(appController.onWordListUpdated.bind(appController))\n WordlistController.evt.WORDITEM_SELECTED.sub(appController.onWordItemSelected.bind(appController))\n\n return appController\n }", "title": "" }, { "docid": "194b2908a69f9048e53dd70c73766630", "score": "0.586542", "text": "function loadController(data) {\n\n\t\t// Check if controller object exists and if not, create it.\n\t\tif (typeof controller == \"undefined\") {\n\t\t\tvar controller = new Controller();\n\t\t}\n\t\tcontroller.setview(data);\n\t}", "title": "" }, { "docid": "88d2e44fe12dce7329872b4c560ba63d", "score": "0.5855321", "text": "constructor(){\n this.helper = {};\n this.renderEngine = {};\n this.rootModel = {};\n this.rootController = {};\n }", "title": "" }, { "docid": "a896c0a048d08510641e957e3aafb284", "score": "0.58457077", "text": "function WysiwygController() {\n\t}", "title": "" }, { "docid": "34942788e1a4a05a23c4dc4879184ca0", "score": "0.58409566", "text": "function addUserController()\n\n{\n\n}", "title": "" }, { "docid": "98e3f0cf1c4ebe3f3e853ad1217bbd21", "score": "0.58398587", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `sobre` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "f6f7febcb1ea7f38221e1a03d7257272", "score": "0.5831639", "text": "function StartCtrl() {\n\t\tvar vm = this;\n\n\t\t// view model bindings\n\t\tvm.title = 'start';\n\t\tvm.doSomething = doSomething;\n\n\t\t// view model implementations\n\t\tfunction doSomething() {\n\t\t\treturn [vm.title, 'a sublime controller'].join(' - ');\n\t\t}\n\t}", "title": "" }, { "docid": "63f4932ed3847b0622fe378c24e164a8", "score": "0.5830434", "text": "constructor() {\n let newCtrl = new Controller();\n }", "title": "" }, { "docid": "87e2dbff3869f653698aa9ebea428999", "score": "0.5826559", "text": "function ModuleController () {\r\n let myModuleContainer = null;\r\n let myModuleModel = null;\r\n let showWin = document.getElementById('signIn');\r\n\r\n\r\n this.init = function(container, model) {\r\n myModuleContainer = container;\r\n myModuleModel = model;\r\n\r\n // вешаем слушателей на событие hashchange и кликам по пунктам меню\r\n window.addEventListener(\"hashchange\", this.updateState);\r\n this.updateState(); //первая отрисовка\r\n }\r\n\r\n this.updateState = function() {\r\n myModuleModel.updateState();\r\n }\r\n\r\n this.showModal = function() {\r\n showWin.addEventListener('click', myModuleModel.showWindow());\r\n }\r\n \r\n }", "title": "" }, { "docid": "d6478178a5bb46d78e2a8a4e189b3be6", "score": "0.5819686", "text": "function SettingsController() {\n let vm = this;\n\n function init() {\n console.log(\"Settings Controller loaded\");\n }\n init();\n }", "title": "" }, { "docid": "7961fe6c7b19e9c26ac21d7e9951f6fa", "score": "0.58172643", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `vision` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "e02bc3fad10c6ede7770c5a37716c462", "score": "0.58108807", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `side_menus` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "2216d59a891c529711443f79da47dbe7", "score": "0.57943416", "text": "function SoundController()\n {\n //run this to make sounds json and print in the console\n //var cv = new Convert();\n //cv = null;\n\n // No bindings: static object\n }", "title": "" }, { "docid": "a8cfb11d4b847785dea8f7c6130d7df9", "score": "0.5791052", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `mision` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "9e96c808795f982a158ed8f5f35dde11", "score": "0.579096", "text": "function universalController(){\n\t$('.sandbox').html('');\n\t$('.legend, .controls').remove();\n console.log('Universal Controller - ready to run your functions!');\n\n////// STEP 1: Draw a bar for each year of our data.\n //var Region = changePage();\n \n //var Region = Region;\n initializeBars(Region);\n\n////// STEP 2: Allow for user interaction with our visualization\n initializeControls();\n\n////// STEP 3: Advanced interaction through a click and hold interface\n handleTouch();\n\n}", "title": "" }, { "docid": "e1f060890d21b8988f3e34c1768bd8c2", "score": "0.5790893", "text": "setupController (controller) {\n this._super.apply(this, arguments);\n\n if (this.get('session.isAuthenticated')){\n controller.setProperties({\n showGlobalSearch: true,\n rmwbIntegration: Ember.rmwbIntegration\n });\n }\n }", "title": "" }, { "docid": "6cb445676ab15fef1f78a86bcab93f3f", "score": "0.5789746", "text": "function Controller(){\n this.isRunning = false;\n }", "title": "" }, { "docid": "f11baa0dce1fb91f2cdd548a6a5f619f", "score": "0.5779938", "text": "function loadController($controller, $rootScope, $timeout) {\n scope = $rootScope.$new();\n scope[\"configuration\"] = {\n };\n if (configured) {\n scope.configuration.data.siteUrl = 'http://site.com';\n scope.configuration.data.listName = 'Tasks';\n scope.configuration.data.category = 'Priority';\n scope.configuration.data.series = [{ aggregateField: 'Field' }];\n }\n var controllerId = 'customizationController';\n controller = $controller(ontrollerId, {\n $scope: scope, $timeout: $timeout, localize: localize\n });\n }", "title": "" }, { "docid": "95a859c38482b527dc18599b16430343", "score": "0.57709527", "text": "setCtrlActions() {\n this.addVideoHandling();\n this.addFilterHandling();\n this.addSnapShotHandling();\n }", "title": "" }, { "docid": "bfacdf98753fb209e1907946ea74c9b8", "score": "0.57686067", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n//debug: all data\n//console.log(data_tica_y_legals);\n$ionicConfig.backButton.text(\"\");\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `tica_y_legal` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "543c4d9d8ff58cca5413e2b65a2af13f", "score": "0.57661927", "text": "get controller() {\n return this.objectName + 'Controller';\n }", "title": "" }, { "docid": "df45eadb29327eea9a92aa09c35d7e01", "score": "0.5761642", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n//debug: all data\n//console.log(data_criptomonedas);\n$ionicConfig.backButton.text(\"\");\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `criptomonedas` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "43cfe25b54a0b72180ec4e80ff4fc5e8", "score": "0.57568944", "text": "function HomeController() {\n var self = this;\n self.awesome = true;\n self.numbers = [4, 5, 12, 9, 16];\n self.puppies = 'ruff';\n self.object = {cats: 'meow'};\n}", "title": "" }, { "docid": "e80786ffde4299601af1f3c2da9cb72d", "score": "0.575297", "text": "function initController(app) {\n app.use(_TestController.index.routes());\n app.use(_TestController.index.allowedMethods);\n app.use(_TreeAPIController.TreeAPI.routes());\n app.use(_TreeAPIController.TreeAPI.allowedMethods);\n}", "title": "" }, { "docid": "666972de119823a5441bf72619c4c8bc", "score": "0.57528836", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `about` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "5c6d3ff37dace2ee7d71e45c52fb135b", "score": "0.5741433", "text": "function init() {Ohm64_Controller.init();}", "title": "" }, { "docid": "3750a7bd46062389e1d8bc80e6026140", "score": "0.57247376", "text": "get controller() {\n return this;\n }", "title": "" }, { "docid": "bebdff4e9dcb05c003128c304cc1bc7e", "score": "0.5718176", "text": "function ReplicationController() {\n}", "title": "" }, { "docid": "07812a56bc7ffa00f33047145d6ef98c", "score": "0.57164055", "text": "constructor() {\n super()\n this.controller = new Controller();\n this.entry = '/numbers';\n this.build();\n }", "title": "" }, { "docid": "8d6016ce2c2c2c12aa728360bb028d8f", "score": "0.5716081", "text": "onLoggedIn(){this.controller=new MainController(this.login.pryvUserConnection,\"event-view\",\"category-events\");this.controller.init();}", "title": "" }, { "docid": "8dcaf77c4f96cdd98f509c968513caf3", "score": "0.57127154", "text": "setupController(controller, model) {\n // Call _super for default behavior\n this._super(controller, model);\n\n //if (this.get('session.data.authenticated.role')!=='Admin'){\n if ( localStorage.getItem('role') !== 'Admin'){\n\t\t this.transitionTo('/search-contact');\n\t}\n }", "title": "" }, { "docid": "d13981681111524ba1115b0ec121a63d", "score": "0.5711115", "text": "initializeController() {\n if (!this.hash.controller && this.getPrototype().controller) this.hash.controller = new(this.getPrototype().controller)(this);\n return this;\n }", "title": "" }, { "docid": "20fdbc5f83d7b352ac6764702c2bb97e", "score": "0.57053", "text": "function Controller(){\n console.log(\"Run controller script\");\n var dir = __dirname + \"/Python/controller.py\";\n console.log(json.controller);\n require('child_process').exec(\"python \" + dir + \" \" + json.controller, function (err, stdout, stderr) {\n if (err) {\n return console.log(err);\n }\n console.log(stdout);\n });\n}", "title": "" }, { "docid": "795bdb60920dfdb7837920cf1cb5afbc", "score": "0.5700582", "text": "function AddDicomParserctrlController(controllerName, controller) {\n DicomParserApp.controller(controllerName, controller);\n}", "title": "" }, { "docid": "e039ba4ee132d137d3f79a6d74950671", "score": "0.57004726", "text": "setOneInstanceOfNewsController() {\n if (this.newsController == null) {\n this.newsController = new NewsController()\n }\n }", "title": "" }, { "docid": "240a177b041fd1a9db1ceb5acbf1c112", "score": "0.5700078", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n$ionicConfig.backButton.text(\"\");\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `videos_i` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "4b5a6877a628657e19536021fbcaf459", "score": "0.569846", "text": "static FindControllerInstance(key) {\n return BaseController.controllers[key];\n }", "title": "" }, { "docid": "13cc287e5eedc944af9c3c010994b478", "score": "0.56971264", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n$ionicConfig.backButton.text(\"\");\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `criptomonedas_singles` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "724ad06ff58d14f5616c9180ee3f3df5", "score": "0.56884396", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n$ionicConfig.backButton.text(\"\");\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `videos_iii` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "d2398492b503a00fdd8cd764f64ab2df", "score": "0.5683918", "text": "createController() {\n this.controller = Botkit.slackbot({\n retry: Infinity,\n debug: false\n });\n }", "title": "" }, { "docid": "0ac77be9b6ccd406761864d4f59a5236", "score": "0.5682005", "text": "function cmdController () {\n prompt.start();\n\n prompt.get({\n properties: {\n module: {\n description: 'Module name related',\n type: 'string',\n pattern: /^[a-zA-Z\\s\\-\\.]+$/,\n message: 'Module name must be only letters, spaces, or dashes',\n required: true\n },\n name: {\n description: 'Controller name',\n type: 'string',\n pattern: /^[a-zA-Z\\s\\-\\.]+$/,\n message: 'Name must be only letters, spaces, or dashes',\n required: true\n },\n dependencies: {\n description: 'Controller dependencies',\n type: 'string',\n pattern: /^[a-zA-Z\\,\\s\\$]+$/,\n message: 'Dependencies must be letters or $ and separated by coma and space',\n required: false\n },\n description: {\n description: 'Description of the controller',\n type: 'string',\n pattern: /^[a-zA-Z\\s\\-]+$/,\n message: 'Description must be only letters, spaces, or dashes',\n required: false\n }\n }\n }, ngController);\n}", "title": "" }, { "docid": "6a23d1a28a6de84aa8b5e3fd72b9a691", "score": "0.5681902", "text": "async function autoCreateController() {\n try {\n await poly.addNode(\n new Controller(poly,\n controllerAddress, controllerAddress, 'Ring NodeServer')\n );\n\n // Add a notice in the UI\n poly.addNoticeTemp('newController', 'Controller node initialized', 5);\n\n // After we have the controller we need to display the authorization notice\n // getAccessToken does this for us.\n await ringInterface.getAccessToken();\n } catch (err) {\n logger.errorStack(err, 'Error creating controller node:');\n\n // Add a notice in the UI, and leave it there\n poly.addNotice('newController', 'Error creating controller node');\n }\n}", "title": "" }, { "docid": "0b4397acd7d28b04a4f45fb654d4d076", "score": "0.5681186", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n$ionicConfig.backButton.text(\"\");\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `criptomoneda_singles` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" }, { "docid": "d7b51d86ce48e5cfa888f7f010cb05db", "score": "0.56800306", "text": "onControllerChange(sw) {\n if (this.config.debug) console.log('onControllerChange', sw)\n }", "title": "" }, { "docid": "0f15caab9f850865862ad5941278ab97", "score": "0.56798786", "text": "function init() {\n\n RefineServlet.registerCommand(module, \"CheckDataSensitivity\", new ControlPrivacy()); \n \n\n \n ClientSideResourceManager.addPaths(\n \"project/scripts\",\n module,\n [\n \"scripts/project-injection.js\"\n ]\n );\n\n}", "title": "" }, { "docid": "911297c4795186369ee2b4ac533b9596", "score": "0.56659484", "text": "function loadControlPanel() {\n cp.controller.setView();\n}", "title": "" }, { "docid": "e0657d4cdbbafb97f56d2015d4e143c8", "score": "0.56656927", "text": "function controller_by_user(){\n\t\ttry {\n\t\t\t\n$ionicConfig.backButton.text(\"\");\t\t\t\n\t\t} catch(e){\n\t\t\tconsole.log(\"%cerror: %cPage: `videos3` and field: `Custom Controller`\",\"color:blue;font-size:18px\",\"color:red;font-size:18px\");\n\t\t\tconsole.dir(e);\n\t\t}\n\t}", "title": "" } ]
166d3b71dfe3811444e0f3f564276ee9
Gets the users info and saves access token
[ { "docid": "9cf16614a99c08305106175f7586e9eb", "score": "0.5778293", "text": "function getUserInfo (commit, state, accessToken, callbackFN) {\n window.gapi.client.request('https://www.googleapis.com/oauth2/v1/userinfo?alt=json').then(function (response) {\n if ((response.status < 200) || (response.status > 299)) {\n console.log(response)\n callbackFN('Error', 'Couldn\\'t retrieve user info')\n }\n else {\n commit('SET_USER_INFO', response.result)\n loadGoogleSheetsAPIIntoWebPage(commit, accessToken, callbackFN)\n }\n })\n // https://www.googleapis.com/oauth2/v1/userinfo?alt=json\n}", "title": "" } ]
[ { "docid": "33c90662c058bba8e1a9541b6e78873d", "score": "0.64945436", "text": "function getUserData() {\n const url = 'http://18.221.60.193/me';\n fetch(url, {\n method: 'GET',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json',\n 'Authorization': 'Bearer ' + userToken.token,\n }\n })\n .then((response) => {\n const statusCode = response.status;\n const data = response.json();\n return Promise.all([statusCode, data]);\n })\n .then(([status, Jsonresponse]) => {\n if (status != 200) { //navigate user to the sign in page if token of the user has expires\n alert('We need to verify it\\'s you! You\\'ll be redirected to the sign in page soon');\n navigation.navigate('Sign In');\n } else {\n storeData(Jsonresponse);\n }\n })\n .catch((error) => {\n console.log(error);\n alert('An error occurred!')\n });\n }", "title": "" }, { "docid": "84e2a72f3b9caaeaca8f3e7c57cd0cce", "score": "0.6328719", "text": "getUser(access_token) {\n\t\treturn new Promise((resolve, reject) => {\n\t\t\tthis.$http.get(`https://www.googleapis.com/userinfo/v2/me?access_token=${access_token}`).then((response) => {\n\t\t\t\tresolve(response.data);\n\t\t\t}).catch((error) => {\n\t\t\t\treject(error);\n\t\t\t});\n\t\t});\n\t}", "title": "" }, { "docid": "bd37f7a936ebdd457ca7682c5e6ced4d", "score": "0.6302967", "text": "retrieveUserData() {\n const endpoint = `https://skylabcoders.herokuapp.com/api/user/${this._user.id}`\n const params = {\n method: 'GET',\n headers: {\n 'Authorization': `Bearer ${this._user.token}`\n }\n }\n\n return fetch(endpoint, params)\n .then(response => response.json())\n .then(response => {\n if (response.error) throw Error(response.error)\n\n this._user.username = response.data.username || ''\n this._user.email = response.data.email || ''\n this._user.name = response.data.name || ''\n this._user.surname = response.data.surname || ''\n this._user.seen = response.data.movies_seen || []\n this._user.pending = response.data.movies_pending || []\n // this._userFavourites = response.data.movies_favourites || []\n sessionStorage.setItem('user', JSON.stringify(this._user))\n })\n }", "title": "" }, { "docid": "cc71988f00555ee2e09b3d79a9510ed4", "score": "0.62990105", "text": "function getAccountData(){\n\t\t\trestAPI.user.read(globals.user.user_id, function(user){\n\t\t\t\tconsole.log(user);\n\t\t\t\t$scope.user = user;\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "1fca501446d719aa6e2ea89096e42d85", "score": "0.62743676", "text": "function processAuth() {\n\n // Add the required Authorization header with bearer token.\n $http.defaults.headers.common.Authorization = 'Bearer ' + localStorage.token;\n\n if (localStorage.getItem('user') === null) {\n\n // Get the profile of the current user.\n GraphHelper.me().then(function (response) {\n\n // Save the user to localStorage.\n let user = response.data;\n console.log(user);\n localStorage.setItem('user', angular.toJson(user));\n\n vm.displayName = user.displayName;\n vm.emailAddress = user.mail || user.userPrincipalName;\n });\n } else {\n let user = angular.fromJson(localStorage.user);\n\n vm.displayName = user.displayName;\n vm.emailAddress = user.mail || user.userPrincipalName;\n }\n }", "title": "" }, { "docid": "b4ffb59a25edcabd728c10786b1d9afa", "score": "0.62710726", "text": "async function getUser(){\n try {\n let { username } = decode(token);\n let currentUser = await JoblyApi.getUser(username);\n // setStoredUser(currentUser);\n // console.log(\"APP.js storedUser\",storedUser)\n // setStoredUser(JSON.stringify(currentUser));\n console.log(\"before\",currentUser)\n setStoredUser(currentUser);\n console.log(\"after\",storedUser)\n // console.log(\"currentUser! in App\", storedUser);\n } catch (err) {\n setStoredUser(null);\n }\n }", "title": "" }, { "docid": "c51c33a6513898800456860bfb1764b1", "score": "0.62678254", "text": "function getProfile() {\n if (!userProfile) {\n var accessToken = localStorage.getItem('access_token');\n\n if (!accessToken) {\n console.log('Access token must exist to fetch profile');\n }\n\n webAuth.client.userInfo(accessToken, function(err, profile) {\n if (profile) {\n userProfile = profile;\n displayProfile();\n }\n });\n } else {\n displayProfile();\n }\n }", "title": "" }, { "docid": "5df1e590e4756eb835cc008d8ea454fa", "score": "0.62595296", "text": "function updateUserInfo() {\n\t\t\tUserAPI.getUserInfo()\n\t\t\t.then(function (data) {\n\n\t\t\t\t$rootScope.userData = data.user;\n\t\t\t\t//update expiration on cookie\n\t\t\t\tif(rememberMe.get()===true) {\n\t\t\t\t\t//have an expiration date\n\t\t\t\t\tUserAuthToken.set(UserAuthToken.get(), 90);\n\t\t\t\t\trememberMe.set(true, 90);\n\t\t\t\t} else {\n\t\t\t\t\t//don't have one\n\t\t\t\t\tUserAuthToken.set(UserAuthToken.get());\n\t\t\t\t\trememberMe.set(false);\n\t\t\t\t}\n\t\t\t}, function (messages) {\n\t\t\t\tlogout();\n\t\t\t});\n\t\t}", "title": "" }, { "docid": "466aeeaebc7e0562656a00949cc32b13", "score": "0.6245559", "text": "static async getCurrentUserData() {\n //get currentUser from localStorage\n const token = localStorage.getItem('userToken');\n\n //verify token\n let user = jwt.verify(token, SECRET);\n\n //extract username from user\n const { username } = user;\n\n //get data about that user\n let res = await JoblyApi.request(`users/${username}`);\n return res.user;\n }", "title": "" }, { "docid": "ee9afa8345f1fe074f3525b785f01f48", "score": "0.6232054", "text": "async function getUserInfo() {\n\t\tfetch(baseApiUrl + \"/user\", authHeaders())\n\t\t\t.then((response) => response.text())\n\t\t\t.then((data) => setUser(data ? JSON.parse(data) : {}))\n\t\t\t.catch((error) => console.error(\"Error: \", error));\n\t}", "title": "" }, { "docid": "856f7126ab22f719ccd02aaf78023867", "score": "0.62312514", "text": "function getAccessToken() {\n\n\n var signupExternalUser = function (token, provider) {\n //function registers the user with our application\n $.ajax({\n url: '/api/Account/RegisterExternal',\n method: 'POST',\n headers: {\n 'content-type': 'application/JSON',\n 'Authorization': 'Bearer ' + token\n },\n success: function () {\n alert(provider);\n window.location.href = \"/api/Account/ExternalLogin?provider=\" + provider +\"&response_type=token&client_id=self&redirect_uri=https%3A%2F%2Flocalhost%3A44340%2FHtml%2FLogin.html&state=hPiXIKNPFzSJPqYgXzKRdKocBkwCJZNDT2_qmAjBDlg1\";\n }\n });\n };\n\n \n var isUserRegistered = function (token) { \n //function checks if the user authenticated by Google is registered with our application\n $.ajax({\n url: '/api/Account/UserInfo',\n method: 'GET',\n headers: {\n 'content-type': 'application/JSON',\n 'Authorization': 'Bearer ' + token\n },\n success: function(response) {\n \n if (response.HasRegistered) {\n localStorage.setItem('accessToken', token);\n localStorage.setItem('userName', response.Email);\n window.location.href = \"Data.html\";\n } else {\n signupExternalUser(token, response.LoginProvider);\n }\n }\n });\n };\n if (location.hash) {\n if (location.hash.split('access_token=')) {\n var accessToken = location.hash.split('access_token=')[1].split('&')[0];\n if (accessToken) {\n isUserRegistered(accessToken);\n }\n }\n }\n}", "title": "" }, { "docid": "9e84ca696168a5e6173003d842b2bb4b", "score": "0.6227387", "text": "getUserInfo() {\n const self = this\n let url = this._getUrl('/user')\n return _request(url).then((result) => self._formatUser(result.data))\n }", "title": "" }, { "docid": "6ddbbdb6cb1158c46d22b71249784778", "score": "0.6223951", "text": "function getUser(accessToken) {\n const headers = new Headers();\n headers.append(\"Authorization\", `Bearer ${accessToken}`);\n\n return fetch('https://www.googleapis.com/oauth2/v2/userinfo', { headers })\n .then(resp => resp.json(), err => console.log(err))\n}", "title": "" }, { "docid": "9f1e6d67439f1664669b78fc4e8347a1", "score": "0.6200818", "text": "function populate_user_cache() {\n\t\treturn fetch_endpoint('user')\n\t\t.then(function(user_info){\n\t\t\t// Store the apikey in the cache.\n\t\t\tuser_info.data.apikey = wkof.Apiv2.key;\n\t\t\twkof.Apiv2.user = user_info.data.username;\n\t\t\twkof.user = user_info.data\n\t\t\treturn wkof.file_cache.save('Apiv2.user', user_info);\n\t\t});\n\t}", "title": "" }, { "docid": "880395259cb1359e40c44a8e744e0fbc", "score": "0.6200482", "text": "updatedUserdata() {\n // Grabs a Stringify version of user account information from Google.\n var user = sessionStorage.getItem('account');\n // Creates a JSON object called user.\n user = JSON.parse(user);\n\n var url = new URL('http://localhost:8080/users/getUserById');\n var params = {userId: user.id};\n url.search = new URLSearchParams(params)\n fetch(url, {\n method: 'get',\n dataType: 'json',\n headers: {\n 'Accept': 'application/json',\n 'Content-Type': 'application/json',\n 'Authorization': sessionStorage.getItem('token'),\n },\n })\n .then(response => response.json())\n .then(response => {\n console.log('updated user: ', response);\n sessionStorage.setItem('account', JSON.stringify(response))\n return response\n })\n .catch(error => console.log('parsing failed. Error: ', error)) \n }", "title": "" }, { "docid": "b0e3198a14d741a0d8a4a7243aaed01f", "score": "0.61914885", "text": "function getUserInfo(){\n \n $.ajax({\n type: \"GET\",\n url: \"userInfo\",\n data: {\n },\n success: function(result) {\n $(\"#userName\").text(\"Welcome, \" + result.body.id);\n },\n failure: function(){\n alert(\"Unable to retrieve user info. Please refresh page and try again!\"); // TODO: refresh access token as this is most likely the cause of error.\n }\n });\n}", "title": "" }, { "docid": "86b95b08de63a342ff5e249fdba06caf", "score": "0.6188167", "text": "async fetchUserFromToken() {\n return await this.request({ endpoint: \"auth/me/\", method: \"GET\" });\n }", "title": "" }, { "docid": "28e530f5f40b4f3d91d09cb849b988b5", "score": "0.61751837", "text": "_getUser(access_token, done) {\n this.mlh.get('/user', {\n authenticated: access_token\n }, (err, body) => {\n if(err) return done(true);\n\n if(body.status === 'error') return done(body.error.message);\n\n return done(false, body);\n })\n }", "title": "" }, { "docid": "29959350831eef262bee94fff2826c69", "score": "0.61720717", "text": "getUsers(token) {\n axios\n .get(`https://ach2.herokuapp.com/users/${localStorage.getItem(\"user\")}`, {\n headers: { Authorization: `Bearer ${token}` },\n })\n .then((response) => {\n this.props.profile(response.data);\n })\n .catch(function (error) {\n console.log(error);\n });\n }", "title": "" }, { "docid": "bebf7a5e7a9f14dd84bd918675dd131c", "score": "0.61708283", "text": "function processAuth() {\n var auth = angular.fromJson(localStorage.auth);\n\n // Check token expiry. If the token is valid for another 5 minutes, we'll use it. \n var expiration = new Date();\n expiration.setTime((auth.expires - 300) * 1000);\n if (expiration > new Date()) {\n\n // Add the required Authorization header with bearer token.\n $http.defaults.headers.common.Authorization = 'Bearer ' + auth.access_token;\n\n // This header has been added to identify our sample in the Microsoft Graph service. If extracting this code for your project please remove.\n $http.defaults.headers.common.SampleID = 'angular-connect-rest-sample';\n\n if (localStorage.getItem('user') === null) {\n\n // Get the profile of the current user.\n GraphHelper.me().then(function (response) {\n\n // Save the user to localStorage.\n var user = response.data;\n localStorage.setItem('user', angular.toJson(user));\n\n //vm.displayName = user.displayName;\n //vm.emailAddress = user.mail || user.userPrincipalName;\n });\n } else {\n var user = angular.fromJson(localStorage.user);\n\n //vm.displayName = user.displayName;\n //vm.emailAddress = user.mail || user.userPrincipalName;\n }\n }\n }", "title": "" }, { "docid": "09a1e14a71b966e83cea4545bfe2fc26", "score": "0.61646605", "text": "function getUserInfo() {\n\t$.ajax({\n\t\turl: 'https://www.googleapis.com/oauth2/v1/userinfo?access_token=' + acToken,\n\t\tdata: null,\n\t\tsuccess: function(resp) {\n\t\t\tuser = resp;\n\t\t\tvar jsonObj = [];\n\t\t\tvar item={};\n\t\t\titem[\"name\"]=user.name;\n\t\t\titem[\"email\"]=user.email;\n\t\t\titem[\"source\"]='google';\n\t\t\tjsonObj.push(item);\n\t\t\tif (typeof user.name != 'undefined') {\n\t\t\t\t$(\"#socialMediaIntegrationData\").val(JSON.stringify(jsonObj));\n\t\t\t\t$(\"#saveDataInDB\").submit();\n\t\t\t}\n\t\t},\n\t\tdataType: \"jsonp\"\n\t});\n}", "title": "" }, { "docid": "374c54d05d0c77502da8733ec44fd977", "score": "0.6160277", "text": "static getAccessToken() {\n const user = this.getCurrentUser();\n if (user) {\n return user[ 'accessToken' ];\n } else {\n CommonService.getBrowserHistory().push('/')\n }\n }", "title": "" }, { "docid": "b44d695356eb93b895aa87f4f27d0853", "score": "0.6145065", "text": "getUserInformation(){\n\t\taxios.get(\"https://alarmbuddy-312620.uc.r.appspot.com/users/\"\n\t\t\t+ this.props.username, {\n\t\t\theaders: { \n\t\t\t\t'Authorization': this.props.token,\n\t\t\t}\n\t\t}\n\t\t\t).then(response => {\n\n\t\t\t\tif(response.status === 200) {\n\t\t\t\t\tthis.updateProfile(response.data[0]);\n\t\t\t\t\t\t\t\t\t}\t\n\t\t\t}).catch(error => {\n\t\t\t\tconsole.log(\"Profile Load Error\", error);\n\t\t});\n\t}", "title": "" }, { "docid": "5b46eed3366258b13844720ba1432e7d", "score": "0.61130553", "text": "function fetchUserData(accessToken, refreshToken, profile, done) {\n\n var serverList = []; // server info list\n var user = { profile: profile };\n\n Bot.guilds.cache.forEach(guild => {\n if (guild.ownerId === profile.id) {\n var server = Bot.servers.get(guild.id);\n if (server) {\n serverList.push({\n id: guild.id,\n name: guild.name,\n available: guild.available,\n iconImage: guild.iconURL() || null,\n memberCount: guild.memberCount\n });\n }\n }\n });\n\n var discordTag = `${profile.username}#${profile.discriminator}`;\n\n let logEvent = {\n author: 'Snowflake Web',\n message: `User Log In: ${discordTag}\\nDiscord User ID: ${profile.id}`,\n footer: new Date().toString(),\n type: 'default'\n };\n\n serverLog(Bot, logEvent);\n\n if (serverList.length > 0) {\n\n user.isRegistered = true;\n user.servers = serverList;\n return done(null, user);\n\n } else {\n return done(null, user);\n }\n }", "title": "" }, { "docid": "2d4d4c2a67ea9b6a1ae7ac38551db66e", "score": "0.6112633", "text": "function refresh(SAVED_ACCESS_TOKEN) {\n var defer = $q.defer();\n\n $rootScope.loggingIn = true;\n\n sc.auth(SAVED_ACCESS_TOKEN).then(function() {\n // we are authenticated, get the user data\n return sc('/api/v1/me').get();\n }).then(function(data) {\n $rootScope.user = data;\n\n vm.saved.uri = '/user/' + $rootScope.user.name + '/saved';\n saveDirtySaves();\n $rootScope.loggingIn = false;\n defer.resolve(data);\n }, function(err) {\n console.error(err);\n delete $localStorage.accessToken;\n defer.reject(err);\n });\n return defer.promise;\n }", "title": "" }, { "docid": "343c7527e3e4dc53828a6c9267cc39a9", "score": "0.6109687", "text": "async function autologin() {\n console.debug(\"|--- SERVER CALL ---|--- GET ---| userServices.autologin\");\n\n // No token, no autologin!\n const token = localStorage.getItem(\"accessToken\");\n if (!token) throw new Error({ error: \"no token!\" });\n\n const params = { access_token: token };\n const options = {\n method: \"GET\",\n url: `${config.boUrl}/users/me?${qs.stringify(params)}`,\n crossdomain: true,\n headers: { \"content-type\": \"application/x-www-form-urlencoded\" }\n };\n\n try {\n const response = await axios(options);\n const { user } = response.data;\n console.debug(\"[UserServices] Autologin response: \", response);\n localStorage.setItem(\"id\", user.id);\n localStorage.setItem(\"user\", JSON.stringify(user));\n // Add token to user\n user.accessToken = token;\n return user;\n } catch (error) {\n console.error(\"[UserServices] autologin error: \", error);\n throw error;\n }\n}", "title": "" }, { "docid": "84534bd1de86e333e712e6cf00c5877b", "score": "0.6070477", "text": "getUser() {\n const token = localStorage.getItem('token');\n const user = localStorage.getItem('user');\n return this.http.get(apiUrl + `users/${user}`, { headers: new _angular_common_http__WEBPACK_IMPORTED_MODULE_1__[\"HttpHeaders\"]({\n Authorization: 'Bearer ' + token,\n })\n }).pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_3__[\"map\"])(this.extractResponseData), Object(rxjs_internal_operators__WEBPACK_IMPORTED_MODULE_0__[\"catchError\"])(this.handleError));\n }", "title": "" }, { "docid": "58928f4d103356957f06d01b44f0b437", "score": "0.60671747", "text": "getCurrentUser(onSuccess) {\n let endpoint = BASE_URL + \"currentUser\";\n dataProvider.retrieveData(endpoint, onSuccess);\n }", "title": "" }, { "docid": "ac9c405a21938a46553a7ab254748658", "score": "0.60671157", "text": "resolveUser (access_token) {\n ENV.TMP_TORII_TOKEN = access_token;\n\n return this.store.find('user', 'current').then((user) => {\n ENV.TMP_TORII_TOKEN = null;\n localStorage.setItem(LSTokenItemName, access_token);\n return {currentUser: user, token: access_token};\n });\n }", "title": "" }, { "docid": "d07441722b3f6287da1f9e44c8a3b9f0", "score": "0.6064289", "text": "function populateStorage(data) {\n localStorage.setItem('username', data.user.username);\n localStorage.setItem('userID', data.user.id);\n localStorage.setItem('token', data.authToken);\n}", "title": "" }, { "docid": "8eb7b71bd8dd7f852f17b0b2507f75e3", "score": "0.60566044", "text": "async fetchUsers(context) {\n const res = await fetch(\"http://127.0.0.1:8000/api/register\", {\n \"method\": \"GET\",\n \"headers\": {\n Authorization: \"Bearer \"+localStorage.getItem('token')\n }\n })\n const data = await res.json();\n context.commit(\"setUsersList\", data);\n console.log(data)\n console.log(users)\n\n }", "title": "" }, { "docid": "083538c04be7f5bcbfd9d146d6110185", "score": "0.6053682", "text": "function userData() {\n $.get(\"/api/customers\", function (data) {\n customerData = data;\n // console.log(\"TESTING FOR USER DATA\");\n // console.log(customerData);\n\n for (i = 0; i < customerData.length; i++) {\n if (customerData[i].email === localStorage.getItem(\"email\")) {\n customerUserName = customerData[i].username;\n customerID = customerData[i].id;\n }\n }\n // console.log(customerUserName);\n // console.log(customerID);\n });\n }", "title": "" }, { "docid": "61fb38a415576bab6c4f1601a3ecec1b", "score": "0.6033615", "text": "function getFullProfile() {\n var baseURL = \"https://xplainr.auth0.com/api/v2/users/\"\n\n var user = localStorage.getItem('userId');\n var userId = user;\n url = baseURL + userId;\n var manage_token = localStorage.getItem('manage_token');\n var settings = {\n \"async\": true,\n \"crossDomain\": true,\n \"url\": url,\n \"method\": \"GET\",\n \"headers\": {\n \"content-type\": \"application/json\",\n \"authorization\": \"Bearer \" + manage_token\n }\n }\n $.ajax(settings).done(function(response) {\n\n //Check if they have a google account associated with their username/password login\n if (response.identities[0].connection == \"Username-Password-Authentication\" && !response.identities[1]) {\n getPizzaMessage.text('Order successful!');\n pizzaMessage.text('Enjoy your 42 inch pizza!');\n orderPizzaBtn.css('display', 'none');\n pizzaView.css('display', 'inline-block');\n userProfile = response\n }\n\n //Get and set google access token even if it is the second account merged into their profile\n else {\n googleAccessToken = response.identities[0].access_token\n if (!googleAccessToken) {\n googleAccessToken = response.identities[1].access_token\n googleUserId = response.identities[1].user_id\n userProfile = response\n\n } else {\n googleAccessToken = response.identities[0].access_token\n googleUserId = response.identities[0].user_id\n }\n localStorage.setItem('gToken', googleAccessToken);\n localStorage.setItem('gUserId', googleUserId);\n userProfile = response\n getGoogleContacts()\n }\n });\n }", "title": "" }, { "docid": "65c8a63099a484793d7376c3766739a5", "score": "0.6028309", "text": "async function getUserInfo(token) { \n try {\n const { data: { user } } = await request.get(`/users/me`);\n\n if (user) {\n store.dispatch({\n type: FETCH_CURRENT_USER_SUCCESS,\n payload: user,\n });\n }\n } catch (error) {\n store.dispatch({\n type: FETCH_CURRENT_USER_FAILURE,\n payload: error,\n });\n }\n}", "title": "" }, { "docid": "c0e97d85131824abc93b799ed7ee4822", "score": "0.6021893", "text": "async getUser({ accessToken, }) {\n const { data } = await this.$http.get('user', {\n headers: { Authorization: `bearer ${accessToken}` },\n });\n return normalizeUser(data, this.baseURL);\n }", "title": "" }, { "docid": "be4014c11111b4c9754be9acdc54682d", "score": "0.6017226", "text": "function getProfile() {\n $http.get(\"/api/auth/\").then(function (result) {\n auth.user = result.data;\n auth.user.loggedIn = true;\n $rootScope.user = auth.user;\n });\n }", "title": "" }, { "docid": "c28271f263d5e9c3eaf03703de6701bf", "score": "0.601321", "text": "async function getUser(){\n let response=await AsyncStorage.getItem('userData');\n let json=JSON.parse(response);\n setUser(json.id);\n }", "title": "" }, { "docid": "2cdef8d243e5e3a3dfcc5bf6bd0b0c3a", "score": "0.6005018", "text": "function saveTokens(tokens) {\n if (tokens) {\n MeanSsoApi.setUserAuthorizationHeader('Bearer', tokens.access_token);\n MeanSsoPrimus.setUserAuthorizationHeader('bearer', tokens.access_token);\n } else {\n MeanSsoApi.setUserAuthorizationHeader();\n MeanSsoPrimus.setUserAuthorizationHeader();\n }\n $window.localStorage[LOCAL_STORAGE_ID] = JSON.stringify(tokens);\n }", "title": "" }, { "docid": "c479101d3b69cbeb7175054174b62cec", "score": "0.5999022", "text": "function save_access_token() {\n\t\t// get file if it exists\n\t\tvar file = Ti.Filesystem.getFile(Ti.Filesystem.applicationDataDirectory, 'twitter.config');\n\t\t// create file if it doesn't exist\n\t\tif (file == null) {\n\t\t\tfile = Ti.Filesystem.createFile(Ti.Filesystem.applicationDataDirectory, 'twitter.config');\n\t\t}\n\n\t\t// write config\n\t\tvar config = {\n\t\t\taccess_token: cfg.access_token,\n\t\t\taccess_token_secret: cfg.access_token_secret\n\t\t};\n\t\tfile.write(JSON.stringify(config));\n\n\t\tTi.API.debug('Saving access token: '+JSON.stringify(config));\n\t}", "title": "" }, { "docid": "f3dcd4bb2be34795005b19f26774fa20", "score": "0.5994107", "text": "function saveUserAndDeviceToken() {\n\n}", "title": "" }, { "docid": "bc56daef037941d8127fecbba2dbaa94", "score": "0.5989288", "text": "populate() {\n if (this.jwtService.getToken()) {\n this.apiService.get('/token')\n .then(data => {\n this.setAuth(data)\n return data;\n },err => {\n return \"Error occured.\";\n })\n } else {\n // Remove any potential remnants of previous auth states\n this.purgeAuth();\n }\n }", "title": "" }, { "docid": "7192bab69111b8a552a943c72834084c", "score": "0.59859115", "text": "async function getUserInfo() {\n return client.request('GET', 'users/current').then(response => response.body);\n}", "title": "" }, { "docid": "7192bab69111b8a552a943c72834084c", "score": "0.59859115", "text": "async function getUserInfo() {\n return client.request('GET', 'users/current').then(response => response.body);\n}", "title": "" }, { "docid": "ae1b0d6ddd4effcd8c8669c174a60312", "score": "0.5949206", "text": "_setToken(userData){\n\t\tlocalStorage.token = Math.random().toString(36).substring(7);\n localStorage.setItem(\"userName\",userData.data.username);\n localStorage.setItem(\"firstName\",userData.data.firstName);\n\t\tlocalStorage.setItem(\"lastName\",userData.data.lastName);\n\t}", "title": "" }, { "docid": "2f31df03535031347157a7b417720015", "score": "0.59458816", "text": "function gotProfile(accessToken, refreshToken, profile, done) {\n //console.log(\"Google profile\",profile);\n // here is a good place to check if user is in DB,\n // and to store him in DB if not already there. \n // Second arg to \"done\" will be passed into serializeUser,\n // should be key to get user out of database.\n\n let dbRowID = profile.id;\n // key for db Row for this user in DB table.\n // Note: cannot be zero, has to be something that evaluates to\n // True. \n\t\n\tdb.get(`SELECT * FROM Usernames WHERE user=\\'${profile.id}\\'`, dataCallback);\n\tfunction dataCallback(err, rowData){\n\t\tconsole.log(\"callback: check db for user\");\n\t\tif(err){console.log(\"error: \",err);}\n\t\telse{\n\t\t\tif(rowData == undefined){\n\t\t\t\tcmdStr = 'INSERT INTO Usernames(user, username, last_seen) VALUES(@0,@1,0)';\n\t\t\t\tdb.run(cmdStr,profile.id,profile.displayName,function(err){\n\t\t\t\t\tconsole.log(\"callback: add user to db\");\n\t\t\t\t\tif (err) {\n\t\t\t\t\t\treturn console.log(err.message);\n\t\t\t\t\t}\n\t\t\t\t\tconsole.log(`A row has been inserted with rowid ${this.lastID}`);\n\t\t\t\t\n\t\t\t\t});\n\t\t\t}\t\n\t\t\t//console.log(\"got: \", rowData, \"\\n\");\n\t\t}\n\t}\n\n\t//TODO:check for username in database\n\t//if new user, store username and send to make cards\n\t//if returning user, send to review cards\n\n done(null, dbRowID); \n}", "title": "" }, { "docid": "520af583351697eb9a725eccd4c1ced1", "score": "0.59413946", "text": "function getProfileSilent() {\n if (!userProfile) {\n var accessToken = localStorage.getItem('access_token');\n\n if (!accessToken) {\n //console.log('Access token must exist to fetch profile');\n }\n\n webAuth.client.userInfo(accessToken, function(err, profile) {\n if (profile) {\n userProfile = profile;\n var userId = userProfile.sub\n localStorage.setItem('userId', userId);\n }\n });\n } else {}\n }", "title": "" }, { "docid": "4edc30d0f82f1d3dbefe06836a2bdd2d", "score": "0.59378964", "text": "responseAfterLoggedIn(res){\n const token = res.data.access_token\n const user = res.data.user\n if(Token.isValid(token)){\n AppStorage.store(user, token)\n }\n }", "title": "" }, { "docid": "778b34c10bf82b9fd9fe919904928ec7", "score": "0.59271455", "text": "function gotProfile(accessToken, refreshToken, profile, done) {\n console.log(\"Google profile\",profile); //<-------------------------------------------------------profile.emails will be email address\n console.log(\"Google email domain\", profile._json.hd); \n\n // here is a good place to check if user is in DB,\n // and to store them in DB if not already there. \n // Second arg to \"done\" will be passed into serializeUser,\n // should be key to get user out of database.\n\n let UNIQUE_ID = profile._json.email; // temporary! Should be the real unique\n // key for db Row for this user in DB table.\n // Note: cannot be zero, has to be something that evaluates to\n // True. \n if (profile._json.hd != 'ucdavis.edu') {\n UNIQUE_ID = 3;\n }\n\n console.log(\"The UNIQUE ID IS \", UNIQUE_ID);\n done(null, UNIQUE_ID);\n}", "title": "" }, { "docid": "78f0429d2ec2548ed74cbd8139d18fd5", "score": "0.5920642", "text": "async function getUserInfo() {\n let userData = await Auth.currentAuthenticatedUser();\n setUser(userData.username);\n }", "title": "" }, { "docid": "1f917100b94abe1488d18b31d7c97b5b", "score": "0.5920508", "text": "function gotProfile(accessToken, refreshToken, profile, done) {\n console.log(\"Google profile\",profile);\n // here is a good place to check if user is in DB,\n // and to store him in DB if not already there.\n // Second arg to \"done\" will be passed into serializeUser,\n // should be key to get user out of database.\n\n let dbRowID = 1; // temporary! Should be the real unique\n // key for db Row for this user in DB table.\n // Note: cannot be zero, has to be something that evaluates to\n // True.\n\n done(null, dbRowID);\n}", "title": "" }, { "docid": "3d160d371a93b57ffe94a34742989cdb", "score": "0.5919546", "text": "retrieveUser(token) {\r\n return this._call('get', 'user', undefined, token)\r\n }", "title": "" }, { "docid": "63b373e8e9fa958d7b5d4e2ebc1cbdaf", "score": "0.59153754", "text": "get accesstoken() {\n return this.accessToken.access_token;\n }", "title": "" }, { "docid": "c332494e63c57c2ea0872de01fe411ab", "score": "0.5908826", "text": "async function fetchUserStatus() {\n await AsyncStorage.getItem(\"userToken\")\n .then(async (token) => {\n UpdateXtoken(token);\n await apiGetUserStatus(token)\n .then((res) => {\n //all is well\n })\n .catch((error) => {\n //user access denied\n signOut();\n });\n })\n .catch((error) => {\n signOut();\n });\n }", "title": "" }, { "docid": "8f3a472b073b2d791151a016085f9555", "score": "0.59055847", "text": "refreshUser() {\n /* try and get new user information based on current token. Returns user if good or response if bad */\n return new Promise((resolve, reject) => {\n if (this.authToken === \"0\")\n return reject({ status: 401, detail: \"No authtoken\" });\n\n axios\n .get(restURL + \"/customers/get-with-token/\", {\n headers: {\n Authorization: \"Token \" + this.authToken,\n },\n })\n .then((response) => {\n let data = {\n ...response.data,\n isAuth: true,\n };\n this.currentUser = data;\n return resolve(data);\n })\n .catch((err) => {\n if (err.response) reject(err.response);\n else reject({ status: 0 });\n });\n });\n }", "title": "" }, { "docid": "f6d1f69027c15f361f277aa8982c856f", "score": "0.58835936", "text": "function getUserInfo ( token, callback) {\n\tconst pusher = new Pushbullet(token);\n\n\tpusher.me(function(err, response) {\n\t\t\tHomey.ManagerSettings.set('userinfo', {\n\t\t\t\tname\t: response.name,\n\t\t\t\temail : response.email,\n\t\t\t\ttoken : token\n\t\t});\n\t\t\tconsole.log('Pushbullet - Userinfo saved');\n\t\t\tcallback(true);\n\t\t});\n}", "title": "" }, { "docid": "b038f9f93ba860691f1ef09d8220c4e4", "score": "0.5880807", "text": "function getUserProfile () {\n if (!userProfile) {\n var accessToken = localStorage.getItem('access_token');\n\n if (!accessToken) {\n swal({\n type: 'warning',\n title: 'Missing Data',\n text: 'Access token must exist to fetch user profile'\n });\n }\n\n webAuth.client.userInfo(accessToken, (err, profile) => {\n if (profile) {\n userProfile = profile;\n displayProfile();\n }\n });\n } else {\n displayProfile();\n }\n }", "title": "" }, { "docid": "d9aebff9745b42b0a37b9b59ffc13263", "score": "0.58754206", "text": "_getFbUser (req, res, next) {\n Facebook.getUser(req.body.accessToken, function (err, user) {\n if (err) {\n return next(err);\n }\n\n user.role = Models.users.ROLE.USER;\n req.local = user;\n next();\n })\n }", "title": "" }, { "docid": "c801de374f71f18d25d11187c78b3f17", "score": "0.5871814", "text": "function usersGet() {\n\t /*\n\t* Here we need to change 'api/users' with the appropriate \n\t* server url we want to use!\n\t*/\n return jsonRequester.get('api/users')\n .then(function(response) {\n return response.result;\n });\n }", "title": "" }, { "docid": "bc08847ada25ab08a1f851b0c323bcde", "score": "0.58707756", "text": "function tokenGetter() {\n //console.log(localStorage.getItem('AccessToken'))\n return localStorage.getItem('AccessToken');\n}", "title": "" }, { "docid": "8e3f27e215bf1cb2af241aaf38bff064", "score": "0.5868713", "text": "function pullData() {\n if (localStorage.user) {\n\n var data = localStorage.getItem('user');\n\n var parsedData = JSON.parse(data);\n\n User.all = parsedData;\n }\n\n}", "title": "" }, { "docid": "7fe994e16ba3e01fb69e8ba0535fb255", "score": "0.58618426", "text": "function getUserInfo () {\n return userInfo;\n }", "title": "" }, { "docid": "d03c054d9be667265ace0c176f33905e", "score": "0.5861052", "text": "getAccessToken() {\n return accessToken\n }", "title": "" }, { "docid": "355650a71b3906a6521a56ba77a9004e", "score": "0.5859777", "text": "function getUserData(token) {\n\tvar xhr = new XMLHttpRequest();\n\txhr.onload = function () {\n\t if (xhr.status >= 200 && xhr.status < 300) {\n\t const response = JSON.parse(xhr.response);\n\n\t if (response.session.gamesWon !== undefined) {\n\t \tupdateGamesWonElement(response.session.gamesWon);\n\t \t}\n\n\t \tif (response.session.gamesLost !== undefined) {\n\t \tupdateGamesLostElement(response.session.gamesLost);\n\t \t}\n\t \trefreshStats();\n\t } else {\n\t console.log('The request failed!');\n\t }\n\t};\n\n\txhr.open('GET', SERVER_URL + '/getUserData/' + token);\n\txhr.send();\n}", "title": "" }, { "docid": "9ab82114c4e51c20d6eb634e930db91f", "score": "0.5858855", "text": "async function getToken() {\n await spotifyApi.clientCredentialsGrant().then(\n function(data) {\n console.log('The access token expires in ' + data.body['expires_in']);\n console.log('The access token is ' + data.body['access_token']);\n \n // Save the access token so that it's used in future calls\n spotifyApi.setAccessToken(data.body['access_token']);\n },\n function(err) {\n console.log('Something went wrong when retrieving an access token', err);\n }\n );\n}", "title": "" }, { "docid": "0364ce6238e2d087899fc5409f1d0de7", "score": "0.5858059", "text": "async function saveUserCredentialsInLocalStorage() {\n if (currentUser) {\n let teamsList = await Team.getTeams();\n\n favName = teamsList.find(function (obj) {\n if (obj[\"id\"] == favTeam) return obj;\n });\n\n localStorage.setItem(\"username\", currentUser.username);\n localStorage.setItem(\"userId\", currentUser.userId);\n localStorage.setItem(\"favTeamId\", favTeam);\n localStorage.setItem(\"favTeamName\", favName.name);\n }\n}", "title": "" }, { "docid": "12e5d4ced97025519a133e89c4581743", "score": "0.585336", "text": "async refreshUserInfo() {\n const data = await this.get('/user/info');\n let userInfo;\n try {\n userInfo = JSON.parse(data);\n } catch (e) {\n throw new Error(`Error parsing response for /user/info`);\n }\n\n if (userInfo && userInfo.user && userInfo.companies[0]) {\n const user = userInfo.user;\n const companyId = userInfo.user.company_id;\n const company = userInfo.companies.find(c => c.id === companyId);\n\n return await this.userConfig.append({\n auth: {\n token: this.accessToken,\n sorcerer: user.sorcerer_auth_token\n },\n user: {\n id: user.id,\n email: user.email,\n features: user.features || {},\n company_id: user.company_id\n },\n company: {\n id: company.id,\n name: company.name,\n slug: company.slug,\n products: company.products\n },\n updated: new Date()\n });\n } else {\n throw new Error('There was a problem authenticating');\n }\n }", "title": "" }, { "docid": "c1ceb1ff3a2d305394e10c5292b311d2", "score": "0.5840639", "text": "getUser() {\n this.http\n .get(this.url + 'user')\n .pipe(Object(rxjs_operators__WEBPACK_IMPORTED_MODULE_0__[\"map\"])((x) => {\n return x;\n }))\n .subscribe((x) => {\n /* get user from response and set it to local storrage */\n this.user = x.data.user;\n localStorage.setItem('user', JSON.stringify(this.user));\n }, (e) => {\n console.log(e);\n /* in case of error remove token and user from localstorrage */\n localStorage.removeItem('user');\n localStorage.removeItem('token');\n });\n }", "title": "" }, { "docid": "ddbeb45763ca9d2ee05dfe1bddd01b76", "score": "0.5834871", "text": "setUserAndTOken(user, token) {\r\n this.user = user;\r\n this.token = token;\r\n localStorage.setItem('user', user);\r\n localStorage.setItem('token', token);\r\n }", "title": "" }, { "docid": "28842da6bf904405edf44d1250b5488a", "score": "0.58344007", "text": "async function getGithubUser(access_token) {\n console.log(\"getGithubUser\");\n const req = await fetch(\"https://api.github.com/user\", {\n headers: {\n Authorization: `bearer ${access_token}`,\n },\n });\n console.log(access_token);\n const data = await req.json();\n console.log(\"***data:\", data);\n return data;\n }", "title": "" }, { "docid": "7de49f80168cca74c5506d2e82984fac", "score": "0.5834048", "text": "function saveUserCredentialsInLocalStorage() {\n // console.debug(\"saveUserCredentialsInLocalStorage\");\n if (currentUser) {\n localStorage.setItem(\"token\", currentUser.loginToken);\n localStorage.setItem(\"username\", currentUser.username);\n }\n}", "title": "" }, { "docid": "d214a455b731e951bfe3998e749e3e73", "score": "0.58322513", "text": "async getAccessToken() {\n const currentUserToken = await AsyncStorage.getItem(`${this.namespace}`);\n\n return currentUserToken ? JSON.parse(currentUserToken) : null;\n }", "title": "" }, { "docid": "b8bf27546c70e32c1fbd9bc01dbaa2d5", "score": "0.58260834", "text": "async updateUserValues(json){\r\n this.accessToken = `Bearer ${json.accessToken}`;\r\n this.clientToken = json.clientToken;\r\n\r\n this.username = json.selectedProfile.name;\r\n this.uuid = json.selectedProfile.id;\r\n }", "title": "" }, { "docid": "91002e7614a41a3a7d9922e75fc48570", "score": "0.5825232", "text": "function getUser() {\n \n var username = dom.$ghUserInput.val();\n \n $.getJSON(api.endpoint + username, api.params)\n .then(getRepos); // then call getRepos()\n }", "title": "" }, { "docid": "f9c500038173c44fc626434d1b8d07a6", "score": "0.58221155", "text": "function getCurrentUserData(){\n var user;\n userStatus.getCurrent().then(function(result){\n if(result !== 'anonymous' && result.uid){\n formattedData.getData().then(function(data){\n console.log('formatted data acquired');\n });\n user = {\n uid: result.uid,\n isPaid: false,\n isAdmin: false\n };\n userStatus.isAdmin(result.uid).then(function(res){\n isAdmin = true;\n user.isAdmin = true;\n }).catch(function(res){\n isAdmin = false;\n user.isAdmin = false;\n });\n } else {\n fetchService.clearCache();\n user = {\n uid: 'anonymous',\n isPaid: false,\n isAdmin: false\n }\n }\n currentUser = user;\n updateRootUser(user);\n }).catch(function(err){\n $rootScope.globalError = 'Cannot get user data at the moment. Please try again later';\n console.error(err);\n });\n }", "title": "" }, { "docid": "1beec2d7b758267acb293108f0e67775", "score": "0.58162105", "text": "function saveUserCredentialsInLocalStorage() {\n console.debug(\"saveUserCredentialsInLocalStorage\");\n if (currentUser) {\n localStorage.setItem(\"token\", currentUser.loginToken);\n localStorage.setItem(\"username\", currentUser.username);\n }\n}", "title": "" }, { "docid": "48521d546284b898b8d85fbd9cc8e5d0", "score": "0.58136797", "text": "getAccessTokens(){\n //Todo: Change it to set all tokens in store and change id of user (get it from cookies)\n Axios.get(\"http://localhost:5050/basic_inst_token/\"+Cookies.get('id')+\"?token=\"+Cookies.get(\"sessionToken\")).then((response)=>{\n if(response.status === 200){ \n \n let tokenData = response.data.token\n console.log(tokenData.access_token)\n this.props.setInstBasicAccessToken({\n tried :true,\n token:{\n token: tokenData.access_token,\n userId: tokenData.userId || \"\" \n }\n })\n }else{\n //If no token founded in response\n this.props.setInstBasicAccessToken({\n tried :true,\n token:{\n accessToken: \"\",\n userId: \"\"\n } \n })\n }\n }).catch((error)=>{\n this.setState({\n errorOccur: true\n })\n console.log(error)\n })\n }", "title": "" }, { "docid": "f2177ccd8ee44eb9f4b40b9cf48f8d94", "score": "0.58124226", "text": "function getBearerToken(code, userId) {\n request.post(\"https://unsplash.com/oauth/token?client_id=\" + unsplashCred.applicationId + \"&client_secret=\" + unsplashCred.secret + \"&redirect_uri=http://sloogle.herokuapp.com/sloogle\" + \"&code=\" + code + \"&grant_type=authorization_code\", function (error, response, body) {\n db.none('UPDATE users SET token=$1 WHERE id=$2', [(JSON.parse(response.body)).access_token, userId])\n .then(function () {\n // console.log(JSON.parse(response.body));\n // console.log('token:' + JSON.parse(response.body).access_token + ', added to user: ' + userId);\n getUserName((JSON.parse(response.body).access_token), userId);\n })\n });\n}", "title": "" }, { "docid": "dff5f62a7013504313f59798263c8748", "score": "0.5808891", "text": "getUserInfo() {\n return this.http.get('http://localhost:59038/api/account');\n }", "title": "" }, { "docid": "ecc3b8c3c1b3cc76b4bd798ae63f7fa6", "score": "0.5808069", "text": "function getUserInfo() {\n return userInfo;\n }", "title": "" }, { "docid": "80e9821e916e4328c32bfa461d9b185f", "score": "0.5805515", "text": "function getInfo(id,token,user, response){\n const headers = {\n 'Accept':'application/json',\n 'Authorization' : 'Bearer ' + token\n };\n\n fetch('https://www.polaraccesslink.com/v3/users/'+id,\n{\n method: 'GET',\n headers: headers\n})\n.then(function(res) {\n return res.json();\n}).then(function(body) {\n data.storeUser(body,user);\n return response(id); //storing data in Qridi database\n});\n}", "title": "" }, { "docid": "60d041b110994f95a68e094bde3f8047", "score": "0.5799758", "text": "function getUserInfo(token) {\n console.log({token })\n // adding the token to the local storage\n localStorage.setItem(\"token\", JSON.stringify(token));\n // setting userInfo variable to token userInfo\n const userInfo = token.userInfo;\n // adding userInfo to currentUserSubject\n currentUserSubject.next(userInfo);\n \n return userInfo;\n}", "title": "" }, { "docid": "0a48c9ad57e6696daf30c27fee158c92", "score": "0.5795837", "text": "function useAccessAuth() {\n return new Promise(function (resolve, reject) {\n if (!_defaults2.default.accessToken) {\n reject((0, _fns.__generateFakeResponse__)(0, '', {}, 'accessToken is missing for Access authentication'));\n } else {\n var details = {\n \"token_type\": \"\",\n \"expires_in\": 0,\n \"appName\": _defaults2.default.appName,\n \"username\": \"\",\n \"role\": \"\",\n \"firstName\": \"\",\n \"lastName\": \"\",\n \"fullName\": \"\",\n \"regId\": 0,\n \"userId\": null\n };\n var aToken = _defaults2.default.accessToken.toLowerCase().startsWith('bearer') ? _defaults2.default.accessToken : 'Bearer ' + _defaults2.default.accessToken;\n _utils2.default.storage.set('user', {\n token: {\n Authorization: aToken,\n appName: _defaults2.default.appName\n },\n details: details\n });\n resolve((0, _fns.__generateFakeResponse__)(200, 'OK', {}, details, {}));\n }\n });\n}", "title": "" }, { "docid": "6626a26b446f964b39ed359cd36ce39c", "score": "0.5785799", "text": "loadUserDetails() {\n $http({\n url: HsStatusManagerService.endpointUrl() + '?request=getuserinfo',\n }).then(me.setUserDetails, (err) => {});\n }", "title": "" }, { "docid": "bc7f2d142f4a49e2ffe09d17b7f74a1f", "score": "0.5784509", "text": "getAllUsers() {\n axios.get(API_URL + \"/admin/users\", {\n headers: {\"Authorization\" : `Bearer ${localStorage.getItem('token')}`}\n }).then(res => {\n console.log(res);\n }).catch(err => console.log(err));\n }", "title": "" }, { "docid": "7a2fe4b2077a90d0f66d6df0b02b570e", "score": "0.57791525", "text": "function reqApires() {\n fetch(\"https://randomuser.me/api/\")\n .then((res) => res.json())\n .then((json) => {\n sessionStorage.setItem(\"userdata\", JSON.stringify(json));\n setDataFromSession(); // set data to html from SessionStorage\n });\n}", "title": "" }, { "docid": "7c33b252712aa9d06ea29254a9e348ad", "score": "0.57784605", "text": "static async getLoggedInUser(token, username) {\n // if we don't have user info, return null\n if (!token || !username) return null;\n\n // call the API\n const response = await axios.get(`${BASE_URL}/users/${username}`, {\n params: {\n token\n }\n });\n\n // instantiate the user from the API information\n const existingUser = new User(response.data.user);\n\n // attach the token to the newUser instance for convenience\n existingUser.loginToken = token;\n\n // instantiate Story instances for the user's favorites and ownStories\n existingUser.favorites = response.data.user.favorites.map(s => new Story(s));\n existingUser.ownStories = response.data.user.stories.map(s => new Story(s));\n return existingUser;\n\n }", "title": "" }, { "docid": "89a67e60fcfefe8e0ab5d54abe282a6d", "score": "0.5777414", "text": "async function getRemoteUserInfo(token) {\r\n // this will use the access token to get user details\r\n const userResponse = await superagent.get(`https://oauth2.googleapis.com/tokeninfo?access_token=${token}`)\r\n .set('user-agent', 'express-app')\r\n .set('Authorization', `token ${token}`);\r\n\r\n const user = userResponse.body;\r\n return user;\r\n}", "title": "" }, { "docid": "09190473b712cf20e5b38666f3e54f57", "score": "0.5773463", "text": "async localLogin() {\n const {accessToken, refreshToken, usuarioLogado} = getAuthLocal();\n\n if (accessToken && refreshToken && usuarioLogado && usuarioLogado.id) {\n this.usuarioStore.isAuthenticated = true;\n await this.saveTokens({access_token: accessToken, refresh_token: refreshToken});\n }\n }", "title": "" }, { "docid": "c11a1c2474ac53bca42f4d0a4a2ac8c6", "score": "0.5771666", "text": "function getUsers() {\n var auth = $firebaseAuth();\n var firebaseUser = auth.$getAuth();\n if(firebaseUser){\n firebase.auth().currentUser.getToken().then(function(idToken) {\n $http({\n method: 'GET',\n url: '/admin/manageUsers',\n headers: {\n id_token: idToken\n }\n }).then(function(response){\n allUsers.list = response.data;\n console.log(allUsers.list);\n for (var i = 0; i < allUsers.list.length; i++) {\n if(allUsers.list[i].ideas_flags_count == null){\n allUsers.list[i].ideas_flags_count = 0;\n }\n if(allUsers.list[i].comments_flags_count == null){\n allUsers.list[i].comments_flags_count = 0;\n }\n if(allUsers.list[i].subflags_count == null){\n allUsers.list[i].subflags_count = 0;\n }\n }\n })\n });\n }\n}", "title": "" }, { "docid": "0027f7cc9d387663bfb5bb73a3d096fc", "score": "0.5771082", "text": "function getData() {\n\n //make the user JSON\n var userData = {\n username: document.getElementById('reg_username').value,\n password: document.getElementById('reg_password').value,\n passwordConfirm: document.getElementById('reg_password_confirm').value,\n email: document.getElementById('reg_email').value,\n name: document.getElementById('reg_fullname').value\n };\n //get user data from localStorage if that information exist\n var users = JSON.parse(localStorage.getItem('users'));\n //if not we will create it\n if (!users){\n users = [];\n }\n //insert in the next open position of the array the user data\n users.push(userData);\n //this is for saving the information on local storage\n localStorage.setItem('users', JSON.stringify(users));\n //location= '../Anime.html';\n\n }", "title": "" }, { "docid": "228c01fc86792a26d1d64ae4f69e6745", "score": "0.5767654", "text": "function getTokenInformation() {\n var token = $localStorage.token;\n var user = {};\n if (typeof token !== 'undefined') {\n var encoded = token.split('.')[1];\n user = JSON.parse(base64Decode(encoded));\n }\n return user;\n }", "title": "" }, { "docid": "80e96bd7536c673a74f0312e8786de44", "score": "0.5766699", "text": "getUserDetails() {\n this.makeGETRequest('getuserinfo','userinfoloaded','userInfo');\n }", "title": "" }, { "docid": "67df98b8a137b1fd2c34616821e29325", "score": "0.5757162", "text": "async info() {\n const {appid, openid} = this.ctx.wxuser;\n const info = await this.service.user.query({appid, openid});\n this.ctx.body = {\n data: info,\n success: true,\n };\n }", "title": "" }, { "docid": "decd76de163d39f4fb5d3a826cc87a41", "score": "0.57554096", "text": "async saveToken () {\n\t\tconst input = this.isClientToken ? this.request.query : this.request.body;\n\t\tconst token = (this.tokenData && this.tokenData.accessToken) || input.token;\n\t\tif (!token) {\n\t\t\tthrow this.errorHandler.error('updateAuth', { reason: 'token not returned from provider, tokenData is ' + JSON.stringify(this.tokenData) });\n\t\t}\n\t\tthis.tokenData = this.tokenData || { accessToken: token };\n\t\tif (this.request.body.data) {\n\t\t\tthis.tokenData.data = this.request.body.data;\n\t\t}\n\t\tconst modifiedAt = Date.now();\n\n\t\t// if (and only if) the user previously had credentials above the team level (as in, they used the provider for sign-in),\n\t\t// ignore the team parameter and set the data at that level ... this supports a re-auth in case their original token starts failing\n\t\tlet setKey;\n\t\tif (\n\t\t\t(this.user.get('providerInfo') || {})[this.provider] &&\n\t\t\t(this.user.get('providerInfo') || {})[this.provider].accessToken\n\t\t) {\n\t\t\tsetKey = `providerInfo.${this.provider}`;\n\t\t} else {\n\t\t\tsetKey = `providerInfo.${this.team.id}.${this.provider}`;\n\t\t\tif (this.host) {\n\t\t\t\tconst host = this.host.replace(/\\./g, '*');\n\t\t\t\tsetKey += `.hosts.${host}`;\n\t\t\t}\n\t\t}\n\n\t\t// add sub-keys for enterprise hosts\n\t\t// add sub-keys for providers that support multiple access tokens, only allowed in sharing model\n\t\tlet multiKeys = {};\n\t\tconst op = { $set: {}, $unset: {} };\n\t\tif (this.sharing) {\n\t\t\tconst multiAuthExtraData = await this.serviceAuth.getMultiAuthExtraData(this.tokenData, { request: this });\n\t\t\tif (multiAuthExtraData) {\n\t\t\t\tconst multiAuthKeyExtraDataBySetKey = Object.keys(multiAuthExtraData).reduce(function (map, key) {\n\t\t\t\t\tmap[`${setKey}.multiple.${key}`] = multiAuthExtraData[key];\n\t\t\t\t\treturn map;\n\t\t\t\t}, {});\n\t\t\t\tmultiKeys = { ...multiAuthKeyExtraDataBySetKey };\n\t\t\t}\n\n\t\t\tconst providerUserId = await this.serviceAuth.getUserId(this.tokenData);\n\t\t\tif (providerUserId) {\n\t\t\t\tconst identity = `${this.provider}::${providerUserId}`;\n\t\t\t\tif (!(this.user.get('providerIdentities') || []).find(id => id === identity)) {\n\t\t\t\t\top.$addToSet = { providerIdentities: identity };\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse {\n\t\t\tmultiKeys[setKey] = undefined;\n\t\t}\n\n\t\tfor (let multiKey of Object.keys(multiKeys)) {\n\t\t\tfor (let key of Object.keys(this.tokenData)) {\n\t\t\t\tconst dataKey = `${multiKey}.${key}`;\n\t\t\t\top.$set[dataKey] = this.tokenData[key];\n\t\t\t}\n\t\t\tif (multiKeys[multiKey]) {\n\t\t\t\top.$set[`${multiKey}.extra`] = Object.assign({}, op.$set[`${multiKey}.extra`] || {}, multiKeys[multiKey]);\n\t\t\t}\n\n\t\t\t// remove any previous token error\n\t\t\top.$unset[`${multiKey}.tokenError`] = true;\n\t\t}\n\n\t\top.$set.modifiedAt = modifiedAt;\n\t\tthis.transforms.userUpdate = await new ModelSaver({\n\t\t\trequest: this,\n\t\t\tcollection: this.data.users,\n\t\t\tid: this.user.id\n\t\t}).save(op);\n\t}", "title": "" }, { "docid": "850ce33345b1f81793d69b5eb235c9e1", "score": "0.57534647", "text": "function getAuthenticatedUser() {\n // get request\n const token = localStorage.getItem(\"webscrapper-token\");\n\n // redirect to login page if token not present\n if (!token) {\n location.href = \"/\";\n }\n\n // verify token\n // GET request\n $.ajax({\n type: \"get\",\n url: \"/users/profile?secret_token=\" + token,\n dataType: \"json\",\n success: function (response) {\n // Print response to console for debugging purpose\n console.log(response);\n\n // Set user_name in navbar\n $(\"#user_name\").text(response.user.name);\n // Update url for edit user button\n $(\"#user_edit\").attr(\n \"href\",\n \"/dashboard/users/edit?email=\" + response.user.email\n );\n },\n error: function (error) {\n // Print error message in console\n console.log(\"An error has occured\");\n console.error(error.responseText);\n\n // redirect to login page if token not present\n location.href = \"/\";\n },\n });\n}", "title": "" }, { "docid": "da8ef300af391669c7e00f7a161ffd72", "score": "0.57499367", "text": "function generateAuthTokens(code, id) {\n return new Promise((resolve, reject) => {\n const localoAuth2Client = getoAuthClient();\n localoAuth2Client.getToken(code, function (err, tokens) {\n if (err) {\n reject(err);\n } else {\n localoAuth2Client.setCredentials(tokens);\n //Get the user's email\n plus.people.get({auth: localoAuth2Client, userId: 'me'}, function(err, resp) {\n if (err) reject(err);\n const email2 = resp.emails[0].value;\n //Update the user profile with their email & google tokens\n User.findByIdAndUpdate(id, {google: tokens, authenticated: true, email: email2}, function(err, result) {\n if (err) reject(err);\n resolve();\n });\n })\n }\n });\n\n })\n\n}", "title": "" }, { "docid": "5f906111fad8d4d09ed8f33a0b2dc6c6", "score": "0.5746175", "text": "static createAndSaveRefreshToken(req, res, next) {\n req.user.refreshToken = sha256.x2(((Date.now() + req.user.id) * Math.floor(Math.random() * (20 - 2 + 1)) + 2).toString());\n req.user.update({\n refreshToken: req.user.refreshToken\n })\n .then(function (user) {\n next();\n })\n .catch(next)\n }", "title": "" }, { "docid": "6040646697cce5526ad8aa733ae150d1", "score": "0.57435817", "text": "function getUser() {\n return JSON.parse(localStorage.getItem('user'));\n }", "title": "" }, { "docid": "195ce031b2c20a026a4a255af8008888", "score": "0.5738447", "text": "getUsers() {\n this.ac.get('/api/users').then(res => {\n this.users = res.content;\n });\n }", "title": "" }, { "docid": "7d2da8a7ab119ddccc9e64155ee33281", "score": "0.5738305", "text": "getUsers(){\n angular.forEach(this.users, (userID) => {\n this.User.get(userID).then((data) => this.userData.push(data));\n });\n }", "title": "" } ]
79b433d25e1ed28db0654a9607db152b
anything that is passed to an exec must be validated or sanitized we use the term sanitize here lightly in this instance this // ////validates
[ { "docid": "b1f1140efc6eed09b4a52785cc83ad2c", "score": "0.0", "text": "function safeString(stringToCheck) {\n return (\n validator.isAscii(stringToCheck) &&\n validator.matches(stringToCheck, /^((\\w)*[-.]?(\\w)*)*$/)\n );\n}", "title": "" } ]
[ { "docid": "9f61e9d162fa02dae644e6132c0822fe", "score": "0.6318564", "text": "static sanitize(value) {\n return (value || '').toString().replace(/[^a-zA-Z0-9\\-_. @$!%^&()+=,]/g, '');\n }", "title": "" }, { "docid": "25a1628463ea6835be061da2c8044cba", "score": "0.62008476", "text": "function sanitize(str) {\n\n return str;\n}", "title": "" }, { "docid": "aac77d331739eef9531625ef9f79ee18", "score": "0.61088306", "text": "function sanitizeString(text) {\n return validator.escape( validator.trim(text) );\n }", "title": "" }, { "docid": "209ec6c640806f5dd0cc2021ad8c555b", "score": "0.5929125", "text": "function cleanArgs(str) {\t\n\tstr = decodeURIComponent(str);\n\tstr = str.replace(/'t/,'').replace(/'s/,'s');\n\tstr = str.replace(/(&|\\$)+/g,' ');\n\tstr = str.replace(/(&|\\?|:|\"|'|@|\\+|#)+/g,'');\n\treturn trim(str);\n}", "title": "" }, { "docid": "44ff4b5147fa090bf5b8219eb6dfe6f6", "score": "0.5895301", "text": "function sanitize(something) {\n const somethingType = (typeof something);\n switch (somethingType) {\n case \"object\":\n return sanitizeObject(something);\n break;\n case \"boolean\":\n case \"number\":\n return something;\n break;\n case \"string\":\n return sanitizeHtml(something, sanitizeOptions);\n break;\n case \"undefined\":\n case \"symbol\":\n case \"function\":\n default:\n return undefined;\n }\n}", "title": "" }, { "docid": "6bb692a1ed7baf7b924b49817993c151", "score": "0.58559716", "text": "function sanitize(text) {\n return DOMPurify.sanitize(text, { FORBID_ATTR: [ 'onerror', 'onload' ], FORBID_TAGS: [ 'script', 'iframe' ] });\n}", "title": "" }, { "docid": "598f5af8ebc7a4b71da75c1d5b858323", "score": "0.5818336", "text": "function _sanitize (raw, clean, req, validator) {\n validator = validator || allValidValidator;\n\n // error & warning messages\n var messages = { errors: [], warnings: [] };\n\n // it's not a required parameter, so if it's not provided just move on\n if (!raw.hasOwnProperty('categories')) {\n return messages;\n }\n\n // if categories string has been set\n // map input categories to valid format\n clean.categories = raw.categories.split(',')\n .map(cat => {\n return cat.toLowerCase().trim(); // lowercase inputs\n })\n .filter(cat => {\n if (_.isString(cat) && !_.isEmpty(cat) && validator.isValidCategory(cat)) {\n return true;\n }\n return false;\n });\n\n if( !clean.categories.length ){\n // display a warning that the input was empty\n messages.warnings.push(WARNINGS.empty);\n }\n\n return messages;\n}", "title": "" }, { "docid": "b284ba74f359e4bf5b907a7899e5c89a", "score": "0.58125603", "text": "function sanitize_input(str) {\n\treturn str.toString().replace(/[^\\-a-zA-Z0-9]/gi,'')\t\n}", "title": "" }, { "docid": "d08c5b33d16c302a61dfb637cfc88177", "score": "0.5807083", "text": "function sanitizeString(unsafeWord){\n\tvar safeWord = '\\\"'+ unsafeWord + '\\\"';\n\treturn safeWord;\n}", "title": "" }, { "docid": "8508b1efd32ff2a155fc90828739816d", "score": "0.5768603", "text": "function validator(req, res, next) {\n req.sanitize = function(obj, prop, op) {\n if (req.body[obj][prop]) {\n req.body[obj][prop] = sanitizer(req.body[obj][prop])[op]().trim();\n }\n };\n next();\n}", "title": "" }, { "docid": "cdf6fee1e8b328c85a57cb54c263d850", "score": "0.5753378", "text": "function sanitize( raw, clean ){\n\n // error & warning messages\n var messages = { errors: [], warnings: [] };\n\n // invalid input 'text'\n if( !check.nonEmptyString( raw.text ) ){\n messages.errors.push('invalid param \\'text\\': text length, must be >0');\n }\n\n // valid input 'text'\n else {\n // valid text\n clean.text = normalize(raw.text);\n\n // remove anything that may have been parsed before\n var fromLibpostal = clean.parsed_text;\n delete clean.parsed_text;\n\n // parse text with query parser\n var parsed_text = parse(clean.text);\n\n // use the libpostal parsed address components if available\n if(check.assigned(fromLibpostal)) {\n parsed_text = parsed_text || {};\n assignValidLibpostalParsing(parsed_text, fromLibpostal, clean.text);\n }\n\n if (check.assigned(parsed_text) && Object.keys(parsed_text).length > 0) {\n clean.parsed_text = parsed_text;\n }\n }\n\n return messages;\n}", "title": "" }, { "docid": "908800b2fb74b2a712ee934b625bfce2", "score": "0.57348686", "text": "sanitise(node,text,pack){let rep=node.unescape;if(rep){let idx=0;rep=`\\\\${rep}`;while((idx=text.indexOf(rep,idx))!==-1){text=text.substr(0,idx)+text.substr(idx+1);idx++;}}text=escapeSlashes(text);return pack?cleanSpaces(text):escapeReturn(text);}", "title": "" }, { "docid": "2db8676f4aaa00607945c8da085bf910", "score": "0.57155496", "text": "* _checkResParamsQuotes() {\n }", "title": "" }, { "docid": "bf0cf70821c2f500bb3f62876ae992a1", "score": "0.56059545", "text": "function sanitizeFilter(str) {\n return str.replace(rscripts, \"\").replace(ropen, function (a, b) {\n var match = a.toLowerCase().match(/<(\\w+)\\s/);\n if (match) {\n //处理a标签的href属性,img标签的src属性,form标签的action属性\n var reg = rsanitize[match[1]];\n if (reg) {\n a = a.replace(reg, function (s, name, value) {\n var quote = value.charAt(0);\n return name + \"=\" + quote + \"javascript:void(0)\" + quote; // jshint ignore:line\n });\n }\n }\n return a.replace(ron, \" \").replace(/\\s+/g, \" \"); //移除onXXX事件\n });\n }", "title": "" }, { "docid": "7270edbc6b4f1ce8f7b150250c31d4c4", "score": "0.5591367", "text": "function sanitize(text)\n{\n if (debug) console.log(`sanitize(text) where text.length = ${text.length} bytes`); // DEBUG\n const chunkSize = 131072; // process text in 128 kB chunks\n if (text.length > chunkSize)\n return sanitize(text.slice(0, chunkSize)).concat(sanitize(text.slice(chunkSize)));\n return text\n .replace(/(?!\\n)\\r(?!\\n)/g, '\\n').replace(/\\r/g, '') // convert all line endings to '\\n'\n .replace(/[^\\S\\n]+/g, ' ') // convert all whitespace to ' '\n .replace(/[^ -~\\n]+/g, '') // remove non-printable characters\n .toLowerCase();\n}", "title": "" }, { "docid": "7c2286ee685fe22917f4b077252aab68", "score": "0.55847836", "text": "sanitize(input, isCourseCode) {\n let expressionAllowSpaces = new RegExp('^[a-zA-Z0-9 _]{0,15}$');\n let expressionNoSpaces = new RegExp('^[a-zA-Z0-9]{0,15}$');\n let newExpression = new RegExp(\"[<\\\"\\/>%\\$&#@\\[\\\\\\^\\$\\.\\|\\?\\*\\+\\(\\)\\{\\}]\");\n if (!isCourseCode) {\n if (newExpression.test(input)) {\n return false;\n }\n else {\n return true;\n }\n }\n else {\n if (expressionNoSpaces.test(input)) {\n return true;\n }\n else {\n return false;\n }\n }\n }", "title": "" }, { "docid": "e8147d5f0abe7d7e8c4c1051cdc4d35e", "score": "0.55639935", "text": "function sanitize(txt){\n\tif(!txt || typeof(txt) !== 'string')\n\t\ttxt = '';\n\n\ttxt = txt.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;');\n\n\tif(txt.length > 32)\n\t\ttxt = txt.slice(32);\n\n\treturn txt;\n}", "title": "" }, { "docid": "a55c85d7c15544dd04e2d4a4274927ca", "score": "0.5518044", "text": "function sanitize(s, noContext, notredirect) { \r\n\t\r\n for (var j = 0; j < bad.length; j++) { \r\n if(noContext && modifiers[j].indexOf(\"c\") != -1 || notredirect && modifiers[j].indexOf(\"r\") !=-1 ) { \r\n continue;\r\n } \r\n\r\n////////////////////////////////////////////////////////////////\r\n//CHOOSE ONLY ONE OPTION, AND PUT '//' IN FRONT OF THE OTHER 2//\r\n////////////////////////////////////////////////////////////////\r\n\r\n//Show what is being replaced and what its replaced with\r\n// s = s.replace(bad[j], '[[\\'' + bad[j] + '\\' , \\'' + good[j] + '\\']]');\r\n\r\n//Show the replacement with asterisks to show the word has been edited\r\n s = s.replace(bad[j], '**' + good[j] + '**');\r\n\r\n//Show the replacement with no asterisks\r\n// s = s.replace(bad[j], good[j]);\r\n\r\n////////////////////////////////////////////////////////////////\r\n\r\n } \r\n return s; \r\n}", "title": "" }, { "docid": "188aaa95ca247c181e53326a61d19700", "score": "0.55011505", "text": "function sanitizeString(text) {\n if(text == null || text == 'undefined') return text;\n return text.toString().replace(/(?:\\u2019|\\u275C)/ig,\"'\");\n }", "title": "" }, { "docid": "2db2363676d8fcc5262f11f6c6fc9d3d", "score": "0.5495158", "text": "function validateExec(es, f, __trace) {\n return as => validateExec_(as, es, f, __trace);\n}", "title": "" }, { "docid": "449d44aa0c2db9dd0c1e3c703947e41d", "score": "0.54912394", "text": "function sanitize(string) {\n return $.trim(string).replace(/\\s+/g, ' ').toLowerCase();\n}", "title": "" }, { "docid": "584be2b238c1c7e04682c8b629890f39", "score": "0.5462432", "text": "function sanitize(str) {\n if (!str)\n return '';\n return str.normalize('NFD').replace(/[\\u0300-\\u036f]/g, \"\").toLowerCase();\n}", "title": "" }, { "docid": "92b2106a6f35d939ba306825c23e854d", "score": "0.5453857", "text": "function StyleSanitizeFn() { }", "title": "" }, { "docid": "92b2106a6f35d939ba306825c23e854d", "score": "0.5453857", "text": "function StyleSanitizeFn() { }", "title": "" }, { "docid": "bb561d4b9edb38f2f57c2135a0bc897e", "score": "0.5442012", "text": "function sanitize(target){\n target.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/\"/g, '&quot;').replace(/'/g, '&#39;');\n return target;\n }", "title": "" }, { "docid": "c2be04e62dd6de10243bffbb71e9949d", "score": "0.54216105", "text": "static sanitize(mgrsString){\n mgrsString.toUpperCase();\n return mgrsString.replace(/\\s+/g, '');\n }", "title": "" }, { "docid": "4c8142265d3592567f25b7dcf65779bf", "score": "0.5396078", "text": "function SafeScript() { }", "title": "" }, { "docid": "4c8142265d3592567f25b7dcf65779bf", "score": "0.5396078", "text": "function SafeScript() { }", "title": "" }, { "docid": "4c8142265d3592567f25b7dcf65779bf", "score": "0.5396078", "text": "function SafeScript() { }", "title": "" }, { "docid": "f3fb2d22d6636213ea1830da8975b336", "score": "0.53907645", "text": "function sanitize(aStr) {\n let unprintableRE = new RegExp(\"[\\\\x00-\\\\x1F\\\\x7F]\" ,\"gi\");\n return aStr.replace(unprintableRE, \"\");\n}", "title": "" }, { "docid": "f9831a8cfc33aff434e074dabf5ddd20", "score": "0.5387578", "text": "function sanitizeWord( word ) {\n if(typeof word === 'undefined') {\n return '';\n }\n // - make lowercase\n let sanitizedWord = word.toLowerCase();\n // - remove all non-letters\n sanitizedWord = sanitizedWord.replace(/[^a-z]/g, '');\n return sanitizedWord\n}", "title": "" }, { "docid": "3f81f4d8cdddec178722885a30d44794", "score": "0.53476685", "text": "function sanitize( raw, clean ){\n\n // error & warning messages\n var messages = { errors: [], warnings: [] };\n\n // valid input 'lang'\n if(check.nonEmptyString( raw.lang )) {\n clean.lang = raw.lang;\n }\n\n return messages;\n}", "title": "" }, { "docid": "b45705e4d33a7ad793752b0ae004657e", "score": "0.5332292", "text": "function clean_uneval(val) {\n return uneval(val).replace(/\\s+/g, ' ');\n}", "title": "" }, { "docid": "b45705e4d33a7ad793752b0ae004657e", "score": "0.5332292", "text": "function clean_uneval(val) {\n return uneval(val).replace(/\\s+/g, ' ');\n}", "title": "" }, { "docid": "326993e1a3111c0ec41723985cf2da92", "score": "0.53290933", "text": "function sanitize ( str ) {\n\tif ( !str ) {\n\t\treturn str;\n\t}\n\treturn str.replace( '&', '&amp;' ).replace( '<', '&lt;').replace( '>', '&gt;');\n}", "title": "" }, { "docid": "950e109fe56746d3245858769571d109", "score": "0.53223854", "text": "function validateCommand(rawCommand) {\n var v = '', c = '', parts, sharpCommand = ['about', 'help', 'author'];\n if (rawCommand.indexOf(':') > 0) {\n parts = rawCommand.split(':');\n c = parts[0];\n v = parts[1];\n } else if (rawCommand.indexOf('#') === 0) {\n parts = rawCommand.split('#');\n c = '#';\n v = parts[1];\n }\n console.log('console-console:validateCommand', rawCommand, c, v);\n switch (c) {\n case '#':\n if (sharpCommand.indexOf(v) === -1) {\n console.log('console-console:validateCommand [' + v + '] command does not exists in: ', sharpCommand);\n $scope.validateCommand = 'This command does not exist';\n }\n break;\n default:\n if (['level'].indexOf(c) > -1) {\n c = 'callback';\n }\n if ($scope.source.array.indexOf(c) === -1) {\n console.log('console-console:validateCommand [' + c + ':' + v + '] command does not exists in: ', $scope.source.array);\n $scope.validateCommand = 'Please put another command';\n }\n }\n return {command: c, value: v};\n }", "title": "" }, { "docid": "7d2960195b09c2305a5dd396ac983480", "score": "0.5310821", "text": "sanitise(node, text, pack) {\n let rep = node.unescape;\n if (rep) {\n let idx = 0;\n rep = `\\\\${rep}`;\n while ((idx = text.indexOf(rep, idx)) !== -1) {\n text = text.substr(0, idx) + text.substr(idx + 1);\n idx++;\n }\n }\n\n text = escapeSlashes(text);\n\n return pack ? cleanSpaces(text) : escapeReturn(text)\n }", "title": "" }, { "docid": "add3d85635343ccab58549d7a1c1a67d", "score": "0.52976245", "text": "function sanitize(key) {\n // Allow lowercase alphanumerics, dashes, underscores, and periods:\n return typeof key == 'string' ? key.toLowerCase().replace(regexFunkyPunc, '') : '';\n }", "title": "" }, { "docid": "a1c0dd8a6042856a450cfd164f2ffa33", "score": "0.5293098", "text": "function sanitiseSearch(inTxt)\n{\n var outTxt, maxLen;\n maxLen = 15; //This is based on the longest (CURRENTLY) available search tag + 3 for different word choice\n\n //regex to remove all non alphanumeric or whitespace characters\n outTxt = inTxt.replace(/[^0-9a-zA-Z ]/g, \"\");\n\n //only accept strings less than maxLen characters\n if (outTxt.length > maxLen)\n {\n outTxt = outTxt.slice(0, maxLen);\n }\n\n //Add new sanitise rules here if necessary in future\n\n //CONSIDER\n //This function can also do the searching of the document if thought more secure to not have the sanitised input move around before use\n\n return outTxt;\n}", "title": "" }, { "docid": "00c492f34f8b013f88770c3116bc4520", "score": "0.525922", "text": "function cleanScheduleName(res, dirtyInput){\n if(dirtyInput.length > 50 || dirtyInput.length < 1){ //less than or equal to 25 characters.\n return res.status('400').send('Schedule Name should be >0 and <=50 characters.');\n }\n\n //Input filtering for potential malicious injection attacks\n const cleanInput = dirtyInput.replace(/[`#$%^&*()_+\\-=\\[\\]{};':\"\\\\|,.<>\\/?~]/g, \"\"); //remove special characters from input\n return cleanInput;\n}", "title": "" }, { "docid": "21309e96361e88ba684b4a42f62dc7f9", "score": "0.5254855", "text": "function clean(code) {\n //code : the string of js code we need to clean up and ensure is not malicious\n var regex = /(XMLHttpRequest)|(xhr\\.\\w*)|(\\$\\.\\w*)|(document\\.getElementBy\\w*\\(\\w*\\))|(document\\.getElementsBy\\w*\\(\\w*\\))/g;\n //replace the offending functions and return the sanitized code\n return code.replace(regex, \" \");\n\n}", "title": "" }, { "docid": "8423764c73860056b9645518c3481f73", "score": "0.52452534", "text": "validatesExecution(val){\r\n if(typeof(val)===\"string\" && this.INPUT_RESULT.value.length>0) {\r\n if(this.exec && this.previusCharCount==0 ){\r\n this.calculate();\r\n this.exec=false;\r\n }\r\n this.exec=true;\r\n this.operationType=val;\r\n }\r\n }", "title": "" }, { "docid": "c18dddb24b49c1a34dba2ab550aacb80", "score": "0.5242326", "text": "function SanityChecker() {}", "title": "" }, { "docid": "c18dddb24b49c1a34dba2ab550aacb80", "score": "0.5242326", "text": "function SanityChecker() {}", "title": "" }, { "docid": "c18dddb24b49c1a34dba2ab550aacb80", "score": "0.5242326", "text": "function SanityChecker() {}", "title": "" }, { "docid": "6725dd97c9d116923d280d0fd3c32198", "score": "0.52311605", "text": "function filterXSS2(payload){\n payload = payload.replace(/'/gi, '');\n payload = payload.replace(/</gi, '');\n payload = payload.replace(/>/gi, '');\n payload = payload.replace(/\\(/gi, '');\n payload = payload.replace(/\\)/gi, '');\n payload = payload.replace(/alert/gi, '$');\n payload = payload.replace(/prompt/gi, '$');\n payload = payload.replace(/eval/gi, '$');\n payload = payload.replace(/window/gi, '$');\n payload = payload.replace(/document/gi, '$');\n payload = payload.replace(/location/gi, '$');\n payload = payload.replace(/throw/gi, '$');\n\nreturn payload;\n}", "title": "" }, { "docid": "bc0cbdd6e630fb218ad7e84b84f9c7c6", "score": "0.52203697", "text": "function Sanitize(){\n var i, e, options;\n options = arguments[0] || {};\n this.config = {};\n this.config.elements = options.elements ? options.elements : [];\n this.config.attributes = options.attributes ? options.attributes : {};\n this.config.attributes[Sanitize.ALL] = this.config.attributes[Sanitize.ALL] ? this.config.attributes[Sanitize.ALL] : [];\n this.config.allow_comments = options.allow_comments ? options.allow_comments : false;\n this.allowed_elements = {};\n this.config.protocols = options.protocols ? options.protocols : {};\n this.config.add_attributes = options.add_attributes ? options.add_attributes : {};\n this.dom = options.dom ? options.dom : document;\n for(i=0;i<this.config.elements.length;i++) {\n this.allowed_elements[this.config.elements[i]] = true;\n }\n this.config.remove_element_contents = {};\n this.config.remove_all_contents = false;\n if(options.remove_contents) {\n\n if(options.remove_contents instanceof Array) {\n for(i=0;i<options.remove_contents.length;i++) {\n this.config.remove_element_contents[options.remove_contents[i]] = true;\n }\n }\n else {\n this.config.remove_all_contents = true;\n }\n }\n this.transformers = options.transformers ? options.transformers : [];\n}", "title": "" }, { "docid": "26e4f13e21212124e1c24be7342769a0", "score": "0.5212869", "text": "function Sanitize(){\n var i, e, options;\n options = arguments[0] || {};\n this.config = {};\n this.config.elements = options.elements ? options.elements : [];\n this.config.attributes = options.attributes ? options.attributes : {};\n this.config.attributes[Sanitize.ALL] = this.config.attributes[Sanitize.ALL] ? this.config.attributes[Sanitize.ALL] : [];\n this.config.allow_comments = options.allow_comments ? options.allow_comments : false;\n this.allowed_elements = {};\n this.config.protocols = options.protocols ? options.protocols : {};\n this.config.add_attributes = options.add_attributes ? options.add_attributes : {};\n this.dom = options.dom ? options.dom : document;\n for(i=0;i<this.config.elements.length;i++) {\n this.allowed_elements[this.config.elements[i]] = true;\n }\n this.config.remove_element_contents = {};\n this.config.remove_all_contents = false;\n if(options.remove_contents) {\n \n if(options.remove_contents instanceof Array) {\n for(i=0;i<options.remove_contents.length;i++) {\n this.config.remove_element_contents[options.remove_contents[i]] = true;\n }\n }\n else {\n this.config.remove_all_contents = true;\n }\n }\n this.transformers = options.transformers ? options.transformers : [];\n}", "title": "" }, { "docid": "63d1ff09fb45548e127a6eb4c9e1be2f", "score": "0.51904166", "text": "function SanityChecker() {}", "title": "" }, { "docid": "5504c5c326fddd19d38209a9c5f9e1ad", "score": "0.5188989", "text": "sanitize(input) {\n if (needsToWarn) {\n needsToWarn = false;\n\n getLogger('html-sanitizer')\n .warn(`CAUTION: The default HTMLSanitizer does NOT provide security against a wide variety of sophisticated XSS attacks,\n and should not be relied on for sanitizing input from unknown sources.\n Please see https://aurelia.io/docs/binding/basics#element-content for instructions on how to use a secure solution like DOMPurify or sanitize-html.`);\n }\n\n return input.replace(SCRIPT_REGEX, '');\n }", "title": "" }, { "docid": "4bb604a3d6212c8943fd959471a1b860", "score": "0.5163551", "text": "function invalidFilter(x) {\n for (var i = 0; i < invalid.length; i++) {\n if (x === invalid[i]) {\n eval = false;\n break;\n } else {\n eval = true;\n }\n }\n if (eval === true) {\n cleanString += x;\n }\n}", "title": "" }, { "docid": "49d795bb38073007c89a30eaf5efa3ec", "score": "0.5163499", "text": "function sanitize(s) {\n return s.replace(/[&<>'\"_]/g, '-'); // used on all output token CSS classes\n}", "title": "" }, { "docid": "fe72e77aca43c647a9f0b065245b9266", "score": "0.5152439", "text": "function sanitizeInputString(s, options={}) {\n\n if (!s) {\n return s;\n }\n\n // Remove ASCII control characters\n s = s.replace(/[\\x01-\\x1F]+/g, '');\n\n // Remove Unicode control characters\n s = s.replace(/[\\p{C}]+/gu, '');\n\n s = s.trim();\n\n return s;\n}", "title": "" }, { "docid": "8c31beec123ce48630ace8a7050c1290", "score": "0.51428497", "text": "function cleanEnteredSearchText(str) {\n\t la(check.string(str), 'expected string to clean', str);\n\t str = str.toLowerCase();\n\t str = str.replace('&nbsp;', ' ');\n\t str = str.trim();\n\t str = _.unescape(str);\n\t return str;\n\t}", "title": "" }, { "docid": "9c633b43ca21c9b3de2274d5df56c68c", "score": "0.51387507", "text": "function validate(value) {\n value = value.replace( /-/g , '__').replace( /\\?/g , '-qmark').replace( / /g , '--').replace( /\\n/g , '-n').replace( /</g , '-lt').replace( />/g , '-gt').replace( /&/g , '-amp').replace( /#/g , '-nsign').replace( /__t-n/g , '__t').replace( /\\+/g , '_plus_').replace( /=/g , '-equal');\n return value;\n}", "title": "" }, { "docid": "b69c2eb8069d981ca3640d3d29811a8c", "score": "0.5136458", "text": "function _sanitize(raw, clean) {\n // error & warning messages\n // this function doesn't add any error or warning messages\n const messages = { errors: [], warnings: [] };\n\n // only try to transliterate if there is a city in parsed_text\n if (!_.isEmpty(_.get(clean, 'parsed_text.city'))) {\n // eg input: Ft. st Louis\n // after 1. ft st louis\n // after 2. fort st louis\n // after 3. fort st louis\n\n // 1. remove '.' that could abbreviate ft and mt (makes transliteration regex easier)\n const periods_removed = _.toLower(clean.parsed_text.city).replace(/\\b(mt|ft)\\./g, '$1 ');\n\n // 2. transliterate 'ft'->'fort', etc\n const transliterated = periods_removed.replace(mountFort, transliterate);\n\n // 3. reduce whitespace sequences that can occur when removing periods down to a single space\n const whitespace_normalized = _.trimEnd(transliterated.replace(/\\s+/, ' '));\n\n clean.parsed_text.city = whitespace_normalized;\n\n }\n\n return messages;\n\n}", "title": "" }, { "docid": "dce32fb8577e8b6c9c2d943f4b625162", "score": "0.51358986", "text": "function clean() {\r\n\t\t// Get all text inside the input textbox\r\n\t\tvar sourceCode = document.getElementById(\"bigString\").value;\r\n\t\tvar newCode = sourceCode;\r\n\t\t\r\n\t\t// Get a list of element names and whether they should be removed\r\n\t\tvar elementNames = getCollection('form', true);\r\n\t\tvar elementsChecked = getCollection('form', false);\r\n\r\n\t\tnewCode = attriClean(newCode, elementNames, elementsChecked);\r\n\t\tnewCode = executeCleanTags(newCode, elementNames, elementsChecked);\r\n\t\tnewCode = cleanScript(newCode, elementsChecked);\r\n\t\tnewCode = cleanComments(newCode);\r\n\t\t\r\n\t\t// Return cleaned code\r\n\t\tdocument.getElementById(\"demo\").innerHTML = newCode;\r\n\t}", "title": "" }, { "docid": "b303050b36d49b61c44e16efe72dfd2c", "score": "0.51062113", "text": "function cleanInputString(str) {\n\tstr = str.trim();\n\tstr = str.replace(/\\t/g, ' '); // all tabs become space\n\tstr = str.replace(/\\s\\s+/g, ' '); // all whitespace becomes one space\n\treturn str;\n}", "title": "" }, { "docid": "20234c17125f59b5ac9bc99ab5c9cc59", "score": "0.5104253", "text": "function sanitizeExpression(expression) {\n return expression.trim().replace(/;+$/, \"\");\n}", "title": "" }, { "docid": "67eef8af95dd5b5d606efb9944ee861c", "score": "0.5103149", "text": "function sanitize(str) {\n str = String(str);\n const map = {\n '&': '&amp;',\n '<': '&lt;',\n '>': '&gt;',\n '\"': '&quot;',\n \"'\": '&#x27;',\n \"/\": '&#x2F;',\n \"?\": '&#63;'\n };\n const reg = /[&<>\"'?/]/ig;\n var output = str.replace(reg, (match)=>(map[match]));\n return(output);\n}", "title": "" }, { "docid": "6c9b06d5df143654dd8291a36b785217", "score": "0.509755", "text": "cleanString (string,illegalChars){\n let baseIllegalChars = '<>()+';\n let regex = null;\n let cleanedString = '';\n if(typeof illegalChars === 'string'){\n\n }\n else if(Array.isArray(illegalChars)){\n\n }\n\n regex = new RegExp(`[${baseIllegalChars}]`);\n return cleanedString.replace(regex,'');\n }", "title": "" }, { "docid": "41a7859c5153e03531154c42a1a0df0c", "score": "0.5082873", "text": "function sanitizeHtml()\n {\n $.perc_utils.handleLinks(iframe);\n $.perc_utils.handleObjects(iframe);\n }", "title": "" }, { "docid": "e60c631210977386fe9ccb60c0f852f8", "score": "0.50798106", "text": "function sanitizeXml(){\r\n\txmlInput = xmlInput.replace(/(\\r\\n|\\n|\\r|\\t)/gm,\"\");\r\n\txmlInput = xmlInput.replace(/<!--.[^(><.)]*-->/g, '');\r\n}", "title": "" }, { "docid": "8f5e28dbae2a78a3c6c4f5c84d6afcc4", "score": "0.5077392", "text": "function sanitize(markup) {\n return `${markup}`\n .trim()\n .replace(/[\\r|\\n]/g, ' ')\n .replace(/>\\s+</g, '><');\n }", "title": "" }, { "docid": "406fc8216e7e34fdae9c59be9a0e36b2", "score": "0.50666547", "text": "function validateExec_(as, es, f, __trace) {\n return (0, _absolve.absolve)((0, _map.map_)((0, _exclForEach.forEachExec_)(as, es, a => (0, _either.either)(f(a))), mergeExits()), __trace);\n}", "title": "" }, { "docid": "c90890f360a4d2d817f89b71b60dda7b", "score": "0.5066421", "text": "function sanitizeHtml()\n {\n $.perc_utils.handleLinks(iframe);\n $.perc_utils.handleObjects(iframe);\n }", "title": "" }, { "docid": "69d551ae4f362344752c8244f3d249dc", "score": "0.50630444", "text": "sanitizeString(string) {\n return string.normalize(\"NFD\").replace(/[\\u0300-\\u036f]/g, \"\").toLowerCase();\n }", "title": "" }, { "docid": "9c195fa68d06ca730beddb352bff7c9a", "score": "0.5052437", "text": "_cleanHTML(html) {\n\n\t\tlet sanitized = html;\n\n\t\tsanitized = sanitized.replace(/-\\\\n/g, ' ');\n\t\tsanitized = sanitized.replace(/\\\\n|\\\\r\\\\n|\\\\r/g, '');\n\t\tsanitized = _s.clean(sanitized);\n\n\n\t\treturn sanitized;\n\t}", "title": "" }, { "docid": "09ed1d7d28de121019a6a027466665a7", "score": "0.5048319", "text": "cleanQuery(){\n // first part is either bookmark shortcut or search term\n this.query[0] = this.query[0].trim();\n\n // second part needs leading whitespace trimming\n // last part needs trailing whitespace trimming\n if(this.query.length > 1){\n this.query[1] = this.query[1].replace(/^\\s+/g, \"\");\n this.query[this.query.length -1] = this.query[this.query.length -1].replace(/\\s+$/, \"\");\n }\n }", "title": "" }, { "docid": "25c400f36ab637a8e67766439c9e84e2", "score": "0.5040176", "text": "function cleanSql(sql) {\n sql = sql.trim();\n sql = sql.replace(/\\--.*(\\n|$)/g, \"\"); // eslint-disable-line\n sql = sql.replace(/\\/\\\\*[\\S\\n ]+\\\\*\\//g, \"\");\n sql = sql.replace(/\\s+/g, \" \");\n return sql;\n}", "title": "" }, { "docid": "5e831c2ff6f5e1a76b98e8f1f9a8928a", "score": "0.5022554", "text": "function sanitize (v) {\n v.name = sanitizer.sanitize(v.name)\n v.description = sanitizer.sanitize(v.description)\n if (v.edges) {\n v.edges = v.edges.map(e => {\n e.command = sanitizer.sanitize(e.command)\n e.goesTo = sanitizer.sanitize(e.goesTo)\n return e\n })\n }\n return v\n}", "title": "" }, { "docid": "a470346ed68826d06049469f181439a5", "score": "0.5019125", "text": "function FilterProcess(AStrInputString,AStrAllowedSpecialCharacters){\n\tvar LStrInvalidString\n\tvar LStrFilteredInvalidString\n\tvar LChrInputString\n\tvar LStrOutputFilteredString\n\tvar LIntCtr\n\tAStrInputString = LTrim(RTrim(AStrInputString))\n\n\tif(AStrAllowedSpecialCharacters.length > 0){\n\t\tLStrInvalidString = \"`~!@#$%^&*?|'\"\n\t\tLStrFilteredInvalidString = \"\"\n\t\tfor(LIntCtr = 0; LIntCtr < LStrInvalidString.length; LIntCtr++){\n\t\t\tLChrInputString = LStrInvalidString.charAt(LIntCtr)\n\t\t\tif(AStrAllowedSpecialCharacters.indexOf(LChrInputString) == -1) LStrFilteredInvalidString = LStrFilteredInvalidString + LChrInputString\n\t\t}\n\t\t\n\t\tLStrOutputFilteredString = \"\"\n\t\tfor(LIntCtr = 0; LIntCtr < AStrInputString.length; LIntCtr++){\n\t\t\tLChrInputString = AStrInputString.charAt(LIntCtr)\n\t\t\tif(LStrFilteredInvalidString.indexOf(LChrInputString) == -1) LStrOutputFilteredString = LStrOutputFilteredString + LChrInputString\n\t\t}\t\n\t}\n\telse{\n\t\tLStrInvalidString = \"`~!@#$%^&*?|'\"\n\t\tLStrOutputFilteredString = \"\"\n\t\tfor(LIntCtr = 0; LIntCtr < AStrInputString.length; LIntCtr++){\n\t\t\tLChrInputString = AStrInputString.charAt(LIntCtr)\n\t\t\tif(LStrInvalidString.indexOf(LChrInputString) == -1) LStrOutputFilteredString = LStrOutputFilteredString + LChrInputString\n\t\t}\n\t}\n\treturn LStrOutputFilteredString;\n}", "title": "" }, { "docid": "f6ce1fa0df0d29004c28cba6e3bb8fd9", "score": "0.5019016", "text": "function sanitizeString(string) {\n string = string\n .toString()\n .trim()\n .toLowerCase();\n\n return string;\n}", "title": "" }, { "docid": "290f3500a5fda5e05bc5f9248c4bb1fe", "score": "0.5018312", "text": "function _sqliClean(text) { return text.replace(/[<>\"=;/\\(\\)\\[\\]\\{\\}]/g, \"\"); }", "title": "" }, { "docid": "c226043fd234c87e9c30fedafc6fda60", "score": "0.50177515", "text": "function assertValidExecutionArguments(schema, document, rawVariableValues) {\n document || devAssert(0, 'Must provide document.'); // If the schema used for execution is invalid, throw an error.\n\n assertValidSchema(schema); // Variables, if provided, must be an object.\n\n rawVariableValues == null || isObjectLike(rawVariableValues) || devAssert(0, 'Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.');\n}", "title": "" }, { "docid": "87627cc027484ae3e3f77c6b8fb5020e", "score": "0.5013625", "text": "function sanitize(key)\n{\n\treturn key ? (key + '').replace(/[^a-z0-9_-]+/gi, '') : '';\n}", "title": "" }, { "docid": "fd83621b2500463067eda9c23252cd4f", "score": "0.5013462", "text": "function sanitiseDescription(description) {\n // https://www.npmjs.com/package/xss\n // https://jsxss.com/en/options.\n let options = {\n whiteList: {\n a: ['href'], // title\n // p: [],\n // strong: []\n },\n stripIgnoreTag: true,\n onTag: onTag,\n onIgnoreTagAttr: onIgnoreTagAttr\n };\n description = window.filterXSS(description, options);\n return description;\n}", "title": "" }, { "docid": "778d20afdb3b084197f1821bef4d11ad", "score": "0.5011289", "text": "function isSanitized(inputString) {\n\tif(!inputString || typeof inputString !== 'string' || inputString.length === 0 || !/^[a-z0-9]+$/i.test(inputString))\n\t\treturn false;\n\treturn true;\n}", "title": "" }, { "docid": "0074a735ba0f0742b7a00f878870581b", "score": "0.5010093", "text": "function verify (v, cb) {\n if (validate(v))\n return sanitize(v)\n return\n}", "title": "" }, { "docid": "6f87fd2a65cd537eee8686739ff9e3b2", "score": "0.500876", "text": "function assertValidExecutionArguments(schema, document, rawVariableValues) {\n document || Object(devAssert[\"a\" /* default */])(0, 'Must provide document'); // If the schema used for execution is invalid, throw an error.\n\n Object(validate[\"a\" /* assertValidSchema */])(schema); // Variables, if provided, must be an object.\n\n rawVariableValues == null || Object(isObjectLike[\"a\" /* default */])(rawVariableValues) || Object(devAssert[\"a\" /* default */])(0, 'Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.');\n}", "title": "" }, { "docid": "34a8fafd65a42c2ae9ad03989bd11655", "score": "0.500705", "text": "sanitize(dirty, options) {\n return sanitize_html_1.default(dirty, Object.assign({}, this._options, (options || {})));\n }", "title": "" }, { "docid": "a903767cba5b490a0eaecc9a2c73637d", "score": "0.50027853", "text": "sanitizeForm() {\n for (var ix = 0; ix < this.inputs.length; ix++) {\n if (this.hasError == true) { break };\n var input = this.inputs[ix];\n var name = input.name;\n var value = input.value;\n var strict = input.strict || false;\n // console.log\n\n var meth = input.meth || 'string';\n if (meth == 'string') {\n if (strict == true) {\n this.inputs[ix].value = this.getString(value);\n } else {\n this.inputs[ix].value = value;\n }\n } else if (meth == 'email') {\n if (strict == true) {\n this.inputs[ix].value = this.getEmail(value);\n } else {\n this.inputs[ix].value = value;\n }\n } else if (meth == 'int') {\n if (strict == true) {\n this.inputs[ix].value = this.getInt(value);\n } else {\n this.inputs[ix].value = value;\n }\n } else if (meth == 'object') {\n this.inputs[ix].value = value;\n }\n\n var checked = this.checkCondition(this.inputs[ix].value, input);\n if (checked == false) {\n this.hasError = true;\n break;\n }\n }\n\n if (this.hasError == false) {\n return this.assembleInput();\n } else {\n return false;\n }\n\n }", "title": "" }, { "docid": "7d42480800e3c679c3ab197de936c598", "score": "0.49879116", "text": "function sanitize_tag (tag) {\n\t\t\t\t\t\treturn tag.replace(/ /g, '\\\\ ').replace(/,/g, '\\\\,').replace(/=/g, '\\\\=');\n\t\t\t\t\t}", "title": "" }, { "docid": "0bca764d8f96ecfd19e59dd1b3b500af", "score": "0.49851614", "text": "function cleanText(dirtyText) {\r\n\t\t\tvar cleanText = dirtyText;\r\n\t\t\tcleanText = he.decode(dirtyText);\r\n\t\t\treturn cleanText;\r\n\t\t}", "title": "" }, { "docid": "183a55a48bd16b3c1869684b4bd8e40f", "score": "0.49731323", "text": "function sanitise(arr) {\n\n let equation = [...arr]\n\n let regex = /[\\d\\(|\\d√]/\n\n //Replace multiplication and division signs\n equation = equation.join('')\n .replace(\"x\", \"*\")\n .replace(\"√\", \"Math.sqrt\")\n\n //Make sure equation doesn't end with an operator\n regex = /[+\\-*\\/(√]$/\n if (!regex.test(equation)) {\n solve(equation)\n }\n}", "title": "" }, { "docid": "2b419f7ed6a687f2ebe4f19e8ab9d337", "score": "0.49727547", "text": "function checkEscape(v) {return v !== 'dook';}", "title": "" }, { "docid": "329c6476de0073ebe7e7e8c68a6a2b06", "score": "0.49618748", "text": "function assertValidExecutionArguments(schema, document, rawVariableValues) {\n document || (0, _devAssert.devAssert)(false, 'Must provide document.'); // If the schema used for execution is invalid, throw an error.\n\n (0, _validate.assertValidSchema)(schema); // Variables, if provided, must be an object.\n\n rawVariableValues == null || (0, _isObjectLike.isObjectLike)(rawVariableValues) || (0, _devAssert.devAssert)(false, 'Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.');\n}", "title": "" }, { "docid": "99887cfa05a00086b07d845eca9d2007", "score": "0.49592733", "text": "_validate() {}", "title": "" }, { "docid": "03efc32455c9710dcc7c8664b5103cc3", "score": "0.49517173", "text": "function cleanTweet(_rawTweet)\n{\n\tvar escape_chars = Array(\"\\\"\",\"/\", \"\\\\\", \"'\", \"#\", \"@\");\n\tvar safeTweet = _rawTweet;\n\t\n\t//Remove @user replys\n\tsafeTweet = safeTweet.replace(/@[^\\s]*/g, \"\");\n\t\n\t//Remove URLs\n\tsafeTweet = safeTweet.replace(/[-a-zA-Z0-9@:%_\\+.~#?&//=]{2,256}\\.[a-z]{2,4}\\b(\\/[-a-zA-Z0-9@:%_\\+.~#?&//=]*)?/g, \"\");\n\t\n\t//Remove unsafe characters not in the whitelist below\n\tsafeTweet = safeTweet.replace(/[^A-Za-z-_0-9!.?=,+ ]/g, \"\")\n\t\n\t//remove extra whitespace\n\tsafeTweet = safeTweet.replace(/\\s+/g, \" \");\n\t\n\t//remove RT\n\tsafeTweet = safeTweet.replace(/RT /g, \" \");\n\t\n\treturn safeTweet;\n}", "title": "" }, { "docid": "aa749dbcffa5a28c27b753feac372732", "score": "0.49514502", "text": "function sanitize(parameters)\n{\n let sanitized = {};\n for (let param in parameters)\n {\n if (param.indexOf(\"pass\") != -1 || param == \"confirm\")\n {\n sanitized[param] = \"********\";\n }\n else\n {\n sanitized[param] = parameters[param];\n }\n }\n\n return buildQuery(sanitized);\n}", "title": "" }, { "docid": "df7f168705cdc44170e39729689c5114", "score": "0.49444577", "text": "function clean(str) {\n return str;\n}", "title": "" }, { "docid": "be2e552efd7baeaf3761de1b08e3b37d", "score": "0.4942078", "text": "function sanitize(ast) {\n return (({\n 'JSXElement': sanitizeJsxElement\n })[ast.get('type')] || identity)(ast);\n}", "title": "" }, { "docid": "25390109a2d018a8e1a31e35168f9c8b", "score": "0.49387076", "text": "function cleanMeta(text, escape) {\n // replace with space the special chars\n var cleanText = (text ? text : \"\").replace(/[\"=<>\\{\\}\\[\\]\\\\\\/]/gi, ' ');\n // escape single quotes\n if (escape == true) {\n cleanText = cleanText.replace(/[']/g, '\\\\$&').replace(/\\u0000/g, '\\\\0');\n }\n return cleanText;\n }", "title": "" }, { "docid": "5d8ff11d302667cb20b63d5044ae3ba4", "score": "0.4937648", "text": "function sanitize(code) {\n // Remove block comments\n var blockStarts = [], toRemove = {}\n for (var i = 0; i < code.length; i++) {\n if (code.charAt(i) === COMPONENTS.COMMENT_LEFT) {\n blockStarts.push(i)\n } else if (code.charAt(i) === COMPONENTS.COMMENT_RIGHT) {\n var start = blockStarts.length > 0 ? blockStarts.pop() : 0\n for (var j = start; j <= i; j++) {\n toRemove[j] = true\n }\n }\n }\n for (var i = 0; i < blockStarts.length; i++) {\n for (var j = blockStarts[i]; j < code.length; j++) {\n toRemove[j] = true\n }\n }\n var tmpCode = []\n for (var i = 0; i < code.length; i++) {\n if (!toRemove.hasOwnProperty(i)) {\n tmpCode.push(code.charAt(i))\n }\n }\n code = tmpCode.join('')\n\n // Remove comments\n code = code.replace(new RegExp(regexEscape(COMPONENTS.COMMENT) + '.*$', 'gm'), '')\n // Remove trailing whitespace and empty lines\n code = code.replace(/\\s+$/gm,'').replace(/^\\r?\\n/, '')\n\n // Check for invalid characters\n for(var i = 0; i < code.length; i++) {\n if (CODE_ALPHABET.indexOf(code.charAt(i)) === -1)\n throw newErr('Code contains forbidden character \"' + code.charAt(i) + '\".')\n }\n return code\n}", "title": "" }, { "docid": "766879a423e1f2dd605fa6a7f2c805ea", "score": "0.49339685", "text": "function cleanInput(data) {\n \n\treturn data.toString().replace(/(\\r\\n|\\n|\\r)/gm,\"\");\n\t\n }", "title": "" }, { "docid": "e525dd0073a95b685646ad789fbe3618", "score": "0.4924673", "text": "executeIfValid() {\n // first validates the command list and executes the commands if they pass\n // otherwise triggers a halt execution action\n if (this.validateCommands()) {\n this.execute()\n } else {\n setTimeout(function() {\n // timeout to stop simaltanious dispatch errors\n rmActions.haltExecution()\n flashActions.flash('Hang on, some of the commands aren\\'t valid (they refer to non existant commands or buckets or something). Please fix.')\n }, 0)\n }\n }", "title": "" }, { "docid": "41fda0ed38ca7ddeed60f935ef810921", "score": "0.49236295", "text": "function test_REGEXP_TEST_EXEC_UNSAFE() {\n (/foo/).test('xfoox');\n var match = new RegExp('(.|\\r|\\n)*','').exec()[0];\n if (match === 'undefined') { return false; }\n if (match === 'xfoox') { return true; }\n return 'regExp.exec() does not match against \"undefined\".';\n }", "title": "" }, { "docid": "56e8f3b2c64701f48db45c28045ddbe4", "score": "0.4920629", "text": "function assertValidExecutionArguments(schema, document, rawVariableValues) {\n document || (0, _devAssert.default)(0, 'Must provide document.'); // If the schema used for execution is invalid, throw an error.\n\n (0, _validate.assertValidSchema)(schema); // Variables, if provided, must be an object.\n\n rawVariableValues == null || (0, _isObjectLike.default)(rawVariableValues) || (0, _devAssert.default)(0, 'Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.');\n}", "title": "" }, { "docid": "56e8f3b2c64701f48db45c28045ddbe4", "score": "0.4920629", "text": "function assertValidExecutionArguments(schema, document, rawVariableValues) {\n document || (0, _devAssert.default)(0, 'Must provide document.'); // If the schema used for execution is invalid, throw an error.\n\n (0, _validate.assertValidSchema)(schema); // Variables, if provided, must be an object.\n\n rawVariableValues == null || (0, _isObjectLike.default)(rawVariableValues) || (0, _devAssert.default)(0, 'Variables must be provided as an Object where each property is a variable value. Perhaps look to see if an unparsed JSON string was provided.');\n}", "title": "" }, { "docid": "36f3f2abfa558ffb2ca9716e4bc16c99", "score": "0.49192348", "text": "function ValidateCharAndSpace(textBoxObj)\n\t{\n\t\ttextBoxObj.value = filterNum(textBoxObj.value)\n\t\tfunction filterNum(str)\n\t\t{\n\t\t\tre = /\\~|\\`|[0-9]|\\@|-|_|\\$|\\!|\\#|%|\\^|\\&|\\*|\\(|\\)|\\+|\\=|\\{|\\}|\\[|\\]|\\'|\\\"|\\;|\\:|\\,|\\\\|\\||\\?|\\/|\\>|\\</g;\n\t\t\treturn str.replace(re, \"\");\n\t\t}\n\t}", "title": "" }, { "docid": "620ba3700b37f6e75f9db002d6945057", "score": "0.4905535", "text": "function assertValidExecutionArguments(schema, document, rawVariableValues) {\n !document ? Object(invariant[\"a\" /* default */])(0, 'Must provide document') : void 0; // If the schema used for execution is invalid, throw an error.\n\n assertValidSchema(schema); // Variables, if provided, must be an object.\n\n !(!rawVariableValues || execute_typeof(rawVariableValues) === 'object') ? Object(invariant[\"a\" /* default */])(0, 'Variables must be provided as an Object where each property is a ' + 'variable value. Perhaps look to see if an unparsed JSON string ' + 'was provided.') : void 0;\n}", "title": "" } ]
2dd1dd7ac84754aa315cecdc19854dac
seeds with the time if called with a parameter of 0; returns the seed regardless. All RNGs are seeded simultaneously and identically.
[ { "docid": "49779bb36bdcfc9f2b640bde8d6effa7", "score": "0.7265295", "text": "function seedRandomGenerator(seed) {\n\tif (!seed) {\n\t\tseed = Date.now() - 1352700000;\n\t}\n\tseed = seed % RAND_MAX_COMBO;\n\n\traninit(RNGState[RNG_SUBSTANTIVE], seed);\n\traninit(RNGState[RNG_COSMETIC], seed);\n\treturn seed;\n}", "title": "" } ]
[ { "docid": "c7d22365d5efd19e2c33ce5f4cabc617", "score": "0.8172034", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n}", "title": "" }, { "docid": "c7d22365d5efd19e2c33ce5f4cabc617", "score": "0.8172034", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n}", "title": "" }, { "docid": "c7d22365d5efd19e2c33ce5f4cabc617", "score": "0.8172034", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n}", "title": "" }, { "docid": "c7d22365d5efd19e2c33ce5f4cabc617", "score": "0.8172034", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n}", "title": "" }, { "docid": "223ba0d519d469bf53392a38ce85aa6e", "score": "0.8136611", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "223ba0d519d469bf53392a38ce85aa6e", "score": "0.8136611", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "223ba0d519d469bf53392a38ce85aa6e", "score": "0.8136611", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "223ba0d519d469bf53392a38ce85aa6e", "score": "0.8136611", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "223ba0d519d469bf53392a38ce85aa6e", "score": "0.8136611", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "223ba0d519d469bf53392a38ce85aa6e", "score": "0.8136611", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "39105fe3544befab35567e3e29ae76e4", "score": "0.81133264", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "3c4c13b3e5cd0f6ed170eefa79e41751", "score": "0.8099201", "text": "function rng_seed_time() {\n rng_seed_int(new Date().getTime());\n }", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "46f3e0d3dd833c93139d9bf471e8dec3", "score": "0.80883634", "text": "function rng_seed_time() {\n\t rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "b5188ed4b64e8cc48b2b331dda45f02f", "score": "0.8057226", "text": "function rng_seed_time() {\n\t\t rng_seed_int(new Date().getTime());\n\t\t}", "title": "" }, { "docid": "b5188ed4b64e8cc48b2b331dda45f02f", "score": "0.8057226", "text": "function rng_seed_time() {\n\t\t rng_seed_int(new Date().getTime());\n\t\t}", "title": "" }, { "docid": "b5188ed4b64e8cc48b2b331dda45f02f", "score": "0.8057226", "text": "function rng_seed_time() {\n\t\t rng_seed_int(new Date().getTime());\n\t\t}", "title": "" }, { "docid": "b5188ed4b64e8cc48b2b331dda45f02f", "score": "0.8057226", "text": "function rng_seed_time() {\n\t\t rng_seed_int(new Date().getTime());\n\t\t}", "title": "" }, { "docid": "b5188ed4b64e8cc48b2b331dda45f02f", "score": "0.8057226", "text": "function rng_seed_time() {\n\t\t rng_seed_int(new Date().getTime());\n\t\t}", "title": "" }, { "docid": "7ea5c7b4defdc4efa46bcdd4f46b17eb", "score": "0.7646768", "text": "rng_seed_time() {\n\t\tthis.rng_seed_int(new Date().getTime());\n\t}", "title": "" }, { "docid": "3ffdca2802c312ab43ed52277cb07e72", "score": "0.7615382", "text": "function rng_seed_time(){!function rng_seed_int(t){T[M++]^=255&t,T[M++]^=t>>8&255,T[M++]^=t>>16&255,T[M++]^=t>>24&255,M>=O&&(M-=O)}((new Date).getTime())}", "title": "" }, { "docid": "3ffdca2802c312ab43ed52277cb07e72", "score": "0.7615382", "text": "function rng_seed_time(){!function rng_seed_int(t){T[M++]^=255&t,T[M++]^=t>>8&255,T[M++]^=t>>16&255,T[M++]^=t>>24&255,M>=O&&(M-=O)}((new Date).getTime())}", "title": "" }, { "docid": "f4081a27500c3e292b51bd62ab0c6c5c", "score": "0.75309664", "text": "function rng_seed_time(){!function rng_seed_int(e){U[D++]^=255&e,U[D++]^=e>>8&255,U[D++]^=e>>16&255,U[D++]^=e>>24&255,D>=M&&(D-=M)}((new Date).getTime())}", "title": "" }, { "docid": "f4081a27500c3e292b51bd62ab0c6c5c", "score": "0.75309664", "text": "function rng_seed_time(){!function rng_seed_int(e){U[D++]^=255&e,U[D++]^=e>>8&255,U[D++]^=e>>16&255,U[D++]^=e>>24&255,D>=M&&(D-=M)}((new Date).getTime())}", "title": "" }, { "docid": "fbc72c17c657cd2baabf8de153f4c589", "score": "0.70941293", "text": "function rng(seed) {\n return seedrandom(seed || 'test');\n}", "title": "" }, { "docid": "6248e9e1109cb2f84235f91d3fbbc2fd", "score": "0.69102997", "text": "static Random(seed) {\n return null;\n }", "title": "" }, { "docid": "e0a2583c9eb5954cacef331beaea103d", "score": "0.68992895", "text": "function rng_seed_int(x){rng_pool[rng_pptr++]^=x&255;rng_pool[rng_pptr++]^=x>>8&255;rng_pool[rng_pptr++]^=x>>16&255;rng_pool[rng_pptr++]^=x>>24&255;if(rng_pptr>=rng_psize)rng_pptr-=rng_psize;}// Mix in the current time (w/milliseconds) into the pool", "title": "" }, { "docid": "f08b74a84d9bfb666298f91b674a0038", "score": "0.6875746", "text": "function _seed() {\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // digest pool 0's entropy and restart it\n md.update(ctx.pools[0].digest().getBytes());\n ctx.pools[0].start();\n\n // digest the entropy of other pools whose index k meet the\n // condition '2^k mod n == 0' where n is the number of reseeds\n var k = 1;\n for(var i = 1; i < 32; ++i) {\n // prevent signed numbers from being used\n k = (k === 31) ? 0x80000000 : (k << 2);\n if(k % ctx.reseeds === 0) {\n md.update(ctx.pools[i].digest().getBytes());\n ctx.pools[i].start();\n }\n }\n\n // get digest for key bytes and iterate again for seed bytes\n var keyBytes = md.digest().getBytes();\n md.start();\n md.update(keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update\n ctx.key = ctx.plugin.formatKey(keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n ctx.generated = 0;\n }", "title": "" }, { "docid": "5894083579d76ecf4bb4559488484089", "score": "0.6861586", "text": "function resetSeed() {\n window.seeder = 1777771 / (window.seed = (round(random() * 10000000))); // 1777771 is prime\n window.seedlast = .007;\n window.getSeed = function() { \n return seedlast = \"0.\" + String(seeder / seedlast).substring(4).replace('.', '');\n }\n}", "title": "" }, { "docid": "de9a154878f535b991a3ccf31ac02aa7", "score": "0.6819545", "text": "function rng() {\n return random();\n }", "title": "" }, { "docid": "de9a154878f535b991a3ccf31ac02aa7", "score": "0.6819545", "text": "function rng() {\n return random();\n }", "title": "" }, { "docid": "595e5748622fab249574e7f79d98d632", "score": "0.6795483", "text": "seed(seed)\n\t{\n\t\tseed = Math.abs(seed | 0);\n\t\tthis._a = (Random.r1 + Random.r2 + seed) % Random.r1;\n\t\tthis._b = (Random.r2 + Random.r3 + seed) % Random.r2;\n\t\tthis._c = (Random.r3 + Random.r1 + seed) % Random.r3;\n\t\tthis._d = 0;\n\t\tthis._e = 0;\n\t\tthis._f = 0;\n\t}", "title": "" }, { "docid": "8fde4aaabc6cdd937dea602f71c77b35", "score": "0.67602056", "text": "function _seed() {\n\t // create a plugin-based message digest\n\t var md = ctx.plugin.md.create();\n\n\t // digest pool 0's entropy and restart it\n\t md.update(ctx.pools[0].digest().getBytes());\n\t ctx.pools[0].start();\n\n\t // digest the entropy of other pools whose index k meet the\n\t // condition '2^k mod n == 0' where n is the number of reseeds\n\t var k = 1;\n\t for(var i = 1; i < 32; ++i) {\n\t // prevent signed numbers from being used\n\t k = (k === 31) ? 0x80000000 : (k << 2);\n\t if(k % ctx.reseeds === 0) {\n\t md.update(ctx.pools[i].digest().getBytes());\n\t ctx.pools[i].start();\n\t }\n\t }\n\n\t // get digest for key bytes and iterate again for seed bytes\n\t var keyBytes = md.digest().getBytes();\n\t md.start();\n\t md.update(keyBytes);\n\t var seedBytes = md.digest().getBytes();\n\n\t // update\n\t ctx.key = ctx.plugin.formatKey(keyBytes);\n\t ctx.seed = ctx.plugin.formatSeed(seedBytes);\n\t ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\t ctx.generated = 0;\n\t }", "title": "" }, { "docid": "2b7b5200da0ca7dbcc13d624a2e87670", "score": "0.6758097", "text": "function initialize(seed = DEFAULT_SEED) {\n return seed;\n }", "title": "" }, { "docid": "18c05267bd83612defab11ed31e063f7", "score": "0.67316175", "text": "function rng() {\n return random();\n }", "title": "" }, { "docid": "9c2a509ac139037db4b8d4b52a9e1a4b", "score": "0.6700422", "text": "function initRandom(seed) {\n let val = seed % 2147483647;\n return () => val = (val * 16807) % 2147483647;\n}", "title": "" }, { "docid": "64d33f50cbb4d164d5b340f17093667a", "score": "0.6638239", "text": "function randomNumberGenerator() {\n seed = (seed * g) % n;\n return seed;\n}", "title": "" }, { "docid": "505e2219e72cf430120976351dec466a", "score": "0.662474", "text": "function seededRandom(s) {\n if (s !== undefined) _seed = s % 2147483647;\n // Park-Miller algorithm\n _seed = _seed * 16807 % 2147483647;\n return (_seed - 1) / 2147483646;\n}", "title": "" }, { "docid": "4400ffee82222145ca7c0fe6125d7ce8", "score": "0.66136664", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = ctx.reseeds === 0xffffffff ? 0 : ctx.reseeds + 1;\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n // consume current key bytes\n md.update(ctx.keyBytes);\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k){\n if (ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "be63e740080460be3b39e77f140a6735", "score": "0.65794045", "text": "function _seed() {\n // update reseed count\n ctx.reseeds = (ctx.reseeds === 0xffffffff) ? 0 : ctx.reseeds + 1;\n\n // goal is to update `key` via:\n // key = hash(key + s)\n // where 's' is all collected entropy from selected pools, then...\n\n // create a plugin-based message digest\n var md = ctx.plugin.md.create();\n\n // consume current key bytes\n md.update(ctx.keyBytes);\n\n // digest the entropy of pools whose index k meet the\n // condition 'n mod 2^k == 0' where n is the number of reseeds\n var _2powK = 1;\n for(var k = 0; k < 32; ++k) {\n if(ctx.reseeds % _2powK === 0) {\n md.update(ctx.pools[k].digest().getBytes());\n ctx.pools[k].start();\n }\n _2powK = _2powK << 1;\n }\n\n // get digest for key bytes\n ctx.keyBytes = md.digest().getBytes();\n\n // paranoid deviation from Fortuna:\n // update `seed` via `seed = hash(key)`\n // instead of initializing to zero once and only\n // ever incrementing it\n md.start();\n md.update(ctx.keyBytes);\n var seedBytes = md.digest().getBytes();\n\n // update state\n ctx.key = ctx.plugin.formatKey(ctx.keyBytes);\n ctx.seed = ctx.plugin.formatSeed(seedBytes);\n ctx.generated = 0;\n }", "title": "" }, { "docid": "7fe7a1414302ac63ff8f90d5c629f98d", "score": "0.65781736", "text": "function random(seed) {\r\n // Returns random number to caller\r\n return Math.floor((Math.random() * seed));\r\n}", "title": "" }, { "docid": "da10824c74832a9b86835a5271c680ae", "score": "0.6570102", "text": "function setSeed(seed) {\n random = seed === null ? singletonRandom : (0, _seedRandom.default)(String(seed));\n } // initialize a seeded pseudo random number generator with config's random seed", "title": "" }, { "docid": "0d75479f63b605823af7bae8ded0bcfd", "score": "0.6562349", "text": "function seededRandom( s ) {\n\n\tif ( s !== undefined ) _seed = s % 2147483647;\n\n\t// Park-Miller algorithm\n\n\t_seed = _seed * 16807 % 2147483647;\n\n\treturn ( _seed - 1 ) / 2147483646;\n\n}", "title": "" }, { "docid": "94d0e5f009bbb9d6b8525466658a57fa", "score": "0.6539234", "text": "function next() {\n seed += 1;\n return seed;\n}", "title": "" }, { "docid": "0e3741dabf7b0daaff4c552b62a17abb", "score": "0.65005463", "text": "function srand(s) {\n initialized = true;\n return _srand(s);\n }", "title": "" }, { "docid": "3647c4d1ab96a75fbb32ecce9da8a5c0", "score": "0.64969575", "text": "function setSeed (seed) {\n random = seed === null ? singletonRandom : seedrandom(String(seed));\n }", "title": "" }, { "docid": "67530a43aabcab200373f1df6b7f6524", "score": "0.64528847", "text": "function seedrand(seed) {\n for (let i = 0; i < randseed.length; i++) {\n randseed[i] = 0;\n }\n for (let i = 0; i < seed.length; i++) {\n randseed[i % 4] = (randseed[i % 4] << 5) - randseed[i % 4] + seed.charCodeAt(i);\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "cbeca0e231aa550b3c6ff68ee8ad5ebf", "score": "0.64496726", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "54fc84e7cb681051d92925bd21b7937d", "score": "0.64324933", "text": "function makeRNG(seed)\n{\n let lcg = (a) => (a * 48271 % 2147483647)\n\t\n seed = lcg(seed)\n\t\n return () => ((seed = lcg(seed)) / 2147483648)\n}", "title": "" }, { "docid": "271235ba464b6deaaa7a3f02b157bae1", "score": "0.6430599", "text": "function seedRandon(seed) {\n let _seed = seed;\n return function random() {\n var x = Math.sin(_seed++) * 10000;\n return x - Math.floor(x);\n };\n}", "title": "" }, { "docid": "b8b4e8b4f40cdfff69b53b0fb6f3476c", "score": "0.64221394", "text": "function get_random() {\n return Math.seededRandom(0, 1);\n}", "title": "" }, { "docid": "ba2cf406e6e7bd66a33998b8e263b214", "score": "0.6387703", "text": "static createGenerator(_seed) {\n // TODO: replace with random number generator to generate predictable sequence\n return Math.random;\n }", "title": "" }, { "docid": "78e6386c6878bd92e0ce22518db1218b", "score": "0.6370942", "text": "function pseudoRandom(seed) {\n seed = (seed * 9301 + 49297) % 233280;\n return seed / 233280.0;\n}", "title": "" }, { "docid": "78e6386c6878bd92e0ce22518db1218b", "score": "0.6370942", "text": "function pseudoRandom(seed) {\n seed = (seed * 9301 + 49297) % 233280;\n return seed / 233280.0;\n}", "title": "" }, { "docid": "4570181f34cbd2e0d9185b131788eed8", "score": "0.63542783", "text": "function autoseed() {\n try {\n if (nodecrypto) { return tostring(nodecrypto.randomBytes(width)); }\n var out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "4570181f34cbd2e0d9185b131788eed8", "score": "0.63542783", "text": "function autoseed() {\n try {\n if (nodecrypto) { return tostring(nodecrypto.randomBytes(width)); }\n var out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "4570181f34cbd2e0d9185b131788eed8", "score": "0.63542783", "text": "function autoseed() {\n try {\n if (nodecrypto) { return tostring(nodecrypto.randomBytes(width)); }\n var out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n}", "title": "" }, { "docid": "8d3b01dcb12c0c52d5688ebdd8b3ac67", "score": "0.6352211", "text": "function random() {\n return Math.random();\n // var x = Math.sin(seed++) * 10000;\n // return x - Math.floor(x);\n}", "title": "" }, { "docid": "41194c063c36ca898339623ceb2f6c12", "score": "0.6352122", "text": "function setSeed(seed) {\n random = seed === null ? singletonRandom : __WEBPACK_IMPORTED_MODULE_0_seed_random___default()(String(seed));\n } // initialize a seeded pseudo random number generator with config's random seed", "title": "" }, { "docid": "fe5ffd3b2c60aa1602b81da824102725", "score": "0.6329799", "text": "function SeededRandom(){}", "title": "" }, { "docid": "f6e03ed536612e36621d31634d63a391", "score": "0.63265043", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n }", "title": "" }, { "docid": "f6e03ed536612e36621d31634d63a391", "score": "0.63265043", "text": "function autoseed() {\n try {\n var out;\n if (nodecrypto && (out = nodecrypto.randomBytes)) {\n // The use of 'out' to remember randomBytes makes tight minified code.\n out = out(width);\n } else {\n out = new Uint8Array(width);\n (global.crypto || global.msCrypto).getRandomValues(out);\n }\n return tostring(out);\n } catch (e) {\n var browser = global.navigator,\n plugins = browser && browser.plugins;\n return [+new Date, global, plugins, global.screen, tostring(pool)];\n }\n }", "title": "" } ]
3ba1c4bbc2f4d1c32c3b11dc06fc4936
Resize the window on a resize event.
[ { "docid": "2d6b26f261e66153fcbb139310d340f3", "score": "0.0", "text": "function _resize() {\n if (!view)\n return;\n view.resize();\n}", "title": "" } ]
[ { "docid": "24fa3344715d84feb171989cb06bd0e1", "score": "0.8136594", "text": "function windowResized() {\n resize();\n redraw();\n}", "title": "" }, { "docid": "ac6c2f3efd5f41f22633da471714380f", "score": "0.789357", "text": "function qodeOnWindowResize() {\n }", "title": "" }, { "docid": "728ba02b902235e9dd1b67ec2d558fe8", "score": "0.7860834", "text": "function windowResized() {\r\n resizeCanvas(windowWidth, windowHeight)\r\n }", "title": "" }, { "docid": "94f7eb64439135a3469c7724ef08045b", "score": "0.78116107", "text": "function qodeOnWindowResize() {\n\n\t}", "title": "" }, { "docid": "acdb044ad7a811ea556181d57574c9b4", "score": "0.7788217", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n }", "title": "" }, { "docid": "62055c70c06e59df0701da0d3003770b", "score": "0.7772455", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n redraw();\n}", "title": "" }, { "docid": "349534ec307632701d20607f315920dc", "score": "0.77722406", "text": "function windowResized () {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0888d811d7ba71cb2932d8f8c6e9fd1d", "score": "0.7736968", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "0f541238ed71272f067f7e52f15dccfe", "score": "0.7725165", "text": "onWindowResize() {\n debugLog('ForceHorseViewer:onWindowResize');\n\n this.calcFixAspectRatio();\n this.updateGraphInDOM();\n }", "title": "" }, { "docid": "73185f1b6b409f81d8c030a4b5adfd3b", "score": "0.7725083", "text": "function handleResize() {\n setWindowHeight(getWindowHeight())\n setWindowWidth(getWindowWidth())\n }", "title": "" }, { "docid": "b8ed627b77a9536df75032edc5acabb6", "score": "0.7694354", "text": "function windowResized() {\n\tresizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "b8ed627b77a9536df75032edc5acabb6", "score": "0.7694354", "text": "function windowResized() {\n\tresizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "b8ed627b77a9536df75032edc5acabb6", "score": "0.7694354", "text": "function windowResized() {\n\tresizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "b8ed627b77a9536df75032edc5acabb6", "score": "0.7694354", "text": "function windowResized() {\n\tresizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "e550dee9ccd55c821be80821541b208c", "score": "0.7682193", "text": "function windowResize() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "b3a7189878a59b295fe2eb29e0d22610", "score": "0.76710385", "text": "function windowresized() {\n \tresizeCanvas(windowWidth, windowHeight);}", "title": "" }, { "docid": "b589054787bef78aab3bea88149524a2", "score": "0.766994", "text": "function handleResize() {\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "5e1740e5712c31058dc7659c33cf7aab", "score": "0.76677483", "text": "function windowResized () {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "2578bb250fa9420182ddc02e8f569c90", "score": "0.7666071", "text": "function emitWindowResize() {\n window.dispatchEvent(new Event('resize'));\n }", "title": "" }, { "docid": "15ec93a70bcf41773bbabaed7a6a4015", "score": "0.76642513", "text": "function onResize() {\n setSize();\n }", "title": "" }, { "docid": "15ec93a70bcf41773bbabaed7a6a4015", "score": "0.76642513", "text": "function onResize() {\n setSize();\n }", "title": "" }, { "docid": "15ec93a70bcf41773bbabaed7a6a4015", "score": "0.76642513", "text": "function onResize() {\n setSize();\n }", "title": "" }, { "docid": "b83717935c265614928d172b11ca9a51", "score": "0.76548904", "text": "function windowResizeEventHandler() {\n adjustToContainer();\n }", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "1dbc400102708c599877699b7cabc691", "score": "0.7647684", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "be5bfa3b7bb8a79cec4cc0f6cea363b0", "score": "0.7647009", "text": "function handleResize() {\n setWindowSize( {\n width: window.innerWidth,\n height: window.innerHeight\n });\n }", "title": "" }, { "docid": "1af70147af2f818d4dc3047ac1131d93", "score": "0.76452917", "text": "function windowResized() {\r\n resizeCanvas(windowWidth, windowHeight);\r\n}", "title": "" }, { "docid": "1af70147af2f818d4dc3047ac1131d93", "score": "0.76452917", "text": "function windowResized() {\r\n resizeCanvas(windowWidth, windowHeight);\r\n}", "title": "" }, { "docid": "d0110e396d275c90036bb05eddff64da", "score": "0.76452225", "text": "function windowResized() {\n resizeCanvas(windowHeight, windowHeight);\n}", "title": "" }, { "docid": "94f0b63749e0ff85c1d15ea67c8e0126", "score": "0.76236886", "text": "function windowResized() {\n\tresizeCanvas(canW, canH)\n\tcanW = container.offsetWidth\n\tcanH = container.offsetHeight\n\tredraw()\n}", "title": "" }, { "docid": "5101f55966462d65a0b1417eead6e94d", "score": "0.7617071", "text": "function windowResized() {\n\tresizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "71284aa02d5ec669d15553fe076366a1", "score": "0.76134616", "text": "function onWindowResize(event, obj) {\n var code = event.type;\n\n var action = obj.Bindings[obj.ACTIONs.RESIZE][code];\n if (action) {\n action();\n }\n }", "title": "" }, { "docid": "ea30e1be2ab557aeb1cdd436f83c0275", "score": "0.7612448", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight)\n}", "title": "" }, { "docid": "ea30e1be2ab557aeb1cdd436f83c0275", "score": "0.7612448", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight)\n}", "title": "" }, { "docid": "ea30e1be2ab557aeb1cdd436f83c0275", "score": "0.7612448", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight)\n}", "title": "" }, { "docid": "811d801c22e98b975a33a476464c7058", "score": "0.76094747", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "57a04d4cb44091f4790b1be0533a7a16", "score": "0.7607394", "text": "function windowResized() {\n resizeCanvas(windowWidth - 10, windowHeight - 10);\n}", "title": "" }, { "docid": "f7b1bd33b28f4d7605321652285d4fe5", "score": "0.75968456", "text": "function windowResized() {\n extentsX = windowWidth;\n extentsY = windowHeight;\n resizeCanvas(extentsX, extentsY);\n InitializeCells(); // Refresh cell drawing\n }", "title": "" }, { "docid": "ead8e4103b2743146e6b4fcf71628481", "score": "0.7596461", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight\n });\n } // Add event listener", "title": "" }, { "docid": "e963f336ceb359bb0be42c7254ed6186", "score": "0.7594644", "text": "function onWindowResize( event ) {\n\n layout();\n\n }", "title": "" }, { "docid": "a60951b5afeea6c413f4eae165567775", "score": "0.75651294", "text": "function resize(){\n\t\t\tsetDimensions();\n\t\t\tconsole.log('resized');\n\t\t}", "title": "" }, { "docid": "3102c291bab7626422f5f7bd2754c03e", "score": "0.7546841", "text": "function qodefOnWindowResize() {\n\n }", "title": "" }, { "docid": "07314bcfef5ab7f5942908a8b369cebc", "score": "0.75371206", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight);\n // update w & h while we are at it\n w = windowWidth\n h = windowHeight\n \n}", "title": "" }, { "docid": "beab89d333bc202c836e7e5ae469002f", "score": "0.7535215", "text": "function resize() {\n resizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "b75cd7e0ded4f85ab0810b85064bdde7", "score": "0.7535171", "text": "function windowResized() {\n resizeCanvas(innerWidth, innerHeight);\n}", "title": "" }, { "docid": "b75cd7e0ded4f85ab0810b85064bdde7", "score": "0.7535171", "text": "function windowResized() {\n resizeCanvas(innerWidth, innerHeight);\n}", "title": "" }, { "docid": "494c22dc28d2f26cfef3b599ece2a4e9", "score": "0.75235116", "text": "function windowResized() {\n\t//Update the width and height of canvas\n\tresizeCanvas(windowWidth, windowHeight);\n}", "title": "" }, { "docid": "9352eead6331874774a33138115ba821", "score": "0.75224555", "text": "function resize(){global.screenWidth=window.innerWidth;global.screenHeight=window.innerHeight;canvasGameBoard.setHeight(global.screenHeight);canvasGameBoard.setWidth(global.screenWidth);socket.emit('windowResized',{screenWidth:global.screenWidth,screenHeight:global.screenHeight});}", "title": "" }, { "docid": "1941a5d212bcd4df2bb2ab3d9f70fc4f", "score": "0.7521648", "text": "function windowResized() {\r\n resizeCanvas(windowWidth, windowHeight)\r\n}", "title": "" }, { "docid": "7945ae9e5035e0947074f49a5dee80ad", "score": "0.74946404", "text": "onWindowResize (event) {\n\n \t// TODO: what is this??\n\t\t// this.computeComponentDimensions();\n\n\t}", "title": "" }, { "docid": "da76e7da2b44ca3f0d3379700e4945cb", "score": "0.74900377", "text": "function windowResized() {\n\t// if the window width is smaller than css_maxwidth (22rem), resize the canvas to the width of the viewport\n\tlet w = css_maxwidth > windowWidth ? windowWidth : css_maxwidth;\n\tresizeCanvas(w, w);\n}", "title": "" }, { "docid": "6c16c82587551236462da68e7cc72bdc", "score": "0.7488989", "text": "function onResize(event) {\n}", "title": "" }, { "docid": "be8eefa2177537816bf75d414e49a8a5", "score": "0.7474915", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "be8eefa2177537816bf75d414e49a8a5", "score": "0.7474915", "text": "function windowResized() {\n resizeCanvas(windowWidth, windowHeight, false);\n}", "title": "" }, { "docid": "6d11132b211d6d5a0cd80505fe349aea", "score": "0.7465532", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "2fe11634a135b89b9c1c5d915ef00e3e", "score": "0.74630535", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "d4493a8c97106dc7d0552281c56523c3", "score": "0.74619967", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "486c432b8d71509e55fb24117dab503f", "score": "0.74567056", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "486c432b8d71509e55fb24117dab503f", "score": "0.74567056", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "486c432b8d71509e55fb24117dab503f", "score": "0.74567056", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "2c5e362cc5f540a3530dc28fa0e1b381", "score": "0.74467474", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "2c5e362cc5f540a3530dc28fa0e1b381", "score": "0.74467474", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "35c730a85a75982b3d3028ff9e0a48fd", "score": "0.7443771", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "35c730a85a75982b3d3028ff9e0a48fd", "score": "0.7443771", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "35c730a85a75982b3d3028ff9e0a48fd", "score": "0.7443771", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "35c730a85a75982b3d3028ff9e0a48fd", "score": "0.7443771", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "35c730a85a75982b3d3028ff9e0a48fd", "score": "0.7443771", "text": "function handleResize() {\n // Set window width/height to state\n setWindowSize({\n width: window.innerWidth,\n height: window.innerHeight,\n });\n }", "title": "" }, { "docid": "1cf3f72672bdaa7d24c2ac46369e25e8", "score": "0.7435205", "text": "function windowResized() {\n resizeCanvas(innerWidth, innerHeight);\n}", "title": "" } ]
f41c2977b706f61bd005676dee29416e
write the new posotion of the ball to the data base set()is used to set a new value inside the database
[ { "docid": "0ef3059ab4298eddb19d4f3d7ac0335f", "score": "0.74146885", "text": "function writePosition(x,y){\n // ball.x = ball.x + x;\n database.ref ('ball/position').set({\n 'x':position.x + x,\n 'y':position.y + y\n})\n}", "title": "" } ]
[ { "docid": "d6badeca1c9b0f9e8351cdd706df34ae", "score": "0.7031924", "text": "function changePosition(a,b){\n\n db.ref('ball/position').update({\n\n 'x': ball.x + a,\n 'y': ball.y + b,\n })\n \n \n}", "title": "" }, { "docid": "d93c48a52fa1157ba5dc04b99010bffa", "score": "0.6744434", "text": "function changePosition(x,y){\n database.ref('ball/position').set({\n x:position.x+x,\n y:position.y+y\n })\n}", "title": "" }, { "docid": "ca3f628fc7bd257b009b864b9aa099d4", "score": "0.6680745", "text": "function writePosition(x,y){\n dataBase.ref('ball/position').set({\n 'x':position.x+x,\n 'y':position.y+y\n });\n}", "title": "" }, { "docid": "39fe00a203f18593622bc20215815209", "score": "0.6052126", "text": "save(){\n DB.setPoints(this.id, this.points);\n DB.setBirthday(this.id, this.birthday);\n return;\n }", "title": "" }, { "docid": "73d6d63583c7bc097ab2a968540e91fa", "score": "0.59753275", "text": "function readPosition(data){\nposition = data.val()\nhypnoticBall.x = position.x\nhypnoticBall.y = position.y\n}", "title": "" }, { "docid": "82264b953c3186d3b67b73b40ba29bbb", "score": "0.59336585", "text": "function addFoods(){\r\n Dog.addImage(DogImg1);\r\n foodS++;\r\n database.ref('/').update({\r\n Food:foodS\r\n })\r\n Dog.position.x=475;\r\n Dog.position.y=250;\r\n}", "title": "" }, { "docid": "a3e5f131c960d651ec346a95a4beece8", "score": "0.59065104", "text": "function newPositionofBall(){\n ball.position.x += speedx \n ball.position.y += speedy \n}", "title": "" }, { "docid": "4becaaa7ca41bba4f8162fc6d138a0be", "score": "0.5890374", "text": "function readpos(data){\n\n ballPosition = data.val();\n ball.x = ballPosition.x;\n ball.y = ballPosition.y;\n}", "title": "" }, { "docid": "53f058ed56620ac72d20da5017864fe8", "score": "0.57725364", "text": "function addFood(){\r\n \r\n foodObj.foodStock+=1;\r\n database.ref('/').set({\r\n food:foodObj.foodStock\r\n });\r\n\r\n}", "title": "" }, { "docid": "e4f54be272e3f68c8bcd87627b0caa92", "score": "0.5759461", "text": "function readposition(data){ \n position = data.val(); \n ball.x= position.x ;\n ball.y = position.y ; \n\n}", "title": "" }, { "docid": "0a01d2e41a11c3d5dbf405362091950f", "score": "0.5661976", "text": "function writeStock(x){\r\n if(x<=0){\r\n x=20;\r\n //dog.addImage(dogImg1);\r\n }else{\r\n x=x-1;\r\n } \r\n\r\n database.ref('/').update({\r\n Food:x\r\n })\r\n}", "title": "" }, { "docid": "b18a45b46a3239f17fde9a8af8ac4cab", "score": "0.5586817", "text": "updatePosition() {\n this.position = Utils.convertToEntityPosition(this.bmp);\n }", "title": "" }, { "docid": "fe231b248347689f2e23d172bc8b467c", "score": "0.5581444", "text": "function addFood(){\r\n dog.addImage(Dog);//dog changes back to image stored in variable Dog\r\n foodS++; //the value in foodS in incremented by 1\r\n database.ref('/').update({\r\n Food:foodS //Food now also refers to the value of foodS\r\n })\r\n }", "title": "" }, { "docid": "f7a041bdf3c9de18470da62276b2f2da", "score": "0.55739665", "text": "resetBall ()\n{\n this.ball.setVelocity(0);\n this.ball.setPosition(this.paddle.x, 545);\n this.ball.setData('onPaddle', true);\n}", "title": "" }, { "docid": "5d308f5547bb566f5bcd083a87602779", "score": "0.55659664", "text": "update(){\r\n\t\tlet e \t\t= App.ecs.entities[ this.entity_id ];\r\n\t\tlet pnts\t= e.Points;\r\n\r\n\t\tpnts.reset();\r\n\t\tfor( let p of this.points ){\r\n\t\t\tpnts.add( p.pos, p.color );\r\n\t\t}\r\n\t\tthis.updated = false;\r\n\t}", "title": "" }, { "docid": "c8cf3319af955274b8ee25e9bdfab55b", "score": "0.55610776", "text": "function addFoods(){\r\n\r\n poorman.addImage(sadPoorman);\r\n poorman.scale = 0.22;\r\n\r\n foodS++;\r\n database.ref('/').update({\r\n Food:foodS\r\n })\r\n}", "title": "" }, { "docid": "03e6f43a44d474ebf816f3ade393df83", "score": "0.5535597", "text": "function feedDog(){\r\n Dog.addImage(DogImg2);\r\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\r\n database.ref('/').update({\r\n Food:foodObj.getFoodStock(),\r\n FeedTime:hour()\r\n })\r\n Dog.position.x=250;\r\n Dog.position.y=200;\r\n}", "title": "" }, { "docid": "dc8cdc32cb53ea69a72a02b706642abf", "score": "0.5516335", "text": "update() {\n\t\tthis.boids.forEach((boid)=>{\n\t\t\tboid.move();\n\t\t});\n\t}", "title": "" }, { "docid": "38b55d349721f0033982b0202ddaa9ad", "score": "0.55091256", "text": "function addFood()\n{\n dog.addImage(dogImg);\n foodObject.foodStock++;\n database.ref('/').update({\n Food : foodObject.foodStock\n })\n}", "title": "" }, { "docid": "6425a945ae7eef33fa3ccb5ba2714c10", "score": "0.55071604", "text": "savePosition (x, y) {\n this.trajectory.push(this.getPosition(x, y))\n }", "title": "" }, { "docid": "d6e016209ca46ec7f76ebaae8503c070", "score": "0.5494853", "text": "function readPosition(data){\n position = data.val();\n hypnoticBall.x = position.x;\n hypnoticBall.y = position.y;\n}", "title": "" }, { "docid": "a527e1fc3820e632da506c3ed2726080", "score": "0.5486923", "text": "function writeStock(x){\n database.ref('/').update({\n food:x\n })\n\n }", "title": "" }, { "docid": "f90c3751baaed1b7c821989ff5e7a33d", "score": "0.5429528", "text": "function feed_Dog(){\r\n dog.addImage(happyDog);\r\n foodS--;\r\n console.log(foodS);\r\n getFeedTime();\r\n database.ref('/').update({\r\n Food:foodS })\r\n database.ref('/').update({\r\n FeedTime:lastfeed})\r\n \r\n }", "title": "" }, { "docid": "7384054f614eb0ddb08fb83ff68c2d63", "score": "0.54246587", "text": "setPos(pos){this.pos = pos;}", "title": "" }, { "docid": "0d4ca4b6dfe12ee72f9035e8217c9c4a", "score": "0.54106134", "text": "updateNewPosState(name, value) {\n let newState = this.state;\n newState.new_pos[name] = value;\n this.setState(newState);\n }", "title": "" }, { "docid": "c8b0310acd260333847764e716c340fb", "score": "0.54100186", "text": "function writeStock(x){\nif(x<=0){\n x = 0;\n}else{\n x = x-1;\n}\n\n\n\ndatabase.ref('/').update({\nFood : x\n\n })\n\n}", "title": "" }, { "docid": "e76b90389992b1350e963207167c3cd6", "score": "0.54019934", "text": "$setPos(pos) {\n checkArgs('$setPos', arguments, ['point']);\n [this.x, this.y] = [pos.x, pos.y];\n this.$rec.setTo(this.x, this.y, this.width, this.height);\n }", "title": "" }, { "docid": "60014506b4784caf83484ea6115fd82e", "score": "0.5392964", "text": "function feedDog(){\n dog.addImage(happyDog);\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\n database.ref('/').update({\n Food:foodObj.getFoodStock(),\n FeedTime :hour(),\n //lastFed : hour(),\n \n \n })\n}", "title": "" }, { "docid": "80aa30a92ea2a7e249fb6f526cfe8ab3", "score": "0.5390588", "text": "function feedDog(){\r\n foodS = foodS - 1;\r\n dog.addImage(happyDog);\r\n database.ref('/').update({\r\n food: foodObj.getFoodStock(),\r\n food : foodS\r\n })\r\n}", "title": "" }, { "docid": "859a92cef28d3bbfc071b35f38b87dda", "score": "0.53855336", "text": "saveData() {\n const data = {\n souls: this.souls,\n levels: this.levels,\n lastPlayed: this.timeNow()\n };\n saveObjectToLocal(data);\n }", "title": "" }, { "docid": "fcd0b9dbaa7df00c89553902205c5c2c", "score": "0.5376831", "text": "function writeStock(x) {\n database. ref('/') . update({\n Food :x\n }) \n }", "title": "" }, { "docid": "2ff613ca0b9e5a1aa7369d2081551e21", "score": "0.5373361", "text": "Update(){}", "title": "" }, { "docid": "330a8054ed43c86394fa07abe6bbe39e", "score": "0.5371524", "text": "function feedDog(){\r\n dog.addImage(happyDog);\r\n\r\n if(foodObj.getFoodStock()<=0){\r\n foodObj.updateFoodStock(foodObj.getFoodStock()*0);\r\n } else{\r\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\r\n }\r\n\r\n // database.ref('/').set({\r\n // FeedTime: feedTime\r\n // });\r\n}", "title": "" }, { "docid": "3531097d2277edfef30daf046edf0841", "score": "0.53474766", "text": "function addFoods(){\n dog.addImage(sadDog);\n foodObj.updateFoodStock(foodObj.getFoodStock()+1);\n foodS++;\n database.ref('/').update({\n Food:foodS\n })\n}", "title": "" }, { "docid": "1e6288ac572c820d33985cd216575baf", "score": "0.5339591", "text": "function addFoods(){\n dog.addImage(dogImg)\n dog.visible = true;\n foodS++;\n database.ref('/').update({\n Food:foodS,\n gameState:\"2\"\n })\n}", "title": "" }, { "docid": "066ce59aac254903b83f91851f24217a", "score": "0.5337407", "text": "function movimentaBolinha(){\n xBolinha += velocidadeXBolinha; \n yBolinha += velocidadeYBolinha;\n \n}", "title": "" }, { "docid": "0f1648e729c0247ffa32f43525701987", "score": "0.5325115", "text": "function feedDog(){\n dog.addImage(happyDog);\n \n foodObj.updateFoodStock(foodObj.getFoodStock()-1); \n database.ref('/').update({ \n Food:foodObj.getFoodStock(), \n FeedTime:hour(), \n gameState:\"Hungry\" \n })\n}", "title": "" }, { "docid": "9ba725c395792892dd5fdaf4502aac8f", "score": "0.5322069", "text": "update(){\r\n \r\n //print(this.velo);\r\n this.velo.add(this.acc);\r\n this.velo.limit(this.maxSpeed);\r\n this.pos.add(this.velo);\r\n \r\n\r\n}", "title": "" }, { "docid": "8d442827fe87e698a5a521bbec15343a", "score": "0.53105205", "text": "updateBall(ball) {\r\n ball.pos = this.finalPos();\r\n ball.speed = this.vel.norm();\r\n\r\n if (ball.speed == 0)\r\n ball.velDir = Vec.of(0,0,0);\r\n else\r\n ball.velDir = this.vel.normalized();\r\n }", "title": "" }, { "docid": "1513132cff003d1891ea87d74e9e7052", "score": "0.53073996", "text": "feedDog(){\r\n dog.addImage(happyDog);\r\n\r\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\r\n database.ref('/').update({\r\nFood:foodObj.getFoodStock(),\r\nFeedTime:hour()\r\n\r\n })\r\n}", "title": "" }, { "docid": "42bb2c773b0a099e4535d9796e8a251e", "score": "0.5307272", "text": "function writeStock(x){\n database.ref('/').update({\n Food:x\n })\n}", "title": "" }, { "docid": "4a46839464308e7e08cea71a47717e69", "score": "0.52941555", "text": "savePositionToDatabase(tag, location) {\n console.log(\"saveposition\")\n try{\n let loc=location.position;\n loc.name=location.name;\n this.axios().put(`${this.restUrl}/api/v1/residents/bytag/${tag}/lastRecordedPosition`,loc).then(()=>{\n console.log(`position saved for tag ${tag}`)\n }).catch(()=>{console.log(`no user found for tag${tag}`)});\n \n }catch(e){\n\n console.log(\"error on saving\");\n console.log(e);\n\n }\n\n\n }", "title": "" }, { "docid": "bfd942ebb91c67725975ed687520f1e9", "score": "0.52902645", "text": "function updateFoodStock(){\r\n foodS +=1;\r\n database.ref('/').update({\r\n Food : foodS\r\n })\r\n}", "title": "" }, { "docid": "391465aab4d29ecad28bb6a2fe5a8038", "score": "0.52887166", "text": "function updateDataBase(pCompanyName, pPositionTitle, pUrl, pNotes, pColCardPosition, pDate)\n{\n\tdb.run('INSERT INTO Portfolios (CompanyName, PositionTitle, Url, Notes, ColCardPosition, Color, Date) VALUES ($CompanyName, $PositionTitle, $Url, $Notes, $ColCardPosition, $Color, $Date)',\n\t{\n\t\t$CompanyName: pCompanyName,\n\t\t$PositionTitle: pPositionTitle,\n\t\t$Url: pUrl,\n\t\t$Notes: pNotes,\n\t\t$ColCardPosition: pColCardPosition,\n\t\t$Color: colCardColor,\n\t\t$Date: pDate\n\t});\t\n}", "title": "" }, { "docid": "3fd370e3767701f3758ddbdf5528c54e", "score": "0.52869374", "text": "function store(pos) {\n\t\tlastTarget.copy(targetPos);\n\t\tstoredPos.copy(pos);\n\t}", "title": "" }, { "docid": "6e091e8532f8d3c0b573e288086e351f", "score": "0.52855843", "text": "update(pos) {\r\n this.newCursor(pos);\r\n this.t += this.tStep;\r\n }", "title": "" }, { "docid": "abf1b34909a6c11233887e74e02cf7b9", "score": "0.5284164", "text": "addFood(){\r\n foodS++;\r\n database.ref('/').update({\r\n Food:foodS\r\n\r\n})\r\n}", "title": "" }, { "docid": "d1983043e3737b9b633a20802c96105d", "score": "0.5281691", "text": "function feedDog(){\n dog.addImage(happydogImg);\n\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\n database.ref('/').update({\n Food:foodObj.getFoodStock(),\n fedTime:hour()\n })\n\n\n }", "title": "" }, { "docid": "57cda49c68758b361f41b892a699183d", "score": "0.52688754", "text": "function writeStock(x){\n\n database.ref(\"/\").update({\n Food:x\n })\n}", "title": "" }, { "docid": "3d35f461070a2711c6ded1124928f50b", "score": "0.52662313", "text": "updatePlayerNameAndDistance () {\r\n var playerIndex =\"/players/player\"+this.index;\r\n var playerRef = database.ref (playerIndex).set (\r\n {\r\n name:this.name,\r\n distance:this.distance \r\n }\r\n );\r\n \r\n }", "title": "" }, { "docid": "c375dc2c22841c4f5ddc9db4acb3a46e", "score": "0.5262172", "text": "function setup() {\r\n database=firebase.database();\r\n createCanvas(1400,700);\r\n createEdgeSprites();\r\n\r\n balloon=createSprite(250,450,150,150);\r\n balloon.addAnimation(\"hotAirBalloon\",balloonImage1);\r\n balloon.scale=0.5;\r\n var balloonPos = database.ref('ball/position');\r\n balloonPos.on(\"value\", readPosition, showError)\r\n\r\n textSize(20); \r\n}", "title": "" }, { "docid": "d0a6221d4064f91baef36d8967a0e50d", "score": "0.5261049", "text": "function writeStokingMec(x){\n\n if(x<=0){\n x=0\n }else{\n x=x-1\n }\n database.ref('/').set({\n food:x\n })\n}", "title": "" }, { "docid": "7ac18b54659e041cf9d3dd6dfd236beb", "score": "0.5255", "text": "function put_boat(slip_id, boat_id){\r\n const slip_key = datastore.key([SLIP, parseInt(slip_id,10)]);\r\n // console.log(\"slipKey: \", slip_key);\r\n return datastore.get(slip_key)\r\n .then( (slip) => {\r\n // console.log(\"slip[0]: \", slip[0]);\r\n if( slip[0].current_boat === null){\r\n // console.log(\"inside if\");\r\n slip[0].current_boat = boat_id;\r\n } else if (slip[0].current_boat !== null) {\r\n return null;\r\n }\r\n // console.log(\"slip[0].currentBoat after push: \", slip[0].current_boat);\r\n return datastore.save({\"key\":slip_key, \"data\":slip[0]});\r\n });\r\n}", "title": "" }, { "docid": "fb2d95dab9678c8c6753908ca27f2aef", "score": "0.52530026", "text": "function setData() {\n // add the current game to the stats\n calculateStats();\n \n // set the stats\n setStats();\n\n // calculate money before saving it\n calculateMoney();\n\n // set total money\n setMoney();\n}", "title": "" }, { "docid": "f75cf7943cc6bdf7ffffc92df2bbb28a", "score": "0.5252271", "text": "async save() {\n await db.query(`\n UPDATE jobs \n SET title=$1, salary=$2, equity=$3, company_handle=$4 \n WHERE id = $5`,\n [this.title, this.salary, this.equity, this.companyHandle, this.id]\n );\n }", "title": "" }, { "docid": "9610f0c4d3c9534601f0a5f02ff04f27", "score": "0.52489173", "text": "function writeStock(x){\n if(x<=0){\n x=0 \n }\n else{\n x=x-1\n } \n database.ref('/').update({Food:x})\n }", "title": "" }, { "docid": "1aeea0494cac6fd513aa5d576d36b026", "score": "0.5247281", "text": "function writeStock(x){\r\n if(x<=0){\r\n x=0;\r\n }else{\r\n x=x-1;\r\n } \r\n database.ref('/').update({\r\n food:x\r\n })\r\n}", "title": "" }, { "docid": "b70dd810c9c09b085304d89b38949585", "score": "0.52462435", "text": "updatePosition(paddleX) {\n this.x = paddleX;\n }", "title": "" }, { "docid": "e331fdb61fc44110d4e6b857df7ebd41", "score": "0.5241648", "text": "function setPosition(position) { \n console.log(\"current longitude: \" + position.coords.longitude);\n console.log(\"current latitude : \" + position.coords.latitude);\n oxfordPosition[0] = position.coords.longitude + 0.00005;\n oxfordPosition[1] = position.coords.latitude + 0.0003;\n}", "title": "" }, { "docid": "0d784c99d6f516a2244f3dcde3038afa", "score": "0.52416295", "text": "function createPoint(position) {\n pointPoi = new Object();\n pointPoi.latitude = position.coords.latitude;\n pointPoi.longitude = position.coords.longitude;\n pointPoi.groupName = document.getElementById(\"groupNameTB\").value;\n pointPoi.name = document.getElementById(\"namePuiTXT\").value;\n pointPoi.description = document.getElementById(\"descriptionPuiTXT\").value;\n pointPoi.imageUrl = document.getElementById(\"imageUrl\").value;\n //save to db\n savePOI(pointPoi);\n}", "title": "" }, { "docid": "4a479be329aa8e5e6f057fe14652f7b8", "score": "0.5237488", "text": "function fireBall(){\n ballObjects[weapon.whichBall].dx = 10;\n \n }", "title": "" }, { "docid": "8737d223f71b5999921d2762ca5a1a3c", "score": "0.52373636", "text": "function updateBall() {\n // Update the ball's position based on velocity\n ball.x += ball.vx;\n ball.y += ball.vy;\n}", "title": "" }, { "docid": "8737d223f71b5999921d2762ca5a1a3c", "score": "0.52373636", "text": "function updateBall() {\n // Update the ball's position based on velocity\n ball.x += ball.vx;\n ball.y += ball.vy;\n}", "title": "" }, { "docid": "8737d223f71b5999921d2762ca5a1a3c", "score": "0.52373636", "text": "function updateBall() {\n // Update the ball's position based on velocity\n ball.x += ball.vx;\n ball.y += ball.vy;\n}", "title": "" }, { "docid": "52977296391a3b9bd4d2f170419e4157", "score": "0.5230414", "text": "function update(){}", "title": "" }, { "docid": "a02da9e232bf279f2e551e8f727e131a", "score": "0.52273846", "text": "function writeStock(x){\n \n if (x<=0)\n {\n x=0;\n }\n else{\n x=x-1;\n }\n\n database.ref('/').update({ \n Food:x\n })\n}", "title": "" }, { "docid": "882518ff5ca8f3d3f74cb45bb4c172a5", "score": "0.5227167", "text": "setPos(x, y) {\n this.frogPos.x = this.frogPos.x + x;\n this.frogPos.y = this.frogPos.y + y;\n console.log(\"Frog position: (\" + this.frogPos.x + \", \" + this.frogPos.y + \")\");\n }", "title": "" }, { "docid": "e08865bcd1ea5143fc4ebfe653e7c7ef", "score": "0.5226233", "text": "function ballPos() {\n console.clear();\n console.log(\"Position:\" + \"\\nX Pos: \" + ball.getX() + \"\\nY Pos: \" + ball.getY());\n console.log(paddle1.getLength())\n }", "title": "" }, { "docid": "f9fd60ed464ec35274ebd1a8cba13613", "score": "0.5224706", "text": "function addFood(){\n foodS++;\n database.ref('/').update({\n Food:foodS\n })\n\n }", "title": "" }, { "docid": "20157805b377a0f92756e3617e4b881b", "score": "0.5222949", "text": "dbChangeGameState() {\n try {\n db.collection(\"Lobbies\").doc(this.id).set({\n state: this.state,\n });\n } catch (err) {\n return err;\n }\n }", "title": "" }, { "docid": "b962845ea45d7f374f26e68466af7f06", "score": "0.52144855", "text": "function SaveData() {\n\tthis.version = 1;\n\tthis.p1 = null;\n\tthis.p2 = null;\n\tthis.rupees = 0;\n}", "title": "" }, { "docid": "cdb0e506d37139f8755f20ed39d0f614", "score": "0.52131367", "text": "function writeStock(x){\r\n\r\n if (x <= 0) {\r\n x = 0\r\n } else {\r\n x = x - 1;\r\n }\r\n\r\n database.ref('/').update({\r\n food: x\r\n });\r\n\r\n}", "title": "" }, { "docid": "b6b53a0e829fd112abf55fa7be517ca3", "score": "0.52071565", "text": "_save (pos) {\n this.a_.set(mod.HEAP32.subarray(pos / 4, pos / 4 + this.a_.length))\n }", "title": "" }, { "docid": "2b9356bf7a2209814814905a54039794", "score": "0.52037835", "text": "function writeStock(x){\nif(x<=0){\n x=0\n}\nelse{\n x=x-1\n}\n database.ref(\"/\").update ({\n Food:x\n })\n}", "title": "" }, { "docid": "1a80a4cf39d88aead63bbc31d51a6dd0", "score": "0.5203197", "text": "async loadSpot(spot){\n\n spot.history = [];\n spot.values = [];\n spot.currentValue = 0;\n //spot.currentValueTime = null;\n\n let collection = this.db.collection(\"surf-spots\");\n collection.doc(spot.name).set(spot, {merge: false});\n }", "title": "" }, { "docid": "dde1436703f26a97ee57d4c45cdb7032", "score": "0.52013326", "text": "function addFoods(){\r\n foodS++;\r\n //console.log(foodS);\r\n //update value in db of Food\r\n db.ref('/').update({\r\n Food:foodS\r\n })\r\n}", "title": "" }, { "docid": "d1bf0ee866c492de17315539c8951e40", "score": "0.5195935", "text": "function writePlayerData(playerId, x, y) {\n database.ref('players/' + playerId).set({\n id: playerId,\n x: x,\n y: y\n });\n}", "title": "" }, { "docid": "91e753d522f4c6bda4ec76bb0968f0ce", "score": "0.5191312", "text": "function save() {\n const newSpeedCodes = userSpeedDial8.speedCodes.map(code =>\n code.speedCode === form.speedCode ? { ...form } : code\n )\n update(newSpeedCodes)\n }", "title": "" }, { "docid": "4d5c6713f76c203c9837df3d59b40c9a", "score": "0.5187435", "text": "savePositionToDatabase(tag, location) {\n console.log(\"saveposition\");\n try {\n let loc = location.position;\n loc.name = location.name;\n this.axios().put(`${this.restUrl}/api/v1/residents/bytag/${tag}/lastRecordedPosition`, loc).then(() => {\n console.log(`position saved for tag ${tag}`);\n }).catch(() => {\n console.log(`no user found for tag${tag}`);\n });\n } catch (e) {\n\n console.log(\"error on saving\");\n console.log(e);\n }\n }", "title": "" }, { "docid": "7c2a16fc6dff9ed5e47d186cacaca3a5", "score": "0.51682", "text": "ballPosition() {\n\t\t\t\tvar ball = document.getElementById(this.id)\n\t\t\t\tball.style.left = this.xpos + 'px'\n\t\t\t\tball.style.top = this.ypos + 'px'\n\t\t\t}", "title": "" }, { "docid": "c20e099a346d3dbdbf0914eb88bce511", "score": "0.5166953", "text": "function update(){\n ball.x += ball.velocityX;\n ball.y += ball.velocityY;\n\n //simple AI to control the com paddle\n let computerLevel = 0.1;\n com.y += (ball.y - (com.y + com.height/2)) * computerLevel\n\n\n// the first part of the if is for the bottom part of the table the second part is for the top\n if(ball.y + ball.radius > table.height || ball.y - ball.radius < 0){\n ball.velocityY = -ball.velocityY\n } // this player variable lets us know whos who in the game depending on which side the ball is at\n let player = (ball.x < table.width/2) ? user : com;\n if (collision(ball,player)){\n //where the ball hit the player\n let collidePoint = (ball.y - (player.y + player.height/2));\n // this lets us know it was hit in the middle of the paddle^\n //normalization\n collidePoint = collidePoint/(player.height/2)\n // when it hits the sides of the paddle it will come back at 45 degree \n let angleRad = collidePoint * Math.PI/4\n //X direction of the ball when hit\n let direction = (ball.x < table.width/2) ? 1 : -1;\n\n /*\n Depending on VelocityX and velocityY we know what directin the\n ball will go if x is positive and y is negative the direction is to the left 45 degrees\n if x is 5 and y is 0 it will straight\n and last but not least the if x is postive and y is positive it will got right\n at 45 degrees\n */\n \n //change vel X and Y\n /*\n cos = ball.velocityX/ball.speed\n sin = ball.velocityY/ball.speed\n ball velocityX and ball velocityY is what allows the paddles to get \n the right angles when the ball collides with the paddle\n the velocityX is dependent on direction velocityY is not \n\n \n */\n ball.velocityX = direction * ball.speed * Math.cos(angleRad);\n ball.velocityY = ball.speed * Math.sin(angleRad);\n //everytime the ball hit a paddle,we increase its speed\n ball.speed += 0.5;\n }\n\n//update the score\n\n if(ball.x - ball.radius < 0){\n com.score++;\n resetBall();\n }else if(ball.x + ball.radius >table.width){\n user.score++;\n resetBall();\n }\n\n}", "title": "" }, { "docid": "d5f38558c37a7ae495c80c33fb372f98", "score": "0.5160016", "text": "function ballmove() {\n // Gestion de la désertion\n if (!connectes[login] || !connectes[adversaire]) {\n clearInterval(roundballmove);\n date = new Date();\n console.log('['+date.getFullYear()+'-'+('0'+(date.getMonth()+1)).slice(-2)+'-'+('0'+date.getDate()).slice(-2)+' '+('0'+date.getHours()).slice(-2)+':'+('0'+date.getMinutes()).slice(-2)+':'+('0'+date.getSeconds()).slice(-2)+'] Abandon de la partie entre '+adversaire+' et '+login);\n }\n // Mise à jour de la position de la balle\n balleH += vitesseH;\n balleV += vitesseV;\n // Gestion de la collision avec la raquette gauche\n if (balleH <= 20 && balleV+20 > raquette1 && balleV < raquette1+100) {\n vitesseH = -vitesseH * 1.05;\n vitesseV = -((raquette1+50)-(balleV+10))/15;\n }\n // Gestion de la collision avec la raquette droite\n if (balleH >= 760 && balleV+20 > raquette2 && balleV < raquette2+100) {\n vitesseH = -vitesseH * 1.05;\n vitesseV = -((raquette2+50)-(balleV+10))/15;\n }\n // Gestion de la collision avec les murs\n if (balleV <= 0 || balleV >= 580)\n vitesseV = -vitesseV;\n // Gestion point marqué gauche\n if (balleH <= 0) {\n clearInterval(roundballmove);\n score2++;\n majscores();\n // Si la partie n'est pas terminée, on relance la balle\n if (score2 < 11) {\n initround(2);\n setTimeout(function() {\n roundballmove = setInterval(ballmove, 15);\n }, 500);\n }\n // Sinon on traite la fin de partie\n else {\n try {\n endgame(login, adversaire);\n }\n catch (e) {}\n }\n }\n // Gestion point marqué droite\n if (balleH >= 780) {\n clearInterval(roundballmove);\n score1++;\n majscores();\n // Si la partie n'est pas terminée, on relance la balle\n if (score1 < 11) {\n initround(1);\n setTimeout(function() {\n roundballmove = setInterval(ballmove, 15);\n }, 500);\n }\n // Sinon on traite la fin de partie\n else\n endgame(adversaire, login);\n }\n // Envoie de la nouvelle position de la balle\n try {\n connectesWS[adversaire].ws.send(JSON.stringify({action: 'balle', balleH: balleH, balleV: balleV}));\n connectesWS[login].ws.send(JSON.stringify({action: 'balle', balleH: balleH, balleV: balleV}));\n }\n catch (e) {}\n }", "title": "" }, { "docid": "45dfd2aec080f77eff4e3c89b77be71c", "score": "0.5159294", "text": "function writeStock(x){\r\n if(x<=0){\r\n x=0;\r\n }else{\r\n x=x-1;\r\n } \r\n database.ref('/').update({\r\n Food:x\r\n })\r\n}", "title": "" }, { "docid": "c5b7e4f135688b555d6e01f6036c3540", "score": "0.51589614", "text": "function setup() {\r\n database= firebase.database();\r\n createCanvas(1500,700);\r\n\r\n hotBalloon=database.ref('balloon/position');\r\n hotBalloon.on(\"value\",readPosition,showErr);\r\n \r\n balloon=createSprite(250,450,150,150);\r\n balloon.addAnimation(\"hotAirBalloon\",balloonImage1);\r\n balloon.scale=0.5;\r\n\r\n textSize(20); \r\n}", "title": "" }, { "docid": "cbc218e1bee856ffc5ddf17b50103802", "score": "0.5157776", "text": "function setToDB (arr) {\n\tfor (var i = 0; i < arr.length; i++) {\n\t\t// modifiy data format for the following properties\n\t\tvar address = arr[i]['Location 1'];\n\t\tvar location = address.split('\\n')[2].replace('(', '').replace(')', '').split(', ');\n\t\tvar geoLocation = location.map(function (str) {\n\t\t\treturn Number(str);\n\t\t})\n\t\t// create in db\n\t\tParkLocation.create({\n\t\t\tParkName: arr[i].ParkName,\n\t\t\tParkType: arr[i].ParkType,\n\t\t\tParkServiceArea: arr[i].ParkServiceArea,\n\t\t\temail: arr[i].email,\n\t\t\tNumber: arr[i].Number,\n\t\t\tZipcode: arr[i].Zipcode,\n\t\t\tAcreage: arr[i].Acreage,\n\t\t\tSupDist: arr[i].SupDist,\n\t\t\tParkID: arr[i].parkID,\n\t\t\tGeo: geoLocation\n\t\t})\n\t}\n}", "title": "" }, { "docid": "5cafe4f893a9fe26ff27b87199455383", "score": "0.5156315", "text": "addfood(){\r\n db.ref(\"/\").update({\"food\":food+1})\r\n }", "title": "" }, { "docid": "d320684601f692d2d705a3f68b8cc1a8", "score": "0.51552874", "text": "function shootBall(_event) {\n //if a player is in possession of the ball and the game is frozen it will unfreeze the game, so the user can shoot the ball\n if (Endaufgabe_Football_Simulation.freeze && ballPossessed) {\n Endaufgabe_Football_Simulation.freeze = false;\n for (let player of Endaufgabe_Football_Simulation.players) {\n if (player.inPossession) {\n player.inPossession = false;\n //\n let rect = Endaufgabe_Football_Simulation.canvas.getBoundingClientRect();\n //the user can click somewhere on the field and the position where the ball should roll to gets calculated\n let mousePosition = new Endaufgabe_Football_Simulation.Vector(_event.clientX - rect.left, _event.clientY - rect.top);\n //declare the variable direction that gets the distance between the clicked position and the ball\n let direction = new Endaufgabe_Football_Simulation.Vector(mousePosition.x - Endaufgabe_Football_Simulation.football.position.x, mousePosition.y - Endaufgabe_Football_Simulation.football.position.y);\n //the currentPrecision value will change depending on the distance between clicked position and the ball\n //if the distance is greater than 500 the currentPrecision will increase by 20\n if (direction.length > 500) {\n Endaufgabe_Football_Simulation.currentPrecision += 20;\n console.log(\"worst case scenario\");\n //if the distance is greater than 250 the currentPrecision will increase by 10\n }\n else if (direction.length > 170) {\n Endaufgabe_Football_Simulation.currentPrecision += 10;\n console.log(\"medium case scenario\");\n //if the distance is smaller than 250 the currentPrecision will increase by 5\n }\n else {\n Endaufgabe_Football_Simulation.currentPrecision += 1;\n console.log(\"best case scenario\");\n }\n //the new calculated position will be set as the new football position\n let newTarget = new Endaufgabe_Football_Simulation.Vector(mousePosition.x - Endaufgabe_Football_Simulation.currentPrecision, mousePosition.y - Endaufgabe_Football_Simulation.currentPrecision);\n Endaufgabe_Football_Simulation.football.target = newTarget;\n }\n }\n }\n }", "title": "" }, { "docid": "7f7360f47413b853a7060aff06c332c9", "score": "0.51538306", "text": "setTape(pos, vals){\n this.tape.curr = pos;\n this.tape.values = vals;\n }", "title": "" }, { "docid": "6e6450f9b417926a9874591271f4f36a", "score": "0.51529473", "text": "function writeStock(x) {\n if (x <= 0) {\n x = 0;\n } else {\n x = x - 1;\n }\n\n database.ref('Food').update({ food: x })\n}", "title": "" }, { "docid": "dc277278228f45d129ccc5e7495511de", "score": "0.51440424", "text": "function feedDog(){\n dog.addImage(happyDog);\n\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\n database.ref('/').update({\n Food:foodObj.getFoodStock(),\n FeedTime:hour(),\n gameState:\"Hungry\"\n })\n}", "title": "" }, { "docid": "68a5185870cdbe596fc3abe53d92e7ce", "score": "0.5143572", "text": "move() {// changes x and y of ball in the array\n\t\tthis.x += (this.speedX * globalSpeedMutiplier);\n\t\tthis.y += (this.speedY * globalSpeedMutiplier);\n\t\t\n\t\ttestCollisionBallWithWalls(this);\n\t\ttestCollisionWithPlayer(this, balls.indexOf(this));\n }", "title": "" }, { "docid": "7b8c5d4c5ee881a52f1a4d857fa4afce", "score": "0.5142668", "text": "writeResultToDb(){\n for(var candidate in this.listOfCandidates){\n db.runQuery('INSERT INTO group_result(votes, id) VALUES( ?, ? )', [this.listOfCandidates[candidate].vote, this.listOfCandidates[candidate].id]);\n }\n }", "title": "" }, { "docid": "6b38848b7060f3882f52fb16923d7ab7", "score": "0.5140798", "text": "function feedDog(){\n dog.addImage(happyDog);\n\n\n foodObj.updateFoodStock(foodObj.getFoodStock()-1);\n database.ref('/').update({\n Food : foodObj.getFoodStock(),\n feedTime : hour()\n })\n}", "title": "" }, { "docid": "373b7a84724377209bb8a69539bb34f5", "score": "0.51365215", "text": "function resetBallPosition(){\n ballXPosition = 350;\n ballYPosition = 100;\n ballXVelocity = 1;\n ballYVelocity = 1;\n\n computerPaddleYPosition = 400;\n computerPaddleYVelocity = 3.15;\n}", "title": "" }, { "docid": "99df77895958260fde1997323b199e8f", "score": "0.51358736", "text": "updatePoints(){\n\t\tthis.points += this.prizes[this.multiplier];\n\t\tconsole.log(this.points);\n\t\tCookies.set('points', this.points);\n\t\t$('#points_').text(this.points);\n\n\t}", "title": "" }, { "docid": "a123e004c3fcf1e4323d858bb2d9dbb4", "score": "0.5134589", "text": "function addRock() {\n massData.totalMass += massData.auto;\n runUpdates();\n}", "title": "" }, { "docid": "dbda4ff29bbfd26822e4fa8be02e9424", "score": "0.5125814", "text": "function addFood(){\r\n var currentFood = foodObj.getFoodStock() + 1;\r\n console.log(currentFood);\r\n if(foodObj.getFoodStock()<=14){\r\n database.ref('/').update({\r\n Food: currentFood\r\n });\r\n }\r\n}", "title": "" }, { "docid": "b650ce97f7035d1ad5ccb290b9e09aeb", "score": "0.5125775", "text": "function addFoods(){\n foodS++;\n database.ref('/').update({\n Food:foodS\n \n})\n\n}", "title": "" }, { "docid": "2a891550aadae52ff181c8baed9d2647", "score": "0.51243925", "text": "updateGameState () {\r\n var gameStateRef = database.ref (\"/gameState\");\r\n gameStateRef.set ({\"gameState\" : state}) ;\r\n }", "title": "" }, { "docid": "05655db365c837a0a18b5e8f0f099ae8", "score": "0.5119206", "text": "function writeStock(x)\n {\n database.ref('/').update\n ({\n Food:x\n })\n }", "title": "" } ]
7139a1c2a489905dd838def25f63712f
threat this constructor as private use ChordComponentManager
[ { "docid": "d59dda30b6e4facac237640a3f951f1d", "score": "0.0", "text": "function ChordComponent(chordComponentString, id, isDown){\n\n // just for tests\n this.id = id;\n this.isDown = isDown;\n\n var baseComponentsSemitonesNumber = {\n '1' : 0,\n '2' : 2,\n '3' : 4,\n '4' : 5,\n '5' : 7,\n '6' : 9,\n '7' : 10,\n '8' : 12,\n '9' : 14\n // todo: for future consideration\n // '10' : 16,\n // '11' : 17,\n // '13' : 21\n };\n\n var deltaPlus = 0;\n var deltaMinus = 0;\n var baseComponent = \"\";\n for(var i=0; i<chordComponentString.length; i++){\n if(chordComponentString[i] === '>') deltaMinus--;\n else if(chordComponentString[i] === '<') deltaPlus++;\n else baseComponent = baseComponent + chordComponentString[i];\n }\n if(deltaMinus !== 0 && deltaPlus !== 0) {\n error(\"Invalid chord component string - cannot contains both < and >\");\n return;\n }\n\n this.chordComponentString = chordComponentString;\n this.baseComponent = baseComponent;\n this.semitonesNumber = this.isDown ? baseComponentsSemitonesNumber[baseComponent] + deltaMinus + deltaPlus - 1 : baseComponentsSemitonesNumber[baseComponent] + deltaMinus + deltaPlus;\n\n this.equals = function(other){\n return this.id === other.id;\n }\n\n // this.toString = function () {\n // todo without this test are not passing - dont know why\n // return this.chordComponentString;\n // }\n\n this.toXmlString = function() {\n return (this.chordComponentString.replace(\"<\", \"&lt;\")).replace(\">\", \"&gt;\");\n }\n\n this.toString = function() {\n return \"CC string: \" + this.chordComponentString +\n \" CC semitones_number: \" + this.semitonesNumber;\n }\n}", "title": "" } ]
[ { "docid": "8ea2578a1a79cbab165aa130e3e22945", "score": "0.6867271", "text": "constructor(components) {\r\n this.components = components;\r\n }", "title": "" }, { "docid": "2173e7bba57f8ea5b5455ca5fcf44160", "score": "0.65652925", "text": "onComponentConstructed() {}", "title": "" }, { "docid": "2173e7bba57f8ea5b5455ca5fcf44160", "score": "0.65652925", "text": "onComponentConstructed() {}", "title": "" }, { "docid": "b42351186d39e9dcb30e6c46cddcfeee", "score": "0.6462296", "text": "constructor () {\r\n\t\t\r\n\t}", "title": "" }, { "docid": "f1bdb62cba9f25eb25d179eedfd529de", "score": "0.64340466", "text": "defineComponents() {\r\n this.components.forEach(Component => {\r\n this[Component.name] = new Component();\r\n });\r\n }", "title": "" }, { "docid": "cab92ce7f7467d82fb9e8208f1d74ea9", "score": "0.6425786", "text": "constructor() {\n super(); // loading the parent component methods and properties\n return this.buildComponenent(); // this function should always be called, it returns the object to render\n }", "title": "" }, { "docid": "50975fc0f5872e6b931b1a331f7d29f4", "score": "0.63953435", "text": "constructor() {\r\n // ohne Inhalt\r\n }", "title": "" }, { "docid": "759dcf2fa21737211060806e2c4839ae", "score": "0.6383002", "text": "GetComponents() {}", "title": "" }, { "docid": "759dcf2fa21737211060806e2c4839ae", "score": "0.6383002", "text": "GetComponents() {}", "title": "" }, { "docid": "759dcf2fa21737211060806e2c4839ae", "score": "0.6383002", "text": "GetComponents() {}", "title": "" }, { "docid": "759dcf2fa21737211060806e2c4839ae", "score": "0.6383002", "text": "GetComponents() {}", "title": "" }, { "docid": "074ce4877c6f29dadd62b578d8212882", "score": "0.6315963", "text": "function Component() { }", "title": "" }, { "docid": "6c94262737ee5596ad072f58b28fef19", "score": "0.627302", "text": "function PratoDoDiaComponent() {\n }", "title": "" }, { "docid": "9088a0ce43272138d3418cd03c9f8d7a", "score": "0.6267506", "text": "constructor() {\r\n super()\r\n this.init()\r\n }", "title": "" }, { "docid": "dcf6773fb3fafa96c2f813e26ec27ed5", "score": "0.62381333", "text": "consructor() {\n }", "title": "" }, { "docid": "d2c6ce3597960c867f7fec31ce902789", "score": "0.62267953", "text": "function _construct()\n\t\t{;\n\t\t}", "title": "" }, { "docid": "b27c648948292b25ea1e50e2566dbd8a", "score": "0.6226591", "text": "constructor() {\n this.updateHash();\n componentManager.register(this);\n }", "title": "" }, { "docid": "0caaa6c7dc3db0aae10831406d3874af", "score": "0.6206657", "text": "function ComponentContainer()\r\n{\r\n\t//this function never will be called (because only the methods are attached to other classes)\r\n\t//unless you instantiate this class directly, something that would be weird\r\n}", "title": "" }, { "docid": "b762ba73dbe0c6e8acc47c8b94fa5559", "score": "0.6198549", "text": "function _ctor() {\n\t}", "title": "" }, { "docid": "280d9d751508ad833de012437dfa8620", "score": "0.6184291", "text": "constructor(props){\n //Call the constrictor of Super class i.e The Component\n super(props);\n }", "title": "" }, { "docid": "d137af80c61e1e90ad9432eae8f932d5", "score": "0.61751586", "text": "constructor() {\n }", "title": "" }, { "docid": "7d1986459c31ed50c00ce05318866ca3", "score": "0.61705154", "text": "constructor() {\n super();\n this._init();\n }", "title": "" }, { "docid": "f4c5c43aee87940e8dec002e1d315fc5", "score": "0.6166861", "text": "_construct() {\r\n\tLog.info('Dtag: Enter Diagnostic Component ')\r\n }", "title": "" }, { "docid": "c77ca634ea632974f4211b52f0190b6e", "score": "0.6144923", "text": "constructor(){\r\n\t}", "title": "" }, { "docid": "428191450dea6f0c81c9e49e95642503", "score": "0.61420274", "text": "function JAFTING_Component() { this.initialize(...arguments); }", "title": "" }, { "docid": "cff30cbf5d207807c41c3f8864dc0080", "score": "0.6141418", "text": "constructor(props)\n {\n super(props)\n\n }", "title": "" }, { "docid": "0d02a4e40f88847b20a4c619af1ba180", "score": "0.613671", "text": "function WebCom_ComponentLoader() {\n\n var components = [];\n \n /*public void*/function initComponent(name, version, className, data, onRenderComplete) {\n if(name) {\n //Add component to queue for init\n components.push({\n 'name': name, \n 'className': className,\n 'version': version, \n 'data': data,\n 'onRenderComplete': onRenderComplete\n });\n //Load the component JS file\n WebCom.ResourceLoader.loadLib(name, version, true);\n }\n };\n \n /*public void*/function flushQueue() {\n for(var i=0;i<components.length;i++) {\n startComponent(components[i].className, components[i].data, components[i].onRenderComplete);\n }\n components = [];\n }\n \n /*private void*/function startComponent(className, data, onRenderComplete) {\n var componentClass = eval(className);\n \n if (componentClass && typeof(componentClass.initInstances) == 'function') {\n componentClass.initInstances(data , {listeners: {'renderComplete' : {handler: function() { if(typeof(onRenderComplete) == 'function') { onRenderComplete();}} }}});\n }\n }\n \n this.initComponent = initComponent;\n this.flushQueue = flushQueue;\n \n return this;\n }", "title": "" }, { "docid": "79e74140a8f54e4405a9ee4b53efb57d", "score": "0.6134308", "text": "constructor(){\n this.init();\n }", "title": "" }, { "docid": "c16cda55c89b87c4ec7720269486eb07", "score": "0.61317235", "text": "constructor() {\n\n\t}", "title": "" }, { "docid": "891943215ef4f9c5469f5ceca0b6c554", "score": "0.612615", "text": "constructor(arrayOfRelevantEntities) {\n super(arrayOfRelevantEntities);\n this.requiredComponents = ['cPos', 'cPlayer'];\n //also uses cCamera\n }", "title": "" }, { "docid": "b69903587a17ad3a1ea275a749b6238b", "score": "0.6117233", "text": "constructor(arrayOfRelevantEntities) {\n super(arrayOfRelevantEntities);\n // this.requiredComponents = ['cPos', 'cDraggable',];\n }", "title": "" }, { "docid": "c375526b2b536b96fc911b772581f59b", "score": "0.61159796", "text": "constructor() {\n this.init();\n }", "title": "" }, { "docid": "c0ef66eedb41e33cffcbb12421155b39", "score": "0.6113935", "text": "constructor() {\n\t\tsuper(Catberry);\n\t}", "title": "" }, { "docid": "08fec6c3e07ccbf65bd9524e193b8cb6", "score": "0.6111128", "text": "constructor(props) {\n this.component = props;\n }", "title": "" }, { "docid": "08fec6c3e07ccbf65bd9524e193b8cb6", "score": "0.6111128", "text": "constructor(props) {\n this.component = props;\n }", "title": "" }, { "docid": "4cb68838902611ae810456b94c719559", "score": "0.6108515", "text": "constructor(){\n this.uiComponent = new UIComponent();\n}", "title": "" }, { "docid": "e4213672cc6984b6cd824e0085e3c431", "score": "0.6086838", "text": "constructor(entityUID, isAlive) {\n super();\n this.__components = []; // index is ComponentTID\n this.__entity_uid = entityUID;\n this.__isAlive = isAlive;\n }", "title": "" }, { "docid": "ed4ba2b5f2a0a74b89880978879baf2d", "score": "0.60772616", "text": "constructor()\n {\n this.init();\n }", "title": "" }, { "docid": "75bcff552d4e3e67b87ab993065d75bb", "score": "0.6074961", "text": "createComponent(obj){\n\t\t\tvar comp = new Component(obj.selector, obj.template, obj.ctrlFunc);\n\t\t\tthis[componentSymbol].push({\n\t\t\t\tname: obj.name,\n\t\t\t\tcomponent: comp\n\t\t\t});\n\t\t\treturn comp;\n\t\t}", "title": "" }, { "docid": "f66ee57414255f4244ad5d088c1767f9", "score": "0.6066229", "text": "constructor() {\n\t\t// ...\n\t}", "title": "" }, { "docid": "9f099c90b31bcc46569bee1245b3d0d8", "score": "0.60622466", "text": "constructor(props) { super(props); autoBind(this); }", "title": "" }, { "docid": "ec971bea07684e91fe1a9c441b4c7dba", "score": "0.60539", "text": "constructor() \n { \n \n\n }", "title": "" }, { "docid": "73b4cce0fafcbd61018267fbea540133", "score": "0.60474443", "text": "constructor() {\r\n\r\n\r\n }", "title": "" }, { "docid": "dc76be3f7d73b3fb41bfb9efa166c8c6", "score": "0.6043632", "text": "function CB_ComponentControl(params) {\r\n\tthis.TYPE = \"COMPONENT_CONTROL\";\r\n\tthis.container = null;\r\n\tthis.setting(params);\r\n\r\n\tthis.setContainer = function(container) {\r\n\t\tif ((typeof container==='undefined')||(container===null)) return;\r\n\t\tthis.container = container;\r\n\t};\r\n}", "title": "" }, { "docid": "d3283e69f0d65bbf02ce540236026e42", "score": "0.6040264", "text": "constructor(props) {\n super(props);\n\n // Passed on prop for all components that may be loaded on this page.\n this.passUpdateFunctions = {\n refreshList: this.resetConvos.bind(this),\n changeView: this.changeView.bind(this)\n };\n\n this.state = this.getInitState();\n }", "title": "" }, { "docid": "4d43e7455093f3346de7c7d78d04a2f1", "score": "0.6039044", "text": "setupComponents() {\n\t\tthis.contactBar = new ContactBar();\n\t\tthis.contactBar.setup();\n\n\t\tthis.modal = new Modal();\n\t\tthis.modal.setup();\n\n\t\tthis.accordion = new Accordion();\n\t\tthis.accordion.setup();\n\n\t\tthis.mediaGallery = new MediaGallery();\n\t\tthis.mediaGallery.setup();\n\t}", "title": "" }, { "docid": "b9c36b77abf7c634e8f36f7c0044bcf0", "score": "0.60225457", "text": "constructor(){\r\n\r\n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "306a6831588985655a0f9fa260ba672f", "score": "0.6014208", "text": "constructor() {\n \n }", "title": "" }, { "docid": "71d7bab8c6aaef142f3353644252d9ea", "score": "0.6010273", "text": "configure () {\n // this can be extended in children classes to avoid using the constructor\n }", "title": "" }, { "docid": "7502380e7de43be1478a9a972753e90e", "score": "0.6005245", "text": "constructor() {\n super();\n \n }", "title": "" }, { "docid": "ff0a284840d266233705461a4ea9ba1a", "score": "0.6003504", "text": "constructor(){\n this.init();\n\n\n }", "title": "" }, { "docid": "7482f433caa13b074513ed27b59bb347", "score": "0.60029817", "text": "constructor() {\n\n\t\tsuper();\n\n\t}", "title": "" }, { "docid": "e8d0b1ddcf4b90bbb7f275465872f758", "score": "0.6000468", "text": "constructor()\n {\n this.type = ComponentType.Default;\n this.entity = undefined;\n }", "title": "" }, { "docid": "16b6d0b4b8c3dcec93169de8e126507f", "score": "0.5996649", "text": "constructor(arrayOfRelevantEntities) {\n super(arrayOfRelevantEntities);\n this.requiredComponents = ['cPos', 'cMesh', 'cPhysics'];\n //also uses cCamera\n }", "title": "" }, { "docid": "76a5f244e652d428875f6341e8f25215", "score": "0.59732246", "text": "constructor() {\n super();\n }", "title": "" }, { "docid": "c8b5ab86038bdb6473d08707aa85ab20", "score": "0.59605664", "text": "constructor() {\n\t}", "title": "" }, { "docid": "c8b5ab86038bdb6473d08707aa85ab20", "score": "0.59605664", "text": "constructor() {\n\t}", "title": "" }, { "docid": "c954f2a71bb4018f41ba0b0ee2c5535a", "score": "0.59599006", "text": "constructor() {\n this.init();\n\n }", "title": "" }, { "docid": "132c72f7957736b12734663b427e85bc", "score": "0.59535384", "text": "constructor(props) {\n // TODO: add pitch\n super(props);\n this.init();\n }", "title": "" }, { "docid": "afcd2d9c184af913f1dbe719d1e5197f", "score": "0.59520876", "text": "constructor() {\r\n }", "title": "" }, { "docid": "071086c2e63e3c33c601545304859522", "score": "0.59478796", "text": "constructor(elemid, loader) {\n Object.assign(ChannelView.prototype, ChannelMixins);\n this.vue = new Vue({\n el: elemid,\n data: this.setupChannels(loader)\n });\n }", "title": "" }, { "docid": "a94867447da2e5c6c62a17048aeb8b5c", "score": "0.59446096", "text": "constructor () {\n this.compOptionsList = new OptionsList();\n this.compArticle = new Article();\n this.compTechnologiesList = new TechnologiesList();\n }", "title": "" }, { "docid": "319c5a5833436fc2104ffb8b7fa751af", "score": "0.5944333", "text": "function init(){\n buildComponent();\n attachHandlers();\n addComponents();\n }", "title": "" }, { "docid": "efeeacb1cf5476573776aabf50a104c0", "score": "0.59424174", "text": "constructor() {\n super(0, 'W');\n this.type = ComponentType.TYPE_CONNECTOR;\n this.dependant = { V: undefined, I: undefined };\n this.pins = [new Pin(this, 0), new Pin(this, 1)];\n }", "title": "" }, { "docid": "ad91cf774842c7f01d01e1212f9f184d", "score": "0.5941269", "text": "constructor () { super() }", "title": "" }, { "docid": "f2c7eac9e03724491ca2d3cbd07c3a64", "score": "0.593735", "text": "constructor() {\n super()\n console.info('construct')\n // Maximum number of clients allowed to connect into the room.\n // When room reaches this limit, it is locked automatically.\n // Unless the room was explicitly locked by you via lock() method,\n // the room will be unlocked as soon as a client disconnects from it.\n this.maxClients = 2\n // Frequency to send the room state to connected clients (in milliseconds)\n this.setPatchRate(patchRate)\n }", "title": "" }, { "docid": "febbd242c44eef4bd9e2b39be2e81481", "score": "0.5932635", "text": "constructor(cmdParams, botClient, msg) {\n super(cmdParams, botClient, msg);\n //class based variable initialization\n this.channelId = '';\n this.friendlyChannelName = '';\n this.joinLink = 'https://www.youtube.com/watch?v=KLIiGMMMf-E';\n //this.joinLink = 'https://youtu.be/MvlGLx4M1cw';\n this.leaveLink = 'https://youtu.be/7NFwhd0zsHU';\n this.audioPlayer = new AudioPlayer(botClient);\n this.dateService = new DateService();\n }", "title": "" }, { "docid": "b24a7239269fcd53f66c091b7c2c0115", "score": "0.59293884", "text": "constructor() {\n \n }", "title": "" }, { "docid": "89d5f0a88623480cdd2a5965ece3727d", "score": "0.59285724", "text": "constructor(){\n \n\n }", "title": "" }, { "docid": "1316747a1e93a54aacdca65d19b03f55", "score": "0.5927617", "text": "constructor(props, context){\n super(props, context);\n\n }", "title": "" }, { "docid": "1d1cd2f4d3dd53f90bac1ca0fe1ea6b6", "score": "0.5921495", "text": "constructor() {\n this._initialize();\n }", "title": "" }, { "docid": "571fea20efadbf48175fc5efee96a62e", "score": "0.5920292", "text": "constructor() {\n this.init();\n }", "title": "" }, { "docid": "571fea20efadbf48175fc5efee96a62e", "score": "0.5920292", "text": "constructor() {\n this.init();\n }", "title": "" }, { "docid": "14e171dec3b81d98fffed636dab7fc9a", "score": "0.59196043", "text": "init() {\n }", "title": "" }, { "docid": "c2e79ed420771ace5eb1a7a2b0411751", "score": "0.5919498", "text": "constructor(){\r\n }", "title": "" }, { "docid": "4232d26f154dc5b26772e436dbdcdf02", "score": "0.5915446", "text": "constructor() {\n super();\n }", "title": "" }, { "docid": "4232d26f154dc5b26772e436dbdcdf02", "score": "0.5915446", "text": "constructor() {\n super();\n }", "title": "" }, { "docid": "4232d26f154dc5b26772e436dbdcdf02", "score": "0.5915446", "text": "constructor() {\n super();\n }", "title": "" }, { "docid": "61f9ef3d8f0717e59720597de9f5ba4f", "score": "0.5910734", "text": "constructor() {\n super()\n self = this\n self.init()\n }", "title": "" }, { "docid": "8b29cd8ec1242ea3f08f2c42308632ef", "score": "0.59074163", "text": "constructor() {\n\n\n }", "title": "" }, { "docid": "ace10e8541b6a668f1b92a8a771437c4", "score": "0.59046227", "text": "constructor() {\r\n super();\r\n }", "title": "" }, { "docid": "ace10e8541b6a668f1b92a8a771437c4", "score": "0.59046227", "text": "constructor() {\r\n super();\r\n }", "title": "" } ]
fd6ad8b7159dc0a05621d657c25a2695
Create a function named Car with one property named `manufactured_date`whose value will be Date.now()
[ { "docid": "d0107d638cd5b3c3d2fb547de6590dfa", "score": "0.71934754", "text": "function Car () {\n // Create the manufactured date property (see above)\n this.madeDate = Date.now();\n}", "title": "" } ]
[ { "docid": "683ca05106c60daca56a1e023f1f0dba", "score": "0.59952664", "text": "function dateGenerator() {\n\n}", "title": "" }, { "docid": "0bda0f4ad7c357b91f942c31e6a3dcf4", "score": "0.58727384", "text": "function date(){\r\n new Date();\r\n}", "title": "" }, { "docid": "d03ec052ec5602c8f2f4c48fdeeb1055", "score": "0.5719902", "text": "function returnNewDate() {\n returnDate(1);\n}", "title": "" }, { "docid": "42c38bbd904ff058cd0ec6a26abd64ba", "score": "0.57193875", "text": "function carMaker(/* code here */) {\n /* code here */\n}", "title": "" }, { "docid": "d14da37ceec9f811041cc9eb7d3d3770", "score": "0.5662416", "text": "function CarMaker() {}", "title": "" }, { "docid": "02ae2beabd754e29787c09bb7d169757", "score": "0.5651201", "text": "function carMaker(/* code here */) {\n /* code here */\n\n}", "title": "" }, { "docid": "ff3e48f709ce16e9e618cf49e43b462d", "score": "0.56412905", "text": "function dateStamp(func) {\n\tlet date = ''\n let obj = {}\n function calc(x){\n date = new Date().getTime()\n obj = {date: date, output: func(x)}\n console.log(obj)\n }\n return calc\n}", "title": "" }, { "docid": "145e74a2af9eeeefe3d7b5dc6bc960ac", "score": "0.56281894", "text": "function carFactory ({ brand = 'Volkswagen', year = 1999 }) {\n console.log(brand)\n console.log(year)\n}", "title": "" }, { "docid": "e8593b82e2782c89044ca4749557a308", "score": "0.55899847", "text": "function CarMaker(make, model, year) {\n this.make = make;\n this.model = model;\n this.year = year;\n this.register = function() {\n console.log(this.make, \"has been registered\");\n };\n}", "title": "" }, { "docid": "75f115330886232ad26abb499b487de5", "score": "0.5586211", "text": "function Car(make,color,kilometersPassed,yearOfProduction,isItRegistered,babaDaliJaVozela){\n this.brend = make;\n this.boja = color || 'red';\n this.kilometri = kilometersPassed;\n this.godinaNaProizvodstvo = yearOfProduction;\n this.daliERegistrirana = isItRegistered;\n this.didGrandmaDroveIt = babaDaliJaVozela;\n this.isNew = function(){\n if(this.godinaNaProizvodstvo > 2010){\n return true;\n }\n return false;\n }\n carConstuctorcalled++;\n}", "title": "" }, { "docid": "097d6b2667fbf83c63a6015f664006d4", "score": "0.5557085", "text": "function carFactory ({ brand = 'Volkswagen', year = 1999 }) {\n console.log(brand);\n console.log(year);\n}", "title": "" }, { "docid": "5fcf985ed112b87c94546978d437c3d1", "score": "0.55335146", "text": "static creationDate() {\n let date = new Date();\n let month = date.getMonth();\n if (month.toString().length === 1) {\n month = \"0\" + (month + 1).toString();\n }\n return `${date.getFullYear()}-${month}-${date.getDate()}`;\n }", "title": "" }, { "docid": "043655a65de2b9788d0dc13b998d11ce", "score": "0.5508676", "text": "function today() { return { d: 6, m: 2, y: 2013 }; }", "title": "" }, { "docid": "cf0c805f7215f247e9077288d6b3c052", "score": "0.54912084", "text": "function dateConstructor(inputDate, inputMonth, inputYear) {\n // console.log(inputDate + \" \" + inputMonth + \" \" + inputYear);\n\n return `dtdate=${inputMonth}%2F${inputDate}%2F${inputYear}`\n}", "title": "" }, { "docid": "a4682aadfdc8f5fcf4d80467c4e6dbcb", "score": "0.54591197", "text": "function Car(model, type, brand){\n console.log('log...creating Car fn')\n // Every time we enter this function we create a single object of the type Car\n // Once we set the properties we return the instance\n \n // set the properties of this Object using the \"this\" keyword\n this.model = model;\n this.type = type;\n this.brand = brand;\n this.year = 2020;\n}", "title": "" }, { "docid": "976b0be003d6fea83cf72d77e096aa99", "score": "0.5448937", "text": "function date() {\n console.log(new Date())\n}", "title": "" }, { "docid": "cde04c388f30ab8db675d5ff35a20480", "score": "0.54365414", "text": "function get_today_date() {\n //ripristino i campi data alla data odierna\n return get_date(new Date());\n}", "title": "" }, { "docid": "ece1b5d30f6dde98d92e4ee7060ec3ac", "score": "0.542673", "text": "function Car(brand, type, isElectric) {\n this.brand = brand;\n this.type = type;\n this.isElectric = isElectric;\n this.carHorn = function() { console.log(\"HONK!\")}\n}", "title": "" }, { "docid": "e5c186d84d222fb64796dc2dbebccbd1", "score": "0.54193646", "text": "function createEthDateFunction(current_eth_block) {\n return (eth_block) => {\n let SECONDS_PER_ETH_BLOCK = 15;\n\n var options = { year: undefined, month: 'short', day: 'numeric' };\n let date = new Date(Date.now() - ((current_eth_block - eth_block)*SECONDS_PER_ETH_BLOCK*1000));\n return date.toLocaleDateString(undefined, options);\n }\n}", "title": "" }, { "docid": "7b88dcd4c5539b8569768cdf0303e34d", "score": "0.5415477", "text": "function showDate () {\n return new Date();\n}", "title": "" }, { "docid": "7fe5318fc0a7997e589a9178068dbdea", "score": "0.5415103", "text": "newDate() {\r\n let date = new Date();\r\n return {\r\n year: date.getFullYear(),\r\n day: date.getDate(),\r\n month: date.getMonth()\r\n };\r\n }", "title": "" }, { "docid": "1f31ce102ffab72866610de2f4849ca6", "score": "0.5399882", "text": "function Car(manufacturer, model, age) {\n this.manufacturer = manufacturer;\n this.model = model;\n this.age = age;\n this.determineAge = function () {\n return 2019 - this.age;\n }\n}", "title": "" }, { "docid": "4f1d48fd77faf00ca3573debf9e74655", "score": "0.53953874", "text": "function today() {\n return { d: 6, m: 2, y: 2013 };\n}", "title": "" }, { "docid": "4135f0679d952edf9674e1b5bbd05a64", "score": "0.539189", "text": "function Car(color, year, brand) {\n\n\tthis.color = color;\n\tthis.year = year;\n\tthis.brand = brand;\n\n\tthis.horn = function() { console.log(\"BEEEEEEEP! BEEP!\"); };\n\n}", "title": "" }, { "docid": "ba282aaaf8f07668965dd4fddf481b7b", "score": "0.53788215", "text": "onGetCurrentDate(){\n let newDate = new Date();\n let day = newDate.getDate();\n let month = newDate.getMonth() + 1;\n let year = newDate.getFullYear();\n let date = day.toString() + \"-\" + month.toString() + \"-\" + year.toString() ;\n return date;\n }", "title": "" }, { "docid": "92eff787ce8082821f646411c9abda8d", "score": "0.53758895", "text": "function Car() {\n this.cost = function() {\n return 20000;\n };\n this.make = function() {\n return 'Kia';\n };\n}", "title": "" }, { "docid": "b12bc708854ecdf8e34b2c4c2483d2d9", "score": "0.53733414", "text": "constructor(registration, model) {\nthis.registration = registration; //this keyword that define an object they belong to\nthis.model = model;\nthis.carInfo = function () { // method which is function used as a property of object\nreturn \" Our car has\" + \" \" + this.registration + \"\" + \"number \" + \" and\" + \" \" + this.model\n}\nCar.prototype.refillPetrol = 40; // using prototype to add an other object property\n}", "title": "" }, { "docid": "c63f9896ea349dd80164171681c9a8b3", "score": "0.537018", "text": "function whatDateIs() {\n let today = new Date();\n console.log(today); \n}", "title": "" }, { "docid": "b1794583717689be7d665b61359acf6d", "score": "0.53588516", "text": "function Car(make, model, isNew) {\n console.log(\"Our new car:\", this);\n \n this.make = make;\n this.model = model;\n this.isNew = isNew;\n \n this.honk = function() { console.log(\"Honk!\"); };\n \n console.log(\"CAR ASSEMBLY COMPLETE!\");\n}", "title": "" }, { "docid": "be29f09ba9c5196694b65c3ca16e0bb9", "score": "0.53421795", "text": "function carFactory ({ brand = 'Volkswagen', year = 1999 }={}) {\n console.log(brand)\n console.log(year)\n}", "title": "" }, { "docid": "e3421e936e0eea79494ec12ac80e9cc2", "score": "0.53356355", "text": "function createCar(color, model , speed) {\n var myCar = {\n color: color,\n make: model,\n speed: speed\n };\n console.log(myCar);\n // (\"I bought a new \" + color + \" \" + model + \" that has a top speed of \" + speed);\n}", "title": "" }, { "docid": "a6a958e68fce2bc2da06a363f7a6eb1d", "score": "0.53152835", "text": "function Car(brand, year, fast) {\n console.log(\"Our new car:\", this);\n this.brand = brand;\n this.year = year;\n this.fast = fast;\n this.vroom = function() { console.log(\"MORE POWER!\"); };\n console.log(\"CAR INITIALIZATION COMPLETE\");\n}", "title": "" }, { "docid": "55b42d2d66f2414ac6bf7ab7df912b92", "score": "0.53101087", "text": "getCreationDate(){\n\t\treturn this.creationDate.toDateString();\n\t}", "title": "" }, { "docid": "3d9ae5a78e670aa48c9d474cee6e00f6", "score": "0.5295711", "text": "function Car(color, year, good_condition) {\r\n // console.log(\"Our new car:\", this);\r\n this.color = color;\r\n this.year = year;\r\n this.good_condition = good_condition;\r\n console.log(\"Car INITIALIZATION COMPLETE\")\r\n this.drives_fast = function() {console.log (\"This \" + this.color + \" color car drives fast\"); }; \r\n console.log( \"Our \" + this.color + this.year);\r\n}", "title": "" }, { "docid": "55d385557c09661f3ab82139619511ad", "score": "0.5280604", "text": "function ordersPlacedToday(){\n const today = new Date();\n return today;\n}", "title": "" }, { "docid": "7939d6be75f342f65770dcf9c52fcbe2", "score": "0.52755535", "text": "newDate() {\r\n let date = new Date();\r\n return {\r\n year: date.getFullYear(),\r\n day: date.getDate(),\r\n month: date.getMonth(),\r\n hour: date.getHours(),\r\n minutes: date.getMinutes()\r\n };\r\n }", "title": "" }, { "docid": "1b3fc7ce41d2b24cf07cc25aa76551e7", "score": "0.52752715", "text": "function Car() {\n this.make = \"Honda\"\n this.model = \"Accord\"\n this.speed = 0.0\n \n function updateCarFirmware() {\n \n }\n\n}", "title": "" }, { "docid": "66adb917b2ad1933bc85207b94d0c84a", "score": "0.5274245", "text": "function cake(name, flavor, typeOfmix, fillings, toppings, size, bakeTime){\r\n//Initializing the property of the function with values.\r\n this.name = name;\r\n this.flavor = flavor;\r\n this.typeOfmix = typeOfmix;\r\n this.fillings = fillings;\r\n this.toppings = toppings;\r\n this.size = size;\r\n this.bakeTime = bakeTime;\r\n this.availableAt = function(){\r\n console.log(\"Sheena T multi-store\")\r\n }\r\n}", "title": "" }, { "docid": "d6631cc88b4e9a943c44839cd2365bef", "score": "0.5250475", "text": "function today() {\n return {\n month: 6,\n day: 2,\n year: 2015\n }\n}", "title": "" }, { "docid": "d7ed726dfc11c6f28479d7c4c1fc8ff4", "score": "0.52219254", "text": "function newd (){ return time = new Date()}", "title": "" }, { "docid": "b3a882c0916dba0637a20b88d67dca13", "score": "0.5221399", "text": "getDate() {\n const dateObj = new Date()\n const month = dateObj.getUTCMonth() + 1\n const day = dateObj.getUTCDate()\n const year = dateObj.getUTCFullYear()\n return (\n day + \"-\" + month + \"-\" + year\n ) //return\n }", "title": "" }, { "docid": "588345b4abbe506daea1fd8cabab9843", "score": "0.52184445", "text": "function setDate(num) {\n let today = new Date();\n return `${(today.getMonth()) + 1} / ${(today.getDate()) + num}`;\n //return date;\n}", "title": "" }, { "docid": "1f4240da4f598260df158e5886f29ba4", "score": "0.52014303", "text": "function generateDate() {\n\t\t\tvar today = new Date();\n\t\t\tvar dd = today.getDate();\n\t\t\tvar mm = today.getMonth() + 1;\n\t\t\tvar yyyy = today.getFullYear();\n\t\t\t\n\t\t\tif(dd < 10) {\n\t\t\t\tdd = '0' + dd;\n\t\t\t}\n\t\t\t\n\t\t\tif(mm < 10) {\n\t\t\t\tdd = '0' + mm;\n\t\t\t}\n\t\t\t\n\t\t\tvar date = mm + \"/\" + dd + \"/\" + yyyy;\n\t\t\treturn date;\n\t\t}", "title": "" }, { "docid": "aaca8b2dd48fa0fe01d8abb9c0585834", "score": "0.5182392", "text": "function buildCar(name, color, year = 2018){\n console.log(name, year, color);\n}", "title": "" }, { "docid": "4a588d9649112a820b8d05da3173493c", "score": "0.51823354", "text": "function Car(make, model, year) {\n this.make = make;\n this.model = model;\n this.year = year;\n this.display = function () {\n console.log(`This is a ${year} ${make} ${model}.`)\n }\n}", "title": "" }, { "docid": "486995b0029b8cca790a5b44210169d2", "score": "0.51719147", "text": "createdDate(created_at) {\n this.createdDate = Intl.DateTimeFormat().format(new Date(created_at));\n }", "title": "" }, { "docid": "a6ddcb6b4fd04eb9338e87b200983f68", "score": "0.5152576", "text": "function CurrentDate()\n{\n\tconsole.log(new Date());\n}", "title": "" }, { "docid": "0c9b7e6ffd9b12003f9a578e440cac7a", "score": "0.5151942", "text": "forCreate() { return withCreateTime(this); }", "title": "" }, { "docid": "5a6b5ef70e2c800ca55f4f64942e3e75", "score": "0.51517063", "text": "create(car) { \n let response = {\n status: 200,\n data: {\n id: car.id,\n created_on: car.created_on,\n manufacturer: car.manufacturer,\n bodyType: car.body_type,\n email: car.email,\n price: car.price,\n owner: car.owner,\n model: car.model,\n status: car.status,\n state: car.state\n }\n }\n return response;\n }", "title": "" }, { "docid": "b827e1cb5848d0c727081e0b3d7dabce", "score": "0.51480496", "text": "function Car(company, model, color, year) {\n this.company = company;\n this.model = model;\n this.color = color;\n this.year = year;\n this.sayMotto = function(motto) {\n console.log(motto);\n }\n}", "title": "" }, { "docid": "ddfa07d73b4f7f556874c2980b3b47cc", "score": "0.5146949", "text": "function rightNow(){\n return new Date();\n}", "title": "" }, { "docid": "ca6d40c53495623594fa1a0aca7b60be", "score": "0.5144944", "text": "function _getDateNow(){\n return Date.now();\n}", "title": "" }, { "docid": "281501cd4d0a8f08596389b9584be0c8", "score": "0.51390076", "text": "function Car(name,brand,year){\n this.name = name;\n this.brand = brand;\n this.year = year;\n this.move = 0;\n this.moveCar = function(){\n return this.move + 10;\n }\n}", "title": "" }, { "docid": "90f5f514aebb6c7f4bd3c2b8a1580224", "score": "0.5138599", "text": "getDate() {\n const dateObj = new Date();\n // get date\n const month = dateObj.getMonth() + 1;\n const day = dateObj.getDate();\n const year = dateObj.getFullYear();\n // format date\n const date = year + '_' + month + '_' + day;\n // return date\n return date;\n }", "title": "" }, { "docid": "5b5797da18d6ed105bbb4881b9dcb4da", "score": "0.5134002", "text": "function _date(obj) {\n return exports.PREFIX.date + ':' + obj.toISOString();\n}", "title": "" }, { "docid": "6361acbd828b2c6b3d2f9e721dd33c20", "score": "0.5133867", "text": "function date() {\n return define('date', (value) => {\n return ((value instanceof Date && !isNaN(value.getTime())) ||\n `Expected a valid \\`Date\\` object, but received: ${print(value)}`);\n });\n }", "title": "" }, { "docid": "0382b4dc25f806323bca48a9f3f6f470", "score": "0.5129523", "text": "function carFactory ({ brand = 'Volkswagen', year = 1999 } = {}) {\n console.log(brand);\n console.log(year);\n}", "title": "" }, { "docid": "b07b048364e04b70c802e511a4f6c9af", "score": "0.51238555", "text": "function Car(model, color) {\n //create object in here with model and color\n //return created object\n this.model = model;\n this.color = color;\n this.fuel = 100;\n\n this.drive = function() {\n this.fuel--;\n return 'Vroom!';\n };\n\n this.refuel = function() {\n this.fuel = 100;\n return this.fuel;\n };\n}", "title": "" }, { "docid": "50e3acd6d772b0e20f5aebb3ecf1076b", "score": "0.51234514", "text": "function carFactory(brand, numberOfCars){\n\n\tthis.brand = brand;\n\tthis.numberOfCars = numberOfCars;\n\tthis.carsAvailable = [];\n\tthis.manufacture = function manufacture(){\n\n\t\t\t\t\tfor (var i = 0; i < this.numberOfCars; i++) {\n\n\n\t\t\t\t\t\tvar currentCar = new Car(\"Audi\", \"TT\", \"red\");\n\n\t\t\t\t\t\t//push keyword adds whats in the brackets to the end of the array\n\n\t\t\t\t\t\tthis.carsAvailable.push(currentCar);\n\t\t\t\t\t\t\n\t\t\t\t\t}\n\t};\n\t\n}", "title": "" }, { "docid": "90d60647f85cc626f4c9fd0f335ba92b", "score": "0.5114985", "text": "function carFactory(model, color) {\n //create object in here with model and color\n //return created object\n var carObj = {};\n carObj.model = model;\n carObj.color = color;\n carObj.fuel = 100;\n carObj.drive = function() {\n this.fuel--;\n return 'Vroom!';\n };\n carObj.refuel = function() {\n this.fuel = 100;\n };\n return carObj;\n}", "title": "" }, { "docid": "83c9543398ad00826189f5ffbe1a892a", "score": "0.51062423", "text": "function newDate (){\n let d = new Date();\n let date = d.getMonth()+'.'+ d.getDate()+'.'+ d.getFullYear();\n return date\n}", "title": "" }, { "docid": "1d7ba0fc68bb8493e4191be097d6e114", "score": "0.5105789", "text": "function sc_currentDate() {\n return new Date();\n}", "title": "" }, { "docid": "331cdd40b7d0f505b68e68338e660868", "score": "0.5101278", "text": "currentDate(date) {\n this.current = date;\n return this.current;\n }", "title": "" }, { "docid": "2d91087aa79a4ea24a620746664eca90", "score": "0.5095494", "text": "function Car() {}", "title": "" }, { "docid": "2d91087aa79a4ea24a620746664eca90", "score": "0.5095494", "text": "function Car() {}", "title": "" }, { "docid": "a3034052dd3f9c562ceccb2aa51ab8f9", "score": "0.5094119", "text": "setDateStructure(purchaseDate) {\n var d = purchaseDate;\n var curr_date = d.getDate();\n var curr_month = d.getMonth() + 1;\n var curr_year = d.getFullYear();\n return curr_date + \"/\" + curr_month + \"/\" + curr_year;\n }", "title": "" }, { "docid": "66f68c5f196e258fbf88379869171a27", "score": "0.50920075", "text": "function invokeFunPre (iid, f, base, args, isConstructor) {\n\t\t//console.log('before calling ' + f.name + ': ' + instructCnt);\n\t\ttimeList.push(new DATE());\n\t}", "title": "" }, { "docid": "efae107f38700de2c7c65abfd71bd32f", "score": "0.5072743", "text": "function Car(make, model, year, horsepower, color) {\n this.make = make;\n this.model = model;\n this.year = year;\n this.horsepower = horsepower;\n this.color = color;\n this.description = function() {\n return `${this.make} ${this.model} ${this.year} (${this.horsepower}) in ${this.color}`;\n };\n}", "title": "" }, { "docid": "13e101dceb8d1bba2afe6262d23706e3", "score": "0.5067018", "text": "function now() {\r\n return new Date();\r\n}", "title": "" }, { "docid": "f2f9bea20dfa671c968cd142719bf784", "score": "0.50598013", "text": "function getDate() {\n\tlet date = new Date();\n\tlet today = `${date.getMonth() + 1}-${date.getDate()}-${date.getFullYear()}`;\n\treturn today;\n}", "title": "" }, { "docid": "7ecec8e8ec0c3107c98bf2036e2590e8", "score": "0.50556475", "text": "function Car(manufacturer, model, year, color) {\n return {\n toString() {\n return `${manufacturer} ${model} (${year}, ${color})`\n }\n }\n}", "title": "" }, { "docid": "cd38e5e339e597881a13a470b53106e5", "score": "0.505066", "text": "function Car(name,year,color){\n this.name = name;\n this.year = year;\n this.color = color;\n\n this.drive = function(){\n console.log(\"Driving\") ;\n }\n\n}", "title": "" }, { "docid": "fff39bb5d3b5d193e4924bed2890ee61", "score": "0.5044171", "text": "add_vendor(dct){\r\n var dt = new Date();\r\n var datetime = dt.toISOString().substr(0, 10) + \" \" + dt.toTimeString().substr(0, 8);\r\n return \"insert into abc.vendor (name, deviceid, startdate, expirydate, updated) values(\"+\"\\'\"+dct[\"name\"]+\"\\',\"+\"\\'\"+dct[\"deviceid\"]+\"\\'\"+\",\"+\r\n \"\\'\"+dct[\"startdate\"]+\"\\',\\'\"+dct[\"enddate\"]+\"\\',\\'\"+datetime+\"\\'\"+\");\";\r\n }", "title": "" }, { "docid": "095b2ce05b501acdc13bc2f719cb6b9b", "score": "0.50378084", "text": "rentalCore() {\n if(carsData) {\n return {\n pickUpDateTime: helper.formatDate(carsData[0]['VehAvailRSCore']['VehRentalCore']['@PickUpDateTime']),\n returnDateTime: helper.formatDate(carsData[0]['VehAvailRSCore']['VehRentalCore']['@ReturnDateTime']),\n pickUpLocationName: carsData[0]['VehAvailRSCore']['VehRentalCore']['PickUpLocation']['@Name'],\n returnLocationName: carsData[0]['VehAvailRSCore']['VehRentalCore']['ReturnLocation']['@Name']\n }\n } else {\n throw new Error('Cars data do not exist.');\n }\n }", "title": "" }, { "docid": "cb0a7404d1af7a54c41cc0a1a8d5277d", "score": "0.503183", "text": "function date() {\n var date = new Date()\n alert(date)\n}", "title": "" }, { "docid": "d231d54787a9b817b98b8c73f0718612", "score": "0.50284374", "text": "function carFactory (options = { brand: 'Volkswagen', year: 1999 }) {\n console.log(options.brand)// <- 'Volkswagen'\n console.log(options.year)// <- 1999\n}", "title": "" }, { "docid": "8cd4aed0672061d63530d134bc842e94", "score": "0.5022313", "text": "function newdate(){\r\n var dat = new Date()\r\n document.write(dat) \r\n}", "title": "" }, { "docid": "d8b820781d7f314bcd7ef2ed6dc5b89a", "score": "0.5018238", "text": "objDate(date) {\n\n let dateObj;\n\n if (!date)\n dateObj = new Date();\n\n if (date)\n dateObj = new Date(Date.parse(date));\n\n return dateObj;\n }", "title": "" }, { "docid": "5f5937bf3e99b62105f698b18b103c3b", "score": "0.5016244", "text": "get creationDate() {\n return new Date(this._data.created_at);\n }", "title": "" }, { "docid": "adaac66fb653eb65893da175faf1538b", "score": "0.50106", "text": "function dateHeure () {\n const d = new Date()\n return d.getFullYear() + '-' + e2(d.getMonth() + 1) + '-' + e2(d.getDate()) + '_' + e2(d.getHours()) + e2(d.getMinutes()) + e2(d.getSeconds())\n}", "title": "" }, { "docid": "422ae148d42fc5e0bec94acfed5e7d8b", "score": "0.50095963", "text": "function getDate (argv, next) {\n argv.date = today()\n next()\n}", "title": "" }, { "docid": "927f1737b10dcbd5edcb1e5a32607418", "score": "0.50093436", "text": "function dateWrite() {\r\n var month = [\"Janvier\", \"Février\", \"Mars\", \"Avril\", \"Mai\", \"Juin\", \"Juillet\", \"Août\", \"Septembre\", \"Octobre\", \"Novembre\", \"Decembre\"]\r\n var today = new Date();\r\n var dd = today.getDate();\r\n var mm = month[today.getMonth()]\r\n\r\n var date = {\r\n 'day': dd,\r\n 'month': mm\r\n }\r\n\r\n return date\r\n}", "title": "" }, { "docid": "d7ac14b5865ab0e420678ae59e62ad05", "score": "0.49897692", "text": "function Car(color, mark, year, plate) {\n\tthis.color = color;\n\tthis.mark = mark;\n\tthis.plate = plate;\n\tthis.year = year;\n\tthis.name = function () {\n\t\treturn this.plate + '' + this.mark;\n\t};\n}", "title": "" }, { "docid": "fc83641f8888156367310ee1ed049621", "score": "0.4985408", "text": "get servicedDate() {\n\t\treturn this.__servicedDate;\n\t}", "title": "" }, { "docid": "76df6a4206ff5b130dcd48948ce1caf8", "score": "0.49797472", "text": "function date() {\n if (TYPE == \"DEBUG\")\n return new Date();\n else\n return DATE;\n}", "title": "" }, { "docid": "060c336626530578ec898a98c319c53f", "score": "0.49771133", "text": "get_dateTime()\n {\n return this.liveFunc._dateTime;\n }", "title": "" }, { "docid": "2b26a99dae49716d8a503c15a2084265", "score": "0.4974768", "text": "function dateWriter(year, month, day){\nreturn year + month + day;\n}", "title": "" }, { "docid": "af9e37ae16ff5b8c109de0720d39447c", "score": "0.497316", "text": "function getDate() {\n return new Date().toDateString();\n}", "title": "" }, { "docid": "305d94f2bb8814a263be5896a949c682", "score": "0.49620596", "text": "function now() {\n return new Date();\n}", "title": "" }, { "docid": "305d94f2bb8814a263be5896a949c682", "score": "0.49620596", "text": "function now() {\n return new Date();\n}", "title": "" }, { "docid": "305d94f2bb8814a263be5896a949c682", "score": "0.49620596", "text": "function now() {\n return new Date();\n}", "title": "" }, { "docid": "0d06e5c76398fc9136bb698b97811060", "score": "0.49619865", "text": "function Car(name) {\n this.name = name;\n this.speed = 55;\n this.race = function () {\n console.log(`The ${this.name} wins the race going ${this.speed}MPH`);\n }\n}", "title": "" }, { "docid": "81025b6216d8a043d3b8607079eb68d1", "score": "0.4960239", "text": "function Car(model,color,isAutomatic) {\n console.log(\"On the assembly line:\", this) //initialization message\n\n // make 'instance' values of our parameters\n this.model = model;\n this.color = color;\n this.isAutomatic = isAutomatic;\n \n // make functions for our cars\n this.shift = function() {\n if(this.isAutomatic) {\n console.log(\"Enjoy driving right now!\");\n } else {\n console.log(\"Back to driving school to learn how to drive stick!\");\n }\n }; \n \n this.horn = function() {\n console.log(\"beep beep\")\n };\n}", "title": "" }, { "docid": "7be64f610098b6d411cd24ecf8cd4d25", "score": "0.4948862", "text": "function createCar(make, model, year) {\n return {\n make,\n model,\n year,\n started: false,\n start(){\n this.started = true\n },\n stop(){\n this.started = false\n }\n }\n}", "title": "" }, { "docid": "e64d232dd12f0c966fda0fd74842fdc0", "score": "0.4942237", "text": "function fncObtenerFecha(){\n\tvar today = new Date();\n\tvar dd = today.getDate();\n\tvar mm = today.getMonth()+1; /* January is 0! */\n\tvar yyyy = today.getFullYear();\n\tif(dd<10){dd='0'+dd}\n\tif(mm<10){mm='0'+mm}\n\tfecha = dd + '-' + mm + '-' + yyyy;\n\treturn fecha\n}", "title": "" }, { "docid": "33b42223915a878cca6dfb2601903c01", "score": "0.4931843", "text": "function CurrentDate()\n{\n\n var d=new Date();\n return d;\n}", "title": "" }, { "docid": "5a6eed0e8be3b04b51a15eb3f6af0a9e", "score": "0.49306226", "text": "getDate() {\n const today = new Date();\n const date = today.getFullYear()+'-'+(today.getMonth()+1)+'-'+today.getDate();\n const time = today.getHours() + \":\" + today.getMinutes() + \":\" + today.getSeconds();\n const dateTime = date +' '+ time;\n this.timestamp = dateTime;\n }", "title": "" }, { "docid": "b430ae56422ee3e9186ebb408936cbe5", "score": "0.492541", "text": "function Car(color, make, model){\n this.color = color\n this.make = make\n this.model = model\n // this.getSummary = function(){\n // return `car color ${this.color}, model ${this.model}, maker ${this.make}`\n // }\n}", "title": "" }, { "docid": "299510ea7295e3d69c80eb7a60e222b7", "score": "0.4924766", "text": "function Car(inputModel, inputColor, inputYear, inputFuel, inputFuelConsumption){\n this.model = inputModel;\n this.color = inputColor;\n this.year = inputYear;\n this.fuel = inputFuel;\n this.fuelConsumption = inputFuelConsumption;\n\n this.calculateDistance = function(inputDistance){\n let fuelWeNeed = inputDistance * (this.fuelConsumption / 100);\n \n // if(fuelWeNeed > this.fuel){\n // return `Sorry, you cannot go on holiday with this car!`;\n // } else {\n // return `You can go on holiday! Hooray!`;\n // }\n // new fancy ternary operators (use them :) )\n return fuelWeNeed > this.fuel ? `Sorry, you cannot go on holiday with this car!` : `You can go on holiday! Hooray!`;\n };\n}", "title": "" }, { "docid": "fe04cea2c8ed4cf17cb2bf5065bafb9c", "score": "0.49207443", "text": "function createDate({year, month, day, hour=0, minute=0, second=0}) {\n return new Date(year + '-' + month + '-' + day + ' ' + hour + ':' + minute + ':' + second);\n}", "title": "" } ]
3dbddc440cfec99648739827224adcc5
Function to draw the bird
[ { "docid": "15af351414680ef5711b43b2f0677c55", "score": "0.0", "text": "show()\n {\n stroke(0);\n fill(191, 46, 13);\n ellipse(this.x,this.y,32,32);\n }", "title": "" } ]
[ { "docid": "f0cd0d18d3c2246da4a98244a6544b98", "score": "0.7736643", "text": "function Bird() {\n this.y = height / 2\n this.x = 25\n this.show = function() {\n fill(255)\n ellipse(this.x, this.y, 32, 32)\n }\n}", "title": "" }, { "docid": "60cf3d68547e2436afe119f8a3a67407", "score": "0.75173306", "text": "draw() {\n\n this.ctx.beginPath();\n this.ctx.drawImage(this.birdImg, 0, 194.625 * this.i, 200, 194.625, this.x, this.y, this.size, this.size);\n this.ctx.fill();\n this.ctx.closePath();\n }", "title": "" }, { "docid": "7af03e9aea8c82c1bf9e3cda396180d7", "score": "0.7349343", "text": "function drawKirby(){\n\tdrawBody();\n\tdrawFeet();\n\tdrawArms();\n}", "title": "" }, { "docid": "ae855bcb226b15b3f31294abc19fbc1a", "score": "0.7301919", "text": "function drawSmallBird(x, y) {\n\n context.save();\n\n context.fillStyle='yellow';\n context.beginPath();\n context.arc(x, y, 20, 0, 2 * Math.PI, true);\n context.arc(x-20, y-10, 10, 0, 2 * Math.PI, true);\n context.fill();\n\n context.fillStyle='orange';\n context.beginPath();\n context.moveTo(x-26, y-10);\n context.lineTo(x-38, y-10);\n context.lineTo(x-26, y-15);\n context.fill();\n\n context.restore();\n}", "title": "" }, { "docid": "b12ed6bc57d93aba297a0445da3de0f3", "score": "0.7253854", "text": "function drawLargeBird(x, y) {\n\n context.save();\n\n context.fillStyle='orange';\n context.beginPath();\n context.arc(x, y, 40, 0, 2 * Math.PI, true);\n context.arc(x-40, y-20, 20, 0, 2 * Math.PI, true);\n context.fill();\n\n context.fillStyle='yellow';\n context.beginPath();\n context.moveTo(x-56, y-17);\n context.lineTo(x-80, y-17);\n context.lineTo(x-56, y-24);\n context.fill();\n\n context.restore();\n}", "title": "" }, { "docid": "3ff89a09037bad2f7fe68b72731e64c5", "score": "0.71412253", "text": "drawBoid() {\r\n\t\tc.beginPath();\r\n\t\tc.arc(this.x, this.y, this.radius, 0, Math.PI * 2, false);\r\n\t\tc.fillStyle = this.color;\r\n\t\tc.fill();\r\n\t\tc.closePath();\r\n\t}", "title": "" }, { "docid": "5d7084733d8ffef3a39d4fb6c6f41aab", "score": "0.7129728", "text": "show() {\n var pos = this.body.position;\n var angle = this.body.angle;\n\n push();\n translate(pos.x, pos.y);\n rotate(angle);\n rectMode(CENTER);\n\n drawSprite(this.birdspr);\n /* strokeWeight(1);\n stroke(255);\n fill(127);\n ellipse(0, 0, this.r * 2);\n line(0, 0, this.r, 0);*/\n pop();\n }", "title": "" }, { "docid": "cf04e0a5c12ca64637e00d3bfba9c855", "score": "0.71083504", "text": "function draw(){\n\tboard.clearRect(0,0,BOARD_SIZE,BOARD_SIZE);\n\tball.draw();\n\tbricks.forEach((b) => {b.draw();});\n\tpaddle.draw();\n\tarrow.draw();\n\tfor(var i = 0; i < lives; i++)\n\t\tdrawHeart(475 - (i*50), 475);\n}", "title": "" }, { "docid": "1b3aeb1753c10303c894bb4c3a6f7223", "score": "0.71033305", "text": "show()\n {\n stroke(0);\n fill(0);\n image(birdImge,this.x,this.y,80,80);\n }", "title": "" }, { "docid": "a13cc3b75a1e11b7975a59acd532a562", "score": "0.7061174", "text": "draw() {\n this.drawAsteroid();\n }", "title": "" }, { "docid": "496015f00f819664fccdbc9ff1d3d189", "score": "0.7013143", "text": "function drawAllBirds(context) {\r\n for (var i = 0; i < birds.length; i = i + 1) {\r\n var bird = birds[i];\r\n drawOneBird(context, bird);\r\n }\r\n}", "title": "" }, { "docid": "1d548982e59177aa72e680abf0fe3d57", "score": "0.6997662", "text": "function drawBowls(){\n fill(255,120,125);\n rect(width/35, height/1.65, width/6, height/5);\n fill(220);\n ellipse(width/15, height/1.4, width/17.5);\n ellipse(width/6.5, height/1.4, width/17.5);\n fill(151,227, 255);\n ellipse(width/15, height/1.4, width/25);\n fill(97,48, 19);\n ellipse(width/6.5, height/1.4, width/25);\n}", "title": "" }, { "docid": "3ac2c3b666988860da0a7935b35fcb74", "score": "0.69840515", "text": "function draw() {\n bkgd.draw();\n\tplayer.draw();\n\t//solid.draw();\n}", "title": "" }, { "docid": "653284e7b3c4fd101618360dad7509c3", "score": "0.6979397", "text": "function drawEverything() {\r\n var canvas = getCanvas();\r\n var context = canvas.getContext(\"2d\"); \r\n drawBackground(context);\r\n drawSlingshot(context);\r\n if (birdToLaunch != undefined) { \r\n drawRubberBand(context, birdToLaunch);\r\n }\r\n drawAllPigs(context);\r\n drawAllBirds(context); \r\n}", "title": "" }, { "docid": "5449dd685a546d026e2a07bd3280c428", "score": "0.69434476", "text": "draw(){\n\n for(let i=0; i<this.belt.length;i++){\n this.belt[i].draw();\n }\n }", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "38d7a302cfd754dbd803c9c5f6732ac1", "score": "0.69341046", "text": "function draw() {}", "title": "" }, { "docid": "e77a45657aa2c7a20dd1d308842394f6", "score": "0.68713224", "text": "function draw() {\n background(color(bg.r, bg.g, bg.b));\n noCursor();\n\n //Make Stars every frame, adding them to the starfield array.\n //First i initializes and second controls amount of starfield on screen.\n //Higher numbers increases starfield density.\n //Also makes the sky change from blue to black.\n for (let i = 0; i < 15; i++) {\n starfield.push(new star());\n bg.r -= 0.75;\n bg.g -= 0.75;\n bg.b -= 0.75;\n }\n\n //Keep those stars spawning with a for of loop,\n //updating their position and drawing more using the nested\n //motion and display functions within the starfield function.\n for (let star of starfield) {\n star.motion();\n star.display();\n }\n\n //Make our Rocketship appear.\n rocketShip();\n}", "title": "" }, { "docid": "da15fb79c4903e693321ef12c6e504b5", "score": "0.6861489", "text": "draw(ctx) {\n // The image will be cropped from y = 80 and y = 150 giving us a nice two frame animation\n ctx.drawImage(bird, this.x, this.y, this.w, this.h);\n }", "title": "" }, { "docid": "e227b9a49ed1f35893cd5a104fc9f198", "score": "0.685887", "text": "function drawBed(){\n fill(109, 199, 237);\n ellipse(width/1.5, height/1.65, width/6, width/10);\n fill(145, 206, 256);\n ellipse(width/1.5, height/1.65, width/8, width/12);\n}", "title": "" }, { "docid": "489d6fc5942d6548fe97006010ff9e8d", "score": "0.6855612", "text": "function draw() {\n drawBackground();\n drawSnake();\n}", "title": "" }, { "docid": "a0b9bc6ad38186c569130237b5d29ded", "score": "0.6849098", "text": "function drawBird(canvas, context) {\n var birdImage = new Image();\n birdImage.src = \"twitterBird.png\";\n birdImage.onload = function () {\n context.drawImage(birdImage, 20, 120, 70, 70);\n };\n}", "title": "" }, { "docid": "da6f937c3b049bcc93fde376dfcd5929", "score": "0.6840696", "text": "function criaFlappyBird() {\r\n const flappyBird = {\r\n sprinteX: 0,\r\n sprinteY: 0,\r\n largura: 33,\r\n altura: 24,\r\n x: 10,\r\n y: 50,\r\n //Definir tamanho do pulo\r\n pulo: 4.6,\r\n //Ao click, o passaro vai pular\r\n pula() {\r\n flappyBird.velocidade = -flappyBird.pulo;\r\n },\r\n\r\n //atualizar e fazer o bird cair\r\n gravidade: 0.25,\r\n velocidade: 0,\r\n atualiza() {\r\n if (fazColisao(flappyBird, globais.chao)) {\r\n som_HIT.play();\r\n mudaParaTela(Telas.GAME_OVER);\r\n return;\r\n }\r\n flappyBird.velocidade = flappyBird.velocidade + flappyBird.gravidade;\r\n flappyBird.y = flappyBird.y + flappyBird.velocidade;\r\n },\r\n\r\n //Fazer com que o bird movimenta a asa\r\n movimentos: [\r\n { sprinteX: 0, sprinteY: 0 }, //asa pra cima\r\n { sprinteX: 0, sprinteY: 26 }, //asa no meio\r\n { sprinteX: 0, sprinteY: 52 }, //asa pra baixo\r\n ],\r\n frameAtual: 0,\r\n atualizaOFrameAtual() {\r\n const intervaloDeFrames = 10;\r\n const passouOIntervalo = frames % intervaloDeFrames === 0;\r\n\r\n if (passouOIntervalo) {\r\n const baseDoIncremento = 1;\r\n const incremento = baseDoIncremento + flappyBird.frameAtual;\r\n const baseRepeticao = flappyBird.movimentos.length;\r\n flappyBird.frameAtual = incremento % baseRepeticao;\r\n }\r\n },\r\n //Função para ficar chamando em loop a imagem do bird (passaro). a função drawImage vai posicionar e especificar a largarua e altura da imagem e recortar a imagem\r\n desenha() {\r\n flappyBird.atualizaOFrameAtual();\r\n const { sprinteX, sprinteY } =\r\n flappyBird.movimentos[flappyBird.frameAtual];\r\n\r\n contexto.drawImage(\r\n //passa a imagem\r\n sprites,\r\n //define os valores\r\n sprinteX,\r\n sprinteY, //Posicione a imagem na tela\r\n flappyBird.largura,\r\n flappyBird.altura, //Posicione a imagem na tela e especifique a largura e a altura da imagem\r\n flappyBird.x,\r\n flappyBird.y, //Recorte a imagem\r\n flappyBird.largura,\r\n flappyBird.altura //posicione a parte recortada na tela\r\n );\r\n },\r\n };\r\n return flappyBird;\r\n}", "title": "" }, { "docid": "07a4bb76f43d8ffc4dd644a5ac359439", "score": "0.67975146", "text": "function draw() {\ndraw_board(board_width,board_heigths,board_color)\ndraw_fruit()\ndraw_snake()\n}", "title": "" }, { "docid": "c98d7d2eded51ef5758ddf690ba6bec9", "score": "0.6795544", "text": "function drawBees() {\n for (let i = 0; i < bees.length; i++) {\n bees[i].draw();\n }\n }", "title": "" }, { "docid": "cc7e9b632e2bece66b9e9775618272ad", "score": "0.67905694", "text": "function draw() {\n draw_board(width, height, color)\n draw_snake()\n draw_square(fruit.pos.x,fruit.pos.y,fruit.color,fruit.color)\n\n\n}", "title": "" }, { "docid": "db7f0f3b1e1ee0fe9f478558fbd6a239", "score": "0.6778044", "text": "render() {\n push();\n fill('#283747');\n stroke('#154360');\n //For the rotational motion we set angle Theta\n let theta = this.vel.heading() + radians(90);\n translate(this.pos.x, this.pos.y);\n //rotate the bird\n rotate(theta);\n beginShape();\n vertex(0, -this.r * 2);\n vertex(-this.r, this.r * 2);\n vertex(this.r, this.r * 2);\n endShape(CLOSE);\n pop();\n }", "title": "" }, { "docid": "5b326592d3413c3d1491a89e7dea724c", "score": "0.67698985", "text": "draw() {\r\n }", "title": "" }, { "docid": "e3517a4e635d824d17e941ee91d38ba9", "score": "0.67613506", "text": "drawBear() {\n context.drawImage(\n this.bearImage,\n this.xPosition,\n this.yPosition,\n this.width,\n this.height\n );\n }", "title": "" }, { "docid": "fb167bf1e0fb6e16e4f31b3676c632a6", "score": "0.67597127", "text": "function draw() { }", "title": "" }, { "docid": "936ea4e0a037f35cebc20ef52d463a97", "score": "0.67406803", "text": "function drawBirdsGraphics(){\n\n let level = mBackgroundSoundAmplitude.getLevel();\n let background = map(level,0,1,50,255);\n mCanvas.background(background);\n\n}", "title": "" }, { "docid": "43ef8338797b5340ad3d87fb3a7e4478", "score": "0.67360234", "text": "function draw() {\n background(53);\n\n for (var i = 0; i < birds.length; i++) {\n\n //Align the bird's velocity to the neighbours velocities\n birds[i].align(birds);\n\n birds[i].update();\n birds[i].show();\n }\n\n}", "title": "" }, { "docid": "23ae98a3f47c1d36172856448fe0b2cf", "score": "0.6735391", "text": "function drawFrame() {\n draw(0, 150, 300, 150);\n draw(225, 300, 225, 0);\n draw(225, 0, 75, 0);\n draw(75, 0, 75, 25);\n }", "title": "" }, { "docid": "94ee7cfdaf77eba80c69d642950559c8", "score": "0.6726192", "text": "function draw() {\n context.clearRect(0, 0, 600, 600);\n rod.draw();\n // draw water and shit.\n }", "title": "" }, { "docid": "24b6e17d4292646f219bdb833d3eb35e", "score": "0.67235035", "text": "draw(){\n push();\n noFill();\n noStroke();\n rect(this.x,this.y,this.width,this.height);\n pop();\n }", "title": "" }, { "docid": "6038c2505dad7a987733e25c75cc655b", "score": "0.6700905", "text": "draw()\n {\n \n \n }", "title": "" }, { "docid": "277beeeead800c5abcd34a065f402224", "score": "0.6700264", "text": "function draw() {\n strokeWeight(1);\n //to have hat behind ears\n hatBase();\n drawEars();\n drawHead();\n //to have hat front in front of ears\n drawHat();\n drawMouth();\n drawMoustache();\n drawEyebrows();\n drawEyes();\n drawSideburns();\n //To increase the line weight of the nose\n strokeWeight(4);\n drawNose();\n}", "title": "" }, { "docid": "734dc2cd8bc85f551e87313049c3f8f9", "score": "0.669034", "text": "function draw_copter() {\n draw_main_body();\n draw_legs();\n blade_rotate();\n }", "title": "" }, { "docid": "aa02ba59c261d0f1dd35fb99919981cc", "score": "0.6690095", "text": "function draw() {\n clear();\n var ctx = sim.ctx;\n\n // 1! draw conveyor\n var conveyor = sim.conveyor;\n drawConveyor(conveyor, ctx);\n\n // draw a worker\n drawWorker(conveyor, ctx);\n\n // 2! draw storageBins\n var storageBins = sim.rack.storageBins;\n drawStorageBins(storageBins, ctx);\n\n // 3! draw locations\n var locations = sim.locations;\n drawLocations(locations, ctx);\n\n // 4! draw boxes\n var boxes = sim.boxes;\n drawBoxes(boxes, ctx);\n\n /*// 1! draw rackFeeder\n var rackFeeder = sim.rackFeeder;\n ctx.beginPath();\n ctx.rect(rackFeeder.x, rackFeeder.y, rackFeeder.width, rackFeeder.height);\n ctx.closePath();\n ctx.lineWidth = 1;\n ctx.strokeStyle = 'blue';\n ctx.stroke();*/\n\n}", "title": "" }, { "docid": "2cf70bd60311ccc6a58e120849f81492", "score": "0.6676948", "text": "function brasg ()\n{\t\ncontext.beginPath();\ncontext.lineWidth = '7';\ncontext.lineCap = 'round';\ncontext.moveTo(240, 180);\ncontext.lineTo(190, 170);\ncontext.stroke();\n}", "title": "" }, { "docid": "4bbfc5d4b4a10a5881617ea33c2dd5e4", "score": "0.6675513", "text": "function draw(){\r\n clearScreen();\r\n drawBricks(); // on efface l'écran à chaque fois, il faut donc redessiner les briques !\r\n drawBall();\r\n ballWhoToMove();\r\n}", "title": "" }, { "docid": "f0f54764db1294a4b079fe6c66b1a906", "score": "0.6667619", "text": "function draw() {\n\tbackground(200,200,200)\n\n\t//When the active game is bouncing ball\n\tif (activeGame == 'bb') {\n\t\t//call ball draw loop\n\t\tbb_draw();\n\t}\n}", "title": "" }, { "docid": "802245c17537b4a87e206854f314715f", "score": "0.6661581", "text": "function draw() {\n draw_board (width, height, board_color)\n draw_snake (snake.x, snake.y, snake.color)\n draw_square (fruit.x, fruit.y, fruit.color) \n \n // console.log(\"drawing\");\n}", "title": "" }, { "docid": "2e6967908582c6105df31ae0ae8ed514", "score": "0.66528904", "text": "function draw(){\n // background(220);\n for (i = 0; i < boids.length; i++) {//making it run\n boids[i].run()\n } \n}", "title": "" }, { "docid": "767ccdf5f1430a4ffe42bbac126a11e7", "score": "0.66522163", "text": "draw(){}", "title": "" }, { "docid": "1ba27f620679ecc88e92ce44cede160c", "score": "0.66499406", "text": "display() {\n // draw the frog at its current position\n image(this.graphic, this.x, this.y);\n }", "title": "" }, { "docid": "c4bfd78e553c55197931e9dd29d9a28d", "score": "0.66443175", "text": "function draw() {\n // Background image is forest\n background(forestImg);\n\n instructions();\n\n // Handle input for the tiger and the lion\n bear.handleInput();\n lion.handleInput();\n\n // Move all the \"animals\"\n bear.move();\n lion.move();\n mouseOne.move();\n mouseTwo.move();\n mouseThree.move();\n\n // Handle the bear eating any of the prey\n bear.handleEating(mouseOne);\n bear.handleEating(mouseTwo);\n bear.handleEating(mouseThree);\n\n // Handle the lion eating any of the prey\n lion.handleEating(mouseOne);\n lion.handleEating(mouseTwo);\n lion.handleEating(mouseThree);\n\n // Display all the \"animals\"\n bear.display();\n lion.display();\n mouseOne.display();\n mouseTwo.display();\n mouseThree.display();\n}", "title": "" }, { "docid": "8098cd24621a8f4d142f3c8833d827b1", "score": "0.6639846", "text": "function InventoryItemMouth2HarnessBallGagDraw() {\n\tInventoryItemMouthBallGagDraw();\n}", "title": "" }, { "docid": "c44c0452e02d8e1df4bc18ac7bc6d590", "score": "0.6634051", "text": "draw()\n {\n \n }", "title": "" }, { "docid": "dcee2b9cc44df8c56e178a49a4e76f8c", "score": "0.66333133", "text": "function draw() {\n\t// colors background white\n\tbackground(255);\n\n\t// displays the objects\n\troof.display();\n\trope1.display();\n\trope2.display();\n\trope3.display();\n\trope4.display();\n\trope5.display();\n\tbobObject1.display();\n\tbobObject2.display();\n\tbobObject3.display();\n\tbobObject4.display();\n\tbobObject5.display();\n}", "title": "" }, { "docid": "eac306244a306ce3f5b6c063653395b3", "score": "0.6626376", "text": "function draw() {\n casa.draw();\n edson.draw();\n}", "title": "" }, { "docid": "5381a873a19d12867fe04cf278c953a2", "score": "0.66205233", "text": "function draw() {\n image (video, 0,0);\n d = dist(noseX, noseY, noseX, noseY);\n \n //insert dog halo hoope, make it offset to be more central to face\n image(dogHaloHoop, noseX-100, noseY-120, 250, 320);\n for (let i = 0; i < biscuit.length; i++) { \n biscuit[i].move();\n biscuit[i].show();\n biscuit[i].dissappear(noseX, noseY); \n }\n}", "title": "" }, { "docid": "09c209b021136c86d1e07783534c9e2f", "score": "0.6612505", "text": "function drawBird(stringParams){\n\n map = document.getElementById(\"twitmap\");\n if(map == null) document.getElementById(\"accelmap\");\n\n bird = document.createElement('img');\n bird.setAttribute('positive', 0);\n bird.setAttribute('negative', 0);\n bird.setAttribute('neutral', 0);\n \n if(stringParams == null || stringParams == \"\"){\n return;\n }\n\tobjJson=jQuery.parseJSON(stringParams);\n\n\t\n\n\tswitch (objJson.sentiment){\n\n\t\tcase \"positive\":\n \n\t\t\tbirdie = \"birds/twitbird-green.png\";\n sentiment = \"<font color='green'>\"+objJson.text+\"</font><br>\";\n bird.setAttribute('positive', 1);\n alert(sentiment);\n\n\t\t\tbreak;\n\n\t\tcase \"negative\":\n\n\t\t\tbirdie = \"birds/twitbird-red.png\";\n sentiment = \"<font color='red'>\"+objJson.text+\"</font><br>\";\n bird.setAttribute('negative', 1);\n\n\t\t\tbreak;\n \n case \"ripple\":\n \n birdie = \"gifspeed.php?speed=\"+objJson.speed;\n sentiment = \"<font color='red'>\"+objJson.text+\"</font><br>\";\n bird.setAttribute('negative', 1);\n\n \t\tbreak;\n \n\t\tcase \"neutral\":\n\n\t\t\tbirdie = \"birds/twitbird-blue.png\";\n sentiment = \"<font color='blue'>\"+objJson.text+\"</font><br>\";\n bird.setAttribute('neutral', 1);\n\n\t\t\tbreak;\n\n\t\tdefault:\n\n\t\t\treturn;\n\n\t}\n\n\tbird.setAttribute('src',birdie);\n \n if (objJson.lat == null || objJson.lat==\"\"){\n\tlat = Math.floor((Math.random()*(mapHeight-100))+100);\n bird.style.top = lat;\n\tlon = Math.floor((Math.random()*(mapWidth -100))+100);\n bird.style.left = lon;\n }else{\n \n lat = calculateLat(objJson.lat);\n bird.style.top = lat;\n lon = calculateLon(objJson.lon);\n bird.style.left = lon\n }\n \n bird.style.height = 20;\n bird.style.width = 20;\n \n //bird.style.top = objJson.lat;\n //bird.style.left = objJson.lon;\n \n //alert(bird.style.top+\" \"+bird.style.left+\" of \"+mapHeight+\" \"+mapWidth);\n birdSize = 60;\n \n \n\n\t\n\n\t//bird.setAttribute('src','twitterpos.png');\n\n\t\n\n\tid = lat + lon + 1;\n\n\t\n //title = objJson.sentiment+'<br>';\n title = sentiment;// + objJson.lat+\" \"+objJson.lon;\n\t//lat = (objJson.lat / 2000) * 100;\n\n\t//longit = (objJson.lon / 3000) * 100;\n var imgs = document.getElementById(\"twitmap\").getElementsByClassName(\"birdie\");\n if(imgs == null) document.getElementById(\"accelmap\").getElementsByClassName(\"birdie\");\n if(imgs.length > 0){\n for (var i = 0; i < imgs.length; i++) {\n //var radius = imgs[i].clientWidth - 20;\n var radius = 200;\n var difX = Math.abs(parseInt(imgs[i].style.top) - parseInt(bird.style.top));\n var difY = Math.abs(parseInt(imgs[i].style.left) - parseInt(bird.style.left));\n \n if ((difX<=radius && difY<=radius) || (difX < 25 && difY < 25) || (imgs[i].style.left == bird.style.left && imgs[i].style.top == bird.style.top)) {\n //alert(\"collision detected\");\n \n /*if(parseInt(imgs[i].clientWidth)<=40){\n imgs[i].style.width = imgs[i].clientWidth + 20;\n imgs[i].style.height = imgs[i].clientHeight + 20;\n }\n \n if(parseInt(imgs[i].clientWidth)>40){\n imgs[i].style.width = 60;\n imgs[i].style.height = 60;\n }*/\n \n imgs[i].style.width = sizeBird(imgs[i]);\n imgs[i].style.height = sizeBird(imgs[i]);\n \n temptip = imgs[i].getAttribute('tiptitle');\n if(temptip == null || temptip == \"\"){\n temptip = imgs[i].getAttribute('title');\n }\n texts = imgs[i].getAttribute('texts');\n imgs[i].setAttribute('texts', texts);\n \n var tooBig = temptip.split(\"<br>\");\n if (tooBig.length<10){\n temptip = temptip +title; // <br> was here\n texts = texts +title; // // <br> was here\n imgs[i].setAttribute('title', temptip);\n }else{\n if (tooBig[tooBig.length-1] == \"Click to see more\"){\n newPage = 'newWindow(this)';\n imgs[i].setAttribute('onClick', newPage);\n texts = texts +title; // // <br> was here\n }else{\n linking = temptip + \"Click to see more\"; // <br> was here\n imgs[i].setAttribute('title', linking); \n }\n \n }\n newPage = 'newWindow(this)';\n imgs[i].setAttribute('onClick', newPage);\n imgs[i].setAttribute('texts', texts);\n //imgs[i].setAttribute('title', texts);\n \n //alert(\"temptip\"+temptip);\n \n feeling = imgs[i].getAttribute(objJson.sentiment);\n feeling = parseInt(feeling) + 1;\n imgs[i].setAttribute(objJson.sentiment, feeling);\n \n //alert(objJson.sentiment+\" feeling : \"+feeling);\n var pos = imgs[i].getAttribute('positive');\n var neg = imgs[i].getAttribute('negative');\n var neu = imgs[i].getAttribute('neutral');\n newBird = nextBird(pos, neg, neu);\n imgs[i].setAttribute('src', newBird);\n //imgs[i].tiptitle = imgs[i].tiptitle + title;\n //alert(imgs[i].style.height);\n return;\n }\n \n }\n }\n\n\tbird.setAttribute('class', 'birdie');\n\n\tbird.setAttribute('id', id);\n \n bird.setAttribute('title', title);\n bird.setAttribute('texts', title);\n if (objJson.speed == null || objJson.speed == \"\"){\n bird.setAttribute('speed', Math.ceil((Math.random()*20)+1));\n }else{\n bird.setAttribute('speed', objJson.speed);\n \n }\n bird.setAttribute('direction', 1);\n\n\t//bird.setAttribute('onLoad', 'shakeAll()');\n bird.setAttribute('onLoad', 'this.focus()');\n \n //bird.setAttribute('onClick', \"Popup.show(null,null,null,{'content':'DIV!','width':200,'height':200,'style':{'border':'1px solid black','backgroundColor':'cyan'}});return false;\");\n \n //bird.setAttribute('onClick', 'alert(\"working!\")');\n\n\tmap.appendChild(bird);\n\n\t\n\n\t//birds++;\n\n\t//birdmap[id] = Math.floor((Math.random()*30)+50);\n \n //return;\n\n}", "title": "" }, { "docid": "2864f6b550b28308393a1147a5fefd64", "score": "0.6593101", "text": "function draw(){\r\n background(20, 20, 20, 22);\r\n for(var i = 0; i < Boids.length; i++){\r\n Boids[i].run();\r\n chaser.run();\r\n }\r\n}", "title": "" }, { "docid": "2002370abae17cb8a3d4ee13bd7cc7a9", "score": "0.656933", "text": "function draw() {\r\n // SET variables & colours for self portrait skin, hair, shirt, nose.\r\n var skinlight = color(255, 213, 188);\r\n var skinMed = color(249, 199, 169);\r\n var skinDark = color(200, 200, 169);\r\n var hair = color(100, 50, 30);\r\n var shirt = color(50, 50, 60);\r\n var noseRing = color(244, 189, 100);\r\n var black = color (0, 0, 0);\r\n \r\n //SET bacground (light grey colour)\r\n background(220);\r\n \r\n //Start filling colours into shapes such as rectangles, ellipses, curves & lines.\r\n noStroke ();\r\n fill(skinMed);\r\n rect(165, 200, 70, 100);\r\n \r\n\r\n // drawing the shirt\r\n fill(shirt);\r\n rect(115, 275, 170, 130);\r\n \r\n fill(shirt);\r\n ellipse(120, 395, 120, 240);\r\n \r\n fill(shirt);\r\n ellipse(280, 395, 120, 240);\r\n \r\n\r\n // \r\n fill(skinMed);\r\n ellipse(199, 275, 70, 60);\r\n \r\n fill(skinDark);\r\n ellipse(199, 210, 80, 100);\r\n \r\n fill(skinMed);\r\n ellipse(199, 170, 120, 160);\r\n ellipse(138, 173, 20, 40);\r\n ellipse(260, 173, 20, 40);\r\n \r\n noFill();\r\n stroke(noseRing);\r\n strokeWeight(3);\r\n ellipse(199, 202, 12, 12);\r\n \r\n noStroke();\r\n fill(skinlight);\r\n ellipse(199, 195, 20, 15);\r\n \r\n \r\n // Hair \r\n fill(hair);\r\n stroke(20);\r\n strokeWeight(1); \r\n // using lines...\r\n // top position (hair) \r\n line(170,100, 190, 90);\r\n line(180,100, 190, 90);\r\n line(185,100, 190, 90);\r\n line(200,100, 200, 90);\r\n line(210,100, 200, 90);\r\n line(220,100, 200, 90);\r\n line(230,100, 200, 90);\r\n // right side (hair)\r\n line(140, 140, 150, 150);\r\n line(140, 130, 150, 140);\r\n line(150, 120, 160, 130);\r\n line(150, 110, 160, 120);\r\n line(160, 110, 170, 120);\r\n line(170, 110, 180, 120);\r\n // left side (hair)\r\n line(240, 110, 230, 120);\r\n line(240, 120, 230, 130); \r\n line(250,130, 240, 140); \r\n line(260, 140, 250, 150); \r\n \r\n\r\n // eyes\r\n fill(black);\r\n ellipse(175, 173, 10, 12);\r\n ellipse(225, 173, 10, 12);\r\n \r\n // eyebrows and mouth\r\n stroke(black);\r\n strokeWeight(3);\r\n // right eyebrow\r\n line(182, 159, 160, 160);\r\n // left eyebrow\r\n line(213, 159, 233, 160);\r\n // mouth\r\n line(185, 222, 215, 222);\r\n \r\n\r\n \r\n // Glasses\r\n //Rims\r\n strokeWeight(4);\r\n //reflection for glasses\r\n fill(255, 100);\r\n stroke(0);\r\n ellipse(width / 1.79, 175, 30);\r\n ellipse(width / 2.3, 175, 30);\r\n //Bridge\r\n stroke(0); \r\n curve(170, 190, 210, 172, 190, 172, 210, 200); \r\n //Handles\r\n //Left\r\n stroke(0);\r\n curve(160, 157, 157, 175, 137, 155, 100, 140); \r\n //Right\r\n stroke(0);\r\n curve(310, 120, 240, 175, 255, 150, 230,140); \r\n \r\n \r\n \r\n \r\n \r\n }", "title": "" }, { "docid": "3bc64651883b69849a2e978519cc82e4", "score": "0.65679085", "text": "draw() {\n push();\n noStroke();\n fill(255,255,255);\n ellipse(this.bulletX, this.bulletY, 10, 10); \n pop();\n \n }", "title": "" }, { "docid": "7f22ec62a479c4203823aa3985e058cf", "score": "0.65617275", "text": "draw() {\n for (let i = 0; i < this.cols; i++) {\n for (let j = 0; j < this.rows; j++) {\n push();\n\n stroke(255);\n strokeWeight(1);\n fill(51);\n\n rect(\n i * this.tileWidth,\n j * this.tileHeight,\n this.tileWidth,\n this.tileHeight\n );\n\n pop();\n }\n }\n\n for (let i = 0; i < this.cols; i++) {\n for (let j = 0; j < this.rows; j++) {\n if (this.belt[i][j] !== -1) {\n this.belt[i][j].draw(i);\n }\n }\n }\n }", "title": "" }, { "docid": "7b1b072084f5adda09cdc34103badcfb", "score": "0.6548579", "text": "function draw() {\n\nif (state === `title`){\nbackground(0);\ntitleText();\n\n}\nelse if(state === `simulation`){\nbackground(148, 221, 185); // greenish background\n\nupdateAnimals();\nupdateSausageDog();\n\ntimerTable.display(sausageDog);\n\nstopWarnings();\n\n}\nelse if(state === `badEnding`){\nbackground(170, 170, 170);\n// Display SausageDog\nsausageDog.display();\n// Display Rain\nimage(rain, width/2, height/2, width, height);\n\n}\n\n}", "title": "" }, { "docid": "97a39999f6e3920cd2a1f3b6f70c9eed", "score": "0.65485257", "text": "display1(){\r\n var pos = this.body.position;\r\n fill(\"white\");\r\n stroke(\"white\");\r\n rect(pos.x,pos.y,this.width,this.height);\r\n image(this.image,pos.x-105,pos.y-212,210,200);\r\n }", "title": "" }, { "docid": "55882cdb4b9ba6f4c58fac65d45a0176", "score": "0.65429413", "text": "function draw() {\n // Kleur de achtergrond blauw, zodat je het kunt zien\n background('blue');\n \n for(var i= 0; i < ballen.length; i++){\n ballen[i].show();\n ballen[i].update();\n }\n \n}", "title": "" }, { "docid": "3ef59e7a05306b37746aa149fd691ef1", "score": "0.6532658", "text": "draw() {\n //TODO\n }", "title": "" }, { "docid": "7c86e779b0877efcee88b872a5a65fd1", "score": "0.6519961", "text": "function draw() {\n\t\n\t// Draw the background before every thing else\n\t// This not done but what I am trying to do is set a img as a background\n if (bacONOFF) {\n if(!(bacImg == null))\n setBacIMG();\n else {\n background(bacColer);\n }\n }\n\t\n\t// Draw ever object that was in the list (click)\n simble();\n\t\n if (!(mouseX <= 0 | mouseX >= width | mouseY <= 0 | mouseY >= height)) {// see if the mouse is in the canvas\n drawSimbles(mouseX, mouseY, simle, sizeO, ObjectColer);// draw the idea of how it will look if click\n }\n}", "title": "" }, { "docid": "3ec7c95378d5dfff9f07944d86c433c7", "score": "0.6509456", "text": "function draw() {\n background(0);\n if (mouseX>width/2){\n \tbackground('#b5bace');\n }\n else{background (0);}\n \n noStroke();\n if (mouseIsPressed) {\n triangle(0, 200, -250, -150, 250, -150);\n } else {\n shapegroup1();\n shapegroup2();\n shapegroup3();\n }\n\n\n // shapes in da bkgd\n shapegroup1();\n shapegroup2();\n shapegroup3();\n // the sparkles on the side\n sparkle1();\n sparkle2();\n\n //a line\n stroke (255,204,0);\n fill(255,204,0);\n strokeWeight (4);\n line(-100,-200,100,-200);\n\n arc(0,230,80,80,0,PI);\n\nstroke(0);\nfill(255);\nstrokeWeight(1);\n //pyramid\n rotateY(millis() / 1000);\n cone(-60, -90);\n \n //torus\n rotateX(frameCount * 0.07);\n rotateY(frameCount * 0.05);\n torus(150, 25);\n\n}", "title": "" }, { "docid": "d493c3b53966675dc9379e962b820bcb", "score": "0.65067", "text": "function draw() \n{\n rectMode(CENTER);\n background(255);\n\n \n \n \n drawSprites();\n//Displaying Ball \n paper.display();\n//Displaying Ground \n ground.display();\n ground1.display();\n ground2.display();\n ground3.display();\n//Displaying Dustbin \n D1.display();\n D2.display();\n D3.display();\n}", "title": "" }, { "docid": "530cf4d040da4abcdb9a3c2c286224c4", "score": "0.65017986", "text": "draw() {\n }", "title": "" }, { "docid": "e1a5487134be49b4f08acef21623efeb", "score": "0.65001017", "text": "function draw() {\n\tbackground(0);\n\n\tvar i;\n\tfor(i=0;i<bubbles.length;i++){\n\t\tbubbles[i].move();\n\t\tbubbles[i].display();\n\t}\n\n\n}", "title": "" }, { "docid": "a2de5e1c5033d95e200f53b7e31632fe", "score": "0.6496616", "text": "draw() { // ← :/\r\n }", "title": "" }, { "docid": "2ecc1dd2c5e1f81b8c415ed9a09edfe4", "score": "0.6496258", "text": "function draw () {\n\n\n}", "title": "" }, { "docid": "51978c402ac1047332478840194251a7", "score": "0.64921504", "text": "draw() {}", "title": "" }, { "docid": "51978c402ac1047332478840194251a7", "score": "0.64921504", "text": "draw() {}", "title": "" }, { "docid": "cc6898dacf04f6d7fdacf9af53aff5d7", "score": "0.64836633", "text": "draw() {\n this.c.strokeStyle = \"#FF0000\";\n this.c.strokeRect(this.x, this.y, this.ancho, this.largo);\n }", "title": "" }, { "docid": "cce232d4561d6bc5dc154f3b3947d8d1", "score": "0.64802635", "text": "function draw() {\n\tframeRate(5); //define frame rate\n\tbackground('pink'); //draw background color defined in variable\n\n\tfor (i = 0; i < smileyQuantity; i = i + 1) {\n\t\tdrawSmiley(smileyX[i], smileyY[i], radius);\n\t\tmoveSmiley(smileyX[i], smileyY[i], smileyXspeed, smileyYspeed);\n\t}\n}", "title": "" }, { "docid": "a2bd205dd3c06373af4780ef4f858902", "score": "0.6470572", "text": "function draw(){\n\tdrawLines();\n\tdrawCells();\n}", "title": "" }, { "docid": "728ca179e3fa3499410195024cfeb78d", "score": "0.6469753", "text": "function draw() {\n hud.draw();\n map.draw();\n dots.draw();\n powerups.draw();\n ghosts.draw();\n\tplayer.draw();\n}", "title": "" }, { "docid": "0a6aa13e9adba7658bec06ace1e7224d", "score": "0.64695996", "text": "display() {\n push();\n fill(255, 60, 100);\n rect(this.x, this.y, this.size * 2, this.size * 2);\n\n pop();\n }", "title": "" }, { "docid": "2d62078f9e6cbdb387360d796a6bdaa6", "score": "0.64625657", "text": "function draw() {\n\tbackground('lightblue');\n\n\t// draw characters\n\timage(mrlair, mrlairX, mrlairY);\n\timage (jerry, jerryX, jerryY);\n image (ground, groundX, groundY);\n\t// narration\n\ttextSize(30);\n\ttextAlign(CENTER, CENTER);\n\ttext(story, width/4, 20, width/2);\n}", "title": "" }, { "docid": "2b846b102264073b9b5d39fd66506483", "score": "0.6462421", "text": "function draw(){\r\n\r\n ctx.drawImage(bg,0,0);\r\n //bg is background\r\n //bg is the image name, x position, y position. width, height\r\n //this is the background image which si the size of the whole page\r\n\r\n\r\n\r\n for(var i = 0; i < pipe.length; i++){\r\n\r\n constant = pipeNorth.height+gap;\r\n ctx.drawImage(pipeNorth,pipe[i].x,pipe[i].y);\r\n ctx.drawImage(pipeSouth,pipe[i].x,pipe[i].y+constant);\r\n\r\n pipe[i].x--;\r\n //what this function does is move the pipe from the right to left of the screen. it iterates through the for loop continuosly subtracting the x position from the right of the screen to the left and constantly pushing it into the array.\r\n\r\n if( pipe[i].x == 90 ){\r\n pipe.push({\r\n x : cvs.width,\r\n y : Math.floor(Math.random()*pipeNorth.height)-pipeNorth.height\r\n // in order to set a new pipe position, we use the math.random then we need actial sizes for the pipes which will be between 0 and the total pipe height\r\n });\r\n }\r\n //here if the pipe reaches the 188 pixel spot on the screen then we add a new pipe. this is responsible for the space between the pipes\r\n\r\n // detect collision\r\n\r\n if( bX + bird.width >= pipe[i].x && bX <= pipe[i].x + pipeNorth.width && (bY <= pipe[i].y + pipeNorth.height || bY+bird.height >= pipe[i].y+constant) || bY + bird.height >= cvs.height - fg.height){\r\n location.reload(); // reload the page\r\n }\r\n\r\n if(pipe[i].x == 5){\r\n score++;\r\n scor.play();\r\n }\r\n\r\n\r\n }\r\n\r\n ctx.drawImage(fg,0,cvs.height - fg.height);\r\n //fg stands for forground\r\n\r\n ctx.drawImage(bird,bX,bY);\r\n // this is drawing the image; we have the bird image, the x coordinate and the y coordinate..\r\n //var bX = 10;\r\n // var bY = 150;\r\n //above is the starting point for the coordinates\r\n\r\n\r\n bY += gravity;\r\n //this is gravity which is constantly increased by bY\r\n\r\n\r\n ctx.fillStyle = \"#000\";\r\n ctx.font = \"20px Verdana\";\r\n ctx.fillText(\"Score : \"+score,10,cvs.height-20);\r\n\r\n requestAnimationFrame(draw);\r\n //this constantly calls the draw function, which draws the images of the pipes, the bird, the background, the forground\r\n\r\n}", "title": "" }, { "docid": "64ba32cd5a2ae9c909c9cbb9eed7b3e4", "score": "0.64612216", "text": "display(){\r\n var pos = this.body.position;\r\n fill(\"white\");\r\n stroke(\"white\");\r\n rect(pos.x,pos.y,this.width,this.height); \r\n }", "title": "" }, { "docid": "dd40d64775a77a20dcd626fc442b63d5", "score": "0.64610124", "text": "draw() {\n // Draw the grid\n this.drawGrid();\n // Draw the snake\n this.drawSnake();\n // Draw the food\n this.drawFood();\n // Draw the game\n this.drawGame();\n }", "title": "" }, { "docid": "20a7030668d1d243d51725ee6e1f5a96", "score": "0.6455025", "text": "display() {\n image(b, this.pos.x, this.pos.y, 50, 50);\n }", "title": "" }, { "docid": "1cb572aa648220f54c2bbbc9051050fd", "score": "0.6449462", "text": "draw () {\n this.drawCylinder(this.bottomVertices, this.topVertices, 0, 0.5)\n this.drawCylinder(this.extrusionBottomVertices, this.extrusionTopVertices, 0.6, 0.8)\n this.drawCylinder(this.extrusionTopVertices, this.topVertices, 0.8, 0.85)\n this.drawRing(this.groundVertices, 51, true)\n }", "title": "" }, { "docid": "a573efa36a3a6d54daaaa830470ae5a3", "score": "0.6439647", "text": "display() {\n push();\n noStroke();\n fill(this.fillColor);\n rect(this.x, this.y, -this.width, this.height);\n image(this.image, this.x + 20, this.y + 10, 30, 30);\n pop();\n }", "title": "" }, { "docid": "77d3d98ffdf9013a76a498491a9911c5", "score": "0.6436759", "text": "display()\r\n {\r\n var pos = this.body.position;\r\n push();\r\n fill(\"yellow\");\r\n rect(pos.x, pos.y, this.w, this.h);\r\n pop();\r\n\r\n \r\n }", "title": "" }, { "docid": "225178371f8be2c29ef00c8e8d01bce0", "score": "0.64317536", "text": "display() {\n noStroke();\n fill(this.r, this.g, this.b, this.a);\n circle(this.x, this.y, this.radius * 2);\n }", "title": "" }, { "docid": "df64cfbd68a294f64d7c0b6fad9282e9", "score": "0.6429337", "text": "function dFrame(){\r\n\tctx.clearRect(0,0,1000,400);\r\n\tp.draw();\r\n\tsensor.draw();\r\n\tBoxes.forEach(function(b){b.draw();});\r\n}", "title": "" }, { "docid": "f30e81e386a2f23aa6d1b500da81c414", "score": "0.64293355", "text": "function render() {\r\n g.context.clearRect(0, 0, g.canvas.width, g.canvas.height);\r\n g.ship.draw();\r\n var i;\r\n i = 0;\r\n console.log(\"astronauts:\" + g.astronauts.length);\r\n while (i < g.astronauts.length ) {\r\n g.astronauts[i].draw();\r\n i++;\r\n }\r\n i = 0;\r\n while (i < g.stars.length) {\r\n g.stars[i].starDraw();\r\n i++;\r\n }\r\n}", "title": "" }, { "docid": "08392fece4797d26171735ecf39f52f7", "score": "0.6428244", "text": "function drawBeard2(){\n drawPolygon(\"white\",[topx-60,360,topx+60,360,topx,520]);\n}", "title": "" }, { "docid": "5dbb933b64a1dcca6e3fa8785e54a4e2", "score": "0.6423877", "text": "drawBall(){\n \tstroke(0);\n strokeWeight(1);\n \tfill(\"red\");\n\tellipse(this.x,this.y,this.size,this.size);\n\t}", "title": "" }, { "docid": "c1c2ed4296017bac67414314b6878ce2", "score": "0.64193803", "text": "display(){\n let blu = random(255);\n fill(0,0, blu);\n ellipse(this.posX, this.posY, this.w, this.h);\n }", "title": "" }, { "docid": "1dc6b083bb86e6c071fb785eba5a1ecb", "score": "0.6417613", "text": "function draw() {\n debugMode();\n orbitControl();\n\n background(240);\n\n for (let i = 0; i < asteroids.length; i++) {\n let asteroid = asteroids[i];\n\n asteroid.motion();\n asteroid.display();\n }\n}", "title": "" }, { "docid": "60863a56b69d32c6c9b2fa82f30fcabb", "score": "0.63976306", "text": "function render() {\n\t//game.debug.spriteInfo(game.bird, 10, 10);\n\t//game.debug.body(game.bird);\n\n}", "title": "" }, { "docid": "7e1fcb815b7aa9cf07930ea1581f4596", "score": "0.6396316", "text": "function draw(){\n background('#ECEBE4');\n \n if(game.isEnd === \"playerWin\"){\n drawPlayerWin();\n }\n //A. init object:\n //A-1: paddle:\n fill(paddle.fill)\n .noStroke();\n rect(paddle.x, paddle.y, paddle.width, paddle.height); //rect(x, y, width, height);\n //A-2: ball:\n fill(ball.fill);\n ellipse(ball.x, ball.y, ball.width);\n //A-3: bricks:\n bricksPlot.forEach(function(brick){\n fill(brick.fill)\n .stroke('gray')\n .strokeWeight(1);\n rect(\n brick.x,\n brick.y,\n brick.magnification,\n brick.magnification\n );\n fill('white');\n });\n \n //B. handle paddle:\n handleKeyPress();\n //C. handle ball:\n handleBall();\n //D. game rules: life & score information\n handleRules();\n}", "title": "" }, { "docid": "16f6cc091c133a47773f267c175591b6", "score": "0.63912565", "text": "function draw() {\n ctx.fillRect(0, 0, 700, 600);\n ctx.save();\n ctx.fillStyle = \"#fff\";\n\n ctx.fillRect(GAME.BALL.position.x, GAME.BALL.position.y, GAME.BALL.size, GAME.BALL.size);\n\n for (var ID in GAME.PLAYERS) {\n ctx.fillRect(GAME.PLAYERS[ID].position.x, GAME.PLAYERS[ID].position.y, GAME.PLAYERS[ID].dimensions.width, GAME.PLAYERS[ID].dimensions.height);\n }\n\n //ai.draw();\n // draw the net\n var w = 4;\n var x = (700 - w) * 0.5;\n var y = 0;\n var step = 600 / 20; // how many net segments\n while (y < 600) {\n ctx.fillRect(x, y + step * 0.25, w, step * 0.5);\n y += step;\n }\n ctx.restore();\n}", "title": "" }, { "docid": "cca1d3e22cad9fa0488dc4268e326ab7", "score": "0.6380894", "text": "function drawBricks() {\n bricks.forEach((rows) => {\n rows.forEach((brick) => {\n ctx.beginPath();\n ctx.rect(brick.x, brick.y, brick.w, brick.h);\n ctx.fillStyle = brick.visible ? \"#2f3061\" : \"transparent\";\n ctx.fill();\n ctx.closePath();\n });\n });\n }", "title": "" } ]
84beba8940d9acccc0ac91f12bffe5da
declaring abstractionfunction, which can be used by ALL animals on inventory list
[ { "docid": "e73dd837c51f1e1d46a564443a62285f", "score": "0.0", "text": "function numberPlacePaddingWithAppendableLabel(int_animalCount, int_numberPlaceWidth)\n {\n // line declares a variable(var) named 'string_animalCount' and initializes its value to a 'String',\n // representing the 'int_animalCount'(Integer data-type) value with commas, where needed(after every 3 0's)\n\n // this is accomplished by using the Integer.toLocaleString()-method, while using the string-'en'(english)\n // as an argument, to pass through its parameter\n var string_animalCount = int_animalCount.toLocaleString('en');\n\n // adding '.length'(an Object.String-property), after a string value will give us the 'length' of that string-value\n\n // This 'while'-loop will execute until the string-length is less than 'int_numberPlaceWidth'-value\n // (remember, the 'count' always starts at '0')\n while(string_animalCount.length < int_numberPlaceWidth)\n {\n // line adds a char representing an 'empty-space' to the beginning of the 'string_animalCount'-variable,\n // then stores it as the 'new' value of the 'string_animalCount'-variable\n string_animalCount = \" \" + string_animalCount;\n }\n\n // returns the value of the 'string_animalCount'-variable's value to the calling function(console.log();\n return string_animalCount\n }", "title": "" } ]
[ { "docid": "cca1065c1e8f3fdf151fc5eb1e76908e", "score": "0.668023", "text": "function inventory() {\n /**\n * accessing the inventory method from util\n */\n access.inventory(object);\n}", "title": "" }, { "docid": "9b5b0bfebd9d3d25adb7b2d096c8e32a", "score": "0.66443944", "text": "function animalShelter() {\n \n}", "title": "" }, { "docid": "e203a855c4ff1c70fb6dbea879098737", "score": "0.62025917", "text": "function addToInventory() {\n\n\n} //close addToInventory", "title": "" }, { "docid": "e81690a8d25c310135098c597b8c9d45", "score": "0.6145616", "text": "function myAnimal() {\n return animal\n}", "title": "" }, { "docid": "f99c4264062f75f269e1cbbf3b8a6ecf", "score": "0.6112911", "text": "function displayInventory() {\n\n}", "title": "" }, { "docid": "848822f4a131502b257fc5858176008b", "score": "0.6026755", "text": "function inventoryManagement() {\n try {\n access.inventory(details);\n /*\n *invoking inventory function from utility file\n */\n } catch (error) {\n console.log(error.message);\n }\n}", "title": "" }, { "docid": "68569f381aad1e5a1fe90ec3fca1bd55", "score": "0.59543246", "text": "function makeIngredient() {\n\n }", "title": "" }, { "docid": "1276d46b1b9b1e30e90e161163be6afa", "score": "0.5875621", "text": "function addFoodItems() {\n\n\n}", "title": "" }, { "docid": "d1135f911387990ebd954590f4d9142b", "score": "0.5827331", "text": "function AnimalPets(animal,name) {\n this.typeAnimal = animal\n this.name = name\n this.facts = function() {\n console.log(`${this.name} the ${this.typeAnimal} is super obedient and fluffy!`)\n }\n}", "title": "" }, { "docid": "27c402d18454b5be43bbe66f5fc9afa1", "score": "0.57349354", "text": "function Animal(species, name, diet) {\n this.diet = diet;\n this.name = name;\n this.species = species;\n this.description = function() {\n console.log(\"The name of this animal is \" + this.name + \". It belongs to the species \" + this.species);\n };\n this.eats = function() {\n console.log(\"This animal has a \" + diet + \" diet.\");\n }\n\n}", "title": "" }, { "docid": "e31a2f26ada8bea0793c5000d188679e", "score": "0.567754", "text": "manageInventory(){\n alert('Inventory action!');\n }", "title": "" }, { "docid": "bd0bbbc21fd5e4ea8d4f5d5163695941", "score": "0.56129944", "text": "function Animal(name, energy){\n let animal = {};\n animal.name = name;\n animal.energy = energy;\n \n animal.eat = function(amount){\n console.log(this.name + \" is eating\");\n //console.log(`${this.name} is eating`);\n this.energy += amount;\n }\n\n animal.sleep = function(length){\n console.log(this.name + \" is sleeping\")\n this.energy += length;\n }\n \n animal.play = function(length){\n console.log(this.name + \" is playing\");\n this.energy -= length;\n }\n \n return animal;\n}", "title": "" }, { "docid": "a827c0b690ace16ab9edf99583a27ea2", "score": "0.56125766", "text": "function Animal() {}", "title": "" }, { "docid": "238cd90d6c8be39757ae7118d21bbd35", "score": "0.55654204", "text": "function addFiveStarsToTheProductShirt() {\n\n}", "title": "" }, { "docid": "a68c28005cee2011bfe43a663658ef18", "score": "0.55524325", "text": "function printItem(food){\n console.log(food);\n}", "title": "" }, { "docid": "7c8562bad9348143156b4e12353e5db9", "score": "0.5547798", "text": "function logAnimals(animals) {\n// function logAnimals(animals: Array<Animal>) {\n animals.forEach(animal => console.log(`Animal: ${animal.name}`));\n}", "title": "" }, { "docid": "8465939f6bb1ae63454c9eae52a70c80", "score": "0.55471975", "text": "function Animal(){\n\n}", "title": "" }, { "docid": "8bd28619231757cf0899b791b776afe4", "score": "0.5509467", "text": "function Animal() { \n}", "title": "" }, { "docid": "7a155a782e8d9148ae954c30eabe092c", "score": "0.5479231", "text": "function Animal_V3(name, energy) {\n // Use function's prototype as backstop for missing methods\n var animal = Object.create(Animal_V3.prototype); // Member variables\n\n animal.name = name;\n animal.energy = energy; // Member functions\n\n Animal_V3.prototype.eat = function (amount) {\n console.log(\"\".concat(this.name, \" is eating.\"));\n this.energy += amount;\n };\n\n Animal_V3.prototype.sleep = function (length) {\n console.log(\"\".concat(this.name, \" is sleeping.\"));\n this.energy += length;\n };\n\n Animal_V3.prototype.play = function (length) {\n console.log(\"\".concat(this.name, \" is playing.\"));\n this.energy -= length;\n };\n\n return animal;\n}", "title": "" }, { "docid": "441f17cd94ea5c8ea293c94943f4edd9", "score": "0.54503083", "text": "function inventoryControl(adminChoice){\n \n switch (adminChoice) {\n \n case \"Review\":\n return review();\n \n case \"Replenish\":\n return replenish();\n\n case \"Remove\":\n return deleteItem();\n\n case \"Create\":\n return createItem();\n \n case \"Quit\":\n console.log(`Goodbye ${userName}. \\nSee you Again!`)\n connection.end();\n }\n\n}", "title": "" }, { "docid": "756f4734e9e2a87832e51d9445e51541", "score": "0.54419553", "text": "function inventoryFactory(name,weight,price){\n//pushing new object in the list\n data.inventory.push({\n \"name\": name,\n \"weight\": weight,\n \"price\": price\n });\n // calculation total price of the inventory\n for(ind in data.inventory){\n console.log(\"Name: \"+data.inventory[ind].name+\"\\n\"+\"Cost: \"+(parseFloat(data.inventory[ind].weight)\n *parseFloat(data.inventory[ind].price)));\n total=total+(parseFloat(data.inventory[ind].weight)*parseFloat(data.inventory[ind].price));\n }\n console.log(\"Total : \"+total);\n}", "title": "" }, { "docid": "0a3942476f8ef05b4ccd69992a87af7f", "score": "0.54409814", "text": "handleAnimalChange() {}", "title": "" }, { "docid": "f542d0bca49afed31afd3e84c699a092", "score": "0.54342157", "text": "function checkInventory(scannedItem) {\n // change code below this line\n return foods[scannedItem];\n}", "title": "" }, { "docid": "ff86b1d66ba748f980348c4910cf2c0f", "score": "0.54222524", "text": "function create_animal() {\n\treturn \"Cat\"\n}", "title": "" }, { "docid": "f2a20c8083a3253f06f3d8f5e74bf302", "score": "0.541979", "text": "function animal(takesName,takesType,takesWeight,takesCountry,takesDomesticated){\n this.name=takesName;\n this.type=takesType;\n this.weight=takesWeight;\n this.country=takesCountry;\n this.domesicated=takesDomesticated;\n}", "title": "" }, { "docid": "55885235a407b48cc6593a45a2c4922e", "score": "0.53991854", "text": "function checkInventory(scannedItem) {\n // change code below this line\n return foods[scannedItem];\n}", "title": "" }, { "docid": "3423a2456c6a1dc073d4d88b5b1ca94b", "score": "0.53988355", "text": "function addItem(inventory, itemName, itemDesc, itemValue, itemPic) {\n // Get Inventory type\n var type = $('#inventoryType').html().toLowerCase();\n\n $.each(inventory, (key, items) => {\n // Key == home, auto, business\n if (key === type) {\n var newItem = new Item(itemName, itemDesc, itemValue, itemPic);\n inventory[type][inventory[type].length] = newItem;\n }\n });\n\n $('#addItemResetBtn').click();\n return inventory;\n}", "title": "" }, { "docid": "7e13151a609d31b3e52fa95d3b182b50", "score": "0.53540725", "text": "function bindEquipListener(){\n\t\t$('.equippable-item').click(function(){\n\t\t\tequippableItemClicked($(this).data('component-id'));\n\t\t});\n\t}", "title": "" }, { "docid": "07a3e76cdb1427d8f3e0e0e54ffc6e0c", "score": "0.53485", "text": "getInventory() {\n return pets\n }", "title": "" }, { "docid": "ef4acd6ffb457e9ab45d60eef1c92bd8", "score": "0.5344759", "text": "function Animal_V1(name, energy) {\n var animal = {}; // Member variables\n\n animal.name = name;\n animal.energy = energy; // Member functions\n\n animal.eat = function (amount) {\n console.log(\"\".concat(this.name, \" is eating.\"));\n this.energy += amount;\n };\n\n animal.sleep = function (length) {\n console.log(\"\".concat(this.name, \" is sleeping.\"));\n this.energy += length;\n };\n\n animal.play = function (length) {\n console.log(\"\".concat(this.name, \" is playing.\"));\n this.energy -= length;\n };\n\n return animal;\n}", "title": "" }, { "docid": "28ca402aa4b29c1be1cf496c8a58889c", "score": "0.5326238", "text": "function Animal(name, energy){\n let animal = {};\n animal.name = name;\n animal.energy = energy;\n animal.eat = animalMethods.eat;\n animal.sleep = animalMethods.sleep;\n animal.play = animalMethods.play;\n\n return animal;\n }", "title": "" }, { "docid": "919320d5fb23e4dda10ade5b5305bf98", "score": "0.5309372", "text": "function checkInventory(scannedItem) {\n // change code below this line\n\n}", "title": "" }, { "docid": "37f5173400df378853ff7d03cb26f0a3", "score": "0.53090984", "text": "function Item() { }", "title": "" }, { "docid": "ce700ea950d20daf85cc4659c0a928f0", "score": "0.53046733", "text": "function pig(diet) {\n FarmAnimal.call(this, 'diet', 'pig', 'oink', 'https://www.google.com/search?q=farm+pig&rlz=1C5CHFA_enUS750US750&tbm=isch&imgil=fvYtmNj3RxDNiM%253A%253BFV3LNMwVv0WsOM%253Bhttps%25253A%25252F%25252Fwww.farmsanctuary.org%25252Flearn%25252Fthe-someone-project%25252Fpigs%25252F&source=iu&pf=m&fir=fvYtmNj3RxDNiM%253A%252CFV3LNMwVv0WsOM%252C_&usg=__L0w5kllUDNCJz821bHgdRlw2yU8%3D&biw=1440&bih=803&ved=0ahUKEwiKytPxjbXVAhUIqlQKHXaBDgQQyjcIMw&ei=fvd_WYqTGojU0gL2grog#imgrc=OEfsRPgGPNoR3M:')\n this.action = function(){\n }\n}", "title": "" }, { "docid": "62ff288dcbda47658641caf86c3cb645", "score": "0.5294478", "text": "harvestOrange(){\n\n }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "fe9b8207a51762640cd2991d22de5140", "score": "0.52935743", "text": "function Animal() { }", "title": "" }, { "docid": "f24dac77a9783144936a35e7c2f5bacf", "score": "0.5270703", "text": "function animalDetails(type, place) {\n return this.name + ' ' + type + ' ' + place;\n}", "title": "" }, { "docid": "a56c91900cb1a480abf7f4596ce6be6e", "score": "0.52659976", "text": "constructor(str, dmg, magic, price){\n\t\tthis.name = str;\n\t\tthis.healthIncrease = dmg;\n\t\tthis.magicIncrease = magic;\n\t\tthis.price = price;\n\t\tthis.isWeapon = false;\n\t\tthis.itemTypeNumber = 3; \n\t\t// supposed to represent total number of item types\n\t\t// \n\t}", "title": "" }, { "docid": "d7ee07cf61ac00018836283452cfe359", "score": "0.5251741", "text": "function addToInventory() {\n //query all products like just in option1, for reference\n viewProductsForSale();\n}", "title": "" }, { "docid": "2964b7c0a75c71a176ea18cad0f71866", "score": "0.52506745", "text": "function Animal(food) {\n this.food = food;\n this.eat = function() {\n console.log(`This animal likes to eat ${this.food}`);\n }\n}", "title": "" }, { "docid": "0dad7a28befe078d4dd4dc79199fc243", "score": "0.5247675", "text": "function Fruit() {}", "title": "" }, { "docid": "a2480c1d994632b9bdd1399931f3a182", "score": "0.5244348", "text": "function Bizzy () {}", "title": "" }, { "docid": "dda314cc8bd61ce21456442b63bdbb2f", "score": "0.5238835", "text": "function addToInventory() {\n\tconsole.log('work in progess')\n\twhatToDo()\n}", "title": "" }, { "docid": "2a6fcbbb32e666052feb53b4f84d57e1", "score": "0.5234104", "text": "function iron(clothing_item){\n return clothing_item.toLowerCase();\n}", "title": "" }, { "docid": "cab385bb9a233dc46bfba34e24e16aa3", "score": "0.5232704", "text": "function StuffedAnimal (id,name,type) {\r\n\tthis.id = stashList.length +1;\r\n\tthis.name = name;\r\n\tthis.type = type;\r\n}", "title": "" }, { "docid": "b209cf483ea3fb3f0d85649f82041b59", "score": "0.5231732", "text": "function inventory() {\n connection.query(\"SELECT * FROM products \", function (err, response) {\n if (err) throw err;\n console.table(response);\n menuOptions();\n });\n}", "title": "" }, { "docid": "37cd6d6a308e39277847c5fad5094732", "score": "0.5227705", "text": "function FindWood() { //This would become [Look, BrainLook, MoveForward]\n Behaviour.call(this);\n}", "title": "" }, { "docid": "9056ea44f444dcc0ce028d9f6b521b2c", "score": "0.52224845", "text": "function interact(genericInteraction, name){\n console.log(genericInteraction(name));\n}", "title": "" }, { "docid": "ad4ebdc24e318e83b3829c7a7734c610", "score": "0.5217625", "text": "function Juicer() {}", "title": "" }, { "docid": "f31b885811857ed0fdc22d45ac14c7d3", "score": "0.52083474", "text": "function callExtendedSortableFunctionOnItemChanged(uiItemChanged) {\n var ulParent = $(uiItemChanged).parent();\n var functionName = $(ulParent).closest('.gridMultiSelector-choice').attr(\"data-onitemcreate-functionname\");\n if (typeof (functionName) != \"undefined\" && functionName != \"\") {\n window[functionName]($(uiItemChanged));\n }\n}", "title": "" }, { "docid": "76d701525b0496644bef4bc43a6f7241", "score": "0.5193021", "text": "function inventoryTable() {\n\n connection.query(\"SELECT * FROM products\", function(err, res) {\n if (err) throw err;\n console.table(res);\n\n customerItem(res);\n });\n}", "title": "" }, { "docid": "39391f879349dc8554f9fe00685ef15d", "score": "0.5190743", "text": "adminGetInventory({ characterName }) {\n const data = commonGet('darksteam97d99i/characters/inventory', [characterName]);\n return data;\n }", "title": "" }, { "docid": "0597e79725dffe53e8cf1898718645ed", "score": "0.5181292", "text": "onInteract() {\n // Filter out the hammer\n var items = player.getInventory().getItems().filter(item => item.name != \"hammer\");\n\n // If we have an item in the inventory which is usable for placing on the plate...\n if (items.length > 0) {\n // Remove it from the inventory, update the sprite, and enable the pressure plate\n player.getInventory().removeItemByName(items[0].name);\n this.item.sprite.setSpritesheet(items[0].image);\n this.item.sprite.show();\n this.itemPlaced = items[0];\n this.setState(true);\n } else {\n utils.displayDialogBox(\"I need something heavy...\", 2000);\n }\n }", "title": "" }, { "docid": "8b1056775f312b5f3f31cec60060a5f6", "score": "0.51671314", "text": "function describerecipe(arecipe){\n\n console.log('Recipe serving(in function) :', arecipe.serving);\n console.log('Recipe rating(in function) :', arecipe.rating);\n\n}", "title": "" }, { "docid": "99f3ebdc96c6780c8919d628e7fcc170", "score": "0.5153492", "text": "function Item(fun,array){this.fun=fun;this.array=array}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "e7dcc3b19988f437486fa3b0b3694899", "score": "0.51526624", "text": "function Item(fun,array){this.fun=fun;this.array=array;}", "title": "" }, { "docid": "4e66432d0ff7bcfc1280c0a64e060efa", "score": "0.5149631", "text": "function Item(fun,array){this.fun = fun;this.array = array;}", "title": "" }, { "docid": "4e66432d0ff7bcfc1280c0a64e060efa", "score": "0.5149631", "text": "function Item(fun,array){this.fun = fun;this.array = array;}", "title": "" }, { "docid": "4e66432d0ff7bcfc1280c0a64e060efa", "score": "0.5149631", "text": "function Item(fun,array){this.fun = fun;this.array = array;}", "title": "" }, { "docid": "4e66432d0ff7bcfc1280c0a64e060efa", "score": "0.5149631", "text": "function Item(fun,array){this.fun = fun;this.array = array;}", "title": "" }, { "docid": "c3bc4eeea0ed19af6334c60a2b08fe61", "score": "0.51390445", "text": "function AnimalSetup(nameInput = 'doggo') {\n const name = nameInput;\n let food = 'pudding';\n\n function eats(foodInput) {\n food = foodInput;\n }\n\n function dinner() {\n return `${name} eats ${food || 'nothing'} for dinner.`;\n }\n\n return {\n eats,\n dinner,\n };\n}", "title": "" }, { "docid": "7afc0627151545449a6e4800146df9eb", "score": "0.51313335", "text": "function inventoryAdd(item) {\n\titem.moveTo(inventory_layer);\n\titem.clearImageHitRegion();\n\titem.setScale(1);\n\titem.setSize(80, 80);\n\tif (item.getAttr('category') != 'reward') {\n\t\titem.setAttr('category', 'usable');\n\t}\n\titem.setDraggable(true);\n\n\tredrawInventory();\n}", "title": "" }, { "docid": "b27017e3bbd15aac6c658af7796b5bda", "score": "0.5125351", "text": "function Animal_V2(name, energy) {\n // Member function picked up from animalMethods\n var animal = Object.create(animalMethods); // Member variables.\n\n animal.name = name;\n animal.energy = energy;\n return animal;\n}", "title": "" }, { "docid": "cd8b5d7cc49d38f5a03fe75fc4b6a405", "score": "0.5121901", "text": "function _addToInventory(data) {\n\t//create the class / ref to the image\n\tvar className = 'r' + data.name,\n\t\tlevelFolder = 'level' + ($game.$player.currentLevel + 1),\n\t\timgPath = CivicSeed.CLOUD_PATH + '/img/game/resources/' + levelFolder + '/small/' + data.name +'.png';\n\t\t//tagline = $game.$resources.getTagline(index);\n\t//put image on page in inventory\n\t$inventory.prepend('<img class=\"inventoryItem '+ className + '\"src=\"' + imgPath + '\" data-placement=\"top\" data-original-title=\"' + data.tagline + '\">');\n\n\t$('.' + className).bind('mouseenter',function() {\n\t\t//var info = $(this).attr('title');\n\t\t$(this).tooltip('show');\n\t});\n\t$inventoryBtn.text(_inventory.length);\n\n\t//bind click and drag functions, pass npc #\n\t$('img.inventoryItem.'+ className)\n\t\t.bind('click', function() {\n\t\t\t//false means don't go straight to answers\n\t\t\t$game.$resources.beginResource(data.npc, false);\n\t\t})\n\t\t.bind('dragstart',{npc: data.npc + ',' + data.name}, $game.$botanist.dragStart);\n}", "title": "" }, { "docid": "2c212dbb1eb8c42ea430c08ef29453bf", "score": "0.51217395", "text": "function Animal(name){\n this.name = name;\n this.jump = function(){\n alert (this.name + \" is jumping...\");\n };\n\n this.eat = function(){\n alert (this.name + \" is eatting...\");\n };\n}", "title": "" }, { "docid": "0d5fe162df5495aeeb8b2b5ac1ec8ca4", "score": "0.51215184", "text": "function inventory() {\n console.log(\"\")\n console.log(\"Doorkey: \" + doorkey + \" Sword: \" + sword + \" Mirror Shield: \" + mirrorShield + \" Torch: \" + torch + \" Gorgon Head: \" + gorgonHead);\n console.log(\"\");\n\n}", "title": "" }, { "docid": "3ea56534aef18a7900255e50b280efbd", "score": "0.51171255", "text": "function Animal(name, type, weight, legs) {\n this.name = name;\n this.type = type;\n this.weight = weight;\n this.legs = legs;\n this.byte = function(name) {\n console.log(`${this.name} the ${this.type} done bit ${name}!`);\n }; /**/\n}", "title": "" }, { "docid": "dd46f232f83bcb47e7c9b77884aafab6", "score": "0.51103634", "text": "function Food_item(brand,name,cal,calfat,chol,fib,prot,satfat,serv_sz,serv_un,ser_per_con,sodi,sug,carb,fat) {\n\tthis.brand = brand;\n\tthis.name = name;\n\tthis.cal = cal;\n\tthis.calfat = calfat;\n\tthis.chol = chol;\n\tthis.fib = fib;\n\tthis.prot = prot;\n\tthis.satfat = satfat;\n\tthis.serv_sz = serv_sz;\n\tthis.serv_un = serv_un;\n\tthis.ser_per_con = ser_per_con;\n\tthis.sodi = sodi;\n\tthis.sug = sug;\n\tthis.carb = carb;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" }, { "docid": "ca01081b98764d49bf50d7e67cd85562", "score": "0.51090294", "text": "function Item(fun, array) {\n this.fun = fun;\n this.array = array;\n}", "title": "" } ]
daeb780409d45fd5f42a84523f5266f0
If an image is still, set it to move. If it's moving, set it to still.
[ { "docid": "232d0fbfdc2c2e31f16bde38d9369ab5", "score": "0.7352466", "text": "function toggleMovement(){\n var state = $(this).attr(\"image-state\");\n\n if (state === \"still\")\n {\n $(this).attr(\"src\", $(this).attr(\"image-moving\"));\n $(this).attr(\"image-state\", \"animate\");\n }else{\n $(this).attr(\"src\", $(this).attr(\"image-still\"));\n $(this).attr(\"image-state\", \"still\"); \n }\n}", "title": "" } ]
[ { "docid": "d269d167d3caad8cec932836b4b8cd8c", "score": "0.6716991", "text": "function moveImage() {\r\n\t\t\r\n\t\t// move downs\r\n\t\tif (imgTopPosition < 270 && imgLeftPosition == 450) {\r\n\t\t\timgTopPosition++;\r\n\t\t\timgElement.style.top = imgTopPosition + 'px';\r\n\t\t\t\r\n\t\t} else if ( imgLeftPosition < 720 && imgTopPosition == 270) {\r\n\t\t\t\r\n\t\t\timgLeftPosition++;\r\n\t\t\timgElement.style.left = imgLeftPosition + 'px';\r\n\t\t\t\r\n\t\t} else if (imgTopPosition > 0) { \r\n\t\t\t\r\n\t\t\timgTopPosition--;\r\n\t\t\timgElement.style.top = imgTopPosition + 'px';\r\n\t\t\t\r\n\t\t} else if ( imgLeftPosition > 450 ) {\r\n\t\t\t\r\n\t\t\timgLeftPosition--;\r\n\t\t\timgElement.style.left = imgLeftPosition + 'px';\r\n\t\t\t\r\n\t\t}\r\n\t\t\r\n\t }", "title": "" }, { "docid": "410924650291ec3d0370b632ed3aa35f", "score": "0.6693052", "text": "function moveImage(){\n id = setInterval(frame, 5);\n function frame() {\n if(type_of_movement == 0){\n if (initial_top > final_top) {\n clearInterval(id);\n count++;\n } else {\n initial_top+=step_top; \n initial_left+=step_left;\n elem.style.top = initial_top + 'px'; \n elem.style.left = initial_left + 'px'; \n }\n }\n else if(type_of_movement == 1){\n if (initial_top < final_top) {\n clearInterval(id);\n count++;\n } else {\n initial_top+=step_top; \n initial_left+=step_left;\n elem.style.top = initial_top + 'px'; \n elem.style.left = initial_left + 'px'; \n \n }\n }\n } \n}", "title": "" }, { "docid": "a9d34b5820605542edbae984d59a9e9a", "score": "0.6676187", "text": "function moveImage() {\n\t\t//move down\n\t\tif (imgTopPosition < 270 && imgLeftPosition == 450) {\n\n\t\t\timgTopPosition++;\n\t\t\timgElement.style.top = imgTopPosition + \"px\";\n\n\t\t} else if (imgLeftPosition < 720 && imgTopPosition == 270) {\n\n\t\t\timgLeftPosition++;\n\t\t\timgElement.style.left = imgLeftPosition + \"px\";\n\t\t\n\t\t} else if (imgTopPosition > 0) {\n\n\t\t\timgTopPosition--;\n\t\t\timgElement.style.top = imgTopPosition + \"px\";\n\t\t\n\t\t} else if (imgLeftPosition > 450) {\n\t\t\t\n\t\t\timgLeftPosition--;\n\t\t\timgElement.style.left = imgLeftPosition + \"px\";\n\t\t\n\t\t}\n\n\t}", "title": "" }, { "docid": "444b280e269e6484ff010d61ee880259", "score": "0.6664613", "text": "function move() {\n\tif (leftArrow) {\n\t\tif (playerImage.x > sidebarImage.getBounds().width) {\n\t\t\tplayerImage.x -= PLAYER_MOVE_SPEED;\n\t\t}\n\t}\n\tif (rightArrow) {\n\t\tif (playerImage.x < STAGE_WIDTH - playerImage.getBounds().width) {\n\t\t\tplayerImage.x += PLAYER_MOVE_SPEED;\n\t\t}\n\t}\n}", "title": "" }, { "docid": "9bf6fee8b0e506023281e31b97b1c6c1", "score": "0.64508575", "text": "function animateImg() {\r\n var state = $(this).attr(\"data-state\");\r\n if (state === \"still\") {\r\n $(this).attr(\"src\", $(this).attr(\"data-animate\"));\r\n $(this).attr(\"data-state\", \"animate\");\r\n } else {\r\n $(this).attr(\"src\", $(this).attr(\"data-still\"));\r\n $(this).attr(\"data-state\", \"still\");\r\n }\r\n }", "title": "" }, { "docid": "24aae59f21742fb746ad8467efb8f192", "score": "0.639686", "text": "function moveForward(){\n setCurrentImage((currentImage+1)%images.length)\n }", "title": "" }, { "docid": "e9f97a07e305a492a53e9f187b32afde", "score": "0.6345533", "text": "function prevImage(){\n if(!moving){\n moving = true;\n if (currentIndex === 0){\n currentIndex = images.length-1;\n direction = 'left';\n speed = DEFAULT_SPEED*2.5;\n moveImage();\n }\n else{\n currentIndex --;\n direction = 'right';\n moveImage(); \n }\n }\n\n}", "title": "" }, { "docid": "0dda23c4dad213f6ec7a781af5ac2659", "score": "0.6339096", "text": "move() {\n //If the position x of shoot is out of canvas\n if (this.x > WIDTH)\n //Then deactivate the shoot\n this.active = LifeState.DISACTIVE;\n //Else move\n super.move();\n }", "title": "" }, { "docid": "be9f963809b344b3c776b621a9d815eb", "score": "0.63309586", "text": "function changeImgState(img) {\n\t// sets conditions for changing states\n\tif (img.data('current_state') === 'still') {\n\t\timg.attr('src', img.data('motion_state'))\n\t\t\t.data('current_state', 'motion');\n\t}\n\telse if (img.data('current_state') === 'motion') {\n\t\timg.attr('src', img.data('still_state'))\n\t\t\t.data('current_state', 'still');\n\t}\t\n}", "title": "" }, { "docid": "69164df970a7a39c4fb2b26316436b34", "score": "0.63072294", "text": "function turnAround(){\n\tfacingRight = !facingRight;\n\t//change image\n}", "title": "" }, { "docid": "15618ca5b8765758db401481ec34bd5b", "score": "0.6224771", "text": "function movable(){\r\n\t\toldTop = parseInt(this.style.top);\r\n\t\toldLeft = parseInt(this.style.left);\r\n\t\tif (oldTop == emptyTop && oldLeft == (emptyLeft-100) || oldTop == emptyTop && oldLeft == (emptyLeft+100) || oldTop == (emptyTop-100) && oldLeft == emptyLeft || oldTop == (emptyTop+100) && oldLeft == emptyLeft){\r\n\t\tthis.addClassName(\"movablepiece\");\r\n\t\t\t\t\r\n\t\t}\r\n\t\telse{\r\n\t\tthis.removeClassName(\"movablepiece\");\r\n\t}\r\n\t}", "title": "" }, { "docid": "ba7a09f674570a83ef558d03843b905b", "score": "0.6221859", "text": "function animateGif() {\n var state = $(this).attr(\"data-state\"); //puts the data value into the state variable\n // console.log(this)\n if (state == \"still\") { //if the gif is still, this makes it move\n $(this).attr(\"src\", $(this).attr(\"data-animate\"));\n $(this).attr(\"data-state\", \"animate\");\n } else { //if the gif is moving this makes it still\n $(this).attr(\"src\", $(this).attr(\"data-still\"));\n $(this).attr(\"data-state\", \"still\");\n } //end of else\n }", "title": "" }, { "docid": "abc6812756712b8717662163020980d8", "score": "0.61810493", "text": "function gifMovement() {\n var state = $(this).attr(\"data-state\"); //assign a variable to see what the current state is\n\n var animatedImage = $(this).attr(\"data-animate\");\n var stillImage = $(this).attr(\"data-still\");\n\n if (state == \"still\") { //if the state is moving\n $(this).attr(\"src\", animatedImage); //then change the src so that it's pulling the still image from the api\n $(this).attr(\"data-state\", \"data-animate\"); //change the data state to still\n } else { //otherwise if the state is still...\n $(this).attr(\"src\", stillImage); //change the src so that it's pulling the moving image from the api\n $(this).attr(\"data-state\", \"data-still\"); //change the data state to animate\n }\n }", "title": "" }, { "docid": "fdca3fe56d8e09cd8969f7868c961fc7", "score": "0.61587745", "text": "function toggleImage() {\n var state = $(this).attr(\"data-state\");\n\n if (state === \"still\") {\n $(this).attr(\"src\", $(this).attr(\"data-animate\"));\n $(this).attr(\"data-state\", \"animate\");\n } else {\n $(this).attr(\"src\", $(this).attr(\"data-still\"));\n $(this).attr(\"data-state\", \"still\");\n }\n }", "title": "" }, { "docid": "b8ac5cde9a82e6a1021ac5c04b95a730", "score": "0.6150929", "text": "public function move(){\n\t\tmove(1);\n\t}", "title": "" }, { "docid": "09c68a4298ec98dafb7b9fe779e2016c", "score": "0.61474794", "text": "function nextImage(){\n if(!moving){\n moving = true;\n currentIndex ++;\n if (currentIndex === images.length){\n currentIndex = 0;\n direction = 'right';\n speed = DEFAULT_SPEED*2.5;\n moveImage(); \n }\n else{\n direction = 'left';\n moveImage();\n }\n }\n\n\n}", "title": "" }, { "docid": "3dcdf85da57ba159963c4678f955bd8c", "score": "0.6121529", "text": "function move() {\r\n\r\n\tif(parseInt(robot.style.left)<=parseInt(window.innerWidth)){\r\n\t\trobot.style.left=robot.offsetLeft+(parseInt(amount.value)||10)+'px';\r\n\t\tanim=setTimeout(move,speed.value);\r\n }\r\n //If the image's left position is greater than the screen width, the position is reset.\r\n\telse{\r\n\t\trobot.style.left=(parseInt(robot.style.left)*-.7)+'px';\r\n\t\trobot.style.left=robot.offsetLeft+(parseInt(amount.value)||10)+'px';\r\n\t\tanim=setTimeout(move,speed.value);\r\n}\r\n\r\n}", "title": "" }, { "docid": "a3e4c5218bebab69d8e41d6b2510106b", "score": "0.6119604", "text": "function move(){\r\n\thuman.style.left = parseInt(human.style.left) + 5 + 'px'\r\n\timageNumber++;\r\n\timageNumber = imageNumber % 4\r\n\tdocument.getElementById(\"human\").src = \"images/c_\" + imageNumber + \".png\";\r\n}", "title": "" }, { "docid": "09b63ec3e7cb34b367965c1201b6bb22", "score": "0.6054081", "text": "idle() {\n let sprite = this.sprite;\n\n this.vx = 0;\n this.vy = 0;\n\t\t\t\n sprite.stopAnimation();\n }", "title": "" }, { "docid": "3765843f69f3deab14f43447e6f3d2c6", "score": "0.60516495", "text": "function controlGif() {\n // The attr jQuery method allows us to get or set the value of any attribute on our HTML element\n var state = $(this).attr(\"data-state\");\n // If the clicked image's state is still, update its src attribute to what its data-animate value is.\n // Then, set the image's data-state to animate\n // Else set src to the data-still value\n if (state === \"still\") {\n $(this).attr(\"src\", $(this).attr(\"animate-url\"));\n $(this).attr(\"data-state\", \"animate\");\n } else {\n $(this).attr(\"src\", $(this).attr(\"still-url\"));\n $(this).attr(\"data-state\", \"still\");\n };\n }", "title": "" }, { "docid": "50609f15b76c35b6e7a861043dcbc8bd", "score": "0.6050025", "text": "function moveBackward(){\n let newImage = currentImage-1;\n if (newImage < 0){\n newImage = images.length -1;\n } \n setCurrentImage(newImage)\n }", "title": "" }, { "docid": "d369db4bda62c90bc010edc110516b30", "score": "0.6049122", "text": "move() {\n if (this.prev instanceof SnakePiece) {\n this.x = this.prev.x;\n this.y = this.prev.y;\n this.direction = this.prev.direction;\n return;\n }\n\n switch(this.direction) {\n case Direction.UP : this.y--; break;\n case Direction.DOWN : this.y++; break;\n case Direction.LEFT : this.x--; break;\n case Direction.RIGHT : this.x++; break;\n case Direction.NONE : break;\n default: break;\n }\n }", "title": "" }, { "docid": "aee7a9bd3b9aaf81186630fc21e58edc", "score": "0.604278", "text": "changeImage(direction) {\r\n if (this.hasImg(this.imgNum + direction)) {\r\n this.imgNum += direction;\r\n this.setState({});\r\n return true;\r\n } else {\r\n return this.changeSubgroup(direction, direction === 1);\r\n }\r\n }", "title": "" }, { "docid": "26185b8dcd53f9c2300e956ba5ed7999", "score": "0.602264", "text": "function myMoveDown()\n{\n var elem=document.getElementById(\"animate\");\n var picture=document.getElementById(\"image\");\n var quoteColor=document.getElementById(\"quote\");\n var containerColor=document.getElementById(\"container\");\n var pos=0;\n var id=setInterval(frame,3);\n image.src = \"images/hardwork2.jpg\";\n quoteColor.style.color=\"#f2a104\";\n containerColor.style.backgroundColor=\"#192e5b\";\n function frame(){\n\n if(pos==350){\n clearInterval(id);\n myMoveLeft();\n }\n else{\n pos++;\n elem.style.top=pos+\"px\";\n }\n }\n}", "title": "" }, { "docid": "248012f19e6b1b38d6369ee02f7cb514", "score": "0.60220176", "text": "move(x, y) {\n var newX = this.activeX + x\n var newY = this.activeY + y\n if (this.validPosition(newX, newY, this.shape.pos)) {\n this.clearActive()\n this.activeX = newX\n this.activeY = newY\n this.addActive()\n this.render()\n }\n if (this.shouldStop()){\n this.stop()\n }\n }", "title": "" }, { "docid": "a8d5cbc9e05b7f179fead5e857146df7", "score": "0.6020123", "text": "function move(dir) {\n myGamePiece.image.src = \"images/basketballmove.png\";\n if (dir == \"up\") {myGamePiece.speedY = -1, passSound.play(); }\n if (dir == \"down\") {myGamePiece.speedY = 1, passSound.play(); }\n if (dir == \"left\") {myGamePiece.speedX = -1, passSound.play(); }\n if (dir == \"right\") {myGamePiece.speedX = 1, passSound.play(); }\n}", "title": "" }, { "docid": "529171814a730afbec5c04806f0bad73", "score": "0.60020757", "text": "move(){\n\t\t\n\t\tthis.x = this.x +2;\n\t\tthis.x %= width;\n\t\t\n\t}", "title": "" }, { "docid": "528b119b7988233e35a1cace9db9a7d6", "score": "0.5990824", "text": "function moveLeft() {\n var index = findCurrentIndex();\n if (index == 0) {\n index = images.length - 1;\n }\n else {\n index--;\n }\n\n changeImage(index);\n }", "title": "" }, { "docid": "b99a86b95e9f1c2071d246e279dcc988", "score": "0.5985819", "text": "move(){\n if(this.moving != MoveState.IMMOBILE){\n if(this.up){\n this.speed_y = -this.speed_y;\n super.move();\n this.speed_y = -this.speed_y;\n }\n else{\n super.move()\n }\n }\n }", "title": "" }, { "docid": "20cb0dce00e6188da77eb00067d01aaa", "score": "0.5978501", "text": "move(){\n if (this.dragging && !this.config.Lock) {\n this.sprite.setParent(this.game.app.stage);\n var newPosition = this.interaction.getLocalPosition(this.sprite.parent);\n let bounds=this.sprite.getBounds();\n this.sprite.x = newPosition.x;\n this.sprite.y = newPosition.y;\n //We can only move the object inside the stage\n //if(newPosition.x>bounds.width/2 && newPosition.x<this.game.width-bounds.width/2) this.sprite.x = newPosition.x;\n //if(newPosition.y>bounds.height && newPosition.y<this.game.height) this.sprite.y = newPosition.y;\n }\n }", "title": "" }, { "docid": "9d4a4531e42a4932dfa4315c4a2e95f3", "score": "0.5971571", "text": "stopMove() {\n this.x = prevX[0];\n this.y = prevY[0];\n }", "title": "" }, { "docid": "683165e99d48c983efd24f6fbec4f62f", "score": "0.59701365", "text": "function moveZero() {\n setTimeout(function() {\n $spriteImg.attr(\"src\", rightMove0);\n }, loopTimer);\n }", "title": "" }, { "docid": "b1f563f5c314dcbcdb10ff20ec2c3136", "score": "0.5962422", "text": "function myMoveLeft()\n{\n var elem=document.getElementById(\"animate\");\n var picture=document.getElementById(\"image\");\n var quoteColor=document.getElementById(\"quote\");\n var containerColor=document.getElementById(\"container\");\n var pos=350;\n var id=setInterval(frame,3);\n image.src = \"images/hardwork3.jpg\";\n quoteColor.style.color=\"#daa2da\";\n containerColor.style.backgroundColor=\"#93a806\";\n function frame(){\n\n if(pos==0){\n clearInterval(id);\n myMoveUp();\n }\n else{\n pos--;\n elem.style.left=pos+\"px\";\n }\n }\n}", "title": "" }, { "docid": "89ce85ad9f20a8ee57b81c9979548924", "score": "0.59578496", "text": "function mapXyPosToAction(x, y) {\n\t// if we were previously on the image\n\tif(previouslyOnImage) { \n\t\t// and we're still on the image\n\t\tif(onImage(x, y)) { \n\t\t\tmovedOnImage(x, y); \n\t\t} else {\n\t\t\tmovedOffImage(x, y); \n\t\t\tpreviouslyOnImage = false;\n\t\t}\n\t} else { // if we weren't on the image last time we checked\n\t\tif(onImage(x, y)) { \n\t\t\tmovedOnToImage(x, y); \n\t\t\tpreviouslyOnImage = true;\n\t\t}\n\t}\n}", "title": "" }, { "docid": "12448a31f96c9f67eabef3158aee7203", "score": "0.5945302", "text": "function moveImg() {\n\t$(\"#myImage\").animate({\"left\": (width/3), opacity: 1}, 2100);\n\t$(\"#myImage2\").animate({\"left\": (width/3)}, 1900).fadeTo('slow',1);\n}", "title": "" }, { "docid": "b589914fafa02717ca11ab3e98c9ad7e", "score": "0.594321", "text": "move() {\n this.coordinates();\n if(this.state == this.SWINGING)\n this.swing();\n else if(this.state == this.EXTENDING) {\n this.checkState();\n if (this.state == this.EXTENDING)\n this.extending();\n }\n else\n this.retract();\n }", "title": "" }, { "docid": "b24e7044ae8208369220fbf6206d7683", "score": "0.5942787", "text": "function autoMotion()\n{\n ++currentImg;\n checkIndex();\n changeImg();\n selectedClass();\n}", "title": "" }, { "docid": "1bc59311e902cdbbd8015677a0ac15f2", "score": "0.5933445", "text": "moveLeft() {\n if (this.state.activeSlide === 0) {\n this.setState(prevState => ({\n activeSlide: this.props.images.length - 1\n }));\n } else {\n this.setState(prevState => ({\n activeSlide: this.state.activeSlide - 1\n }));\n }\n }", "title": "" }, { "docid": "a9a8c7422a117341a0de7c9929279e6d", "score": "0.59255487", "text": "updateImageAfterFalling() {\n\t\tif (this.imageName === HERO_FALLS_RIGHT && this.isOnPassiveActorHorizontal()) {\n\t\t\tthis.setImage(HERO_ON_ROPE_RIGHT);\n\t\t\treturn;\n\t\t} else if (this.imageName === HERO_FALLS_LEFT && this.isOnPassiveActorHorizontal()) {\n\t\t\tthis.setImage(HERO_ON_ROPE_LEFT);\n\t\t\treturn;\n\t\t} else if (this.imageName === HERO_FALLS_RIGHT) {\n\t\t\tthis.setImage(HERO_RUNS_RIGHT);\n\t\t\treturn;\n\t\t} else {\n\t\t\tthis.setImage(HERO_RUNS_LEFT);\n\t\t\treturn;\n\t\t}\n\t}", "title": "" }, { "docid": "f36f2659c4473fa694fd8f7594e4ca8d", "score": "0.5911557", "text": "dontMove(){\n if(this.sonido){\n this.body.setVelocityX(0);\n this.PlayerHit.play();\n this.sonido=false;\n }\n }", "title": "" }, { "docid": "c7917ab7b94d000788d1695d86752c35", "score": "0.5908092", "text": "function movePlayer() {\r\n player.isMoving = true;\r\n }", "title": "" }, { "docid": "f2270533a18cf6ae56c74c697b7aafde", "score": "0.59064794", "text": "function mouseMove(){\n var libro = document.getElementById(\"libroIcon\");\n var moving = false;\n\n libro.addEventListener(\"mousedown\", initialClick, false);\n\n function move(e){\n var newX = e.clientX - 10;\n var newY = e.clientY - 10;\n\n image.style.left = newX + \"px\";\n image.style.top = newY + \"px\";\n }\n\n function initialClick(e) {\n if(moving){\n document.removeEventListener(\"mousemove\", move);\n moving = !moving;\n return;\n }\n \n moving = !moving;\n image = this;\n\n document.addEventListener(\"mousemove\", move, false);\n }\n}", "title": "" }, { "docid": "206aea47ea33ea48d3b0f5818655b136", "score": "0.58966136", "text": "function animatePlayer(x, y) { //the actual drawing part\r\n\tif (moveStyle === \"rotationBased\") {\r\n context.drawImage(ssImage, 192, 186, 48, 48, x, y, player.width, player.height);\r\n \r\n } else if (player.jumping) { //if player is jumping\r\n \tif (player.state === \"right\") {\r\n \tcontext.drawImage(ssImage, 192, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (player.state === \"left\") {\r\n \tcontext.drawImage(ssImage, 192, 84, 48, 84, x, y, player.width, player.height);\r\n }\r\n \r\n } else if (player.velocityX === 0 && player.velocityY === 0) { //standing still\r\n \tif (player.state === \"right\") {\r\n \tcontext.drawImage(ssImage, 0, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (player.state === \"left\") {\r\n \tcontext.drawImage(ssImage, 0, 84, 48, 84, x, y, player.width, player.height);\r\n } else if (player.state === \"up\") {\r\n \tcontext.drawImage(ssImage, 0, 168, 48, 84, x, y, player.width, player.height);\r\n } else if (player.state === \"down\") {\r\n \tcontext.drawImage(ssImage, 0, 252, 48, 84, x, y, player.width, player.height);\r\n } else {\r\n \tcontext.drawImage(ssImage, 0, 168, 48, 84, x, y, player.width, player.height);\r\n }\r\n \r\n } else if (player.state === \"right\") { //walking right\r\n \tif (frame < animationSpeed) {\r\n \tcontext.drawImage(ssImage, 0, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 2 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 48, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 3 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 96, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 4 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 48, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 5 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 0, 0, 48, 84, x, y, player.width, player.height);\r\n } else if (frame <= 6 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 144, 0, 48, 84, x, y, player.width, player.height);\r\n }\r\n \r\n } else if (player.state === \"left\") { //walking left\r\n \tif (frame < animationSpeed) {\r\n \tcontext.drawImage(ssImage, 0, 84, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 2 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 48, 84, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 3 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 96, 84, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 4 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 48, 84, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 5 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 0, 84, 48, 84, x, y, player.width, player.height);\r\n } else if (frame <= 6 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 144, 84, 48, 84, x, y, player.width, player.height);\r\n } \r\n \r\n } else if (player.state === \"up\") { //walking up\r\n \tif (frame < 2 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 0, 168, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 4 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 48, 168, 48, 84, x, y, player.width, player.height);\r\n } else if (frame <= 6 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 144, 168, 48, 84, x, y, player.width, player.height);\r\n }\r\n \r\n } else if (player.state === \"down\") { //walking down\r\n \tif (frame < 2 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 0, 252, 48, 84, x, y, player.width, player.height);\r\n } else if (frame < 4 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 48, 252, 48, 84, x, y, player.width, player.height);\r\n } else if (frame <= 6 * animationSpeed) {\r\n \tcontext.drawImage(ssImage, 144, 252, 48, 84, x, y, player.width, player.height);\r\n }\r\n }\r\n \r\n frame++ //increment the animations\r\n if (frame > 6 * animationSpeed) { //if reaches the end of the sheet\r\n \tframe = 0; //loop back around\r\n }\r\n}", "title": "" }, { "docid": "9670a4abf15d0b1dea32791ade87270c", "score": "0.5895305", "text": "function animation(){\n var state = $(this).attr(\"data-state\");\n if (state === \"still\"){\n $(this).attr(\"src\",$(this).data(\"animate\"));\n $(this).attr(\"data-state\", \"animate\");\n } else {\n $(this).attr(\"src\", $(this).data(\"still\"));\n $(this).attr(\"data-state\", \"still\");\n }\n }", "title": "" }, { "docid": "6b5ceceac3744d5623bdc6026bcd2d4b", "score": "0.5877002", "text": "function animate(){\n\t\tvar state = $(this).attr(\"data-state\");\n\t\tvar animateImage = $(this).attr(\"data-animate\");\n\t\tvar stillImage = $(this).attr(\"data-still\");\n\n\t\tif (state == \"still\") {\n\t\t\t$(this).attr(\"src\", animateImage);\n\t\t\t$(this).attr(\"data-state\", \"animate\");\n\t\t}\n\n\t\telse if (state == \"animate\") {\n\t\t\t$(this).attr(\"src\", stillImage);\n\t\t\t$(this).attr(\"data-state\", \"still\");\n\t\t}\n\t}", "title": "" }, { "docid": "5713a4de27c26a5290eeee67c2fe9f44", "score": "0.58769846", "text": "move() {\n if (this.game.flag.disableMove) {\n // We cannot move when game is pause move\n return\n }\n\n if (this.type === 'tileSprite') {\n // Tile sprites cannot move\n return\n }\n\n this.x += this.vx\n this.checkHitSprites()\n\n this.y += this.vy\n this.checkHitSprites()\n }", "title": "" }, { "docid": "caa8b6cb0f679834c9b6b6cbe8d4349f", "score": "0.58662355", "text": "function move(newIndex) { // Creates the image from old to new one\n\n advance(); // When image moves, call advance() again\n\n if (currentIndex === newIndex) { // If current image is showing, then do nothing\n return;\n }\n\n if (newIndex > currentIndex) { // If new item > current\n logo.style.backgroundImage = images[newIndex]; // Change the background image\n }\n currentIndex = newIndex; // Set currentIndex to new image\n }", "title": "" }, { "docid": "a8bc0594e8e445a6542051c56f52294c", "score": "0.58648986", "text": "function mover() {\n\t\tmoveIt(this);\n\t}", "title": "" }, { "docid": "4037cbaa30c6cf145064013417e782c0", "score": "0.5864562", "text": "function myMoveUp()\n{\n var elem=document.getElementById(\"animate\");\n var picture=document.getElementById(\"image\");\n var quoteColor=document.getElementById(\"quote\");\n var containerColor=document.getElementById(\"container\");\n var pos=350;\n var id=setInterval(frame,3);\n image.src = \"images/hardwork4.jpg\";\n quoteColor.style.color=\"#f1f3f2\";\n containerColor.style.backgroundColor=\"#c0334d\";\n function frame(){\n\n if(pos==0){\n clearInterval(id);\n myMoveRight();\n }\n else{\n pos--;\n elem.style.top=pos+\"px\";\n }\n }\n}", "title": "" }, { "docid": "4aad6c59bb63ca554008e4f20cdb81b4", "score": "0.586421", "text": "function toggleImage(img) {\n if (img.attr('data-state') == 'still') {\n img.attr('src', img.attr('data-animated')).attr('data-state', 'animated');\n } else {\n img.attr('src', img.attr('data-still')).attr('data-state', 'still');\n }\n}", "title": "" }, { "docid": "1d3695b05df18e8df185ddf4d9ddf550", "score": "0.58591163", "text": "switchMoveMode(){\n let particle = this.state.particle;\n particle.pos.x = CANVAS_WIDTH/2;\n particle.pos.y = CANVAS_HEIGHT/2;\n this.setState({moveMode: !this.state.moveMode, particle: particle});\n reDraw(null, this.state.particle, this.state.boundary, this.state.render3d);\n }", "title": "" }, { "docid": "487c5eead0e7683f123de76059d3dc95", "score": "0.58531743", "text": "move() {\n imageMode(CENTER);\n if (abs(this.pos.x - this.dest.x) > this.ToDest && abs(this.pos.y - this.dest.y) > this.ToDest) {// If the distance between the fish and its destination are within a certain num\n this.acc = p5.Vector.sub(this.dest, this.pos);\n this.acc.setMag(this.CAcc);\n this.vel.add(this.acc);\n this.vel.limit(this.CV);\n this.pos.add(this.vel);\n }\n else {// else pick a new destination\n if (this.direct) {// toggles the directions so fish swims both to left and right\n this.dest.set(int(random(width * 0.1, width / 2)), random(height * 0.80));\n while (p5.Vector.sub(this.dest, this.pos) < this.ToDest) {\n this.dest.set(int(random(width * 0.1, width / 2)), random(height * 0.80));\n }\n this.direct = false;\n }\n else if (this.direct === false) {\n this.dest.set(int(random(width / 2, width * 0.8)), random(height * 0.80));\n while (p5.Vector.sub(this.dest, this.pos) < this.ToDest) {\n this.dest.set(int(random(width / 2, width * 0.8)), random(height * 0.80));\n }\n this.direct = true;\n }\n }\n }", "title": "" }, { "docid": "4d2f28cb2a5077649af0153991b3d321", "score": "0.58378273", "text": "function moveBoth() {\n // find a direction, left = 1, right = 0\n var direction = (this.id.toLowerCase().indexOf(\"left\")==-1)? 1 : 0;\n\n // get all images\n var wrapper = document.getElementById(\"wrapper\");\n var left = parseInt(wrapper.style.left) || 0;\n\n // a variable for stopping movement\n var start = left;\n\n // set a step\n if (direction) {\n var step = -100;\n }\n else {\n step = 100;\n }\n\n // doing nothing if there are nothing farther\n if ((direction)&&(start<=(-1200))||((!direction)&&(start>=0))) {\n return;\n }\n\n // actually, move!\n function move() {\n // change left\n left+=step;\n wrapper.style.left = left + 'px';\n\n // if can not move, just stop\n if (Math.abs(start-left)==200) {\n // add clear interval\n clearInterval(timer);\n }\n }\n // that was set here\n var timer = setInterval(move, 60);\n}", "title": "" }, { "docid": "69e848c97e0c1dfd5593a8ad3b7ba423", "score": "0.5833709", "text": "function toggleMoveDock() {\n moveDisc = !moveDisc;\n}", "title": "" }, { "docid": "a127fdfdacfcff5cb9de6f4cecd5dfcc", "score": "0.5822322", "text": "function moveSprite() {\n if(keyIsDown(RIGHT_ARROW)) {\n playerSprite.changeAnimation('moving');\n playerSprite.velocity.x = 10;\n return;\n }\n else if(keyIsDown(LEFT_ARROW)) {\n playerSprite.changeAnimation('moving');\n playerSprite.velocity.x = -10;\n return;\n }\n else {\n playerSprite.changeAnimation('regular');\n playerSprite.velocity.x = 0;\n }\n\n if(keyIsDown(DOWN_ARROW)){\n playerSprite.changeAnimation('moving');\n playerSprite.velocity.y = 10;\n }\n else if(keyIsDown(UP_ARROW)) {\n playerSprite.changeAnimation('moving');\n playerSprite.velocity.y = -10;\n }\n else {\n playerSprite.changeAnimation('regular');\n playerSprite.velocity.y = 0;\n }\n}", "title": "" }, { "docid": "ccb1a970bf3b5e25fe4241c26916ce2a", "score": "0.5822136", "text": "function SetPieceImage(x, y, src) \r\n{\t \r\n\t//miramos si vamos a hacer un cambio para prevenir redibujado innecesario\r\n if (board[x][y].imagenum != -1)\r\n {\r\n if (document.images[board[x][y].imagenum].src != src) \r\n {\r\n document.images[board[x][y].imagenum].src = src;\r\n }\r\n }\r\n}", "title": "" }, { "docid": "c1647715505effda4772294b3f9c3219", "score": "0.58204824", "text": "function movedOffImage(x, y) {\n\trgb = getPixelRGB(x, y);\n\tinfo = colourSpaceMapping(rgb);\n\tsynth.stop(info);\n}", "title": "" }, { "docid": "cc073c4d6280ccf4bdf11276bc491441", "score": "0.58176965", "text": "move(){\n this.x--//va a permitir que el fondo se mueveva de derecha a izquierda\n if(this.x< -canvas.width) this.x =0\n }", "title": "" }, { "docid": "567e5279ea1d35edc77933604d2859df", "score": "0.5810042", "text": "function animation(){\n var state = $(this).attr(\"data-state\");\n if (state === \"still\") {\n $(this).attr(\"src\", $(this).attr(\"data-animate\"));\n $(this).attr(\"data-state\", \"animate\") \n }else{\n $(this).attr(\"src\", $(this).attr(\"data-still\"));\n $(this).attr(\"data-state\", \"still\")\n }\n }", "title": "" }, { "docid": "5d840a3dc9f087070251c27d15e46d4a", "score": "0.5805747", "text": "function animateImage (){\n\t\tconsole.log(\"click working\")\n\t\tvar state = $(this).attr('data-state');\n\t\tconsole.log(state);\n\t\t \n\t\t if (state === 'still') {\n\t \t$(this).attr('src', $(this).data('animate'));\n\t \t$(this).attr('data-state', 'animate');\n\t \tconsole.log('clicked1');\n\t } else { \n\t $(this).attr('src', $(this).data('still'));\n\t \t$(this).attr('data-state', 'still');\t\t\n\t \tconsole.log('clicked2');\t\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "427b0f0e7541f09bc65d6032b16f33fb", "score": "0.5804052", "text": "function movablePiece(){\r\n\t\tif (testX(this) || testY(this)){\r\n\t\t\t//call to change the color of the movable piece and change the value to allow movement\r\n\t\t\thighlightPiece(this);\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "7d76eb11eee6a73fd3d43a2119f3983b", "score": "0.57981575", "text": "function frame() {\n\t\tif (pos == 1500) { /* animation keeps running until this position */\n\t\tclearInterval(id);\n\t\t}\t\n\t\telse {\n\t\t\tpos++; \n\t\t\telem.style.left = pos + 'px'; /* moves image left */\n\t\t}\n\t}", "title": "" }, { "docid": "5449f1840610b4e5aa0c5c0624ed9d4f", "score": "0.5795846", "text": "function marsCollide(){\n let d7 = dist(ship2.x, ship2.y, mars.x, mars.y);\n if (d7 < (img.width/3 && img.height/3) + mars.size/2) {\n state = 'marsWin';\n setUpShip02();\n //background(0, 255, 200);\n }\n}", "title": "" }, { "docid": "c72b865f91293aadc38d1c0ae17543d3", "score": "0.57875717", "text": "updateImageOnFalling() {\n\t\tif (this.imageName === HERO_RUNS_RIGHT || this.imageName === HERO_ON_ROPE_RIGHT) {\n\t\t\tthis.setImage(HERO_FALLS_RIGHT);\n\t\t\treturn;\n\t\t} else if (this.imageName === HERO_RUNS_LEFT || this.imageName === HERO_ON_ROPE_LEFT) {\n\t\t\tthis.setImage(HERO_FALLS_LEFT);\n\t\t\treturn;\n\t\t}\n\t}", "title": "" }, { "docid": "a0b2d2ebeb73f852d826f80d6fd320bf", "score": "0.5773385", "text": "move(timeDelta) {\n if (this.constructor.name === \"Avatar\") {\n this.temperSpeed();\n }\n\n const velocityScale = (timeDelta / NORMAL_FRAME_TIME_DELTA) * 1.8,\n offsetX = this.vel[0] * velocityScale,\n offsetY = this.vel[1] * velocityScale;\n\n let checkingPosition = [this.pos[0] + offsetX, this.pos[1] + offsetY];\n\n if (this.constructor.name === \"Avatar\") {\n this.setXCoordinate(offsetX);\n this.setYCoordinate(offsetY);\n this.cursor.updatePos([\n this.pos[0] + (this.width/2) + (this.vel[0] * 15),\n this.pos[1] + (this.height/2) + (this.vel[1] * 15)\n ]);\n } else {\n this.pos = [this.pos[0] + offsetX, this.pos[1] + offsetY];\n }\n\n if (this.game.isOutOfBounds(this.pos)) {\n this.remove();\n }\n }", "title": "" }, { "docid": "5041c58fba47246c09fd928c13602aa3", "score": "0.5771451", "text": "move() {\n this.rect.move();\n }", "title": "" }, { "docid": "b5b5acca69201c9dbd3a682ce8472374", "score": "0.57699734", "text": "function checkAndMove() {\n\n if (mouseDown && selected.move) {\n selected.move();\n }\n\n}", "title": "" }, { "docid": "7f695b3b064b2e0c57953ce6b334b700", "score": "0.5765066", "text": "function slide() {\n\t\t// grab the old tile row/col values to update position of the empty square\n\t\tvar tileRow = parseInt(getComputedStyle(this).top) / TILE_WIDTH;\n\t\tvar tileCol = parseInt(getComputedStyle(this).left) / TILE_WIDTH;\n\t\t\n\t\tif (bordersEmpty(tileRow, tileCol)) {\n\t\t\t// move the tile to its new position\n\t\t\tthis.style.top = emptyRow * TILE_WIDTH + \"px\";\n\t\t\tthis.style.left = emptyCol * TILE_WIDTH + \"px\";\n\t\t\t// update tile id to match location\n\t\t\tthis.id = constructId(emptyRow, emptyCol);\n\t\t\t// update position of the empty square\n\t\t\temptyRow = tileRow;\n\t\t\temptyCol = tileCol;\n\t\t\t// if the user won, set the correct div value\n\t\t\tif (!isShuffling) {\n\t\t\t\tsetWin();\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "1b9f3902ff6234a8b6686bc4657c73b3", "score": "0.5764841", "text": "function mouseReleased() {\r\n moveLeft = false;\r\n moveRight = false;\r\n}", "title": "" }, { "docid": "ad3dd32f611466805e6641302e5e4634", "score": "0.576303", "text": "resetRightMove() {\r\n this.wasRightPushed_ = false;\r\n }", "title": "" }, { "docid": "11d5770bc5249cbfdf3e4e39aa83b0c8", "score": "0.57577866", "text": "function move() {\n $lis.each(function(index, element) {\n var state = states[index];\n $(element).css('zIndex', state.$zIndex).finish().animate(state, setting.speed).find('img').css('opacity', state.$opacity);\n });\n }", "title": "" }, { "docid": "7528dccfed40134100ef48140e86ba3b", "score": "0.57559335", "text": "function moveShipMissile() {\n if (missile && missile.isDisplayed()) {\n if (!missile.moveTop()) {\n missile.hideMissile();\n } else {\n checkIfAlienIsTouched();\n }\n }\n}", "title": "" }, { "docid": "168e58740e2000142ca0a18cbed5fa29", "score": "0.57553035", "text": "move() {\n\t}", "title": "" }, { "docid": "a70502294086c52f3612f3b1f7c6141d", "score": "0.5750309", "text": "moveLeft() {\n this.orientation = \"l\";\n \nif(this.jumping==false)\n{\n this.frame=(this.frame==this.framesWalkLeft.length-1)?0:this.frame+1;\n\n this.image = this.framesWalkLeft[this.frame];\n }\n this.impulse_x = -5;\n }", "title": "" }, { "docid": "e80ad37a468036e2dac854b692d5785c", "score": "0.57495284", "text": "function setBrokenImage(){\n\t\t\tgame.spaceshipImg.setAnimationImageIndex([13]);\t\t\n\t\t\t\n\t\t}", "title": "" }, { "docid": "19fcae9c21ec019067874f796e309b7a", "score": "0.5733738", "text": "function frame() {\n\t\tif (pos2 == 1500) { /* animation keeps running until this position */\n\t\tclearInterval(id2);\n\t\t}\t\n\t\telse {\n\t\t\tpos2++; \n\t\t\telem2.style.left = pos2 + 'px'; /* moves image left */\n\t\t}\n\t}", "title": "" }, { "docid": "c1be017693478b1f207cc96f3312e188", "score": "0.57325315", "text": "function disableInteraction() {\n moving = true;\n\n setTimeout(function(){\n moving = false\n }, 500);\n }", "title": "" }, { "docid": "0ed8bf6ad8104ec8cc26c2ca0d777fa2", "score": "0.57188076", "text": "function animateGif() {\n\n var state = $(this).find(\"img\").attr(\"data-state\");\n\n if (state === \"still\") {\n $(this).find(\"img\").attr(\"src\", $(this).find(\"img\").attr(\"data-animate\"));\n $(this).find(\"img\").attr(\"data-state\", \"animate\");\n } else {\n $(this).find(\"img\").attr(\"src\", $(this).find(\"img\").attr(\"data-still\"));\n $(this).find(\"img\").attr(\"data-state\", \"still\");\n }\n }", "title": "" }, { "docid": "c174203320a7310ec269efbccd21c488", "score": "0.57168746", "text": "function move(){\r\n\t\tmovedColor(this);\r\n\t\t//console.log(\"the empty top is:\" + emptyTop);\r\n\t\t//console.log(\"the empty left is:\" + emptyLeft);\r\n\t \toldTop = parseInt(this.style.top);\r\n\t\toldLeft = parseInt(this.style.left);\r\n\t\t//console.log (\"the old top is:\" + oldTop);\r\n\t\t//console.log (\"the old left is:\" + oldLeft);\r\n\t\tif (oldTop == emptyTop && oldLeft == (emptyLeft-100) || oldTop == emptyTop && oldLeft == (emptyLeft+100) || oldTop == (emptyTop-100) && oldLeft == emptyLeft || oldTop == (emptyTop+100) && oldLeft == emptyLeft){\r\n\t\tthis.style.top = emptyTop + \"px\";\r\n\t\tthis.style.left = emptyLeft + \"px\";\r\n\t\temptyTop = oldTop;\r\n\t\temptyLeft = oldLeft;\r\n\t\t//console.log (\"the empty top is:\" + emptyTop);\r\n\t\t//console.log (\"the empty left is:\" + emptyLeft);\r\n\t\t\t\t\r\n\t}\r\n\t\r\n\t}", "title": "" }, { "docid": "0108ac10f16d31d39441ea23f9f51f9d", "score": "0.57114506", "text": "function autoMove(){\n\tindex++;\n\tmove(bannerImg,\"left\",index*-1000,500,function(attr){\n\t\tif(index >= 4){\n\t\t\tindex = 0;\n\t\t\tutils.css(this,attr,0);\n\t\t}\n\t\tshowTip(index);\n\t\tbannerImg.timer = window.setTimeout(autoMove,3000);\n\t})\n}", "title": "" }, { "docid": "61c5660e53a1ff7c3228f03b34211f9b", "score": "0.5707664", "text": "function toggleImageF() {\n var state = $(this).attr(\"data-stateF\");\n\n if (state === \"still\") {\n $(this).attr(\"src\", $(this).attr(\"data-animateF\"));\n $(this).attr(\"data-stateF\", \"animate\");\n } else {\n $(this).attr(\"src\", $(this).attr(\"data-stillF\"));\n $(this).attr(\"data-stateF\", \"still\");\n }\n }", "title": "" }, { "docid": "0a2b5831d00bdd0e5e1d75be95324bd8", "score": "0.5707312", "text": "move()\r\n {\r\n if(this.alive)\r\n {\r\n var move = this.findDirection(this.x, this.y)\r\n if(move)\r\n {\r\n this.x = move[0];\r\n this.y = move[1];\r\n }\r\n }\r\n }", "title": "" }, { "docid": "10ba2498715bc61c9ad96b6bffcec1db", "score": "0.5700628", "text": "move () {\n // Rewrite speed. It's need whtn user clickd change speed\n if (this.xSpeed) {\n this.xSpeed = (this.xSpeed > 0) ? this.speed : -this.speed;\n }\n if (this.ySpeed) {\n this.ySpeed = (this.ySpeed > 0) ? this.speed : -this.speed;\n }\n\n this.x += this.xSpeed;\n this.y += this.ySpeed;\n\n if (this.x < this.size) {\n this.setDirection('right');\n } else if (this.x > width - this.size) {\n this.setDirection('left');\n }\n\n if (this.y < this.size) {\n this.setDirection('down');\n } else if (this.y > height - this.size) {\n this.setDirection('up');\n }\n }", "title": "" }, { "docid": "814e434ad964e5929b1e768f2b8aa32e", "score": "0.5695889", "text": "function move(imgs, sign, useCallback = false) {\n if (!(sign+1) && !useCallback) {\n switchSource(imgs, sign);\n }\n\n imgs[0].animate({\"left\":getPX(imgs[0]) + (imageWidth * sign) + 'px'}, 800, ()=>{\n if ((sign+1) && useCallback) {\n switchSource(imgs, sign);\n }\n });\n}", "title": "" }, { "docid": "2746ace90fce40c20dd81a36ab804831", "score": "0.56945115", "text": "function moveEvil() {\n evil.x = evil.x + evil.xspeed;\n evil.y = evil.y + evil.yspeed;\n}", "title": "" }, { "docid": "dbc5d057bb11e9272c64401bceafb781", "score": "0.56920624", "text": "function animateGIF() {\n var state = $(this).attr(\"data-state\");\n if (state === \"still\") {\n $(this).attr(\"src\", $(this).attr(\"data-animate\"));\n $(this).attr(\"data-state\", \"animate\");\n } else {\n $(this).attr(\"src\", $(this).attr(\"data-still\"));\n $(this).attr(\"data-state\", \"still\");\n }\n }", "title": "" }, { "docid": "2e61b52c698764fbecb85fad71654ad9", "score": "0.5691266", "text": "atackLeft() {\n this.frame=(this.frame>=this.framesAttackLeft.length-1)?0:this.frame+1;\n\n\n this.image = this.framesAttackLeft[this.frame];\n }", "title": "" }, { "docid": "7d616e067ecaa8c643b42816c1b57ced", "score": "0.5689958", "text": "faceWall() {\n let sprite = this.sprite;\n\n this.vx = 0;\n this.vy = 0;\n\n // only check once\n if (this.currentMovement !== 'faceWall') {\n this.currentMovement = 'faceWall';\n sprite.advanceFrame('faceWall');\n this.switchAbove = this.sprite.currentMap.getSwitchAboveMaster();\n console.log('**** faceWall', this.switchAbove);\n }\n }", "title": "" }, { "docid": "7dc767a40d7c48d3f0e32348c6d47350", "score": "0.5689391", "text": "standStill(){\n standStill2 = true;\n this.sprite.velocity.x = 0;\n this.sprite.velocity.y = 0;\n }", "title": "" }, { "docid": "d71d8f319c7cf3570c01ad975a392d89", "score": "0.5682351", "text": "function playerMove() {\n /** return false if the player should try to slide around obstruction */\n function move(h, v) {\n var c = getMap(pPos.x+h, pPos.y+v);\n if (c==WALL || c==BULLET || c==GNOMEGEN || c==GNOME) return false;\n if (c==STAIRDOWN) {\n exitLevel = true;\n }\n if (c==GOLD) {\n changeScore(20);\n }\n if (c==HEALTH) {\n changeHealth(10);\n changeScore(5);\n }\n pPos.x+=h;\n pPos.y+=v;\n return true;\n }\n \n opPos.set(pPos);\n if (pDir.x==0 && pDir.y==0) return;\n if (!move(pDir.x, pDir.y)) {\n move(pDir.x, 0);\n move(0, pDir.y);\n }\n if (!opPos.equals(pPos)) {\n setMap(pPos.x, pPos.y, PLAYER);\n setMap(opPos.x, opPos.y, FLOOR);\n moveCool = MOVECOOL;\n }\n }", "title": "" }, { "docid": "b1d737c42c0d5fd0417b549a80358bee", "score": "0.56795913", "text": "function nextImage() {\n\tmoveImages(1, true);\n}", "title": "" }, { "docid": "b2597c7220dd56e86bbe8ef1a0bc2b96", "score": "0.5679273", "text": "moveRight() {\n if (this.state.activeSlide === this.props.images.length - 1) {\n this.setState(prevState => ({\n activeSlide: 0\n }));\n } else {\n this.setState(prevState => ({\n activeSlide: this.state.activeSlide + 1\n }));\n }\n }", "title": "" }, { "docid": "2f41a3d04890fbef08bd3d439988174f", "score": "0.5679252", "text": "function moveUp() {\n isGoingLeft = false;\n isGoingRight = false;\n clearInterval(leftTimerId);\n clearInterval(rightTimerId);\n }", "title": "" }, { "docid": "5d56c613192826f4c3dc83f35b033ed7", "score": "0.56699973", "text": "function toggleGiphyImages() {\n\t\tvar state = $(this).attr(\"data-state\");\n\t\tif (state === \"still\") {\n\t\t\t$(this).attr(\"src\", $(this).attr(\"data-animate\"));\n\t\t\t$(this).attr(\"data-state\", \"animate\");\n\t\t} else {\n\t\t\t$(this).attr(\"src\", $(this).attr(\"data-still\"));\n\t\t\t$(this).attr(\"data-state\", \"still\");\n\t\t}\n\t}", "title": "" }, { "docid": "0b68dfd73bb29c1ab249017607e21ec6", "score": "0.5668675", "text": "function ifMoving(old,pos){\n return (!old||old.row!=pos.row||old.col!=pos.col) ? pos : old;\n}", "title": "" }, { "docid": "c2debd6b119777dc51ca8515b3bb5c3f", "score": "0.5664653", "text": "resetLeftMove() {\r\n this.wasLeftPushed_ = false;\r\n }", "title": "" }, { "docid": "173d225ac4a525d7217d7d528d270609", "score": "0.566041", "text": "function move() {\r\n if(pos >= 150) {\r\n clearInterval(t);\r\n }\r\n else {\r\n pos += 1;\r\n box.style.left = pos+\"px\";\r\n }\r\n}", "title": "" }, { "docid": "311e56de835de44c27009c81a6798aba", "score": "0.5659839", "text": "function startStop(){\n\n //Checks is gif is stopped if so,\n if ($(this).data('still') === $(this).attr('src')){\n\n //Swap current source with active gif source\n var newSrc = $(this).data('active');\n $(this).attr('src', newSrc);\n\n // If in motion,\n } else {\n \n //Swap current source with still gif source\n var newSrc = $(this).data('still');\n $(this).attr('src', newSrc);\n }\n }", "title": "" }, { "docid": "311e56de835de44c27009c81a6798aba", "score": "0.5659839", "text": "function startStop(){\n\n //Checks is gif is stopped if so,\n if ($(this).data('still') === $(this).attr('src')){\n\n //Swap current source with active gif source\n var newSrc = $(this).data('active');\n $(this).attr('src', newSrc);\n\n // If in motion,\n } else {\n \n //Swap current source with still gif source\n var newSrc = $(this).data('still');\n $(this).attr('src', newSrc);\n }\n }", "title": "" }, { "docid": "42eda321f4fec73050646cc823126fcd", "score": "0.5656868", "text": "move(){\n\t\tthis.x = this.x + this.dx;\n\t\tthis.y = this.y + this.dy;\n\t}", "title": "" } ]
f137cf5b58658446d64c77eb30f9ba67
Lines with gutter elements, widgets or a background class need to be wrapped, and have the extra elements added to the wrapper div
[ { "docid": "6fd89bcf294179797731b93264996185", "score": "0.0", "text": "function ensureLineWrapped(lineView) {\n if (lineView.node == lineView.text) {\n lineView.node = elt(\"div\", null, null, \"position: relative\");\n if (lineView.text.parentNode)\n { lineView.text.parentNode.replaceChild(lineView.node, lineView.text); }\n lineView.node.appendChild(lineView.text);\n if (ie && ie_version < 8) { lineView.node.style.zIndex = 2; }\n }\n return lineView.node\n }", "title": "" } ]
[ { "docid": "398ada76c2a612f6d7ed7426c11ffdeb", "score": "0.66535497", "text": "function grid()\n{\n var wrappedItems = detectWrap(\"flex-divider\");\n // When my items are side by side, I want the divider to be vertical\n for ([key, item] of Object.entries(wrappedItems[\"inline\"]))\n {\n\titem.classList.remove(\"line-top\");\n item.classList.add(\"line-left\");\n }\n // When my items are on top of each other, I want the divider to be horizontal\n for ([key, item] of Object.entries(wrappedItems[\"block\"]))\n {\n item.classList.remove(\"line-left\");\n item.classList.add(\"line-top\");\n }\n}", "title": "" }, { "docid": "a314d0994793daba6ed66163b4259259", "score": "0.586628", "text": "function updateGutters(cm){var gutters=cm.display.gutters,specs=cm.options.gutters;removeChildren(gutters);var i=0;for(;i<specs.length;++i){var gutterClass=specs[i];var gElt=gutters.appendChild(elt(\"div\",null,\"CodeMirror-gutter \"+gutterClass));if(gutterClass==\"CodeMirror-linenumbers\"){cm.display.lineGutter=gElt;gElt.style.width=(cm.display.lineNumWidth||1)+\"px\";}}gutters.style.display=i?\"\":\"none\";updateGutterSpace(cm);}// Make sure the gutters options contains the element", "title": "" }, { "docid": "93aea269b8db5e9062db4c20df248135", "score": "0.570792", "text": "function itemTimelineWrap(el, wrapper, classes) {\r\n wrapper.classList.add(classes);\r\n el.parentNode.insertBefore(wrapper, el);\r\n wrapper.appendChild(el);\r\n }", "title": "" }, { "docid": "b7498fb18b732664d7241591ef0df9fa", "score": "0.5691318", "text": "function appendBackgroundHorizontalGridLines(paddingGroup, plot) {\n const gridGroup = paddingGroup.append('g')\n .attr('class', 'grid');\n paddingGroup.selectAll('.yAxis .tick')\n .each(function(d,i) {\n const tick = d3.select(this);\n const {x, y} = extractTranslation(tick);\n gridGroup.append('line')\n .attr('x1', 0)\n .attr('y1', y)\n .attr('x2', plot.range.x)\n .attr('y2', y);\n })\n }", "title": "" }, { "docid": "47b3a4b17221720a89726def1d3045c8", "score": "0.5677009", "text": "buildLineContainerElement() {\n return html.makeDivElement('line-container');\n }", "title": "" }, { "docid": "0409dd1c46ed5aa2fbc658d10704b4a7", "score": "0.56761503", "text": "function ScreedWrapper() {\n}", "title": "" }, { "docid": "d8fc526bfd62b7cd0381a33f851dc2b4", "score": "0.56566554", "text": "function initSplitRows() {\n var wrapList = jQuery('.projects-area');\n var thumbClass = 'thumbs';\n jQuery('.info').each(function () {\n var holder = jQuery(this);\n var rightBox = holder.parent().find('.right-side');\n var ellipsis = holder.find('.ellipsis');\n var textHolder = holder.find('>span');\n var textBox = holder.find('.location');\n var orienteer = rightBox.find('.orienteer');\n if (rightBox.length && orienteer.length) {\n holder.css({width: (wrapList.hasClass(thumbClass) ? orienteer.offset().left : rightBox.offset().left) - holder.offset().left - 20});\n }\n function calcContent(box, separate) {\n var text = box.data('text'),\n str = '',\n i = 0;\n for (i = text.length - 1; i > 0; i--) {\n if (!str.length) {\n str = text;\n }\n textBox.html(str);\n if (textHolder.height() <= lineHeight) {\n return false;\n }\n else {\n text = text.substr(0, text.length - 1);\n str = text + separate.html();\n }\n }\n }\n\n if (ellipsis.length && textBox.length) {\n textBox.data('text', textBox.text());\n\n var lineHeight = parseInt(textHolder.css('lineHeight')) + 3;\n if (wrapList.length && !wrapList.hasClass(thumbClass)) {\n lineHeight *= 2;\n }\n if (textHolder.height() > lineHeight) {\n textBox.css({opacity: 0});\n jQuery(window).load(function () {\n calcContent(textBox, ellipsis);\n textBox.css({opacity: ''});\n });\n }\n jQuery(window).bind('resize', function () {\n setTimeout(function () {\n holder.css({width: (wrapList.hasClass(thumbClass) ? orienteer.offset().left : rightBox.offset().left) - holder.offset().left});\n lineHeight = parseInt(textHolder.css('lineHeight')) + 3;\n if (wrapList.length && !wrapList.hasClass(thumbClass)) {\n lineHeight *= 2;\n }\n calcContent(textBox, ellipsis);\n }, 100);\n });\n }\n });\n}", "title": "" }, { "docid": "bdd84afd4c3b520975cf925454c7bb76", "score": "0.56482315", "text": "function insertLineWidgets(cm,lineView,dims){insertLineWidgetsFor(cm,lineView.line,lineView,dims,true);if(lineView.rest){for(var i=0;i<lineView.rest.length;i++){insertLineWidgetsFor(cm,lineView.rest[i],lineView,dims,false);}}}", "title": "" }, { "docid": "53ba5d9dc15135c27910addd95a90316", "score": "0.55736893", "text": "static createPhotoDivs() {\n this.photosPerLine = this.getPhotosPerLine()\n let lines = Math.floor(this.photos.length / this.photosPerLine)\n if (this.photos.length % this.photosPerLine !== 0) {\n lines++\n }\n for (let i = 0; i < lines; i++) {\n const div = document.createElement(\"div\")\n div.setAttribute(\"id\", \"lineDiv=\" + i)\n if (this.photosPerLine === 6 || this.photosPerLine === 4) {\n div.setAttribute(\"class\", \"line-div\")\n } else {\n if (this.rightToggled) {\n div.setAttribute(\"class\", \"line-div right\")\n } else {\n div.setAttribute(\"class\", \"line-div left\")\n }\n }\n this.divs.push(div)\n }\n if (this.photosPerLine === 6 || this.photosPerLine === 4) {\n this.divs[0].setAttribute(\"class\", \"first-line-div\")\n } else {\n if (this.rightToggled) {\n this.divs[0].setAttribute(\"class\", \"first-line-div right\")\n } else {\n this.divs[0].setAttribute(\"class\", \"first-line-div left\")\n }\n }\n }", "title": "" }, { "docid": "57d5e7a292ecf7b39ce4248425e9f8b7", "score": "0.5562785", "text": "function addCorners(el) {\n $(el).wrapInner('<div class=\"' + className + '-content\" />').append(spans).addClass(className);\n }", "title": "" }, { "docid": "eb6ee2803966fcfd22daba7c0c3cee70", "score": "0.5553659", "text": "function addHitsGutters(editor, lineNum, item, hits, exclId, exclComment, thData, gbIndex ,gbLength ) {\n var template;\n var imgSource;\n var imgExtraAttr = '';\n var imgExtraClasses = '';\n var divExtraAttr = '';\n var divExtraClasses = '';\n var generateBlockGutClass = '';\n var addHitText= true;\n\n // This block is responsible for adding borders to the same GB and center the hits count gutter text\n if (gbIndex && gbLength > 1){\n var hitIndex = Math.ceil(gbLength / 2);\n generateBlockGutClass = 'gb-gut '\n addHitText = (gbLength == 1 || (gbIndex == hitIndex))\n if (gbIndex == 1) {\n generateBlockGutClass += 'gb-first-gut';\n } else if (gbIndex == gbLength) {\n generateBlockGutClass += 'gb-last-gut';\n }\n }\n\n var isGenBlkExist = (typeof hits === 'object');\n var isHitsExlcuded = (typeof hits === 'string');\n var isExclWithCommentOrIsgenBlk = (exclComment || GLOBAL_JSON.exclReason.hasOwnProperty(hits) || (hits == 'E-hit' && exclComment) || isGenBlkExist); //Excluded with comment or generate block exist\n\n if (isHitsExlcuded || isGenBlkExist) { //hits gutter incase of Exclusion or generate blocks.\n\n if (isExclWithCommentOrIsgenBlk) {\n imgExtraClasses = 'img-comment';\n divExtraClasses = 'excl-comment';\n if (isGenBlkExist) {\n imgSource = hits[0].cp ? 'icons/cp.png' : 'icons/gi.png'; //generate blocks icon Or class Parameter\n imgExtraClasses = 'img-comment';\n divExtraClasses = getGenBlockHits(hits);\n } else if (hits == 'E-hit') {\n imgSource = 'icons/echeckcomment.png'; //Excluded and hit with comment icon\n } else if (exclComment) {\n imgSource = 'icons/ecomment.png'; //Excluded with comment icon\n } else {\n imgSource = 'icons/exclude.png'; //Excluded icon\n }\n\n if (thData) {\n imgExtraAttr = 'style=\"height: 20px;width: 20px; float: left;margin-right: 5px;margin-left: 11px;\" excl=\"' + exclId + '\"';\n divExtraAttr = 'excl=\"' + exclId + '\"' + 'line=\"' + lineNum + '\"' + 'item=\"' + item + '\"';\n } else {\n imgExtraAttr = 'style=\"height: 20px;width: 20px\" excl=\"' + exclId + '\"' ;\n divExtraAttr = 'excl=\"' + exclId + '\"' ;\n }\n\n } else {\n imgSource = (hits == 'E-hit') ? 'icons/echeck.png' : 'icons/exclude.png';\n\n if (thData) {\n imgExtraAttr = 'style=\"height: 17px;width: 17x; float: left;margin-right: 5px;margin-left: 11px;\"';\n divExtraAttr = 'excl=\"' + exclId + '\"' + 'line=\"' + lineNum + '\"' + 'item=\"' + item + '\"';\n } else {\n imgExtraAttr = 'style=\"height: 17px;width: 17x\"' ;\n }\n\n divExtraClasses = 'excl';\n }\n\n if (thData) {\n template = '<div class=\"excl-item ' + divExtraClasses + '\" ' + divExtraAttr + '><img src=\"' + imgSource + '\" class=\"center-img ' + imgExtraClasses + '\" alt=\"E\" ' + imgExtraAttr + '\" onclick=\"onCodeMirrorGutterClick(event)\"></img> <i class=\"fa fa-flask\" aria-hidden=\"true\" style=\"color: black;font-size: 20px;\" onclick=\"thdModal(event)\"></i> <i id= \"thdCheck\" class=\"fa fa-check\" style=\"position: absolute;margin-left: 40px;display: block;color: #11ef06;margin-top: -18px;font-size: 18px;z-index: 30;\"onclick=\"thdModal(event)\"></i></div>';\n } else {\n template = '<div class=\"excl-item ' + divExtraClasses + '\" ' + divExtraAttr + '><img src=\"' + imgSource + '\" class=\"center-img ' + imgExtraClasses + '\" alt=\"E\" ' + imgExtraAttr + '\" onclick=\"onCodeMirrorGutterClick(event)\"></img></div>';\n }\n\n } else { //Normal hits gutter \"just the value\"\n\n if (thData) {\n divExtraAttr = 'excl=\"' + exclId + '\"' + 'line=\"' + lineNum + '\"' + 'item=\"' + item + '\"'; //Extra attributes to get the line, item number in the Thd modal\n }\n\n //Constructing gutters template\n if (thData && hits != 0) {\n template = '<p class=\"' + (hits == 0 ? 'src-gut-not-hit ' : 'src-gut-hit ') + generateBlockGutClass+ (addHitText ? '' : ' transparent') +'\" ' + divExtraAttr + '>' + hits + ' <i class=\"fa fa-flask\" aria-hidden=\"true\" style=\"color: black;font-size: 20px;\" onclick=\"thdModal(event)\"></i> <i id= \"thdCheck\" class=\"fa fa-check\" style=\"position: absolute;margin-left: 33px;display: block;color: #11ef06;margin-top: -21px;font-size: 18px;z-index: 30;\"onclick=\"thdModal(event)\"></i></p>'; //adding flask icon incase of testhit data exist\n } else {\n template = '<p class=\"' + (hits == 0 ? 'src-gut-not-hit ' : 'src-gut-hit ') + generateBlockGutClass + (addHitText ? '' : ' transparent') + '\">' + hits + ' </p>';\n }\n }\n\n editor.doc.setGutterMarker(lineNum, 'codemirror-gut' + item, $(template)[0]);\n}", "title": "" }, { "docid": "f8299affc8fb4169e11f5ae3ad05782d", "score": "0.5534517", "text": "function createGutter() {\n var gutter = document.createElement('div');\n gutter.style.paddingBottom = GUTTER_SIZE_IN_PX + \"px\";\n gutter.id = GUTTER_SELECTOR.substr(1);\n var initialized = false;\n var mounted = false;\n var currentParent = null;\n var observer;\n var isVisible = false;\n return {\n addGutter: function (parent) {\n if (parent) {\n currentParent = parent;\n parent.appendChild(gutter);\n mounted = true;\n if (observer) {\n observer.observe(gutter);\n }\n }\n },\n removeGutter: function () {\n if (currentParent && mounted) {\n mounted = false;\n currentParent.removeChild(gutter);\n if (observer)\n observer.unobserve(gutter);\n }\n },\n element: function () {\n return gutter;\n },\n isMounted: function () {\n return mounted;\n },\n visible: function () {\n // If we know whether it's visible we can avoid expensive calculations\n if (observer)\n return isVisible;\n // Fallback for legacy browsers assumes it's visible (if mounted)\n return mounted;\n },\n observe: function (scrollElement) {\n if (!initialized) {\n initialized = true;\n observer = listenForGutterVisibilityChanges(scrollElement, function (visible) { return (isVisible = visible); });\n }\n },\n destroy: function () {\n if (observer)\n observer.disconnect();\n observer = undefined;\n this.removeGutter();\n initialized = mounted = false;\n },\n };\n}", "title": "" }, { "docid": "3e99f5e8961735d1eeebcc8d5e720d57", "score": "0.5494486", "text": "handleWrapping() {\n // Off the left or right\n if (this.x < 0) {\n this.x += width;\n } else if (this.x > width) {\n this.x -= width;\n }\n // Off the top or bottom\n if (this.y < 0) {\n this.y += height;\n } else if (this.y > height) {\n this.y -= height;\n }\n }", "title": "" }, { "docid": "a621d39cd1698ba8b461d07c1c206df2", "score": "0.54805875", "text": "handleWrapping() {\n // Off the left or right\n if (this.x < 0) {\n this.x += width;\n } else if (this.x > width) {\n this.x -= width;\n }\n // Off the top or bottom\n if (this.y < 0) {\n this.y += height;\n } else if (this.y > height) {\n this.y -= height;\n }\n }", "title": "" }, { "docid": "a621d39cd1698ba8b461d07c1c206df2", "score": "0.54805875", "text": "handleWrapping() {\n // Off the left or right\n if (this.x < 0) {\n this.x += width;\n } else if (this.x > width) {\n this.x -= width;\n }\n // Off the top or bottom\n if (this.y < 0) {\n this.y += height;\n } else if (this.y > height) {\n this.y -= height;\n }\n }", "title": "" }, { "docid": "a621d39cd1698ba8b461d07c1c206df2", "score": "0.54805875", "text": "handleWrapping() {\n // Off the left or right\n if (this.x < 0) {\n this.x += width;\n } else if (this.x > width) {\n this.x -= width;\n }\n // Off the top or bottom\n if (this.y < 0) {\n this.y += height;\n } else if (this.y > height) {\n this.y -= height;\n }\n }", "title": "" }, { "docid": "efdf93997cf5a3a7281a8724c26872b5", "score": "0.5479562", "text": "function appendBackgroundVerticalGridLines(paddingGroup, plot) {\n const gridGroup = paddingGroup.selectAll('.grid');\n paddingGroup.selectAll('.xAxis .tick')\n .each(function(d,i) {\n if (i > 0) {\n const tick = d3.select(this);\n const {x, y} = extractTranslation(tick);\n gridGroup.append('line')\n .attr('x1', x)\n .attr('y1', 0)\n .attr('x2', x)\n .attr('y2', plot.range.y);\n }\n })\n }", "title": "" }, { "docid": "3db103f494cfbd552dfd8fa318da808a", "score": "0.5467039", "text": "function setTileWrapperHeights() {\n\n // These are examples from another project. You'll need to set your own wrapper heights using the tile IDs and the annotation indices, but these are kept in as a template\n\n // Sunburst annotations run from the second annotation div (first visible) to the ninth (top of ten)\n // There's a little extra finagling at the end to get the margin between the two viz wrappers correct\n // const beeswarmWrapperHeight = scrollerDivObjects[13].getBoundingClientRect().bottom - scrollerDivObjects[1].getBoundingClientRect().top - 200;\n // $(\"#beeswarm-wrapper\")\n // .css(\"height\", beeswarmWrapperHeight);\n\n\n const bubblePlotWrapperHeight = scrollerDivObjects[11].getBoundingClientRect().bottom - scrollerDivObjects[0].getBoundingClientRect().top;\n $(\"#bubbleplot-wrapper\")\n .css(\"height\", bubblePlotWrapperHeight);\n\n // // Flowchart annotation divs run from the tenth annotation div to the fourteenth\n // const flowChartWrapperHeight = scrollerDivObjects[scrollerDivObjects.length - 1].getBoundingClientRect().top - scrollerDivObjects[9].getBoundingClientRect().top + 700;\n // $(\"#flowchart-wrapper\")\n // .css(\"height\", flowChartWrapperHeight);\n}", "title": "" }, { "docid": "854c2ca22a37325c8f804d00955b02d5", "score": "0.54563916", "text": "function gutter(config) {\n return [gutters(), activeGutters.of(Object.assign(Object.assign({}, defaults), config))];\n}", "title": "" }, { "docid": "25b7ba71f95f2f98454b758f849b6cbf", "score": "0.54530215", "text": "handleWrapping() {\n // Off the left or right\n if (this.x < 0) {\n this.x += width;\n }\n else if (this.x > width) {\n this.x -= width;\n }\n // Off the top or bottom\n if (this.y < 0) {\n this.y += height;\n }\n else if (this.y > height) {\n this.y -= height;\n }\n }", "title": "" }, { "docid": "2ec60ab19c7fd9a099f07a8f1b96d5d5", "score": "0.54421425", "text": "function gutter(config) {\n return [gutters(), activeGutters.of(Object.assign(Object.assign({}, defaults$1), config))];\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "bc4419a03af1339e830b08a00aa6199d", "score": "0.54050446", "text": "function renderGutters(display) {\n var gutters = display.gutters, specs = display.gutterSpecs;\n removeChildren(gutters);\n display.lineGutter = null;\n for (var i = 0; i < specs.length; ++i) {\n var ref = specs[i];\n var className = ref.className;\n var style = ref.style;\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + className));\n if (style) { gElt.style.cssText = style; }\n if (className == \"CodeMirror-linenumbers\") {\n display.lineGutter = gElt;\n gElt.style.width = (display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = specs.length ? \"\" : \"none\";\n updateGutterSpace(display);\n }", "title": "" }, { "docid": "fe876f274410be415365ac982c15536f", "score": "0.5381091", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters\n removeChildren(gutters)\n var i = 0\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i]\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass))\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\"\n }\n }\n gutters.style.display = i ? \"\" : \"none\"\n updateGutterSpace(cm)\n }", "title": "" }, { "docid": "7a9d6c91ec96bf9f29654da93dbf8cc9", "score": "0.53800607", "text": "function insertLineWidgets(cm, lineView, dims) {\n\t insertLineWidgetsFor(cm, lineView.line, lineView, dims, true)\n\t if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n\t { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false) } }\n\t}", "title": "" }, { "docid": "014c310223ebbbdf90d950adfe0e0363", "score": "0.5371828", "text": "ensureLineGaps(current, mayMeasure) {\n let wrapping = this.heightOracle.lineWrapping;\n let margin = wrapping ? 10000 /* LG.MarginWrap */ : 2000 /* LG.Margin */, halfMargin = margin >> 1, doubleMargin = margin << 1;\n // The non-wrapping logic won't work at all in predominantly right-to-left text.\n if (this.defaultTextDirection != Direction.LTR && !wrapping)\n return [];\n let gaps = [];\n let addGap = (from, to, line, structure) => {\n if (to - from < halfMargin)\n return;\n let sel = this.state.selection.main, avoid = [sel.from];\n if (!sel.empty)\n avoid.push(sel.to);\n for (let pos of avoid) {\n if (pos > from && pos < to) {\n addGap(from, pos - 10 /* LG.SelectionMargin */, line, structure);\n addGap(pos + 10 /* LG.SelectionMargin */, to, line, structure);\n return;\n }\n }\n let gap = find(current, gap => gap.from >= line.from && gap.to <= line.to &&\n Math.abs(gap.from - from) < halfMargin && Math.abs(gap.to - to) < halfMargin &&\n !avoid.some(pos => gap.from < pos && gap.to > pos));\n if (!gap) {\n // When scrolling down, snap gap ends to line starts to avoid shifts in wrapping\n if (to < line.to && mayMeasure && wrapping &&\n mayMeasure.visibleRanges.some(r => r.from <= to && r.to >= to)) {\n let lineStart = mayMeasure.moveToLineBoundary(_codemirror_state__WEBPACK_IMPORTED_MODULE_2__.EditorSelection.cursor(to), false, true).head;\n if (lineStart > from)\n to = lineStart;\n }\n gap = new LineGap(from, to, this.gapSize(line, from, to, structure));\n }\n gaps.push(gap);\n };\n for (let line of this.viewportLines) {\n if (line.length < doubleMargin)\n continue;\n let structure = lineStructure(line.from, line.to, this.stateDeco);\n if (structure.total < doubleMargin)\n continue;\n let target = this.scrollTarget ? this.scrollTarget.range.head : null;\n let viewFrom, viewTo;\n if (wrapping) {\n let marginHeight = (margin / this.heightOracle.lineLength) * this.heightOracle.lineHeight;\n let top, bot;\n if (target != null) {\n let targetFrac = findFraction(structure, target);\n let spaceFrac = ((this.visibleBottom - this.visibleTop) / 2 + marginHeight) / line.height;\n top = targetFrac - spaceFrac;\n bot = targetFrac + spaceFrac;\n }\n else {\n top = (this.visibleTop - line.top - marginHeight) / line.height;\n bot = (this.visibleBottom - line.top + marginHeight) / line.height;\n }\n viewFrom = findPosition(structure, top);\n viewTo = findPosition(structure, bot);\n }\n else {\n let totalWidth = structure.total * this.heightOracle.charWidth;\n let marginWidth = margin * this.heightOracle.charWidth;\n let left, right;\n if (target != null) {\n let targetFrac = findFraction(structure, target);\n let spaceFrac = ((this.pixelViewport.right - this.pixelViewport.left) / 2 + marginWidth) / totalWidth;\n left = targetFrac - spaceFrac;\n right = targetFrac + spaceFrac;\n }\n else {\n left = (this.pixelViewport.left - marginWidth) / totalWidth;\n right = (this.pixelViewport.right + marginWidth) / totalWidth;\n }\n viewFrom = findPosition(structure, left);\n viewTo = findPosition(structure, right);\n }\n if (viewFrom > line.from)\n addGap(line.from, viewFrom, line, structure);\n if (viewTo < line.to)\n addGap(viewTo, line.to, line, structure);\n }\n return gaps;\n }", "title": "" }, { "docid": "61aa6e97ad1387bd03f1942bdd167541", "score": "0.5360378", "text": "function appendBackgroundBorderLines(paddingGroup, plot) {\n const offset = 0.5;\n paddingGroup.append('path')\n .attr('d',\n 'M ' + (plot.svg.width - plot.padding.left) + ',' + offset + ' ' //top border, right endpoint\n + 'L ' + offset + ',' + offset + ' '\n + offset + ',' + (plot.range.y + offset) + ' '\n + (plot.svg.width - plot.padding.left) + ',' + (plot.range.y + offset) // bottom border, right endpoint\n )\n .attr('class', 'background-border');\n }", "title": "" }, { "docid": "255bb8f1e16a7efae9457a1a7892c6cc", "score": "0.53590065", "text": "function insertLineWidgets(cm, lineView, dims) {\n\t insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n\t if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n\t insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n\t }", "title": "" }, { "docid": "255bb8f1e16a7efae9457a1a7892c6cc", "score": "0.53590065", "text": "function insertLineWidgets(cm, lineView, dims) {\n\t insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n\t if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n\t insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n\t }", "title": "" }, { "docid": "c028fb7432b3010fe256a141ddbd4119", "score": "0.534346", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n var i = 0;\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "c028fb7432b3010fe256a141ddbd4119", "score": "0.534346", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n var i = 0;\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "c028fb7432b3010fe256a141ddbd4119", "score": "0.534346", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n var i = 0;\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "c028fb7432b3010fe256a141ddbd4119", "score": "0.534346", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n var i = 0;\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "7d45e7f679ce8983d606b5266b7d5f5e", "score": "0.5342567", "text": "function insertLineWidgets(cm, lineView, dims) {\n\t insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n\t if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n\t { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n\t}", "title": "" }, { "docid": "7d45e7f679ce8983d606b5266b7d5f5e", "score": "0.5342567", "text": "function insertLineWidgets(cm, lineView, dims) {\n\t insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n\t if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n\t { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n\t}", "title": "" }, { "docid": "d36e8c38b7e76ad3703e77520b562338", "score": "0.5336019", "text": "handleWrapping() {\n\n if (this.x < 0) {\n this.x += width;\n } else if (this.x > width) {\n this.x -= width;\n }\n if (this.y < 0) {\n this.y += height;\n } else if (this.y > height) {\n this.y -= height;\n }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "76334d531640c5148b9a760038fe8aa8", "score": "0.5327243", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) { for (var i = 0; i < lineView.rest.length; i++)\n { insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false); } }\n }", "title": "" }, { "docid": "66825483ac189da3cd11160270b00b3b", "score": "0.5325569", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters\n removeChildren(gutters)\n var i = 0\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i]\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass))\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\"\n }\n }\n gutters.style.display = i ? \"\" : \"none\"\n updateGutterSpace(cm)\n}", "title": "" }, { "docid": "66825483ac189da3cd11160270b00b3b", "score": "0.5325569", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters\n removeChildren(gutters)\n var i = 0\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i]\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass))\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\"\n }\n }\n gutters.style.display = i ? \"\" : \"none\"\n updateGutterSpace(cm)\n}", "title": "" }, { "docid": "66825483ac189da3cd11160270b00b3b", "score": "0.5325569", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters\n removeChildren(gutters)\n var i = 0\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i]\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass))\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\"\n }\n }\n gutters.style.display = i ? \"\" : \"none\"\n updateGutterSpace(cm)\n}", "title": "" }, { "docid": "253bee707f2ade61de675cf5bf105a0b", "score": "0.532094", "text": "function updateGutters(cm) {\r\n var gutters = cm.display.gutters, specs = cm.options.gutters;\r\n removeChildren(gutters);\r\n var i = 0;\r\n for (; i < specs.length; ++i) {\r\n var gutterClass = specs[i];\r\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\r\n if (gutterClass == \"CodeMirror-linenumbers\") {\r\n cm.display.lineGutter = gElt;\r\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\r\n }\r\n }\r\n gutters.style.display = i ? \"\" : \"none\";\r\n updateGutterSpace(cm);\r\n}", "title": "" }, { "docid": "02217556a6aab428d25eb75fa6851308", "score": "0.5315879", "text": "function updateGutters(cm) {\n\t var gutters = cm.display.gutters, specs = cm.options.gutters\n\t removeChildren(gutters)\n\t var i = 0\n\t for (; i < specs.length; ++i) {\n\t var gutterClass = specs[i]\n\t var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass))\n\t if (gutterClass == \"CodeMirror-linenumbers\") {\n\t cm.display.lineGutter = gElt\n\t gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\"\n\t }\n\t }\n\t gutters.style.display = i ? \"\" : \"none\"\n\t updateGutterSpace(cm)\n\t}", "title": "" }, { "docid": "6801eb1ee1f24bd7e3f806384f4d1c5e", "score": "0.5293291", "text": "function gutterEvent(cm,e,type,prevent){var mX,mY;try{mX=e.clientX;mY=e.clientY;}catch(e){return false;}if(mX>=Math.floor(cm.display.gutters.getBoundingClientRect().right)){return false;}if(prevent){e_preventDefault(e);}var display=cm.display;var lineBox=display.lineDiv.getBoundingClientRect();if(mY>lineBox.bottom||!hasHandler(cm,type)){return e_defaultPrevented(e);}mY-=lineBox.top-display.viewOffset;for(var i=0;i<cm.options.gutters.length;++i){var g=display.gutters.childNodes[i];if(g&&g.getBoundingClientRect().right>=mX){var line=_lineAtHeight(cm.doc,mY);var gutter=cm.options.gutters[i];signal(cm,type,cm,line,gutter,e);return e_defaultPrevented(e);}}}", "title": "" }, { "docid": "6780e3c501e09215b67ff49e16239a91", "score": "0.52931", "text": "ensureLineGaps(current, mayMeasure) {\n let wrapping = this.heightOracle.lineWrapping;\n let margin = wrapping ? 10000 /* LG.MarginWrap */ : 2000 /* LG.Margin */, halfMargin = margin >> 1, doubleMargin = margin << 1;\n // The non-wrapping logic won't work at all in predominantly right-to-left text.\n if (this.defaultTextDirection != Direction.LTR && !wrapping)\n return [];\n let gaps = [];\n let addGap = (from, to, line, structure) => {\n if (to - from < halfMargin)\n return;\n let sel = this.state.selection.main, avoid = [sel.from];\n if (!sel.empty)\n avoid.push(sel.to);\n for (let pos of avoid) {\n if (pos > from && pos < to) {\n addGap(from, pos - 10 /* LG.SelectionMargin */, line, structure);\n addGap(pos + 10 /* LG.SelectionMargin */, to, line, structure);\n return;\n }\n }\n let gap = find(current, gap => gap.from >= line.from && gap.to <= line.to &&\n Math.abs(gap.from - from) < halfMargin && Math.abs(gap.to - to) < halfMargin &&\n !avoid.some(pos => gap.from < pos && gap.to > pos));\n if (!gap) {\n // When scrolling down, snap gap ends to line starts to avoid shifts in wrapping\n if (to < line.to && mayMeasure && wrapping &&\n mayMeasure.visibleRanges.some(r => r.from <= to && r.to >= to)) {\n let lineStart = mayMeasure.moveToLineBoundary(EditorSelection.cursor(to), false, true).head;\n if (lineStart > from)\n to = lineStart;\n }\n gap = new LineGap(from, to, this.gapSize(line, from, to, structure));\n }\n gaps.push(gap);\n };\n for (let line of this.viewportLines) {\n if (line.length < doubleMargin)\n continue;\n let structure = lineStructure(line.from, line.to, this.stateDeco);\n if (structure.total < doubleMargin)\n continue;\n let target = this.scrollTarget ? this.scrollTarget.range.head : null;\n let viewFrom, viewTo;\n if (wrapping) {\n let marginHeight = (margin / this.heightOracle.lineLength) * this.heightOracle.lineHeight;\n let top, bot;\n if (target != null) {\n top = Math.max(line.from, target - margin);\n bot = Math.min(line.to, target + margin);\n }\n else {\n top = (this.visibleTop - line.top - marginHeight) / line.height;\n bot = (this.visibleBottom - line.top + marginHeight) / line.height;\n }\n viewFrom = findPosition(structure, top);\n viewTo = findPosition(structure, bot);\n }\n else {\n let left, right;\n if (target != null) {\n left = Math.max(line.from, target - doubleMargin);\n right = Math.min(line.to, target + doubleMargin);\n }\n else {\n let totalWidth = structure.total * this.heightOracle.charWidth;\n let marginWidth = margin * this.heightOracle.charWidth;\n left = (this.pixelViewport.left - marginWidth) / totalWidth;\n right = (this.pixelViewport.right + marginWidth) / totalWidth;\n }\n viewFrom = findPosition(structure, left);\n viewTo = findPosition(structure, right);\n }\n if (viewFrom > line.from)\n addGap(line.from, viewFrom, line, structure);\n if (viewTo < line.to)\n addGap(viewTo, line.to, line, structure);\n }\n return gaps;\n }", "title": "" }, { "docid": "9b537d5678049671ef1eb7bcf4255255", "score": "0.52913743", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters,\n specs = cm.options.gutters;\n removeChildren(gutters);\n var i = 0;\n for (; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "d64ac72cf1a76dc004bcef99f48ad90e", "score": "0.5289934", "text": "function insertLineWidgets(cm, lineView, dims) {\n insertLineWidgetsFor(cm, lineView.line, lineView, dims, true);\n if (lineView.rest) for (var i = 0; i < lineView.rest.length; i++)\n insertLineWidgetsFor(cm, lineView.rest[i], lineView, dims, false);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" }, { "docid": "452d2fdb7b511a602636665a362663af", "score": "0.52827287", "text": "function updateGutters(cm) {\n var gutters = cm.display.gutters, specs = cm.options.gutters;\n removeChildren(gutters);\n for (var i = 0; i < specs.length; ++i) {\n var gutterClass = specs[i];\n var gElt = gutters.appendChild(elt(\"div\", null, \"CodeMirror-gutter \" + gutterClass));\n if (gutterClass == \"CodeMirror-linenumbers\") {\n cm.display.lineGutter = gElt;\n gElt.style.width = (cm.display.lineNumWidth || 1) + \"px\";\n }\n }\n gutters.style.display = i ? \"\" : \"none\";\n updateGutterSpace(cm);\n }", "title": "" } ]
1f6a26030fa8bc1afda45c900a585c56
the following progress bar functions are described here:
[ { "docid": "9c5826a40381a122336af1273486e9ae", "score": "0.0", "text": "function roundRect(ctx, x, y, width, height, radius) {\n ctx.beginPath();\n ctx.moveTo(x + radius, y);\n ctx.lineTo(x + width - radius, y);\n ctx.arc(x+width-radius, y+radius, radius, -Math.PI/2, Math.PI/2, false);\n ctx.lineTo(x + radius, y + height);\n ctx.arc(x+radius, y+radius, radius, Math.PI/2, 3*Math.PI/2, false);\n ctx.closePath();\n ctx.fill();\n }", "title": "" } ]
[ { "docid": "d867825e8d2568122609320e1493c401", "score": "0.81315356", "text": "function progressBar(){\n\t\t\tif(percent <= 100){\n\t\t\t\t$(timerProgress).width(percent + \"%\");\n\t\t\t\tpercent++;\n\t\t\t}\n\t\t\telse{\n\t\t\t\tif(timer.loop === 1){\n\t\t\t\t\tpercent = 0;\n\t\t\t\t\tswitchImages(currentIndex);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\treturn;\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "4ae3606785be2b798b37f48e32ec1fe9", "score": "0.8102116", "text": "function incProgressBar() {}", "title": "" }, { "docid": "8771678b65f1e75600edd4ec95f8ff8b", "score": "0.79046386", "text": "function ProgressBar() {\n\tvar prog = ((positionSequence + 1)) * nbBricks;\n\t\n\t$(\".progress-bar\").attr(\"style\", \"width: \" + prog + \"%\");\n\t$(\".progress-bar\").text((positionSequence + 1) + \" / \" + nbBricks + \" briques\")\n}", "title": "" }, { "docid": "d75f9cb1ba12c8f2905215ab773a292b", "score": "0.7878697", "text": "function incProgress( ) {\n progresBar=progresBar+1;\n // bar1.set(progresBar);\n if(progresBar==100){\n hideProgressBar();\n // bufferAnm.style.visibility = \"hidden\";\n box.style.visibility = \"visible\";\n box.style.zIndex = 3;\n bufferAnm.style.visibility = \"hidden\";\n bufferAnm.style.zIndex = -2;\n progresBar=0;\n\n }else if(progresBar<100){\n showProgressBar();\n updateProgressBar( progresBar ); \n }else{\n //nothing \n } \n }", "title": "" }, { "docid": "989a62662d1727707a2d7a2306b13960", "score": "0.78391415", "text": "function makeProgress(){\r\n\t\t\r\n\t\tvar currentWidth = bar.width();\r\n\t\t\r\n\t\tif(widthCounter < 100){\r\n\t\t\t\r\n\t\t\twidthCounter += increment;\r\n\t\t\t\r\n\t\t\tbar.css(\"width\", widthCounter + \"%\");\r\n\t\t\t\r\n\t\t\tif(widthCounter < 88){\r\n\t\t\t\t\r\n\t\t\t\tbar_marker.css(\"margin-left\", widthCounter + \"%\");\r\n\t\t\t}\t\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "5b8e35e48459e7c7c48aa509a0e2615b", "score": "0.7661717", "text": "function update_progress_bar()\n\t\t\t{\n\t\t\t\tvar diff=total_time-char_time_begin;\n\t\t\t\tvar bar,percent;\n\t\t\t\tif(diff<18)\n\t\t\t\t{\n\t\t\t\t\tbar=document.getElementById(\"bar_one\");\n\t\t\t\t\tdocument.getElementById(\"bar_two\").style.width=\"28%\";\n\t\t\t\t\tdocument.getElementById(\"bar_three\").style.width=\"28%\";\n\t\t\t\t\tpercent=30*(17-diff)/18;\n\t\t\t\t\tconsole.log(percent);\n\t\t\t\t\tbar.style.width=percent+\"%\";\n\t\t\t\t}\n\t\t\t\telse if(diff<=36)\n\t\t\t\t{\n\t\t\t\t\tdiff=diff-18;\n\t\t\t\t\tbar=document.getElementById(\"bar_two\");\n\t\t\t\t\tdocument.getElementById(\"bar_three\").style.width=\"28%\";\n\t\t\t\t\tpercent=30*(17-diff)/18;\n\t\t\t\t\tbar.style.width=percent+\"%\";\n\t\t\t\t}\n\n\t\t\t\telse if(diff<=54)\n\t\t\t\t{\n\t\t\t\t\tdiff=diff-36;\n\t\t\t\t\tbar=document.getElementById(\"bar_three\");\n\t\t\t\t\tpercent=30*(18-diff)/18;\n\t\t\t\t\tbar.style.width=percent+\"%\";\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "d1812128f76d8b1c7d90a8440e8966d8", "score": "0.76411057", "text": "function addProgress() {\n\t //increase myBarWidth by 100/questionsNumber\n\t myBarWidth += 100 / numberQuestions;\n\t // make sure that width of the progress bar won't be more than 100% & fix for questionsNumber that are not dividers of 100\n\t if (myBarWidth > 100) {\n\t myBarWidth = 100;\n\t }\n\t // update the width #myBar by changing the css\n\t document.getElementById(\"myBar\").style.width = myBarWidth + \"%\";\n\t}", "title": "" }, { "docid": "e34ed66b059d2bccec2edd51c7440862", "score": "0.76004577", "text": "function setProgress(progress)\n\t{ \n var progressBarWidth =progress*$(\".progBar\").width()/ 100; \n $(\".progressbar\").animate({width:progressBarWidth},500).html(progress + \"% \");\n\t}", "title": "" }, { "docid": "65165fc8554f3d16bb0a942b523fd6f3", "score": "0.756685", "text": "function UpdateBar(percentage) {\n progressBar.css('width', function() {\n return percentage + '%'\n });\n percent.html( Math.round(percentage*100) / 100 + '%' );\n MB.html( Math.round( ( (percentage/100)*SelectedFile.size)/1048576 ) );\n }", "title": "" }, { "docid": "7a54af7fcfe268fb839c8c150fccd770", "score": "0.7565559", "text": "function progressBar() {\n function timer(n) {\n $(\".progress-bar\").css(\"width\", n + \"%\");\n if(n < 100) {\n setTimeout(function() {\n timer(n + 10);\n }, 200);\n }\n }\n\n timer(0);\n}", "title": "" }, { "docid": "db33e75b0d3fa07666a1475af99e7180", "score": "0.7555489", "text": "function updateBar() { // permettant d'animer la barre de progression\n if (current_progress > 100) current_progress = 100;\n $(\"#dynamic\")\n .css(\"width\", current_progress + \"%\")\n .attr(\"aria-valuenow\", current_progress)\n .text(current_progress + \"% Complete\");\n }", "title": "" }, { "docid": "bbeadc29353ad875029c423edf476e7e", "score": "0.7530802", "text": "progress() {\n var elem = document.getElementById(\"myBar\"); \n var width = 10;\n var id = setInterval(frame, 0.7);\n function frame() {\n if (width >= 100) {\n clearInterval(id);\n } else {\n width++; \n elem.style.width = width + '%'; \n elem.style.backgroundColor=\"blue\";\n elem.innerHTML = width * 1 + '%';\n }\n }\n }", "title": "" }, { "docid": "2ac6418692b3d5e786df703f92af9de4", "score": "0.7451164", "text": "function updateProgressbar(){\n\t\t\tvar percentage = 100*ytplayer.getCurrentTime()/ytplayer.getDuration();\n\t\t\t$(\"#progressbar_filler\").css(\"width\", percentage+\"%\");\n\t\t}", "title": "" }, { "docid": "9c2377b935803aad52881825c76fc8d9", "score": "0.74482876", "text": "function progressBar(elem){\n\t\t $elem = elem;\n\t\t //build progress bar elements\n\t\t buildProgressBar();\n\t\t //start counting\n\t\t start();\n\t\t}", "title": "" }, { "docid": "9c2377b935803aad52881825c76fc8d9", "score": "0.74482876", "text": "function progressBar(elem){\n\t\t $elem = elem;\n\t\t //build progress bar elements\n\t\t buildProgressBar();\n\t\t //start counting\n\t\t start();\n\t\t}", "title": "" }, { "docid": "a7137127ccb5d49d372d026ea518257c", "score": "0.7435428", "text": "function progressBar(elem){\n\t $elem = elem;\n\t //build progress bar elements\n\t buildProgressBar();\n\t //start counting\n\t start();\n\t }", "title": "" }, { "docid": "a7137127ccb5d49d372d026ea518257c", "score": "0.7435428", "text": "function progressBar(elem){\n\t $elem = elem;\n\t //build progress bar elements\n\t buildProgressBar();\n\t //start counting\n\t start();\n\t }", "title": "" }, { "docid": "74643df19e3728d62493e67b949e6cd5", "score": "0.7433478", "text": "function progressBar(elem){\r\n\t\t $elem = elem;\r\n\t\t //build progress bar elements\r\n\t\t buildProgressBar();\r\n\t\t //start counting\r\n\t\t start();\r\n\t\t}", "title": "" }, { "docid": "7bff5e91c06d55a13037a1329dd223a3", "score": "0.7427803", "text": "function progressBar(val, range) {\n noStroke();\n fill(255, 0, 0, 180);\n rect(0, 0, width*val/range, 3);\n}", "title": "" }, { "docid": "2187e99a4739d5a3013320c7e7287b88", "score": "0.739855", "text": "drawProgressBar() {\n // if (document.querySelector('#jspsych-progressbar-container') === null) {\n // let div = document.createElement('div');\n // div.id = 'jspsych-progressbar-container';\n // let outer = document.createElement('div');\n // outer.id = 'progressbar-outer';\n // div.appendChild(outer);\n // let inner = document.createElement('div');\n // inner.id = 'progressbar-inner';\n // outer.appendChild(inner);\n // let content = document.querySelector('.jspsych-content-wrapper');\n // content.parentElement.insertBefore(div, content);\n // }\n // let inner = document.querySelector('#progressbar-inner');\n // inner.style.width = ((this.currentTrialIndex + 1) / this.trials.length * 100).toString()+'%';\n }", "title": "" }, { "docid": "a94f16ed316602749d04d149fc0ed6b4", "score": "0.73802197", "text": "function updateProgressInfo() {\n\tif (!div_progress_info) {\n\t\tdiv_progress_info = document.getElementById('progress_info');\n\t}\n\tif (!div_progress_bar) {\n\t\tdiv_progress_bar = document.getElementById('progress_bar');\n\t}\n\tif (!div_progress_info && !div_progress_bar) {\n\t\treturn;\n\t}\n\n\tvar percentage = Math.floor(100.0*blamedLines/totalLines);\n\n\tif (div_progress_info) {\n\t\tdiv_progress_info.firstChild.data = blamedLines + ' / ' + totalLines +\n\t\t\t' (' + padLeftStr(percentage, 3, '\\u00A0') + '%)';\n\t}\n\n\tif (div_progress_bar) {\n\t\t//div_progress_bar.setAttribute('style', 'width: '+percentage+'%;');\n\t\tdiv_progress_bar.style.width = percentage + '%';\n\t}\n}", "title": "" }, { "docid": "c86fca968b1157cee14afea58d8b1afa", "score": "0.7371707", "text": "function progressBar(elem){\n $elem = elem;\n //build progress bar elements\n buildProgressBar();\n //start counting\n start();\n }", "title": "" }, { "docid": "aacc0b00d5ebfd46c8c95b08abdb001b", "score": "0.7363603", "text": "function updateProcessBar(action, valueBar){\n\t\t document.getElementById(action+'_progressbar').style.width = valueBar*100+'%';\n\t}", "title": "" }, { "docid": "2923dcff5f26b46b867fe4a31598fb7e", "score": "0.73546106", "text": "function updateProgressBar(){\n\t\tif(progress < 100){\n\t\t\tprogress = progress += updateVal; //13 calls\n \t\t$rootScope.$broadcast('loading-bar-updated', progress, map);\n\t\t}\n }", "title": "" }, { "docid": "b541d1ef87f469f506e22612cd99eb84", "score": "0.7347018", "text": "function progressBar(elem){\r\n $elem = elem;\r\n //build progress bar elements\r\n buildProgressBar();\r\n //start counting\r\n start();\r\n }", "title": "" }, { "docid": "be8986c2379b9b63185bc9053a05fb38", "score": "0.7341815", "text": "function progressBar(elem){\r\n $elem = elem;\r\n //build progress bar elements\r\n buildProgressBar();\r\n //start counting\r\n start();\r\n }", "title": "" }, { "docid": "c31b20d9748444759d844e95aa6fee0f", "score": "0.7335867", "text": "function progress() {\r\n var progressBar = document.getElementById('progressBar');\r\n var progressFloat = document.getElementById('progress');\r\n var left = progressFloat.style.marginLeft.match(/\\d+/);\r\n var width = progressFloat.style.width.match(/\\d+/);\r\n var position = parseInt(left) + parseInt(width);\r\n\r\n //Set the progressFloat to zero once completed\r\n if (position >= parseInt(progressBar.style.width)) {\r\n //reduce width\r\n width = parseInt(width) - 5;\r\n //increment progressFloat bar position\r\n progressFloat.style.marginLeft = parseInt(left) + 5 + 'px';\r\n progressFloat.style.width = parseInt(width) + 'px';\r\n \r\n //reset progress bar position if width is zero\r\n if(width <= 0){\r\n left = 0;\r\n progressFloat.style.marginLeft = parseInt(left);\r\n \r\n }\r\n } else {\r\n //increment width\r\n if (parseInt(width) < 100) {\r\n left = -5; //do not move float until its width is 100\r\n width = parseInt(width) + 5;\r\n }\r\n //increment progressFloat bar position\r\n progressFloat.style.marginLeft = parseInt(left) + 5 + 'px';\r\n progressFloat.style.width = parseInt(width) + 'px';\r\n }\r\n //Request time out \r\n if (++timeOut > 1000){\r\n showStatusMessage(\"Request timed out! Please check the logs.\");\r\n endRequest();\r\n }\r\n}", "title": "" }, { "docid": "54ead82150c3c5c0e388d34042dfbeb2", "score": "0.73299974", "text": "function progressBar(elem){\n $elem = elem;\n //build progress bar elements\n buildProgressBar();\n //start counting\n start();\n }", "title": "" }, { "docid": "59ebd92a610b3ff2dc5161db0e2f5361", "score": "0.73292106", "text": "function progressBar(elem){\n $elem = elem;\n //build progress bar elements\n buildProgressBar();\n //start counting\n start();\n }", "title": "" }, { "docid": "6b32f5b578d22f5f93cb1c8eb448dd1e", "score": "0.73246044", "text": "function progressBar(elem){\n $elem = elem;\n //build progress bar elements\n buildProgressBar();\n //start counting\n start();\n }", "title": "" }, { "docid": "451dc801cc2bf6a50a4437778a436568", "score": "0.7319271", "text": "progressFunc(progress) {\n if(this.phase === 'ANALYSIS') {\n this.spinnerIndicator.text = ` %s read ${progress.readFolders} folder(s) | ${progress.readThreads} thread(s)`;\n }\n else if(this.phase === 'EXPORT') {\n this.progressIndicator.update(progress.threadsProcessed);\n }\n }", "title": "" }, { "docid": "d082c7cc0dee756d16a4def01e886435", "score": "0.73110884", "text": "function progressBar(elem){\n $elem = elem;\n //build progress bar elements\n buildProgressBar();\n //start counting\n start();\n }", "title": "" }, { "docid": "e81cc354ec0cbe98a90fdd9b97bf4e2a", "score": "0.73074156", "text": "function drawProgressBar() {\n var point = API.worldToScreenMantainRatio(positions[0]);\n var newPoint = Point.Round(point);\n // taskHealth * 3 (100 = 300);\n API.drawRectangle(newPoint.X - 170, newPoint.Y - 10, 320, 40, 0, 0, 0, 100);\n API.drawRectangle(newPoint.X - 160, newPoint.Y, (taskHealth * 3), 20, 0, 255, 0, 100);\n}", "title": "" }, { "docid": "8a1da48511929744dc8474d43f77b4a2", "score": "0.729572", "text": "function progressBar(data, index) {\n index = index + 1; // because we're dealing with the question number not the actual index in an array\n var barWidth = (index * 100) / data.length;\n $('#progressBar #bar').css('width', barWidth + '%');\n }", "title": "" }, { "docid": "3270cec375b22c08c19fe506164e9cd1", "score": "0.7288967", "text": "function refreshBar() {\n var value = (100 / 7) * (step - 1) + \"%\";\n $(\".progress-bar\").css('width', value).attr('aria-valuenow', value);\n }", "title": "" }, { "docid": "3bf4bce1595f2db67a8fe4f415fbb5fc", "score": "0.7270543", "text": "function progressBar(){\r\n\tvar currentBegin = stories[currentStory].begin;\r\n\tvar currentEnd = stories[currentStory].end;\r\n\tvar totalTime = currentEnd - currentBegin;\r\n\tvar progress = ((currentTime - currentBegin) / totalTime) * 100;\r\n\r\n\tvar bar;\r\n\tif(isReadMoreShowing()){\r\n\t\tbar = document.getElementsByClassName(\"progress-bar\")[0];\r\n\t}else{\r\n\t\tbar = document.getElementById(\"mini-bar\");\r\n\t}\r\n\t\r\n\tbar.style.width = progress + \"%\";\r\n}", "title": "" }, { "docid": "0acaddd06c4f7394fc6b9a3b63af1eee", "score": "0.72495073", "text": "function bar_progress(direction) {\n const number_of_steps = progressLine.data('number-of-steps');\n const now_value = progressLine.data('now-value');\n let new_value = 0;\n if (direction == 'right') {\n new_value = now_value + (100 / number_of_steps);\n }\n else if (direction == 'left') {\n new_value = now_value - (100 / number_of_steps);\n }\n progressLine.attr('style', 'width: ' + new_value + '%;').data('now-value', new_value);\n }", "title": "" }, { "docid": "f6b1e0d81fb6b2d7b7861c1fb3cd8d28", "score": "0.722557", "text": "function updateProgress(progress) {\n progress = Math.floor(progress * 100);\n const progressBar = document.getElementById(\"progress-bar\");\n const progressPercentage = document.getElementById(\n \"progress-percentage\"\n );\n progressBar.setAttribute(\"style\", `width:${progress}%`);\n progressPercentage.innerHTML = `&nbsp;${progress}%`;\n }", "title": "" }, { "docid": "bcc7a01e57ae44629e64c22b00d95399", "score": "0.7221543", "text": "function progression() {\n progress = 100 / subjects.length * getqeustionId;\n\n document.getElementById(\"progress-bar\").style.width = progress.toString() + \"%\";\n}", "title": "" }, { "docid": "63591f3b43c7da97e7940c4b0780585c", "score": "0.7203351", "text": "function ProgressBar() {\r\n \r\n\t\tvar getMax = function(){\r\n\t\t\treturn $(document).height() - $(window).height();\r\n\t\t}\r\n\t\t\r\n\t\tvar getValue = function(){\r\n\t\t\treturn $(window).scrollTop();\r\n\t\t}\r\n\t\t\r\n\t\tif('max' in document.createElement('progress')){\r\n\t\t\tvar progressBar = $('progress');\r\n\t\t\t\r\n\t\t\tprogressBar.attr({ max: getMax() });\r\n\t\r\n\t\t\t$(document).on('scroll', function(){\r\n\t\t\t\tprogressBar.attr({ value: getValue() });\r\n\t\t\t});\r\n\t\t \r\n\t\t\t$(window).resize(function(){\r\n\t\t\t\tprogressBar.attr({ max: getMax(), value: getValue() });\r\n\t\t\t}); \r\n\t\t}\r\n\t\telse {\r\n\t\t\tvar progressBar = $('.progress_bar'), \r\n\t\t\t\tmax = getMax(), \r\n\t\t\t\tvalue, width;\r\n\t\t\t\r\n\t\t\tvar getWidth = function(){\r\n\t\t\t\tvalue = getValue(); \r\n\t\t\t\twidth = (value/max) * 100;\r\n\t\t\t\twidth = width + '%';\r\n\t\t\t\treturn width;\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\tvar setWidth = function(){\r\n\t\t\t\tprogressBar.css({ width: getWidth() });\r\n\t\t\t}\r\n\t\t\t\r\n\t\t\t$(document).on('scroll', setWidth);\r\n\t\t\t$(window).on('resize', function(){\r\n\t\t\t\tmax = getMax();\r\n\t\t\t\tsetWidth();\r\n\t\t\t});\r\n\t\t}\r\n\t\r\n\t $('#flat').addClass(\"active\");\r\n\t $('#progressBar').addClass('flat');\r\n\t\t\r\n\t $('#flat').on('click', function(){\r\n\t\t$('#progressBar').removeClass().addClass('flat');\r\n\t\t$('a').removeClass();\r\n\t\t$(this).addClass('active');\r\n\t\t$(this).preventDefault();\r\n\t });\r\n\t\t\r\n\t\t\r\n\t}", "title": "" }, { "docid": "a0546f7c1337a261eb52d9714ed39c3b", "score": "0.71983457", "text": "function progressBar(progressVal,totalPercentageVal = 100) {\n var strokeVal = (4.64 * 100) / totalPercentageVal;\n\tvar x = document.querySelector('.progress-circle-prog');\n x.style.strokeDasharray = progressVal * (strokeVal) + ' 999';\n\t//$('.progress-text').data('progress', progressVal);\n}", "title": "" }, { "docid": "36b9a87b37213fdb7b0cb85e8b6b1ace", "score": "0.7191395", "text": "setProgress(percentage) {\n let bar = document.getElementById(\"loading_bar\");\n bar.style.width = percentage * 400 + \"px\";\n }", "title": "" }, { "docid": "4b7d16684f10a9df68dd72143787d690", "score": "0.71888804", "text": "function updateProgressBar()\n{\n var width = (index + 1) / (numberOfCards + 1) * 100;\n progressBar.style.width = width + '%';\n}", "title": "" }, { "docid": "639cddcf12ddace06f989aa18fa62cfa", "score": "0.71885896", "text": "function Progressbar(bar) {\n // define `p` object and all parameters associated to it\n var p = [\n \"bar\", \"points\", \"pointCount\", \"activePoint\", \"maxIndex\",\n \"activePointIndex\", \"nextPointIndex\", \"prevPointIndex\", \"onChange\"\n ].reduce((p, param) => { p[ param ] = null; return p; }, {});\n\n // assign progress bar element to the object\n p.bar = bar;\n // create a new event for `change` of progress bar\n p.onChange = new Event(\"change\");\n // initialise all the points on the progress bar\n initPoints();\n // bind and expose methods to the progress bar\n // usage: `document.getElementById('progressbar').next();`\n p.bar.next = __next.bind(p.bar);\n p.bar.prev = __prev.bind(p.bar);\n p.bar.pick = __pick.bind(p.bar);\n\n /**\n * pick() iterates all points and activates the requested index then\n * deactivates all other points. Always use this method to activate a point.\n *\n * @param int index\n * @return void\n */\n function pick(index) {\n p.points.forEach((point, i) => __setActivePoint(point, (i === index)));\n p.bar.dispatchEvent(p.onChange);\n }\n\n /**\n * __next() contains logic to move the progress bar on to the next point\n *\n * @param fn callback\n * @return void\n */\n function __next(callback) {\n if (p.activePointIndex !== p.nextPointIndex) {\n pick(p.nextPointIndex);\n if (typeof callback === \"function\") callback(p);\n }\n }\n\n /**\n * __prev() contains logic to move the progress bar back to the last point\n *\n * @param fn callback\n * @return void\n */\n function __prev(callback) {\n if (p.activePointIndex !== p.prevPointIndex) {\n pick(p.prevPointIndex);\n if (typeof callback === \"function\") callback(p);\n }\n }\n\n /**\n * __pick() contains logic to move the progress bar to the requested point\n *\n * @param int point\n * @param fn callback\n * @return void\n */\n function __pick(point, callback) {\n if (p.activePointIndex !== point) {\n pick(point);\n if (typeof callback === \"function\") callback(p);\n }\n }\n\n /**\n * __setActivePoint() if `active` is true, sets the requested point as the\n * active point and sets indexes for active, next and previous points. If\n * `active` is false then removes active status from this point\n *\n * This method should only be called via the `pick()` method to ensure\n * other points are deactivated.\n *\n * @param object point\n * @param active bool\n * @return void\n */\n function __setActivePoint(point, active) {\n if (active === true) {\n p.activePoint = point;\n p.activePointIndex = p.points.indexOf(point);\n p.nextPointIndex = Math.min((p.activePointIndex + 1), p.maxIndex);\n p.prevPointIndex = Math.max((p.activePointIndex - 1), 0);\n point.dataset.active = 1;\n }\n else {\n delete point.dataset.active;\n }\n }\n\n /**\n * initPoints() loops through and initialises all points within the\n * initialised `bar` element\n *\n * @return void\n */\n function initPoints() {\n p.points = Array.from(p.bar.getElementsByTagName(\"li\"));\n p.points.forEach((point, i) => {\n point.className = point.className.concat(\" progressbar__item\").trim();\n // define active index\n if (point.dataset.active && p.activePointIndex === null)\n p.activePointIndex = i;\n });\n p.pointCount = p.points.length;\n p.maxIndex = p.pointCount - 1;\n pick(p.activePointIndex || 0);\n }\n }", "title": "" }, { "docid": "a751d2284e3a12c03b9b4313e13fd162", "score": "0.7183224", "text": "function reportProgress() {\n var barwidth = 500;\n var sliderwidth = 30;\n // get current time\n var time = Math.round(this.currentTime);\n //get the media play time\n var duration = parseInt(this.duration);\n //calculate the position on the progress bar\n var position = barwidth * (time / duration);\n if (isNaN(position)) return;\n //update the progress bar\n document.getElementById(\"loadingprogress\").style.width=position + \"px\";\n // update the position of the butterfly\n var butterfly = document.getElementById(\"butterfly\");\n if (position <= (barwidth - Math.round(sliderwidth / 2))) {\n butterfly.style.left=position + \"px\";\n } else {\n butterfly.style.left=barwidth - Math.round(sliderwidth / 2);\n }\n }", "title": "" }, { "docid": "70587165291462a3e52d991da421bc68", "score": "0.71739936", "text": "function updateProgress() {\n var progress = pathsAndPrices.length / numPaths * 100;\n document.getElementById(\"progressbar\").style.width = progress + \"%\";\n console.log(\"Progress:\", progress);\n}", "title": "" }, { "docid": "b61d03c4b6318101e6c199979800528e", "score": "0.7173494", "text": "function updateProgressBar(){\n\t\t$numDone = $(\".next.ready\").length;\n\t\t$f.percentDone = 100*$numDone / $f.length;\n\t\t$f.progressBarDiv.css('width',$f.percentDone + \"%\");\n\t\t$f.numberDoneElement.html($numDone);\n\t}", "title": "" }, { "docid": "ab71d878b93d6ce8e80bd42958480b4d", "score": "0.7166678", "text": "loadingBar() {\n\n if (!this._progressBarAdded) {\n\n //Run the method that creates the progress bar object\n this.makeProgressBar(this);\n\n //Create the loading bar\n this.progressBar.create();\n\n //Tell Hexi that a progress bar has been added\n this._progressBarAdded = true;\n } else {\n\n //Update the progress bar each frame\n this.progressBar.update();\n }\n }", "title": "" }, { "docid": "321fb616b0d9e14bc8cecc76fab58ccb", "score": "0.7166195", "text": "function makeProgress(percent) {\r\n var p = percent * 100;\r\n var rounded = p.toFixed(2);\r\n\r\n $('#pBar').attr('aria-valuenow', rounded).css('width', rounded + '%').text(rounded + '%')\r\n }", "title": "" }, { "docid": "7ea0f01d47c96cf64627761ea45df756", "score": "0.71646357", "text": "function animateProressBar($myBar){\n // 1. get parent element width\n var $parent = $myBar.closest('.bar');\n var parentWidth = getElementWidth($parent);\n var elementWidth = getElementWidth($myBar);\n console.log(getElementProgress(elementWidth,parentWidth));\n\n // 2. \n setInterval(function(){\n var elementWidth = getElementWidth($myBar);\n if(state == 1){\n if(getElementProgress(elementWidth,parentWidth)<uperLimit){\n increaseProgress($myBar,elementWidth);\n }else{\n state = 2;\n }\n }else{\n if(getElementProgress(elementWidth,parentWidth)>lowerLimit){\n decreaseProgress($myBar,elementWidth);\n }else{\n state = 1;\n }\n }\n \n \n \n },100)\n\n}", "title": "" }, { "docid": "245909307745ca8edb1e02e0a5f7aea7", "score": "0.7160048", "text": "progress(percent) {\n this.loadingBar.setAttributeNS(null, 'width', percent * 155 + ''); // 155 = width of the bar\n }", "title": "" }, { "docid": "6ab2077d58971363c51177c8a7faaffe", "score": "0.7156899", "text": "function draw(progress){\n\t\t\n\t}", "title": "" }, { "docid": "5c1206fe0851b0eb4fd1f477dd28a3d8", "score": "0.71391547", "text": "function updateProgress() {\n steps.forEach((step, index) => {\n if(index < currentStep) {\n step.classList.add(\"active\");\n } else {\n step.classList.remove(\"active\");\n }\n });\n\n // Actualizar barra\n const progress = (currentStep - 1) / (steps.length -1) * 100\n bar.style.width = progress + \"%\"\n\n // Control de los botones\n if (currentStep == steps.length) {\n nextButton.disabled = true\n } else if (currentStep == 1){ \n prevButton.disabled = true;\n }else {\n prevButton.disabled = nextButton.disabled = false;\n }\n}", "title": "" }, { "docid": "420aebc5af0fc9c5dfbdf410c4f1c786", "score": "0.71231383", "text": "function updateProgressBar(e) {\n\tif (e.lengthComputable) {\n\t\tvar completedPercentage = parseInt((e.loaded + totalValOfUploadedFiles) * 100 / noOfSelectedFiles);\n\t\tvar progressBar = document.getElementById('prBar');\n\t\tprogressBar.style.width = completedPercentage + '%';\n\t\tprogressBar.innerHTML = completedPercentage + ' % Completed';\n\t} else {\n\t\tconsole.err(\"Incapable to figure length\");\n\t}\n}", "title": "" }, { "docid": "df18989151adf3e9342f7380e529970d", "score": "0.711748", "text": "showProgressBar() {\n // Get the progress bar filler texture dimensions.\n const {width: w, height: h} = this.textures.get('progress-bar').get();\n\n // Place the filler over the progress bar of the splash screen.\n const img = this.add.sprite(82, 282, 'progress-bar').setOrigin(0);\n\n // Crop the filler along its width, proportional to the amount of files\n // loaded.\n this.load.on('progress', v => img.setCrop(0, 0, Math.ceil(v * w), h));\n }", "title": "" }, { "docid": "f8d915e122ba6fd72c5e0b957992e453", "score": "0.7114456", "text": "function updateProgress(remaining) {\n var percent = 100 - (remaining / numTests) * 100;\n get('progressbar').setAttribute(\"style\", \"width:\"+percent + \"%\");\n get('progressbarTop').setAttribute(\"style\", \"width:\"+percent + \"%\");\n}", "title": "" }, { "docid": "7129774198dad8fa792740ff8060d9e7", "score": "0.71104413", "text": "function animateProgressBar() {\n\t$('.pro-bar').each(function (i, elem) {\n\t\tvar elem = $(this),\n\t\t\tpercent = elem.attr('data-pro-bar-percent'),\n\t\t\tdelay = elem.attr('data-pro-bar-delay');\n\n\t\tif (!elem.hasClass('animated'))\n\t\t\telem.css({\n\t\t\t\t'width': '0%'\n\t\t\t});\n\n\t\tif (elem.visible(true)) {\n\t\t\tsetTimeout(function () {\n\t\t\t\telem.animate({\n\t\t\t\t\t'width': percent + '%'\n\t\t\t\t}, 2000, 'easeInOutExpo').addClass('animated');\n\t\t\t}, delay);\n\t\t}\n\t});\n}", "title": "" }, { "docid": "1c8e42c82189c8031f124cf43e8c7525", "score": "0.7110417", "text": "function updateProgressBar() {\n var winScroll = document.body.scrollTop || document.documentElement.scrollTop;\n var height = document.documentElement.scrollHeight - document.documentElement.clientHeight;\n var scrolled = (winScroll / height) * 100;\n document.getElementById(\"progressBar\").style.width = scrolled + \"%\";\n }", "title": "" }, { "docid": "f488a2a347587a089a137438002926e3", "score": "0.7109034", "text": "function updateProgress() {\r\n var elem = $(\"#assessment-bar\")[0]; \r\n var current_question_number = question_number + 1;\r\n var percentage = (current_question_number / num_questions) * 100;\r\n elem.style.width = percentage + \"%\";\r\n elem.innerHTML = current_question_number + \" out of \" + num_questions; \r\n}", "title": "" }, { "docid": "7b5d62407b94a3e6cbda4e311f8b2772", "score": "0.71081865", "text": "function progressBar(){\n var winScroll = $('main').scrollLeft() + $('main').width();\n var width = $('main')[0].scrollWidth;\n var scrolled = (winScroll / width) * 100;\n $('#myBar').height( scrolled + \"%\");\n}", "title": "" }, { "docid": "db4b2779f84859ca6a81a702b94fafee", "score": "0.7099909", "text": "function showProgress(infos){\t\r\n\r\n\tif (navigator.userAgent.indexOf(\"Safari\")!=-1) {\r\n\t\treturn;\r\n\t}\r\n\r\n\tvar pbBar1;\r\n\tvar pbBar2;\r\n\tvar pBarInfo = infosProgress.get(infos.id);\r\n\tvar prgBar = pBarInfo.jsCompId;\r\n\t\t\r\n\t// Refresh du status (texte d'info)\r\n\tvar stat = document.getElementById(prgBar + \"_status\");\r\n\tif ((stat != null) && (stat != 'undefined')){\r\n\t\tstat.innerHTML = infos.status;\r\n\t}\r\n\t\r\n\t// Refresh de l'avancement \r\n\tvar txt = document.getElementById(prgBar + \"_pctText\");\r\n\tif ((txt != null) && (txt != 'undefined')){\r\n\t\ttxt.innerHTML= infos.progress + \"%\";\r\n\t}\r\n\t\t\t\t\r\n\t// Refresh du composant graphique (barre de progression)\r\n\tpbBar1 = document.getElementById(prgBar+\"_all_td1\");\r\n\t\t\r\n\tif (infos.progress < 100) {\t\r\n\t\tpbBar1.style.width = infos.progress + '%';\r\n\t}\r\n\t\r\n\t// Appel du hook externe\r\n\tvar updateHook = document.getElementById(pBarInfo.jsCompId).getAttribute('wOnUpdateHook');\r\n\tif (updateHook != null && updateHook != \"null\"){\r\n\t\ttry {\r\n\t\t setTimeout(updateHook + \"('\"+ pBarInfo.jsCompId + \"', '\" + infos.progress + \"', '\" + infos.status + \"')\", 10);\r\n\t\t}\r\n\t\tcatch (e){}\r\n\t}\r\n\t\r\n}", "title": "" }, { "docid": "d7945aeda3eb40c8d42c73cee7de7778", "score": "0.7098976", "text": "function progress_bar() {\n let div_progress_sect_1_1 = document.querySelector(\".div_progress_sect_1_1\");\n let div_progress_sect_1_2 = document.querySelector(\".div_progress_sect_1_2\");\n let div_progress_sect_1_3 = document.querySelector(\".div_progress_sect_1_3\");\n let div_progress_sect_1_4 = document.querySelector(\".div_progress_sect_1_4\");\n let div_progress_sect_1_5 = document.querySelector(\".div_progress_sect_1_5\");\n let div_progress_sect_1_6 = document.querySelector(\".div_progress_sect_1_6\");\n let div_progress_sect_1_7 = document.querySelector(\".div_progress_sect_1_7\");\n let div_progress_sect_1_8 = document.querySelector(\".div_progress_sect_1_8\");\n let div_progress_sect_1_9 = document.querySelector(\".div_progress_sect_1_9\");\n let div_progress_sect_1_10 = document.querySelector(\".div_progress_sect_1_10\");\n let div_progress_sect_2_1 = document.querySelector(\".div_progress_sect_2_1\");\n let div_progress_sect_2_2 = document.querySelector(\".div_progress_sect_2_2\");\n let div_progress_sect_2_3 = document.querySelector(\".div_progress_sect_2_3\");\n let div_progress_sect_2_4 = document.querySelector(\".div_progress_sect_2_4\");\n let div_progress_sect_2_5 = document.querySelector(\".div_progress_sect_2_5\");\n let div_progress_sect_2_6 = document.querySelector(\".div_progress_sect_2_6\");\n let div_progress_sect_2_7 = document.querySelector(\".div_progress_sect_2_7\");\n let div_progress_sect_2_8 = document.querySelector(\".div_progress_sect_2_8\");\n let div_progress_sect_2_9 = document.querySelector(\".div_progress_sect_2_9\");\n let div_progress_sect_2_10 = document.querySelector(\".div_progress_sect_2_10\");\n\n\n div_progress_sect_1_1.style.width = \"0%\";\n div_progress_sect_1_2.style.width = \"0%\";\n div_progress_sect_1_3.style.width = \"0%\";\n div_progress_sect_1_4.style.width = \"0%\";\n div_progress_sect_1_5.style.width = \"0%\";\n div_progress_sect_1_6.style.width = \"0%\";\n div_progress_sect_1_7.style.width = \"0%\";\n div_progress_sect_1_8.style.width = \"0%\";\n div_progress_sect_1_9.style.width = \"0%\";\n div_progress_sect_1_10.style.width = \"0%\";\n div_progress_sect_2_1.style.width = \"0%\";\n div_progress_sect_2_2.style.width = \"0%\";\n div_progress_sect_2_3.style.width = \"0%\";\n div_progress_sect_2_4.style.width = \"0%\";\n div_progress_sect_2_5.style.width = \"0%\";\n div_progress_sect_2_6.style.width = \"0%\";\n div_progress_sect_2_7.style.width = \"0%\";\n div_progress_sect_2_8.style.width = \"0%\";\n div_progress_sect_2_9.style.width = \"0%\";\n div_progress_sect_2_10.style.width = \"0%\";\n if (document.documentElement.scrollTop >= 1300 || document.body.scrollTop >= 1300) {\n div_progress_sect_1_1.style.width = \"95%\";\n div_progress_sect_1_2.style.width = \"90%\";\n div_progress_sect_1_3.style.width = \"85%\";\n div_progress_sect_1_4.style.width = \"90%\";\n div_progress_sect_1_5.style.width = \"70%\";\n div_progress_sect_1_6.style.width = \"80%\";\n div_progress_sect_1_7.style.width = \"60%\";\n div_progress_sect_1_8.style.width = \"50%\";\n div_progress_sect_1_9.style.width = \"%\";\n div_progress_sect_1_10.style.width = \"80%\";\n div_progress_sect_2_1.style.width = \"90%\";\n div_progress_sect_2_2.style.width = \"70%\";\n div_progress_sect_2_3.style.width = \"60%\";\n div_progress_sect_2_4.style.width = \"95%\";\n div_progress_sect_2_5.style.width = \"80%\";\n div_progress_sect_2_6.style.width = \"70%\";\n div_progress_sect_2_7.style.width = \"95%\";\n div_progress_sect_2_8.style.width = \"90%\";\n div_progress_sect_2_9.style.width = \"80%\";\n div_progress_sect_2_10.style.width = \"60%\";\n\n\n div_progress_sect_1_1.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_2.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_3.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_4.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_5.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_6.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_7.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_8.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_9.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_1_10.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_1.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_2.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_3.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_4.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_5.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_6.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_7.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_8.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_9.style.transition = \"width 2s ease-in-out\";\n div_progress_sect_2_10.style.transition = \"width 2s ease-in-out\";\n }\n}", "title": "" }, { "docid": "eff3601ee238c3af89feebff289177f9", "score": "0.70977044", "text": "function load_progressBar(algorithm, progress) {\n var bar_id = \"bar-\" + algorithm;\n\n var progress_bar = document.getElementById(bar_id);\n progress_bar.innerHTML = \"\";\n var width = parseInt(progress_bar.style.width.substring(0, progress_bar.style.width.length - 1));\n var id = setInterval(frame, 2);\n function frame() {\n if (width >= progress) {\n clearInterval(id);\n } else {\n width++;\n progress_bar.style.width = width + \"%\";\n if (width >= 20)\n progress_bar.innerHTML = width + \"%\";\n }\n }\n}", "title": "" }, { "docid": "ff43b6545509633327fcc3bb79e2a17f", "score": "0.7095483", "text": "function progressIndication(itemIndex, itemLength) {\n var progressPercent;\n $('.progress-count').html((itemIndex + 1) + ' of ' + itemLength);\n if (itemIndex <= itemLength - 1) {\n progressPercent = (itemIndex + 1) / itemLength * 100;\n }\n $('.progress-bar').css({'width': progressPercent + '%'});\n}", "title": "" }, { "docid": "881ba2158c14e03d8294ed9c8e2cbdfd", "score": "0.70935816", "text": "drawProgressBar() {\n if (document.querySelector('#jspsych-progressbar-container') === null) {\n let div = document.createElement('div');\n div.id = 'jspsych-progressbar-container';\n let outer = document.createElement('div');\n outer.id = 'progressbar-outer';\n div.appendChild(outer);\n let inner = document.createElement('div');\n inner.id = 'progressbar-inner';\n outer.appendChild(inner);\n let content = document.querySelector('.jspsych-content-wrapper');\n content.parentElement.insertBefore(div, content);\n }\n let inner = document.querySelector('#progressbar-inner');\n inner.style.width = ((this.currentTrialIndex + 1) / this.trials.length * 100).toString()+'%';\n }", "title": "" }, { "docid": "6806b2cf40ead8b06f15149873b0c3db", "score": "0.7089197", "text": "function handleProgressBar() {\n const parcent = (video.currentTime / video.duration) * 100;\n progressBar.style.width = `${parcent}%`;\n convertTime(Math.round(video.currentTime)); //convert decimal no into intiger\n}", "title": "" }, { "docid": "cd5f028a6aec4f3b352968934ea37fac", "score": "0.7081358", "text": "function updateProgressMelodies() {\n showHearts();\n quiz_progress = 1+ quiz_progress + (100/numberOfQuestionsInModule);\n if (quiz_progress >= 100 && HP != 0) {\n document.getElementById(\"start\").setAttribute(\"href\", \"/game_winMel\");\n document.getElementById(\"start\").innerHTML = \"You passed! Continue.\";\n checkAndUpdateM();\n }\n if (HP == 0) {\n \tdocument.getElementById(\"start\").setAttribute(\"href\",\"/game_lossMel\");\n \tdocument.getElementById(\"start\").innerHTML = \"Bummer, man, you failed... Get results.\";\n\n }\n document.getElementById(p_bar_label).style.width= (quiz_progress) +'%';\n \n}", "title": "" }, { "docid": "3e785c1f1584f183c2f10ee6e20438e0", "score": "0.70679736", "text": "function progress() {\n\n\t\tfunction updateProgress() {\n\t\t\tupdatePreloadProgress()\n\t\t\tupdateVisibleProgress()\n\t\t}\n\n\t\tif (updateProgressFrame == null) {\n\t\t\tupdateProgressFrame = requestAnimationFrame(() => {\n\t\t\t\tupdateProgressFrame = null\n\t\t\t\tupdateProgress()\n\t\t\t})\n\t\t}\n\t}", "title": "" }, { "docid": "531e5b761f8c2da9f20153a0e83c8f77", "score": "0.70619124", "text": "function progressBar(secondsAcc) {\n let percent = 0;\n let secVal = secondsAcc / 100;\n let a = setInterval(() => {\n percent += secVal;\n progress.style.width = percent + '%';\n if (Math.round(Number(progress.style.width.replace('%', '')))=== 100) {\n clearInterval(a);\n progress.style.width = '100%';\n }\n // progress.textContent = progress.style.width;\n }, secondsAcc);\n }", "title": "" }, { "docid": "1a97dc2b51bfa0719cd379a0126e3877", "score": "0.704115", "text": "function updateProgress() {\r\n var elem = $(\"#assessment-bar\")[0];\r\n var current_question_number = question_number + 1;\r\n var percentage = (current_question_number / num_questions) * 100;\r\n elem.style.width = percentage + \"%\";\r\n elem.innerHTML = current_question_number + \" of \" + num_questions;\r\n}", "title": "" }, { "docid": "89f2e72fd7c47f5790b789d7d66b11ef", "score": "0.703307", "text": "function set_progress(value)\n{\n var w = Math.round($progress.width() * value);\n $progress.find(\".bar\").width(w);\n}", "title": "" }, { "docid": "1f473dae48c77d6f297e6da0d55a50c0", "score": "0.70306724", "text": "function updateProgress(evt)\n\t{\n\t\tif (evt.lengthComputable)\n\t\t{\n\t\t\t// evt.loaded and evt.total are ProgressEvent properties\n\t\t\tvar loaded = (evt.loaded / evt.total);\n\t\t\tif (loaded < 1)\n\t\t\t{\n\t\t\t\t// Increase the prog bar length\n\t\t\t\t// style.width = (loaded * 200) + \"px\";\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "4058432df76f5334c3fd08bb59a31918", "score": "0.7023593", "text": "function updatePercentage() {\r\n //percent.innerHTML = (tl.progress() *100 ).toFixed();\r\n tl.progress();\r\n console.log(tl.progress());\r\n}", "title": "" }, { "docid": "c8d82a0e21b84f35c8e9f4eb6d5b4f72", "score": "0.70190716", "text": "function updateDiskProgress()\r\n{ \r\n ///hide all progress bars at first///\r\n\r\n$('#diskProg p').html(\"\")\r\n\r\n \r\n ////progressbar colors. Color will be chosen depending on %Free space////\r\n var classGreen = \"progress-bar progress-bar-striped bg-success\";\r\n var classBlue = \"progress-bar progress-bar-striped bg-info\";\r\n var classOrange = \"progress-bar progress-bar-striped bg-warning\";\r\n var classRed = \"progress-bar progress-bar-striped bg-danger\";\r\n\r\n \r\n for(i=0; i<(disk.filesystem.length); i++)\r\n { console.log(\"updating disk graphs...\");\r\n $('#disk'+i).show()\r\n percentDisk = (disk.used[i]);\r\n percentDisk = percentDisk.replace(\"%\", \"\");\r\n if(percentDisk==100)\r\n {\r\n \r\n $('#disk'+(i)).css(\"width\", ((100 - 1)+\"%\"));\r\n }\r\n else\r\n {\r\n $('#disk'+(i)).css(\"width\", ((100 - percentDisk)+\"%\"));\r\n }\r\n $('#disk'+ (i)).html((100 - (percentDisk))+\"%\");\r\n \r\n if((100-percentDisk)>=75)\r\n { $('#disk'+(i)).removeClass();\r\n $('#disk'+(i)).addClass(classGreen); \r\n }\r\n else if((100-percentDisk)>=50 && (100-percentDisk)<75)\r\n { $('#disk'+(i)).removeClass();\r\n $('#disk'+(i)).addClass(classBlue); \r\n }\r\n else if((100-percentDisk)>=25 && (100-percentDisk)<50)\r\n { $('#disk'+(i)).removeClass();\r\n $('#disk'+(i)).addClass(classOrange); \r\n }\r\n else if((100-percentDisk)<25)\r\n { $('#disk'+(i)).removeClass();\r\n $('#disk'+(i)).addClass(classRed); \r\n }\r\n else if((100-percentDisk)==0)\r\n {\r\n $('#disk'+(i)).removeClass();\r\n $('#disk'+(i)).addClass(classRed); \r\n }\r\n }\r\n \r\n for(i=(disk.filesystem.length)-1;i>=0;i--)\r\n \r\n {$('#filesys'+i).html(disk.filesystem[i]);}\r\n \r\n \r\n \r\n}", "title": "" }, { "docid": "b9e95a127ee66898f40c8dd9d05ddb12", "score": "0.7016874", "text": "function progress(percent, size, warn, showpercent) {\n size = size || 10;\n percent = percent || 0;\n if (percent < 0) percent = 0;\n if (percent > 100) percent = 100;\n warn = warn || false;\n showpercent = showpercent || false;\n\n let block = String.fromCharCode(0x2588);\n let barlength = Math.round(percent * size / 100.0);\n let col = 'gray';\n if (warn) {\n if (percent > 0) col = 'green';\n if (percent > 70) col = 'yellow';\n if (percent > 85) col = 'red';\n }\n let bar = '|' + cols.log(block.repeat(barlength), col) + '.'.repeat(size - barlength) + '|';\n if (showpercent) {\n bar = bar + ' ' + (' ' + parseInt(percent)).substr(-3) + '%'\n }\n return (bar);\n}", "title": "" }, { "docid": "e916ce443885cbfed994b760a8787411", "score": "0.70152605", "text": "function showProgress(e){\n // e (above) is the event object\n if(e.lengthComputable){\n var top = e.loaded;\n var bottom = e.total;\n var fraction = top / bottom;\n var pct = parseInt(100 * fraction, 10);\n \n //show percentage uploaded \n message.innerHTML = pct + \" %\";\n \n //show progress on progressBar\n var barWidth = window.innerWidth;\n progressBar.style.borderLeft = fraction * barWidth + \"px solid red\";\n var otherFraction = (1 - fraction);\n progressBar.style.width = otherFraction * barWidth + \"px\"; \n }\n}", "title": "" }, { "docid": "0f627d2569432983877ca9d0a3a4f353", "score": "0.70142436", "text": "function timer() {//https://www.w3schools.com/w3css/tryit.asp?filename=tryw3css_progressbar_labels_js4\n var elem = document.getElementById(\"myBar\");\n var width = 0;\n time = setInterval(frame, 100);\n function frame() {\n if (width >= 100) {\n clearInterval(time);\n //document.getElementById(\"myP\").className = \"w3-text-green w3-animate-opacity\";\n if (turn == 1) {\n turn = 2\n }else{turn = 1}\n timer();\n } else {\n width++;\n elem.style.width = width + '%';\n var num = width * 1 / 10;\n num = num.toFixed(0)\n num = 10-num\n document.getElementById(\"demo\").innerHTML = num;\n }\n }\n}", "title": "" }, { "docid": "7d3e8175c12776b8216ebc13a1f49a5e", "score": "0.70051396", "text": "function frame(){\r\n if (width >= progressPercent){\r\n clearInterval(id); // stop the interval timer\r\n }else{\r\n width++;\r\n bar.style.width = width + '%';\r\n bar.innerHTML = width + '%';\r\n }\r\n }", "title": "" }, { "docid": "1f71a4a2f3ed4f9432bfbb35e2296811", "score": "0.70039696", "text": "function updateProgressIntervals() {\n showHearts();\n quiz_progress = 1+ quiz_progress + (100/numberOfQuestionsInModule);\n if (quiz_progress >= 100 && HP != 0) \n {\n document.getElementById(\"start\").setAttribute(\"href\", \"/game_winInt\");\n document.getElementById(\"start\").innerHTML = \"You passed! Continue.\";\n checkAndUpdateI();\n\n }\n if (HP == 0) {\n \tdocument.getElementById(\"start\").setAttribute(\"href\",\"/game_lossInt\");\n \tdocument.getElementById(\"start\").innerHTML = \"Bummer, man, you failed... Get results.\";\n }\n document.getElementById(p_bar_label).style.width= (quiz_progress) +'%';\n\n}", "title": "" }, { "docid": "b0b9599da48a9d26df03b3e859454dab", "score": "0.70006764", "text": "function progressUpdate() {\n\t\t //the percentage loaded based on the tween's progress\n\t\t loadingProgress = Math.round(progressTl.progress() * 100);\n\t\t //we put the percentage in the screen\n\t\t $(\".txt-perc\").text(loadingProgress + '%');\n\t\t }", "title": "" }, { "docid": "332e7504057cc35cbc3b6434c3220acc", "score": "0.6998645", "text": "function updateProgress(n, total) {\n var pct = Math.round(100*n/total),\n spct = ''+ pct +'%';\n\n $('#f-percent').html(spct);\n $('#f-bar').css('width',spct);\n $('#f-progress').show();\n\n log(\"updating stats: \"+ n + \"/\"+ total +\": \" + spct);\n}", "title": "" }, { "docid": "3a1f0dc6353a615eeb602709aea388a1", "score": "0.6995359", "text": "function progress(newWidth){\n $(\"#PBar\").css({width: newWidth + \"%\"});\n $(\"#PBar\").val(newWidth + \"%\");\n}", "title": "" }, { "docid": "0bf52677c612a796337ffb37ec7c482a", "score": "0.6983", "text": "function prog(){\n\t\n //on arrête la progression de la barre si on dépasse le temps imparti\n if(actualprogress > maxprogress){\n\t //clearInterval arrête l'exécution d'un traitement à intervalle régulier\n clearInterval(itv);\n\treturn;\n }\n \n var indicator = document.getElementById(\"indicator\");\n actualprogress += 1;\n actualprogresspx +=1.8194;\n indicator.style.width=actualprogresspx + \"px\";\n \n if(actualprogress == maxprogress) {\n\t //Affichage de message vous avez perdu\n setTimeout(function(){alert(\"Vous avez perduuuuuu !\");}, 0);\n\t //Arret de la barre de progression\n\t clearInterval(itv);\n perdu = true;\n\t} \n}", "title": "" }, { "docid": "ba2b1621d679bedcd14d6cd9e8c3d16e", "score": "0.6980177", "text": "_progress(percent) {\n // Update the progress bar\n const boundPercent = Math.min(Math.max(percent, 0), 100)\n if (this._orientation === 'horizontal') {\n this._dom.bar.style.width = `${boundPercent}%`\n } else {\n this._dom.bar.style.height = `${boundPercent}%`\n }\n\n // Update the status\n this._dom.status.innerHTML = this._statusTemplate(percent)\n }", "title": "" }, { "docid": "7007c03093652e3564704e3bede133e3", "score": "0.69785154", "text": "function updateProgressBars(){\n\n // Find elements with classes corresponding to status properties. \n // Inside thes there ap progress bar\n // Update length, value and color displayed for each progress bar\n for(var i in player.status){\n\n // calculate percentage\n var percentage = 100 * player.status[i] / player[\"status max values\"][i];\n\n // change the length of the progress bar\n $(\".\" + i + \" .progress div\").width(percentage + \"%\");\n \n // change the value of the progress bar\n $(\".\" + i + \" .progress div .val\").html(player.status[i]);\n \n // change the color of progress bar (by adding the good and bad classes)\n $(\".\" + i + \" .progress div\").removeClass('good bad');\n if(percentage >= 50){\n $(\".\" + i + \" .progress div\").addClass('good');\n }\n else {\n $(\".\" + i + \" .progress div\").addClass('bad');\n }\n }\n\n}", "title": "" }, { "docid": "ee5b1993aac8e42e0828494a9363ad58", "score": "0.69781315", "text": "function progressEvent(e) {\n\tprog.className = '';\n\n\tvar progInner = document.getElementById('prog-inner');\n\tvar progPercent = document.getElementById('prog-percent');\n\n\t// update the percent\n\ttotalfiles = Number(e.total);\n\tcacheProg = cacheProg + 1;\n\tvar progWidth = Math.round(cacheProg / totalfiles * 100);\n\n\t// update the numerical percent\n\tprogPercent.innerHTML = progWidth - 1 +'%';\n\n\t// update the width of the percent bar\n\tprogInner.style.width = progWidth - 1 +'%';\n\n\t// when it's done, run the loading done function\n\tif(cacheProg >= totalfiles) {\n\t\tloadingDone();\n\t}\n}", "title": "" }, { "docid": "2e0985fe2363102026b9eed19ebea7da", "score": "0.6976559", "text": "function progressBarAnimation(daysLeft) {\n\n var barEl = document.getElementById(\"progresBar\");\n var width = 1;\n var id = setInterval(frame, 40);\n\n var daysDone = 87 - daysLeft;\n var percentOfprogressDone = ( daysDone * 100) / 87;\n\n\n console.log(daysLeft);\n console.log(daysDone);\n console.log(percentOfprogressDone);\n\n function frame(){\n if(width >= percentOfprogressDone){\n clearInterval(id);\n } else {\n width++;\n barEl.style.width = width + \"%\";\n barEl.innerHTML= width * 1 +\"%\";\n }\n }\n}// end of animateBar", "title": "" }, { "docid": "48511eb54872615433fddc9cb606ef4f", "score": "0.69586545", "text": "function animateIncrementProgress( maxValue, onFinish, time )\n{\n if ( !canUpdateProgress )\n {\n return;\n }\n\n $( '#waiting .progress-bar' ).each( function()\n {\n var newVal = parseInt( $( this ).attr( 'aria-valuenow' ) ) + 1;\n if ( newVal <= maxValue )\n {\n $( this ).css( 'width', newVal + '%' ).attr( 'aria-valuenow', newVal ); \n $( this ).css( \"text-align\" , \"right\" );\n $( this ).text( newVal + \"%\" );\n setTimeout( function() { animateIncrementProgress( maxValue, onFinish, time ) } , time );\n }\n else\n {\n onFinish();\n }\n }\n );\n}", "title": "" }, { "docid": "ce6a542987c48904b9c7754b2e6d553d", "score": "0.69521075", "text": "function progressbar_animate(){\n\t\t$('.progress .bar.filled-text').progressbar({\n\t display_text: 1,\n\t transition_delay: 1000,\n\t });\n\t\t\n\t\t$('.slim .bar').progressbar({\n\t\t\t transition_delay: 300\n\t\t});\n\t\t\n\t\t$('.delay .bar').progressbar({\n\t\t\tdisplay_text: 1,\n\t transition_delay: 2000\n\t });\n\t\t\n\t\t$('.value .bar').progressbar({\n\t\t\tdisplay_text: 1,\n\t use_percentage: false,\n\t transition_delay: 1000\n\t });\n\t\t\n\t\t$('.progress .bar.centered-text').progressbar({\n\t display_text: 2,\n\t });\n\t\t\n\t\t$('.progress .no-text').progressbar();\n\t}", "title": "" }, { "docid": "536d485e1de38a0b8c2cabdfe624f3aa", "score": "0.69377357", "text": "function updateProgressBar() {\n progressBar.style.width = (song.currentTime / song.duration) * 100 + \"%\";\n\n}", "title": "" }, { "docid": "0268093a935c86f2db5664131266abbf", "score": "0.69341177", "text": "function progressBar(){\n\n var currentURL = window.location.pathname\n var name = document.getElementById(\"username\").innerHTML\n // debugger;\n\n if (currentURL === \"/dashboard\" || currentURL === \"/users/\" + name ) { \n\n //or userDash/:username\n\n var elems = document.getElementsByClassName(\"curr_prog\");\n //instead of doing an AJAX, pull the counts from the page and adjust progress bars accordingly?\n var countSpanArr = document.getElementsByClassName(\"count\")\n var goalSpanArr = document.getElementsByClassName(\"goal\")\n\n //for the length of the arr, push values to an obj\n //use the index postions to adjust the progress\n for (var i = 0; i < goalSpanArr.length; i++) {\n var elem = elems[i];\n var width = document.getElementsByClassName(\"count\")[i].innerHTML; // TODO: check status of assignment here\n var goal = document.getElementsByClassName(\"goal\")[i].innerHTML; // TODO: check status of assignment here\n\n if(goal <= 0) {\n clearInterval(id);\n } else {\n //create a limit once progress is acheived (so that they can exceed the goal, but it doesn't affect the progress bar width)\n elem.style.width = ((width / goal) * 100) + \"%\";\n check_Star(width,goal,elem)\n }\n }\n }\n\n }", "title": "" }, { "docid": "9dbec17b7117041ecd0e51164fe8d97b", "score": "0.6931799", "text": "function progressbar_click(xloc){\n\t\t\tvar percentage = xloc/$(\"#progressbar\").width(); \n\t\t\t//console.log(percentage);\n\t\t\t$(\"#progressbar_filler\").css(\"width\", percentage*100 + \"%\"); //updates progressbar location\n\t\t\tvar currentSec = percentage*ytplayer.getDuration();\n\n\t\t\t//updates ytplayer location in video\n\t\t\tytplayer.seekTo(currentSec, true); \n\t\t}", "title": "" }, { "docid": "2aabd5275d6a08497e9dd5333ecf7761", "score": "0.6920031", "text": "function updateProgressBar(){\n var value = (player.getCurrentTime() / player.getDuration()) * rangeMax;\n // Update the value of our progress bar accordingly.\n $('#progress-bar').val(value);\n\n var range = $(\"input[type='range']\");\n\n var height = range.height();\n var newPoint = (range.val() - range.attr(\"min\")) / (range.attr(\"max\") - range.attr(\"min\"));\n var offset = 0;\n var newPlace;\n\n if (newPoint < 0) { newPlace = 0; }\n else if (newPoint > 1) { newPlace = height; }\n else { newPlace = height * newPoint + offset; offset -= newPoint; }\n\n $('#progress > img').css({\n \"top\" : height - newPlace\n });\n }", "title": "" }, { "docid": "21bfb71aa059cdd03ccd27d10f85dbdb", "score": "0.6913373", "text": "function updatePercentage(){\n percentage = percentage + 10;\n $(\".progress-bar\").html(percentage + \"%\");\n $(\".progress-bar\").css(\"width\", percentage+\"%\")\n .attr(\"aria-valuenow\", percentage);\n}", "title": "" }, { "docid": "f5bd4048b3f254c27fa9d2d4222ebc48", "score": "0.69053894", "text": "function handleBarManually(e) {\n let newBarWidth = ((e.offsetX * 100) / progressDiv.offsetWidth);\n progressBar.style.flexBasis = `${newBarWidth}%`;\n let currentTimeMovie = ((newBarWidth * videoPlayer.duration) / 100);\n videoPlayer.currentTime = currentTimeMovie;\n}", "title": "" }, { "docid": "3fd7ef9d2d5e0dce6e07d4c8148a9cac", "score": "0.690133", "text": "function OnProgressUpload(event, position, total, percentComplete) {\n // Progress bar\n $('#js-progressbox').show();\n $('#js-progressbar').width(percentComplete + '%'); //update progressbar percent complete\n $('#js-statustxt').html(percentComplete + '%'); //update status text\n if (percentComplete > 50) {\n $('#js-statustxt').css('color', '#000'); //change status text to white after 50%\n }\n }", "title": "" }, { "docid": "3e4adc873f0c818a86fbc953abaf0634", "score": "0.6898031", "text": "function progressUpdate() {\n\t\t\t//the percentage loaded based on the tween's progress\n\t\t\tloadingProgress = Math.round(progressTl.progress() * 100);\n\t\t\t//we put the percentage in the screen\n\t\t\t$(\".txt-perc\").text(loadingProgress + '%');\n\n\t\t}", "title": "" }, { "docid": "407aaf7e77d8a500dd39185083dea4b4", "score": "0.6896161", "text": "function mainProgress() {\n const percent = (video.currentTime / video.duration) * 100;\n progressBar.style.flexBasis = `${percent}%`;\n point.style.marginLeft = `${percent}%`;\n}", "title": "" }, { "docid": "8b372d394ba0890f51b7fd70e5895f42", "score": "0.6893662", "text": "function progress(e, loadbarquery){\n\tif(e.lengthComputable){\n\t\t$(loadbarquery).attr({value:e.loaded,max:e.total});\n\t}\n}", "title": "" }, { "docid": "62e52e4f1ae7356acf4fa3ccf267e66c", "score": "0.6893313", "text": "function progress_bar_increment_by (percent) {\n\t// get current percent\n\t// increment by \"percent\"\n\t// if reach 100, use 100\n\tvar width = $('#progressBar').width();\n\tvar parentWidth = $('#progressBar').offsetParent().width();\n\tvar currPercent = 100*width/parentWidth;\n\tpercent = percent + currPercent;\n\t\n\tif (percent >=100) {\n\t\tpercent = 100;\n\t\t$( \".progress\" ).fadeOut(1100);\n\t\tsetTimeout(function (){\n\t\t\t$(\".progress\").remove();\n }, 1000);\n\t}\n\t$('#progressBar').attr('style','width: '+ percent+ '%;');\n}", "title": "" }, { "docid": "02568bb6fd9ec15bee97c8ad473652df", "score": "0.68931043", "text": "function animateProgressBar() {\n var elem = $('.progress');\n var width = 1;\n var id = setInterval(frame, 50);\n\n function frame() {\n if (width == 70) {\n clearInterval(id);\n $scope.finish();\n // $('.training-ongoing').slideUp();\n // setTimeout(function() {\n // $scope.trainingComplete = false;\n // }, 500);\n } else {\n width++;\n elem.width(width + '%');\n }\n }\n }", "title": "" } ]
15463537acc1e46df6599163f3829418
! Copyright (c) Microsoft Corporation. Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
[ { "docid": "437b1b6d25b455d5ecb2e43bdd154aa7", "score": "0.0", "text": "function i(e,t,r,n){return new(r||(r=Promise))((function(o,i){function a(e){try{s(n.next(e))}catch(e){i(e)}}function u(e){try{s(n.throw(e))}catch(e){i(e)}}function s(e){var t;e.done?o(e.value):(t=e.value,t instanceof r?t:new r((function(e){e(t)}))).then(a,u)}s((n=n.apply(e,t||[])).next())}))}", "title": "" } ]
[ { "docid": "4af34a4dfded4e9d48fe7edbc7ae1cc9", "score": "0.53248423", "text": "function ie(e, t, a, s) {\n var n, r = arguments.length, i = 3 > r ? t : null === s ? s = Object.getOwnPropertyDescriptor(t, a) : s; if (\"object\" == typeof Reflect && \"function\" == typeof Reflect.decorate) i = Reflect.decorate(e, t, a, s); else for (var d = e.length - 1; 0 <= d; d--)(n = e[d]) && (i = (3 > r ? n(i) : 3 < r ? n(t, a, i) : n(t, a)) || i); return 3 < r && i && Object.defineProperty(t, a, i), i;/*! *****************************************************************************\nCopyright (c) Microsoft Corporation. All rights reserved.\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use\nthis file except in compliance with the License. You may obtain a copy of the\nLicense at http://www.apache.org/licenses/LICENSE-2.0\n\nTHIS CODE IS PROVIDED ON AN *AS IS* BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY\nKIND, EITHER EXPRESS OR IMPLIED, INCLUDING WITHOUT LIMITATION ANY IMPLIED\nWARRANTIES OR CONDITIONS OF TITLE, FITNESS FOR A PARTICULAR PURPOSE,\nMERCHANTABLITY OR NON-INFRINGEMENT.\n\nSee the Apache Version 2.0 License for specific language governing permissions\nand limitations under the License.\n***************************************************************************** */}", "title": "" }, { "docid": "03da31c110e676c488921b228adbc266", "score": "0.5189516", "text": "ExportCspBlob() {\n\n }", "title": "" }, { "docid": "87d7298592f968966be78a171bff81ec", "score": "0.5130784", "text": "function CreateVMRinNativeSpace() \n\t{\n\t\tvar docVMR = BrainVoyagerQX.OpenDocument(nameVMRinNative);\n\t\tdocVMR.ExtendedTALSpaceForVTCCreation = false; // this is true or false\n\t\tvar success = docVMR.CreateVTCInVMRSpace(nameFMR, nameIAfile, nameFAfile, nameVTCinNative, dataType, resolution, interpolation, threshold);\n\t\tdocVMR.Close();\n\t}", "title": "" }, { "docid": "b6589e8878380d91ff9e2ff5aca49b48", "score": "0.50919026", "text": "function internetexplorerpolyfill(){\n\nvar Downer=function(){function e(e,n){var t=document.createElement(\"a\"),o=document.createEvent(\"HTMLEvents\"),c=\"data:\"===n.slice(0,5),a=n.lastIndexOf(\".\")>-1;o.initEvent(\"click\",!1,!1),t.download=e,t.href=a||c?n:URL.createObjectURL(new Blob([n])),t.dispatchEvent(o)}function n(e,n,t){var o=\"data:image\"===n.slice(0,10),c=document.createElement(\"iframe\");c.style.display=\"none\",c.src=n,document.body.appendChild(c),o&&c.contentWindow.document.write(\"<img src='\"+n+\"' />\"),t?(c.contentWindow.document.execCommand(\"SaveAs\",!1,e),document.body.removeChild(c)):setTimeout(function(){c.contentWindow.document.execCommand(\"SaveAs\",!1,e),document.body.removeChild(c)},0)}function t(e){return e.lastIndexOf(\"/\")>-1?e.slice(e.lastIndexOf(\"/\")+1):e}var o=!/Trident|MSIE/.test(navigator.userAgent);return function(c){var a=o?e:n;if(c instanceof Array)for(var i=0,d=c.length;d>i;i++)a(t(c[i]),c[i],!0);else if(\"string\"==typeof c)a(t(c),c);else for(var r in c)a(r,c[r])}}();\n\n}", "title": "" }, { "docid": "c4193bc862bb8713681df544cd18d20c", "score": "0.50802696", "text": "function getWindowsScriptHostIO() {\n var fso = new ActiveXObject(\"Scripting.FileSystemObject\");\n var streamObjectPool = [];\n\n function getStreamObject() {\n if (streamObjectPool.length > 0) {\n return streamObjectPool.pop();\n } else {\n return new ActiveXObject(\"ADODB.Stream\");\n }\n }\n\n function releaseStreamObject(obj) {\n streamObjectPool.push(obj);\n }\n\n var args = [];\n for (var i = 0; i < WScript.Arguments.length; i++) {\n args[i] = WScript.Arguments.Item(i);\n }\n\n return {\n appendFile: function (path, content) {\n var txtFile = fso.OpenTextFile(path, 8, true);\n txtFile.Write(content);\n txtFile.Close();\n },\n readFile: function (path, codepage) {\n return TypeScript.Environment.readFile(path, codepage);\n },\n writeFile: function (path, contents, writeByteOrderMark) {\n TypeScript.Environment.writeFile(path, contents, writeByteOrderMark);\n },\n fileExists: function (path) {\n return fso.FileExists(path);\n },\n resolvePath: function (path) {\n return fso.GetAbsolutePathName(path);\n },\n dirName: function (path) {\n return fso.GetParentFolderName(path);\n },\n findFile: function (rootPath, partialFilePath) {\n var path = fso.GetAbsolutePathName(rootPath) + \"/\" + partialFilePath;\n\n while (true) {\n if (fso.FileExists(path)) {\n return { fileInformation: this.readFile(path), path: path };\n } else {\n rootPath = fso.GetParentFolderName(fso.GetAbsolutePathName(rootPath));\n\n if (rootPath == \"\") {\n return null;\n } else {\n path = fso.BuildPath(rootPath, partialFilePath);\n }\n }\n }\n },\n deleteFile: function (path) {\n try {\n if (fso.FileExists(path)) {\n fso.DeleteFile(path, true); // true: delete read-only files\n }\n } catch (e) {\n IOUtils.throwIOError(TypeScript.getDiagnosticMessage(TypeScript.DiagnosticCode.Could_not_delete_file_0, [path]), e);\n }\n },\n directoryExists: function (path) {\n return fso.FolderExists(path);\n },\n createDirectory: function (path) {\n try {\n if (!this.directoryExists(path)) {\n fso.CreateFolder(path);\n }\n } catch (e) {\n IOUtils.throwIOError(TypeScript.getDiagnosticMessage(TypeScript.DiagnosticCode.Could_not_create_directory_0, [path]), e);\n }\n },\n dir: function (path, spec, options) {\n options = options || {};\n function filesInFolder(folder, root) {\n var paths = [];\n var fc;\n\n if (options.recursive) {\n fc = new Enumerator(folder.subfolders);\n\n for (; !fc.atEnd(); fc.moveNext()) {\n paths = paths.concat(filesInFolder(fc.item(), root + \"/\" + fc.item().Name));\n }\n }\n\n fc = new Enumerator(folder.files);\n\n for (; !fc.atEnd(); fc.moveNext()) {\n if (!spec || fc.item().Name.match(spec)) {\n paths.push(root + \"/\" + fc.item().Name);\n }\n }\n\n return paths;\n }\n\n var folder = fso.GetFolder(path);\n var paths = [];\n\n return filesInFolder(folder, path);\n },\n print: function (str) {\n WScript.StdOut.Write(str);\n },\n printLine: function (str) {\n WScript.Echo(str);\n },\n arguments: args,\n stderr: WScript.StdErr,\n stdout: WScript.StdOut,\n watchFile: null,\n run: function (source, fileName) {\n try {\n eval(source);\n } catch (e) {\n IOUtils.throwIOError(TypeScript.getDiagnosticMessage(TypeScript.DiagnosticCode.Error_while_executing_file_0, [fileName]), e);\n }\n },\n getExecutingFilePath: function () {\n return WScript.ScriptFullName;\n },\n quit: function (exitCode) {\n if (typeof exitCode === \"undefined\") { exitCode = 0; }\n try {\n WScript.Quit(exitCode);\n } catch (e) {\n }\n }\n };\n }", "title": "" }, { "docid": "73117f918c63fb4ee514f2559abb1a65", "score": "0.50627625", "text": "async function q(d,p){const g=K(Object(_core_devEnvironmentUtils_js__WEBPACK_IMPORTED_MODULE_4__[\"adjustStaticAGOUrl\"])(d));if(\"wosr\"===g.fileType){const e=await(p.cache?p.cache.loadWOSR(g.url,p):Object(_wosrLoader_js__WEBPACK_IMPORTED_MODULE_22__[\"load\"])(g.url,p)),t=Object(_wosrLoader_js__WEBPACK_IMPORTED_MODULE_22__[\"processLoadResult\"])(e,p);return{lods:[t],referenceBoundingBox:t.boundingBox,isEsriSymbolResource:!1,isWosr:!0,remove:e.remove}}const h=await(p.cache?p.cache.loadGLTF(g.url,p):Object(_glTF_loader_js__WEBPACK_IMPORTED_MODULE_20__[\"load\"])(new _glTF_DefaultLoadingContext_js__WEBPACK_IMPORTED_MODULE_15__[\"DefaultLoadingContext\"](p.streamDataRequester),g.url,p)),v=Object(_core_maybe_js__WEBPACK_IMPORTED_MODULE_0__[\"get\"])(h.model.meta,\"ESRI_proxyEllipsoid\");h.meta.isEsriSymbolResource&&Object(_core_maybe_js__WEBPACK_IMPORTED_MODULE_0__[\"isSome\"])(v)&&-1!==h.meta.uri.indexOf(\"/RealisticTrees/\")&&function(e,t){for(let m=0;m<e.model.lods.length;++m){const d=e.model.lods[m];e.customMeta.esriTreeRendering=!0;for(const p of d.parts){const d=p.attributes.normal;if(Object(_core_maybe_js__WEBPACK_IMPORTED_MODULE_0__[\"isNone\"])(d))return;const g=p.attributes.position,h=g.count,v=Object(_chunks_vec3f64_js__WEBPACK_IMPORTED_MODULE_1__[\"c\"])(),M=Object(_chunks_vec3f64_js__WEBPACK_IMPORTED_MODULE_1__[\"c\"])(),w=Object(_chunks_vec3f64_js__WEBPACK_IMPORTED_MODULE_1__[\"c\"])(),R=Object(_support_buffer_utils_js__WEBPACK_IMPORTED_MODULE_19__[\"createBuffer\"])(_support_buffer_BufferView_js__WEBPACK_IMPORTED_MODULE_8__[\"BufferViewVec4u8\"],h),y=Object(_support_buffer_utils_js__WEBPACK_IMPORTED_MODULE_19__[\"createBuffer\"])(_support_buffer_BufferView_js__WEBPACK_IMPORTED_MODULE_8__[\"BufferViewVec3f\"],h),B=Object(_chunks_mat4_js__WEBPACK_IMPORTED_MODULE_3__[\"a\"])(Object(_chunks_mat4f64_js__WEBPACK_IMPORTED_MODULE_6__[\"a\"])(),p.transform);for(let r=0;r<h;r++){g.getVec(r,M),d.getVec(r,v),Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"i\"])(M,M,p.transform),Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"f\"])(w,M,t.center),Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"C\"])(w,w,t.radius);const o=w[2],c=Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"l\"])(w),f=Math.min(.45+.55*c*c,1);Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"C\"])(w,w,t.radius),Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"i\"])(w,w,B),Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"n\"])(w,w),m+1!==e.model.lods.length&&e.model.lods.length>1&&Object(_chunks_vec3_js__WEBPACK_IMPORTED_MODULE_2__[\"e\"])(w,w,v,o>-1?.2:Math.min(-4*o-3.8,1)),y.setVec(r,w),R.set(r,0,255*f),R.set(r,1,255*f),R.set(r,2,255*f),R.set(r,3,255)}p.attributes.normal=y,p.attributes.color=R}}}(h,v);const M=h.meta.isEsriSymbolResource?{usePBR:p.usePBR,isSchematic:!1,treeRendering:h.customMeta.esriTreeRendering,mrrFactors:[0,1,.2]}:{usePBR:!0,isSchematic:!1,mrrFactors:[0,1,.5]},w={...p.materialParamsMixin,treeRendering:h.customMeta.esriTreeRendering};if(null!=g.specifiedLodIndex){const e=Q(h,M,w,g.specifiedLodIndex);let t=e[0].boundingBox;if(0!==g.specifiedLodIndex){t=Q(h,M,w,0)[0].boundingBox}return{lods:e,referenceBoundingBox:t,isEsriSymbolResource:h.meta.isEsriSymbolResource,isWosr:!1,remove:h.remove}}const R=Q(h,M,w);return{lods:R,referenceBoundingBox:R[0].boundingBox,isEsriSymbolResource:h.meta.isEsriSymbolResource,isWosr:!1,remove:h.remove}}", "title": "" }, { "docid": "9e5fe8ce6959ebc9fc260d81f0c18af4", "score": "0.49606568", "text": "function NativeInfo() {\n\n }", "title": "" }, { "docid": "89366a150b988fc27a95d3f53ce7e782", "score": "0.48396155", "text": "function DataViewer() {\n\n \"use strict\";\n\n}", "title": "" }, { "docid": "827c09572063dc1454abd43942bf9e69", "score": "0.48045242", "text": "ImportCspBlob() {\n\n }", "title": "" }, { "docid": "c48d44c98fb439a0e21b587533776910", "score": "0.4785388", "text": "predefineWindowsMacros(macros)\r\n {\r\n macros[\"DUMMYSTRUCTNAME\"] = \"\";\r\n macros[\"DUMMYUNIONNAME\"] = \"\";\r\n macros[\"MAX_PATH\"] = \"260\";\r\n macros[\"IN\"] = \"\";\r\n macros[\"OUT\"] = \"\";\r\n macros[\"ANYSIZE_ARRAY\"] = \"1\";\r\n }", "title": "" }, { "docid": "2d7beaa5b2aefdcff35f14b927f7a026", "score": "0.47763726", "text": "function BlueGhostCopyrightControl() {\n}", "title": "" }, { "docid": "db06ba7eb029713415aa4c1342dc90eb", "score": "0.4756064", "text": "function s(){f.canvas=!!window[\"CanvasRenderingContext2D\"]||f.cocoonJS;try{f.localStorage=!!localStorage.getItem}catch(t){f.localStorage=!1}f.file=!!(window[\"File\"]&&window[\"FileReader\"]&&window[\"FileList\"]&&window[\"Blob\"]),f.fileSystem=!!window[\"requestFileSystem\"],f.webGL=!!window.WebGLRenderingContext,f.worker=!!window[\"Worker\"],f.pointerLock=\"pointerLockElement\"in document||\"mozPointerLockElement\"in document||\"webkitPointerLockElement\"in document,f.quirksMode=\"CSS1Compat\"!==document.compatMode,navigator.getUserMedia=navigator.getUserMedia||navigator.webkitGetUserMedia||navigator.mozGetUserMedia||navigator.msGetUserMedia||navigator.oGetUserMedia,window.URL=window.URL||window.webkitURL||window.mozURL||window.msURL,f.getUserMedia=f.getUserMedia&&!!navigator.getUserMedia&&!!window.URL,\n// Older versions of firefox (< 21) apparently claim support but user media does not actually work\nf.firefox&&f.firefoxVersion<21&&(f.getUserMedia=!1),\n// TODO: replace canvasBitBltShift detection with actual feature check\n// Excludes iOS versions as they generally wrap UIWebView (eg. Safari WebKit) and it\n// is safer to not try and use the fast copy-over method.\n!f.iOS&&(f.ie||f.firefox||f.chrome)&&(f.canvasBitBltShift=!0),\n// Known not to work\n(f.safari||f.mobileSafari)&&(f.canvasBitBltShift=!1)}", "title": "" }, { "docid": "f89311375bfbddf6354de49f9c039f85", "score": "0.47364965", "text": "GetVersionEx()\r\n{\r\n return this.GetOneByteDataFromChaKey(GETVEREX); \r\n}", "title": "" }, { "docid": "a049317ce0367282b077907428d346c3", "score": "0.47323608", "text": "constructor(data,endianness=TcHmi.Endianness.LittleEndian){this.__offset=0,this.__stringEncodings={\"UTF-8\":{decode:(bytes,endianness)=>{let codePoints=[];for(let i=0,byteLength=bytes.length;i<byteLength;i++){let byte=bytes[i];if(0===byte)return{codePoints:codePoints,byteCount:i+1};if(byte<=127)codePoints.push(byte);else if(byte>=194&&byte<=244){let followBytes=1,firstByteMask=31,mask=32;for(;mask>0;)(byte&mask)>0?(followBytes++,firstByteMask>>>=1,mask>>>=1):mask=0;let codePoint=byte&firstByteMask,lastByteIndex=i+followBytes;if(lastByteIndex>=byteLength)codePoint=65533;else for(;i<lastByteIndex;){i++;let byte=bytes[i];if(byte<128||byte>191){codePoint=65533,i--;break}codePoint=codePoint<=67108863?(codePoint<<6|63&byte)>>>0:codePoint*Math.pow(2,6)+(63&byte)}codePoints.push(codePoint)}else codePoints.push(65533)}return{codePoints:codePoints,byteCount:bytes.length}}}};let decoded=tchmi_base64decode(data);if(null===decoded)throw new Error(`Could not decode string \"${data}\" as base64.`);this.__data=[];for(let i=0,ii=decoded.length;i<ii;i++)this.__data.push(decoded.charCodeAt(i));this.__endianness=endianness}", "title": "" }, { "docid": "a5e364d2a8905877bad656f44028f9a5", "score": "0.4671601", "text": "function te559582() { return 'eXOb'; }", "title": "" }, { "docid": "1f77d62f1b0785eb3f2697c84d071201", "score": "0.4663073", "text": "function CLS() {/*noop*/}", "title": "" }, { "docid": "4f1b399154edaf560218b25a2834fdc3", "score": "0.4625504", "text": "function __b_aPxD_aAgzT_aoP7hbI6qzoA(){}", "title": "" }, { "docid": "4ac1a3e5fae2e6b221c9e02541a52a2d", "score": "0.4613721", "text": "function n(e){var t={},n={},i=e.match(/Firefox\\/([\\d.]+)/),r=e.match(/MSIE\\s([\\d.]+)/)||e.match(/Trident\\/.+?rv:(([\\d.]+))/),o=e.match(/Edge\\/([\\d.]+)/),a=/micromessenger/i.test(e);return i&&(n.firefox=!0,n.version=i[1]),r&&(n.ie=!0,n.version=r[1]),o&&(n.edge=!0,n.version=o[1]),a&&(n.weChat=!0),{browser:n,os:t,node:!1,canvasSupported:document.createElement(\"canvas\").getContext?!0:!1,touchEventsSupported:\"ontouchstart\"in window&&!n.ie&&!n.edge,pointerEventsSupported:\"onpointerdown\"in window&&(n.edge||n.ie&&n.version>=11)}}", "title": "" }, { "docid": "b78e31dfbd5fd11c3fca4276ef31b676", "score": "0.46135816", "text": "function VTUtil(){}", "title": "" }, { "docid": "4d532ef6705a92e2c1c03d720c9d2202", "score": "0.4613033", "text": "function test_ssui_snapshot_memory_checkbox() {}", "title": "" }, { "docid": "a9301b67f541e910d199bbae7d4b8a47", "score": "0.46058893", "text": "_apiVersion() {\n throw new Error('Not implemented');\n }", "title": "" }, { "docid": "8715dc7b63ed68c28eeab8da314df940", "score": "0.46054667", "text": "function ChangeToClrSafe(proj)\n{\n try\n {\n var oConfigs = proj.Object.Configurations;\n for (var nCntr = 1; nCntr <= oConfigs.Count; nCntr++)\n {\n var config = oConfigs(nCntr);\n config.ManagedExtensions = 3;\n }\n }\n catch(e)\n { \n throw e;\n }\n}", "title": "" }, { "docid": "a17a6748e65f6ae5618fd62b360f9f23", "score": "0.45759138", "text": "function Section_Browser_Compatibility____________________________________________(){}", "title": "" }, { "docid": "97d6862b88343ebffac679278aeebfd4", "score": "0.4559436", "text": "function addToolbox () {\n const QH_BEMFA_ICO = 'data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAFAAAABQCAYAAACOEfKtAAAACXBIWXMAAC4jAAAuIwF4pT92AAALhWlUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNS42LWMxNDIgNzkuMTYwOTI0LCAyMDE3LzA3LzEzLTAxOjA2OjM5ICAgICAgICAiPiA8cmRmOlJERiB4bWxuczpyZGY9Imh0dHA6Ly93d3cudzMub3JnLzE5OTkvMDIvMjItcmRmLXN5bnRheC1ucyMiPiA8cmRmOkRlc2NyaXB0aW9uIHJkZjphYm91dD0iIiB4bWxuczp4bXA9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC8iIHhtbG5zOmRjPSJodHRwOi8vcHVybC5vcmcvZGMvZWxlbWVudHMvMS4xLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0RXZ0PSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VFdmVudCMiIHhtbG5zOnN0UmVmPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VSZWYjIiB4bWxuczpwaG90b3Nob3A9Imh0dHA6Ly9ucy5hZG9iZS5jb20vcGhvdG9zaG9wLzEuMC8iIHhtbG5zOnRpZmY9Imh0dHA6Ly9ucy5hZG9iZS5jb20vdGlmZi8xLjAvIiB4bWxuczpleGlmPSJodHRwOi8vbnMuYWRvYmUuY29tL2V4aWYvMS4wLyIgeG1wOkNyZWF0b3JUb29sPSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOCAoV2luZG93cykiIHhtcDpDcmVhdGVEYXRlPSIyMDE4LTA4LTEwVDE5OjI1OjI1KzA4OjAwIiB4bXA6TWV0YWRhdGFEYXRlPSIyMDE5LTA0LTEyVDE0OjQzOjMwKzA4OjAwIiB4bXA6TW9kaWZ5RGF0ZT0iMjAxOS0wNC0xMlQxNDo0MzozMCswODowMCIgZGM6Zm9ybWF0PSJpbWFnZS9wbmciIHhtcE1NOkluc3RhbmNlSUQ9InhtcC5paWQ6NWU5ZWIyZGMtM2U2ZC1kYzRlLTg5MmMtNmJjNjNmZjVkZmUwIiB4bXBNTTpEb2N1bWVudElEPSJhZG9iZTpkb2NpZDpwaG90b3Nob3A6YzBmYWUyM2QtZjEzZi02NTRhLTgyZWUtOTE3NWNjNGNiYTdiIiB4bXBNTTpPcmlnaW5hbERvY3VtZW50SUQ9InhtcC5kaWQ6MGViNzZhZTYtNTM4Ny00MDQxLWJhYzYtNjNhNDk4YzlkMGNmIiBwaG90b3Nob3A6Q29sb3JNb2RlPSIzIiBwaG90b3Nob3A6SUNDUHJvZmlsZT0ic1JHQiBJRUM2MTk2Ni0yLjEiIHRpZmY6T3JpZW50YXRpb249IjEiIHRpZmY6WFJlc29sdXRpb249IjMwMDAwMDAvMTAwMDAiIHRpZmY6WVJlc29sdXRpb249IjMwMDAwMDAvMTAwMDAiIHRpZmY6UmVzb2x1dGlvblVuaXQ9IjIiIGV4aWY6Q29sb3JTcGFjZT0iMSIgZXhpZjpQaXhlbFhEaW1lbnNpb249IjgwMCIgZXhpZjpQaXhlbFlEaW1lbnNpb249IjgwMCI+IDx4bXBNTTpIaXN0b3J5PiA8cmRmOlNlcT4gPHJkZjpsaSBzdEV2dDphY3Rpb249ImNyZWF0ZWQiIHN0RXZ0Omluc3RhbmNlSUQ9InhtcC5paWQ6MGViNzZhZTYtNTM4Ny00MDQxLWJhYzYtNjNhNDk4YzlkMGNmIiBzdEV2dDp3aGVuPSIyMDE4LTA4LTEwVDE5OjI1OjI1KzA4OjAwIiBzdEV2dDpzb2Z0d2FyZUFnZW50PSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOCAoV2luZG93cykiLz4gPHJkZjpsaSBzdEV2dDphY3Rpb249InNhdmVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOjEyOTdhMjQ4LWEwYWUtZDA0OS1hMDE3LTRmMDBlYjc1NjdiMCIgc3RFdnQ6d2hlbj0iMjAxOC0wOC0yOVQxNzo1NzoxMCswODowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTggKFdpbmRvd3MpIiBzdEV2dDpjaGFuZ2VkPSIvIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDpkYmQ4OWExMy03OTMzLWQzNDUtYTIzNi1lZmIzYjkwYWY2NzAiIHN0RXZ0OndoZW49IjIwMTktMDQtMTJUMTQ6NDM6MzArMDg6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCBDQyAyMDE4IChXaW5kb3dzKSIgc3RFdnQ6Y2hhbmdlZD0iLyIvPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0iY29udmVydGVkIiBzdEV2dDpwYXJhbWV0ZXJzPSJmcm9tIGFwcGxpY2F0aW9uL3ZuZC5hZG9iZS5waG90b3Nob3AgdG8gaW1hZ2UvcG5nIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJkZXJpdmVkIiBzdEV2dDpwYXJhbWV0ZXJzPSJjb252ZXJ0ZWQgZnJvbSBhcHBsaWNhdGlvbi92bmQuYWRvYmUucGhvdG9zaG9wIHRvIGltYWdlL3BuZyIvPiA8cmRmOmxpIHN0RXZ0OmFjdGlvbj0ic2F2ZWQiIHN0RXZ0Omluc3RhbmNlSUQ9InhtcC5paWQ6NWU5ZWIyZGMtM2U2ZC1kYzRlLTg5MmMtNmJjNjNmZjVkZmUwIiBzdEV2dDp3aGVuPSIyMDE5LTA0LTEyVDE0OjQzOjMwKzA4OjAwIiBzdEV2dDpzb2Z0d2FyZUFnZW50PSJBZG9iZSBQaG90b3Nob3AgQ0MgMjAxOCAoV2luZG93cykiIHN0RXZ0OmNoYW5nZWQ9Ii8iLz4gPC9yZGY6U2VxPiA8L3htcE1NOkhpc3Rvcnk+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOmRiZDg5YTEzLTc5MzMtZDM0NS1hMjM2LWVmYjNiOTBhZjY3MCIgc3RSZWY6ZG9jdW1lbnRJRD0iYWRvYmU6ZG9jaWQ6cGhvdG9zaG9wOmVlZDRhMDdjLTQ5MjctODI0NC1iZDA0LTNkNmYzMzgwMzVmOSIgc3RSZWY6b3JpZ2luYWxEb2N1bWVudElEPSJ4bXAuZGlkOjBlYjc2YWU2LTUzODctNDA0MS1iYWM2LTYzYTQ5OGM5ZDBjZiIvPiA8cGhvdG9zaG9wOkRvY3VtZW50QW5jZXN0b3JzPiA8cmRmOkJhZz4gPHJkZjpsaT5hZG9iZTpkb2NpZDpwaG90b3Nob3A6NDA4NTIwMjktNjMwZi0yZjRjLTlkMmItMGY0NGM4ZTI2YmFmPC9yZGY6bGk+IDxyZGY6bGk+eG1wLmRpZDowZWI3NmFlNi01Mzg3LTQwNDEtYmFjNi02M2E0OThjOWQwY2Y8L3JkZjpsaT4gPC9yZGY6QmFnPiA8L3Bob3Rvc2hvcDpEb2N1bWVudEFuY2VzdG9ycz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz4WHlDIAAAXoUlEQVR4nNVdeXwUVbb+zq2q7vSaTifpbIQgCTvug4K4oI4O74k6g4jLqKOgojMuqKPOiAqKC6Lz1BGRUTYd3MYV1HFD4vIAFxBRNo0EWbIvZOlOd1dX3fv+qO6Q0EmnutPovO/3qx9J+m791Tn3nHvuuRcSQqArBr2RfeAXSYA6GKiFARLiwQFhAeDiABNAgIGCDJAEIAAIQLg4qE2CcHAIlw5o1FmdBAERAkgAzCgPZrSLIAEOYfzMAFD072SUq2prwsSBp2PVGat7GBgAQI4+erRWJNpDWsHS3eDPBa/Vhq8avsKu9l09fUwwXnkYBnEcgBUGoWnFfx6BFH1iP7Muv3eBQ3agtr0N71e/21MrCgzSYhKnwSCTAFjQsz6lhLS/kaQhcEBedCjQiCAEgWAonyBAERqY0MEPMMmj6r6l5duDW5SMTxDqoadI9DM5Wk6DQXTKoD7nwBAzugwTKBydszgAizE/ClkAsgAiDFAEoAMUIoiMaLsRAjJElAyjHlQC6QRBBnvCpylQSQZBQCWNdbASqDhNSPBBEhIF2X7h4utFtr6J1Uq6kAFSCcIiAKsAwgQ9pMPmsGPHlXusALRxbx6px77GXv8enDNoMhaeuAT17XU47l+j8NP0RilKpDZ4SZ4urBwQAIUZwAGeo3XOtz9NbuqVwF9UAkWRJiHALAiSoDALI4IS6mCPg+NskPEiIADIAtTKQC1si3CKmSJbW0O1cpxB2HHlHhkAxq08QF5v8C216fXTggwx2U8Rv9gcqBdGJASYlUIUoQ4WogDNpwCrhG6QB8Cw5l15EhhNflrN9ijvCyYGiRydwERX2yrBUFOzYDDUOGX8YgRShAQFKUTt0mQKsP0IsVs63ZjeEDMoEZxBfraLVckPN4mAFbLA7hsbFQBi/KqjTc1p9dOCCgAxeImvX3Pgz0ugIKNHSYDVKqOpTfoGYbwMHR5Iokdr2yNio+5gt+Q0ZjZSmP2+VW2Vyp4pUFvVVrRF2ro9LZEWdGiBzuo/TW9kANjg5blqf7/SIZ8DhU8jCjCAkzCMDTkoSEsRpKmdDnQqIBgqrsFJfmnF4Y8OvlPY6ZKBtkEbBefoahzDWggexWOMx9D3mIPdbxxaAhVBFCQZ0XmJOughqHQbOBlfPh1gAGPA3qrm4X8989bpD0ycv7FdbetGIBccimQBAOS58mUA8C21aU7m7Hf3h5ZAnQRCLELA7xCkJdCQFVPhdIGIUNNWgyGFA8N3nT5nHgC4LO5EVWQA/VbdGNI6Bwo7Z52tGvZtFAVpI/zsdXBkQYL5ec4kCIDfL/Dnk//yhE2x7+mjuAJADFqS0y/D0RVpkUCRrTPo3AI/42BChSAHBdhCROgyQBiBhkMAiRh2Nldj/JAxu68+7tpZJqqwulCtCkrfW0wsgSb6ETbBhEZWCjCdIqRSmP0JIWqBCoO8NEtcV6i6Cs6BO0+b8zD6UMvaYA3N+PgyXvxyASMJnaug/iIxgaKPDqIhK4pQCAE2jtpYBQJsARjk3oIA6YLEJOxubMQFR05eN3Hofz/ZV/l8W4H47Kd12jOjl55dVd34hN3isIqYk94PBUlMYG+GPubwSgAF2BDWIK0hP30CHWXpNBC9gUBoDbXA7bDinl/fd6/Zehsv+Vaa98nc+YqfrrPUZlRRB/uD8OqsP2NOzoh0j5xYoNIiCrAdCLEJnYbjZ4DEGOqbAvjTuBuWD8sd8b7ZevPKH7h2x95dQwZ4C8AjIpuapOWs0rIJEToG8kHLRpNIHI0BQJHo6iFEII0AjUABmgaVngCHPR2kERF0oSMYCaBdDaAjBEP6Y21Hh2jJADKtGfCHQxjgLsbG67eMcFndO8z0sat5Z/4xCw6vUBg53dbMmEMd1TIC7Px9kaVPB6cqhOkQRGNkAYQpg9rZBwjRSZD6sYqAoYZEQFOwGfvbw5AkoNiTi+F5o+uOyD9qT2HmANlmySAmMYTCITQHmtUttd9m72jeVtpQW4VbJt1+j1nyAODeNbP/0tIWdA4pKILOu8xNEgAIwM9+Q2HaJ1z8XFjFKrPt9k6giH6qIRbvs1CT9AV0OiIVUY+ByHitVW11CPk5hhUW4w9HTPry3JHnLT+i4Ohyr9O7G0Cwl+qstaNl6PaGbaNG5Y8uN9vnJ5Xlv3ru6+dvLM7xdievKywC0ABqllaKXO1CKOJlaNSngYknMGY5ZQGEGQMDh0pg1XJ5f8lTmIyGYDOamztw3GGHh68567qllx47bZ4sy305wDHwTLtnx9iSE0xLHgDcV37PXZwDGYqtdwIFOqWRmqWXyMX3CAdfDz2xK9EzgQSASJLqZMY9OqdmaT7CdAKU1MgjEBgDvm/YB7clA0umPrV42thrZgII9FW3v1i6YfFFq7d9ck5pQX7v5HWFDEAlsCrlRT44UgZZJIwXxhFIIWOhT0FGCBOnFnYUBejWlMkjAhc6dlbX48TBY2peuWTllPzMgnUpNZYkIrqK+Z/ef7fdAXRahL4gYGxNhKiE6qVZws6XAehVQ+IJbJRiDQlYuE4qTU1p9DDI04SG3dUNmD720u2LL3huLIC2VNtLFnPXzPnL91U/DR9SWAidJ7n8lQTIzyZBpRoAT/dWLM6OUoiMJ0wCKgHA2FRWFARD8nbXNOCGk67dsfiC58ahD/Law22oaa8CALy57TUUz8vGyU8fh+312wAAwUhvtiUe4UjIs+x/l92WYU9+7ABiG/1lpGFkX8Xi/xJ7CIBG3lTcFcYIu2rrcdmvLvrh8ckLTwDQ2ledfa17sbXuOwDA/mAz9lU3Y2vdtwjrIQjBEdKC0Li5LQyrktEy+zez3wsFgY5IMGr9kwR1bn/2ir6pIajJrhVlJqOisRonHDam8tmLXxgHYL+ZeoqkwK44AAAZsg3MCeQ6fJCZDCIGRlJSynDlCddcfNuEW1ZU1e9PNQATXe33jrQvvgiExmAjvFY7npv6wiUAmlNrp3ubPX/SNx6a9MgVpw09acePDTWQWZIJCaIzN6JXpJ9AAppbQpg1Yc68Ul/Z+qTqgmCJht7tFkMSLZIVLqsLgOFHpgDtkbMeu86uMLSr7anUT4i0EkggVLXX4NjiUfU3n3Lr/cnWd1icqGqrwvKNz1y2dMM/ns+225d0qP7l93x056IF6x89vz5Q75KSlSIARxcf89H0Y65+raa5DYzSKzPp3RMhIBgErjn+hidB8CdT9cemHwpuf2/mPR9WvHdBe5twO5wKBnh8UHUVz254Hku152fMdt+u/tfQcxbNPeOhOw7zliblhN8w/pa/rdj8z/MCET9scqqmOR6JXkfSnnNLaD/KsosCUw6f+lQy9RZ98fdzhjw8bN/r3757lcfmcZcWFiDflYOIroMgYZC3AKV5BbBIVsvzX712w9BHypqf/fqZs5Ppo8xXtv7c4ee+XdPadtCc2j8kIpBMlOlSmNDUHsJvR05Z6XF4GswO4O4P/3rhtStuXJnrdLAhviIozAohxIFwEwyfXggBu+LE0IIiuG12y+XLrl51X/ndF5ntBwB+O/q8lyEA0b+ErG6II0fIgJBBQoYkZABkLtdEgAMEnHjYBNOhoCfWPXrx3LfmvVhUmIXMjExTa1WN6/DaPCgs9OCuN+e+sOiLBZeY7e/EkpM/KMsuCqXTmJjxAzvMNOSP+DHYU9A+dsDYD82U316/tfSWf9+83JubAZtiAxfmpYILDrtihyfbipvfvnHJD407yszUy3bl1I8fePIHDQFTXymmg/32A01NGK2hAEbljd6W58lvBgDOeefTEx765MFZkRCUbHt2UuTFwAWHz5GDYIBbHii//7aeyggh4sYxJGfoNtP5WAIEkdhsp82mhyNAkXvATgAIdATQEeyAP+BHWA3Hla1pq7G+98M7k3xZDnMhpl6gcR35OS688/2bv93TsjvOtKqqCn/Aj45gBzqChtQVuooqIKHbHJsQfRRLn1PEAa8thwDAYXfA6XDC7XLDlmGLK7p+z9oL69pbcp2W/uem2BU7Gv3+3G9qNk05+DOr1Qq3yw2nwwmnw+jL58xjEoCD94JSRVq9SrfdbUrdN1Z/eSo0gNLQPcFIyd1St/lUM+XddjfJyUhgH0jvSsSkexWMBEVSapQAIpr9sK+lylxjXU8BpAHxK5F+fKeOkLl4HaX7vIsAJGau0WAwCF0/OECROuIJPCCTMSNuTkploL69TkcA2N26GwCgRlRke7LhzfR2K+qxeRl0I2Ld37koRkRp9tC479IeaEdtYy0sihGgKPGUYE/Tbp1J6RPCeHIkEXvI2PsVITPv1iID9f46W1ANGrsPgkef+MpjB45fL1nQLwscAwcHScBI3+i4fRYhRJdxGG5MbXuNTdUBSlNQoe9gAplLRrRJMvb6dx+JDGBgVgnCYcN94ZyDC94tCjJu4PgVxZ6CB1tCjZ5sW06/5sKW4H4MyipoPb543EsHf6bICgbml4CIjIi0BWhSG45M5wzS92sQ5qQ9y+bFpurvStfu/mwkABAzUkJkRY4LITktTv8FR/z+7ZbmCCSWuiTITML+ZhUXHXnZG5kZmXFbBrIsgxiBGMFisaCjI4BPK8uP8tiVvhs3NvGor++fNissQUJEAzbVbjwLACyKBVbFCkXuebBzfn3PvYOLirWdzVXJR4phkLeruQolBQWRO06d9WBPZRRZgdVi7ZwDN9ZuGLOlaccYj9WTdH+9IW0ECgjY7cCqba//zoyKZMj2iuem/vMqXQNq2uogJxFtlpmMOn8DIiqwZMryaxwW1w9m6r27450zVRWQKH1h0LT6gXkOH9bu2TDu/R3vjTVTfnzJKcvfuuK1P7YHNVQ07oPEKKF7QSDIjKGyaR9a21W8evmLfzq99MylZvpqD7bjlS0vXZHlsqTNiQbSTKBEEgQDnvri77earTNp+OSnNt20YdpwXwkq9tSgpr0OEX7AbsUI1XgEdf56/LCnGiVZBfhy5rpp5426cKHZfpZ8+fSMHxv2lnpt2X0XTgJpi8YAABcCJZ4crNzx7uS3t646zmy9owqOXfbNDd8XLbzo8VdG+IZhf3A/KptqUVlfi511NahsrEVDoAmDvYPEo1Mfevu7m3YOHzNg3DKz7bcF2vDE+sdmupxS2s+sJ3KkU4LCLJBlYPaHs/42acTZJ4GZ498iWauvHXvD1BnHX5f3fcO28zfXfjPhx6YKazAS1Euzy2xjisauHuEbuVBmctIJSbM+uH1OZcO+4UMLi6Clwffsit7T22LaQ4iPRyUAFxyDs4rw9d4tJ177+tV3PzXlGdM5zADAiNWN8I1eMMI3ekEy9YQQPWYfvLLppfEL1i2aPTAvJ+3kAT3JG+/yiOhfkhR7nXOU5OVg0frF9yxau+Cyfo+yFxgrjd4Ht61mS+n0N/6w0u1SYGWWVLqInSdOWKD7oDIEhE0IoQgGPbVDeQICCrMg1+vEtauuf3bFV8uvSraNvhAMd6CxpbHXnJe61urDJi799ecdXM3Od+RBTyHqDUAFxV0d0A3xEmjjgJ0Ddk4UISsI36ay9OaCI8uWCXBg/uqHHwSQmXCkuooPf3gXDa31vZZpD7bhy8rPsbnyG9Q01UCN9Dy77GrcOWjMgmM/3+uvyynzDjCdkNQNhmDvAkNFomI9e5QcgFUEhIu7wbGSQnR/5xGHJKDpGiCAWyfe+jT6yM6KCBXnL5uCBybMQ7PSgLyOQlx5xgyQlfDl11/i8a3zMSxrBGrq6zHl2PPhdXghd1nlxCRxzfcfDD93xdmfBLnqG5Y7ABE9BfIIQJggsvU3hIMn3GWMV2GbMB4LwH16BBrtgUvMjeYKmoZEDJVNdZg46rTNlx59+R19lWeMoTAzD5l2D9ZUrMFH36xGLLl2a8V3eGPT64iQhkJPHuxWe1z0ttXfghvfnDHr9MW/2U4SfGXZ/SBPJSBD/MjztLnCqyfM3+7dCgsAkgiKXN1OtfI8OPgEhOgks8kgQS0IWQLuPn3uHLNjl8jIasx35SFXy+98vZkuDwZ6i2GVLNHIDsHKrHBZXAAHFqx9dPJ95ffOr2ttKR3g88Im21IjDzBOJTCAF2kXQQGnSGK/LnFEWiVARYc+IGKjJmkKq5c/g4ahfWXqy0xCZe1+XH3i9FfHDTzhTbNjl0mBQ3aCC45cqw/MZrzNIlsxhC5gk+xQrBboXMfXNV8VvFfxzjlvVbxxc2VD7dCsTBtifl7KcUYdIJ3AC7XJwq1vQLjvgG9ieYruH1AYQTi4ELnaSdTGPkIHGw2555OYBEJjRxN8XjfuPPWuR82OfX+g2d2q77/91R9frN7XvmezVdgsH+9YQ9YMCz5uKAdTWPjz2rXZalg9csWuxeO+q98+MaQLZNkzUJpfAAj0z8+LEKAI8CxtolDE+4jQAQ4SwHRYggIsJJw8Ilz8OKqTb6EgzYUWPbrfpRNGhOaWEOaedfuyYk+J6Wz8J9c9ftOu1ro76sIr4VHcqLRU4OUXXoTggMOuwGvJxupdH0EwHRIY8l05kJjcpy/YJ3TjMI1w87dEln4F6WgizfyuTfxZuVUHnZULEsAEKCAZKq0I8Ewus1aWTW3sSYTpPOM2DgFGhH2tNRjsLQt9O3P7EInkfWYG8V3t5gHjnjp2u8vqcDoUh5FMBGFkLAgjOMvSnQuqR29gsoudws4vFS59PRhAfuOmOu7ROy+FSnRWLrlRRY9asEamQaM65POLhZ2fDFlsACdwnSMUAv464a77zZIHAHPXzH4gENSdLqurM9REIEgkQWJS+siLHRUx1LVRZOtX8VytDFa+HiozSE3SVUt+ZLF9VQ6INlJrHA1r+cDwKc5c23mVzXU4c/hpVZccfdl9Zptbte3NE1/ZtPLSQTm5adlkSojovCay9Pncp+UKF18MnaLEpTYNxM2BtaHuOeEFSBw/K/T7+M4ralUAbx+9dFjRkinL43M5EuCBj+fOlxRAZkpKSUamoBlxEW7nHwqvfikU1CFMB65m7AfiCByX/atuv//U2OMFh53YeX1t7Ai2OsQ7rHqAu9h05wvWP37RFzu/HldWUHBoyItdn5fB93K7uAQZ/FMoAlBZ9PC4MJ9O0QviCCw//atuvx/2ck5fbSgAuPwIicll5rNuW0Mt1v/57KF5LpeU/ns5BYyrRi1Ch1P/M3fwxyDIODwuI6quhyozIQlUXlUnAaDShXlJX2Tz4Mf337Srtmbg0KI0BzljJ+w9fDl3638EECQNabroKR79NW+xI9mmMHPtdQotILa9dtvxT6577MG8HGfyhwB7g25cRwAn3yDytZHcq10BJoIUIUOND9ENIilLYOWMOhkASp/I13sKOX66uxwvb30ePkceAGD2KfcrQ7KGSJAhZrx3+fEa1+CWMqH3VzQ4AE6AlVcLu5gmPLpxCYVKP8slGP1R4YSXHa7eVY6F/14C+ABxtyAA0nWvzgwhAlSM3PrUwKH527UmfTFCNBAkkr8W9sA8B+HmtyODzwcTB65ZPoR31nRFSgRWXlVvXF74TB7vbR832+YGfECZtwgwDI1e5i0C6QQ9HImomepqZFApa5auh5/NR5hkKCZvOtKMCyuEm/+LZ+pXgdBGYUJab4UziaSFvPKK+tgBPFPHHyqu28cA0JAFA4zysdVAGxMUII1n6Y/zIi1PZOnPdq4SeuNAhyFhGWIrL9CO5rnaBWBoo1idn0nquiKVWUIBwAf/I8/sq+55X4UACAJ1MA6gWeTr00W+fhSc/BMABlGxzS0dhpGwok549It5tjZa2Pg3UOmQWVezSEqFY27L4Gd8qpnXLe4WMgA2ZMGA3t2c6LIQQdKFIjaLPO006mCHI0ynIkKDwCHBIupgFV9BEeXgpJJGEMlcNXsIEReN6QNWRBXJZPkMGKreTU7O+vA0vFtdjhJHttESAVAAIQCK3XgfIQhHNLcsgqgDHP05dtU27/Jv7J59jgNiEVuqRde6wgJQ7D5rRP8uCQjFuOqg817qWBTmnN6jMDEko8JytGuz5Mk4oIDdcHLeqRCR9OUp/5JIhsDY1enJlO9R0SYV/w6ZdgkhPeGW6/8LmCXQAkP6zC4bLOj+nwF0w8is0TjMXYb2SFJHiv8j8X8D48AgBA7ImwAAAABJRU5ErkJggg==';\n\n return `\n<category name=\"%{BKY_QH_BEMFA_CATEGORY}\" id=\"QH_BEMFA_CATEGORY\" colour=\"#42CCFF\" secondaryColour=\"#42CCFF\" iconURI=\"${QH_BEMFA_ICO}\">\n <block type=\"QDP_tcp_device_cloud_subscription\">\n <statement name=\"function\">\n <block type=\"serialPrint\">\n <value name=\"VALUE\">\n <block type=\"QH_variables_get\">\n <value name=\"VAR\">\n <shadow type=\"text\">\n <field name=\"TEXT\">DATA</field>\n </shadow>\n </value>\n </block>\n </value>\n </block>\n </statement>\n </block>\n <block type=\"QDP_tcp_device_cloud_theme_push\">\n <value name=\"data\">\n <shadow type=\"text\">\n <field name=\"TEXT\">test</field>\n </shadow>\n </value>\n </block>\n <block type=\"serialPrint\">\n <value name=\"VALUE\">\n <shadow type=\"text\">\n <field name=\"TEXT\">2</field>\n </shadow>\n </value>\n </block> \n <block type=\"QH_variables_get\">\n <value name=\"VAR\">\n <shadow type=\"text\">\n <field name=\"TEXT\">item</field>\n </shadow>\n </value>\n </block>\n</category>\n`;\n}", "title": "" }, { "docid": "c1c8afffe6a84e6d43bc6250715eea49", "score": "0.4552518", "text": "function test_snapshot_image_copies_system_info() {}", "title": "" }, { "docid": "e5f4bd2b3807e4bea7e9d5e18ab063c7", "score": "0.4533828", "text": "function __loadCompat(w){w.Debug=function(){};w.Debug._fail=function(message){throw new Error(message);};w.Debug.writeln=function(text){if(window.console){window.console.debug(text);}};w.__getNonTextNode=function(node){try{while(node&&(node.nodeType!=1)){node=node.parentNode;}} catch(ex){node=null;} return node;};}", "title": "" }, { "docid": "db0914569ac076c09239d754679dc12a", "score": "0.45244658", "text": "function te875091() { return '.Res'; }", "title": "" }, { "docid": "1da1a3eb13a3b2f3651e94fc55045aa8", "score": "0.45164183", "text": "static isSupported() {\n\t\treturn true;\n\t}", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "78dc4d7acfbc7b81b7ca903afba98639", "score": "0.45140797", "text": "constructor() {\n \n\n \n \n\n \n\n \n }", "title": "" }, { "docid": "6277589887e2a66ca2809bd82962be4c", "score": "0.45135576", "text": "exportVisualData() {\r\n let iv = this.i.as();\r\n return (iv);\r\n }", "title": "" }, { "docid": "70eba78a38e7693f4765d21d8e6996b2", "score": "0.45097196", "text": "get FallbackAdvanceX() { return this.native.FallbackAdvanceX; }", "title": "" }, { "docid": "897f0dcbe4d8790f2b521c2ab824034c", "score": "0.45075747", "text": "function setup() {\n\n}", "title": "" }, { "docid": "56785194e1a846e70ad57736c23e8405", "score": "0.449992", "text": "get wrap(){ return this.__rt.wrap; }", "title": "" }, { "docid": "05c02d428633467dbd129128e6a4c173", "score": "0.44989598", "text": "function HighLightCpp(str1)\r\n {\r\n\tvar fstr1=new Object();\r\n\tfstr1.name1=cdh_Fill0(str1);\r\n\r\n\tstr1=cdh_H2(str1,fstr1,/(\\/\\/.*)/gim,\"shCmm1\");\r\n\tstr1=cdh_H3(str1,fstr1,/(\\/\\*(.|\\n)*?\\*\\/)/gim,\"shCmm1\");\r\n\tstr1=cdh_H3(str1,fstr1,/(^#(\\\\<br\\/>\\n|.)*)/gim,\"shPre1\");\r\n\tstr1=cdh_H2(str1,fstr1,/(\".*?\")/gim,\"shString1\");\r\n\tstr1=cdh_H2(str1,fstr1,/('.')/gim,\"shString1\");\r\n\tvar re1=/\\b(int|long|__int64|short|char|wchar_t|float|double|bool|void|signed|unsigned|true|false)\\b/gm;\r\n\tstr1=cdh_H2(str1,fstr1,re1,\"shType1\");\r\n\tvar re1=/\\b(for|while|do|if|else|switch|case|default|return|break|continue|goto|virtual|static|const|auto|register|volatile|mutable|extern|explicit|export|inline|typedef|using|namespace|template|typename|sizeof|typeid|operator|new|delete|public|protected|private|friend|struct|class|union|enum|try|catch|throw|this|static_cast|dynamic_cast|const_cast|reinterpret_cast)\\b/gm;\r\n\tstr1=cdh_H2(str1,fstr1,re1,\"shReser1\");\r\n\tvar re1=/\\b(BOOL|TRUE|FALSE|NULL|BYTE|WORD|DWORD|UINT|LPSTR|LPCSTR|LPTSTR|LPCTSTR|HANDLE|HDC|WINAPI|dllimport|dllexport|ASSERT|printf|scanf|std|vector|string|iterator)\\b/gm;\r\n\tstr1=cdh_H2(str1,fstr1,re1,\"shCommon1\");\r\n\r\n\treturn str1;\r\n }", "title": "" }, { "docid": "e11c4ca749172390ee57e1be089293b7", "score": "0.4497128", "text": "function dllView_attachToDSP()\n{\n var debugSession = GetActiveDebugSession();\n // currently have to configure CCS4 to enable legacy real-time mode for \n // non-intrusive connect\n debugSession.target.connect(); \n}", "title": "" }, { "docid": "cdf34d30850302cb02518decc6c460fc", "score": "0.44924274", "text": "function zf(b){var c=!!b.readOnly;if(c)var d=null,e=!1,f=!1,k=!1,m=!1,p=!1,t=!1;else(d=b.toolbox)?(\"string\"!=typeof d&&(\"undefined\"==typeof XSLTProcessor&&d.outerHTML?d=d.outerHTML:d instanceof Element||(d=null)),\"string\"==typeof d&&(d=Yc(d))):d=null,e=!(!d||!d.getElementsByTagName(\"category\").length),f=b.trashcan,void 0===f&&(f=e),k=b.collapse,void 0===k&&(k=e),m=b.comments,void 0===m&&(m=e),p=b.disable,void 0===p&&(p=e),t=b.sounds,void 0===t&&(t=!0);var v=b.scrollbars;void 0===v&&(v=e);var z=b.css;\nvoid 0===z&&(z=!0);var B=\"https://blockly-demo.appspot.com/static/media/\";b.media?B=b.media:b.path&&(B=b.path+\"media/\");this.s=!!b.rtl;this.o=k;this.P=m;this.U=p;this.i=c;this.N=b.maxBlocks||Infinity;this.Zb=B;this.Z=e;this.G=v;this.pa=f;this.xa=t;this.ha=z;this.yd=d;c=b.grid||{};d={};d.spacing=parseFloat(c.spacing)||0;d.jd=c.colour||\"#888\";d.length=parseFloat(c.length)||1;d.eq=0<d.spacing&&!!c.snap;this.h=d;b=b.zoom||{};c={};c.controls=void 0===b.controls?!1:!!b.controls;c.np=void 0===b.wheel?!1:\n!!b.wheel;c.jp=void 0===b.startScale?1:parseFloat(b.startScale);c.ae=void 0===b.maxScale?3:parseFloat(b.maxScale);c.be=void 0===b.minScale?.3:parseFloat(b.minScale);c.gp=void 0===b.scaleSpeed?1.2:parseFloat(b.scaleSpeed);this.g=c}", "title": "" }, { "docid": "98a40f6fcbee78b0f17b1e00318dcaae", "score": "0.4480949", "text": "function _4LCoogDb2D6OWKZ_aVgzWZw() {}", "title": "" }, { "docid": "0d0a3965bf0623ef6a510ea412952908", "score": "0.4478908", "text": "function test_service_provision_managed_image_azure() {}", "title": "" }, { "docid": "49fe92d2e0ba317c613b2d6a51a2a459", "score": "0.44744116", "text": "exportVisualData() {\n let iv = this.i.nw();\n return (iv);\n }", "title": "" }, { "docid": "d88e48bde7b6f9cb0d487fdb4e0efbc0", "score": "0.4463565", "text": "function wc() {\n if (\"undefined\" == typeof Uint8Array) throw new N(S.UNIMPLEMENTED, \"Uint8Arrays are not available in this environment.\");\n}", "title": "" }, { "docid": "496733c5e9c5907f20a4706482a8b2af", "score": "0.44618976", "text": "function takeScreenshot() {\n // Take only one screenshot at a time.\n if (isSavingFile == true) {\n document.getElementById(\"statustext\").innerHTML = \"Screenshot save already in progress. Please try again later.\";\n return;\n } else {\n isSavingFile = true;\n }\n\n // Get the bitmap of the canvas.\n var blob = document.getElementById(\"mainCanvas\").msToBlob();\n\n var input = null;\n var fileStream = null;\n var finalizeSave = function () {\n if (input != null) { input.close(); input = null; }\n if (fileStream != null) { fileStream.close(); fileStream = null; }\n isSavingFile = false;\n };\n var date = new Date();\n var time = date.getHours() + '-' + date.getMinutes() + '-' + date.getSeconds();\n var fileName = \"KinectScreenshot-Depth-\" + time + \".png\";\n\n // Write the screenshot to the given file name.\n Windows.Storage.KnownFolders.picturesLibrary.createFileAsync(fileName,\n Windows.Storage.CreationCollisionOption.replaceExisting)\n .then(function (file) {\n return file.openAsync(Windows.Storage.FileAccessMode.readWrite);\n })\n .then(function (stream) {\n fileStream = stream;\n var output = stream.getOutputStreamAt(0);\n input = blob.msDetachStream();\n return Windows.Storage.Streams.RandomAccessStream.copyAndCloseAsync(input, output);\n })\n .done(\n function () {\n finalizeSave();\n document.getElementById(\"statustext\").innerHTML = \"Saved screenshot to Pictures Library as \" + fileName;\n },\n function (err) {\n finalizeSave();\n document.getElementById(\"statustext\").innerHTML = \"Screenshot failed to save to Pictures Library!\" + fileName;\n });\n}", "title": "" }, { "docid": "b6a0b7c568ef070ce3c316a17d746c06", "score": "0.44510153", "text": "function getMicrosoftSilverlightVersion(options)\n {\n const keys = [];\n let strOut = null;\n\n try\n {\n let strSilverlightVersion;\n\n try\n {\n var objControl = new ActiveXObject('AgControl.AgControl');\n\n if (objControl.IsVersionSupported('5.0'))\n strSilverlightVersion = '5.x';\n else if (objControl.IsVersionSupported('4.0'))\n strSilverlightVersion = '4.x';\n else if (objControl.IsVersionSupported('3.0'))\n strSilverlightVersion = '3.x';\n else if (objControl.IsVersionSupported('2.0'))\n strSilverlightVersion = '2.x';\n else\n strSilverlightVersion = '1.x';\n \n objControl = null;\n } catch (e)\n {\n let objPlugin = navigator.plugins['Silverlight Plug-In'];\n\n if (objPlugin)\n {\n if (objPlugin.description === '1.0.30226.2')\n strSilverlightVersion = '2.x';\n else\n strSilverlightVersion = parseInt(objPlugin.description[0], 10);\n } else\n {\n strSilverlightVersion = 'N/A';\n }\n }\n\n strOut = strSilverlightVersion;\n\n } catch (err) { }\n \n if (!options.excludeMicrosoftSilverlightVersion)\n keys.push({ 'ms_silverlight_version': strOut || 'Error' });\n \n return keys;\n }", "title": "" }, { "docid": "b7084992218bc4aa6aadb80055d427e6", "score": "0.44490495", "text": "function _4Xmw8hHFnzuUOt7IaRLq5g() {}", "title": "" }, { "docid": "9d6d654cfc697f459d366a9591cb3c01", "score": "0.4446436", "text": "function RMXFViewer_SetSize()\n{\n var text4ref = true;\n var instText1 = \"You have to install<br>Vidicor View Component<p>\";\n var instText2 = \"<b>Click this link</b> to install ActiveX/Plugin component.\";\n var instText3 = \"<br>(run the file downloaded then follow its instructions)\";\n var instText4 = \"<b>Click here</b> or <b>Press F5</b> since installation completed\";\n if (UAisOpera)\n {\n instText4 = \"Restart your browser since installation completed <br>and return to this page again\";\n text4ref = false;\n }\n// var instText5 = \"Attention! This page requires additional component to work.\\n\" +\n// \"Press OK and follow component installation instructions.\";\n var instText6 = \"Don't pay attention to a browser message on a yellow bar (if any) above this page\";\n\n if (lang == \"ru\")\n {\n instText1 = \"Вам необходимо установить<br>компонент просмотра видео Vidicor<p>\";\n instText2 = \"<b>Нажмите на эту ссылку</b>, чтобы установить ActiveX компонент\";\n instText3 = \"<br>(запустите этот файл и следуйте его инструкциям)\";\n instText4 = \"После завершения установки <b>щелкните здесь</b> или <b>нажмите F5</b>\";\n if (UAisOpera)\n {\n instText4 = \"После завершения установки перезапустите ваш браузер <br>и вернитесь на эту страницу снова\";\n text4ref = false;\n }\n// instText5 = \"Внимание! Эта страница требует для работы установки дополнительного компонента.\\n\" +\n// \"Нажмите OK и следуйте появившимся инструкциям по установке ActiveX компонента.\";\n var instText6 = \"Не обращайте внимания на сообщение браузера<br>на желтой полосе сверху этой страницы, если имеется\";\n }\n\n var w = -1;\n var h = -1;\n if (arguments.length == 2)\n {\n w = parseInt(arguments[0]);\n h = parseInt(arguments[1]);\n }\n else\n if (arguments.length == 1)\n {\n var str = new String(arguments[0]);\n var xi = str.indexOf('x', 0);\n if (xi < 0) xi = str.indexOf('X', 0);\n if (xi < 0) xi = str.indexOf('*', 0);\n if (xi >= 0)\n {\n w = parseInt(str.substring(0, xi));\n h = parseInt(str.substring(xi + 1));\n }\n }\n else\n if (arguments.length == 0)\n {\n w = this.reqW;\n h = this.reqH;\n }\n\n if ((w >= 0) && (h >= 0))\n {\n this.reqW = w;\n this.reqH = h; \n if (this.rmxfobj && (UAisAlternative || (this.rmxfobj.readyState >= 4)))\n {\n if (this.rmxfobj.URL != null)\n {\n window.setTimeout('RMXFCallSetVideoSize(' + this.rmxfidx + ', ' + w + ', ' + h + ')', 10);\n }\n else\n {\n var svrBase = '';\n if (this.passivemode == 0)\n svrBase = \"http://\" + this.rmxfhost + ((this.rmxfport != 0) ? (\":\" + this.rmxfport) : \"\") + \"/\";\n this.rmxftag.innerHTML = \"<TABLE id=instructions width=\" + this.reqW + \" height=\" + this.reqH + \" border=10 cellpadding=0 cellspacing=0 bgcolor=#ffffaa>\" +\n \"<TR><TD align=center valign=middle>\" +\n \"<FONT color=#ff00000 size=+2><b>\" + instText1 + \"</b></FONT><p>\" +\n \"<LI><A target='_blank' href='\" + svrBase + \"activex_setup.exe?nocache=\" + Math.round(999999 * Math.random()) + \".exe'><U>\" + instText2 + \"</U></A>\" +\n instText3 + \"<br>\" +\n \"<LI>\" + (text4ref ? \"<a href='#' onclick='return DoReload();'><U>\" : \"\") + instText4 + (text4ref ? \"</u></a>\" : \"\") +\n \"<p><FONT color=#ff00000 size=+1>\" + instText6 + \"</font>\" + \"<br>\" +\n \"</TD></TR></TABLE>\";\n {\n var el = document.getElementById('instructions');\n if (el) el.scrollIntoView(true);\n }\n }\n }\n }\n}", "title": "" }, { "docid": "53b4d5c0d20434b3bfb3bf716dd7a580", "score": "0.44461524", "text": "function CAknAppUiVisual() {\r\n}", "title": "" }, { "docid": "4cae00914d9e6acdc704387b46f9bda5", "score": "0.44446707", "text": "function msll() {}", "title": "" }, { "docid": "7c70a00f820cfc01c74ad9829351e500", "score": "0.44409788", "text": "function _7iCNA6ww_aDCiPTZUe8462Q() {}", "title": "" }, { "docid": "0d84847c98908520e3f4e6b2b80e4145", "score": "0.44389862", "text": "function VerifyDeviceConnection()\n{\n //Step1. Click on files in device tree view\n AssertClass.IsTrue(IECBrowserPage.SelectFilesInDeviceTree(), \"Files selected under Device tree view\")\n \n //Step2. Download the cid files\n AssertClass.IsTrue(IECBrowserPage.DownloadCIDFile(), \"CID file downloaded\")\n \n //Step3. Verify File downloaded successfully or not\n AssertClass.IsTrue(IECBrowserCommonMethod.CheckTraceLog(\"Copied with success.\"))\n}", "title": "" }, { "docid": "a9679d0a016c1e3fa611df112c0486ec", "score": "0.4434787", "text": "Es(){\r\n return 29000000\r\n }", "title": "" }, { "docid": "2ac82eecab7045d9d68115dfc6203bab", "score": "0.44215176", "text": "function NintendoDS() {\n\n}", "title": "" }, { "docid": "72148348f3c9fc01fea10d1f8cbd4c7b", "score": "0.44059306", "text": "function _3RhvcSQcujmOU5OTLoz_bAw(){}", "title": "" }, { "docid": "f7137ffc8b0bae68104fc80452a6776c", "score": "0.43988872", "text": "function _5wzrP2I6Vj2DJL7jzmH7UA(){}", "title": "" }, { "docid": "1891912d6b846e5df18b3bf0c14f9fa3", "score": "0.43953353", "text": "function DT_DecoderHardwarePowerReadyResponse()\n{\n //do stuff\n}", "title": "" }, { "docid": "fd4323c22be432c485e9bbecc9f23a77", "score": "0.43906325", "text": "function test_provision_image_managed_azure() {}", "title": "" }, { "docid": "4fc058d2d1b57a284013deda02881e93", "score": "0.43887758", "text": "function Main()\n { \n\n }", "title": "" }, { "docid": "ca9eeda339cc62fecd92228661ee6e65", "score": "0.4380679", "text": "function CanvasUtils() {}", "title": "" }, { "docid": "af9ed55702f4c060f26a160a3352491d", "score": "0.43796635", "text": "function setup() {\n\n }", "title": "" }, { "docid": "91e892e5e4c44adb8c0d5d4c7da67941", "score": "0.43759128", "text": "function mbcs() {}", "title": "" }, { "docid": "91e892e5e4c44adb8c0d5d4c7da67941", "score": "0.43759128", "text": "function mbcs() {}", "title": "" }, { "docid": "91e892e5e4c44adb8c0d5d4c7da67941", "score": "0.43759128", "text": "function mbcs() {}", "title": "" }, { "docid": "91e892e5e4c44adb8c0d5d4c7da67941", "score": "0.43759128", "text": "function mbcs() {}", "title": "" }, { "docid": "91e892e5e4c44adb8c0d5d4c7da67941", "score": "0.43759128", "text": "function mbcs() {}", "title": "" }, { "docid": "91e892e5e4c44adb8c0d5d4c7da67941", "score": "0.43759128", "text": "function mbcs() {}", "title": "" }, { "docid": "c45a3683f814b3ab62c80802010e0ceb", "score": "0.4372761", "text": "function BTTInitialize() {\n\n}", "title": "" }, { "docid": "4530e8fb788868a779cc74b3b61df81a", "score": "0.43694368", "text": "browserSupportsFeature() {\n return \"speechSynthesis\" in window;\n }", "title": "" }, { "docid": "37de097f0b355e1dd19166fd77fda0eb", "score": "0.43581092", "text": "function Automation() {\n}", "title": "" }, { "docid": "022ee3aba2b00b2df9515313124353c5", "score": "0.43545184", "text": "get SUPPORT_BASE64_DRAWING() {\n 'use strict';\n\n return function (src) {\n var _value = testBase64(document, src);\n Object.defineProperty(FEATURES, 'SUPPORT_BASE64_DRAWING', { value: function value() {\n return _value;\n } });\n return _value;\n };\n }", "title": "" } ]
d70806b099ffa1a0a2776a35018dd84a
Top value rendering function
[ { "docid": "8fe484932358c94b52459d186d18d5ed", "score": "0.0", "text": "function renderTopResult(session, args_index, args_values, args_topcount) {\n var TrueFlag = -1;\n var renderOnce = (args_topcount * 2) + 1;\n if (args_index == renderOnce) {\n TrueFlag = 1;\n }\n else {\n TrueFlag = 0;\n }\n if (TrueFlag == 1) {\n if (args_topcount == 2) {\n var QuestOne = args_values[1];\n var AnsOne = args_values[2];\n var QuesTwo = args_values[3];\n var AnsTwo = args_values[4];\n\n var BaseHtml = '<table style=\"padding:10px;border:1px solid black;\">';\n\n var FirstHtml = \"<tr> <td>\" + QuestOne + \"</td> <td>\" + AnsOne + \"</td> </tr>\";\n var SecondHtml = \"<tr> <td>\" + QuesTwo + \"</td> <td>\" + AnsTwo + \"</td> </tr> </table>\";\n var HtmlTable = BaseHtml + FirstHtml + SecondHtml;\n session.send(HtmlTable);\n }\n else if (args_topcount == 3) {\n var QuestOne_topThree = args_values[1];\n var AnsOne_topThree = args_values[2];\n var QuesTwo_topThree = args_values[3];\n var AnsTwo_topThree = args_values[4];\n var QuesThree_topThree = args_values[5];\n var AnsThree_topThree = args_values[6];\n\n var BaseHtml_topThree = '<table style=\"padding:10px;border:1px solid black;\">';\n\n var FirstHtml_topThree = \"<tr> <td>\" + QuestOne_topThree + \"</td> <td>\" + AnsOne_topThree + \"</td> </tr>\";\n var SecondHtml_topThree = \"<tr> <td>\" + QuesTwo_topThree + \"</td> <td>\" + AnsTwo_topThree + \"</td> </tr>\";\n var ThirdHtml_topThree = \"<tr> <td>\" + QuesThree_topThree + \"</td> <td>\" + AnsThree_topThree + \"</td> </tr> </table>\";\n var HtmlTable_topThree = BaseHtml_topThree + FirstHtml_topThree + SecondHtml_topThree + ThirdHtml_topThree;\n session.send(HtmlTable_topThree);\n }\n else if (args_topcount == 4) {\n var QuestOne_topFour = args_values[1];\n var AnsOne_topFour = args_values[2];\n var QuesTwo_topFour = args_values[3];\n var AnsTwo_topFour = args_values[4];\n var QuesThree_topFour = args_values[5];\n var AnsThree_topFour = args_values[6];\n var QuesFour_topFour = args_values[7];\n var AnsFour_topFour = args_values[8];\n\n var BaseHtml_topFour = '<table style=\"padding:10px;border:1px solid black;\">';\n\n var FirstHtml_topFour = \"<tr> <td>\" + QuestOne_topFour + \"</td> <td>\" + AnsOne_topFour + \"</td> </tr>\";\n var SecondHtml_topFour = \"<tr> <td>\" + QuesTwo_topFour + \"</td> <td>\" + AnsTwo_topFour + \"</td> </tr>\";\n var ThirdHtml_topFour = \"<tr> <td>\" + QuesThree_topFour + \"</td> <td>\" + AnsThree_topFour + \"</td> </tr>\";\n var FourthHtml_topFour = \"<tr> <td>\" + QuesFour_topFour + \"</td> <td>\" + AnsFour_topFour + \"</td> </tr> </table>\";\n var HtmlTable_topFour = BaseHtml_topFour + FirstHtml_topFour + SecondHtml_topFour + ThirdHtml_topFour + FourthHtml_topFour;\n session.send(HtmlTable_topFour);\n }\n else {\n session.send('Please ask top 2 or top 3 or top 4!')\n }\n }\n}", "title": "" } ]
[ { "docid": "b583c788829a1f5e3a74956d187864aa", "score": "0.69021577", "text": "displayValue () { return this.variant.displayValue(this.value) }", "title": "" }, { "docid": "5aeaa58758c63189c5074939f35ed758", "score": "0.6740952", "text": "getGlobalDisplayValue() {}", "title": "" }, { "docid": "04ea77b55b6514905d5f60ea15bacd82", "score": "0.67011297", "text": "render() {\n\t\treturn (\n\t\t\t<div className=\"Generic-Value\">\n\t\t\t\t{this.getFormattedValue()} <b>{this.getUnits()}</b>\n\t\t\t</div>\n\t\t);\n\t}", "title": "" }, { "docid": "d03ee86003063c8013c28ea747b648dc", "score": "0.6521503", "text": "function TileValue(props){\n if(props.isDisplayed){\n return (props.tileValue);\n }\n return ('');\n}", "title": "" }, { "docid": "f9d45aa60fdc931a6f2187db5af6a1e8", "score": "0.64024633", "text": "@readOnly\n @computed('lastValue', 'value')\n renderValue (lastValue, value) {\n if (typeOf(value) === 'object') {\n return JSON.stringify(value, null, 2) || lastValue\n }\n\n return value || lastValue\n }", "title": "" }, { "docid": "0d8f2479aa4ad1db933dd19a1242f138", "score": "0.6394084", "text": "renderDisplayWeights() {\r\n const { metric } = this.props;\r\n const displayData = this.getDisplayData();\r\n\r\n return (\r\n // Reverse the entries for display purposes (most recent entry at top of list)\r\n Object.keys(displayData).reverse().map(key => <CardSection key={key}>\r\n <Text style={styles.displayDataText}>{key}\r\n : {this.round(displayData[key][metric], 2)}{metric}</Text>\r\n </CardSection>));\r\n }", "title": "" }, { "docid": "0336a3519aec9db6bc950c82846266d1", "score": "0.63179165", "text": "function handleDisplay(value) {\n if (displayValue === null) {\n text.textContent += value.key;\n } else {\n text.textContent = total+=value.key;\n }\n}", "title": "" }, { "docid": "5b8890a385f3b67bbf17d63ff8ac0778", "score": "0.6165291", "text": "get displayValue() {\n if (this.displayWith) {\n // Value is never null but since setters and getters cannot have\n // different types, the value getter is also typed to return null.\n return this.displayWith(this.value);\n }\n // Note that this could be improved further by rounding something like 0.999 to 1 or\n // 0.899 to 0.9, however it is very performance sensitive, because it gets called on\n // every change detection cycle.\n if (this._roundToDecimal && this.value && this.value % 1 !== 0) {\n return this.value.toFixed(this._roundToDecimal);\n }\n return this.value || 0;\n }", "title": "" }, { "docid": "87cd4f90882b3c128c4967c1ab9d8aed", "score": "0.6154336", "text": "$displayValue( value ) { return value.toString(); }", "title": "" }, { "docid": "3de8425958f7c34f984dfc966f45812d", "score": "0.6098013", "text": "render() {\n return this.props.value ? (\n\n <div className=\"field numeric\">\n <span className=\"field\">{this.props.field}</span>:{' '}\n <span className=\"value\">{this.props.value.toLocaleString()}</span>\n </div>\n\n ) : null;\n }", "title": "" }, { "docid": "08db5cfe764ee65a443b568de96ff07f", "score": "0.6070244", "text": "defaultRenderer({\n value\n }) {\n return value ? this.formatValue(value) : '';\n }", "title": "" }, { "docid": "08db5cfe764ee65a443b568de96ff07f", "score": "0.6070244", "text": "defaultRenderer({\n value\n }) {\n return value ? this.formatValue(value) : '';\n }", "title": "" }, { "docid": "2526114272060e158c212f11cbfb7b46", "score": "0.6060339", "text": "function drawValueScreen\n (result) {\n let drawPage = function () {\n clearScreen();\n let fontSize = g.getHeight() / 3;\n g.setFontVector(fontSize);\n\n // Reduce the font size until both the value and unit fit on the screen\n while (g.stringWidth(result.value) > g.getWidth() - 10 || g.getFontHeight() > g.getHeight() / 2) {\n fontSize--;\n g.setFontVector(fontSize);\n }\n\n let valueY = yCenter - g.getFontHeight() / 2;\n let unitY = yCenter + g.getFontHeight() / 2;\n let valueWidth = g.stringWidth(result.value);\n let unitWidth = g.stringWidth(result.unit);\n let valueX = (g.getWidth() - valueWidth) / 2;\n let unitX = (g.getWidth() - unitWidth) / 2;\n\n g.drawString(result.value, valueX, valueY);\n g.drawString(result.unit, unitX, unitY);\n g.flip();\n };\n\n // Shows the back button on the value screen\n return function () {\n clearScreen();\n let valueMenu = {\n '': { 'title': 'Results' },\n '< Back': function () {\n E.showMenu(resultsMenu);\n }\n };\n E.showMenu(valueMenu);\n drawPage();\n };\n }", "title": "" }, { "docid": "08db782903005c07b9c7db1927d206f8", "score": "0.6036271", "text": "render() {\n\t\treturn html`\n\t\t\t<span>\n\t\t\t\t<span class=\"display-label\">${this.label}</span>:\n\t\t\t\t<span class=\"display-value\">${this.value}</span>\n\t\t\t</span>\n\t\t`;\n\t}", "title": "" }, { "docid": "dac3480094940460552fdf329f042f65", "score": "0.600593", "text": "function DisplayStat(props) {\n const background = {background:props.color}\n return(\n <h3 \n style={background} \n className = 'displayStatContainer'\n > \n\n {props.text}\n <br/>\n {props.value}\n\n </h3>);\n}", "title": "" }, { "docid": "53e36b2109288f138db8346e4a0a9912", "score": "0.60050076", "text": "function displayValues(val){\n\t// Remove previous buttons and inspectors\n\t$(\".inspector, .inspector_img, .inspector_br, .inspector_lp\").remove(); \n\n\t// Display the inspector for each value to display\n\tfor(var key in val){\n\t\t// console.log($(\".ace_gutter-cell:eq(32)\").html());\n\t\t// Get the position\n\t\tvar xpos = $(\".ace_gutter-cell:eq(\"+key+\")\").position().top;\n\n\t\tif (val[key][2] == \"branch\") displayBranch(val[key], key, xpos);\n\t\telse if (val[key][2] == \"loop\") displayLoop(val[key], key, xpos);\n\t\telse displayVariableValues(val[key], key, xpos);\n\t\t\n }\n}", "title": "" }, { "docid": "7cc1fc9b70cb5ccc0a4c5c50d6f2f4a1", "score": "0.59952146", "text": "defaultRenderer({\n value = 0\n }) {\n if (this.unit) {\n return `${value}${this.unit}`;\n }\n\n return value;\n }", "title": "" }, { "docid": "f0bee9b88ca5b0eee2a714afc3bf7abd", "score": "0.5980492", "text": "getDisplayValue() {\n return this.get('value');\n }", "title": "" }, { "docid": "c9815b553e86202411a89d895ed3c590", "score": "0.59658647", "text": "maximumDisplayValue () { return this.maximumValue().toString() }", "title": "" }, { "docid": "139e873235260cf6d45e377823090b4b", "score": "0.5919302", "text": "displayString () { return this.variant.displayString(this.value) }", "title": "" }, { "docid": "590c290ab59b1f8ed358818dbbf8bf62", "score": "0.5890278", "text": "render() {\n const currScore = binarySearchLower(this.props.scoreData, this.props.currTime, 0, this.props.scoreData.length-1);\n return (\n <Group>\n <Text\n x={-64 * this.props.windowScale}\n y={-48 * this.props.windowScale}\n text={'Score: ' + Math.floor(currScore[1])}\n fontSize={18 * this.props.windowScale}\n />\n <Text\n x={-64 * this.props.windowScale}\n y={-28 * this.props.windowScale}\n text={'Combo: ' + currScore[2]}\n fontSize={18 * this.props.windowScale}\n />\n </Group>\n )\n }", "title": "" }, { "docid": "6ec9d1e68f9fe38d8cfe39b8960a8d86", "score": "0.5875023", "text": "_getCellValue() {\n //FIXME use the mixin here\n var recData = this.getRecordData(this.props.index,this.props.config);\n var renderedData = recData.formattedValue;\n var toRenderer;\n\n if ( recData.renderer ) {\n toRenderer = { \n value: recData.value,\n formattedValue: recData.formattedValue,\n record: recData.record,\n config: recData.config,\n id: recData.id,\n index: this.props.index\n\n };\n renderedData = recData.renderer(toRenderer);\n }\n\n return <div>{renderedData}</div>;\n }", "title": "" }, { "docid": "21a52f13dc883ad0a7673431edf7c43c", "score": "0.5874826", "text": "get displayValue(){return this._valueString;}", "title": "" }, { "docid": "5bedbf1d087387366f1d82694bf269db", "score": "0.5838416", "text": "defaultRenderer({ value = 0 }) {\n value = this.formatter.format(value);\n\n if (this.unit) {\n return `${value}${this.unit}`;\n }\n\n return value;\n }", "title": "" }, { "docid": "c2d7ef629588d64934e15189da31840b", "score": "0.58162636", "text": "userFormat(val) {\n return '<p>' + val + '</p>';\n }", "title": "" }, { "docid": "96692554fd907bbf864556c3a7ae1b0d", "score": "0.5787378", "text": "function getValue() {\n\n const{tile} = props;\n\n /* If tile hasn't been revealed... */\n if(!tile.revealed) {\n \n /* ... and doesn't have a flag show nothing */\n if(!tile.flag) {\n return null;\n }\n\n /* ... and DOES have a flag, display flag */\n\n return \"F\";\n }\n\n /* If the tile is a mine, show that its a mine */\n if(tile.mine) {\n return \"M\";\n }\n\n /* If tile is empty, show empty tile */\n if(tile.mineCount === 0) {\n return \"\";\n }\n\n /* Else show the tiles value */\n return tile.mineCount;\n }", "title": "" }, { "docid": "fe7c1d59b9e2dd2e4543891e9939240a", "score": "0.57645476", "text": "render() {\r\n Utils.colorText(this.value, this.posX, this.posY, this.size, 'center', this.color);\r\n }", "title": "" }, { "docid": "a1d0abe4871a1a55f2ce915872b63ea5", "score": "0.57390225", "text": "get top() {\n return this._values[0];\n }", "title": "" }, { "docid": "ccd7c94197975947a2e482c8f6f71d68", "score": "0.5715315", "text": "_getText(){\n let data = this.props.data;\n let index = this.props.index;\n let total = Math.ceil(this.props.data.reduce((n, d) => d.value + n, 0));\n if(data[index] !== undefined){\n let percent = numeral(data[index]['value'] / total ).format('0.00%');\n return (\n <View>\n <Text style={styles.bold15Text}>{percent}</Text>\n <Text style={[styles.bold15Text, {flex: 1}, {flexWrap: 'wrap'}]}>{data[index]['label']}</Text>\n <Text style={styles.light14Text}>{data[index]['value']+' crashes'}</Text>\n </View>\n )\n }\n return <Text>{'Value'}</Text>\n }", "title": "" }, { "docid": "d8d6494971865b47e36bba30dbd93345", "score": "0.57033426", "text": "renderer({\n value\n }) {\n value = value || 0;\n return {\n className: 'b-percent-bar-outer',\n children: [{\n tag: 'div',\n className: {\n 'b-percent-bar': 1,\n 'b-zero': value === 0,\n 'b-low': value < this.lowThreshold\n },\n style: {\n width: value + '%'\n },\n html: value + '%'\n }]\n };\n }", "title": "" }, { "docid": "18cc187cd201cdda742e183cd4070e9c", "score": "0.5688839", "text": "$_valueToDisplay(value) {\n let valueNumber = value.toFixed(this.digits);\n if (this.digits === 0 && valueNumber > 1000) {\n valueNumber /= 1000;\n valueNumber = valueNumber.toFixed(valueNumber < 10 ? 2 : 1) + \"k\";\n }\n return valueNumber + this.units;\n }", "title": "" }, { "docid": "0d6e0e272f0915930c90cff290d37e31", "score": "0.5680069", "text": "get rendering() {\n return this[renderingValue];\n }", "title": "" }, { "docid": "39d51b11a15bfab84d38b6f3018828d2", "score": "0.56687206", "text": "function render() {\n const lastResult = document.querySelector('.calculator__results--last');\n const currentResult = document.querySelector('.calculator__results--current');\n\n lastResult.innerHTML = prettifyDisplay(store.getState().last, true);\n currentResult.innerHTML = prettifyDisplay(store.getState().current, false);\n }", "title": "" }, { "docid": "e672167bae60599ee5ef145481fcb236", "score": "0.5664274", "text": "function renderStats(error, loading, value) {\n if (error) {\n return error.detail;\n } else if (loading) {\n return <i className=\"fa fa-spinner fa-spin fa-fw\" />;\n }\n return value && value.toLocaleString();\n}", "title": "" }, { "docid": "73184a7ee257147d7b5e26625acc611c", "score": "0.56585187", "text": "function getHighTemp()\n{\n return \"<span style='text-align:center'>High 11&deg;C </span>\";\n}", "title": "" }, { "docid": "4fb10153899de3c15696e63abcff47ff", "score": "0.5647475", "text": "function displayRender(label) {\n return label[label.length - 1];\n}", "title": "" }, { "docid": "e5dc9ae2368cbb491c08242bf4bcbce7", "score": "0.5628041", "text": "renderMaxThreshold(qf) {\n\n }", "title": "" }, { "docid": "81ac5521f57030992ca99a5e6f0f92d2", "score": "0.5617022", "text": "function displayRender(label) {\n return label[label.length - 1];\n}", "title": "" }, { "docid": "1973a33d6d0a1e374f86c3126d83b052", "score": "0.5616375", "text": "function renderTop() {\n var $myList = $('<ul>');\n var itemToAdd = displayStack.pop();\n for (symbolType in itemToAdd) {\n $myList.append($('<li>'+itemToAdd[symbolType]+'</li>'));\n }\n $myList.insertBefore('#vis-clear'); \n}", "title": "" }, { "docid": "ef66b97fb1b31c996fbc89d191cfcc2f", "score": "0.5605303", "text": "render() {\n if (!this.model) {\n return null;\n }\n let text;\n if (this.model.memoryLimit === null) {\n text = `Mem: ${this.model.currentMemory.toFixed(memoryUsage_Private.DECIMAL_PLACES)} ${this.model.units}`;\n }\n else {\n text = `Mem: ${this.model.currentMemory.toFixed(memoryUsage_Private.DECIMAL_PLACES)} / ${this.model.memoryLimit.toFixed(memoryUsage_Private.DECIMAL_PLACES)} ${this.model.units}`;\n }\n return react_default.a.createElement(TextItem, { title: \"Current memory usage\", source: text });\n }", "title": "" }, { "docid": "8be946e56a7edb32cb6a34374f0105f5", "score": "0.5599015", "text": "_replaceDisplay(value) {}", "title": "" }, { "docid": "54e9f459853dd660b9fb20c0ab890861", "score": "0.5567598", "text": "renderer({\n value\n }) {\n let html = `<div class=\"b-rating-cell-inner ${!this.editable ? 'b-not-editable' : ''}\">`;\n\n for (let i = 0; i < this.max; i++) {\n let filled = i < value;\n html += `<i class=\"b-rating-icon ${filled ? 'b-filled ' + this.filledIcon : 'b-empty ' + this.emptyIcon}\"></i>`;\n }\n\n html += '</div>';\n return html;\n }", "title": "" }, { "docid": "7e54b276b2c0d3abe85fe4ea697a0a1a", "score": "0.55649227", "text": "function render() {\n $('.display').text(calcDisplay);\n}", "title": "" }, { "docid": "c7dce9a5a550c4ccfbca2d9f0af51c06", "score": "0.55621064", "text": "display() {\n let runner = this.head;\n let vals = \"\";\n \n while (runner) {\n vals += `${runner.value}${runner.next ? \", \" : \"\"}`;\n runner = runner.next;\n }\n console.log(vals);\n return vals;\n }", "title": "" }, { "docid": "527c5968c8f74a3c34701b75a0dbe0f4", "score": "0.55551016", "text": "function render() {\n var state = store.getState();\n document.getElementById('value').innerHTML = state.count;\n document.getElementById('valSum').innerHTML = state.sum;\n}", "title": "" }, { "docid": "79b3f12e8905cc0f45d564424a3a2e02", "score": "0.5549954", "text": "render() {\n return (\n <div>\n <h2> Best match: {this.props.bestMatch} </h2>\n <h2> Number of generations: {this.props.numberGen} </h2>\n <h2> Average fitness: {this.props.averageFitness.toPrecision(2)} </h2>\n </div>\n );\n }", "title": "" }, { "docid": "9bd5347da5d0af0371c7904940068e0d", "score": "0.5549249", "text": "function render() {\n const lastResult = document.querySelector('.last__result');\n const currentResult = document.querySelector('.current__result');\n\n lastResult.innerHTML = prettifyDisplay(store.getState().last, true);\n currentResult.innerHTML = prettifyDisplay(store.getState().current, false);\n }", "title": "" }, { "docid": "5d21d2c7aca6c31bfa8f99ad521ba317", "score": "0.5544321", "text": "function returnLabelsNormal(value) {\n\n if (value === 0){ // enter your lowest slider value here\n return \"nicht wichtig\";\n }else if (value == 100){// enter your highest slider value here\n return \"sehr wichtig\";\n } else\n return value;\n }", "title": "" }, { "docid": "24a97f4cf4ea799c48deca276cc32bf1", "score": "0.55254453", "text": "function Head(value) {\n //return colors.inverse(colors.blackBG(' ' + colors.blue(colors.bold(value)) + ' '));\n return colors.bgBlue(' ' + colors.white(colors.bold(value)) + ' ');\n}", "title": "" }, { "docid": "25f80e66b9c140dd9e73470fd7107c9f", "score": "0.5518237", "text": "function renderer_qty_on_hand(value, metadata, record) {\n var data = record.getData();\n var value = parseFloat(value);\n var reorder_level = parseFloat(data.i_reorder_level);\n var number = value % 1 == 0 ? Ext.util.Format.number(value, '0') : Ext.util.Format.number(value, '0.00');\n if(value > reorder_level) {\n return '<span class=\"text-success\">' + number + '</span>';\n } else if(value <= reorder_level) {\n if(value == reorder_level) {\n return '<span class=\"text-warning\">' + number + '</span>';\n } else {\n return '<span class=\"text-error\">' + number + '</span>';\n }\n }\n}", "title": "" }, { "docid": "4500ce0d4ff94d5e36df331a0f34d932", "score": "0.55078334", "text": "function renderStats(error: ?number, loading: boolean, value: ?number){\n if(error){\n return \"error loading stats\"\n } else if(loading){\n return <i className=\"fa fa-spinner fa-spin fa-fw\"></i>\n }\n return value && value.toLocaleString()\n}", "title": "" }, { "docid": "c106fea03e0e64f1e914e59ae78d7838", "score": "0.54956603", "text": "function renderPostPopularityChart(){\n\n }", "title": "" }, { "docid": "e20c885627f06d544d217362c8bec027", "score": "0.5489003", "text": "function renderTooltip({ payload }) {\n if (!payload[0]) {\n return;\n }\n\n return <span>{`$${payload[0].value.toFixed(2)}`}</span>;\n}", "title": "" }, { "docid": "3f06ba4d2bba94bd884e88b3ece43947", "score": "0.5454823", "text": "function ResultPane({resultValue}) {\n if (isNaN(parseFloat(resultValue))) {\n return null;\n }\n\n const value = resultValue;\n const amount = value === 1 ? \"point\" : \"points\";\n let bs_style = \"success\";\n if (value > 5) {\n bs_style = \"warning\";\n }\n if (value > 10) {\n bs_style = \"danger\";\n }\n\n return (\n <Col xsOffset={4} className=\"popper\">\n <h1>\n <Label bsStyle={bs_style}>\n {value} {amount}\n </Label>\n </h1>\n </Col>\n );\n}", "title": "" }, { "docid": "e1dcb4423ec76b6723cfebf90b8c6094", "score": "0.54516953", "text": "function formatValue(value, valueToHtml, maxDepth) {\n if (Object(vega_util__WEBPACK_IMPORTED_MODULE_0__[\"isArray\"])(value)) {\n return `[${value.map(v => valueToHtml(Object(vega_util__WEBPACK_IMPORTED_MODULE_0__[\"isString\"])(v) ? v : stringify(v, maxDepth))).join(', ')}]`;\n }\n if (Object(vega_util__WEBPACK_IMPORTED_MODULE_0__[\"isObject\"])(value)) {\n let content = '';\n const _a = value, { title } = _a, rest = __rest(_a, [\"title\"]);\n if (title) {\n content += `<h2>${valueToHtml(title)}</h2>`;\n }\n const keys = Object.keys(rest);\n if (keys.length > 0) {\n content += '<table>';\n for (const key of keys) {\n let val = rest[key];\n if (Object(vega_util__WEBPACK_IMPORTED_MODULE_0__[\"isObject\"])(val)) {\n val = stringify(val, maxDepth);\n }\n content += `<tr><td class=\"key\">${valueToHtml(key)}:</td><td class=\"value\">${valueToHtml(val)}</td></tr>`;\n }\n content += `</table>`;\n }\n return content || '{}'; // show empty object if there are no properties\n }\n return valueToHtml(value);\n}", "title": "" }, { "docid": "1096b35e1592cb9c820a1d72122e678b", "score": "0.54457355", "text": "getLabel() {\n return this.viewValue;\n }", "title": "" }, { "docid": "1096b35e1592cb9c820a1d72122e678b", "score": "0.54457355", "text": "getLabel() {\n return this.viewValue;\n }", "title": "" }, { "docid": "1096b35e1592cb9c820a1d72122e678b", "score": "0.54457355", "text": "getLabel() {\n return this.viewValue;\n }", "title": "" }, { "docid": "1096b35e1592cb9c820a1d72122e678b", "score": "0.54457355", "text": "getLabel() {\n return this.viewValue;\n }", "title": "" }, { "docid": "e2ce7172d4ccb7ccf919b560499e0691", "score": "0.54398036", "text": "display(visStyle,c, type = 'co2'){\n if(this.value>0){\n\n if (type === 'co2') {\n this.updateValue();\n }\n\n if(visStyle){\n //drawLineFromVector(this.loc3D, this.loc3Dend, c, 1);\n drawCylinder(this.loc3D, this.loc3Dend, c, map(this.value, 0, 255, 2, 5));\n //drawLine(this.loc3D.x, this.loc3D.y, this.loc3D.z, this.loc3Dend.x, this.loc3Dend.y, this.loc3Dend.z, c);\n }else{\n strokeWeight(pointWeight)\n stroke(c)\n point(-this.loc3D.x,this.loc3D.y,this.loc3D.z)\n }\n }else{\n // do something else when the value (brightness is 0 or black or no information)\n }\n }", "title": "" }, { "docid": "1acf0bb4b2faaf39e0dee07bc520a8cf", "score": "0.5425059", "text": "function renderResults(){\n\tlet houseArray = createTotalScoresArray();\n\tlet houseName = highestHouse(houseArray);\n\treturn getCharacters(houseName);\n}", "title": "" }, { "docid": "ef94d6dd6775324f44ef89f74f5d73f2", "score": "0.5424351", "text": "function displayHighScore(){\n $('#high-score').text(UI.highScore);\n }", "title": "" }, { "docid": "63a617ee93f1cb284be0d95a8f656a7f", "score": "0.54235774", "text": "toString() {\n // Adding space at the end if there is content to make concatenation code simpler in renderers.\n return this.length ? `${this.value} ` : '';\n }", "title": "" }, { "docid": "2c318897eb304a8c602c404a1aff70d7", "score": "0.54113644", "text": "get displayValueClassName(){return this._valueClassName;}", "title": "" }, { "docid": "ee4f272758e01e93785188428237182a", "score": "0.5411188", "text": "getValue() {\n const { data } = this.props;\n\n if (!data.isRevealed) {\n return null;\n }\n if (data.isRevealed) {\n if (data.isFlagged) {\n return \"🚩\";\n }\n if (data.isMine) {\n return \"💣\";\n }\n if (data.neighbour === 0) {\n return null;\n }\n return data.neighbour;\n }\n }", "title": "" }, { "docid": "1a8ef8bb14e9a02c083e6e5844728314", "score": "0.54075575", "text": "get valueText() {\n var textObject = this.childrenMap.value;\n if (textObject === undefined) {\n return '';\n }\n return textObject.text;\n }", "title": "" }, { "docid": "6245a0afbc64e5fa977c86c91a487c14", "score": "0.54024494", "text": "function renderGraph2(value, p, record) {\r\n\t\tif (!record.data.graph2Exist) {\r\n\t\t\tif (record.data.graph2Path) {\r\n\t\t\t\treturn \"<div style='white-space:normal !important;word-wrap: break-word;'><h4>Graph not found:<br>\" + record.data.graph2Path + \"</h4></div>\";\r\n\t\t\t} else {\r\n\t\t\t\treturn \"\";\r\n\t\t\t}\r\n\t\t} else {\r\n\t\t\treturn MXUI.getGraphByPath(record.data.graph2Path);\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "64b75c84fa6cff1c86298d0c4d6df04d", "score": "0.539952", "text": "display(){}", "title": "" }, { "docid": "a40e9a98f58b9e85db5ee7a937a4e99c", "score": "0.53946537", "text": "function getLowTemp()\n{\n return \"<span style='text-align:center'>Low 6&deg;C </span>\";\n}", "title": "" }, { "docid": "c0f346f6fd77314e011bb242ce4ff259", "score": "0.5377133", "text": "render() {\n\n//DESTRUCTURE REDUCERS TO ASSIGN VARIABLES\n const {\n cppIncome : {financialValue: cppIncome }, //Grabs and assigns variable names from reducer\n oasIncome : {financialValue: oasIncome },\n rrsp: {financialValue: rrsp },\n tfsa: {financialValue: tfsa },\n nonRegistered: {financialValue: nonRegistered },\n } = this.props.income_reducer[75] \n\n\n\nreturn (\n <HeaderValuesWrapper onMouseMove={(e) => this.handleMouseMove(e)}>\n <Left >\n {/* Displays the total shortfall, the value determines the color of the number negative for red or positive for lightGrey */}\n <h1>\n Lifetime Income Chart BUILD 2\n </h1>\n </Left>\n <Right>\n <h2>Optimized Retirement Income Plan</h2>\n <PensionIncomeWrapper onMouseMove={(e) => this.handleMouseMove(e) }>\n <CPPSummary>\n {`${(cppIncome)/1000}k`} \n <h4>CPP</h4>\n <Circle color={\"#F29278\"}/>\n </CPPSummary>\n <OASSummary >\n {`${(oasIncome)/1000}k`}\n <h4 >OAS</h4>\n <Circle color={\"#7DA8B8\"}/>\n </OASSummary>\n <Vr/>\n <RRIFSummary>\n {`${(rrsp)/1000}k`}\n <h4 >RRSP</h4>\n <Circle color={\"#B0CFE3\"}/>\n </RRIFSummary>\n <NRegSummary>\n {`${tfsa/1000}k`}\n <h4>TFSA</h4>\n <Circle color={\"#81CCAF\"}/>\n\n </NRegSummary>\n {\n nonRegistered > 1000 ? \n <NRegSummary>\n {`${nonRegistered/1000}k`}\n <h4>N-Reg</h4>\n <Circle color={\"#B9B0A2\"}/>\n\n </NRegSummary>\n : null\n }\n\n </PensionIncomeWrapper>\n <Summary>\n {`${(cppIncome + oasIncome + rrsp + tfsa + nonRegistered)/1000}k`}\n <h4>Total</h4>\n </Summary>\n </Right>\n \n </HeaderValuesWrapper>\n )\n }", "title": "" }, { "docid": "ee9f20ee107b39c5da21447cc18049aa", "score": "0.5373887", "text": "render() {\n return html`\n <label>Date:</label>\n <p>${this.date}</p><br>\n <label>Open:</label>\n <!--Coverting the number to formatted string, if application grows we can use a common function to return the formatted string-->\n <p>${this.open.toLocaleString('en', {useGrouping:true})}</p><br>\n <label>High:</label>\n <p>${this.high.toLocaleString('en', {useGrouping:true})}</p><br>\n <label>Low:</label>\n <p>${this.low.toLocaleString('en', {useGrouping:true})}</p><br>\n <label>Close:</label>\n <p>${this.close.toLocaleString('en', {useGrouping:true})}</p><br>\n <label>Volume:</label>\n <p>${this.volume.toLocaleString('en', {useGrouping:true})}</p><br>\n `;\n }", "title": "" }, { "docid": "436caf1f74daaf4fa2707740b85ce500", "score": "0.5373774", "text": "_initDisplay(value) {}", "title": "" }, { "docid": "ce62ca0f6ef0b79cb9912cf202f71502", "score": "0.5373486", "text": "function toString(row, index)\n {\n let value = row[tableJson.title[index]];\n switch(index)\n {\n case 0:\n case 1:\n case 5:\n case 6:\n return value;\n case 2:\n return (value.map((row, index) =>\n {\n return (\n <div key={index}>\n {\"id :\"+row[\"id\"]+\" | \"+row[\"proportion\"]+\"%\"}\n </div>\n )\n }));\n case 3:\n return (value.map((row, index) =>\n {\n if (index < 50)\n {\n return (\n <div key={index}>\n {row[\"type\"]+(row[\"value\"]!==\"\"?(\" : \"+row[\"value\"]):\"\")}{(row[\"min\"]!==0||row[\"max\"]!==0)?(\" | min : \"+row[\"min\"]+\" - max : \"+row[\"max\"]):\"\"}\n </div>\n )\n } else if (index === 50) \n {\n return (\n <div key={index}>\n {\"... (View more on Detail page)\"}\n </div>\n )\n } else \n {\n return \"\"\n }\n \n }));\n case 4:\n return (value.map((row, index) =>\n {\n return (\n <div key={index}>\n {row}\n </div>\n )\n }));\n default:\n return \"Error\"+index;\n }\n }", "title": "" }, { "docid": "d7c557cd5c8067cc856be4a0c23d1e02", "score": "0.5367786", "text": "function trackFormatter(value, row) {\n\tif (value) return '<i class=\"fa fa-plane\"></i> ' + value;\n}", "title": "" }, { "docid": "ac78ccea459f007ea1ea8f4643d7fa64", "score": "0.5365412", "text": "defaultDisplayString () { return this.displayString(this._value._default) }", "title": "" }, { "docid": "1339614f96130526d85f36bbc8ca0d49", "score": "0.5350828", "text": "function showValue(number) {\n screen.value += number;\n }", "title": "" }, { "docid": "bcc19441d4c6341494a14843ad51f0c8", "score": "0.5350017", "text": "renderBoardHeading(i) {\n return <BoardHeading value={i} />;\n }", "title": "" }, { "docid": "5c5b6770b7ae708027aac1942b8ca3e0", "score": "0.5346387", "text": "displayUnits () { return '' }", "title": "" }, { "docid": "9eca1377b463a46e38e3ce3ee635147f", "score": "0.5346199", "text": "function change_renderer(value, metaData, record, rowIndex, colIndex, store) {\n\tif(value > 0){\n\t\tmetaData.tdCls = 'positive_change';\n\t\treturn \"+\" + value + \"%\";\n\t}else if(value < 0){\n\t\tmetaData.tdCls = 'negative_change';\n\t\treturn value + \"%\";\n\t}else if(value == 0){\n\t\tmetaData.tdCls = 'no_change';\n\t\treturn value + \"%\";\n\t}\n\treturn value;\n}", "title": "" }, { "docid": "48f6e90882763e1682575999cb1f22c5", "score": "0.5343781", "text": "render() {\n alert(\"If you are feeling a 8 or higher in your perception of your intensity, please see the Crisis Resources page for more support. Be well\")\n return (\n <div>\n <h3> Take just a moment to rate the following items on a scale of 1 to 10. 1 is very little intensity, and 10 being the most intense it has ever felt to you:\n \n <div>\n 1. On a scale of 1 to 10 where is your anger?\n 2. On a scale of 1 to 10 where is your depression?\n 3. On a scale of 1 to 10 where is your anxiety?\n </div>\n </h3>\n </div>\n )\n\n }", "title": "" }, { "docid": "cd181ba235d1fab0d0d55c5018f900ee", "score": "0.5341477", "text": "function displayRenderer(item, attrs) {\n const { descriptionProp } = attrs;\n if (descriptionProp && item[descriptionProp]) {\n return mithril__WEBPACK_IMPORTED_MODULE_0___default()(\"span\", mithril__WEBPACK_IMPORTED_MODULE_0___default()(\"span.value\", item[attrs.valueProp]), mithril__WEBPACK_IMPORTED_MODULE_0___default()(\"span.description\", item[descriptionProp]));\n }\n return mithril__WEBPACK_IMPORTED_MODULE_0___default()(\"span.value\", item[attrs.valueProp]);\n}", "title": "" }, { "docid": "efacd9e7658b1abb40792baa3c22cea1", "score": "0.53411335", "text": "function renderString(val){return val==null?'':(typeof val==='undefined'?'undefined':_typeof(val))==='object'?JSON.stringify(val,null,2):String(val);}", "title": "" }, { "docid": "840f720b9c29c5b1a8101b71830c75fd", "score": "0.53397876", "text": "get top() { return this.y}", "title": "" }, { "docid": "4c08f951beb7efd8b21f187f074ee8e6", "score": "0.5338019", "text": "function innerCellRenderer(params) {\n let str;\n if (params.node.group) {\n str = `${params.data.dim}: <strong>${params.data.toString()}</strong>`;\n } else {\n str = `${params.data.dim}: <strong>${params.data.toString()}</strong>`;\n }\n return str;\n }", "title": "" }, { "docid": "030065029d05ba5851ba2f1614a35f3c", "score": "0.53348076", "text": "function show(data){\n return \"<h4>Current Temperature: \"+ data.main.temp +\"°C</h4>\";\n}", "title": "" }, { "docid": "e8b5f303fe2d1b4e797a3d1483dceb7b", "score": "0.53326917", "text": "function displayOutput(){\n\t\t$(\"#number-least\").append(numLeast);\n\t\t$(\"#number-greatest\").append(numGreatest);\n\t\t$(\"#number-mean\").append(numMean);\n\t\t$(\"#number-sum\").append(numSum);\n\t\t$(\"#number-product\").append(numProduct);\n\t\tgameOver=true;\n\t}", "title": "" }, { "docid": "8825c330435e517c9d559fd4e22f9cd0", "score": "0.53305143", "text": "getRowOperator() {\n let variables;\n if (this.props.type === 'between') {\n variables = this.props.dataStore.variableStores.between.getRelatedVariables('event');\n } else {\n variables = this.props.dataStore.variableStores.sample\n .currentVariables.map((id) => this.props.dataStore.variableStores.sample\n .getById(id));\n }\n return variables.map((variable, i) => {\n let lineHeight;\n let fontWeight;\n if (variable.id === this.props.dataStore.globalPrimary) {\n lineHeight = this.props.visStore.secondaryHeight;\n fontWeight = 'bold';\n } else {\n lineHeight = this.props.visStore.secondaryHeight;\n fontWeight = 'normal';\n }\n const transform = `translate(0,${i * lineHeight})`;\n let fontSize = 10;\n if (lineHeight < fontSize) {\n fontSize = Math.round(lineHeight);\n }\n return (\n <g key={variable.id} className=\"clickable\" transform={transform}>\n {this.getRowLabel(variable, fontWeight, fontSize)}\n </g>\n );\n });\n }", "title": "" }, { "docid": "d11f89afe32d395de7c0784f08298ec8", "score": "0.53263795", "text": "function showFullToolTip(row, size, value) {\n // console.log(row, size, value)\n if (!d.getValue(row,1)) {\n return '<div style=\"background:#000; padding:10px; border-style:solid; color:#fff\">' +\n '<span><b>Strain: ' + d.getValue(row, 0).split(\" \")[0] +'</b></span><br>'+\n 'mice: '+d.getValue(row,2)+'</div> ';\n } else if ([\"single-f\", \"single-m\"].indexOf(d.getValue(row,0)) !== -1 ) {\n return '<div style=\"background:#000; padding:10px; border-style:solid; color:#fff\">' +\n '<span><b>Cage type: ' + d.getValue(row, 0).split(\" \")[0] +'</b></span><br>'+\n 'mice: '+d.getValue(row,2)+'</div> ';\n } else if ([\"single-f\", \"single-m\"].indexOf(d.getValue(row,1)) !== -1 ) {\n var ageRange = d.getValue(row, 0).split(\" \")\n var cat = ageRange.shift();\n var ageStr = ageRange.join(\" \");\n return '<div style=\"background:#000; padding:10px; border-style:solid; color:#fff\">' +\n '<span><b>Age of mice: ' + cat + ' months</b></span><br>'+\n 'mice: '+d.getValue(row,2)+'</div> ';\n } else {\n var cageNum = d.getValue(row, 0).split(\"|\")[0];\n var ageRange = d.getValue(row, 0).split(\" \")\n var cat = ageRange.shift();\n var ageStr = ageRange.join(\" \").replace(\"(\",\"\").replace(\")\",\"\");\n return '<div style=\"background:#000; padding:10px; border-style:solid; color:#fff\">' +\n '<span><b>Cage number: ' + cageNum +'</b></span><br>'+\n 'Mice in age range: '+d.getValue(row,2)+'</div> ';\n }\n }", "title": "" }, { "docid": "f63805668b1ab81e73fb8e35dd85fe68", "score": "0.53248364", "text": "function Output(props) {\n return <OutputContainer>{formatOutput(props.value)}</OutputContainer>;\n}", "title": "" }, { "docid": "2a269a7d660beaff3cd800676b2a63d1", "score": "0.5324329", "text": "render(){\n const { dataValues , title} = this.props\n return(\n <div className=\"app-print\">\n <a style={{color: title[1], textAlign: 'center', display: 'block', fontSize: '2.5vw', fontWeight: '800'}}>{title[0]}</a>\n <table style={{backgroundColor: title[2],fontSize: '2vw'}}>\n <thead></thead>\n <tbody>\n {dataValues.map(el => {\n return <tr key={el[0]}>\n <th style={{color: title[3], paddingRight: '1vw'}}>\n {el[0]}\n </th>\n {Array.from({length: el[1]}, (x,i) => <td key={i} style={{backgroundColor: el[2]}}></td>)}\n <td style={{color: title[3]}}>{el[1]}</td>\n </tr>\n })}\n </tbody>\n <tfoot></tfoot> \n </table><br />\n </div>\n )\n }", "title": "" }, { "docid": "25e653df29bee54a561e65a41fa8ca68", "score": "0.5322937", "text": "function renderParameterValues(){\r\n\t\t\r\n\tvar settingEles = $(\".sideNavSetting\");\r\n\tfor (var i = 0; i < settingEles.length; i ++){\r\n\t\tvar ele = $(settingEles[i]);\r\n\t\tvar child = ele.children(\"input\");\r\n\t\t//console.log(child.val());\r\n\t\t//ele.attr(\"title\", roundToSF(parseFloat(child.val())));\r\n\t\tchild.next(\"span\").html(roundToSF(parseFloat(child.val())));\r\n\t\t\r\n\t}\r\n\t\r\n\t\r\n}", "title": "" }, { "docid": "019f6a7dbcf9dbbc32124b21e26a5e6c", "score": "0.5321936", "text": "function getDisplayValueFilter() {\n return myPortfolio.getValueFilter();\n}", "title": "" }, { "docid": "63fa2f60f516c0f6158f45d0b80d9aa6", "score": "0.53119624", "text": "function resultGetter() {\n return overlayModel.value;\n }", "title": "" }, { "docid": "f1b18a7ebeb1e09b56d6bbfbb5f63b97", "score": "0.53058946", "text": "function renderElement(forceValue) {\n // element.style.webkitTransform = 'translateX(-50%) translateY(-50%) scale(' + (1 + forceValue * 1.5) + ')';\n // background.style.webkitFilter = 'blur(' + forceValue * 30 + 'px)';\n \n forceValueOutput.innerHTML = 'Force: ' + forceValue.toFixed(4);\n}", "title": "" }, { "docid": "545079eebd41d3fa5046241b2956a694", "score": "0.5305858", "text": "render(){\n if (this.result >= 0){\n this.output.innerText = this.result;\n } else {\n this.output.innerText = \"\";\n }\n }", "title": "" }, { "docid": "8502768b2e8658170df738c57c01d12e", "score": "0.53053814", "text": "renderScore() {\n const score = document.getElementById('score');\n score.innerHTML = `$${this.score}`;\n }", "title": "" }, { "docid": "f373d1aaf88715331491a84563ecd1b4", "score": "0.5305175", "text": "_render({adjective, level}){\n return html`\n <p>This element is ${adjective} at an estimated level of ${level}.</p>\n `;\n }", "title": "" }, { "docid": "3796ca9f4fce58e7774eac646cf00433", "score": "0.5305142", "text": "renderSegments() {\n let {orgId, projectId, group, totalValues, topValues, tag} = this.props;\n\n let totalVisible = topValues.reduce((sum, value) => sum + value.count, 0);\n let hasOther = totalVisible < totalValues;\n let otherPct = percent(totalValues - totalVisible, totalValues);\n let otherPctLabel = Math.floor(otherPct);\n\n return (\n <div className=\"segments\">\n {topValues.map((value, index) => {\n const pct = percent(value.count, totalValues);\n const pctLabel = Math.floor(pct);\n const className = 'segment segment-' + index;\n\n const tooltipHtml =\n '<div class=\"truncate\">' +\n escape(deviceNameMapper(value.name || '', this.state.iOSDeviceList) || '') +\n '</div>' +\n pctLabel +\n '%';\n\n return (\n <Tooltip key={value.value} title={tooltipHtml} tooltipOptions={{html: true}}>\n <Link\n className={className}\n style={{width: pct + '%'}}\n to={`/${orgId}/${projectId}/issues/${group.id}/tags/${tag}/`}\n >\n <span className=\"tag-description\">\n <span className=\"tag-percentage\">{pctLabel}%</span>\n <span className=\"tag-label\">\n <DeviceName>{value.name}</DeviceName>\n </span>\n </span>\n </Link>\n </Tooltip>\n );\n })}\n {hasOther && (\n <Link\n key=\"other\"\n className=\"segment segment-9\"\n style={{width: otherPct + '%'}}\n to={`/${orgId}/${projectId}/issues/${this.props.group.id}/tags/${this.props\n .tag}/`}\n title={'Other<br/>' + otherPctLabel + '%'}\n >\n <span className=\"tag-description\">\n <span className=\"tag-percentage\">{otherPctLabel}%</span>\n <span className=\"tag-label\">{t('Other')}</span>\n </span>\n </Link>\n )}\n </div>\n );\n }", "title": "" }, { "docid": "ae2b8f3dabf4a031746d9916d7c26df4", "score": "0.53036803", "text": "tooltip_render(tooltip_data) {\n let text = \"<h2>\" + tooltip_data.state + \"</h2>\";\n text += \"Voter Shift: \";\n text += \"<ul>\"\n tooltip_data.result.forEach((row)=>{\n if(row[1]>0)\n text += \"<li class = \" + this.chooseClass(row[1])+ \">\" + row[0]+\":\\t\\t shift toward Republican \"+row[1]+\"%\" + \"</li>\"\n else if(row[1]<0)\n text += \"<li class = \" + this.chooseClass(row[1])+ \">\" + row[0]+\":\\t\\t shift toward Democrat \"+ (-1*row[1])+\"%\" + \"</li>\"\n else\n text += \"<li class = \" + this.chooseClass(row[1])+ \">\" + row[0]+\":\\t\\t no shift\" + \"</li>\"\n \n });\n text += \"</ul>\";\n\n return text;\n }", "title": "" }, { "docid": "3c6a6c195d87d40c25afb484aedccb4f", "score": "0.5302401", "text": "function numberRenderer(value) {\n // Create a link if we have a URL and number.\n if (URL && value) {\n return Ext.String.format(\n \"<a href='{0}/{1}' target='_blank'>{1}</a>\",\n URL, value);\n }\n\n // Just use the number if that's all we have.\n if (value) {\n return value;\n }\n\n return \"n/a\";\n }", "title": "" }, { "docid": "3ed3708c0304e18999b56f656500026b", "score": "0.52949286", "text": "function renderEHealth() {$('#eHealth').text(\"Health: \" + area[0].health);}", "title": "" } ]
72fd2548a98d83dd5c8a0a21d6cc4d89
return the current mapping of element paths > flex values
[ { "docid": "ef41b5796e2fd9113c324712b5cf0759", "score": "0.7604788", "text": "get flexMap () {\n const result = {}\n\n for (let path of this.paths) {\n const node = this._paths.get(path)\n if (node.flex == null) continue\n\n result[path] = node.flex\n }\n\n return result\n }", "title": "" } ]
[ { "docid": "30ae0a035b90ffb2dcdd9eb26da77857", "score": "0.59048855", "text": "function PathMap() {\n\n /**\n * Contains a map of path elements\n *\n * <h1>Path definition</h1>\n * A parameterized path is defined like this:\n * <pre>\n * 'GATEWAY_PARALLEL': {\n * d: 'm {mx},{my} {e.x0},0 0,{e.x1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} ' +\n '-{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z',\n * height: 17.5,\n * width: 17.5,\n * heightElements: [2.5, 7.5],\n * widthElements: [2.5, 7.5]\n * }\n * </pre>\n * <p>It's important to specify a correct <b>height and width</b> for the path as the scaling\n * is based on the ratio between the specified height and width in this object and the\n * height and width that is set as scale target (Note x,y coordinates will be scaled with\n * individual ratios).</p>\n * <p>The '<b>heightElements</b>' and '<b>widthElements</b>' array must contain the values that will be scaled.\n * The scaling is based on the computed ratios.\n * Coordinates on the y axis should be in the <b>heightElement</b>'s array, they will be scaled using\n * the computed ratio coefficient.\n * In the parameterized path the scaled values can be accessed through the 'e' object in {} brackets.\n * <ul>\n * <li>The values for the y axis can be accessed in the path string using {e.y0}, {e.y1}, ....</li>\n * <li>The values for the x axis can be accessed in the path string using {e.x0}, {e.x1}, ....</li>\n * </ul>\n * The numbers x0, x1 respectively y0, y1, ... map to the corresponding array index.\n * </p>\n m1,1\n l 0,55.3\n c 29.8,19.7 48.4,-4.2 67.2,-6.7\n c 12.2,-2.3 19.8,1.6 30.8,6.2\n l 0,-54.6\n z\n */\n this.pathMap = {\n 'KNOWLEDGE_SOURCE': {\n d: 'm {mx},{my} ' +\n 'l 0,{e.y0} ' +\n 'c {e.x0},{e.y1} {e.x1},-{e.y2} {e.x2},-{e.y3} ' +\n 'c {e.x3},-{e.y4} {e.x4},{e.y5} {e.x5},{e.y6} ' +\n 'l 0,-{e.y7}z',\n width: 100,\n height: 65,\n widthElements: [ 29.8, 48.4, 67.2, 12.2, 19.8, 30.8 ],\n heightElements: [ 55.3, 19.7, 4.2, 6.7, 2.3, 1.6, 6.2, 54.6 ]\n },\n 'BUSINESS_KNOWLEDGE_MODEL': {\n d: 'm {mx},{my} l {e.x0},-{e.y0} l {e.x1},0 l 0,{e.y1} l -{e.x2},{e.y2} l -{e.x3},0z',\n width: 125,\n height: 45,\n widthElements: [ 13.8, 109.2, 13.8, 109.1 ],\n heightElements: [ 13.2, 29.8, 13.2 ]\n },\n 'TEXT_ANNOTATION': {\n d: 'm {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0',\n width: 10,\n height: 30,\n widthElements: [ 10 ],\n heightElements: [ 30 ]\n }\n };\n\n this.getRawPath = function getRawPath(pathId) {\n return this.pathMap[pathId].d;\n };\n\n /**\n * Scales the path to the given height and width.\n * <h1>Use case</h1>\n * <p>Use case is to scale the content of elements (event, gateways) based\n * on the element bounding box's size.\n * </p>\n * <h1>Why not transform</h1>\n * <p>Scaling a path with transform() will also scale the stroke and IE does not support\n * the option 'non-scaling-stroke' to prevent this.\n * Also there are use cases where only some parts of a path should be\n * scaled.</p>\n *\n * @param {String} pathId The ID of the path.\n * @param {Object} param <p>\n * Example param object scales the path to 60% size of the container (data.width, data.height).\n * <pre>\n * {\n * xScaleFactor: 0.6,\n * yScaleFactor:0.6,\n * containerWidth: data.width,\n * containerHeight: data.height,\n * position: {\n * mx: 0.46,\n * my: 0.2,\n * }\n * }\n * </pre>\n * <ul>\n * <li>targetpathwidth = xScaleFactor * containerWidth</li>\n * <li>targetpathheight = yScaleFactor * containerHeight</li>\n * <li>Position is used to set the starting coordinate of the path. M is computed:\n * <ul>\n * <li>position.x * containerWidth</li>\n * <li>position.y * containerHeight</li>\n * </ul>\n * Center of the container <pre> position: {\n * mx: 0.5,\n * my: 0.5,\n * }</pre>\n * Upper left corner of the container\n * <pre> position: {\n * mx: 0.0,\n * my: 0.0,\n * }</pre>\n * </li>\n * </ul>\n * </p>\n *\n */\n this.getScaledPath = function getScaledPath(pathId, param) {\n var rawPath = this.pathMap[pathId];\n\n // positioning\n // compute the start point of the path\n var mx, my;\n\n if (param.abspos) {\n mx = param.abspos.x;\n my = param.abspos.y;\n } else {\n mx = param.containerWidth * param.position.mx;\n my = param.containerHeight * param.position.my;\n }\n\n var coordinates = {}; //map for the scaled coordinates\n if (param.position) {\n\n // path\n var heightRatio = (param.containerHeight / rawPath.height) * param.yScaleFactor;\n var widthRatio = (param.containerWidth / rawPath.width) * param.xScaleFactor;\n\n\n //Apply height ratio\n for (var heightIndex = 0; heightIndex < rawPath.heightElements.length; heightIndex++) {\n coordinates['y' + heightIndex] = rawPath.heightElements[heightIndex] * heightRatio;\n }\n\n //Apply width ratio\n for (var widthIndex = 0; widthIndex < rawPath.widthElements.length; widthIndex++) {\n coordinates['x' + widthIndex] = rawPath.widthElements[widthIndex] * widthRatio;\n }\n }\n\n //Apply value to raw path\n var path = format(\n rawPath.d, {\n mx: mx,\n my: my,\n e: coordinates\n }\n );\n return path;\n };\n}", "title": "" }, { "docid": "baa765b72eae60a123d7668a687d598c", "score": "0.57289803", "text": "function PathMap() {\n\n /**\n * Contains a map of path elements\n *\n * <h1>Path definition</h1>\n * A parameterized path is defined like this:\n * <pre>\n * 'GATEWAY_PARALLEL': {\n * d: 'm {mx},{my} {e.x0},0 0,{e.x1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} ' +\n '-{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z',\n * height: 17.5,\n * width: 17.5,\n * heightElements: [2.5, 7.5],\n * widthElements: [2.5, 7.5]\n * }\n * </pre>\n * <p>It's important to specify a correct <b>height and width</b> for the path as the scaling\n * is based on the ratio between the specified height and width in this object and the\n * height and width that is set as scale target (Note x,y coordinates will be scaled with\n * individual ratios).</p>\n * <p>The '<b>heightElements</b>' and '<b>widthElements</b>' array must contain the values that will be scaled.\n * The scaling is based on the computed ratios.\n * Coordinates on the y axis should be in the <b>heightElement</b>'s array, they will be scaled using\n * the computed ratio coefficient.\n * In the parameterized path the scaled values can be accessed through the 'e' object in {} brackets.\n * <ul>\n * <li>The values for the y axis can be accessed in the path string using {e.y0}, {e.y1}, ....</li>\n * <li>The values for the x axis can be accessed in the path string using {e.x0}, {e.x1}, ....</li>\n * </ul>\n * The numbers x0, x1 respectively y0, y1, ... map to the corresponding array index.\n * </p>\n */\n this.pathMap = {\n 'EVENT_MESSAGE': {\n d: 'm {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}',\n height: 36,\n width: 36,\n heightElements: [6, 14],\n widthElements: [10.5, 21]\n },\n 'EVENT_SIGNAL': {\n d: 'M {mx},{my} l {e.x0},{e.y0} l -{e.x1},0 Z',\n height: 36,\n width: 36,\n heightElements: [18],\n widthElements: [10, 20]\n },\n 'EVENT_ESCALATION': {\n d: 'M {mx},{my} l {e.x0},{e.y0} l -{e.x0},-{e.y1} l -{e.x0},{e.y1} Z',\n height: 36,\n width: 36,\n heightElements: [20, 7],\n widthElements: [8]\n },\n 'EVENT_CONDITIONAL': {\n d: 'M {e.x0},{e.y0} l {e.x1},0 l 0,{e.y2} l -{e.x1},0 Z ' +\n 'M {e.x2},{e.y3} l {e.x0},0 ' +\n 'M {e.x2},{e.y4} l {e.x0},0 ' +\n 'M {e.x2},{e.y5} l {e.x0},0 ' +\n 'M {e.x2},{e.y6} l {e.x0},0 ' +\n 'M {e.x2},{e.y7} l {e.x0},0 ' +\n 'M {e.x2},{e.y8} l {e.x0},0 ',\n height: 36,\n width: 36,\n heightElements: [8.5, 14.5, 18, 11.5, 14.5, 17.5, 20.5, 23.5, 26.5],\n widthElements: [10.5, 14.5, 12.5]\n },\n 'EVENT_LINK': {\n d: 'm {mx},{my} 0,{e.y0} -{e.x1},0 0,{e.y1} {e.x1},0 0,{e.y0} {e.x0},-{e.y2} -{e.x0},-{e.y2} z',\n height: 36,\n width: 36,\n heightElements: [4.4375, 6.75, 7.8125],\n widthElements: [9.84375, 13.5]\n },\n 'EVENT_ERROR': {\n d: 'm {mx},{my} {e.x0},-{e.y0} {e.x1},-{e.y1} {e.x2},{e.y2} {e.x3},-{e.y3} -{e.x4},{e.y4} -{e.x5},-{e.y5} z',\n height: 36,\n width: 36,\n heightElements: [0.023, 8.737, 8.151, 16.564, 10.591, 8.714],\n widthElements: [0.085, 6.672, 6.97, 4.273, 5.337, 6.636]\n },\n 'EVENT_CANCEL_45': {\n d: 'm {mx},{my} -{e.x1},0 0,{e.x0} {e.x1},0 0,{e.y1} {e.x0},0 ' +\n '0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z',\n height: 36,\n width: 36,\n heightElements: [4.75, 8.5],\n widthElements: [4.75, 8.5]\n },\n 'EVENT_COMPENSATION': {\n d: 'm {mx},{my} {e.x0},-{e.y0} 0,{e.y1} z m {e.x1},-{e.y2} {e.x2},-{e.y3} 0,{e.y1} -{e.x2},-{e.y3} z',\n height: 36,\n width: 36,\n heightElements: [6.5, 13, 0.4, 6.1],\n widthElements: [9, 9.3, 8.7]\n },\n 'EVENT_TIMER_WH': {\n d: 'M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ',\n height: 36,\n width: 36,\n heightElements: [10, 2],\n widthElements: [3, 7]\n },\n 'EVENT_TIMER_LINE': {\n d: 'M {mx},{my} ' +\n 'm {e.x0},{e.y0} l -{e.x1},{e.y1} ',\n height: 36,\n width: 36,\n heightElements: [10, 3],\n widthElements: [0, 0]\n },\n 'EVENT_MULTIPLE': {\n d:'m {mx},{my} {e.x1},-{e.y0} {e.x1},{e.y0} -{e.x0},{e.y1} -{e.x2},0 z',\n height: 36,\n width: 36,\n heightElements: [6.28099, 12.56199],\n widthElements: [3.1405, 9.42149, 12.56198]\n },\n 'EVENT_PARALLEL_MULTIPLE': {\n d:'m {mx},{my} {e.x0},0 0,{e.y1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} ' +\n '-{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z',\n height: 36,\n width: 36,\n heightElements: [2.56228, 7.68683],\n widthElements: [2.56228, 7.68683]\n },\n 'GATEWAY_EXCLUSIVE': {\n d:'m {mx},{my} {e.x0},{e.y0} {e.x1},{e.y0} {e.x2},0 {e.x4},{e.y2} ' +\n '{e.x4},{e.y1} {e.x2},0 {e.x1},{e.y3} {e.x0},{e.y3} ' +\n '{e.x3},0 {e.x5},{e.y1} {e.x5},{e.y2} {e.x3},0 z',\n height: 17.5,\n width: 17.5,\n heightElements: [8.5, 6.5312, -6.5312, -8.5],\n widthElements: [6.5, -6.5, 3, -3, 5, -5]\n },\n 'GATEWAY_PARALLEL': {\n d:'m {mx},{my} 0,{e.y1} -{e.x1},0 0,{e.y0} {e.x1},0 0,{e.y1} {e.x0},0 ' +\n '0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z',\n height: 30,\n width: 30,\n heightElements: [5, 12.5],\n widthElements: [5, 12.5]\n },\n 'GATEWAY_EVENT_BASED': {\n d:'m {mx},{my} {e.x0},{e.y0} {e.x0},{e.y1} {e.x1},{e.y2} {e.x2},0 z',\n height: 11,\n width: 11,\n heightElements: [-6, 6, 12, -12],\n widthElements: [9, -3, -12]\n },\n 'GATEWAY_COMPLEX': {\n d:'m {mx},{my} 0,{e.y0} -{e.x0},-{e.y1} -{e.x1},{e.y2} {e.x0},{e.y1} -{e.x2},0 0,{e.y3} ' +\n '{e.x2},0 -{e.x0},{e.y1} l {e.x1},{e.y2} {e.x0},-{e.y1} 0,{e.y0} {e.x3},0 0,-{e.y0} {e.x0},{e.y1} ' +\n '{e.x1},-{e.y2} -{e.x0},-{e.y1} {e.x2},0 0,-{e.y3} -{e.x2},0 {e.x0},-{e.y1} -{e.x1},-{e.y2} ' +\n '-{e.x0},{e.y1} 0,-{e.y0} -{e.x3},0 z',\n height: 17.125,\n width: 17.125,\n heightElements: [4.875, 3.4375, 2.125, 3],\n widthElements: [3.4375, 2.125, 4.875, 3]\n },\n 'DATA_OBJECT_PATH': {\n d:'m 0,0 {e.x1},0 {e.x0},{e.y0} 0,{e.y1} -{e.x2},0 0,-{e.y2} {e.x1},0 0,{e.y0} {e.x0},0',\n height: 61,\n width: 51,\n heightElements: [10, 50, 60],\n widthElements: [10, 40, 50, 60]\n },\n 'DATA_OBJECT_COLLECTION_PATH': {\n d:'m {mx}, {my} ' +\n 'm 0 15 l 0 -15 ' +\n 'm 4 15 l 0 -15 ' +\n 'm 4 15 l 0 -15 ',\n height: 61,\n width: 51,\n heightElements: [12],\n widthElements: [1, 6, 12, 15]\n },\n 'DATA_ARROW': {\n d:'m 5,9 9,0 0,-3 5,5 -5,5 0,-3 -9,0 z',\n height: 61,\n width: 51,\n heightElements: [],\n widthElements: []\n },\n 'DATA_STORE': {\n d:'m {mx},{my} ' +\n 'l 0,{e.y2} ' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 ' +\n 'l 0,-{e.y2} ' +\n 'c -{e.x0},-{e.y1} -{e.x1},-{e.y1} -{e.x2},0' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 ' +\n 'm -{e.x2},{e.y0}' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0' +\n 'm -{e.x2},{e.y0}' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0',\n height: 61,\n width: 61,\n heightElements: [7, 10, 45],\n widthElements: [2, 58, 60]\n },\n 'TEXT_ANNOTATION': {\n d: 'm {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0',\n height: 30,\n width: 10,\n heightElements: [30],\n widthElements: [10]\n },\n 'MARKER_SUB_PROCESS': {\n d: 'm{mx},{my} m 7,2 l 0,10 m -5,-5 l 10,0',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_PARALLEL': {\n d: 'm{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_SEQUENTIAL': {\n d: 'm{mx},{my} m 0,3 l 10,0 m -10,3 l 10,0 m -10,3 l 10,0',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_COMPENSATION': {\n d: 'm {mx},{my} 7,-5 0,10 z m 7.1,-0.3 6.9,-4.7 0,10 -6.9,-4.7 z',\n height: 10,\n width: 21,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_LOOP': {\n d: 'm {mx},{my} c 3.526979,0 6.386161,-2.829858 6.386161,-6.320661 0,-3.490806 -2.859182,-6.320661 ' +\n '-6.386161,-6.320661 -3.526978,0 -6.38616,2.829855 -6.38616,6.320661 0,1.745402 ' +\n '0.714797,3.325567 1.870463,4.469381 0.577834,0.571908 1.265885,1.034728 2.029916,1.35457 ' +\n 'l -0.718163,-3.909793 m 0.718163,3.909793 -3.885211,0.802902',\n height: 13.9,\n width: 13.7,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_ADHOC': {\n d: 'm {mx},{my} m 0.84461,2.64411 c 1.05533,-1.23780996 2.64337,-2.07882 4.29653,-1.97997996 2.05163,0.0805 ' +\n '3.85579,1.15803 5.76082,1.79107 1.06385,0.34139996 2.24454,0.1438 3.18759,-0.43767 0.61743,-0.33642 ' +\n '1.2775,-0.64078 1.7542,-1.17511 0,0.56023 0,1.12046 0,1.6807 -0.98706,0.96237996 -2.29792,1.62393996 ' +\n '-3.6918,1.66181996 -1.24459,0.0927 -2.46671,-0.2491 -3.59505,-0.74812 -1.35789,-0.55965 ' +\n '-2.75133,-1.33436996 -4.27027,-1.18121996 -1.37741,0.14601 -2.41842,1.13685996 -3.44288,1.96782996 z',\n height: 4,\n width: 15,\n heightElements: [],\n widthElements: []\n },\n 'TASK_TYPE_SEND': {\n d: 'm {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}',\n height: 14,\n width: 21,\n heightElements: [6, 14],\n widthElements: [10.5, 21]\n },\n 'TASK_TYPE_SCRIPT': {\n d: 'm {mx},{my} c 9.966553,-6.27276 -8.000926,-7.91932 2.968968,-14.938 l -8.802728,0 ' +\n 'c -10.969894,7.01868 6.997585,8.66524 -2.968967,14.938 z ' +\n 'm -7,-12 l 5,0 ' +\n 'm -4.5,3 l 4.5,0 ' +\n 'm -3,3 l 5,0' +\n 'm -4,3 l 5,0',\n height: 15,\n width: 12.6,\n heightElements: [6, 14],\n widthElements: [10.5, 21]\n },\n 'TASK_TYPE_USER_1': {\n d: 'm {mx},{my} c 0.909,-0.845 1.594,-2.049 1.594,-3.385 0,-2.554 -1.805,-4.62199999 ' +\n '-4.357,-4.62199999 -2.55199998,0 -4.28799998,2.06799999 -4.28799998,4.62199999 0,1.348 ' +\n '0.974,2.562 1.89599998,3.405 -0.52899998,0.187 -5.669,2.097 -5.794,4.7560005 v 6.718 ' +\n 'h 17 v -6.718 c 0,-2.2980005 -5.5279996,-4.5950005 -6.0509996,-4.7760005 z' +\n 'm -8,6 l 0,5.5 m 11,0 l 0,-5'\n },\n 'TASK_TYPE_USER_2': {\n d: 'm {mx},{my} m 2.162,1.009 c 0,2.4470005 -2.158,4.4310005 -4.821,4.4310005 ' +\n '-2.66499998,0 -4.822,-1.981 -4.822,-4.4310005 '\n },\n 'TASK_TYPE_USER_3': {\n d: 'm {mx},{my} m -6.9,-3.80 c 0,0 2.25099998,-2.358 4.27399998,-1.177 2.024,1.181 4.221,1.537 ' +\n '4.124,0.965 -0.098,-0.57 -0.117,-3.79099999 -4.191,-4.13599999 -3.57499998,0.001 ' +\n '-4.20799998,3.36699999 -4.20699998,4.34799999 z'\n },\n 'TASK_TYPE_MANUAL': {\n d: 'm {mx},{my} c 0.234,-0.01 5.604,0.008 8.029,0.004 0.808,0 1.271,-0.172 1.417,-0.752 0.227,-0.898 ' +\n '-0.334,-1.314 -1.338,-1.316 -2.467,-0.01 -7.886,-0.004 -8.108,-0.004 -0.014,-0.079 0.016,-0.533 0,-0.61 ' +\n '0.195,-0.042 8.507,0.006 9.616,0.002 0.877,-0.007 1.35,-0.438 1.353,-1.208 0.003,-0.768 -0.479,-1.09 ' +\n '-1.35,-1.091 -2.968,-0.002 -9.619,-0.013 -9.619,-0.013 v -0.591 c 0,0 5.052,-0.016 7.225,-0.016 ' +\n '0.888,-0.002 1.354,-0.416 1.351,-1.193 -0.006,-0.761 -0.492,-1.196 -1.361,-1.196 -3.473,-0.005 ' +\n '-10.86,-0.003 -11.0829995,-0.003 -0.022,-0.047 -0.045,-0.094 -0.069,-0.139 0.3939995,-0.319 ' +\n '2.0409995,-1.626 2.4149995,-2.017 0.469,-0.4870005 0.519,-1.1650005 0.162,-1.6040005 -0.414,-0.511 ' +\n '-0.973,-0.5 -1.48,-0.236 -1.4609995,0.764 -6.5999995,3.6430005 -7.7329995,4.2710005 -0.9,0.499 ' +\n '-1.516,1.253 -1.882,2.19 -0.37000002,0.95 -0.17,2.01 -0.166,2.979 0.004,0.718 -0.27300002,1.345 ' +\n '-0.055,2.063 0.629,2.087 2.425,3.312 4.859,3.318 4.6179995,0.014 9.2379995,-0.139 13.8569995,-0.158 ' +\n '0.755,-0.004 1.171,-0.301 1.182,-1.033 0.012,-0.754 -0.423,-0.969 -1.183,-0.973 -1.778,-0.01 ' +\n '-5.824,-0.004 -6.04,-0.004 10e-4,-0.084 0.003,-0.586 10e-4,-0.67 z'\n },\n 'TASK_TYPE_INSTANTIATING_SEND': {\n d: 'm {mx},{my} l 0,8.4 l 12.6,0 l 0,-8.4 z l 6.3,3.6 l 6.3,-3.6'\n },\n 'TASK_TYPE_SERVICE': {\n d: 'm {mx},{my} v -1.71335 c 0.352326,-0.0705 0.703932,-0.17838 1.047628,-0.32133 ' +\n '0.344416,-0.14465 0.665822,-0.32133 0.966377,-0.52145 l 1.19431,1.18005 1.567487,-1.57688 ' +\n '-1.195028,-1.18014 c 0.403376,-0.61394 0.683079,-1.29908 0.825447,-2.01824 l 1.622133,-0.01 ' +\n 'v -2.2196 l -1.636514,0.01 c -0.07333,-0.35153 -0.178319,-0.70024 -0.323564,-1.04372 ' +\n '-0.145244,-0.34406 -0.321407,-0.6644 -0.522735,-0.96217 l 1.131035,-1.13631 -1.583305,-1.56293 ' +\n '-1.129598,1.13589 c -0.614052,-0.40108 -1.302883,-0.68093 -2.022633,-0.82247 l 0.0093,-1.61852 ' +\n 'h -2.241173 l 0.0042,1.63124 c -0.353763,0.0736 -0.705369,0.17977 -1.049785,0.32371 -0.344415,0.14437 ' +\n '-0.665102,0.32092 -0.9635006,0.52046 l -1.1698628,-1.15823 -1.5667691,1.5792 1.1684265,1.15669 ' +\n 'c -0.4026573,0.61283 -0.68308,1.29797 -0.8247287,2.01713 l -1.6588041,0.003 v 2.22174 ' +\n 'l 1.6724648,-0.006 c 0.073327,0.35077 0.1797598,0.70243 0.3242851,1.04472 0.1452428,0.34448 ' +\n '0.3214064,0.6644 0.5227339,0.96066 l -1.1993431,1.19723 1.5840256,1.56011 1.1964668,-1.19348 ' +\n 'c 0.6140517,0.40346 1.3028827,0.68232 2.0233517,0.82331 l 7.19e-4,1.69892 h 2.226848 z ' +\n 'm 0.221462,-3.9957 c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 ' +\n '0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 ' +\n '0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z'\n },\n 'TASK_TYPE_SERVICE_FILL': {\n d: 'm {mx},{my} c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 ' +\n '0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 ' +\n '0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z'\n },\n 'TASK_TYPE_BUSINESS_RULE_HEADER': {\n d: 'm {mx},{my} 0,4 20,0 0,-4 z'\n },\n 'TASK_TYPE_BUSINESS_RULE_MAIN': {\n d: 'm {mx},{my} 0,12 20,0 0,-12 z' +\n 'm 0,8 l 20,0 ' +\n 'm -13,-4 l 0,8'\n },\n 'MESSAGE_FLOW_MARKER': {\n d: 'm {mx},{my} m -10.5 ,-7 l 0,14 l 21,0 l 0,-14 z l 10.5,6 l 10.5,-6'\n }\n };\n\n this.getRawPath = function getRawPath(pathId) {\n return this.pathMap[pathId].d;\n };\n\n /**\n * Scales the path to the given height and width.\n * <h1>Use case</h1>\n * <p>Use case is to scale the content of elements (event, gateways) based\n * on the element bounding box's size.\n * </p>\n * <h1>Why not transform</h1>\n * <p>Scaling a path with transform() will also scale the stroke and IE does not support\n * the option 'non-scaling-stroke' to prevent this.\n * Also there are use cases where only some parts of a path should be\n * scaled.</p>\n *\n * @param {String} pathId The ID of the path.\n * @param {Object} param <p>\n * Example param object scales the path to 60% size of the container (data.width, data.height).\n * <pre>\n * {\n * xScaleFactor: 0.6,\n * yScaleFactor:0.6,\n * containerWidth: data.width,\n * containerHeight: data.height,\n * position: {\n * mx: 0.46,\n * my: 0.2,\n * }\n * }\n * </pre>\n * <ul>\n * <li>targetpathwidth = xScaleFactor * containerWidth</li>\n * <li>targetpathheight = yScaleFactor * containerHeight</li>\n * <li>Position is used to set the starting coordinate of the path. M is computed:\n * <ul>\n * <li>position.x * containerWidth</li>\n * <li>position.y * containerHeight</li>\n * </ul>\n * Center of the container <pre> position: {\n * mx: 0.5,\n * my: 0.5,\n * }</pre>\n * Upper left corner of the container\n * <pre> position: {\n * mx: 0.0,\n * my: 0.0,\n * }</pre>\n * </li>\n * </ul>\n * </p>\n *\n */\n this.getScaledPath = function getScaledPath(pathId, param) {\n var rawPath = this.pathMap[pathId];\n\n // positioning\n // compute the start point of the path\n var mx, my;\n\n if (param.abspos) {\n mx = param.abspos.x;\n my = param.abspos.y;\n } else {\n mx = param.containerWidth * param.position.mx;\n my = param.containerHeight * param.position.my;\n }\n\n var coordinates = {}; // map for the scaled coordinates\n if (param.position) {\n\n // path\n var heightRatio = (param.containerHeight / rawPath.height) * param.yScaleFactor;\n var widthRatio = (param.containerWidth / rawPath.width) * param.xScaleFactor;\n\n\n // Apply height ratio\n for (var heightIndex = 0; heightIndex < rawPath.heightElements.length; heightIndex++) {\n coordinates['y' + heightIndex] = rawPath.heightElements[heightIndex] * heightRatio;\n }\n\n // Apply width ratio\n for (var widthIndex = 0; widthIndex < rawPath.widthElements.length; widthIndex++) {\n coordinates['x' + widthIndex] = rawPath.widthElements[widthIndex] * widthRatio;\n }\n }\n\n // Apply value to raw path\n var path = format(\n rawPath.d, {\n mx: mx,\n my: my,\n e: coordinates\n }\n );\n return path;\n };\n}", "title": "" }, { "docid": "94b374a4432059974d6200deb3c78d46", "score": "0.57289803", "text": "function PathMap() {\n\n /**\n * Contains a map of path elements\n *\n * <h1>Path definition</h1>\n * A parameterized path is defined like this:\n * <pre>\n * 'GATEWAY_PARALLEL': {\n * d: 'm {mx},{my} {e.x0},0 0,{e.x1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} ' +\n '-{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z',\n * height: 17.5,\n * width: 17.5,\n * heightElements: [2.5, 7.5],\n * widthElements: [2.5, 7.5]\n * }\n * </pre>\n * <p>It's important to specify a correct <b>height and width</b> for the path as the scaling\n * is based on the ratio between the specified height and width in this object and the\n * height and width that is set as scale target (Note x,y coordinates will be scaled with\n * individual ratios).</p>\n * <p>The '<b>heightElements</b>' and '<b>widthElements</b>' array must contain the values that will be scaled.\n * The scaling is based on the computed ratios.\n * Coordinates on the y axis should be in the <b>heightElement</b>'s array, they will be scaled using\n * the computed ratio coefficient.\n * In the parameterized path the scaled values can be accessed through the 'e' object in {} brackets.\n * <ul>\n * <li>The values for the y axis can be accessed in the path string using {e.y0}, {e.y1}, ....</li>\n * <li>The values for the x axis can be accessed in the path string using {e.x0}, {e.x1}, ....</li>\n * </ul>\n * The numbers x0, x1 respectively y0, y1, ... map to the corresponding array index.\n * </p>\n */\n this.pathMap = {\n 'EVENT_MESSAGE': {\n d: 'm {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}',\n height: 36,\n width: 36,\n heightElements: [6, 14],\n widthElements: [10.5, 21]\n },\n 'EVENT_SIGNAL': {\n d: 'M {mx},{my} l {e.x0},{e.y0} l -{e.x1},0 Z',\n height: 36,\n width: 36,\n heightElements: [18],\n widthElements: [10, 20]\n },\n 'EVENT_ESCALATION': {\n d: 'M {mx},{my} l {e.x0},{e.y0} l -{e.x0},-{e.y1} l -{e.x0},{e.y1} Z',\n height: 36,\n width: 36,\n heightElements: [20, 7],\n widthElements: [8]\n },\n 'EVENT_CONDITIONAL': {\n d: 'M {e.x0},{e.y0} l {e.x1},0 l 0,{e.y2} l -{e.x1},0 Z ' +\n 'M {e.x2},{e.y3} l {e.x0},0 ' +\n 'M {e.x2},{e.y4} l {e.x0},0 ' +\n 'M {e.x2},{e.y5} l {e.x0},0 ' +\n 'M {e.x2},{e.y6} l {e.x0},0 ' +\n 'M {e.x2},{e.y7} l {e.x0},0 ' +\n 'M {e.x2},{e.y8} l {e.x0},0 ',\n height: 36,\n width: 36,\n heightElements: [8.5, 14.5, 18, 11.5, 14.5, 17.5, 20.5, 23.5, 26.5],\n widthElements: [10.5, 14.5, 12.5]\n },\n 'EVENT_LINK': {\n d: 'm {mx},{my} 0,{e.y0} -{e.x1},0 0,{e.y1} {e.x1},0 0,{e.y0} {e.x0},-{e.y2} -{e.x0},-{e.y2} z',\n height: 36,\n width: 36,\n heightElements: [4.4375, 6.75, 7.8125],\n widthElements: [9.84375, 13.5]\n },\n 'EVENT_ERROR': {\n d: 'm {mx},{my} {e.x0},-{e.y0} {e.x1},-{e.y1} {e.x2},{e.y2} {e.x3},-{e.y3} -{e.x4},{e.y4} -{e.x5},-{e.y5} z',\n height: 36,\n width: 36,\n heightElements: [0.023, 8.737, 8.151, 16.564, 10.591, 8.714],\n widthElements: [0.085, 6.672, 6.97, 4.273, 5.337, 6.636]\n },\n 'EVENT_CANCEL_45': {\n d: 'm {mx},{my} -{e.x1},0 0,{e.x0} {e.x1},0 0,{e.y1} {e.x0},0 ' +\n '0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z',\n height: 36,\n width: 36,\n heightElements: [4.75, 8.5],\n widthElements: [4.75, 8.5]\n },\n 'EVENT_COMPENSATION': {\n d: 'm {mx},{my} {e.x0},-{e.y0} 0,{e.y1} z m {e.x1},-{e.y2} {e.x2},-{e.y3} 0,{e.y1} -{e.x2},-{e.y3} z',\n height: 36,\n width: 36,\n heightElements: [6.5, 13, 0.4, 6.1],\n widthElements: [9, 9.3, 8.7]\n },\n 'EVENT_TIMER_WH': {\n d: 'M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ',\n height: 36,\n width: 36,\n heightElements: [10, 2],\n widthElements: [3, 7]\n },\n 'EVENT_TIMER_LINE': {\n d: 'M {mx},{my} ' +\n 'm {e.x0},{e.y0} l -{e.x1},{e.y1} ',\n height: 36,\n width: 36,\n heightElements: [10, 3],\n widthElements: [0, 0]\n },\n 'EVENT_MULTIPLE': {\n d:'m {mx},{my} {e.x1},-{e.y0} {e.x1},{e.y0} -{e.x0},{e.y1} -{e.x2},0 z',\n height: 36,\n width: 36,\n heightElements: [6.28099, 12.56199],\n widthElements: [3.1405, 9.42149, 12.56198]\n },\n 'EVENT_PARALLEL_MULTIPLE': {\n d:'m {mx},{my} {e.x0},0 0,{e.y1} {e.x1},0 0,{e.y0} -{e.x1},0 0,{e.y1} ' +\n '-{e.x0},0 0,-{e.y1} -{e.x1},0 0,-{e.y0} {e.x1},0 z',\n height: 36,\n width: 36,\n heightElements: [2.56228, 7.68683],\n widthElements: [2.56228, 7.68683]\n },\n 'GATEWAY_EXCLUSIVE': {\n d:'m {mx},{my} {e.x0},{e.y0} {e.x1},{e.y0} {e.x2},0 {e.x4},{e.y2} ' +\n '{e.x4},{e.y1} {e.x2},0 {e.x1},{e.y3} {e.x0},{e.y3} ' +\n '{e.x3},0 {e.x5},{e.y1} {e.x5},{e.y2} {e.x3},0 z',\n height: 17.5,\n width: 17.5,\n heightElements: [8.5, 6.5312, -6.5312, -8.5],\n widthElements: [6.5, -6.5, 3, -3, 5, -5]\n },\n 'GATEWAY_PARALLEL': {\n d:'m {mx},{my} 0,{e.y1} -{e.x1},0 0,{e.y0} {e.x1},0 0,{e.y1} {e.x0},0 ' +\n '0,-{e.y1} {e.x1},0 0,-{e.y0} -{e.x1},0 0,-{e.y1} -{e.x0},0 z',\n height: 30,\n width: 30,\n heightElements: [5, 12.5],\n widthElements: [5, 12.5]\n },\n 'GATEWAY_EVENT_BASED': {\n d:'m {mx},{my} {e.x0},{e.y0} {e.x0},{e.y1} {e.x1},{e.y2} {e.x2},0 z',\n height: 11,\n width: 11,\n heightElements: [-6, 6, 12, -12],\n widthElements: [9, -3, -12]\n },\n 'GATEWAY_COMPLEX': {\n d:'m {mx},{my} 0,{e.y0} -{e.x0},-{e.y1} -{e.x1},{e.y2} {e.x0},{e.y1} -{e.x2},0 0,{e.y3} ' +\n '{e.x2},0 -{e.x0},{e.y1} l {e.x1},{e.y2} {e.x0},-{e.y1} 0,{e.y0} {e.x3},0 0,-{e.y0} {e.x0},{e.y1} ' +\n '{e.x1},-{e.y2} -{e.x0},-{e.y1} {e.x2},0 0,-{e.y3} -{e.x2},0 {e.x0},-{e.y1} -{e.x1},-{e.y2} ' +\n '-{e.x0},{e.y1} 0,-{e.y0} -{e.x3},0 z',\n height: 17.125,\n width: 17.125,\n heightElements: [4.875, 3.4375, 2.125, 3],\n widthElements: [3.4375, 2.125, 4.875, 3]\n },\n 'DATA_OBJECT_PATH': {\n d:'m 0,0 {e.x1},0 {e.x0},{e.y0} 0,{e.y1} -{e.x2},0 0,-{e.y2} {e.x1},0 0,{e.y0} {e.x0},0',\n height: 61,\n width: 51,\n heightElements: [10, 50, 60],\n widthElements: [10, 40, 50, 60]\n },\n 'DATA_OBJECT_COLLECTION_PATH': {\n d:'m {mx}, {my} ' +\n 'm 0 15 l 0 -15 ' +\n 'm 4 15 l 0 -15 ' +\n 'm 4 15 l 0 -15 ',\n height: 61,\n width: 51,\n heightElements: [12],\n widthElements: [1, 6, 12, 15]\n },\n 'DATA_ARROW': {\n d:'m 5,9 9,0 0,-3 5,5 -5,5 0,-3 -9,0 z',\n height: 61,\n width: 51,\n heightElements: [],\n widthElements: []\n },\n 'DATA_STORE': {\n d:'m {mx},{my} ' +\n 'l 0,{e.y2} ' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 ' +\n 'l 0,-{e.y2} ' +\n 'c -{e.x0},-{e.y1} -{e.x1},-{e.y1} -{e.x2},0' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0 ' +\n 'm -{e.x2},{e.y0}' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0' +\n 'm -{e.x2},{e.y0}' +\n 'c {e.x0},{e.y1} {e.x1},{e.y1} {e.x2},0',\n height: 61,\n width: 61,\n heightElements: [7, 10, 45],\n widthElements: [2, 58, 60]\n },\n 'TEXT_ANNOTATION': {\n d: 'm {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0',\n height: 30,\n width: 10,\n heightElements: [30],\n widthElements: [10]\n },\n 'MARKER_SUB_PROCESS': {\n d: 'm{mx},{my} m 7,2 l 0,10 m -5,-5 l 10,0',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_PARALLEL': {\n d: 'm{mx},{my} m 3,2 l 0,10 m 3,-10 l 0,10 m 3,-10 l 0,10',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_SEQUENTIAL': {\n d: 'm{mx},{my} m 0,3 l 10,0 m -10,3 l 10,0 m -10,3 l 10,0',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_COMPENSATION': {\n d: 'm {mx},{my} 7,-5 0,10 z m 7.1,-0.3 6.9,-4.7 0,10 -6.9,-4.7 z',\n height: 10,\n width: 21,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_LOOP': {\n d: 'm {mx},{my} c 3.526979,0 6.386161,-2.829858 6.386161,-6.320661 0,-3.490806 -2.859182,-6.320661 ' +\n '-6.386161,-6.320661 -3.526978,0 -6.38616,2.829855 -6.38616,6.320661 0,1.745402 ' +\n '0.714797,3.325567 1.870463,4.469381 0.577834,0.571908 1.265885,1.034728 2.029916,1.35457 ' +\n 'l -0.718163,-3.909793 m 0.718163,3.909793 -3.885211,0.802902',\n height: 13.9,\n width: 13.7,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_ADHOC': {\n d: 'm {mx},{my} m 0.84461,2.64411 c 1.05533,-1.23780996 2.64337,-2.07882 4.29653,-1.97997996 2.05163,0.0805 ' +\n '3.85579,1.15803 5.76082,1.79107 1.06385,0.34139996 2.24454,0.1438 3.18759,-0.43767 0.61743,-0.33642 ' +\n '1.2775,-0.64078 1.7542,-1.17511 0,0.56023 0,1.12046 0,1.6807 -0.98706,0.96237996 -2.29792,1.62393996 ' +\n '-3.6918,1.66181996 -1.24459,0.0927 -2.46671,-0.2491 -3.59505,-0.74812 -1.35789,-0.55965 ' +\n '-2.75133,-1.33436996 -4.27027,-1.18121996 -1.37741,0.14601 -2.41842,1.13685996 -3.44288,1.96782996 z',\n height: 4,\n width: 15,\n heightElements: [],\n widthElements: []\n },\n 'TASK_TYPE_SEND': {\n d: 'm {mx},{my} l 0,{e.y1} l {e.x1},0 l 0,-{e.y1} z l {e.x0},{e.y0} l {e.x0},-{e.y0}',\n height: 14,\n width: 21,\n heightElements: [6, 14],\n widthElements: [10.5, 21]\n },\n 'TASK_TYPE_SCRIPT': {\n d: 'm {mx},{my} c 9.966553,-6.27276 -8.000926,-7.91932 2.968968,-14.938 l -8.802728,0 ' +\n 'c -10.969894,7.01868 6.997585,8.66524 -2.968967,14.938 z ' +\n 'm -7,-12 l 5,0 ' +\n 'm -4.5,3 l 4.5,0 ' +\n 'm -3,3 l 5,0' +\n 'm -4,3 l 5,0',\n height: 15,\n width: 12.6,\n heightElements: [6, 14],\n widthElements: [10.5, 21]\n },\n 'TASK_TYPE_USER_1': {\n d: 'm {mx},{my} c 0.909,-0.845 1.594,-2.049 1.594,-3.385 0,-2.554 -1.805,-4.62199999 ' +\n '-4.357,-4.62199999 -2.55199998,0 -4.28799998,2.06799999 -4.28799998,4.62199999 0,1.348 ' +\n '0.974,2.562 1.89599998,3.405 -0.52899998,0.187 -5.669,2.097 -5.794,4.7560005 v 6.718 ' +\n 'h 17 v -6.718 c 0,-2.2980005 -5.5279996,-4.5950005 -6.0509996,-4.7760005 z' +\n 'm -8,6 l 0,5.5 m 11,0 l 0,-5'\n },\n 'TASK_TYPE_USER_2': {\n d: 'm {mx},{my} m 2.162,1.009 c 0,2.4470005 -2.158,4.4310005 -4.821,4.4310005 ' +\n '-2.66499998,0 -4.822,-1.981 -4.822,-4.4310005 '\n },\n 'TASK_TYPE_USER_3': {\n d: 'm {mx},{my} m -6.9,-3.80 c 0,0 2.25099998,-2.358 4.27399998,-1.177 2.024,1.181 4.221,1.537 ' +\n '4.124,0.965 -0.098,-0.57 -0.117,-3.79099999 -4.191,-4.13599999 -3.57499998,0.001 ' +\n '-4.20799998,3.36699999 -4.20699998,4.34799999 z'\n },\n 'TASK_TYPE_MANUAL': {\n d: 'm {mx},{my} c 0.234,-0.01 5.604,0.008 8.029,0.004 0.808,0 1.271,-0.172 1.417,-0.752 0.227,-0.898 ' +\n '-0.334,-1.314 -1.338,-1.316 -2.467,-0.01 -7.886,-0.004 -8.108,-0.004 -0.014,-0.079 0.016,-0.533 0,-0.61 ' +\n '0.195,-0.042 8.507,0.006 9.616,0.002 0.877,-0.007 1.35,-0.438 1.353,-1.208 0.003,-0.768 -0.479,-1.09 ' +\n '-1.35,-1.091 -2.968,-0.002 -9.619,-0.013 -9.619,-0.013 v -0.591 c 0,0 5.052,-0.016 7.225,-0.016 ' +\n '0.888,-0.002 1.354,-0.416 1.351,-1.193 -0.006,-0.761 -0.492,-1.196 -1.361,-1.196 -3.473,-0.005 ' +\n '-10.86,-0.003 -11.0829995,-0.003 -0.022,-0.047 -0.045,-0.094 -0.069,-0.139 0.3939995,-0.319 ' +\n '2.0409995,-1.626 2.4149995,-2.017 0.469,-0.4870005 0.519,-1.1650005 0.162,-1.6040005 -0.414,-0.511 ' +\n '-0.973,-0.5 -1.48,-0.236 -1.4609995,0.764 -6.5999995,3.6430005 -7.7329995,4.2710005 -0.9,0.499 ' +\n '-1.516,1.253 -1.882,2.19 -0.37000002,0.95 -0.17,2.01 -0.166,2.979 0.004,0.718 -0.27300002,1.345 ' +\n '-0.055,2.063 0.629,2.087 2.425,3.312 4.859,3.318 4.6179995,0.014 9.2379995,-0.139 13.8569995,-0.158 ' +\n '0.755,-0.004 1.171,-0.301 1.182,-1.033 0.012,-0.754 -0.423,-0.969 -1.183,-0.973 -1.778,-0.01 ' +\n '-5.824,-0.004 -6.04,-0.004 10e-4,-0.084 0.003,-0.586 10e-4,-0.67 z'\n },\n 'TASK_TYPE_INSTANTIATING_SEND': {\n d: 'm {mx},{my} l 0,8.4 l 12.6,0 l 0,-8.4 z l 6.3,3.6 l 6.3,-3.6'\n },\n 'TASK_TYPE_SERVICE': {\n d: 'm {mx},{my} v -1.71335 c 0.352326,-0.0705 0.703932,-0.17838 1.047628,-0.32133 ' +\n '0.344416,-0.14465 0.665822,-0.32133 0.966377,-0.52145 l 1.19431,1.18005 1.567487,-1.57688 ' +\n '-1.195028,-1.18014 c 0.403376,-0.61394 0.683079,-1.29908 0.825447,-2.01824 l 1.622133,-0.01 ' +\n 'v -2.2196 l -1.636514,0.01 c -0.07333,-0.35153 -0.178319,-0.70024 -0.323564,-1.04372 ' +\n '-0.145244,-0.34406 -0.321407,-0.6644 -0.522735,-0.96217 l 1.131035,-1.13631 -1.583305,-1.56293 ' +\n '-1.129598,1.13589 c -0.614052,-0.40108 -1.302883,-0.68093 -2.022633,-0.82247 l 0.0093,-1.61852 ' +\n 'h -2.241173 l 0.0042,1.63124 c -0.353763,0.0736 -0.705369,0.17977 -1.049785,0.32371 -0.344415,0.14437 ' +\n '-0.665102,0.32092 -0.9635006,0.52046 l -1.1698628,-1.15823 -1.5667691,1.5792 1.1684265,1.15669 ' +\n 'c -0.4026573,0.61283 -0.68308,1.29797 -0.8247287,2.01713 l -1.6588041,0.003 v 2.22174 ' +\n 'l 1.6724648,-0.006 c 0.073327,0.35077 0.1797598,0.70243 0.3242851,1.04472 0.1452428,0.34448 ' +\n '0.3214064,0.6644 0.5227339,0.96066 l -1.1993431,1.19723 1.5840256,1.56011 1.1964668,-1.19348 ' +\n 'c 0.6140517,0.40346 1.3028827,0.68232 2.0233517,0.82331 l 7.19e-4,1.69892 h 2.226848 z ' +\n 'm 0.221462,-3.9957 c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 ' +\n '0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 ' +\n '0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z'\n },\n 'TASK_TYPE_SERVICE_FILL': {\n d: 'm {mx},{my} c -1.788948,0.7502 -3.8576,-0.0928 -4.6097055,-1.87438 -0.7521065,-1.78321 ' +\n '0.090598,-3.84627 1.8802645,-4.59604 1.78823,-0.74936 3.856881,0.0929 4.608987,1.87437 ' +\n '0.752106,1.78165 -0.0906,3.84612 -1.879546,4.59605 z'\n },\n 'TASK_TYPE_BUSINESS_RULE_HEADER': {\n d: 'm {mx},{my} 0,4 20,0 0,-4 z'\n },\n 'TASK_TYPE_BUSINESS_RULE_MAIN': {\n d: 'm {mx},{my} 0,12 20,0 0,-12 z' +\n 'm 0,8 l 20,0 ' +\n 'm -13,-4 l 0,8'\n },\n 'MESSAGE_FLOW_MARKER': {\n d: 'm {mx},{my} m -10.5 ,-7 l 0,14 l 21,0 l 0,-14 z l 10.5,6 l 10.5,-6'\n }\n };\n\n this.getRawPath = function getRawPath(pathId) {\n return this.pathMap[pathId].d;\n };\n\n /**\n * Scales the path to the given height and width.\n * <h1>Use case</h1>\n * <p>Use case is to scale the content of elements (event, gateways) based\n * on the element bounding box's size.\n * </p>\n * <h1>Why not transform</h1>\n * <p>Scaling a path with transform() will also scale the stroke and IE does not support\n * the option 'non-scaling-stroke' to prevent this.\n * Also there are use cases where only some parts of a path should be\n * scaled.</p>\n *\n * @param {String} pathId The ID of the path.\n * @param {Object} param <p>\n * Example param object scales the path to 60% size of the container (data.width, data.height).\n * <pre>\n * {\n * xScaleFactor: 0.6,\n * yScaleFactor:0.6,\n * containerWidth: data.width,\n * containerHeight: data.height,\n * position: {\n * mx: 0.46,\n * my: 0.2,\n * }\n * }\n * </pre>\n * <ul>\n * <li>targetpathwidth = xScaleFactor * containerWidth</li>\n * <li>targetpathheight = yScaleFactor * containerHeight</li>\n * <li>Position is used to set the starting coordinate of the path. M is computed:\n * <ul>\n * <li>position.x * containerWidth</li>\n * <li>position.y * containerHeight</li>\n * </ul>\n * Center of the container <pre> position: {\n * mx: 0.5,\n * my: 0.5,\n * }</pre>\n * Upper left corner of the container\n * <pre> position: {\n * mx: 0.0,\n * my: 0.0,\n * }</pre>\n * </li>\n * </ul>\n * </p>\n *\n */\n this.getScaledPath = function getScaledPath(pathId, param) {\n var rawPath = this.pathMap[pathId];\n\n // positioning\n // compute the start point of the path\n var mx, my;\n\n if (param.abspos) {\n mx = param.abspos.x;\n my = param.abspos.y;\n } else {\n mx = param.containerWidth * param.position.mx;\n my = param.containerHeight * param.position.my;\n }\n\n var coordinates = {}; //map for the scaled coordinates\n if (param.position) {\n\n // path\n var heightRatio = (param.containerHeight / rawPath.height) * param.yScaleFactor;\n var widthRatio = (param.containerWidth / rawPath.width) * param.xScaleFactor;\n\n\n //Apply height ratio\n for (var heightIndex = 0; heightIndex < rawPath.heightElements.length; heightIndex++) {\n coordinates['y' + heightIndex] = rawPath.heightElements[heightIndex] * heightRatio;\n }\n\n //Apply width ratio\n for (var widthIndex = 0; widthIndex < rawPath.widthElements.length; widthIndex++) {\n coordinates['x' + widthIndex] = rawPath.widthElements[widthIndex] * widthRatio;\n }\n }\n\n //Apply value to raw path\n var path = format(\n rawPath.d, {\n mx: mx,\n my: my,\n e: coordinates\n }\n );\n return path;\n };\n}", "title": "" }, { "docid": "7e3987b54f2a77902f5d3a18ca095f5a", "score": "0.5677307", "text": "getFieldsMap(path) {\r\n\t let current = this.value;\r\n\t if (!current.mapValue.fields) {\r\n\t current.mapValue = { fields: {} };\r\n\t }\r\n\t for (let i = 0; i < path.length; ++i) {\r\n\t let next = current.mapValue.fields[path.get(i)];\r\n\t if (!isMapValue(next) || !next.mapValue.fields) {\r\n\t next = { mapValue: { fields: {} } };\r\n\t current.mapValue.fields[path.get(i)] = next;\r\n\t }\r\n\t current = next;\r\n\t }\r\n\t return current.mapValue.fields;\r\n\t }", "title": "" }, { "docid": "8b14f5d895ea095705ec5e1be98480b0", "score": "0.5630811", "text": "function PathMap() {\n\n var PATH_USER_TYPE_1 = 'm {mx},{my} c 0.909,-0.845 1.594,-2.049 1.594,-3.385 0,-2.554 -1.805,-4.62199999 ' +\n '-4.357,-4.62199999 -2.55199998,0 -4.28799998,2.06799999 -4.28799998,4.62199999 0,1.348 ' +\n '0.974,2.562 1.89599998,3.405 -0.52899998,0.187 -5.669,2.097 -5.794,4.7560005 v 6.718 ' +\n 'h 17 v -6.718 c 0,-2.2980005 -5.5279996,-4.5950005 -6.0509996,-4.7760005 z' +\n 'm -8,6 l 0,5.5 m 11,0 l 0,-5';\n\n var PATH_USER_TYPE_2 = 'm {mx},{my} m 2.162,1.009 c 0,2.4470005 -2.158,4.4310005 -4.821,4.4310005 ' +\n '-2.66499998,0 -4.822,-1.981 -4.822,-4.4310005';\n\n var PATH_USER_TYPE_3 = 'm {mx},{my} m -6.9,-3.80 c 0,0 2.25099998,-2.358 4.27399998,-1.177 2.024,1.181 4.221,1.537 ' +\n '4.124,0.965 -0.098,-0.57 -0.117,-3.79099999 -4.191,-4.13599999 -3.57499998,0.001 ' +\n '-4.20799998,3.36699999 -4.20699998,4.34799999 z';\n\n /**\n * Contains a map of path elements\n *\n * <h1>Path definition</h1>\n * A parameterized path is defined like this:\n * <pre>\n * 'EVENT_TIMER_WH': {\n * d: 'M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ',\n * height: 17.5,\n * width: 17.5,\n * heightElements: [2.5, 7.5],\n * widthElements: [2.5, 7.5]\n * }\n * </pre>\n * <p>It's important to specify a correct <b>height and width</b> for the path as the scaling\n * is based on the ratio between the specified height and width in this object and the\n * height and width that is set as scale target (Note x,y coordinates will be scaled with\n * individual ratios).</p>\n * <p>The '<b>heightElements</b>' and '<b>widthElements</b>' array must contain the values that will be scaled.\n * The scaling is based on the computed ratios.\n * Coordinates on the y axis should be in the <b>heightElement</b>'s array, they will be scaled using\n * the computed ratio coefficient.\n * In the parameterized path the scaled values can be accessed through the 'e' object in {} brackets.\n * <ul>\n * <li>The values for the y axis can be accessed in the path string using {e.y0}, {e.y1}, ....</li>\n * <li>The values for the x axis can be accessed in the path string using {e.x0}, {e.x1}, ....</li>\n * </ul>\n * The numbers x0, x1 respectively y0, y1, ... map to the corresponding array index.\n * </p>\n */\n this.pathMap = {\n\n // TASK DECORATOR\n\n 'TASK_TYPE_FOLDER': {\n d: 'm {mx},{my} l18,0 l0,12 l-18,0 l0,-12 m 2,0 l3,-4 l5,0 l3,4'\n },\n 'TASK_TYPE_CHEVRON': {\n d: 'm {mx},{my} l15,0 l6,6 l-6,6 l-15,0 l6,-6 l-6,-6'\n },\n 'TASK_TYPE_USER_1': {\n d: PATH_USER_TYPE_1\n },\n 'TASK_TYPE_USER_2': {\n d: PATH_USER_TYPE_2\n },\n 'TASK_TYPE_USER_3': {\n d: PATH_USER_TYPE_3\n },\n 'TASK_TYPE_MANUAL': {\n d: 'm {mx},{my} c 0.234,-0.01 5.604,0.008 8.029,0.004 0.808,0 1.271,-0.172 1.417,-0.752 0.227,-0.898 ' +\n '-0.334,-1.314 -1.338,-1.316 -2.467,-0.01 -7.886,-0.004 -8.108,-0.004 -0.014,-0.079 0.016,-0.533 0,-0.61 ' +\n '0.195,-0.042 8.507,0.006 9.616,0.002 0.877,-0.007 1.35,-0.438 1.353,-1.208 0.003,-0.768 -0.479,-1.09 ' +\n '-1.35,-1.091 -2.968,-0.002 -9.619,-0.013 -9.619,-0.013 v -0.591 c 0,0 5.052,-0.016 7.225,-0.016 ' +\n '0.888,-0.002 1.354,-0.416 1.351,-1.193 -0.006,-0.761 -0.492,-1.196 -1.361,-1.196 -3.473,-0.005 ' +\n '-10.86,-0.003 -11.0829995,-0.003 -0.022,-0.047 -0.045,-0.094 -0.069,-0.139 0.3939995,-0.319 ' +\n '2.0409995,-1.626 2.4149995,-2.017 0.469,-0.4870005 0.519,-1.1650005 0.162,-1.6040005 -0.414,-0.511 ' +\n '-0.973,-0.5 -1.48,-0.236 -1.4609995,0.764 -6.5999995,3.6430005 -7.7329995,4.2710005 -0.9,0.499 ' +\n '-1.516,1.253 -1.882,2.19 -0.37000002,0.95 -0.17,2.01 -0.166,2.979 0.004,0.718 -0.27300002,1.345 ' +\n '-0.055,2.063 0.629,2.087 2.425,3.312 4.859,3.318 4.6179995,0.014 9.2379995,-0.139 13.8569995,-0.158 ' +\n '0.755,-0.004 1.171,-0.301 1.182,-1.033 0.012,-0.754 -0.423,-0.969 -1.183,-0.973 -1.778,-0.01 ' +\n '-5.824,-0.004 -6.04,-0.004 10e-4,-0.084 0.003,-0.586 10e-4,-0.67 z'\n },\n\n 'TASK_TYPE_BUSINESS_RULE_HEADER': {\n d: 'm {mx},{my} 0,4 20,0 0,-4 z'\n },\n 'TASK_TYPE_BUSINESS_RULE_MAIN': {\n d: 'm {mx},{my} 0,12 20,0 0,-12 z' +\n 'm 0,8 l 20,0 ' +\n 'm -13,-4 l 0,8'\n },\n\n // EVENT LISTENER DECORATOR\n\n 'EVENT_TIMER_WH': {\n d: 'M {mx},{my} l {e.x0},-{e.y0} m -{e.x0},{e.y0} l {e.x1},{e.y1} ',\n height: 36,\n width: 36,\n heightElements: [10, 2],\n widthElements: [3, 7]\n },\n 'EVENT_TIMER_LINE': {\n d: 'M {mx},{my} ' +\n 'm {e.x0},{e.y0} l -{e.x1},{e.y1} ',\n height: 36,\n width: 36,\n heightElements: [10, 3],\n widthElements: [0, 0]\n },\n\n 'EVENT_USER_1': {\n d: PATH_USER_TYPE_1,\n height: 36,\n width: 36,\n heightElements: [],\n widthElements: []\n\n },\n 'EVENT_USER_2': {\n d: PATH_USER_TYPE_2,\n height: 36,\n width: 36,\n heightElements: [],\n widthElements: []\n },\n 'EVENT_USER_3': {\n d: PATH_USER_TYPE_3,\n height: 36,\n width: 36,\n heightElements: [],\n widthElements: []\n },\n\n // MARKERS\n\n 'MARKER_STAGE_EXPANDED': {\n d: 'm{mx},{my} m 2,7 l 10,0',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_STAGE_COLLAPSED': {\n d: 'm{mx},{my} m 2,7 l 10,0 m -5,-5 l 0,10',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_REQUIRED': {\n d: 'm{mx},{my} l 0,9 m 0,2 l0,3',\n height: 14,\n width: 3,\n heightElements: [],\n widthElements: []\n },\n\n 'MARKER_MANUAL_ACTIVATION': {\n d: 'm{mx}, {my} l 14,7 l -14,7 l 0,-14 z',\n height: 14,\n width: 14,\n heightElements: [],\n widthElements: []\n },\n\n 'MARKER_REPEATABLE': {\n d: 'm{mx},{my} m 3,0 l 0,14 m 6,-14 l 0,14 m -10,-10 l 14,0 m -14,6 l 14,0',\n height: 14,\n width: 14,\n heightElements: [],\n widthElements: []\n },\n\n 'MARKER_PLANNING_TABLE_EXPANDED': {\n d: 'm{mx},{my} m 0,12 l 30,0 m -20,-12 l 0, 24 m 10, -24 l 0, 24 m -10, -6 l 10,0',\n height: 24,\n width: 30,\n heightElements: [],\n widthElements: []\n },\n 'MARKER_PLANNING_TABLE_COLLAPSED': {\n d: 'm{mx},{my} m 0,12 l 30,0 m -20,-12 l 0, 24 m 10, -24 l 0, 24 m -10, -6 l 10,0 m -5, -6 l 0,12',\n height: 10,\n width: 10,\n heightElements: [],\n widthElements: []\n },\n\n 'DATA_OBJECT_PATH': {\n d:'m 0,0 {e.x1},0 {e.x0},{e.y0} 0,{e.y1} -{e.x2},0 0,-{e.y2} {e.x1},0 0,{e.y0} {e.x0},0',\n height: 61,\n width: 51,\n heightElements: [10, 50, 60],\n widthElements: [10, 40, 50, 60]\n },\n\n 'TEXT_ANNOTATION': {\n d: 'm {mx}, {my} m 10,0 l -10,0 l 0,{e.y0} l 10,0',\n height: 30,\n width: 10,\n heightElements: [30],\n widthElements: [10]\n }\n };\n\n this.getRawPath = function getRawPath(pathId) {\n return this.pathMap[pathId].d;\n };\n\n /**\n * Scales the path to the given height and width.\n * <h1>Use case</h1>\n * <p>Use case is to scale the content of elements (event) based\n * on the element bounding box's size.\n * </p>\n * <h1>Why not transform</h1>\n * <p>Scaling a path with transform() will also scale the stroke and IE does not support\n * the option 'non-scaling-stroke' to prevent this.\n * Also there are use cases where only some parts of a path should be\n * scaled.</p>\n *\n * @param {String} pathId The ID of the path.\n * @param {Object} param <p>\n * Example param object scales the path to 60% size of the container (data.width, data.height).\n * <pre>\n * {\n * xScaleFactor: 0.6,\n * yScaleFactor:0.6,\n * containerWidth: data.width,\n * containerHeight: data.height,\n * position: {\n * mx: 0.46,\n * my: 0.2,\n * }\n * }\n * </pre>\n * <ul>\n * <li>targetpathwidth = xScaleFactor * containerWidth</li>\n * <li>targetpathheight = yScaleFactor * containerHeight</li>\n * <li>Position is used to set the starting coordinate of the path. M is computed:\n * <ul>\n * <li>position.x * containerWidth</li>\n * <li>position.y * containerHeight</li>\n * </ul>\n * Center of the container <pre> position: {\n * mx: 0.5,\n * my: 0.5,\n * }</pre>\n * Upper left corner of the container\n * <pre> position: {\n * mx: 0.0,\n * my: 0.0,\n * }</pre>\n * </li>\n * </ul>\n * </p>\n *\n */\n this.getScaledPath = function getScaledPath(pathId, param) {\n var rawPath = this.pathMap[pathId];\n\n // positioning\n // compute the start point of the path\n var mx, my;\n\n if (param.abspos) {\n mx = param.abspos.x;\n my = param.abspos.y;\n } else {\n mx = param.containerWidth * param.position.mx;\n my = param.containerHeight * param.position.my;\n }\n\n var coordinates = {}; //map for the scaled coordinates\n if (param.position) {\n\n // path\n var heightRatio = (param.containerHeight / rawPath.height) * param.yScaleFactor;\n var widthRatio = (param.containerWidth / rawPath.width) * param.xScaleFactor;\n\n\n //Apply height ratio\n for (var heightIndex = 0; heightIndex < rawPath.heightElements.length; heightIndex++) {\n coordinates['y' + heightIndex] = rawPath.heightElements[heightIndex] * heightRatio;\n }\n\n //Apply width ratio\n for (var widthIndex = 0; widthIndex < rawPath.widthElements.length; widthIndex++) {\n coordinates['x' + widthIndex] = rawPath.widthElements[widthIndex] * widthRatio;\n }\n }\n\n //Apply value to raw path\n var path = Snap.format(\n rawPath.d, {\n mx: mx,\n my: my,\n e: coordinates\n }\n );\n return path;\n };\n}", "title": "" }, { "docid": "505f9d77be231d965f3069b1f26001e4", "score": "0.50937355", "text": "get gltfElementMap() {\n return this[$gltfElementMap];\n }", "title": "" }, { "docid": "dedd791f8e2d1bc5b129aaa899a74e23", "score": "0.5072527", "text": "get pathArray(){\r\n\t\treturn this.__items != null ?\r\n\t\t\tthis.get('focused', \r\n\t\t\t\tfunction(e, i, p){ return p }) \r\n\t\t\t// XXX do we use .options.path???\r\n\t\t\t// XXX is this an array???\r\n\t\t\t: (this.options || {}).path }", "title": "" }, { "docid": "f75f929d90da41243e65e83e0d8cffbe", "score": "0.49729523", "text": "function renderPath(path) {\n let map = {};\n let x = 0;\n let y = 0;\n for (let instruction of path) {\n let direction = instruction[0];\n let distance = parseInt(instruction.substr(1));\n // console.log(`going through instruction ${direction} for ${distance}.`);\n for (let i = 0; i < distance; i++) {\n if (direction === 'U') {\n y += 1;\n }\n else if (direction === 'R') {\n x += 1;\n }\n else if (direction === 'D') {\n y -= 1;\n }\n else if (direction === 'L') {\n x -= 1;\n }\n else {\n throw `wtf is ${direction}? that's not a direction.`\n }\n let coords = `${x},${y}`;\n if (map[coords]) {\n console.log(`overlap with self at ${coords}.`);\n map[coords]++;\n } else {\n map[coords] = 1;\n }\n }\n }\n return map;\n}", "title": "" }, { "docid": "d3c32f2076859ffb5cfdf3eb3451f066", "score": "0.49494797", "text": "selectedPaths () {\n return Array.from(this.getSelectedEntries()).map((entry) => entry.getPath())\n }", "title": "" }, { "docid": "e0c61dd22c08d372f09dec02e35e2c39", "score": "0.49188724", "text": "getElement(compositePath, defaultValue = null) {\n const value = getMapElement(compositePath, this.multiLevels);\n return value instanceof NotFound ? defaultValue : value;\n }", "title": "" }, { "docid": "526694594d3eced6eaf1617bd896069c", "score": "0.48967493", "text": "mapify_(path, value) {\n if (typeof value == 'object') { // Catches arrays too, arrays are objects\n for (var key in value) { // If an array, key would be an index\n this.mapify_(path.concat([key]), value[key]); // RECURSION!\n\n let element = value[key];\n let elementPath = path.concat([key]);\n if (element instanceof Array) {\n let mapping = findMapping(elementPath);\n if (mapping) {\n value[mapping.newMap] = this.arrayToMap_(element, mapping.keyBy);\n }\n }\n }\n }\n return value;\n }", "title": "" }, { "docid": "86d924e2b82fc320c75e1347c2063e36", "score": "0.48548356", "text": "function getPaths(items) {\n var paths = {}, d, offset = .5 * y2(1) + 0.5, result = [];\n for (var i = 0; i < items.length; i++) {\n d = items[i];\n if (!paths[d.class]) paths[d.class] = '';\n paths[d.class] += ['M', x(d.start), (y2(d.lane) + offset), 'H', x(d.end)].join(' ');\n }\n\n for (var className in paths) {\n result.push({class: className, path: paths[className]});\n }\n\n return result;\n }", "title": "" }, { "docid": "3f88f465eea5e835fe46f88acdab9429", "score": "0.48467618", "text": "function docPosToMapPos(xPix,yPix){\n var TrsfMatrix=document.getElementById(\"GroupIcons\").getCTM();\n console.log(\"La matrice di trasformazione è \" + TrsfMatrix.a, TrsfMatrix.e, TrsfMatrix.f);\n\t\tvar xMapPosition = (xPix - TrsfMatrix.e)/TrsfMatrix.a;\n\t\tvar yMapPosition = (yPix - TrsfMatrix.f)/TrsfMatrix.a;\n\t\treturn {\n\t\t\t\txMapPosition: xMapPosition,\n\t\t\t\tyMapPosition: yMapPosition\n\t\t\t\t};\n\t}", "title": "" }, { "docid": "d2c9d10017d622545dbce3d82d3c6653", "score": "0.48143286", "text": "_getAttributeLocations() {\n const attributeLocations = {};\n const length = this.getAttributeCount();\n for (let location = 0; location < length; location++) {\n const name = this.getAttributeName(location);\n attributeLocations[name] = this.getAttributeLocation(name);\n }\n return attributeLocations;\n }", "title": "" }, { "docid": "0721888c3a475800fb422fc4ef173da7", "score": "0.48012155", "text": "getValues() {\n return this.children.map(child => child.getValue());\n }", "title": "" }, { "docid": "1e05da945de415161bdeab44319743db", "score": "0.47726133", "text": "function getConstraints()\n{\n var viewConstraints = VIEW_DATA[CURRENT_VIEW.name].constraint;\n\n var returnConstraints = {};\n\n for(var i=0; i < viewConstraints.length; i++) {\n\treturnConstraints[viewConstraints[i]] = selectorValue(viewConstraints[i]);\n }\n\n return(returnConstraints);\n}", "title": "" }, { "docid": "05b0be838be819d654d08964aafa04bb", "score": "0.47645554", "text": "map(layout){\n\t\tvar map = new src_mapping(layout);\n\t\treturn map.section();\n\t}", "title": "" }, { "docid": "34d3484d6effad61d5090352010bc0de", "score": "0.47468185", "text": "computeFlexData(children = this.getValidChildren(), props = this.props) {\n const pixelFlex = this.computePixelFlex(props.orientation);\n\n const computeFreeFlex = flexData => {\n return flexData.reduce((sum, entry) => {\n if (!__WEBPACK_IMPORTED_MODULE_3__ReflexSplitter__[\"a\" /* default */].isA(entry) && entry.constrained) {\n return sum - entry.flex;\n }\n\n return sum;\n }, 1.0);\n };\n\n const computeFreeElements = flexData => {\n return flexData.reduce((sum, entry) => {\n if (!__WEBPACK_IMPORTED_MODULE_3__ReflexSplitter__[\"a\" /* default */].isA(entry) && !entry.constrained) {\n return sum + 1;\n }\n\n return sum;\n }, 0.0);\n };\n\n const flexDataInit = children.map(child => {\n const props = child.props;\n return {\n maxFlex: (props.maxSize || Number.MAX_VALUE) * pixelFlex,\n sizeFlex: (props.size || Number.MAX_VALUE) * pixelFlex,\n minFlex: (props.minSize || 1) * pixelFlex,\n constrained: props.flex !== undefined,\n guid: props.ref || this.guid(),\n flex: props.flex || 0,\n type: child.type\n };\n });\n\n const computeFlexDataRec = (flexDataIn, depth = 0) => {\n let hasContrain = false;\n const freeElements = computeFreeElements(flexDataIn);\n const freeFlex = computeFreeFlex(flexDataIn);\n const flexDataOut = flexDataIn.map((entry, idx) => {\n if (__WEBPACK_IMPORTED_MODULE_3__ReflexSplitter__[\"a\" /* default */].isA(entry)) {\n return entry;\n }\n\n const proposedFlex = !entry.constrained ? freeFlex / freeElements : entry.flex;\n const constrainedFlex = Math.min(entry.sizeFlex, Math.min(entry.maxFlex, Math.max(entry.minFlex, proposedFlex)));\n const constrained = constrainedFlex !== proposedFlex;\n hasContrain = hasContrain || constrained;\n return __WEBPACK_IMPORTED_MODULE_1__babel_runtime_helpers_objectSpread___default()({}, entry, {\n flex: constrainedFlex,\n constrained\n });\n });\n return hasContrain && depth < this.props.maxRecDepth ? computeFlexDataRec(flexDataOut, depth + 1) : flexDataOut;\n };\n\n const flexData = computeFlexDataRec(flexDataInit);\n return flexData.map(entry => {\n return {\n flex: !__WEBPACK_IMPORTED_MODULE_3__ReflexSplitter__[\"a\" /* default */].isA(entry) ? entry.flex : 0.0,\n guid: entry.guid\n };\n });\n }", "title": "" }, { "docid": "1283ed1983321a1bc22cbcacbb66e76e", "score": "0.46990168", "text": "visitElementValuePairs(ctx) {\n\t return this.visitChildren(ctx);\n\t}", "title": "" }, { "docid": "8abdccf5283918b721ff198774279161", "score": "0.4696453", "text": "get paths () {\n return Array.from(this._paths.keys())\n }", "title": "" }, { "docid": "d058d0733574d77950c91683c402866a", "score": "0.46788123", "text": "get pathArray(){\r\n\t\tvar r = (this.parent || {}).root\r\n\t\treturn r ? \r\n\t\t\tr.pathOf(this)\r\n\t\t\t: undefined }", "title": "" }, { "docid": "d9a89d5ee1eeb35d016000a5c97df8b1", "score": "0.46660587", "text": "function paths_to_victory() {\n\t\tvar paths = {\"first_row\": [\"11\", \"12\", \"13\"], \n\t\t\t\t\t \"second_row\": [\"21\", \"22\", \"23\"], \n\t\t\t\t\t \"third_row\": [\"31\", \"32\", \"33\"], \n\t\t\t\t\t \"first_col\": [\"11\", \"21\", \"31\"], \n\t\t\t\t\t \"second_col\": [\"12\", \"22\", \"32\"], \n\t\t\t\t\t \"third_col\": [\"13\", \"23\", \"33\"], \n\t\t\t\t\t \"first_diag\": [\"11\", \"22\", \"33\"],\n\t\t\t\t\t \"second_diag\": [\"13\", \"22\", \"31\"]}\n\n\t\t// deletes paths along which a win is impossible\n\n\t\tjQuery.each(paths, function(path_key, path_val) {\n\t\t\tjQuery.each(human_boxes(), function(box_index, box_val) {\n\t\t\t\tif (path_val.includes(box_val)) {\n\t\t\t\t\tdelete paths[path_key]\n\t\t\t\t}\n\t\t\t})\n\t\t})\n\n\t\t// remove any elements of values that have already been selected by the computer\n\n\t\tjQuery.each(paths, function(path_key, path_val) {\n\t\t\tjQuery.each(computer_boxes(), function(box_index, box_val) {\n\t\t\t\tif (path_val.includes(box_val)) {\n\t\t\t\t\tvar index = path_val.indexOf(box_val)\n\t\t\t\t\tpath_val.splice(index,1)\n\t\t\t\t}\n\t\t\t})\n\t\t})\n\n\t\treturn paths\n\n\t}", "title": "" }, { "docid": "cd3b505eeb42ba330431a8d614d3287a", "score": "0.46473652", "text": "function collectKeys(host, content) {\n var node = host.firstChild;\n var keyMap = Object.create(null);\n for (var _i = 0, content_1 = content; _i < content_1.length; _i++) {\n var vNode = content_1[_i];\n if (vNode.type === 'element' && vNode.attrs.key) {\n keyMap[vNode.attrs.key] = { vNode: vNode, element: node };\n }\n node = node.nextSibling;\n }\n return keyMap;\n }", "title": "" }, { "docid": "afe57301552a4aebfc2d76aaf7fecfff", "score": "0.4640963", "text": "function collectKeys(host, content) {\r\n var node = host.firstChild;\r\n var keyMap = Object.create(null);\r\n for (var _i = 0, content_1 = content; _i < content_1.length; _i++) {\r\n var vNode = content_1[_i];\r\n if (vNode.type === 'element' && vNode.attrs.key) {\r\n keyMap[vNode.attrs.key] = { vNode: vNode, element: node };\r\n }\r\n node = node.nextSibling;\r\n }\r\n return keyMap;\r\n }", "title": "" }, { "docid": "5944c6c8a0df5d588c78440a92d83264", "score": "0.4623564", "text": "function nodeChildrenAsMap(node) {\n var map$$1 = {};\n if (node) {\n node.children.forEach(function (child) { return map$$1[child.value.outlet] = child; });\n }\n return map$$1;\n}", "title": "" }, { "docid": "5944c6c8a0df5d588c78440a92d83264", "score": "0.4623564", "text": "function nodeChildrenAsMap(node) {\n var map$$1 = {};\n if (node) {\n node.children.forEach(function (child) { return map$$1[child.value.outlet] = child; });\n }\n return map$$1;\n}", "title": "" }, { "docid": "5944c6c8a0df5d588c78440a92d83264", "score": "0.4623564", "text": "function nodeChildrenAsMap(node) {\n var map$$1 = {};\n if (node) {\n node.children.forEach(function (child) { return map$$1[child.value.outlet] = child; });\n }\n return map$$1;\n}", "title": "" }, { "docid": "5944c6c8a0df5d588c78440a92d83264", "score": "0.4623564", "text": "function nodeChildrenAsMap(node) {\n var map$$1 = {};\n if (node) {\n node.children.forEach(function (child) { return map$$1[child.value.outlet] = child; });\n }\n return map$$1;\n}", "title": "" }, { "docid": "5944c6c8a0df5d588c78440a92d83264", "score": "0.4623564", "text": "function nodeChildrenAsMap(node) {\n var map$$1 = {};\n if (node) {\n node.children.forEach(function (child) { return map$$1[child.value.outlet] = child; });\n }\n return map$$1;\n}", "title": "" }, { "docid": "5944c6c8a0df5d588c78440a92d83264", "score": "0.4623564", "text": "function nodeChildrenAsMap(node) {\n var map$$1 = {};\n if (node) {\n node.children.forEach(function (child) { return map$$1[child.value.outlet] = child; });\n }\n return map$$1;\n}", "title": "" }, { "docid": "50277bff90f0eeaa6e820ed31c84dc29", "score": "0.46046996", "text": "[Symbol.iterator]() {\n return this.values(this._root);\n }", "title": "" }, { "docid": "9b81f8ee092a71cb6c80cecd245cbe68", "score": "0.4600978", "text": "function mapPosToDocPos(xPix,yPix){\n var TrsfMatrix=document.getElementById(\"GroupIcons\").getCTM();\n\t\tvar xDocPosition = xPix * TrsfMatrix.a + TrsfMatrix.e\n\t\tvar yDocPosition = yPix * TrsfMatrix.a + TrsfMatrix.f\n\n\t\treturn {\n\t\t\t\txDocPosition: xDocPosition,\n\t\t\t\tyDocPosition: yDocPosition\n\t\t\t\t};\n\t}", "title": "" }, { "docid": "9741ebc614eac60a540e7b1a10b12218", "score": "0.4596072", "text": "values(){\n let valuesarr=[];\n for(let i=0;i<this.keyMap.length;i++){ //iterate over keymap\n if(this.keyMap[i]) { //if something at that index\n for(let j=0;j<this.keyMap[i].length;j++) { // iterate over each index completely\n if(!valuesarr.includes(this.keyMap[i][j][1])){\n valuesarr.push(this.keyMap[i][j][1]);\n }\n }\n }\n }\n return valuesarr;\n }", "title": "" }, { "docid": "feedb8cd0bcafeccf85f18d04fd579d2", "score": "0.4593849", "text": "function findInfo(path){\n var result;\n allInfo.forEach(function(element){\n if(element.inside.indexOf(element)){\n result=element;\n }\n });\n return result\n}", "title": "" }, { "docid": "d0d5f31652e00d436df653b30ff761f1", "score": "0.45902902", "text": "get selectedElements() {\n return this.selections.map(node => this.layout.elementFromNode(node));\n }", "title": "" }, { "docid": "1a45810b998eea863d57ec8d76bfec60", "score": "0.4584051", "text": "function getLayoutMiniMaps(structures) {\n var structureToLayout = [];\n angular.forEach(structures, function(val, key) {\n var layout = [];\n angular.forEach(val.rows, function(row) {\n angular.forEach(row.columns, function(col) {\n layout.push(col.styleClass.split('-')[2]);\n });\n });\n structureToLayout[key] = layout;\n });\n return structureToLayout;\n }", "title": "" }, { "docid": "b8de664fc8f1f7c912d3a5c8483e0dbd", "score": "0.45769548", "text": "function NavigationMap() {\n\n\tthis.content = [\n\t\t[[],[],[]],\n\t\t[[],[scalarview.currentNode],[]],\n\t\t[[],[],[]]\n\t]\n\tthis.btnType = [\n\t\t['up','up','up'],\n\t\t['left','self','right'],\n\t\t['down','down','down']\n\t]\n\tthis.enclosingPaths = [];\n\t\n\tvar containedNodes;\n\tif (scalarview.currentNode == scalarview.tocNode) {\n\t\tcontainedNodes = scalarview.currentNode.getRelatedNodes('referee', 'outgoing', true);\n\t} else {\n\t\tcontainedNodes = scalarview.currentNode.getRelatedNodes('path', 'outgoing');\n\t}\n\tif (containedNodes.length > 0) {\n\t\tthis.content[2][2].push(containedNodes[0]);\n\t}\n\t\n\tvar containingNodes = scalarview.currentNode.getRelatedNodes('path', 'incoming');\n\tif (containingNodes.length > 0) {\n\t\n\t\t// what if we're contained by more than one path?\n\t\n\t\tvar containingNode = containingNodes[0];\n\t\tthis.content[0][0].push(containingNode);\n\t\t\n\t\tcontainedNodes = containingNode.getRelatedNodes('path', 'outgoing');\n\t\t\n\t\tvar i;\n\t\tvar n = containedNodes.length;\n\t\tvar node;\n\t\tvar pageIndex = -2;\n\t\tfor (i=0; i<n; i++) {\n\t\t\tnode = containedNodes[i];\n\t\t\tif (node == scalarview.currentNode) {\n\t\t\t\tpageIndex = i;\n\t\t\t\tif (i > 0) {\n\t\t\t\t\tthis.content[1][0].push(containedNodes[i-1]);\n\t\t\t\t}\n\t\t\t}\n\t\t\tif (i == (pageIndex + 1)) {\n\t\t\t\tthis.content[1][2].push(node);\n\t\t\t\tbreak;\n\t\t\t}\n\t\t}\n\n\t} else if (scalarview.currentNode != scalarview.tocNode) {\n\t\tthis.content[0][0].push(scalarview.tocNode);\n\t}\n\t\n}", "title": "" }, { "docid": "f4e3ccecda44d36d8cb5968907f00fa4", "score": "0.4570061", "text": "function getDat(p){ // pathPoint\r with(p) return [anchor, rightDirection, leftDirection, pointType];\r}", "title": "" }, { "docid": "cd654cf4749ed13336c09ccdee70e853", "score": "0.45636803", "text": "function makefirstpaths(specs, rekt, exix){\n\tfor(var i = BORDER; i < rekt[0].y + PATHSIZE; i++){\n\t\tfor(var j = exix - 1; j < exix + PATHSIZE + 1; j++){\n\t\t\theightmap[i][j] = specs.height;\n\t\t}\n\t}\n\n\tfor(i = rekt[0].y; i < rekt[0].y + PATHSIZE; i++){\n\t\tif(rekt[0].x < exix){\n\t\t\tfor(j = exix + PATHSIZE - 1; j > rekt[0].x; j--) heightmap[i][j] = specs.height;\n\t\t} else {\n\t\t\tfor(j = exix; j < rekt[0].x; j++) heightmap[i][j] = specs.height;\n\t\t}\n\t}\n}", "title": "" }, { "docid": "5f532213c64540e2160d15aedca7d598", "score": "0.4558667", "text": "getActualPath () {\n let progress = this.getClampedProgress()\n\n let newPath = []\n\n for (let i = 0; i < this.nextPath.length; i++) {\n let interpolationX = (this.nextPath[i].x - this.currentPath[i].x) * progress + this.currentPath[i].x\n let interpolationY = (this.nextPath[i].y - this.currentPath[i].y) * progress + this.currentPath[i].y\n\n newPath = [...newPath, ...[{\n type: this.nextPath[i].type,\n x: interpolationX,\n y: interpolationY\n }]]\n }\n\n return newPath\n }", "title": "" }, { "docid": "7c302a62a4a680367e69218b477c15d8", "score": "0.45570675", "text": "function reconstruct_path(came_from, current){\n var total_path = [];\n while(current in came_from){\n current = came_from[current];\n total_path.push(current);\n }\n total_path = total_path.map(function(a){\n var splt = a.split('x')\n var x = splt[1]\n var y = splt[0]\n return [parseInt(x), parseInt(y)]\n })\n total_path = total_path.splice(1)\n return total_path.reverse();\n }", "title": "" }, { "docid": "781891d0d3ad12a99e8eeeb7e95c8aef", "score": "0.455319", "text": "function extractSVGPaths(svgDoc) {\r\n\r\n var ret = [];\r\n // rect, polygon should've been converted to <path> by SVGO at this point\r\n if (svgDoc.getElementsByTagName('rect').length>0) console.warn(\"Only SVG <path>'s are supported; ignoring <rect> items\");\r\n if (svgDoc.getElementsByTagName('polygon').length>0) console.warn(\"Only SVG <path>'s are supported; ignoring <polygon> items\");\r\n if (svgDoc.getElementsByTagName('line').length>0) console.warn(\"Only SVG <path>'s are supported; ignoring <line> items\");\r\n\r\n // These elements are not supported:\r\n if (svgDoc.getElementsByTagName('image').length>0) console.warn(\"Only SVG <path>'s are supported; ignoring <image> items\");\r\n if (svgDoc.getElementsByTagName('text').length>0) console.warn(\"Only SVG <path>'s are supported; ignoring <text> items\");\r\n\r\n\r\n /*\r\n * A few helper functions to get information about the path (color, stroke weight)\r\n */\r\n function getFillColor(el){\r\n // Should look up CSS Class too...\r\n var f= el.getAttribute(\"fill\") || null;\r\n if (f==\"transparent\" || f==\"none\") f = null;\r\n return f;\r\n }\r\n function getStrokeColor(el){\r\n return el.getAttribute(\"stroke\") || null;\r\n }\r\n function getStrokeWidth(el){\r\n return (el.getAttribute(\"stroke-width\")*1) || (el.getAttribute(\"stroke\")?1:0);\r\n }\r\n function getScaleTransform(path){\r\n // Reference: https://developer.mozilla.org/en/docs/Web/API/SVGTransform\r\n var ret = {x:1, y:1};\r\n for (var i=0; i<path.transform.baseVal.length; i++) {\r\n if (path.transform.baseVal[i].type==3) {ret.x += path.transform.baseVal[i].matrix.a; ret.y += path.transform.baseVal[i].matrix.d;}\r\n }\r\n return ret;\r\n }\r\n function getTranslateTransform(path){\r\n var ret = {x:0, y:0};\r\n for (var i=0; i<path.transform.baseVal.length; i++) {\r\n if (path.transform.baseVal[i].type==2) {ret.x += path.transform.baseVal[i].matrix.e; ret.y += path.transform.baseVal[i].matrix.f;}\r\n }\r\n return ret;\r\n }\r\n\r\n\r\n /*\r\n * Helper funcs to create pretty SVG Path strings \r\n */\r\n function pathobject2str(dat){\r\n return dat.reduce(function (acc, val){\r\n return acc + ' ' + val.type + ' ' + val.values.join(' ');\r\n },'');\r\n }\r\n function circleAttrsToPath(r,cx,cy) {\r\n return `M ${cx-r},${cy} a ${r},${r} 0 1,0 ${r*2},0 a ${r},${r} 0 1,0 -${r*2},0`;\r\n };\r\n function ellipseAttrsToPath (rx,cx,ry,cy) {\r\n return `M${cx-rx},${cy} a ${rx},${ry} 0 1,0 ${rx*2},0 a ${rx},${ry} 0 1,0 -${rx*2},0`;\r\n }\r\n\r\n\r\n // Process each <path> element\r\n Array.prototype.slice.call(svgDoc.getElementsByTagName('path')).map(function (path) {\r\n\r\n //var d = pathobject2str(path.getPathData());\r\n var tmp = {\r\n strokeWidth: getStrokeWidth(path),\r\n closed: path.getAttribute('d').search(/Z/i)>0,\r\n d: path.getAttribute('d'), // was \"pathobject2str(path.getPathData());\" but I think this is not necessary...\r\n fillColor: getFillColor(path),\r\n strokeColor: getStrokeColor(path),\r\n scale: getScaleTransform(path),\r\n translate: getTranslateTransform(path),\r\n path: path};\r\n\r\n if (tmp.fillColor==null) tmp.closed=false;\r\n\r\n ret.push(tmp);\r\n\r\n });\r\n\r\n\r\n\r\n // Process each <circle> element\r\n //https://stackoverflow.com/questions/5737975/circle-drawing-with-svgs-arc-path\r\n Array.prototype.slice.call(svgDoc.getElementsByTagName('circle')).map(function (path) {\r\n\r\n var tmp = {\r\n strokeWidth: getStrokeWidth(path),\r\n closed: true,\r\n d: circleAttrsToPath( path.r.baseVal.value, path.cx.baseVal.value, path.cy.baseVal.value),\r\n fillColor: getFillColor(path),\r\n strokeColor: getStrokeColor(path),\r\n scale: getScaleTransform(path),\r\n translate: getTranslateTransform(path),\r\n path: path};\r\n\r\n if (tmp.fillColor==null) tmp.closed=false;\r\n\r\n ret.push(tmp);\r\n\r\n });\r\n\r\n\r\n // Process each <ellipse> element\r\n // https://stackoverflow.com/questions/5737975/circle-drawing-with-svgs-arc-path/10477334#10477334\r\n Array.prototype.slice.call(svgDoc.getElementsByTagName('ellipse')).map(function (path) {\r\n\r\n var tmp = {\r\n strokeWidth: getStrokeWidth(path),\r\n closed: true,\r\n d: ellipseAttrsToPath( path.rx.baseVal.value, path.cx.baseVal.value, path.ry.baseVal.value, path.cy.baseVal.value),\r\n fillColor: getFillColor(path),\r\n strokeColor: getStrokeColor(path),\r\n scale: getScaleTransform(path),\r\n translate: getTranslateTransform(path),\r\n path: path};\r\n\r\n if (tmp.fillColor==null) tmp.closed=false;\r\n\r\n ret.push(tmp);\r\n\r\n });\r\n\r\n\r\n return ret;\r\n\r\n} // function extractSVGPaths()", "title": "" }, { "docid": "4bb2d4b57910dfa655050b8f37c25b48", "score": "0.45518458", "text": "getIndexes() {\n return this.children.map(child => child.currentIndex);\n }", "title": "" }, { "docid": "7f8487a8431c0ce1a91183cd4fd20b73", "score": "0.45411506", "text": "renderMap() {\n this.tree.querySelectorAll(`[${this.attr.parent}]`).forEach(parent => {\n const id = parent.getAttribute(this.attr.parent);\n const state = this.hiddenItems.indexOf(id) !== -1;\n parent.classList.toggle('hide', state);\n });\n }", "title": "" }, { "docid": "dab51cab7636d55c9e752b186ab1003a", "score": "0.45409772", "text": "function getCamundaInOutMappings(element, type) {\n var bo = getBusinessObject(element);\n return extensionElementsHelper.getExtensionElements(bo, type) || [];\n}", "title": "" }, { "docid": "73b7e4728ce6914bbc4d9f6181b3678d", "score": "0.45385426", "text": "function getPathKey0(puzzle, path) {\n return []\n}", "title": "" }, { "docid": "5d06a474afffda7fa83ffa383702d1a7", "score": "0.4532515", "text": "static match(map) {\n let direct = Object.create(null);\n for (let prop in map)\n for (let name of prop.split(\" \"))\n direct[name] = map[prop];\n return (node) => {\n for (let groups = node.prop(NodeProp.group), i = -1; i < (groups ? groups.length : 0); i++) {\n let found = direct[i < 0 ? node.name : groups[i]];\n if (found)\n return found;\n }\n };\n }", "title": "" }, { "docid": "43b7e7692f5410d2141150ee5b16b23d", "score": "0.45085856", "text": "function createDict(item, sourceDom){\n let nodesMap = new Map();\n const numberToCss = JSON.parse(readFileSync(join(dirname(__dirname), 'fathom-products', 'product_classification_test_data', item, 'nodes.txt'), 'utf-8'));\n const elems = sourceDom.getElementsByTagName('*');\n\n //Match each node from the sourceDom to its css, and store in the global dict\n for (let i = 0; i < elems.length; i++){\n nodesMap.set(elems[i], numberToCss[i]);\n }\n\n //check that #nodes in sourceDom match #elements in number->css dictionary\n if (sourceDom.getElementsByTagName('*').length !== nodesMap.size){\n throw 'number of nodes do not match number of elements in css dictionary';\n }\n return nodesMap;\n}", "title": "" }, { "docid": "4d85eaadb8f0717429e928dd88d3bd77", "score": "0.45080873", "text": "function nodeChildrenAsMap(node) {\n var map = {};\n\n if (node) {\n node.children.forEach(function (child) {\n return map[child.value.outlet] = child;\n });\n }\n\n return map;\n }", "title": "" }, { "docid": "4d85eaadb8f0717429e928dd88d3bd77", "score": "0.45080873", "text": "function nodeChildrenAsMap(node) {\n var map = {};\n\n if (node) {\n node.children.forEach(function (child) {\n return map[child.value.outlet] = child;\n });\n }\n\n return map;\n }", "title": "" }, { "docid": "d278bfce0ec5ed56510461bd1c9fb0e0", "score": "0.45035934", "text": "values() { return this.keys.map(k => this.find(k).value); }", "title": "" }, { "docid": "8a6396cc03a590ab98c597d42c360343", "score": "0.44920874", "text": "function get_bounds(path){\r\n var bounding_rect = new google.maps.LatLngBounds();\r\n\r\n $.each(path, function(i,v){\r\n bounding_rect.extend(v);\r\n })\r\n\r\n return bounding_rect;\r\n}", "title": "" }, { "docid": "265f343601a751873d7e244645d3b9ce", "score": "0.44813457", "text": "function XMaps() {}", "title": "" }, { "docid": "4bc060d825bc156c43155d38904e0c2c", "score": "0.44755208", "text": "field(path) {\r\n\t if (path.isEmpty()) {\r\n\t return this.value;\r\n\t }\r\n\t else {\r\n\t let currentLevel = this.value;\r\n\t for (let i = 0; i < path.length - 1; ++i) {\r\n\t currentLevel = (currentLevel.mapValue.fields || {})[path.get(i)];\r\n\t if (!isMapValue(currentLevel)) {\r\n\t return null;\r\n\t }\r\n\t }\r\n\t currentLevel = (currentLevel.mapValue.fields || {})[path.lastSegment()];\r\n\t return currentLevel || null;\r\n\t }\r\n\t }", "title": "" }, { "docid": "9797e82e2378985eb670d9237adbff07", "score": "0.44743216", "text": "getNamespaces() {\n return [...this.paths.keys()];\n }", "title": "" }, { "docid": "e2fba40ce3e93a9afb525766c1bf93e9", "score": "0.44686028", "text": "async getFileMap() {\n // TODO VirtualFileSystem candidate\n if (!isGlob(this.inputPath) && fs.existsSync(this.inputPath)) {\n // When inputPath is a directory, make sure it has a slash for passthrough copy aliasing\n // https://github.com/11ty/eleventy/issues/2709\n let inputPath = this.addTrailingSlashIfDirectory(this.inputPath);\n return [\n {\n inputPath,\n outputPath: this.getOutputPath(),\n },\n ];\n }\n\n let paths = [];\n // If not directory or file, attempt to get globs\n let files = await this.getFiles(this.inputPath);\n for (let inputPath of files) {\n paths.push({\n inputPath,\n outputPath: this.getOutputPath(inputPath),\n });\n }\n\n return paths;\n }", "title": "" }, { "docid": "3ddecf7eb066c66a2103dbef32b28522", "score": "0.44682917", "text": "get path() {\n return this.getAttribute(\"path\");\n }", "title": "" }, { "docid": "473bca044c200e82abdd56209f8aaa64", "score": "0.44606808", "text": "function map_value(d) { return d.map_no }", "title": "" }, { "docid": "ceb786f01a034bb5a798b6881c896b66", "score": "0.44565156", "text": "function iconMapper(structure) {\n \n var iconTypeMap = {}; \n iconTypeMap[\"Conteneur verre\"] = 'resources/images/montpellier/marker_verre.png';\n iconTypeMap[\"Conteneur verre, \"] = 'resources/images/montpellier/marker_verre.png';\n iconTypeMap[\"Conteneurs verre\"] = 'resources/images/montpellier/marker_verre.png';\n iconTypeMap[\"Conteneurs : verre, papier-carton\"] = 'resources/images/montpellier/marker_verre_carton.png'; \n iconTypeMap[\"Conteneur papier-carton\"] = 'resources/images/montpellier/marker_verre_carton.png';\n iconTypeMap[\"Conteneurs : verre, papier-carton, plastique\"] = 'resources/images/montpellier/marker_verre_carton_plastique.png';\n iconTypeMap[\"Conteneurs : papier-carton, plastique\"] = 'resources/images/montpellier/marker_verre_carton_plastique.png';\n iconTypeMap[\"Conteneurs : verre, plastique\"] = 'resources/images/montpellier/marker_verre_carton_plastique.png';\n iconTypeMap[\"Conteneur verre, papier, plastique\"] = 'resources/images/montpellier/marker_verre_carton_plastique.png';\n iconTypeMap[\"Conteneur verre, papier\"] = 'resources/images/montpellier/marker_verre_carton.png';\n \n //LISTE des différentes icônes\n var iconDefault={}; \n var iconBase= {\n //iconUrl: '/resources/images/montpellier/marker_verre.png',\n //shadowUrl: '/resources/images/montpellier/leaf-shadow.png',\n iconSize: [32, 48], // size of the icon\n shadowSize: [32, 48], // size of the shadow\n iconAnchor: [15, 48], // point of the icon which will correspond to marker's location\n shadowAnchor: [4, 30], // the same for the shadow\n popupAnchor: [0, -45] // point from which the popup should open relative to the iconAnchor\n };\n \n if (structure.type in iconTypeMap) {\n \n iconCustom=iconBase;\n iconCustom.iconUrl=iconTypeMap[structure.type];\n return iconCustom;\n } \n else return iconDefault;\n \n }", "title": "" }, { "docid": "e37eea3fe8df4d5700a8fdb92a52b973", "score": "0.44559112", "text": "get points() {\n return parsePath(this.attr('d'));\n }", "title": "" }, { "docid": "501047764959a0dfa2274e811f54959c", "score": "0.44371977", "text": "function updatePathDimensions() {\n layoutOptions.nodeSizeChange && layoutOptions.nodeSizeChange();\n node.select(\"path\")\n .attr(\"d\", function (d) {\n return typeof layoutOptions.nodePath === \"function\" ? layoutOptions.nodePath(d) : layoutOptions.nodePath;\n })\n .attr(\"transform\", function (d) {\n // Scale appropriately using http://stackoverflow.com/a/9877871/6421793\n const currentWidth = this.getBBox().width, w = d.width, currentHeight = this.getBBox().height, h = d.height, scaleW = (w - layoutOptions.margin) / currentWidth, scaleH = (h - layoutOptions.margin) / currentHeight;\n if (isNaN(scaleW) || isNaN(scaleH) || isNaN(w) || isNaN(h)) {\n return \"\";\n }\n return `translate(${-w / 2 + layoutOptions.margin},${-h / 2 + layoutOptions.margin}) scale(${scaleW},${scaleH})`;\n });\n }", "title": "" }, { "docid": "2ea9e0d9d1af00a72378bd599bbba734", "score": "0.44338647", "text": "function getTransform(which){\n var hold = document.getElementById(which).getAttributeNS(null, 'transform');\n var retVal = new Array();\n retVal[0] = hold.substring((hold.search(/\\(/) + 1), hold.search(/,/)); //x value\n retVal[1] = hold.substring((hold.search(/,/) + 1), hold.search(/\\)/)); //y value\n return retVal;\n}", "title": "" }, { "docid": "e8e7907137d888c864060fc06cc5cbab", "score": "0.44336396", "text": "_mapAttr(src) {\n\t\tlet tgt = this.mapping[src];\n\t\treturn tgt ? tgt : src;\n\t}", "title": "" }, { "docid": "c97a44cf9ae5d0d5b6cc222952ec02f2", "score": "0.44334775", "text": "function svgAdminMaps () {\n // Step 1: build array of SVG content\n const SVGContent = []\n for (const curOffice of global.offices) {\n global.logger.log('debug', 'svgAdminMaps: %s', curOffice.name)\n SVGContent.push(`<div class=\"map small\"${curOffice.officeID}>'${getSVG(curOffice.officeID)}'</div>`)\n }\n // Step 2: provide content to render\n return _.flatten(SVGContent).toString()\n}", "title": "" }, { "docid": "43bcf235c3cc4cf2d28333f406f44db7", "score": "0.4432458", "text": "function get_constraints(){\n\t\tvar c = {};\n\t\tc[\"keyword\"] = $('#search_field').val();\n\t\tc[\"length\"] = slider_values;\n\t\tc[\"match_any\"] = $('input[value=match_any]').is(':checked');\n\t\tc[\"attractions\"] = []\n\t\t$('input[name=attractions]:checked').each(function(){\n\t\t\tc[\"attractions\"].push(this.value);\n\t\t});\n\t\t[\"scenery\",\"terrain\",\"difficulty\"].forEach(function(key){\n\t\t\tc[key] = $('input[name='+key+']:checked').val();\n\t\t});\n\t\tif($('input[name=location]').is(':checked')){\n\t\t\tvar zip = $('input[id=zip]').val();\n\t\t\tif(zip.length == 5 && Number(zip) > 0){\n\t\t\t\tc[\"distance\"] = $('#location_distance').val();\n\t\t\t\tc[\"zip\"] = zip;\n\t\t\t}\n\t\t}\n\t\treturn c;\n\t}", "title": "" }, { "docid": "619787ca1ab2313552f236f260987a2e", "score": "0.44310653", "text": "function elementStylingMap(index,classes,styles){updateStylingMap(getStylingContext(index),classes,styles);}//////////////////////////", "title": "" }, { "docid": "4c87a13202a18eb822ecf1f29252fe74", "score": "0.44304898", "text": "function selectPath(){\n\t\tvar a = Array.prototype.slice.call(arguments)\n\t\treturn function(d){\n\t\t\tvar accum = d, i\n\t\t\tfor(i=0; i<a.length && accum; accum = accum[a[i]], ++i){}\n\t\t\treturn accum\n\t\t}\n\t}", "title": "" }, { "docid": "353d9780e3df42c9dd8b1e247a601f7f", "score": "0.4429449", "text": "function get_datamap_from_selBtn() {\n const data_map = (selected_btn === \"btn_subject\") ? subject_map :\n (selected_btn === \"btn_schemeitem\") ? schemeitem_map :\n (selected_btn === \"btn_package\") ? packageitem_map : null;\n return data_map;\n }", "title": "" }, { "docid": "9bd753fb60d121d4b6a037e84fd53929", "score": "0.44247484", "text": "getVisibleElements() {\n const currPage = this.state.currentPage;\n const visElCount = this.getVisibleElemenstCount();\n\n const firstItemVisIndex = (currPage - 1) * visElCount;\n let lastItemVisIndex = firstItemVisIndex + visElCount - 1;\n lastItemVisIndex =\n lastItemVisIndex > this.props._children.length - 1\n ? this.props._children.length - 1\n : lastItemVisIndex;\n\n const visIndex = [];\n for (let i = firstItemVisIndex; i <= lastItemVisIndex; i++) {\n visIndex.push(i);\n }\n\n return visIndex.map(i => this.elements.items[i]);\n }", "title": "" }, { "docid": "bd6ebead1d491e8e655837904fd952b2", "score": "0.44247457", "text": "printPathMap(){\n console.log(\"!-------ROAD MAP-----------!\");\n for (let [k,v] of this._roadMap) {\n console.log(\"Key: \" + k, \" val: \", v);\n }\n }", "title": "" }, { "docid": "b9158bbc85e212bd5b149be0a61a062c", "score": "0.44187516", "text": "Pt(t, e) {\n let n = !1;\n const s = this.Tt.field(t), i = vt(s) ? // If there is already data at the current path, base our\n Object.assign({}, s.mapValue.fields) : {};\n return e.forEach(((e, s) => {\n if (e instanceof Map) {\n const r = this.Pt(t.child(s), e);\n null != r && (i[s] = r, n = !0);\n } else null !== e ? (i[s] = e, n = !0) : i.hasOwnProperty(s) && (delete i[s], n = !0);\n })), n ? {\n mapValue: {\n fields: i\n }\n } : null;\n }", "title": "" }, { "docid": "8151105bc0c01e91bac45486ded0239b", "score": "0.44183823", "text": "function handlePath(path) {\n var subPaths = Array.from(path.subPathItems);\n return subPaths.map(handleSubPath);\n}", "title": "" }, { "docid": "47e6087970e6878e2d7f51e7e3d6afd5", "score": "0.4416981", "text": "_getClosestElementsInfo(element) {\n const results = [];\n this._elementInfo.forEach((info, currentElement) => {\n if (currentElement === element || (info.checkChildren && currentElement.contains(element))) {\n results.push([currentElement, info]);\n }\n });\n return results;\n }", "title": "" }, { "docid": "47e6087970e6878e2d7f51e7e3d6afd5", "score": "0.4416981", "text": "_getClosestElementsInfo(element) {\n const results = [];\n this._elementInfo.forEach((info, currentElement) => {\n if (currentElement === element || (info.checkChildren && currentElement.contains(element))) {\n results.push([currentElement, info]);\n }\n });\n return results;\n }", "title": "" }, { "docid": "47e6087970e6878e2d7f51e7e3d6afd5", "score": "0.4416981", "text": "_getClosestElementsInfo(element) {\n const results = [];\n this._elementInfo.forEach((info, currentElement) => {\n if (currentElement === element || (info.checkChildren && currentElement.contains(element))) {\n results.push([currentElement, info]);\n }\n });\n return results;\n }", "title": "" }, { "docid": "6548519e64b93a3da3eb9bf8213a5553", "score": "0.4409323", "text": "function flatPath(s){\n\t\treturn line(x[s].domain().map(function(p) {\n\t\t\t// return [x[s](p), height];\n\t\t\treturn [xx(p), height];\n\t\t}));\n\t}", "title": "" }, { "docid": "6548519e64b93a3da3eb9bf8213a5553", "score": "0.4409323", "text": "function flatPath(s){\n\t\treturn line(x[s].domain().map(function(p) {\n\t\t\t// return [x[s](p), height];\n\t\t\treturn [xx(p), height];\n\t\t}));\n\t}", "title": "" }, { "docid": "2e15f68855c936a98b7903712cf184d7", "score": "0.44035333", "text": "get selectedPath() {\n return this.props.value ? typeof this.props.value === 'object' ? this.props.value.path : this.props.value : null;\n }", "title": "" }, { "docid": "398b74c0c30a2c877f2805cb61443777", "score": "0.44018188", "text": "function getMapResolutions() {\n return mapResolutions;\n}", "title": "" }, { "docid": "bac3f4eb40521939c610a292d632f3a9", "score": "0.43897745", "text": "function changeMapFormat ( domElts /*: Array<groupElement> */, codElts /*: Array<groupElement> */ ) /*: Array<groupElement> */ {\n var result = Array( D.order ).fill( NaN );\n domElts.map( function ( domElt, index ) {\n result[domElt] = codElts[index];\n } );\n return result;\n }", "title": "" }, { "docid": "c9993d99f1e95f30f459bc6d93cd9b14", "score": "0.43847406", "text": "function makeBouncedPath(composedPath) {\n const docs = [];\n for (let el of composedPath) {\n const root = getPropagationRoot(el, composedPath);\n const doc = docs.find(({root: oldRoot}) => oldRoot === root);\n if (!doc) {\n const parent = root.host ? getPropagationRoot(root.host, path) : undefined;\n const entry = {root, path: [el], parent};\n el instanceof HTMLSlotElement ? docs.push(entry) : docs.unshift(entry);\n } else\n doc.path.push(el);\n }\n return docs;\n }", "title": "" }, { "docid": "994e83e5be6ef1f11be645b1c0299fdf", "score": "0.43790892", "text": "function currentSlideComponents(){\n return [slides, slidebuttons].map(x => x[slideIndex]);\n}", "title": "" }, { "docid": "0690f5de831ce735aa2c23b5dca05d07", "score": "0.437624", "text": "getTypeMappings() {\n \n const typeMappings = super.getTypeMappings();\n\ttypeMappings.circleFormat = this.CIRCLE_FORMAT \n return typeMappings; \n }", "title": "" }, { "docid": "21d3d5e5557e49ab2f269934de89fb2a", "score": "0.43758458", "text": "function mapX(value) {\n return value * window.innerWidth / schema.resolution.width;\n }", "title": "" }, { "docid": "805f24654f4928500be6ecc6e4156eab", "score": "0.4375395", "text": "function getElementIndexPath(fromElement, toElement) {\n var path = [];\n while (toElement && fromElement && toElement !== fromElement) {\n var parent_1 = Object(_dom_getParent__WEBPACK_IMPORTED_MODULE_2__[\"getParent\"])(toElement, true);\n if (parent_1 === null) {\n return [];\n }\n path.unshift(Array.prototype.indexOf.call(parent_1.children, toElement));\n toElement = parent_1;\n }\n return path;\n}", "title": "" }, { "docid": "805f24654f4928500be6ecc6e4156eab", "score": "0.4375395", "text": "function getElementIndexPath(fromElement, toElement) {\n var path = [];\n while (toElement && fromElement && toElement !== fromElement) {\n var parent_1 = Object(_dom_getParent__WEBPACK_IMPORTED_MODULE_2__[\"getParent\"])(toElement, true);\n if (parent_1 === null) {\n return [];\n }\n path.unshift(Array.prototype.indexOf.call(parent_1.children, toElement));\n toElement = parent_1;\n }\n return path;\n}", "title": "" }, { "docid": "805f24654f4928500be6ecc6e4156eab", "score": "0.4375395", "text": "function getElementIndexPath(fromElement, toElement) {\n var path = [];\n while (toElement && fromElement && toElement !== fromElement) {\n var parent_1 = Object(_dom_getParent__WEBPACK_IMPORTED_MODULE_2__[\"getParent\"])(toElement, true);\n if (parent_1 === null) {\n return [];\n }\n path.unshift(Array.prototype.indexOf.call(parent_1.children, toElement));\n toElement = parent_1;\n }\n return path;\n}", "title": "" }, { "docid": "6f34438e3dd9250495a119f91e42425b", "score": "0.43751204", "text": "get mapping() {\n return this.__mapping.get();\n }", "title": "" }, { "docid": "6abda8cacc8ff3b21104f4af03448440", "score": "0.43697283", "text": "resolve(value){\n\t\tif (this.mappings[value] !== undefined){\n\t\t\treturn this.mappings[value]\n\t\t}\n\n\t\treturn []\n\t}", "title": "" }, { "docid": "7e993724a72ddfb7789d3f4a9aad7f72", "score": "0.43644553", "text": "nextDegree() {\n return Object.keys(this.parent().parents).map((name) => {\n const path = this.parent().parents[name]\n return new PolyPath(this.path.concat([path]))\n })\n }", "title": "" }, { "docid": "8355a3bb4bdc95acd8d8ad33e0c2af3a", "score": "0.43612534", "text": "_createShapeMap(vrm) {\n let shapeMap = new Map();\n vrm.blendShapeMaster.blendShapeGroups.forEach(\n (blendShapeObj, index) => {\n if (blendShapeObj.presetName != \"unknown\") {\n shapeMap.set(blendShapeObj.presetName, {\n index: index,\n name: blendShapeObj.name\n })\n }\n else {\n shapeMap.set(blendShapeObj.name, {\n index: index,\n name: blendShapeObj.name\n })\n }\n });\n console.log(shapeMap);\n return shapeMap;\n }", "title": "" }, { "docid": "1a53ad332b6b64d80a92e9860614c9f3", "score": "0.43602705", "text": "function fnGetPathesCurrentlyShown(oTemplateContract){\n\t\tvar aActiveComponents = oTemplateContract.oNavigationControllerProxy.getActiveComponents();\n\t\tvar aRet = [];\n\t\tfor (var i = 0; i < aActiveComponents.length; i++){\n\t\t\tvar sComponentId = aActiveComponents[i];\n\t\t\tvar oRegistryEntry = oTemplateContract.componentRegistry[sComponentId];\n\t\t\tvar iViewLevel = oRegistryEntry.viewLevel;\n\t\t\tif (iViewLevel > 0){\n\t\t\t\tvar oContext = oRegistryEntry.oComponent.getBindingContext();\n\t\t\t\tif (oContext){\n\t\t\t\t\taRet[iViewLevel] = oContext.getPath();\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn aRet;\n\t}", "title": "" }, { "docid": "c6d4e2ed3fbd7fc8c07805bac4ea0d54", "score": "0.43534598", "text": "function getElementIndexPath(fromElement, toElement) {\n var path = [];\n while (toElement && fromElement && toElement !== fromElement) {\n var parent_1 = Object(__WEBPACK_IMPORTED_MODULE_2__dom_getParent__[\"a\" /* getParent */])(toElement, true);\n if (parent_1 === null) {\n return [];\n }\n path.unshift(Array.prototype.indexOf.call(parent_1.children, toElement));\n toElement = parent_1;\n }\n return path;\n}", "title": "" }, { "docid": "c6d4e2ed3fbd7fc8c07805bac4ea0d54", "score": "0.43534598", "text": "function getElementIndexPath(fromElement, toElement) {\n var path = [];\n while (toElement && fromElement && toElement !== fromElement) {\n var parent_1 = Object(__WEBPACK_IMPORTED_MODULE_2__dom_getParent__[\"a\" /* getParent */])(toElement, true);\n if (parent_1 === null) {\n return [];\n }\n path.unshift(Array.prototype.indexOf.call(parent_1.children, toElement));\n toElement = parent_1;\n }\n return path;\n}", "title": "" }, { "docid": "7409c1c735fdaec15c57616a5b414af4", "score": "0.4345031", "text": "get_paths () {\n\t\t\n\t}", "title": "" }, { "docid": "e8e32edcd7ce315d7f9b649261edba34", "score": "0.43380103", "text": "_cacheChildrenWithExternalReferences(element) {\n const elementsWithFuncIri = element.querySelectorAll(funcIriAttributeSelector);\n const elements = this._elementsWithExternalReferences =\n this._elementsWithExternalReferences || new Map();\n for (let i = 0; i < elementsWithFuncIri.length; i++) {\n funcIriAttributes.forEach(attr => {\n const elementWithReference = elementsWithFuncIri[i];\n const value = elementWithReference.getAttribute(attr);\n const match = value ? value.match(funcIriPattern) : null;\n if (match) {\n let attributes = elements.get(elementWithReference);\n if (!attributes) {\n attributes = [];\n elements.set(elementWithReference, attributes);\n }\n attributes.push({ name: attr, value: match[1] });\n }\n });\n }\n }", "title": "" }, { "docid": "e8e32edcd7ce315d7f9b649261edba34", "score": "0.43380103", "text": "_cacheChildrenWithExternalReferences(element) {\n const elementsWithFuncIri = element.querySelectorAll(funcIriAttributeSelector);\n const elements = this._elementsWithExternalReferences =\n this._elementsWithExternalReferences || new Map();\n for (let i = 0; i < elementsWithFuncIri.length; i++) {\n funcIriAttributes.forEach(attr => {\n const elementWithReference = elementsWithFuncIri[i];\n const value = elementWithReference.getAttribute(attr);\n const match = value ? value.match(funcIriPattern) : null;\n if (match) {\n let attributes = elements.get(elementWithReference);\n if (!attributes) {\n attributes = [];\n elements.set(elementWithReference, attributes);\n }\n attributes.push({ name: attr, value: match[1] });\n }\n });\n }\n }", "title": "" }, { "docid": "e8e32edcd7ce315d7f9b649261edba34", "score": "0.43380103", "text": "_cacheChildrenWithExternalReferences(element) {\n const elementsWithFuncIri = element.querySelectorAll(funcIriAttributeSelector);\n const elements = this._elementsWithExternalReferences =\n this._elementsWithExternalReferences || new Map();\n for (let i = 0; i < elementsWithFuncIri.length; i++) {\n funcIriAttributes.forEach(attr => {\n const elementWithReference = elementsWithFuncIri[i];\n const value = elementWithReference.getAttribute(attr);\n const match = value ? value.match(funcIriPattern) : null;\n if (match) {\n let attributes = elements.get(elementWithReference);\n if (!attributes) {\n attributes = [];\n elements.set(elementWithReference, attributes);\n }\n attributes.push({ name: attr, value: match[1] });\n }\n });\n }\n }", "title": "" }, { "docid": "d81d9cf39615124d5a2a62ed63216f99", "score": "0.43372855", "text": "function currentPlacement(stack){\n//Takes the column values from the stack,\n//returns the corresponding tree placement\n return Array.from(stack.keys()).map((i) => [i, stack[i]]);\n}", "title": "" }, { "docid": "0829a4fac89776b2ef34ba7249de6058", "score": "0.4329908", "text": "get entries () {\n return [\n res(this.paths.js, 'index.js'),\n res(this.paths.sass, 'main.sass')\n ]\n }", "title": "" } ]
c6c9d7a823d089e5fb828eaeb9f44f46
Changes the form title Required that the for title has an id of form_title
[ { "docid": "4b6c5b5d9447b5286fe97bf6c3df0f82", "score": "0.7567154", "text": "function changeFormTitle(titleFor){\n document.querySelector('#form_title').innerText = `Create a ${titleFor} File`\n }", "title": "" } ]
[ { "docid": "9c475e43d54528f53bd36ca01dbf4b58", "score": "0.72931135", "text": "get formTitle() {return $('div=Creando un accidente')}", "title": "" }, { "docid": "00449e0d93d5b356337cd49ec1b5c7ac", "score": "0.7217572", "text": "formTitle() {\n if(this.$options.form && this.$options.form.title) {\n const title = this.$options.form.title;\n return typeof title === 'function' ? title.call(this) : title;\n }\n return undefined;\n }", "title": "" }, { "docid": "b1170f7408a4e3985983c4e67b8de4fd", "score": "0.71563697", "text": "function setTitle(title) {\n\t\tif (title === null || title === \"\") {\n\t\t\ttitle = settings.getDefaultValue(\"documentTitle\");\n\t\t}\n\t\t$input.val(title);\n\t\toldTitle = title;\n\t\tmirrorWidth($input, $mirror);\n\t\tunsavedChanges.setHasChanges(true);\n\t\tsettings.setSetting(\"documentTitle\", title);\n\t}", "title": "" }, { "docid": "7cd4f8094f14a466d769b2e44c5d71e7", "score": "0.7075831", "text": "function get_form_id(title) {\n\treturn title.replace(/ /g, \"_\").toLowerCase();\n}", "title": "" }, { "docid": "2b26369ebf2a62af533c011ef35e56a8", "score": "0.70729357", "text": "function editTitle(newTitle) {\n title = newTitle;\n }", "title": "" }, { "docid": "1843d8cc617535d8afc08bba03b0f897", "score": "0.6989152", "text": "function form_title_change(id)\n{\n document.getElementById('form_setting_para_1').innerHTML = id.value;\n \n var str_status_verification = edit_value_change_check(id.value);\n if (!str_status_verification) {\n document.getElementById('form_setting_para_1').innerHTML = 'Type Again';\n id.value = 'Type Again';\n }\n}", "title": "" }, { "docid": "090fb3bdc50d74147dc9288184d423ad", "score": "0.6907838", "text": "function qw_set_setting_title(){\r\n // change title values\r\n var new_title = '';\r\n\r\n // single value\r\n if(jQuery('#'+qw_current_form_id).hasClass('qw-single-value')){\r\n new_title = jQuery('#'+qw_current_form_id).children('.qw-field-value').val();\r\n }\r\n // multiple values\r\n else if (jQuery('#'+qw_current_form_id).hasClass('qw-multiple-values')){\r\n // use an array and join it\r\n var title_array = [];\r\n jQuery('#'+qw_current_form_id).children('.qw-field-value').each(function(index, element){\r\n title_array.push(jQuery(element).val());\r\n });\r\n \r\n // handle empty\r\n if(title_array.length > 0){\r\n new_title = title_array.join(\" - \");\r\n } else {\r\n new_title = 'None';\r\n }\r\n }\r\n // checkboxes\r\n else if (jQuery('#'+qw_current_form_id).hasClass('qw-checkbox-values')){\r\n // use an array and join it\r\n var title_array = [];\r\n jQuery('#'+qw_current_form_id).find('input[type=checkbox]:checked').each(function(index, element){\r\n title_array.push(jQuery(element).val());\r\n });\r\n \r\n // handle empty\r\n if(title_array.length > 0){\r\n new_title = title_array.join(\",\");\r\n } else {\r\n new_title = 'None';\r\n }\r\n }\r\n // fields\r\n else if (jQuery('#'+qw_current_form_id).hasClass('qw-sort-fields-values')) {\r\n var title_array = [];\r\n jQuery('#'+qw_current_form_id).find('.qw-field-title').each(function(index, element){\r\n var field_name = jQuery(element).siblings('.qw-sort-field-name').text();\r\n title_array.push('<div><span class=\"qw-query-fields-name\" title=\"qw-field-'+field_name+'\">'+jQuery(element).text()+'</span></div>'); \r\n });\r\n jQuery('#qw-query-fields-list').html(title_array.join(''));\r\n }\r\n // header - footer - empty\r\n else if (jQuery('#'+qw_current_form_id).hasClass('qw-header-footer-empty')){\r\n if(jQuery('#'+qw_current_form_id).find('.qw-field-textarea').val().trim() == \"\"){\r\n new_title = 'None';\r\n } else {\r\n new_title = 'In Use';\r\n }\r\n }\r\n // set new title\r\n jQuery('span[title='+qw_current_form_id+'] span').text(new_title);\r\n}", "title": "" }, { "docid": "7b1d9eddf1f479e08f0a88718f64ba0d", "score": "0.68143564", "text": "function setTitle()\n {\n var newTitle=document.title;\n if(newTitle != oldTitle)\n document.title=oldTitle;\n //bug 8883221:malmishr \n //This is for Iframe not to show the old data while the iframe is loading.\n if(divid != null)\n {\n var popupIframe=window.top.document.getElementById(iframeid);\n //bug 9696833\n if(!popupIframe)\n popupIframe = document.getElementById(iframeid);\n if(popupIframe!=null)\n popupIframe.style.visibility=\"visible\";\n popupFormName = getPopupFormName(popupIframe);\n // bug 9255491\n // Save off the initial state of the parameterized popup form.\n initialPopupFormState = getPopupFormState();\n } \n \n }", "title": "" }, { "docid": "85ce1d2b5386532a4cc31fdaf91fdd84", "score": "0.67780507", "text": "static update_title() {\n\n //this.title_el.classList.remove('selected')\n Editor.page.title = Editor.title_el.value\n\n PageController.save_page(Editor.page)\n .then((e) => { })\n .catch((e) => { (Editor.title = Editor.title_el.value = Editor.title_el.originalvalue) })\n }", "title": "" }, { "docid": "406e1aed00757141f82295b16ddba13c", "score": "0.671071", "text": "function setSurveyTitleAsFormLable(form) {\r\n\t$.post(app_path_webroot+'Design/set_survey_title_as_form_name.php?pid='+pid,{ form: form },function(data){\r\n\t\tif (data == '0') {\r\n\t\t\talert(woops);\r\n\t\t} else {\r\n\t\t\tsimpleDialog(langSetSurveyTitleAsForm5+' \"<b>'+data+'</b>\"'+langPeriod,langSetSurveyTitleAsForm6,null,null,\"window.location.reload();\");\r\n\t\t}\r\n\t});\r\n}", "title": "" }, { "docid": "52222d7597cd3160958b62a32a2e42fa", "score": "0.666748", "text": "setTitle(newTitle) {\n this._doc.title = newTitle || '';\n }", "title": "" }, { "docid": "52222d7597cd3160958b62a32a2e42fa", "score": "0.666748", "text": "setTitle(newTitle) {\n this._doc.title = newTitle || '';\n }", "title": "" }, { "docid": "52222d7597cd3160958b62a32a2e42fa", "score": "0.666748", "text": "setTitle(newTitle) {\n this._doc.title = newTitle || '';\n }", "title": "" }, { "docid": "52222d7597cd3160958b62a32a2e42fa", "score": "0.666748", "text": "setTitle(newTitle) {\n this._doc.title = newTitle || '';\n }", "title": "" }, { "docid": "3bd25ef0ca9fdb319942600c851695e8", "score": "0.66662717", "text": "setTitle(title) {\n if (title != null) {\n $(\"#candy-title\").text(title); \n }\n }", "title": "" }, { "docid": "12ca1bf39f7aebce10b4718ca4d715a0", "score": "0.6639116", "text": "function titleUpdate(){\n\tvar title = document.getElementById('title').value;\n\tdocument.getElementById('updateTitle').innerHTML = title;\n}", "title": "" }, { "docid": "5d9932c11c29ae497965fae096640087", "score": "0.6617446", "text": "function handleEditTitle() {}", "title": "" }, { "docid": "81216d4d46e227e865bc9af536fe343d", "score": "0.6570774", "text": "function FM_SetTitle(title) {\r\n this.m_title = title;\r\n}", "title": "" }, { "docid": "8a14f8e74fbc5d5196176eb036c9bcd1", "score": "0.6535601", "text": "function updateTitle()\n{\n\tclearTitle();\n\taddTitle();\n}", "title": "" }, { "docid": "7ae00279990a52aab4ec4ce028435d61", "score": "0.6526665", "text": "function onChangeTitle(){\r\n $(\"h2\").text($(\".js-change-title\").val());\r\n }", "title": "" }, { "docid": "469ad80072264deba04f1ff7f1b6290d", "score": "0.6521246", "text": "setTitle(title) {\n if (this._context) {\n this._context.setTitle(title);\n }\n }", "title": "" }, { "docid": "0d0c95165878561d5f673e3cae4ec85b", "score": "0.6514868", "text": "function changeTitleEverywhereOnThePage(pageName, newTitle)\r\n{\r\n\t//get global title (20 = length of \"Заголовок сторінки: \")\r\n\tvar titlePrefix = $(\"[id $= '_title_label']\").html().substring(\"Заголовок сторінки: \".length, $(\"[id $= '_title_label']\").html().length);\r\n\t\r\n\t//change editor form data for next edits\r\n\t$(\"#pageTitle\").val(newTitle);\r\n\t//change page title (<title> tag)\r\n\tparent.document.title = titlePrefix + newTitle;\r\n}", "title": "" }, { "docid": "4c63e2d0e47aff5a3917b43bc34bb913", "score": "0.6511889", "text": "set title(newTitle){\n return _private.get(this).properties['_title']=newTitle;\n }", "title": "" }, { "docid": "f3ce768774e050d4945ceb8743f8aabf", "score": "0.65020865", "text": "static init_page_title() {\n\n let title_el = document.createElement('input')\n\n title_el.classList.add('title')\n title_el.value = Editor.page.title\n title_el.dataset.originalvalue = Editor.page.title\n title_el.onchange = Editor.update_title.bind(Editor)\n title_el.onkeydown = () => { window.setTimeout(Editor.resize_title, 0) }\n \n Editor.title_el = title_el\n Editor.element.appendChild(Editor.title_el)\n Editor.resize_title()\n }", "title": "" }, { "docid": "e138fbad58bcf6566f93fff39f5ce1aa", "score": "0.6497579", "text": "function layoutTitle(title) {\n if (title) {\n $(\"#isitupTitleId\").html(title);\n } else {\n $(\"#isitupTitleId\").html(\"Environment Status \");\n }\n}", "title": "" }, { "docid": "684f1da5dc165f74791777a2627ba3d6", "score": "0.6496462", "text": "setTitle(newTitle) {\n this._doc.title = newTitle || '';\n }", "title": "" }, { "docid": "871457c6a4ca20ee8e06fa1e95567a45", "score": "0.64923626", "text": "function setTitle(modalTemplate, title) {\n if (title != null && title != '') {\n modalTemplate.title.html(title);\n } else {\n modalTemplate.header.hide();\n }\n }", "title": "" }, { "docid": "78a8f71181b48fdb56e5f991d336c9e3", "score": "0.64584094", "text": "function updateTitle( event ) {\n\t\t\tprops.setAttributes( { title: event.target.value } );\n\t\t}", "title": "" }, { "docid": "01107ec40552876e979587727d9fdaab", "score": "0.64562905", "text": "function updateTitle(title){\n if(title){\n document.title = title + \" | Postr\"; \n }\n else{\n document.title = \"Postr\";\n }\n}", "title": "" }, { "docid": "738144d52b17d4500f1a6eedd746176a", "score": "0.6455815", "text": "function _setTitle(title) {\n var html = $(me.infoWindow.getContent())\n .find(\"h1\").html(title).parent().get(0).outerHTML;\n\n me.infoWindow.setContent(html);\n }", "title": "" }, { "docid": "7a6392bf66b85f3c9d9756ad6658582c", "score": "0.64284074", "text": "set title(value) { //\r\n this._title = value; //\r\n }", "title": "" }, { "docid": "de3e5f96452868e06bc13d82f0f056ae", "score": "0.6417033", "text": "updateFormTitle(type) {\n this.checkType(type, 'updateFormTitle');\n\n return (e) => {\n let form = (type === newFormType) ? this.state.newForm\n : this.state.editViewItem;\n form.title = e.target.value;\n if (type === newFormType) this.setState({newForm: form});\n else this.setState({editViewItem: form});\n };\n }", "title": "" }, { "docid": "098f9173820023c577975fceb96ecbb2", "score": "0.64051807", "text": "function setTitle(title) {\n document.title = title;\n }", "title": "" }, { "docid": "854316c51556038fad4e233275c07ad1", "score": "0.6402052", "text": "_buildHeader(form, title) {\n let header = form.append('div').attr('class', 'francy-modal-header');\n\n let headerTitle = header.append('span').html(title);\n if (this.data.title) {\n headerTitle.append('span').text(`${this.data.title}`);\n }\n }", "title": "" }, { "docid": "85a51b4e9e28924e9ebd5e18a6262046", "score": "0.6397477", "text": "function setTitle() {\n if (titleInputBak != '') { // only do this if we previously found 'XXX' in the title\n titleInput.value = titleInputBak // reset the title to the default\n if (globalFilterIn.value == '') { \n titleInput.value = titleInputBak // if global filter is clear, then reset the title to the default\n } else {\n titleInput.value = titleInputBak.replace( 'XXX' , globalFilterIn.value ) // if globabal filter is set, then replace 'XXX' in the title with the string in global filter\n }\n }\n}", "title": "" }, { "docid": "f1bb7cf43ef1b45bd8507e1ddc3d7be3", "score": "0.63890475", "text": "function set_title(title){\n\t\t$(\"#title-bar\").text(title);\n\t}", "title": "" }, { "docid": "ad09ecf8f018af7df4063241daac87f6", "score": "0.6370868", "text": "setTitle(title) { this.setParam(WPConst.TITLE, title); }", "title": "" }, { "docid": "f54d2f968e17fb7cbbc97f0efa5de77c", "score": "0.63615096", "text": "setTitre(titre){\n\t\tthis.titleField.innerHTML = titre || this.titre\n\t}", "title": "" }, { "docid": "4112fc8dabaf29435ce636402fb38068", "score": "0.6352714", "text": "function setSearchTitle() {\n $('#title').html('Zoek instellingen')\n $('#subtitle').html('Stel hier de waarde in waarop gezocht wordt in uw social media kanalen')\n}", "title": "" }, { "docid": "5fedb68d6dfb53ad447d3dea8ea70e73", "score": "0.6339066", "text": "function qw_title_click_action()\r\n{\r\n // trigger cancel button\r\n if(qw_current_form_id !== undefined && qw_current_form_id != ''){\r\n jQuery('#qw-options-actions-cancel').trigger('click');\r\n }\r\n // hide forms\r\n jQuery('#qw-options-forms .qw-query-content').hide();\r\n // show form\r\n jQuery('#qw-options-forms #'+qw_new_form_id).show();\r\n // backup the form\r\n qw_form_backup = jQuery('form#qw-edit-query-form').serialize();\r\n // make the new form id the current form id\r\n qw_current_form_id = qw_new_form_id;\r\n}", "title": "" }, { "docid": "50b7d58033cc5aa7f4dfa05c8f4e585a", "score": "0.6330988", "text": "function getTitle(){\n\tif(document.getElementById('editpane_title').value)\n\t\treturn document.getElementById('editpane_title').value;\n\telse\n\t\treturn '';\n}", "title": "" }, { "docid": "88027183bea61bfaaa86a8499e75403c", "score": "0.631323", "text": "setTitle() {\n const title = opts.title;\n if (typeof title === 'string') {\n opts.title = {\n label: title,\n href: '#'\n };\n }\n }", "title": "" }, { "docid": "3e927e19f394af176074d58e6d467fce", "score": "0.63107103", "text": "function changeFormToSubmit() {\r\n // edit form name\r\n const formTitle = document.querySelector(\"form h2\");\r\n const formSubmit = document.querySelector(\"#submit-button\");\r\n formTitle.textContent = \"Add Movie\";\r\n formSubmit.textContent = \"Add Movie\";\r\n}", "title": "" }, { "docid": "d557da450cc963a603593f704c358e68", "score": "0.6282502", "text": "function _updateTitle(title) {\n _data.title = title;\n}", "title": "" }, { "docid": "4b538ba017f5bc73b511dbad90ae3f4a", "score": "0.62579715", "text": "titleChange(event) {\n this.setState({ title: event.target.value });\n if (event.target.value !== '') {\n this.setState({ requireTitle: '' });\n } else {\n this.setState({ requireTitle: 'required' });\n }\n }", "title": "" }, { "docid": "73877313a576a760024f9632f3eaf756", "score": "0.6224224", "text": "function setModalTitle($target) {\n var title = $target.attr('data-title');\n if (!_.isUndefined(title)) {\n $('.modal-title', '#schedule-modal').html(title);\n }\n\n }", "title": "" }, { "docid": "cd19ee1681738253223096f44b6993c7", "score": "0.621186", "text": "title(title) {\n super.set(\"title\", title);\n return this;\n }", "title": "" }, { "docid": "1314e8c4abb135979e72d13c86ce0b01", "score": "0.62113947", "text": "function resetTitle(message) {\n var title = document.getElementById('title');\n title.innerHTML = message;\n}", "title": "" }, { "docid": "df4e017fd2e668ec7957a44401c42757", "score": "0.6207678", "text": "function vcs_set_title(title) {\n var vcs_title = document.getElementById('vcs_title');\n vcs_title.innerHTML = title;\n}", "title": "" }, { "docid": "9f405eaaca0f153e6357afc459693f7e", "score": "0.6205639", "text": "function changeTitlePoemAdd(){\n\n\n document.getElementById('addPoemTitle').innerHTML = document.getElementById('title').value;\n\n}", "title": "" }, { "docid": "e0871d5b98f1ec7070ea02ef5fae61ac", "score": "0.6202305", "text": "function changeFormToEdit() {\r\n // edit form name\r\n const formTitle = document.querySelector(\"form h2\");\r\n const formSubmit = document.querySelector(\"#submit-button\");\r\n formTitle.textContent = \"Edit Movie\";\r\n formSubmit.textContent = \"Edit Movie\";\r\n}", "title": "" }, { "docid": "3b1967ac166128e6820197f7b1970d5d", "score": "0.6189994", "text": "function saveTitle() {\n var sid = txtTitleEdit.attr('sid');\n var title = $(btnSoundTitles[sid]);\n //TODO Make sure you cannot save if input is empty by disabling button\n if(txtTitleEdit.val() === \"\")\n {\n txtTitleEdit.val(title.attr('default'));\n }\n title.text(txtTitleEdit.val());\n title.attr('name', txtTitleEdit.val());\n saveConfig();\n closeEditTitleOverlay();\n }", "title": "" }, { "docid": "47b329c4aa26583566cc68a7e20c9789", "score": "0.6184471", "text": "function setHeaderTitle() {\n var title = InquiryGeneralViewModel.Title;\n $(\"#InquiryGeneralHeader\").text(inquiryGeneralResources.Inquiry + \" - \" + title);\n }", "title": "" }, { "docid": "09afe0df33a0003f1d195587bcc60817", "score": "0.6182318", "text": "function titleSetup() {\n\t\t\t\t\tif(scope.title !== undefined) {\n\t\t\t\t\t\t// For now we don't display the title\n\t\t\t\t\t\t// sel.select(\"span.list-title\").text(scope.title);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tsel.select(\"span.list-title\").text(null);\n\t\t\t\t\t}\n\t\t\t\t}", "title": "" }, { "docid": "e94b67000619d131e90a9d51501f5090", "score": "0.61807644", "text": "set title(val) {\n if (this._title) {\n throw new Error(`Can't change title!`);\n }\n this._title = val;\n }", "title": "" }, { "docid": "50e198075a6c165baad1de04a76956a9", "score": "0.6173299", "text": "function changeTitle() {\n if (currentEdition[\"id\"] > -1) {\n currentEdition[\"title\"] = $(\"#prompt_node_title\").val()\n commitNodeTitle()\n }\n $(\"#nodeTitlePrompt\").modal(\"hide\"); \n}", "title": "" }, { "docid": "fd9682ddc5281042e4da6970a7ab1da2", "score": "0.6173296", "text": "validateTitle() {\n const title = this.state.title.value.trim()\n if (title.length === 0) {\n return '*Title content is required'\n };\n }", "title": "" }, { "docid": "95f71810b04d489c269a785d987f4575", "score": "0.6171455", "text": "setTitle(title) {\n this.title = title;\n }", "title": "" }, { "docid": "bd5031f7fe725be4c5583756e751f3a6", "score": "0.6153221", "text": "function setTitle() {\n var current_title = $(document).attr('title');\n if(current_title.indexOf(\" -- \") >=0) {\n \tvar n = current_title.indexOf(\" -- \");\n \tvar orig_title = current_title.substring(n + 4);\n }\n else {\n \tvar orig_title = current_title;\n }\n var new_title = $( \"#charName\" ).val() + \" -- \" + orig_title;\n $(document).attr(\"title\", new_title);\n}", "title": "" }, { "docid": "0b33d171c079cc79249480e6cdc15931", "score": "0.6145382", "text": "function SiteTitleEdit() {\n var _useEntityProp = useEntityProp('root', 'site', 'title'),\n _useEntityProp2 = Object(slicedToArray[\"a\" /* default */])(_useEntityProp, 2),\n title = _useEntityProp2[0],\n setTitle = _useEntityProp2[1];\n\n return Object(react[\"createElement\"])(plain_text, {\n __experimentalVersion: 2,\n tagName: block_wrapper_Block.h1,\n placeholder: Object(i18n_build_module[\"__\"])('Site Title'),\n value: title,\n onChange: setTitle,\n disableLineBreaks: true\n });\n}", "title": "" }, { "docid": "02f1ac2b5d84b28286e22eb7ce4d24bb", "score": "0.6136575", "text": "function checkTitle() {\n\t\t\t\n\t\t\tvar element = '';\n\t\t\t\n\t\t\t// check if title attribute has been set and grab title\n\t\t\tif ($(this).attr('title') != '' && $(this).attr('title') != undefined)\n\t\t\t\telement = $(this).attr('title');\n\t\n\t\t\t\n\t\t\t// else, check value attribute for title\n\t\t\telse if ($(this).prop('defaultValue') != '' && $(this).prop('defaultValue') != undefined)\n\t\t\t\telement = $(this).prop('defaultValue');\n\t\n\t\t\t// else, check placeholder (html5)\n\t\t\telse if ($(this).attr('placeholder') != '' && $(this).attr('placeholder') != undefined)\n\t\t\t\telement = $(this).attr('placeholder');\n\t\n\t\t\t// else, use element name\n\t\t\telse\n\t\t\t\telement = $(this).attr('name');\n\t\n\t\t\t\t\n\t\t\telTitle = element;\n\t\t}", "title": "" }, { "docid": "82ae7eef7ced661a8e476236efaab3ff", "score": "0.6128265", "text": "function validateTitle() {\n \n}", "title": "" }, { "docid": "774ea1932f98d8d321822873f6ca826b", "score": "0.6123601", "text": "function setTitle(title) {\n contextPageTitleElement.textContent = title\n }", "title": "" }, { "docid": "be406d14fa21b4d7b1b23e394c1783a0", "score": "0.612107", "text": "function setupRenameForm(form) {\r\n\tdocument.getElementById('formlabel-'+form).style.display = 'none';\r\n\tdocument.getElementById('form_menu_description_input_span-'+form).style.display = '';\r\n\tsetCaretToEnd(document.getElementById('form_menu_description_input-'+form));\r\n}", "title": "" }, { "docid": "f2118c5fc8fdf5da6aea98e02c4c248b", "score": "0.6120619", "text": "function updateTitle () {\n\n\tvar projectName = localStorage.getItem('projectName');\n\tdocument.title = projectName;\n\n}", "title": "" }, { "docid": "928b0378117be436798697ad3bd68201", "score": "0.6106579", "text": "function setTitle(title) {\n $(\"title\").html(title)\n $(\"h1\").html(title)\n}", "title": "" }, { "docid": "928b0378117be436798697ad3bd68201", "score": "0.6106579", "text": "function setTitle(title) {\n $(\"title\").html(title)\n $(\"h1\").html(title)\n}", "title": "" }, { "docid": "5b7ba9c2b7f60912c281f26d7e96e2cf", "score": "0.60981375", "text": "function set_doc_title(title) {\n document.title = title;\n}", "title": "" }, { "docid": "c12b03826663fd97907cfd3c77a39306", "score": "0.60897034", "text": "function hackyUpdatePlaceholderText() {\n\tvar titlePlaceholder = localization.GetStringOrFallback(\"title_placeholder\", \"Title\");\n\tvar titleTextBoxes = document.getElementsByClassName(\"titleTextBox\");\n\tfor (var i = 0; i < titleTextBoxes.length; i++) {\n\t\ttitleTextBoxes[i].placeholder = titlePlaceholder;\n\t}\n}", "title": "" }, { "docid": "a3a81fca8a46952de0754155d2d3e331", "score": "0.6089373", "text": "function h_setModuleContainerTitle(moduleID,title) {\r\n\t$(\"#\" + moduleID + '_Title').html(title);\r\n}", "title": "" }, { "docid": "065a790658d5f43d6a34205c5554a139", "score": "0.6087224", "text": "function setTitle(title) {\n\t$(\"#reportPopupTitle\").html(\"\\\"\" + title + \"\\\"\");\n}", "title": "" }, { "docid": "e5df4ea1c6c3c3ccdd1e55571b71b762", "score": "0.60843736", "text": "function clientTitle(title) {\n $(\"#\" + vizControlConfig.selectParm).text(title);\n }", "title": "" }, { "docid": "7f5a151d62a207e7ddb395289b66b4a6", "score": "0.6080841", "text": "function checkIfTitle() {\n if (typeof(scope.clssdata.options) != \"undefined\") {\n if (scope.clssdata.options.title === scope.field.uid) {\n elem.find('.chk-title').prop(\"checked\", true);\n }\n }\n }", "title": "" }, { "docid": "265c3ed6a915a69c0c0e3cad42e51fbc", "score": "0.60708433", "text": "function switchForm() {\n\n\t// change form title to edit note\n\tif (newTitle.value === \"\") {\n\t\tformTitle.textContent = \"New Note\";\n\t\tformUpdate.style.display = \"none\";\n\t\tformSave.style.display = \"block\";\n\t} else {\n\t\tformTitle.textContent = \"Edit Note\";\n\t\tformSave.style.display = \"none\";\n\t\tformUpdate.style.display = \"block\";\n\t}\n}", "title": "" }, { "docid": "6d62b49ebdbbd7ae54d63bc6552fc39d", "score": "0.6064505", "text": "function _updateTitle() {\n var title = '';\n if (State.url != root_url && $('[data-page-title]').length) {\n title = $('[data-page-title]').first().attr('data-page-title');\n }\n if (title == '') {\n title = 'Nate Beaty’s Head in the Clouds';\n } else {\n title = title + ' – Nate Beaty';\n }\n\n // Snippet from Ajaxify to update title tag\n document.title = title;\n try {\n document.getElementsByTagName('title')[0].innerHTML = document.title.replace('<','&lt;').replace('>','&gt;').replace(' & ',' &amp; ');\n } catch (Exception) {}\n }", "title": "" }, { "docid": "396c3e02da371683481ba33e6e981c2e", "score": "0.6064169", "text": "function file_form_update(id) {\n\t$('file_title_'+id).innerHTML = $('file_form_title_'+id).value;\n}", "title": "" }, { "docid": "25c75adbae02cea06ecda8dc03afddd1", "score": "0.6061468", "text": "changeWidthTitle(event) {\n this.inputClass = true;\n let hide = document.getElementById(\"hide\");\n let txt = document.getElementById(\"txt\");\n this.resize(hide, txt);\n // Set tab title on change\n this.titleService.setTitle(document.getElementById(\"hide\").innerText);\n }", "title": "" }, { "docid": "33ff9d77fbab90f06ae8e9a84cd63b6b", "score": "0.6060692", "text": "function modalSetTitle(modal, title='') {\n $(modal + ' #modal-title').html(title);\n}", "title": "" }, { "docid": "eb433e6c34299a7b1115d83d23d47035", "score": "0.6041306", "text": "set title(title) {\n\t\tlet titleElem = this.myShadowRoot.querySelector('.title');\n\t\ttitleElem.textContent = title;\n\t}", "title": "" }, { "docid": "a5e11b66aea3201b7de2a56d0be26554", "score": "0.6040675", "text": "set title(aValue) {\n this._logger.debug(\"title[set]\");\n this._title = aValue;\n }", "title": "" }, { "docid": "6f3c9f16953c4d043d672322a61a1305", "score": "0.60357785", "text": "function setFormMenuDescription(form_name,askChangeSurveyTitle) {\r\n\tif (askChangeSurveyTitle == null) askChangeSurveyTitle = 0;\r\n\tif ($('#form_menu_description_input-'+form_name).val().length < 1) {\r\n\t\talert('Please enter a value for the form name');\r\n\t\treturn false;\r\n\t} else if (checkIsTwoByte($('#form_menu_description_input-'+form_name).val())) {\r\n\t\talert('Please remove two-byte characters');\r\n\t\treturn false;\r\n\t}\r\n\tdocument.getElementById('progress-'+form_name).style.visibility = 'visible';\r\n\tvar this_value = document.getElementById('form_menu_description_input-'+form_name).value;\r\n\tdocument.getElementById('form_menu_description_input-'+form_name).disabled = true;\r\n\tdocument.getElementById('form_menu_save_btn-'+form_name).disabled = true;\r\n\t$.get(app_path_webroot+'Design/set_form_name.php', { pid: pid, page: form_name, action: 'set_menu_name', menu_description: this_value },\r\n\t\tfunction(data) {\r\n\t\t\tvar formArray = data.split(\"\\n\");\r\n\t\t\tvar new_form = formArray[0];\r\n\t\t\tvar new_form_menu = formArray[1];\r\n\t\t\tvar survey_title = formArray[2];\r\n\t\t\tdocument.getElementById('formlabel-'+form_name).innerHTML = new_form_menu;\r\n\t\t\tdocument.getElementById('formlabel-'+form_name).style.display = '';\r\n\t\t\tdocument.getElementById('form_menu_description_input_span-'+form_name).style.display = 'none';\r\n\t\t\tdocument.getElementById('progress-'+form_name).style.visibility = 'hidden';\r\n\t\t\tdocument.getElementById('form_menu_description_input-'+form_name).disabled = false;\r\n\t\t\tdocument.getElementById('form_menu_save_btn-'+form_name).disabled = false;\r\n\t\t\t// If instrument is a survey, prompt to also change survey title to this value\r\n\t\t\tif (askChangeSurveyTitle && survey_title != new_form_menu) {\r\n\t\t\t\tsimpleDialog(langSetSurveyTitleAsForm1+' \"<b>'+new_form_menu+'</b>\"'+langQuestionMark+\" \"\r\n\t\t\t\t\t+langSetSurveyTitleAsForm2+' \"'+survey_title+'\"'+langPeriod, langSetSurveyTitleAsForm3,null,null,\"window.location.reload();\",langNo,\"setSurveyTitleAsFormLable('\"+new_form+\"');\",langSetSurveyTitleAsForm4);\r\n\t\t\t\treturn;\r\n\t\t\t}\r\n\t\t\t// Change menu label and reload page (if in development only)\r\n\t\t\tif (status == 0) {\r\n\t\t\t\tif (document.getElementById('form['+form_name+']') != null) {\r\n\t\t\t\t\tdocument.getElementById('form['+form_name+']').innerHTML = new_form_menu;\r\n\t\t\t\t}\r\n\t\t\t\twindow.location.reload();\r\n\t\t\t}\r\n\t\t}\r\n\t);\r\n}", "title": "" }, { "docid": "2414a8379d17acaa502fcfae54787a62", "score": "0.6019578", "text": "title( str )\n {\n this.ui.title.text(str);\n }", "title": "" }, { "docid": "e76f65f6ab56ea40ce30591797ec4fb7", "score": "0.6013636", "text": "function video_form_update(id) {\n\t$('video_title_'+id).innerHTML = $('video_form_title_'+id).value;\n}", "title": "" }, { "docid": "de7ee802345433bc9c4ab0a088dbf3bb", "score": "0.6012386", "text": "function setPageTitle() {\n const title = document.getElementById('title');\n title.innerText = pageTitle;\n}", "title": "" }, { "docid": "141b0b2c6f31524dcf025f9297745926", "score": "0.6009058", "text": "function setPageTitle() {\n let pageTitle = document.getElementById('title');\n pageTitle.innerText = title;\n}", "title": "" }, { "docid": "60aebb4a7bbb4705bdb30c5abea4c391", "score": "0.6000244", "text": "function setPageTitle(sTitle) {\n document.title = sTitle;\n}", "title": "" }, { "docid": "aedb43e2b4773108f777c74165e65504", "score": "0.59989727", "text": "function updateTitle(iTitle) {\n\t\tif (!currentDiv)\n\t\t\treturn;\n\n\t\tvar value = iTitle.getValue();\n\t\tvar data = JSON.parse(currentDiv.getAttribute('data-asset'));\n\t\tdata.title = value;\n\t\tcurrentDiv.setAttribute('data-asset', JSON.stringify(data) );\n\t\tcurrentDiv.setAttribute('title', value);\n\t}", "title": "" }, { "docid": "2e73a78fc1bec906538c6dbf97f780ca", "score": "0.59933096", "text": "function changeTitle() {\n var title = $(document).prop('title');\n\n if (title.indexOf(notif) === -1 && document.hidden) {\n changeTitle;\n $(document).prop('title', '('+ notif + ') '+titlefix);\n }\n else {\n notif += 1;\n if (document.hidden) {\n changeTitle;\n $(document).prop('title', '(' + notif + ') ' + titlefix);\n }\n }\n}", "title": "" }, { "docid": "7fcfb000ef28b37feb11139454bd4ed0", "score": "0.59929734", "text": "function setPageTitle() {\r\n const title = document.getElementById('title');\r\n title.innerText = pageTitle;\r\n}", "title": "" }, { "docid": "71d4c56a6f534ac02de4f25b86205e29", "score": "0.59915084", "text": "updateProjectName(currentTitle) {\n if (currentTitle.trim().length > 0) {\n this.pageData.projectName = currentTitle;\n } else {\n // Preserves space for users to double click to edit name if they enter a blank one\n this.pageData.projectName = \"_____________\";\n }\n }", "title": "" }, { "docid": "7bec07e006b11610dde64b0f15073fea", "score": "0.59799725", "text": "function updateProductTitle(title) {\n $('#ext-product .product-title').text(title);\n }", "title": "" }, { "docid": "ef982eeb53751b43d5d334e99c840dcf", "score": "0.5966429", "text": "function setPageTitle() {\n const title = document.getElementById('title');\n title.innerText = pageTitle;\n}", "title": "" }, { "docid": "700fb53428a77e073bbf24f01d716e34", "score": "0.5958286", "text": "setTitle(title) \n {\n if (this.width < 2 || this.height < 1)\n {\n return;\n }\n\n this.title = title;\n\n this.write(0, 0, title);\n }", "title": "" }, { "docid": "0bc1e757af53432cdbd821f08d69a51c", "score": "0.5956352", "text": "function updateTitle() {\n let LicenceType = getLicence();\n const title = document.querySelector(\"#calc .intro h2\");\n const description = document.querySelector(\"#calc .intro p\");\n title.innerHTML = titleCase(LicenceType);\n\n if (LicenceType === \"learner permit\") {\n description.innerHTML = `Please enter the expiry date as it appears in 4b of your ${LicenceType} card.`;\n }\n\n if (LicenceType === \"driving licence\") {\n description.innerHTML = `Please enter the expiry date as it appears in 4b on your ${LicenceType} card or in the third column alongside the categories on your paper driving licence.`;\n }\n\n clearDisplay();\n }", "title": "" }, { "docid": "97ec1c180b68cd95a7b3262141275d9b", "score": "0.5955018", "text": "function setTitle(title) {\n var pageTitle = document.getElementById('page-title');\n pageTitle.innerHTML = title; \n}", "title": "" }, { "docid": "98fd2fe4a5ee5e3e6b1e0597d76c547c", "score": "0.5954415", "text": "function set_title() {\n // get title from query string\n const urlParams = new URLSearchParams(window.location.search);\n\n // go ahead and set doc title\n document.title = urlParams.get('title');\n}", "title": "" }, { "docid": "5c1bf27ace49ab348c6d353573bdd1f1", "score": "0.59424514", "text": "function centerControlTitle(title) {\n $(\"#\" + centerControlConfig.title_id).text(title);\n }", "title": "" }, { "docid": "d63b03f1f9722075ce45a1215b8e5204", "score": "0.593855", "text": "function changePageTitle(page_title){\n \n $('#page-title').text(page_title);\n document.title=page_title;\n}", "title": "" }, { "docid": "c02685dc3a338cf321a6f662727895af", "score": "0.5921401", "text": "function createSettingsInputTitle (text, isRequired) {\n const settingsInputTitle = document.createElement('span');\n settingsInputTitle.classList.add('general-input-title');\n settingsInputTitle.innerHTML = text;\n if (isRequired)\n addRequiredItemSign(settingsInputTitle);\n document.querySelector('.filter-settings-content-wrapper').appendChild(settingsInputTitle);\n}", "title": "" }, { "docid": "5f70ec8067e47309a209e6e20dbf678b", "score": "0.5904281", "text": "function addTitle() {\n\t\n}", "title": "" } ]
3f7cbc1aa8b0756581d80c65f23e64a4
Function to generate pairs of points, representing Euler Numerical Solution
[ { "docid": "e94c31960d7682d94feebfc6ae81e025", "score": "0.5791793", "text": "function generate_Euler(start, y0, end, gap, fun) {\n let x_axis = generate_points(start, end, gap);\n let y_axis = [];\n y_axis.push(y0);\n let res = [];\n let dest = Math.round((end - start)/gap + 1);\n for (let i = 1; i <= dest; i++) {\n y_axis.push(y_axis[i - 1] + gap * fun(x_axis[i - 1], y_axis[i - 1]));\n }\n for (let i = 1; i <= dest; i++) {\n res.push({\n x: x_axis[i-1],\n y: y_axis[i-1]\n });\n }\n return res;\n}", "title": "" } ]
[ { "docid": "f87600aa9fc8213830abfbc9c2cd0eba", "score": "0.63948184", "text": "function EulerSolution1 () {\n }", "title": "" }, { "docid": "22a626643538c0572ccb6887835fdff9", "score": "0.60909575", "text": "function EulerSolution55() {\n }", "title": "" }, { "docid": "91e8706146ce8fa3e564feb39a26758f", "score": "0.5821038", "text": "function generatePoints(numberOfPoints=20, layers=5, mountainFactor=1.5, factorDiscount=2,heightFactor=3,pertubationFactor=0.11){\n\n // required variables\n var points = [];\n const pi = Math.PI;\n const euler = Math.E;\n const aurea = (1 + Math.sqrt(5) / 2);\n let x, y, z;\n let xBool = false;\n let yBool = false;\n let zBool = false;\n // points choosed\n // If this points were draw in a plane, they will form a irregular base\n var varAuxPoints = [\n [5,0,0],\n [4.25,1,0],[4.75,1.75,0],[3.75,4,0],[2.75,4.85,0],[1,4.55,0],\n [0,5,0],\n [-2,4.55,0],[-3.25,4.55,0],[-4.75,1.75],\n [-5,0,0],\n [-4.75,-1.75,0],[-4.75,-3.25,0],[-3.25,-4.55,0],[-2,-3.25,0],[-0.80,-4.95,0],\n [0,-5,0],\n [1.55,-4.85,0],[3.15,-2.85,0],[4.60,-1.02,0]\n ];\n\n // For to the number of layers\n for(let j = 1; j <= layers; j++){\n // For to the number of points\n for(let i = 0; i < numberOfPoints; i++){\n\n x = varAuxPoints[i][0]*mountainFactor + xBool*pertubationFactor*pi; // pertubates points with pi when xBool is true\n y = varAuxPoints[i][1]*mountainFactor+ yBool*pertubationFactor*euler; // pertubates points with euler when yBool is true\n z = j-1 == 0 ? 0 : (j-1)*heightFactor + zBool*pertubationFactor*aurea; // pertubates points with aurea when zBool is true\n points.push(new THREE.Vector3(x, y, z)); // Push the points to the list\n xBool = i % 2 == 0 ? !xBool : xBool; // Updates the bool value when i is even\n yBool = i % 2 != 0 ? !yBool : yBool; // Updates the bool value when i is odd\n zBool = !zBool; // Updates bool value in each iteration\n\n }\n\n mountainFactor /= factorDiscount; // Discounts the mountain factor by factorDiscount\n\n }\n\n return points; // Return the generated points\n}", "title": "" }, { "docid": "7edf21589bb129d104e60926cec0dd24", "score": "0.5782984", "text": "function applyEulerMethod(f, xi, yi, h, n) {\r\n // initialize solutions with initial values\r\n let solutions = {\r\n x: [xi],\r\n y: [yi]\r\n };\r\n\r\n for (let j=1; j<=n; j++) {\r\n yi += h*f(xi, yi);\r\n xi += h;\r\n\r\n solutions.x.push(xi);\r\n solutions.y.push(yi);\r\n }\r\n\r\n return solutions;\r\n}", "title": "" }, { "docid": "1717933f17ff151db86648db52e15a1d", "score": "0.5776439", "text": "function p12() {\n var divisors = 0;\n var number = 0;\n var index = 0;\n while (divisors <= 500) {\n number = euler.triangularNumberAt(index);\n var factors = euler.findFactorsOf(number);\n divisors = factors.length;\n index++;\n }\n console.log(number);\n}", "title": "" }, { "docid": "783117a855f050fafd3e20cc9c678f26", "score": "0.5722789", "text": "function generate_Improved_Euler(start, y0, end, gap, fun) {\n let x_axis = generate_points(start, end, gap);\n let y_axis = [];\n y_axis.push(y0);\n let res = [];\n let dest = Math.round((end - start)/gap + 1);\n for (let i = 1; i <= dest; i++) {\n y_axis.push(y_axis[i - 1] + (gap/2) * (fun(x_axis[i - 1], y_axis[i - 1]) + fun(x_axis[i], (y_axis[i-1] + gap*fun(x_axis[i - 1], y_axis[i - 1])))));\n }\n for (let i = 1; i <= dest; i++) {\n res.push({\n x: x_axis[i-1],\n y: y_axis[i-1]\n });\n }\n return res;\n}", "title": "" }, { "docid": "6ebff9b95d07db4257c95f8d10387ab4", "score": "0.56527144", "text": "function euler () {\n var xPoint = Number(document.getElementById('x').value) || 0;\n var yPoint = Number(document.getElementById('y').value) || 0;\n var zPoint = Number(document.getElementById('z').value) || 0;\n var angle = Number(document.getElementById('eulerAngle').value) || 90;\n\n var radians = (Math.PI / 180) * (angle);\n var cos = Math.cos(radians);\n var sin = Math.sin(radians);\n\n return {\n x: (() => {\n var y = (yPoint * cos) - (zPoint * sin);\n var z = (yPoint * sin) + (zPoint * cos);\n return [Math.round(xPoint), Math.round(y), Math.round(z)]\n })(),\n y:(() => {\n var x = (zPoint * sin) + (xPoint * cos);\n var z = (zPoint * cos) - (xPoint * sin);\n return [Math.round(x), Math.round(yPoint), Math.round(z)]\n })(),\n z:(() => {\n var x = (xPoint * cos) - (yPoint * sin);\n var y = (xPoint * sin) + (yPoint * cos);\n return [Math.round(x), Math.round(y), Math.round(zPoint)]\n })()\n }\n}", "title": "" }, { "docid": "1dcf81d3a4b1678b09a14b2c949edf71", "score": "0.56468177", "text": "function computePoints(e = null, numPoints = null) {\n const n = e ? e.target.value : numPoints;\n console.info(`computing ${n} points...`);\n\n // Specify a starting point p for our iterations\n // p must lie inside any set of three vertices\n\n const u = add(vertices[0], vertices[1]);\n const v = add(vertices[0], vertices[2]);\n let p = scale(0.25, add(u, v));\n\n // And, add our initial point into our array of points\n\n points = [p];\n\n for (let i = 0; points.length < n; i++) {\n const j = Math.floor(Math.random() * 3);\n p = add(points[i], vertices[j]);\n p = scale(0.5, p);\n points.push(p);\n }\n\n if (e) {\n update();\n render();\n }\n\n // birtum hjá slidernum hversu marga punkta er verið að rendera\n document.getElementById('punktafjoldi').innerHTML = n;\n}", "title": "" }, { "docid": "91b6b71371f9c32a8dcd2bba88702ad7", "score": "0.5616401", "text": "function probPairs( a, b, c ){\n \"use strict\";\n return a*b + a*c + b*c - 2*a*b*c; \n}", "title": "" }, { "docid": "9c730b94afb1e41cd03ea136036ea10b", "score": "0.56010157", "text": "function generateNumbers(sValue, eValue) {\n\n //generate all integers from startValue to endValue\n for(let index = sValue; index <= eValue; index++){\n\n numberSet.push(index);\n }\n\n return numberSet;\n}", "title": "" }, { "docid": "059ac80c5c9db4570765aca3c406e1cc", "score": "0.55882424", "text": "function p16() {\n var digitLut = [0, 1, 2, 3, 4, 5, 6, 7, 8, 9];\n var result = euler.pow(2, 1000);\n var start = \"0\";\n var sum = 0;\n for (var i = 0; i < result.length; i++) {\n var digit = digitLut[result[i] - start];\n sum += digit;\n }\n console.log(result + \" with sum of the digits: \" + sum);\n}", "title": "" }, { "docid": "9992cabc8510d809b1a4cca63f6db7b7", "score": "0.5550735", "text": "function calculateStepPoints(p0, p1, p2, p3) {\n var stepPoints = [];\n var i = stepInterval;\n\n // Value access\n var p0_x = p0.x;\n var p0_y = p0.y;\n var p0_p = p0.p;\n\n // Algebraic conveniences, not geometric\n var A_x = p3.x - 3 * p2.x + 3 * p1.x - p0_x;\n var A_y = p3.y - 3 * p2.y + 3 * p1.y - p0_y;\n var A_p = p3.p - 3 * p2.p + 3 * p1.p - p0_p;\n var B_x = 3 * p2.x - 6 * p1.x + 3 * p0_x;\n var B_y = 3 * p2.y - 6 * p1.y + 3 * p0_y;\n var B_p = 3 * p2.p - 6 * p1.p + 3 * p0_p;\n var C_x = 3 * p1.x - 3 * p0_x;\n var C_y = 3 * p1.y - 3 * p0_y;\n var C_p = 3 * p1.p - 3 * p0_p;\n\n var t = (i - stepOffset) / Math.sqrt(C_x * C_x + C_y * C_y);\n\n while (t <= 1.0) {\n // Point\n var step_x = t * (t * (t * A_x + B_x) + C_x) + p0_x;\n var step_y = t * (t * (t * A_y + B_y) + C_y) + p0_y;\n var step_p = t * (t * (t * A_p + B_p) + C_p) + p0_p;\n stepPoints.push(new Point(\n step_x,\n step_y,\n step_p\n ));\n\n // Step distance until next one\n var s_x = t * (t * 3 * A_x + 2 * B_x) + C_x; // dx/dt\n var s_y = t * (t * 3 * A_y + 2 * B_y) + C_y; // dy/dt\n var s = Math.sqrt(s_x * s_x + s_y * s_y); // s = derivative in 2D space\n var dt = i / s; // i = interval / derivative in 2D\n t = t + dt;\n }\n\n // TODO: Maybe use a better approximation for distance along the bezier?\n if (stepPoints.length == 0) // We didn't step at all along this Bezier\n stepOffset = stepOffset + p0.getDistance(p3);\n else\n stepOffset = stepPoints.last().getDistance(p3);\n\n return stepPoints;\n }", "title": "" }, { "docid": "008c5cfd4883c02f3c2e945c5be6e6e9", "score": "0.5539846", "text": "function calculatePiMonteCarlo(numPoints) {\n let count = 0;\n let x, y;\n\n for (var i = 0; i < numPoints; i++) {\n x = Math.random();\n y = Math.random();\n\n if (x*x + y*y <= 1) count++;\n }\n\n return 4*count/numPoints;\n}", "title": "" }, { "docid": "62a7317af8cfb6fd99bf25635755462d", "score": "0.5511171", "text": "function printAllPairs(n) {\n for(let i = 0; i < n; i++) {\n for(let j = 0; j < n; j++) {\n console.log(i, j);\n }\n }\n}", "title": "" }, { "docid": "32094227405167309e67d2928667f514", "score": "0.55108947", "text": "function drawEuler () {\n var eulerDiv = document.querySelector('.euler');\n var coordinates = euler();\n eulerDiv.innerHTML = '<table class=\"table table-dark\">' +\n '<tbody>' +\n '<tr>' +\n '<th scope=\"row\">x</th>' +\n '<td>' + coordinates.x[0] + '</td>' +\n '<td>' + coordinates.x[1] + '</td>' +\n '<td>' + coordinates.x[2] + '</td>' +\n '</tr>' +\n '<tr>' +\n '<th scope=\"row\">y</th>' +\n '<td>' + coordinates.y[0] + '</td>' +\n '<td>' + coordinates.y[1] + '</td>' +\n '<td>' + coordinates.y[2] + '</td>' +\n '</tr>' +\n '<tr>' +\n '<th scope=\"row\">z</th>' +\n '<td>' + coordinates.z[0] + '</td>' +\n '<td>' + coordinates.z[1] + '</td>' +\n '<td>' + coordinates.z[2] + '</td>' +\n '</tr>' +\n '</tbody>' +\n '</table>';\n}", "title": "" }, { "docid": "27d5026cc168476e1dc9cb9c7d3d5ad5", "score": "0.5479214", "text": "function createPairs(arr) {\n let ticks = 0;\n for (let i = 0; i < arr.length; i++) {\n ticks++;\n for (let j = i + 1; j < arr.length; j++) {\n ticks++;\n console.log(arr[i] + \", \" + arr[j]);\n }\n }\n return { ticks };\n}", "title": "" }, { "docid": "8cb18a0b464fb099aaa133daa665abe7", "score": "0.54608005", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for(let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "8cb18a0b464fb099aaa133daa665abe7", "score": "0.54608005", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for(let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "8cb18a0b464fb099aaa133daa665abe7", "score": "0.54608005", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for(let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "14f913f52857254f4aef490a95030255", "score": "0.54595274", "text": "function printAllPairs(n) {\n for (let i = 0; i < n; i++) {\n for (let j = 0; j < n; j++) {\n console.log(i, j);\n }\n }\n}", "title": "" }, { "docid": "e127258c8c4f3270b12e694ca4a4ddf3", "score": "0.5454658", "text": "static _generatePoints(p1, p2, segments) {\n let points = [];\n let angle = Electricity._angleBetweenPoints(p1, p2);\n let prevX = p1.x;\n let prevY = p1.y;\n let distance = Electricity._distanceBetweenPoints({\n x: prevX,\n y: prevY\n }, p2);\n let length = distance / segments;\n\n let mutation = 150;\n\n let giveUp = 100;\n\n while (distance > length && giveUp >= 0) {\n let randomAngleMutator = Util.randomInteger(0, mutation);\n randomAngleMutator -= (mutation / 2);\n randomAngleMutator = randomAngleMutator / 200;\n\n let x2 = prevX + Math.cos(angle + randomAngleMutator) * length;\n let y2 = prevY + Math.sin(angle + randomAngleMutator) * length;\n prevX = x2;\n prevY = y2;\n\n angle = Electricity._angleBetweenPoints({\n x: x2,\n y: y2\n }, p2);\n distance = Electricity._distanceBetweenPoints({\n x: prevX,\n y: prevY\n }, p2);\n\n points.push({\n x: x2,\n y: y2\n });\n giveUp--;\n\n }\n\n return points;\n }", "title": "" }, { "docid": "2677d4e13cb7d3ce9d02247cfb76aa1a", "score": "0.5444063", "text": "function allSquaredPairs(num) {\r\n let array = []\r\n for (let i = 0; i <= Math.sqrt(num/2); i++) if (Math.sqrt(num-i*i) % 1 == 0) array.push([i, Math.sqrt(num-i*i)])\r\n return array\r\n}", "title": "" }, { "docid": "d7c059e53438119e69ec1919fdbe5c6b", "score": "0.54429656", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for(let j = i+1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "b2a00aa48a6b46ede40c07bb5193ce6c", "score": "0.5435552", "text": "function generarPointOfCurve() {\n pointsCurve = [];\n for (var i = 0; i <= 10; i = i + 0.1) {\n pointsCurve.push([i, Math.sqrt(Math.pow(7, 2) - Math.pow(i, 2))]);\n }\n }", "title": "" }, { "docid": "1ea8ac03bf7335315cc645fb2ba49bf4", "score": "0.54303133", "text": "function pairs(number) {\n\tif(number%2 == 0) return \"Es parell\";\n\treturn \"Es imparell\";\n}", "title": "" }, { "docid": "ba9a9d7d46355e1829886b6b16f25afc", "score": "0.5423739", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for (let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j]);\n }\n }\n}", "title": "" }, { "docid": "ba9a9d7d46355e1829886b6b16f25afc", "score": "0.5423739", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for (let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j]);\n }\n }\n}", "title": "" }, { "docid": "32d9d14de369152b29fd737550a48722", "score": "0.5416147", "text": "function generateMultiples(x, y, limit) {\n let multiples = [];\n for (let i = 0; i < limit; i++) {\n if (i % x == 0 || i % y == 0) {\n multiples.push(i);\n }\n }\n return multiples;\n}", "title": "" }, { "docid": "86d5de9af32dd489da698bfda01b2eae", "score": "0.5411663", "text": "function _generateKeyPair(state, options, callback) {\n if (typeof options === 'function') {\n callback = options;\n options = {};\n }\n\n options = options || {};\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n\n if ('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function (err, num) {\n if (err) {\n return callback(err);\n }\n\n state.p = num;\n\n if (state.q !== null) {\n return finish(err, state.q);\n }\n\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if (err) {\n return callback(err);\n } // set q\n\n\n state.q = num; // ensure p is larger than q (swap them if not)\n\n if (state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n } // ensure p is coprime with e\n\n\n if (state.p.subtract(BigInteger.ONE).gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n } // ensure q is coprime with e\n\n\n if (state.q.subtract(BigInteger.ONE).gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n } // compute phi: (p - 1)(q - 1) (Euler's totient function)\n\n\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1); // ensure e and phi are coprime\n\n if (state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n } // create n, ensure n is has the right number of bits\n\n\n state.n = state.p.multiply(state.q);\n\n if (state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n } // set keys\n\n\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(state.n, state.e, d, state.p, state.q, d.mod(state.p1), d.mod(state.q1), state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "1f396fef5a95b1fced0549f8b742077e", "score": "0.54090184", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for(let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + \", \" + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "3d1888cddd4fdc7c872ee263ba67a63c", "score": "0.53968644", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for(let j = i+1; j < arr.length; j++) {\n console.log(arr[i] + ', ' + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "fec4f5701aaf526d8d9a9f0925245517", "score": "0.53943604", "text": "function looping(x,y){\n for(var i=0; i<x; i++){\n for(var j=0; j<y; j++){
 \n console.log(i*j);\n } \n }\n return x*y;\n}", "title": "" }, { "docid": "2bd88735b5fbb8e320cd85baaaf33084", "score": "0.53859663", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for (let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + ', ' + arr[j]);\n }\n }\n}", "title": "" }, { "docid": "2bd88735b5fbb8e320cd85baaaf33084", "score": "0.53859663", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for (let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + ', ' + arr[j]);\n }\n }\n}", "title": "" }, { "docid": "2bd88735b5fbb8e320cd85baaaf33084", "score": "0.53859663", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for (let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + ', ' + arr[j]);\n }\n }\n}", "title": "" }, { "docid": "2bd88735b5fbb8e320cd85baaaf33084", "score": "0.53859663", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) {\n for (let j = i + 1; j < arr.length; j++) {\n console.log(arr[i] + ', ' + arr[j]);\n }\n }\n}", "title": "" }, { "docid": "20abf600cb2f88879d8b4866987b6e0b", "score": "0.5374363", "text": "function euler18() {\n const triangle = [\n '75',\n '95 64',\n '17 47 82',\n '18 35 87 10',\n '20 04 82 47 65',\n '19 01 23 75 03 34',\n '88 02 77 73 07 63 67',\n '99 65 04 28 06 16 70 92',\n '41 41 26 56 83 40 80 70 33',\n '41 48 72 33 47 32 37 16 94 29',\n '53 71 44 65 25 43 91 52 97 51 14',\n '70 11 33 28 77 73 17 78 39 68 17 57',\n '91 71 52 38 17 14 91 43 58 50 27 29 48',\n '63 66 04 68 89 53 67 30 73 16 69 87 40 31',\n '04 62 98 27 23 09 70 98 73 93 38 53 60 04 23'];\n // Good luck!\n return true;\n}", "title": "" }, { "docid": "3ee14e21db897b37c8c39eae5b9caf8b", "score": "0.5371118", "text": "function multiply(x,y) {\n let result = 0;\n for (let i=1; i<=y; i++) {\n\n result = add(result,x);\n \n }\n return result;\n}", "title": "" }, { "docid": "226d38dfe578f527dab0e328ed580ebc", "score": "0.53434473", "text": "function points(twoPointers, threePointers) {\n return (twoPointers * 2) + (threePointers * 3);\n}", "title": "" }, { "docid": "5be658c0e154a1ed0ea05722262f9645", "score": "0.53411293", "text": "function p1() {\n var multiples= euler.findMultiplesBelow(1000, 3, 5); var result = 0;\n for (var i in multiples) {\n result += multiples[i];\n }\n console.log(result);\n}", "title": "" }, { "docid": "74b2678694467f8a253cc2ec674b4ef0", "score": "0.5335836", "text": "function generateAdjacentNumber (num) {\n\t\tvar arr = [];\n\t\tif(num == 1) {\n\t\t\tarr.push(num + 1);\n\t\t\tarr.push(num + settings.grid);\n\t\t\tarr.push(num + settings.grid + 1);\n\t\t} else if(num == totalBox) {\n\t\t\tarr.push(num - settings.grid - 1);\n\t\t\tarr.push(num - settings.grid);\n\t\t\tarr.push(num - 1);\n\t\t} else if(num == settings.grid) {\n\t\t\tarr.push(num - 1);\n\t\t\tarr.push(num + settings.grid - 1);\n\t\t\tarr.push(num + settings.grid);\n\t\t} else if(num == (settings.grid * (settings.grid - 1) + 1)) {\n\t\t\tarr.push(num - settings.grid);\n\t\t\tarr.push(num - settings.grid + 1);\n\t\t\tarr.push(num + 1);\n\t\t} else if(num > 1 && num < settings.grid) {\n\t\t\tarr.push(num - 1);\n\t\t\tarr.push(num + 1);\n\t\t\tarr.push(num + settings.grid - 1);\n\t\t\tarr.push(num + settings.grid);\n\t\t\tarr.push(num + settings.grid + 1);\n\t\t} else if(num > (settings.grid * (settings.grid - 1)) && num < totalBox) {\n\t\t\tarr.push(num - settings.grid + 1);\n\t\t\tarr.push(num - settings.grid);\n\t\t\tarr.push(num - settings.grid - 1);\n\t\t\tarr.push(num - 1);\n\t\t\tarr.push(num + 1);\n\t\t} else if(num > settings.grid && num < (settings.grid * (settings.grid - 1)) && (num % settings.grid == 1)) {\n\t\t\tarr.push(num - settings.grid);\n\t\t\tarr.push(num + settings.grid);\n\t\t\tarr.push(num - settings.grid + 1);\n\t\t\tarr.push(num + settings.grid + 1);\n\t\t\tarr.push(num + 1);\n\t\t} else if(num > settings.grid && num < (settings.grid * (settings.grid - 1)) && (num % settings.grid == 0)) {\n\t\t\tarr.push(num - settings.grid);\n\t\t\tarr.push(num + settings.grid);\n\t\t\tarr.push(num - settings.grid - 1);\n\t\t\tarr.push(num + settings.grid - 1);\n\t\t\tarr.push(num - 1);\n\t\t} else {\n\t\t\tarr.push(num - settings.grid + 1);\n\t\t\tarr.push(num - settings.grid);\n\t\t\tarr.push(num - settings.grid - 1);\n\t\t\tarr.push(num - 1);\n\t\t\tarr.push(num + 1);\n\t\t\tarr.push(num + settings.grid - 1);\n\t\t\tarr.push(num + settings.grid);\n\t\t\tarr.push(num + settings.grid + 1);\n\t\t}\n\t\tfor(var i = 0, l = arr.length; i < l; i++) {\n\t\t\tadjacentNumber[arr[i]] += 1;\n\t\t}\n\t}", "title": "" }, { "docid": "61630bae8f7227c65fb5123804557a58", "score": "0.5333069", "text": "function looping(x,y){\n for(var i=0; i<x; i++){\n for(var j=0; j<x; j++){ \n console.log(i*j);\n } \n }\n}", "title": "" }, { "docid": "ba2ad75082fc595881798a304d3292f1", "score": "0.5331862", "text": "function applyImprovedEulerMethod(f, xi, yi, h, n) {\r\n // initialize solutions with initial values\r\n let solutions = {\r\n x: [xi],\r\n y: [yi]\r\n };\r\n\r\n let temp=-1;\r\n for (let j=1; j<=n; j++) {\r\n temp = f(xi, yi);\r\n xi += h;\r\n yi += 0.5*h*(temp + f(xi, yi+h*temp));\r\n\r\n solutions.x.push(xi);\r\n solutions.y.push(yi);\r\n }\r\n return solutions;\r\n}", "title": "" }, { "docid": "753b3c1f64245fb923e1dc0af8795099", "score": "0.5321926", "text": "function looping(x,y){\n for(var i=0; i<x; i++){\n for(var j=0; j<y; j++){ \n console.log(i*j);\n } \n }\n return x*y;\n}", "title": "" }, { "docid": "64d117015ba9c629c92c040fd7691604", "score": "0.5314287", "text": "function obtenerXY(a,b,c,d,e,f){\n let listTemp=[];\n let g=a*e-b*d;\n let x=(c*e-b*f)/g;\n let y=(a*f-c*d)/g;\n listTemp.push(x);\n listTemp.push(y);\n return listTemp;\n }", "title": "" }, { "docid": "99be53b6108dc838a3f2bd80f693e342", "score": "0.5311825", "text": "function pythaTriplets(triplet) {\n let a, b, c = 0;\n let m = 2;\n while (c < triplet) {\n for (let n = 1; n < m; ++n) {\n a = m * m - n * n;\n b = 2 * m * n;\n c = m * m + n * n;\n if (c > triplet)\n break;\n console.log(a, b, c);\n }\n m++;\n }\n}", "title": "" }, { "docid": "864345d1ce9d7a41eb0878f94b51bd8b", "score": "0.5311326", "text": "function tri(n){return n*(n+1)/2;}", "title": "" }, { "docid": "f1732ec483921045b2c1effef31a80e5", "score": "0.5305847", "text": "function looping(x,y) {\n for(var i=0; i<x; i++) {\n for(var j=0; j<y; j++) { \n console.log(i*j);\n } \n }\nreturn x*y;\n}", "title": "" }, { "docid": "ac972df7ebcd1b54a06fb69cbf255b60", "score": "0.5304559", "text": "function euler1(){\n var numbers = [];\n var total = 0;\n for(var i = 0; i < 1000; i++){\n if(i % 3 === 0 || i % 5 === 0)\n numbers.push(i);\n }\n numbers.forEach(function(number){\n total = total + number;\n });\n console.log(total);\n }", "title": "" }, { "docid": "df9f76401416a195b700b12ed0a97e3c", "score": "0.53022313", "text": "function looping(x,y) {\n for(var i=0; i<x; i++) {\n for(var j=0; j<x; j++) { \n console.log(i*j);\n } \n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "65a5bf6794db955070704bee72afbf24", "score": "0.5300771", "text": "function _generateKeyPair(state, options, callback) {\n if(typeof options === 'function') {\n callback = options;\n options = {};\n }\n options = options || {};\n\n var opts = {\n algorithm: {\n name: options.algorithm || 'PRIMEINC',\n options: {\n workers: options.workers || 2,\n workLoad: options.workLoad || 100,\n workerScript: options.workerScript\n }\n }\n };\n if('prng' in options) {\n opts.prng = options.prng;\n }\n\n generate();\n\n function generate() {\n // find p and then q (done in series to simplify)\n getPrime(state.pBits, function(err, num) {\n if(err) {\n return callback(err);\n }\n state.p = num;\n if(state.q !== null) {\n return finish(err, state.q);\n }\n getPrime(state.qBits, finish);\n });\n }\n\n function getPrime(bits, callback) {\n forge.prime.generateProbablePrime(bits, opts, callback);\n }\n\n function finish(err, num) {\n if(err) {\n return callback(err);\n }\n\n // set q\n state.q = num;\n\n // ensure p is larger than q (swap them if not)\n if(state.p.compareTo(state.q) < 0) {\n var tmp = state.p;\n state.p = state.q;\n state.q = tmp;\n }\n\n // ensure p is coprime with e\n if(state.p.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.p = null;\n generate();\n return;\n }\n\n // ensure q is coprime with e\n if(state.q.subtract(BigInteger.ONE).gcd(state.e)\n .compareTo(BigInteger.ONE) !== 0) {\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // compute phi: (p - 1)(q - 1) (Euler's totient function)\n state.p1 = state.p.subtract(BigInteger.ONE);\n state.q1 = state.q.subtract(BigInteger.ONE);\n state.phi = state.p1.multiply(state.q1);\n\n // ensure e and phi are coprime\n if(state.phi.gcd(state.e).compareTo(BigInteger.ONE) !== 0) {\n // phi and e aren't coprime, so generate a new p and q\n state.p = state.q = null;\n generate();\n return;\n }\n\n // create n, ensure n is has the right number of bits\n state.n = state.p.multiply(state.q);\n if(state.n.bitLength() !== state.bits) {\n // failed, get new q\n state.q = null;\n getPrime(state.qBits, finish);\n return;\n }\n\n // set keys\n var d = state.e.modInverse(state.phi);\n state.keys = {\n privateKey: pki.rsa.setPrivateKey(\n state.n, state.e, d, state.p, state.q,\n d.mod(state.p1), d.mod(state.q1),\n state.q.modInverse(state.p)),\n publicKey: pki.rsa.setPublicKey(state.n, state.e)\n };\n\n callback(null, state.keys);\n }\n}", "title": "" }, { "docid": "8fc949fa7c6681b55117d4da3cd28894", "score": "0.5291133", "text": "function euler9(limit)\n{\n\tvar trifectas = [];\t\t//it's awesome, baby!\n\n\t//skip 1 because 1^2 is 1 and can't be part of a pythagorean triplet\n\tfor(b=3;b<limit;b++)\n\t{\n\t\ta = 2;\n\t\twhile(a<b)\n\t\t{\n\t\t\tvar bSq = b * b;\t\t//a^2\n\t\t\tvar aSq = a * a;\t\t//b^2\n\t\t\tvar cSq = aSq + bSq;\t\t\n\t\t\t\n\t\t\tvar c = Math.sqrt(cSq);\t\t//see if c^2, if not, it doesn't meet criteria\n\t\t\t\n\t\t\tif(Number.isInteger(c))\n\t\t\t{\n\t\t\t\ttrifectas.push([a, b, c]);\n\t\t\t}\n\n\t\t\ta++;\t\t//next iteration\n\t\t}\n\t}\n\n\t//filter only sums of 1000\n\ttrifectas = trifectas.filter(function(n){\n\t\t\treturn (n[0] + n[1] + n[2] == 1000);\t\t\n\t\t})\n\n\t//array within array - should only be one item though\n\tif(trifectas[0]){\n\t\treturn trifectas[0].reduce(function(a,b){return a*b;});\t\t//trifectas(500) = 31875000\n\t}\n\telse{\n\t\treturn \"no match\";\n\t}\n}", "title": "" }, { "docid": "10851d14a775436cca127ef6792472ed", "score": "0.5288318", "text": "function p5() {\n var array = [];\n for (var i = 0; i < 20; i++) {\n array[i] = i + 1;\n }\n var result = euler.findLeastCommonMultiple(array);\n console.log(result);\n}", "title": "" }, { "docid": "9b4903e94cd50449835d7497b098450c", "score": "0.5275676", "text": "function looping(x,y){\n for(var i=0; i<x; i++)\n {\n for(var j=0; j<x; j++)\n { \n console.log(i*j);\n } \n }\n}", "title": "" }, { "docid": "1605815d44a2c99e5e421227e12fd48a", "score": "0.52736485", "text": "function makePair(num1, num2) {\n let array = [];\n array.push(num1);\n array.push(num2);\n return array;\n }", "title": "" }, { "docid": "67a851b389e854de3091d7c1025f5fdb", "score": "0.52656466", "text": "function foo(x,y){\n for(var i=0; i<x; i++){\n for(var j=0; j<y; j++){\n console.log(i*j);\n } \n }\n return x*y;\n}", "title": "" }, { "docid": "7949aaec44319e648f3027323eab83c1", "score": "0.52617216", "text": "function pairs(n){\n for(var i=0; i<n ; i++){ // Big-O Notation- O(n)\n for(var j=0; j<n ; j++){ // Big-O Notation - O(n)\n console.log(i,j);\n }\n }\n }", "title": "" }, { "docid": "501b24ce70913be024e41c153297fd42", "score": "0.52548134", "text": "function createPairs(arr) {\n for (let i = 0; i < arr.length; i++) { // go thru array once\n for(let j = i+1; j < arr.length; j++) { // go thru array almost once\n console.log(arr[i] + ', ' + arr[j] );\n }\n }\n}", "title": "" }, { "docid": "673612e9228c7baa5bc4d8d9d30075b7", "score": "0.52472335", "text": "function euler16() {\n // Good luck!\n return true;\n}", "title": "" }, { "docid": "0ec4495b7f77ec720de7102a60af6546", "score": "0.5240649", "text": "function Triangle(x1, y1, x2, y2, x3, y3) {\n\n this.x1 = x1;\n this.y1 = y1;\n this.x2 = x2;\n this.y2 = y2;\n this.x3 = x3;\n this.y3 = y3;\n \n // seed to determine which one of the triangles points to be used to divide\n this.generateNew = function(seed) {\n let choice = 1;\n // seed value 4 is random\n if (seed === 4) {\n choice = random([1, 2, 3]);\n } else {\n choice = seed \n }\n // choose (x1, y1), \n // draw dividing line to the edge (x2, y2) - (x3, y3)\n if (choice === 1) {\n // divide this triangle equally into two \n // so take center of the edge (x2, y2) - (x3, y3)\n let nx = (x2 + x3) / 2;\n let ny = (y2 + y3) / 2;\n return [new Triangle(nx, ny, x1, y1, x2, y2),\n new Triangle(nx, ny, x1, y1, x3, y3)];\n // choose (x2, y2)\n // draw dividing line to the edge (x1, y1) - (x3, y3)\n } else if (choice === 2){\n let nx = (x1 + x3) / 2;\n let ny = (y1 + y3) / 2;\n return [new Triangle(nx, ny, x2, y2, x1, y1),\n new Triangle(nx, ny, x2, y2, x3, y3)]; \n // choose (x3, y3)\n // draw dividing line to the edge (x2, y2) - (x1, y1)\n } else if (choice === 3){\n let nx = (x2 + x1) / 2;\n let ny = (y2 + y1) / 2;\n return [new Triangle(nx, ny, x3, y3, x2, y2),\n new Triangle(nx, ny, x3, y3, x1, y1)]; \n } \n } \n}", "title": "" }, { "docid": "2d8da554c1aaa9abd9011a42f7974e87", "score": "0.52327394", "text": "getCantorPair(num1, num2){\n return (num1 + num2) * (num1 + num2 + 1) / 2 + num2;\n }", "title": "" }, { "docid": "c04a7ed8b681724a084f4dd9af379a13", "score": "0.52313656", "text": "function foo(x,y){\n for(var i=0; i<x; i++){\n for(var j=0; j<x; j++){\n console.log(i*j);\n } \n }\n}", "title": "" }, { "docid": "cdf6ed115f2de92a0bcacefcad6e97a4", "score": "0.5226738", "text": "function DiffiHellman(P,Q, size){\r\n let p,q;\r\n if (SolovayStrassenTest(BigInt(P),32) && SolovayStrassenTest(BigInt(Q),32)){\r\n p = BigInt(P); q = BigInt(Q);\r\n } else {\r\n let numbers = getPrimeNumbers(size);\r\n console.log(numbers);\r\n // Find g\r\n q = BigInt(numbers.q); p = BigInt(numbers.p);\r\n }\r\n let g = 5n;\r\n while(fastDegreeModule(g,q,p) === 1n){\r\n g = BigInt(bigInt.randBetween(1, (p-1n).toString()))\r\n }\r\n\r\n // first client\r\n let Xa = (bigInt.randBetween((p/2n).toString(), (p-1n).toString())).toString();\r\n let Ya = fastDegreeModule(g,Xa, p);\r\n\r\n // second\r\n let Xb = (bigInt.randBetween((p/2n).toString(), (p-1n).toString())).toString();\r\n let Yb = fastDegreeModule(g,Xb, p);\r\n\r\n // Connection\r\n let Zab = fastDegreeModule(Yb,Xa, p);\r\n let Zba = fastDegreeModule(Ya,Xb, p);\r\n\r\n // console.table({q, p, g, Xa, Ya, Xb, Yb, Zab, Zba})\r\n return {q, p, g, Xa, Ya, Xb, Yb, Zab, Zba}\r\n}", "title": "" }, { "docid": "e9ef37418314dac548f11ca57db4ccd2", "score": "0.52261084", "text": "function Triangulate(points)\n{\n var indices = [];\n\n var n = points.length;\n if (n < 3)\n return indices;\n\n var V = [];\n V.length = n;\n\n if (Area() > 0)\n {\n for (var v = 0; v < n; v++)\n V[v] = v;\n }\n else\n {\n for (var v = 0; v < n; v++)\n V[v] = (n - 1) - v;\n }\n\n var nv = n;\n var count = 2 * nv;\n for (var m = 0, v = nv - 1; nv > 2; )\n {\n if ((count--) <= 0)\n return indices;\n\n var u = v;\n if (nv <= u)\n u = 0;\n v = u + 1;\n if (nv <= v)\n v = 0;\n var w = v + 1;\n if (nv <= w)\n w = 0;\n\n if (Snip(u, v, w, nv, V))\n {\n var a, b, c, s, t;\n a = V[u];\n b = V[v];\n c = V[w];\n indices.push(a);\n indices.push(b);\n indices.push(c);\n m++;\n for (s = v, t = v + 1; t < nv; s++, t++)\n V[s] = V[t];\n nv--;\n count = 2 * nv;\n }\n }\n\n indices.reverse();\n\n return indices;\n\n function Area()\n {\n var n = points.length;\n var A = 0.0;\n for (var p = n - 1, q = 0; q < n; p = q++)\n {\n var pval = points[p];\n var qval = points[q];\n A += pval.x * qval.y - qval.x * pval.y;\n }\n return A * 0.5;\n }\n\n function Snip(u, v, w, n, V)\n {\n var A = points[V[u]];\n var B = points[V[v]];\n var C = points[V[w]];\n if (Help.EPSILON > (((B.x - A.x) * (C.y - A.y)) - ((B.y - A.y) * (C.x - A.x))))\n return false;\n for (var p = 0; p < n; p++)\n {\n if ((p == u) || (p == v) || (p == w))\n continue;\n var P = points[V[p]];\n if (InsideTriangle(A, B, C, P))\n return false;\n }\n return true;\n }\n\n function InsideTriangle( A, B, C, P)\n {\n var ax, ay, bx, by, cx, cy, apx, apy, bpx, bpy, cpx, cpy;\n var cCROSSap, bCROSScp, aCROSSbp;\n\n ax = C.x - B.x; ay = C.y - B.y;\n bx = A.x - C.x; by = A.y - C.y;\n cx = B.x - A.x; cy = B.y - A.y;\n apx = P.x - A.x; apy = P.y - A.y;\n bpx = P.x - B.x; bpy = P.y - B.y;\n cpx = P.x - C.x; cpy = P.y - C.y;\n\n aCROSSbp = ax * bpy - ay * bpx;\n cCROSSap = cx * apy - cy * apx;\n bCROSScp = bx * cpy - by * cpx;\n\n return ((aCROSSbp >= 0.0) && (bCROSScp >= 0.0) && (cCROSSap >= 0.0));\n }\n}", "title": "" }, { "docid": "3f35d2388c87d991b158e093bd2c5b10", "score": "0.5225259", "text": "function foo(x, y) {\n for (var i = 0; i < x; i++) {\n for (var j = 0; j < x; j++) {\n console.log(i * j);\n }\n }\n}", "title": "" }, { "docid": "d12ff4667864c037fc819967c547f1c7", "score": "0.5221507", "text": "function foo(x, y) {\n for (var i = 0; i < x; i++) {\n for (var j = 0; j < y; j++) {\n console.log(i * j);\n }\n }\n return x * y;\n}", "title": "" }, { "docid": "074404dc2cf5f8cd6615169956dd871e", "score": "0.52174807", "text": "function SE2801() {\n calculatefor(new Array(\n// 2801 1 6\n2744109.553819, 1.0, -4.0, 4.0, 3050.4, 3050.4,\n -0.1803450, 0.5820856, 3.000e-06, -9.880e-06,\n 0.6096880, 0.0099653, 1.349e-04, -5.000e-08,\n -22.4293499, 0.0048600, 6.000e-06,\n 194.0474091, 14.9970312, 0.000e-00,\n 0.5385270, 0.0000303, -1.310e-05,\n -0.0075730, 0.0000302, -1.310e-05,\n 0.0047517, 0.0047280,\n// 2801 7 2\n2744286.773911, 7.0, -4.0, 4.0, 3053.4, 3053.4,\n 0.2196610, 0.5065598, -9.000e-06, -5.710e-06,\n -0.2173080, 0.0085962, -1.346e-04, -1.800e-07,\n 22.8687191, -0.0033310, -5.000e-06,\n 283.5342407, 14.9993315, 0.000e-00,\n 0.5653280, 0.0000197, -9.700e-06,\n 0.0190950, 0.0000196, -9.700e-06,\n 0.0046038, 0.0045809,\n// 2801 12 26\n2744464.201819, 17.0, -4.0, 4.0, 3056.5, 3056.5,\n 0.0860050, 0.5723788, 1.850e-05, -9.280e-06,\n -0.0609870, -0.0359821, 1.794e-04, 7.200e-07,\n -23.2470798, 0.0016250, 6.000e-06,\n 75.2693100, 14.9965391, 0.000e-00,\n 0.5421370, -0.0000813, -1.270e-05,\n -0.0039810, -0.0000809, -1.270e-05,\n 0.0047478, 0.0047242,\n// 2802 6 21\n2744640.892704, 9.0, -4.0, 4.0, 3059.5, 3059.5,\n -0.2752910, 0.5251029, 9.900e-06, -6.640e-06,\n 0.5221110, 0.0505584, -1.755e-04, -7.300e-07,\n 23.3330708, -0.0002680, -6.000e-06,\n 314.1235352, 14.9989862, 0.000e-00,\n 0.5556080, 0.0001151, -1.050e-05,\n 0.0094230, 0.0001145, -1.040e-05,\n 0.0046086, 0.0045857,\n// 2802 12 16\n2744818.697515, 5.0, -4.0, 4.0, 3062.6, 3062.6,\n 0.0280060, 0.5371025, 4.130e-05, -7.380e-06,\n -0.7906440, -0.0775806, 2.010e-04, 1.220e-06,\n -23.1950302, -0.0017350, 6.000e-06,\n 256.5491333, 14.9966087, 0.000e-00,\n 0.5556490, -0.0001257, -1.140e-05,\n 0.0094640, -0.0001251, -1.130e-05,\n 0.0047416, 0.0047180,\n// 2803 5 12\n2744965.942592, 11.0, -4.0, 4.0, 3065.1, 3065.1,\n 0.6641410, 0.5381558, -2.900e-06, -8.640e-06,\n -1.1661510, 0.1997010, -5.470e-05, -3.400e-06,\n 18.1345291, 0.0099700, -4.000e-06,\n 345.6975403, 15.0012321, 0.000e-00,\n 0.5365550, 0.0000667, -1.250e-05,\n -0.0095350, 0.0000663, -1.240e-05,\n 0.0046441, 0.0046210,\n// 2803 6 10\n2744995.302214, 19.0, -4.0, 4.0, 3065.6, 3065.6,\n -0.3547670, 0.5527238, 2.890e-05, -8.340e-06,\n 1.2229210, 0.0953439, -2.219e-04, -1.540e-06,\n 22.9664993, 0.0027290, -5.000e-06,\n 104.7355423, 14.9991570, 0.000e-00,\n 0.5409620, 0.0001133, -1.180e-05,\n -0.0051500, 0.0001127, -1.180e-05,\n 0.0046153, 0.0045923,\n// 2803 11 5\n2745143.162897, 16.0, -4.0, 4.0, 3068.1, 3068.1,\n 0.6141800, 0.4640232, 1.650e-05, -5.120e-06,\n 1.3222120, -0.1981160, 3.390e-05, 2.340e-06,\n -15.6584702, -0.0120050, 4.000e-06,\n 64.2322998, 15.0011806, 0.000e-00,\n 0.5714370, -0.0000252, -9.800e-06,\n 0.0251730, -0.0000250, -9.800e-06,\n 0.0046991, 0.0046757,\n// 2803 12 5\n2745172.900394, 10.0, -4.0, 4.0, 3068.6, 3068.6,\n -0.1437670, 0.4998499, 5.090e-05, -5.810e-06,\n -1.5375040, -0.1133008, 2.059e-04, 1.470e-06,\n -22.2270107, -0.0050560, 6.000e-06,\n 332.7326050, 14.9973192, 0.000e-00,\n 0.5696350, -0.0000815, -1.020e-05,\n 0.0233810, -0.0000811, -1.010e-05,\n 0.0047329, 0.0047093,\n// 2804 5 1\n2745320.631524, 3.0, -4.0, 4.0, 3071.2, 3071.2,\n 0.1565750, 0.5346877, 3.490e-05, -9.010e-06,\n -0.5882270, 0.2328813, -6.040e-05, -4.120e-06,\n 15.2103300, 0.0119720, -4.000e-06,\n 225.5926971, 15.0022240, 0.000e-00,\n 0.5334530, -0.0000179, -1.290e-05,\n -0.0126220, -0.0000178, -1.290e-05,\n 0.0046569, 0.0046337,\n// 2804 10 24\n2745497.158359, 16.0, -4.0, 4.0, 3074.2, 3074.2,\n 0.4157140, 0.4609554, 3.900e-06, -5.280e-06,\n 0.6245560, -0.2230838, 4.270e-05, 2.730e-06,\n -12.0458002, -0.0136460, 3.000e-06,\n 64.0223999, 15.0026550, 0.000e-00,\n 0.5670340, 0.0000735, -1.010e-05,\n 0.0207920, 0.0000732, -1.000e-05,\n 0.0046843, 0.0046610,\n// 2805 4 20\n2745675.278575, 19.0, -4.0, 4.0, 3077.3, 3077.3,\n 0.1099160, 0.5070941, 4.370e-05, -7.710e-06,\n 0.1790700, 0.2466567, -7.250e-05, -3.950e-06,\n 11.8059502, 0.0136080, -3.000e-06,\n 105.2515869, 15.0030413, 0.000e-00,\n 0.5424110, -0.0001145, -1.210e-05,\n -0.0037080, -0.0001140, -1.200e-05,\n 0.0046710, 0.0046478,\n// 2805 10 13\n2745851.378119, 21.0, -4.0, 4.0, 3080.3, 3080.3,\n -0.0443200, 0.4802112, 7.900e-06, -6.490e-06,\n 0.0028380, -0.2515540, 5.080e-05, 3.580e-06,\n -8.1295204, -0.0147000, 2.000e-06,\n 138.4520874, 15.0038719, 0.000e-00,\n 0.5520600, 0.0001256, -1.120e-05,\n 0.0058930, 0.0001250, -1.110e-05,\n 0.0046693, 0.0046460,\n// 2806 4 10\n2746029.698272, 5.0, -4.0, 4.0, 3083.4, 3083.4,\n -0.2952360, 0.4698117, 5.240e-05, -5.950e-06,\n 0.8403730, 0.2457892, -7.320e-05, -3.310e-06,\n 7.9399199, 0.0148630, -2.000e-06,\n 254.6953735, 15.0036173, 0.000e-00,\n 0.5584460, -0.0001226, -1.080e-05,\n 0.0122470, -0.0001220, -1.070e-05,\n 0.0046859, 0.0046626,\n// 2806 10 3\n2746205.900137, 10.0, -4.0, 4.0, 3086.4, 3086.4,\n -0.1559340, 0.5034119, 1.120e-05, -8.030e-06,\n -0.7607980, -0.2745974, 6.890e-05, 4.570e-06,\n -4.1107602, -0.0152400, 1.000e-06,\n 332.6483154, 15.0047112, 0.000e-00,\n 0.5375340, 0.0000733, -1.250e-05,\n -0.0085610, 0.0000729, -1.240e-05,\n 0.0046549, 0.0046317,\n// 2807 2 28\n2746354.048706, 13.0, -4.0, 4.0, 3089.0, 3089.0,\n 0.5611860, 0.4462662, -4.570e-05, -4.880e-06,\n -1.2566360, 0.2333523, 9.000e-05, -2.720e-06,\n -7.9744201, 0.0151950, 2.000e-06,\n 12.1983299, 15.0027733, 0.000e-00,\n 0.5740670, 0.0000133, -9.800e-06,\n 0.0277900, 0.0000133, -9.800e-06,\n 0.0047343, 0.0047107,\n// 2807 8 24\n2746531.277404, 19.0, -4.0, 4.0, 3092.0, 3092.0,\n 0.6667480, 0.5176772, -5.820e-05, -8.460e-06,\n 0.8997170, -0.2567138, -1.161e-04, 4.370e-06,\n 10.7656803, -0.0136070, -2.000e-06,\n 104.1058121, 15.0042772, 0.000e-00,\n 0.5335710, -0.0000722, -1.260e-05,\n -0.0125040, -0.0000719, -1.250e-05,\n 0.0046136, 0.0045906,\n// 2807 9 23\n2746560.589001, 2.0, -4.0, 4.0, 3092.5, 3092.5,\n -0.7569200, 0.5117576, 4.540e-05, -8.610e-06,\n -1.2153670, -0.2806208, 6.970e-05, 4.930e-06,\n -0.0493300, -0.0153630, 0.000e-00,\n 211.6971283, 15.0051270, 0.000e-00,\n 0.5324870, -0.0000112, -1.290e-05,\n -0.0135830, -0.0000111, -1.280e-05,\n 0.0046417, 0.0046186,\n// 2808 2 17\n2746708.078896, 14.0, -4.0, 4.0, 3095.1, 3095.1,\n 0.3373400, 0.4690409, -6.090e-05, -5.650e-06,\n -0.5700570, 0.2268735, 8.680e-05, -2.930e-06,\n -12.0614595, 0.0139810, 3.000e-06,\n 26.8967896, 15.0016842, 0.000e-00,\n 0.5659630, 0.0000976, -1.050e-05,\n 0.0197260, 0.0000971, -1.050e-05,\n 0.0047431, 0.0047195,\n// 2808 8 13\n2746885.861750, 9.0, -4.0, 4.0, 3098.2, 3098.2,\n 0.3163050, 0.5003871, -3.480e-05, -7.040e-06,\n 0.2749760, -0.2266949, -1.002e-04, 3.360e-06,\n 14.2291603, -0.0122390, -3.000e-06,\n 313.4463806, 15.0033302, 0.000e-00,\n 0.5455450, -0.0001246, -1.140e-05,\n -0.0005900, -0.0001240, -1.130e-05,\n 0.0046073, 0.0045844,\n// 2809 2 5\n2747062.389559, 21.0, -4.0, 4.0, 3101.2, 3101.2,\n -0.2050270, 0.5095811, -4.930e-05, -7.400e-06,\n -0.0135250, 0.2186163, 9.270e-05, -3.370e-06,\n -15.6600103, 0.0122170, 4.000e-06,\n 131.9377289, 15.0004168, 0.000e-00,\n 0.5505360, 0.0001235, -1.190e-05,\n 0.0043760, 0.0001229, -1.180e-05,\n 0.0047489, 0.0047252,\n// 2809 8 2\n2747240.166469, 16.0, -4.0, 4.0, 3104.3, 3104.3,\n -0.1458670, 0.4815858, -2.020e-05, -5.710e-06,\n -0.3759440, -0.1902478, -8.520e-05, 2.410e-06,\n 17.3479500, -0.0104200, -4.000e-06,\n 58.0423508, 15.0021629, 0.000e-00,\n 0.5598610, -0.0000866, -1.010e-05,\n 0.0136550, -0.0000862, -1.010e-05,\n 0.0046033, 0.0045804,\n// 2810 1 26\n2747416.958956, 11.0, -4.0, 4.0, 3107.3, 3107.3,\n -0.2602460, 0.5450585, -3.810e-05, -9.060e-06,\n 0.6925430, 0.1975626, 8.640e-05, -3.470e-06,\n -18.6434898, 0.0099890, 5.000e-06,\n 342.3486633, 14.9990950, 0.000e-00,\n 0.5395720, 0.0000460, -1.300e-05,\n -0.0065330, 0.0000458, -1.290e-05,\n 0.0047520, 0.0047284,\n// 2810 7 22\n2747594.221264, 17.0, -4.0, 4.0, 3110.4, 3110.4,\n -0.5128480, 0.4806636, -1.900e-05, -5.330e-06,\n -1.0720980, -0.1559593, -7.240e-05, 1.860e-06,\n 19.9606705, -0.0081300, -5.000e-06,\n 72.9421768, 15.0009642, 0.000e-00,\n 0.5656680, 0.0000130, -9.700e-06,\n 0.0194330, 0.0000129, -9.600e-06,\n 0.0046014, 0.0045785,\n// 2810 12 17\n2747742.147052, 16.0, -4.0, 4.0, 3112.9, 3112.9,\n 0.3481240, 0.5652994, -1.300e-05, -8.830e-06,\n -1.2918330, 0.0356561, 2.415e-04, -6.500e-07,\n -23.2542305, -0.0015230, 6.000e-06,\n 61.3726883, 14.9966278, 0.000e-00,\n 0.5449870, -0.0001089, -1.240e-05,\n -0.0011450, -0.0001083, -1.230e-05,\n 0.0047419, 0.0047183,\n// 2811 1 16\n2747771.614361, 3.0, -4.0, 4.0, 3113.5, 3113.5,\n -0.2409870, 0.5557321, -1.950e-05, -9.170e-06,\n 1.3840390, 0.1584090, 7.330e-05, -2.800e-06,\n -20.9635696, 0.0073400, 6.000e-06,\n 223.1063232, 14.9978447, 0.000e-00,\n 0.5402600, -0.0000643, -1.290e-05,\n -0.0058490, -0.0000640, -1.290e-05,\n 0.0047529, 0.0047292,\n// 2811 6 12\n2747918.790812, 7.0, -4.0, 4.0, 3116.0, 3116.0,\n 0.0409020, 0.5363256, -2.390e-05, -7.120e-06,\n 0.8614160, -0.0186191, -1.946e-04, 3.700e-07,\n 23.0685196, 0.0025520, -5.000e-06,\n 284.6468506, 14.9990692, 0.000e-00,\n 0.5517730, 0.0001148, -1.090e-05,\n 0.0056070, 0.0001142, -1.080e-05,\n 0.0046147, 0.0045917,\n// 2811 12 7\n2748096.571049, 2.0, -4.0, 4.0, 3119.1, 3119.1,\n 0.1470870, 0.5326971, 1.390e-05, -6.960e-06,\n -0.6663720, -0.0078876, 1.836e-04, 2.000e-08,\n -22.4382896, -0.0047930, 6.000e-06,\n 212.5599670, 14.9972429, 0.000e-00,\n 0.5598640, -0.0001216, -1.100e-05,\n 0.0136580, -0.0001210, -1.090e-05,\n 0.0047339, 0.0047103,\n// 2812 5 31\n2748273.277754, 19.0, -4.0, 4.0, 3122.1, 3122.1,\n 0.1871130, 0.5684187, -1.620e-05, -8.960e-06,\n 0.0766820, 0.0219400, -1.601e-04, -2.400e-07,\n 22.0339508, 0.0054480, -5.000e-06,\n 105.1875610, 14.9996271, 0.000e-00,\n 0.5378940, 0.0000841, -1.220e-05,\n -0.0082030, 0.0000836, -1.210e-05,\n 0.0046230, 0.0045999,\n// 2812 11 25\n2748450.693770, 5.0, -4.0, 4.0, 3125.2, 3125.2,\n 0.1795710, 0.5049418, 1.290e-05, -5.730e-06,\n 0.0179950, -0.0457391, 1.307e-04, 4.400e-07,\n -20.7249908, -0.0078540, 5.000e-06,\n 258.5149536, 14.9984150, 0.000e-00,\n 0.5717420, -0.0000543, -1.000e-05,\n 0.0254760, -0.0000540, -9.900e-06,\n 0.0047234, 0.0046999,\n// 2813 5 21\n2748627.956685, 11.0, -4.0, 4.0, 3128.3, 3128.3,\n 0.0936360, 0.5804990, 9.900e-06, -9.900e-06,\n -0.6508040, 0.0627857, -1.051e-04, -9.700e-07,\n 20.2856102, 0.0080850, -5.000e-06,\n 345.5585632, 15.0004549, 0.000e-00,\n 0.5319680, 0.0000006, -1.290e-05,\n -0.0140990, 0.0000006, -1.280e-05,\n 0.0046332, 0.0046101,\n// 2813 11 14\n2748804.668323, 4.0, -4.0, 4.0, 3131.4, 3131.4,\n 0.0963980, 0.5009802, 5.700e-06, -5.690e-06,\n 0.7269770, -0.0805130, 8.530e-05, 8.500e-07,\n -18.1881409, -0.0104950, 4.000e-06,\n 244.0870667, 14.9999704, 0.000e-00,\n 0.5707420, 0.0000577, -1.000e-05,\n 0.0244820, 0.0000574, -9.900e-06,\n 0.0047104, 0.0046870,\n// 2814 4 11\n2748953.223331, 17.0, -4.0, 4.0, 3133.9, 3133.9,\n -0.5435020, 0.5325499, 5.760e-05, -7.790e-06,\n 1.1528860, 0.1550919, -1.033e-04, -2.220e-06,\n 8.5168104, 0.0149260, -2.000e-06,\n 74.7824173, 15.0036907, 0.000e-00,\n 0.5471570, -0.0001105, -1.170e-05,\n 0.0010140, -0.0001100, -1.170e-05,\n 0.0046834, 0.0046601,\n// 2814 5 11\n2748982.638682, 3.0, -4.0, 4.0, 3134.4, 3134.4,\n 0.0535730, 0.5618935, 2.960e-05, -8.940e-06,\n -1.4038070, 0.0975532, -4.020e-05, -1.450e-06,\n 17.8811493, 0.0104250, -4.000e-06,\n 225.6960754, 15.0013838, 0.000e-00,\n 0.5381950, -0.0000843, -1.230e-05,\n -0.0079030, -0.0000839, -1.230e-05,\n 0.0046455, 0.0046223,\n// 2814 10 4\n2749129.299110, 19.0, -4.0, 4.0, 3137.0, 3137.0,\n -0.5008030, 0.5267293, 1.650e-05, -7.630e-06,\n -1.2633760, -0.1657195, 9.710e-05, 2.300e-06,\n -4.6578698, -0.0154430, 1.000e-06,\n 107.7649994, 15.0046864, 0.000e-00,\n 0.5468110, 0.0001251, -1.160e-05,\n 0.0006700, 0.0001244, -1.150e-05,\n 0.0046569, 0.0046337,\n// 2814 11 3\n2749158.810182, 7.0, -4.0, 4.0, 3137.5, 3137.5,\n 0.0712440, 0.5209754, -1.400e-06, -6.830e-06,\n 1.4201900, -0.1152441, 3.450e-05, 1.470e-06,\n -15.0378704, -0.0125520, 3.000e-06,\n 289.2225647, 15.0016088, 0.000e-00,\n 0.5571700, 0.0001308, -1.090e-05,\n 0.0109770, 0.0001302, -1.090e-05,\n 0.0046958, 0.0046724,\n// 2815 4 1\n2749307.553551, 1.0, -4.0, 4.0, 3140.1, 3140.1,\n -0.3127810, 0.4978281, 3.450e-05, -6.090e-06,\n 0.5076240, 0.1541667, -4.060e-05, -1.830e-06,\n 4.3903499, 0.0157810, -1.000e-06,\n 194.0954895, 15.0039902, 0.000e-00,\n 0.5634840, -0.0000983, -1.040e-05,\n 0.0172600, -0.0000978, -1.040e-05,\n 0.0046985, 0.0046751,\n// 2815 9 24\n2749483.889201, 9.0, -4.0, 4.0, 3143.2, 3143.2,\n -0.3658930, 0.5517970, 1.270e-05, -9.200e-06,\n -0.4966060, -0.1762909, 3.550e-05, 2.850e-06,\n -0.5728400, -0.0156140, 0.000e-00,\n 316.8226624, 15.0051947, 0.000e-00,\n 0.5344370, 0.0000676, -1.270e-05,\n -0.0116430, 0.0000672, -1.260e-05,\n 0.0046432, 0.0046201,\n// 2816 3 20\n2749661.595527, 2.0, -4.0, 4.0, 3146.3, 3146.3,\n -0.1011690, 0.4803770, 5.300e-06, -5.340e-06,\n -0.1691070, 0.1518564, 7.300e-06, -1.630e-06,\n -0.0125300, 0.0161460, 0.000e-00,\n 208.3414154, 15.0039454, 0.000e-00,\n 0.5727910, -0.0000098, -9.800e-06,\n 0.0265210, -0.0000098, -9.800e-06,\n 0.0047129, 0.0046895,\n// 2816 9 13\n2749838.592524, 2.0, -4.0, 4.0, 3149.3, 3149.3,\n -0.0806430, 0.5544587, 3.000e-06, -9.320e-06,\n 0.1710380, -0.1740994, -3.280e-05, 2.840e-06,\n 3.4605701, -0.0153870, -1.000e-06,\n 210.8308105, 15.0052538, 0.000e-00,\n 0.5331100, -0.0000373, -1.280e-05,\n -0.0129620, -0.0000371, -1.270e-05,\n 0.0046315, 0.0046084,\n// 2817 3 9\n2750015.595069, 2.0, -4.0, 4.0, 3152.4, 3152.4,\n 0.1046630, 0.4918743, -2.450e-05, -5.820e-06,\n -0.8284550, 0.1522443, 5.420e-05, -1.750e-06,\n -4.4555602, 0.0159590, 1.000e-06,\n 207.6426849, 15.0035410, 0.000e-00,\n 0.5679290, 0.0000886, -1.030e-05,\n 0.0216830, 0.0000882, -1.020e-05,\n 0.0047253, 0.0047018,\n// 2817 9 2\n2750193.213627, 17.0, -4.0, 4.0, 3155.5, 3155.5,\n 0.1913480, 0.5333551, -8.000e-06, -7.890e-06,\n 0.8870950, -0.1593979, -9.440e-05, 2.260e-06,\n 7.4126501, -0.0147690, -1.000e-06,\n 74.8662186, 15.0048847, 0.000e-00,\n 0.5430760, -0.0001090, -1.170e-05,\n -0.0030460, -0.0001084, -1.160e-05,\n 0.0046216, 0.0045986,\n// 2818 1 27\n2750340.309703, 19.0, -4.0, 4.0, 3158.1, 3158.1,\n -0.4535660, 0.5560785, -1.340e-05, -8.580e-06,\n 1.2588860, 0.0911167, 5.620e-05, -1.300e-06,\n -18.2884808, 0.0105720, 5.000e-06,\n 102.2816391, 14.9993048, 0.000e-00,\n 0.5464740, 0.0001139, -1.230e-05,\n 0.0003340, 0.0001133, -1.220e-05,\n 0.0047520, 0.0047283,\n// 2818 2 26\n2750369.838707, 8.0, -4.0, 4.0, 3158.6, 3158.6,\n 0.3414210, 0.5249271, -4.910e-05, -7.380e-06,\n -1.4281920, 0.1524334, 1.155e-04, -2.100e-06,\n -8.6800604, 0.0152240, 2.000e-06,\n 297.1327820, 15.0027962, 0.000e-00,\n 0.5534190, 0.0001217, -1.150e-05,\n 0.0072450, 0.0001211, -1.150e-05,\n 0.0047352, 0.0047116,\n// 2818 7 24\n2750518.016903, 12.0, -4.0, 4.0, 3161.2, 3161.2,\n -0.3407560, 0.5073632, 6.800e-06, -5.870e-06,\n -1.0258189, -0.0650000, -7.860e-05, 6.900e-07,\n 19.5701008, -0.0087650, -4.000e-06,\n 357.9306946, 15.0012274, 0.000e-00,\n 0.5626940, -0.0000569, -9.900e-06,\n 0.0164740, -0.0000567, -9.800e-06,\n 0.0046014, 0.0045785,\n// 2819 1 17\n2750694.922646, 10.0, -4.0, 4.0, 3164.2, 3164.2,\n -0.1411070, 0.5799067, -9.300e-06, -9.860e-06,\n 0.6074370, 0.0545210, 1.182e-04, -8.200e-07,\n -20.7045898, 0.0079650, 5.000e-06,\n 328.0000610, 14.9980574, 0.000e-00,\n 0.5384720, 0.0000206, -1.310e-05,\n -0.0076280, 0.0000205, -1.310e-05,\n 0.0047529, 0.0047292,\n// 2819 7 13\n2750872.043934, 13.0, -4.0, 4.0, 3167.3, 3167.3,\n -0.0450910, 0.5063882, -1.100e-05, -5.730e-06,\n -0.3054250, -0.0289035, -1.204e-04, 2.500e-07,\n 21.6128407, -0.0061580, -5.000e-06,\n 13.1007404, 15.0001221, 0.000e-00,\n 0.5649020, 0.0000359, -9.700e-06,\n 0.0186710, 0.0000357, -9.700e-06,\n 0.0046016, 0.0045787,\n// 2820 1 7\n2751049.566792, 2.0, -4.0, 4.0, 3170.4, 3170.4,\n 0.2280960, 0.5721780, -2.000e-06, -9.230e-06,\n -0.0450590, 0.0111330, 1.715e-04, -7.000e-08,\n -22.3749104, 0.0049880, 6.000e-06,\n 209.0171967, 14.9970379, 0.000e-00,\n 0.5428440, -0.0000920, -1.270e-05,\n -0.0032780, -0.0000915, -1.260e-05,\n 0.0047518, 0.0047281,\n// 2820 7 1\n2751226.178506, 16.0, -4.0, 4.0, 3173.5, 3173.5,\n -0.1586450, 0.5293781, -7.200e-06, -6.760e-06,\n 0.4624440, 0.0094551, -1.688e-04, -2.000e-07,\n 22.8817101, -0.0032740, -5.000e-06,\n 58.5313301, 14.9993734, 0.000e-00,\n 0.5544440, 0.0001153, -1.060e-05,\n 0.0082650, 0.0001148, -1.050e-05,\n 0.0046037, 0.0045808,\n// 2820 12 26\n2751404.047851, 13.0, -4.0, 4.0, 3176.6, 3176.6,\n -0.1263840, 0.5398168, 3.350e-05, -7.350e-06,\n -0.7646950, -0.0325153, 2.026e-04, 5.800e-07,\n -23.2348499, 0.0016870, 6.000e-06,\n 15.2554903, 14.9964619, 0.000e-00,\n 0.5569130, -0.0001170, -1.130e-05,\n 0.0107220, -0.0001164, -1.130e-05,\n 0.0047482, 0.0047246,\n// 2821 5 22\n2751551.264596, 18.0, -4.0, 4.0, 3179.2, 3179.2,\n 0.2028100, 0.5511174, 1.840e-05, -8.940e-06,\n -1.3777651, 0.1653488, -6.360e-05, -2.870e-06,\n 20.5487309, 0.0075080, -5.000e-06,\n 90.5258179, 15.0002632, 0.000e-00,\n 0.5352930, 0.0000803, -1.250e-05,\n -0.0107900, 0.0000799, -1.250e-05,\n 0.0046321, 0.0046090,\n// 2821 6 21\n2751580.608220, 3.0, -4.0, 4.0, 3179.7, 3179.7,\n 0.1158460, 0.5604405, -4.900e-06, -8.540e-06,\n 1.2079819, 0.0516825, -2.252e-04, -8.700e-07,\n 23.3286896, -0.0003150, -5.000e-06,\n 224.1103058, 14.9990778, 0.000e-00,\n 0.5398150, 0.0000954, -1.190e-05,\n -0.0062910, 0.0000949, -1.180e-05,\n 0.0046081, 0.0045851,\n// 2821 11 15\n2751728.476883, 23.0, -4.0, 4.0, 3182.3, 3182.3,\n 0.2954890, 0.4738966, 2.920e-05, -5.220e-06,\n 1.4787130, -0.1711869, 5.110e-05, 2.030e-06,\n -18.6558399, -0.0098650, 5.000e-06,\n 169.0257111, 14.9996405, 0.000e-00,\n 0.5724780, -0.0000094, -9.800e-06,\n 0.0262090, -0.0000093, -9.800e-06,\n 0.0047124, 0.0046890,\n// 2821 12 15\n2751758.232571, 18.0, -4.0, 4.0, 3182.8, 3182.8,\n -0.0037160, 0.5061637, 3.420e-05, -5.860e-06,\n -1.5326550, -0.0723974, 2.169e-04, 9.700e-07,\n -23.1880493, -0.0017680, 6.000e-06,\n 91.5632477, 14.9965372, 0.000e-00,\n 0.5707370, -0.0000784, -1.010e-05,\n 0.0244770, -0.0000780, -1.010e-05,\n 0.0047418, 0.0047182,\n// 2822 5 12\n2751905.961505, 11.0, -4.0, 4.0, 3185.4, 3185.4,\n 0.1870580, 0.5462245, 3.720e-05, -9.200e-06,\n -0.6292190, 0.2035054, -8.180e-05, -3.610e-06,\n 18.2312508, 0.0098750, -4.000e-06,\n 345.6953125, 15.0012093, 0.000e-00,\n 0.5329090, -0.0000257, -1.290e-05,\n -0.0131620, -0.0000256, -1.280e-05,\n 0.0046438, 0.0046207,\n// 2822 11 4\n2752082.471671, 23.0, -4.0, 4.0, 3188.5, 3188.5,\n 0.1581420, 0.4712169, 1.860e-05, -5.450e-06,\n 0.7829360, -0.2028166, 5.960e-05, 2.520e-06,\n -15.5635004, -0.0120450, 4.000e-06,\n 169.2295074, 15.0012465, 0.000e-00,\n 0.5672910, 0.0000885, -1.010e-05,\n 0.0210480, 0.0000881, -1.010e-05,\n 0.0046983, 0.0046749,\n// 2823 5 2\n2752260.607003, 3.0, -4.0, 4.0, 3191.6, 3191.6,\n 0.1964090, 0.5157905, 4.690e-05, -7.790e-06,\n 0.1574640, 0.2239908, -9.550e-05, -3.570e-06,\n 15.3263998, 0.0119240, -3.000e-06,\n 225.6030273, 15.0021315, 0.000e-00,\n 0.5423810, -0.0001199, -1.200e-05,\n -0.0037380, -0.0001193, -1.190e-05,\n 0.0046573, 0.0046341,\n// 2823 10 25\n2752436.702063, 5.0, -4.0, 4.0, 3194.7, 3194.7,\n 0.0846580, 0.4894519, 1.220e-05, -6.680e-06,\n -0.0129760, -0.2370585, 7.500e-05, 3.420e-06,\n -12.0241203, -0.0136150, 2.000e-06,\n 259.0168762, 15.0027380, 0.000e-00,\n 0.5520210, 0.0001208, -1.130e-05,\n 0.0058540, 0.0001202, -1.120e-05,\n 0.0046832, 0.0046599,\n// 2824 4 20\n2752615.016216, 12.0, -4.0, 4.0, 3197.8, 3197.8,\n -0.5520040, 0.4756618, 7.080e-05, -5.970e-06,\n 0.6669650, 0.2307016, -8.900e-05, -3.080e-06,\n 11.8402100, 0.0136330, -3.000e-06,\n 0.2554900, 15.0029469, 0.000e-00,\n 0.5585190, -0.0001069, -1.070e-05,\n 0.0123200, -0.0001063, -1.060e-05,\n 0.0046720, 0.0046487,\n// 2824 10 13\n2752791.232146, 18.0, -4.0, 4.0, 3200.9, 3200.9,\n -0.1026800, 0.5095333, 2.110e-05, -8.190e-06,\n -0.7293430, -0.2656606, 9.130e-05, 4.460e-06,\n -8.2278004, -0.0146400, 1.000e-06,\n 93.4697876, 15.0039253, 0.000e-00,\n 0.5377310, 0.0000682, -1.260e-05,\n -0.0083640, 0.0000678, -1.250e-05,\n 0.0046686, 0.0046454,\n// 2825 3 10\n2752939.372737, 21.0, -4.0, 4.0, 3203.5, 3203.5,\n 0.6926540, 0.4422692, -3.950e-05, -4.840e-06,\n -1.2109960, 0.2415848, 6.570e-05, -2.820e-06,\n -3.7259300, 0.0158130, 1.000e-06,\n 132.7497253, 15.0035229, 0.000e-00,\n 0.5732620, 0.0000139, -9.800e-06,\n 0.0269890, 0.0000138, -9.800e-06,\n 0.0047236, 0.0047000,\n// 2825 9 4\n2753116.592838, 2.0, -4.0, 4.0, 3206.6, 3206.6,\n 0.4308860, 0.5096079, -3.600e-05, -8.260e-06,\n 1.0956930, -0.2695490, -1.029e-04, 4.550e-06,\n 6.8862200, -0.0146210, -1.000e-06,\n 209.9893036, 15.0048962, 0.000e-00,\n 0.5345840, -0.0000627, -1.250e-05,\n -0.0114960, -0.0000624, -1.250e-05,\n 0.0046224, 0.0045994,\n// 2825 10 3\n2753145.918536, 10.0, -4.0, 4.0, 3207.1, 3207.1,\n -0.6784120, 0.5131701, 5.480e-05, -8.620e-06,\n -1.2007730, -0.2772318, 9.220e-05, 4.870e-06,\n -4.2624998, -0.0152150, 1.000e-06,\n 332.6790161, 15.0047178, 0.000e-00,\n 0.5333250, -0.0000193, -1.290e-05,\n -0.0127490, -0.0000192, -1.280e-05,\n 0.0046548, 0.0046316,\n// 2826 2 27\n2753293.417357, 22.0, -4.0, 4.0, 3209.7, 3209.7,\n 0.3045720, 0.4629799, -5.020e-05, -5.620e-06,\n -0.6001300, 0.2425037, 6.360e-05, -3.140e-06,\n -8.0614700, 0.0151530, 2.000e-06,\n 147.1920624, 15.0027914, 0.000e-00,\n 0.5646830, 0.0001024, -1.060e-05,\n 0.0184530, 0.0001019, -1.050e-05,\n 0.0047344, 0.0047108,\n// 2826 8 24\n2753471.161287, 16.0, -4.0, 4.0, 3212.9, 3212.9,\n 0.2668960, 0.4894543, -2.550e-05, -6.800e-06,\n 0.3760700, -0.2446082, -8.260e-05, 3.560e-06,\n 10.6685896, -0.0136670, -2.000e-06,\n 59.1165886, 15.0042315, 0.000e-00,\n 0.5468880, -0.0001205, -1.130e-05,\n 0.0007470, -0.0001199, -1.120e-05,\n 0.0046142, 0.0045912,\n// 2827 2 17\n2753647.746337, 6.0, -4.0, 4.0, 3216.0, 3216.0,\n 0.0181280, 0.5006649, -5.120e-05, -7.320e-06,\n 0.0747660, 0.2424066, 6.220e-05, -3.740e-06,\n -12.0409698, 0.0139510, 3.000e-06,\n 266.9042053, 15.0017662, 0.000e-00,\n 0.5494690, 0.0001107, -1.200e-05,\n 0.0033150, 0.0001102, -1.190e-05,\n 0.0047426, 0.0047190,\n// 2827 8 13\n2753825.445250, 23.0, -4.0, 4.0, 3219.1, 3219.1,\n 0.0146830, 0.4701653, -2.300e-05, -5.520e-06,\n -0.3600830, -0.2133099, -6.540e-05, 2.670e-06,\n 14.2300901, -0.0122680, -3.000e-06,\n 163.4326477, 15.0032568, 0.000e-00,\n 0.5608240, -0.0000878, -1.010e-05,\n 0.0146130, -0.0000874, -1.000e-05,\n 0.0046078, 0.0045849,\n// 2828 2 6\n2754002.326897, 20.0, -4.0, 4.0, 3222.2, 3222.2,\n -0.2067510, 0.5333576, -3.670e-05, -8.880e-06,\n 0.7086440, 0.2290811, 5.900e-05, -4.010e-06,\n -15.5531197, 0.0122570, 4.000e-06,\n 116.9410934, 15.0005178, 0.000e-00,\n 0.5391140, 0.0000361, -1.300e-05,\n -0.0069890, 0.0000359, -1.300e-05,\n 0.0047485, 0.0047248,\n// 2828 8 1\n2754179.490005, 0.0, -4.0, 4.0, 3225.3, 3225.3,\n -0.2859870, 0.4705617, -2.760e-05, -5.210e-06,\n -1.0605150, -0.1847306, -5.370e-05, 2.190e-06,\n 17.4128094, -0.0103820, -4.000e-06,\n 178.0211639, 15.0021133, 0.000e-00,\n 0.5657160, 0.0000094, -9.700e-06,\n 0.0194810, 0.0000094, -9.600e-06,\n 0.0046032, 0.0045803,\n// 2828 12 28\n2754327.507176, 0.0, -4.0, 4.0, 3227.9, 3227.9,\n 0.0967010, 0.5588212, -1.580e-05, -8.640e-06,\n -1.3228360, 0.0823062, 2.416e-04, -1.380e-06,\n -23.1653805, 0.0018970, 6.000e-06,\n 180.0790100, 14.9965477, 0.000e-00,\n 0.5460650, -0.0000966, -1.230e-05,\n -0.0000720, -0.0000961, -1.220e-05,\n 0.0047484, 0.0047247,\n// 2829 1 26\n2754356.982078, 12.0, -4.0, 4.0, 3228.4, 3228.4,\n -0.2396830, 0.5427735, -2.110e-05, -8.900e-06,\n 1.3953630, 0.1959246, 5.030e-05, -3.420e-06,\n -18.5346298, 0.0100940, 5.000e-06,\n 357.3382263, 14.9991426, 0.000e-00,\n 0.5405780, -0.0000740, -1.290e-05,\n -0.0055320, -0.0000736, -1.280e-05,\n 0.0047521, 0.0047284,\n// 2829 6 22\n2754504.084323, 14.0, -4.0, 4.0, 3231.0, 3231.0,\n 0.0925060, 0.5353754, -3.900e-05, -7.180e-06,\n 0.9289600, -0.0607246, -1.982e-04, 9.500e-07,\n 23.3129807, -0.0004900, -5.000e-06,\n 29.0124493, 14.9990368, 0.000e-00,\n 0.5504160, 0.0001173, -1.090e-05,\n 0.0042580, 0.0001167, -1.090e-05,\n 0.0046078, 0.0045848,\n// 2829 12 17\n2754681.914111, 10.0, -4.0, 4.0, 3234.2, 3234.2,\n 0.0778290, 0.5297380, 3.100e-06, -6.840e-06,\n -0.6755950, 0.0354558, 1.924e-04, -5.500e-07,\n -23.2577000, -0.0014770, 6.000e-06,\n 331.3644104, 14.9965334, 0.000e-00,\n 0.5612170, -0.0001156, -1.090e-05,\n 0.0150040, -0.0001150, -1.080e-05,\n 0.0047425, 0.0047189,\n// 2830 6 12\n2754858.590215, 2.0, -4.0, 4.0, 3237.3, 3237.3,\n -0.0890760, 0.5701802, -1.480e-05, -9.070e-06,\n 0.1398970, -0.0212571, -1.720e-04, 4.600e-07,\n 23.0792809, 0.0025020, -6.000e-06,\n 209.6282043, 14.9991465, 0.000e-00,\n 0.5366840, 0.0000926, -1.230e-05,\n -0.0094070, 0.0000921, -1.220e-05,\n 0.0046143, 0.0045913,\n// 2830 12 6\n2755036.018953, 12.0, -4.0, 4.0, 3240.4, 3240.4,\n -0.2300080, 0.5060532, 1.640e-05, -5.710e-06,\n 0.0158060, -0.0076560, 1.465e-04, 0.000e-00,\n -22.4149704, -0.0048500, 6.000e-06,\n 2.5872700, 14.9971991, 0.000e-00,\n 0.5727990, -0.0000338, -9.900e-06,\n 0.0265280, -0.0000336, -9.900e-06,\n 0.0047339, 0.0047103,\n// 2831 6 1\n2755213.279558, 19.0, -4.0, 4.0, 3243.5, 3243.5,\n 0.1915420, 0.5835941, -3.500e-06, -9.960e-06,\n -0.5897660, 0.0214145, -1.244e-04, -2.600e-07,\n 22.0859509, 0.0053410, -5.000e-06,\n 105.1641388, 14.9996309, 0.000e-00,\n 0.5314120, -0.0000118, -1.290e-05,\n -0.0146530, -0.0000117, -1.280e-05,\n 0.0046229, 0.0045998,\n// 2831 11 25\n2755389.988957, 12.0, -4.0, 4.0, 3246.7, 3246.7,\n 0.1995410, 0.5058101, -4.000e-06, -5.770e-06,\n 0.6884650, -0.0471984, 1.067e-04, 4.700e-07,\n -20.6635303, -0.0079310, 5.000e-06,\n 3.5438900, 14.9984703, 0.000e-00,\n 0.5711090, 0.0000563, -1.000e-05,\n 0.0248460, 0.0000561, -9.900e-06,\n 0.0047225, 0.0046989,\n// 2832 4 22\n2755538.552446, 1.0, -4.0, 4.0, 3249.3, 3249.3,\n -0.4619270, 0.5357216, 5.860e-05, -7.770e-06,\n 1.2268651, 0.1372902, -1.317e-04, -1.950e-06,\n 12.3792200, 0.0136300, -3.000e-06,\n 195.3237152, 15.0029697, 0.000e-00,\n 0.5471890, -0.0001143, -1.160e-05,\n 0.0010460, -0.0001137, -1.160e-05,\n 0.0046696, 0.0046463,\n// 2832 5 21\n2755567.960406, 11.0, -4.0, 4.0, 3249.8, 3249.8,\n 0.1173910, 0.5654864, 2.240e-05, -8.930e-06,\n -1.3362610, 0.0617292, -6.510e-05, -8.600e-07,\n 20.3642006, 0.0079890, -5.000e-06,\n 345.5446777, 15.0003729, 0.000e-00,\n 0.5381860, -0.0000947, -1.220e-05,\n -0.0079120, -0.0000942, -1.220e-05,\n 0.0046336, 0.0046105,\n// 2832 10 15\n2755714.623166, 3.0, -4.0, 4.0, 3252.4, 3252.4,\n -0.3684460, 0.5317275, 1.770e-05, -7.770e-06,\n -1.3469270, -0.1554698, 1.266e-04, 2.170e-06,\n -8.7523603, -0.0147820, 1.000e-06,\n 228.5558319, 15.0038471, 0.000e-00,\n 0.5467640, 0.0001188, -1.170e-05,\n 0.0006230, 0.0001182, -1.160e-05,\n 0.0046706, 0.0046474,\n// 2832 11 13\n2755744.141020, 15.0, -4.0, 4.0, 3252.9, 3252.9,\n 0.0187100, 0.5280664, -6.000e-07, -6.990e-06,\n 1.3836330, -0.0867627, 5.920e-05, 1.100e-06,\n -18.1497898, -0.0105080, 4.000e-06,\n 49.0960388, 15.0000696, 0.000e-00,\n 0.5571240, 0.0001307, -1.100e-05,\n 0.0109310, 0.0001301, -1.100e-05,\n 0.0047091, 0.0046856,\n// 2833 4 11\n2755892.870975, 9.0, -4.0, 4.0, 3255.6, 3255.6,\n -0.1226550, 0.4995896, 3.350e-05, -6.070e-06,\n 0.6074550, 0.1438359, -6.860e-05, -1.690e-06,\n 8.5399599, 0.0149480, -2.000e-06,\n 314.7902832, 15.0035992, 0.000e-00,\n 0.5633190, -0.0001029, -1.040e-05,\n 0.0170950, -0.0001024, -1.030e-05,\n 0.0046845, 0.0046611,\n// 2833 10 4\n2756069.218699, 17.0, -4.0, 4.0, 3258.7, 3258.7,\n -0.3260800, 0.5539657, 1.950e-05, -9.270e-06,\n -0.5633170, -0.1721044, 6.470e-05, 2.790e-06,\n -4.7802100, -0.0154120, 1.000e-06,\n 77.7880173, 15.0047359, 0.000e-00,\n 0.5347760, 0.0000602, -1.280e-05,\n -0.0113050, 0.0000599, -1.270e-05,\n 0.0046565, 0.0046333,\n// 2834 3 31\n2756246.908523, 10.0, -4.0, 4.0, 3261.8, 3261.8,\n 0.1224150, 0.4814620, 4.300e-06, -5.360e-06,\n -0.0625890, 0.1487129, -2.010e-05, -1.590e-06,\n 4.2993002, 0.0158070, -1.000e-06,\n 329.0911865, 15.0039501, 0.000e-00,\n 0.5719930, -0.0000139, -9.800e-06,\n 0.0257270, -0.0000139, -9.800e-06,\n 0.0046995, 0.0046761,\n// 2834 9 24\n2756423.917617, 10.0, -4.0, 4.0, 3265.0, 3265.0,\n 0.0123560, 0.5528799, 7.200e-06, -9.250e-06,\n 0.0824620, -0.1760019, -3.000e-06, 2.860e-06,\n -0.7462000, -0.0156130, 0.000e-00,\n 331.8584900, 15.0051870, 0.000e-00,\n 0.5340940, -0.0000478, -1.270e-05,\n -0.0119830, -0.0000475, -1.270e-05,\n 0.0046436, 0.0046205,\n// 2835 3 20\n2756600.920905, 10.0, -4.0, 4.0, 3268.1, 3268.1,\n 0.1905590, 0.4921817, -2.040e-05, -5.870e-06,\n -0.7741340, 0.1561813, 2.780e-05, -1.810e-06,\n -0.1212800, 0.0161370, 0.000e-00,\n 328.3337097, 15.0039654, 0.000e-00,\n 0.5665440, 0.0000883, -1.030e-05,\n 0.0203050, 0.0000879, -1.020e-05,\n 0.0047131, 0.0046897,\n// 2835 9 14\n2756778.523125, 1.0, -4.0, 4.0, 3271.3, 3271.3,\n 0.4896860, 0.5287397, -1.390e-05, -7.750e-06,\n 0.7304510, -0.1671857, -6.300e-05, 2.360e-06,\n 3.3206201, -0.0154150, -1.000e-06,\n 195.8597260, 15.0052004, 0.000e-00,\n 0.5444790, -0.0001238, -1.160e-05,\n -0.0016500, -0.0001232, -1.160e-05,\n 0.0046322, 0.0046091,\n// 2836 2 8\n2756925.672470, 4.0, -4.0, 4.0, 3273.9, 3273.9,\n -0.3629480, 0.5516024, -1.780e-05, -8.570e-06,\n 1.2689940, 0.1227090, 2.880e-05, -1.800e-06,\n -15.1197596, 0.0127700, 4.000e-06,\n 236.9188843, 15.0007477, 0.000e-00,\n 0.5456270, 0.0001032, -1.240e-05,\n -0.0005090, 0.0001027, -1.230e-05,\n 0.0047480, 0.0047243,\n// 2836 3 8\n2756955.186339, 16.0, -4.0, 4.0, 3274.4, 3274.4,\n 0.1853420, 0.5234723, -3.530e-05, -7.430e-06,\n -1.4592240, 0.1637326, 9.060e-05, -2.280e-06,\n -4.4622998, 0.0159290, 1.000e-06,\n 57.6465797, 15.0036135, 0.000e-00,\n 0.5519570, 0.0001285, -1.160e-05,\n 0.0057910, 0.0001278, -1.150e-05,\n 0.0047249, 0.0047013,\n// 2836 8 3\n2757103.289280, 19.0, -4.0, 4.0, 3277.0, 3277.0,\n -0.1833940, 0.5016241, -2.600e-06, -5.770e-06,\n -1.1329350, -0.0943772, -5.550e-05, 1.030e-06,\n 16.9222107, -0.0109470, -4.000e-06,\n 103.0695801, 15.0023890, 0.000e-00,\n 0.5633280, -0.0000600, -9.900e-06,\n 0.0171050, -0.0000597, -9.800e-06,\n 0.0046037, 0.0045808,\n// 2837 1 27\n2757280.292553, 19.0, -4.0, 4.0, 3280.1, 3280.1,\n -0.1121800, 0.5751383, -1.640e-05, -9.790e-06,\n 0.6122760, 0.0935718, 9.460e-05, -1.500e-06,\n -18.1825008, 0.0106570, 5.000e-06,\n 102.2681122, 14.9994020, 0.000e-00,\n 0.5383280, 0.0000116, -1.310e-05,\n -0.0077710, 0.0000115, -1.310e-05,\n 0.0047517, 0.0047281,\n// 2837 7 23\n2757457.313332, 20.0, -4.0, 4.0, 3283.3, 3283.3,\n 0.1928500, 0.5039144, -2.690e-05, -5.720e-06,\n -0.4221180, -0.0631823, -1.000e-04, 6.500e-07,\n 19.6226006, -0.0087090, -4.000e-06,\n 117.9272385, 15.0011921, 0.000e-00,\n 0.5645760, 0.0000323, -9.800e-06,\n 0.0183470, 0.0000321, -9.700e-06,\n 0.0046014, 0.0045784,\n// 2838 1 17\n2757634.933059, 10.0, -4.0, 4.0, 3286.5, 3286.5,\n -0.2193320, 0.5684236, 8.900e-06, -9.100e-06,\n -0.0661810, 0.0543358, 1.562e-04, -7.600e-07,\n -20.6238499, 0.0080740, 5.000e-06,\n 327.9725647, 14.9980679, 0.000e-00,\n 0.5435250, -0.0000764, -1.260e-05,\n -0.0026000, -0.0000760, -1.250e-05,\n 0.0047533, 0.0047296,\n// 2838 7 12\n2757811.464069, 23.0, -4.0, 4.0, 3289.6, 3289.6,\n -0.0513860, 0.5305600, -2.220e-05, -6.850e-06,\n 0.3862970, -0.0300070, -1.542e-04, 3.100e-07,\n 21.6354809, -0.0061100, -5.000e-06,\n 163.0986328, 15.0001698, 0.000e-00,\n 0.5534030, 0.0001151, -1.060e-05,\n 0.0072290, 0.0001146, -1.060e-05,\n 0.0046011, 0.0045782,\n// 2839 1 6\n2757989.400054, 22.0, -4.0, 4.0, 3292.8, 3292.8,\n 0.2315500, 0.5388525, 5.100e-06, -7.290e-06,\n -0.7611450, 0.0119110, 1.957e-04, -5.000e-08,\n -22.3444195, 0.0050530, 6.000e-06,\n 149.0049438, 14.9969683, 0.000e-00,\n 0.5579120, -0.0001296, -1.120e-05,\n 0.0117160, -0.0001290, -1.120e-05,\n 0.0047525, 0.0047288,\n// 2839 6 3\n2758136.584219, 2.0, -4.0, 4.0, 3295.4, 3295.4,\n 0.3001490, 0.5628488, 7.900e-06, -9.210e-06,\n -1.4033051, 0.1254286, -7.760e-05, -2.220e-06,\n 22.2571602, 0.0047240, -6.000e-06,\n 210.0952454, 14.9995003, 0.000e-00,\n 0.5342360, 0.0000674, -1.250e-05,\n -0.0118420, 0.0000671, -1.250e-05,\n 0.0046217, 0.0045987,\n// 2839 7 2\n2758165.914242, 10.0, -4.0, 4.0, 3295.9, 3295.9,\n 0.0169230, 0.5646437, -1.330e-05, -8.700e-06,\n 1.1180850, 0.0080269, -2.166e-04, -2.000e-07,\n 22.8651695, -0.0033160, -5.000e-06,\n 328.5083008, 14.9994726, 0.000e-00,\n 0.5387140, 0.0001010, -1.200e-05,\n -0.0073870, 0.0001005, -1.190e-05,\n 0.0046031, 0.0045802,\n// 2839 11 27\n2758313.795308, 7.0, -4.0, 4.0, 3298.5, 3298.5,\n 0.3757170, 0.4839080, 2.400e-05, -5.330e-06,\n 1.4732950, -0.1384455, 7.170e-05, 1.660e-06,\n -21.0109291, -0.0072180, 5.000e-06,\n 288.4189148, 14.9981813, 0.000e-00,\n 0.5733740, -0.0000113, -9.800e-06,\n 0.0271000, -0.0000112, -9.800e-06,\n 0.0047244, 0.0047009,\n// 2839 12 27\n2758343.566638, 2.0, -4.0, 4.0, 3299.1, 3299.1,\n 0.1151070, 0.5093028, 1.580e-05, -5.880e-06,\n -1.5159670, -0.0299522, 2.187e-04, 4.600e-07,\n -23.2337093, 0.0016580, 6.000e-06,\n 210.2769470, 14.9963837, 0.000e-00,\n 0.5716760, -0.0000743, -1.010e-05,\n 0.0254110, -0.0000739, -1.010e-05,\n 0.0047487, 0.0047250,\n// 2840 5 22\n2758491.288450, 19.0, -4.0, 4.0, 3301.7, 3301.7,\n 0.2482030, 0.5577760, 3.300e-05, -9.390e-06,\n -0.6686720, 0.1678516, -1.008e-04, -2.990e-06,\n 20.6312408, 0.0073890, -5.000e-06,\n 105.4980774, 15.0002327, 0.000e-00,\n 0.5324740, -0.0000353, -1.280e-05,\n -0.0135960, -0.0000351, -1.280e-05,\n 0.0046320, 0.0046089,\n// 2840 11 15\n2758667.790967, 7.0, -4.0, 4.0, 3304.9, 3304.9,\n 0.2868400, 0.4828648, 1.620e-05, -5.630e-06,\n 0.7612980, -0.1761029, 8.280e-05, 2.210e-06,\n -18.5845909, -0.0099120, 4.000e-06,\n 289.0425110, 14.9997110, 0.000e-00,\n 0.5675350, 0.0000858, -1.020e-05,\n 0.0212900, 0.0000854, -1.010e-05,\n 0.0047114, 0.0046879,\n// 2841 5 12\n2758845.929569, 10.0, -4.0, 4.0, 3308.0, 3308.0,\n -0.1672410, 0.5255622, 6.630e-05, -7.870e-06,\n -0.0483320, 0.1952210, -1.089e-04, -3.100e-06,\n 18.3193703, 0.0098170, -4.000e-06,\n 330.6826477, 15.0011120, 0.000e-00,\n 0.5425170, -0.0001045, -1.190e-05,\n -0.0036020, -0.0001039, -1.180e-05,\n 0.0046443, 0.0046212,\n// 2841 11 4\n2759022.032655, 13.0, -4.0, 4.0, 3311.2, 3311.2,\n 0.1326790, 0.5010364, 1.680e-05, -6.920e-06,\n 0.0097600, -0.2158175, 9.800e-05, 3.160e-06,\n -15.5537205, -0.0120140, 3.000e-06,\n 19.2336998, 15.0013323, 0.000e-00,\n 0.5519730, 0.0001192, -1.140e-05,\n 0.0058060, 0.0001186, -1.130e-05,\n 0.0046971, 0.0046737,\n// 2842 5 1\n2759200.326807, 20.0, -4.0, 4.0, 3314.3, 3314.3,\n -0.2391320, 0.4837582, 6.470e-05, -6.040e-06,\n 0.7601470, 0.2093948, -1.154e-04, -2.790e-06,\n 15.3552399, 0.0119420, -3.000e-06,\n 120.6055679, 15.0020323, 0.000e-00,\n 0.5584750, -0.0001158, -1.060e-05,\n 0.0122760, -0.0001152, -1.050e-05,\n 0.0046584, 0.0046352,\n// 2842 10 25\n2759376.570421, 2.0, -4.0, 4.0, 3317.5, 3317.5,\n -0.1226250, 0.5186786, 3.270e-05, -8.400e-06,\n -0.6654290, -0.2498732, 1.131e-04, 4.230e-06,\n -12.1161804, -0.0135450, 2.000e-06,\n 214.0224762, 15.0027857, 0.000e-00,\n 0.5379630, 0.0000666, -1.260e-05,\n -0.0081340, 0.0000663, -1.260e-05,\n 0.0046824, 0.0046591,\n// 2843 3 22\n2759524.690411, 5.0, -4.0, 4.0, 3320.1, 3320.1,\n 0.8779890, 0.4415602, -3.450e-05, -4.840e-06,\n -1.1413569, 0.2438396, 4.120e-05, -2.850e-06,\n 0.6125900, 0.0159070, 0.000e-00,\n 253.4635468, 15.0038719, 0.000e-00,\n 0.5723230, 0.0000116, -9.800e-06,\n 0.0260550, 0.0000116, -9.800e-06,\n 0.0047114, 0.0046879,\n// 2843 4 20\n2759554.423188, 22.0, -4.0, 4.0, 3320.7, 3320.7,\n -0.7482460, 0.4552714, 6.390e-05, -5.030e-06,\n 1.3652160, 0.2202468, -1.142e-04, -2.600e-06,\n 11.7729597, 0.0136860, -3.000e-06,\n 150.2522430, 15.0029030, 0.000e-00,\n 0.5696450, -0.0000308, -9.800e-06,\n 0.0233900, -0.0000307, -9.800e-06,\n 0.0046732, 0.0046499,\n// 2843 9 15\n2759701.912501, 10.0, -4.0, 4.0, 3323.3, 3323.3,\n 0.6422300, 0.5044509, -3.370e-05, -8.120e-06,\n 1.0534720, -0.2761590, -7.790e-05, 4.620e-06,\n 2.7702501, -0.0152100, -1.000e-06,\n 330.9894409, 15.0051613, 0.000e-00,\n 0.5356630, -0.0000756, -1.250e-05,\n -0.0104230, -0.0000752, -1.240e-05,\n 0.0046330, 0.0046100,\n// 2843 10 14\n2759731.253815, 18.0, -4.0, 4.0, 3323.8, 3323.8,\n -0.6594250, 0.5179322, 6.650e-05, -8.680e-06,\n -1.1620370, -0.2671788, 1.144e-04, 4.690e-06,\n -8.3749504, -0.0145980, 1.000e-06,\n 93.4877396, 15.0039177, 0.000e-00,\n 0.5342290, -0.0000238, -1.290e-05,\n -0.0118490, -0.0000237, -1.290e-05,\n 0.0046684, 0.0046451,\n// 2844 3 10\n2759878.751962, 6.0, -4.0, 4.0, 3326.5, 3326.5,\n 0.3103330, 0.4599361, -3.910e-05, -5.630e-06,\n -0.6182670, 0.2517940, 4.090e-05, -3.280e-06,\n -3.8195701, 0.0157810, 1.000e-06,\n 267.7456970, 15.0035467, 0.000e-00,\n 0.5632750, 0.0001051, -1.060e-05,\n 0.0170510, 0.0001046, -1.060e-05,\n 0.0047238, 0.0047002,\n// 2844 9 3\n2760056.462240, 23.0, -4.0, 4.0, 3329.6, 3329.6,\n 0.2031710, 0.4809390, -1.320e-05, -6.590e-06,\n 0.4898420, -0.2563135, -6.570e-05, 3.680e-06,\n 6.7814798, -0.0146710, -1.000e-06,\n 165.0022125, 15.0048418, 0.000e-00,\n 0.5483540, -0.0001154, -1.120e-05,\n 0.0022060, -0.0001148, -1.120e-05,\n 0.0046230, 0.0046000,\n// 2845 2 27\n2760233.100726, 14.0, -4.0, 4.0, 3332.8, 3332.8,\n -0.2280050, 0.4942614, -2.930e-05, -7.290e-06,\n -0.0667830, 0.2591136, 4.280e-05, -4.030e-06,\n -8.0409098, 0.0151180, 2.000e-06,\n 27.2044201, 15.0028667, 0.000e-00,\n 0.5481670, 0.0001203, -1.200e-05,\n 0.0020190, 0.0001197, -1.200e-05,\n 0.0047339, 0.0047103,\n// 2845 8 24\n2760410.724365, 5.0, -4.0, 4.0, 3336.0, 3336.0,\n -0.2850670, 0.4603632, -6.400e-06, -5.340e-06,\n -0.1269870, -0.2303980, -5.330e-05, 2.840e-06,\n 10.6865501, -0.0136930, -2.000e-06,\n 254.1062622, 15.0041571, 0.000e-00,\n 0.5619830, -0.0000686, -1.000e-05,\n 0.0157660, -0.0000682, -1.000e-05,\n 0.0046147, 0.0045918,\n// 2846 2 17\n2760587.692804, 5.0, -4.0, 4.0, 3339.2, 3339.2,\n -0.1201660, 0.5230713, -3.230e-05, -8.720e-06,\n 0.7453970, 0.2532216, 2.990e-05, -4.430e-06,\n -11.9194298, 0.0139700, 3.000e-06,\n 251.9186707, 15.0018616, 0.000e-00,\n 0.5385220, 0.0000248, -1.300e-05,\n -0.0075780, 0.0000246, -1.300e-05,\n 0.0047419, 0.0047182,\n// 2846 8 13\n2760764.759766, 6.0, -4.0, 4.0, 3342.3, 3342.3,\n -0.5217440, 0.4610184, -1.700e-05, -5.100e-06,\n -0.8679510, -0.2080239, -4.000e-05, 2.450e-06,\n 14.3228703, -0.0122320, -3.000e-06,\n 268.4130859, 15.0032053, 0.000e-00,\n 0.5658760, 0.0000256, -9.700e-06,\n 0.0196400, 0.0000255, -9.600e-06,\n 0.0046079, 0.0045850,\n// 2847 1 8\n2760912.869724, 9.0, -4.0, 4.0, 3345.0, 3345.0,\n 0.3702600, 0.5487073, -4.030e-05, -8.410e-06,\n -1.2808460, 0.1273112, 2.282e-04, -2.070e-06,\n -22.1488209, 0.0052340, 6.000e-06,\n 313.8448486, 14.9971170, 0.000e-00,\n 0.5469100, -0.0001074, -1.230e-05,\n 0.0007680, -0.0001068, -1.220e-05,\n 0.0047521, 0.0047284,\n// 2847 2 6\n2760942.349191, 20.0, -4.0, 4.0, 3345.5, 3345.5,\n -0.7479600, 0.5298598, 7.800e-06, -8.620e-06,\n 1.1923980, 0.2263755, 3.540e-05, -3.900e-06,\n -15.4323997, 0.0123340, 4.000e-06,\n 116.9430313, 15.0005627, 0.000e-00,\n 0.5408310, -0.0000581, -1.280e-05,\n -0.0052810, -0.0000579, -1.280e-05,\n 0.0047483, 0.0047246,\n// 2847 7 3\n2761089.376708, 21.0, -4.0, 4.0, 3348.1, 3348.1,\n 0.1686020, 0.5311903, -5.390e-05, -7.190e-06,\n 0.9926470, -0.1022909, -1.938e-04, 1.540e-06,\n 22.7363300, -0.0034780, -5.000e-06,\n 133.4357452, 14.9994745, 0.000e-00,\n 0.5491920, 0.0001190, -1.100e-05,\n 0.0030390, 0.0001184, -1.090e-05,\n 0.0046031, 0.0045802,\n// 2847 12 28\n2761267.259511, 18.0, -4.0, 4.0, 3351.3, 3351.3,\n -0.0158000, 0.5231795, -7.300e-06, -6.680e-06,\n -0.7013680, 0.0792538, 1.922e-04, -1.120e-06,\n -23.1568794, 0.0019500, 6.000e-06,\n 90.0676804, 14.9964600, 0.000e-00,\n 0.5624360, -0.0001083, -1.080e-05,\n 0.0162170, -0.0001078, -1.080e-05,\n 0.0047490, 0.0047254,\n// 2848 6 22\n2761443.901125, 10.0, -4.0, 4.0, 3354.5, 3354.5,\n 0.2358620, 0.5683319, -4.300e-05, -9.090e-06,\n 0.1800340, -0.0663802, -1.743e-04, 1.200e-06,\n 23.3082199, -0.0005460, -6.000e-06,\n 328.9906311, 14.9991245, 0.000e-00,\n 0.5356840, 0.0000755, -1.230e-05,\n -0.0104010, 0.0000751, -1.220e-05,\n 0.0046072, 0.0045842,\n// 2848 12 16\n2761621.348152, 20.0, -4.0, 4.0, 3357.7, 3357.7,\n -0.1790270, 0.5042199, 1.400e-06, -5.660e-06,\n -0.0165110, 0.0336150, 1.554e-04, -4.800e-07,\n -23.2500896, -0.0015340, 6.000e-06,\n 121.3940811, 14.9964724, 0.000e-00,\n 0.5736800, -0.0000313, -9.900e-06,\n 0.0274050, -0.0000311, -9.900e-06,\n 0.0047429, 0.0047193,\n// 2849 6 12\n2761798.598561, 2.0, -4.0, 4.0, 3360.9, 3360.9,\n -0.2343650, 0.5835219, 6.900e-06, -9.940e-06,\n -0.5221050, -0.0231163, -1.373e-04, 5.100e-07,\n 23.1016808, 0.0023890, -6.000e-06,\n 209.5958252, 14.9991713, 0.000e-00,\n 0.5309720, -0.0000007, -1.280e-05,\n -0.0150900, -0.0000007, -1.280e-05,\n 0.0046138, 0.0045908,\n// 2849 12 5\n2761975.315506, 20.0, -4.0, 4.0, 3364.0, 3364.0,\n 0.2297100, 0.5086112, -1.520e-05, -5.820e-06,\n 0.6774220, -0.0089224, 1.219e-04, 2.000e-08,\n -22.3815002, -0.0049290, 6.000e-06,\n 122.6245880, 14.9972343, 0.000e-00,\n 0.5713750, 0.0000574, -1.000e-05,\n 0.0251110, 0.0000571, -1.000e-05,\n 0.0047335, 0.0047099,\n// 2850 5 3\n2762123.875714, 9.0, -4.0, 4.0, 3366.7, 3366.7,\n -0.2862760, 0.5396885, 5.220e-05, -7.760e-06,\n 1.3231440, 0.1128356, -1.602e-04, -1.580e-06,\n 15.8277903, 0.0118760, -3.000e-06,\n 315.6294861, 15.0020218, 0.000e-00,\n 0.5472270, -0.0001209, -1.150e-05,\n 0.0010840, -0.0001203, -1.150e-05,\n 0.0046558, 0.0046327,\n// 2850 6 1\n2762153.277365, 19.0, -4.0, 4.0, 3367.3, 3367.3,\n 0.2425110, 0.5669219, 8.400e-06, -8.880e-06,\n -1.2764831, 0.0211046, -8.460e-05, -2.100e-07,\n 22.1370201, 0.0052310, -5.000e-06,\n 105.1387329, 14.9995613, 0.000e-00,\n 0.5382650, -0.0001076, -1.210e-05,\n -0.0078330, -0.0001070, -1.210e-05,\n 0.0046230, 0.0045999,\n// 2850 10 26\n2762299.953343, 11.0, -4.0, 4.0, 3369.9, 3369.9,\n -0.2911950, 0.5383065, 1.900e-05, -7.940e-06,\n -1.4021850, -0.1381351, 1.554e-04, 1.930e-06,\n -12.5978298, -0.0136230, 2.000e-06,\n 349.0726929, 15.0026598, 0.000e-00,\n 0.5467340, 0.0001156, -1.180e-05,\n 0.0005940, 0.0001150, -1.170e-05,\n 0.0046845, 0.0046612,\n// 2850 11 24\n2762329.477721, 23.0, -4.0, 4.0, 3370.4, 3370.4,\n -0.1192670, 0.5342295, -7.000e-07, -7.140e-06,\n 1.3585740, -0.0518408, 8.060e-05, 6.300e-07,\n -20.6342106, -0.0079560, 5.000e-06,\n 168.5576324, 14.9985704, 0.000e-00,\n 0.5569990, 0.0001334, -1.110e-05,\n 0.0108070, 0.0001327, -1.110e-05,\n 0.0047214, 0.0046978,\n// 2851 4 22\n2762478.182316, 16.0, -4.0, 4.0, 3373.1, 3373.1,\n -0.3517760, 0.5027677, 4.550e-05, -6.060e-06,\n 0.5963580, 0.1272582, -9.240e-05, -1.480e-06,\n 12.3886700, 0.0136510, -3.000e-06,\n 60.3208618, 15.0028782, 0.000e-00,\n 0.5632310, -0.0000894, -1.030e-05,\n 0.0170080, -0.0000890, -1.020e-05,\n 0.0046707, 0.0046474,\n// 2851 10 16\n2762654.553789, 1.0, -4.0, 4.0, 3376.3, 3376.3,\n -0.3501080, 0.5581110, 2.840e-05, -9.380e-06,\n -0.6053630, -0.1607318, 9.340e-05, 2.610e-06,\n -8.8683004, -0.0147360, 2.000e-06,\n 198.5736542, 15.0038900, 0.000e-00,\n 0.5351600, 0.0000560, -1.280e-05,\n -0.0109230, 0.0000558, -1.280e-05,\n 0.0046700, 0.0046467,\n// 2852 4 10\n2762832.216683, 17.0, -4.0, 4.0, 3379.5, 3379.5,\n -0.0817470, 0.4844644, 1.670e-05, -5.390e-06,\n -0.0812730, 0.1393074, -4.330e-05, -1.490e-06,\n 8.4436903, 0.0149880, -2.000e-06,\n 74.7713089, 15.0035639, 0.000e-00,\n 0.5711460, -0.0000006, -9.800e-06,\n 0.0248840, -0.0000006, -9.700e-06,\n 0.0046858, 0.0046625,\n// 2852 10 4\n2763009.246348, 18.0, -4.0, 4.0, 3382.7, 3382.7,\n 0.0574910, 0.5534165, 1.370e-05, -9.220e-06,\n 0.0141220, -0.1708857, 2.630e-05, 2.760e-06,\n -4.9494500, -0.0153900, 1.000e-06,\n 92.8218613, 15.0047159, 0.000e-00,\n 0.5351570, -0.0000559, -1.270e-05,\n -0.0109260, -0.0000556, -1.270e-05,\n 0.0046565, 0.0046333,\n// 2853 3 30\n2763186.242608, 18.0, -4.0, 4.0, 3385.9, 3385.9,\n 0.3139950, 0.4946346, -1.780e-05, -5.940e-06,\n -0.7015270, 0.1535587, 1.100e-06, -1.790e-06,\n 4.1957302, 0.0158120, -1.000e-06,\n 89.0756531, 15.0039768, 0.000e-00,\n 0.5650830, 0.0000859, -1.030e-05,\n 0.0188510, 0.0000855, -1.030e-05,\n 0.0047001, 0.0046767,\n// 2853 9 24\n2763363.835793, 8.0, -4.0, 4.0, 3389.1, 3389.1,\n 0.2089250, 0.5261393, 6.400e-06, -7.610e-06,\n 0.7605000, -0.1682245, -3.940e-05, 2.340e-06,\n -0.8705700, -0.0156270, 0.000e-00,\n 301.8853455, 15.0051212, 0.000e-00,\n 0.5460960, -0.0001133, -1.160e-05,\n -0.0000410, -0.0001128, -1.150e-05,\n 0.0046440, 0.0046209,\n// 2854 2 18\n2763511.032457, 13.0, -4.0, 4.0, 3391.7, 3391.7,\n -0.2223130, 0.5472744, -2.050e-05, -8.560e-06,\n 1.3104280, 0.1470129, -1.200e-06, -2.200e-06,\n -11.4299202, 0.0144090, 3.000e-06,\n 11.9471102, 15.0020771, 0.000e-00,\n 0.5446470, 0.0000906, -1.240e-05,\n -0.0014840, 0.0000901, -1.230e-05,\n 0.0047412, 0.0047176,\n// 2854 3 20\n2763540.528894, 1.0, -4.0, 4.0, 3392.3, 3392.3,\n 0.5951480, 0.5240579, -4.470e-05, -7.500e-06,\n -1.3033020, 0.1681089, 5.850e-05, -2.360e-06,\n -0.1132100, 0.0161080, 0.000e-00,\n 193.3430939, 15.0040369, 0.000e-00,\n 0.5505340, 0.0001090, -1.160e-05,\n 0.0043750, 0.0001085, -1.160e-05,\n 0.0047128, 0.0046893,\n// 2854 8 15\n2763688.563220, 2.0, -4.0, 4.0, 3394.9, 3394.9,\n -0.0461870, 0.4955150, -7.800e-06, -5.670e-06,\n -1.2544510, -0.1181262, -2.990e-05, 1.300e-06,\n 13.7344904, -0.0127300, -3.000e-06,\n 208.5072327, 15.0034723, 0.000e-00,\n 0.5640870, -0.0000622, -9.800e-06,\n 0.0178600, -0.0000618, -9.800e-06,\n 0.0046087, 0.0045857,\n// 2855 2 8\n2763865.660671, 4.0, -4.0, 4.0, 3398.1, 3398.1,\n -0.0536050, 0.5691910, -1.980e-05, -9.690e-06,\n 0.6321000, 0.1256360, 6.670e-05, -2.050e-06,\n -14.9958897, 0.0128310, 4.000e-06,\n 236.9291687, 15.0008411, 0.000e-00,\n 0.5380530, 0.0000014, -1.310e-05,\n -0.0080440, 0.0000014, -1.310e-05,\n 0.0047476, 0.0047239,\n// 2855 8 4\n2764042.584745, 2.0, -4.0, 4.0, 3401.3, 3401.3,\n -0.1044080, 0.5000825, -2.090e-05, -5.700e-06,\n -0.4689930, -0.0926423, -7.810e-05, 9.900e-07,\n 16.9970398, -0.0108950, -4.000e-06,\n 208.0451355, 15.0023527, 0.000e-00,\n 0.5643290, 0.0000489, -9.800e-06,\n 0.0181010, 0.0000486, -9.700e-06,\n 0.0046037, 0.0045808,\n// 2856 1 28\n2764220.298022, 19.0, -4.0, 4.0, 3404.6, 3404.6,\n -0.0793700, 0.5622438, -3.900e-06, -8.940e-06,\n -0.0530320, 0.0921372, 1.331e-04, -1.370e-06,\n -18.0789394, 0.0107480, 4.000e-06,\n 102.2666092, 14.9994192, 0.000e-00,\n 0.5439940, -0.0000867, -1.260e-05,\n -0.0021330, -0.0000863, -1.250e-05,\n 0.0047519, 0.0047282,\n// 2856 7 23\n2764396.750809, 6.0, -4.0, 4.0, 3407.8, 3407.8,\n 0.0269940, 0.5292486, -3.310e-05, -6.910e-06,\n 0.2998290, -0.0660575, -1.335e-04, 7.900e-07,\n 19.6553593, -0.0086630, -4.000e-06,\n 267.9141541, 15.0012379, 0.000e-00,\n 0.5524910, 0.0001152, -1.070e-05,\n 0.0063220, 0.0001147, -1.060e-05,\n 0.0046009, 0.0045780,\n// 2857 1 17\n2764574.752834, 6.0, -4.0, 4.0, 3411.0, 3411.0,\n 0.0380900, 0.5346253, 1.900e-06, -7.160e-06,\n -0.7625660, 0.0524174, 1.802e-04, -6.000e-07,\n -20.5772095, 0.0081370, 5.000e-06,\n 267.9698792, 14.9980059, 0.000e-00,\n 0.5588640, -0.0001192, -1.120e-05,\n 0.0126630, -0.0001186, -1.110e-05,\n 0.0047538, 0.0047301,\n// 2857 6 13\n2764721.899369, 10.0, -4.0, 4.0, 3413.6, 3413.6,\n 0.4493350, 0.5720365, -9.100e-06, -9.430e-06,\n -1.4483480, 0.0816897, -8.400e-05, -1.490e-06,\n 23.1742001, 0.0017430, -6.000e-06,\n 329.5179138, 14.9991121, 0.000e-00,\n 0.5333030, 0.0000515, -1.260e-05,\n -0.0127700, 0.0000513, -1.250e-05,\n 0.0046130, 0.0045901,\n// 2857 7 12\n2764751.218323, 17.0, -4.0, 4.0, 3414.2, 3414.2,\n -0.0734170, 0.5654905, -2.020e-05, -8.800e-06,\n 1.0465230, -0.0337506, -2.012e-04, 4.500e-07,\n 21.6083603, -0.0061410, -5.000e-06,\n 73.0848770, 15.0002718, 0.000e-00,\n 0.5377750, 0.0001053, -1.200e-05,\n -0.0083210, 0.0001047, -1.200e-05,\n 0.0046005, 0.0045776,\n// 2857 12 7\n2764899.119702, 15.0, -4.0, 4.0, 3416.8, 3416.8,\n 0.3716960, 0.4926864, 1.680e-05, -5.440e-06,\n 1.4970590, -0.1008232, 8.650e-05, 1.230e-06,\n -22.5902691, -0.0041480, 6.000e-06,\n 47.4412003, 14.9970331, 0.000e-00,\n 0.5741420, -0.0000106, -9.800e-06,\n 0.0278650, -0.0000105, -9.800e-06,\n 0.0047350, 0.0047114,\n// 2858 1 6\n2764928.903741, 10.0, -4.0, 4.0, 3417.4, 3417.4,\n 0.1918610, 0.5090126, -9.000e-07, -5.850e-06,\n -1.4953530, 0.0116636, 2.110e-04, -4.000e-08,\n -22.3540096, 0.0050190, 6.000e-06,\n 329.0256958, 14.9968882, 0.000e-00,\n 0.5724130, -0.0000687, -1.010e-05,\n 0.0261450, -0.0000684, -1.000e-05,\n 0.0047527, 0.0047291,\n// 2858 6 3\n2765076.609696, 3.0, -4.0, 4.0, 3420.1, 3420.1,\n 0.3778900, 0.5679086, 2.050e-05, -9.550e-06,\n -0.7096220, 0.1270437, -1.151e-04, -2.280e-06,\n 22.3059006, 0.0045990, -5.000e-06,\n 225.0746307, 14.9994812, 0.000e-00,\n 0.5321530, -0.0000482, -1.280e-05,\n -0.0139150, -0.0000480, -1.270e-05,\n 0.0046217, 0.0045986,\n// 2858 11 26\n2765253.117045, 15.0, -4.0, 4.0, 3423.3, 3423.3,\n 0.3275620, 0.4946717, 1.200e-05, -5.810e-06,\n 0.7772930, -0.1432705, 1.022e-04, 1.840e-06,\n -20.9589596, -0.0072760, 5.000e-06,\n 48.4359894, 14.9982491, 0.000e-00,\n 0.5676810, 0.0000860, -1.030e-05,\n 0.0214360, 0.0000856, -1.020e-05,\n 0.0047235, 0.0047000,\n// 2859 5 23\n2765431.246242, 18.0, -4.0, 4.0, 3426.5, 3426.5,\n 0.0616890, 0.5353929, 5.410e-05, -7.970e-06,\n -0.0302320, 0.1604722, -1.304e-04, -2.550e-06,\n 20.6940403, 0.0073180, -5.000e-06,\n 90.4882278, 15.0001383, 0.000e-00,\n 0.5426210, -0.0001159, -1.180e-05,\n -0.0034990, -0.0001154, -1.170e-05,\n 0.0046325, 0.0046094,\n// 2859 11 15\n2765607.369904, 21.0, -4.0, 4.0, 3429.7, 3429.7,\n 0.0937780, 0.5140237, 2.100e-05, -7.180e-06,\n 0.0616840, -0.1877078, 1.194e-04, 2.790e-06,\n -18.5767593, -0.0098850, 4.000e-06,\n 139.0429535, 14.9997988, 0.000e-00,\n 0.5518850, 0.0001208, -1.150e-05,\n 0.0057190, 0.0001202, -1.140e-05,\n 0.0047104, 0.0046869,\n// 2860 5 12\n2765785.631509, 3.0, -4.0, 4.0, 3432.9, 3432.9,\n -0.3330040, 0.4929112, 6.980e-05, -6.110e-06,\n 0.6633970, 0.1824247, -1.334e-04, -2.430e-06,\n 18.3435593, 0.0098230, -4.000e-06,\n 225.6773529, 15.0010128, 0.000e-00,\n 0.5585380, -0.0001061, -1.050e-05,\n 0.0123380, -0.0001056, -1.040e-05,\n 0.0046452, 0.0046220,\n// 2860 11 4\n2765961.913517, 10.0, -4.0, 4.0, 3436.1, 3436.1,\n -0.2027020, 0.5301891, 4.410e-05, -8.650e-06,\n -0.5841650, -0.2269968, 1.347e-04, 3.890e-06,\n -15.6326199, -0.0119360, 3.000e-06,\n 334.2353516, 15.0013733, 0.000e-00,\n 0.5382380, 0.0000679, -1.270e-05,\n -0.0078610, 0.0000675, -1.270e-05,\n 0.0046965, 0.0046732,\n// 2861 4 1\n2766110.004214, 12.0, -4.0, 4.0, 3438.8, 3438.8,\n 0.6478540, 0.4442186, -1.610e-05, -4.880e-06,\n -1.3055750, 0.2401781, 2.530e-05, -2.810e-06,\n 4.8995099, 0.0155010, -1.000e-06,\n 359.1958618, 15.0038204, 0.000e-00,\n 0.5712500, 0.0000273, -9.800e-06,\n 0.0249870, 0.0000272, -9.800e-06,\n 0.0046980, 0.0046746,\n// 2861 5 1\n2766139.720339, 5.0, -4.0, 4.0, 3439.4, 3439.4,\n -0.7300970, 0.4640779, 6.800e-05, -5.140e-06,\n 1.3219219, 0.2006872, -1.345e-04, -2.380e-06,\n 15.2864904, 0.0120020, -3.000e-06,\n 255.5954437, 15.0020008, 0.000e-00,\n 0.5689770, -0.0000223, -9.800e-06,\n 0.0227250, -0.0000222, -9.700e-06,\n 0.0046592, 0.0046360,\n// 2861 9 25\n2766287.234886, 18.0, -4.0, 4.0, 3442.0, 3442.0,\n 0.8043640, 0.5026214, -2.820e-05, -8.040e-06,\n 1.0312520, -0.2763653, -5.370e-05, 4.600e-06,\n -1.4411100, -0.0153640, 0.000e-00,\n 92.0215836, 15.0050259, 0.000e-00,\n 0.5368610, -0.0000866, -1.250e-05,\n -0.0092300, -0.0000862, -1.240e-05,\n 0.0046453, 0.0046221,\n// 2861 10 25\n2766316.593414, 2.0, -4.0, 4.0, 3442.6, 3442.6,\n -0.6842740, 0.5256754, 7.840e-05, -8.800e-06,\n -1.1100750, -0.2502527, 1.370e-04, 4.400e-06,\n -12.2488499, -0.0134900, 2.000e-06,\n 214.0372314, 15.0027580, 0.000e-00,\n 0.5352110, -0.0000256, -1.290e-05,\n -0.0108720, -0.0000255, -1.290e-05,\n 0.0046826, 0.0046593,\n// 2862 3 21\n2766464.082734, 14.0, -4.0, 4.0, 3445.3, 3445.3,\n 0.3529060, 0.4602642, -2.860e-05, -5.690e-06,\n -0.6216320, 0.2548942, 1.830e-05, -3.350e-06,\n 0.5227700, 0.0158840, 0.000e-00,\n 28.4462204, 15.0039091, 0.000e-00,\n 0.5617510, 0.0001058, -1.070e-05,\n 0.0155350, 0.0001053, -1.060e-05,\n 0.0047115, 0.0046880,\n// 2862 9 15\n2766641.766069, 6.0, -4.0, 4.0, 3448.5, 3448.5,\n 0.1041670, 0.4753538, 2.000e-06, -6.430e-06,\n 0.6226290, -0.2619741, -4.960e-05, 3.710e-06,\n 2.6808500, -0.0152490, -1.000e-06,\n 271.0078430, 15.0050964, 0.000e-00,\n 0.5499270, -0.0001086, -1.110e-05,\n 0.0037710, -0.0001081, -1.110e-05,\n 0.0046336, 0.0046106,\n// 2863 3 10\n2766818.452179, 23.0, -4.0, 4.0, 3451.7, 3451.7,\n 0.0581430, 0.4909461, -2.890e-05, -7.300e-06,\n 0.0659750, 0.2690751, 1.170e-05, -4.200e-06,\n -3.7802100, 0.0157440, 1.000e-06,\n 162.7564850, 15.0036192, 0.000e-00,\n 0.5468990, 0.0001040, -1.210e-05,\n 0.0007570, 0.0001035, -1.200e-05,\n 0.0047234, 0.0046999,\n// 2863 9 4\n2766996.006412, 12.0, -4.0, 4.0, 3455.0, 3455.0,\n -0.1472260, 0.4528559, -2.900e-06, -5.210e-06,\n -0.1079610, -0.2418492, -3.330e-05, 2.950e-06,\n 6.7999802, -0.0146980, -1.000e-06,\n 359.9878235, 15.0047779, 0.000e-00,\n 0.5631240, -0.0000679, -1.000e-05,\n 0.0169020, -0.0000676, -9.900e-06,\n 0.0046232, 0.0046002,\n// 2864 2 28\n2767173.055977, 13.0, -4.0, 4.0, 3458.2, 3458.2,\n -0.5066430, 0.5153560, -8.000e-07, -8.610e-06,\n 0.5366510, 0.2699276, 1.420e-05, -4.720e-06,\n -7.9096599, 0.0151220, 2.000e-06,\n 12.2278099, 15.0029411, 0.000e-00,\n 0.5378450, 0.0000378, -1.310e-05,\n -0.0082520, 0.0000376, -1.300e-05,\n 0.0047336, 0.0047100,\n// 2864 8 23\n2767350.032842, 13.0, -4.0, 4.0, 3461.4, 3461.4,\n -0.3159920, 0.4529088, -1.800e-05, -5.010e-06,\n -0.8739160, -0.2258489, -1.890e-05, 2.660e-06,\n 10.7750502, -0.0136700, -2.000e-06,\n 14.0786400, 15.0041265, 0.000e-00,\n 0.5661110, 0.0000238, -9.700e-06,\n 0.0198740, 0.0000237, -9.700e-06,\n 0.0046142, 0.0045913,\n// 2865 1 18\n2767498.232187, 18.0, -4.0, 4.0, 3464.1, 3464.1,\n 0.6287940, 0.5360634, -5.890e-05, -8.130e-06,\n -1.2071340, 0.1677046, 2.056e-04, -2.680e-06,\n -20.2590408, 0.0082770, 5.000e-06,\n 87.8524628, 14.9981918, 0.000e-00,\n 0.5476270, -0.0001179, -1.220e-05,\n 0.0014820, -0.0001173, -1.210e-05,\n 0.0047533, 0.0047296,\n// 2865 2 17\n2767527.713695, 5.0, -4.0, 4.0, 3464.6, 3464.6,\n -0.6669470, 0.5184175, 1.230e-05, -8.380e-06,\n 1.2153471, 0.2494504, 8.100e-06, -4.250e-06,\n -11.7827797, 0.0140310, 3.000e-06,\n 251.9337769, 15.0018892, 0.000e-00,\n 0.5409180, -0.0000695, -1.280e-05,\n -0.0051930, -0.0000692, -1.270e-05,\n 0.0047420, 0.0047184,\n// 2865 7 14\n2767674.668782, 4.0, -4.0, 4.0, 3467.3, 3467.3,\n 0.2546540, 0.5243612, -6.600e-05, -7.160e-06,\n 1.0507410, -0.1413111, -1.827e-04, 2.100e-06,\n 21.3723907, -0.0062750, -5.000e-06,\n 238.0375671, 15.0003061, 0.000e-00,\n 0.5481000, 0.0001202, -1.110e-05,\n 0.0019530, 0.0001196, -1.100e-05,\n 0.0046007, 0.0045778,\n// 2866 1 8\n2767852.606333, 3.0, -4.0, 4.0, 3470.6, 3470.6,\n 0.3909340, 0.5133252, -3.420e-05, -6.490e-06,\n -0.6276040, 0.1213263, 1.788e-04, -1.660e-06,\n -22.1296406, 0.0052890, 6.000e-06,\n 223.8442230, 14.9970360, 0.000e-00,\n 0.5633640, -0.0001217, -1.080e-05,\n 0.0171410, -0.0001211, -1.070e-05,\n 0.0047527, 0.0047291,\n// 2866 7 3\n2768029.210603, 17.0, -4.0, 4.0, 3473.8, 3473.8,\n 0.0229320, 0.5630262, -4.400e-05, -9.070e-06,\n 0.2792830, -0.1104141, -1.717e-04, 1.930e-06,\n 22.7133503, -0.0035250, -5.000e-06,\n 73.4147491, 14.9995651, 0.000e-00,\n 0.5347830, 0.0000819, -1.240e-05,\n -0.0112980, 0.0000815, -1.230e-05,\n 0.0046028, 0.0045798,\n// 2866 12 28\n2768206.679853, 4.0, -4.0, 4.0, 3477.1, 3477.1,\n -0.1551670, 0.4990084, -1.290e-05, -5.570e-06,\n -0.0420730, 0.0755081, 1.549e-04, -9.600e-07,\n -23.1655903, 0.0018960, 6.000e-06,\n 240.1021576, 14.9963970, 0.000e-00,\n 0.5743490, -0.0000276, -9.900e-06,\n 0.0280700, -0.0000275, -9.900e-06,\n 0.0047491, 0.0047255,\n// 2867 6 23\n2768383.914991, 10.0, -4.0, 4.0, 3480.3, 3480.3,\n -0.0314320, 0.5797454, -1.570e-05, -9.860e-06,\n -0.4617190, -0.0691634, -1.412e-04, 1.310e-06,\n 23.2994804, -0.0006560, -6.000e-06,\n 328.9592896, 14.9991550, 0.000e-00,\n 0.5307080, -0.0000170, -1.280e-05,\n -0.0153530, -0.0000169, -1.280e-05,\n 0.0046072, 0.0045843,\n// 2867 12 17\n2768560.646865, 4.0, -4.0, 4.0, 3483.5, 3483.5,\n 0.1993700, 0.5084407, -2.720e-05, -5.840e-06,\n 0.6776100, 0.0325780, 1.289e-04, -4.700e-07,\n -23.2388802, -0.0016200, 6.000e-06,\n 241.4395142, 14.9965029, 0.000e-00,\n 0.5714560, 0.0000605, -1.010e-05,\n 0.0251920, 0.0000602, -1.000e-05,\n 0.0047422, 0.0047186,\n// 2868 5 13\n2768709.192447, 17.0, -4.0, 4.0, 3486.2, 3486.2,\n -0.0041280, 0.5434493, 3.750e-05, -7.750e-06,\n 1.4265580, 0.0821655, -1.871e-04, -1.120e-06,\n 18.7386894, 0.0096970, -4.000e-06,\n 75.6659317, 15.0009823, 0.000e-00,\n 0.5473100, -0.0001306, -1.140e-05,\n 0.0011660, -0.0001299, -1.140e-05,\n 0.0046429, 0.0046198,\n// 2868 6 12\n2768738.589525, 2.0, -4.0, 4.0, 3486.8, 3486.8,\n -0.1323970, 0.5652422, 1.490e-05, -8.760e-06,\n -1.2187181, -0.0223603, -9.730e-05, 4.800e-07,\n 23.1227703, 0.0022710, -6.000e-06,\n 209.5650940, 14.9991102, 0.000e-00,\n 0.5385650, -0.0000987, -1.210e-05,\n -0.0075350, -0.0000982, -1.200e-05,\n 0.0046141, 0.0045912,\n// 2868 11 5\n2768885.289683, 19.0, -4.0, 4.0, 3489.5, 3489.5,\n -0.2712430, 0.5457691, 1.940e-05, -8.130e-06,\n -1.4333820, -0.1135826, 1.832e-04, 1.580e-06,\n -16.0558491, -0.0119480, 3.000e-06,\n 109.2329407, 15.0012140, 0.000e-00,\n 0.5467080, 0.0001155, -1.190e-05,\n 0.0005670, 0.0001150, -1.180e-05,\n 0.0046985, 0.0046751,\n// 2868 12 5\n2768914.820080, 8.0, -4.0, 4.0, 3490.0, 3490.0,\n 0.1991280, 0.5382080, -2.340e-05, -7.240e-06,\n 1.3149070, -0.0113414, 9.700e-05, 8.000e-08,\n -22.3673401, -0.0049540, 6.000e-06,\n 302.6429749, 14.9973316, 0.000e-00,\n 0.5569050, 0.0001163, -1.120e-05,\n 0.0107130, 0.0001157, -1.110e-05,\n 0.0047323, 0.0047087,\n// 2869 5 2\n2769063.486377, 0.0, -4.0, 4.0, 3492.7, 3492.7,\n 0.0206410, 0.5068168, 3.270e-05, -6.080e-06,\n 0.7384820, 0.1042961, -1.209e-04, -1.190e-06,\n 15.8341398, 0.0118920, -4.000e-06,\n 180.6312866, 15.0019321, 0.000e-00,\n 0.5630120, -0.0000996, -1.020e-05,\n 0.0167900, -0.0000991, -1.020e-05,\n 0.0046568, 0.0046336,\n// 2869 10 26\n2769239.894523, 9.0, -4.0, 4.0, 3496.0, 3496.0,\n -0.4388730, 0.5637983, 3.830e-05, -9.510e-06,\n -0.6278210, -0.1419795, 1.218e-04, 2.300e-06,\n -12.7046900, -0.0135690, 3.000e-06,\n 319.0797119, 15.0026875, 0.000e-00,\n 0.5356190, 0.0000553, -1.290e-05,\n -0.0104660, 0.0000550, -1.280e-05,\n 0.0046842, 0.0046609,\n// 2870 4 22\n2769417.517313, 0.0, -4.0, 4.0, 3499.2, 3499.2,\n -0.2016790, 0.4889788, 2.410e-05, -5.450e-06,\n -0.0573510, 0.1237179, -6.770e-05, -1.320e-06,\n 12.2975702, 0.0136990, -3.000e-06,\n 180.3147125, 15.0028601, 0.000e-00,\n 0.5702150, 0.0000095, -9.800e-06,\n 0.0239570, 0.0000095, -9.700e-06,\n 0.0046716, 0.0046484,\n// 2870 10 16\n2769594.580340, 2.0, -4.0, 4.0, 3502.5, 3502.5,\n 0.0358930, 0.5559067, 2.250e-05, -9.210e-06,\n -0.0255400, -0.1586414, 5.480e-05, 2.540e-06,\n -9.0295200, -0.0147000, 2.000e-06,\n 213.5984802, 15.0038443, 0.000e-00,\n 0.5363160, -0.0000606, -1.270e-05,\n -0.0097730, -0.0000603, -1.270e-05,\n 0.0046704, 0.0046472,\n// 2871 4 11\n2769771.559459, 1.0, -4.0, 4.0, 3505.7, 3505.7,\n -0.0118370, 0.4991183, 0.000e-00, -6.060e-06,\n -0.7573610, 0.1444363, -2.090e-05, -1.700e-06,\n 8.3440399, 0.0150040, -2.000e-06,\n 194.7608948, 15.0036058, 0.000e-00,\n 0.5634580, 0.0001017, -1.040e-05,\n 0.0172340, 0.0001012, -1.030e-05,\n 0.0046862, 0.0046629,\n// 2871 10 5\n2769949.152203, 16.0, -4.0, 4.0, 3509.0, 3509.0,\n 0.4004060, 0.5256185, 6.200e-06, -7.530e-06,\n 0.6475120, -0.1627273, -9.400e-06, 2.240e-06,\n -5.0719099, -0.0153920, 1.000e-06,\n 62.8441887, 15.0046349, 0.000e-00,\n 0.5476740, -0.0001237, -1.150e-05,\n 0.0015280, -0.0001231, -1.140e-05,\n 0.0046570, 0.0046338,\n// 2872 2 29\n2770096.390790, 21.0, -4.0, 4.0, 3511.7, 3511.7,\n -0.5901550, 0.5441311, 3.900e-06, -8.600e-06,\n 1.2128429, 0.1638866, -2.500e-05, -2.490e-06,\n -7.3798699, 0.0154880, 2.000e-06,\n 132.2868805, 15.0031281, 0.000e-00,\n 0.5434860, 0.0001016, -1.240e-05,\n -0.0026390, 0.0001011, -1.240e-05,\n 0.0047325, 0.0047090,\n// 2872 3 30\n2770125.868396, 9.0, -4.0, 4.0, 3512.2, 3512.2,\n 0.5005540, 0.5269687, -3.240e-05, -7.620e-06,\n -1.3032020, 0.1653235, 3.350e-05, -2.350e-06,\n 4.2057400, 0.0157830, -1.000e-06,\n 314.0788574, 15.0040493, 0.000e-00,\n 0.5489470, 0.0001108, -1.170e-05,\n 0.0027950, 0.0001103, -1.160e-05,\n 0.0046997, 0.0046763,\n// 2872 8 25\n2770273.838493, 8.0, -4.0, 4.0, 3515.0, 3515.0,\n -0.4114310, 0.4899443, 7.200e-06, -5.580e-06,\n -1.2476200, -0.1359116, -7.800e-06, 1.490e-06,\n 10.1368904, -0.0140880, -2.000e-06,\n 299.2147827, 15.0043488, 0.000e-00,\n 0.5649740, -0.0000439, -9.800e-06,\n 0.0187420, -0.0000437, -9.800e-06,\n 0.0046154, 0.0045925,\n// 2872 9 23\n2770303.451417, 23.0, -4.0, 4.0, 3515.5, 3515.5,\n 0.5532970, 0.4933519, -9.600e-06, -5.940e-06,\n 1.4373950, -0.1589047, -6.090e-05, 1.830e-06,\n -0.8824300, -0.0156450, 0.000e-00,\n 166.8860474, 15.0050478, 0.000e-00,\n 0.5617860, -0.0000906, -1.020e-05,\n 0.0155710, -0.0000902, -1.020e-05,\n 0.0046443, 0.0046212,\n// 2873 2 18\n2770451.027659, 13.0, -4.0, 4.0, 3518.2, 3518.2,\n 0.0254840, 0.5633784, -2.000e-05, -9.600e-06,\n 0.6659010, 0.1500731, 3.680e-05, -2.470e-06,\n -11.2863903, 0.0144520, 3.000e-06,\n 11.9573298, 15.0021553, 0.000e-00,\n 0.5376830, -0.0000095, -1.310e-05,\n -0.0084130, -0.0000094, -1.310e-05,\n 0.0047410, 0.0047174,\n// 2873 8 14\n2770627.857118, 9.0, -4.0, 4.0, 3521.4, 3521.4,\n 0.0833240, 0.4957913, -2.800e-05, -5.670e-06,\n -0.5996520, -0.1168506, -5.160e-05, 1.270e-06,\n 13.8258305, -0.0126860, -3.000e-06,\n 313.4846497, 15.0034475, 0.000e-00,\n 0.5642140, 0.0000463, -9.800e-06,\n 0.0179860, 0.0000460, -9.800e-06,\n 0.0046082, 0.0045853,\n// 2874 2 8\n2770805.662634, 4.0, -4.0, 4.0, 3524.7, 3524.7,\n 0.0610740, 0.5549883, -1.160e-05, -8.770e-06,\n -0.0213180, 0.1229587, 1.057e-04, -1.850e-06,\n -14.8691597, 0.0129080, 3.000e-06,\n 236.9317322, 15.0008516, 0.000e-00,\n 0.5443360, -0.0000970, -1.250e-05,\n -0.0017930, -0.0000965, -1.240e-05,\n 0.0047478, 0.0047242,\n// 2874 8 3\n2770982.039500, 13.0, -4.0, 4.0, 3528.0, 3528.0,\n 0.0674470, 0.5263739, -3.860e-05, -6.940e-06,\n 0.2116100, -0.0973644, -1.089e-04, 1.220e-06,\n 17.0289402, -0.0108580, -4.000e-06,\n 13.0316200, 15.0024042, 0.000e-00,\n 0.5517060, 0.0001160, -1.080e-05,\n 0.0055410, 0.0001154, -1.070e-05,\n 0.0046031, 0.0045802,\n// 2875 1 28\n2771160.104566, 15.0, -4.0, 4.0, 3531.2, 3531.2,\n 0.3832740, 0.5282103, -1.830e-05, -7.020e-06,\n -0.7055290, 0.0878151, 1.566e-04, -1.070e-06,\n -18.0169392, 0.0108080, 4.000e-06,\n 42.2669907, 14.9993601, 0.000e-00,\n 0.5595330, -0.0001314, -1.110e-05,\n 0.0133280, -0.0001307, -1.110e-05,\n 0.0047526, 0.0047289,\n// 2875 7 24\n2771336.524186, 1.0, -4.0, 4.0, 3534.5, 3534.5,\n 0.3587360, 0.5635572, -4.820e-05, -8.840e-06,\n 0.9259900, -0.0722237, -1.776e-04, 1.070e-06,\n 19.6084995, -0.0086940, -4.000e-06,\n 192.9004822, 15.0013456, 0.000e-00,\n 0.5370860, 0.0000862, -1.210e-05,\n -0.0090060, 0.0000858, -1.200e-05,\n 0.0046003, 0.0045774,\n// 2875 12 18\n2771484.447470, 23.0, -4.0, 4.0, 3537.2, 3537.2,\n 0.3162540, 0.4990182, 7.400e-06, -5.510e-06,\n 1.5312910, -0.0599988, 9.370e-05, 7.700e-07,\n -23.2949696, -0.0008040, 6.000e-06,\n 166.2294769, 14.9964199, 0.000e-00,\n 0.5747390, -0.0000084, -9.900e-06,\n 0.0284590, -0.0000083, -9.800e-06,\n 0.0047435, 0.0047199,\n// 2876 1 17\n2771514.240989, 18.0, -4.0, 4.0, 3537.8, 3537.8,\n 0.2561820, 0.5057275, -1.430e-05, -5.780e-06,\n -1.4747920, 0.0500617, 1.952e-04, -4.900e-07,\n -20.5960102, 0.0081110, 5.000e-06,\n 87.9929581, 14.9979172, 0.000e-00,\n 0.5729650, -0.0000630, -1.000e-05,\n 0.0266940, -0.0000627, -1.000e-05,\n 0.0047544, 0.0047308,\n// 2876 6 13\n2771661.928296, 10.0, -4.0, 4.0, 3540.5, 3540.5,\n -0.0407600, 0.5753497, 3.160e-05, -9.650e-06,\n -0.8559660, 0.0828413, -1.170e-04, -1.520e-06,\n 23.1892891, 0.0016210, -6.000e-06,\n 329.4772339, 14.9991102, 0.000e-00,\n 0.5320010, -0.0000372, -1.270e-05,\n -0.0140660, -0.0000370, -1.270e-05,\n 0.0046129, 0.0045900,\n// 2876 12 6\n2771838.447846, 23.0, -4.0, 4.0, 3543.8, 3543.8,\n 0.3020370, 0.5052647, 5.200e-06, -5.990e-06,\n 0.8124320, -0.1052556, 1.161e-04, 1.390e-06,\n -22.5569000, -0.0042200, 6.000e-06,\n 167.4789734, 14.9970980, 0.000e-00,\n 0.5677010, 0.0000881, -1.030e-05,\n 0.0214560, 0.0000877, -1.030e-05,\n 0.0047341, 0.0047105,\n// 2877 6 3\n2772016.558030, 1.0, -4.0, 4.0, 3547.0, 3547.0,\n -0.1893430, 0.5437388, 5.850e-05, -8.020e-06,\n -0.1562750, 0.1212168, -1.406e-04, -1.930e-06,\n 22.3404007, 0.0045240, -5.000e-06,\n 195.0489349, 14.9993954, 0.000e-00,\n 0.5429270, -0.0001063, -1.170e-05,\n -0.0031940, -0.0001058, -1.160e-05,\n 0.0046221, 0.0045991,\n// 2877 11 26\n2772192.712831, 5.0, -4.0, 4.0, 3550.3, 3550.3,\n -0.0254130, 0.5271325, 2.360e-05, -7.460e-06,\n 0.1250170, -0.1530307, 1.378e-04, 2.330e-06,\n -20.9512100, -0.0072560, 5.000e-06,\n 258.4426270, 14.9983416, 0.000e-00,\n 0.5517240, 0.0001252, -1.160e-05,\n 0.0055580, 0.0001246, -1.150e-05,\n 0.0047225, 0.0046989,\n// 2878 5 23\n2772370.928967, 10.0, -4.0, 4.0, 3553.6, 3553.6,\n -0.3414440, 0.5020672, 6.710e-05, -6.180e-06,\n 0.6023580, 0.1501206, -1.503e-04, -2.010e-06,\n 20.7032795, 0.0073260, -5.000e-06,\n 330.4829712, 15.0000401, 0.000e-00,\n 0.5586640, -0.0000997, -1.040e-05,\n 0.0124640, -0.0000992, -1.040e-05,\n 0.0046335, 0.0046104,\n// 2878 11 15\n2772547.262818, 18.0, -4.0, 4.0, 3556.8, 3556.8,\n -0.3674010, 0.5430578, 5.540e-05, -8.920e-06,\n -0.4921950, -0.1969198, 1.552e-04, 3.410e-06,\n -18.6406403, -0.0097990, 4.000e-06,\n 94.0364532, 14.9998436, 0.000e-00,\n 0.5384850, 0.0000728, -1.280e-05,\n -0.0076150, 0.0000725, -1.270e-05,\n 0.0047096, 0.0046862,\n// 2879 4 12\n2772695.311443, 19.0, -4.0, 4.0, 3559.6, 3559.6,\n 0.4696390, 0.4499559, -5.000e-07, -4.970e-06,\n -1.4418180, 0.2307262, 8.600e-06, -2.720e-06,\n 9.0081596, 0.0146140, -2.000e-06,\n 104.8681335, 15.0033894, 0.000e-00,\n 0.5701030, 0.0000401, -9.800e-06,\n 0.0238460, 0.0000399, -9.800e-06,\n 0.0046843, 0.0046610,\n// 2879 5 12\n2772725.010908, 12.0, -4.0, 4.0, 3560.1, 3560.1,\n -0.6247890, 0.4741280, 6.550e-05, -5.260e-06,\n 1.3080240, 0.1754193, -1.549e-04, -2.090e-06,\n 18.2851391, 0.0098900, -4.000e-06,\n 0.6765500, 15.0009785, 0.000e-00,\n 0.5683330, -0.0000166, -9.700e-06,\n 0.0220840, -0.0000165, -9.700e-06,\n 0.0046464, 0.0046233,\n// 2879 10 7\n2772872.561853, 1.0, -4.0, 4.0, 3562.9, 3562.9,\n 0.3904360, 0.5042077, 4.900e-06, -7.990e-06,\n 1.3156030, -0.2700846, -4.420e-05, 4.450e-06,\n -5.6183901, -0.0150670, 1.000e-06,\n 197.9557037, 15.0044928, 0.000e-00,\n 0.5382200, -0.0000698, -1.240e-05,\n -0.0078790, -0.0000695, -1.240e-05,\n 0.0046582, 0.0046350,\n// 2879 11 5\n2772901.938080, 11.0, -4.0, 4.0, 3563.4, 3563.4,\n -0.2309240, 0.5358693, 6.300e-05, -8.960e-06,\n -1.2744210, -0.2259181, 1.717e-04, 3.980e-06,\n -15.7612495, -0.0118550, 3.000e-06,\n 349.2360229, 15.0013371, 0.000e-00,\n 0.5361650, -0.0000500, -1.290e-05,\n -0.0099230, -0.0000498, -1.290e-05,\n 0.0046964, 0.0046730,\n// 2880 3 31\n2773049.408668, 22.0, -4.0, 4.0, 3566.1, 3566.1,\n 0.4443190, 0.4640368, -2.020e-05, -5.790e-06,\n -0.6061410, 0.2518672, -4.500e-06, -3.340e-06,\n 4.8239002, 0.0154860, -1.000e-06,\n 149.1899872, 15.0038633, 0.000e-00,\n 0.5601610, 0.0001039, -1.070e-05,\n 0.0139540, 0.0001034, -1.060e-05,\n 0.0046983, 0.0046749,\n// 2880 9 25\n2773227.073280, 14.0, -4.0, 4.0, 3569.4, 3569.4,\n 0.4328530, 0.4729887, 7.000e-07, -6.340e-06,\n 0.5128040, -0.2617553, -2.310e-05, 3.680e-06,\n -1.5314800, -0.0153930, 0.000e-00,\n 32.0374603, 15.0049534, 0.000e-00,\n 0.5514780, -0.0001220, -1.110e-05,\n 0.0053140, -0.0001214, -1.100e-05,\n 0.0046458, 0.0046226,\n// 2881 3 21\n2773403.799170, 7.0, -4.0, 4.0, 3572.7, 3572.7,\n -0.0919060, 0.4912276, -8.500e-06, -7.370e-06,\n -0.0428200, 0.2723278, -7.300e-06, -4.290e-06,\n 0.5611500, 0.0158410, 0.000e-00,\n 283.4595947, 15.0039787, 0.000e-00,\n 0.5454350, 0.0001090, -1.210e-05,\n -0.0006990, 0.0001085, -1.200e-05,\n 0.0047110, 0.0046876,\n// 2881 9 14\n2773581.290912, 19.0, -4.0, 4.0, 3576.0, 3576.0,\n -0.0360860, 0.4481624, 3.100e-06, -5.120e-06,\n -0.0844730, -0.2476366, -1.370e-05, 3.000e-06,\n 2.7030799, -0.0152790, -1.000e-06,\n 105.9989014, 15.0050325, 0.000e-00,\n 0.5643730, -0.0000660, -1.000e-05,\n 0.0181440, -0.0000656, -9.900e-06,\n 0.0046340, 0.0046109,\n// 2882 3 10\n2773758.415647, 22.0, -4.0, 4.0, 3579.3, 3579.3,\n -0.3202670, 0.5108897, 3.800e-06, -8.550e-06,\n 0.6151810, 0.2794651, -1.560e-05, -4.890e-06,\n -3.6449699, 0.0157290, 1.000e-06,\n 147.7880554, 15.0036831, 0.000e-00,\n 0.5371000, 0.0000225, -1.300e-05,\n -0.0089930, 0.0000223, -1.300e-05,\n 0.0047227, 0.0046992,\n// 2882 9 3\n2773935.309476, 19.0, -4.0, 4.0, 3582.6, 3582.6,\n -0.5877110, 0.4470358, -8.000e-07, -4.960e-06,\n -0.6429890, -0.2380741, -6.300e-06, 2.800e-06,\n 6.9108100, -0.0146820, -2.000e-06,\n 104.9533386, 15.0047522, 0.000e-00,\n 0.5664170, 0.0000429, -9.700e-06,\n 0.0201790, 0.0000427, -9.700e-06,\n 0.0046230, 0.0046000,\n// 2883 1 30\n2774083.594230, 2.0, -4.0, 4.0, 3585.3, 3585.3,\n 0.3486860, 0.5225460, -4.720e-05, -7.830e-06,\n -1.3107270, 0.2014910, 1.866e-04, -3.170e-06,\n -17.6074104, 0.0108710, 4.000e-06,\n 207.1996460, 14.9995499, 0.000e-00,\n 0.5483090, -0.0001041, -1.210e-05,\n 0.0021600, -0.0001036, -1.210e-05,\n 0.0047515, 0.0047278,\n// 2883 2 28\n2774113.075034, 14.0, -4.0, 4.0, 3585.9, 3585.9,\n -0.5331520, 0.5095537, 1.750e-05, -8.190e-06,\n 1.2727290, 0.2650751, -2.040e-05, -4.490e-06,\n -7.7466302, 0.0151670, 2.000e-06,\n 27.2547207, 15.0029631, 0.000e-00,\n 0.5408970, -0.0000825, -1.270e-05,\n -0.0052150, -0.0000821, -1.270e-05,\n 0.0047333, 0.0047098,\n// 2883 7 25\n2774259.962064, 11.0, -4.0, 4.0, 3588.6, 3588.6,\n 0.3270080, 0.5158800, -7.320e-05, -7.110e-06,\n 1.1081769, -0.1762081, -1.668e-04, 2.610e-06,\n 19.2868500, -0.0087780, -4.000e-06,\n 342.8992920, 15.0013838, 0.000e-00,\n 0.5471520, 0.0001218, -1.120e-05,\n 0.0010090, 0.0001212, -1.110e-05,\n 0.0046008, 0.0045779,\n// 2883 8 23\n2774289.430080, 22.0, -4.0, 4.0, 3589.1, 3589.1,\n -0.8403390, 0.4730972, -7.500e-06, -5.930e-06,\n -1.3163180, -0.2339081, 6.500e-06, 3.070e-06,\n 10.8483601, -0.0136230, -2.000e-06,\n 149.0531158, 15.0041628, 0.000e-00,\n 0.5555250, 0.0001177, -1.050e-05,\n 0.0093400, 0.0001171, -1.050e-05,\n 0.0046135, 0.0045905,\n// 2884 1 19\n2774437.954088, 11.0, -4.0, 4.0, 3591.9, 3591.9,\n 0.2650210, 0.5012921, -3.610e-05, -6.260e-06,\n -0.6595370, 0.1587583, 1.624e-04, -2.120e-06,\n -20.2366409, 0.0083250, 5.000e-06,\n 342.8504944, 14.9981117, 0.000e-00,\n 0.5642470, -0.0001128, -1.070e-05,\n 0.0180190, -0.0001123, -1.070e-05,\n 0.0047540, 0.0047304,\n// 2884 7 14\n2774614.519197, 0.0, -4.0, 4.0, 3595.2, 3595.2,\n -0.1626960, 0.5548606, -4.280e-05, -9.000e-06,\n 0.4097000, -0.1515750, -1.638e-04, 2.620e-06,\n 21.3323307, -0.0063120, -5.000e-06,\n 178.0198975, 15.0004072, 0.000e-00,\n 0.5340160, 0.0000877, -1.240e-05,\n -0.0120610, 0.0000873, -1.240e-05,\n 0.0046001, 0.0045772,\n// 2885 1 7\n2774792.014166, 12.0, -4.0, 4.0, 3598.5, 3598.5,\n -0.1602000, 0.4907088, -2.390e-05, -5.450e-06,\n -0.0674660, 0.1156513, 1.456e-04, -1.410e-06,\n -22.1593304, 0.0052320, 6.000e-06,\n 358.8748779, 14.9969559, 0.000e-00,\n 0.5748510, -0.0000228, -9.900e-06,\n 0.0285700, -0.0000227, -9.900e-06,\n 0.0047533, 0.0047297,\n// 2885 7 3\n2774969.229111, 17.0, -4.0, 4.0, 3601.8, 3601.8,\n -0.3616740, 0.5723885, -9.700e-06, -9.700e-06,\n -0.3262160, -0.1138102, -1.410e-04, 2.080e-06,\n 22.6744995, -0.0036290, -5.000e-06,\n 73.3882294, 14.9996166, 0.000e-00,\n 0.5305940, -0.0000090, -1.280e-05,\n -0.0154670, -0.0000090, -1.270e-05,\n 0.0046024, 0.0045795,\n// 2885 12 27\n2775145.982208, 12.0, -4.0, 4.0, 3605.1, 3605.1,\n 0.1201300, 0.5048333, -3.770e-05, -5.820e-06,\n 0.6750220, 0.0750465, 1.269e-04, -9.800e-07,\n -23.1780109, 0.0018090, 6.000e-06,\n 0.1429500, 14.9964066, 0.000e-00,\n 0.5713750, 0.0000652, -1.010e-05,\n 0.0251120, 0.0000649, -1.010e-05,\n 0.0047488, 0.0047252,\n// 2886 5 25\n2775294.503402, 0.0, -4.0, 4.0, 3607.8, 3607.8,\n -0.1696010, 0.5458391, 3.760e-05, -7.700e-06,\n 1.4651279, 0.0464937, -2.078e-04, -6.000e-07,\n 20.9969196, 0.0071520, -5.000e-06,\n 180.4234924, 15.0000191, 0.000e-00,\n 0.5475850, -0.0001202, -1.130e-05,\n 0.0014400, -0.0001196, -1.130e-05,\n 0.0046313, 0.0046082,\n// 2886 6 23\n2775323.898061, 10.0, -4.0, 4.0, 3608.4, 3608.4,\n 0.1129060, 0.5600211, -8.400e-06, -8.600e-06,\n -1.1793931, -0.0669119, -1.007e-04, 1.170e-06,\n 23.2897701, -0.0007790, -6.000e-06,\n 328.9270020, 14.9991140, 0.000e-00,\n 0.5388980, -0.0001157, -1.200e-05,\n -0.0072030, -0.0001151, -1.190e-05,\n 0.0046074, 0.0045844,\n// 2886 11 17\n2775470.632226, 3.0, -4.0, 4.0, 3611.1, 3611.1,\n -0.3126330, 0.5530927, 1.830e-05, -8.320e-06,\n -1.4499919, -0.0819339, 2.089e-04, 1.120e-06,\n -18.9854298, -0.0097470, 4.000e-06,\n 228.9826660, 14.9996681, 0.000e-00,\n 0.5466420, 0.0001187, -1.200e-05,\n 0.0005020, 0.0001181, -1.190e-05,\n 0.0047115, 0.0046880,\n// 2886 12 16\n2775500.167282, 16.0, -4.0, 4.0, 3611.6, 3611.6,\n -0.0864920, 0.5390057, -2.460e-05, -7.320e-06,\n 1.2989830, 0.0325725, 1.045e-04, -5.300e-07,\n -23.2336292, -0.0016550, 6.000e-06,\n 61.4615402, 14.9965963, 0.000e-00,\n 0.5565610, 0.0001238, -1.130e-05,\n 0.0103710, 0.0001232, -1.120e-05,\n 0.0047412, 0.0047176,\n// 2887 5 14\n2775648.785035, 7.0, -4.0, 4.0, 3614.4, 3614.4,\n -0.0330650, 0.5106856, 3.160e-05, -6.080e-06,\n 0.7829440, 0.0757044, -1.442e-04, -8.400e-07,\n 18.7369003, 0.0097140, -4.000e-06,\n 285.6537476, 15.0008907, 0.000e-00,\n 0.5629170, -0.0000916, -1.010e-05,\n 0.0166960, -0.0000912, -1.010e-05,\n 0.0046441, 0.0046210,\n// 2887 11 6\n2775825.239974, 18.0, -4.0, 4.0, 3617.7, 3617.7,\n -0.0112820, 0.5703427, 1.860e-05, -9.650e-06,\n -0.7608290, -0.1154798, 1.554e-04, 1.860e-06,\n -16.1595802, -0.0118730, 3.000e-06,\n 94.2341309, 15.0012360, 0.000e-00,\n 0.5361180, 0.0000315, -1.300e-05,\n -0.0099700, 0.0000313, -1.290e-05,\n 0.0046978, 0.0046744,\n// 2888 5 2\n2776002.813307, 8.0, -4.0, 4.0, 3621.0, 3621.0,\n 0.2277620, 0.4943923, 1.030e-05, -5.520e-06,\n 0.0967450, 0.1018124, -9.550e-05, -1.070e-06,\n 15.7581596, 0.0119490, -4.000e-06,\n 300.6195374, 15.0019131, 0.000e-00,\n 0.5692870, -0.0000019, -9.800e-06,\n 0.0230340, -0.0000019, -9.700e-06,\n 0.0046581, 0.0046349,\n// 2888 10 26\n2776179.918854, 10.0, -4.0, 4.0, 3624.3, 3624.3,\n -0.0424370, 0.5598968, 3.190e-05, -9.220e-06,\n -0.0451660, -0.1391588, 8.290e-05, 2.210e-06,\n -12.8505497, -0.0135110, 3.000e-06,\n 334.0964966, 15.0026312, 0.000e-00,\n 0.5375150, -0.0000625, -1.270e-05,\n -0.0085800, -0.0000622, -1.260e-05,\n 0.0046843, 0.0046610,\n// 2889 4 21\n2776356.870784, 9.0, -4.0, 4.0, 3627.6, 3627.6,\n 0.2185610, 0.5051804, -4.300e-06, -6.180e-06,\n -0.6438580, 0.1287630, -4.850e-05, -1.520e-06,\n 12.2223501, 0.0137210, -3.000e-06,\n 315.3045959, 15.0029068, 0.000e-00,\n 0.5618990, 0.0000940, -1.040e-05,\n 0.0156830, 0.0000935, -1.030e-05,\n 0.0046722, 0.0046489,\n// 2889 10 15\n2776534.473007, 23.0, -4.0, 4.0, 3630.9, 3630.9,\n 0.0044130, 0.5269785, 3.020e-05, -7.450e-06,\n 0.7182210, -0.1505370, 1.350e-05, 2.040e-06,\n -9.1295404, -0.0146900, 2.000e-06,\n 168.6143646, 15.0037546, 0.000e-00,\n 0.5494270, -0.0001085, -1.140e-05,\n 0.0032730, -0.0001080, -1.140e-05,\n 0.0046708, 0.0046475,\n// 2890 3 12\n2776681.744740, 6.0, -4.0, 4.0, 3633.7, 3633.7,\n -0.3405850, 0.5428644, 9.000e-07, -8.630e-06,\n 1.3035901, 0.1732668, -5.670e-05, -2.650e-06,\n -3.0976400, 0.0160250, 1.000e-06,\n 267.8763733, 15.0038242, 0.000e-00,\n 0.5423250, 0.0000850, -1.250e-05,\n -0.0037940, 0.0000846, -1.240e-05,\n 0.0047216, 0.0046981,\n// 2890 4 10\n2776711.202118, 17.0, -4.0, 4.0, 3634.2, 3634.2,\n 0.4599810, 0.5319681, -2.350e-05, -7.770e-06,\n -1.2784290, 0.1555641, 7.600e-06, -2.230e-06,\n 8.3653498, 0.0149730, -2.000e-06,\n 74.7737579, 15.0036774, 0.000e-00,\n 0.5473350, 0.0001093, -1.170e-05,\n 0.0011910, 0.0001088, -1.170e-05,\n 0.0046859, 0.0046626,\n// 2890 9 5\n2776859.117356, 15.0, -4.0, 4.0, 3637.0, 3637.0,\n -0.3150840, 0.4855970, 8.500e-06, -5.500e-06,\n -1.3552990, -0.1477593, 1.820e-05, 1.620e-06,\n 6.2117100, -0.0150290, -1.000e-06,\n 45.1169815, 15.0049229, 0.000e-00,\n 0.5659040, -0.0000437, -9.800e-06,\n 0.0196680, -0.0000435, -9.700e-06,\n 0.0046245, 0.0046014,\n// 2890 10 5\n2776888.749608, 6.0, -4.0, 4.0, 3637.6, 3637.6,\n 0.4463160, 0.4931820, 1.200e-06, -5.880e-06,\n 1.4157341, -0.1537032, -3.600e-05, 1.750e-06,\n -5.0698700, -0.0154090, 1.000e-06,\n 272.8347778, 15.0045652, 0.000e-00,\n 0.5633090, -0.0000832, -1.020e-05,\n 0.0170860, -0.0000828, -1.010e-05,\n 0.0046572, 0.0046340,\n// 2891 3 1\n2777036.390339, 21.0, -4.0, 4.0, 3640.3, 3640.3,\n -0.3915090, 0.5587843, 8.400e-06, -9.520e-06,\n 0.5616740, 0.1666296, 1.380e-05, -2.750e-06,\n -7.2309499, 0.0155090, 2.000e-06,\n 132.3189240, 15.0031919, 0.000e-00,\n 0.5372260, 0.0000032, -1.310e-05,\n -0.0088680, 0.0000031, -1.300e-05,\n 0.0047321, 0.0047085,\n// 2891 8 25\n2777213.133790, 15.0, -4.0, 4.0, 3643.6, 3643.6,\n -0.2745050, 0.4919910, -1.320e-05, -5.660e-06,\n -0.5924850, -0.1352328, -2.880e-05, 1.490e-06,\n 10.2361298, -0.0140550, -2.000e-06,\n 44.1786919, 15.0043354, 0.000e-00,\n 0.5641460, 0.0000651, -9.900e-06,\n 0.0179190, 0.0000647, -9.800e-06,\n 0.0046151, 0.0045921,\n// 2892 2 19\n2777391.024203, 13.0, -4.0, 4.0, 3647.0, 3647.0,\n 0.2362380, 0.5479601, -1.650e-05, -8.600e-06,\n 0.0366200, 0.1461484, 7.580e-05, -2.210e-06,\n -11.1466198, 0.0145100, 2.000e-06,\n 11.9792700, 15.0021553, 0.000e-00,\n 0.5445510, -0.0001088, -1.240e-05,\n -0.0015790, -0.0001083, -1.240e-05,\n 0.0047412, 0.0047176,\n// 2892 8 13\n2777567.329982, 20.0, -4.0, 4.0, 3650.3, 3650.3,\n 0.0743650, 0.5229616, -3.890e-05, -6.970e-06,\n 0.1274020, -0.1230708, -8.240e-05, 1.570e-06,\n 13.8635702, -0.0126500, -3.000e-06,\n 118.4669037, 15.0035028, 0.000e-00,\n 0.5510490, 0.0001173, -1.090e-05,\n 0.0048870, 0.0001167, -1.080e-05,\n 0.0046076, 0.0045846,\n// 2893 2 7\n2777745.454805, 23.0, -4.0, 4.0, 3653.6, 3653.6,\n 0.2083270, 0.5209363, -1.300e-05, -6.850e-06,\n -0.7259340, 0.1162843, 1.326e-04, -1.440e-06,\n -14.8096800, 0.0129540, 3.000e-06,\n 161.9433441, 15.0007868, 0.000e-00,\n 0.5601490, -0.0001219, -1.100e-05,\n 0.0139420, -0.0001213, -1.100e-05,\n 0.0047485, 0.0047248,\n// 2893 8 3\n2777921.830151, 8.0, -4.0, 4.0, 3656.9, 3656.9,\n 0.2064790, 0.5599991, -4.460e-05, -8.860e-06,\n 0.8641800, -0.1051300, -1.527e-04, 1.600e-06,\n 16.9738503, -0.0108750, -4.000e-06,\n 298.0339661, 15.0025072, 0.000e-00,\n 0.5364760, 0.0000911, -1.220e-05,\n -0.0096130, 0.0000907, -1.210e-05,\n 0.0046026, 0.0045797,\n// 2893 12 29\n2778069.779206, 7.0, -4.0, 4.0, 3659.7, 3659.7,\n 0.2069500, 0.5021477, -1.800e-06, -5.550e-06,\n 1.5641410, -0.0181113, 9.190e-05, 2.900e-07,\n -23.0769005, 0.0026270, 6.000e-06,\n 284.9284058, 14.9964590, 0.000e-00,\n 0.5751450, -0.0000045, -9.900e-06,\n 0.0288630, -0.0000044, -9.800e-06,\n 0.0047496, 0.0047259,\n// 2894 1 28\n2778099.578285, 2.0, -4.0, 4.0, 3660.2, 3660.2,\n 0.3050730, 0.5004450, -2.290e-05, -5.690e-06,\n -1.4561200, 0.0834735, 1.737e-04, -8.700e-07,\n -18.0530109, 0.0107820, 4.000e-06,\n 207.2822876, 14.9992733, 0.000e-00,\n 0.5732840, -0.0000571, -1.000e-05,\n 0.0270110, -0.0000568, -1.000e-05,\n 0.0047530, 0.0047293,\n// 2894 6 24\n2778247.242529, 18.0, -4.0, 4.0, 3663.0, 3663.0,\n 0.1621230, 0.5793319, 9.400e-06, -9.700e-06,\n -0.9042130, 0.0370033, -1.161e-04, -7.300e-07,\n 23.2500000, -0.0014220, -6.000e-06,\n 88.8512115, 14.9991999, 0.000e-00,\n 0.5319680, -0.0000542, -1.270e-05,\n -0.0140990, -0.0000540, -1.260e-05,\n 0.0046065, 0.0045836,\n// 2894 12 18\n2778423.784360, 7.0, -4.0, 4.0, 3666.3, 3666.3,\n 0.1970710, 0.5133793, -2.700e-06, -6.150e-06,\n 0.8522470, -0.0636056, 1.223e-04, 8.800e-07,\n -23.2847195, -0.0008820, 6.000e-06,\n 286.2648315, 14.9964724, 0.000e-00,\n 0.5675700, 0.0000927, -1.040e-05,\n 0.0213260, 0.0000922, -1.030e-05,\n 0.0047427, 0.0047191,\n// 2895 6 14\n2778601.865170, 9.0, -4.0, 4.0, 3669.7, 3669.7,\n 0.1552950, 0.5496435, 3.280e-05, -8.050e-06,\n -0.1607120, 0.0785054, -1.501e-04, -1.280e-06,\n 23.2009296, 0.0015270, -6.000e-06,\n 314.4514771, 14.9990339, 0.000e-00,\n 0.5432270, -0.0001223, -1.160e-05,\n -0.0028960, -0.0001217, -1.160e-05,\n 0.0046134, 0.0045905,\n// 2895 12 7\n2778778.060677, 13.0, -4.0, 4.0, 3673.0, 3673.0,\n -0.2191690, 0.5388891, 2.420e-05, -7.720e-06,\n 0.1792190, -0.1127278, 1.514e-04, 1.760e-06,\n -22.5509205, -0.0042080, 6.000e-06,\n 17.4854298, 14.9971924, 0.000e-00,\n 0.5514840, 0.0001322, -1.170e-05,\n 0.0053190, 0.0001315, -1.160e-05,\n 0.0047332, 0.0047096,\n// 2896 6 2\n2778956.221700, 17.0, -4.0, 4.0, 3676.3, 3676.3,\n -0.2952220, 0.5100459, 5.790e-05, -6.240e-06,\n 0.5563290, 0.1133621, -1.635e-04, -1.530e-06,\n 22.3453197, 0.0045220, -5.000e-06,\n 75.0377731, 14.9993019, 0.000e-00,\n 0.5588240, -0.0000954, -1.030e-05,\n 0.0126230, -0.0000949, -1.030e-05,\n 0.0046229, 0.0045999,\n// 2896 11 26\n2779132.616892, 3.0, -4.0, 4.0, 3679.7, 3679.7,\n -0.0477360, 0.5560089, 3.730e-05, -9.190e-06,\n -0.5737970, -0.1596687, 1.824e-04, 2.810e-06,\n -21.0037708, -0.0071560, 5.000e-06,\n 228.4282532, 14.9983816, 0.000e-00,\n 0.5387920, 0.0000549, -1.290e-05,\n -0.0073090, 0.0000547, -1.280e-05,\n 0.0047221, 0.0046986,\n// 2897 4 23\n2779280.613389, 3.0, -4.0, 4.0, 3682.4, 3682.4,\n 0.7843140, 0.4583438, -3.400e-06, -5.090e-06,\n -1.3371930, 0.2153819, -1.670e-05, -2.560e-06,\n 12.8291101, 0.0132490, -3.000e-06,\n 225.3743744, 15.0026503, 0.000e-00,\n 0.5689210, 0.0000308, -9.800e-06,\n 0.0226690, 0.0000307, -9.800e-06,\n 0.0046700, 0.0046468,\n// 2897 5 22\n2779310.295794, 19.0, -4.0, 4.0, 3683.0, 3683.0,\n -0.4424770, 0.4843397, 5.600e-05, -5.390e-06,\n 1.3052390, 0.1448340, -1.733e-04, -1.750e-06,\n 20.6597309, 0.0073930, -5.000e-06,\n 105.4804688, 15.0000124, 0.000e-00,\n 0.5676820, -0.0000133, -9.700e-06,\n 0.0214370, -0.0000132, -9.700e-06,\n 0.0046342, 0.0046111,\n// 2897 10 17\n2779457.892717, 9.0, -4.0, 4.0, 3685.8, 3685.8,\n 0.4117200, 0.5089632, 1.620e-05, -8.010e-06,\n 1.3514680, -0.2573890, -2.140e-05, 4.220e-06,\n -9.6619396, -0.0142970, 2.000e-06,\n 318.7039185, 15.0035658, 0.000e-00,\n 0.5395920, -0.0000754, -1.240e-05,\n -0.0065130, -0.0000751, -1.230e-05,\n 0.0046722, 0.0046489,\n// 2897 11 15\n2779487.287498, 19.0, -4.0, 4.0, 3686.3, 3686.3,\n -0.3603690, 0.5471681, 7.230e-05, -9.130e-06,\n -1.1852610, -0.1947959, 1.927e-04, 3.450e-06,\n -18.7436600, -0.0097040, 4.000e-06,\n 109.0281372, 14.9997969, 0.000e-00,\n 0.5371870, -0.0000456, -1.290e-05,\n -0.0089060, -0.0000453, -1.290e-05,\n 0.0047099, 0.0046864,\n// 2898 4 12\n2779634.730343, 6.0, -4.0, 4.0, 3689.1, 3689.1,\n 0.5794910, 0.4710681, -1.480e-05, -5.950e-06,\n -0.5789710, 0.2426642, -2.780e-05, -3.250e-06,\n 8.9538498, 0.0146010, -2.000e-06,\n 269.8597717, 15.0034418, 0.000e-00,\n 0.5585170, 0.0000997, -1.070e-05,\n 0.0123170, 0.0000993, -1.070e-05,\n 0.0046844, 0.0046610,\n// 2898 10 6\n2779812.384500, 21.0, -4.0, 4.0, 3692.4, 3692.4,\n 0.2314660, 0.4738902, 2.060e-05, -6.270e-06,\n 0.6879110, -0.2555227, -8.000e-06, 3.550e-06,\n -5.7053099, -0.0150860, 1.000e-06,\n 137.9710083, 15.0044098, 0.000e-00,\n 0.5531980, -0.0001110, -1.100e-05,\n 0.0070260, -0.0001104, -1.100e-05,\n 0.0046587, 0.0046355,\n// 2899 4 1\n2779989.142066, 15.0, -4.0, 4.0, 3695.8, 3695.8,\n -0.1926490, 0.4950984, 9.500e-06, -7.510e-06,\n -0.1288300, 0.2690173, -2.680e-05, -4.280e-06,\n 4.8632698, 0.0154400, -1.000e-06,\n 44.1973915, 15.0039272, 0.000e-00,\n 0.5439580, 0.0001115, -1.220e-05,\n -0.0021690, 0.0001110, -1.210e-05,\n 0.0046980, 0.0046746,\n// 2899 9 26\n2780166.580165, 2.0, -4.0, 4.0, 3699.1, 3699.1,\n 0.0221610, 0.4465626, 1.160e-05, -5.060e-06,\n -0.0401110, -0.2478603, 5.400e-06, 2.980e-06,\n -1.4936600, -0.0154220, 0.000e-00,\n 212.0224152, 15.0049009, 0.000e-00,\n 0.5656450, -0.0000617, -9.900e-06,\n 0.0194110, -0.0000614, -9.900e-06,\n 0.0046457, 0.0046226,\n// 2900 3 22\n2780343.771433, 7.0, -4.0, 4.0, 3702.5, 3702.5,\n -0.0772340, 0.5100751, 6.200e-06, -8.560e-06,\n 0.7246580, 0.2819556, -4.620e-05, -4.940e-06,\n 0.7159800, 0.0158140, 0.000e-00,\n 283.4902649, 15.0040188, 0.000e-00,\n 0.5363230, 0.0000047, -1.300e-05,\n -0.0097660, 0.0000047, -1.300e-05,\n 0.0047108, 0.0046873,\n// 2900 9 15\n2780520.590084, 2.0, -4.0, 4.0, 3705.8, 3705.8,\n -0.4430940, 0.4438795, 4.000e-06, -4.930e-06,\n -0.6333330, -0.2448203, 1.390e-05, 2.880e-06,\n 2.8187001, -0.0152690, -1.000e-06,\n 210.9624176, 15.0050287, 0.000e-00,\n 0.5667980, 0.0000442, -9.800e-06,\n 0.0205570, 0.0000440, -9.700e-06,\n 0.0046332, 0.0046101\n));\n}", "title": "" }, { "docid": "7ed82161de6af3f37381f9b2895873ec", "score": "0.5206486", "text": "function monte_carlo(n)\r\n{\r\n let count = 0;\r\n\r\n for(let i = 0; i < n; i++)\r\n {\r\n // Generates a random point in the range [-1, 1].\r\n let rand_x = (Math.random() * 2) - 1;\r\n let rand_y = (Math.random() * 2) - 1;\r\n\r\n // console.log(rand_x);\r\n // console.log(rand_y);\r\n\r\n if((rand_x * rand_x) + (rand_y * rand_y) < 1)\r\n {\r\n count = count + 1;\r\n }\r\n }\r\n\r\n return (count / n) * 4;\r\n}", "title": "" }, { "docid": "c12ea40a3a77c23d4d5d7d5aba094552", "score": "0.5205998", "text": "_loopIndex(t) {\n let i, tt;\n if (t > 1)\n t = 1;\n if (t < 0)\n t = 0;\n if (t != 1) {\n tt = t * this._point_cnt; // Find the starting point for a curve.\n i = tt | 0; // Curve index by stripping out the decimal, BitwiseOR 0 same op as Floor\n tt -= i; // Strip out the whole number to get the decimal norm to be used for the curve ( FRACT )\n }\n else {\n i = this._point_cnt - 1; // Use the last point as the starting point\n tt = 1;\n }\n const ia = Maths.mod(i - 1, this._point_cnt); // Get Previous Point as Starting Tangent\n const ic = Maths.mod(i + 1, this._point_cnt); // Get Next point is the end point of the curve\n const id = Maths.mod(i + 2, this._point_cnt); // The the following point as the Ending Tangent\n this._precalcParams(tt, i, ic);\n return [ia, i, ic, id];\n }", "title": "" }, { "docid": "1d27534da207940bb290f43cd87d631b", "score": "0.5203029", "text": "function generatePair(seed) {\n return 2 * ((seed.w2 >> 8) & 31);\n}", "title": "" }, { "docid": "0da8bc07bce8c9fa65ce6edff9df6e6d", "score": "0.52005345", "text": "function p(x, y) {\n var xf = Math.floor(x);\n var yf = Math.floor(y);\n \n return i(i(n(xf, yf), n(xf + 1, yf), x - xf), i(n(xf, yf + 1), n(xf + 1, yf + 1), x - xf), y - yf);\n}", "title": "" }, { "docid": "e0bbaac2768d4129deac39b45e648c8e", "score": "0.519768", "text": "function calculateAdjacent(degree, hypotenuse) {\n return Math.cos(degree * RAD) * hypotenuse;\n}", "title": "" }, { "docid": "ab0f53e752a82a89cf2e7f21693de9e7", "score": "0.5196029", "text": "function pythagoreanTripletSum(n) {\n for (var i = 1; i < n; i++) {\n for (var j = 1; j < n; j++) {\n for (var k = 1; k < n; k++ ) {\n if (isPythagoreanTriplet(i, j, k)) {\n if (i + j + k === n) {\n return i * j * k;\n }\n }\n }\n }\n }\n}", "title": "" }, { "docid": "d0532e3b04b1d71526a3af13f3e0c0d7", "score": "0.5186103", "text": "function nextTriangle(n) {\r\n\r\n var c;\r\n\r\n if (n <= 20) {\r\n\r\n if (n <= 10) {\r\n c = 0;\r\n } else {\r\n c = 1;\r\n }\r\n\r\n var k;\r\n k = n - 10 * c;\r\n\r\n if (k <= 8) {\r\n a = k % 2 + 2 * ((k - 1) % 2);\r\n b = (k - 1 - (k + 1) % 2) / 2 + 1;\r\n\r\n return [a, b, c];\r\n\r\n } else {\r\n a = 3;\r\n b = 2 * (k - 8) - (c + 1) % 2;\r\n\r\n return [a, b, c];\r\n }\r\n\r\n } else {\r\n\r\n c = 2;\r\n\r\n\r\n if ((24 - n) < 2) {\r\n a = 1;\r\n b = 24 - n + 1;\r\n } else {\r\n a = 2;\r\n b = 24 - n - 1;\r\n }\r\n\r\n return [a, b, c];\r\n }\r\n\r\n}", "title": "" }, { "docid": "f2acd88ca65ff9aa15feb87f809b001e", "score": "0.5181466", "text": "function getPythagoreanTriplet(limit){\n\tlet k=0;\n\tfor( let i=1; i<=limit ; i++ )\n\t\tfor( let j=i+1; j<=limit ; j++, k=limit-i-j)\n\t\t\tif( (i*i + j*j)===k*k ) \n\t\t\t\treturn (i*j*k);\n\t\n\treturn \"not found!\";\n}", "title": "" }, { "docid": "a343332ea8272aa2c5f30dff879ca9f2", "score": "0.5179321", "text": "function arithmaticPairOfThree(nums) {\n let length = nums.length;\n \n for (let i = 1; i < length - 1; i++) {\n let j = i - 1,\n k = i + 1;\n \n while (j >= 0 && k <= length - 1) {\n let sum = nums[j] + nums[k];\n if (sum === nums[i] * 2) return true;\n sum < nums[i] * 2 ? k++ : j--;\n }\n }\n \n return false;\n}", "title": "" }, { "docid": "604f6e49e238d27e2cd5a1874cc9fac9", "score": "0.51719517", "text": "addPoints() {\n\tfor(var i = 0; i < arguments.length; i+=2) {\n\t\tthis.addPoint(arguments[i], arguments[i+1]);\n\t}\n }", "title": "" }, { "docid": "f8c7f870f1760898fd992741d6b84f32", "score": "0.5155861", "text": "function relativelyPrime(x,y){\r\n var bool = true;\r\n var valsX = [];\r\n var valsY = [];\r\n var i = 0;\r\n var j = 0;\r\n var k = 0;\r\n var l = 0;\r\n \r\n //multiple check starts at 2\r\n for(i=2; i<y; i++){\r\n //multiple of y found\r\n if(y % i === 0){\r\n //store multiples of y in an array\r\n valsY[j] = i;\r\n j++;\r\n }\r\n }\r\n\r\n for(k=2; k<x; k++){\r\n if(x % k === 0){\r\n valsX[l] = k;//store mutliples of x in an array\r\n l++;\r\n } \r\n }\r\n \r\n if(x > y){\r\n if(x % y === 0){\r\n bool = false;\r\n }\r\n for(i=0; i<valsY.length; i++){\r\n for(j=0; j<valsX.length; j++){\r\n if(valsY.length > 0 && valsX.length > 0){\r\n if(valsY[i] === valsX[j]){\r\n bool = false;// if x and y share a multiple, return false\r\n }\r\n }\r\n }\r\n }\r\n }\r\n \r\n else if(y > x){\r\n if(y % x === 0){\r\n bool = false;\r\n }\r\n for(i=0; i<valsX.length; i++){\r\n for(j=0; j<valsY.length; j++){\r\n if(valsY.length > 0 && valsX.length > 0){\r\n if(valsX[i] === valsY[j]){\r\n bool = false; //if x and y share a multiple, return false\r\n }\r\n }\r\n }\r\n }\r\n }\r\n \r\n return bool;\r\n}", "title": "" }, { "docid": "ef2695d64408b1f77a9093f560f6fc04", "score": "0.5155403", "text": "function NurbsGenPointsFastUnweightedUniformCurve3(cps, num, out) {\n var np = cps.length >> 1;\n var a = 3, b = np, step = (b - a) / num;\n\n var p = 0;\n for (var j = 0, u = a; j < num; ++j, u += step) {\n var num_x = 0, num_y = 0, den = 0;\n for (var i = (u - 3) >> 0, k = 0; k < 4 && i < np; ++k, ++i) {\n var i1 = i+1, i2 = i1+1, i3 = i2+1, i4 = i3+1;\n var v = ((u - (i)) /3) * (((u - (i)) /2) * (((u - (i)) ) * (i <= u && u < i1 ? 1 : 0) + ((i2 - u) ) * (i1 <= u && u < i2 ? 1 : 0)) + ((i3 - u) /2) * (((u - (i1)) ) * (i1 <= u && u < i2 ? 1 : 0) + ((i3 - u) ) * (i2 <= u && u < i3 ? 1 : 0))) + ((i4 - u) /3) * (((u - (i1)) /2) * (((u - (i1)) ) * (i1 <= u && u < i2 ? 1 : 0) + ((i3 - u) ) * (i2 <= u && u < i3 ? 1 : 0)) + ((i4 - u) /2) * (((u - (i2)) ) * (i2 <= u && u < i3 ? 1 : 0) + ((i4 - u) ) * (i3 <= u && u < i4 ? 1 : 0)));\n num_x += v * cps[i*2];\n num_y += v * cps[i*2+1];\n den += v;\n }\n out[p++] = num_x/den;\n out[p++] = num_y/den;\n }\n return p;\n}", "title": "" }, { "docid": "d98146ff541ce5380990ab5a0f879386", "score": "0.5140065", "text": "function h({coords:t,lengths:e}){let r=0;for(const s of e){for(let e=1;e<s;e++)t[2*(r+e)]+=t[2*(r+e)-2],t[2*(r+e)+1]+=t[2*(r+e)-1];r+=s;}}", "title": "" }, { "docid": "bea5a8a23fc0e971aa46f77104455ff6", "score": "0.51378596", "text": "function ex2_newton(){\n let u_n = u0;\n let u_n1 = u0;\n let u_mikro = 0.;\n\n let ta = []; //accepts t\n let ya = []; //accepts u_n1\n let yb = []; //accepts N - u_n1\n\n ta.push(0.);\n ya.push(u_n1);\n yb.push(N - u_n1);\n\n for(let t = 0.1; t < 100.; t += dt){\n let iteracja_mi = 0;\n u_n = u_n1;\n u_mikro = 0.;\n\n while(1){\n\n if((Math.abs(u_n1-u_mikro) < TOL) || iteracja_mi++ > iteracje_max){\n break;\n }\n\n u_mikro = u_n1;\n u_n1 = u_mikro - (u_mikro - u_n - (dt / 2.) * (f(u_n) + f(u_mikro))) / (1 - (dt / 2.) * df(u_mikro));\n }\n\n ta.push(t);\n ya.push(u_n1);\n yb.push(N - u_n1);\n }\n\n /* We return an object, containing our 3 arrays */\n return {\n t: ta,\n y: ya,\n y2: yb\n }\n}", "title": "" }, { "docid": "8c21bf18678b559c677c535c052e8b2f", "score": "0.51244587", "text": "function h({coords:t,lengths:e}){let r=0;for(const s of e){for(let e=1;e<s;e++)t[2*(r+e)]+=t[2*(r+e)-2],t[2*(r+e)+1]+=t[2*(r+e)-1];r+=s}}", "title": "" }, { "docid": "b77dd18bca9f77718bb881a9b08b2e42", "score": "0.5123515", "text": "function squareProducts(n, callback) {\n for (var i = 1; i * i < n; i++) {\n for (var j = i+1; j * j <= n; j++) {\n if (relativelyPrime(i,j)) {\n var lowerBase = Math.pow(i,2);\n var upperBase = Math.pow(j,2);\n var multiplier = 1;\n while (upperBase * multiplier <= n) {\n callback(lowerBase*multiplier, upperBase*multiplier);\n multiplier ++;\n }\n }\n }\n }\n}", "title": "" }, { "docid": "c3685d664a2c3811d25b0b1368f40e88", "score": "0.5123204", "text": "function euler1()\n{\n\tvar sum = 0;\n\tfor(var i = 1; i < 1000; i++)\n\t{\n\t\tif(i%5 === 0 || i%3 === 0)\n\t\t{\n\t\t\tsum+=i;\n\t\t}\n\t}\n\treturn sum;\t\t//233168\n}", "title": "" }, { "docid": "f7e8a1290198ff83234a0a7c6d46be98", "score": "0.51187897", "text": "function generator(times, xmin, xmax, ymin, ymax)\n{\nvar points = new Array();\nxmin = xmin * 1000000;\nxmax = xmax * 1000000;\n\n//let's hard written this part temporarily.\nymin = ymin * -1000000;\nymax = ymax * -1000000;\n\nvar i = 0;\nfor (i = 0; i < times; i++)\n{\n var x = randomIntFromInterval(xmin, xmax);\n x = x / parseFloat(1000000);\n\n var y = randomIntFromInterval(ymin, ymax);\n y = y / parseFloat(-1000000);\n\n points[i] = new coordinate(i,x,y);\n}\nreturn points;\n}", "title": "" }, { "docid": "19f11cdd6ab3895903629bd74e1e6931", "score": "0.51181185", "text": "function pair_with_target_sum(arr, targetSum) {\n\nlet left = 0,\nright = arr.length - 1;\nconsole.log(right)\nwhile (left < right) {\nconst currentSum = arr[left] + arr[right];\nif (currentSum === targetSum) {\n return [left, right];\n}\n\nif (targetSum > currentSum) {\n left += 1; // we need a pair with a bigger sum\n} else {\n right -= 1; // we need a pair with a smaller sum\n}\n}\nreturn [-1, -1];\n\n}", "title": "" }, { "docid": "2418955c7c8966a98e9fced5bc9c2578", "score": "0.5112236", "text": "function generatePointData(){\r\n\tvar totalPoints = 0;\r\n\t\r\n\tvar mealSections = _getMealSections();\r\n\tfor (var i = 0; i < mealSections.length; i++){\r\n\t\ttotalPoints += _generatePointsForSection(mealSections[i]);\r\n\t}\r\n\t\t\r\n\treturn totalPoints;\r\n}", "title": "" }, { "docid": "19778e1f18569f4420d15f4c3b656346", "score": "0.5095775", "text": "function LE2401() {\n calculatefor(new Array(\n \" 2401 to 2500\",\n// 2401 6 26\n2598183.958214, 11.0, 1059.4, \" 2.107\", \" 1.139\", 1,\n 5.31800, 0.99489, 0.27108,\n -2.64605, -1.66349, -0.45826, -0.00287, 0.45186, 1.65685, 2.64111,\n 275.7906624, 0.65205, -6.390e-04,\n -23.6776294, 0.07927, 1.335e-03,\n// 2401 12 21\n2598361.580633, 2.0, 1061.2, \" 2.666\", \" 1.571\", 1,\n 7.98970, 0.90739, 0.24724,\n -3.17650, -1.99307, -0.89697, -0.06481, 0.76756, 1.86379, 3.04579,\n 89.1535098, 0.54575, -6.900e-05,\n 23.4995595, -0.04342, -9.590e-04,\n// 2402 6 16\n2598538.636795, 3.0, 1063.0, \" 2.193\", \" 1.251\", 1,\n 20.62308, 1.02311, 0.27877,\n -2.29233, -1.37698, -0.29492, 0.28309, 0.86103, 1.94309, 2.85867,\n 264.5150856, 0.68992, -2.080e-04,\n -22.9546795, 0.03453, 1.490e-03,\n// 2402 12 10\n2598715.544757, 1.0, 1064.8, \" 1.892\", \" 0.794\", 2,\n 6.24825, 0.90306, 0.24606,\n -2.86873, -1.54344, 0.00000, 0.07418, 0.00000, 1.69118, 3.01755,\n 76.6261643, 0.53787, -7.700e-05,\n 22.3215910, -0.00003, -8.870e-04,\n// 2403 5 7\n2598863.971983, 11.0, 1066.3, \" 0.093\", \"-0.895\", 3,\n 2.00068, 0.98224, 0.26764,\n -0.37791, 0.00000, 0.00000, 0.32760, 0.00000, 0.00000, 1.03798,\n 223.7718324, 0.60570, 6.620e-04,\n -18.2074299, -0.11821, 9.020e-04,\n// 2403 6 5\n2598893.336902, 20.0, 1066.6, \" 0.841\", \"-0.119\", 3,\n 12.93091, 1.00552, 0.27398,\n -1.83365, 0.00000, 0.00000, 0.08565, 0.00000, 0.00000, 2.00624,\n 253.7518276, 0.66067, 2.670e-04,\n -21.4552498, -0.01303, 1.292e-03,\n// 2403 11 29\n2599069.642865, 3.0, 1068.4, \" 0.656\", \"-0.397\", 3,\n 7.51500, 0.93983, 0.25608,\n -1.46122, 0.00000, 0.00000, 0.42876, 0.00000, 0.00000, 2.31602,\n 64.4447814, 0.57219, -6.500e-05,\n 20.1800893, 0.04424, -9.420e-04,\n// 2404 4 25\n2599218.349247, 20.0, 1070.0, \" 1.367\", \" 0.320\", 2,\n 10.28660, 0.93007, 0.25342,\n -2.16898, -0.69366, 0.00000, 0.38193, 0.00000, 1.46012, 2.93334,\n 213.4427149, 0.52761, 4.950e-04,\n -14.2333800, -0.12867, 5.320e-04,\n// 2404 10 19\n2599394.621730, 3.0, 1071.8, \" 1.307\", \" 0.340\", 2,\n 4.87070, 1.01383, 0.27624,\n -2.33997, -1.09737, 0.00000, -0.07849, 0.00000, 0.93905, 2.18317,\n 24.1010704, 0.61189, 2.040e-04,\n 10.9143597, 0.17253, -6.510e-04,\n// 2405 4 14\n2599572.430948, 22.0, 1073.6, \" 2.711\", \" 1.626\", 1,\n 11.55336, 0.90048, 0.24536,\n -2.78694, -1.60971, -0.51514, 0.34276, 1.20075, 2.29541, 3.47204,\n 203.1678427, 0.48215, 2.360e-04,\n -9.7712097, -0.13716, 3.290e-04,\n// 2405 10 8\n2599749.305511, 19.0, 1075.4, \" 2.591\", \" 1.634\", 1,\n 20.17578, 1.02110, 0.27822,\n -2.31842, -1.41541, -0.45979, 0.33227, 1.12443, 2.08015, 2.98264,\n 14.2794103, 0.60870, 3.060e-04,\n 6.2559099, 0.18870, -3.240e-04,\n// 2406 4 3\n2599926.437151, 22.0, 1077.2, \" 1.766\", \" 0.692\", 2,\n 10.81464, 0.91308, 0.24879,\n -2.34509, -1.03022, 0.00000, 0.49162, 0.00000, 2.01216, 3.32845,\n 192.9278865, 0.48696, -1.500e-05,\n -4.9442399, -0.15293, 2.170e-04,\n// 2406 9 28\n2600103.926409, 10.0, 1079.0, \" 1.753\", \" 0.763\", 2,\n 10.47813, 0.98401, 0.26812,\n -2.33705, -1.23351, 0.00000, 0.23380, 0.00000, 1.70251, 2.80376,\n 4.9498902, 0.56076, 2.770e-04,\n 1.5114100, 0.18258, 3.000e-06,\n// 2407 2 22\n2600251.150785, 16.0, 1080.5, \" 0.183\", \"-0.819\", 3,\n 2.15390, 0.98819, 0.26926,\n -1.36347, 0.00000, 0.00000, -0.38115, 0.00000, 0.00000, 0.59701,\n 155.3161248, 0.57796, -4.850e-04,\n 8.7193802, -0.16461, -3.700e-04,\n// 2407 3 24\n2600280.663764, 4.0, 1080.8, \" 0.497\", \"-0.527\", 3,\n 16.09234, 0.95996, 0.26157,\n -1.69477, 0.00000, 0.00000, -0.06966, 0.00000, 0.00000, 1.55169,\n 183.3413882, 0.53350, -2.270e-04,\n -0.0941700, -0.17566, 7.900e-05,\n// 2407 8 19\n2600428.729387, 6.0, 1082.3, \" 0.294\", \"-0.766\", 3,\n 3.82288, 0.91142, 0.24834,\n -1.84382, 0.00000, 0.00000, -0.49470, 0.00000, 0.00000, 0.85743,\n 328.3420286, 0.50021, -1.020e-04,\n -11.4476993, 0.12799, 4.560e-04,\n// 2407 9 17\n2600458.307901, 19.0, 1082.6, \" 0.316\", \"-0.727\", 3,\n 18.76405, 0.93153, 0.25382,\n -0.97024, 0.00000, 0.00000, 0.38961, 0.00000, 0.00000, 1.75322,\n 355.3803433, 0.50342, 1.000e-04,\n -3.3852300, 0.16519, 1.920e-04,\n// 2408 2 12\n2600605.753187, 6.0, 1084.2, \" 1.470\", \" 0.501\", 2,\n 15.45352, 1.02301, 0.27874,\n -2.25849, -1.11937, 0.00000, 0.07650, 0.00000, 1.27196, 2.41179,\n 144.9230631, 0.63477, -4.580e-04,\n 13.1452907, -0.15084, -7.620e-04,\n// 2408 8 7\n2600782.759003, 6.0, 1086.0, \" 1.644\", \" 0.574\", 2,\n 3.08416, 0.90110, 0.24553,\n -2.59675, -1.21598, 0.00000, 0.21608, 0.00000, 1.64769, 3.02933,\n 317.6542305, 0.50321, -2.950e-04,\n -15.5906205, 0.10128, 5.620e-04,\n// 2409 1 31\n2600960.406001, 22.0, 1087.8, \" 2.697\", \" 1.715\", 1,\n 6.75860, 1.01162, 0.27564,\n -2.95780, -2.02275, -1.06638, -0.25597, 0.55463, 1.51116, 2.44492,\n 134.6673018, 0.63943, -2.310e-04,\n 17.0229710, -0.11777, -1.030e-03,\n// 2409 7 27\n2601136.874363, 9.0, 1089.6, \" 2.694\", \" 1.661\", 1,\n 5.35365, 0.93211, 0.25398,\n -2.98713, -1.91479, -0.86736, -0.01529, 0.83645, 1.88363, 2.95825,\n 307.1628960, 0.55430, -4.740e-04,\n -19.1087297, 0.07911, 8.000e-04,\n// 2410 1 21\n2601314.914436, 10.0, 1091.5, \" 1.725\", \" 0.693\", 2,\n 18.05274, 0.96325, 0.26246,\n -2.69580, -1.49617, 0.00000, -0.05355, 0.00000, 1.39085, 2.58790,\n 123.4712284, 0.59864, -2.700e-05,\n 20.4530800, -0.07284, -1.056e-03,\n// 2410 7 16\n2601491.281919, 19.0, 1093.3, \" 1.283\", \" 0.305\", 2,\n 14.64231, 0.98412, 0.26815,\n -2.55274, -1.23258, 0.00000, -0.23395, 0.00000, 0.76212, 2.08424,\n 296.5902823, 0.63343, -4.910e-04,\n -22.0021089, 0.05164, 1.196e-03,\n// 2411 1 10\n2601669.130725, 15.0, 1095.1, \" 0.393\", \"-0.695\", 3,\n 22.32771, 0.91482, 0.24927,\n -1.41314, 0.00000, 0.00000, 0.13741, 0.00000, 0.00000, 1.69072,\n 111.5292301, 0.55445, 3.200e-05,\n 23.1654489, -0.02892, -9.790e-04,\n// 2411 6 7\n2601816.651238, 4.0, 1096.6, \" 1.087\", \" 0.143\", 2,\n 21.02264, 1.02293, 0.27872,\n -2.45389, -1.04374, 0.00000, -0.37028, 0.00000, 0.30358, 1.71317,\n 255.6625594, 0.67270, 6.000e-04,\n -21.7822895, -0.11963, 1.353e-03,\n// 2411 7 6\n2601845.932427, 10.0, 1096.9, \" 0.003\", \"-0.940\", 3,\n 4.94466, 1.02053, 0.27807,\n 0.26063, 0.00000, 0.00000, 0.37826, 0.00000, 0.00000, 0.49432,\n 285.3495394, 0.69398, -1.500e-04,\n -24.1899107, 0.01098, 1.571e-03,\n// 2411 11 30\n2601993.328034, 20.0, 1098.5, \" 1.109\", \" 0.021\", 2,\n 0.63138, 0.91008, 0.24798,\n -2.56994, -0.41955, 0.00000, -0.12718, 0.00000, 0.16292, 2.31462,\n 66.7661988, 0.52387, 3.080e-04,\n 20.7818102, 0.12413, -8.230e-04,\n// 2412 5 26\n2602171.321820, 20.0, 1100.3, \" 2.421\", \" 1.448\", 1,\n 12.32773, 0.99327, 0.27064,\n -2.99236, -2.03564, -1.01127, -0.27633, 0.45900, 1.48352, 2.43826,\n 244.5961229, 0.62173, 8.900e-04,\n -21.1219809, -0.15628, 1.075e-03,\n// 2412 11 19\n2602347.510703, 0.0, 1102.1, \" 2.438\", \" 1.403\", 1,\n 3.90361, 0.95509, 0.26024,\n -2.61715, -1.55231, -0.46956, 0.25688, 0.98279, 2.06522, 3.13248,\n 54.7093508, 0.55847, 3.620e-04,\n 19.1963013, 0.17679, -9.200e-04,\n// 2413 5 16\n2602525.773338, 7.0, 1104.0, \" 1.872\", \" 0.842\", 2,\n 22.61913, 0.94105, 0.25641,\n -3.20284, -2.02682, 0.00000, -0.43990, 0.00000, 1.14866, 2.32247,\n 233.5552314, 0.54288, 8.140e-04,\n -19.7306492, -0.17483, 7.470e-04,\n// 2413 11 8\n2602701.998194, 12.0, 1105.8, \" 1.979\", \" 0.999\", 2,\n 15.19775, 1.00572, 0.27403,\n -2.63209, -1.62250, 0.00000, -0.04333, 0.00000, 1.53512, 2.54653,\n 43.6480473, 0.59725, 5.510e-04,\n 17.1177194, 0.23013, -9.480e-04,\n// 2414 5 5\n2602879.919595, 10.0, 1107.6, \" 0.460\", \"-0.615\", 3,\n 0.88862, 0.90382, 0.24627,\n -1.61345, 0.00000, 0.00000, 0.07028, 0.00000, 0.00000, 1.75580,\n 222.0866061, 0.48315, 5.740e-04,\n -17.4115695, -0.18885, 5.530e-04,\n// 2414 9 29\n2603027.294872, 19.0, 1109.2, \" 0.190\", \"-0.771\", 3,\n 19.57261, 1.01421, 0.27635,\n -0.88723, 0.00000, 0.00000, 0.07692, 0.00000, 0.00000, 1.04326,\n 6.8476002, 0.55103, 1.990e-04,\n 1.3616700, 0.29639, 9.000e-06,\n// 2414 10 29\n2603056.659616, 4.0, 1109.5, \" 0.740\", \"-0.220\", 3,\n 6.50283, 1.02408, 0.27903,\n -1.95770, 0.00000, 0.00000, -0.16921, 0.00000, 0.00000, 1.62007,\n 33.0097510, 0.59876, 7.460e-04,\n 14.5034201, 0.26532, -7.470e-04,\n// 2415 3 25\n2603204.264301, 18.0, 1111.0, \" 1.300\", \" 0.236\", 2,\n 6.20051, 0.92406, 0.25179,\n -2.19080, -0.60094, 0.00000, 0.34323, 0.00000, 1.28482, 2.87621,\n 184.6723872, 0.45783, -1.140e-04,\n -1.1321501, -0.24876, 1.180e-04,\n// 2415 9 19\n2603381.868817, 9.0, 1112.9, \" 1.444\", \" 0.441\", 2,\n 8.87222, 0.96883, 0.26398,\n -2.61648, -1.34032, 0.00000, -0.14839, 0.00000, 1.04576, 2.31917,\n 357.0714161, 0.50262, 1.290e-04,\n -2.0673600, 0.27360, 1.980e-04,\n// 2416 3 14\n2603558.573549, 2.0, 1114.7, \" 2.658\", \" 1.648\", 1,\n 13.48369, 0.97570, 0.26585,\n -3.05323, -2.05317, -1.05232, -0.23483, 0.58231, 1.58288, 2.58509,\n 174.5981040, 0.50982, -3.210e-04,\n 2.4359601, -0.27720, 2.100e-05,\n// 2416 9 7\n2603736.168435, 16.0, 1116.6, \" 2.833\", \" 1.778\", 1,\n 15.15266, 0.91929, 0.25048,\n -2.99908, -1.88645, -0.83154, 0.04243, 0.91665, 1.97175, 3.08243,\n 346.8430986, 0.45717, -5.100e-05,\n -5.6528400, 0.24211, 2.530e-04,\n// 2417 3 3\n2603913.145158, 15.0, 1118.4, \" 1.772\", \" 0.801\", 2,\n 1.78057, 1.01824, 0.27745,\n -1.99744, -0.96385, 0.00000, 0.48379, 0.00000, 1.93098, 2.96580,\n 163.9867358, 0.56167, -4.180e-04,\n 6.1937701, -0.29305, -2.390e-04,\n// 2417 8 27\n2604090.216352, 17.0, 1120.2, \" 1.557\", \" 0.482\", 2,\n 15.41668, 0.89959, 0.24512,\n -2.58243, -1.14159, 0.00000, 0.19246, 0.00000, 1.52652, 2.96797,\n 336.3599876, 0.44707, -2.850e-04,\n -9.1465505, 0.22076, 2.700e-04,\n// 2418 1 22\n2604238.351230, 20.0, 1121.8, \" 0.211\", \"-0.783\", 3,\n 4.14995, 1.00008, 0.27250,\n -0.60460, 0.00000, 0.00000, 0.42951, 0.00000, 0.00000, 1.46696,\n 125.1673830, 0.61886, -5.740e-04,\n 20.9673898, -0.19094, -1.185e-03,\n// 2418 2 21\n2604267.809999, 7.0, 1122.1, \" 0.550\", \"-0.423\", 3,\n 17.08565, 1.01861, 0.27754,\n -1.14274, 0.00000, 0.00000, 0.43998, 0.00000, 0.00000, 2.02439,\n 153.6983945, 0.57503, -3.510e-04,\n 9.5176603, -0.27630, -5.240e-04,\n// 2418 7 18\n2604414.773874, 7.0, 1123.6, \" 0.502\", \"-0.515\", 3,\n 2.74500, 0.94614, 0.25780,\n -2.07978, 0.00000, 0.00000, -0.42702, 0.00000, 0.00000, 1.22207,\n 298.5551092, 0.56537, -8.390e-04,\n -22.0143110, 0.15094, 9.070e-04,\n// 2418 8 16\n2604444.282365, 19.0, 1123.9, \" 0.223\", \"-0.824\", 3,\n 16.68344, 0.92231, 0.25131,\n -1.39148, 0.00000, 0.00000, -0.22325, 0.00000, 0.00000, 0.94124,\n 326.0027707, 0.48354, -5.480e-04,\n -12.1744297, 0.21345, 3.490e-04,\n// 2419 1 12\n2604592.787068, 7.0, 1125.5, \" 1.387\", \" 0.337\", 2,\n 14.44135, 0.94743, 0.25815,\n -2.62892, -1.19152, 0.00000, -0.11036, 0.00000, 0.97341, 2.40800,\n 113.6817642, 0.57346, -3.240e-04,\n 22.3784096, -0.13610, -1.067e-03,\n// 2419 7 7\n2604769.262068, 18.0, 1127.3, \" 1.968\", \" 1.003\", 1,\n 13.03639, 0.99768, 0.27184,\n -2.30507, -1.30505, 0.21775, 0.28963, 0.36073, 1.88324, 2.88484,\n 286.9537323, 0.64383, -8.260e-04,\n -22.9636305, 0.12496, 1.255e-03,\n// 2420 1 1\n2604946.917319, 10.0, 1129.2, \" 2.651\", \" 1.554\", 1,\n 16.71084, 0.90611, 0.24689,\n -3.10150, -1.91242, -0.81110, 0.01566, 0.84260, 1.94403, 3.13176,\n 101.2666181, 0.53678, -2.380e-04,\n 23.1084714, -0.08476, -9.240e-04,\n// 2420 6 26\n2605123.949770, 11.0, 1131.1, \" 2.326\", \" 1.385\", 1,\n 5.34422, 1.02335, 0.27884,\n -2.80494, -1.90478, -0.88872, -0.20551, 0.47769, 1.49377, 2.39409,\n 276.2364278, 0.68497, -4.540e-04,\n -22.9698698, 0.08593, 1.469e-03,\n// 2420 12 20\n2605300.877532, 9.0, 1132.9, \" 1.916\", \" 0.817\", 2,\n 14.96938, 0.90403, 0.24633,\n -2.88844, -1.57180, 0.00000, 0.06078, 0.00000, 1.69273, 3.01062,\n 88.6830669, 0.53943, -2.500e-04,\n 22.8951100, -0.04128, -9.030e-04,\n// 2421 6 16\n2605478.647754, 4.0, 1134.8, \" 0.962\", \" 0.001\", 2,\n 21.65204, 1.00304, 0.27330,\n -2.48658, -0.51350, 0.00000, -0.45389, 0.00000, -0.39161, 1.57999,\n 265.3966444, 0.66051, 4.800e-05,\n -22.2699206, 0.03572, 1.346e-03,\n// 2421 12 9\n2605654.986147, 12.0, 1136.6, \" 0.686\", \"-0.367\", 3,\n 17.23888, 0.94249, 0.25681,\n -2.25252, 0.00000, 0.00000, -0.33246, 0.00000, 0.00000, 1.58506,\n 76.6763388, 0.58279, -2.320e-04,\n 21.6739012, 0.00098, -1.017e-03,\n// 2422 5 7\n2605803.651252, 4.0, 1138.2, \" 1.258\", \" 0.210\", 2,\n 19.00774, 0.92744, 0.25270,\n -2.85389, -1.25866, 0.00000, -0.36996, 0.00000, 0.52154, 2.11469,\n 224.3907158, 0.54001, 5.000e-04,\n -17.6626694, -0.10244, 7.000e-04,\n// 2422 10 30\n2605979.965794, 11.0, 1140.1, \" 1.251\", \" 0.283\", 2,\n 13.59183, 1.01559, 0.27672,\n -2.04483, -0.75692, 0.00000, 0.17906, 0.00000, 1.11371, 2.40302,\n 34.4194918, 0.62948, 2.910e-04,\n 14.6719498, 0.15068, -8.820e-04,\n// 2423 4 26\n2606157.726217, 5.0, 1141.9, \" 2.609\", \" 1.526\", 1,\n 19.27176, 0.90004, 0.24524,\n -2.69016, -1.51034, -0.39653, 0.42920, 1.25501, 2.36890, 3.54828,\n 213.3786614, 0.49297, 2.770e-04,\n -13.5518996, -0.12000, 4.760e-04,\n// 2423 10 20\n2606334.645357, 3.0, 1143.8, \" 2.522\", \" 1.561\", 1,\n 4.89692, 1.02020, 0.27798,\n -2.16087, -1.24957, -0.28015, 0.48858, 1.25743, 2.22697, 3.13766,\n 24.3291202, 0.61849, 4.420e-04,\n 10.3181397, 0.17334, -5.600e-04,\n// 2424 4 14\n2606511.743832, 6.0, 1145.7, \" 1.849\", \" 0.781\", 2,\n 19.53577, 0.91501, 0.24932,\n -3.00999, -1.73658, 0.00000, -0.14804, 0.00000, 1.43928, 2.71423,\n 203.3110991, 0.49689, 6.100e-05,\n -9.1458000, -0.14171, 3.770e-04,\n// 2424 10 8\n2606689.251197, 18.0, 1147.5, \" 1.837\", \" 0.841\", 2,\n 19.19927, 0.98113, 0.26734,\n -2.58637, -1.49548, 0.00000, 0.02872, 0.00000, 1.55420, 2.64278,\n 14.9794398, 0.56268, 4.070e-04,\n 5.7912102, 0.17423, -2.050e-04,\n// 2425 3 5\n2606836.502254, 0.0, 1149.1, \" 0.159\", \"-0.838\", 3,\n 10.87504, 0.99075, 0.26995,\n -0.86059, 0.00000, 0.00000, 0.05410, 0.00000, 0.00000, 0.96464,\n 165.4005986, 0.57184, -3.680e-04,\n 4.6460398, -0.18005, -1.590e-04,\n// 2425 4 3\n2606865.993723, 12.0, 1149.4, \" 0.561\", \"-0.457\", 3,\n 0.81348, 0.96291, 0.26237,\n -1.85796, 0.00000, 0.00000, -0.15065, 0.00000, 0.00000, 1.55318,\n 193.4025300, 0.54022, -1.090e-04,\n -4.4088803, -0.17069, 2.680e-04,\n// 2425 8 29\n2607014.010083, 12.0, 1151.0, \" 0.157\", \"-0.906\", 3,\n 10.53854, 0.90960, 0.24784,\n -0.75939, 0.00000, 0.00000, 0.24199, 0.00000, 0.00000, 1.24656,\n 337.9342096, 0.48822, -5.400e-05,\n -7.7639102, 0.14323, 3.100e-04,\n// 2425 9 28\n2607043.609411, 3.0, 1151.3, \" 0.414\", \"-0.635\", 3,\n 3.48519, 0.92886, 0.25309,\n -1.92461, 0.00000, 0.00000, -0.37415, 0.00000, 0.00000, 1.17951,\n 5.5460701, 0.50019, 2.040e-04,\n 1.0199400, 0.16396, 2.100e-05,\n// 2426 2 22\n2607191.115882, 15.0, 1152.8, \" 1.448\", \" 0.481\", 2,\n 1.17739, 1.02356, 0.27889,\n -2.53959, -1.39352, 0.00000, -0.21883, 0.00000, 0.95555, 2.10228,\n 155.7510030, 0.62038, -3.650e-04,\n 9.2529093, -0.17525, -5.170e-04,\n// 2426 8 18\n2607368.031996, 13.0, 1154.7, \" 1.496\", \" 0.426\", 2,\n 10.80255, 0.90188, 0.24574,\n -2.96122, -1.49397, 0.00000, -0.23209, 0.00000, 1.02912, 2.49746,\n 328.0927540, 0.49133, -2.840e-04,\n -12.1577196, 0.12367, 4.190e-04,\n// 2427 2 12\n2607545.769540, 6.0, 1156.6, \" 2.682\", \" 1.699\", 1,\n 15.47974, 1.00974, 0.27513,\n -2.23725, -1.29958, -0.33994, 0.46895, 1.27805, 2.23787, 3.17416,\n 145.2387135, 0.62012, -2.090e-04,\n 13.7226398, -0.14720, -8.160e-04,\n// 2427 8 7\n2607722.158994, 16.0, 1158.5, \" 2.840\", \" 1.810\", 1,\n 13.07205, 0.93503, 0.25477,\n -3.15026, -2.08704, -1.05389, -0.18414, 0.68530, 1.71821, 2.78378,\n 317.8104233, 0.54327, -5.120e-04,\n -16.2186291, 0.10913, 6.480e-04,\n// 2428 2 1\n2607900.268362, 18.0, 1160.4, \" 1.734\", \" 0.700\", 2,\n 2.77387, 0.96044, 0.26170,\n -2.21477, -1.01185, 0.00000, 0.44070, 0.00000, 1.89499, 3.09525,\n 134.6301319, 0.57933, -9.500e-05,\n 17.6982001, -0.10667, -8.950e-04,\n// 2428 7 27\n2608076.584259, 2.0, 1162.3, \" 1.423\", \" 0.447\", 2,\n 22.36071, 0.98722, 0.26899,\n -2.37166, -1.15797, 0.00000, 0.02223, 0.00000, 1.20024, 2.41578,\n 307.3634850, 0.62315, -6.000e-04,\n -19.7489695, 0.08987, 1.042e-03,\n// 2429 1 20\n2608254.469955, 23.0, 1164.1, \" 0.404\", \"-0.685\", 3,\n 7.04884, 0.91307, 0.24879,\n -1.29530, 0.00000, 0.00000, 0.27891, 0.00000, 0.00000, 1.85565,\n 123.3067984, 0.54061, -1.000e-04,\n 21.1229184, -0.06599, -8.750e-04,\n// 2429 6 17\n2608401.966355, 11.0, 1165.7, \" 0.959\", \" 0.016\", 2,\n 4.74104, 1.02229, 0.27855,\n -1.79294, -0.03910, 0.00000, 0.19253, 0.00000, 0.42481, 2.17808,\n 266.6022548, 0.68208, 4.120e-04,\n -22.2980405, -0.07221, 1.418e-03,\n// 2429 7 16\n2608431.243921, 18.0, 1166.0, \" 0.134\", \"-0.809\", 3,\n 13.66579, 1.02147, 0.27833,\n -0.95094, 0.00000, 0.00000, -0.14590, 0.00000, 0.00000, 0.65798,\n 296.9850672, 0.68398, -3.690e-04,\n -22.5991306, 0.05883, 1.443e-03,\n// 2429 12 11\n2608578.660927, 4.0, 1167.6, \" 1.085\", \"-0.003\", 3,\n 9.35252, 0.91167, 0.24841,\n -2.55601, 0.00000, 0.00000, -0.13775, 0.00000, 0.00000, 2.27956,\n 78.6240014, 0.53934, 1.920e-04,\n 22.0770599, 0.08543, -9.050e-04,\n// 2430 6 7\n2608756.631600, 3.0, 1169.5, \" 2.295\", \" 1.320\", 1,\n 20.04613, 0.99033, 0.26984,\n -2.54489, -1.57239, -0.49449, 0.15840, 0.81180, 1.88985, 2.86031,\n 255.5731932, 0.63400, 7.650e-04,\n -22.4164008, -0.11336, 1.192e-03,\n// 2430 11 30\n2608932.855038, 9.0, 1171.4, \" 2.408\", \" 1.374\", 1,\n 13.62749, 0.95797, 0.26102,\n -3.33909, -2.27548, -1.18454, -0.47910, 0.22580, 1.31643, 2.38246,\n 66.7192686, 0.58219, 3.010e-04,\n 21.4420299, 0.13814, -1.066e-03,\n// 2431 5 27\n2609111.069134, 14.0, 1173.3, \" 1.996\", \" 0.965\", 2,\n 6.33753, 0.93804, 0.25559,\n -3.15761, -2.00806, 0.00000, -0.34079, 0.00000, 1.32784, 2.47516,\n 244.5712064, 0.55807, 7.650e-04,\n -21.8016599, -0.13951, 8.820e-04,\n// 2431 11 19\n2609287.351113, 20.0, 1175.1, \" 2.020\", \" 1.039\", 1,\n 23.91888, 1.00788, 0.27462,\n -2.16910, -1.16861, 0.18003, 0.42672, 0.67280, 2.02140, 3.02358,\n 54.6033531, 0.62310, 5.890e-04,\n 19.8573202, 0.19681, -1.141e-03,\n// 2432 5 15\n2609465.204502, 17.0, 1177.1, \" 0.580\", \"-0.493\", 3,\n 8.60702, 0.90277, 0.24599,\n -1.96323, 0.00000, 0.00000, -0.09196, 0.00000, 0.00000, 1.78073,\n 232.9730807, 0.50086, 5.880e-04,\n -20.2175905, -0.16169, 6.890e-04,\n// 2432 10 10\n2609612.628635, 3.0, 1178.6, \" 0.110\", \"-0.856\", 3,\n 4.29374, 1.01256, 0.27590,\n -0.65154, 0.00000, 0.00000, 0.08725, 0.00000, 0.00000, 0.82872,\n 16.8106597, 0.55624, 4.110e-04,\n 5.5015001, 0.28685, -1.830e-04,\n// 2432 11 8\n2609642.010579, 12.0, 1178.9, \" 0.790\", \"-0.173\", 3,\n 15.22397, 1.02381, 0.27896,\n -1.58586, 0.00000, 0.00000, 0.25389, 0.00000, 0.00000, 2.09447,\n 43.6159215, 0.62103, 8.710e-04,\n 17.7828602, 0.23726, -9.620e-04,\n// 2433 4 5\n2609789.581063, 2.0, 1180.5, \" 1.230\", \" 0.172\", 2,\n 14.92165, 0.92645, 0.25244,\n -2.52874, -0.86694, 0.00000, -0.05450, 0.00000, 0.75514, 2.41851,\n 194.8949264, 0.46530, 2.800e-05,\n -5.4441500, -0.24389, 2.620e-04,\n// 2433 9 29\n2609967.183850, 16.0, 1182.4, \" 1.345\", \" 0.335\", 2,\n 16.59062, 0.96575, 0.26314,\n -2.00769, -0.64632, 0.00000, 0.41241, 0.00000, 1.47370, 2.83226,\n 6.6305398, 0.49992, 2.970e-04,\n 1.9702601, 0.27047, 4.300e-05,\n// 2434 3 25\n2610143.912941, 10.0, 1184.3, \" 2.604\", \" 1.600\", 1,\n 22.20483, 0.97852, 0.26662,\n -2.89084, -1.89781, -0.89292, -0.08943, 0.71370, 1.71831, 2.71341,\n 184.5987987, 0.51242, -1.350e-04,\n -1.8432599, -0.27904, 1.910e-04,\n// 2434 9 18\n2610321.460127, 23.0, 1186.2, \" 2.714\", \" 1.654\", 1,\n 22.87106, 0.91704, 0.24987,\n -3.00611, -1.88131, -0.81310, 0.04304, 0.89943, 1.96779, 3.09069,\n 356.6495017, 0.45035, 7.900e-05,\n -1.5443501, 0.24571, 1.190e-04,\n// 2435 3 14\n2610498.499612, 0.0, 1188.1, \" 1.810\", \" 0.843\", 2,\n 11.50444, 1.01937, 0.27775,\n -2.49987, -1.48227, 0.00000, -0.00931, 0.00000, 1.46330, 2.48202,\n 174.4556399, 0.55538, -1.880e-04,\n 1.7713800, -0.30179, -3.000e-05,\n// 2435 9 7\n2610675.494861, 0.0, 1190.0, \" 1.696\", \" 0.619\", 2,\n 23.13508, 0.89975, 0.24516,\n -2.97246, -1.60100, 0.00000, -0.12333, 0.00000, 1.35427, 2.72648,\n 346.3772797, 0.43792, -1.760e-04,\n -5.1742901, 0.23136, 1.410e-04,\n// 2436 2 3\n2610823.714554, 5.0, 1191.6, \" 0.195\", \"-0.801\", 3,\n 13.87382, 0.99775, 0.27186,\n -0.84819, 0.00000, 0.00000, 0.14930, 0.00000, 0.00000, 1.15032,\n 136.7958893, 0.59123, -5.450e-04,\n 18.0039808, -0.22588, -9.790e-04,\n// 2436 3 3\n2610853.168907, 16.0, 1191.9, \" 0.574\", \"-0.397\", 3,\n 2.80953, 1.01717, 0.27715,\n -1.56222, 0.00000, 0.00000, 0.05377, 0.00000, 0.00000, 1.67155,\n 164.3065389, 0.56004, -1.460e-04,\n 5.3198401, -0.29143, -3.140e-04,\n// 2436 7 28\n2611000.063277, 14.0, 1193.5, \" 0.368\", \"-0.647\", 3,\n 10.46340, 0.94935, 0.25868,\n -1.90892, 0.00000, 0.00000, -0.48136, 0.00000, 0.00000, 0.94192,\n 309.5130275, 0.54917, -8.710e-04,\n -19.7537796, 0.18542, 7.590e-04,\n// 2436 8 27\n2611029.568816, 2.0, 1193.9, \" 0.362\", \"-0.683\", 3,\n 0.40184, 0.92484, 0.25200,\n -1.81379, 0.00000, 0.00000, -0.34842, 0.00000, 0.00000, 1.11378,\n 336.1152756, 0.47237, -4.500e-04,\n -8.5578300, 0.23174, 2.060e-04,\n// 2437 1 22\n2611178.137192, 15.0, 1195.4, \" 1.373\", \" 0.320\", 2,\n 23.16248, 0.94477, 0.25743,\n -2.22582, -0.76672, 0.00000, 0.29262, 0.00000, 1.35459, 2.81079,\n 125.2292645, 0.55031, -3.860e-04,\n 20.2646607, -0.17225, -9.300e-04,\n// 2437 7 18\n2611354.568063, 2.0, 1197.3, \" 1.833\", \" 0.871\", 2,\n 21.75753, 1.00035, 0.27257,\n -2.90763, -1.88391, 0.00000, -0.36648, 0.00000, 1.14974, 2.17488,\n 298.5523771, 0.62761, -9.450e-04,\n -21.3325693, 0.16971, 1.106e-03,\n// 2438 1 11\n2611532.253815, 18.0, 1199.3, \" 2.636\", \" 1.537\", 1,\n 1.43198, 0.90494, 0.24658,\n -3.02982, -1.83605, -0.72943, 0.09155, 0.91271, 2.01942, 3.21191,\n 113.2345780, 0.52148, -3.600e-04,\n 21.8085703, -0.12342, -8.400e-04,\n// 2438 7 7\n2611709.262028, 18.0, 1201.2, \" 2.460\", \" 1.520\", 1,\n 13.06262, 1.02343, 0.27886,\n -2.32977, -1.44043, -0.46586, 0.28867, 1.04320, 2.01782, 2.90721,\n 287.2153832, 0.67269, -6.360e-04,\n -22.2527802, 0.13276, 1.384e-03,\n// 2438 12 31\n2611886.212558, 17.0, 1203.1, \" 1.935\", \" 0.837\", 2,\n 23.69052, 0.90511, 0.24662,\n -2.85133, -1.54295, 0.00000, 0.10140, 0.00000, 1.74510, 3.05489,\n 100.7538690, 0.53375, -4.130e-04,\n 22.5407905, -0.08265, -8.650e-04,\n// 2439 6 27\n2612063.955533, 11.0, 1205.0, \" 1.090\", \" 0.128\", 2,\n 5.37044, 1.00045, 0.27260,\n -2.20757, -0.71708, 0.00000, -0.06721, 0.00000, 0.58517, 2.07420,\n 276.4666052, 0.65223, -1.580e-04,\n -22.2950198, 0.08213, 1.331e-03,\n// 2439 12 20\n2612240.333055, 20.0, 1206.9, \" 0.708\", \"-0.343\", 3,\n 1.96001, 0.94515, 0.25753,\n -1.94703, 0.00000, 0.00000, -0.00668, 0.00000, 0.00000, 1.93130,\n 88.4901482, 0.58679, -4.220e-04,\n 22.2581300, -0.04322, -1.035e-03,\n// 2440 5 17\n2612388.945700, 11.0, 1208.5, \" 1.134\", \" 0.086\", 2,\n 2.72614, 0.92485, 0.25200,\n -2.70074, -0.88348, 0.00000, -0.30319, 0.00000, 0.28013, 2.09533,\n 235.1793138, 0.55142, 4.470e-04,\n -20.4268214, -0.07164, 8.440e-04,\n// 2440 11 9\n2612565.316177, 20.0, 1210.4, \" 1.209\", \" 0.239\", 2,\n 23.31571, 1.01720, 0.27716,\n -2.60524, -1.27630, 0.00000, -0.41174, 0.00000, 0.45154, 1.78172,\n 45.6953999, 0.64998, 3.020e-04,\n 18.1055799, 0.11872, -1.115e-03,\n// 2441 5 6\n2612743.014875, 12.0, 1212.4, \" 2.492\", \" 1.412\", 1,\n 2.99015, 0.89973, 0.24516,\n -2.74565, -1.55957, -0.41136, 0.35699, 1.12541, 2.27369, 3.45949,\n 223.9042561, 0.50597, 2.790e-04,\n -16.9125507, -0.09690, 6.180e-04,\n// 2441 10 30\n2612919.990233, 12.0, 1214.3, \" 2.464\", \" 1.500\", 1,\n 14.62079, 1.01916, 0.27770,\n -2.88274, -1.96278, -0.97821, -0.23442, 0.50954, 1.49424, 2.41349,\n 35.2534613, 0.63328, 5.280e-04,\n 14.2162798, 0.14862, -8.070e-04,\n// 2442 4 25\n2613097.045276, 13.0, 1216.2, \" 1.945\", \" 0.882\", 2,\n 3.25417, 0.91709, 0.24988,\n -2.80142, -1.56829, 0.00000, 0.08663, 0.00000, 1.74040, 2.97521,\n 213.4276475, 0.51047, 1.050e-04,\n -12.9024493, -0.12474, 5.310e-04,\n// 2442 10 20\n2613274.580522, 2.0, 1218.1, \" 1.910\", \" 0.908\", 2,\n 3.92041, 0.97826, 0.26655,\n -2.72062, -1.63682, 0.00000, -0.06748, 0.00000, 1.50307, 2.58452,\n 25.1670495, 0.56943, 5.130e-04,\n 9.8739503, 0.15863, -4.110e-04,\n// 2443 3 16\n2613421.849234, 8.0, 1219.7, \" 0.124\", \"-0.868\", 3,\n 19.59618, 0.99326, 0.27064,\n -0.42632, 0.00000, 0.00000, 0.38161, 0.00000, 0.00000, 1.18534,\n 175.3480588, 0.57059, -2.280e-04,\n 0.3844100, -0.18823, 5.300e-05,\n// 2443 4 14\n2613451.317925, 20.0, 1220.1, \" 0.638\", \"-0.373\", 3,\n 9.53462, 0.96591, 0.26319,\n -2.16914, 0.00000, 0.00000, -0.36981, 0.00000, 0.00000, 1.42639,\n 203.5958907, 0.55195, -9.000e-06,\n -8.5457602, -0.15848, 4.580e-04,\n// 2443 9 9\n2613599.293505, 19.0, 1221.7, \" 0.028\", \"-1.040\", 3,\n 18.25694, 0.90793, 0.24739,\n -0.38475, 0.00000, 0.00000, 0.04411, 0.00000, 0.00000, 0.47623,\n 347.8277933, 0.47977, 1.900e-05,\n -3.6756800, 0.15330, 1.600e-04,\n// 2443 10 9\n2613628.915495, 10.0, 1222.0, \" 0.503\", \"-0.552\", 3,\n 11.20359, 0.92631, 0.25240,\n -1.72927, 0.00000, 0.00000, -0.02812, 0.00000, 0.00000, 1.67575,\n 15.2594212, 0.50151, 2.970e-04,\n 5.1936998, 0.15629, -1.430e-04,\n// 2444 3 4\n2613776.475140, 23.0, 1223.6, \" 1.417\", \" 0.453\", 2,\n 9.89853, 1.02395, 0.27900,\n -1.89864, -0.74112, 0.00000, 0.40335, 0.00000, 1.54761, 2.70571,\n 165.7195548, 0.61082, -2.240e-04,\n 5.2055403, -0.19044, -2.810e-04,\n// 2444 8 28\n2613953.308914, 19.0, 1225.5, \" 1.357\", \" 0.286\", 2,\n 17.51822, 0.90280, 0.24599,\n -2.22504, -0.64099, 0.00000, 0.41393, 0.00000, 1.46788, 3.05324,\n 337.7551221, 0.48233, -2.400e-04,\n -8.4653698, 0.13964, 2.760e-04,\n// 2445 2 22\n2614131.129950, 15.0, 1227.5, \" 2.660\", \" 1.677\", 1,\n 1.20361, 1.00774, 0.27458,\n -2.59137, -1.65107, -0.68719, 0.11880, 0.92502, 1.88908, 2.82793,\n 156.1152160, 0.60280, -1.270e-04,\n 9.8101700, -0.17007, -5.840e-04,\n// 2445 8 17\n2614307.447757, 23.0, 1229.4, \" 2.766\", \" 1.737\", 1,\n 20.79045, 0.93800, 0.25558,\n -3.20704, -2.14825, -1.11518, -0.25383, 0.60719, 1.64002, 2.70124,\n 328.1081629, 0.53272, -4.940e-04,\n -12.8210898, 0.13341, 4.830e-04,\n// 2446 2 12\n2614485.620223, 3.0, 1231.4, \" 1.747\", \" 0.711\", 2,\n 12.49775, 0.95763, 0.26093,\n -2.78435, -1.57985, 0.00000, -0.11466, 0.00000, 1.35224, 2.55402,\n 145.9983808, 0.55978, -9.400e-05,\n 14.2181598, -0.13487, -7.090e-04,\n// 2446 8 7\n2614661.888251, 9.0, 1233.3, \" 1.561\", \" 0.588\", 2,\n 6.07911, 0.99024, 0.26982,\n -2.13969, -1.00118, 0.00000, 0.31803, 0.00000, 1.63540, 2.77566,\n 317.7896595, 0.61071, -6.340e-04,\n -16.8992404, 0.12264, 8.580e-04,\n// 2447 2 1\n2614839.808650, 7.0, 1235.2, \" 0.415\", \"-0.675\", 3,\n 15.76998, 0.91143, 0.24834,\n -1.18989, 0.00000, 0.00000, 0.40761, 0.00000, 0.00000, 2.00740,\n 134.7276397, 0.52388, -1.670e-04,\n 18.3362200, -0.09738, -7.400e-04,\n// 2447 6 28\n2614987.279297, 19.0, 1236.8, \" 0.828\", \"-0.115\", 3,\n 13.46218, 1.02150, 0.27833,\n -2.16827, 0.00000, 0.00000, -0.29687, 0.00000, 0.00000, 1.57494,\n 278.2557869, 0.68406, 1.750e-04,\n -22.0697704, -0.02106, 1.419e-03,\n// 2447 7 28\n2615016.555732, 1.0, 1237.2, \" 0.264\", \"-0.678\", 3,\n 21.38419, 1.02226, 0.27854,\n -0.77982, 0.00000, 0.00000, 0.33757, 0.00000, 0.00000, 1.45409,\n 307.6337693, 0.66925, -4.830e-04,\n -20.3461602, 0.09871, 1.267e-03,\n// 2447 12 22\n2615163.997340, 12.0, 1238.8, \" 1.067\", \"-0.021\", 3,\n 18.07366, 0.91334, 0.24886,\n -2.46173, 0.00000, 0.00000, -0.06385, 0.00000, 0.00000, 2.33312,\n 90.6180800, 0.54869, 3.000e-05,\n 22.4732792, 0.04402, -9.390e-04,\n// 2448 6 17\n2615341.937856, 11.0, 1240.7, \" 2.162\", \" 1.185\", 1,\n 4.76727, 0.98731, 0.26902,\n -3.17517, -2.18131, -1.01257, -0.49146, 0.03031, 1.19923, 2.19101,\n 267.3584387, 0.64113, 5.650e-04,\n -23.0189499, -0.06533, 1.265e-03,\n// 2448 12 10\n2615518.203691, 17.0, 1242.7, \" 2.385\", \" 1.352\", 1,\n 22.34862, 0.96081, 0.26180,\n -2.95823, -1.89699, -0.80033, -0.11143, 0.57692, 1.67328, 2.73694,\n 78.4180917, 0.60098, 1.640e-04,\n 22.7048790, 0.09622, -1.163e-03,\n// 2449 6 6\n2615696.361114, 21.0, 1244.6, \" 2.128\", \" 1.096\", 1,\n 14.05593, 0.93509, 0.25479,\n -3.20024, -2.07204, -0.73538, -0.33327, 0.06966, 1.40664, 2.53257,\n 255.8682300, 0.56959, 6.460e-04,\n -23.1435291, -0.10013, 9.850e-04,\n// 2449 11 30\n2615872.707697, 5.0, 1246.6, \" 2.053\", \" 1.072\", 1,\n 9.64276, 1.00992, 0.27518,\n -2.61554, -1.62248, -0.34495, -0.01527, 0.31388, 1.59135, 2.58596,\n 66.5235290, 0.64863, 5.230e-04,\n 22.0739403, 0.15399, -1.323e-03,\n// 2450 5 26\n2616050.485092, 0.0, 1248.5, \" 0.710\", \"-0.363\", 3,\n 16.32542, 0.90186, 0.24574,\n -2.40312, 0.00000, 0.00000, -0.35778, 0.00000, 0.00000, 1.68861,\n 244.2090425, 0.51787, 5.410e-04,\n -22.3720609, -0.12932, 8.100e-04,\n// 2450 10 21\n2616197.966872, 11.0, 1250.1, \" 0.039\", \"-0.931\", 3,\n 13.01488, 1.01081, 0.27542,\n -0.23942, 0.00000, 0.00000, 0.20493, 0.00000, 0.00000, 0.65244,\n 26.9247406, 0.56732, 6.000e-04,\n 9.4217098, 0.27013, -3.780e-04,\n// 2450 11 19\n2616227.365736, 21.0, 1250.5, \" 0.830\", \"-0.136\", 3,\n 0.94785, 1.02341, 0.27885,\n -2.10226, 0.00000, 0.00000, -0.22235, 0.00000, 0.00000, 1.65841,\n 55.2089006, 0.64649, 9.090e-04,\n 20.7082286, 0.19939, -1.189e-03,\n// 2451 4 16\n2616374.891601, 9.0, 1252.1, \" 1.146\", \" 0.095\", 2,\n 22.64005, 0.92897, 0.25312,\n -2.00182, -0.20874, 0.00000, 0.39842, 0.00000, 1.00250, 2.79719,\n 204.7943703, 0.47820, 1.480e-04,\n -9.3186303, -0.23341, 4.020e-04,\n// 2451 10 11\n2616552.503744, 0.0, 1254.1, \" 1.257\", \" 0.241\", 2,\n 1.31176, 0.96271, 0.26231,\n -2.28429, -0.82343, 0.00000, 0.08986, 0.00000, 1.00603, 2.46402,\n 16.7563494, 0.50374, 4.660e-04,\n 6.1926999, 0.26114, -1.240e-04,\n// 2452 4 4\n2616729.246333, 18.0, 1256.0, \" 2.537\", \" 1.538\", 1,\n 6.92597, 0.98135, 0.26739,\n -2.86997, -1.88278, -0.86895, -0.08802, 0.69253, 1.70607, 2.69524,\n 194.6502553, 0.52149, 4.900e-05,\n -6.0613297, -0.27406, 3.630e-04,\n// 2452 9 29\n2616906.757264, 6.0, 1258.0, \" 2.608\", \" 1.543\", 1,\n 6.58946, 0.91495, 0.24930,\n -2.87804, -1.73858, -0.64825, 0.17432, 0.99717, 2.08763, 3.22523,\n 6.4240998, 0.44909, 2.110e-04,\n 2.6080700, 0.24368, -1.300e-05,\n// 2453 3 25\n2617083.848287, 8.0, 1259.9, \" 1.862\", \" 0.898\", 2,\n 20.22558, 1.02039, 0.27803,\n -2.14505, -1.14555, 0.00000, 0.35889, 0.00000, 1.86307, 2.86357,\n 184.3200314, 0.55649, 4.000e-05,\n -2.4320600, -0.30287, 1.610e-04,\n// 2453 9 18\n2617260.779358, 7.0, 1261.9, \" 1.822\", \" 0.743\", 2,\n 6.85348, 0.90006, 0.24525,\n -3.20376, -1.88017, 0.00000, -0.29540, 0.00000, 1.28924, 2.61369,\n 356.2548261, 0.43388, -5.700e-05,\n -1.0314601, 0.23644, 1.500e-05,\n// 2454 2 13\n2617409.075114, 14.0, 1263.5, \" 0.173\", \"-0.824\", 3,\n 23.59770, 0.99531, 0.27120,\n -1.14044, 0.00000, 0.00000, -0.19726, 0.00000, 0.00000, 0.74966,\n 148.0272884, 0.56566, -4.340e-04,\n 14.4236400, -0.25250, -7.680e-04,\n// 2454 3 15\n2617438.522942, 1.0, 1263.9, \" 0.609\", \"-0.362\", 3,\n 12.53340, 1.01558, 0.27672,\n -2.10957, 0.00000, 0.00000, -0.44939, 0.00000, 0.00000, 1.21266,\n 174.7604030, 0.55194, 8.000e-05,\n 0.8938900, -0.29846, -1.080e-04,\n// 2454 8 8\n2617585.354394, 21.0, 1265.5, \" 0.236\", \"-0.776\", 3,\n 18.18180, 0.95260, 0.25956,\n -1.64906, 0.00000, 0.00000, -0.49455, 0.00000, 0.00000, 0.65509,\n 320.1205572, 0.53255, -8.340e-04,\n -16.8951491, 0.21442, 5.970e-04,\n// 2454 9 7\n2617614.859409, 9.0, 1265.8, \" 0.496\", \"-0.550\", 3,\n 8.12024, 0.92745, 0.25271,\n -2.06088, 0.00000, 0.00000, -0.37418, 0.00000, 0.00000, 1.30991,\n 346.0011821, 0.46551, -3.270e-04,\n -4.6519799, 0.24434, 6.500e-05,\n// 2455 2 2\n2617763.486276, 0.0, 1267.5, \" 1.357\", \" 0.302\", 2,\n 8.88636, 0.94213, 0.25671,\n -2.84606, -1.36447, 0.00000, -0.32939, 0.00000, 0.70835, 2.18698,\n 136.9606471, 0.52538, -3.680e-04,\n 17.2401898, -0.20356, -7.640e-04,\n// 2455 7 29\n2617939.874188, 9.0, 1269.4, \" 1.697\", \" 0.737\", 2,\n 5.47593, 1.00295, 0.27328,\n -2.50024, -1.44408, 0.00000, -0.01948, 0.00000, 1.40374, 2.46119,\n 309.2281540, 0.60965, -9.670e-04,\n -19.1566999, 0.20708, 9.370e-04,\n// 2456 1 23\n2618117.590369, 2.0, 1271.4, \" 2.621\", \" 1.521\", 1,\n 10.15312, 0.90388, 0.24629,\n -2.95555, -1.75825, -0.64656, 0.16884, 0.98442, 2.09618, 3.29227,\n 124.9258128, 0.50221, -4.150e-04,\n 19.6713102, -0.15754, -7.220e-04,\n// 2456 7 18\n2618294.573397, 2.0, 1273.4, \" 2.597\", \" 1.657\", 1,\n 21.78376, 1.02334, 0.27883,\n -2.87092, -1.98821, -1.03894, -0.23847, 0.56202, 1.51134, 2.39399,\n 298.6817409, 0.65285, -7.500e-04,\n -20.6267803, 0.17834, 1.230e-03,\n// 2457 1 11\n2618471.549853, 1.0, 1275.3, \" 1.950\", \" 0.853\", 2,\n 8.41166, 0.90629, 0.24694,\n -2.75704, -1.45671, 0.00000, 0.19647, 0.00000, 1.84900, 3.15089,\n 112.6774258, 0.52172, -5.320e-04,\n 21.2807811, -0.12186, -7.800e-04,\n// 2457 7 7\n2618649.261477, 18.0, 1277.3, \" 1.221\", \" 0.257\", 2,\n 13.08884, 0.99776, 0.27186,\n -1.96448, -0.63273, 0.00000, 0.27545, 0.00000, 1.18599, 2.51628,\n 287.4947106, 0.63680, -3.240e-04,\n -21.5404598, 0.12651, 1.254e-03,\n// 2457 12 31\n2618825.682871, 4.0, 1279.3, \" 0.725\", \"-0.324\", 3,\n 10.68115, 0.94784, 0.25826,\n -1.56487, 0.00000, 0.00000, 0.38890, 0.00000, 0.00000, 2.34045,\n 100.3128437, 0.58321, -6.020e-04,\n 21.9485209, -0.08790, -9.920e-04,\n// 2458 5 28\n2618974.235712, 18.0, 1280.9, \" 1.002\", \"-0.046\", 3,\n 10.44454, 0.92234, 0.25132,\n -2.63547, 0.00000, 0.00000, -0.34291, 0.00000, 0.00000, 1.95088,\n 246.3232319, 0.56040, 3.320e-04,\n -22.5356593, -0.03599, 9.590e-04,\n// 2458 11 21\n2619150.671083, 4.0, 1282.9, \" 1.175\", \" 0.204\", 2,\n 8.03685, 1.01865, 0.27756,\n -2.06250, -0.69587, 0.00000, 0.10599, 0.00000, 0.90663, 2.27434,\n 56.6844093, 0.66945, 2.330e-04,\n 20.8130890, 0.08108, -1.315e-03,\n// 2459 5 17\n2619328.298073, 19.0, 1284.9, \" 2.364\", \" 1.287\", 1,\n 10.70856, 0.89957, 0.24511,\n -2.92429, -1.72729, -0.51974, 0.15375, 0.82727, 2.03487, 3.23174,\n 234.7819334, 0.51924, 2.300e-04,\n -19.7256393, -0.06815, 7.470e-04,\n// 2459 11 10\n2619505.339937, 20.0, 1286.8, \" 2.418\", \" 1.449\", 1,\n 23.34193, 1.01801, 0.27738,\n -2.48944, -1.56080, -0.56093, 0.15848, 0.87809, 1.87810, 2.80592,\n 45.8716188, 0.64912, 5.490e-04,\n 17.4916807, 0.11745, -1.031e-03,\n// 2460 5 5\n2619682.342400, 20.0, 1288.8, \" 2.052\", \" 0.995\", 2,\n 10.97257, 0.91930, 0.25049,\n -2.69535, -1.49968, 0.00000, 0.21760, 0.00000, 1.93386, 3.13133,\n 223.8331128, 0.52638, 1.100e-04,\n -16.2428899, -0.10154, 6.800e-04,\n// 2460 10 30\n2619859.914506, 10.0, 1290.8, \" 1.972\", \" 0.964\", 2,\n 12.64154, 0.97540, 0.26577,\n -2.73751, -1.65673, 0.00000, -0.05187, 0.00000, 1.55414, 2.63256,\n 35.6068997, 0.57982, 5.790e-04,\n 13.6260797, 0.13588, -6.140e-04,\n// 2461 3 26\n2620007.191790, 17.0, 1292.5, \" 0.079\", \"-0.908\", 3,\n 5.32006, 0.99574, 0.27132,\n -1.04153, 0.00000, 0.00000, -0.39705, 0.00000, 0.00000, 0.24316,\n 185.8387512, 0.57468, -7.800e-05,\n -4.1251201, -0.18851, 2.780e-04,\n// 2461 4 25\n2620036.638290, 3.0, 1292.8, \" 0.726\", \"-0.280\", 3,\n 17.25302, 0.96895, 0.26402,\n -1.57433, 0.00000, 0.00000, 0.31896, 0.00000, 0.00000, 2.20951,\n 213.4483020, 0.56765, 5.700e-05,\n -12.2295801, -0.14018, 6.410e-04,\n// 2461 10 19\n2620214.226902, 17.0, 1294.8, \" 0.579\", \"-0.482\", 3,\n 18.92199, 0.92389, 0.25174,\n -1.37477, 0.00000, 0.00000, 0.44564, 0.00000, 0.00000, 2.26839,\n 25.1216595, 0.50704, 3.720e-04,\n 9.1808799, 0.14262, -3.050e-04,\n// 2462 3 16\n2620361.830020, 8.0, 1296.4, \" 1.377\", \" 0.415\", 2,\n 19.62240, 1.02420, 0.27907,\n -2.35714, -1.18142, 0.00000, -0.07953, 0.00000, 1.02223, 2.19846,\n 176.1621217, 0.60621, -5.700e-05,\n 0.7781800, -0.19798, -3.300e-05,\n// 2462 9 9\n2620538.590291, 2.0, 1298.4, \" 1.228\", \" 0.155\", 2,\n 1.23662, 0.90386, 0.24628,\n -2.37725, -0.62461, 0.00000, 0.16698, 0.00000, 0.95726, 2.71141,\n 347.6859166, 0.47636, -1.700e-04,\n -4.3726303, 0.15052, 1.270e-04,\n// 2463 3 5\n2620716.485809, 0.0, 1300.4, \" 2.629\", \" 1.646\", 1,\n 10.92749, 1.00559, 0.27400,\n -3.05403, -2.11083, -1.14108, -0.34058, 0.46017, 1.43013, 2.37180,\n 166.7377584, 0.58999, 0.000e-00,\n 5.5538001, -0.18427, -3.500e-04,\n// 2463 8 29\n2620892.741139, 6.0, 1302.4, \" 2.634\", \" 1.606\", 1,\n 4.50885, 0.94102, 0.25641,\n -3.14712, -2.08872, -1.04367, -0.21266, 0.61797, 1.66280, 2.72369,\n 338.0982708, 0.52454, -4.340e-04,\n -9.0402301, 0.15165, 3.110e-04,\n// 2464 2 23\n2621070.966869, 11.0, 1304.4, \" 1.768\", \" 0.731\", 2,\n 21.21889, 0.95479, 0.26016,\n -2.48276, -1.28056, 0.00000, 0.20487, 0.00000, 1.69194, 2.89138,\n 156.4754675, 0.54287, -3.600e-05,\n 10.3938703, -0.15393, -5.220e-04,\n// 2464 8 17\n2621247.196132, 17.0, 1306.4, \" 1.692\", \" 0.720\", 2,\n 14.80025, 0.99319, 0.27062,\n -2.80252, -1.71803, 0.00000, -0.29283, 0.00000, 1.13080, 2.21696,\n 328.4642890, 0.59741, -6.020e-04,\n -13.4158499, 0.15050, 6.460e-04,\n// 2465 2 11\n2621425.143650, 15.0, 1308.4, \" 0.432\", \"-0.659\", 3,\n 0.49112, 0.90986, 0.24792,\n -1.18290, 0.00000, 0.00000, 0.44759, 0.00000, 0.00000, 2.08014,\n 145.7706622, 0.50708, -1.720e-04,\n 14.9361399, -0.12226, -5.880e-04,\n// 2465 7 9\n2621572.590831, 2.0, 1310.1, \" 0.694\", \"-0.249\", 3,\n 21.18058, 1.02053, 0.27807,\n -1.55892, 0.00000, 0.00000, 0.17995, 0.00000, 0.00000, 1.91955,\n 289.1271258, 0.67760, -2.500e-05,\n -21.0129301, 0.02568, 1.344e-03,\n// 2465 8 7\n2621601.869009, 9.0, 1310.4, \" 0.393\", \"-0.549\", 3,\n 6.10533, 1.02288, 0.27871,\n -1.48857, 0.00000, 0.00000, -0.14379, 0.00000, 0.00000, 1.20035,\n 318.5961683, 0.65125, -5.200e-04,\n -17.3790697, 0.13458, 1.048e-03,\n// 2466 1 1\n2621749.336304, 20.0, 1312.0, \" 1.054\", \"-0.033\", 3,\n 2.79479, 0.91510, 0.24934,\n -2.30949, 0.00000, 0.00000, 0.07129, 0.00000, 0.00000, 2.45120,\n 102.5914699, 0.55087, -1.440e-04,\n 21.9501499, 0.00216, -9.180e-04,\n// 2466 6 28\n2621927.240716, 18.0, 1314.1, \" 2.023\", \" 1.045\", 1,\n 12.48567, 0.98421, 0.26817,\n -2.87915, -1.85706, -0.49069, -0.22282, 0.04591, 1.41249, 2.43248,\n 278.5458241, 0.63917, 3.510e-04,\n -22.7174209, -0.01938, 1.262e-03,\n// 2466 12 22\n2622103.556721, 1.0, 1316.1, \" 2.371\", \" 1.340\", 1,\n 7.06976, 0.96363, 0.26257,\n -2.47342, -1.41577, -0.31665, 0.36131, 1.03871, 2.13754, 3.19762,\n 90.2408623, 0.61302, -3.000e-05,\n 23.0966791, 0.05112, -1.205e-03,\n// 2467 6 18\n2622281.646955, 4.0, 1318.1, \" 2.271\", \" 1.237\", 1,\n 21.77433, 0.93218, 0.25400,\n -3.38648, -2.27518, -1.07980, -0.47307, 0.13429, 1.32994, 2.43897,\n 267.3447237, 0.57520, 4.740e-04,\n -23.6845296, -0.05837, 1.040e-03,\n// 2467 12 11\n2622458.069380, 14.0, 1320.1, \" 2.075\", \" 1.094\", 1,\n 19.36664, 1.01181, 0.27569,\n -2.93654, -1.94893, -0.70855, -0.33488, 0.03831, 1.27861, 2.26763,\n 78.7290497, 0.66881, 3.510e-04,\n 23.4201296, 0.10516, -1.453e-03,\n// 2468 6 6\n2622635.760562, 6.0, 1322.1, \" 0.850\", \"-0.221\", 3,\n 23.04108, 0.90110, 0.24553,\n -1.95516, 0.00000, 0.00000, 0.25349, 0.00000, 0.00000, 2.46288,\n 255.2042810, 0.53068, 4.330e-04,\n -23.6763590, -0.09452, 8.960e-04,\n// 2468 11 30\n2622812.725315, 5.0, 1324.1, \" 0.859\", \"-0.109\", 3,\n 9.66899, 1.02286, 0.27870,\n -1.50190, 0.00000, 0.00000, 0.40755, 0.00000, 0.00000, 2.31783,\n 66.5061052, 0.66820, 8.430e-04,\n 22.7177505, 0.15681, -1.371e-03,\n// 2469 4 26\n2622960.198295, 17.0, 1325.7, \" 1.053\", \" 0.008\", 2,\n 7.36119, 0.93161, 0.25384,\n -2.55495, -0.41702, 0.00000, -0.24093, 0.00000, -0.06824, 2.07136,\n 215.4044408, 0.49607, 2.510e-04,\n -13.0976894, -0.21579, 5.530e-04,\n// 2469 10 21\n2623137.828216, 8.0, 1327.8, \" 1.182\", \" 0.160\", 2,\n 10.03290, 0.95971, 0.26150,\n -2.45459, -0.87619, 0.00000, -0.12282, 0.00000, 0.63370, 2.20920,\n 27.0545398, 0.51319, 6.150e-04,\n 10.1924403, 0.24521, -2.940e-04,\n// 2470 4 16\n2623314.576266, 2.0, 1329.8, \" 2.460\", \" 1.467\", 1,\n 15.64711, 0.98417, 0.26816,\n -2.92958, -1.94672, -0.91789, -0.16961, 0.57824, 1.60679, 2.59155,\n 204.8565524, 0.53667, 2.170e-04,\n -10.0841596, -0.26205, 5.400e-04,\n// 2470 10 10\n2623492.058092, 13.0, 1331.8, \" 2.511\", \" 1.441\", 1,\n 14.30786, 0.91299, 0.24877,\n -2.65791, -1.50183, -0.38088, 0.39421, 1.16959, 2.29063, 3.44492,\n 16.2710098, 0.45326, 3.360e-04,\n 6.6820898, 0.23608, -1.460e-04,\n// 2471 4 5\n2623669.193152, 17.0, 1333.8, \" 1.921\", \" 0.962\", 2,\n 5.94946, 1.02127, 0.27827,\n -2.88365, -1.90266, 0.00000, -0.36435, 0.00000, 1.17379, 2.15565,\n 194.8084972, 0.56479, 2.730e-04,\n -6.8780398, -0.29596, 3.730e-04,\n// 2471 9 29\n2623846.069179, 14.0, 1335.8, \" 1.938\", \" 0.856\", 2,\n 14.57188, 0.90053, 0.24537,\n -3.29557, -2.00660, 0.00000, -0.33971, 0.00000, 1.32700, 2.61693,\n 6.0948399, 0.43527, 6.500e-05,\n 3.1557600, 0.23605, -1.100e-04,\n// 2472 2 24\n2623994.431720, 22.0, 1337.5, \" 0.143\", \"-0.855\", 3,\n 8.31884, 0.99277, 0.27051,\n -0.50026, 0.00000, 0.00000, 0.36128, 0.00000, 0.00000, 1.22682,\n 158.3672386, 0.54535, -2.750e-04,\n 10.6490897, -0.26962, -5.750e-04,\n// 2472 3 25\n2624023.871644, 9.0, 1337.8, \" 0.654\", \"-0.316\", 3,\n 21.25454, 1.01383, 0.27624,\n -1.79581, 0.00000, 0.00000, -0.08055, 0.00000, 0.00000, 1.63662,\n 184.6312831, 0.55068, 3.020e-04,\n -3.3146902, -0.29770, 8.000e-05,\n// 2472 8 19\n2624170.650304, 4.0, 1339.5, \" 0.114\", \"-0.896\", 3,\n 1.90020, 0.95586, 0.26045,\n -1.20170, 0.00000, 0.00000, -0.39271, 0.00000, 0.00000, 0.41089,\n 330.3799385, 0.51790, -7.420e-04,\n -13.5597603, 0.23743, 4.320e-04,\n// 2472 9 17\n2624200.156838, 16.0, 1339.9, \" 0.617\", \"-0.428\", 3,\n 15.83864, 0.93012, 0.25344,\n -2.08967, 0.00000, 0.00000, -0.23588, 0.00000, 0.00000, 1.61577,\n 355.7440372, 0.46377, -1.910e-04,\n -0.5819000, 0.25129, -7.400e-05,\n// 2473 2 13\n2624348.831655, 8.0, 1341.5, \" 1.333\", \" 0.278\", 2,\n 17.60750, 0.93951, 0.25599,\n -2.54978, -1.03856, 0.00000, -0.04028, 0.00000, 0.96070, 2.46892,\n 147.7917972, 0.50314, -2.890e-04,\n 13.8138100, -0.22611, -6.030e-04,\n// 2473 8 8\n2624525.183404, 16.0, 1343.5, \" 1.568\", \" 0.609\", 2,\n 13.19433, 1.00541, 0.27395,\n -2.01462, -0.91736, 0.00000, 0.40170, 0.00000, 1.71923, 2.81763,\n 319.5788959, 0.59106, -9.090e-04,\n -16.4089506, 0.23850, 7.520e-04,\n// 2474 2 2\n2624702.924360, 10.0, 1345.6, \" 2.600\", \" 1.500\", 1,\n 18.87426, 0.90293, 0.24603,\n -2.94102, -1.74076, -0.62266, 0.18464, 0.99210, 2.11025, 3.30938,\n 136.2663721, 0.48191, -4.050e-04,\n 16.8057812, -0.18596, -5.870e-04,\n// 2474 7 29\n2624879.885858, 9.0, 1347.6, \" 2.732\", \" 1.791\", 1,\n 5.50216, 1.02308, 0.27876,\n -2.38047, -1.50034, -0.56344, 0.26058, 1.08464, 2.02158, 2.90153,\n 309.2195206, 0.63100, -7.610e-04,\n -18.4774000, 0.21575, 1.056e-03,\n// 2475 1 22\n2625056.886784, 9.0, 1349.6, \" 1.966\", \" 0.871\", 2,\n 17.13280, 0.90759, 0.24730,\n -2.67077, -1.38006, 0.00000, 0.28281, 0.00000, 1.94502, 3.23741,\n 124.3265184, 0.50557, -5.860e-04,\n 19.1857401, -0.15700, -6.590e-04,\n// 2475 7 19\n2625234.565646, 2.0, 1351.7, \" 1.356\", \" 0.388\", 2,\n 21.80998, 0.99497, 0.27110,\n -2.75673, -1.52370, 0.00000, -0.42449, 0.00000, 0.67689, 1.90845,\n 298.9837991, 0.61511, -4.280e-04,\n -19.8732294, 0.16911, 1.118e-03,\n// 2476 1 11\n2625411.034382, 13.0, 1353.7, \" 0.740\", \"-0.307\", 3,\n 20.40503, 0.95054, 0.25900,\n -2.13843, 0.00000, 0.00000, -0.17483, 0.00000, 0.00000, 1.78669,\n 112.5689419, 0.57138, -7.370e-04,\n 20.6345291, -0.13243, -8.830e-04,\n// 2476 6 8\n2625559.520035, 0.0, 1355.4, \" 0.861\", \"-0.188\", 3,\n 17.16020, 0.91991, 0.25066,\n -1.68090, 0.00000, 0.00000, 0.48085, 0.00000, 0.00000, 2.64410,\n 257.1963466, 0.56419, 1.730e-04,\n -23.8915800, 0.00113, 1.030e-03,\n// 2476 12 1\n2625736.030754, 13.0, 1357.4, \" 1.150\", \" 0.179\", 2,\n 17.76073, 1.01994, 0.27791,\n -2.41135, -1.01399, 0.00000, -0.26190, 0.00000, 0.48906, 1.88731,\n 68.6824903, 0.68542, 5.200e-05,\n 22.8652809, 0.03405, -1.475e-03,\n// 2477 5 28\n2625913.576378, 2.0, 1359.5, \" 2.225\", \" 1.151\", 1,\n 18.42696, 0.89957, 0.24511,\n -3.21107, -1.99667, -0.67923, -0.16694, 0.34535, 1.66281, 2.87722,\n 246.0021310, 0.53045, 1.250e-04,\n -21.8719801, -0.03443, 8.490e-04,\n// 2477 11 21\n2626090.694838, 5.0, 1361.5, \" 2.382\", \" 1.410\", 1,\n 9.06581, 1.01673, 0.27703,\n -2.97255, -2.03572, -1.02176, -0.32388, 0.37423, 1.38832, 2.32422,\n 57.4971881, 0.66523, 4.710e-04,\n 20.2698004, 0.07678, -1.239e-03,\n// 2478 5 17\n2626267.634467, 3.0, 1363.5, \" 2.171\", \" 1.120\", 1,\n 18.69098, 0.92165, 0.25113,\n -2.70862, -1.54735, -0.22553, 0.22721, 0.67929, 2.00087, 3.16406,\n 234.5652252, 0.54272, 6.100e-05,\n -19.0460610, -0.07232, 8.160e-04,\n// 2478 11 10\n2626445.253391, 18.0, 1365.6, \" 2.021\", \" 1.007\", 1,\n 21.36269, 0.97256, 0.26500,\n -2.63190, -1.55067, -0.02910, 0.08137, 0.19279, 1.71454, 2.79339,\n 46.3687097, 0.59203, 5.860e-04,\n 16.9137101, 0.10623, -8.060e-04,\n// 2479 4 7\n2626592.529589, 1.0, 1367.3, \" 0.022\", \"-0.959\", 3,\n 14.04120, 0.99818, 0.27198,\n -0.63435, 0.00000, 0.00000, -0.28986, 0.00000, 0.00000, 0.05025,\n 195.8472460, 0.58477, 6.100e-05,\n -8.3706000, -0.18137, 4.960e-04,\n// 2479 5 6\n2626621.953629, 11.0, 1367.6, \" 0.827\", \"-0.173\", 3,\n 1.97416, 0.97202, 0.26485,\n -2.10308, 0.00000, 0.00000, -0.11292, 0.00000, 0.00000, 1.87497,\n 224.1538858, 0.58590, 7.400e-05,\n -15.6324793, -0.11354, 8.250e-04,\n// 2479 10 31\n2626799.543669, 1.0, 1369.6, \" 0.643\", \"-0.424\", 3,\n 3.64313, 0.92160, 0.25111,\n -1.86625, 0.00000, 0.00000, 0.04806, 0.00000, 0.00000, 1.96442,\n 35.7371207, 0.51668, 4.180e-04,\n 12.9830507, 0.12209, -4.700e-04,\n// 2480 3 26\n2626947.179657, 16.0, 1371.3, \" 1.325\", \" 0.366\", 2,\n 4.34355, 1.02430, 0.27909,\n -1.93406, -0.73033, 0.00000, 0.31177, 0.00000, 1.35384, 2.55797,\n 185.9750682, 0.60765, 1.150e-04,\n -3.5100500, -0.19726, 2.020e-04,\n// 2480 9 19\n2627123.877463, 9.0, 1373.4, \" 1.111\", \" 0.037\", 2,\n 8.95502, 0.90505, 0.24661,\n -2.38942, -0.33197, 0.00000, 0.05911, 0.00000, 0.44851, 2.50764,\n 357.4872107, 0.47476, -8.600e-05,\n -0.1286600, 0.15551, -2.300e-05,\n// 2481 3 16\n2627301.837495, 8.0, 1375.4, \" 2.589\", \" 1.607\", 1,\n 19.64863, 1.00332, 0.27338,\n -2.61601, -1.66943, -0.69167, 0.09987, 0.89169, 1.86967, 2.81465,\n 176.6316972, 0.58260, 1.490e-04,\n 1.2946000, -0.18967, -1.290e-04,\n// 2481 9 8\n2627478.038979, 13.0, 1377.5, \" 2.511\", \" 1.484\", 1,\n 12.22725, 0.94408, 0.25724,\n -2.97541, -1.91412, -0.84549, -0.06450, 0.71605, 1.78446, 2.84832,\n 347.8552507, 0.52004, -3.450e-04,\n -4.9985600, 0.16374, 1.370e-04,\n// 2482 3 5\n2627656.309884, 19.0, 1379.5, \" 1.796\", \" 0.759\", 2,\n 5.94003, 0.95194, 0.25938,\n -2.27069, -1.07320, 0.00000, 0.43722, 0.00000, 1.94923, 3.14393,\n 166.7122408, 0.53002, 5.700e-05,\n 6.2537899, -0.16569, -3.360e-04,\n// 2482 8 29\n2627832.507129, 0.0, 1381.6, \" 1.818\", \" 0.847\", 2,\n 22.51865, 0.99604, 0.27139,\n -2.38111, -1.33739, 0.00000, 0.17109, 0.00000, 1.67823, 2.72356,\n 338.2267057, 0.58783, -5.130e-04,\n -9.6937998, 0.17010, 4.390e-04,\n// 2483 2 22\n2628010.475268, 23.0, 1383.6, \" 0.456\", \"-0.635\", 3,\n 9.21226, 0.90839, 0.24752,\n -1.26744, 0.00000, 0.00000, 0.40643, 0.00000, 0.00000, 2.08210,\n 156.4709595, 0.49254, -1.300e-04,\n 11.0646401, -0.14032, -4.300e-04,\n// 2483 7 20\n2628157.901426, 10.0, 1385.3, \" 0.559\", \"-0.385\", 3,\n 5.90172, 1.01942, 0.27777,\n -1.94964, 0.00000, 0.00000, -0.36577, 0.00000, 0.00000, 1.21922,\n 300.4626717, 0.66466, -1.850e-04,\n -19.1722607, 0.07120, 1.206e-03,\n// 2483 8 18\n2628187.184159, 16.0, 1385.7, \" 0.518\", \"-0.425\", 3,\n 13.82374, 1.02334, 0.27883,\n -1.10543, 0.00000, 0.00000, 0.41981, 0.00000, 0.00000, 1.94456,\n 328.5564692, 0.63478, -4.670e-04,\n -14.0442495, 0.16109, 8.230e-04,\n// 2484 1 13\n2628334.677002, 4.0, 1387.4, \" 1.043\", \"-0.042\", 3,\n 11.51594, 0.91694, 0.24985,\n -2.11698, 0.00000, 0.00000, 0.24806, 0.00000, 0.00000, 2.61227,\n 114.3922746, 0.54638, -2.930e-04,\n 20.5384506, -0.03784, -8.440e-04,\n// 2484 7 9\n2628512.542149, 1.0, 1389.5, \" 1.883\", \" 0.902\", 2,\n 20.20407, 0.98107, 0.26732,\n -2.60959, -1.55125, 0.00000, 0.01158, 0.00000, 1.57574, 2.63199,\n 289.6379693, 0.62994, 1.550e-04,\n -21.6317009, 0.02462, 1.197e-03,\n// 2485 1 1\n2628688.911346, 10.0, 1391.5, \" 2.359\", \" 1.330\", 1,\n 16.79364, 0.96643, 0.26333,\n -2.95035, -1.89710, -0.79651, -0.12769, 0.54056, 1.64089, 2.69657,\n 102.6573881, 0.61656, -2.520e-04,\n 22.6029401, 0.00288, -1.178e-03,\n// 2485 6 28\n2628866.931075, 10.0, 1393.6, \" 2.418\", \" 1.382\", 1,\n 4.48999, 0.92936, 0.25323,\n -2.60699, -1.50681, -0.38595, 0.34581, 1.07804, 2.19915, 3.29708,\n 278.2848289, 0.57317, 2.890e-04,\n -23.3724309, -0.01837, 1.037e-03,\n// 2485 12 21\n2629043.433646, 22.0, 1395.6, \" 2.091\", \" 1.111\", 1,\n 4.08778, 1.01356, 0.27617,\n -2.19393, -1.21102, 0.00478, 0.40750, 0.80979, 2.02548, 3.00967,\n 90.4053196, 0.68021, 1.230e-04,\n 23.7679996, 0.05578, -1.503e-03,\n// 2486 6 17\n2629221.032580, 13.0, 1397.7, \" 0.998\", \"-0.072\", 3,\n 6.75949, 0.90048, 0.24536,\n -2.57671, 0.00000, 0.00000, -0.21808, 0.00000, 0.00000, 2.14098,\n 266.8991768, 0.53904, 2.740e-04,\n -24.2814198, -0.05538, 9.470e-04,\n// 2486 12 11\n2629398.088311, 14.0, 1399.7, \" 0.881\", \"-0.090\", 3,\n 19.39287, 1.02216, 0.27851,\n -1.81193, 0.00000, 0.00000, 0.11946, 0.00000, 0.00000, 2.05161,\n 78.7456539, 0.68586, 6.580e-04,\n 24.0587813, 0.10607, -1.515e-03,\n// 2487 5 8\n2629545.499773, 0.0, 1401.5, \" 0.948\", \"-0.091\", 3,\n 15.07959, 0.93436, 0.25459,\n -2.21582, 0.00000, 0.00000, -0.00544, 0.00000, 0.00000, 2.20290,\n 225.8148103, 0.51672, 3.080e-04,\n -16.2047809, -0.19282, 6.970e-04,\n// 2487 11 1\n2629723.157931, 16.0, 1403.5, \" 1.118\", \" 0.090\", 2,\n 18.75404, 0.95678, 0.26070,\n -2.50394, -0.78206, 0.00000, -0.20965, 0.00000, 0.36617, 2.08514,\n 37.6141284, 0.52709, 7.290e-04,\n 13.8321602, 0.22268, -4.670e-04,\n// 2488 4 26\n2629899.900117, 10.0, 1405.6, \" 2.368\", \" 1.381\", 1,\n 0.36825, 0.98700, 0.26893,\n -3.13108, -2.14992, -1.09494, -0.39720, 0.30007, 1.35475, 2.33774,\n 215.3142004, 0.55706, 3.540e-04,\n -13.7794909, -0.24275, 7.240e-04,\n// 2488 10 20\n2630077.365495, 21.0, 1407.7, \" 2.430\", \" 1.353\", 1,\n 23.02901, 0.91119, 0.24828,\n -3.27829, -2.10497, -0.94758, -0.22813, 0.49164, 1.64911, 2.82070,\n 26.7472308, 0.46328, 4.550e-04,\n 10.7742904, 0.22231, -2.900e-04,\n// 2489 4 16\n2630254.532378, 1.0, 1409.7, \" 1.994\", \" 1.039\", 1,\n 14.67060, 1.02202, 0.27847,\n -2.76032, -1.79838, -0.46432, -0.22292, 0.01827, 1.35244, 2.31512,\n 204.9127375, 0.57924, 4.780e-04,\n -10.8339701, -0.28196, 5.740e-04,\n// 2489 10 9\n2630431.364981, 21.0, 1411.8, \" 2.042\", \" 0.957\", 2,\n 22.29029, 0.90112, 0.24553,\n -3.23342, -1.96950, 0.00000, -0.24045, 0.00000, 1.48839, 2.75339,\n 16.0007700, 0.44207, 1.830e-04,\n 7.2610204, 0.23017, -2.370e-04,\n// 2490 3 7\n2630579.783985, 7.0, 1413.6, \" 0.104\", \"-0.894\", 3,\n 18.04272, 0.99014, 0.26979,\n -0.92259, 0.00000, 0.00000, -0.18436, 0.00000, 0.00000, 0.55820,\n 169.0096432, 0.53046, -8.200e-05,\n 6.3065100, -0.28017, -3.780e-04,\n// 2490 4 5\n2630609.214906, 17.0, 1413.9, \" 0.710\", \"-0.258\", 3,\n 5.97569, 1.01194, 0.27573,\n -1.62227, 0.00000, 0.00000, 0.15773, 0.00000, 0.00000, 1.93964,\n 194.5844943, 0.55601, 5.180e-04,\n -7.4703700, -0.28979, 2.710e-04,\n// 2490 9 28\n2630785.459967, 23.0, 1416.0, \" 0.728\", \"-0.317\", 3,\n 23.55704, 0.93284, 0.25418,\n -1.94659, 0.00000, 0.00000, 0.03922, 0.00000, 0.00000, 2.02333,\n 5.4411400, 0.46759, -5.000e-05,\n 3.5309502, 0.25256, -2.140e-04,\n// 2491 2 24\n2630934.173217, 16.0, 1417.7, \" 1.303\", \" 0.246\", 2,\n 2.32864, 0.93691, 0.25528,\n -2.33936, -0.78992, 0.00000, 0.15721, 0.00000, 1.10710, 2.65352,\n 158.3126381, 0.48491, -1.700e-04,\n 9.9499199, -0.24176, -4.440e-04,\n// 2491 8 19\n2631110.494675, 0.0, 1419.8, \" 1.442\", \" 0.484\", 2,\n 21.91548, 1.00777, 0.27459,\n -2.47490, -1.32429, 0.00000, -0.12780, 0.00000, 1.06706, 2.21866,\n 330.1842672, 0.57274, -7.790e-04,\n -12.9347092, 0.26459, 5.460e-04,\n// 2492 2 13\n2631288.256483, 18.0, 1421.9, \" 2.575\", \" 1.476\", 1,\n 3.59540, 0.90208, 0.24580,\n -2.96955, -1.76708, -0.64137, 0.15560, 0.95271, 2.07845, 3.27988,\n 147.2423358, 0.46325, -3.420e-04,\n 13.3449500, -0.20812, -4.460e-04,\n// 2492 8 8\n2631465.199498, 17.0, 1423.9, \" 2.793\", \" 1.851\", 1,\n 14.22330, 1.02267, 0.27865,\n -2.85667, -1.97530, -1.04008, -0.21204, 0.61604, 1.55129, 2.43235,\n 320.0705602, 0.60728, -6.870e-04,\n -15.5143205, 0.24846, 8.470e-04,\n// 2493 2 1\n2631642.223159, 17.0, 1426.0, \" 1.985\", \" 0.891\", 2,\n 1.85394, 0.90899, 0.24768,\n -2.59748, -1.31788, 0.00000, 0.35581, 0.00000, 2.02883, 3.31022,\n 135.6259735, 0.48810, -5.760e-04,\n 16.3639909, -0.18681, -5.200e-04,\n// 2493 7 29\n2631819.870192, 9.0, 1428.1, \" 1.489\", \" 0.518\", 2,\n 5.52839, 0.99211, 0.27033,\n -2.53046, -1.36403, 0.00000, -0.11540, 0.00000, 1.13524, 2.30016,\n 309.5906185, 0.59139, -4.420e-04,\n -17.6633388, 0.20366, 9.600e-04,\n// 2494 1 21\n2631996.387331, 21.0, 1430.2, \" 0.753\", \"-0.291\", 3,\n 5.12617, 0.95325, 0.25974,\n -1.67491, 0.00000, 0.00000, 0.29594, 0.00000, 0.00000, 2.26484,\n 123.9779465, 0.55625, -7.930e-04,\n 18.6066699, -0.17097, -7.440e-04,\n// 2494 6 19\n2632144.800479, 7.0, 1431.9, \" 0.713\", \"-0.338\", 3,\n 0.87861, 0.91758, 0.25002,\n -1.79062, 0.00000, 0.00000, 0.21151, 0.00000, 0.00000, 2.21543,\n 268.8145531, 0.56205, -1.800e-05,\n -24.4610197, 0.04194, 1.052e-03,\n// 2494 7 18\n2632174.323076, 20.0, 1432.3, \" 0.007\", \"-1.017\", 3,\n 15.81979, 0.93994, 0.25611,\n -0.44829, 0.00000, 0.00000, -0.24618, 0.00000, 0.00000, -0.03839,\n 298.8304751, 0.54823, -2.780e-04,\n -19.2400401, 0.14922, 8.750e-04,\n// 2494 12 12\n2632321.394248, 21.0, 1434.0, \" 1.133\", \" 0.161\", 2,\n 2.48187, 1.02109, 0.27822,\n -1.67353, -0.25245, 0.00000, 0.46194, 0.00000, 1.17530, 2.59708,\n 80.2549140, 0.69408, -1.830e-04,\n 24.0494803, -0.01490, -1.563e-03,\n// 2495 6 8\n2632498.850931, 8.0, 1436.1, \" 2.079\", \" 1.006\", 1,\n 1.14263, 0.89973, 0.24516,\n -2.57726, -1.33741, 0.31512, 0.42233, 0.52948, 2.18199, 3.42198,\n 256.9639563, 0.53728, -2.000e-05,\n -23.2534200, 0.00123, 9.140e-04,\n// 2495 12 2\n2632676.053422, 13.0, 1438.2, \" 2.356\", \" 1.380\", 1,\n 17.78696, 1.01533, 0.27665,\n -2.36840, -1.42397, -0.39743, 0.28214, 0.96196, 1.98863, 2.93201,\n 68.7971555, 0.67636, 3.160e-04,\n 22.2357099, 0.03235, -1.391e-03,\n// 2496 5 27\n2632852.923534, 10.0, 1440.3, \" 2.299\", \" 1.253\", 1,\n 2.40938, 0.92414, 0.25181,\n -2.78943, -1.65800, -0.46249, 0.16482, 0.79159, 1.98687, 3.12035,\n 245.6146134, 0.55716, -4.600e-05,\n -21.1986993, -0.03769, 9.260e-04,\n// 2496 11 21\n2633030.596576, 2.0, 1442.4, \" 2.061\", \" 1.041\", 1,\n 6.08383, 0.96972, 0.26423,\n -2.41909, -1.33520, 0.05880, 0.31781, 0.57773, 1.97193, 3.05344,\n 57.4819636, 0.60356, 5.230e-04,\n 19.6056106, 0.07027, -9.740e-04,\n// 2497 5 16\n2633207.266065, 18.0, 1444.5, \" 0.935\", \"-0.059\", 3,\n 9.69257, 0.97511, 0.26569,\n -1.69786, 0.00000, 0.00000, 0.38556, 0.00000, 0.00000, 2.46716,\n 234.5913438, 0.60441, 3.000e-05,\n -18.3815588, -0.08174, 9.880e-04,\n// 2497 11 10\n2633384.864447, 9.0, 1446.6, \" 0.698\", \"-0.374\", 3,\n 12.36427, 0.91942, 0.25052,\n -2.24435, 0.00000, 0.00000, -0.25327, 0.00000, 0.00000, 1.73965,\n 46.6763790, 0.52813, 4.180e-04,\n 16.3026302, 0.09517, -6.260e-04,\n// 2498 4 7\n2633532.524496, 1.0, 1448.3, \" 1.262\", \" 0.306\", 2,\n 14.06743, 1.02425, 0.27908,\n -2.61836, -1.37324, 0.00000, -0.41209, 0.00000, 0.54913, 1.79456,\n 196.4896116, 0.61525, 2.760e-04,\n -7.9128100, -0.18786, 4.530e-04,\n// 2498 9 30\n2633709.170552, 16.0, 1450.4, \" 1.006\", \"-0.069\", 3,\n 16.67342, 0.90636, 0.24696,\n -2.26061, 0.00000, 0.00000, 0.09324, 0.00000, 0.00000, 2.44685,\n 7.2628697, 0.47786, 1.000e-06,\n 4.1423501, 0.15459, -1.740e-04,\n// 2499 3 27\n2633887.182571, 16.0, 1452.5, \" 2.536\", \" 1.554\", 1,\n 4.36977, 1.00090, 0.27272,\n -2.33492, -1.38388, -0.39399, 0.38170, 1.15771, 2.14783, 3.09722,\n 186.5096944, 0.58077, 3.010e-04,\n -3.0131301, -0.18756, 9.000e-05,\n// 2499 9 19\n2634063.343252, 20.0, 1454.6, \" 2.400\", \" 1.374\", 1,\n 19.94566, 0.94714, 0.25807,\n -2.64643, -1.57973, -0.47683, 0.23806, 0.95241, 2.05512, 3.12442,\n 357.4668841, 0.52007, -2.400e-04,\n -0.8174600, 0.16966, -3.700e-05,\n// 2500 3 17\n2634241.646151, 4.0, 1456.8, \" 1.838\", \" 0.800\", 2,\n 15.66391, 0.94906, 0.25860,\n -3.22551, -2.03686, 0.00000, -0.49237, 0.00000, 1.05362, 2.23948,\n 177.3318189, 0.52250, 1.710e-04,\n 1.7620799, -0.17061, -1.450e-04,\n// 2500 9 9\n2634417.823599, 8.0, 1458.8, \" 1.933\", \" 0.963\", 2,\n 7.23979, 0.99878, 0.27214,\n -2.81886, -1.80531, 0.00000, -0.23364, 0.00000, 1.33690, 2.35201,\n 348.3334732, 0.58130, -3.870e-04,\n -5.5431301, 0.18349, 2.190e-04\n));\n}", "title": "" }, { "docid": "774ceac2704b466fa2af84edee6427af", "score": "0.50953496", "text": "function bruteForceHull(newPoints) {\n\tvar tempPoints = [];\n\tvar lineSegments = [];\n\tif(newPoints.length == 1){\n\n\t\ttempPoints.push(newPoints[0]);\n\t\treturn [tempPoints, lineSegments];\n\n\t} else if (newPoints.length == 2){\n\t\t\n\t\tvar p1 = newPoints[0];\n\t\tvar p2 = newPoints[1];\n\n\t\tif(p1.x < p2.x){\n\t\t\ttempPoints.push(p1);\n\t\t\ttempPoints.push(p2);\n\t\t\tlineSegments.push(new LineObj(p1.x, p1.y, p2.x, p2.y));\n\t\t} else {\n\t\t\ttempPoints.push(p2);\n\t\t\ttempPoints.push(p1);\n\t\t\tlineSegments.push(new LineObj(p2.x, p2.y, p1.x, p1.y));\n\t\t}\n\n\t\t\n\t\treturn [tempPoints, lineSegments];\n\n\t} else {\n\n\t\tfor(var i=0; i<newPoints.length; ++i){\n\t\t\ttempPoints.push(newPoints[i]);\n\t\t}\n\t\tvar p1 = newPoints[0];\n\t\tvar p2 = newPoints[1];\n\t\tvar p3 = newPoints[2];\n\n\t\tif(isClockwise(p1,p2,p3)){\n\t\t\ttempPoints = newPoints.reverse();\n\t\t\tfor(var i=0; i<3; ++i){\n\t\t\t\tp1 = tempPoints[i];\n\t\t\t\tp2 = tempPoints[(i+1)%3];\n\t\t\t\tlineSegments.push(new LineObj(p1.x, p1.y, p2.x, p2.y));\n\n\t\t\t}\n\t\t\treturn [tempPoints,lineSegments];\n\t\t} else {\n\t\t\ttempPoints = newPoints;\n\t\t\tfor(var i=0; i<3; ++i){\n\t\t\t\tp1 = tempPoints[i];\n\t\t\t\tp2 = tempPoints[(i+1)%3];\n\t\t\t\tlineSegments.push(new LineObj(p1.x, p1.y, p2.x, p2.y));\n\t\t\t}\n\t\t\treturn [tempPoints,lineSegments];\n\t\t}\n\t}\n}", "title": "" }, { "docid": "49bc7f222f1a347c2d30b409da938ff6", "score": "0.5081869", "text": "function p13() {\n var numbers = [ \n \"37107287533902102798797998220837590246510135740250\",\n \"46376937677490009712648124896970078050417018260538\",\n \"74324986199524741059474233309513058123726617309629\",\n \"91942213363574161572522430563301811072406154908250\",\n \"23067588207539346171171980310421047513778063246676\",\n \"89261670696623633820136378418383684178734361726757\",\n \"28112879812849979408065481931592621691275889832738\",\n \"44274228917432520321923589422876796487670272189318\",\n \"47451445736001306439091167216856844588711603153276\",\n \"70386486105843025439939619828917593665686757934951\",\n \"62176457141856560629502157223196586755079324193331\",\n \"64906352462741904929101432445813822663347944758178\",\n \"92575867718337217661963751590579239728245598838407\",\n \"58203565325359399008402633568948830189458628227828\",\n \"80181199384826282014278194139940567587151170094390\",\n \"35398664372827112653829987240784473053190104293586\",\n \"86515506006295864861532075273371959191420517255829\",\n \"71693888707715466499115593487603532921714970056938\",\n \"54370070576826684624621495650076471787294438377604\",\n \"53282654108756828443191190634694037855217779295145\",\n \"36123272525000296071075082563815656710885258350721\",\n \"45876576172410976447339110607218265236877223636045\",\n \"17423706905851860660448207621209813287860733969412\",\n \"81142660418086830619328460811191061556940512689692\",\n \"51934325451728388641918047049293215058642563049483\",\n \"62467221648435076201727918039944693004732956340691\",\n \"15732444386908125794514089057706229429197107928209\",\n \"55037687525678773091862540744969844508330393682126\",\n \"18336384825330154686196124348767681297534375946515\",\n \"80386287592878490201521685554828717201219257766954\",\n \"78182833757993103614740356856449095527097864797581\",\n \"16726320100436897842553539920931837441497806860984\",\n \"48403098129077791799088218795327364475675590848030\",\n \"87086987551392711854517078544161852424320693150332\",\n \"59959406895756536782107074926966537676326235447210\",\n \"69793950679652694742597709739166693763042633987085\",\n \"41052684708299085211399427365734116182760315001271\",\n \"65378607361501080857009149939512557028198746004375\",\n \"35829035317434717326932123578154982629742552737307\",\n \"94953759765105305946966067683156574377167401875275\",\n \"88902802571733229619176668713819931811048770190271\",\n \"25267680276078003013678680992525463401061632866526\",\n \"36270218540497705585629946580636237993140746255962\",\n \"24074486908231174977792365466257246923322810917141\",\n \"91430288197103288597806669760892938638285025333403\",\n \"34413065578016127815921815005561868836468420090470\",\n \"23053081172816430487623791969842487255036638784583\",\n \"11487696932154902810424020138335124462181441773470\",\n \"63783299490636259666498587618221225225512486764533\",\n \"67720186971698544312419572409913959008952310058822\",\n \"95548255300263520781532296796249481641953868218774\",\n \"76085327132285723110424803456124867697064507995236\",\n \"37774242535411291684276865538926205024910326572967\",\n \"23701913275725675285653248258265463092207058596522\",\n \"29798860272258331913126375147341994889534765745501\",\n \"18495701454879288984856827726077713721403798879715\",\n \"38298203783031473527721580348144513491373226651381\",\n \"34829543829199918180278916522431027392251122869539\",\n \"40957953066405232632538044100059654939159879593635\",\n \"29746152185502371307642255121183693803580388584903\",\n \"41698116222072977186158236678424689157993532961922\",\n \"62467957194401269043877107275048102390895523597457\",\n \"23189706772547915061505504953922979530901129967519\",\n \"86188088225875314529584099251203829009407770775672\",\n \"11306739708304724483816533873502340845647058077308\",\n \"82959174767140363198008187129011875491310547126581\",\n \"97623331044818386269515456334926366572897563400500\",\n \"42846280183517070527831839425882145521227251250327\",\n \"55121603546981200581762165212827652751691296897789\",\n \"32238195734329339946437501907836945765883352399886\",\n \"75506164965184775180738168837861091527357929701337\",\n \"62177842752192623401942399639168044983993173312731\",\n \"32924185707147349566916674687634660915035914677504\",\n \"99518671430235219628894890102423325116913619626622\",\n \"73267460800591547471830798392868535206946944540724\",\n \"76841822524674417161514036427982273348055556214818\",\n \"97142617910342598647204516893989422179826088076852\",\n \"87783646182799346313767754307809363333018982642090\",\n \"10848802521674670883215120185883543223812876952786\",\n \"71329612474782464538636993009049310363619763878039\",\n \"62184073572399794223406235393808339651327408011116\",\n \"66627891981488087797941876876144230030984490851411\",\n \"60661826293682836764744779239180335110989069790714\",\n \"85786944089552990653640447425576083659976645795096\",\n \"66024396409905389607120198219976047599490197230297\",\n \"64913982680032973156037120041377903785566085089252\",\n \"16730939319872750275468906903707539413042652315011\",\n \"94809377245048795150954100921645863754710598436791\",\n \"78639167021187492431995700641917969777599028300699\",\n \"15368713711936614952811305876380278410754449733078\",\n \"40789923115535562561142322423255033685442488917353\",\n \"44889911501440648020369068063960672322193204149535\",\n \"41503128880339536053299340368006977710650566631954\",\n \"81234880673210146739058568557934581403627822703280\",\n \"82616570773948327592232845941706525094512325230608\",\n \"22918802058777319719839450180888072429661980811197\",\n \"77158542502016545090413245809786882778948721859617\",\n \"72107838435069186155435662884062257473692284509516\",\n \"20849603980134001723930671666823555245252804609722\",\n \"53503534226472524250874054075591789781264330331690\"];\n console.log(euler.add(numbers));\n}", "title": "" }, { "docid": "f8ad9dd780e651a8cc1b8b60430ba829", "score": "0.5079863", "text": "add(p1, p2){\n if(p1.x === 0n && p1.y === 0n ) return p2;\n else if(p2.x === 0n && p2.y === 0n) return p1;\n else if(p1.x === p2.x && p1.y === p2.y) {\n return this.double(p1);\n }\n else {\n //I am messing too much with commutativity. This is not commutative so i am forcing the comunatiivity myself\n let min;\n let max;\n if(p2.x > p1.x) {\n max = p2;\n min = p1;\n } else {\n max = p1;\n min = p2;\n }\n let s = mod((max.y - min.y) * modinv(max.x - min.x, this.P), this.P);\n let x3 = mod((s ** 2n - max.x - min.x), this.P);\n let y3 = mod(s * ( min.x - x3) - min.y, this.P);\n return new Point(x3, y3 );\n }\n }", "title": "" }, { "docid": "e8d272095ef6e94357ec0a3b231ad7d4", "score": "0.5065317", "text": "function ex1_picard(){\n let u_n = u0;\n let u_n1 = u0;\n let u_mikro = 0.;\n\n let ta = []; //accepts t\n let ya = []; //accepts u_n1\n let yb = []; //accepts N - u_n1\n\n ta.push(0.);\n ya.push(u_n1);\n yb.push(N - u_n1);\n\n for(let t = 0.1; t < 100.; t += dt){\n let iteracja_mi = 0;\n u_n = u_n1;\n u_mikro = 0.;\n\n while(1){\n \n if((Math.abs(u_n1-u_mikro) < TOL) || iteracja_mi++ > iteracje_max){\n break;\n }\n\n u_mikro = u_n1;\n u_n1 = u_n + (dt / 2.) * (f(u_n) + f(u_mikro));\n }\n\n ta.push(t);\n ya.push(u_n1);\n yb.push(N - u_n1);\n }\n\n /* We return an object, containing our 3 arrays */\n return {\n t: ta,\n y: ya,\n y2: yb\n }\n}", "title": "" }, { "docid": "62f51bbad63c7268732c2b20852896ef", "score": "0.5061527", "text": "function printUnorderedPairs(array) {\n //time complexity= n * ((n)+(n-1)+(n-2)...)\n //= (n) * (1/2)(n+1)\n //drop coefs (1/2) and lower order terms (1)\n //= n*n\n\n for (var i = 0; i < array.length; i++) {\n for (var j = i; j < array.length; j++) {\n console.log(array[i] + \",\" + array[j]); //constant space\n }\n }\n}", "title": "" }, { "docid": "2fc5435992bd5f3379629d871c698025", "score": "0.5049234", "text": "function findSpecialPythagoreanЕriplet()\n{\n\n\t// time: 1.731 seconds.\n\t\n\tvar d0 = new Date();\n\tvar PythagoreanTripletArr = [];\n\tvar sum = 0;\n\t\n\t\n\tfor(var c=0; c<1000; c++)\n\t{\n\t\tfor(var b=0; b<1000; b++)\n\t\t{\n\t\t\tfor(var a=0; a<1000; a++)\n\t\t\t{\n\t\t\t\tif(b<c)\n\t\t\t\t{\n\t\t\t\t\tif(a<b)\n\t\t\t\t\t{\n\t\t\t\t\t\tsum = (a+b+c);\n\t\t\t\t\t\tif(sum == 1000)\n\t\t\t\t\t\t{\n\t\t\t\t\t\t\tvar flag = (Math.pow(a,2) + Math.pow(b,2)) == Math.pow(c,2);\n\t\t\t\t\t\t\tif(flag)\n\t\t\t\t\t\t\t{\n\t\t\t\t\t\t\t\tPythagoreanTripletArr.push(a);\n\t\t\t\t\t\t\t\tPythagoreanTripletArr.push(b);\n\t\t\t\t\t\t\t\tPythagoreanTripletArr.push(c);\n\t\t\t\t\t\t\t\tconsole.log(\"Answer: \" + (a*b*c));\n\t\t\t\t\t\t\t\tbreak;\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t\n\tvar d1 = new Date();\n\tconsole.log(\"time: \" + (d1.getTime() - d0.getTime())/1000 + \" seconds.\");\n}", "title": "" } ]
561a4189ca238d2293734aaa39e855f3
Compose a matcher function with the given patterns. This allows matcher functions to be compiled once and called multiple times.
[ { "docid": "4880516b08b062c94fb48bfaecf42c23", "score": "0.7269761", "text": "function compose(patterns, options, matcher) {\n var matchers;\n return memoize('compose', String(patterns), options, function () {\n return function (file) {\n // delay composition until it's invoked the first time,\n // after that it won't be called again\n if (!matchers) {\n matchers = [];\n\n for (var i = 0; i < patterns.length; i++) {\n matchers.push(matcher(patterns[i], options));\n }\n }\n\n var len = matchers.length;\n\n while (len--) {\n if (matchers[len](file) === true) {\n return true;\n }\n }\n\n return false;\n };\n });\n}", "title": "" } ]
[ { "docid": "f82ef8a9823b96f89a9b8908e897e754", "score": "0.7253778", "text": "function compose$1(patterns, options, matcher) {\n var matchers;\n\n return memoize$3('compose', String(patterns), options, function() {\n return function(file) {\n // delay composition until it's invoked the first time,\n // after that it won't be called again\n if (!matchers) {\n matchers = [];\n for (var i = 0; i < patterns.length; i++) {\n matchers.push(matcher(patterns[i], options));\n }\n }\n\n var len = matchers.length;\n while (len--) {\n if (matchers[len](file) === true) {\n return true;\n }\n }\n return false;\n };\n });\n}", "title": "" }, { "docid": "20b167e1cd07d076bbe959217ecd73ea", "score": "0.7221715", "text": "function compose(patterns, options, matcher) {\n var matchers;\n\n return memoize('compose', String(patterns), options, function() {\n return function(file) {\n // delay composition until it's invoked the first time,\n // after that it won't be called again\n if (!matchers) {\n matchers = [];\n for (var i = 0; i < patterns.length; i++) {\n matchers.push(matcher(patterns[i], options));\n }\n }\n\n var len = matchers.length;\n while (len--) {\n if (matchers[len](file) === true) {\n return true;\n }\n }\n return false;\n };\n });\n}", "title": "" }, { "docid": "20b167e1cd07d076bbe959217ecd73ea", "score": "0.7221715", "text": "function compose(patterns, options, matcher) {\n var matchers;\n\n return memoize('compose', String(patterns), options, function() {\n return function(file) {\n // delay composition until it's invoked the first time,\n // after that it won't be called again\n if (!matchers) {\n matchers = [];\n for (var i = 0; i < patterns.length; i++) {\n matchers.push(matcher(patterns[i], options));\n }\n }\n\n var len = matchers.length;\n while (len--) {\n if (matchers[len](file) === true) {\n return true;\n }\n }\n return false;\n };\n });\n}", "title": "" }, { "docid": "f953ae8d9cf4689afeec102d780ac22b", "score": "0.71786964", "text": "function compose(patterns, options, matcher) {\n var matchers;\n\n return memoize$2('compose', String(patterns), options, function() {\n return function(file) {\n // delay composition until it's invoked the first time,\n // after that it won't be called again\n if (!matchers) {\n matchers = [];\n for (var i = 0; i < patterns.length; i++) {\n matchers.push(matcher(patterns[i], options));\n }\n }\n\n var len = matchers.length;\n while (len--) {\n if (matchers[len](file) === true) {\n return true;\n }\n }\n return false;\n };\n });\n}", "title": "" }, { "docid": "2c598302abe40aa622f152342a125f53", "score": "0.6146762", "text": "function buildMatchFn(sites) {\n\n var matchers = sites.map(function(site) {\n var pat = site;\n var wild_host = (pat[0]=='.');\n var wild_path = (pat.slice(-3)=='...');\n\n if(wild_host) {\n pat = pat.slice(1);\n }\n if(wild_path) {\n pat = pat.slice(0,-3);\n }\n\n pat = pat.replace( /[.]/g, \"[.]\");\n\n if(wild_host) {\n pat = '[^/]*' + pat;\n }\n\n pat = \"https?://\" + pat + '.*';\n\n return new RegExp(pat);\n });\n\n\n return function (url) {\n for (var idx = 0; idx < matchers.length; idx++) {\n var re = matchers[idx];\n if( re.test(url)) {\n return true;\n }\n }\n return false;\n };\n}", "title": "" }, { "docid": "9d2597b50562003283bcf975eaf4f663", "score": "0.6052621", "text": "function makeMatcher(makeRegexpFn = pathToRegexp) {\n let cache = {};\n\n // obtains a cached regexp version of the pattern\n const getRegexp = pattern =>\n (cache[pattern]) || (cache[pattern] = makeRegexpFn(pattern));\n\n return (pattern, path) => {\n const { regexp, keys } = getRegexp(pattern || \"\");\n const out = regexp.exec(path);\n\n if (!out) return [false, null];\n\n // formats an object with matched params\n const params = keys.reduce((params, key, i) => {\n params[key.name] = out[i + 1];\n return params;\n }, {});\n\n return [true, params];\n };\n}", "title": "" }, { "docid": "350bde189a25885b797b2097fa0325b7", "score": "0.58431715", "text": "function patternFactory() {\n var len,\n j,\n newPattern,\n funcs = arguments; // each argument is a pattern being combined\n\n len = funcs.length;\n\n for (j = 0; j < len; j += 1) {\n if (typeof funcs[j] !== \"function\") {\n funcs[j] = createSequenceFunc(funcs[j]);\n }\n }\n\n newPattern = concatenatePatternFuncs(funcs);\n\n return function (args) {\n if (typeof args === \"number\") {\n newPattern(args);\n } else {\n executeSequence(args, newPattern, emptyFunc);\n }\n };\n }", "title": "" }, { "docid": "58dfffffee03cbdbd8737653cab1dedc", "score": "0.5790365", "text": "function concatenatePatternFuncs() {\n var funcs = arguments,\n len = arguments.length;\n\n return function (duration) {\n var i = 0,\n d = duration / len;\n\n function executeCurrentFunc() {\n funcs[i](d);\n }\n\n for (i = 0; i < len; i += 1) {\n global.setTimeout(executeCurrentFunc, d);\n }\n };\n }", "title": "" }, { "docid": "6e529a77e471e6dd2ec697a1ce1e7e34", "score": "0.5764924", "text": "addMatchingFunc(name, fn) {\n return __awaiter(this, void 0, void 0, function* () {\n this.hasPattern = true;\n this.matchingFunc = fn;\n });\n }", "title": "" }, { "docid": "76d69825989a00ef7cdfb80af6232d12", "score": "0.57320523", "text": "function patternMatcher(pattern, string) {\n // Write your code here.\n}", "title": "" }, { "docid": "275e98a50880a6d379a7a2966ba43548", "score": "0.5626003", "text": "fnmatch(pattern) {\n if (pattern.indexOf('*') === -1) {\n return filename => pattern === filename;\n } else {\n let reRegExpChar = /[\\\\^$.*+?()[\\]{}|]/g;\n let escaped = pattern.replace(reRegExpChar, '\\\\$&');\n let matcher = new RegExp('^' + escaped.replace(/\\\\\\*/g, '.*') + '$');\n return filename => matcher.test(filename);\n }\n }", "title": "" }, { "docid": "de3d0ca2e42b7f26a467bb963ae3c458", "score": "0.5617516", "text": "function test(pattern) {\n return function(s) {\n return withRegex (pattern, function() { return pattern.test (s); });\n };\n }", "title": "" }, { "docid": "dc87839e3cc18dc5bd59cd04a89829fb", "score": "0.56126046", "text": "function _getMatcher(matchMap) {\n return function (fn) {\n var postFns = [];\n\n for (var _i = 1; _i < arguments.length; _i++) {\n postFns[_i - 1] = arguments[_i];\n }\n\n return function (selector) {\n var _a;\n\n var matched = matchMap(fn, this);\n\n if (selector) {\n matched = filterArray(matched, selector, this.options.xmlMode, (_a = this._root) === null || _a === void 0 ? void 0 : _a[0]);\n }\n\n return this._make( // Post processing is only necessary if there is more than one element.\n this.length > 1 && matched.length > 1 ? postFns.reduce(function (elems, fn) {\n return fn(elems);\n }, matched) : matched);\n };\n };\n}", "title": "" }, { "docid": "9151fbb62d980d7ebf4ec8aeb312475a", "score": "0.5593745", "text": "function matcher(regexp){\n return function(value){return regexp.test(value);};\n}", "title": "" }, { "docid": "7db45adb8eec2cae4e2240e2f9375bb8", "score": "0.55734646", "text": "function filter(patterns) {\n if (typeof patterns === 'function') {\n return patterns;\n }\n\n return function(str) {\n var arr = ['\\\\[\\\\!\\\\[', '{%', '<%'].concat(patterns || []);\n var re = new RegExp(arr.join('|'));\n return !re.test(str);\n };\n}", "title": "" }, { "docid": "c469109da04d09a5774c71d5632d7e01", "score": "0.5489483", "text": "function patternMatcher(pattern) {\n return function(path, stats) {\n var minimatcher = new minimatch.Minimatch(pattern, {matchBase: true})\n return (!minimatcher.negate || stats.isFile()) && minimatcher.match(path)\n }\n }", "title": "" }, { "docid": "db0ce5cc34483c37bd1ed68d724ecfec", "score": "0.5470965", "text": "function buildRegEx(reMatchStrings) {\n return new RegExp(\n reMatchStrings\n .reduce(\n (re, fileType, i) => `${re}${i === 0 ? '' : '|' }(${fileType})`, ''\n )\n + ('$')\n );\n}", "title": "" }, { "docid": "e53e962e4a9a3efaa94013845462e19c", "score": "0.5420135", "text": "function isAnyOf() {\n for (var _len = arguments.length, matchers = new Array(_len), _key = 0; _key < _len; _key++) {\n matchers[_key] = arguments[_key];\n }\n\n return function (action) {\n return matchers.some(function (matcher) {\n return matches(matcher, action);\n });\n };\n}", "title": "" }, { "docid": "55f1a2f6cb152c3c63fbb2d27febe465", "score": "0.5415681", "text": "function is(...patterns) {\n return patterns.some((pattern) => {\n if (minimatch(fileName, pattern)) {\n return true;\n }\n });\n }", "title": "" }, { "docid": "e02475391d195ba78826a201195982ea", "score": "0.539885", "text": "function _getMatcher(matchMap) {\n return function (fn, ...postFns) {\n return function (selector) {\n var _a;\n let matched = matchMap(fn, this);\n if (selector) {\n matched = filterArray(matched, selector, this.options.xmlMode, (_a = this._root) === null || _a === void 0 ? void 0 : _a[0]);\n }\n return this._make(\n // Post processing is only necessary if there is more than one element.\n this.length > 1 && matched.length > 1\n ? postFns.reduce((elems, fn) => fn(elems), matched)\n : matched);\n };\n };\n}", "title": "" }, { "docid": "b01d6383d1ae8babb1845686dc5f255f", "score": "0.5394875", "text": "function glob(/* patterns... */) {\n return glob.pattern.apply(null, arguments);\n }", "title": "" }, { "docid": "c9c184e99f282a8e118b45b5d7c0ff7f", "score": "0.5350228", "text": "function isAllOf() {\n for (var _len2 = arguments.length, matchers = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) {\n matchers[_key2] = arguments[_key2];\n }\n\n return function (action) {\n return matchers.every(function (matcher) {\n return matches(matcher, action);\n });\n };\n}", "title": "" }, { "docid": "3d5be2c3bcb95267bb3be0c11ad33523", "score": "0.5343434", "text": "function _filterPattern(filenames, patterns) {\n\t\n\tvar minimatch = require( 'minimatch' ),\n\t matching = new Set();\n\t\n\tif ( !Array.isArray(patterns) ) {\n\t\tpatterns = [ patterns ];\n\t}\n\t\t\n\tfor (var pattern of patterns) {\n\t\tfor (var filename of filenames) {\n\t\t\tif (minimatch(filename, pattern)) {\n\t\t\t\tmatching.add(filename);\n\t\t\t}\n\t\t}\n\t}\n\t\n\treturn matching;\n}", "title": "" }, { "docid": "2e06edf629dc09b1195ceb5d4f819588", "score": "0.5334871", "text": "function match(patterns, itemPath) {\n let result = internalMatchKind.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "7b55c0d293b8a11aadef5a22ffdacc1f", "score": "0.52821445", "text": "function compilePathPattern0(pat) {\n const keys = [];\n const rgx = pathToRegexp(pat, keys);\n return path => rgx.exec(path);\n}", "title": "" }, { "docid": "a695848c2a5a0f7c41c107ed25e59a2b", "score": "0.5253277", "text": "findAndExecute(...patterns) {\n\t\treturn this.find(...patterns).map(pattern => importFresh(pattern));\n\t}", "title": "" }, { "docid": "0789b7c8f3fd52aacf6265fb6e163bf1", "score": "0.5207028", "text": "function regexpToFunction(re, keys, options = {}) {\n const { decode = (x) => x } = options;\n return function (pathname) {\n const m = re.exec(pathname);\n if (!m)\n return false;\n const { 0: path, index } = m;\n const params = Object.create(null);\n for (let i = 1; i < m.length; i++) {\n if (m[i] === undefined)\n continue;\n const key = keys[i - 1];\n if (key.modifier === '*' || key.modifier === '+') {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(value => {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n }\n return { path, index, params };\n };\n}", "title": "" }, { "docid": "581300824381b7a19f1ba47ae0fcf285", "score": "0.5202844", "text": "function match(patterns, itemPath) {\n let result = internal_match_kind_1.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "581300824381b7a19f1ba47ae0fcf285", "score": "0.5202844", "text": "function match(patterns, itemPath) {\n let result = internal_match_kind_1.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "581300824381b7a19f1ba47ae0fcf285", "score": "0.5202844", "text": "function match(patterns, itemPath) {\n let result = internal_match_kind_1.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "581300824381b7a19f1ba47ae0fcf285", "score": "0.5202844", "text": "function match(patterns, itemPath) {\n let result = internal_match_kind_1.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "581300824381b7a19f1ba47ae0fcf285", "score": "0.5202844", "text": "function match(patterns, itemPath) {\n let result = internal_match_kind_1.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "581300824381b7a19f1ba47ae0fcf285", "score": "0.5202844", "text": "function match(patterns, itemPath) {\n let result = internal_match_kind_1.MatchKind.None;\n for (const pattern of patterns) {\n if (pattern.negate) {\n result &= ~pattern.match(itemPath);\n }\n else {\n result |= pattern.match(itemPath);\n }\n }\n return result;\n}", "title": "" }, { "docid": "0217e8ccdb78c1b1a379baa00a210dd3", "score": "0.5177677", "text": "function tokensToFunction(tokens){// Compile all the tokens into regexps.\nvar matches=new Array(tokens.length);// Compile all the patterns before compilation.\nfor(var i=0;i<tokens.length;i++){if(_typeof2(tokens[i])==='object'){matches[i]=new RegExp('^(?:'+tokens[i].pattern+')$');}}return function(obj,opts){var path='';var data=obj||{};var options=opts||{};var encode=options.pretty?encodeURIComponentPretty:encodeURIComponent;for(var i=0;i<tokens.length;i++){var token=tokens[i];if(typeof token==='string'){path+=token;continue;}var value=data[token.name];var segment;if(value==null){if(token.optional){// Prepend partial segment prefixes.\nif(token.partial){path+=token.prefix;}continue;}else{throw new TypeError('Expected \"'+token.name+'\" to be defined');}}if(isarray(value)){if(!token.repeat){throw new TypeError('Expected \"'+token.name+'\" to not repeat, but received `'+JSON.stringify(value)+'`');}if(value.length===0){if(token.optional){continue;}else{throw new TypeError('Expected \"'+token.name+'\" to not be empty');}}for(var j=0;j<value.length;j++){segment=encode(value[j]);if(!matches[i].test(segment)){throw new TypeError('Expected all \"'+token.name+'\" to match \"'+token.pattern+'\", but received `'+JSON.stringify(segment)+'`');}path+=(j===0?token.prefix:token.delimiter)+segment;}continue;}segment=token.asterisk?encodeAsterisk(value):encode(value);if(!matches[i].test(segment)){throw new TypeError('Expected \"'+token.name+'\" to match \"'+token.pattern+'\", but received \"'+segment+'\"');}path+=token.prefix+segment;}return path;};}", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "06055aff8606cf531dd26138a67945cd", "score": "0.517295", "text": "function matcher(attrs) {\n attrs = extendOwn({}, attrs);\n return function(obj) {\n return isMatch(obj, attrs);\n };\n }", "title": "" }, { "docid": "527014fb34044f23ada91fca6bdbfac1", "score": "0.5168208", "text": "function tokensToFunction(tokens){// Compile all the tokens into regexps.\nvar matches=new Array(tokens.length);// Compile all the patterns before compilation.\nfor(var i=0;i<tokens.length;i++){if(_typeof(tokens[i])==='object'){matches[i]=new RegExp('^(?:'+tokens[i].pattern+')$');}}return function(obj,opts){var path='';var data=obj||{};var options=opts||{};var encode=options.pretty?encodeURIComponentPretty:encodeURIComponent;for(var i=0;i<tokens.length;i++){var token=tokens[i];if(typeof token==='string'){path+=token;continue;}var value=data[token.name];var segment;if(value==null){if(token.optional){// Prepend partial segment prefixes.\nif(token.partial){path+=token.prefix;}continue;}else{throw new TypeError('Expected \"'+token.name+'\" to be defined');}}if(isarray(value)){if(!token.repeat){throw new TypeError('Expected \"'+token.name+'\" to not repeat, but received `'+JSON.stringify(value)+'`');}if(value.length===0){if(token.optional){continue;}else{throw new TypeError('Expected \"'+token.name+'\" to not be empty');}}for(var j=0;j<value.length;j++){segment=encode(value[j]);if(!matches[i].test(segment)){throw new TypeError('Expected all \"'+token.name+'\" to match \"'+token.pattern+'\", but received `'+JSON.stringify(segment)+'`');}path+=(j===0?token.prefix:token.delimiter)+segment;}continue;}segment=token.asterisk?encodeAsterisk(value):encode(value);if(!matches[i].test(segment)){throw new TypeError('Expected \"'+token.name+'\" to match \"'+token.pattern+'\", but received \"'+segment+'\"');}path+=token.prefix+segment;}return path;};}", "title": "" }, { "docid": "527014fb34044f23ada91fca6bdbfac1", "score": "0.5168208", "text": "function tokensToFunction(tokens){// Compile all the tokens into regexps.\nvar matches=new Array(tokens.length);// Compile all the patterns before compilation.\nfor(var i=0;i<tokens.length;i++){if(_typeof(tokens[i])==='object'){matches[i]=new RegExp('^(?:'+tokens[i].pattern+')$');}}return function(obj,opts){var path='';var data=obj||{};var options=opts||{};var encode=options.pretty?encodeURIComponentPretty:encodeURIComponent;for(var i=0;i<tokens.length;i++){var token=tokens[i];if(typeof token==='string'){path+=token;continue;}var value=data[token.name];var segment;if(value==null){if(token.optional){// Prepend partial segment prefixes.\nif(token.partial){path+=token.prefix;}continue;}else{throw new TypeError('Expected \"'+token.name+'\" to be defined');}}if(isarray(value)){if(!token.repeat){throw new TypeError('Expected \"'+token.name+'\" to not repeat, but received `'+JSON.stringify(value)+'`');}if(value.length===0){if(token.optional){continue;}else{throw new TypeError('Expected \"'+token.name+'\" to not be empty');}}for(var j=0;j<value.length;j++){segment=encode(value[j]);if(!matches[i].test(segment)){throw new TypeError('Expected all \"'+token.name+'\" to match \"'+token.pattern+'\", but received `'+JSON.stringify(segment)+'`');}path+=(j===0?token.prefix:token.delimiter)+segment;}continue;}segment=token.asterisk?encodeAsterisk(value):encode(value);if(!matches[i].test(segment)){throw new TypeError('Expected \"'+token.name+'\" to match \"'+token.pattern+'\", but received \"'+segment+'\"');}path+=token.prefix+segment;}return path;};}", "title": "" }, { "docid": "cbbd0ca03162fbe86c54d115a344d633", "score": "0.5150312", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "9eb0c5f7de6eb4519568434df8f8e37e", "score": "0.5148106", "text": "function tokensToFunction(tokens){// Compile all the tokens into regexps.\n\tvar matches=new Array(tokens.length);// Compile all the patterns before compilation.\n\tfor(var i=0;i<tokens.length;i++){if(_typeof(tokens[i])==='object'){matches[i]=new RegExp('^(?:'+tokens[i].pattern+')$');}}return function(obj,opts){var path='';var data=obj||{};var options=opts||{};var encode=options.pretty?encodeURIComponentPretty:encodeURIComponent;for(var i=0;i<tokens.length;i++){var token=tokens[i];if(typeof token==='string'){path+=token;continue;}var value=data[token.name];var segment;if(value==null){if(token.optional){// Prepend partial segment prefixes.\n\tif(token.partial){path+=token.prefix;}continue;}else{throw new TypeError('Expected \"'+token.name+'\" to be defined');}}if(isarray(value)){if(!token.repeat){throw new TypeError('Expected \"'+token.name+'\" to not repeat, but received `'+JSON.stringify(value)+'`');}if(value.length===0){if(token.optional){continue;}else{throw new TypeError('Expected \"'+token.name+'\" to not be empty');}}for(var j=0;j<value.length;j++){segment=encode(value[j]);if(!matches[i].test(segment)){throw new TypeError('Expected all \"'+token.name+'\" to match \"'+token.pattern+'\", but received `'+JSON.stringify(segment)+'`');}path+=(j===0?token.prefix:token.delimiter)+segment;}continue;}segment=token.asterisk?encodeAsterisk(value):encode(value);if(!matches[i].test(segment)){throw new TypeError('Expected \"'+token.name+'\" to match \"'+token.pattern+'\", but received \"'+segment+'\"');}path+=token.prefix+segment;}return path;};}", "title": "" }, { "docid": "dd828fd377909b511f3fd3cfd1651b42", "score": "0.5139308", "text": "async addMatchingFunc(name, fn) {\n this.hasPattern = true;\n if (typeof name === 'string' && fn) {\n this.matchingFunc = fn;\n }\n else if (typeof name === 'function') {\n this.matchingFunc = name;\n }\n else {\n throw new Error('error: domain should be 1 parameter');\n }\n }", "title": "" }, { "docid": "e82c10d9a46d22f8e455ca8b93f152e4", "score": "0.51321477", "text": "find(...patterns) {\n\t\treturn globby.sync(flatten(patterns).map(pattern => this.resolve(pattern)));\n\t}", "title": "" }, { "docid": "2f1236aecbf68924f9c43a99aa2ce484", "score": "0.51165885", "text": "function regex(flags) {\n return function(source) {\n return new RegExp (source, flags);\n };\n }", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b8aa27e9b55ede2322c316709cdb43ec", "score": "0.5109667", "text": "function match(str, options) {\n var keys = [];\n var re = pathToRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "466d409656d7b873ee7fc0b6a6e10b83", "score": "0.51036", "text": "function getMatches(pattern, strings) {\n return strings\n .filter(s => s.indexOf(pattern) >= 0)\n .map(s => markupMatch(s, pattern));\n}", "title": "" }, { "docid": "679963f2d8969e0512d43a367f360d88", "score": "0.5095679", "text": "findAndRequire(...patterns) {\n\t\treturn this.find(...patterns).map(pattern => require(pattern));\n\t}", "title": "" }, { "docid": "8c129aa85d3c97bddef7aa83d7c99752", "score": "0.5087398", "text": "pattern() {\n return this.defs().pattern(...arguments);\n }", "title": "" }, { "docid": "95414541ba26e0d675d47dda1dbbb615", "score": "0.5081569", "text": "function replaceFunc(f) {\n return (...args) => { // args are [match, group1, group2, ..., offset, whole string, (some browsers:) named groups obj]\n const info = { // replace function will be called with this object\n match: args[0], // full matching string\n groups: [args[0]], // matched groups per index and, if available, by name\n offset: -1, // offset of match in all\n all: '', // full text in which match was found\n };\n let i=1;\n while(i<args.length && 'number' !== typeof args[i]) info.groups.push(args[i++]);\n info.offset = args[i];\n info.all = args[i+1];\n Object.entries(args[i+2] || {}).forEach(([k,v]) => info.groups[k] = v);\n return f.call(null, info);\n };\n}", "title": "" }, { "docid": "c5921ed7b96293f5a692e3fa5c9e52a2", "score": "0.5042415", "text": "function routeMatcher(paths) {\n // EXAMPLE. For the following paths:\n\n /* [\n \"/orgs/{org}/invitations\",\n \"/repos/{owner}/{repo}/collaborators/{username}\"\n ] */\n const regexes = paths.map(p => p.split(\"/\").map(c => c.startsWith(\"{\") ? \"(?:.+?)\" : c).join(\"/\")); // 'regexes' would contain:\n\n /* [\n '/orgs/(?:.+?)/invitations',\n '/repos/(?:.+?)/(?:.+?)/collaborators/(?:.+?)'\n ] */\n\n const regex = `^(?:${regexes.map(r => `(?:${r})`).join(\"|\")})[^/]*$`; // 'regex' would contain:\n\n /*\n ^(?:(?:\\/orgs\\/(?:.+?)\\/invitations)|(?:\\/repos\\/(?:.+?)\\/(?:.+?)\\/collaborators\\/(?:.+?)))[^\\/]*$\n It may look scary, but paste it into https://www.debuggex.com/\n and it will make a lot more sense!\n */\n\n return new RegExp(regex, \"i\");\n}", "title": "" }, { "docid": "dcac25399c3e8ecb690b170047a02e15", "score": "0.50327903", "text": "function joinRegex() {\r\n if( arguments.length < 2 ) {\r\n throw \"Minimum 2 RegExp arguments\";\r\n }\r\n\r\n var regex = new RegExp( arguments[0] );\r\n\r\n for( var i = 1; i < arguments.length; i++ ) {\r\n regex = new RegExp( regex.source + \"|\" + arguments[i].source );\r\n }\r\n\r\n return regex;\r\n }", "title": "" }, { "docid": "b6efb1e6a07dae3ebebb332b3f97c8fc", "score": "0.5021098", "text": "function match(str, options) {\n const keys = [];\n const re = toRegexp(str, keys, options);\n return regexpToFunction(re, keys, options);\n}", "title": "" }, { "docid": "b61b7738577b2fa93f03d4a28e25ac84", "score": "0.50161374", "text": "regexSelector(pattern) {\n this.registerRegexInput(pattern);\n }", "title": "" }, { "docid": "1ac9dcdca6a3fa16f7d6be7cfffa7543", "score": "0.5010059", "text": "function compilePathPattern2(pat, param1, param2) {\n const keys = [];\n const rgx = pathToRegexp(pat, keys);\n\n let param1Idx = 0;\n keys.forEach((k, i) => {\n if (k.name === param1) {\n param1Idx = i + 1;\n }\n });\n if (!param1Idx) {\n nogthrow(ERR_PARAM_INVALID, {\n reason: `Missing param \\`${param1}\\` in \\`${pat}\\`.`,\n });\n }\n\n let param2Idx = 0;\n keys.forEach((k, i) => {\n if (k.name === param2) {\n param2Idx = i + 1;\n }\n });\n if (!param2Idx) {\n nogthrow(ERR_PARAM_INVALID, {\n reason: `Missing param \\`${param2}\\` in \\`${pat}\\`.`,\n });\n }\n\n return function matchPath(path) {\n const m = rgx.exec(path);\n if (!m) {\n return null;\n }\n\n return [m[param1Idx], m[param2Idx]];\n };\n}", "title": "" }, { "docid": "58bb34fecf2ca8aad5a2a5779525b1f4", "score": "0.4990332", "text": "function matchPattern( val, tmpl ) {\n // TODO!\n }", "title": "" }, { "docid": "2f44a1cb626bd0a2873079c1e62e9c9a", "score": "0.49861446", "text": "function andSomeMatchers(subMatchers) {\n if (subMatchers.length === 0) {\n return everythingMatcher;\n }\n\n if (subMatchers.length === 1) {\n return subMatchers[0];\n }\n\n return function (docOrBranches) {\n var match = {};\n match.result = subMatchers.every(function (fn) {\n var subResult = fn(docOrBranches); // Copy a 'distance' number out of the first sub-matcher that has\n // one. Yes, this means that if there are multiple $near fields in a\n // query, something arbitrary happens; this appears to be consistent with\n // Mongo.\n\n if (subResult.result && subResult.distance !== undefined && match.distance === undefined) {\n match.distance = subResult.distance;\n } // Similarly, propagate arrayIndices from sub-matchers... but to match\n // MongoDB behavior, this time the *last* sub-matcher with arrayIndices\n // wins.\n\n\n if (subResult.result && subResult.arrayIndices) {\n match.arrayIndices = subResult.arrayIndices;\n }\n\n return subResult.result;\n }); // If we didn't actually match, forget any extra metadata we came up with.\n\n if (!match.result) {\n delete match.distance;\n delete match.arrayIndices;\n }\n\n return match;\n };\n }", "title": "" }, { "docid": "d92914d51965c9c89501163374420506", "score": "0.49669677", "text": "function withRegex(pattern, thunk) {\n var lastIndex = pattern.lastIndex;\n var result = thunk ();\n pattern.lastIndex = lastIndex;\n return result;\n }", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "b16374e58be6b8832537a3a9f505473f", "score": "0.49251878", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n // tslint:disable-next-line\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "f44f00b25da456fd0ebec57159818dcb", "score": "0.491513", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) {\n options = {};\n }\n\n var _a = options.decode,\n decode = _a === void 0 ? function (x) {\n return x;\n } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m) return false;\n var path = m[0],\n index = m.index;\n var params = Object.create(null);\n\n var _loop_1 = function _loop_1(i) {\n // tslint:disable-next-line\n if (m[i] === undefined) return \"continue\";\n var key = keys[i - 1];\n\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n } else {\n params[key.name] = decode(m[i], key);\n }\n };\n\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n\n return {\n path: path,\n index: index,\n params: params\n };\n };\n}", "title": "" }, { "docid": "9d05f818b577dcdc443533dd2c889307", "score": "0.49065247", "text": "function matches(regex) {\n var res = function (val) {\n regex.lastIndex = 0;\n return (0, isString_1.default)(val) && regex.test(val);\n };\n res.assert = (0, assert_1.default)(res);\n res.schema = 'matches(' + regex + ')';\n return res;\n}", "title": "" }, { "docid": "94359a8e1afb8395491ed1e703d066cb", "score": "0.4901188", "text": "function matcherFromTokens( tokens, context, xml ) {\n\tvar token, matcher,\n\t\ti = 0;\n\n\tfor ( ; (token = tokens[i]); i++ ) {\n\t\tif ( Expr.relative[ token.part ] ) {\n\t\t\tmatcher = addCombinator( matcher, Expr.relative[ token.part ], context );\n\t\t} else {\n\t\t\ttoken.captures.push( context, xml );\n\t\t\tmatcher = addMatcher( matcher, Expr.filter[ token.part ].apply( null, token.captures ) );\n\t\t}\n\t}\n\n\treturn matcher;\n}", "title": "" }, { "docid": "9a1932efb6a34f1fd98eebd801e7a903", "score": "0.48968482", "text": "function matches(msg, array_of_patterns) {\n var msg_lower = msg.toLowerCase(); //makes everything lowercase, doesn't matter if you type uppercase\n for(var i = 0; i < array_of_patterns.length; i++) {\n var pattern_lower = array_of_patterns[i].toLowerCase();\n if(msg_lower.search(pattern_lower) > -1) { //searches for matches in the patterns as listed above\n return true;\n }\n }\n return false; \n}", "title": "" }, { "docid": "2e17da35ac9a1143a3dba9b498fb6baa", "score": "0.4879215", "text": "static generateFiltersFunction(filters) {\n if (!filters || (!filters.length && !filters.count)) {\n return FunctionHelper.returnTrue;\n }\n\n return function(candidate) {\n let match = true;\n\n for (const filter of filters) {\n // Skip disabled filters\n if (!filter.disabled) {\n match = filter.filter(candidate);\n }\n if (!match) {\n break;\n }\n }\n\n return match;\n };\n }", "title": "" }, { "docid": "fe24367c433769914112ac828db0a374", "score": "0.48771685", "text": "function factory(list) {\n var expressions = []\n var sensitive = []\n var insensitive = []\n\n construct()\n\n return test\n\n function construct() {\n var length = list.length\n var index = -1\n var value\n var normal\n\n while (++index < length) {\n value = list[index]\n normal = value === lower(value)\n\n if (value.charAt(value.length - 1) === '*') {\n // Regexes are insensitive now, once we need them this should check for\n // `normal` as well.\n expressions.push(new RegExp('^' + value.slice(0, -1), 'i'))\n } else if (normal) {\n insensitive.push(value)\n } else {\n sensitive.push(value)\n }\n }\n }\n\n function test(value) {\n var normal = lower(value)\n var length\n var index\n\n if (sensitive.indexOf(value) !== -1 || insensitive.indexOf(normal) !== -1) {\n return true\n }\n\n length = expressions.length\n index = -1\n\n while (++index < length) {\n if (expressions[index].test(value)) {\n return true\n }\n }\n\n return false\n }\n}", "title": "" }, { "docid": "582230030d7cd30eae4d9232b3285fa0", "score": "0.48740485", "text": "static generateFiltersFunction(filters) {\n if (!filters || !filters.length && !filters.count) {\n return FunctionHelper.returnTrue;\n }\n\n return function (candidate) {\n let match = true;\n\n for (const filter of filters) {\n // Skip disabled filters\n if (!filter.disabled) {\n match = filter.filter(candidate);\n }\n\n if (!match) {\n break;\n }\n }\n\n return match;\n };\n }", "title": "" }, { "docid": "2e559a85e7eb59ff94b8919f4de2641e", "score": "0.48720086", "text": "function compilePathPattern1(pat, paramName) {\n const keys = [];\n const rgx = pathToRegexp(pat, keys);\n\n let paramIdx = 0;\n keys.forEach((k, i) => {\n if (k.name === paramName) {\n paramIdx = i + 1;\n }\n });\n if (!paramIdx) {\n nogthrow(ERR_PARAM_INVALID, {\n reason: `Missing param \\`${paramName}\\` in \\`${pat}\\`.`,\n });\n }\n\n return function matchPath(path) {\n const m = rgx.exec(path);\n if (!m) {\n return null;\n }\n\n return m[paramIdx];\n };\n}", "title": "" }, { "docid": "f7b4add47707ae255138d92cb4aaa91a", "score": "0.48715416", "text": "function matches(msg, array_of_patterns) {\n\n var msg_lower = msg.toLowerCase();\n\n for(var i = 0; i < array_of_patterns.length; i++) {\n\n var pattern_lower = array_of_patterns[i].toLowerCase();\n\n if(msg_lower.search(pattern_lower) > -1) {\n\n return true;\n\n }\n }\n return false;\n}", "title": "" }, { "docid": "85be7d28cdea6b20322f092ae0877129", "score": "0.48710257", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" }, { "docid": "85be7d28cdea6b20322f092ae0877129", "score": "0.48710257", "text": "function regexpToFunction(re, keys, options) {\n if (options === void 0) { options = {}; }\n var _a = options.decode, decode = _a === void 0 ? function (x) { return x; } : _a;\n return function (pathname) {\n var m = re.exec(pathname);\n if (!m)\n return false;\n var path = m[0], index = m.index;\n var params = Object.create(null);\n var _loop_1 = function (i) {\n if (m[i] === undefined)\n return \"continue\";\n var key = keys[i - 1];\n if (key.modifier === \"*\" || key.modifier === \"+\") {\n params[key.name] = m[i].split(key.prefix + key.suffix).map(function (value) {\n return decode(value, key);\n });\n }\n else {\n params[key.name] = decode(m[i], key);\n }\n };\n for (var i = 1; i < m.length; i++) {\n _loop_1(i);\n }\n return { path: path, index: index, params: params };\n };\n}", "title": "" } ]
9108f21d79e20c691e407112ece7bc38
Get named Repository Ctor (by injection), new it, and initialize it
[ { "docid": "77826e2420f9f56c3684b1d0c56f7a37", "score": "0.6579866", "text": "function getRepo(repoName) {\r\n var fullRepoName = 'repository.' + repoName.toLowerCase();\r\n var factory = $injector.get(fullRepoName);\r\n return factory;\r\n }", "title": "" } ]
[ { "docid": "37216fd45f267554926ea02691fb752f", "score": "0.68866694", "text": "repository(repositoryName, ...args) {\n if(config.type_db == 'mysql') {\n repositoryName = `MySql/${repositoryName}`;\n } else if(config.type_db == 'mongodb'){\n repositoryName = `MongoDB/${repositoryName}`;\n }\n let Repository = require(`${__dirname}/../src/repository/${repositoryName}.js`);\n return new Repository(...args);\n }", "title": "" }, { "docid": "37a8ca57d7f3a648968849c6d4fcfb3b", "score": "0.66768056", "text": "function getRepo(repoName) {\n //var fullRepoName = 'repository.' + repoName.toLowerCase();\n var fullRepoName = 'repository.' + repoName;\n var Repo = $injector.get(fullRepoName);\n return new Repo(manager);\n }", "title": "" }, { "docid": "0c112b8b87772097ee0f09c8c1284751", "score": "0.6587994", "text": "function getRepo(repoName) {\n var fullRepoName = \"repository.\" + repoName.toLowerCase();\n var repo = $injector.get(fullRepoName);\n return repo;\n //var Repo = $injector.get(fullRepoName);\n //return new Repo(manager);\n }", "title": "" }, { "docid": "dad6b7948f6e10ba5b3bc31f91695fe7", "score": "0.6164018", "text": "function createRepo() {\n var taskRepo = new Object('Task');\n return taskRepo;\n }", "title": "" }, { "docid": "76721ec8242f9cc449e7c58c9a81e81a", "score": "0.60619456", "text": "function Repo() {\n _classCallCheck(this, Repo);\n\n Repo.initialize(this);\n }", "title": "" }, { "docid": "39c907a801897a410420d8763e9f6150", "score": "0.58255994", "text": "function gitInit(args, repo) {\n if (repo) throw new Error(\"Repository already exists\");\n return new Repo();\n}", "title": "" }, { "docid": "e60110239fb54db8ca453023cbc48a6d", "score": "0.5686415", "text": "constructor(repository = UserRepository) {\n this.orm = repository;\n }", "title": "" }, { "docid": "1d55a29cf9b76b1ee69e7409f399c626", "score": "0.56201595", "text": "getRepository(entityName) {\n entityName = utils_1.Utils.className(entityName);\n if (!this.repositoryMap[entityName]) {\n const meta = this.metadata.get(entityName);\n const RepositoryClass = this.config.getRepositoryClass(meta.customRepository);\n this.repositoryMap[entityName] = new RepositoryClass(this, entityName);\n }\n return this.repositoryMap[entityName];\n }", "title": "" }, { "docid": "327b7b7bad8377cb9b9e4f51c85eb32f", "score": "0.5607951", "text": "function factory() {\r\n var args = [];\r\n for (var _d = 0; _d < arguments.length; _d++) {\r\n args[_d] = arguments[_d];\r\n }\r\n var values = props ? props.apply(void 0, __spread(args)) : {};\r\n return Object.assign({ ngMetadataName: name }, values);\r\n }", "title": "" }, { "docid": "953a3b0856c478659943846d57e28fac", "score": "0.5545923", "text": "constructor(scope, id, props) {\n super(scope, id, { type: CfnRepository.CFN_RESOURCE_TYPE_NAME, properties: props });\n try {\n jsiiDeprecationWarnings.aws_cdk_lib_aws_codeartifact_CfnRepositoryProps(props);\n }\n catch (error) {\n if (process.env.JSII_DEBUG !== \"1\" && error.name === \"DeprecationError\") {\n Error.captureStackTrace(error, CfnRepository);\n }\n throw error;\n }\n cdk.requireProperty(props, 'domainName', this);\n cdk.requireProperty(props, 'repositoryName', this);\n this.attrArn = cdk.Token.asString(this.getAtt('Arn', cdk.ResolutionTypeHint.STRING));\n this.attrDomainName = cdk.Token.asString(this.getAtt('DomainName', cdk.ResolutionTypeHint.STRING));\n this.attrDomainOwner = cdk.Token.asString(this.getAtt('DomainOwner', cdk.ResolutionTypeHint.STRING));\n this.attrName = cdk.Token.asString(this.getAtt('Name', cdk.ResolutionTypeHint.STRING));\n this.domainName = props.domainName;\n this.repositoryName = props.repositoryName;\n this.description = props.description;\n this.domainOwner = props.domainOwner;\n this.externalConnections = props.externalConnections;\n this.permissionsPolicyDocument = props.permissionsPolicyDocument;\n this.tags = new cdk.TagManager(cdk.TagType.STANDARD, \"AWS::CodeArtifact::Repository\", props.tags, { tagPropertyName: 'tags' });\n this.upstreams = props.upstreams;\n }", "title": "" }, { "docid": "69f0dc78aa55d386f0aade8cf2ef678b", "score": "0.55451", "text": "CardRepo() { \r\n }", "title": "" }, { "docid": "7fb7b1e82aafcd8f67a6fb6106c8ec37", "score": "0.5532889", "text": "function instantiateStore(){return angular.injector([name]).invoke(factory, _store)}", "title": "" }, { "docid": "616ca667958608110691c1f75f068a3d", "score": "0.5489657", "text": "function Repository(aggregateType){\n\n this._eventStore = new EventStore();\n\n /*\n Assign the type of the aggregate. It is expected that the\n type passed has a constructor function that expects an Id\n */\n this._aggregateType = aggregateType;\n}", "title": "" }, { "docid": "f3741229936c90c4b87b1629ec084ea5", "score": "0.5484343", "text": "function factory() {\n var values = props ? props.apply(void 0, arguments) : {};\n return Object.assign({\n ngMetadataName: name\n }, values);\n }", "title": "" }, { "docid": "34773fce9f430848b22e81baceefa435", "score": "0.54725957", "text": "function factory() {}", "title": "" }, { "docid": "54e6551d648e4b3ee5f9124316d88795", "score": "0.54571295", "text": "function factory(...args) {\n const values = props ? props(...args) : {};\n return Object.assign({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "54e6551d648e4b3ee5f9124316d88795", "score": "0.54571295", "text": "function factory(...args) {\n const values = props ? props(...args) : {};\n return Object.assign({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "54e6551d648e4b3ee5f9124316d88795", "score": "0.54571295", "text": "function factory(...args) {\n const values = props ? props(...args) : {};\n return Object.assign({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "54e6551d648e4b3ee5f9124316d88795", "score": "0.54571295", "text": "function factory(...args) {\n const values = props ? props(...args) : {};\n return Object.assign({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "400f32a64eda26b79624363e50b96e15", "score": "0.5426031", "text": "function factory() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var values = props ? props.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__spread\"])(args)) : {};\n return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__assign\"])({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "400f32a64eda26b79624363e50b96e15", "score": "0.5426031", "text": "function factory() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var values = props ? props.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__spread\"])(args)) : {};\n return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__assign\"])({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "400f32a64eda26b79624363e50b96e15", "score": "0.5426031", "text": "function factory() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var values = props ? props.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__spread\"])(args)) : {};\n return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__assign\"])({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "400f32a64eda26b79624363e50b96e15", "score": "0.5426031", "text": "function factory() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var values = props ? props.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__spread\"])(args)) : {};\n return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__assign\"])({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "400f32a64eda26b79624363e50b96e15", "score": "0.5426031", "text": "function factory() {\n var args = [];\n for (var _i = 0; _i < arguments.length; _i++) {\n args[_i] = arguments[_i];\n }\n var values = props ? props.apply(void 0, Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__spread\"])(args)) : {};\n return Object(tslib__WEBPACK_IMPORTED_MODULE_0__[\"__assign\"])({ ngMetadataName: name }, values);\n }", "title": "" }, { "docid": "5076dbec39e94f2a73f813631abda42e", "score": "0.54132354", "text": "function createService(fetcher, serviceName = \"mongo-db\") {\n return { db: createDatabase.bind(null, fetcher, serviceName) };\n }", "title": "" }, { "docid": "12cbf3696b55a914f7c8f3911c261d17", "score": "0.5400458", "text": "function Factory() {}", "title": "" }, { "docid": "0108b8ac0576a7369afd7c0d3f900204", "score": "0.5395123", "text": "function Repository(props) {\n return __assign({ Type: 'AWS::CodeCommit::Repository' }, props);\n }", "title": "" }, { "docid": "65de231c090b79f1a6936f1fe6cf88cf", "score": "0.5386969", "text": "static _fromCloudFormation(scope, id, resourceAttributes, options) {\n resourceAttributes = resourceAttributes || {};\n const resourceProperties = options.parser.parseValue(resourceAttributes.Properties);\n const propsResult = CfnRepositoryPropsFromCloudFormation(resourceProperties);\n const ret = new CfnRepository(scope, id, propsResult.value);\n for (const [propKey, propVal] of Object.entries(propsResult.extraProperties)) {\n ret.addPropertyOverride(propKey, propVal);\n }\n options.parser.handleAttributes(ret, resourceAttributes, id);\n return ret;\n }", "title": "" }, { "docid": "e1b2b86a0a0dd3ab30fc1c6ff5b7ada5", "score": "0.53814983", "text": "function Repository(props) {\n return __assign({ Type: 'AWS::ECR::Repository' }, props);\n }", "title": "" }, { "docid": "7fa2198de932c70e6ec1164ddbdedfc6", "score": "0.5377858", "text": "function add_repository (repository) {\r\n if (repository && repository.id) {\r\n DataRepositories[repository.id] = repository;\r\n DataRepositoriesCount++;\r\n if (repository.default) {\r\n DataRepositoryDefault = DataRepositories[repository.id];\r\n }\r\n }\r\n}", "title": "" }, { "docid": "94e33e977c75763fd8731433a4768144", "score": "0.53718305", "text": "function createRepository (options) {\n options = options || {};\n var stats = new hakaru.Repository(options);\n\n // Augmenting our stats object with middleware function\n stats.middleware = function (opts) {\n opts = opts || {};\n var request = opts.request || 'request'\n , response = opts.response || 'response'\n , missed = opts.missed || 'missed';\n\n // actual middleware function for proxy\n return function (req, res, next) {\n stats.mark(request);\n res.once('proxy start', function () {\n var end = stats.start(response);\n res.once('proxy end', end);\n });\n req.once('proxy miss', stats.deferMark(missed));\n next();\n }\n }\n\n // allows user to provide own reporting mechanisms\n return stats;\n}", "title": "" }, { "docid": "cd9ee86028fccb233c7779baf674b2b2", "score": "0.5332008", "text": "function RepoMan(githubUsername) {\n this.username = githubUsername;\n\n this.init();\n}", "title": "" }, { "docid": "0c24ccf92eb4579d01a423b1a22ade8b", "score": "0.5327162", "text": "constructor(name, readOnly, initializer) {\n Object.assign(this, { name, readOnly, initializer })\n }", "title": "" }, { "docid": "8a54986cf31f508603f17e99b1bf4c80", "score": "0.5317268", "text": "function default_repository (id) {\r\n if (id && DataRepositories[id]) {\r\n DataRepositoryDefault = DataRepositories[id];\r\n }\r\n}", "title": "" }, { "docid": "193effb7d0c0b2cfcb2075ea3bc0a715", "score": "0.53081256", "text": "function Personfactory(firstName, lastName) {\n var person = Object.create(Person);\n person.firstName = firstName;\n person.lastName = lastName;\n return person;\n}", "title": "" }, { "docid": "338e0116fcd30065a48801179f7af6d4", "score": "0.5284249", "text": "function createDriver() {\n let DriverId = 0;\n return class {\n constructor(name) {\n this.name = name;\n this.id = ++DriverId;\n };\n };\n}", "title": "" }, { "docid": "cae15775cc151d0d3e6457d20f1dfeba", "score": "0.52581483", "text": "function Repository(server) {\n if (!(this instanceof Repository)) {\n return new Repository(server);\n }\n this._server = server || '';\n}", "title": "" }, { "docid": "63d5e24528b0e64ab535c2e2330ee606", "score": "0.52578807", "text": "function makeOne(name, repository) {\n\t\t\treturn {\n\t\t\t\tbefore: function() {\n\t\t\t\t\trepository[name] = (repository[name] || {});\n\t\t\t\t\tif (repository[name].begin) {\n\t\t\t\t\t\trepository[name].begin.push(new Date());\n\t\t\t\t\t} else {\n\t\t\t\t\t\trepository[name].begin = [ new Date() ];\n\t\t\t\t\t}\n\t\t\t\t},\n\t\t\t\tafter: function() {\n\t\t\t\t\trepository[name].count = (repository[name].count || 0) + 1;\n\t\t\t\t\tvar begin = repository[name].begin.pop();\n\t\t\t\t\trepository[name].time = (repository[name].time || 0) + (new Date() - begin);\n\t\t\t\t\tif ( !repository[name].begin.length) {\n\t\t\t\t\t\tdelete repository[name].begin;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t};\n\t\t}", "title": "" }, { "docid": "9d747b75cf87ebb6214f018be6ee7984", "score": "0.52500093", "text": "function Repository(config, client) {\n if (config && config instanceof config_1.Config) {\n this.config = config;\n }\n else {\n this.config = new config_1.Config(config);\n }\n this.client = client || new client_1.Client(this.config);\n }", "title": "" }, { "docid": "39ca5221fae032a5f46426a6f58c3948", "score": "0.52222073", "text": "function createDriver() {\n let driverID = 0;\n\n return class {\n constructor(name) {\n this.name = name;\n this.id = ++driverID;\n }\n }\n}", "title": "" }, { "docid": "3c534d4690305c357ed80dff6dcc92a5", "score": "0.5201207", "text": "create() {\n const dbConfig = new DatabaseConfiguration('TESTS');\n return new DatabaseConnectionManager(_connectionFactoryMethod.bind(this), dbConfig);\n }", "title": "" }, { "docid": "91c0d4a6f015d2b9ac13b67633d2966c", "score": "0.5187759", "text": "make(abstract, parameters = []) {\n const resolved_abstract = this.resolveAbstract(abstract);\n this.parameters = parameters;\n if (this.bindings === undefined) {\n this.bindings = [];\n }\n if (this.bindings[resolved_abstract] === undefined) {\n if (typeof abstract === 'string') {\n return 'null';\n } else {\n return new abstract();\n }\n } else {\n if (this.bindings[resolved_abstract]['useValue'] === true) {\n return this.bindings[resolved_abstract]['value'];\n } else if (this.bindings[resolved_abstract]['isSingleton'] === true) {\n if (this.bindings[resolved_abstract]['instance'] === undefined) {\n this.bindings[resolved_abstract]['instance'] = new this.bindings[resolved_abstract]['concrete']();\n }\n return this.bindings[resolved_abstract]['instance'];\n } else {\n return new this.bindings[resolved_abstract]['concrete']();\n }\n }\n }", "title": "" }, { "docid": "2503e0460a36567ce8c85800eef5c640", "score": "0.5186687", "text": "function createInjector(defType, parent, additionalProviders, name) {\n if (parent === void 0) { parent = null; }\n if (additionalProviders === void 0) { additionalProviders = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, additionalProviders, parent, name);\n}", "title": "" }, { "docid": "2503e0460a36567ce8c85800eef5c640", "score": "0.5186687", "text": "function createInjector(defType, parent, additionalProviders, name) {\n if (parent === void 0) { parent = null; }\n if (additionalProviders === void 0) { additionalProviders = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, additionalProviders, parent, name);\n}", "title": "" }, { "docid": "16350f21e79c0127b454f075775d18b9", "score": "0.51856846", "text": "function defineLazyLoadedRepos() {\r\n repoNames.forEach(function(name) {\r\n Object.defineProperty(service, name, {\r\n configurable: true, // will redefine this property once\r\n get: function() {\r\n // The 1st time the repo is request via this property,\r\n // we ask the repositories for it (which will inject it).\r\n var repo = getRepo(name);\r\n // Rewrite this property to always return this repo;\r\n // no longer redefinable\r\n Object.defineProperty(service, name, {\r\n value: repo,\r\n configurable: false,\r\n enumerable: true\r\n });\r\n return repo;\r\n }\r\n });\r\n });\r\n }", "title": "" }, { "docid": "02535e9b511f8da761ad242bb64ba1a3", "score": "0.51806617", "text": "static fromEcr(repository, props) {\n return {\n _bind() {\n return new code_1.EcrImageCode(repository, props);\n },\n };\n }", "title": "" }, { "docid": "3f64af62d028c8d264f8e146f936a19b", "score": "0.5154071", "text": "function factory(name, age){\r\n return {\r\n name,\r\n age\r\n }\r\n}", "title": "" }, { "docid": "155e21f620b13db6b0abd781c3c7a9b2", "score": "0.51478934", "text": "function factory(n) {\n var ob = {\n name: n,\n };\n return ob\n}", "title": "" }, { "docid": "c85614cd4cb62e33d926b612272db5d0", "score": "0.5134312", "text": "function ioc(key, args, context) { return ioc.instance(key, args, context) }", "title": "" }, { "docid": "ae6268aa1298f4a3682b4146bf329f3a", "score": "0.51137275", "text": "function createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector._resolveInjectorDefTypes();\n return injector;\n}", "title": "" }, { "docid": "ae6268aa1298f4a3682b4146bf329f3a", "score": "0.51137275", "text": "function createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector._resolveInjectorDefTypes();\n return injector;\n}", "title": "" }, { "docid": "ae6268aa1298f4a3682b4146bf329f3a", "score": "0.51137275", "text": "function createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector._resolveInjectorDefTypes();\n return injector;\n}", "title": "" }, { "docid": "ae6268aa1298f4a3682b4146bf329f3a", "score": "0.51137275", "text": "function createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector._resolveInjectorDefTypes();\n return injector;\n}", "title": "" }, { "docid": "ae6268aa1298f4a3682b4146bf329f3a", "score": "0.51137275", "text": "function createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector._resolveInjectorDefTypes();\n return injector;\n}", "title": "" }, { "docid": "ae6268aa1298f4a3682b4146bf329f3a", "score": "0.51137275", "text": "function createInjector(defType, parent = null, additionalProviders = null, name) {\n const injector = createInjectorWithoutInjectorInstances(defType, parent, additionalProviders, name);\n injector._resolveInjectorDefTypes();\n return injector;\n}", "title": "" }, { "docid": "21fc5fc4a1c83c45571376e2b44e100b", "score": "0.5107807", "text": "function createDriver(){\n let driverId = 0;\n // return the class that allows us to create a driver with a name attribute\n return class {\n constructor(name){\n this.name = name;\n // increment the driverId each tiem a driver is created \n this.id = ++driverId;\n }\n }\n}", "title": "" }, { "docid": "29e4f537dc63379d2e57c76eeff4e871", "score": "0.5101599", "text": "function createDriver(){\n let DriverId = 0;\n\n return class Driver {\n constructor(name){\n this.name = name;\n this.id = ++DriverId;\n }\n\n }\n}", "title": "" }, { "docid": "75c710884082a87c2f47c13086d218f4", "score": "0.5092818", "text": "function Repo() {\n var opts = arguments.length <= 0 || arguments[0] === undefined ? {} : arguments[0];\n\n _classCallCheck(this, Repo);\n\n this.github = opts.github;\n this.owner = opts.owner;\n this.repo = opts.repo;\n this.branch = opts.branch;\n this.commitPrefix = opts.commitPrefix || '';\n\n this._blobCache = {};\n this._treeCache = null;\n this._lastHeadCommit = '';\n }", "title": "" }, { "docid": "d4186f1879c0d6e2a3a2f0b1391d8198", "score": "0.5086662", "text": "function createInjector(defType, parent) {\n if (parent === void 0) { parent = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, parent);\n}", "title": "" }, { "docid": "d4186f1879c0d6e2a3a2f0b1391d8198", "score": "0.5086662", "text": "function createInjector(defType, parent) {\n if (parent === void 0) { parent = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, parent);\n}", "title": "" }, { "docid": "d4186f1879c0d6e2a3a2f0b1391d8198", "score": "0.5086662", "text": "function createInjector(defType, parent) {\n if (parent === void 0) { parent = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, parent);\n}", "title": "" }, { "docid": "d52604e1830034793ba376d0ee0c1c9a", "score": "0.5076272", "text": "constructor(repository, tagOrDigest) {\n super();\n this.repository = repository;\n this.tagOrDigest = tagOrDigest;\n try {\n jsiiDeprecationWarnings.aws_cdk_lib_aws_ecr_IRepository(repository);\n }\n catch (error) {\n if (process.env.JSII_DEBUG !== \"1\" && error.name === \"DeprecationError\") {\n Error.captureStackTrace(error, EcrImage);\n }\n throw error;\n }\n this.imageName = this.repository.repositoryUriForTagOrDigest(this.tagOrDigest);\n }", "title": "" }, { "docid": "617031a227f75bf1d047c90df80dbac4", "score": "0.5067377", "text": "function NamedConstructor () {}", "title": "" }, { "docid": "6a3c2e4944438b021992cd549134001f", "score": "0.5062955", "text": "function ProductsFactory(){}", "title": "" }, { "docid": "8a02eb06acacbf0ca12d27120cffe0cb", "score": "0.505533", "text": "function factory() {\n this.create = function(moduleOrPlugin, config) {\n return new instance(moduleOrPlugin, config);\n };\n}", "title": "" }, { "docid": "1d8dfed166459718066110b848e12a6f", "score": "0.5049134", "text": "function createInjector(defType,parent,additionalProviders){if(parent===void 0){parent=null;}if(additionalProviders===void 0){additionalProviders=null;}parent=parent||getNullInjector();return new R3Injector(defType,additionalProviders,parent);}", "title": "" }, { "docid": "4209aabc6599d190d01a1684611dec22", "score": "0.5044477", "text": "constructor(name, initializer) {\n this._name = name;\n this._initializer = initializer;\n }", "title": "" }, { "docid": "5ae8e0dd02e870f6035c3a88fe08a431", "score": "0.5030833", "text": "constructor(name, type) {\n Object.assign(this, { name, type })\n }", "title": "" }, { "docid": "8da4f0e0898e603ece372cf911d7e15a", "score": "0.5030335", "text": "static create(componentName) {\n const ComponentClass = require(`./${componentName}Component`);\n return new ComponentClass();\n }", "title": "" }, { "docid": "a98eeddca182f7e28cda7a4d34619421", "score": "0.50284797", "text": "function createDriver() {\n // you need a class ID, but it needs to be within the function in order to keep the variable private\n let driverId = 0\n // get ready to return an instance of the class\n return class {\n // build the instance\n constructor(name) {\n this.id = ++driverId\n this.name = name\n }\n }\n}", "title": "" }, { "docid": "bdb88fccf1fa096cf8d637a01ebcf4ec", "score": "0.50057375", "text": "static tryCreateRepository(path, gitRevision, gitRemote) {\n ShellJS.pushd(path);\n const out = (ShellJS.exec(\"git rev-parse --show-toplevel\", { silent: true }));\n const remotesOutput = (ShellJS.exec(`git remote get-url ${gitRemote}`, { silent: true }));\n ShellJS.popd();\n if (!out ||\n out.code !== 0 ||\n !remotesOutput ||\n remotesOutput.code !== 0) {\n return;\n }\n const remotes = remotesOutput.code === 0 ? remotesOutput.stdout.split(\"\\n\") : [];\n return new Repository(base_path_1.BasePath.normalize(out.stdout.replace(\"\\n\", \"\")), gitRevision, remotes);\n }", "title": "" }, { "docid": "40a37da8e2714ca47e7eec124e55ea0a", "score": "0.5001363", "text": "function Repository(nativeRepo) {\n var index, _priv;\n if (!(nativeRepo instanceof NativeRepository)) {\n throw new Error(\"Don't construct me, see gitteh.(open|init)Repository\");\n }\n _priv = _createPrivate(this);\n _priv[\"native\"] = nativeRepo;\n _immutable(this, nativeRepo).set(\"bare\").set(\"path\").set(\"workDir\", \"workingDirectory\").set(\"remotes\").set(\"references\").set(\"submodules\");\n index = new Index(nativeRepo.index);\n _immutable(this, {\n index: index\n }).set(\"index\");\n }", "title": "" }, { "docid": "9eb8e4ee588b5b2f253f99952715e65b", "score": "0.49996755", "text": "function CarFactory(name) {\n const newCar = Object.assign(\n {},\n new Vehicle(name, 4),\n )\n return Object.freeze(newCar);\n}", "title": "" }, { "docid": "aeba836d8ff10a6642d6ae9b71437b75", "score": "0.49976233", "text": "function DenodeifiedRepo(path) {\n this._repo = new Repo(path);\n}", "title": "" }, { "docid": "05ccb01f5f6561b7790265e1d23933bd", "score": "0.49891368", "text": "function Repo(name, description, url, watchers) {\n this.name = name;\n this.description = description;\n this.url = url;\n this.watchers = watchers;\n}", "title": "" }, { "docid": "3625e4bf5d55fd33288f468f1922f900", "score": "0.49613044", "text": "clone() {\n return new DefaultKernel({\n name: this._name,\n username: this._username,\n serverSettings: this.serverSettings\n }, this._id);\n }", "title": "" }, { "docid": "b53efe34f09f0289f1f176ed721fcb12", "score": "0.4959696", "text": "constructor(name){\n this.id = ++driverId\n this.name = name\n }", "title": "" }, { "docid": "abe453bababdc361ceaea670d2735b78", "score": "0.4952391", "text": "function createProvider() {\n return (new LocalProvider());\n }", "title": "" }, { "docid": "1d0c12a100339fa4dc0d3c6934ad3f12", "score": "0.49489385", "text": "function createHasOneRepositoryFactory(relationMetadata, targetRepositoryGetter) {\n const meta = resolveHasOneMetadata(relationMetadata);\n debug('Resolved HasOne relation metadata: %o', meta);\n return function (fkValue) {\n // tslint:disable-next-line:no-any\n const constraint = { [meta.keyTo]: fkValue };\n return new has_one_repository_1.DefaultHasOneRepository(targetRepositoryGetter, constraint);\n };\n}", "title": "" }, { "docid": "073f8239c41b0ec2e92c1833b6f4aca6", "score": "0.4948702", "text": "function ctor() {}", "title": "" }, { "docid": "318213fc4a9f190c42cc6a0d28c6d10d", "score": "0.49397898", "text": "function createRepo(config) {\n var bare = !!config.bare;\n var init = !!config.init;\n var db = config.db;\n var fs = config.fs;\n if (!fs && !bare) {\n throw new Error(\"Full repos are required to have a fs backend\");\n }\n if (!db && !fs) {\n throw new Error(\"Either a db or fs interface must be provided for bare repos\");\n }\n if (!db) {\n if (bare) {\n db = require('./fs-db.js')(fs);\n }\n else {\n db = require('./fs-db.js')(fs(\".git\"));\n }\n }\n\n var repo = {\n bare: bare,\n db: db,\n load: load,\n save: save,\n readRef: readRef,\n updateHead: updateHead\n };\n if (!bare) {\n repo.fs = fs;\n }\n\n // load(hash) -> continuable<object>\n function load(hash) {\n return decode(db.load(hash));\n }\n\n // encode(object) -> continuable<hash>\n function save(object) {\n return db.save(encode(object));\n }\n\n // readRef(path) -> continuable<hash>\n // resolves symbolic refs\n function readRef(ref) {\n return function (callback) {\n db.read(ref)(onRead);\n function onRead(err, value) {\n if (err) return callback(err);\n if (value.substr(0, 4) === \"ref:\") {\n db.read(value.substr(4).trim())(onRead);\n return;\n }\n callback(null, value.trim());\n }\n };\n }\n\n // updateHead(hash) -> continuable\n // writes hash to whatever HEAD points to.\n function updateHead(hash) {\n return function (callback) {\n db.read(\"HEAD\")(function (err, value) {\n if (err) return callback(err);\n if (value.substr(0, 4) !== \"ref:\") {\n return callback(new Error(\"HEAD must be symbolic ref\"));\n }\n db.write(value.substr(4).trim(), hash + \"\\n\")(callback);\n });\n };\n }\n\n if (init) {\n return function (callback) {\n db.init({ core: {\n repositoryformatversion: 0,\n filemode: true,\n bare: bare\n }})(function (err) {\n if (err) return callback(err);\n callback(null, repo);\n });\n };\n }\n return function (callback) {\n callback(null, repo);\n };\n\n}", "title": "" }, { "docid": "8efc22f5f21414da65b4af80f1566ad2", "score": "0.49385813", "text": "constructor(name, id, email, github){\n //construct our base class\n super(name, id, email);\n //unique variable\n this.github = github;\n }", "title": "" }, { "docid": "cde1150c12792e7c9fff1999612d2abf", "score": "0.49343118", "text": "function constructor(spec){\n var that = otherMake(spec)\n}", "title": "" }, { "docid": "826adb7f5e45f7240b32e6bf73b8888c", "score": "0.4925533", "text": "create() {\n if (typeof $this.new === 'function') {\n return $this.new();\n }\n }", "title": "" }, { "docid": "dcedb617bedc305130f20548432b65cf", "score": "0.4924239", "text": "constructor() { \n \n RepoDiff.initialize(this);\n }", "title": "" }, { "docid": "3b6985f8b303d4575e8e3f873a250721", "score": "0.49140072", "text": "constructor(name, readOnly, type) {\n Object.assign(this, { name, readOnly, type })\n }", "title": "" }, { "docid": "fb18f05a60af46970a03b23f13d7fab1", "score": "0.49119097", "text": "constructor(repo) {\n super();\n this.repo = repo;\n this.data = {\n shops: this.repo.pullShops(),\n currentItem: null,\n }\n }", "title": "" }, { "docid": "673adfddd184d4734373642c2a829514", "score": "0.49058053", "text": "pickComponent(scope, identifier) {\n const identifiers = getOrSet(this.repository, scope, () => new Map());\n return getOrSet(identifiers, identifier, () => {\n return new Component(scope);\n });\n }", "title": "" }, { "docid": "48fa1e9aae7ec23d24bba20039f7d714", "score": "0.4898313", "text": "function dogFactory(name,breed,weight) {\n return {name: name, breed: breed, weight: weight};\n}", "title": "" }, { "docid": "8d12c57a018fe4ce1d1ea748efe11b33", "score": "0.48872563", "text": "constructor(name) { //constructor\n if (name == null){\n this.name = \"default\"\n }\n else {\n this.name = name;\n }\n }", "title": "" }, { "docid": "cf179e986165dff8c06775a3a6947449", "score": "0.48791", "text": "function DialogRepository(){\n\tRepository.prototype.constructor.call(this);\n\tthis.schema = Dialog;\n\tthis.model = Dialog;\n\tthis.bindListeners();\n}", "title": "" }, { "docid": "ca208f2dd8a5073a79e2519158f6b518", "score": "0.4876006", "text": "constructor() {\n\n V1GitType.initialize(this);\n }", "title": "" }, { "docid": "09ee61fb52f03b033bb251133a51f8a6", "score": "0.4868054", "text": "function getProvider(name) {\n return new mongoProvider[name](\n config.mongo.host,\n config.mongo.port,\n config.mongo.db\n );\n}", "title": "" }, { "docid": "a429cd23bb0b6db608cc35719afb955c", "score": "0.48657715", "text": "function init(id, params) {\n // look for the generator\n var generatorType = generatorRegistry[id],\n generator;\n \n // if we didn't find a generator, raise an exception\n if (! generatorType) {\n throw new Error('Unable to locate requested generator: ' + id);\n } // if\n \n // create the new generator\n return new generatorType(params);\n } // init", "title": "" }, { "docid": "a429cd23bb0b6db608cc35719afb955c", "score": "0.48657715", "text": "function init(id, params) {\n // look for the generator\n var generatorType = generatorRegistry[id],\n generator;\n \n // if we didn't find a generator, raise an exception\n if (! generatorType) {\n throw new Error('Unable to locate requested generator: ' + id);\n } // if\n \n // create the new generator\n return new generatorType(params);\n } // init", "title": "" }, { "docid": "c98f89c9fe6c74ccde448da48f881f09", "score": "0.48647055", "text": "function __FACTORY(){}", "title": "" }, { "docid": "124cabbf69fcef743812e45f6eaf14f7", "score": "0.4856677", "text": "function createInjector(defType, parent, additionalProviders) {\n if (parent === void 0) { parent = null; }\n if (additionalProviders === void 0) { additionalProviders = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, additionalProviders, parent);\n}", "title": "" }, { "docid": "124cabbf69fcef743812e45f6eaf14f7", "score": "0.4856677", "text": "function createInjector(defType, parent, additionalProviders) {\n if (parent === void 0) { parent = null; }\n if (additionalProviders === void 0) { additionalProviders = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, additionalProviders, parent);\n}", "title": "" }, { "docid": "124cabbf69fcef743812e45f6eaf14f7", "score": "0.4856677", "text": "function createInjector(defType, parent, additionalProviders) {\n if (parent === void 0) { parent = null; }\n if (additionalProviders === void 0) { additionalProviders = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, additionalProviders, parent);\n}", "title": "" }, { "docid": "124cabbf69fcef743812e45f6eaf14f7", "score": "0.4856677", "text": "function createInjector(defType, parent, additionalProviders) {\n if (parent === void 0) { parent = null; }\n if (additionalProviders === void 0) { additionalProviders = null; }\n parent = parent || getNullInjector();\n return new R3Injector(defType, additionalProviders, parent);\n}", "title": "" } ]
7dffc504dec3b7ee562a3d9477c587e8
Run a function n times.
[ { "docid": "fa0abd9e7c26b46cead88aaddfaca640", "score": "0.70512646", "text": "function times(n, iteratee, context) {\n var accum = Array(Math.max(0, n));\n iteratee = optimizeCb(iteratee, context, 1);\n for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n return accum;\n}", "title": "" } ]
[ { "docid": "92cf4ffbd3b4efd239831ff4d0d74396", "score": "0.8456841", "text": "function repeat(func, n) {\n for(let i=0; i < n; i++){\n func();\n }\n}", "title": "" }, { "docid": "96750b2db3be518b9cba696920c6ad78", "score": "0.83738583", "text": "function callNTimes(times, fun) {\n let calls = 0;\n while (calls < times) {\n fun();\n calls ++;\n }\n}", "title": "" }, { "docid": "8365d72d4a89d5491fbbd1db3268dbc5", "score": "0.81764066", "text": "function repeat(fn, n) {\n var result;\n \n for( var i = 0; i < n; i++) {\n result = fn( result, i)\n }\n \n return result;\n}", "title": "" }, { "docid": "8d529b13e8fccb01f333255a66c93812", "score": "0.81687033", "text": "function doTimes(n, fn) {\n var results = [];\n while (n--) {\n results.push(fn());\n }\n return results;\n}", "title": "" }, { "docid": "5428aed1ddd7ab89f17163f4e569ad75", "score": "0.81551254", "text": "function repeat(n, action) {\n for (let i = 0; i < n; i++) {\n action(i);\n }\n}", "title": "" }, { "docid": "5428aed1ddd7ab89f17163f4e569ad75", "score": "0.81551254", "text": "function repeat(n, action) {\n for (let i = 0; i < n; i++) {\n action(i);\n }\n}", "title": "" }, { "docid": "9c564e16bfcc5429dcac2b9828adde1c", "score": "0.8048518", "text": "function repeat(times, func) {\n for (var i=0; i < times; i++) {\n func(i);\n }\n }", "title": "" }, { "docid": "b663d98f392908f8dfed95dbb3d7eaef", "score": "0.80276996", "text": "function repeatNTIMES(func, num){\n for(let i = 0; i < num; i++){ //we want function to run all the way up to however much num is equal to\n func ();\n }\n}", "title": "" }, { "docid": "1e9355d97a27dc34d3c522b78d098e0e", "score": "0.79386455", "text": "function thisManyTimes(fn, n) {\n let done = 0;\n return((...args) => {\n if (done < n) {\n done += 1;\n fn(...args);\n }\n });\n}", "title": "" }, { "docid": "67db677a37a2862d3321517795d39e85", "score": "0.7851394", "text": "function repeat1(n, action) {\n let result = 0;\n for (let i = 0; i < n; i++) {\n result = action(i);\n }\n return result;\n}", "title": "" }, { "docid": "eb04467bfe5ddd9b48ed87ee75235601", "score": "0.7746139", "text": "function make_repeater(func, n) {\n return x => {\n for (i = 0; i < n; i++) {\n x = func(x);\n }\n return x;\n }\n}", "title": "" }, { "docid": "f0b244c49882ff860faa6b209d229b68", "score": "0.76397663", "text": "function repeat(fn, times){\n let loop = function(times){\n if (times){\n fn(times);\n loop(--times);\n }\n }\n loop(times);\n}", "title": "" }, { "docid": "1132d43651f39313a7a294e481049e6a", "score": "0.75736845", "text": "function callTenTimes(func) {\n for (let i = 0; i < 10; i++) {\n func();\n }\n}", "title": "" }, { "docid": "f0132337b6ae7053a6525057782faffd", "score": "0.7493348", "text": "function times(n, callback, thisObj){\n var i = -1;\n while (++i < n) {\n if ( callback.call(thisObj, i) === false ) {\n break;\n }\n }\n }", "title": "" }, { "docid": "58766957aa90cdb3c1ff1d81e4505587", "score": "0.7452614", "text": "function repeater(x) {\n let reps = n;\n for (var i = 0; i < reps; i++) {\n x = func(x);\n }\n return x;\n }", "title": "" }, { "docid": "1f5afdaa712a02e6afeb06b3038881b3", "score": "0.7293598", "text": "function times(func, number) {\n\n\tfor(let i = 0; i < number; i += 1) {\n\t\tfunc();\n\t}\n\n\treturn number\n}", "title": "" }, { "docid": "70e3715254bb4a82b4d67bb03cdcfa99", "score": "0.7278068", "text": "function repeatN(n, __trace) {\n return self => repeatN_(self, n, __trace);\n}", "title": "" }, { "docid": "68cf7b6ea75978e37ccc8da822d663bf", "score": "0.72578484", "text": "function ntimes(times, block)\n{\n\tfor (var i = 0; i < times; i++)\n\t{\n\t\tblock(i)\n\t}\n}", "title": "" }, { "docid": "b37f5d9ae00ee011baa1b7322f1c8389", "score": "0.7216119", "text": "function repeat(n, delay, func) {\n if (n > 0) { \n func(n-1);\n setTimeout(repeat, delay, n-1, delay, func);\n }\n}", "title": "" }, { "docid": "151f3a2a58d43e63e9a6dfc4d08a1ec4", "score": "0.71669424", "text": "function repeat(functionToUse, number) {\n\tvar result;\n\n\tfor (let i = 0; i < number; i += 1) {\n\t\tresult = functionToUse(result, i);\n\t}\n\n\treturn result;\n}", "title": "" }, { "docid": "dbce1839190ab2bf614be87601741fa1", "score": "0.7154604", "text": "function repeatThreeTimes(func) {\n func();\n func();\n func();\n}", "title": "" }, { "docid": "de4de318ecf28006c322319b97925333", "score": "0.70361584", "text": "function times(n, iteratee, context) {\n var accum = Array(Math.max(0, n));\n iteratee = Object(__WEBPACK_IMPORTED_MODULE_0__optimizeCb_js__[\"a\" /* default */])(iteratee, context, 1);\n for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n return accum;\n}", "title": "" }, { "docid": "de4de318ecf28006c322319b97925333", "score": "0.70361584", "text": "function times(n, iteratee, context) {\n var accum = Array(Math.max(0, n));\n iteratee = Object(__WEBPACK_IMPORTED_MODULE_0__optimizeCb_js__[\"a\" /* default */])(iteratee, context, 1);\n for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n return accum;\n}", "title": "" }, { "docid": "dda734e17235be3f9e3254c720416bc0", "score": "0.7005321", "text": "function times(n, iteratee, context) {\n var accum = Array(Math.max(0, n));\n iteratee = optimizeCb(iteratee, context, 1);\n for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n return accum;\n }", "title": "" }, { "docid": "dda734e17235be3f9e3254c720416bc0", "score": "0.7005321", "text": "function times(n, iteratee, context) {\n var accum = Array(Math.max(0, n));\n iteratee = optimizeCb(iteratee, context, 1);\n for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n return accum;\n }", "title": "" }, { "docid": "dda734e17235be3f9e3254c720416bc0", "score": "0.7005321", "text": "function times(n, iteratee, context) {\n var accum = Array(Math.max(0, n));\n iteratee = optimizeCb(iteratee, context, 1);\n for (var i = 0; i < n; i++) accum[i] = iteratee(i);\n return accum;\n }", "title": "" }, { "docid": "9dbfaea5c0496228995f7d7befe2f958", "score": "0.6943733", "text": "function Repeat(n) {\n var sequence = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n sequence[_i - 1] = arguments[_i];\n }\n return Create(n * sequence.length, function (index) { return sequence[Math.floor(index / n)]; });\n }", "title": "" }, { "docid": "334356a66d49bebed818cd462ec0aafc", "score": "0.69371104", "text": "function repeat(times, body){\n for(var i = 0; i < times; i++){\n body(i);\n }\n}", "title": "" }, { "docid": "e81fc494b97622164b6501d847c9a920", "score": "0.6925477", "text": "function repeated(f,n) {\n if (n<=0) {\n\treturn identity;\n } else {\n\treturn function (t) {\n\t return f(repeated(f,n-1)(t));\n\t}\n }\n}", "title": "" }, { "docid": "323f92df823d237ddf91605457efe6fc", "score": "0.6855467", "text": "function _times (n, iteratee, context) {\n\tvar accum = Array(Math.max(0, n));\n\titeratee = optimizeCb(iteratee, context, 1);\n\tfor (var i = 0; i < n; i++) {\n\t\taccum[i] = iteratee(i);\n\t}return accum;\n}", "title": "" }, { "docid": "bc035d37177cbb37e527843eabce23e8", "score": "0.68545085", "text": "function call_times(number) {\n if (number == 1) {\n return call_times1\n }\n else if (number == 2) {\n return call_times2\n }\n else if (number == 3) {\n return call_times3\n }\n else if (number == 4) {\n return call_times4\n }\n}", "title": "" }, { "docid": "41ca9be2f2cbefba12621baff422b505", "score": "0.68365806", "text": "function repeatLog(n) {\n for (let i = 0; i < n; i++) {\n console.log(i);\n }\n}", "title": "" }, { "docid": "36bb501a0c944cd8ba85263fc3ef64a3", "score": "0.6815182", "text": "function callThreeTimes(f) {\n //And calls it 3 times:\n f();\n f();\n f();\n}", "title": "" }, { "docid": "4ddf1f2b99bc55df35a4fdb73742aa51", "score": "0.67869896", "text": "function iterate(i, fn) {\n\twhile (Math.random() < i--) {\n\t\tfn();\n\t}\n}", "title": "" }, { "docid": "f24e465d986e49d15c3d90d91754ab4c", "score": "0.6721118", "text": "function repeatN_(self, n, __trace) {\n return (0, _core.chain_)(self, a => n <= 0 ? (0, _core.succeed)(a) : (0, _zips.zipRight_)(_core.yieldNow, repeatN_(self, n - 1)), __trace);\n}", "title": "" }, { "docid": "30aba7e1ef0902b72ef440754c7aa61a", "score": "0.6698071", "text": "function repeat(s, n) {\n\n}", "title": "" }, { "docid": "a203f6f0f57ef7337f60986b2a32b285", "score": "0.6697207", "text": "function repeat(n, nextfn) {\n\treturn function(opts, tablevel) {\n\t\tvar rowGroups = _.range(n).map(function(i) {\n\t\t\tconsole.log(spaces(3*tablevel) + 'Repetition ' + (i+1) + '/' + n);\n\t\t\treturn nextfn(opts, tablevel+1);\n\t\t});\n\t\treturn _.flatten(rowGroups);\n\t};\n}", "title": "" }, { "docid": "e621c8ba328a713bd7dc1c609a74326f", "score": "0.66550946", "text": "function loopForTimes( times, callback ) {\n for( var i=0; i < times; i++ ){\n callback(i)\n }\n}", "title": "" }, { "docid": "f12a9142aa3c02e151c808525a627a0c", "score": "0.6598594", "text": "function repeat(operation, num) {\n // SOLUTION GOES HERE\n for (var i = 0; i < num; i++) {\n operation;\n }\n}", "title": "" }, { "docid": "2a57e1e9dff4ea9238ae81226cf7adfc", "score": "0.6550591", "text": "function foundit(items, n) {\n for (var i = 0; i < 10; i++)\n arguments[2](items, this);\n}", "title": "" }, { "docid": "b1e436de240a6afbd42b9e913d755d01", "score": "0.6518604", "text": "function repeat_566(x, n)\n{\n return map_53 // !'@1425.(Func (Array Int) (Func Int '@1425) (Array '@1425))\n (op_dot_dot_1762 // (Func Int Int (Array Int))\n (0 // Int\n ,n // Int\n ) // (Array Int)\n ,(i) => x // '@1425\n // !'@1425.(Func Int '@1425)\n ) // !'@1425.(Array '@1425)\n ;\n}", "title": "" }, { "docid": "d84b2bad1c2b1ad1ebc2aabaf6c06183", "score": "0.64722216", "text": "function counter(n) {\n for (var i = 0; i <= n; i++) {\n setTimeout(function() {\n console.log(i), 1000\n });\n }\n}", "title": "" }, { "docid": "253777bfb5f3ab9d58e58c1ed25c4742", "score": "0.6432095", "text": "function callbackOnNthTime(cb, n) {\n var cnt = 0;\n return function() {\n if(cb && ++cnt === n) {\n return cb();\n }\n };\n }", "title": "" }, { "docid": "57fb7effa788f808d99bfef479dae859", "score": "0.6421025", "text": "function example() {\r\n for (var i = 0; i < 3; i++) {\r\n run();\r\n }\r\n}", "title": "" }, { "docid": "37a06fe70b8c7b092f1d4caa4920e623", "score": "0.64080006", "text": "function callThreeTimes(fn) {\n fn();\n fn();\n fn();\n}", "title": "" }, { "docid": "2ab5b3d9b0579e5b49ce5c5237dd6204", "score": "0.6384189", "text": "function ten() {\n console.log(\"patata \".repeat(10));\n}", "title": "" }, { "docid": "e28dab4ca21ea6428735386cc362976d", "score": "0.6374208", "text": "function repeat(operation, num) {\n if (num <= 0){ return null }{\n for(var i = 0; i < num; i++){\n operation = (num) => {\n return operation(num)\n };\n }\n }\n}", "title": "" }, { "docid": "c14d34eea3438fb0da1a7658e9f94afb", "score": "0.63730294", "text": "function RepeatSequence(n) {\n var sequence = [];\n for (var _i = 1; _i < arguments.length; _i++) {\n sequence[_i - 1] = arguments[_i];\n }\n return Create(n * sequence.length, function (index) { return sequence[index % sequence.length]; });\n }", "title": "" }, { "docid": "3179748e11ae9975572fbcdae59206a2", "score": "0.6339188", "text": "function repeat(operation, num) {\n return function() {\n if (num <= 0) {\n return\n } else {\n operation()\n return repeat(operation, --num)\n }\n }\n}", "title": "" }, { "docid": "9619f6936ee85264d08d8c1b47726c0b", "score": "0.6320568", "text": "function iterate(func, x) {\n return accumulate(repeat(x), function (fx, _) {\n return func(fx);\n });\n}", "title": "" }, { "docid": "b1ab56c4c536aec1804bb075121bf044", "score": "0.63193774", "text": "function iterate(func,x,n){\n function funcCycle(i){\n if(i !== n){\n ys[i + 1] = func(ys[i]);\n return(funcCycle(i + 1));\n }else {\n return(ys);\n }\n }\n let i = 0;\n let ys = [x];\n let zs = funcCycle(i);\n return(zs);\n}", "title": "" }, { "docid": "04510a1a3678750ca2e391c38556a9bf", "score": "0.6314817", "text": "function loop(n, cb) {\n cb(n);\n return n > 0 ? loop(n - 1, cb) : n;\n }", "title": "" }, { "docid": "e6fd9a078f4b2235435880a98af3c949", "score": "0.6306712", "text": "function repeatSomething(n, stringToRepeat) { // this is a function that repeats a string n times\n for (let i = 0; i < n; i++) { // this is a for loop(more info in the loop.js file, or the according YT video)\n console.log(stringToRepeat);\n }\n}//With this function we can repeat any string, any number of times without writing the whole code, you can just call it:", "title": "" }, { "docid": "bf6761f5033713a0aba00541600afa29", "score": "0.6305874", "text": "function times(t, f) {\n const a = [];\n for (let i = 0; i < t; i++) {\n a.push(f(i));\n }\n return a;\n}", "title": "" }, { "docid": "8da0b6ba9aba3205040b42ece26c7d90", "score": "0.6297165", "text": "function loop(f) {\n function rep(x, k) {\n return f(x, function(y) {\n if(y.repeat) {\n return rep(y.value, k);\n } else {\n return k(y.value);\n }\n });\n }\n rep.run = run.curry()(rep);\n rep.next = cpsnext.curry()(rep);\n return rep;\n}", "title": "" }, { "docid": "8b7cfd6593c3e0d37d22ea0a7e0fe03e", "score": "0.629312", "text": "function loop(n, test, update, action) {\n if (test(n)) {\n action(n);\n n = update(n);\n return loop(n, test, update, action);\n }\n return;\n}", "title": "" }, { "docid": "ef3303ce5ee8742fa6be08b77b74599a", "score": "0.6292039", "text": "function repeat (operation, num) {\n // modify this so it can be interrupted\n if (num <= 0) return\n operation()\n return setImmediate(\n function () { repeat(operation, --num) }\n )\n}", "title": "" }, { "docid": "17f81c5593bcf46585578957c5a61cfe", "score": "0.62860364", "text": "function times(t, f) {\n let a = [];\n for (let i = 0; i < t; i++) {\n a.push(f(i));\n }\n return a;\n}", "title": "" }, { "docid": "b6d2fe33549020f60a4618611bde152a", "score": "0.6279918", "text": "function timeFun(fun, numItrs)\n{\n var startTime = (new Date()).getTime();\n\n for (var i = 0; i < numItrs; ++i)\n fun();\n\n var endTime = (new Date()).getTime();\n\n return (endTime - startTime) / numItrs;\n}", "title": "" }, { "docid": "76680eac359bc39d4809fe1dab311225", "score": "0.6244308", "text": "function repeat(times, proc)\n{\n\tvar arr = []\n\tfor (var i = 0; i < times; i++)\n\t\tarr[i] = proc()\n\treturn arr\n}", "title": "" }, { "docid": "32951f9bbf3c9748542286defcb20402", "score": "0.62252647", "text": "function multiplos(n,callback){\n\tfor (var i=1; i<=10; i++){\n\t\tif(i%num==0){\n\t\t\tcallback(i);\n\t\t}\n\t}\n}", "title": "" }, { "docid": "4184dc66be97fab0c014f5edfce2731f", "score": "0.6212865", "text": "function callThreeTimes(func){\n func();\n func();\n func();\n}", "title": "" }, { "docid": "d8e16251dfc6c5e51961428470913414", "score": "0.62046283", "text": "function repeat(operation, num) {\n // Modify this so it doesn't cause a stack overflow!\n if (num <= 0) return\n operation()\n return repeat(operation, --num)\n}", "title": "" }, { "docid": "3fcbefd52477245937e4a1a21100e4c1", "score": "0.6168007", "text": "function timesTen(n) {\n console.log(n * 10);\n}", "title": "" }, { "docid": "2734deaa906a829c8f1563d157ebe3e9", "score": "0.6166328", "text": "function looper(){\r\n for (var i=0; i<5; i++){\r\n run();\r\n }\r\n}", "title": "" }, { "docid": "8c74092ef02900b3223c2c85f8c5d3ba", "score": "0.6160181", "text": "function repeat(x, n) {\n if (typeof(n) !== \"number\") {\n throw \"Number of reps must be numeric\";\n } else {\n var y=Array(n);\n for (var i=0; i<n; i++) {\n y[i] = x;\n }\n return(y);\n }\n}", "title": "" }, { "docid": "8815a8881e7e82388b66602549cb14f3", "score": "0.6148956", "text": "function allFib(n){\n for ( let i = 0; i < n; i ++){\n \n }\n}", "title": "" }, { "docid": "d597021d58e2955c454a1e267b8b9f99", "score": "0.61483514", "text": "function repeat() {\n\tvar operation = random_int(1, 3);\n\t(operations[operation])();\n}", "title": "" }, { "docid": "e19fbf72230e34b5076650bae13064d2", "score": "0.61378723", "text": "function replicate(times, number) {\n var nArr = [];\n function helper(times, number) {\n if(times <= 0)\n return;\n \n nArr.push(number);\n helper(--times, number);\n\n }\n helper(times, number)\n return nArr;\n}", "title": "" }, { "docid": "d469bbd1ac4c3f2c98dabd3c98c98bdd", "score": "0.61210686", "text": "bark(times){\n console.log('bark'.repeat(times)); //chain it to repeat() aka: a new ES6 method\n }", "title": "" }, { "docid": "22c73ba884ce852cc3ad87ef935af3b0", "score": "0.6110013", "text": "randomTest (n, fun) {\n return Promise.all(\n Array.from(Array(n).keys()).map(() => {\n return new Promise((resolve, reject) => {\n fun()\n resolve()\n })\n })\n )\n }", "title": "" }, { "docid": "2538f36ce559233e8d5c65cdecb97c73", "score": "0.6103983", "text": "function printNums(n) {\n var i = 1;\n var f = function() {// capture counter and n\n console.log(i);\n i++;\n if (i<=n) {\n setTimeout(f, 2000);// recursive scheduling\n }\n }\n return f;\n}", "title": "" }, { "docid": "001f3a411a852ba4ebc5869606b3cfab", "score": "0.6098757", "text": "times (n) {\n this._times = n;\n \n return this;\n }", "title": "" }, { "docid": "0d56554d6dd2a9b87e39779d81660124", "score": "0.60981643", "text": "function add_call_times(number) {\n if (number == 1) {\n call_times1 += 1\n }\n else if (number == 2) {\n call_times2 += 1\n }\n else if (number == 3) {\n call_times3 += 1\n }\n else if (number == 4) {\n call_times4 += 1\n }\n}", "title": "" }, { "docid": "31590387576641cf39620e43f666cf92", "score": "0.60919064", "text": "function example6(n) {\n if (n <= 1) return;\n for (let i = 1; i <= 4; i++) {\n example6(n - 1);\n }\n}", "title": "" }, { "docid": "db70d0131c3e9be809a27850a9f64789", "score": "0.608241", "text": "function steps(n) {}", "title": "" }, { "docid": "9246bb07c697c64f61fc329575eebe49", "score": "0.6080992", "text": "function boooo(n) {\n for (let i = 0; i < n; i++) {\n console.log('booooo');\n }\n}", "title": "" }, { "docid": "2314b7752e4cab7d3bf6c1f97aac6362", "score": "0.60486335", "text": "function repeat(times, operation) {\n return operation()\n .then(ok => {\n if ((times - 1) > 0) {\n return repeat(times - 1, operation);\n }\n return ok;\n });\n}", "title": "" }, { "docid": "3515a5b681d3d6d5d8dbd941afb62889", "score": "0.6040648", "text": "function boooo(n) {\n for (let i = 0; i < n; i++) {\n console.log('booooo');\n }\n}", "title": "" }, { "docid": "e6463315bf7de9dd3c132ff1a26da712", "score": "0.6028267", "text": "function boooo(n) {\n for (let i = 0; i < n; i++) {\n console.log('booooo');\n }\n}", "title": "" }, { "docid": "51fc8afb51a7876b9681e313296cbfeb", "score": "0.60087425", "text": "function count(){\nfor (i = 0; i < 10; i++) {\n console.count();\n }\n}", "title": "" }, { "docid": "87d66e4ff308343dd893b0d223df0490", "score": "0.6002661", "text": "function useLet(){\r\n\tfor(let i = 0; i < 5; i++){\r\n\t\tsetTimeout(function(){\r\n\t\t\tconsole.log(i);\r\n\t\t}, 1000*i)\r\n\t}\r\n}", "title": "" }, { "docid": "a913d4984e539f370e6f0e7763526684", "score": "0.5979445", "text": "function $n(num){\n\t// this is necessary because JS interpreters suck and won't do 5.times(...) or even (5).times(...) but WILL do $n(5).times(...)\n\treturn num;\n}", "title": "" }, { "docid": "7c608f52b77e1a531f42c990db1eff75", "score": "0.5972083", "text": "function sequence() {\n var n = 0\n return function() {\n var fns = arguments\n n++\n if(n-1 >= fns.length) throw Error(\"Unexpected call \"+n)\n fns[n-1]()\n\n }\n}", "title": "" }, { "docid": "5ad4ac739b366729c7d55d376febaf1e", "score": "0.5965068", "text": "function repeatLoop() {\n\n for(let i = 0; i < 10; i++) {\n console.log(`Voy por la vuelta ${i + 1}`);\n }\n}", "title": "" }, { "docid": "5e073fef5293d6dabcdf9d570c33b258", "score": "0.59537536", "text": "function beCheerful(times){\n var sum = 0;\n for (i = 0; i < times; i++){\n console.log(\"good morning!\");\n sum += 1\n }\n return \"You called this function \" + sum +\" times\"\n}", "title": "" }, { "docid": "b44726463f99fced3fe200f9226fae43", "score": "0.5949599", "text": "function example3(n) {\n for (let i = 0; i < (n / 2); i++){\n }\n}", "title": "" }, { "docid": "fa95a0954cfb98d2ff1e3ca641408dd4", "score": "0.5942592", "text": "function testSetTimeout(num) {\n var _loop = function _loop(i) {\n setTimeout(function () {\n console.log(i);\n }, i * 1000);\n };\n\n for (var i = 1; i <= num; i++) {\n _loop(i);\n }\n} //testSetTimeout(10);", "title": "" }, { "docid": "dfee1fd8f42b1230d46e0a6ab758d6f3", "score": "0.5940005", "text": "function inception(loop){\r\n for (var i = 0; i < loop; i++){\r\n run();\r\n }\r\n}", "title": "" }, { "docid": "576f21dfaa77074c78a96abc1297be3a", "score": "0.5930897", "text": "function repeat(n, value) {\n var arr = new Array(n);\n return arr.fill(value);\n }", "title": "" }, { "docid": "cd06702c73bc0d5f829140998d6b68f2", "score": "0.5913377", "text": "function multiple(times, cb) {\n 'use strict';\n var result = [];\n\n for (let i = 0; i < times; i++) {\n result.push(cb());\n }\n\n return result;\n}", "title": "" }, { "docid": "2c1c625649cb676f48bc2bd1a41ea76b", "score": "0.59101", "text": "function example4(n) {\n if (n === 0) return;\n\n for (let i = 1; i <= 23; i++) {\n }\n example4(n - 1);\n}", "title": "" }, { "docid": "ce89fd9a2a89d6ad7a6659730fd24900", "score": "0.5898982", "text": "function timesFive(arg) {\n return arg * 5;\n}", "title": "" }, { "docid": "d6f484d0948b9b3d82ee41c0e4b4b4fe", "score": "0.5892048", "text": "function makeMultipleLister(number) {\n return function() {\n for (let multiple = number; multiple < 100; multiple += number) {\n console.log(multiple);\n }\n }\n}", "title": "" } ]
d1736e87cbd1f9c31c70697d4071b0da
Find value of selected radio button
[ { "docid": "e079afef4bb4776f3f3ca4c0d3945638", "score": "0.7742827", "text": "function getSelectedRadio(){\n\t\tvar radios = document.forms[0].primary;\n\t\tfor(var i=0; i<radios.length; i++){\n\t\t\tif(radios[i].checked){\n\t\t\tprimaryValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" } ]
[ { "docid": "17076d5911d5e8d6bf3935840d6bf02b", "score": "0.78619397", "text": "function getRadioButtonValue (radio)\n{ for (var i = 0; i < radio.length; i++)\n { if (radio[i].checked) { break }\n }\n return radio[i].value\n}", "title": "" }, { "docid": "161033cbb7dc04dc02bdaf09c3ed3e97", "score": "0.78448755", "text": "function getRadioButtonValue (radio)\r\n{ for (var i = 0; i < radio.length; i++)\r\n { if (radio[i].checked) { break }\r\n }\r\n return radio[i].value\r\n}", "title": "" }, { "docid": "200d2270ebf34fd3a4f5e284e326b2d7", "score": "0.78390837", "text": "function getSelectedRadio(){\n\t\tvar radios = document.forms[0].priority;\n\t\tfor (var i=0; i<radios.length; i++){\n\t\t\tif (radios[i].checked){\n\t\t\t\tpriorityValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "4e9a7e484f8bcbe2f26c4dbdf0553261", "score": "0.7788249", "text": "function getSelectedRadio() {\n\t\tvar radios = document.forms[0].filmRating;\n\t\tfor (var i=0; i<radios.length; i++) {\n\t\t\tif (radios[i].checked) {\n\t\t\t\tconditionValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "2049d6cb0636a35e3339016d919d91fe", "score": "0.7705264", "text": "static getSelectedRadioValue(name) {\n const options = document.getElementsByName(name);\n let value = null;\n let label = null;\n for(let i=0;i < options.length; i++) {\n if(options[i].checked) {\n value = options[i].value;\n label = options[i].nextElementSibling.innerText;\n }\n }\n return {label, value};\n }", "title": "" }, { "docid": "5d52a3224ccfc11de1803ef7266e38cd", "score": "0.7676415", "text": "function getSelectedRadioButton(){\n var radioButtons = document.getElementsByName(\"radioAssetType\");\n \n for (var i = 0; i < radioButtons.length; i++) {\n if (radioButtons[i].checked) {\n return radioButtons[i].value;\n }\n }\n return null;\n}", "title": "" }, { "docid": "e7b17b282d73ab4464a74becba30a641", "score": "0.76389885", "text": "function GetRadioButtonSelectedValue(radioButtonControl) {\n if (radioButtonControl) {\n radioButtonControl = radioButtonControl.getElementsByTagName(\"input\");\n\n if (radioButtonControl) {\n var optionLength = radioButtonControl.length;\n\n for (var i = 0; i < optionLength; i++) {\n if (radioButtonControl[i].checked == true) {\n return radioButtonControl[i].value;\n }\n }\n }\n }\n\n return '';\n}", "title": "" }, { "docid": "b8a2acf614370c41caa4973cbcb6dcd3", "score": "0.7637944", "text": "function getRadioButtonSelectedValue(ctrl)\n{\n for(i=0;i<ctrl.length;i++)\n if(ctrl[i].checked) return ctrl[i].value;\n}", "title": "" }, { "docid": "3278891ff73aa159678246217d1c26be", "score": "0.7630104", "text": "function radio_value(rb)\n\n{\n\t\n\tif(!rb) { return; }\n\n\tfor(var i=0;i< rb.length;i++) {\n\n\t\tif(rb[i].checked===true) {\n\n\t\t\treturn rb[i].value;\n\n\t\t}\n\n\t}\n\n}", "title": "" }, { "docid": "573cb8535625ac29bf28cb77b6f7d3fa", "score": "0.7551832", "text": "function getSelectedRadio(){\n\t\tvar radios = document.forms(0).relation\n\t\tfor(var i=0; i<radio.length; i++){\n\t\t\tif(radios[i].checked){\n\t\t\t \trelationValue = radios[i].value;\n\t\t\t }\n\t\t}\n\t}", "title": "" }, { "docid": "fd4c79b789fc44c71c6f08af7ff74207", "score": "0.75516963", "text": "function getSelectedRadio(){\n\t\tvar radio = document.forms[0].crust;\n\t\tfor (var i=0 ; i < radio.length; i++){\n\t\t\tif(radio[i].checked) {\n\t\t\t\tcrustValue = radio[i].value; \n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "7e1f18e4cacf4f3b579a0116e75ebbdf", "score": "0.75317013", "text": "function getSelectedRadio(){\n\t\tvar radios = document.forms[0].gender;\n\t\tfor(var i=0; i<radios.length; i++){\n\t\t\tif(radios[i].checked){\n\t\t\t\tgenderValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "e4487e33b36e83a841007fd589ef90df", "score": "0.75141954", "text": "function getRadioValue(buttons){\n for (let i=0; i<buttons.length; i++){\n if (buttons[i].checked){\n return buttons[i].value;\n }\n }\n}", "title": "" }, { "docid": "8f45bb69520e4ae3355eae0a5deff98a", "score": "0.7497202", "text": "function getSelectedRadio() {\n\t\tvar radios = document.forms[0].favorite;\n\t\tfor(var i=0; i<radios.length; i++){\n\t\t\tif(radios[i].checked){\n\t\t\tfavoriteValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "66484a89ad01ef540dc283933ca195b2", "score": "0.7469243", "text": "function getSelectedRadio(){\n var radios = document.forms[0].group;\n for(var i=0; i < radios.length; i++){\n if(radios[i].checked){\n var groupValue = radios[i].value;\n }\n }\n }", "title": "" }, { "docid": "23774e0425b56c1ba1332cac8bf65632", "score": "0.7399705", "text": "function getRadioValue() {\n //Obtengo el conjunto de radio buttons cuyo nombre es fisio\n var ele = document.getElementsByName('fisio');\n //Recorro esos elementos y devuelvo el que esté CHECKED\n for (i = 0; i < ele.length; i++) {\n if (ele[i].checked) {\n return ele[i].value;\n }\n\n }\n return null;\n}", "title": "" }, { "docid": "5a98d2e77055c2de06c4712d7b5ac383", "score": "0.7387145", "text": "function getRadioValue()\n{\n for (var i = 0; i < document.getElementsByName('stor').length; i++)\n {\n \tif (document.getElementsByName('stor')[i].checked)\n \t{\n \t\treturn document.getElementsByName('stor')[i].value;\n \t}\n }\n}", "title": "" }, { "docid": "ba1168c08f38538ebef9e8c84b750304", "score": "0.7385347", "text": "function radioButtonValorSeleccionado(elemento) {\n\tvar totalElementos = elemento.length;\n\tvar i = 0;\n\t\n\twhile(i < totalElementos){\n\t\tif(elemento[i].checked) {\n\t\t\treturn elemento[i].value;\n\t\t}\n\t\ti++;\n\t}\n\t\n\treturn -1;\n}", "title": "" }, { "docid": "92d82653c3307c6d3b298f87834c497f", "score": "0.7383147", "text": "function getSelectedRadio() {\n\t var radio = document.getElementById(\"form\").purchased;\n\t for (var i = 0; i < radio.length; i += 1) {\n\t\t if (radio[i].checked) { \n\t\t\t purchasedValue = radio[i].value;\n\t\t }\n\t }\n }", "title": "" }, { "docid": "b47e91b15699e917474ebae16d35c222", "score": "0.736624", "text": "function getSelectedRadio() {\n\t\tvar radio = document.forms[0].gender;\n\t\tfor (var i=0; i<radio.length; i++) {\n\t\t\tif (radio[i].checked) {\n\t\t\t\tgenderValue = radio[i].value;\n\t\t\t};\n\t\t};\n\t}", "title": "" }, { "docid": "c93a75dcc28a63875fbfaf70fe11592f", "score": "0.7365317", "text": "function getCheckedValue(radioObj) {\n\tif(!radioObj)\n\t\treturn \"\";\n\tvar radioLength = radioObj.length;\n\tif(radioLength == undefined)\n\t\tif(radioObj.checked)\n\t\t\treturn radioObj.value;\n\t\telse\n\t\t\treturn \"\";\n\tfor(var i = 0; i < radioLength; i++) {\n\t\tif(radioObj[i].checked) {\n var checkedButton = radioObj[i].value;\n\n refreshScoreBoard(checkedButton);\n nextQuestion();\n\t\t\treturn checkedButton;\n\t\t}\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "bbce773501a7e36850313eb38716654b", "score": "0.7361635", "text": "function getSelectedRadioBtn() {\n if (document.getElementById('radio-alpha').checked) {\n return \"Positive\";\n } else if (document.getElementById('radio-beta').checked) {\n return \"Negative\";\n } else {\n return \"Pending\";\n }\n}", "title": "" }, { "docid": "794a408966e462ce0190c345c8a68204", "score": "0.7334442", "text": "function getValueFromRadioButtons(arrRadioButtons) {\n\tfor(var i in arrRadioButtons) {\n\t\tvar rb = arrRadioButtons[i];\n\n\t\tif (rb.checked) return rb.value;\n\t}\n\n\t// nothing was checked\n\treturn null;\n}", "title": "" }, { "docid": "e1d61a32f3f8abcefe49d19f44f69415", "score": "0.73052406", "text": "function getRadioVal(form, name) {\r\n\t\t\t\t\tvar radios = form.elements[name];\r\n\t\t\t\t\tvar val;\r\n\t\t\t\t\t\r\n\t\t\t\t\tfor (var i=0, len=radios.length; i<len; i++) {\r\n\t\t\t\t\t\tif ( radios[i].checked == true ) {\r\n\t\t\t\t\t\t\tval = radios[i].value;\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\t\r\n \t\r\n\t\t\t\t\t}\r\n\t\t\t\t\treturn val;\r\n\t\t\t\t}", "title": "" }, { "docid": "c1648d4e12b57a72eaca35137ad730d7", "score": "0.7286235", "text": "function checkedRadioBoxValue(name){\n return document.querySelector(\"input[name='\" + name + \"']:checked\").value;\n }", "title": "" }, { "docid": "ed9016fcae7990d91d4b6460d52d1b4d", "score": "0.72607577", "text": "function get_model_selection(){\n const radio_button_selection = document.querySelectorAll('input[name=\"model_selection\"]');\n let selectedValue;\n for (const selection of radio_button_selection) {\n if (selection.checked) {\n selectedValue = selection.value;\n break;\n }\n }\n return selectedValue;\n}", "title": "" }, { "docid": "05d9910c068015982e402073c94e9bbe", "score": "0.7251404", "text": "function radioButtonValorSeleccionado(elemento) {\n var totalElementos = elemento.length;\n var i = 0;\n\n while(i < totalElementos){\n if(elemento[i].checked) {\n return elemento[i].value;\n }\n i++;\n }\n\n return -1;\n}", "title": "" }, { "docid": "cb35847ac02c398fdb979dd89b889894", "score": "0.72471356", "text": "function getRadioVal(formulaire, radio) {\n \n var boutons = document.getElementsByName(radio);\n var valeur = '';\n for(var i = 0; i < boutons.length; i++){\n if(boutons[i].checked){\n valeur = boutons[i].value;\n }\n }\n \n return valeur;\n}", "title": "" }, { "docid": "b403980032f068c4ea1df0ecf743102a", "score": "0.72275966", "text": "function getValueFromRadio(radioName){\n var radios = document.getElementsByName(radioName);\n for (var i = 0; i < radios.length; i++) {\n if (radios[i].checked) {\n return radios[i].value;\n }\n }\n }", "title": "" }, { "docid": "01d89b0ebfa8421d8c416ec1ac0de8c8", "score": "0.72239983", "text": "function getRadioValue(form) {\n var val;\n // get list of radio buttons with specified name\n var radios = form.elements;\n\n // loop through list of radio buttons\n for (var i = 0; i < 7; i++) {\n if (radios[i].checked) { // radio checked?\n val = radios[i].value; // if so, hold its value in val\n break; // and break out of for loop\n }\n }\n return val; // return value of checked radio or undefined if none checked\n}", "title": "" }, { "docid": "52d06091bf6eb129165942e567115855", "score": "0.71830285", "text": "function getRadioValue(classeUtilizada) {\r\n var radVal = ($(\".\"+ classeUtilizada +\":checked\").val());\r\n return radVal;\r\n}", "title": "" }, { "docid": "7494cd4abe8f45dd72d55a3969754db2", "score": "0.7166532", "text": "getRadioValue(name) {\n let radio = document.getElementsByName(name), i;\n let radioDefault = \"white\";\n for (i = 0; i < radio.length; i++) {\n if (radio[i].checked) {\n return radio[i].value;\n }\n }\n return radioDefault;\n }", "title": "" }, { "docid": "f2667f41b2bc8ca0db1a8a9e03883fc8", "score": "0.71658766", "text": "function GetSelectedRadioValueInGroup(radioGroupName) {\n return $(\"[name='\" + radioGroupName + \"']:checked\").val();\n}", "title": "" }, { "docid": "3845edc8f0cd823bda79aab9a37ce391", "score": "0.7161819", "text": "function getRadioVal(radioName) {\n var rads = document.getElementsByName(radioName);\n for (var rad in rads) {\n if (rads[rad].checked) {\n return rads[rad].value;\n }\n }\n return null;\n}", "title": "" }, { "docid": "eebcbecbf1b02192480486be70435f88", "score": "0.7151278", "text": "function radioValue(){\n\t\tvar rbutton = document.forms[0].sLocation;\n\t\tfor(var i=0; i<rbutton.length; i++){\n\t\t\tif(rbutton[i].checked){\n\t\t\t\tstoreLocation = rbutton[i].value;\t\n\t\t\t}\t\t\t\n\t\t}\n\t}", "title": "" }, { "docid": "b66b12e08c002f2aba86fc4e9e7da5a5", "score": "0.71457076", "text": "function radioValue( radioGrp ){\n for( var i=0; i<radioGrp.length; i++ ){\n if( radioGrp[i].checked == true ){\n if( radioGrp[i].disabled != true ){\t \n return radioGrp[i].value;\n }\n }\n }\n return;\n}", "title": "" }, { "docid": "5f3da32d5703bc8c7bc80fdab39c8e33", "score": "0.7142684", "text": "function getAnswerOption(){\n return document.querySelector('input[name=\"answer\"]:checked').value;\n}", "title": "" }, { "docid": "be8f4aa59ca60a4201d312f834d97717", "score": "0.713644", "text": "function getRadioValue(radioName) {\r\n var rValue = null, rInputs = document.getElementsByName(String(radioName));\r\n for (var i = 0; i < rInputs.length; i++) {\r\n if (rInputs[i].checked) {\r\n rValue = rInputs[i].value;\r\n break;\r\n }\r\n }\r\n return rValue;\r\n }", "title": "" }, { "docid": "3df9d5d2c933308a7bc2616e819b06da", "score": "0.71194667", "text": "function getRadioVal(form, name) {\r\n\tvar val;\r\n\t// gets list of radio buttons with specified name\r\n\tvar radios = form.elements[name];\r\n\r\n\t// loops through the list of radio buttons\r\n\tfor (var i = 0; i < radios.length; i++) {\r\n\t\tif (radios[i].checked) {\r\n\t\t\tval = radios[i].value;\r\n\t\t\tbreak;\r\n\t\t}\r\n\t}\r\n\r\n\treturn val;\r\n}", "title": "" }, { "docid": "7cca0dd8563c5124b429c0950142557b", "score": "0.7112745", "text": "function radiogetselected(radioname) {\r\n\r\n\tvar chkboxgrpele = document.getElementsByName(radioname);\r\n\tvar chkboxtotal = chkboxgrpele.length;\r\n\tfor (i=0; i<chkboxtotal; i++) {\r\n\t\tif (chkboxgrpele[i].checked == true) {\r\n\t\t\treturn chkboxgrpele[i].value;\r\n\t\t}\r\n\t}\r\n\treturn false;\r\n\r\n}", "title": "" }, { "docid": "ded37e3e0542b71340d6fa90526d44ca", "score": "0.70995", "text": "function getValorRadio(nomRadio) {\n var radios = document.getElementsByName(nomRadio);\n for (radio of radios) {\n if (radio.checked) {\n return radio.value;\n }\n }\n return \"\";\n}", "title": "" }, { "docid": "378620089a239c85327adedc49bc335d", "score": "0.7090323", "text": "function getRadioCheckedValue(formNum, radio_name)\n{\n var oRadio = document.forms[formNum].elements[radio_name];\n for(var i = 0; i < oRadio.length; i++)\n {\n if(oRadio[i].checked)\n {\n return oRadio[i].value;\n }\n }\n return '';\n}", "title": "" }, { "docid": "c616368d85e11d1e4b17ec83bd3fbce4", "score": "0.7033419", "text": "function getCheckedRadioValue(radioObj) {\r\n if (!radioObj || radioObj==undefined)\r\n return \"\";\r\n var radioLength = radioObj.length;\r\n if (radioLength == undefined)\r\n if (radioObj.checked)\r\n return radioObj.value;\r\n else\r\n return \"\";\r\n for (var i = 0; i < radioLength; i++) {\r\n if (radioObj[i].checked) {\r\n return radioObj[i].value;\r\n }\r\n }\r\n return \"\";\r\n }", "title": "" }, { "docid": "a34f395b5adfaa43252ef8e0c5785fda", "score": "0.7033121", "text": "function getCheckedRadioValue(radioGroupName) {\n var rads = document.getElementsByName(radioGroupName);\n for (i = 0; i < rads.length; i++)\n if (rads[i].checked)\n return rads[i].value;\n return null; // or undefined, or your preferred default for none checked\n}", "title": "" }, { "docid": "f858ce3a987f242bdc2e29094c0378c8", "score": "0.7014091", "text": "function getOption(){\n\t\treturn $('input:checked').val();\n\t}", "title": "" }, { "docid": "c98897b9f9456db49ab4abf5c4e3b03f", "score": "0.70043355", "text": "function getRadio(){\n\t\tvar radioInputs = document.forms[0].warranty;\n\t\tfor(var i=0; i<radioInputs.length; i++){\n\t\t\tif(radioInputs[i].checked){\n\t\t\t\twarrantyValue = radioInputs[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "6846f7d4039ad5838a67a40758f483c8", "score": "0.6986854", "text": "search_checked_radio(name_input){\n const search = document.getElementsByName(name_input);\n for(const data of search){\n if(data.checked){\n return data.value;\n break;\n }\n }\n }", "title": "" }, { "docid": "afe86e6ab5e07d1febc9f8b3c0bb95a7", "score": "0.6981842", "text": "getTypeRadioValue(iceCreamId) {\n var selectedVal = \"\";\n var selected = $(\"#\" + iceCreamId + \"typeRadio\" + \" input[type='radio']:checked\");\n if (selected.length > 0) {\n selectedVal = selected.val();\n return selectedVal;\n }\n }", "title": "" }, { "docid": "33d67d065007f88e52843092b3887e24", "score": "0.6959676", "text": "function getRadioCheck(tagSelect)\n{\n var strSelectOption = \"\";//holds the select option the user has choosen\n\t\n\t//gets the name of the radio button as it uses the name to group all together\n\ttagSelect = document.getElementsByName(tagSelect);\n\n //goes around finding the current seleted value from tagSelection\n for (var intIndex = 0;intIndex < tagSelect.length; intIndex++)\n {\n if (tagSelect[intIndex].checked == true)\n strSelectOption = tagSelect[intIndex].value;\n }//end of for loop\n \n return strSelectOption;\n}//end of getRadioCheck()", "title": "" }, { "docid": "45329f3edd09701fbe0acb1dd2660f9f", "score": "0.6955827", "text": "function getSpendingThreshold() {\r\n //for loop finding val of radial input\r\n var options = document.getElementsByName('optionsRadios');\r\n var s;\r\n for(var i = 0; i < options.length; i++){\r\n if(options[i].checked){\r\n s = options[i].value; \r\n }\r\n }\r\n \r\n return Number(s); //which one they selected\r\n}", "title": "" }, { "docid": "3344ca801ccef9df632dc01db6d19eca", "score": "0.6947587", "text": "function getChecked() {\n\t\tlet radio = document.querySelectorAll('.numOfGames');\n\t\tfor (let i = 0; i < radio.length; i++) {\n\t\t\tif(radio[i].checked) {\n\t\t\t\treturn radio[i].getAttribute('value');\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "9a2d58709d691d26ac99a735df6abd97", "score": "0.69443893", "text": "function getNameRadioValue(idNameList) {\n var valueReturned = -1;\n for (var j=0; j<idNameList.length;j++ ) {\n if (document.getElementById(idNameList[j]).checked) {\n valueReturned = j;\n }\n }\n return valueReturned;\n}", "title": "" }, { "docid": "24efda293463e39381b60e9f2e60e536", "score": "0.69442034", "text": "function getCheckedRadio(name) {\n\tvar match = 0;\n\tvar radioButtons = document.getElementsByName(name);\n\tfor (x = 0; x < radioButtons.length; x++) {\n\t\tif (radioButtons[x].checked) {\n\t\t\treturn radioButtons[x].value;\n\t\t\tbreak;\n\t\t}\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "97de523047b05100e56ee23825e12719", "score": "0.69371474", "text": "function getCheckedValue(radioObj) {\r\n\tvar radioLength = radioObj.length;\r\n\tif(radioLength == undefined) {\r\n\t\tif(radioObj.checked) {\r\n\t\t\treturn radioObj.value;\r\n\t\t}\r\n\t\telse {\r\n\t\t\treturn \"\";\r\n\t\t}\r\n\t}\r\n\tfor(var i = 0; i < radioLength; i++) {\r\n\t\tif(radioObj[i].checked) {\r\n\t\t\treturn radioObj[i].value;\r\n\t\t}\r\n\t}\r\n\treturn \"\";\r\n}", "title": "" }, { "docid": "9820866bd9fd6df41f2383eb61791795", "score": "0.69269854", "text": "function getCheckedValue(radioObj) {\r\n\tif(!radioObj)\r\n\t\treturn false;\r\n\tvar radioLength = radioObj.length;\r\n\tif(radioLength == undefined)\r\n\t\tif(radioObj.checked)\r\n\t\t\treturn radioObj.value;\r\n\t\telse\r\n\t\t\treturn false;\r\n\tfor(var i = 0; i < radioLength; i++) {\r\n\t\tif(radioObj[i].checked) {\r\n\t\t\treturn radioObj[i].value;\r\n\t\t}\r\n\t}\r\n\treturn false;\r\n}", "title": "" }, { "docid": "22b7df046d84e883d5a22c8733f1acc7", "score": "0.6916099", "text": "function getCheckedValue(radioObj) {\r\n\tif (!radioObj)\r\n\t\treturn \"\";\r\n\tvar radioLength = radioObj.length;\r\n\tif (radioLength == undefined)\r\n\t\tif (radioObj.checked)\r\n\t\t\treturn radioObj.value;\r\n\t\telse\r\n\t\t\treturn \"\";\r\n\tfor (var i = 0; i < radioLength; i++) {\r\n\t\tif (radioObj[i].checked) {\r\n\t\t\treturn radioObj[i].value;\r\n\t\t}\r\n\t}\r\n\treturn \"\";\r\n}", "title": "" }, { "docid": "d1539b19ede2f0457163f2e7a390634a", "score": "0.68929976", "text": "function getCheckedValue(radioObj) {\r\n\tif(!radioObj)\r\n\t\treturn \"\";\r\n\tvar radioLength = radioObj.length;\r\n\tif(radioLength == undefined)\r\n\t\tif(radioObj.checked)\r\n\t\t\treturn radioObj.value;\r\n\t\telse\r\n\t\t\treturn \"\";\r\n\tfor(var i = 0; i < radioLength; i++) {\r\n\t\tif(radioObj[i].checked) {\r\n\t\t\treturn radioObj[i].value;\r\n\t\t}\r\n\t}\r\n\treturn \"\";\r\n}", "title": "" }, { "docid": "7137295bbaa6e87186739bf3cc07fce8", "score": "0.68861485", "text": "function getCheckedRadioValue(name) {\r\n var elements = document.getElementsByName(name);\r\n\r\n for (var i = 0, len = elements.length; i < len; ++i)\r\n if (elements[i].checked) return elements[i].value;\r\n}", "title": "" }, { "docid": "a3615cd8fbb6f7672e519cea8236f696", "score": "0.68630826", "text": "function getSelectedRadio() {\n\t\tvar radios = document.forms[0].mins;\n\t\tfor (var i=0; i<radios.length; i++) {\n\t\t\tif(radios[i].checked) {\n\t\t\t\tminValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "89bf6e81c75b68f9e3cd0a01fbef8a92", "score": "0.6853041", "text": "function getCheckedValue(radioObj) {\r\n\tif(!radioObj)\r\n\t\treturn \"\";\r\n\r\n\tvar radioLength = radioObj.length;\r\n\tif(radioLength == undefined)\r\n\t\tif(radioObj.checked)\r\n\t\t\treturn radioObj.value;\r\n\t\telse\r\n\t\t\treturn \"\";\r\n\tfor(var i = 0; i < radioLength; i++) {\r\n\t\tif(radioObj[i].checked) {\r\n\t\t\treturn radioObj[i].value;\r\n\t\t}\r\n\t}\r\n\r\n\treturn \"\";\r\n}", "title": "" }, { "docid": "af09e5d48a3486dd0d957a746d495480", "score": "0.6848841", "text": "function getSelected() {\n const answerEls = document.querySelectorAll(\".answer\");\n let answer = undefined;\n answerEls.forEach((answerEl) => {\n if (answerEl.checked) {\n answer = answerEl.value;\n }\n });\n\n return answer;\n }", "title": "" }, { "docid": "603c0b6bc2e2c9577efb6f5f4b948c0f", "score": "0.6844412", "text": "function getCheckedValue( groupName ) {\n var radios = document.getElementsByName( groupName );\n for( i = 0; i < radios.length; i++ ) {\n if( radios[i].checked ) {\n return radios[i].value;\n }\n }\n return null;\n}", "title": "" }, { "docid": "930f48808a55a979bdfa81adb3f14c5b", "score": "0.68400383", "text": "function valButton(btn) {var cnt = -1;for (var i=btn.length-1; i > -1; i--) { if (btn[i].checked) {cnt = i; i = -1;}}if (cnt > -1) return btn[cnt].value;else return null;}", "title": "" }, { "docid": "70504a8d772a3b0b7fd22bc88923e13d", "score": "0.6820381", "text": "function RadioValue(element)\r\n{\r\n for (var i=0; i <= element.length; i++)\r\n {\r\n if(element[i].checked == true)\r\n {\r\n return element[i].value;\r\n }\r\n }\r\n\r\nreturn;\r\n}", "title": "" }, { "docid": "99b44209c4e4948b30b25948f8d12381", "score": "0.6817696", "text": "function getRadio(){\n\t\tvar radios = document.forms[0].timeOfDay;\n\t\tfor(var i=0; i<radios.length; i++){\n\t\t\tif(radios[i].checked){\n\t\t\t\ttimeValue = radios[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "7cbbb2ae9b60685781db1a2a34cbcc8d", "score": "0.6814171", "text": "function findRadioValue(radioGroup) {\n for (let i = 0; i < radioGroup.length; i++) {\n if (radioGroup[i].checked) {\n return i;\n }\n\n }\n}", "title": "" }, { "docid": "6970c47977b2e1c0075c090b2b2b640e", "score": "0.67933667", "text": "function radioCheckedValueGet(rdId){\n\tvar fldElement = document.getElementById(rdId);\n\tif(!fldElement)\treturn;\n\tvar rdbName = fldElement.getAttribute('name')\n var rdbObjArr = document.getElementsByName(rdbName);\n if (rdbObjArr.length < 1) \n return null;\n var value = null;\n for (var i = 0; i < rdbObjArr.length; ++i) {\n if ((!rdbObjArr[i].disabled) && rdbObjArr[i].checked) {\n value = rdbObjArr[i].value;\n break;\n }\n }\n return value;\n}", "title": "" }, { "docid": "5e13487d19ba5f392380332632f22d40", "score": "0.6784724", "text": "function __getCheckedValue(el) {\n if(!el) return \"\";\n var radioLength = el.length;\n if(radioLength == undefined)\n if(el.checked)\n return el.value;\n else\n return \"\";\n for(var i = 0; i < radioLength; i++) {\n if(el[i].checked) {\n return el[i].value;\n }\n }\n return \"\";\n}", "title": "" }, { "docid": "00ed796a5d71994c5375894e9fb54bb9", "score": "0.67599636", "text": "function getRadioValueByCost() { \n var ele = document.getElementsByName('sortByPrice'); \n for(i = 0; i < ele.length; i++) { \n if(ele[i].checked) return ele[i].id; \n } \n}", "title": "" }, { "docid": "6458fb7579441cda0b313c4dc3b20a31", "score": "0.67592055", "text": "function GetSelRadValue(objRadGroup){\n\tfor (var i=0; i<objRadGroup.length; i++){\n\t\tif (objRadGroup[i].checked) return objRadGroup[i].value;\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "42bd06c30bb6838ed04aa5a6a02be802", "score": "0.67541856", "text": "function check() {\n let radios = document.getElementsByName('radioButtonAnswers');\n for (let k = 0; k < radios.length; k++) {\n if (radios[k].checked) {\n // get value, set checked flag or do whatever you need to\n value = radios[k].value;\n console.log(value);\n}\n}\n}", "title": "" }, { "docid": "a7aab749120ec91dc43d299e7cd54f91", "score": "0.6746615", "text": "function getCheckedValue(radioObj) {\n\tif(!radioObj)\n\t\treturn \"\";\n\tvar radioLength = radioObj.length;\n\tif(radioLength == undefined)\n\t\tif(radioObj.checked)\n\t\t\treturn radioObj.value;\n\t\telse\n\t\t\treturn \"\";\n\tfor(var i = 0; i < radioLength; i++) {\n\t\tif(radioObj[i].checked) {\n\t\t\treturn radioObj[i].value;\n\t\t}\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "a7aab749120ec91dc43d299e7cd54f91", "score": "0.6746615", "text": "function getCheckedValue(radioObj) {\n\tif(!radioObj)\n\t\treturn \"\";\n\tvar radioLength = radioObj.length;\n\tif(radioLength == undefined)\n\t\tif(radioObj.checked)\n\t\t\treturn radioObj.value;\n\t\telse\n\t\t\treturn \"\";\n\tfor(var i = 0; i < radioLength; i++) {\n\t\tif(radioObj[i].checked) {\n\t\t\treturn radioObj[i].value;\n\t\t}\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "ba67091495ffc17da322a67b697b7c54", "score": "0.6723791", "text": "function getRadioGroupValue(radioGroupObj) {\n\tfor (var i=0; i < radioGroupObj.length; i++)\n\t\tif (radioGroupObj[i].checked) return radioGroupObj[i].value;\n\treturn null;\n}", "title": "" }, { "docid": "063b7f95d0b73df88dee02093ff32f0e", "score": "0.67184967", "text": "function selRadio(){\n\t\tvar rad = document.forms[0].sex;\n\t\tfor (var i = 0; i<rad.length; i++){\n\t\t\tif(rad[i].checked){\n\t\t\tsexData = rad[i].value;\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "5a0e64cd3975cc8298703e430b44379f", "score": "0.66845703", "text": "function displayRadioValue() {\n elem.radioInputx = document.getElementsByName('one_option');\n\t//Loop through the options\n for(let i = 0; i < elem.radioInputx.length; i++) {\n\t\t//Get the value of the checked radio\n\t\tif(elem.radioInputx[i].checked){\n\n\t\t\telem.radioAnswer = elem.radioInputx[i].value;\n\t\t}\n\t\telem.radioInputx[i].checked = false;\n }\n}", "title": "" }, { "docid": "29076909ae1a8e7d267912042c6b1cd4", "score": "0.66797584", "text": "function GetSelectedMeasurement()\r\n{\r\n\tvar SelectedIndex=-1; // Declares the index of selected radio button\r\n\tfor (var i=0;i<Measurements.length;i++) // Iterates through the number of elements of \"Measurement\" aary in Global variables\r\n\t{\r\n\t\tvar GetRadioOptions = document.getElementById(\"Measurement\"+Measurements[i]); // Gets the id of the radio buttons\r\n\t\tif (GetRadioOptions.checked) // If the radio button is checked proceed\r\n\t\t{\r\n\t\t\tSelectedIndex=i; // Provides the index of the selected radio button\r\n\t\t}\r\n\t}\r\n\treturn(SelectedIndex); // Returns the value of the SelectedIndex value\r\n}", "title": "" }, { "docid": "d5b3b4ad22c9b196bab64e93b6890bae", "score": "0.6647328", "text": "getSizeRadioValue(iceCreamId) {\n var selectedVal = \"\";\n var selected = $(\"#\" + iceCreamId + \"sizeRadio\" + \" input[type='radio']:checked\");\n if (selected.length > 0) {\n selectedVal = selected.val();\n return selectedVal;\n }\n }", "title": "" }, { "docid": "8e79829daed07c740037c4aed91d25b9", "score": "0.6646757", "text": "function elecciond() {\n for (var i = 0; i < radioBtnd.length; i++)\n {\n if (radioBtnd[i].checked)\n resultado = radioBtnd[i].value;\n }\n return resultado;\n}", "title": "" }, { "docid": "903246cb5deba223ed4b4884aad97424", "score": "0.6630851", "text": "function getRadio(name){\r\n\r\n\tvar rads = document.getElementsByName(name);\r\n\r\n\tfor(var i = 0; i < rads.length; i++){\r\n\r\n\t\tif(rads[i].checked){\r\n\r\n\t\t\treturn rads[i].value;\t//verifica se esta marcado o radio e pega o valor dele(0[incorreta] ou 1[correta])\r\n\r\n\t\t}//if\r\n\r\n\t}//for\r\n\r\n\treturn null;\r\n\r\n}", "title": "" }, { "docid": "21bb9492856f697f82d0102d36ad79d3", "score": "0.6566874", "text": "function get_selected_classifier() {\n // Dataset radio buttons\n let name = \"\"\n let rlist = document.getElementsByName(\"sel-cl\");\n for (let i = 0, length = rlist.length; i < length; i++) {\n if (rlist[i].checked) {\n name = rlist[i].value;\n break;\n }\n }\n return name;\n}", "title": "" }, { "docid": "8ccdbd16e441a0a566064d421b8b8eba", "score": "0.6558084", "text": "function getSelectedRadioBtnIndex(){\n if (aiPlayerACheckbox.checked == true){\n let difficultyRadioBtns = document.getElementsByName('difficultyForA')\n\n for(i=0; i < difficultyRadioBtns.length; i++){\n if(difficultyRadioBtns[i].checked == true){\n return i;\n }\n }\n }else if (aiPlayerBCheckbox.checked == true){\n let difficultyRadioBtns = document.getElementsByName('difficultyForB')\n\n for(i=0; i < difficultyRadioBtns.length; i++){\n if(difficultyRadioBtns[i].checked == true){\n return i;\n }\n }\n }\n }", "title": "" }, { "docid": "4f64af06deb8afd07533d399a9ea0d3c", "score": "0.65553933", "text": "function verifRadio(Elegido){\n if (Elegido[0]!=null){\n for (i=0;i<Elegido.length;i++){\n if (Elegido[i].checked==true){\n return Elegido[i].value;\n }\n }\n return \"\";\n }else{\n if (Elegido.checked){\n return Elegido.value;\n }else{\n return \"\";\n }\n }\n}", "title": "" }, { "docid": "aa67055bfad4914ef401f28aedaa3aa6", "score": "0.6549045", "text": "function TextOrURL(){\n return ($(\".radioButtons\").attr('id'));\n}", "title": "" }, { "docid": "2259ccb5568d4fa29f437b38ce786315", "score": "0.65393597", "text": "function get_id() {\n for (var iter = 0, len = radio_buttons.length; iter < len; iter++){\n if(radio_buttons[iter].checked){\n return radio_buttons[iter].id\n }\n }\n}", "title": "" }, { "docid": "65b98240dab863f63eb414bead4c7c1d", "score": "0.6514739", "text": "function whoIsCheck(name){\n\n var radios = document.getElementsByName(name);\n var valor = \"\";\n\n for (var i = 0, length = radios.length; i < length; i++) {\n if (radios[i].checked) {\n // do whatever you want with the checked radio\n // alert(radios[i].value);\n // only one radio can be logically checked, don't check the rest\n return radios[i].value;\n break;\n }\n}\n \n}", "title": "" }, { "docid": "9beac97658da308a1295ee9820ac05b8", "score": "0.6508503", "text": "function getCheckedRadio(radio_group) {\n for (var i = 0; i < radio_group.length; i++) {\n var radio = radio_group[i];\n if (radio.checked) {\n return radio;\n }\n }\n return undefined;\n}", "title": "" }, { "docid": "c856a76ab70737135d497cb8b6c1c8e0", "score": "0.65047705", "text": "function getValueOfElement(e) {\n if ($(e).is(':checkbox')) {\n //Changes for IWmain\n //return $(e).is(':checked') ? '1' : '0';\n var name = $(e).attr('name');\n return $(e).is(':checked') ? $('input[name=\"'+name+'\"]').val() : '0';\n } else if ($(e).is(':radio')) {\n var name = $(e).attr('name');\n return $('input[name=\"'+name+'\"]:checked').val();\n } else {\n return $(e).val();\n }\n }", "title": "" }, { "docid": "a4135e6476f30c50487ce8e63abca4db", "score": "0.6468404", "text": "function getAnswersFromRadioButtons(){\n\tvar radio = document.getElementsByName('answer');\n\tfor(var i = 0; i < radio.length; i++){ \n\t\tif(radio[i].checked == true) return i; \n\t\telse continue;\n\t}\n\treturn -1;\n}", "title": "" }, { "docid": "613b69ba16c5c53f8135001dfd0f10fc", "score": "0.64611405", "text": "function getValue($el) {\n return $el.is('[type=\"checkbox\"]') ? $el.prop('checked') :\n $el.is('[type=\"radio\"]') ? !!$('[name=\"' + $el.attr('name') + '\"]:checked').length :\n $el.val()\n }", "title": "" }, { "docid": "613b69ba16c5c53f8135001dfd0f10fc", "score": "0.64611405", "text": "function getValue($el) {\n return $el.is('[type=\"checkbox\"]') ? $el.prop('checked') :\n $el.is('[type=\"radio\"]') ? !!$('[name=\"' + $el.attr('name') + '\"]:checked').length :\n $el.val()\n }", "title": "" }, { "docid": "613b69ba16c5c53f8135001dfd0f10fc", "score": "0.64611405", "text": "function getValue($el) {\n return $el.is('[type=\"checkbox\"]') ? $el.prop('checked') :\n $el.is('[type=\"radio\"]') ? !!$('[name=\"' + $el.attr('name') + '\"]:checked').length :\n $el.val()\n }", "title": "" }, { "docid": "7afa1e5b39f22b684d3626e104e2ec34", "score": "0.6445388", "text": "function playerSelection(){\n let decision = getRadioVal();\n console.log(\"Players selection: \" + decision);\n return decision;\n}", "title": "" }, { "docid": "f7d9041d4babd8a939eae4cbaf260610", "score": "0.6429717", "text": "getAnswer () {\n if (this.response.alternatives) {\n let parent = this.shadowRoot.querySelector('#radioBtnContainer').children\n Array.from(parent).some((element) => {\n if (element.checked) {\n console.log('getRadioAnswer:' + element.value)\n this.userAnswer = element.value\n return true\n } else return false\n })\n } else {\n this.userAnswer = this._inputText.value\n }\n }", "title": "" }, { "docid": "cd69745cc4d367ea1e2437f9d22b8bff", "score": "0.63854957", "text": "function selectedOne() {\n let getAnswer = undefined;\n\n allAnswers.forEach((answer) => {\n if (answer.checked) {\n getAnswer = answer.id;\n }\n });\n return getAnswer;\n}", "title": "" }, { "docid": "c0c46ae70476d11820a6154b53b02d69", "score": "0.63632756", "text": "function getBikerGroupRide() {\n var radios = document.getElementsByName('biker-group-ride');\n for (var i = 0, length = radios.length; i < length; i++) {\n if (radios[i].checked) {\n return (radios[i].value);\n }\n }\n}", "title": "" }, { "docid": "dfbba241e1db6df990e12b5ea9657dc6", "score": "0.6360204", "text": "function choose() {\n let radio = document.getElementsByName('answer');\n console.log('test');\n for (let i = 0; i < radio.length; i++) {\n console.log(radio[i]);\n if (radio[i].checked) {\n selections[questionCounter] = +radio[i].value;\n console.log('checked', selections[questionCounter]);\n\n }\n }\n // selections[questionCounter] = +$('input[na\\me=\"answer\"]:checked').val();\n}", "title": "" }, { "docid": "005396a8efc1571e60af0afe871c55f6", "score": "0.6358116", "text": "function get_selected_dataset() {\n // Dataset radio buttons\n let name = \"\"\n let rlist = document.getElementsByName(\"sel-ds\");\n for (let i = 0, length = rlist.length; i < length; i++) {\n if (rlist[i].checked) {\n name = rlist[i].value;\n break;\n }\n }\n return name;\n}", "title": "" }, { "docid": "dd23f8cb316eb6cc1334cf7e47c02c94", "score": "0.6313569", "text": "function getSelection() {\n selections[questionCounter] = $('input[name=\"option\"]:checked').val();\n}", "title": "" }, { "docid": "2e6b765bc7f50b786cae83547386003a", "score": "0.630786", "text": "static get checkedRadio() {\n return Glyph._byLocation(4, 4, 'checked');\n }", "title": "" } ]
5c71cdbb11a46a96899fc5788cd5c5a9
Fetches a monochrome sprite bitmap for the specified text. Load in batches for speed.
[ { "docid": "ce22e1db8644ca96a36cbb692deaf453", "score": "0.0", "text": "function cloudSprite(contextAndRatio, d, data, di) {\n if (d.sprite) return;\n var c = contextAndRatio.context,\n ratio = contextAndRatio.ratio;\n\n c.clearRect(0, 0, (cw << 5) / ratio, ch / ratio);\n var x = 0,\n y = 0,\n maxh = 0,\n n = data.length,\n w, w32, h, i, j;\n --di;\n while (++di < n) {\n d = data[di];\n c.save();\n c.font = d.style + \" \" + d.weight + \" \" + ~~((d.size + 1) / ratio) + \"px \" + d.font;\n w = c.measureText(d.text + \"m\").width * ratio;\n h = d.size << 1;\n if (d.rotate) {\n var sr = Math.sin(d.rotate * cloudRadians),\n cr = Math.cos(d.rotate * cloudRadians),\n wcr = w * cr,\n wsr = w * sr,\n hcr = h * cr,\n hsr = h * sr;\n w = (Math.max(Math.abs(wcr + hsr), Math.abs(wcr - hsr)) + 0x1f) >> 5 << 5;\n h = ~~Math.max(Math.abs(wsr + hcr), Math.abs(wsr - hcr));\n } else {\n w = (w + 0x1f) >> 5 << 5;\n }\n if (h > maxh) maxh = h;\n if (x + w >= (cw << 5)) {\n x = 0;\n y += maxh;\n maxh = 0;\n }\n if (y + h >= ch) break;\n c.translate((x + (w >> 1)) / ratio, (y + (h >> 1)) / ratio);\n if (d.rotate) c.rotate(d.rotate * cloudRadians);\n c.fillText(d.text, 0, 0);\n if (d.padding) {\n c.lineWidth = 2 * d.padding;\n c.strokeText(d.text, 0, 0);\n }\n c.restore();\n d.width = w;\n d.height = h;\n d.xoff = x;\n d.yoff = y;\n d.x1 = w >> 1;\n d.y1 = h >> 1;\n d.x0 = -d.x1;\n d.y0 = -d.y1;\n d.hasText = true;\n x += w;\n }\n var pixels = c.getImageData(0, 0, (cw << 5) / ratio, ch / ratio).data,\n sprite = [];\n while (--di >= 0) {\n d = data[di];\n if (!d.hasText) continue;\n w = d.width;\n w32 = w >> 5;\n h = d.y1 - d.y0;\n // Zero the buffer\n for (i = 0; i < h * w32; i++) sprite[i] = 0;\n x = d.xoff;\n if (x == null) return;\n y = d.yoff;\n var seen = 0,\n seenRow = -1;\n for (j = 0; j < h; j++) {\n for (i = 0; i < w; i++) {\n var k = w32 * j + (i >> 5),\n m = pixels[((y + j) * (cw << 5) + (x + i)) << 2] ? 1 << (31 - (i % 32)) : 0;\n sprite[k] |= m;\n seen |= m;\n }\n if (seen) seenRow = j;\n else {\n d.y0++;\n h--;\n j--;\n y++;\n }\n }\n d.y1 = d.y0 + seenRow;\n d.sprite = sprite.slice(0, (d.y1 - d.y0) * w32);\n }\n}", "title": "" } ]
[ { "docid": "ba7223cdca4ad0ad69ab032af8461c8a", "score": "0.5871361", "text": "bitmapText(content = \"message\", font, align, tint, x = 0, y = 0) {\n\n //Create a Pixi Sprite object\n let message = new this.BitmapText(content, {font: font, align: align, tint: tint});\n message.x = x;\n message.y = y;\n\n //Add a `_text` property with a getter/setter\n message._content = content;\n Object.defineProperty(message, \"content\", {\n get() {\n return this._content;\n },\n set(value) {\n this._content = value;\n this.text = value;\n },\n enumerable: true, configurable: true\n });\n\n //Return the text object\n return message;\n }", "title": "" }, { "docid": "c3c01552c26dbc45f981621ce9ae8492", "score": "0.58620465", "text": "async function getBitmaps(selection) {\n try {\n let rawBitmap = await fetch(\"https://raw.githubusercontent.com/basti79/LCD-fonts/master/\" + selection);\n rawBitmap = await rawBitmap.text(); // Convert to text\n const bitmaps = rawBitmap.match(/(?<={).*(?=})/g); // Extract bitmaps using regex magic :)\n return [...bitmaps]; // Return array of fonts\n } catch (err) {\n throw \"Failed to load font!\\n Make sure you can access the raw files from: https://github.com/basti79/LCD-fonts\";\n }\n}", "title": "" }, { "docid": "b11ba2498c260e5f07b020dd1c30c0e4", "score": "0.57946193", "text": "function sprite_drawfont(x,y,pic,text) {\n\t// save previous sprite state\n\tvar rotatemodesave = spt_rotatemode;\n\tvar frmsave = spt_frm;\n\tvar handxsave = spt_handx;\n\tvar handysave = spt_handy;\n\tvar douvssave = spt_douvs;\n\tvar u0save = spt_u0;\n\tvar v0save = spt_v0;\n\tvar u1save = spt_u1;\n\tvar v1save = spt_v1;\n\t\n\t// setup for font sprite state\n\tspt_rotatemode = false;\n\tspt_frm = false;\n\tspt_handx = 0;\n\tspt_handy = 0;\n\tspt_douvs = true;\n\t\n\t// draw text as font sprites\n\tspt_infont = true;\n\tvar i;\n\tvar n = text.length;\n\tvar xs = x;\n\tfor (i=0;i<n;++i) {\n\t\tvar cc =\ttext.charCodeAt(i);\n\t\tif (cc >= 128)\n\t\t\tcontinue;\n\t\tif (cc == 32) { // space\n\t\t\tx += spt_lastw;\n\t\t\tcontinue;\n\t\t}\n\t\tif (cc == 10) { // \\n\n\t\t\tx = xs;\n\t\t\ty += spt_lasth;\n\t\t\tcontinue;\n\t\t}\n\t\tvar r = cc>>3;\n\t\tvar c = cc&7;\n\t\tvar fx = .025; // fudge in, helps prevent wrap around effects\n\t\tvar fy = .025;\n\t\tsprite_setuvs(c/8.0,r/16.0,(c+1)/8.0-fx/8.0,(r+1)/16.0-fy/16.0);\n//\t\tsprite_setuvs(c/8.0+fx/8.0,r/16.0+fy/16.0,(c+1)/8.0-fx/8.0,(r+1)/16.0-fy/16.0);\n\t\tsprite_draw(x,y,pic);\n\t\tx += spt_lastw;\n\t\t// y += spt_lasth;\n\t}\n\tspt_infont = false;\n\t\n\t// restore previous sprite state\n\tspt_rotatemode = rotatemodesave;\n\tspt_frm = frmsave;\n\tspt_handx = handxsave;\n\tspt_handy = handysave;\n\tspt_douvs = douvssave;\n\tspt_u0 = u0save;\n\tspt_v0 = v0save;\n\tspt_u1 = u1save;\n\tspt_v1 = v1save;\n}", "title": "" }, { "docid": "73400d6213cec11e05b6beb98b016556", "score": "0.56913924", "text": "function genProcentSprite(text, xPosition, yPosition) {\n var structureCanvas = document.createElement('canvas');\n structureCanvas.width = 1200;\n structureCanvas.height = 1200;\n var structureContext = structureCanvas.getContext('2d');\n structureContext.font = 'bold 60px Montserrat,Helvetica';\n structureContext.fillStyle = \"rgba(255,255,255, 1.0)\";\n structureContext.fillText(text, 5, 50);\n\n var texture = new THREE.Texture(structureCanvas);\n texture.needsUpdate = true;\n var spriteMaterial = new THREE.SpriteMaterial({\n map: texture\n });\n var sprite = new THREE.Sprite(spriteMaterial);\n sprite.scale.set(250, 250, 1.0);\n sprite.position.set(xPosition, yPosition, 980);\n return sprite;\n}", "title": "" }, { "docid": "7b811a37914a48f5c758741503d66007", "score": "0.5641945", "text": "function genBigSprite(text, xPosition, yPosition, zPosition, color) {\n\n var structureCanvas = document.createElement('canvas');\n structureCanvas.width = 1200;\n structureCanvas.height = 1200;\n var structureContext = structureCanvas.getContext('2d');\n structureContext.font = 'bold 70px Montserrat,Helvetica';\n structureContext.fillStyle = color;\n structureContext.fillText(text, 5, 50);\n\n var texture = new THREE.Texture(structureCanvas);\n texture.needsUpdate = true;\n var spriteMaterial = new THREE.SpriteMaterial({\n map: texture\n });\n var sprite = new THREE.Sprite(spriteMaterial);\n sprite.scale.set(250, 250, 1.0);\n sprite.position.set(xPosition, yPosition, zPosition);\n\n return sprite;\n}", "title": "" }, { "docid": "ecb2cd6fbeae81c810787053aa88fefd", "score": "0.5639676", "text": "function loadSprite(url) {\n // This could be an ajax request to the url, and get the file from CDN, for now\n // we will just read from the FS\n\n return fs.readFileSync(url);\n}", "title": "" }, { "docid": "8e0bbfadf45a3811bf327d04c0cdef14", "score": "0.562409", "text": "rasterizeTexts (tile, texts) {\n let canvas = new CanvasText();\n let texture_size = canvas.setTextureTextPositions(texts);\n log.trace(`text summary for tile ${tile}: fits in ${texture_size[0]}x${texture_size[1]}px`);\n\n // update canvas size & rasterize all the text strings we need\n canvas.resize(...texture_size);\n canvas.rasterize(tile, texts, texture_size);\n\n // create a texture\n let t = 'labels-' + tile + '-' + (TextStyle.texture_id++);\n let texture = new Texture(this.gl, t);\n texture.setCanvas(canvas.canvas, {\n filtering: 'linear',\n UNPACK_PREMULTIPLY_ALPHA_WEBGL: true\n });\n\n return { texts, texture: t }; // texture is returned by name (not instance)\n }", "title": "" }, { "docid": "8943f7742927b18f987406d6d02dcfac", "score": "0.5604862", "text": "function genSprite(text, xPosition, yPosition) {\n var structureCanvas = document.createElement('canvas');\n structureCanvas.width = 1200;\n structureCanvas.height = 1200;\n var structureContext = structureCanvas.getContext('2d');\n structureContext.font = 'bold 70px Montserrat,Helvetica';\n structureContext.fillStyle = \"rgba(255,255,255, 1.0)\";\n structureContext.fillText(text, 10, 50);\n\n var texture = new THREE.Texture(structureCanvas);\n texture.needsUpdate = true;\n var spriteMaterial = new THREE.SpriteMaterial({\n map: texture\n });\n var sprite = new THREE.Sprite(spriteMaterial);\n sprite.scale.set(150, 150, 1.0);\n sprite.position.set(xPosition, yPosition, 900);\n return sprite;\n}", "title": "" }, { "docid": "fe6111d4197b635f93b529473863d7f1", "score": "0.55378807", "text": "draw(ctx, text, fontSize = 0, x = 0, y = 0, textAlign = \"left\") {\n if (!text) return;\n\n let fontScale = fontSize / this.bitmapFont.defaultSize;\n let charArr = text.toString().split(\"\");\n\n if (textAlign == \"center\") {\n let textWidth = 0;\n charArr.forEach(n => {\n let ch = this.bitmapFont.chars[n];\n textWidth += fontScale * parseInt(ch.xadvance);\n });\n x -= 0.5 * textWidth;\n }\n\n if (textAlign == \"right\") {\n charArr = charArr.reverse();\n }\n\n charArr.map(n => {\n let ch = this.bitmapFont.chars[n];\n let xadvance = fontScale * parseInt(ch.xadvance);\n ctx.drawImage(\n this.bitmapFont.bitmap,\n parseInt(ch.x),\n parseInt(ch.y),\n parseInt(ch.width),\n parseInt(ch.height),\n fontScale * parseInt(ch.xoffset) + (textAlign == \"right\" ? -xadvance : 0) + x,\n fontScale * parseInt(ch.yoffset) + y,\n fontScale * parseInt(ch.width),\n fontScale * parseInt(ch.height)\n );\n x += xadvance * (textAlign == \"right\" ? -1 : 1);\n });\n\n return x;\n }", "title": "" }, { "docid": "5521c3c1a25532fea5bab2e90e8fec29", "score": "0.551416", "text": "function BitmapSprite(img) {\n\t\tthis.Bitmap_constructor(img);\n\t\tthis._x = this._y = this._z = 0;\n\t\tthis._scaleX = this._scaleY = 1;\n\t}", "title": "" }, { "docid": "b8afd62621f186f08c090e2c3bf6d423", "score": "0.5509366", "text": "function preload(){\n ness.image = loadImage(\"assets/images/ness.png\");\n paula.image = loadImage(\"assets/images/paula.png\");\n lucas.image = loadImage(\"assets/images/lucas.png\");\n\n myFont = loadFont('assets/font/twoson.ttf');\n}", "title": "" }, { "docid": "2be13a85eb285ca4f7c211d946d50cf4", "score": "0.54126024", "text": "function loadSprite(url)\n{\n\tvar o = new Image();\n\to.src = url;\n\treturn o;\n}", "title": "" }, { "docid": "0a31067dd393079aa3e4f98468edcca5", "score": "0.5378903", "text": "function preload() {\n //loading in coolFont\n coolFont = loadFont(\"assets/WalterTurncoat-Regular.ttf\");\n avatarImage = loadImage(\"assets/images/nyan-cat.png\");\n enemyImage = loadImage(\"assets/images/tac-nayn.png\");\n screamingInternally = loadImage(\"assets/images/internally-screaming.jpg\");\n\n}", "title": "" }, { "docid": "abe000936d6784deba1929a3d9cb95f3", "score": "0.5310759", "text": "function loadSprite(name, index){\n var h = images[index].height/300;\n var w = images[index].width/300;\n imageDict[name] = new Array(h);\n for(var y = 0; y < h; y++){\n imageDict[name][y] = new Array(w);\n for(var x = 0; x < w; x++){\n imageDict[name][y][x] = images[index].get(x*300, y*300, 300, 300);\n }\n }\n}", "title": "" }, { "docid": "7ce24bde72f265f8f3e94028661d6700", "score": "0.5307636", "text": "function makeSprite(w, h, xpos, ypos, pic) {\n var pictureA = new Sprite();\n pictureA.width = w;\n pictureA.height = h;\n pictureA.x = xpos;\n pictureA.y = ypos;\n pictureA.image = Textures.load(pic);\n return pictureA;\n}", "title": "" }, { "docid": "fa5307bd3388f72524dbb6f0ef15f4c1", "score": "0.5281374", "text": "get spritesheet() {}", "title": "" }, { "docid": "e10290a8f2fa3f484a39212bd6c25564", "score": "0.5272372", "text": "function makeTextSprite(message, opts) {\n\tvar parameters = opts || {};\n\tvar fontface = parameters.fontface || 'Helvetica';\n\tvar fontsize = parameters.fontsize || 70;\n\tvar canvas = document.createElement('canvas');\n\tvar labelContext = canvas.getContext('2d');\n\tlabelContext.font = fontsize + \"px \" + fontface;\n\n\t// get size data (height depends only on font size)\n\tvar metrics = labelContext.measureText(message);\n\tvar textWidth = metrics.width;\n\n\t// text color\n\tlabelContext.fillStyle = 'rgba(0, 0, 0, 1.0)';\n\tlabelContext.fillText(message, 0, fontsize);\n\n\t// canvas contents will be used for a texture\n\tvar texture = new THREE.Texture(canvas);\n\ttexture.minFilter = THREE.LinearFilter;\n\ttexture.needsUpdate = true;\n\n\tvar spriteMaterial = new THREE.SpriteMaterial({\n\tmap: texture\n\t});\n\tvar sprite = new THREE.Sprite(spriteMaterial);\n\tsprite.scale.set(100, 50, 1.0);\n\treturn sprite;\n}", "title": "" }, { "docid": "e9d56b64c47797cbda220f90ffdbc232", "score": "0.52513677", "text": "function preload() {\n\n game.load.image('bullet', 'images/bullet.png');\n game.load.image('enemyBullet', 'images/enemy-bullet.png');\n game.load.spritesheet('invader', 'images/invader32x32x4.png', 32, 32);\n game.load.image('ship', 'images/player.png');\n game.load.spritesheet('kaboom', 'images/explode.png', 128, 128);\n game.load.image('starfield', 'images/starfield.png');\n game.load.image('diamond', 'images/diamond.png');\n game.load.image('background', 'images/background2.png');\n game.load.bitmapFont('desyrel', 'images/desyrel.png', 'images/desyrel.xml');\n game.load.bitmapFont('carrier', 'images/carrier_command.png', 'images/carrier_command.xml');\n\n}", "title": "" }, { "docid": "d5e73d0666d9c010bdefcee431176c2a", "score": "0.52342206", "text": "loadSprites () {\n var sprites = this.cache.getJSON('sprites');\n\n for (const [sprite, value] of Object.entries(sprites)) {\n\n // Sprite has json information\n if (sprites[sprite].json) {\n this.load.atlasJSONArray(sprites[sprite].name, sprites[sprite].png, sprites[sprite].json); \n // Simple sprite\n } else {\n this.load.image(sprites[sprite].name, sprites[sprite].png);\n } \n }\n }", "title": "" }, { "docid": "f3952d4a76b9b0604902cfbfc4e74fc0", "score": "0.52317053", "text": "function loadImages(image, name, xPos, y_position, cursor, scale) {\n\tvar _bitmap = new createjs.Bitmap(image).set({});\n _bitmap.x = xPos;\n _bitmap.y = y_position;\n\t_bitmap.scaleX = _bitmap.scaleY = scale;\n _bitmap.name = name;\n\t_bitmap.cursor = cursor;\n bacterial_growth_stage.addChild(_bitmap); /** Adding bitmap to the stage */\n}", "title": "" }, { "docid": "3e78d25102dcd37db6f3b08643e82399", "score": "0.52206975", "text": "setTextureTextPositions (texts, max_texture_size) {\n let texture = {\n cx: 0,\n cy: 0,\n width: 0,\n height: 0,\n column_width: 0,\n texture_id: 0,\n texcoord_cache: {}\n },\n textures = [];\n\n for (let style in texts) {\n let text_infos = texts[style];\n\n for (let text in text_infos) {\n let text_info = text_infos[text];\n let texture_position;\n\n if (text_info.text_settings.can_articulate) {\n text_info.textures = [];\n texture.texcoord_cache[style] = texture.texcoord_cache[style] || {};\n\n for (let t = 0; t < text_info.type.length; t++) {\n let type = text_info.type[t];\n\n if (type === 'straight') {\n let word = (text_info.isRTL) ? text.split().reverse().join() : text;\n\n if (!texture.texcoord_cache[style][word]) {\n let size = text_info.size.texture_size;\n texture_position = this.placeText(size[0], size[1], style, texture, textures, max_texture_size);\n texture.texcoord_cache[style][word] = {\n texture_id: texture.texture_id,\n texture_position\n };\n }\n\n text_info.textures[t] = texture.texture_id;\n }\n else if (type === 'curved') {\n text_info.textures[t] = [];\n\n for (let w = 0; w < text_info.segment_sizes.length; w++) {\n let word = text_info.segments[w];\n\n if (!texture.texcoord_cache[style][word]) {\n let size = text_info.segment_sizes[w].texture_size;\n let width = 2 * size[0]; // doubled to account for side-by-side rendering of fill and stroke\n texture_position = this.placeText(width, size[1], style, texture, textures, max_texture_size);\n texture.texcoord_cache[style][word] = {\n texture_id: texture.texture_id,\n texture_position\n };\n }\n\n text_info.textures[t].push(texture.texture_id);\n }\n\n }\n }\n }\n else {\n // rendered size is same for all alignments\n let size = text_info.size.texture_size;\n\n // but each alignment needs to be rendered separately\n for (let align in text_info.align) {\n texture_position = this.placeText (size[0], size[1], style, texture, textures, max_texture_size);\n text_info.align[align].texture_id = texture.texture_id;\n text_info.align[align].texture_position = texture_position;\n }\n }\n }\n }\n\n // save final texture\n if (texture.column_width > 0 && texture.height > 0) {\n textures[texture.texture_id] = {\n texture_size: [texture.width, texture.height],\n texcoord_cache: texture.texcoord_cache\n };\n }\n\n // return computed texture sizes and UV cache\n return textures;\n }", "title": "" }, { "docid": "a5bddd254f8b4ade301213253b85c7b6", "score": "0.52167743", "text": "function createUiMaskSprite(srcKey, w, h) {\n var bmd, fillBMD, maskedBMD, maskedSprite\n var obj = {}\n // make the bitmapdata sillouette from preloaded png file\n bmd = game.make.bitmapData()\n bmd.load(srcKey)\n bmd.processPixelRGB(forEachPixel, this)\n obj.sillhouetteBMD = bmd\n\n fillBMD = game.make.bitmapData(w, h)\n fillBMD.fill(fillColor.r, fillColor.g, fillColor.b, 1)\n maskedBMD = game.make.bitmapData(w, h)\n obj.fillBMD = fillBMD\n obj.maskedBMD = maskedBMD\n maskedSprite = game.add.sprite(0, 0, maskedBMD)\n obj.maskedSprite = maskedSprite\n obj.name = srcKey\n\n return obj\n}", "title": "" }, { "docid": "06c40357d63679f08119aa6342c222d9", "score": "0.5201487", "text": "generate(name, content, callback=undefined)\n {\n var that=this;\n \n // Initialise\n this.sprites[name]={};\n this.sprites[name].name=name;\n this.sprites[name].elem=document.createElement(\"div\");\n this.sprites[name].img=new Image();\n \n // Store callback function if specified\n if (callback!=undefined)\n this.sprites[name].callback=callback;\n\n // Start the conversion\n this.sprites[name].elem.innerHTML=content;\n this.sprites[name].xml=new XMLSerializer().serializeToString(this.sprites[name].elem.firstChild);\n\n // When the image has loaded from the b64, store the sprite and optionally run the callback\n this.sprites[name].img.onload=function () { that.loaded(name); };\n this.sprites[name].img.src='data:image/svg+xml;base64,'+btoa(this.sprites[name].xml);\n }", "title": "" }, { "docid": "d04d22027980b5475cbef3065474d631", "score": "0.5155256", "text": "placeText (text_width, text_height, style, texture, textures, max_texture_size) {\n let texture_position;\n\n // TODO: what if first label is wider than entire max texture?\n\n if (texture.cy + text_height > max_texture_size) {\n // start new column\n texture.cx += texture.column_width;\n texture.cy = 0;\n texture.column_width = text_width;\n }\n else {\n // expand current column\n texture.column_width = Math.max(texture.column_width, text_width);\n }\n\n if (texture.cx + texture.column_width <= max_texture_size) {\n // add label to current texture\n texture_position = [texture.cx, texture.cy];\n\n texture.cy += text_height;\n\n // expand texture if needed\n texture.height = Math.max(texture.height, texture.cy);\n texture.width = Math.max(texture.width, texture.cx + texture.column_width);\n }\n else {\n // start new texture\n // save size and cache of last texture\n textures[texture.texture_id] = {\n texture_size: [texture.width, texture.height],\n texcoord_cache: texture.texcoord_cache\n };\n texture.texcoord_cache = {}; // reset cache\n texture.texcoord_cache[style] = {};\n\n texture.texture_id++;\n texture.cx = 0;\n texture.cy = text_height;\n texture.column_width = text_width;\n texture.width = text_width;\n texture.height = text_height;\n texture_position = [0, 0]; // TODO: allocate zero array once\n }\n\n return texture_position;\n }", "title": "" }, { "docid": "980ac216c99b1fff8904968840d434f4", "score": "0.51462835", "text": "function newTile(sprite_name) {\n let img = new Image();\n // Define source\n img.src = spritePath(sprite_name);\n // Return complete image\n return img;\n}", "title": "" }, { "docid": "e4ee82a20b6ddb153542865023217e90", "score": "0.5125523", "text": "function loadEmoji(type) {\n currentType = type;\n \n for (var i = 0; i < 17; i++) {\n arrayEmoji[i] = \"../sprite/Emoji/\" + type + \"/\" + (i + 1) + \".png\";\n }\n for (var i = 0; i < 5; i++) {\n arraySam[i] = \"../sprite/Sam/\" + type + \"/\" + (i + 1) + \".png\";\n }\n if (typeOverlay == 1) {\n img.src = arraySam[3];\n } else {\n img.src = arrayEmoji[8];\n }\n overlayContent.appendChild(img);\n overlayContent.style.visibility = \"hidden\";\n overlayContent.style.opacity = \"0.5\";\n}", "title": "" }, { "docid": "73da3333cbf21fac01ef5bb426e96eaa", "score": "0.51246977", "text": "loadSprites () {\n this.load.image('on', 'assets/img/on.png')\n this.load.image('off', 'assets/img/off.png')\n this.load.image('kraiom', 'assets/img/kraiom.png')\n }", "title": "" }, { "docid": "b3c17167c5a300314714aaa106379ad3", "score": "0.5120425", "text": "function makeTextSprite( message, parameters )\n{\n if ( parameters === undefined ) parameters = {};\n var fontface = parameters.hasOwnProperty(\"fontface\") ? parameters[\"fontface\"] : \"Arial\";\n var fontsize = parameters.hasOwnProperty(\"fontsize\") ? parameters[\"fontsize\"] : 1;\n var borderThickness = parameters.hasOwnProperty(\"borderThickness\") ? parameters[\"borderThickness\"] : 4;\n var borderColor = parameters.hasOwnProperty(\"borderColor\") ?parameters[\"borderColor\"] : { r:0, g:0, b:0, a:1.0 };\n var backgroundColor = parameters.hasOwnProperty(\"backgroundColor\") ?parameters[\"backgroundColor\"] : { r:255, g:255, b:255, a:1.0 };\n var textColor = parameters.hasOwnProperty(\"textColor\") ?parameters[\"textColor\"] : { r:0, g:0, b:0, a:1.0 };\n\n var canvas = document.createElement('canvas');\n var context = canvas.getContext('2d');\n context.font = \"Bold \" + fontsize + \"px \" + fontface;\n var metrics = context.measureText( message );\n var textWidth = metrics.width;\n\n context.fillStyle = \"rgba(\" + backgroundColor.r + \",\" + backgroundColor.g + \",\" + backgroundColor.b + \",\" + backgroundColor.a + \")\";\n context.strokeStyle = \"rgba(\" + borderColor.r + \",\" + borderColor.g + \",\" + borderColor.b + \",\" + borderColor.a + \")\";\n\n context.lineWidth = borderThickness;\n roundRect(context, borderThickness/2, borderThickness/2, (textWidth + borderThickness), fontsize * 1.4 + borderThickness, 6);\n\n context.fillStyle = \"rgba(\"+textColor.r+\", \"+textColor.g+\", \"+textColor.b+\", 1.0)\";\n\n //that last value in the list is maxWidth so have it be reasonably big\n context.fillText( message, 0, fontsize + borderThickness, 300);\n\n var texture = new THREE.Texture(canvas) \n texture.needsUpdate = true;\n\n var spriteMaterial = new THREE.SpriteMaterial( { map: texture } );\n var sprite = new THREE.Sprite( spriteMaterial );\n sprite.scale.set(spriteMaterial.map.image.width, spriteMaterial.map.image.height, 1);\n sprite.center.set( 1, 0 );\n return sprite; \n}", "title": "" }, { "docid": "9fb27fbcbb9c066e61e2f9ad20f17d38", "score": "0.51005226", "text": "function preload() {\n\timages[0] = loadImage('assets/entrance.png');\n\timages[1] = loadImage('assets/livingroom.png');\n\timages[2] = loadImage('assets/kitchen.png');\n\timages[3] = loadImage('assets/bedroom.png');\n\timages[4] = loadImage('assets/bath.png');\n\timages[5] = loadImage('assets/movie.png');\n\timages[6] = loadImage('assets/instruction.png');\n\n\tfont = loadFont('assets/Uni Sans Heavy.otf');\n}", "title": "" }, { "docid": "257008446f9ab98b62add94e32b3fc90", "score": "0.5100087", "text": "function textLoader(image)\n \t{\n \t\ttexture = new THREE.TextureLoader().load(image);\n \t\treturn texture;\n \t}", "title": "" }, { "docid": "e41a196b14b9b0fa1e597ed6ea221c11", "score": "0.50691974", "text": "function getSpriteText(elementID, textType) {\n \"use strict\";\n \n var i, field;\n \n for (i = 0; i < levelSprites.length; i = i + 1) {\n if (levelSprites[i][2] === elementID) {\n \n if (textType === \"entry\") {\n return levelSprites[i][4];\n } else if (textType === \"bar\") {\n return levelSprites[i][5];\n } else {\n field = getRandomInt(8, levelSprites[i].length);\n return levelSprites[i][field];\n }\n }\n }\n}", "title": "" }, { "docid": "772c7f06cf8cde4e3359f332899c4696", "score": "0.50668895", "text": "function createMushroomSprites(rect = {left: 0,top: 0,width: 300,height: 300},x,y,width,height,url){\n let image = new Image();\n image.src = url;\n let mushroom= new BaseSprite(x,y,width,height,0,image)\n return mushroom;\n}", "title": "" }, { "docid": "28f6409b040366490b990e8ebb21d66d", "score": "0.50615495", "text": "function preload() {\n game.load.bitmapFont('super_mario_font', 'assets/fonts/super_mario_font.png', 'assets/fonts/super_mario_font.fnt');\n game.load.image('floor', 'assets/images/floor_block.png');\n game.load.image('pipe_small_green', 'assets/images/pipe_small_green.png');\n game.load.image('pipe_medium_green', 'assets/images/pipe_medium_green.png');\n game.load.image('pipe_big_green', 'assets/images/pipe_big_green.png');\n game.load.image('grass_small', 'assets/images/grass_small.png');\n game.load.image('grass_medium', 'assets/images/grass_medium.png');\n game.load.image('grass_big', 'assets/images/grass_big.png');\n game.load.image('heel_small', 'assets/images/heel_small.png');\n game.load.image('heel_big', 'assets/images/heel_big.png');\n game.load.image('cloud_small', 'assets/images/cloud_small.png');\n game.load.image('cloud_medium', 'assets/images/cloud_medium.png');\n game.load.image('cloud_big', 'assets/images/cloud_big.png');\n game.load.image('hard_block', 'assets/images/hard_block.png');\n game.load.image('x_sign', 'assets/images/x.png');\n game.load.image('pole_flag', 'assets/images/finish_flag.png');\n game.load.image('pole', 'assets/images/finish_pole.png');\n game.load.image('castle0', 'assets/images/castle_small_0f.png');\n game.load.image('castle1', 'assets/images/castle_small_1f.png');\n game.load.image('castle_flag', 'assets/images/castle_flag.png');\n game.load.spritesheet('breakable_block', 'assets/images/breakable_block.png', 16, 16);\n game.load.spritesheet('hidden_block', 'assets/images/hidden_block.png', 16, 16);\n game.load.spritesheet('coin', 'assets/images/coin.png', 10, 14, 4, 0, 6);\n game.load.spritesheet('coin_spin', 'assets/images/coin_spin.png', 8, 14, 4, 1, 8);\n game.load.spritesheet('coin_mini', 'assets/images/coin_mini.png', 5, 8, 3, 0, 3);\n game.load.spritesheet('loot_block', 'assets/images/loot_block.png', 16, 16);\n game.load.spritesheet('piranha_plant', 'assets/images/piranha_plant.png', 16, 24);\n game.load.spritesheet('firework', 'assets/images/firework.png', 16, 16);\n game.load.audio('theme_song', 'assets/audio/theme.wav');\n game.load.audio('fast_theme_song', 'assets/audio/theme-x1.5.wav');\n game.load.audio('warning', 'assets/audio/warning.wav');\n game.load.audio('death', 'assets/audio/mariodie.wav');\n game.load.audio('coin', 'assets/audio/coin.wav');\n game.load.audio('bump', 'assets/audio/bump.wav');\n game.load.audio('1up', 'assets/audio/1-up.wav');\n game.load.audio('firework', 'assets/audio/firework.wav');\n\n game.stage.smoothed = false;\n game.stage.disableVisibilityChange = true;\n game.physics.arcade.gravity.y = 2000;\n}", "title": "" }, { "docid": "9f4d44aa707f85611ebe8e138ee2781f", "score": "0.5054756", "text": "function generateCharBitmaps() {\n for (var t_i = 0; t_i < chars.length; t_i++) {\n var table = document.getElementById(`charTable${t_i}`);\n var charBitmap = \"\";\n for (var i = 0, row; row = table.rows[i]; i++) {\n let bitString = \"\";\n\n for (var j = 0, col; col = row.cells[j]; j++) {\n bitString += getBit(col);\n }\n\n let hexString = \"0x\" + parseInt(bitString, 2).toString(16).padStart(4, '0').toUpperCase();\n charBitmap += hexString + \", \";\n }\n charBitmap += `/* ${chars[t_i]} */\\n`;\n bitmapStrings[t_i] = charBitmap;\n }\n}", "title": "" }, { "docid": "c502f3c9ae8c3effa86e962d3ed64f02", "score": "0.5051766", "text": "function loadSprite( name ) {\n\tvar _s;\n\tif (mapSprite.get(name) === undefined) {\n\t\t_s = new Sprite(name);\n\t\tmapSprite.set(name,_s);\n\t} else {\n\t\t_s = mapSprite.get(name);\n\t}\n\treturn _s;\n}", "title": "" }, { "docid": "c0c33ff799d4474954600b44a437f68d", "score": "0.505144", "text": "function createGamePieceBitmaps(){\n\t\tvar i;\n\t\tvar coinFrameRate = 20;\n\t\t\n\t\t//create player bitmap\n\t\tvar playerShape = new createjs.Shape();\n\t\t\n\t\tplayerShape.graphics.inject(drawPlayer);\n\t\tplayerShape.cache(0, 0, 64, 133);\n\t\tplayer = new createjs.Bitmap(playerShape.cacheCanvas);\n\t\tplayer.regX = 32;\n\t\tplayer.regY = 66.5;\n\t\t\n\t\t//create yellow enemy sprite\n\t\tvar shapeEnemyYellow = new createjs.Shape();\n\t\t\n\t\tshapeEnemyYellow.graphics.inject(drawEnemyYellow);\n\t\tshapeEnemyYellow.cache(0, 0, 63, 127);\n\t\tspriteEnemyYellow = new createjs.Bitmap(shapeEnemyYellow.cacheCanvas);\n\t\tspriteEnemyYellow.regX = 31.5;\n\t\tspriteEnemyYellow.regY = 63.5;\n\t\t\n\t\t//create green enemy sprite\n\t\tvar shapeEnemyGreen = new createjs.Shape();\n\t\t\n\t\tshapeEnemyGreen.graphics.inject(drawEnemyGreen);\n\t\tshapeEnemyGreen.cache(0, 0, 63, 127);\n\t\tspriteEnemyGreen = new createjs.Bitmap(shapeEnemyGreen.cacheCanvas);\n\t\tspriteEnemyGreen.regX = 31.5;\n\t\tspriteEnemyGreen.regY = 63.5;\n\t\t\n\t\t//create blue enemy sprite\n\t\tvar shapeEnemyBlue = new createjs.Shape();\n\t\t\n\t\tshapeEnemyBlue.graphics.inject(drawEnemyBlue);\n\t\tshapeEnemyBlue.cache(0, 0, 63, 127);\n\t\tspriteEnemyBlue = new createjs.Bitmap(shapeEnemyBlue.cacheCanvas);\n\t\tspriteEnemyBlue.regX = 31.5;\n\t\tspriteEnemyBlue.regY = 63.5;\n\t\t\n\t\t//create road segments\n\t\tvar roadSegmentShape = new createjs.Shape();\n\t\t\n\t\troadSegmentShape.graphics.inject(drawRoadSegment);\n\t\troadSegmentShape.cache(0, 0, 800, 150);\n\t\troadSegments[0] = new createjs.Bitmap(roadSegmentShape.cacheCanvas);\n\t\tfor(i = 1; i < 6; i++){\n\t\t\troadSegments[i] = roadSegments[0].clone();\n\t\t}\n\t\t//create gold coin sprite\n\t\tvar coinGoldSheet = new createjs.SpriteSheet({\n\t\t\timages:[loadQueue.getResult(assets.COIN_GOLD)],\n\t\t\tframes: {width: 32, height: 32}\n\t\t});\n\t\tspriteCoinGold = new createjs.Sprite(coinGoldSheet, 0);\n\t\tspriteCoinGold.framerate = coinFrameRate;\n\t\t\n\t\t//create silver coin sprite\n\t\tvar coinSilverSheet = new createjs.SpriteSheet({\n\t\t\timages:[loadQueue.getResult(assets.COIN_SILVER)],\n\t\t\tframes: {width: 32, height: 32}\n\t\t});\n\t\tspriteCoinSilver = new createjs.Sprite(coinSilverSheet, 0);\n\t\tspriteCoinSilver.framerate = coinFrameRate;\n\t\t\n\t\t//create copper coin sprite\n\t\tvar coinCopperSheet = new createjs.SpriteSheet({\n\t\t\timages: [loadQueue.getResult(assets.COIN_COPPER)],\n\t\t\tframes: {width: 32, height: 32}\n\t\t});\n\t\tspriteCoinCopper = new createjs.Sprite(coinCopperSheet, 0);\n\t\tspriteCoinCopper.framerate = coinFrameRate;\n\t\t\n\t\t//create explosion sprite\n\t\tvar explosionSheet = new createjs.SpriteSheet({\n\t\t\timages: [loadQueue.getResult(assets.EXPLOSION)],\n\t\t\tframes: {width: 256, height: 256}\n\t\t});\n\t\tspriteExplosion = new createjs.Sprite(explosionSheet, 0);\n\t\tspriteExplosion.scaleX = 3;\n\t\tspriteExplosion.scaleY = 3;\n\t\tspriteExplosion.regX = 128;\n\t\tspriteExplosion.regY = 128;\n\t\tspriteExplosion.addEventListener(\"animationend\", onExplosionComplete);\n\t\t\n\t\t//create game over screen\n\t\tscreenGameOver = new createjs.Bitmap(loadQueue.getResult(assets.SCREEN_GAME_OVER));\n\t\t\n\t\t//create welcome screen\n\t\tscreenWelcome = new createjs.Bitmap(loadQueue.getResult(assets.SCREEN_WELCOME));\n\t}", "title": "" }, { "docid": "41bf7de7e19b7c57a1399530da0d38b8", "score": "0.50504947", "text": "function loadTextureForImage(index) {\r\n // Get image Sprite\r\n const image = images[index]\r\n // Set the url to get a random image from Unsplash Source, given image dimensions\r\n const url = `https://source.unsplash.com/random/${image.width}x${image.height}`\r\n // Get the corresponding rect, to store more data needed\r\n const rect = rects[index]\r\n // Create a new AbortController, to abort fetch if needed\r\n const { signal } = rect.controller = new AbortController()\r\n // Fetch the image\r\n fetch(url, { signal }).then(response => {\r\n // Get image URL, and if it was downloaded before, load another image\r\n // Otherwise, save image URL and set the texture\r\n const id = response.url.split('?')[0]\r\n if (imagesUrls[id]) {\r\n loadTextureForImage(index)\r\n } else {\r\n imagesUrls[id] = true\r\n image.texture = PIXI.Texture.from(response.url)\r\n rect.loaded = true\r\n }\r\n }).catch(() => {\r\n // Catch errors silently, for not showing the following error message if it is aborted:\r\n // AbortError: The operation was aborted.\r\n })\r\n}", "title": "" }, { "docid": "dfab7f122af83bdc8106fed578a007a1", "score": "0.5036515", "text": "createSprites() {\n this.positionBootConfig = this.getpositionBootConfig();\n this.addBackgroundSprite();\n this.addLogoSprite();\n this.addDance();\n this.addTermText();\n\n\n }", "title": "" }, { "docid": "a9faa7d6bf28c02e241541c0a5da829f", "score": "0.5034741", "text": "function bmp_mono(width, height, pixarray, palette) {\nvar rowsize = Math.ceil(width / 8);\nvar rowpadding = 4 - (rowsize % 4);\nif (typeof palette == 'undefined')\n palette = ['000000', 'ffffff'];\n\nvar j, pix, mod;\npixarray.reverse();\nvar pixels = [];\nvar b = 0;\nfor (var i=0; i<height; ++i) {\n row = [];\n for (j=0; j<width; ++j) {\n mod = j % 8;\n pix = pixarray.pop();\n if (parseInt(pix, 16) != 0) {\n b = b | Math.pow(2, 7-mod);\n }\n if (mod == 7 || j == width-1) {\n pixels.push(String.fromCharCode(b));\n b = 0;\n }\n }\n for (j=0; j<rowpadding; ++j) {\n pixels.push(\"\\x00\");\n }\n}\nreturn _bmp(width, height, palette, pixels.join(\"\"), 1, 0);\n}", "title": "" }, { "docid": "ef804daf7483f457ab9208f330a3b41e", "score": "0.50347066", "text": "function generateSprite(urlinput) {\n\t\tvar self = this;\n\t\tvar pokeId = randPokemon();\n\n\t\tpullDataById(urlinput, pokeId, function(data) {\n\t\t\tvar href = \"http://pokeapi.co\" + data.image;\n self.pokelist.push({\n \timageUrl: href,\n \tpokemonName: data.name\n });\n spriteLoaded();\n\t\t})\n\t}", "title": "" }, { "docid": "7812f368ec2416f7d56551e3bd8b691c", "score": "0.50256836", "text": "function drawSpriteCanvas() {\n const ctx = CANVASES.SPRITE.getContext(\"2d\");\n\n if (sprites.length === 0) {\n CANVASES.SPRITE.width = DEFAULT_WIDTH;\n CANVASES.SPRITE.height = DEFAULT_HEIGHT;\n ctx.clearRect(0, 0, CANVASES.SPRITE.width, CANVASES.SPRITE.height);\n return;\n }\n\n scaleCanvas(CANVASES.SPRITE, getCurrentSprite().image.width, getCurrentSprite().image.height)\n\n ctx.save();\n\n if (sprites.length === 0) {\n ctx.clearRect(0, 0, CANVASES.SPRITE.width, CANVASES.SPRITE.height);\n console.log(\"EMPTY\")\n return;\n }\n\n ctx.drawImage(getCurrentSprite().image, 0, 0)\n\n // Loading\n if (getCurrentSprite().loading) {\n ctx.fillStyle = \"rgba(0, 0, 0, 0.5)\"\n ctx.fillRect(0, 0, CANVASES.SPRITE.width, CANVASES.SPRITE.height)\n\n ctx.textAlign = \"center\";\n ctx.font = \"30px Arial\"\n ctx.fillStyle = \"white\"\n ctx.fillText(\"Detecting Blobs\", DEFAULT_WIDTH / 2, CANVASES.SPRITE.parentElement.offsetHeight / 2)\n }\n\n // Blobs\n if (showBlobs)\n getCurrentSprite().blobs.forEach(b => {\n ctx.beginPath();\n ctx.strokeStyle = b.edited ? EDITED_BLOB_COLOR : BLOB_COLOR;\n ctx.rect(b.x - 0.5, b.y - 0.5, b.width + 2, b.height + 2);\n ctx.closePath();\n ctx.stroke();\n\n if (showNumbers) {\n ctx.font = `${ TEXT_SIZE }px Arial`;\n const text = \"\" + (getCurrentSprite().blobs.indexOf(b) + 1);\n const size = ctx.measureText(text);\n ctx.fillStyle = TEXT_BACKGROUND\n //ctx.fillRect(b.x + (b.width - size.width) / 2 + 1, b.y + (b.height - TEXT_SIZE) / 2 + 1, size.width + 1, TEXT_SIZE + 1)\n ctx.fillStyle = TEXT_COLOR\n\n ctx.fillText(text, b.x + (b.width - size.width) / 2, b.y + (b.height + TEXT_SIZE) / 2)\n }\n })\n\n // Selected blobs\n\n selectedBlobs.forEach(b => {\n ctx.fillStyle = b.edited ? SELECTED_EDITED_BLOB_COLOR : SELECTED_BLOB_COLOR;\n ctx.fillRect(b.x, b.y, b.width + 1, b.height + 1)\n })\n\n ctx.fillStyle = POINT_COLOR;\n selectedPoints.forEach(p => {\n ctx.fillRect(p.x, p.y, 1, 1)\n })\n\n\n // Draw marquee\n if (selectMarquee) {\n const m = new Path2D();\n const x = selectMarquee.x;\n const y = selectMarquee.y;\n const w = selectMarquee.width;\n const h = selectMarquee.height;\n\n m.rect(x, y, w, h)\n m.rect(x + 1, y + 1, w - 2, h - 2)\n ctx.clip(m, \"evenodd\");\n ctx.globalCompositeOperation = \"exclusion\"\n ctx.fillStyle = \"white\"\n ctx.fillRect(x, y, w, h)\n }\n}", "title": "" }, { "docid": "92a91c6f591ac7ce01b8dcb377e60acb", "score": "0.50100744", "text": "setTextureTextPositions (texts, max_texture_size) {\n // Find widest label\n let widest = 0;\n for (let style in texts) {\n let text_infos = texts[style];\n for (let text in text_infos) {\n let size = text_infos[text].size.texture_size;\n if (size[0] > widest) {\n widest = size[0];\n }\n }\n }\n\n // Layout labels, stacked in columns\n let cx = 0, cy = 0; // current x/y position in atlas\n let height = 0; // overall atlas height\n for (let style in texts) {\n let text_infos = texts[style];\n\n for (let text in text_infos) {\n let text_info = text_infos[text];\n // rendered size is same for all alignments\n let size = text_info.size.texture_size;\n\n // but each alignment needs to be rendered separately\n for (let align in text_info.align) {\n if (cy + size[1] < max_texture_size) {\n text_info.align[align].texture_position = [cx, cy]; // add label to current column\n cy += size[1];\n if (cy > height) {\n height = cy;\n }\n }\n else { // start new column if taller than texture\n cx += widest;\n cy = 0;\n text_info.align[align].texture_position = [cx, cy];\n }\n }\n }\n }\n\n return [cx + widest, height]; // overall atlas size\n }", "title": "" }, { "docid": "f0ab592a42458582d2bb2f8dec5b6834", "score": "0.5005353", "text": "function image(bitmap, x, y, scale) {\r\n var lines = [];\r\n linecount=0;\r\n for (var i = 0; i < bitmap.array.length/bitmap.width; i++) {\r\n for (var j = 0; j < bitmap.width; j++) {\r\n if (bitmap.array[i*bitmap.width+j]) {\r\n lines[linecount] = {id:linecount, type:3, x1:j*scale+x, y1:i*scale+y, x2:j*scale+x+0.001, y2:i*scale+y+0.001, flipped:false, leftExtended:false, rightExtended:false}\r\n linecount++;\r\n }\r\n }\r\n }\r\n return lines;\r\n}", "title": "" }, { "docid": "a2ac16158c56871a39f9ef59d1c6200e", "score": "0.50045747", "text": "function Font(img, w, h, overlap, fontchars) {\n this.width = w;\n this.height = h;\n this.overlap = overlap;\n\n this.chars = {};\n var px32 = Buf32FromImage(img);\n var srcw = img.width;\n for (var i = 0; i < fontchars.length; i++) {\n var ch = fontchars.charCodeAt(i);\n this.chars[ch] = ExtractBuf32(px32, srcw, i * w, 0, w, h);\n }\n\n this.Draw = function(ctx, x, y, s) {\n var xx = x;\n for (var i = 0; i < s.length; i++) {\n var ch = s.charCodeAt(i);\n if (ch == 10) {\n\txx = x;\n\ty += this.height - 1;\n } else {\n\tthis.chars[ch] &&\n\t ctx.drawImage(this.chars[ch], xx, y);\n\txx += this.width - this.overlap;\n }\n }\n };\n}", "title": "" }, { "docid": "02b065cc5b31a15519515c9ff0e07beb", "score": "0.50027156", "text": "preload() {\n this.load.image('background', 'res/black.png');\n this.load.image('sprites_jugador', 'res/nave.png');\n this.load.image('sprites_bala', 'res/bala.png');\n this.load.image('sprites_laser', 'res/laser.png');\n this.load.image('sprites_enemy', 'res/enemy.png');\n this.load.image('sprites_enemy2', 'res/enemy2.png');\n this.load.image('sprites_return', 'res/return.png');\n this.load.image('sprites_menu', 'res/menu.png');\n }", "title": "" }, { "docid": "abbb4929e064ad07aad1a9e798cec1d5", "score": "0.50017977", "text": "function preload() {\n\t// This function executes before the canvas is loaded. For each gommette, we\n\t// load the corresponding image to be able to draw it on the timeline\n\tgommette_icons = gommettes.map((gom) => loadImage(gom.image_src));\n}", "title": "" }, { "docid": "b78c282197af1a0af432024ae814e4f7", "score": "0.49921653", "text": "initCharacters(canvas, ctx, configSprite){\r\n\r\n\t\tlet sprite = new Image();\r\n\t\tsprite.src = configSprite.info.source;\r\n\t\tthis.render(ctx, sprite, configSprite.frames.coords);\r\n\r\n\t}", "title": "" }, { "docid": "781e1cee3c051efdfa8be4fb6c4328f7", "score": "0.4990395", "text": "parseBitmapFontsConfig(data) {\n let dataParse = JSON.parse(data);\n LoaderModel.initialBitmapFonts(dataParse);\n LoaderModel.preloadBitmapFonts(dataParse);\n LoaderModel.lazyBitmapFonts(dataParse);\n }", "title": "" }, { "docid": "f5174e97fe66a764844d31feb3bfd999", "score": "0.49901658", "text": "function getABombImage() {\r\n let gifArray = [\r\n gif1, gif2, gif3, gif4, gif5, gif6, gif7, gif8, gif9, gif10\r\n ]\r\n return gifArray[Math.floor(Math.random() * gifArray.length)];\r\n}", "title": "" }, { "docid": "d18c303c81a5e187206fc0fb09a0caf1", "score": "0.49896255", "text": "function loadTextureForImage(index) {\n // Get image Sprite\n const image = images[index];\n\n // Set the url to get a random image from Unsplash Source, given image dimensions\n const url = `https://source.unsplash.com/random/${image.width}x${image.height}`;\n\n // Get the corresponding rect\n const rect = rects[index];\n\n // Create a new AbortController, to abort fetch if needed\n rect.controller = new AbortController();\n\n // Fetch the image, and react to promise\n fetch(url, rect.controller).then(response => {\n // Get image URL, and if it was downloaded before, load another image\n // Otherwise, save image URL and set the texture\n const id = response.url.split('?')[0];\n if (imagesUrls[id]) {\n loadTextureForImage(index);\n }\n else {\n imagesUrls[id] = true;\n image.texture = PIXI.Texture.from(response.url);\n rect.loaded = true;\n }\n }).catch(() => {\n // Catch errors silently, for not showing the following error message if it is aborted:\n // AbortError: The operation was aborted.\n });\n}", "title": "" }, { "docid": "f4256c240c09f3536866a990a26e8c20", "score": "0.49887192", "text": "function countess_Preload()\n{\n\tLucifer_Game.load.spritesheet('MON_Countess_Stand',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Countess/stand/stand.png',\n\t\t\t\t\t\t\t\t 48, 89);\n\tLucifer_Game.load.spritesheet('MON_Countess_Run',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Countess/run/run.png',\n\t\t\t\t\t\t\t\t 66, 77);\n\tLucifer_Game.load.spritesheet('MON_Countess_Attack',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Countess/attack/attack.png',\n\t\t\t\t\t\t\t\t 106, 101);\n\tLucifer_Game.load.spritesheet('MON_Countess_Dead',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Countess/death/death.png',\n\t\t\t\t\t\t\t\t 82, 159);\n}", "title": "" }, { "docid": "b57b43c2e91148ac5769dc3b6c469a89", "score": "0.49844122", "text": "sprite(name) {\n const {\n width,\n height,\n src,\n scale,\n row,\n column\n } = this.gameScene.load.sprites[name];\n this.image = new Image();\n this.row = row;\n this.column = column;\n this.sx = 0;\n this.sy = 0;\n this.width = width;\n this.height = height;\n this.x = 0;\n this.y = 0;\n this.z = 0;\n this.offsetx = 0;\n this.offsety = 0;\n this.scale = scale;\n this.src = src;\n this.angle = 0;\n this.sprite = {};\n this.currentSprite = '';\n this.border = false;\n this.isDirty = true;\n this.hidden = false;\n this.gameScene.queue.push(this);\n return this;\n }", "title": "" }, { "docid": "3ef3f9c58dbb1d78bd67df3f9c94fd63", "score": "0.49813485", "text": "function preload() {\n game.load.spritesheet('chocobo', './src/sprites/chocobo.png', 30, 30)\n}", "title": "" }, { "docid": "211664b11cee73a6650442a0ecd04212", "score": "0.49753657", "text": "preload() {\n this.loadAssets();\n this.load.spritesheet('coin', 'assets/Coin/coin-sprite-png-2.png', {frameWidth: 200, frameHeight: 250, endFrame: 5});\n }", "title": "" }, { "docid": "43613378709531ec9410ee84b38e854b", "score": "0.49722183", "text": "function Spry() {\n // require dependencies\n var im = require('easyimage');\n var kiwi = require('kiwi');\n var fs = require('fs');\n var exec = require('child_process').exec;\n\n // get the options provided in the gruntfile\n var options = this.options();\n\n // set the required variables for the sprites\n var retina, simple;\n var retina_sprite, simple_sprite;\n var css_retina = [];\n var css_simple = [];\n var css = [];\n var css_info = 0;\n\n var simple_pos = {'x':0, 'y':0};\n var retina_pos = {'x':0, 'y':0};\n\n var output;\n\n // this script has many async operations and we need to\n // tell this to grunt\n this.async();\n\n if (!options.format || !options.cssOut) {\n return grunt.fatal('format option and output file must be provided');\n }\n\n\n var message = '/* file generated by spry! */\\n';\n fs.writeFile(options.cssOut, message, function(err) {\n if(err) {\n grunt.log.error(err);\n }\n });\n\n\n for (var i = 0; i < this.files.length; i++) {\n if (this.files[i].retina) {\n retina = this.files[i];\n } else {\n simple = this.files[i];\n }\n }\n\n retina_sprite = retina.dest;\n simple_sprite = simple.dest;\n\n function split(arr) {\n for (var i=0; i<arr.length; i++) {\n arr[i] = arr[i].split('/').pop();\n }\n return arr;\n }\n\n function path(file) {\n var file_path = file.split('/').slice(0, -1).join('/');\n return file_path;\n }\n\n function intersection(retina, simple) {\n if (simple.length) {\n var inter = [];\n var j = 0;\n var simple_path = path(simple[0]);\n var retina_split = split(retina);\n var simple_split = split(simple);\n for (var i=0; i < retina.length; ++i) {\n if (simple_split.indexOf(retina_split[i]) !== -1) {\n inter[j++] = retina_split[i];\n }\n }\n if (inter) {\n return [inter, simple_path];\n }\n } else {\n return false;\n }\n }\n\n var simple_override = intersection(retina.src, simple.src);\n\n var resize = function(file, callback) {\n var cmd = 'convert ';\n var input = file;\n\n var output = path(simple.orig.src[0]) + '/' + file.split('/').pop();\n\n function puts(error) {\n if (error) {\n grunt.log.error(error);\n }\n }\n\n cmd += input;\n cmd += ' -resize 50% ';\n cmd += output;\n exec(cmd, puts);\n callback();\n };\n\n if (simple_override) {\n for (i=0; i < retina.src.length; i++) {\n if (simple_override[0].indexOf(retina.src[i]) === -1 ) {\n grunt.log.write('resized:' + retina.src[i]);\n }\n }\n\n } else {\n // we will resize all the retina images and put them into the simple images dir\n grunt.util.async.map(retina.src, resize, function(err, info) {\n grunt.log.write('all images resized');\n });\n }\n\n var imageInfo = function(file, callback) {\n im.info(file, function(err, info, stderr) {\n callback(stderr, info);\n });\n };\n\n var sprite = function(files,callback) {\n var cmd = 'montage -mode concatenate -tile x1 -background transparent';\n var output = files.dest;\n var input = files.orig.src;\n\n function puts(error) {\n if (error) {\n grunt.log.error(error);\n }\n }\n\n cmd += ' ' + input + ' '+ output;\n cmd = cmd.replace(/,+/g,' ');\n exec(cmd, puts);\n callback();\n };\n\n grunt.util.async.map([simple, retina ], sprite, function(){\n grunt.log.write('the sprites are ready!');\n });\n\n var retina_files = [];\n var retina_path = path(retina.orig.src[0]);\n for (i=0; i < retina.src.length; i++) {\n retina_files.push(retina_path+'/'+retina.src[i]);\n }\n\n grunt.util.async.map(retina_files, imageInfo, function(err, info) {\n css_retina.push(info);\n css_info += 1;\n if (css_info === 2) {\n createCss();\n }\n });\n\n function render(css) {\n simple_pos.x += parseInt(css[1].width, 10);\n simple_pos.y += parseInt(css[1].height, 10);\n\n retina_pos.x += parseInt(css[0].width, 10);\n retina_pos.y += parseInt(css[0].height, 10);\n\n var current_simple_pos = {};\n var current_retina_pos = {};\n\n current_simple_pos.x = simple_pos.x;\n current_simple_pos.y = simple_pos.y;\n current_retina_pos.x = retina_pos.x;\n current_retina_pos.y = retina_pos.y;\n\n var simple_sprite_path = simple_sprite.split('/');\n var retina_sprite_path = retina_sprite.split('/');\n simple_sprite_path = simple_sprite_path[simple_sprite_path.length - 1];\n retina_sprite_path = retina_sprite_path[retina_sprite_path.length - 1];\n\n\n var template = new kiwi.Template().loadAndRender(__dirname + '/../templates/less.kiwi',\n { 'name': css[0].name.split('.')[0],\n 'simple_sprite_path': simple_sprite_path,\n 'retina_sprite_path': retina_sprite_path,\n 'simple_pos': current_simple_pos,\n 'retina_pos': current_retina_pos,\n 'retina': css[0],\n 'simple': css[1],\n 'retina_width': retina_width\n },\n function onRendered(err, rendered) {\n output += (String(rendered));\n fs.appendFile(options.cssOut, rendered, function(err) {\n if(err) {\n grunt.log.error(err);\n }\n });\n });\n }\n\n var retina_width = 0;\n function createCss() {\n // css Array contains the info of the pairs of each icon [retina, simple]\n for (i = 0; i < css_retina[0].length; i++) {\n css.push([css_retina[0][i],css_simple[0][i]]);\n retina_width += parseInt(css_retina[0][i].width, 10);\n }\n\n grunt.util.async.map(css, render, function(err) {\n if (err) {\n grunt.log.error('Could not write output. \\n' + err);\n }\n grunt.log.write('generating template...');\n });\n }\n\n var simple_files = [];\n var simple_path = path(simple.orig.src[0]);\n for (i=0; i < simple.src.length; i++) {\n simple_files.push(simple_path+'/'+simple.src[i]);\n }\n\n grunt.util.async.map(simple_files, imageInfo, function(err, info) {\n css_simple.push(info);\n css_info += 1;\n if (css_info === 2) {\n createCss();\n }\n });\n }", "title": "" }, { "docid": "9275633c4c4087a0b50ac66ac247b80d", "score": "0.49671823", "text": "function load_sprites() { //returns function() returns {loaded_sprites: int, max: int}\n\t//horrifying javascript voodoo to make this work\n\tvar head = document.getElementsByTagName('head')[0];\n\tvar sprites_loaded = 0;\n\tvar max_sprites = 0;\n\tfor (var path in sprites) {\n\t\tmax_sprites++;\n\t\tvar img = new Image();\n\t\timg.src = \"resource/\" + path + \".png\";\n\t\timg.name = path;\n\t\timg.onload = function() {sprites[this.name] = this; sprites_loaded++;};\n\t\thead.appendChild(img);\n\t}\n\t\n\treturn function() {return {loaded_sprites: sprites_loaded, max: max_sprites};};\n}", "title": "" }, { "docid": "3a0eeb2394d0ec15e347bba0ebde331f", "score": "0.4953767", "text": "function preload() {\n url = 'https://api.punkapi.com/v2/beers/random';\n httpGet(url, 'json', false, function(response) {\n data = response;\n });\n //setting up of the three pages with emojis\n for (var i = 0; i < 8; i++) {\n emojis[i] = loadImage(\"assets/\" + i + \".png\");\n }\n for(var i = 0; i < 2;i++){\n coffee[i] = loadImage(\"assets/coffee\"+i+\".png\");\n }\n for(var i = 0;i < 3;i++){\n sleep[i] = loadImage(\"assets/sleep\"+i+\".png\");\n }\n}", "title": "" }, { "docid": "3d3763990c9b793f83bb3359a69dbb31", "score": "0.49509662", "text": "preload() {\n this.load.image('background', 'res/black.png');\n this.load.image('sprites_start', 'res/start.png');\n this.load.image('sprites_logo', 'res/logo.png');\n }", "title": "" }, { "docid": "75b56e5b8810e8af6d87adc7b3f461a1", "score": "0.49460962", "text": "function drawCellWithBitmoji(cell){\n var avatar_url = localStorage.getItem('avatarurl');\n document.getElementById('avatar').src = avatar_url;\n context.drawImage(document.getElementById('avatar'),0, 0, 200, 200, cell.x - XOffSet, cell.y - YOffSet, size, size);\n}", "title": "" }, { "docid": "7ffcd72dd1e0d3dbf5f65f8cfb5fb949", "score": "0.49459416", "text": "function setbitmap(o, imgurl) {\n if (textures[o.obj]==undefined) {\n texturewaiting++;\n\n var t = new Object();\n o.tex = t;\n t.i = new Image();\n t.i.ownerobj = o;\n t.i.onload = gotbitmap;\n t.i.src = imgurl;\n\n textures[o.obj] = t;\n } else {\n var t = textures[o.obj];\n o.tex = t;\n o.bmp = t.bmp;\n o.bmpw = t.i.width;\n o.bmph = t.i.height;\n o.bmpwh= t.i.width/2|0;\n o.bmphh= t.i.height/2|0;\n }\n}", "title": "" }, { "docid": "5a4b9d18f053100da83cd70239bde604", "score": "0.4943028", "text": "function preload(msg) {\n var numLoaded = 0;\n var total = assets.length;\n var tracker = numLoaded + \" / \" + total;\n\n ctx.font = \"20px courneuf\"; // Will need to load this font from css sheet\n ctx.fillStyle = \"#dddddd\";\n ctx.fillText(msg, 130, 235); // show preloader\n ctx.fillText(tracker, 230, 265);\n\n function onload() { // this is the function called every time an asset is loaded\n numLoaded ++;\n tracker = numLoaded + \" / \" + total;\n clear();\n ctx.fillText(msg, 130, 235); // show preloader\n ctx.fillText(tracker, 230, 265);\n if (numLoaded == total) {\n clear();\n init();\n }\n }\n\n for (var i = 0; i < total; i++) {\n assets[i].onload = onload;\n assets[i].src = assets[i].filePath;\n }\n}", "title": "" }, { "docid": "4b1d264e31558d64a448cbf48aae0875", "score": "0.49422377", "text": "function preload(){\n bImg = loadImage('background.gif');\n wImg = loadImage('whale.png');\n dImg = loadImage('dolphin.png');\n cImg = loadImage('money.gif');\n pImg = loadImage('bottle.png');\n b2Img = loadImage('background2.gif');\n w2Img = loadImage('whale2.png');\n mImg = loadImage('mine.png');\n}", "title": "" }, { "docid": "a38ed50781ce3e07f7a2b304ffe8711e", "score": "0.49389648", "text": "function loadSprite(url) {\n // https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/Image\n let image = new Image()\n let loaded = new Promise(resolve => {\n image.onload = resolve\n })\n image.src = url\n return {\n image: image,\n loaded: loaded,\n }\n}", "title": "" }, { "docid": "a38ed50781ce3e07f7a2b304ffe8711e", "score": "0.49389648", "text": "function loadSprite(url) {\n // https://developer.mozilla.org/en-US/docs/Web/API/HTMLImageElement/Image\n let image = new Image()\n let loaded = new Promise(resolve => {\n image.onload = resolve\n })\n image.src = url\n return {\n image: image,\n loaded: loaded,\n }\n}", "title": "" }, { "docid": "4a83fd608e5907e405fa34009af9b309", "score": "0.49349046", "text": "function loadSprite(gl, name, callback)\n{\n\n if (G.sprites[name] && callback)\n callback(G.sprites[name]);\n\n\n var dir = \"public/sprites/\";\n G.loadFile(dir + name +'.sprt', function(data){\n\n var obj = JSON.parse(data)\n \n var sprite = new Sprite();\n sprite = _.extend(sprite, _.omit(obj, 'image'));\n\n if (obj.image)\n {\n sprite.imageName = obj.image;\n //check to see if texture already exists in another sprite\n for (key in G.sprites)\n {\n var s = G.sprites[key];\n if (s.imageName && !s.imageName.localeCompare(sprite.imageName))\n sprite.texture = s.texture;\n }\n if (gl && !sprite.texture)\n sprite.texture = G.renderer.loadImageTexture(gl, dir + obj.image);\n }\n\n sprite.frameIncr = sprite.fps/G.PHYSICS_FPS;\n\n //add to global list\n G.sprites[name] = sprite;\n\n if (callback)\n callback(sprite);\n });\n}", "title": "" }, { "docid": "dffd3156772885585f375fcfee45cd62", "score": "0.49211258", "text": "function generateUnicodeText(text, size, font, bold) {\n\n var cvs = document.createElement('canvas');\n\n //Calculate text size\n var textSize = MeasureText(text, bold, font, 18);\n\n cvs.setAttribute('width', textSize[0]);\n cvs.setAttribute('height', textSize[1]);\n \n context = cvs.getContext(\"2d\");\n context.textBaseline = \"top\";\n fstring = (bold ? 'bold ' : '');\n fstring = fstring+ \"18pt \" + font;\n context.font = fstring;\n context.fillStyle = 'rgb(255,255,255)';\n context.fillRect(0, 0, textSize[0], textSize[1]); \n context.fillStyle = 'rgb(0,0,0)'; \n context.fillText(text, 0, 0);\n bdata = cvs.toDataURL('image/jpeg', 1.0).slice('data:image/jpeg;base64,'.length);\n bdata = atob(bdata)\n \n return [bdata,(textSize[0] * 0.265), (textSize[1] * 0.6)];\n}", "title": "" }, { "docid": "65b5d4e8eb4804643c4f8ac2faa0d8db", "score": "0.49202845", "text": "preload() {\n this.loadAssets();\n this.load.spritesheet('coin', 'assets/Coin/coin-sprite-png-2.png', {frameWidth: 200, frameHeight: 250, endFrame: 5});\n }", "title": "" }, { "docid": "7c45fe84138bf915ba3653c654fbb33a", "score": "0.49085966", "text": "function renderTinyBotanist () {\n _minimapPlayerContext.drawImage(\n _images['tiny_botanist'],\n 0,\n 0,\n 20,\n 16,\n 60,\n 64,\n 20,\n 16\n )\n }", "title": "" }, { "docid": "a25c9e22279df3efd639a9c88b254775", "score": "0.49073574", "text": "function loadBalloonSpriteData(filename) {\n\tvar spriteData = {\n\t\timages: [\"images/\" + filename],\n\t\tframes: {width:130, height:130, count:7, regX:0, regY:0, spacing:0, margin:0},\n\t\tanimations: {\n\t\t\tnormal: [0, false],\n\t\t\tpop: [0, 6, false]\n\t\t}\n\t};\n\tvar sprite = new createjs.Sprite(new createjs.SpriteSheet(spriteData));\n\n\tballoonSpritesArray.push(sprite);\n\n}", "title": "" }, { "docid": "bbe0bd1392dd04a89b897ee265e529ea", "score": "0.49027905", "text": "function addBGSprite(imagepath = '',pos_x = 0,pos_y = 0,width = 20, height = 20) {\r\n var bgs = new backgroundSprite();\r\n bgs.pos_x = pos_x;\r\n bgs.pos_y = pos_y;\r\n bgs.width = width;\r\n bgs.height = height;bgs.image = document.getElementById(imagepath);\r\n bgSprites.push(bgs);\r\n}", "title": "" }, { "docid": "3959c357538fec43306c764fbed0d21d", "score": "0.48992753", "text": "function aniSprite ( spriteObject, columnSize, rowSize, colFrameStart, rowFrameStart, totalFrames, type:String)\n{\n\tvar index : int = playTime;\t\t\t\t\t\t\t// to control frame location, playTime will equal the index count\n\t\n\tvar font1 = ( index % 10 );\t\t\t\t\t\t\t// font1 position\n\tvar font2 = ( ( index - font1 ) / 10 ) % 10;\t\t// font2 position \n\tvar font3 = ( ( index - font1 ) / 100 ) % 10;\t\t// font3 position\n\tvar font4 = ( ( index - font1 ) / 1000 ) % 10;\t\t// font4 position\n\n\tif ( type == \"font1\" ) index = font1;\t\t\t\t// check for which sprite sheet to use - font1\n\tif ( type == \"font2\" ) index = font2;\t\t\t\t// check for which sprite sheet to use - font2\n\tif ( type == \"font3\" ) index = font3;\t\t\t\t// check for which sprite sheet to use - font3\n\tif ( type == \"font4\" ) index = font4;\t\t\t\t// check for which sprite sheet to use - font4\n\t\n\t//print ( font4 + \" \" + font3 + \" \" + font2 + \" \" + font1 );\t// print to console to see it split the numbers correctly\n\n\tvar size = Vector2 ( 1.0 / columnSize, 1.0 / rowSize );\t// find scale to show on poly \n\n\tvar u = index % columnSize;\t\t\t\t\t\t\t\t// u cord separated from v, to find just the column and mod it\n\tvar v = index / columnSize;\t\t\t\t\t\t\t\t// v finds location on row based on columnSize count\n\t\n\tvar offset = Vector2 ( ( u + colFrameStart ) * size.x, ( 1.0 - size.y ) - ( v + rowFrameStart ) * size.y );\t// offset uv's\n\t\n\tspriteObject.renderer.material.mainTextureOffset = offset; \t// apply the offset amount to the correct sprite sheet object\n\tspriteObject.renderer.material.mainTextureScale = size; \t// apply the scale amount to the correct sprite sheet object\n\n\t// Remember if you want additional texture maps, add them here. Example of normal map below\n\t// spriteObject.renderer.material.SetTextureOffset (\"_BumpMap\", offset);\n\t// spriteObject.renderer.material.SetTextureScale (\"_BumpMap\", size);\n}", "title": "" }, { "docid": "0b55815d90c6e09eb8e52907cf29f374", "score": "0.4898201", "text": "function preload(){\n pieceEn = loadStrings('pieceofyouen.txt'); \n fontH = loadFont('NexaRustHandmade.otf');\n imgShoe = loadImage('shoebox.png'); \n sky = loadImage('img/sky.png');\n sky2 = loadImage('img/sky2.png');\n sky3 = loadImage('img/sky3.png');\n}", "title": "" }, { "docid": "fefcc743ddf1f219f2e5147745ea42e5", "score": "0.4896254", "text": "function preload() {\n enemy = loadImage('assets/images/bomb.png');\n}", "title": "" }, { "docid": "fc6f8a92328cc54f16c0982e4dd49d37", "score": "0.48905173", "text": "function loadSprites() {\n let birdSize = 45,\n dinoSize = 45,\n roadWidth = 175,\n roadHeight = 16;\n\n //this.sprites.push(img.get(x,y,width,height))\n this.sprites.push(img.get(229, 3, 17, 35)); //0-small Cactus\n this.sprites.push(img.get(432, 3, 26, 47)); //1-pair of cactuses\n this.sprites.push(img.get(333, 3, 24, 47)); //2-big Cactus\n\n this.sprites.push(img.get(764, 3, dinoSize, dinoSize)); //3-right\n this.sprites.push(img.get(808, 3, dinoSize, dinoSize)); //4-left\n this.sprites.push(img.get(675, 3, dinoSize, dinoSize)); //5-jump\n this.sprites.push(img.get(939, 17, dinoSize + 10, 33)); //6-duck left\n this.sprites.push(img.get(998, 17, dinoSize + 10, 33)); //7-duck right\n\n this.sprites.push(img.get(133, 0, birdSize, birdSize)); //8-bird up\n this.sprites.push(img.get(177, 0, birdSize, birdSize)); //9-bird down\n\n this.sprites.push(img.get(3, 54, 1201, 15)); //10//10-1st chunk of road\n this.sprites.push(img.get(2 + roadWidth, 53, roadWidth, roadHeight)); //11\n this.sprites.push(img.get(2 + roadWidth * 2, 53, roadWidth, roadHeight)); //12\n this.sprites.push(img.get(2 + roadWidth * 3, 53, roadWidth, roadHeight)); //13\n this.sprites.push(img.get(2 + roadWidth * 4, 53, roadWidth, roadHeight)); //14\n\n this.sprites.push(pauseImg.get(0, 4, 94, 94)); //15 play Button\n this.sprites.push(pauseImg.get(108, 4, 94, 94)); //16 pause Button\n\n this.sprites.push(buttonOn.get(0, 0, 207, 207)); //17 button Pressed\n this.sprites.push(buttonOff.get(0, 0, 207, 207)); //18 button Released\n}", "title": "" }, { "docid": "e9cbb0cc603391a60f1415dc0e94e50f", "score": "0.48890296", "text": "loadGraphics (block) {\n this.gfxROMGraphics = block.decompress()\n this.buildTiles()\n }", "title": "" }, { "docid": "7617261eb8186fa515e9b394bebb9c45", "score": "0.48843202", "text": "function preload() { \n font = loadFont(\"https://cdn.glitch.com/2ffb5c9d-f8e5-46dd-bb94-986926301e9c%2FYoutube%20Star.ttf?v=1615391368488\"); \n}", "title": "" }, { "docid": "f4072ebeb2435fa259b1062de90709a8", "score": "0.48804885", "text": "drawBlock ( block, x, y ) {\r\n const animeToTwinkleBox = [0, 1, 2, 1, 0];\r\n if ( block == 368 ) { \r\n block += animeToTwinkleBox[ (frameCount>>3) % 5 ]\r\n }\r\n\r\n let spriteX = (block&15) * 16;\r\n let spriteY = (block>>4) * 16;\r\n virtualCtx.drawImage( \r\n characterImage, \r\n spriteX, spriteY, 16, 16, //Where to pick the character image up from the source\r\n x, y, 16, 16//Where to draw the image on the virtual context\r\n ); \r\n }", "title": "" }, { "docid": "500d4890b5b86b814ff042655b801f54", "score": "0.48785833", "text": "function TextSprite(fontname,fontsize,text) {\n\tSceneNode.call(this);\n\n\tthis._font_name = \"\" + fontname;\n\tthis._font_size = fontsize;\n\tthis._font_string = this._font_size + \"px \" + this._font_name;\n\tthis._font_weight = \"normal\";\n\tthis._text = null;\n\tthis.setText(text ? (\"\" + text) : \"\");\n\tthis._fillColor = \"Black\";\n\tthis._strokeColor = null;\n\tthis._shadowColor = null;\n\tthis._shadowRadius = 0;\n\tthis._drawmode = TextSprite.DrawMode.ALPHA;\n\tthis.updateFontString();\n}", "title": "" }, { "docid": "55c703d19f688ee4cea75d17e96a586f", "score": "0.48730767", "text": "function textTexture(gl, width, height, text, textSize, font, lineHeight, color, textAlign, textBaseline) {\n var textSize = textSize || 12;\n var lineHeight = lineHeight || textSize + 5;\n var font = font || 'sans-serif';\n var color = color || 'black';\n var textAlign = textAlign || 'left';\n var textBaseline = textBaseline || 'middle';\n var lines = text.split('\\n');\n return renderCanvasTexture(gl, width, height, function(ctx){\n ctx.font = textSize + 'px ' + font;\n ctx.fillStyle = color;\n ctx.textAlign = textAlign;\n ctx.textBaseline = textBaseline;\n var lineWidths = [];\n var splitLines = [];\n for (var i=0; i < lines.length; i++) {\n var size = ctx.measureText(lines[i]);\n if (size > width) {\n var words = lines[i].split(/\\s+/);\n var totalWordSize = 0;\n var rangeStart = 0;\n for (var j=0; j < words.length; j++) {\n var wordSize = ctx.measureText(words[i]);\n if ((totalWordSize + wordSize) > width) {\n splitLines.push(words.slice(rangeStart, j).join(' '));\n lineWidths.push(totalWordSize);\n rangeStart = j;\n totalWordSize = 0;\n } else {\n totalWordSize += wordSize;\n }\n }\n splitLines.push(words.slice(rangeStart, words.length).join(' '));\n lineWidths.push(totalWordSize);\n } else {\n splitLines.push(lines[i]);\n lineWidths.push(size);\n }\n }\n\n var textY = lineHeight / 2;\n for (var i=0; i < splitLines.length; i++) {\n ctx.fillText(splitLines[i], 0, textY);\n textY += lineHeight;\n }\n\n });\n}", "title": "" }, { "docid": "5583b932911f6f7d706135892853c360", "score": "0.4871283", "text": "function preload(){\ngame.load.image('star','assets/star.png');\ngame.load.image('platform','assets/platform.png');\n}", "title": "" }, { "docid": "98520255e56a7819472ef1ab5e6ea8e7", "score": "0.48705468", "text": "function makeRequestForSprite(\r\n url\r\n ) {\r\n let promise = new Promise(\r\n function (\r\n resolve,\r\n reject\r\n ) {\r\n let request = new XMLHttpRequest();\r\n\r\n request.responseType = 'arraybuffer';\r\n\r\n request.open(\r\n 'GET',\r\n url\r\n );\r\n\r\n request.onload = function(\r\n event\r\n ) {\r\n let status = this.status;\r\n\r\n if (\r\n status >= 200\r\n && status < 300\r\n ) {\r\n resolve(\r\n this.response\r\n );\r\n }\r\n else {\r\n reject(\r\n this.statusText\r\n );\r\n }\r\n }; // onload callback\r\n\r\n request.send();\r\n } // executor\r\n ); // promise\r\n \r\n return promise;\r\n }", "title": "" }, { "docid": "c8b11a629140dc1a93b8516eaba0c651", "score": "0.48699707", "text": "function drawCellWithBitmoji(cell){\n var avatar_url = localStorage.getItem('avatarurl');\n document.getElementById('avatar').src = avatar_url;\n context.drawImage(document.getElementById('avatar'),0, 0, 200, 200, cell.x, cell.y, grid, grid);\n}", "title": "" }, { "docid": "b6f43745cd9ddcf5cfd2316bbadc88f6", "score": "0.48696953", "text": "function preloadBlocksRelatedImage(){\r\n\t// set default character look (if player did not choose)\r\n\tfor(let count=0,len=4;count<len;count++){ \r\n\t\tif(ints_selectedCharacterIndex[0] == null && ints_selectedCharacterIndex.indexOf(count)==-1)\r\n\t\t\tints_selectedCharacterIndex[0] = count;\r\n\t\tif(ints_selectedCharacterIndex[1] == null && ints_selectedCharacterIndex.indexOf(count)==-1)\r\n\t\t\tints_selectedCharacterIndex[1] = count;\r\n\t}\r\n\t\r\n\tCHARACTER_DEFAULT_NAME[ints_selectedCharacterIndex[0]] = \"你(\"+CHARACTER_DEFAULT_NAME[ints_selectedCharacterIndex[0]]+\")\";\r\n\t\r\n\t// customize character size\r\n\tlet charData = [\r\n{ \r\n\twidth: convertSizeToCurrentBackground(555,0).x * 0.9 * 0.2,\r\n\theight: convertSizeToCurrentBackground(0,1220).y * 0.9 * 0.2\r\n},{ \r\n\twidth: convertSizeToCurrentBackground(555,0).x * 0.9 * 0.2,\r\n\theight: convertSizeToCurrentBackground(0,1220).y * 0.9 * 0.2\r\n},{ \r\n\twidth: convertSizeToCurrentBackground(555,0).x * 0.9 * 0.2,\r\n\theight: convertSizeToCurrentBackground(0,1220).y * 0.9 * 0.2\r\n},{ \r\n\twidth: convertSizeToCurrentBackground(665,0).x * 0.9 * 0.2,\r\n\theight: convertSizeToCurrentBackground(0,1205).y * 0.9 * 0.2\r\n}\r\n\t];\r\n\t\r\n // draw obj_status1_BG object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/charecter/info_bg_left_'+(ints_selectedCharacterIndex[0]+1)+'.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_fabric.add( img );\r\n\t\t\timg.isLink = false;\r\n\t\t\timg.set({\r\n\t\t\t\twidth: convertSizeToCurrentBackground(img._element.width,0).x * SCALE_OF_STATUS_BG_1.x,\r\n\t\t\t\theight: convertSizeToCurrentBackground(0,img._element.height).y * SCALE_OF_STATUS_BG_1.y\r\n\t\t\t});\r\n\t\t\t\r\n\t\t\tobj_status1_BG = img; // save dice into global variable\r\n\t\t\t// console.log(\"[preload] loaded obj_status1_BG image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'left',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\tleft: calculatePoint( POSITION_OF_STATUS_BG_1.x, 0 ).x,\r\n\t\t\ttop: calculatePoint( 0, POSITION_OF_STATUS_BG_1.y ).y\r\n\t\t}\r\n\t);\r\n\t// draw obj_status2_BG object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/charecter/info_bg_right_'+(ints_selectedCharacterIndex[1]+1)+'.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_fabric.add( img );\r\n\t\t\timg.isLink = false;\r\n\t\t\timg.set({\r\n\t\t\t\twidth: convertSizeToCurrentBackground(img._element.width,0).x * SCALE_OF_STATUS_BG_2.x,\r\n\t\t\t\theight: convertSizeToCurrentBackground(0,img._element.height).y * SCALE_OF_STATUS_BG_2.y\r\n\t\t\t});\r\n\t\t\t\r\n\t\t\tobj_status2_BG = img; // save dice into global variable\r\n\t\t\t// console.log(\"[preload] loaded obj_status2_BG image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'right',\r\n\t\t\toriginY: 'top',\r\n\t\t\tleft: calculatePoint( POSITION_OF_STATUS_BG_2.x, 0 ).x,\r\n\t\t\ttop: calculatePoint( 0, POSITION_OF_STATUS_BG_2.y ).y\r\n\t\t}\r\n\t);\r\n\t// create player1 image object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/charecter/char'+(ints_selectedCharacterIndex[0]+1)+'.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_object_fabric.add( img );\r\n\t\t\tobj_player1 = img; // save player1 into global variable\r\n\t\t\tobj_player1.int_score = SCORE_INIT;\r\n\t\t\tobj_player1.int_rollTimes = AVAILABLE_ROLL_TIMES;\r\n\t\t\tobj_player1.int_playerPosition = 0;\r\n\t\t\tobj_player1.isFollowedByMascot = false;\r\n\t\t\tobj_player1.isFollowedByBadLuck = false;\r\n\t\t\tobj_player1.int_parasiteRemainingRound = 0;\r\n\t\t\tobj_player1.int_order = 0;\r\n\t\t\tobj_currentSubject = obj_player1; // let player1 move first\r\n\t\t\t// console.log(\"[preload] loaded obj_player1 image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\tleft: BLOCKS[0].x + OFFSET_C1.x + BLOCKS[0].offset.x[0],\r\n\t\t\ttop: BLOCKS[0].y + OFFSET_C1.y + BLOCKS[0].offset.y[0],\r\n\t\t\twidth: charData[ints_selectedCharacterIndex[0]].width,\r\n\t\t\theight: charData[ints_selectedCharacterIndex[0]].height\r\n\t\t}\r\n\t);\r\n\t// create player2(or computer) image object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/charecter/char'+(ints_selectedCharacterIndex[1]+1)+'.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_object_fabric.add( img );\r\n\t\t\tobj_player2 = img; // save player2 into global variable\r\n\t\t\tobj_player2.int_score = SCORE_INIT;\r\n\t\t\tobj_player2.int_rollTimes = AVAILABLE_ROLL_TIMES;\r\n\t\t\tobj_player2.int_playerPosition = 0;\r\n\t\t\tobj_player2.isFollowedByMascot = false;\r\n\t\t\tobj_player2.isFollowedByBadLuck = false;\r\n\t\t\tobj_player2.int_parasiteRemainingRound = 0;\r\n\t\t\tobj_player2.int_order = 1;\r\n\t\t\t// console.log(\"[preload] loaded obj_player2 image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\tleft: BLOCKS[0].x + OFFSET_C2.x + BLOCKS[0].offset.x[1],\r\n\t\t\ttop: BLOCKS[0].y + OFFSET_C2.y + BLOCKS[0].offset.y[1],\r\n\t\t\twidth: charData[ints_selectedCharacterIndex[1]].width,\r\n\t\t\theight: charData[ints_selectedCharacterIndex[1]].height\r\n\t\t}\r\n\t);\r\n\r\n\t// create mascot image object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/badluck.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_object_fabric.add( img );\r\n\t\t\tobj_mascot = img;\r\n\t\t\t// randomly set mascot on the map ( except the START point )\r\n\t\t\tgenerateMascot(canvas_object_fabric);\r\n\t\t\t// console.log(\"[preload] loaded obj_mascot image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\tvisible: false\r\n\t\t}\r\n\t);\r\n\t// create mascot image object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/mascot.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_object_fabric.add( img );\r\n\t\t\tobj_badLuck = img;\r\n\t\t\t// randomly set bad luck on the map ( except the START point )\r\n\t\t\tgenerateBadLuck(canvas_object_fabric);\r\n\t\t\t// console.log(\"[preload] loaded obj_badLuck image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\tvisible: false\r\n\t\t}\r\n\t);\r\n\t// draw dice object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/1.png',\r\n\t\tfunction( img ) {\r\n\t\t\tcanvas_episode_fabric.add( img );\r\n\t\t\timg.isLink = true;\r\n\t\t\timg.set({\r\n\t\t\t\twidth: convertSizeToCurrentBackground(img._element.width,0).x * SCALE_OF_DICE.x,\r\n\t\t\t\theight: convertSizeToCurrentBackground(0,img._element.height).y * SCALE_OF_DICE.y\r\n\t\t\t});\r\n\t\t\timg.setCoords();\r\n\t\t\tobj_dice = img; // save dice into global variable\r\n\t\t\t// console.log(\"[preload] loaded obj_dice image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'center',\r\n\t\t\tleft: calculatePoint( POSITION_OF_DICE.x, 0 ).x,\r\n\t\t\ttop: calculatePoint( 0, POSITION_OF_DICE.y ).y\r\n\t\t}\r\n\t);\r\n\t// draw mascotOnCharacter object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/sun.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tobj_mascotOnCharacter = img;\r\n\t\t\tobj_mascotOnCharacter.setOpacity(0.9);\r\n\t\t\tcanvas_object_fabric.add(obj_mascotOnCharacter);\r\n\t\t\t// console.log(\"[preload] loaded obj_mascotOnCharacter image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tvisible: false,\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\twidth: convertSizeToCurrentBackground(256,256).x * SCALE_OF_MASCOT_ON_CHARACTER,\r\n\t\t\theight: convertSizeToCurrentBackground(256,256).y * SCALE_OF_MASCOT_ON_CHARACTER\r\n\t\t}\r\n\t);\r\n\t// draw badLuckOnCharacter object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/cloud.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tobj_badluckOnCharacter = img;\r\n\t\t\tobj_badluckOnCharacter.setOpacity(0.9);\r\n\t\t\tcanvas_object_fabric.add(obj_badluckOnCharacter);\r\n\t\t\t// console.log(\"[preload] loaded obj_badluckOnCharacter image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tvisible: false,\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'bottom',\r\n\t\t\twidth: convertSizeToCurrentBackground(408,255).x * SCALE_OF_BADLUCK_ON_CHARACTER,\r\n\t\t\theight: convertSizeToCurrentBackground(408,255).y * SCALE_OF_BADLUCK_ON_CHARACTER\r\n\t\t}\r\n\t);\r\n\t// draw correct word object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/yes.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tobj_correctWord = img;\r\n\t\t\tcanvas_episode_fabric.add(obj_correctWord);\r\n\t\t\t// console.log(\"[preload] loaded obj_correctWord image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tvisible: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'center',\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false\r\n\t\t}\r\n\t);\r\n\t// draw wrong word object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/no.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tlet tempX = calculatePoint(2600, 800).x;\r\n\t\t\tlet tempY = calculatePoint(2600, 800).y;\r\n\t\t\timg.set({left:tempX,top:tempY});\r\n\t\t\tobj_wrongWord = img;\r\n\t\t\tcanvas_episode_fabric.add(obj_wrongWord);\r\n\t\t\t// console.log(\"[preload] loaded obj_wrongWord image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tvisible: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'center',\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false\r\n\t\t}\r\n\t);\r\n\t// draw obj_eventBG object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/event_background.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tobj_eventBG = img;\r\n\t\t\tlet targetSize = convertSizeToCustomRange(3123, 1975, BG_WIDTH_IN_CANVAS * 9/10, BG_HEIGHT_IN_CANVAS * 9/10);\r\n\t\t\tobj_eventBG.set({\r\n\t\t\t\twidth: targetSize.width,\r\n\t\t\t\theight: targetSize.height,\r\n\t\t\t});\r\n\t\t\tcanvas_episode_fabric.add(obj_eventBG);\r\n\t\t\t// console.log(\"[preload] loaded obj_eventBG image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tvisible: false,\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'center',\r\n\t\t\tleft: canvas_fabric.width/2,\r\n\t\t\ttop: canvas_fabric.height/2\r\n\t\t}\r\n\t);\r\n\t// draw obj_eventOccurrenceBG object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/occurrence_event/occurrence_background.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tobj_eventOccurrenceBG = img;\r\n\t\t\tlet targetSize = convertSizeToCustomRange(3423, 2276, BG_WIDTH_IN_CANVAS, BG_HEIGHT_IN_CANVAS);\r\n\t\t\tobj_eventOccurrenceBG.set({\r\n\t\t\t\twidth: targetSize.width,\r\n\t\t\t\theight: targetSize.height,\r\n\t\t\t});\r\n\t\t\tcanvas_episode_fabric.add(obj_eventOccurrenceBG);\r\n\t\t\t// console.log(\"[preload] loaded obj_eventOccurrenceBG image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tvisible: false,\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'center',\r\n\t\t\tleft: canvas_fabric.width/2,\r\n\t\t\ttop: canvas_fabric.height/2\r\n\t\t}\r\n\t);\r\n\t// draw obj_endGameBG object\r\n\tfabric.Image.fromURL(\r\n\t\t'./images/end_scene/diagnosis_background.png',\r\n\t\tfunction( img ) {\r\n\t\t\timg.isLink = false;\r\n\t\t\tobj_endGameBG = img;\r\n\t\t\tlet targetSize = convertSizeToCustomRange(3385, 2112, BG_WIDTH_IN_CANVAS, BG_HEIGHT_IN_CANVAS);\r\n\t\t\tobj_endGameBG.set({\r\n\t\t\t\twidth: targetSize.width,\r\n\t\t\t\theight: targetSize.height,\r\n\t\t\t});\r\n\t\t\tcanvas_end_fabric.add(obj_endGameBG);\r\n\t\t\t// console.log(\"[preload] loaded obj_endGameBG image\");\r\n\t\t\twindow.progressCount++; // increase progress counter of loading image\r\n\t\t},{\r\n\t\t\tselectable: false,\r\n\t\t\thasControls: false,\r\n\t\t\thasBorders: false,\r\n\t\t\thasRotatingPoint: false,\r\n\t\t\toriginX: 'center',\r\n\t\t\toriginY: 'center',\r\n\t\t\tleft: canvas_fabric.width/2,\r\n\t\t\ttop: canvas_fabric.height/2\r\n\t\t}\r\n\t);\r\n}", "title": "" }, { "docid": "9e66eb7dba943566c91c94ce6c4572f8", "score": "0.48646906", "text": "function Sprite(img, num) {\n\tthis.img = img;\n\tthis.oimg = img;\n\tthis.num = num;\n\tthis.data = null;\n\tthis.loaded = false;\n\tthis.tint = null; //Hat es das tinting?\n\t\n\tthis.frames = null;\n\tthis.frameWidth = -1;\n\tthis.frameHeight = -1;\n}", "title": "" }, { "docid": "c9e4355965542f55603f945e64fbe03f", "score": "0.48618555", "text": "function preload () {\n this.load.spritesheet('ship', '../img/pixel_ship.png',\n { frameWidth: 32, frameHeight: 32 }\n );\n this.load.spritesheet('cross', '../img/cross.png',\n { frameWidth: 16, frameHeight: 16 }\n );\n}", "title": "" }, { "docid": "aa3f18bf5f791145b6633ffe63b84497", "score": "0.48599625", "text": "function Bitmap(image) {\n this.init(image);\n}", "title": "" }, { "docid": "c2dc0405706b4f3060d90e2eddb32633", "score": "0.48549885", "text": "evaluateSprites() {\n this.spriteNumber = 0;\n this.spriteCount = 0;\n\n const height = this.bigSprites ? 16 : 8;\n const bottomY = this.scanline + 1;\n const topY = bottomY - height + 1;\n\n for (let address = 0; address < this.primaryOAM.length; address += 4) {\n const spriteY = this.primaryOAM[address] + 1;\n\n if (spriteY < topY || spriteY > bottomY) {\n continue;\n }\n\n if (this.spriteCount >= 8) {\n this.spriteOverflow = 1;\n break;\n }\n\n let patternTableAddress = this.spPatternTableAddress;\n let patternNumber = this.primaryOAM[address + 1];\n\n if (this.bigSprites) {\n patternTableAddress = (patternNumber & 1) << 12;\n patternNumber &= 0xFE;\n }\n\n const attributes = this.primaryOAM[address + 2];\n let rowNumber = bottomY - spriteY;\n\n if (attributes & 0x80) {\n rowNumber = height - rowNumber - 1; // Vertical flip\n }\n\n if (rowNumber >= 8) { // Overflow to the next (bottom) pattern\n rowNumber -= 8;\n patternNumber++;\n }\n\n const sprite = this.secondaryOAM[this.spriteCount];\n sprite.x = this.primaryOAM[address + 3];\n sprite.zeroSprite = address === 0;\n sprite.horizontalFlip = attributes & 0x40;\n sprite.paletteNumber = 0x10 | ((attributes & 0x03) << 2);\n sprite.inFront = (attributes & 0x20) === 0;\n\n const patternAddress = patternTableAddress + (patternNumber << 4);\n sprite.patternRowAddress = patternAddress + rowNumber;\n\n this.spriteCount++;\n }\n }", "title": "" }, { "docid": "d05a9ec1b5bcd8942a6dace6a7357f08", "score": "0.48511696", "text": "function preload(){\n\t\tvar preloadHTML = \"\";\n\n\t\t// preload arrow corners\n\t\tpreloadHTML = preloadHTML + imageHTML(\"b_l_corner.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"b_r_corner.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"u_l_corner.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"u_r_corner.png\");\n\n\t\t// preload arrow heads\n\t\tpreloadHTML = preloadHTML + imageHTML(\"left_arrow.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"right_arrow.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"up_arrow.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"down_arrow.png\");\n\n\t\t// preload arrow stubs\n\t\tpreloadHTML = preloadHTML + imageHTML(\"left_stub.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"right_stub.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"up_stub.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"down_stub.png\");\n\n\t\t// preload arrow lines\n\t\tpreloadHTML = preloadHTML + imageHTML(\"horizontal_line.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"vertical_line.png\");\n\n\t\t// preload sprites\n\t\tpreloadHTML = preloadHTML + imageHTML(\"character princess girl.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"chest closed.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"chest open.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"key.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"gem blue.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"star.png\");\n\n\t\t// preload UI elements\n\t\tpreloadHTML = preloadHTML + imageHTML(\"gameover.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"grid.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"keysnow.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"playagain.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"tryagain.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"you win.png\");\n\t\tpreloadHTML = preloadHTML + imageHTML(\"title.png\");\t\n\n\t\t// load the images into the page\n\t\t$(\"#preload\").append(preloadHTML);\n\t}", "title": "" }, { "docid": "ab8a6c8a3c3bd1a66f56d8b196fdc756", "score": "0.4844712", "text": "function preload() {\n apple_img = loadImage('Images/apple--v1.png');\n banana_img = loadImage('Images/banana.png');\n kale_img = loadImage('Images/big-carrot---v1.png');\n bacon_img = loadImage('Images/strawberry--v1.png');\n pineapple_img = loadImage('Images/ice-cream-in-waffle-cone.png');\n milk_img = loadImage('Images/milk-bottle--v2.png');\n smoothie_img = loadImage('Images/usageicon-smoothie.png');\n chocolate_img = loadImage('Images/Chocolate_Bar_Emoji_large.png');\n checkMark_img1 = loadImage('Images/icons8-checkmark-512 (1).png');\n checkMark_img2 = loadImage('Images/icons8-checkmark-512 (1).png');\n checkMark_img3 = loadImage('Images/icons8-checkmark-512 (1).png');\n font1 = loadFont('DK Crayon Crumble.ttf');\n font2 = loadFont('FROSTY__.TTF');\n}", "title": "" }, { "docid": "4cbde8157761cb43e1477ed078f14b4b", "score": "0.48313576", "text": "function preload() {\n $('#loading').text('Collecting decorative stone...');\n game.load.image('dungeonTiles', '/assets/dungeon.png');\n\n $('#loading').text('Gathering elf tears...');\n game.load.spritesheet('GUI0', '/assets/GUI0.png', 16, 16, 304);\n\n $('#loading').text('Poking through driftwood...');\n game.load.spritesheet('doors0', '/assets/doors0.png', 16, 16, 40);\n\n $('#loading').text('Still poking...');\n game.load.spritesheet('doors1', '/assets/doors1.png', 16, 16, 40);\n\n $('#loading').text('Petitioning heroes...');\n game.load.spritesheet('player0', '/assets/player0.png', 16, 16, 120);\n\n $('#loading').text('Teasing the cowards...');\n game.load.spritesheet('player1', '/assets/player1.png', 16, 16, 120);\n\n $('#loading').text('Finding tapestries to tie the room together...');\n game.load.spritesheet('decor0', '/assets/decor0.png', 16, 16, 176);\n\n $('#loading').text('Looking for stairs to fall down...');\n game.load.spritesheet('ground', '/assets/ground.png', 16, 16, 56 );\n\n $('#loading').text('Importing exotic dirt...');\n game.load.spritesheet('tile', '/assets/tile.png', 16, 16, 32);\n\n $('#loading').text('Digging the dungeon...');\n }", "title": "" }, { "docid": "b44a57c2ab88e00ce7e069bfd850fd0c", "score": "0.4829779", "text": "function Start(){\n\t\n\t//myTexture = Resources.Load(\"title03\");\n\n}", "title": "" }, { "docid": "9bb72f1e66ddda2ea9b5a458b7cbcabd", "score": "0.4829601", "text": "function loadImages(image, name, xPos, yPos, cursor, rot, container, scale) {\n var _bitmap = new createjs.Bitmap(image).set({});\n _bitmap.x = xPos;\n _bitmap.y = yPos;\n _bitmap.scaleX = _bitmap.scaleY = scale;\n _bitmap.name = name;\n _bitmap.alpha = 1;\n _bitmap.rotation = rot;\n _bitmap.cursor = cursor;\n if ( name == \"clock_needle\" ) {\n _bitmap.regX = _bitmap.image.width / 2;\n _bitmap.regY = _bitmap.image.height / 2; \n }\n container.addChild(_bitmap); /** Adding bitmap to the container */\n}", "title": "" }, { "docid": "a0775a5a6c1a958fffae674b4d14b7a1", "score": "0.48292032", "text": "function Sprite(loader, sources, callback) {\n\n Group.call(this);\n\n this._loader = loader;\n this.sources = sources;\n this.currentBitmapIndex = 0;\n\n if (callback) {\n this.bindAssetCallback(callback);\n }\n\n Object.defineProperties(this._attributes, {\n height: data(0, true, true),\n width: data(0, true, true)\n });\n\n this._load();\n }", "title": "" }, { "docid": "8699994fd9856c284f0557787c31c7ae", "score": "0.48285154", "text": "function skeleton_Preload()\n{\n\tLucifer_Game.load.spritesheet('MON_Skeleton_Stand',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Skeleton/stand/stand.png',\n\t\t\t\t\t\t\t\t 100, 100);\n\tLucifer_Game.load.spritesheet('MON_Skeleton_Walk',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Skeleton/walk/walk.png',\n\t\t\t\t\t\t\t\t 100, 100);\n\tLucifer_Game.load.spritesheet('MON_Skeleton_Attack',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Skeleton/attack/attack.png',\n\t\t\t\t\t\t\t\t 100, 100);\n\tLucifer_Game.load.spritesheet('MON_Skeleton_Dead',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Skeleton/death/death.png',\n\t\t\t\t\t\t\t\t 100, 100);\n\tLucifer_Game.load.spritesheet('MON_Skeleton_Create',\n\t\t\t\t\t\t\t\t '../../static/images/game/Monster/Skeleton/create/create.png',\n\t\t\t\t\t\t\t\t 72, 72);\n}", "title": "" }, { "docid": "be8926e9516d6477827de0d293022a60", "score": "0.48257598", "text": "function loadImages(image, name, xPos, yPos, sFactor, container) {\n\tvar _bitmap = new createjs.Bitmap(image).set({});\n\t_bitmap.x = xPos;\n\t_bitmap.y = yPos;\n\t_bitmap.name = name;\n\t_bitmap.alpha = 1;\n\t_bitmap.scaleX = _bitmap.scaleY = sFactor;\n\tif (name == \"turner1_arrow_Left\" || name == \"turner2_arrow_Left\") { /** flip images */\n\t\t_bitmap.scaleX = _bitmap.scaleY = sFactor * -1;\n\t}\n\t/** register rotation points */\n\tif (name == \"turner1dot\" || name == \"turner2dot\") {\n\t\t_bitmap.regX = _bitmap.image.width / .5;\n\t\t_bitmap.regY = _bitmap.image.height / .5;\n\t\tif (name == \"turner1dot\") /** Initialize tuner rotation to initial value */\n\t\t_bitmap.rotation = -40;\n\t\telse _bitmap.rotation = -90;\n\t}\n\tif (name == \"coil\") { /** Masking coil */\n\t\t_bitmap.mask = coil_mask_rect;\n\t\t_bitmap.scaleY = 1;\n\t}\n\tcontainer.addChild(_bitmap);\n\tstage.update();\n}", "title": "" }, { "docid": "d6fe09efb4471e6b7b5282c2aae7acc9", "score": "0.4818822", "text": "function loadTexture(gl, s) {\n\tconst texture = gl.createTexture();\n\tgl.bindTexture(gl.TEXTURE_2D, texture);\n\n\t//image takes time to load - we use single pixel until its finished loading, then we slap the texture on the object\n\tconst level = 0;\n\tconst internalFormat = gl.RGBA;\n\tconst width = 1;\n\tconst height = 1;\n\tconst border = 0;\n\tconst srcFormat = gl.RGBA;\n\tconst srcType = gl.UNSIGNED_BYTE;\n\tconst pixel = new Uint8Array([0, 0, 255, 255]); // opaque blue\n\tgl.texImage2D(gl.TEXTURE_2D, level, internalFormat,\n\t\t\t\twidth, height, border, srcFormat, srcType,\n\t\t\t\tpixel);\n\n\tconst image = new Image();\n\timage.onload = function() {\n\t\tgl.bindTexture(gl.TEXTURE_2D, texture);\n\t\tgl.texImage2D(gl.TEXTURE_2D, level, internalFormat,\n\t\t\t\t\t srcFormat, srcType, image);\n\n\t\t// WebGL1 has different requirements for power of 2 images\n\t\t// vs non power of 2 images so check if the image is a\n\t\t// power of 2 in both dimensions.\n\t\tif (isPowerOf2(image.width) && isPowerOf2(image.height)) {\n\t\t\t// Yes, it\"s a power of 2. Generate mips.\n\t\t\t//gl.generateMipmap(gl.TEXTURE_2D);\n\t\t\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.REPEAT);\n\t\t\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.REPEAT);\n\t\t\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n\t\t\tconsole.log(\"Image is 2^x\");\n\t\t} else {\n\t\t\t// Not a power of 2. Turn off mips and set\n\t\t\t// wrapping to clamp to edge\n\t\t\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_S, gl.CLAMP_TO_EDGE);\n\t\t\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_WRAP_T, gl.CLAMP_TO_EDGE);\n\t\t\tgl.texParameteri(gl.TEXTURE_2D, gl.TEXTURE_MIN_FILTER, gl.LINEAR);\n\t\t\tconsole.log(\"Image is not 2^x\");\n\t\t}\n\t};\n\timage.src = s;\n\n\treturn texture;\n}", "title": "" }, { "docid": "8dd3b9ef4565f2ee4f534ec8f6f35861", "score": "0.48178902", "text": "function staticSprite(name)\r\n{\r\n this.type = \"static\";\r\n this.image = new Image();\r\n this.image.src = name;\r\n}", "title": "" }, { "docid": "e6663b77e77d32f51432cd9d4f77d054", "score": "0.48169464", "text": "function loadImages(image, name, xPos, y_position, cursor, scale,container) {\n\tvar _bitmap = new createjs.Bitmap(image).set({});\n\t if ( name == \"vernier_scale\" || name == \"main_scale\" ) { /** Masking the main scale and vernier scale */\n \t_bitmap.mask = scale_mask_rect;\n } \n _bitmap.x = xPos;\n _bitmap.y = y_position;\n\t_bitmap.scaleX = _bitmap.scaleY = scale;\n _bitmap.name = name;\n\t_bitmap.cursor = cursor;\n\tcontainer.addChild(_bitmap); /** Adding bitmap to the stage */\n\tupdateStage();\n}", "title": "" }, { "docid": "ed4abf0007392cdd3549b4a8122974b7", "score": "0.48157647", "text": "function outputBitmaps() {\n let outputField = document.getElementById(\"outputField\");\n outputField.value = \"\";\n\n outputField.value +=\n `static const uint16_t Font${numCols - padLeft - padRight}x${numRows} [] = {\\n`;\n\n generateCharBitmaps();\n\n for (var i = 0; i < bitmapStrings.length; i++) {\n outputField.value += \" \";\n outputField.value += bitmapStrings[i];\n }\n\n outputField.value += `};`\n\n outputFieldRefreshDims();\n}", "title": "" }, { "docid": "e69ef9884eba4107bfe75a0f222ae8c9", "score": "0.480866", "text": "function tfcsprite(file, enc, callback) {\n /*jshint validthis:true*/\n\n // Do nothing if no contents\n if (file.isNull()) {\n this.push(file);\n return callback();\n }\n\n if (file.isStream()) {\n\n // http://nodejs.org/api/stream.html\n // http://nodejs.org/api/child_process.html\n // https://github.com/dominictarr/event-stream\n\n // accepting streams is optional\n this.emit(\"error\",\n new gutil.PluginError(\"gulp-tfcsprite\", \"Stream content is not supported\"));\n return callback();\n }\n\n // check if file.contents is a `Buffer`\n if (file.isBuffer()) {\n\n var target = Path.relative(process.cwd(), file.path);\n var parsedPath = parsePath(target);\n var directory = parsedPath.dirname + '/' + param.sprites;\n var converted = new TFCSpriteConverter(\n target,\n directory,\n param.prefix\n ).convert();\n\n\n if (converted) {\n file.contents = new Buffer(converted);\n }\n\n this.push(file);\n\n }\n return callback();\n }", "title": "" }, { "docid": "dc748b2fad7bacd86c63de91b00aaef7", "score": "0.48043752", "text": "function loadBackground(){\n var starfield = game.add.tileSprite(0, 0, 800, 600, 'stars');\n starfield.fixedToCamera = true;\n\n var style = { font: \"bold 32px Arial\", fill: \"#fff\", boundsAlignH: \"center\", boundsAlignV: \"middle\" };\n\n // The Text is positioned at 0, 100\n text = game.add.text(350, 0, \"Penzzle\", style);\n}", "title": "" } ]
dc3cee0a3ff15f901b2459d5f3d88356
Insert rows to table according to sessionStorage.
[ { "docid": "f8bf51f1328a33883e3378fe68f2ad50", "score": "0.0", "text": "function populateTable(tableOutputBody, isInit) {\n\tif (tableOutputBody == null) {\n\t\treturn;\n\t}\n\t\n\tif (!isInit) {\n\t\tdocument.getElementById(\"tableOutput\").style.display = 'block';\n\t}\n\t\n\tvar columnsMetadata = getTableColumnsMetadata();\n\tif (columnsMetadata == null) {\n\t\treturn;\n\t}\n\t\n\tclearAllTableRows();\n\t\n\tvar firstIndex = getTableOrListStart('tableOutputHead');\n\tvar lastIndex = getHighestIndex(columnsMetadata[0].id);\n\tfor (var i = firstIndex; i <= lastIndex; i++) {\n\t\tpopulateTableRow(tableOutputBody, columnsMetadata, i);\n\t}\n\t\n\tvar tableFilter = document.getElementById('tableFilter');\n\tif (tableFilter !== null) {\n\t\ttableFilter.style.width = document.getElementById(\"tableOutputHead\").offsetWidth + 'px';\n\t}\n}", "title": "" } ]
[ { "docid": "1db4723d24730b9f387527789df9642b", "score": "0.5984228", "text": "function appendRow(row) {\n let existing = window.localStorage.getItem(\"tweets\");\n if (!existing) {\n window.localStorage.setItem(\"tweets\", JSON.stringify([row]));\n return;\n }\n existing = JSON.parse(existing);\n existing.push(row);\n window.localStorage.setItem(\"tweets\", JSON.stringify(existing));\n }", "title": "" }, { "docid": "43fb52f290036147008f329ef856fca9", "score": "0.5964763", "text": "function addToSessionStorage(id){\n // create a variable that holds the parsed data held in the sessionStorage//retrieve data\n currentList = JSON.parse(sessionStorage.getItem(\"products\"));\n // console.log(typeof(currentList))\n // if the sessionStorage doesn't hold any strings/objects, then create an empty string so \n // the cart page doesn't render a error 500 if nothing is in the sessionStorage(cart) yet.\n if (currentList === null){\n currentList = []\n } \n // if the session storage does contain data, take the number of the id, push it to the empty list\n currentList.push(Number(id))\n\n // Take the numbers pushed to currentList, make them a string (because thats the \n //way the data can be accepted in sessionStorage), give it a name to refer the value to and set it to sessionStorage\n // store data\n sessionStorage.setItem(\"products\", JSON.stringify(currentList));\n\n loadCartCount();\n\n // Add success message \n document.getElementById(\"alert-\"+id).textContent = \"Loom added to Cart\"\n\n}", "title": "" }, { "docid": "cf18eea3eb06b65bc15c52a791118de1", "score": "0.59110504", "text": "function insertRowToTable()\r\n{\r\n\tif (hasLoaded) {\r\n\t\tvar tbl = document.getElementById(TABLE_NAME);\r\n\t\tvar rowToInsertAt = tbl.tBodies[0].rows.length;\r\n\t\tfor (var i=0; i<tbl.tBodies[0].rows.length; i++) {\r\n\t\t\tif (tbl.tBodies[0].rows[i].myRow && tbl.tBodies[0].rows[i].myRow.four.checked) {\r\n\t\t\t\trowToInsertAt = i;\r\n\t\t\t\tbreak;\r\n\t\t\t}\r\n\t\t}\r\n\t\taddRowToTable(rowToInsertAt);\r\n\t//\treorderRows(tbl, rowToInsertAt);\r\n\t}\r\n}", "title": "" }, { "docid": "c77bf284d2ef584b2ce60f555ac4ca10", "score": "0.58061904", "text": "function showFavTable() {\r\n const favorites = sessionStorage.getItem('favorites');\r\n const favoritesTableBody = document.getElementById('favoritesTableBody');\r\n const tbody = document.createElement('tbody');\r\n tbody.setAttribute(\"id\", \"favoritesTableBody\");\r\n if (favorites != null) {\r\n // Select pysäkki from favourites where userID = document.getElementById('login').value;\r\n const resultSet = JSON.parse(favorites);\r\n for (let i = 0; i < resultSet.length; i++) {\r\n const tr = document.createElement('tr');\r\n const td = document.createElement('td');\r\n const td2 = document.createElement('td');\r\n td2.setAttribute(\"class\", \"deleteFav\")\r\n const icon = document.createElement('i');\r\n icon.setAttribute(\"class\", \"fas fa-minus\")\r\n const deleteBtn = document.createElement('button');\r\n deleteBtn.setAttribute(\"onclick\", \"deleteFavorite(\" + i +\")\");\r\n deleteBtn.appendChild(icon);\r\n td2.appendChild(deleteBtn);\r\n td.innerHTML = resultSet[i].stopName;\r\n td.setAttribute(\"onclick\", \"requestSchedule(\" + i + \")\");\r\n tr.appendChild(td);\r\n tr.appendChild(td2);\r\n tbody.appendChild(tr);\r\n }\r\n } else {\r\n const tr = document.createElement('tr');\r\n const td = document.createElement('td');\r\n td.innerHTML = \"Et ole kirjautuneena sisään. Kirjaudu sisään tai luo käyttäjä käyttääksesi suosikkipysäkit - toimintoa.\";\r\n tr.appendChild(td);\r\n tbody.appendChild(tr);\r\n }\r\n favoritesTableBody.parentNode.replaceChild(tbody, favoritesTableBody);\r\n}", "title": "" }, { "docid": "74c3fef7e40ddd063e9e17a8f8db152c", "score": "0.5806069", "text": "function storeUpscoredRowData(position ){\n \t\n\n \tif(document.getElementById(\"name\").value == null){\n \t\t\n \t\talert(\"name field required\");\n \t\treturn ;\n \t}\n \telse if(document.getElementById(\"subject\").value == null){\n \t\t\n\n \t\talert(\"subject field required\");\n \t\treturn;\n \t}\n \telse if(document.getElementById(\"score\").value == null){\n \t\t\n \t\talert(\"score is required\");\n \t\treturn ;\n \t}\n\n\n \tlet dataList = JSON.parse(localStorage.getItem(\"allData\"));\n \tdataList[position - 1].name = document.getElementById(\"name\").value ;\n \tdataList[position - 1].subject = document.getElementById(\"subject\").value ;\n \tdataList[position - 1].score = document.getElementById(\"score\").value ;\n \tshowUpscoredRow( position , dataList[position - 1].name, dataList[position - 1].subject , dataList[position - 1].score) ;\n\n \tlocalStorage.setItem(\"allData\" , JSON.stringify(dataList));\n\n \tsetPreviousMode() ;\n\n\n }", "title": "" }, { "docid": "c6f7e32ac8b7dd463832d95fdc4616d6", "score": "0.57244784", "text": "function store() {\n $('#storeTable').append(\"<tr><td>\" + questionString + \"</td><td>\" + answer + \"</td></tr>\");\n\n }", "title": "" }, { "docid": "292d5b6f68a99f4f234da5089c6c3e03", "score": "0.5722461", "text": "addSession(id, session) {\n const classes = this.getClassById(id);\n classes.sessions.push(session);\n\n classes.numSessions = classes.sessions.length;\n this.store.save();\n }", "title": "" }, { "docid": "ce1aaf162fe9b24df109e0178cc722b8", "score": "0.57009184", "text": "function insertRowIntoTable(data) {\n // console.log(data);\n const table = document.querySelector('table tbody');\n const isTableData = table.querySelector('.no-data');\n\n let tableHtml = \"<tr>\";\n\n for (var key in data) {\n if (data.hasOwnProperty(key)) {\n if (key === 'dateAdded') {\n data[key] = new Date(data[key]).toLocaleString();\n }\n tableHtml += `<td>${data[key]}</td>`;\n }\n }\n\n tableHtml += `<td><button class=\"delete-row-btn\" data-id=${data.id}>Delete</td>`;\n tableHtml += `<td><button class=\"edit-row-btn\" data-id=${data.id}>Edit</td>`;\n\n tableHtml += \"</tr>\";\n\n if (isTableData) {\n table.innerHTML = tableHtml;\n } else {\n const newRow = table.insertRow();\n newRow.innerHTML = tableHtml;\n }\n\n window.location.reload();\n}", "title": "" }, { "docid": "1189282e863f9eda025a54625415b410", "score": "0.5653605", "text": "insertarCarrito(producto){\r\n const row = document.createElement('tr');\r\n row.innerHTML = `\r\n <td>\r\n <img src=\"${producto.imagen}\" width=100>\r\n </td>\r\n <td>${producto.titulo}</td>\r\n <td>${producto.precio}</td>\r\n <td>\r\n <a href=\"#\" class=\"borrar-producto fas fa-times-circle\" data-id=\"${producto.id}\"></a>\r\n </td>\r\n `;\r\n listaProductos.appendChild(row);\r\n this.guardarProductosLocalStorage(producto);\r\n \r\n}", "title": "" }, { "docid": "b0d3c16d72c8a1f169942c94afe9c5cf", "score": "0.5641182", "text": "function addtable() {\n tbody.html(\"\");\n console.log(`There are ${tableDatashape.length} records in this table.`);\n console.log(\"----------\");\n tableDatashape.forEach(function(sighting) {\n var row = tbody.append(\"tr\");\n Object.entries(sighting).forEach(function([key, value]) {\n var cell = row.append(\"td\");\n cell.text(value);\n });\n });\n }", "title": "" }, { "docid": "39f8bc9a64b8ce59bc9d601167f29de8", "score": "0.5635978", "text": "createSession() {\n if (window.sessionStorage.getItem(LOCAL_SESSION)) {\n Main.favouritesFromSession = JSON.parse(\n window.sessionStorage.getItem(LOCAL_SESSION)\n );\n this.populateModal();\n }\n window.sessionStorage.setItem(LOCAL_SESSION, '{ \"favourites\": [] }');\n }", "title": "" }, { "docid": "a64901988acb56512c9c17797e27dc75", "score": "0.56251925", "text": "tableCreated(tblId) {\n const selectedAppId = this.props.selectedAppId;\n this.props.loadApp(selectedAppId);\n\n // store any new table IDs for duration of session for table homepage\n if (window.sessionStorage) {\n let newTables = window.sessionStorage.getItem(NEW_TABLE_IDS_KEY);\n\n let tableIds = newTables ? newTables.split(\",\") : [];\n tableIds.push(tblId);\n\n window.sessionStorage.setItem(NEW_TABLE_IDS_KEY, tableIds.join(\",\"));\n }\n\n this.props.showTableReadyDialog();\n }", "title": "" }, { "docid": "4177641ee7f33aead0b011339c6faab3", "score": "0.5618318", "text": "function storeId(e){\n sessionStorage.setItem(\"categoryId\",e);\n window.location.replace(\"../html/question-table.html\");\n }", "title": "" }, { "docid": "a9f4c620fecbd59a46277b7e268e4f8e", "score": "0.5616638", "text": "function addRowToTable(row) {\n document.getElementById(\"rows\").appendChild(row);\n}", "title": "" }, { "docid": "e097da2730fc690033d41b09f430140a", "score": "0.5612737", "text": "function sincronizar()\n{\n sessionStorage.setItem('articulos', JSON.stringify(articulos));\n // sessionStorage.setItem('contador', JSON.stringify(contador));\n}", "title": "" }, { "docid": "8c59ace0adccdbd24b669f75b836173b", "score": "0.5603954", "text": "function addToCart() {\n const id = document.getElementById(\"idOfProduct\").innerText;\n const name = document.getElementById(\"nameOfProduct\").innerText;\n const price = document.getElementById(\"priceOfProduct\").innerText;\n const quantity = document.getElementById(\"quantityOfProduct\").value;\n const size = document.getElementById(\"sizeOfProduct\").value;\n const color = document.getElementById(\"colorOfProduct\").value;\n const product = {\n id: id,\n name: name,\n price: price,\n size: size,\n quantity: quantity,\n color: color,\n };\n let products = [];\n if (JSON.parse(sessionStorage.getItem(\"products\"))) {\n products = JSON.parse(sessionStorage.getItem(\"products\"));\n } else {\n products = [];\n }\n products.push(product);\n sessionStorage.setItem(\"products\", JSON.stringify(products));\n document.getElementById(\"addToCart\").innerText = \"Added\";\n document.getElementById(\"addToCart\").disabled = true;\n}", "title": "" }, { "docid": "6043f83a09642fc5ef95076fc489e226", "score": "0.5594931", "text": "function upsertSession(seshData) {\n console.log(seshData)\n $.post(\"/api/sessions\", seshData)\n }", "title": "" }, { "docid": "5faddb4601993d657c3cccc4ac6fe029", "score": "0.55527186", "text": "function nuevoitem(){\nvar clave=document.getElementById('nom').value;\nvar valor=document.getElementById('asunto').value;\n\nif (clave != \"\" && valor!= \"\" ){\n guardar(); //guardamos el dato creado pra volver a llamar\n\n\n //creamos la datos a Almacenar\n clave = \"<tr><td>\" + clave;\n valor = \"</td><td>\" + valor + \"</td><td>\";\n\n //guardamos los datos al sessionstorage\n sessionStorage.setItem(clave, valor);\n mostrar();//mostramos la tabla con los dato obteniudos\n\n //limpiamos input\n document.getElementById('nom').value = '';\n document.getElementById('asunto').value = '';\n document.getElementById('coreo').value = '';\n document.getElementById('msg').value = '';\n deshabilitar();\n} else { \n //mensaje de que es neceario completar el formulario\n document.getElementById(\"validar3\").style.display = \"block\";\n document.getElementById('nom').focus();\n\n }\n}", "title": "" }, { "docid": "d7da5a4a29a7a7e6e1022a664a5820fb", "score": "0.55218077", "text": "function insertarDatosTelefonosFrancia(json) {\n\n console.log(json)\n\n json.forEach(el => {\n console.log(el)\n\n const nombreF = el.nombre\n // const contrasenaF = el.contrasena\n // const dniF = el.dni\n const telefonoF = el.telefono\n // const direccionF = el.direccion\n\n\n const datosF = {\n nombreF,\n // contrasenaF,\n // dniF,\n telefonoF\n // direccionF\n }\n\n\n console.log(datosF)\n\n\n if (sessionStorage.getItem('telefonosFrancia') == null) {\n\n let telefonosFrancia = []\n telefonosFrancia.push(datosF)\n sessionStorage.setItem('telefonosFrancia', JSON.stringify(telefonosFrancia))\n } else {\n\n let telefonosFrancia = JSON.parse(sessionStorage.getItem('telefonosFrancia'))\n telefonosFrancia.push(datosF)\n sessionStorage.setItem('telefonosFrancia', JSON.stringify(telefonosFrancia))\n\n }\n\n\n\n })\n\n pintarDatosTelefonosFrancia()\n document.getElementById('form-telefonos').reset()\n // e.preventDefault()\n\n //Accion de ir la agenda direcciones - recuerda\n\n}", "title": "" }, { "docid": "26dca5811a3c6e12bb79ac0acfc1736e", "score": "0.55123174", "text": "function saveTrainingSession(tx, sessionUserID){\n //SESSION STATUS: 1- IN PROGESS, 2- COMPLETED\n //alert('recording session...' + sessionUsersList[0])\n \n //for(var key in sessionUsersList){\n //alert('key ' + sessionUsersList[key]);\n //session id is auto\n var fields = '(\"start_time\",\"end_time\",\"status\",\"session_type\",\"worker_id\",\"module_id\",\"training_id\")';\n var values = '(' +\n '\"' + getNowDate() + '\",' + //start datetime\n 'NULL,' + //end datetime,\n '\"1\",' + //session status - inprogress or completed\n '\"' + _sessionType + '\",' + //session type\n '\"' + sessionUserID + '\",' + //worker id\n '\"' + _moduleID + '\",' + //module id\n '\"' + _topicID + '\")'; //training (topic) id\n \n var query = 'INSERT INTO cthx_training_session ' + fields + ' VALUES ' + values;\n //alert(query);\n tx.executeSql(query);\n //}\n \n }", "title": "" }, { "docid": "6c8691e92e8b7ee3ce90b1c955734c85", "score": "0.5501034", "text": "addToSession(session, tag, order) {\n this.sessionOrders.push({\n session,\n tag,\n order,\n });\n }", "title": "" }, { "docid": "5c4c1dff957b60611a1d67faa1afd3f6", "score": "0.5493047", "text": "function fill_table(displayArray) {\r\n clearTableRows();\r\n setSum(0);\r\n displayArray.sort(function (a, b) {\r\n if (a.sum < b.sum)\r\n return 1;\r\n if (a.sum > b.sum)\r\n return -1;\r\n return 0;\r\n });\r\n displayArray.forEach(elem => {\r\n insertToTable(elem.member, elem.sum);\r\n })\r\n $('#financial_table td').click(function () {\r\n const id = ($(this).closest('tr').attr('id'));\r\n if (id) {\r\n sessionStorage.setItem('selectedPersonKey', id); // save it temporeriy\r\n document.location.href = 'viewMemberFinancial.html';\r\n }\r\n\r\n });\r\n}", "title": "" }, { "docid": "3612c5bb548492b8e00c0dbc0a172b08", "score": "0.5482787", "text": "function obtenerDatosSession(tableName) {\n let tableData = JSON.parse(sessionStorage.getItem(tableName));\n\n if (!tableData) {\n tableData = [];\n }\n return tableData;\n}", "title": "" }, { "docid": "341aa138f568af886822be142d0dd368", "score": "0.5475866", "text": "function addSessionToDOM(session) {\n const card = document.createElement('div');\n card.className = 'card gray-bg';\n\n const body = document.createElement('div');\n body.className = 'card-body';\n\n const titleHeader = document.createElement('h5');\n titleHeader.className = 'card-title';\n titleHeader.appendChild(document.createTextNode(session.title));\n body.appendChild(titleHeader);\n\n const date = document.createElement('p');\n date.className = 'card-text';\n const dateSmall = document.createElement('small');\n dateSmall.className = 'text-muted';\n dateSmall.appendChild(document.createTextNode(session.date));\n date.appendChild(dateSmall);\n body.appendChild(date);\n\n const markedMsg = document.createElement('p');\n markedMsg.className = 'card-text';\n const markedMsgSmall = document.createElement('small');\n markedMsgSmall.className = (session.marked_submissions === session.total_submissions) ?\n 'text-success' : 'text-danger';\n const markedMsgText = `${session.marked_submissions} out of ${session.total_submissions} submissions have been marked.`;\n markedMsgSmall.appendChild(document.createTextNode(markedMsgText));\n markedMsg.appendChild(markedMsgSmall);\n body.appendChild(markedMsg);\n\n const statusBar = document.createElement('div');\n statusBar.className = 'status-bar';\n\n const statusLabel = document.createElement('p');\n statusLabel.className = 'card-text ' + (session.open ? 'text-primary' : 'text-info');\n const statusText = session.open ? 'OPEN' : 'CLOSED';\n statusLabel.appendChild(document.createTextNode(statusText));\n statusBar.appendChild(statusLabel);\n\n if (session.open) {\n const button = document.createElement('button');\n button.setAttribute('type', 'button');\n button.setAttribute('title', 'Close this session');\n button.addEventListener('click', closeSession);\n\n button.className = 'btn btn-primary';\n button.appendChild(document.createTextNode('Close'));\n statusBar.appendChild(button);\n }\n\n body.appendChild(statusBar);\n card.appendChild(body);\n\n const currentCards = sessionsRow.querySelectorAll('.card');\n if (!currentCards)\n sessionsRow.appendChild(card);\n else\n sessionsRow.insertBefore(card, currentCards[0]);\n}", "title": "" }, { "docid": "9b67fe48ac7e7a96856651ac087f64be", "score": "0.54713583", "text": "function guardarEquipos(frm){\r\r\n\r\r\n sessionStorage.clear();\r\r\n sessionStorage.setItem('equipo1', frm.elements.item(0).value);\r\r\n\r\r\n sessionStorage.setItem('equipo2', frm.elements.item(1).value);\r\r\n\r\r\n}", "title": "" }, { "docid": "21df1c7a0354cecb9cd64b8c3b675aa8", "score": "0.5450356", "text": "function row() {\n var table = document.getElementById('Table').insertRow(1);\n var row1 = table.insertCell(0);\n var row2 = table.insertCell(1);\n var row3 = table.insertCell(2);\n var row4 = table.insertCell(3);\n var row5 = table.insertCell(4);\n row1.innerHTML = document.getElementById('name').value;\n row2.innerHTML = document.getElementById('mail').value;\n row3.innerHTML = document.getElementById('num').value;\n row4.innerHTML = document.getElementById('area').value;\n row5.innerHTML = document.getElementById('state').value;\n\n}", "title": "" }, { "docid": "4729429c0f9ecb7381f98a8d4ebe6d37", "score": "0.54102594", "text": "function buildSessionsTable(){\n\tconsole.log(\"building sessions table\")\n\tdatabase.ref(\"sessions\").once(\"value\", function(snapshot) {\n destroySessionsTableBody();\n for(key in snapshot.val()){\n \tvar player1;\n \tvar player2;\n \tif(snapshot.val()[key].player1){\n \t\tplayer1 = snapshot.val()[key].player1.playerEmail;\n \t} else {\n \t\tplayer1 = \"\";\n \t}\n \tif(snapshot.val()[key].player2){\n \t\tplayer2 = snapshot.val()[key].player2.playerEmail;\n \t} else {\n \t\tplayer2 = \"\";\n \t}\n \t$(\"#sessionsTableBody\").append(buildSessionsTableRow(key, snapshot.val()[key].name,player1,player2));\n }\n }, function(errorObject) {\n console.log(\"Sessions read failed: \" + errorObject.code);\n });\n}", "title": "" }, { "docid": "85ee702e806bd0cdc51a68a8388a4f33", "score": "0.5408227", "text": "function addToBasket(prodId, prodName) {\n let basket = getBasket();\n let selectedSize = $(\"#shoeSize\").val();\n let shoeQuantity = $(\"#shoeQuantity\").val();\n let type = $(\"#type\").val();\n let color = $(\"#color\").val();\n let price = $(\"#price\").val();\n let fileName = $(\"#fileName\").val();\n // Get the session storage JSON and parse it to access the elements as an array\n let getSession = JSON.parse(sessionStorage.getItem(\"basket\"));\n // Check if we got a session storage called basket\n if (sessionStorage[\"basket\"]) {\n // iterate over the session storage elements\n for (let element of getSession) {\n // Check if the product name and size is already inside our session to avoid duplication\n if (element.name === prodName && parseInt(element.size) === parseInt(selectedSize)) {\n\n // Add product details to our session storage\n element._id = prodId;\n element.name = prodName;\n element.size = selectedSize;\n element.quantity = element.quantity + parseInt(shoeQuantity);\n // Update new session storage with the new product details\n let updateObj = JSON.stringify(getSession);\n // Send the newly created session storage to our session storage replacing it\n sessionStorage.setItem(\"basket\", updateObj);\n // break the loop\n return;\n }\n }\n }\n\n // Add product to basket\n basket.push({\n _id: prodId,\n name: prodName,\n size: parseInt(selectedSize),\n quantity: parseInt(shoeQuantity),\n type: type,\n color: color,\n price: price,\n fileName: fileName\n });\n\n // Store in session storage\n sessionStorage.basket = JSON.stringify(basket);\n\n //Display the amount of items in our basket in the navigation bar\n $(\"#Basket\").text(\"Basket (\" + (getSession.length + 1) + \")\");\n\n //Display basket in page.\n // alert(\"Added to basket -> Size: \" + JSON.parse(sessionStorage.basket).length);\n}", "title": "" }, { "docid": "ce7851751a5e7921284256d662324422", "score": "0.5399294", "text": "function insert_Row() {\n let x = document.querySelector('tbody').insertRow(0);\n let one = x.insertCell(0);\n let two = x.insertCell(1);\n let three = x.insertCell(2);\n let four = x.insertCell(3);\n let five = x.insertCell(4);\n one.innerHTML = \"New Cell1\";\n two.innerHTML = \"New Cell2\";\n three.innerHTML = \"New Cell1\";\n four.innerHTML = \"New Cell2\";\n five.innerHTML = \"New Cell2\";\n}", "title": "" }, { "docid": "0339f1908bb0c9a6b392f9f5a9059a93", "score": "0.539102", "text": "function initializeRows() {\r\n $stocksContainer.empty();\r\n var rowsToAdd = [];\r\n for (var i = 0; i < stocks.length; i++) {\r\n rowsToAdd.push(createNewRow(stocks[i]));\r\n }\r\n $stocksContainer.prepend(rowsToAdd);\r\n insertStocks();\r\n }", "title": "" }, { "docid": "5e9281d49bf5411ed0ac5317d097b316", "score": "0.53769696", "text": "function add_session(session_data, cb) {\n MongoClient.connect(url, function(err, db) {\n assert.equal(null, err);\n\n var coll = db.collection(currentCollection);\n\n var official_session = {};\n official_session['title'] = session_data.title;\n official_session['teacherName'] = session_data.teacherName;\n official_session['date'] = session_data.date;\n official_session['visible'] = true;\n official_session['prompts'] = [];\n\n coll.insert(official_session, function(err, records) {\n \tassert.equal(null, err);\n console.log(records);\n \tvar session = records.ops[0];\n \tdb.close();\n \tcb(err, session);\n });\n\n });\n}", "title": "" }, { "docid": "94d94889b329e290ccbad7a4d33b669a", "score": "0.5374858", "text": "function ajax_flash_new_table_rows (tablename, number_of_rows)\n {\n var pgm = 'ajax_flash_new_table_rows: ' ;\n // add2log(pgm + 'table_name = ' + tablename + ', number_of_rows = ' + number_of_rows) ;\n var table = document.getElementById(tablename) ;\n if (!table) return ;\n var rows = table.rows ;\n if (rows.length < number_of_rows) number_of_rows = rows.length ;\n var now = (new Date()).getTime() ;\n var id ;\n // add2log(pgm + 'number_of_rows = ' + number_of_rows) ;\n for (i=rows.length-number_of_rows ; i < rows.length ; i++) {\n id = 'afe-' + now + '-' + i ;\n rows[i].id = id;\n ajax_flash(id) ;\n } // for\n } // ajax_flash_new_table_rows", "title": "" }, { "docid": "ead6f1f52ef14b673cddac7e35c45931", "score": "0.5373906", "text": "function ajax_flash_new_table_rows (tablename, number_of_rows)\n{\n var pgm = 'ajax_flash_new_table_rows: ' ;\n // add2log(pgm + 'table_name = ' + tablename + ', number_of_rows = ' + number_of_rows) ;\n var table = document.getElementById(tablename) ;\n if (!table) return ;\n var rows = table.rows ;\n if (rows.length < number_of_rows) number_of_rows = rows.length ;\n var now = (new Date()).getTime() ;\n var id ;\n // add2log(pgm + 'number_of_rows = ' + number_of_rows) ;\n for (i=rows.length-number_of_rows ; i < rows.length ; i++) {\n id = 'afe-' + now + '-' + i ;\n rows[i].id = id\n ajax_flash(id) ;\n } // for\n} // ajax_flash_new_table_rows", "title": "" }, { "docid": "63f028c51d5c12ca1c0456abf46c4a1c", "score": "0.5366222", "text": "function appendRow() {\n table.append(\"<tr></tr>\");\n}", "title": "" }, { "docid": "51c773a10decb8e6e014ac643781fb40", "score": "0.53643364", "text": "function insertRow(row) {\n for (const name of Object.getOwnPropertyNames(row)) {\n if (row[name] === '') {\n row[name] = undefined;\n }\n }\n table.insert(row);\n if (++count % 1000 === 0) {\n const end = new Date();\n console.log(`Processed ${count} rows in ${(end.getTime() - start.getTime()) / 1000}s`);\n }\n}", "title": "" }, { "docid": "75f39967dc17a858499e377ee2607b3c", "score": "0.5356199", "text": "function createItemRows(listOfItems){\n // if local storage has rows, populate based on that\n if (localStorage.getItem('rows')) {\n $('#tableRows').html(localStorage.getItem('rows'));\n\n // enable popover on item cells\n $('[data-toggle=\"popover\"]').popover({\n placement : 'right',\n trigger: 'click'\n });\n // otherwise, build the rows from scratch using buildItemRow function\n } else {\n listOfItems.forEach(item => buildItemRow(item)) \n } \n\n $('input[type=\"checkbox\"]').click( function(){\n if ($(this).prop(\"checked\") == true){\n let row = this.closest(\"tr\")\n $(row).detach() \n }\n // saves table rows to local storage\n var rows = $('#tableRows').html();\n localStorage.setItem(\"rows\", rows);\n })\n \n }", "title": "" }, { "docid": "cfe19d839a58ef5616d343daccfc2c61", "score": "0.5349707", "text": "function displayCart()\n{\n var total = 0;\n var output = \"<table class ='table table-hover'>\";\n\n //check to see if the cart is empty \n if (sessionStorage.length == 0)\n {\n document.getElementById(\"cart\").innerHTML = \"<h3>Cart is empty!</h3>\";\n document.getElementById(\"total\").innerHTML = \"<h3> TOTAL: \" + total + \"</h3>\";\n }\n else\n {\n output += \"<tr><th> Image </th><th>Name</th><th> Price</th><th>Delete</th>\"; //header row\n\n for (var x = 0; x < sessionStorage.length; x++)\n {\n var key = sessionStorage.key(x); //get key\n output += \"<tr><td><img src='images/img\"+ getID(key) +\".jpg' width ='20px' height='20px'></td>\"; //image of item\n output += \"<td>\" + key + \"</td><td>\" + sessionStorage.getItem(key) + \"</td>\"; //get the name and price\n output += \"<td><input type = 'button' class = 'btn btn-primary' value='Delete' onclick ='remove(\\\"\" + key + \"\\\")'></td></tr>\"; //get delete button and configure arg for remove function\n total += parseFloat(sessionStorage.getItem(key));\n }\n\n document.getElementById(\"cart\").innerHTML = output;\n document.getElementById(\"total\").innerHTML = \"<h3> TOTAL: \" + total.toFixed(2) + \"</h3>\";\n }\n\n}", "title": "" }, { "docid": "41665f83d6bdcb6544a05586a1881512", "score": "0.5341503", "text": "function insertUserToTable(index, table, user) {\n var row = table.insertRow(-1);\n var cellIndex = row.insertCell(0);\n var cellName = row.insertCell(1);\n var cellTable = row.insertCell(2);\n\n cellIndex.innerHTML = index;\n cellName.innerHTML = user.name;\n cellTable.innerHTML = user.table;\n}", "title": "" }, { "docid": "671a0abc742f52ae82121d433b68d406", "score": "0.53406394", "text": "function renderTable() {\n var tbody = document.getElementById(\"tableBody\")\n for (let i = 0; i < localStorage.length; i++) {\n var userName = localStorage.key(i)\n var userScore = localStorage.getItem(userName)\n tbody.insertAdjacentHTML('afterbegin', '<tr class=\"scores\"><td>' + userName + ' - ' + userScore + '</td></tr>')\n console.log(username)\n }\n}", "title": "" }, { "docid": "288d1bf3ca389f63143c45427145acb0", "score": "0.53289115", "text": "function add_item_to_order(id, price) {\n // console.log(id.id)\n let get_order = JSON.parse(sessionStorage.getItem('order'))\n let display_order = document.querySelector('order_modal');\n let ordered_items = []\n let item_objects = []\n\n let item_name = id.id\n let quantity = 1; // Increment quantity instead if item in order already\n let item_price = price\n // Create an order item when clicking add order\n item = {\n 'name': item_name,\n 'quantity': quantity,\n 'price': item_price\n }\n\n for (let i = 0;i < get_order.items.length;i++) {\n if (get_order.items[i].name==id.id) {\n get_order.items[i].quantity = parseInt(get_order.items[i].quantity) + 1;\n sessionStorage.setItem('order', JSON.stringify(get_order))\n current_order()\n return\n } else {\n ordered_items.push(get_order.items[i].name)\n item_objects.push(get_order.items[i])\n }\n }\n\n // console.log(\"Adding item to order...\")\n // When clicking 'order' on a menu item, it should add that item to the menu-modal which users can view\\\n // Order needs to be persistent and editable during a session\n\n let item_names = ordered_items.name\n let ordered_quantity = document.getElementsByClassName(\"quantity\")\n\n // Create a row to add new item to table\n row = document.createElement('tr')\n\n // Push new item to current order (Console.log to check)\n get_order.items.push(item)\n sessionStorage.setItem('order', JSON.stringify(get_order))\n\n order_table = document.getElementsByClassName('table')[0]\n order_table.append(row)\n current_order()\n}", "title": "" }, { "docid": "63dd6b1c0724b5fcf9e38dadf7267e6b", "score": "0.53286123", "text": "insertarCarrito(producto){\n const row = document.createElement('tr');\n row.innerHTML = `\n <td>\n <img src=\"${producto.imagen}\" width=100>\n </td>\n <td>${producto.titulo}</td>\n <td>${producto.precio}</td>\n <td>\n <a href=\"#\" class=\"borrar-producto fas fa-times-circle\" data-id=\"${producto.id}\"></a>\n </td>\n `;\n listaProductos.appendChild(row);\n this.guardarProductosLocalStorage(producto);\n }", "title": "" }, { "docid": "b9a9e5f3cb610359df1ca83d187c671e", "score": "0.53177434", "text": "function addNewStepRowTable() {\n\tcloneStepRowTable();\n\tresetStepLastRowTable();\n}", "title": "" }, { "docid": "d6447064a9767ca2b6b6883cbb3b08fd", "score": "0.5316342", "text": "function AddAllJourneysToTable(response) {\n console.log(response);\n var tb = document.getElementById(\"journeysTable\");\n while (tb.rows.length > 1) {\n tb.deleteRow(1);\n }\n for (i = 0; i < response.length; i++) {\n if (response[i].Journey_Car.CarOwner.User_ID != sessionStorage.getItem(\"currentUser\")) {\n var newRow = document.getElementById(\"journeysTable\").insertRow(1);\n newRow.setAttribute(\"id\", response[i].Journey_ID);\n newRow.setAttribute(\"style\", \"cursor:pointer;\");\n newRow.setAttribute(\"class\", \"table-row\");\n newRow.setAttribute(\n \"onclick\",\n \"openHomePagePopUp('journeyDetailsPopUp');ShowGeneralJourneyDetailsOnPopUp('\" +\n response[i].Journey_ID +\n \"')\"\n );\n var dateTime = newRow.insertCell(0);\n var depature = newRow.insertCell(1);\n var destination = newRow.insertCell(2);\n var numSeats = newRow.insertCell(3);\n dateTime.innerHTML = response[i].Departure_Time.replace(\"T\", \" \").substring(\n 0,\n response[i].Departure_Time.length - 3\n );\n for (j = 0; j < response[i].Journey_Checkpoints.length; j++) {\n if (response[i].Journey_Checkpoints[j].Type == \"departure\") {\n depature.innerHTML = response[i].Journey_Checkpoints[j].Location;\n }\n if (response[i].Journey_Checkpoints[j].Type == \"destination\") {\n destination.innerHTML = response[i].Journey_Checkpoints[j].Location;\n }\n }\n numSeats.innerHTML = response[i].Available_Seats;\n }\n else {\n ShowNoJourney();\n }\n }\n}", "title": "" }, { "docid": "f4510ca17f685c61f7095aff635895a0", "score": "0.5316008", "text": "function fillSavingsTable() {\n var table = document.getElementById('savings-table');\n var tbody = table.lastElementChild;\n\n var _iterator3 = _createForOfIteratorHelper(userslist),\n _step3;\n\n try {\n for (_iterator3.s(); !(_step3 = _iterator3.n()).done;) {\n var user = _step3.value;\n var tr = document.createElement('tr');\n tr.appendChild((0,_Utilities__WEBPACK_IMPORTED_MODULE_1__.createTdata)(user.id));\n tr.appendChild((0,_Utilities__WEBPACK_IMPORTED_MODULE_1__.createTdata)(user.username));\n tr.appendChild((0,_Utilities__WEBPACK_IMPORTED_MODULE_1__.createTdata)((0,_Utilities__WEBPACK_IMPORTED_MODULE_1__.currencyFormat)(user.balance)));\n tbody.appendChild(tr);\n }\n } catch (err) {\n _iterator3.e(err);\n } finally {\n _iterator3.f();\n }\n}", "title": "" }, { "docid": "c8b0042b06bb1307206dfd0157423483", "score": "0.5314397", "text": "function mostrarProductos (){\r\n let rows = \"\";\r\n\r\n for (let index = 0; index < producto.length; index++) {\r\n \r\n rows +='<tr>'\r\n rows += '<td>' + producto[index].idProducto + '</td>'\r\n rows += '<td>' + producto[index].idNombreP +'</td>'\r\n rows+= '<td>' + producto[index].idPrecio +'</td>'\r\n rows += '<td>' + producto[index].idCantidad + '</td>'\r\n rows += '<td>' + producto[index].idFecha + '</td>'\r\n rows += '<td>' + producto[index].idObservaciones + '</td>'\r\n rows +='</tr>'\r\n }\r\n\r\n document.getElementById('tabla').innerHTML = rows;\r\n\r\n localStorage.setItem('mostarProductos', JSON.stringify(proveedor ))\r\n \r\n}", "title": "" }, { "docid": "5b777079dc746dd4549c71f87833eb00", "score": "0.53105885", "text": "function createNewRow(posts) {\n // var date = moment(posts.created_at).format('MM/DD/YYYY');\n var tBody = $(\"tbody\")\n var tRow = $(\"<tr>\").addClass(\"jobRow\")\n var titleTd = $(\"<td>\").text(posts.jobTitle)\n var starTd = $(\"<td id='\" + posts.id + \"'>\")\n var starbtn = $(\"<p>\", {\n class: \"checkedStar\",\n \"data-toggle\": \"tooltip\",\n \"data-placement\": \"left\",\n \"title\": \"Click to unfavorite and remove from list\",\n on: {\n click: function() {\n // call function to remove from the favorites list. delete post.id\n var unselectedJob = $(this).parent().attr(\"id\");\n\n var currentSaved = localStorage.getItem(\"theirJobs\");\n\n console.log(currentSaved);\n\n savedArray = JSON.parse(\"[\" + currentSaved + \"]\");\n\n var index = savedArray.indexOf(parseInt(unselectedJob));\n\n if (index > -1) {\n savedArray.splice(index, 1);\n }\n\n localStorage.setItem(\"theirJobs\", savedArray);\n console.log(\"These should be different\")\n\n var data = {\n newList: localStorage.getItem(\"theirJobs\"),\n id: localStorage.getItem(\"id\")\n };\n\n $.ajax({\n method: \"PUT\",\n url: \"/api/users/star\",\n data: data\n }).then(function () {\n console.log(\"Check the DB and terminal\");\n });\n }\n }\n });\n starTd.append(starbtn)\n var companyTd = $(\"<td>\").text(posts.companyName)\n var descriptionTd = $(\"<td>\").text(posts.jobDescription).addClass(\"description-td overflow\")\n var viewbtn = $(\"<td>\")\n // var btnMap = $('<input />', {\n // type: \"button\",\n // value: \"Map\",\n // class: \"btn-viewPost\",\n // \"data-toggle\": \"modal\",\n // \"data-target\": \"#viewMapMarker\",\n // on: {\n // click: function() {\n // // console.log ( posts.id );\n // displayMap(posts.id)\n // }\n // }\n // })\n var btn = $('<input />', {\n type: \"button\",\n value: \"View\",\n class: \"btn-viewPost\",\n \"data-toggle\": \"modal\",\n \"data-target\": \"#viewJobPostInfo\",\n on: {\n click: function() {\n // console.log ( posts.id );\n displayPost(posts.id)\n }\n }\n })\n // viewbtn.append(btnMap)\n viewbtn.append(btn)\n // var applybtn = $(\"<td>\").text(\"View\").addClass(\"btn-apply\").attr(\"id\", \"applyBtn\")\n tRow.append(titleTd, starTd, companyTd, descriptionTd, viewbtn)\n tBody.append(tRow);\n }", "title": "" }, { "docid": "ba01278c1d053238bcac184f7b741397", "score": "0.52998644", "text": "function insertNewRow() {\n const inputFields = document.getElementsByClassName('inputField');\n const appointmentTable = document.getElementById('appointmentTable');\n const tableRowCount = appointmentTable.rows.length;\n const row = appointmentTable.insertRow(tableRowCount);\n\n for (let i = 0; i < 7; i++) {\n var cell = row.insertCell(i);\n cell.innerHTML = inputFields[i].value;\n }\n\n}", "title": "" }, { "docid": "c128236d2b18688ee6ceac9050b58075", "score": "0.52965534", "text": "function addRows() {\n \n}", "title": "" }, { "docid": "f0c96b2d976ab5cf7ba1d234e1d3bcac", "score": "0.52891254", "text": "function addCartInfo(cart) {\n sessionStorage.setItem(\"cart\", JSON.stringify(cart)); \n }", "title": "" }, { "docid": "2f3a8433c2636632913c9d83470d1f0a", "score": "0.5284414", "text": "function confirmationMsg(idTabela) {\r\n if(sessionStorage.getItem(\"num_pedidos\") != null && sessionStorage.getItem(\"num_pedidos\") != \"\") {\r\n var num = parseInt(sessionStorage.getItem(\"num_pedidos\")) + lista_pro.length;\r\n sessionStorage.setItem(\"num_pedidos\", num);\r\n var int = Math.floor(num/5);\r\n if(sessionStorage.getItem(\"inteiro\") < int) {\r\n var inteiro = int + 1;\r\n alert(\"Agora os seus likes valem por \"+inteiro);\r\n } \r\n sessionStorage.setItem(\"inteiro\", int);\r\n }\r\n else {\r\n sessionStorage.setItem(\"num_pedidos\", lista_pro.length);\r\n var int = Math.floor(lista_pro.length/5);\r\n if(sessionStorage.getItem(\"inteiro\") == null && int >= 1) {\r\n var inteiro = int + 1;\r\n alert(\"Agora os seus likes valem por \"+inteiro);\r\n }\r\n sessionStorage.setItem(\"inteiro\", int);\r\n }\r\n \r\n var tab = document.getElementById(idTabela);\r\n var row_numb = tab.rows.length;\r\n if (row_numb > 0) {\r\n alert('Pedido efetuado com sucesso!');\r\n location.href=\"historico.html\";\r\n storeArray();\r\n deleteList(idTabela);\r\n }\r\n}", "title": "" }, { "docid": "4788714da6e86287a822bdca09ec2192", "score": "0.52735806", "text": "async function populateTable(newPage) {\n table.innerHTML = \"\";\n let startPosition = (newPage - 1) * entriesPerPage;\n let newArray = currentAssignmentArray.slice(startPosition, startPosition + 5);\n\n // Loop through sessionData\n for(let i = 0; i < newArray.length; i++){\n let obj = newArray[i];\n // Create a row entry for each session\n let tr = document.createElement('tr');\n\n // Create a column for the session id and append the it to the row\n let td_id = document.createElement('td');\n let sessionID = obj.data.assignmentID\n td_id.innerHTML = sessionID;\n tr.appendChild(td_id);\n\n // Create a column for the latest session time and append it to the row\n let td_time = document.createElement('td');\n let sessionTime = obj.data.sessionTime;\n sessionTime = sessionTime.seconds * 1000;\n sessionTime = new Date(sessionTime);\n td_time.innerHTML = sessionTime.toLocaleString(navigator.language);\n tr.appendChild(td_time);\n\n // Create a column for the parameters\n let td_params = document.createElement('td');\n // Grab the parameters from obj.data\n let parameters = obj.data.parameters;\n let fbt = \"\";\n if (parameters.feedback == \"true\") {\n\n fbt = \"On\"\n } else {\n fbt = \"Off\"\n }\n // Fill in the text with parameter and append the column to the row\n td_params.innerHTML = parameters.bpm + \" BPM, \" + parameters.soundOnTime + \" On, \" + parameters.soundOffTime + \" Off, \" + parameters.cycles + \" Cycles, Feedback \" + fbt;\n tr.appendChild(td_params);\n\n // Create checkbox\n let td_checkbox = document.createElement('td');\n let label = document.createElement('label');\n let checkbox = document.createElement('input');\n let span = document.createElement('span');\n checkbox.type = \"checkbox\";\n checkbox.addEventListener('input', checkCheckedArray);\n if(checkedArray[i + (currentPage - 1) * entriesPerPage]) {\n checkbox.checked = true;\n }\n label.appendChild(checkbox);\n label.appendChild(span);\n td_checkbox.appendChild(label);\n tr.appendChild(td_checkbox);\n table.appendChild(tr);\n\n // Remove the disabled property for the select all button once table is populated\n let selectBtn = document.querySelector(\"#select\");\n selectBtn.classList.remove(\"disabled\");\n }\n createPagination();\n}", "title": "" }, { "docid": "64b312a3f5b61e24f08b22a7dfca7469", "score": "0.5258991", "text": "function datosUsuarioSession() {\n let nombreUsuario = document.getElementById('usuario-sesion').value;\n let idUsuario= obtenerIdUsuario('usuarios',nombreUsuario);\n\n const usuarioSession={\n nombreUsuario,\n idUsuario\n };\n const usuariosSession = guardarSession('usuario_session',usuarioSession);\n }", "title": "" }, { "docid": "3c22618c6dbd2ba67108377b4bf3a7bf", "score": "0.5250439", "text": "function addPaymentDetailsToTable(){\r\n\tif(document.getElementById(\"paymentDetailsTableHead\").rows.length>0){\r\n\t\t\r\n\t}else{\r\n\t\ttableHeader();// ADDING TABLE HEADER ROW WHEN NO ROWS ARE PRESENT IN HEADER SECTION\r\n\t}\r\n\t\r\n\tvar paymentTableDetails = document.getElementById(\"paymentDetailsTableBody\");\r\n\tvar rows = paymentTableDetails.rows;\r\n\tvar rowLength = rows.length;\r\n\t\t\r\n\tvar newRow = paymentTableDetails.insertRow(rowLength);\r\n\tvar cell1 = newRow.insertCell(0);\r\n\tvar cell2 = newRow.insertCell(1);\r\n\tvar cell3 = newRow.insertCell(2);\r\n\tvar cell4 = newRow.insertCell(3);\r\n\tvar cell5 = newRow.insertCell(4);\r\n\t\r\n\tcell1.innerHTML = paymentDetails[0];\r\n\tcell2.innerHTML = paymentDetails[1];\r\n\tcell3.innerHTML = paymentDetails[2];\r\n\tcell4.innerHTML = \"<img src='../property/img/edit.png' alt='Edit' onclick='editRow(this)'>\";\r\n\tcell5.innerHTML = \"<img src='../property/img/delete.png' alt='Edit' onclick='deleteRow(this)'>\";\r\n\t\r\n\tcell4.className = \"text-center\";\r\n\tcell5.className = \"text-center\";\r\n\t\r\n}", "title": "" }, { "docid": "237d3181c229261a40206b8ab2316b25", "score": "0.523817", "text": "function initializeRows() {\n $userContainer.empty();\n var rowsToAdd = [];\n for (var i = 0; i < users.length; i++) {\n rowsToAdd.push(createNewRow(users[i]));\n }\n $userContainer.prepend(rowsToAdd);\n }", "title": "" }, { "docid": "9d7c63debff79dbc6b3bec17b999aac3", "score": "0.5227927", "text": "saveAndSetSessions(sessionList) {\n this.saveSessions(this.state.exercise.title, sessionList);\n this.setState({sessions:sessionList});\n }", "title": "" }, { "docid": "6b336ee31c89ab6d5318599af618a5dd", "score": "0.52267045", "text": "function addNewTableRow(table) {\n var newRow = document.createElement(\"tr\");\n newRow.innerHTML = table.children[0].innerHTML;\n \n if(newRow.children[0].children[1].getAttribute(\"name\") === \"malts[0].maltName\") {\n maltsRows++;\n newRow.children[0].children[1].setAttribute(\"id\", \"malts\"+maltsRows+\".maltName\");\n newRow.children[0].children[1].setAttribute(\"name\", \"malts[\"+maltsRows+\"].maltName\");\n newRow.children[0].children[1].setAttribute(\"value\", \"\");\n newRow.children[1].children[1].setAttribute(\"id\", \"malts\"+maltsRows+\".maltWeight\");\n newRow.children[1].children[1].setAttribute(\"name\", \"malts[\"+maltsRows+\"].maltWeight\");\n newRow.children[1].children[1].setAttribute(\"value\", \"\");\n \n console.log(newRow.innerHTML);\n }\n\n if(newRow.children[0].children[1].getAttribute(\"name\") === \"hops[0].hopName\") {\n hopsRows++;\n newRow.children[0].children[1].setAttribute(\"id\", \"hops\"+hopsRows+\".hopName\");\n newRow.children[0].children[1].setAttribute(\"name\", \"hops[\"+hopsRows+\"].hopName\");\n newRow.children[0].children[1].setAttribute(\"value\", \"\");\n newRow.children[1].children[1].setAttribute(\"id\", \"hops\"+hopsRows+\".hopWeight\");\n newRow.children[1].children[1].setAttribute(\"name\", \"hops[\"+hopsRows+\"].hopWeight\");\n newRow.children[1].children[1].setAttribute(\"value\", \"\");\n newRow.children[2].children[1].setAttribute(\"id\", \"hops\"+hopsRows+\".hopBoilTime\");\n newRow.children[2].children[1].setAttribute(\"name\", \"hops[\"+hopsRows+\"].hopBoilTime\");\n newRow.children[2].children[1].setAttribute(\"value\", \"\");\n console.log(newRow.innerHTML);\n }\n\n if(newRow.children[0].children[1].getAttribute(\"name\") === \"additions[0].additionName\") {\n additionsRows++;\n newRow.children[0].children[1].setAttribute(\"id\", \"additions\"+additionsRows+\".additionName\");\n newRow.children[0].children[1].setAttribute(\"name\", \"additions[\"+additionsRows+\"].additionName\");\n newRow.children[0].children[1].setAttribute(\"value\", \"\");\n newRow.children[1].children[1].setAttribute(\"id\", \"additions\"+additionsRows+\".additionTime\");\n newRow.children[1].children[1].setAttribute(\"name\", \"additions[\"+additionsRows+\"].additionTime\");\n newRow.children[1].children[1].setAttribute(\"value\", \"\");\n newRow.children[2].children[0].setAttribute(\"id\", \"additions\"+additionsRows+\".additionUse\");\n newRow.children[2].children[0].setAttribute(\"name\", \"additions[\"+additionsRows+\"].additionUse\");\n newRow.children[2].children[0].setAttribute(\"value\", \"\");\n console.log(newRow.innerHTML);\n }\n table.appendChild(newRow);\n }", "title": "" }, { "docid": "80a3e1d3d9c199dc61f19759604a0669", "score": "0.5226702", "text": "function onClick()\n{\n window.sessionStorage.setItem(\"x\", document.getElementById(\"x\").value);\n window.sessionStorage.setItem(\"y\", document.getElementById(\"y\").value);\n window.sessionStorage.setItem(\"space\", document.getElementById(\"space\").value);\n window.sessionStorage.setItem(\"paragraphs\", document.getElementById(\"paragraphs\").value);\n window.location = \"../display/\";\n}", "title": "" }, { "docid": "43c483c22632d76542d9114feef87415", "score": "0.52215004", "text": "function addUserInTable(user) {\n var userTr = mountTr(user); //monta a TR do usuario\n var table = document.querySelector(\"#table-users\"); //busca tabela de usuarios\n table.appendChild(userTr); //adiciona nova linha a tabela de usuarios\n}", "title": "" }, { "docid": "61ee0c369ab488d4394192cf3a8a2207", "score": "0.5216472", "text": "function generateStudentHtmlTable(student) {\n let table = document.getElementById(\"allStudentTable\");\n table.innerHTML = \"\";\n for (let i = 0; i < student.length; i++) {\n let row = table.insertRow(i);\n let status = student[i].status;\n let stage = student[i].registrationState;\n switch (status) {\n case 'terminated':\n row.setAttribute(\"class\", \"danger\");\n break;\n case 'dropped':\n row.setAttribute(\"class\", \"warning\");\n break;\n case 'inactive':\n row.setAttribute(\"class\", \"info\");\n break;\n }\n if (stage === \"finished\") {\n row.setAttribute(\"class\", \"success\");\n }\n let cell0 = row.insertCell(0);\n let cell1 = row.insertCell(1);\n let cell2 = row.insertCell(2);\n let cell3 = row.insertCell(3);\n let cell4 = row.insertCell(4);\n let cell5 = row.insertCell(5);\n let cell6 = row.insertCell(6);\n cell0.innerHTML = \"<td>\" + (i + 1) + \"</td>\";\n cell1.innerHTML = \"<td>\" + student[i].studentID + \"</td>\";\n cell2.innerHTML = \"<td>\" + student[i].nickname + \"</td>\";\n cell3.innerHTML = \"<td>\" + student[i].firstname + \"</td>\";\n cell4.innerHTML = \"<td>\" + student[i].lastname + \"</td>\";\n cell5.innerHTML = \"<td>\" + ((student[i].inCourse) ? \"✔\" : \"✖\") + \"</td>\";\n cell6.innerHTML = \"<td>\" + ((student[i].inHybrid) ? \"✔\" : \"✖\") + \"</td>\";\n\n let clickHandler = (row) => () => {\n //noinspection SpellCheckingInspection\n writeCookie(\"monkeyWebAdminAllstudentSelectedUser\", row.getElementsByTagName(\"td\")[1].innerHTML);\n //noinspection SpellCheckingInspection\n self.location = \"/adminStudentprofile\";\n };\n row.onclick = clickHandler(row);\n }\n}", "title": "" }, { "docid": "1831e89dfdabff521f62568ab3c4eefa", "score": "0.52131075", "text": "function insertTable() {\n var numCols, numRows, toInsert, i, j;\n numCols = $('#kl_table_num_cols').val();\n if (numCols === '') {\n numCols = 2;\n }\n numRows = $('#kl_table_num_rows').val();\n if (numRows === '') {\n numRows = 2;\n }\n toInsert = '<table>';\n if ($('.kl_table_include_header').prop('checked')) {\n numRows = numRows - 1;\n toInsert += '<thead><tr>';\n for (i = 0; i < numCols; i++) {\n toInsert += '<th></th>';\n }\n toInsert += '</tr></thead>';\n }\n toInsert += '<tbody>';\n for (i = 0; i < numRows; i++) {\n toInsert += '<tr>';\n for (j = 0; j < numCols; j++) {\n toInsert += '<td></td>';\n }\n toInsert += '</tr>';\n }\n toInsert += '</tbody></table>';\n tinyMCE.execCommand('mceInsertContent', false, toInsert);\n }", "title": "" }, { "docid": "2e6b92b704807c32207151d416439e8f", "score": "0.52097857", "text": "addRow() {\n\tlet count = this.state.source[0].columns.length;\n\tlet newColumns = Array.apply(null, Array(count))\n\t\t\t .map(x => \"\");\n\n\tlet newRow = {\n\t key: Table.nextKey(),\n\t isNewRow: true,\n\t mode: RowMode.Edit,\n\t columns: newColumns\n\t};\n\t\n\tlet newTable = this.state.source\n\t\t\t .slice()\n\t\t\t .concat([newRow]);\n\t\n\tthis.setState({\n\t source: newTable,\n\t addingNew: true\n\t});\n }", "title": "" }, { "docid": "75c99d1989ff0dde2370ff333fdb03ed", "score": "0.5206158", "text": "function SaveDataToLocalStorage(value) {\n const session = this.getsession();\n\n session.push(value);\n\n localStorage.setItem(\"session\", JSON.stringify(session));\n}", "title": "" }, { "docid": "bca687db06d5fe9390b4eb0b8f25473c", "score": "0.5205718", "text": "function saveTestSession(tx){\n //alert('recording session...' + sessionUsersList[0])\n \n var fields = '\"date_taken\",\"score\",\"total\",\"test_id\",\"worker_id\"';\n var values = '\"' + getNowDate() + '\",' + //date taken\n '\"' + parseInt($('#scorecount').val()) + '\",' + //score\n '\"' + globalObj.questionIDList.length + '\",' + //total number of questions in test\n '\"' + globalObj.testID + '\",' + //test id\n '\"' + globalObj.loggedInUserID + '\"'; //logged in user id - test taker\n \n DAO.save(tx, 'cthx_test_session', fields, values); \n \n \n //queue last inserted row for SMS sending \n //set time out 500 to wait for the update to complete\n setTimeout(function(){\n var query = 'SELECT session_id FROM cthx_test_session ORDER BY session_id DESC LIMIT 1';\n globalObj.db.transaction(function(tx){\n tx.executeSql(query,[],function(tx,result){\n if(result.rows.length>0){\n var row = result.rows.item(0);\n queueTestSMS(tx, row['session_id']); \n }\n });\n });\n },500);\n}", "title": "" }, { "docid": "66ae98654c06d4a93968481ec6a56e20", "score": "0.52035284", "text": "tableAdd(data){\n // in case what we want is actualy editing a paticular row \n if (this.getEditTarget != null){\n // we get that row\n let row = this.getRows.filter( row => row.getId == this.getEditTarget)[0];\n\t\t\t\t\t// we modify its content\n row.setData = data; \n\t\t\t\t\t// then refresh it\n row.hideRow();\n row.showRow(); \n\t\t\t\t\t// then kicking it out of the selection stack \n ISelection = deleteFromArray(ISelection, this.getEditTarget);\n // and turn off the edition flag\n this.setEditTarget = null;\n }\n else{\n\t\t\t\t// when it comes to new data, that's the easy job, we create a new row\n let new_row = new Row(data , this.getIdTracker);\n\t\t\t\t// add it to the table properties\n this.addRow = new_row;\n\t\t\t\t// and show it in the actual table\n new_row.showRow();\n }\n }", "title": "" }, { "docid": "ed09e43a1705582ea93deed9a6bfbb2d", "score": "0.51977104", "text": "function showTable(){\n\nvar myemail=localStorage.getItem(\"email\");\nvar mypswd=localStorage.getItem(\"password\");\nvar mycpswd=localStorage.getItem(\"cpassword\");\n\nlet signInData = [\n { Email: myemail,Password: mypswd,Conform_Password: mycpswd },\n \n \n ];\n\n function generateTableHead(table, data) {\n \n let thead = table.createTHead();\n let row = thead.insertRow();\n for (let key of data) {\n let th = document.createElement(\"th\");\n let text = document.createTextNode(key);\n th.appendChild(text);\n row.appendChild(th);\n }\n }\n function generateTable(table, data) {\n for (let element of data) {\n let row = table.insertRow();\n for (key in element) {\n let cell = row.insertCell();\n let text = document.createTextNode(element[key]);\n cell.appendChild(text);\n }\n }\n }\n let table = document.querySelector(\"table\");\n let data = Object.keys(signInData[0]);\n\n generateTableHead(table, data);\n \n\n generateTable(table, signInData);\n\n}", "title": "" }, { "docid": "0d38e52b87d36825ec378be5d624cd9b", "score": "0.51953375", "text": "function cartPage(event){\n // if the cart button is clicked, add the ID to the storage session\n if (event.target.className === \"cart-button\"){\n addToSessionStorage(event.target.id)\n // console.log(\"Value in sesssion storage is:\", sessionStorage.getItem(\"products\"))\n } \n}", "title": "" }, { "docid": "c67e5d5bacd242d2a45c252217ce8c90", "score": "0.51926285", "text": "function addPlayersTableRow(index, clandata, playerdata) {\r\n let index_ = \"<td>\" + (index + 1) + \"</td>\";\r\n let nickname = \"<td><a href='/user/search/\" + playerdata.nickname + \"' target='_blank'>\" +\r\n playerdata.nickname + \"</a></td>\";\r\n let post = \"<td>\" + clandata.role_i18n + \"</td>\";\r\n let days = \"<td>\" + Math.floor(((new Date()).getTime()/1000 - clandata.joined_at) / 24 / 60 / 60) + \"</td>\";\r\n let battles = \"<td>\" + playerdata.battles + \"</td>\";\r\n let victories= \"<td style='color: \" + playerdata.winrateColor + \";'><b>\" + playerdata.victories + \"</b></td>\";\r\n let wg = \"<td style='color: \" + playerdata.WGcolor + \";'><b>\" + playerdata.wg + \"</b></td>\";\r\n let wn8 = \"<td style='color: \" + playerdata.WN8color + \";'><b>\" + playerdata.WN8 + \"</b></td>\";\r\n\r\n // create a new row in table\r\n $('table#players-table tbody').append(\"<tr></tr>\");\r\n\r\n // add table data to last row which was just created\r\n $('table#players-table tbody tr:last-child').append(\r\n index_, nickname, post, days, battles, victories, wg, wn8);\r\n }", "title": "" }, { "docid": "8e12363c7a0af132a4639db7d523806c", "score": "0.51917297", "text": "function saveToStorage() {\r\n console.log(`2) Saving DOM tableData to storage.`);\r\n window.localStorage.clear();\r\n window.localStorage.setItem(\"tableData\", JSON.stringify(tableData));\r\n console.log(`Done!!\r\n`);\r\n}", "title": "" }, { "docid": "35189103ae7aa145441bdf50966b8972", "score": "0.518773", "text": "function agregarEstudiante(estudiante){\r\n estudiantes.push(estudiante);\r\n \r\n storage.setItem(\"estudiantes\", JSON.stringify(estudiantes));\r\n \r\n var tablaEstudiante = document.getElementById(\"tablaEstudiante\");\r\n \r\n var tr = document.createElement(\"tr\");\r\n var tdNombre = document.createElement(\"td\");\r\n var tdMatricula = document.createElement(\"td\");\r\n var tdIdentificacion = document.createElement(\"td\");\r\n var tdActions = document.createElement(\"td\");\r\n\r\n var btnEditar = document.createElement(\"button\");\r\n btnEditar.className = \"btn btn-primary\"\r\n btnEditar.textContent =\"Editar\";\r\n btnEditar.setAttribute(\"onclick\", \"editarEstudiante(this);\")\r\n btnEditar.setAttribute(\"data-matricula\", estudiante.matricula);\r\n tdActions.appendChild(btnEditar);\r\n \r\n \r\n tdNombre.textContent = estudiante.nombre;\r\n tdMatricula.textContent = estudiante.matricula;\r\n tdIdentificacion.textContent = estudiante.identificacion;\r\n \r\n \r\n tr.appendChild(tdNombre);\r\n tr.appendChild(tdMatricula);\r\n tr.appendChild(tdIdentificacion);\r\n tr.appendChild(tdActions);\r\n\r\n tablaEstudiante.appendChild(tr);\r\n \r\n}", "title": "" }, { "docid": "399c7d49cbd7adfebc18de23a51fd7e2", "score": "0.5185651", "text": "function initializeRows() {\n blogContainer.empty();\n var flashcardsToAdd = [];\n for (var i = 0; i < flashcards.length; i++) {\n flashcardsToAdd.push(createNewRow(flashcards[i]));\n }\n blogContainer.append(flashcardsToAdd);\n }", "title": "" }, { "docid": "91106594a8ce95e46e0042b5f654350b", "score": "0.51756895", "text": "function addToFav(obj) {\n\tvar index = obj.parentNode.parentNode.rowIndex;\n\tvar\tresultBox = document.getElementById(\"resultTable\");\n//Get information from the table\n\tvar sID = resultBox.rows[index].cells[1].innerHTML;\n\tvar sDesc = resultBox.rows[index].cells[2].innerHTML;\n\tvar sURL = resultBox.rows[index].cells[3].innerHTML;\n//Transform it to a gist object\n\tvar newFav = new gistDetail(sID, sDesc, sURL);\n//Add it to the setting \n\tsettings.favorites.push(newFav);\n//Store it to local storage\n\tlocalStorage.setItem('userFavorites', JSON.stringify(settings));\n//Delete the row from the result table\n\tresultBox.deleteRow(index);\n//Add the row to the favorite table\n\tvar\tfavoriteBox = document.getElementById(\"favoriteTable\");\n\tvar rowCount = favoriteBox.rows.length;\n\tvar insertRow = favoriteBox.insertRow(rowCount);\n\tinsertRow.insertCell(0).innerHTML='<input type=\"button\" value = \"Remove from Favorite\" onClick=\"Javacsript:removeFromFav(this)\">';\n\tinsertRow.insertCell(1).innerHTML= sID;\n\tinsertRow.insertCell(2).innerHTML= sDesc;\n\tinsertRow.insertCell(3).innerHTML= sURL;\n}", "title": "" }, { "docid": "752490de6d51f783cb69f0bad46e14b4", "score": "0.5175296", "text": "function store1(prodcts)\n{\n\t\tsessionStorage.currentuser = JSON.stringify(prodcts);\n}", "title": "" }, { "docid": "9fdcb6f51ae5d612d00186df727b6214", "score": "0.5173932", "text": "function loadEndpointSelectionTable() {\n let endpoints = JSON.parse(sessionStorage.getItem('endpoints'));\n let table = document.getElementById('endpoint-selection-table');\n\n\n table.innerHTML = '';\n endpoints.forEach(function(endpoint, index) {\n\n let html = `\n<div class=\"panel panel-default\">\n <div class=\"panel-heading\">\n <h4 style=\"margin: 0px\">\n ${endpoint.node} <small>${endpoint.interface} - ${endpoint.tag}</small>\n <span style=\"float: right;\">\n <span class=\"glyphicon glyphicon-edit\" onclick=\"loadEndpointSelectionModal('${endpoint.node}', ${index})\"></span>\n <span class=\"glyphicon glyphicon-trash\" onclick=\"removeFromEndpointSelectionTable(${index})\"></span>\n </span>\n </h4>\n </div>\n`;\n\n let peeringHTML = '';\n endpoint.peerings.forEach(function(peering, peeringIndex) {\n peeringHTML += `<tr>\n <td>${peering.asn}</td>\n<td>${peering.yourPeerIP}</td>\n<td>${peering.key}</td>\n<td>${peering.oessPeerIP}</td>\n<td><button class=\"btn btn-danger btn-sm\" class=\"form-control\" type=\"button\" onclick=\"deletePeering(${index}, ${peeringIndex})\">&nbsp;<span class=\"glyphicon glyphicon-trash\"></span>&nbsp;</button></td>\n</tr>`;\n });\n\n let bodyHTML = `\n<table class=\"table\">\n <thead>\n <tr><th>Your Peer ASN</th><th>Your Peer IP</th><th>Your BGP Key</th><th>OESS Peer IP</th><th></th></tr>\n </thead>\n <tbody>\n ${peeringHTML}\n <tr id=\"new-peering-form-${index}\">\n <td><input class=\"form-control bgp-asn\" type=\"text\" /></td>\n <td><input class=\"form-control your-peer-ip\" type=\"text\" /></td>\n <td><input class=\"form-control bgp-key\" type=\"text\" /></td>\n <td><input class=\"form-control oess-peer-ip\" type=\"text\" /></td>\n <td><button class=\"btn btn-success btn-sm\" class=\"form-control\" type=\"button\" onclick=\"newPeering(${index})\">&nbsp;<span class=\"glyphicon glyphicon-plus\"></span>&nbsp;</button></td>\n </tr>\n </tbody>\n</table>\n\n</div>\n`;\n\n\n table.innerHTML += html + bodyHTML;\n });\n}", "title": "" }, { "docid": "8d28de5fcdadce6b22a42c89c12854b1", "score": "0.5166792", "text": "function saveHiscoreTable() {\n localStorage.snakeHiscore = JSON.stringify(hiscore);\n }", "title": "" }, { "docid": "77360dc73b016dcf9741e9be326491b3", "score": "0.5147284", "text": "function LeerLocalstorage(){\n let platillosLS;\n platillosLS = obtenerPlatillosLocalStorage();\n platillosLS.forEach(function(platillo){\n const row =document.createElement('tr');\n row.innerHTML= `\n <td>\n <img src=\"${platillo.imagen}\"width=100\">\n </td>\n <td>${platillo.titulo}</td>\n <td>${platillo.precio}</td>\n <td><a href=\"#\" class=\"borrar-platillo\" data-id=\"${platillo.id}\">X</a>\n </td>\n `;\n listaPlatillos.appendChild(row);\n });\n }", "title": "" }, { "docid": "a5aa115fb2c7fa2e3d5742d832d63531", "score": "0.5144081", "text": "function saveCart() {\n sessionStorage.setItem(SESSION_STORAGE_KEY, JSON.stringify(shoppingCart))\n}", "title": "" }, { "docid": "a020caa687779c6e80bbc97fe2736a53", "score": "0.5140503", "text": "function getTable() {\n // check browser support\n if (typeof (Storage) === \"undefined\") {\n return;\n }\n const table = document.getElementById(\"myTable\");\n\n let storageList = JSON.parse(localStorage.getItem('table'));\n\n // check for empty list\n if (!storageList) {\n console.log(\"Empty List\");\n return;\n }\n\n // if item already exists, don't load it again\n for (let i = 1; i < table.rows.length; i++) {\n document.getElementById('myTable').deleteRow(i);\n }\n\n // restore table\n for (let i = 1; i < storageList.length; i++) {\n if (storageList[i] == null) {\n continue;\n }\n const row = table.insertRow(-1); // add rows to the end of the table\n const item = row.insertCell(0);\n const price = row.insertCell(1);\n // default cell descriptions\n item.innerHTML = storageList[i][0];\n price.innerHTML = storageList[i][1];\n\n // if (item.innerHTML && price.innerHTML) {\n // console.log('item.innerHTML && price.innerHTML', item.innerHTML, price.innerHTML);\n // console.log('blank row ', i);\n // }\n\n // leave blank instead of outputting 'NaN'\n if (isNaN(parseInt(price.innerHTML))) {\n price.innerHTML = '';\n }\n\n // Make new rows editable\n item.setAttribute('contenteditable', 'true');\n item.setAttribute('oninput', 'saveList()');\n\n price.setAttribute('oninput', 'saveList()');\n price.setAttribute('contenteditable', 'true');\n price.setAttribute('oninput', 'sumColumn()');\n }\n}", "title": "" }, { "docid": "72eacb16b261c75aadcd6dc9b38aed2e", "score": "0.5136682", "text": "leerLocalStorageCompra(){\n let productosLS;\n productosLS = this.obtenerProductosLocalStorage();\n productosLS.forEach(function (producto){\n const row = document.createElement('tr');\n row.innerHTML = `\n <td>\n <img src=\"${producto.imagen}\" width=100>\n </td>\n <td>${producto.titulo}</td>\n <td>${producto.precio}</td>\n <td>\n <input type=\"number\" class=\"form-control cantidad\" min=\"1\" value=${producto.cantidad}>\n </td>\n <td id='subtotales'>${producto.precio * producto.cantidad}</td>\n <td>\n <a href=\"#\" class=\"borrar-producto fas fa-times-circle\" style=\"font-size:30px\" data-id=\"${producto.id}\"></a>\n </td>\n `;\n listaCompra.appendChild(row);\n });\n }", "title": "" }, { "docid": "3d9d1a8d481bffeba6dee54d582dfe50", "score": "0.5128813", "text": "function drawHistoryTable(){\n if(localStorage.length){\n $('#historyTable').html('<tr><th class=\"hidden\">Local Key</th><th class=\"hideInSmall\">Food Id</th><th>Food Name</th><th>Action</th><th>Nutrients (Click Tag to Check Nutrition)</th></tr>')\n for (var i = 0; i < localStorage.length; i++){\n $('#historyTable').append('<tr><td class=\"hidden\"><p id=\"localKey\">'+localStorage.key(i)+'</p></td>'+localStorage.getItem(localStorage.key(i))+\"</tr>\");\n }\n btnShowAndHide();\n }else{\n $('#historyTable').html(\"<h3>You haven't saved any food yet. Use the search box above to search and save your food!</h3>\")\n }\n}", "title": "" }, { "docid": "fc615fcaac7f4da3e3718915fa9a7780", "score": "0.51248616", "text": "function prepareTable() {\n let targets = $(\".content-targets\").children();\n arraychosse = [];\n for (let i = 0; i < targets.length; i++) {\n const element = targets.eq(i);\n if (element.hasClass(\"active\")) {\n arraychosse.push(i)\n let TA1 = arraychosse[0];\n let TA2 = arraychosse[1];\n setCookie(\"TABLEROJ1 \", TA1, 1);\n setCookie(\"TABLEROJ2 \", TA2, 1);\n }\n }\n }", "title": "" }, { "docid": "f01c0c58fe0553c54ebb1122b6956606", "score": "0.5124024", "text": "function addReplayTableRowsFragment(replayStorageArray) {\r\n //add the loading indicator to the segment\r\n $('.ui.savedReplays.verticalTabMenu.segment').addClass('loading');\r\n //empty the replays table body so we can add the updated information\r\n $('.ui.celled.replaysTable.table tbody').empty();\r\n //target our table row template first, we only need to find the template once\r\n let targetNode = document.querySelector('.replayTableRowTemplate');\r\n //we need to do more work as we have to save the template in a table, which we don't need, we just want the row\r\n let targetRow = targetNode.querySelector('tr');\r\n //then create a document fragment that we will use as a container for each looped template\r\n let docFrag = document.createDocumentFragment();\r\n\r\n //use for-of loop for easier reading\r\n for (let replay of replayStorageArray) {\r\n //then we make a clone of the row, that will serve the purpose\r\n let tempNode = targetRow.cloneNode(true);\r\n //<td data-label=\"replayName\"></td>\r\n let replayNameNode = tempNode.querySelector('td[data-label=\"replayName\"]');\r\n replayNameNode.textContent = replay.replayName;\r\n //<td data-label=\"replay_recordingProjectName\"></td>\r\n let replayProjectNameNode = tempNode.querySelector('td[data-label=\"replay_recordingProjectName\"]');\r\n replayProjectNameNode.textContent = replay.recordingProjectName;\r\n //<td data-label=\"replay_recordingTestName\"></td>\r\n let replayTestNameNode = tempNode.querySelector('td[data-label=\"replay_recordingTestName\"]');\r\n replayTestNameNode.textContent = replay.recordingTestName;\r\n //<td data-label=\"replayRecordingStartUrl\" style=\"max-width: 150px; overflow: hidden; text-overflow: ellipsis;\"></td>\r\n let replayStartUrlNode = tempNode.querySelector('td[data-label=\"replayRecordingStartUrl\"]');\r\n replayStartUrlNode.textContent = replay.replayRecordingStartUrl;\r\n //any text-overflow elements should have a title with the whole string\r\n replayStartUrlNode.title = replay.replayRecordingStartUrl;\r\n //<td data-label=\"replayAssertionsCount\"></td>\r\n let replayAssertionsLengthNode = tempNode.querySelector('td[data-label=\"replayAssertionsCount\"]');\r\n replayAssertionsLengthNode.textContent = replay.replayEventArray.filter((item) =>\r\n item.hasOwnProperty('assertionId')\r\n ).length;\r\n //<td data-label=\"replayCreated\"></td>\r\n let replayCreatedNode = tempNode.querySelector('td[data-label=\"replayCreated\"]');\r\n replayCreatedNode.textContent = new Date(replay.replayCreated).toLocaleDateString();\r\n //<td data-label=\"replayExecuted\"></td>\r\n let replayExecutedNode = tempNode.querySelector('td[data-label=\"replayExecuted\"]');\r\n //this makes a copy of the replay WITH THE RIGHT RECORDING PARAMETERS to access the formatting functions\r\n replayExecutedNode.textContent = new Replay(replay, replay).printExecutionTime();\r\n //<td data-label=\"replayStatus\"></td>\r\n let replayStatusNode = tempNode.querySelector('td[data-label=\"replayStatus\"]');\r\n //this makes a copy of the replay WITH THE RIGHT RECORDING PARAMETERS to access the formatting functions\r\n replayStatusNode.textContent = new Replay(replay, replay).printStatus();\r\n\r\n let replayShowLink = tempNode.querySelector('.showReplayLink');\r\n replayShowLink.setAttribute('data-replay-id', `${replay.id}`);\r\n let replayEditLink = tempNode.querySelector('.runReplayLink');\r\n replayEditLink.setAttribute('data-replay-id', `${replay.id}`);\r\n let replayDeleteLink = tempNode.querySelector('.deleteReplayLink');\r\n replayDeleteLink.setAttribute('data-replay-id', `${replay.id}`);\r\n //then we need to attach the clone of the template node to our container fragment\r\n docFrag.appendChild(tempNode);\r\n }\r\n\r\n //then after the entire loop has been executed we need to adjust the dom in one hit, avoid performance issues with redraw\r\n //then we find the relevant table, using docuement.querySelector which helpfully returns the first Element within the document that matches the specified selector\r\n let replayTable = document.querySelector('.ui.celled.replaysTable.table tbody');\r\n //then we append the fragment to the table\r\n replayTable.appendChild(docFrag);\r\n //then once all the work has been done remove class\r\n $('.ui.savedReplays.verticalTabMenu.segment').removeClass('loading');\r\n //then add the listeners for the buttons built into the form\r\n addReplayTableButtonListeners();\r\n}", "title": "" }, { "docid": "e4ae65eacd242fa6a86427307b580e08", "score": "0.51154923", "text": "function load_table(){\n for(var i = 0; i < data.length; i++){\n add_tr( $(\"#table\"), data[ i ], i );\n }\n}", "title": "" }, { "docid": "bb18b18104570a08396cf91fa2306588", "score": "0.51127386", "text": "function getPago(data) {\n document.getElementById(\"formaPago-table\").insertRow(-1).innerHTML = `\n <td>${data.formaPago}</td>\n <td>${data.formaPago}</td>\n <td>${data.total}</td>\n <td>${data.plazo}</td>\n <td>${data.unidadTiempo}</td>\n <td> <input type=\"button\" value=\"Delete\" onclick=\"deleteRow(this)\"/> </td>`\n}", "title": "" }, { "docid": "da5e94f0130e4b18cd69b7319396a49f", "score": "0.5110432", "text": "leerLocalStorageCompra(){\r\n let productosLS;\r\n productosLS = this.obtenerProductosLocalStorage();\r\n productosLS.forEach(function (producto){\r\n const row = document.createElement('tr'); // APAREZCAN LOS DATOS \r\n row.innerHTML = `\r\n <td>\r\n <img src=\"${producto.imagen}\" width=100>\r\n </td>\r\n <td>${producto.titulo}</td>\r\n <td>${producto.precio}</td>\r\n <td>${producto.cantidad} </td>\r\n <td id='subtotales'>${producto.precio * \"1\"}</td>\r\n <td>\r\n <a href=\"#\" class=\"borrar-producto fas fa-times-circle\" style=\"font-size:30px\" data-id=\"${producto.id}\"></a>\r\n </td>\r\n `;\r\n listaCompra.appendChild(row);\r\n \r\n \r\n\r\n });\r\n \r\n }", "title": "" }, { "docid": "346fca27740ab7e98846a23dfe0795a3", "score": "0.5108747", "text": "function populateTableRow(tableOutputBody, columnsMetadata, rowIndex) {\n\tvar rowCount = tableOutputBody.rows.length;\n\tvar row = tableOutputBody.insertRow(rowCount);\n\t\n\tfor (var i in columnsMetadata) {\n \tvar cellName = columnsMetadata[i].id;\n \tvar cellNameWithIdx = cellName.substr(0, getNameWoIndexLength(cellName)) + '_' + rowIndex;\n \tvar displayFormat = columnsMetadata[i].displayFormat;\n \tvar value = formatTableValue(displayFormat, sessionStorage[cellNameWithIdx]);\n \tvar type = columnsMetadata[i].type !== undefined && columnsMetadata[i].type !== null && columnsMetadata[i].type.length > 0 ? columnsMetadata[i].type : 'read only';\n \t\n \tvar cell;\n \tif (row.cells.length == 0) {\n cell = document.createElement('td');\n row.appendChild(cell);\n } else {\n cell = row.insertCell(-1);\n }\n \tcell.innerHTML = generateHtmlValue(cellNameWithIdx, value, displayFormat, type);\n \t$(cell).enhanceWithin();\n }\n}", "title": "" }, { "docid": "0ab34a29d0fabb5397ed4f7082bf1c98", "score": "0.5108473", "text": "function addToXpStorage(input) {\n var ssxp1 = sessionStorage.getItem(\"ssxp1\");\n var ssxp2 = sessionStorage.getItem(\"ssxp2\");\n var ssxp3 = sessionStorage.getItem(\"ssxp3\");\n var ssxp4 = sessionStorage.getItem(\"ssxp4\");\n var ssxp5 = sessionStorage.getItem(\"ssxp5\");\n sessionStorage.setItem(\"ssxp5\", ssxp4);\n sessionStorage.setItem(\"ssxp4\", ssxp3);\n sessionStorage.setItem(\"ssxp3\", ssxp2);\n sessionStorage.setItem(\"ssxp2\", ssxp1);\n sessionStorage.setItem(\"ssxp1\", input);\n}", "title": "" }, { "docid": "7826c51f232a74a89944f9906bf517e2", "score": "0.51075906", "text": "function saveNewRow(elements, index) {\n if (!elements || !elements.length) {\n // No new element at this point.\n return;\n }\n\n // Add the row. Make sure page has a rows array.\n viewModel.page.rows || (viewModel.page.rows = []);\n\n var newRow = {\n elements: elements\n };\n\n if (typeof index !== 'undefined') {\n // Add new row above existing.\n viewModel.page.rows.splice(index, 0, newRow);\n } else {\n // Add new row to the end.\n viewModel.page.rows.push(newRow);\n }\n }", "title": "" }, { "docid": "8ddb7865df2b27b330c47886157f1ce0", "score": "0.5107461", "text": "function addOrUpdateRowToTable(opt,tableId,rowId,roleName,tempName,sites,actions,pageOf)\r\n {\r\n var tb = document.getElementById(tableId);\r\n var rows = new Array();\r\n rows = tb.rows;\r\n var noOfRows = rows.length;\r\n\r\n if(pageOf!=null && pageOf==\"pageOfAssignPrivilegePage\")\r\n\t\t\t{\r\n\t\t\t var tempStringSize = 45;\r\n\t\t\t}\r\n\t\t\telse if(pageOf!=null)\r\n\t\t\t{\r\n\t\t\t\tvar tempStringSize = 60;\r\n\t\t\t}\r\n\r\n if(opt==\"addRow\")\r\n {\r\n var row = document.getElementById(tableId).insertRow(noOfRows);\r\n row.setAttribute(\"id\",rowId);\r\n\r\n if(noOfRows%2!=0){\r\n row.className=\"tabletd1\";\r\n }\r\n var chkName=\"chk_\"+noOfRows;\r\n }\r\n else if(opt==\"updateRow\")\r\n {\r\n var row = document.getElementById(rowId);\r\n for(counter=0;counter<row.cells.length;)\r\n {\r\n if(row.cells[counter].getElementsByTagName(\"INPUT\")!=null){\r\n if(row.cells[counter].getElementsByTagName(\"INPUT\")[0]!=null){\r\n if(row.cells[counter].getElementsByTagName(\"INPUT\")[0].nodeName==\"INPUT\"){\r\n chkName=row.cells[counter].getElementsByTagName(\"INPUT\")[0].id;\r\n }\r\n }\r\n }\r\n row.removeChild(row.cells[counter]);\r\n }\r\n row.setAttribute(\"id\",rowId);\r\n }\r\n // first cell\r\n\r\n var aprCheckb=row.insertCell(0);\r\n aprCheckb.className=\"black_ar\";\r\n aprCheckb.width=\"6%\";\r\n sname=\"<input type='checkbox' name='\" + chkName +\"' id='\" + chkName +\"'/>\";\r\n aprCheckb.onclick=function(){enableDeleteButton('summaryTableId','deleteButtonId');} ;\r\n aprCheckb.innerHTML=\"\"+sname;\r\n // Second Cell\r\n\r\n var str=\"\"+sites;\r\n var newSites = \"\" ;\r\n if(str.length>30){\r\n newSites=str.substring(0,27)+\"...\";\r\n }\r\n else{\r\n newSites=str;\r\n }\r\n var aprSites=row.insertCell(1);\r\n aprSites.className=\"black_ar\";\r\n aprSites.width=\"27%\";\r\n // aprSites.innerHTML=\"<div style='word-wrap:break-word;width=24%;'>\"+sites+\"</div>\";\r\n aprSites.innerHTML=\"<span>\"+newSites+\"</span>\";\r\n aprSites.onmouseover=function(){Tip(sites,WIDTH,200);} ;\r\n\r\n //third Cell\r\n var apr=row.insertCell(2);\r\n\t apr.className=\"black_ar\";\r\n\t apr.width=\"22%\";\r\n\t apr.innerHTML=\"<span>\"+tempName+\"</span>\";\r\n\r\n //fourth Cell\r\n var actionString = \"\" + actions;\r\n var newActionsString=\"\";\r\n\r\n if(actionString.length>tempStringSize)\r\n {\r\n newActionsString=actionString.substring(0,(tempStringSize-3))+\"...\";\r\n }\r\n else\r\n {\r\n newActionsString=actionString;;\r\n }\r\n\r\n\r\n var aprActions=row.insertCell(3);\r\n aprActions.className=\"black_ar\";\r\n aprActions.width=\"40%\";\r\n aprActions.innerHTML=\"<span>\"+newActionsString+\"</span>\";\r\n aprActions.onmouseover=function(){Tip(actions,WIDTH,200);} ;\r\n\r\n //Fifth Cell\r\n var aprEdit=row.insertCell(4);\r\n aprEdit.align=\"left\";\r\n aprEdit.width=\"5%\";\r\n aprEdit.innerHTML=\"<a href='#' class='view'>Edit</a>\";\r\n aprEdit.onclick=function(){editRow(rowId);} ;\r\n }", "title": "" }, { "docid": "5726a271611b2d0b93c3ed7e76b046fc", "score": "0.5105078", "text": "function showUploadMatchRows() {\n\n //check sport and event type selected\n if ($(\"#sport-type\").val() == null) {\n //no sport selected\n showNotificationModal('Error', 'Please select a sport before clicking.');\n } else {\n if ($(\"#event-type\").val() == null) {\n //no event type selected\n showNotificationModal('Error','Please select the match type (Singles or Doubles) before clicking.');\n } else {\n\n var matchInputNumber = document.getElementById(\"match-field-input\").value;\n\n if (matchInputNumber == \"\") {\n showNotificationModal('Error',\"Please type a number (greater than 1) before clicking\");\n } else {\n\n if (matchInputNumber < 1 || matchInputNumber > 100) {\n showNotificationModal('Error',\"Match input number cannot be less than 1 or more than 100. If your event has more than 100 matches split it across multiple uploads.\");\n } else {\n\n var matchRows = document.getElementById(\"match-field-input\").value;\n\n var table = document.getElementById(\"match-input-table\");\n\n if (table.rows.length !== 0) {\n\n\n for (var deleteCycle = table.rows.length - 1; deleteCycle >= 0; deleteCycle--) {\n table.deleteRow(deleteCycle);\n }\n\n }\n\n var a = document.getElementById(\"event-type\").value;\n var dbl;\n if (a == 'Double') {\n x = 1;\n dbl = 1;\n } else {\n x = 0;\n }\n for (var insertCycle = 0; insertCycle < matchRows; insertCycle++) {\n addEventRow(dbl);\n\n }\n\n var num = document.getElementById(\"match-field-input\").value;\n sessionStorage.setItem(\"lastnumber\", num);\n setupMatchAutoComplete();\n setupMatchErrorChecking();\n setupAdvancedSearchLinks();\n\n // display submit match button\n\n document.getElementById('submit_event').style.display = 'block';\n\n /*var addButton = document.createElement(\"BUTTON\");\n addButton.innerHTML = \"Add More Rows\";\n addButton.setAttribute('class','add-button');\n document.body.appendChild(addButton);*/\n\n\n if (matchInputNumber != 0) {\n document.getElementById(\"match-final-submit\").style.display = \"block\";\n }\n }\n }\n }\n }\n return false;\n}", "title": "" }, { "docid": "6056c574a15f571b81f0323a78deffb1", "score": "0.5096167", "text": "function setUsuarioSesion(usuario) {\n var guardado = sessionStorage.setItem(\"usuario\",usuario);\n}", "title": "" }, { "docid": "c5493aaa3634f28b76d06b7c4ae52b29", "score": "0.50942695", "text": "function addToCart(val) {\n\n let students = JSON.parse(localStorage.getItem(\"students\"));\n var obj = students[val];\n let array;\n array = localStorage.getItem('cart');\n if (array == null) {\n array = [];\n } else {\n\n array = JSON.parse(localStorage.getItem('cart'))\n }\n array.push(obj);\n localStorage.setItem('cart', JSON.stringify(array));\n window.location.reload();\n}", "title": "" }, { "docid": "6c6c5fc9583e4db9ba9b7241436a6bf4", "score": "0.5088372", "text": "function addUserTable(data) {\n \tuserTable.row.add({\n \tuserName: data.userName,\n \tpoints: data.points,\n \twatchTime: data.watchTime,\n \tteam: data.team,\n \trole: data.role,\n \tlink: data.picture,\n \tquotes: data.quotes\n \t})\n \tuserTable.draw() //redraws the table to see our changes\n}", "title": "" }, { "docid": "2deeac754e5bc9b12a43926fca1c9257", "score": "0.50831443", "text": "function addSession(data) {\n console.log(` Adding: ${data.topic} (${data.owner})`);\n Sessions.insert(data);\n}", "title": "" }, { "docid": "e7506f6f29be3d8859ad0fa146e9e8a9", "score": "0.50816774", "text": "function appendRow() {\n let lastRow = document.getElementById(\"tbl\").lastElementChild\n .lastElementChild;\n\n let newElement = document.createElement(\"tr\");\n\n newElement.innerHTML = lastRow.innerHTML;\n\n lastRow.parentNode.insertBefore(newElement, lastRow.nextSibling);\n}", "title": "" }, { "docid": "b6987d7391547aa6fee59b3ff45a5259", "score": "0.50765264", "text": "*set(sid, sess, ttl) {\n if (!this.ready)\n throw new Error(`Error trying to modify koa postgres session: session setup has not been run.\n See https://github.com/TMiguelT/koa-pg-session#the-setup-function for details.`);\n\n ttl = ttl || ms(\"45 minutes\");\n const expiry = (Date.now() + ttl) / 1000;\n\n //If there is a row, update it\n if (yield* this.get(sid))\n yield this.query(this.updateValueSql, [sess, expiry, sid]);\n //Otherwise, insert a new row\n //(These two queries intentionally have a different parameter order because of the SQL structure)\n else yield this.query(this.insertValueSql, [sid, sess, expiry]);\n }", "title": "" }, { "docid": "0bd5630f3b0c9f94ecf8f08ec14a1003", "score": "0.5071728", "text": "function setLocaisTrabalho(data) {\n sessionStorage.setItem(\"arrLocaisTrabalho\", JSON.stringify(data));\n}", "title": "" }, { "docid": "a201232b7d64d8f212823480be1e1c97", "score": "0.5068785", "text": "function addIntoCart(course) {\n // create a <tr>\n \n\n // Build the template\n row.innerHTML = `\n <tr>\n <td>\n <img src=\"${course.image}\" width=100>\n </td>\n <td>${course.title}</td>\n <td>${course.price}</td>\n <td>\n <a href=\"#\" class=\"remove\" data-id=\"${course.id}\">X</a>\n </td>\n </tr>\n `;\n // Add into the shopping cart\n \n\n // Add course into Storage\n \n}", "title": "" }, { "docid": "ad607468bbae44a2d638070e77accb5d", "score": "0.50621957", "text": "function insertTableCell(oRow, nAccess, EPiClientIdentityCounter,isUserOrGroup, iAccessLevelCount, disabled) {\n var oCell;\n\n oCell = oRow.insertCell(-1);\n\n if (iAccessLevelCount > 0) {\n var frmCheckbox = document.createElement('input');\n frmCheckbox.type = 'checkbox';\n frmCheckbox.id = clientID + '_p_' + EPiClientIdentityCounter + '_' + nAccess;\n frmCheckbox.name = uniqueID + 'p_' + EPiClientIdentityCounter + '_' + nAccess;\n frmCheckbox.value = nAccess;\n frmCheckbox.onclick = function () {\n highlightRow(EPiClientIdentityCounter, true);\n };\n frmCheckbox.ondblclick = function () {\n return SecEnableAccess(clientID + '_p_' + EPiClientIdentityCounter, nAccess, EPiClientIdentityCounter);\n };\n oCell.appendChild(frmCheckbox);\n frmCheckbox.checked = nAccess == EPiAccessLevelArray[0] ? 'checked' : '';\n\n if (disabled) {\n frmCheckbox.setAttribute('disabled', 'disabled');\n frmCheckbox.setAttribute('data-is-accesslevel-disabled', 'true');\n }\n } else {\n //This is the control that sets if this row is selected. In LoadPostData method we check if this value is true. If true..save it to ACL.\n var frmInputSaveRow = document.createElement('input');\n frmInputSaveRow.type = 'hidden';\n frmInputSaveRow.id = clientID + '_p_' + EPiClientIdentityCounter + '_save';\n frmInputSaveRow.name = uniqueID + 'p_' + EPiClientIdentityCounter + '_save';\n frmInputSaveRow.value = true;\n\n oRow.appendChild(frmInputSaveRow);\n\n //Here we save what type this user or role are..\n var frmEntryType = document.createElement('input');\n frmEntryType.type = 'hidden';\n frmEntryType.name = uniqueID + 'SecurityEntryType_' + EPiClientIdentityCounter + '_save';\n frmEntryType.value = isUserOrGroup;\n oCell.appendChild(frmEntryType);\n }\n\n}", "title": "" }, { "docid": "6974f5253d975ced5dabfef0461dff97", "score": "0.5062184", "text": "function saveList() {\n // check browser support\n if (typeof (Storage) === \"undefined\") {\n return;\n }\n const table = document.getElementById(\"myTable\");\n\n let tableArray = [];\n\n // store table\n for (let i = 1; i < table.rows.length; i++) {\n if (table.rows[i].cells[0] == null) {\n continue;\n }\n\n tableArray[i] = new Array(2);\n\n tableArray[i][0] = table.rows[i].cells[0].innerHTML;\n\n let price = parseFloat(table.rows[i].cells[1].innerHTML);\n price = Math.round(price * 100) / 100;\n tableArray[i][1] = price.toFixed(2); // .toFixed ensures 2 decimal places\n }\n localStorage.setItem('table', JSON.stringify(tableArray));\n}", "title": "" }, { "docid": "89adc3169dd1103b0c4840a2ddc001af", "score": "0.5062079", "text": "function generateRow(){\n pwdDateDiv.innerHTML = \"\";\n let curr_date = generateDate();\n let curr_pass= pwdDisplay.innerText;\n if(pwds.length == 20){\n pwds.shift()\n }\n if(dates.length == 20){\n dates.shift()\n }\n pwds.push(curr_pass);\n dates.push(curr_date);\n for(i = pwds.length-1; i >= 0; i--){\n let documentFragment = document.createDocumentFragment();\n let tbRow = document.createElement('tr');\n documentFragment.appendChild(tbRow);\n let td1 = document.createElement('td')\n td1.innerText = pwds[i];\n td2 = document.createElement('td')\n td2.innerText = dates[i]\n tbRow.appendChild(td1);\n tbRow.appendChild(td2);\n pwdDateDiv.appendChild(documentFragment)\n }\n localStorage.setItem(\"pwds\",JSON.stringify(pwds))\n localStorage.setItem(\"dates\",JSON.stringify(dates))\n}", "title": "" }, { "docid": "263ce5792af9db33e613358186f898a9", "score": "0.5052209", "text": "addRowToTable(dataArray, table) {\n var row = $(\"<tr></tr>\");\n\n var disableState = dataArray[\"enabled\"];\n delete dataArray[\"enabled\"];\n\n row.on(\"click\", this.selectionEvent);\n for (const key in dataArray) {\n if (dataArray.hasOwnProperty(key)) {\n const element = dataArray[key];\n\n row.append($(\"<td class='align-middle'>\" + element + \"</td>\"));\n }\n }\n\n if (table.find(\"tbody\").length) {\n table.find(\"tbody\").append(row);\n } else {\n table.find(\"tbody\").append(row);\n }\n }", "title": "" } ]
9cd1115208b61aae54bb207299ff1a62
fnSp4EnviarACR fin fnSp4BtCerrarEnviarACR ini
[ { "docid": "c1950250939d7ec2c3a169f8c69c512f", "score": "0.56764156", "text": "function fnSp4BtCerrarEnviarACR()\n{\n\n if($('#btCancelarVerAcr').html() == \"Cancelar\")\n {\n $('#Sp3VentanaHallazgoEditView').modal('hide').removeClass('fade');\n }\n else\n {\n // alert('Ver ACR')\n }\n}", "title": "" } ]
[ { "docid": "b89bbb64872b815a735414a861ca9037", "score": "0.6177467", "text": "function fnSp4EnviarACR(idHallazgo)\n{\n console.log('fnSp4EnviarACR = ', idHallazgo);\n}", "title": "" }, { "docid": "1fdc33721547d0b9d315b78c241484db", "score": "0.5934755", "text": "function enviarOnClick(){\t\n\tif(!sicc_validaciones_generales('tipoMovimiento')) {\n\t\treturn;\n\t}\n\n\tvar tiposMovimiento = get(\"frmFormulario.cbTipoMovimiento\");\n\tset(FORMULARIO+'.tiposMovimiento', tiposMovimiento);\n\n\tvar subaccesos = get(\"frmFormulario.cbSubacceso\");\n\tset(FORMULARIO+'.subaccesos', subaccesos);\n\n\tset(FORMULARIO+'.accion','enviar');\n\tset(FORMULARIO+'.conectorAction','LPEnviarMovimientosAlmacenDiarios');\n\tenviaSICC(FORMULARIO);\n}", "title": "" }, { "docid": "a2855e944342b2385e864c1340dca6f4", "score": "0.59056664", "text": "function fnVerModalEvaluarACR(Id)\n{\n istHall = Id\n console.warn(\"Evaluar \",objHallazgo[Id])\n console.warn(\"$('#btnEvaluarACR').css('display')\",$('#btnEvaluarACR').css('display'))\n /*if($('#btnEvaluarACR').css('display')===\"none\")\n {\n $('#btnEvaluarACR').css('display','block')\n $(\"#btnEvaluarACR\").attr('disabled',false)\n $('#cerrarAA').css('display','block')\n $('#cerrarBB').css('display','none')\n }//*/\n $(\"#cerrarAA\").css(\"display\",\"block\")\n $(\"#cerrarBB\").css(\"display\",\"none\")\n $(\"#btnEvaluarACR\").css(\"display\",\"block\")\n $(\"#btnEvaluarACR\").attr('disabled',false)\n $(\"#cerrarBB\").css(\"display\",\"none\")\n $(\"#btnExportarACR\").css(\"display\",\"none\")\n //$(\"#btnFinalizarACR\").css('display','block')\n // Usamos la funcion definida en hallazgosAsignados.js\n // para Ver la modal del ACR\n let ver = \"disabled\"\n $(\"#ver\").val(ver)\n fnSp4VerModalCrearACR(Id,ver)\n // bloqueamos los inputs\n $(\"#selectAreasHA\").attr(\"disabled\",true);\n $(\"#queHA\").attr(\"disabled\",true);\n $(\"#dondeHA\").attr(\"disabled\",true);\n $(\"#cuandoHA\").attr(\"disabled\",true);\n $(\"#comoHA\").attr(\"disabled\",true);\n $(\"#cualHA\").attr(\"disabled\",true);\n $(\"#problemaHA\").attr(\"disabled\",true);\n fnSp4PintarPlanAccion(ver)\n\n}", "title": "" }, { "docid": "9e675bbca98c26403053f19cd02bca07", "score": "0.5460118", "text": "function fin()\r\n {\r\n // deshabilitamos el casilla de entrar el numero, y el\r\n // boton de enviar\r\n document.getElementById(\"numero\").disabled=true;\r\n document.getElementById(\"btnEnviar\").disabled=true;\r\n }", "title": "" }, { "docid": "e4a5619e247b27d3d79b678dba26815b", "score": "0.54492784", "text": "function creditoAnterior(){\n if(inidiceCreditos>1)\n inidiceCreditos--;\n cargarCreditos();\n KPTF.consola(\"Anterior indiceCreditos: \"+inidiceCreditos);\n}", "title": "" }, { "docid": "5ec1fb11834f9baa7777064cebfd1887", "score": "0.53529197", "text": "function cargarCgg_jur_acuerdoCtrls(){\n if(inRecordCgg_jur_acuerdo){\n txtCjacu_codigo.setValue(inRecordCgg_jur_acuerdo.get('CJACU_CODIGO'));\n tmpCrpjr_codigo=inRecordCgg_jur_acuerdo.get('CRPJR_CODIGO');\n txtCrpjr_codigo.setValue(inRecordCgg_jur_acuerdo.get('RAZON_SOCIAL'));\n tmpCrper_codigo=inRecordCgg_jur_acuerdo.get('CRPER_CODIGO');\n txtCrper_codigo.setValue(inRecordCgg_jur_acuerdo.get('PERSONA'));\n tmpCsctp_codigo=inRecordCgg_jur_acuerdo.get('CSCTP_CODIGO');\n cbxCsctp_codigo.setValue(inRecordCgg_jur_acuerdo.get('SECTOR_PRODUCTIVO'));\n tmpCjtpr_codigo=inRecordCgg_jur_acuerdo.get('CJTPR_CODIGO');\n cbxCjtpr_codigo.setValue(inRecordCgg_jur_acuerdo.get('NOMBRE_PROCESO'));\n tmpCainf_codigo=inRecordCgg_jur_acuerdo.get('CAINF_CODIGO');\n cbxCainf_codigo.setValue(inRecordCgg_jur_acuerdo.get('AREA'));\n numCjacu_anio.setValue(inRecordCgg_jur_acuerdo.get('CJACU_ANIO'));\n txtCjacu_numero.setValue(inRecordCgg_jur_acuerdo.get('CJACU_NUMERO'));\n txtCjacu_objeto.setValue(inRecordCgg_jur_acuerdo.get('CJACU_OBJETO'));\n txtCjacu_descripcion.setValue(inRecordCgg_jur_acuerdo.get('CJACU_DESCRIPCION'));\n txtCjacu_jurisdiccion_ambito.setValue(inRecordCgg_jur_acuerdo.get('CJACU_JURISDICCION_AMBITO'));\n dtCjacu_fecha_suscripcion.setMinValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_SUSCRIPCION')));\n dtCjacu_fecha_suscripcion.setValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_SUSCRIPCION')));\n txtCjacu_institucion_firma.setValue(inRecordCgg_jur_acuerdo.get('CJACU_INSTITUCION_FIRMA'));\n dtCjacu_fecha_inicio.setMinValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_INICIO')));\n dtCjacu_fecha_inicio.setValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_INICIO')));\n tmpCgg_cusu_codigo= inRecordCgg_jur_acuerdo.get('CGG_CUSU_CODIGO');\n txtCgg_cusu_codigo.setValue(inRecordCgg_jur_acuerdo.get('RESPONSABLE'));\n txtCjacu_partida_presupuestaria.setValue(inRecordCgg_jur_acuerdo.get('CJACU_PARTIDA_PRESUPUESTARIA'));\n numCjacu_costo.setValue(inRecordCgg_jur_acuerdo.get('CJACU_COSTO'));\n numCjacu_tiempo.setValue(inRecordCgg_jur_acuerdo.get('CJACU_TIEMPO'));\n cbxCjacu_estado_ejecucion.setValue(inRecordCgg_jur_acuerdo.get('CJACU_ESTADO_EJECUCION'));\n dtCjacu_fecha_finalizacion.setMinValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_FINALIZACION')));\n dtCjacu_fecha_finalizacion.setValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_FINALIZACION')));\n txtCjacu_observacion.setValue(inRecordCgg_jur_acuerdo.get('CJACU_OBSERVACION'));\n tmpCjacu_tipo=inRecordCgg_jur_acuerdo.get('CJACU_TIPO')\n if (tmpCjacu_tipo==0)\n numCjacu_tipo.setValue(\"CONTRATO\");\n else\n numCjacu_tipo.setValue(\"CONVENIO\");\n\n rdgCjpjuTipo_persona.setValue('rdgCjpjuTipo_natural',inRecordCgg_jur_acuerdo.get('CJACU_TIPO_PERSONA'));\n chkCjacu_adendum.setValue(inRecordCgg_jur_acuerdo.get('CJACU_ADENDUM'));\n if (chkCjacu_adendum.checked==true){\n txtCjacu_objeto_adendum.enable();\n dtCjacu_fecha_adendum.enable();\n } else{\n txtCjacu_objeto_adendum.setDisabled(true);\n dtCjacu_fecha_adendum.setDisabled(true);\n }\n dtCjacu_fecha_adendum.setMinValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_ADENDUM')));\n dtCjacu_fecha_adendum.setValue(truncDate(inRecordCgg_jur_acuerdo.get('CJACU_FECHA_ADENDUM')));\n txtCjacu_objeto_adendum.setValue(inRecordCgg_jur_acuerdo.get('CJACU_OBJETO_ADENDUM'));\n\n if (inRecordCgg_jur_acuerdo.get('CJACU_TIPO_PERSONA') ==0){\n pnlPersonaNatural.setVisible(true);\n pnlPersonaJuridica1.setVisible(false);\n\n }else{\n pnlPersonaJuridica1.setVisible(true);\n pnlPersonaNatural.setVisible(false);\n }\n gsAdj_historial_acuerdo.reload({\n params:{\n inCjacu_Codigo:txtCjacu_codigo.getValue(),\n format:TypeFormat.JSON\n }\n });\n isEdit = true;\n habilitarCgg_jur_acuerdoCtrls(true);\n }}", "title": "" }, { "docid": "157dd847bca574e0597776418ce74bff", "score": "0.53251517", "text": "function creditoSiguiente(){\n if(inidiceCreditos<TOTAL_CREDITOS)\n inidiceCreditos++;\n cargarCreditos();\n KPTF.consola(\"Siguiente indiceCreditos: \"+inidiceCreditos);\n}", "title": "" }, { "docid": "b0edd2c8ad3d5d3f06342068a868fec8", "score": "0.528615", "text": "function irComputadores() {\n // Eliminar la clase Activa de los enlaces y atajos\n eliminarClaseActivaEnlances(enlaces, 'activo');\n eliminarClaseActivaEnlances(atajosIcons, 'activo-i');\n // Añadimos la clase activa de la seccion de Coputadores en los enlaces y atajos\n añadirClaseActivoEnlaces(enlaceComputadores, 'activo');\n añadirClaseActivoEnlaces(atajoComputadores, 'activo-i');\n // Crear contenido de la Seccion\n crearContenidoSeccionComputadores();\n // Abrir la seccion \n abrirSecciones();\n}", "title": "" }, { "docid": "a134074224fa2deb39d67fefa4d9cc9a", "score": "0.5283665", "text": "function tractarCanalEnviadorCanviEstat() {\n\t\n\tvar readyState = sendChannel.readyState;\n\tlog('Send channel state is: ' + readyState);\n\tif (readyState == \"open\") {\n\t\t// Enable 'Send' text area and set focus on it\n\t\tdataChannelSend.disabled = false;\n\t\tdataChannelSend.focus();\n\t\tdataChannelSend.placeholder = \"\";\n\t\tsendButton.disabled = false; // Enable 'Send' button\n\n\t} else { // event MUST be 'close', if we are here...\n\t\tdataChannelSend.disabled = true; // Disable 'Send' text area\n\t\tsendButton.disabled = true; // Disable 'Send' \n\t}\n}", "title": "" }, { "docid": "e7a100d3d9709c5ee01aa74028f59243", "score": "0.52406627", "text": "function desactivarBotella(F){\n\telemento = document.getElementById('id5'); \t elemento.addClassName(\"fondo6\");\n\telemento = document.getElementById('id_b0'); elemento.addClassName(\"titulo4\");\n\telemento = document.getElementById('id_b1'); elemento.addClassName(\"titulo4\");\n\tfor(i=2; i<=9; i++){elemento = document.getElementById('id_b'+i); elemento.removeClassName(\"fondo4\"); elemento.addClassName(\"fondo5\");}\n\tfor(i=1; i<=3; i++){campo = eval(\"F.Bc\"+i); campo.disabled=true;}\n\tF.Bc1.value=F.cbc.value=F.Bp1.value=F.pbc.value=F.Bc2.value=F.cbv.value=F.Bp2.value=F.pbv.value=F.Bc3.value=F.cbf.value=F.Bp3.value=F.pbf.value=F.TBc.value=F.cbt.value=F.TBp.value=F.pbt.value=\"\";\t\t\n}", "title": "" }, { "docid": "3015ae026ceb83631e780f328ccd5389", "score": "0.52143663", "text": "function fnSp4EvaluarACR()\n{\n // ocultamos modal\n $('#modalVerACR').modal('hide').removeClass('fade');\n // colocamos titulo a la modal\n $(\"#tituloModalEvularACR\").html(`Evaluar ACR - ${objHallazgo[istHall].dataHallazgo.Code_Hallazgo}`)\n // console.warn(\"Historial \",objHallazgo[istHall],istHall)\n // console.warn(\"Historial \",objHallazgo[istHall].dataHallazgo.AccionCorrectiva.EvaluarACR)\n // console.warn(\"StatusACR \",objHallazgo[istHall].dataHallazgo.AccionCorrectiva.EvaluarACR[12].StatusAccionCorrectivaId)\n // recorremos el historial de evaluaciones y buscamos el activo (Active==1)\n objHallazgo[istHall].dataHallazgo.AccionCorrectiva.EvaluarACR.forEach(function(Item)\n {\n if(Item.Active==1)\n {\n console.warn(\"Item\",Item)\n $(\"#idEvaluacion\").val(Item.Id)\n //fnSp4ValorEvaluarACR(Item.StatusAccionCorrectivaId)\n $(\"#StatusACR\").val(Item.StatusAccionCorrectivaId)\n if(Item.StatusAccionCorrectivaId==4){\n $(\"#aprobarACR\").click()\n $(\"#ObsercacionACRSp4\").attr('disabled',true)\n }else{\n $(\"#observarACR\").click()\n $(\"#ObsercacionACRSp4\").val(Item.Observacion)\n $(\"#ObsercacionACRSp4\").attr('disabled',false)\n }//*/\n }\n })\n // mostramos modal\n $('#modalEvaluarACR').modal('show').addClass('fade')\n}", "title": "" }, { "docid": "37c5ca2374eaf8cdb5664bd7988f7d1b", "score": "0.51943296", "text": "function importAcSetup() {\n let btnInitiateAcSetup = document.getElementById(\"btnInitiateAcSetup\");\n btnInitiateAcSetup.setAttribute(\"disabled\", true);\n EnigmailAutoSetup.performAutocryptSetup(gFoundSetupType).then(r => {\n if (r > 0) {\n document.getElementById(\"previousInstall_none\").style.visibility = \"visible\";\n enableDoneButton();\n }\n });\n}", "title": "" }, { "docid": "d68117c1aaa57148bbecf9d13bd12bf6", "score": "0.51761645", "text": "function irTransferenciasIcon() {\n // Eliminar la clase Activa de los enlaces y atajos\n eliminarClaseActivaEnlances(enlaces, 'activo');\n eliminarClaseActivaEnlances(atajosIcons, 'activo-i');\n // Añadimos la clase activa de la seccion de transferencias generales en los enlaces y atajos\n añadirClaseActivoEnlaces(enlaceTransferencias, 'activo');\n añadirClaseActivoEnlaces(atajoTransferencias, 'activo-i');\n // Crear contenido de la Seccion\n crearContenidoSeccionTransferencias();\n // Abrir la seccion \n abrirSecciones();\n}", "title": "" }, { "docid": "31be9738c45c640c5e836e9c8abaf348", "score": "0.5174813", "text": "function irTransferencias() {\n // Eliminar la clase Activa de los enlaces y atajos\n eliminarClaseActivaEnlances(enlaces, 'activo');\n eliminarClaseActivaEnlances(atajosIcons, 'activo-i');\n // Añadimos la clase activa de la seccion de transferencias generales en los enlaces y atajos\n añadirClaseActivoEnlaces(enlaceTransferencias, 'activo');\n añadirClaseActivoEnlaces(atajoTransferencias, 'activo-i');\n // Crear contenido de la Seccion\n crearContenidoSeccionTransferencias();\n // Abrir la seccion \n abrirSecciones();\n}", "title": "" }, { "docid": "855f1d9ab9be14346a7cf76eb3996ed6", "score": "0.5146582", "text": "function CWM_ELP_55_ASB_DPL_checkPTCO(){\r\n try{\r\n var apprNumStr = \"\";\r\n var boardCode = lookup(\"BOARDS\", \"Allied Health\");\r\n var licenseType = \"PF\";\r\n var licenseNum = AInfo[\"PT Compliance Officer License Number:\"];var flag = 0;\r\n var licHasCond = false;\r\n if (licenseNum != undefined && licenseNum != null && licenseNum != \"\") {\r\n var isActive = isLicenseActive(licenseNum, boardCode, licenseType);\r\n \r\n aa.print(\"Active: \" + isActive);\r\n if(!isActive){\r\n flag = 1;\r\n if(apprNumStr == \"\"){\r\n apprNumStr = licenseNum;\r\n }\r\n else{\r\n apprNumStr = apprNumStr + \", \" + licenseNum;\r\n }\r\n }\r\n else{\r\n var fullLicenseNum = licenseNum+\"-\"+boardCode+\"-\"+licenseType;\r\n var capLP = aa.cap.getCapID(fullLicenseNum).getOutput();\r\n aa.print(\"capLP####:\"+capLP);\r\n vLicStatus = getMyLicenseStatus(capLP);//get license status here\r\n if(vLicStatus){\r\n aa.print(\"1.PT Facility License Number is valid license ,Now cheking for valid status;\");\r\n if(vLicStatus == \"Current\"){\r\n aa.print(\"2.PT Facility License Number status is current. \");\r\n var refLPLicenseSeqNum1 = capLP.getLicenseProfessionalModel().getLicSeqNbr();\r\n var condArr = aa.caeCondition.getCAEConditions(refLPLicenseSeqNum1).getOutput();\r\n for (c in condArr)\r\n {\r\n var vCond = condArr[c];\r\n if ( vCond.getConditionDescription() == \"Probation Condition\")\r\n licHasCond == true;\r\n }\r\n }else{\r\n flag = 1;\r\n }\r\n }\r\n aa.print(\"Flag: \" + flag);\r\n if(flag == 1 || licHasCond == true){\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"The PT Facility License can not be renewed because the PTCO is not in good standing. Please contact the board for further instructions.\");\r\n }\r\n }\r\n }\r\n }\r\n catch(ex) {\r\n showMessage=true;\r\n comment(\"Error on function CWM_ELP_55_ASB_DPL_checkPTCO, Please contact administrator\");\r\n }\r\n}", "title": "" }, { "docid": "237ad25916e7233b1b1bd2e3eabeb4b9", "score": "0.51330364", "text": "function AES_Done() {\n AES_Sbox_Inv = undefined;\n AES_ShiftRowTab_Inv = undefined;\n AES_xtime = undefined;\n}", "title": "" }, { "docid": "a2225ad4272803aeea197810dedb4669", "score": "0.5117839", "text": "function cargarCgg_res_estado_civilCtrls(){\n if(inRecordCgg_res_estado_civil){\n txtCrecv_codigo.setValue(inRecordCgg_res_estado_civil.get('CRECV_CODIGO'));\n txtCrecv_descrpcion.setValue(inRecordCgg_res_estado_civil.get('CRECV_DESCRPCION'));\n isEdit = true;\n habilitarCgg_res_estado_civilCtrls(true);\n }}", "title": "" }, { "docid": "2edc9ad653c92116146dfccd917974ca", "score": "0.51159054", "text": "function desactivarCuadro1(){\n document.getElementById(\"tarjetap\").disabled=true;\n }", "title": "" }, { "docid": "0bf88ec3c028978ebe687138bdecb3e6", "score": "0.510691", "text": "function cancelar() {\n clearComponents();\n enableComponents(false);\n\n $('#cancelar').prop('disabled', true);\n $('#nuevo').text('Nuevo').css('background-color', '#3c8dbc');\n $('.filasTabla').removeClass('seleccionada');\n $('#Password').attr('placeholder', 'Ingrese una Contraseña');\n}", "title": "" }, { "docid": "0a04777ff31fcbac875575f00aec1000", "score": "0.50988835", "text": "function cargarCgg_dhu_encuestaCtrls(){\n if(inRecordCgg_dhu_encuesta){\n txtCdenc_codigo.setValue(inRecordCgg_dhu_encuesta.get('CDENC_CODIGO'));\n txtCdenc_nombre.setValue(inRecordCgg_dhu_encuesta.get('CDENC_NOMBRE'));\n txtCdenc_observacion.setValue(inRecordCgg_dhu_encuesta.get('CDENC_OBSERVACION'));\n isEdit = true;\n habilitarCgg_dhu_encuestaCtrls(true);\n }}", "title": "" }, { "docid": "7e721fb4af36c38820187bf5b8edf158", "score": "0.5082166", "text": "function irComputadoresIcon() {\n // Eliminar la clase Activa de los enlaces y atajos\n eliminarClaseActivaEnlances(enlaces, 'activo');\n eliminarClaseActivaEnlances(atajosIcons, 'activo-i');\n // Añadimos la clase activa de la seccion de Coputadores en los enlaces y atajos\n añadirClaseActivoEnlaces(enlaceComputadores, 'activo');\n añadirClaseActivoEnlaces(atajoComputadores, 'activo-i');\n // Crear contenido de la Seccion\n crearContenidoSeccionComputadores();\n // Abrir la seccion \n abrirSecciones();\n}", "title": "" }, { "docid": "8bab610ee664ed1c567999468328e4d8", "score": "0.5078359", "text": "function inicializarConversacionCodigo(){\nconversacionCodigo = new ArbolConversacion(texturaCristina,texturaGabriela,texturaCristinaSombreada,texturaGabrielaSombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Creo que ha muerto\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"No, solo ahorra fuerzas\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"Creo.. creo que tiene algo en la mano. Lo está sujetando con fuerza\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Tal vez sea importante\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"Es un papel, tien algo escrito. ''Codigo caja fuerte en la oficina: 181651'' ¿Que significa eso?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"No lo se, es posible que signifique algo para otra persona.\",2);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\nconversacionCodigo.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "0039b0b1fc77ebe3943ff6efa6df4766", "score": "0.5062705", "text": "function cargarCgg_dhu_registro_encuestaCtrls(){\n\t\tif(inRecordCgg_dhu_registro_encuesta){\n\t\t\ttxtCdrge_codigo.setValue(inRecordCgg_dhu_registro_encuesta.get('CDRGE_CODIGO'));\n\t\t\ttxtCdprg_codigo.setValue(inRecordCgg_dhu_registro_encuesta.get('CDPRG_CODIGO'));\n\t\t\ttxtCdres_codigo.setValue(inRecordCgg_dhu_registro_encuesta.get('CDRES_CODIGO'));\n\t\t\ttxtCdape_codigo.setValue(inRecordCgg_dhu_registro_encuesta.get('CDAPE_CODIGO'));\n\t\t\ttxtCdrge_respuesta_abierta.setValue(inRecordCgg_dhu_registro_encuesta.get('CDRGE_RESPUESTA_ABIERTA'));\n\t\t\tdtCdrge_fecha_registro.setValue(inRecordCgg_dhu_registro_encuesta.get('CDRGE_FECHA_REGISTRO'));\n\t\t\ttxtCdrge_observacion.setValue(inRecordCgg_dhu_registro_encuesta.get('CDRGE_OBSERVACION'));\n\t\t\tisEdit = true;\n\t\t\thabilitarCgg_dhu_registro_encuestaCtrls(true);\n\t}}", "title": "" }, { "docid": "81dc1b1acdbebb246249e4a413ac9afa", "score": "0.50031435", "text": "function borrador(){\n relleno = false;\n pinta = false;\n borrar = true;\n document.getElementById(\"btnPintar\").style.backgroundColor = \"transparent\";\n document.getElementById(\"btnPintar\").style.color = \"#FDC208\";\n document.getElementById(\"btnBorrar\").style.backgroundColor = \"#FDC208\";\n document.getElementById(\"btnBorrar\").style.color = \"black\";\n document.getElementById(\"btnRelleno\").style.backgroundColor = \"transparent\";\n document.getElementById(\"btnRelleno\").style.color = \"#FDC208\";\n document.getElementById(\"canvasPaint\").style.cursor = \"cursor: url('../img/pencil.cur'), auto\";\n color = \"#FFFFFF\";\n document.getElementById(\"colores\").setAttribute(\"disable\", \"\");\n}", "title": "" }, { "docid": "fe4fac6f9d81619dc375d3a2b10d1de2", "score": "0.49832326", "text": "function CWM_ELP_23_DPL_ASB_validateLicenseForPTFApplication(){\r\n try{\r\nvar boardCode = \"AH\";\r\nvar licNbr = AInfo[\"Existing Facility License Number\"];\r\n\r\n // Validate the license number \r\n if (licNbr != undefined && licNbr != null && licNbr != \"\") {\r\n var isActive = isLicenseActive(licNbr, boardCode, \"\"); \r\n\r\n\r\n if (!isActive) {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"The License Number of the existing facility must be a valid license number for a Physical Therapy Facility. Please contact the board for further instructions.\");\r\n }\r\n }\r\n\r\n }\r\n catch(error){\r\n showMessage=true;\r\n comment(\"Error on function CWM_ELP_23_DPL_ASB_validateLicenseForPTFApplication. Please contact administrator\");\r\n comment(error.message);\r\n }\r\n}", "title": "" }, { "docid": "059cd4730e19d19ebee7a3aaa9963bc1", "score": "0.49791816", "text": "function revocarAcceso(){\r\n\r\n}", "title": "" }, { "docid": "b60d221a067d2e02f8e7ddb7551cbcaa", "score": "0.496748", "text": "function initBt(){\n\t\t btEnable(statusType[st]);\n\t}", "title": "" }, { "docid": "5645b8b5c81dc85e50877f0348d85c33", "score": "0.49604285", "text": "function fin() {\n contador = 0;\n\n //ponemos el contador y el tiempo final a 0\n tiempoFinal = 0;\n console.log('fin');\n\n //desbloqueamos el boton de siguiente y cambiamos el titulo\n document.getElementById('siguiente').innerHTML = '<b>FINALIZAR</b>';\n document.getElementById('siguiente').disabled = false;\n document.getElementById('siguiente').style.backgroundColor = 'rgb(3, 119, 25)';\n}", "title": "" }, { "docid": "760153dd6ca792af5ce9b437388ead2b", "score": "0.49502042", "text": "function fcn_send_cv(){\n\t\n\tvar v_salir = '';\n\t\n\t$(\"#cv_nombre\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#cv_apellido\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#cv_telefono\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#cv_mail\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#cv_puesto\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#cv_sector\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#cv_mensaje\").css({'border-color' : '#ccc', 'background-color' : '#fff'});\n\t$(\"#ModalFranMsj\").empty();\n\t\n\t// Valido campos\n\tvar v_nom = $(\"#cv_nombre\").val();\n\tvar v_ape = $(\"#cv_apellido\").val();\n\tvar v_tel = $(\"#cv_telefono\").val();\n\tvar v_mai = $(\"#cv_mail\").val();\n\tvar v_pue = $(\"#cv_puesto\").val();\n\tvar v_sec = $(\"#cv_sector\").val();\n\tvar v_msj = $(\"#cv_mensaje\").val();\n\t\n\tif(v_nom == ''){\n\t\t$(\"#cv_nombre\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}\n\t\n\tif(v_ape == ''){\n\t\t$(\"#cv_apellido\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}\n\t\n\tif(v_tel == ''){\n\t\t$(\"#cv_telefono\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}\n\t\n\tif(v_mai == ''){\n\t\t$(\"#cv_mail\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}else{\n\t\t\n\n\t var caract = new RegExp(/^([a-zA-Z0-9_.+-])+\\@(([a-zA-Z0-9-])+\\.)+([a-zA-Z0-9]{2,4})+$/);\n\t if (caract.test(v_mai) == false){\n\t\t\t\n\t\t\t$(\"#cv_mail\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\t\t$(\"#ModalCVMsj\").html('<div style=\"color: red; text-align: center;\">Por favor, ingrese un E-mail válido.</div>');\n\t\t\treturn;\n\t\t\n\t }\n\t}\n\t\n\tif(v_pue == ''){\n\t\t$(\"#cv_puesto\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}\n\t\n\tif(v_sec == ''){\n\t\t$(\"#cv_sector\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}\n\t\n\tif(v_msj == ''){\n\t\t$(\"#cv_mensaje\").css({'border-color' : '#f4686b', 'background-color' : '#fee9e7'});\n\t\tv_salir = 'X';\n\t}\n\t\n\tif(v_salir == 'X'){\n\t\t$(\"#ModalCVMsj\").html('<div style=\"color: red; text-align: center;\">Complete los campos obligatorios.</div>');\n\t\treturn;\n\t}\n\t\n\t$(\"#ModalCVMsj\").html('<div style=\"color: green; text-align: center;\"><img height=\"25\" src=\"http://www.datalive.com.ar/shared/spin_loader.gif\"> Enviando..</div>');\n\t\n\t$(\"#btn1_cv\").hide();\n\t$(\"#btn2_cv\").hide();\n\t\n var file_data = $('#cv_upload').prop('files')[0]; \n var form_data = new FormData(); \n form_data.append('file', file_data);\n form_data.append('tipo', 'CV');\n form_data.append('nombre', v_nom);\n form_data.append('apellido', v_ape);\n form_data.append('tel', v_tel);\n form_data.append('mail', v_mai);\n form_data.append('puesto', v_pue);\n form_data.append('sector', v_sec);\n form_data.append('mensaje', v_msj);\n\t\n\t$.ajax({\n\t\t url: \"contacto.php\", // Url a llamar\n\t\t type: \"POST\", \t\t\t\t\t // Metodo de llamada\n\t\t //data: { tipo : 'CV',\n\t\t\t//\t\t\t nombre : v_nom,\n\t\t\t//\t\t\t apellido : v_ape,\n\t\t\t//\t\t\t tel : v_tel,\n\t\t\t//\t\t\t mail : v_mai,\n\t\t\t//\t\t\t puesto : v_pue,\n\t\t\t//\t\t\t sector : v_sec,\n\t\t\t//\t\t\t mensaje : v_msj,\n\t\t\t//\t\t\t file_data : file_data\n\t\t //}, // Datos a enviar\n\t\t \n\t\t data: form_data,\n\t\t contentType: false,\n\t\t cache: false, \n\t\t processData: false,\n\t\t \n\t\t dataType: \"json\", \t\t\t\t\t\t\t\t\t // Tipo de datos a devolver (JSON)\n\t\t success: function (data) {\n\t\t \n\t\t // Si no da error, sigo con el proceso\n\t\t if(data[0] == 'OK'){\n\t\t\t \n\t\t\t\t\t$(\"#ModalCVMsj\").html('<div style=\"color: green; text-align: center;\">'+data[1]+'</div>');\n\n\t\t\t\t\t$(\"#btn2_cv\").html('Salir');\n\t\t\t\t\t$(\"#btn2_cv\").show();\n\t\t\t \n\t\t }else{\n\t\t\t \t\n\t\t\t\t\t$(\"#ModalCVMsj\").html('<div style=\"color: red; text-align: center;\">'+data[1]+'</div>');\n\n\t\t\t\t\t$(\"#btn1_cv\").html('Intentar nuevamente');\n\t\t\t\t\t$(\"#btn1_cv\").show();\n\t\t\t\t\t\n\t\t }\n\t\t \n\t\t }\n\t\t \n\t}).fail(function(){\n\n\t\t$(\"#ModalCVMsj\").html('<div style=\"color: red; text-align: center;\">Ocurrió un error al intentar enviar el mensaje.</div>');\n\n\t\t$(\"#btn1_cv\").html('Intentar nuevamente');\n\t\t$(\"#btn1_cv\").show();\n\t\t\t\t\t\n\t});\n\t\n\t\n} // fcn_send_cv", "title": "" }, { "docid": "9ab1095e61ab894fc5bdedcea85fd0b0", "score": "0.4943567", "text": "function compruebaFin() {\n if( oculta.indexOf(\"_\") == -1 ) {\n document.getElementById(\"msg-final\").innerHTML = \"Felicidades !!\";\n document.getElementById(\"msg-final\").className += \"zoom-in\";\n document.getElementById(\"palabra\").className += \" encuadre\";\n for (var i = 0; i < buttons.length; i++) {\n buttons[i].disabled = true;\n }\n document.getElementById(\"reset\").innerHTML = \"Empezar\";\n btnInicio.onclick = function() { location.reload() };\n }else if( cont == 0 ) {\n document.getElementById(\"msg-final\").innerHTML = \"Game Over\";\n document.getElementById(\"msg-final\").className += \"zoom-in\";\n for (var i = 0; i < buttons.length; i++) {\n buttons[i].disabled = true;\n }\n document.getElementById(\"reset\").innerHTML = \"Empezar\";\n btnInicio.onclick = function () { location.reload() };\n }\n }", "title": "" }, { "docid": "87b4990e591c53935c55845145ab4fad", "score": "0.49294457", "text": "function activarTeclado(){\r\n activadoTeclado=true;\r\n}", "title": "" }, { "docid": "4da7106d486167dd0bf34f35943eec09", "score": "0.4917583", "text": "function habilitarFacturacion() {\n document.getElementById(\"botonConfirmar\").disabled = false;\n}", "title": "" }, { "docid": "c43b3b62089a2bcbad407e9fbb42f8c9", "score": "0.49144784", "text": "mostrarFormularioAsignacionPaciente() {\n\n let funcion = () => this.activarSeleccion(\"asignarPersonal\", botonAltaPaciente);\n crearFormulario([\"Nombre\"], \"asignarPersonal\", funcion);\n let botonAltaPaciente = document.getElementById(\"confirmacion\");\n }", "title": "" }, { "docid": "d17bd4749ccb7a74a3a547155df4c056", "score": "0.49064118", "text": "function cargarRolesAf(empid) { \n var empresa = empid;\n console.log(\"------------------------ \"+empresa);\n console.log(\"-BOTON HABILITADO-----------------------\");\n $(\"#btnAgEmp_PuestoTmp\").removeAttr(\"disabled\");\n M.toast({html: 'No olvides agregar los puestos!', classes: 'rounded blue'}); \n onRequest({ opcion : 43 ,idemp:empresa}, respCargarRolesXempChb);\n onRequest({ opcion : 102 ,empresa:empresa}, respCargaSucursalesXEmpresa);\n }", "title": "" }, { "docid": "1e2dc46250a040f4a7e5a3cd18347fa3", "score": "0.4904929", "text": "function compruebaFin() {\n if( oculta.indexOf(\"_\") == -1 ) {\n document.getElementById(\"msg-final\").innerHTML = \"Felicidades !!\";\n document.getElementById(\"msg-final\").className += \"zoom-in\";\n document.getElementById(\"palabra\").className += \" encuadre\";\n for (var i = 0; i < buttons.length; i++) {\n buttons[i].disabled = true;\n }\n document.getElementById(\"reset\").innerHTML = \"Empezar\";\n btnInicio.onclick = function() { location.reload() };\n }else if( cont == 0 ) {\n document.getElementById(\"msg-final\").innerHTML = \"Game Over\";\n document.getElementById(\"msg-final\").className += \"zoom-in\";\n for (var i = 0; i < buttons.length; i++) {\n buttons[i].disabled = true;\n }\n document.getElementById(\"reset\").innerHTML = \"Empezar\";\n btnInicio.onclick = function () { location.reload() };\n }\n}", "title": "" }, { "docid": "ff7ad04459bb9f1298ffcb0ea4422b1c", "score": "0.49022076", "text": "function C16032_Ability_to_Authorize_Sales_of_Products()\n{\ntry{\n Log.AppendFolder(\"C16032_Ability_to_Authorize_Sales_of_Products\");\n InitializationEnviornment.initiliaze();\n AppLoginLogout.login(); \n var keyWordNm =\"Daily Admission\";\n var packageNm =\"Date/Time\";\n var subPakNm =\"Children (Ages 3-12)\";\n var qtyT = 2; \n var keyWordNm1 =\"Daily Admission\";\n var packageNm1 =\"Dated\";\n var subPakNm1 =\"Adult\";\n var qtyT1 = 1; \n addNewTicket(keyWordNm,packageNm,subPakNm,qtyT,CommonCalender.getTodaysDate()); \n addNewTicket(keyWordNm1,packageNm1,subPakNm1,qtyT1,CommonCalender.getTodaysDate()); \n finilizeOrder();\n aqUtils.Delay(3000);\n var expectedSettlemtnttotal = orderDetailsTotal.Caption;\n var applyAmount= (expectedSettlemtnttotal.split('$')[1]).trim(); \n CashButton.Click(); \n if(applyAmount != 0){\n Log.Message(\"Apply amount\");\n WrapperFunction.setTextValue(PayamountTextBox,applyAmount);\n Button.clickOnButton(applyButton); \n }\n Log.Message(\"Complete the order\");\n WrapperFunction.settlementCompleteOrder();\n aqUtils.Delay(2000);\n validateTicket(\"Don't Validate\");\n Log.Message(\"Don't Validate the order\"); \n verifyTotalOnConfirmationPage(expectedSettlemtnttotal);\n var orderId = cnf_orderID1.Caption;\n if (orderId == null){\n merlinLogError(\"Order id is not present\");\n } \n AppLoginLogout.logout(); \n } catch (e) {\n\t merlinLogError(\"Oops! There's some glitch in the script: \" + e.message);\t \n }\n finally { \n\t Log.PopLogFolder();\n } \n \n}", "title": "" }, { "docid": "b1cb19a667928c3113bdea63e61460e0", "score": "0.48966312", "text": "function fnAgregar(){\n\t//$(\"button\").removeAttr('disabled');\n\tvar id_contratos = $('#txtIdContratos').val();\n\tvar id_loccode = $('#selectObjetoPrincipal').val();\n\tvar nu_estatus = $('#selectEstatus').val();\n\tvar nu_recargos = $('#selectRecargos').val();\n\tvar nu_multa = $('#selectMulta').val();\n\tvar descripcion = $('#txtDescripcion').val();\n\tvar reporte = $('#selectReporte').val();\n\tvar msg = \"\";\n\n\t/*if (id_identificacion == \"\" || id_identificacion == 0 || clave == \"\" || descripcion == \"\") {\n\t\t$('#ModalUR').modal('hide');\n\t\tmuestraMensaje('Agregar Finalidad, Función y Descripción para realizar el proceso', 3, 'msjValidacion', 5000);\n\t\treturn false;\n\t}*/\n\t/*if (clave == \"\" && descripcion == \"\") {\n\t\t\n\t\t$('#ModalUR').modal('hide');\n\t\tmuestraMensaje('Debe agregar Función y Descripción para realizar el proceso', 3, 'msjValidacion', 5000);\n\t\treturn false;\n\t\t\n\t}else if (clave == \"\") {\n\t\t$('#ModalUR').modal('hide');\n\t\tmuestraMensaje('Debe agregar Función para realizar el proceso', 3, 'msjValidacion', 5000);\n\t\treturn false;\n\t}else if (descripcion == \"\") {\n\t\t$('#ModalUR').modal('hide');\n\t\tmuestraMensaje('Debe agregar Descripción para realizar el proceso', 3, 'msjValidacion', 5000);\n\t\t\n\t\treturn false;\n\t}*/\n\t\n\n\tif (id_loccode == \"\" || id_loccode == null || id_loccode == 0 || id_loccode == \"0\" || id_loccode === \"undefined\" || nu_estatus == \"\" || nu_estatus == null || nu_estatus === \"undefined\" || nu_recargos == \"\" || nu_recargos == null || nu_recargos === \"undefined\" || nu_multa == \"\" || nu_multa == null || nu_multa === \"undefined\" || descripcion==\"\" || descripcion == null || descripcion === \"undefined\") {\n\t\tif (id_loccode == \"\" || id_loccode == null || id_loccode == 0 || id_loccode == \"0\" || id_loccode === \"undefined\") {\n\t\t\tmsg += '<p>Falta capturar el objeto principal </p>';\n\t\t}\n\t\tif (nu_estatus == \"\" || nu_estatus == null || nu_estatus === \"undefined\") {\n\t\t\tmsg += '<p>Falta capturar el estatus </p>';\n\t\t}\n\t\tif (nu_recargos == \"\" || nu_recargos == null || nu_recargos === \"undefined\") {\n\t\t\tmsg += '<p>Falta capturar si aplica recargos </p>';\n\t\t}\n\t\tif (nu_multa==\"\" || nu_multa == null || nu_multa === \"undefined\" ) {\n\t\t\tmsg += '<p>Falta capturar si aplica multa </p>';\n\t\t}\n\t\tif (descripcion==\"\" || descripcion == null || descripcion === \"undefined\" ) {\n\t\t\tmsg += '<p>Falta capturar la descripción </p>';\n\t\t}\n\n\t\t\n\n\t\t$('#divMensajeOperacion').removeClass('hide');\n\t\t$('#divMensajeOperacion').empty();\n\t\t$('#divMensajeOperacion').append('<div class=\"alert alert-danger alert-dismissable\">' + msg + '<button type=\"button\" class=\"close\" data-dismiss=\"alert\">&times;</button></div>');\n\t\t\n\t\t\n\n\t}else{\n\t\t$('#ModalUR').modal('hide');\n\t\tdataObj = { \n\t\t\t\toption: 'AgregarCatalogo',\n\t\t\t\tid_contratos: id_contratos,\n\t\t id_loccode: id_loccode,\n\t\t\t\tnu_estatus: nu_estatus,\n\t\t\t\tnu_recargos: nu_recargos,\n\t\t\t\tnu_multa: nu_multa,\n\t\t\t\tdescripcion: descripcion,\n\t\t\t\treporte: reporte,\n\t\t\t\tproceso: proceso\n\t\t };\n\t\t//Obtener datos de las bahias\n\t\t$.ajax({\n\t\t\t async:false,\n\t cache:false,\n\t\t method: \"POST\",\n\t\t dataType:\"json\",\n\t\t url: url,\n\t\t data:dataObj\n\t\t })\n\t\t.done(function( data ) {\n\t\t if(data.result){\n\t\t \tmuestraMensaje(data.contenido, 1, 'divMensajeOperacion', 5000);\n\n\t\t \tfnLimpiarTabla('divTabla', 'divContenidoTabla');\n\t\t \tfnMostrarDatos('','');\n\t\t }else{\n\t\t \tmuestraMensaje(data.contenido, 3, 'divMensajeOperacion', 5000);\n\t\t }\n\t\t})\n\t\t.fail(function(result) {\n\t\t\tconsole.log(\"ERROR\");\n\t\t console.log( result );\n\t\t});\n\t}\n}", "title": "" }, { "docid": "33f1e81b58121f38a316b0d16d2abfb0", "score": "0.48964345", "text": "function habilitar_cambios_especiales()\r\n{var i,boton_del,cant,precio,nbre_prov,es_stock;\r\n\r\n //si la OC no es Orden de Servicio Tecnico, le damos el nombre del proveedor desde el select_proveedor\r\n if(document.all.modo.value!=\"oc_serv_tec\")\r\n nbre_prov=document.all.select_proveedor[document.all.select_proveedor.selectedIndex].text;\r\n else if(document.all.modo.value==\"oc_serv_tec\")//si es una Orden de Servicio Tecnico, le damos el nombre previamente guardado\r\n nbre_prov=document.all.nombre_proveedor.value;\r\n if(es_stock_js(nbre_prov))\r\n es_stock=1;\r\n else\r\n es_stock=0;\r\n\r\n for(i=0;i<document.all.items.value;i++)\r\n {\r\n if(document.all.internacional.value==1)\r\n {posad=eval(\"document.all.select_posad_\"+i);\r\n boton_posad=eval(\"document.all.detalle_posad_\"+i);\r\n }\r\n boton_del=eval(\"document.all.borrar_fila_\"+i);\r\n cant=eval(\"document.all.cant_\"+i);\r\n precio=eval(\"document.all.unitario_\"+i);\r\n\r\n if(document.all.check_habilitar_cambios.checked==0)\r\n {boton_del.style.visibility='hidden';\r\n if(!es_stock)\r\n {cant.disabled=1;\r\n precio.disabled=1;\r\n if(document.all.internacional.value==1)\r\n {posad.disabled=1;\r\n boton_posad.disabled=1;\r\n }\r\n }\r\n }\r\n else\r\n {boton_del.style.visibility='visible';\r\n if(!es_stock)\r\n {cant.disabled=0;\r\n precio.disabled=0;\r\n if(document.all.internacional.value==1)\r\n {posad.disabled=0;\r\n boton_posad.disabled=0;\r\n }\r\n }\r\n }\r\n }//de for(i=0;i<document.all.items.value;i++)\r\n if(!es_stock)\r\n {if(document.all.check_habilitar_cambios.checked==0)\r\n document.all.guardar_cambios_fila.style.visibility='hidden';\r\n else\r\n document.all.guardar_cambios_fila.style.visibility='visible';\r\n }\r\n\r\n}//de function habilitar_cambios_especiales()", "title": "" }, { "docid": "1d3da8f8fbd7b72f480a2931465bb1a0", "score": "0.48912847", "text": "function guarda(sucursal){\r\n\t//validamos si se realizaron cambios\r\n\t\t/*if(contCambios==0){\r\n\t\t\talert('No hay cambios por guardar');\r\n\t\t\treturn false;\r\n\t\t} deshabilitado por oscar para hacer ajuste de inventario en linea*/\r\n\t//mostramos mensaje\r\n\t\tdocument.getElementById('emergente').style.display='block';\r\n\t//ocultamos boton de panel\r\n\t\tdocument.getElementById('footer').style.display='none';\r\n\t//ocultamos encabezado\r\n\t\tdocument.getElementById('enc').style.display='none';\r\n\t//calculamos tamaño de la tabla\r\n\t\tvar tope=parseInt($('#formInv tr').length);\r\n\t//declaramos variables\r\n\t\tvar suma='',resta='',aux='',ax='',aux_id='',idProd='',tipo='',cS=0,cR=0;\r\n\t//recorremos la tabla\r\n\t\tfor(var i=1;i<=tope;i++){\r\n\t\t\taux='4,'+i;\r\n\t\t\tif(document.getElementById(aux).value){\r\n\t\t\t\tax=document.getElementById(aux).value;\r\n\t\t\t\tif(ax=='0'){\r\n\t\t\t\t\t//alert('sin accion');\r\n\t\t\t\t}else{\r\n\t\t\t\t//sacamos el id del producto\r\n\t\t\t\t\taux_id='0,'+i;\r\n\t\t\t\t\tidProd=document.getElementById(aux_id).value;\r\n\t\t\t\t//checamos si la diferencia es positiva o negativa para hacer el movimiento de almacen\r\n\t\t\t\t\tif(ax<0){\r\n\t\t\t\t\t\tcR++;//aumenntamos contador de resta\r\n\t\t\t\t\t\t\tresta+='|'+parseFloat(ax*-1)+','+idProd;//multiplicamos ax por -1 para volverlo positivo\r\n\t\t\t\t\t}\r\n\t\t\t\t\tif(ax>0){\r\n\t\t\t\t\t\tcS++;//aumenntamos contador de suma\r\n\t\t\t\t\t\tsuma+='|'+ax+','+idProd;\r\n\t\t\t\t\t}\r\n\t\t\t\t}//cierra else\r\n\t\t\t}//cierra if\r\n\t\t}//cierra for\r\n\t//capturamos el id del almacen\r\n\t\tvar id_almacen=$(\"#id_alm\").val();\r\n\t\t/*alert(id_almacen);\r\n\t\treturn false;*/\r\n\t//mandamos valores por ajax\r\n\t\t$.ajax({\r\n\t\t\ttype:'POST',\r\n\t\t\turl:'ajax/guardaAjuste.php',\r\n\t\t\tcache:'false',\r\n\t\t\tdata:{quita:cR+resta,agrega:cS+suma,suc:sucursal,almacen:id_almacen},\r\n\t\t\tsuccess: function(datos){\r\n\t\t\t\tif(datos=='okok'){\r\n\t\t\t\t\talert('Cambios guardados exitosamente!!!');\r\n\t\t\t\t\tlink(2);\r\n\t\t\t\t}else{\r\n\t\t\t\t\talert('ERROR!!!\\n'+datos);\r\n\t\t\t\t}\r\n\t\t\t}//fin de function(datos)\r\n\t\t});//fin de ajax\r\n\t\treturn false;\r\n\t}//fin de funcion guardar", "title": "" }, { "docid": "cc2289888e8fc6b585dfa38635066fcd", "score": "0.4889559", "text": "function btAction(acr){\n\t\tacr == 'print' ? actMethod = '{engine.curScreen.printOrder()}' : actMethod = btconfig.rejStr;\n\t\tgui.enableBtn('action', 'button_click', actMethod);\n\t\t$('action').set('text',acr);\n\t}", "title": "" }, { "docid": "ac763ed976b5e601bcea1d508df32e33", "score": "0.48813105", "text": "function VactivarInactivarCampos(idCheckbox){\n\n\tvar contador = idCheckbox.split(\"_\");\n\tcontador = contador[1];\n\n\n \t$(\"#Vcodigo_\"+contador).val(\"\");\n \t$(\"#Vprecio_\"+contador).val(\"\");\n \t$(\"#Vcategoria_\"+contador).val(\"\");\n \t\n\t\n\t//verificar si el check esta seleccionado\n\tif( $('#'+idCheckbox).prop('checked') ) { \n\t\t\t\n \t$(\"#Vcodigo_\"+contador).prop('disabled', false);\n \t$(\"#Vprecio_\"+contador).prop('disabled', false);\n \t$(\"#Vcategoria_\"+contador).prop('disabled', false);\n \t\n\t}else{\n\n\t \t$(\"#label_Vcodigo_\"+contador).removeClass(\"active\");\t\n\t \t$(\"#label_Vprecio_\"+contador).removeClass(\"active\");\t\n\t \t$(\"#btnGenerarCodigo_\"+contador).removeClass(\"active\");\t\n\t\t\t\t\n\t\t$(\"#Vcodigo_\"+contador).removeClass(\"invalid\");\n\t\t$(\"#Vprecio_\"+contador).removeClass(\"invalid\");\n\t\t\n\t\t$(\"#Vcodigo_\"+contador).removeClass(\"valid\");\t\n\t\t$(\"#Vprecio_\"+contador).removeClass(\"valid\");\t\n\n \t$(\"#Vcodigo_\"+contador).prop('disabled', true);\n \t$(\"#Vprecio_\"+contador).prop('disabled', true);\n \t$(\"#Vcategoria_\"+contador).prop('disabled', true); \n \t$(\"#errorReplicarVacunas_\"+contador).html('&nbsp;'); \t\t\t\n\t\t\n\t}\n\t\n}", "title": "" }, { "docid": "be8a856a137f648baaafa19ea9ef0cef", "score": "0.4879772", "text": "function registraCarta(codcarta, tipocarta, scadenza, CVV){\n\n var res = richiedi(\"../../Backend/controller/addpayments?ibanorcard=CARD&codice=\"+codcarta+\"&tipocarta=\"+tipocarta+\"&scadenza=\"+scadenza+\"&CVV=\"+CVV+\"&session_id=\"+session_id); \n \n if (res !=0){\n window.open(\"../view/info.html?errorcode=OKPAYTYPE\",\"_self\",false);\n }\n\n else{\n window.open(\"../view/info.html?errorcode=ERROR\",\"_self\",false);\n }\n return false;\n }", "title": "" }, { "docid": "f979a868c5358e5957f95247a140f72c", "score": "0.48760307", "text": "function C43078_Prevents_adding_Charge_to_Room()\n{\n Log.AppendFolder(\"C43078_Prevents_adding_Charge_to_Room\");\n InitializationEnviornment.initiliaze(); \n AppLoginLogout.login(); \n try{\n var keyWordNm =\"Daily Admission\";\n var packageNm =\"Dated\";\n var subPakNm =\"Adult\";\n var givenPaymentType =\"[BillingTypes.Hotel Room Charge]\";\n \n aqUtils.Delay(2000); \n WrapperFunction.selectKeywordName(keyWordNm); \n selectPackage(packageNm,subPakNm); \n if(datetimeformSubWindow.Exists){ \n selectDateFromSubWindow(dateD); //mm-dd-yyyy \n selectNextButtonFromSubWindow();\n Button.clickOnButton(selectablebuttonClosebutton);\n } \n finilizeOrder(); \n aqUtils.Delay(3000); \n \n var expectedSettlemtnttotal = orderDetailsTotal.Caption;\n var applyAmount= (expectedSettlemtnttotal.split('$')[1]).trim(); \n selectPaymentTypeAddRequiredFields(\"Cash\");\n var halfAmt = parseInt(applyAmount)/2 ;\n remainingAmt = applyAmount - halfAmt;\n WrapperFunction.setTextValue(PayamountTextBox,halfAmt);\n Log.Message(\"Apply remaining amount\"); \n Button.clickOnButton(applyButton); \n selectPaymentType(givenPaymentType);\n Hotelnamecombobox.Button(\"openButton\").Click();\n if(Aliases.Passport_POS.wndApolloRuntimeContentWindow.groupDropdown.scroller.datagroup.Exists){\n merlinLogError(\"Options are Enabled.\")\n } \n selectPaymentTypeAddRequiredFields(\"Invoice\");;\n WrapperFunction.setTextValue(PayamountTextBox,remainingAmt); \n Button.clickOnButton(applyButton);\n WrapperFunction.settlementCompleteOrder();\n Log.Message(\"Don't Validate the order\");\n aqUtils.Delay(2000);\n validateTicket(\"Don't Validate\"); \n aqUtils.Delay(3000); \n verifyTotalOnConfirmationPage(expectedSettlemtnttotal);\n var orderId = cnf_orderID1.Caption;\n if (orderId == null){\n merlinLogError(\"Order id is not present\");\n return;\n } \n var OrderID= (orderId.split('#')[1]).trim();\n OrderInfo.prototype.OrderID = OrderID;\n Log.Message(\"Order id is set:\"+OrderID); \n \n } catch (e) {\n\t merlinLogError(\"Oops! There's some glitch in the script: \" + e.message);\n\t return;\n }\n finally { \n\t Log.PopLogFolder();\n } \n AppLoginLogout.logout(); \n}", "title": "" }, { "docid": "400ac8ec477a20c83c9a5d6022023359", "score": "0.48726782", "text": "function accionaCodA(desc, codigo, codigoR){\n\t\n\t\n\tdocument.form.desCodA.value=desc;\n\tdocument.form.codA.value=codigo;\n\tdocument.getElementById(\"codigo_accion\").innerHTML=\"\";\n document.getElementById(\"codigo_accion\").style.border=\"0px\";\n\t\n\tbuscar_codigo_resultado(codigo, codigoR)\n\t\t\n}", "title": "" }, { "docid": "f8322bda5c5d4bd3abb6fa64db3f9cbb", "score": "0.4872218", "text": "function inicializarConversacionLockerF1(){\nconversacionLockerF1 = new ArbolConversacion(texturaCristina,texturaGabriela,texturaCristinaSombreada,texturaGabrielaSombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"¿Será este el cuerpo que buscamos?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Tiene que ser, es el refrigerador que estaba en su memoria\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"Contémosle al fantasma entonces\",1);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\n\nconversacionLockerF1.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "a181865e601bc3ee6b148c7b23c7caa5", "score": "0.48714647", "text": "function CWM_ELP_DPL_54_ASB_validateASIPTCOCheckbox(){\r\ntry{\r\n var asiPTCO = AInfo[\"I certify under the pains and penalties of perjury that I am the board approved PTCO\"];\r\n logDebug(\"asiPTCO \"+asiPTCO);\r\n var vFlag = true;\r\n if(asiPTCO==\"CHECKED\"){\r\n vFlag = false;\r\n }\r\n if(vFlag){ \r\n cancel = true;\r\n showMessage = true;\r\n comment(\"The board approved PTCO must be the individual who completes the renewal of the license. Please contact the board for further instructions.\");\r\n }\r\n}catch(err){\r\n logDebug(\"Error message: \"+err.message);\r\n}\r\n} // end of function", "title": "" }, { "docid": "706bd51e889cc5fec4b12370738f767e", "score": "0.48673669", "text": "function irAAgregarCliente() {\r\n var msg = \"Desea Agregar un NUEVO REGISTRO?.. \";\r\n //Obtengo el valor que define si el formulario a sufrido cambios, para definir el mensaje de confirmacion\r\n var cambiosSinGuardar = $(\"#c_cambios\").val();\r\n if (cambiosSinGuardar == \"true\")\r\n msg =\r\n \"Puede haber cambios sin guardar en el formulario, ¿Desea agregar un NUEVO Registro de todas formas?.\";\r\n if (confirm(msg)) Cons_cliente(\"\", \"agregar\");\r\n}", "title": "" }, { "docid": "9ed273f52ebbfae0d6a75009e14eb8d1", "score": "0.4867018", "text": "function irAAgregarProducto(){\r\n\tvar msg = \"Desea Agregar un NUEVO REGISTRO?.. \";\r\n\tif(confirm(msg)) Cons_producto('', 'AGREGAR');\r\n}", "title": "" }, { "docid": "122766349256ff8776740d2348b76b15", "score": "0.48655358", "text": "function responsableAcuerdo1(){\n function callBackResponsableAcuerdo1(r){\n txtCjhac_responsable.setValue(r);\n }\n SOAPClient.invoke(URL_WS+\"Cgg_jur_proceso_judicial\",'responsableProcesoJudicial',false, false, callBackResponsableAcuerdo1);\n }", "title": "" }, { "docid": "c1f5f2cde6e86c897f1ce5a62f3e4932", "score": "0.48607072", "text": "function estableceFin(evento){\n\tencendido = false;\n}", "title": "" }, { "docid": "d11e100bd3f7d97ea2bf34d015592469", "score": "0.48566082", "text": "function cargarCgg_jur_asesorCtrls(){\n if(inRecordCgg_jur_asesor){\n txtCjase_codigo.setValue(inRecordCgg_jur_asesor.get('CJASE_CODIGO'));\n tmpCjpju_codigo=inRecordCgg_jur_asesor.get('CJPJU_CODIGO');\n txtCjpju_codigo.setValue(inRecordCgg_jur_asesor.get('NUMERO'));\n cbxCjase_activo.setValue(inRecordCgg_jur_asesor.get('CJASE_ACTIVO'));\n isEdit = true;\n habilitarCgg_jur_asesorCtrls(true);\n\n }\n }", "title": "" }, { "docid": "3732ce315ab68e0c594155742287598b", "score": "0.48489553", "text": "function inicializarConversacionNoPuedeMatar(){\nconversacionNoPuedeMatar = new ArbolConversacion(texturaCristina,texturaGabriela,texturaCristinaSombreada,texturaGabrielaSombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Tiene que ser ella, la novia del fantasma. ¿Que deberiamos hacer por ella?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Ayudarla\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"¿Cómo? No se nada de medicina, y ella apenas si está viva\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Entonces ahorrale el sufrimiento, mátala\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"Si, es lo mejor. ¿Cómo será mejor hacerlo?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Ahógala\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"¿Con qué?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Con una toalla puede ser. Si no tienes ninguna, algo nos ha de servir, busquemos por aquí\",2);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\nconversacionNoPuedeMatar.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "674561e767d74422c5282a5a9291593c", "score": "0.48446044", "text": "function CWM_ELP_188_DPL_ASB_validateMALicenseNbr() \r\n{\r\n try\r\n {\r\n // get the board code using lookup Standard Choice\r\n var boardCode = lookup(\"BOARDS\", \"Home Inspectors\");\r\n var vSuperMALicNbr = AInfo[\"MA License Number\"];\r\n\r\n logDebug(\"MA License Number: \" + vSuperMALicNbr);\r\n \r\n // no need to check for License Type variable\r\n if (vSuperMALicNbr != undefined && vSuperMALicNbr != null && vSuperMALicNbr != \"\")\r\n {\r\n var licenseTC = \"1\";\r\n var isMALicenseActive = isLicenseActive(vSuperMALicNbr, boardCode, licenseTC);\r\n if (!isMALicenseActive)\r\n {\r\n // block user from continuing with submission of the application\r\n cancel = true;\r\n showMessage = true;\r\n //message = \"\";\r\n comment(vSuperMALicNbr + \" is not a valid License Number. Contact the Board for further instructions.\");\r\n }\r\n }\r\n }\r\n catch(err)\r\n {\r\n showMessage=true;\r\n logDebug(\"Error in CWM_ELP_188_DPL_ASB_validateMALicenseNbr: \" + err.message);\r\n comment(\"Error on ASB function CWM_ELP_188_DPL_ASB_validateMALicenseNbr, Please contact administrator\");\r\n }\r\n} // END OF FUNCTION: CWM_ELP_188_DPL_ASB_validateMALicenseNbr() ", "title": "" }, { "docid": "a70ff883be4386fabe9e8b0972d72418", "score": "0.48424083", "text": "function init() {\n addEventHandler(document.entradas.nombre, 'keypress', inputAlphanumericOnly);\n addEventHandler(document.entradas.apellido, 'keypress', inputAlphanumericOnly);\n //manda a llamar la funcion de verificacion de correo\n var boton = document.getElementById(\"btnRegistrar\");\n if (boton.addEventListener) {\n boton.addEventListener(\"click\", ValidarNombre, false);\n boton.addEventListener(\"click\", ValidarEmail, false);\n boton.addEventListener(\"click\", ValidarNumTel, false);\n boton.addEventListener(\"click\", ValidarDireccion, false);\n boton.addEventListener(\"click\", ValidarDUI, false);\n boton.addEventListener(\"click\", ValidarNIT, false);\n boton.addEventListener(\"click\", ValidarContra, false);\n }\n else if (boton.attachEvent) {\n boton.addEventListener(\"onclick\", ValidarNombre, false);\n boton.addEventListener(\"onclick\", ValidarEmail, false);\n boton.addEventListener(\"onclick\", ValidarNumTel, false);\n boton.addEventListener(\"onclick\", ValidarDireccion, false);\n boton.addEventListener(\"onclick\", ValidarDUI, false);\n boton.addEventListener(\"onclick\", ValidarNIT, false);\n boton.attachEvent(\"onclick\", ValidarContra);\n }\n}", "title": "" }, { "docid": "60587e7d887352818a6d99f09a57de14", "score": "0.48399884", "text": "function cargarCgg_res_entidad_financieraCtrls(){\n if(inRecordCgg_res_entidad_financiera){\n txtCretf_codigo.setValue(inRecordCgg_res_entidad_financiera.get('CRETF_CODIGO'));\n txtCretf_nombre_entidad.setValue(inRecordCgg_res_entidad_financiera.get('CRETF_NOMBRE_ENTIDAD'));\n txtCretf_descripcion.setValue(inRecordCgg_res_entidad_financiera.get('CRETF_DESCRIPCION'));\n isEdit = true;\n habilitarCgg_res_entidad_financieraCtrls(true);\n }\n }", "title": "" }, { "docid": "0ed1794939e23e358e20694746e8c936", "score": "0.4836838", "text": "function confermaAdeguamentoDisponibilitaAccertamento(){\n // aggiungo il parametro che permette di sfondare la competenza\n $('input[name=\"forzaDisponibilitaAccertamento\"]').val(\"true\");\n // forzo il submit\n $('#formInserimentoPreDocumentoEntrata').submit();\n }", "title": "" }, { "docid": "6898342200ecdedd05e714741e5ff2b4", "score": "0.4836298", "text": "function botonOperativo(){\n var bTmp = dwr.util.byId(window[\"botonEnProcesoId\"]);\n// alrt(\"bTmp = \" + bTmp);\n bTmp.value = window[\"botonEnProcesoValueOld\"];\n bTmp.disabled = false;\n}", "title": "" }, { "docid": "529df90990a9753c0ef498f14896605b", "score": "0.4831768", "text": "function ActivarRequerimiento(control)\n{\n var activar = true;\n var validControl = true;\n nombre = $(\"#input_form\\\\:nombre\").val();\n apaterno = $(\"#input_form\\\\:apaterno\").val();\n amaterno = $(\"#input_form\\\\:amaterno\").val();\n telefono = $(\"#input_form\\\\:telNumber\").val();\n calle = $(\"#input_form\\\\:calle\").val();\n numeroExt = $(\"#input_form\\\\:numeroExt\").val();\n cpostal = $(\"#input_form\\\\:cpostal\").val();\n municipio = $(\"#input_form\\\\:municipio\").val();\n colonia = $(\"#input_form\\\\:colonia\").val();\n estado = $(\"#input_form\\\\:estado\").val();\n area = $(\"#form\\\\:areaInner\").val();\n rfc = $(\"#input_form\\\\:rfc\").val();\n curp = $(\"#input_form\\\\:curp\").val();\n country = $(\"#form\\\\:countryInner\").val();\n email = $(\"#input_form\\\\:email\").val();\n password = $(\"#input_form\\\\:password\").val();\n password2 = $(\"#input_form\\\\:confirm\").val();\n\n\n if (nombre === \"\" || apaterno === \"\" || amaterno === \"\" || telefono === \"\" || calle === \"\" || numeroExt === \"\" || cpostal === \"\" || municipio === \"\")\n activar = false;\n if (colonia === \"\" || estado === \"\" || area === \"\" || rfc === \"\" || curp === \"\" || country === \"\" || email === \"\")\n activar = false;\n if (password === \"\" || password2 === \"\")\n activar = false;\n\n if (control == 'telefono') {\n validControl = validarTelefono();\n }\n if (control == 'rfc') {\n validControl = validRfc();\n }\n if (control == 'email') {\n validControl = validEmail();\n }\n if (control == 'curp') {\n validControl = validCurp();\n }\n if (control == 'confirm') {\n validControl = validPassword();\n }\n if (activar && validControl)\n $(\"#form\\\\:BtnSave\").css(\"display\", \"inline\");//Ocultar el boton de requerimiento\n else\n {\n $(\"#form\\\\:BtnSave\").css(\"display\", \"none\");\n }\n}", "title": "" }, { "docid": "733bf1f5ab20593feff4fc1e63dccb67", "score": "0.4828781", "text": "function ActCC()\n\t{\n\tvar x = document.getElementById('forpagos').value;\n\tvar y = x.split('[||]');\n\tvar cd = y[0]; // Código de Documento\n\tvar ds = y[1]; // Descripción\n\tvar cta = y[2]; // Cuenta Contable\n\tvar dp = y[3]; // Tipo de Pago\n\tvar cc = y[4]; // Centro de Costo\n\tvar td = y[5]; // Conciliacion\n\t\n\t/* Activa Centro de costo */\n\tif (cc=='S') { document.getElementById('ccosto').disabled=false; }\n\telse { document.getElementById('ccosto').disabled=true; }\n\n\t/* Si el pago es con Cheque a Fecha, Muestro zona oculta */\n\tif (cd=='CH') { document.getElementById('oculto').style.display='block'; }\n\telse { document.getElementById('oculto').style.display='none'; }\n\n\t/* Activa Conciliacion si TipoDocumentoConciliacion es Diferente a 00 */\n\tif (td!='00')\n\t\t{\n\t\tdocument.getElementById('tipdoccon').disabled=false;\n\t\tif ($.trim(td)!='')\n\t\t\t{\n\t\t\tdocument.getElementById('areanumdoccb').style.display='block';\n\t\t\t}\n\t\telse \n\t\t\t{\n\t\t\tdocument.getElementById('areanumdoccb').style.display='none';\n\t\t\t}\n\t\t}\n\telse\n\t\t{\n\t\tdocument.getElementById('tipdoccon').disabled=true;\n\t\tdocument.getElementById('areanumdoccb').style.display='none';\n\t\t}\n\t$('#cc').val(cc);\n\t$('#ctable').val(cta);\n\t}", "title": "" }, { "docid": "6644649752e5a7371f74428dcfe4f681", "score": "0.4828674", "text": "function btEnable(){\n\t\tstoreThis.refreshThis.noOrdersSelected();\n\t\t\t\tvar exeBt = st == 'cooking' ? btconfig.cookedStr : st =='new' || st=='hold'? btconfig.confStr : btconfig.curStr;\n\t\tgui.enableBtn('status', 'button_click',exeBt);\n\t\t$('status').set('text',btconfig.newStat);\n\t\tbtAction(btconfig.newAct);\n\t}", "title": "" }, { "docid": "a568720ecbb3101a64ddc1a28a6eb6cc", "score": "0.48254174", "text": "function CWM_ELP_337_DPL_ASB_CheckMinRowLicProvidingServicesAndValidateLicType()\r\n{\r\n var ownershipRow = 0; \r\n var minRows = 1;\r\n var flag = 0;\r\n try \r\n {\r\n if(!publicUser){\r\n loadASITablesBefore();\r\n }else if(publicUser){\r\n loadASITForACA();\r\n }\r\n //Get the board code from the Std Choice list\r\n var vBoardCode = lookup(\"BOARDS\", \"Cosmetologists\");\r\n var vLicenseTypeCode = \"0\";\r\n ownershipRow = LICENSEESPROVIDINGSERVICES.length;\r\n for(x in LICENSEESPROVIDINGSERVICES){\r\n var vLicenseName = LICENSEESPROVIDINGSERVICES[x][\"Name of Licensee\"];\r\n var vLicenseType = LICENSEESPROVIDINGSERVICES[x][\"License Type\"]; \r\n var vLicenseNbr = LICENSEESPROVIDINGSERVICES[x][\"License Number\"]; \r\n if((vLicenseName.length() != 0) || (vLicenseType.length()!=0) || (vLicenseNbr.length()!=0)){\r\n flag = 1;\r\n if((vLicenseType.length()!=0) && (vLicenseNbr.length()!=0))\r\n {\r\n if (vLicenseType == \"Type 1 - Cosmetologist\") {\r\n vLicenseTypeCode = \"1\";\r\n } else if (vLicenseType == \"Type 2 - Cosmetologist Operator\") {\r\n vLicenseTypeCode = \"2\";\r\n } else if (vLicenseType == \"Type 3 - Manicurist\") {\r\n vLicenseTypeCode = \"3\";\r\n }\r\n else\r\n {\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"The License Number \"+vLicenseNbr+\" is not a valid license or is not in a Current status.\");\r\n } \r\n if(isLicenseActive(vLicenseNbr, vBoardCode, vLicenseTypeCode)) {\r\n var RefLicProf = getRefLicenseProf(vLicenseNbr, vBoardCode, vLicenseTypeCode);\r\n if (RefLicProf){ \r\n if (RefLicProf.getPolicy() != \"Current\") {\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"The License Number \"+vLicenseNbr+\" is not a valid license or is not in a Current status.\");\r\n }\r\n }\r\n }\r\n else\r\n {\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"The License Number \"+vLicenseNbr+\" is not a valid license or is not in a Current status.\");\r\n }\r\n }\r\n }\r\n } \r\n logDebug(\"Number of ownershipRow: \"+ownershipRow);\r\n } \r\n catch (ex) \r\n {\r\n if (ownershipRow < minRows) \r\n {\r\n flag = 0;\r\n }\r\n \r\n }\r\n if(flag == 0){\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"At least one Licensee Providing Services must be added.\");\r\n }\r\n \r\n}//END OF FUNCTION: CWM_ELP_337_DPL_ASB_CheckMinRowLicProvidingServicesAndValidateLicType", "title": "" }, { "docid": "cf4934a5dac813b6734284664d616d44", "score": "0.48247853", "text": "function CWM_ELP_ASB_DEFECT_5044(){\r\nlogDebug(\"Entering CWM_ELP_ASB_DEFECT_5044\");\r\n useAppSpecificGroupName = true;\r\n var asi = new Array();\r\n var licNbr = null;\r\n loadAppSpecificBefore(asi);\r\n for(asiLabel in asi)\r\n {\r\n if(asiLabel==\"ADD NEW RELATIONSHIP.License Number\")\r\n {\r\n if(asi[asiLabel]!= \"\")\r\n {\r\n//logDebug(\"ADD NEW RELATIONSHIP has a license number entered\");\r\n licNbr = asi[asiLabel];\r\n if(isInactive(licNbr,\"SM\")){\r\nlogDebug(\"license is inactive\");\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"License entered is not current, please contact the Board\");\r\n }\r\n break;\r\n }\r\n } \r\n }\r\n useAppSpecificGroupName = false;\r\n}", "title": "" }, { "docid": "af7144a5c1c53108ec09b0f4a0c22996", "score": "0.48095223", "text": "function altaEditCursos(){\n\tif(accionCurso === 'altaCursos' && $('#imgfile2').val() !== ''){\n\t\tcadenaRandom(8);\n\t\tfotoPDF2 = cadAleatoria;\n\t}\n\tvar jsonCursos = {\n\t\tid: idCurso,\n\t\tidEmpresa: idEmpresaCurso,\n\t\tnomEmpresa: $('#nomEmpresa').val(),\n\t\tcurso: $('#nomCurso').val(),\n\t\tduracion: $('#duracion').val(),\n\t\tinicio: $('#fechaIni').val(),\n\t\tfin: $('#fechaFin').val(),\n\t\tarea: $('#cursosCat option:selected').text(),\n\t\tinstructor: $('#instructor').val(),\n\t\tstps: $('#capacitador').val(),\n\t\timagen: fotoPDF2\n\t};\n\n\t$.confirm({\n\t title: tituloCursoAccion,\n\t content: descCursoAccion,\n\t buttons: {\n\t guardar: {\n\t text: 'Guardar',\n\t btnClass: 'btn-default',\n\t action: function(){\n\t $.ajax({\n\t\t\t\t\t\turl:'rutas/rutaCursos.php',\n\t\t\t\t\t\ttype:'POST',\n\t\t\t\t\t\tdata: {info: jsonCursos, action: accionCurso},\n\t\t\t\t\t\tdataType:'JSON',\n\t\t\t\t\t\terror: function(error){\n\t\t\t\t\t\t\tconsole.log(error);\n\t\t\t\t\t\t\t//removeSpinner();\n\t\t\t\t\t\t},\n\t\t\t\t\t\tsuccess: function(data){\n\t\t\t\t\t\t\t//removeSpinner();\n\n\t\t\t\t\t\t\tif(fotoPDF2 !== 'sin-foto' || fotoPDF2 !== 'noeditar'){\n\t\t\t\t\t\t\t\tvar imgEmpresa = document.getElementById(\"imgfile2\").files[0];\n\t\t\t\t\t\t\t\tvar data = new FormData();\n\t\t\t\t\t\t\t\tdata.append('archivo', imgEmpresa);\n\t\t\t\t\t\t\t\tdata.append('nombre', cadAleatoria);\n\n\t\t\t\t\t\t\t\t$.ajax({\n\t\t\t\t\t\t\t\t\turl: \"clases/imgBase64.php\",\n\t\t\t\t\t\t\t\t\ttype: \"POST\",\n\t\t\t\t\t\t\t\t\tcache: false,\n\t\t\t\t\t\t\t\t\tcontentType: false,\n\t\t\t\t\t\t\t\t\tdata: data,\n\t\t\t\t\t\t\t\t\tprocessData: false,\n\t\t\t\t\t\t\t\t\terror: function(error){\n\t\t\t\t\t\t\t\t\t\tconsole.log(error);\n\t\t\t\t\t\t\t\t\t\t//removeSpinner();\n\t\t\t\t\t\t\t\t\t},\n\t\t\t\t\t\t\t\t\tsuccess: function(data){\n\t\t\t\t\t\t\t\t\t\tlimpiarModalCursos();\n\t\t\t\t\t\t\t msgMulti('Exito', 'Curso guardado con exito', 6000, 'success');\n\t\t\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\t\t});\n\t\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\t\tlimpiarModalCursos();\n\t\t\t\t\t\t\t msgMulti('Exito', 'Curso guardado con exito', 6000, 'success');\n\t\t\t\t\t\t\t}\n\n\t\t\t\t\t\t\t/*$.confirm({\n\t\t\t\t\t\t\t title: 'Limpiar Campos',\n\t\t\t\t\t\t\t content: '¿Decea limpiar el formulario?',\n\t\t\t\t\t\t\t buttons: {\n\t\t\t\t\t\t\t guardar: {\n\t\t\t\t\t\t\t text: 'Limpiar',\n\t\t\t\t\t\t\t btnClass: 'btn-info',\n\t\t\t\t\t\t\t action: function(){\n\t\t\t\t\t\t\t \tlimpiarModalCursos();\n\t\t\t\t\t\t\t \tmsgMulti('Exito', 'Curso guardado con exito', 6000, 'success');\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t },\n\t\t\t\t\t\t\t noguardar: {\n\t\t\t\t\t\t\t text: 'Mantener valores',\n\t\t\t\t\t\t\t btnClass: 'btn-default',\n\t\t\t\t\t\t\t action: function(){\n\t\t\t\t\t\t\t \tmsgMulti('Exito', 'Curso guardado con exito', 6000, 'success');\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t }\n\t\t\t\t\t\t\t});*/\n\t\t\t\t\t\t//FIN DE SUCCESS\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t }\n\t },\n\t noguardar: {\n\t text: 'Cancelar',\n\t btnClass: 'btn-danger',\n\t action: function(){}\n\t }\n\t }\n\t});\n}", "title": "" }, { "docid": "1d578a095fc6801ce340742ff2c61b5d", "score": "0.48085994", "text": "function anterior(c){\r\n\r\n\tvar cc0=\"txtTipoMe\"+c;\r\n\tvar cc1=\"txtTipoMeH\"+c;\r\n\tvar cc2=\"txtLote\"+c;\r\n\tvar cc3=\"txtInvima\"+c;\r\n\tvar cc4=\"txtVence\"+c;\r\n\tvar cc5=\"txtCantidad\"+c;\r\n\tvar cc6=\"txtVunitario\"+c;\r\n\tvar cc7=\"txtProvee\"+c;\r\n\tvar cc8=\"txtInv\"+c;\r\n\tvar cc9=\"txtCa\"+c;\r\n\tvar datos22=\"txtM\"+c;\r\n\t\r\n\tvar a8=document.getElementById(cc8).value;\r\n\t\r\n\t\r\n\tvar datos5=document.getElementById(datos22);\r\n\tvar datos2=encodeURIComponent(datos5.value);\r\n\t\r\n\t//recuerda a8 campo de inventario para no repetir\r\n\t//alert(\"El valor de c: \"+c+ \" el valor del campo \"+a8);\r\n\tfor(y=0; y<c; y++){\r\n\t\tvar vs=\"txtInv\"+y;\r\n\t\tvar vss=document.getElementById(vs).value;\r\n\t\tif(vss==a8){\r\n\t\t\talert(\"Solo puede generar 1 movimiento del mismo articulo!!!\");\r\n\t\t\tdocument.getElementById(cc0).value=\"\";\r\n\t\t\tdocument.getElementById(cc1).value=\"\";\r\n\t\t\tdocument.getElementById(cc2).value=\"\";\r\n\t\t\tdocument.getElementById(cc3).value=\"\";\r\n\t\t\tdocument.getElementById(cc4).value=\"\";\r\n\t\t\tdocument.getElementById(cc5).value=\"\";\r\n\t\t\tdocument.getElementById(cc6).value=\"\";\r\n\t\t\tdocument.getElementById(cc7).value=\"\";\r\n\t\t\tdocument.getElementById(cc8).value=\"\";\r\n\t\t\tdocument.getElementById(cc9).value=\"\";\r\n\t\t\tdocument.getElementById(cc0).focus();\r\n\t\t}\r\n\t\t//alert(\"lo hice \"+(y+1)+\" vez\");\r\n\t}\t\r\n}", "title": "" }, { "docid": "b79992baea3c61d54c65ee49d474a8dc", "score": "0.48060712", "text": "function CWM_ELP_DPL_401_ASB_validateASITOnReciprocity() {\r\n try {\r\n var vYouAreApplyingThrough = null;\r\n //Get AppSpecificInfo details\r\n if (publicUser) // HANDLE ACA PAGEFLOW\r\n {\r\n /*var cap = aa.env.getValue('CapModel');\r\n var currentCapId = cap.getCapID();*/\r\n vYouAreApplyingThrough = AInfo[\"You are applying through\"];\r\n }else if(!publicUser){\r\n useAppSpecificGroupName = true;\r\n var myAInfo = new Array();\r\n loadAppSpecificBefore(myAInfo);\r\n vYouAreApplyingThrough = myAInfo[\"APPLICATION TYPE.You are applying through\"];\r\n useAppSpecificGroupName = false;\r\n } \r\n if (vYouAreApplyingThrough != null && vYouAreApplyingThrough == \"Reciprocity\") {\r\n var rowCountFlag = CWM_ELP_401_DPL_ASB_CheckMinRowLicenseinOtherJurisdictions();\r\n if(rowCountFlag == 0){\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"When applying through Reciprocity, License in Other Jurisdictions must contain your current license information.\");\r\n }\r\n }\r\n } catch (err) {\r\n useAppSpecificGroupName = false;\r\n cancel = true;\r\n showMessage = true;\r\n comment(\"ERROR:When applying through Reciprocity, License in Other Jurisdictions must contain your current license information.\");\r\n }\r\n}// END OF FUNCTION: CWM_ELP_DPL_401_ASB_validateASITOnReciprocity", "title": "" }, { "docid": "7373b22e1f0d424e315d1eed0af8b5c5", "score": "0.48000583", "text": "function cargarCgg_veh_cilindrajeCtrls(){\n if(inRecordCgg_veh_cilindraje){\n txtCvcln_codigo.setValue(inRecordCgg_veh_cilindraje.get('CVCLN_CODIGO'));\n numCvcln_cilindraje.setValue(inRecordCgg_veh_cilindraje.get('CVCLN_CILINDRAJE'));\n txtCvcln_observacion.setValue(inRecordCgg_veh_cilindraje.get('CVCLN_OBSERVACION'));\n isEdit = true;\n habilitarCgg_veh_cilindrajeCtrls(true);\n }\n}", "title": "" }, { "docid": "26f86812b9320a581f58bb117c1f7b61", "score": "0.47999924", "text": "function habilitaCamposTipoCancer(miCampo){\n\n\n//el dato no es vacio y está dentro del rango de 1 y 3\n //HABILITAMOS Y DESHABILITAMOS CAMPOS SEGÚN SIVIGILA ESCRITORIO\n\n //variables cáncer cuello uterino\n var miFecTomaE = document.getElementById('FEC_TOMA_E');\n var miFecResEx = document.getElementById('FEC_RES_EX');\n var miBiopExoce = document.getElementById('BIOP_EXOCE');\n var miResBExoc = document.getElementById('RES_B_EXOC');\n var miGradoHist = document.getElementById('GRADO_HIST');\n var miBiopEndoc = document.getElementById('BIOP_ENDOC');\n var miResBAden = document.getElementById('RES_B_ADEN');\n var miResBHist = document.getElementById('RES_B_HIST');\n\n\n\n//variables cáncer de mama\n var miFecProCo = document.getElementById('FEC_PRO_CO');\n var miFecResBi = document.getElementById('FEC_RES_BI');\n var miResBiops9 = document.getElementById('RES_BIOPS9');\n var miGradHisto = document.getElementById('GRAD_HISTO');\n\n //validamos el tipo de cancer para inhabilitar los demás controles\n if(miCampo.value ==1){\n //deshabilitamos campos de cancer de cuello uterino\n miFecTomaE.disabled=true;\n miFecResEx.disabled=true;\n miBiopExoce.disabled=true;\n miResBExoc.disabled=true;\n miGradoHist.disabled=true;\n miBiopEndoc.disabled=true;\n miResBAden.disabled=true;\n miResBHist.disabled=true;\n\n //limpiamos los campos de cancer de cuello uterino\n miFecTomaE.value=\"\";\n miFecResEx.value=\"\";\n miBiopExoce.value=\"\";\n miResBExoc.value=\"\";\n miGradoHist.value=\"\";\n miBiopEndoc.value=\"\";\n miResBAden.value=\"\";\n miResBHist.value=\"\";\n\n\n\n //habilitamos campos de cáncer de mama\n miFecProCo.disabled=false;\n miFecResBi.disabled=false;\n miResBiops9.disabled=false;\n miGradHisto.disabled=false;\n\n\n }\n else if(miCampo.value ==2){\n //deshabilitamos campos de cancer de mama\n miFecProCo.disabled=true;\n miFecResBi.disabled=true;\n miResBiops9.disabled=true;\n miGradHisto.disabled=true;\n\n //limpiamos campos de cancer de mama\n miFecProCo.value=\"\";\n miFecResBi.value=\"\";\n miResBiops9.value=\"\";\n miGradHisto.value=\"\";\n\n //habilitamos campos de cancer de cuello uterino\n miFecTomaE.disabled=false;\n miFecResEx.disabled=false;\n miBiopExoce.disabled=false;\n miResBExoc.disabled=false;\n miGradoHist.disabled=false;\n miBiopEndoc.disabled=false;\n miResBAden.disabled=false;\n miResBHist.disabled=false; \n\n }\n else if(miCampo.value ==3){\n\n //habilitamos campos de cáncer de mama\n miFecProCo.disabled=false;\n miFecResBi.disabled=false;\n miResBiops9.disabled=false;\n miGradHisto.disabled=false;\n //habilitamos campos de cancer de cuello uterino\n miFecTomaE.disabled=false;\n miFecResEx.disabled=false;\n miBiopExoce.disabled=false;\n miResBExoc.disabled=false;\n miGradoHist.disabled=false;\n miBiopEndoc.disabled=false;\n miResBAden.disabled=false;\n miResBHist.disabled=false; \n\n }\n\n\n}", "title": "" }, { "docid": "353ea03a2d443a0c5dc6df24d45eeb71", "score": "0.47992963", "text": "function CWM_ELP_Defect_4280_DPL_ASB_addConditionContactPermit() {\r\n try{\r\n var appLicNum = AInfo[\"License Number\"];\r\n var busLicNum = AInfo[\"Business License #\"];\r\n var vLicType = AInfo[\"License Type\"];\r\n if(vLicType==\"Master Plumber\" || vLicType==\"Journeyman Plumber\"){\r\n var boardCode = lookup(\"BOARDS\", \"Plumbers\");\r\n }\r\n else {\r\n var boardCode = lookup(\"BOARDS\", \"Gas Fitters\"); \r\n }\r\n if(appMatch(\"License/Plumbers and Gas Fitters/Permits/Gas Fitting Permit\")){\r\n var fullLicNum = returnCompleteAltId(appLicNum, boardCode, vLicType);\r\n if(fullLicNum){\r\n var licProfObj = getRefLicenseProf(fullLicNum);\r\n if(licProfObj){\r\n if (licProfObj.getPolicy() != \"Current\") {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"The \"+vLicType+\" \"+appLicNum+\" is not Current, please contact the Board.\");\r\n }\r\n \r\n \r\n }\r\n else {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"The \"+vLicType+\" \"+appLicNum+\" does not exist. Please contact the board for further details.\");\r\n \r\n }\r\n }\r\n else {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"The \"+vLicType+\" \"+appLicNum+\" does not exist. Please contact the board for further details.\");\r\n \r\n }\r\n }\r\n else {\r\n var fullLicNum = returnCompleteAltId(appLicNum, boardCode, vLicType);\r\n if(fullLicNum){\r\n if(vLicType==\"Master Plumber\" || vLicType==\"Journeyman Plumber\"){\r\n var licProfObj = getRefLicenseProf(fullLicNum);\r\n if(licProfObj){\r\n if (licProfObj.getPolicy() != \"Current\") {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"The \"+vLicType+\" \"+appLicNum+\" is not Current, please contact the Board.\");\r\n }\r\n \r\n \r\n }\r\n else {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"The \"+vLicType+\" \"+appLicNum+\" does not exist. Please contact the board for further details.\");\r\n \r\n }\r\n }\r\n else {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"You must provide a current Master or Journeyman Plumber license. Please contact the board for further details.\");\r\n \r\n \r\n }\r\n }\r\n else {\r\n showMessage=true;\r\n cancel=true;\r\n message=\"\";\r\n comment(\"The \"+vLicType+\" \"+appLicNum+\" does not exist. Please contact the board for further details.\");\r\n \r\n }\r\n }\r\n\r\n\r\n\r\n\r\n\r\n var contactCount = 0;\r\n var peopleModel;\r\n var arrayList = aa.env.getValue(\"ContactList\");\r\n var capContactArray = arrayList.toArray();\r\n logDebug(\"capContactArray = \" + capContactArray[0]);\r\n\r\n if (capContactArray) {\r\n for (var yy in capContactArray) {\r\n peopleModel = capContactArray[yy].getPeople();\r\n logDebug(\"CONTACT TYPE\" + peopleModel.getContactType());\r\n if ((peopleModel.getContactType() == \"Permit Applicant\") || (peopleModel.getContactType() == \"Permit Business\")) {\r\n contactCount = contactCount + 1;\r\n }\r\n\r\n //******Permit Applicant and Permit Business validation START ******\r\n if (peopleModel.getContactType() == \"Permit Applicant\") {\r\n //Required field validation\r\n if (!peopleModel.firstName || !peopleModel.lastName || !peopleModel.preferredChannel) {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"First name, last name and Preferred Communication fields are required for Permit Applicant contact.\");\r\n }\r\n\r\n //If preferred channel is Email, the Email field required\r\n if (peopleModel.preferredChannel == 1 && !peopleModel.email) {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"For Permit Applicant Contact, please provide email address if preferred communication channel is Email.\");\r\n }\r\n } else if (peopleModel.getContactType() == \"Permit Business\") {\r\n //Required field validation\r\n if (!peopleModel.businessName || !peopleModel.preferredChannel) {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"Entity name and Preferred Communication fields are required for Permit Business contact.\");\r\n }\r\n\r\n //If preferred channel is Email, the Email field required\r\n if (peopleModel.preferredChannel == 1 && !peopleModel.email) {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"For Permit Business contact, please provide email address if preferred communication channel is Email.\");\r\n }\r\n }\r\n //******Permit Applicant and Permit Business Contact validation END ******\r\n }\r\n }\r\n if (contactCount < 1) {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"Either Permit Applicant or Permit Business Contact must be added to submit the record.\");\r\n } \r\n}\r\ncatch(error){\r\n cancel = true;\r\n logDebug(\"An error has been thrown in CWM_ELP_Defect_4280_DPL_ASB_addConditionContactPermit.\");\r\n logDebug(error.message);\r\n}\r\n \r\n}", "title": "" }, { "docid": "5c2713e91b5188266d9eb910f7d0a492", "score": "0.47988346", "text": "function mostrarEnvioFormulario(){\t\n\t$(\"#barfinal\").html('<div style=\"text-align: center;\"><button type=\"button\" id=\"btnSatisfaccion\" class=\"btn btn-lg btn-primary\">Enviar Formulario</button></div>');\n\t$(\"#btnSatisfaccion\").bind(\"click\",function(){\t\t\n\t\tvar url = base_url + \"encuesta/\";\n\t\t$(location).attr(\"href\",url);\n\t});\n}", "title": "" }, { "docid": "155d145726df0e6716faeb8d1b2db76c", "score": "0.4796888", "text": "function inicioApp(){\n btnEnviar.disabled = true; \n}", "title": "" }, { "docid": "5f89e56e1fcc153ebad58d598894d542", "score": "0.4796658", "text": "function inicializarConversacionF3Paila(){\nconversacionF3Paila = new ArbolConversacion(texturaCristina,texturaF3,texturaCristinaSombreada,texturaF3Sombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Es este ¿Verdad?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"... No, no es ese. El mio era de oro\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"No puede ser, el alambre se a roto. Tal vez si...\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"No te desgates, ya me acostumbré a fallarle a mi esposa. Puedo morir como un fracasado, \\ngrácias por tu esfuerzo\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"Esto no está bien...\",1);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\n\nconversacionF3Paila.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "a3259b8f304faf1639627a0ec275e39c", "score": "0.47949228", "text": "function TelaConfigurarSerial(){\r\n var codigoHTML;\r\n\r\n codigoHTML='<h4 class=\"text-center\">Serial Atual</h4>'\r\n codigoHTML+='<h5 class=\"text-center\" style=\"margin-top:50px\">Data Atual: <span class=\"badge badge-success\">'+localStorage.getItem(\"dataAtualLicencaSisvep\")+'</span> - Licença até: <span class=\"badge badge-danger\">'+localStorage.getItem(\"dataFimLicencaSisvep\")+'</span></h5>'\r\n codigoHTML+='<hr class=\"my-6 bg-dark\" style=\"margin-top:50px\">'\r\n codigoHTML+='<h4 class=\"text-center\" style=\"margin-top:50px\">Cadastrar Novo Serial</h4>'\r\n codigoHTML+='<form style=\"margin-top:50px\">'\r\n codigoHTML+='<div class=\"form-row\">'\r\n codigoHTML+='<input id=\"dataFim\" type=\"date\" class=\"form-control col-md-8\" placeholder=\"Número Pedido\">'\r\n codigoHTML+='<button onclick=\"cadastrarSerial();\" type=\"button\" class=\"btn btn-light border border-dark col-md-3\">'\r\n codigoHTML+='<span class=\"fas fa-search\"></span> Cadastrar'\r\n codigoHTML+='</button>'\r\n codigoHTML+='</div>'\r\n codigoHTML+='</form>'\r\n\r\n document.getElementById('janela2').innerHTML = codigoHTML;\r\n}", "title": "" }, { "docid": "bc46757ec5aa4985410b959626a9335c", "score": "0.47914463", "text": "function inicializarConversacionF1Ayudar(){\nconversacionF1Ayudar = new ArbolConversacion(texturaCristina,texturaF1,texturaCristinaSombreada,texturaF1Sombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Si, ese es mi cuerpo, lo recuerdo claramente... Dios, está horrible\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"No esperarás que haga algo al respecto ¿Verdad?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"No, tranquila, ya has hecho suficiente por mi, ya puedo irme en paz\",2);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\n\nconversacionF1Ayudar.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "0e920d4b5c5329025063730cb605f3a5", "score": "0.478829", "text": "function set_onclick_event_to_cuvar_bt() {\r\n\tvar controlUnitVars = document.getElementsByClassName(\"cuVarBt\");\r\n\t// Ricerca degli oggetti html associati\r\n\tfor (i = 0; i < controlUnitVars.length; i++) {\r\n\t\tif (controlUnitVars[i].id) {\r\n\t\t\tif (is_visible(controlUnitVars[i])) {\r\n\t\t\t}\r\n\t\t\tif (controlUnitVars[i].tagName=='INPUT') {\r\n\t\t\t\tif (controlUnitVars[i].type=='button') {\r\n\t\t\t\t\tif(window.addEventListener) {\r\n\t\t\t\t\t\tcontrolUnitVars[i].addEventListener('onclick', function(){ process_cuvar_button(this); }, false);\r\n\t\t\t\t\t} else if (window.attachEvent){\r\n\t\t\t\t\t\tcontrolUnitVars[i].attachEvent('onclick', function(){ process_cuvar_button(this); }, false);\r\n\t\t\t\t\t}\r\n\t\t\t\t\tcontrolUnitVars[i].onclick = function() { process_cuvar_button(this); };\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t}\t\r\n}", "title": "" }, { "docid": "516ba43221c782a3a9b6a86873edb16b", "score": "0.4785152", "text": "function botonEnProceso(idBoton){\n var bTmp = dwr.util.byId(idBoton);\n window[\"botonEnProcesoId\"] = idBoton;\n window[\"botonEnProcesoValueOld\"] = bTmp.value;\n bTmp.value = \"Procesando\";\n bTmp.disabled = true;\n}", "title": "" }, { "docid": "d5621a441854faf06e4258c4c6eba497", "score": "0.47844577", "text": "function inicializarConversacionLockerF2(){\nconversacionLockerF2 = new ArbolConversacion(texturaCristina,texturaGabriela,texturaCristinaSombreada,texturaGabrielaSombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Aquí está el locker, pero necesitaré algo para forzar la puerta\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"¿Una palanca tal vez? Hay que buscar algo que se le parezca\",2);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\n\nconversacionLockerF2.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "993f5306355d6c048f00c5f1aa223b29", "score": "0.47839713", "text": "function aXActivate()\n{\n //In/Out Port\n selAlarmInPort.options.length = 0;\n selInPort.options.length = 0;\n selOutPort.options.length = 0;\n selAlarmOutPort.options.length = 0;\n\n var\tarrPortNum\t=\tTiandyVideo.Commander(Alarm_PortCnt_Get,iCurLogon,0,0,0,0,0,0,0,0).split('\\n')[1].split(splitCode);\n\n iAlarmInPortNum = parseInt(arrPortNum[0]);\n iAlarmOutPortNum = parseInt(arrPortNum[1]);\n if((iAlarmInPortNum > 0) && (iAlarmInPortNum < 9))\n {\n for(i=1;i<=iAlarmInPortNum;i++)\n {\n opt = new Option(i);\n selAlarmInPort.options.add(opt);\n }\n for(i=1;i<=iAlarmInPortNum;i++)\n {\n opt = new Option(i);\n selInPort.options.add(opt);\n }\n }\n if((iAlarmOutPortNum > 0) && (iAlarmOutPortNum < 9))\n {\n for(i=1;i<=iAlarmOutPortNum;i++)\n {\n opt = new Option(i);\n selAlarmOutPort.options.add(opt);\n }\n for(i=1;i<=iAlarmOutPortNum;i++)\n {\n opt = new Option(i);\n selOutPort.options.add(opt);\n }\n }\n chkbOutLink1.disabled = false;\n chkbOutLink2.disabled = false;\n chkbOutLink3.disabled = false;\n chkbOutLink4.disabled = false;\n if(iAlarmOutPortNum == 0)\n { chkbOutLink1.disabled = true;\n chkbOutLink2.disabled = true;\n chkbOutLink3.disabled = true;\n chkbOutLink4.disabled = true;\n }\n else if(iAlarmOutPortNum == 1)\n {\n chkbOutLink2.disabled = true;\n chkbOutLink3.disabled = true;\n chkbOutLink4.disabled = true;\n }\n else if(iAlarmOutPortNum == 2)\n {\n chkbOutLink3.disabled = true;\n chkbOutLink4.disabled = true;\n }\n else if(iAlarmOutPortNum == 3)\n {\n chkbOutLink4.disabled = true;\n }\n //Selected\n selAlarmInPort.selectedIndex = 0;\n selInPort.selectedIndex = 0;\n selAlarmOutPort.selectedIndex = 0;\n\n txRegIP2.disabled = true;\n txRegIP2.style.backgroundColor = BACKCOLOR;\n txRegIP2.value = JS_cMsg1;\n txRegPort2.disabled = true;\n txRegPort2.style.backgroundColor = BACKCOLOR;\n txRegPort2.value = JS_cMsg2;\n\n iMaxVideoSize = TiandyVideo.Commander(Video_MaxSize_Get,iCurLogon,0,0,0,0,0,0,0,0).split('\\n')[1];\n iMaxMinorSize = TiandyVideo.Commander(Video_MaxMinorSize_Get,iCurLogon,0,0,0,0,0,0,0,0).split('\\n')[1];\n if(iMaxVideoSize == 0)iMaxVideoSize = 3;\n if (iMaxVideoSize == 12)\n {\n if (slVideoSize.options.length==12) {return;}\n }\n else if (iMaxVideoSize == 11)\n {\n if (slVideoSize.options.length==11) {return;}\n }\n else if (iMaxVideoSize == 10)\n {\n if (slVideoSize.options.length==10) {return;}\n }\n else if (iMaxVideoSize == 9)\n {\n if (slVideoSize.options.length==9) {return;}\n }\n else if (iMaxVideoSize == 4)\n {\n if (slVideoSize.options.length==5) {return;}\n }\n else if (iMaxVideoSize == 3)\n {\n if (slVideoSize.options.length==4) {return;}\n }\n else\n {\n }\n slVideoSize.options.length = 0;\n if (iMaxVideoSize == 12)\n {\t//(\"Quarter Cif\",\"Half Cif\",\"Full Cif\",\"Half D1\",\"Full D1\");\n opt = new Option(\"Quarter Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"QVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"HVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"VGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"720P\");\n slVideoSize.options.add(opt);\n opt = new Option(\"960P\");\n slVideoSize.options.add(opt);\n opt = new Option(\"200W\");\n slVideoSize.options.add(opt);\n opt = new Option(\"1080P\");\n slVideoSize.options.add(opt);\n }\n else if (iMaxVideoSize == 11)\n {\t//(\"Quarter Cif\",\"Half Cif\",\"Full Cif\",\"Half D1\",\"Full D1\");\n opt = new Option(\"Quarter Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"QVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"HVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"VGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"720P\");\n slVideoSize.options.add(opt);\n opt = new Option(\"960P\");\n slVideoSize.options.add(opt);\n opt = new Option(\"200W\");\n slVideoSize.options.add(opt);\n }\n else if (iMaxVideoSize == 10)\n {\t//(\"Quarter Cif\",\"Half Cif\",\"Full Cif\",\"Half D1\",\"Full D1\");\n opt = new Option(\"Quarter Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"QVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"HVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"VGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"720P\");\n slVideoSize.options.add(opt);\n opt = new Option(\"960P\");\n slVideoSize.options.add(opt);\n }\n else if (iMaxVideoSize == 9)\n {\n opt = new Option(\"Quarter Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"QVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full Cif\");\n slVideoSize.options.add(opt);\n opt = new Option(\"HVGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Half D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"VGA\");\n slVideoSize.options.add(opt);\n opt = new Option(\"Full D1\");\n slVideoSize.options.add(opt);\n opt = new Option(\"720P\");\n slVideoSize.options.add(opt);\n }else if(iMaxVideoSize == 7)\n {\n for(i=0;i<=4;i++)\n {\n opt = new Option(arrayVideoSize[i]);\n slVideoSize.options.add(opt);\n }\n }\n else\n {\n for(i=0;i<=iMaxVideoSize;i++)\n {\n opt = new Option(arrayVideoSize[i]);\n slVideoSize.options.add(opt);\n }\n }\n}", "title": "" }, { "docid": "42371573eb283380546200044354cadd", "score": "0.47761744", "text": "function cambiarEstadoRdnBtnTipoContrato(){\n\tvar objTipoDocumento = document.getElementById(\"tipoDocumento\");\n\tvar strSelectedValue = objTipoDocumento.options[objTipoDocumento.selectedIndex].value;\n\tvar strSelectedText = objTipoDocumento.options[objTipoDocumento.selectedIndex].text;\n\tvar objTipoContrato1 = document.getElementById(\"tipoObra1\");\n\tvar objTipoContrato2 = document.getElementById(\"tipoObra2\");\n\tif(strSelectedText==\"Contrato\"){\n\t\t//alert(\"Activar tipo contrato\");\n\t\tobjTipoContrato1.disabled = false;\n\t\tobjTipoContrato2.disabled = false;\n\t\tobjTipoContrato2.checked = \"checked\";\n\t}else{\n\t\t//alert(\"Desactivar tipo contrato\");\n\t\tobjTipoContrato1.disabled = true;\n\t\tobjTipoContrato2.disabled = true;\n\t\tobjTipoContrato1.checked = \"\";\n\t\tobjTipoContrato2.checked = \"\";\n\t}\n\treturn \"\";\n}", "title": "" }, { "docid": "88164b563ad36a5b6836203e4747ccd7", "score": "0.47743738", "text": "function anularOrden(id_orden_compra, clave, fecha_anulacion_compromiso){\n\t\n\tvar cofinanciamiento = document.getElementById('cofinanciamiento').value;\n\tif(confirm(\"Realmente desea Anular la Orden?\")){\t\n\t\tvar ajax=nuevoAjax();\n\t\tajax.open(\"POST\", \"lib/orden_compra/orden_compra_ajax.php\", true);\n\t\tajax.setRequestHeader('Content-Type', 'application/x-www-form-urlencoded; charset=ISO-8859-1');\n\t\tajax.onreadystatechange=function(){ \n\t\t\tif(ajax.readyState == 1){\n\t\t\t\t\tdocument.getElementById(\"divCargando\").style.display = \"block\";\n\t\t\t\t\t}\n\t\t\tif (ajax.readyState==4){\n\t\t\t\t//alert(ajax.responseText);\n\t\t\t\t\tif(ajax.responseText == \"exito\"){\n\t\t\t\t\t\tdocument.getElementById('idestado').value='anulado';\n\t\t\t\t\t\tmostrarMensajes(\"exito\", \"La orden se Anulo con Exito\");\n\t\t\t\t\t\tactualizarDatosBasicos(\"consultar\");\n\t\t\t\t\t\tconsultarMateriales(id_orden_compra);\n\t\t\t\t\t\tdocument.getElementById('divPreguntarUsuario').style.display = 'none';\n\t\t\t\t\t\tconsultarOrdenCompra(id_orden_compra);\n\t\t\t\t\t}else if(ajax.responseText == \"claveIncorrecta\"){\n\t\t\t\t\t\tmostrarMensajes(\"error\", \"Disculpe Clave incorrecta\");\n\t\t\t\t\t\tsetTimeout(\"window.location.href='principal.php?accion=249&modulo=3'\",1000);\n\t\t\t\t\t}else{\n\t\t\t\t\t\tmostrarMensajes(\"error\", \"No se pudo anular la orden\");\n\t\t\t\t\t}\n\t\t\t\t\t\tdocument.getElementById(\"verificarClave\").value = \"\";\n\t\t\t\t\t\tdocument.getElementById(\"divCargando\").style.display = \"none\";\n\t\t\t} \n\t\t}\n\t\tajax.send(\"cofinanciamiento=\"+cofinanciamiento+\"&id_orden_compra=\"+id_orden_compra+\"&clave=\"+clave+\"&fecha_anulacion_compromiso=\"+fecha_anulacion_compromiso+\"&ejecutar=anularOrden\");\n\t}\n}", "title": "" }, { "docid": "4f79bace2b95b36677ea2d960af1a86a", "score": "0.47742748", "text": "function inicializarConversacionFracaso(){\nconversacionFracaso = new ArbolConversacion(texturaCristina,texturaConserje,texturaCristinaSombreada,texturaConserjeSombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Ya he hablado con todos, pero...\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Si, hay algo extraño. Ya no veo fantasmas, pero todavía no siento paz en este lugar\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"Es mi culpa, no he podido ayudar correctamente a nadie. Soy un fracaso.\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"No te atormentes así, hiciste lo que podiste. Solo falta que tu descanses, si creo que eso es lo que falta\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"... Si, tal vez tengas razon\",1);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos, FINAL);\nconversacionFracaso.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "7fb09303f49f468530e5cb0f13aecdbb", "score": "0.47737208", "text": "function edaddbtn()\n{\n if(customerName.length!=0 && customerNumber.length!=0 && invoiceNumber.length!=0 && invoiceAmount.length!=0 && dueinDate.length!=0)\n {\n document.getElementById('afaddbtn').disabled=false;\n document.getElementById('afaddbtn').style.backgroundColor='#14AFF1';\n }\n else\n {\n if(customerName.length==0 || customerNumber.length==0 || invoiceNumber.length==0 || invoiceAmount.length==0 || dueinDate.length==0)\n {\n document.getElementById('afaddbtn').disabled=true;\n document.getElementById('afaddbtn').style.backgroundColor='#97A1A9';\n }\n }\n}", "title": "" }, { "docid": "3745640469157b2c3a8dc5d37542d6d2", "score": "0.4773087", "text": "function inicializarConversacionF2Ayudar(){\nconversacionF2Ayudar = new ArbolConversacion(texturaCristina,texturaF2,texturaCristinaSombreada,texturaF2Sombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Ya está, no fue fácil, pero logré abrir la puerta del refirgerador\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Te agradezco, de verdad necesitaba darle un último vistazo. Ya puedo irme en paz.\",2);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos);\n\nconversacionF2Ayudar.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "604979d36b095932adbd496780ea0976", "score": "0.476952", "text": "function CWM_ELP_Defect_3701_DPL_WTUA_AddContactFromRenewaltoLicense(){\r\n try{\r\n var pCapId = getParentLicenseCapID(capId);\r\n if(wfTask==\"Validate\" && wfStatus == \"Approved\"){\r\n if(pCapId){\r\n copyContactsByTypeWithAddress(capId,pCapId,\"Affiliated Broker\");\r\n logDebug(\"Affiliated Broker contact copied to: \" + pCapId.getCustomID());\r\n }\r\n }\r\n }\r\n catch(err){\r\n logDebug(\"Error on function CWM_ELP_Defect_3701_DPL_WTUA_AddContactFromRenewaltoLicense. Please Call System Administrator. \" + err.stack);\r\n logDebug(\"Error Message: \" + err.message); \r\n }\r\n}", "title": "" }, { "docid": "9e5a38a3f55a4d7c087a33f26724a1ac", "score": "0.47635475", "text": "function CWM_ELP_Defect_3700_DPL_WTUA_AddContactFromRenewaltoLicense(){\r\n try{\r\n var pCapId = getParentLicenseRecord(capId);\r\n if(wfTask==\"Validate\" && matches(wfStatus, \"Approved\", \"Approved with Conditions\")){\r\n if(pCapId){\r\n copyContactsByTypeWithAddress(capId,pCapId,\"Affiliated Broker\");\r\n logDebug(\"Affiliated Broker contact copied to: \" + pCapId);\r\n }\r\n }\r\n }\r\n catch(err){\r\n logDebug(\"Error on function CWM_ELP_Defect_3700_DPL_WTUA_AddContactFromRenewaltoLicense. Please Call System Administrator. \" + err.stack);\r\n logDebug(\"Error Message: \" + err.message); \r\n }\r\n}", "title": "" }, { "docid": "341e6c867dd59037cecb9d294dc8537d", "score": "0.47582304", "text": "function habilitarRaza(){\n\t\n\t$( \"#iconoNuevaRaza\" ).show(\"show\");\n\t//se habilita el campo para que se pueda digitar\n\t$(\"#paciente_raza\").prop('disabled', false);\n\t\n}", "title": "" }, { "docid": "0494cc636a20025de5e99bb3f83291c7", "score": "0.47542033", "text": "function irAAgregarTurno(){\r\n\tvar msg = \"Desea Agregar un NUEVO REGISTRO?.. \";\r\n\t//Obtengo el valor que define si el formulario a sufrido cambios, para definir el mensaje de confirmacion\r\n\tvar cambiosSinGuardar = $(\"#t_cambios\").val();\r\n\tif(cambiosSinGuardar == \"true\") msg = 'Puede haber cambios sin guardar en el formulario, ¿Desea agregar un NUEVO Registro de todas formas?.';\r\n\tif(confirm(msg)) Cons_turno('', 'agregar');\r\n}", "title": "" }, { "docid": "4b38a10cfdd5975c8415b38175829fb0", "score": "0.475321", "text": "function desbloquearControles(){\r\ndocument.getElementById(\"txtCodigoRefernciaPresupuestoBuscar\").disabled=false;\r\ndocument.getElementById(\"bttnBuscarPresupuesto\").disabled=false;\r\ndocument.getElementById(\"bttnCancelar\").disabled=true;\r\ndocument.getElementById(\"bttnAprobarPresupuesto\").disabled=true;\r\ndocument.getElementById(\"bttnIniciarEjecucion\").disabled = true;\r\n}", "title": "" }, { "docid": "3c9a709cd92c912e743c8d3237c80a8c", "score": "0.47531036", "text": "function handleButClick(ctlsref) {\n\tvar str = serializeDpchAppDo(srcdoc, \"DpchAppMsdcScfAcquisDo\", scrJref, ctlsref + \"Click\");\n\tsendReq(str, doc, handleDpchAppDataDoReply);\n}", "title": "" }, { "docid": "8b391df3506156c56941daeb29a22c57", "score": "0.47473004", "text": "bloquearCaixa(context) {\n ipcRenderer.sendSync('caixa-setBloqueado', true)\n context.caixaBloqueadoStatus = true\n context.openAlert(\"Caixa bloqueado com sucesso!\")\n }", "title": "" }, { "docid": "33723c63268c327396ee7fdf3e310875", "score": "0.47455516", "text": "function verificar_abc(){\n\n\tvar resul = validarOrden();\n\n\tif(resul){\n\n\t\tmostrarMensaje(\"../../imagen/icon/exito.png\",\"lenguaje/felicitaciones.webm\",\"../../audio/efecto_sonido/felicitaciones.ogg\");\n\n\t\tfin = getActual();\t\n\n\t\tanotarDesempeno();\n\n\t\tsetTimeout(function(){\n\t\t\tcargarActividad();\n\t\t}, 3000);\n\n\t\t$(\"#intentoCont\").val(0);\n\t}\n\telse{\n\t\tmostrarMensaje(\"../../imagen/icon/fracaso1.png\",\"lenguaje/error_repetir.webm\",\"../../audio/efecto_sonido/error_repetir.ogg\");\n\n\t\t$(\"#intentoCont\").val( parseInt($(\"#intentoCont\").val()) + 1 );\n\t}\n}", "title": "" }, { "docid": "610b9f7c6e787e3d309bca4341dd6eab", "score": "0.47444394", "text": "function click_cancelcfd()\r\n{\r\n\tvar wtype = nlapiGetRecordType();\r\n\tvar id = nlapiGetFieldValue('id');\r\n\tvar invoice = nsoGetTranRecord(id);\r\n\tvar subsidiary = invoice.getFieldValue(\"subsidiary\");\r\n\tvar url = nlapiResolveURL(\"SUITELET\", \"customscript_cancelcfdi\", \"customdeploy_cancelcfdi\", null) + \"&pid=\" + id;\r\n\tvar wresponse = nlapiRequestURL(url, null, null, null);\t\t\t\r\n\tvar wbody = wresponse.getBody();\t\t\r\n\teval(wbody);\r\n\tvar wfields = wrkfields;\r\n\tvar setup\t = nlGetSetupRecord(subsidiary, subsidiary);\r\n\tvar sRequestor = setup.getFieldValue('custrecord_cfdi_requestor');\r\n\tvar sEntity\t\t= setup.getFieldValue('custrecord_cfdi_entity');\r\n\tvar sUser \t\t= setup.getFieldValue('custrecord_cfdi_user');\t\r\n\tvar sUserName = setup.getFieldValue('custrecord_cfdi_username');\r\n\tvar serie = isNull(wfields.wSerie);\r\n\tvar folio = wfields.wFolio;\r\n\t\r\n\t\r\n\tif(confirm('Esta por Cancelar la Factura No. : ' + folio + ', Desea Continuar?') == true)\r\n\t{\r\n\t\t/*invoice.setFieldValue('custbody_cancelcfdi', 'T');\r\n\t\tnlapiSubmitRecord(invoice);*/\r\n\t\t\r\n\t\ttry\r\n\t\t{\t\t\t\r\n\t\t\tvar lResult = nsoSendToWS(1, '', folio , id, wtype, sRequestor, sEntity, sUser, sUserName);\t\t\t\t\t\t\r\n\t\t\tif (lResult == null || lResult == '')\r\n\t\t\t{\r\n\t\t\t\tnlapiSubmitField(wtype, id, 'custbody_cancelcfdi', 'T');\r\n\t\t\t\talert('Proceso Terminado.');\r\n\t\t\t\t//window.location = window.location;\r\n\t\t\t}\t\r\n\t\t}\r\n\t\tcatch(e)\r\n\t\t{\r\n\t\t\talert(e.description);\r\n\t\t\treturn;\r\n\t\t}\r\n\t}\r\n}", "title": "" }, { "docid": "e16103320a2f4f168d25e6bd23b02705", "score": "0.47426322", "text": "function barraCerrada() {\n barra.classList.remove(\"dos\");\n barra.className = \"barra uno\";\n btnIcon.innerHTML = `&#9776`;\n i = 0;\n}", "title": "" }, { "docid": "8d5ec6ab420b0a1ae68280bf1a8ccb79", "score": "0.47423536", "text": "function funcpkgCancel(){\n\n document.getElementById('pakige').value=''\n document.getElementById('charges').value=''\n document.getElementById('lblkey2').innerText=''\n\n document.getElementById('buttn').innerText='submit'\n document.getElementById('canclbtn').setAttribute('style','visibility: hidden;')\n\n document.getElementById('lblKeyLabel2').setAttribute('style','visibility: hidden;')\n document.getElementById('lblKey2').setAttribute('style','visibility: hidden;')\n \n}", "title": "" }, { "docid": "6a24a0088e23f694355acd273a62057e", "score": "0.4741954", "text": "function A2_Confirmation_Screen_New_Order_Button()\n{\ntry{\n Log.AppendFolder(\"A2_Confirmation_Screen_New_Order_Button\");\n InitializationEnviornment.initiliaze();\n AppLoginLogout.login();\n var groupNm=defaultGroupName;\n var paymentTypeForReservation = \"Cash\";\n var keyWordNm =\"Daily Admission\";\n var packageNm =\"3 site Combi\";\n var subPakNm =\"Adult\";\n var qtyT = 1;\n var dateD =CommonCalender.getTodaysDate(); \n \n selectGroupFromMainMenu(groupNm);\n clickBuyTicketsButton();\n addNewTicket(keyWordNm,packageNm,subPakNm,qtyT,dateD); \n finilizeOrder();\n aqUtils.Delay(3000); \n var expectedSettlemtnttotal = orderDetailsTotal.Caption;\n var applyAmount= (expectedSettlemtnttotal.split('$')[1]).trim(); \n selectPaymentTypeAddRequiredFields(paymentTypeForReservation); \n WrapperFunction.setTextValue(PayamountTextBox,applyAmount);\n Button.clickOnButton(applyButton);\n Log.Message(\"Complete the order\");\n WrapperFunction.settlementCompleteOrder();\n Log.Message(\"Don't Validate the order\");\n aqUtils.Delay(2000);\n validateTicket(\"Don't Validate\"); \n aqUtils.Delay(3000); \n verifyTotalOnConfirmationPage(expectedSettlemtnttotal);\n var orderId = cnf_orderID1.Caption;\n if (orderId == null){\n merlinLogError(\"Order id is not present\");\n return;\n } \n var OrderID= (orderId.split('#')[1]).trim();\n OrderInfo.prototype.OrderID = OrderID;\n Log.Message(\"Order id is set:\"+OrderID); \n \n Button.clickOnButton(NewOrder_Button);\n //cnf_newGroupOrderBtn.Click();\n aqUtils.Delay(2000); \n if(Keyword_Listgroup.VisibleOnScreen){\n Log.Message(\"POS navigates to and remains on the Point of Sale screen after clicking on New Order button\");\n }else{\n merlinLogError(\"POS is not navigated to the Point of Sale screen after clicking on New Order button\");\n }\n \n } catch (e) {\n\t merlinLogError(\"Oops! There's some glitch in the script: \" + e.message);\n\t return;\n }\n finally { \n AppLoginLogout.logout(); \n\t Log.PopLogFolder(); \n } \n \n}", "title": "" }, { "docid": "a0fb343112d3c39efefa47e027da8159", "score": "0.4741671", "text": "function inicializarConversacionExito(){\nconversacionExito = new ArbolConversacion(texturaCristina,texturaConserje,texturaCristinaSombreada,texturaConserjeSombreada);\n\n/**\n* Nodo Raiz\n* \n*/\nvar dialogos : Array = new Array();\nvar l: LineaDialogo = new LineaDialogo(\"Listo, todos los fantasma descansan ahora sin ningun remordimiento\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Si, es verdad, se siente mucha más paz en este lugar\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"¿Y ahora qué?\",1);\ndialogos.Push(l);\nl = new LineaDialogo(\"Bueno, ya has ayudado a todos los que podias, creo que es hora de que tu tambien descanses\",2);\ndialogos.Push(l);\nl = new LineaDialogo(\"... Si, tienes razon... ya es hora\",1);\ndialogos.Push(l);\n\nvar nodoRaiz:NodoDialogo = new NodoDialogo(dialogos, FINAL);\nconversacionExito.setRaiz(nodoRaiz);\n}", "title": "" }, { "docid": "9b6849b1bc8dc734f0a13cb2617f161f", "score": "0.4738069", "text": "function confirmarCompra() {\n btnConfirmar.html('<span><i style=\"color: var(--primary-color)\" class=\"fas fa-spinner fa-spin\"></i></span>');\n btnVolver.fadeOut().slideUp();\n setTimeout(() => {\n btnConfirmar.remove();\n let confirmacion = generarMensajeCompra();\n mensajeConfirmacion.append(confirmacion);\n localStorage.clear();\n redireccionarAInicio();\n }, 5000)\n}", "title": "" }, { "docid": "39409108baf11d6917a549e7a494d545", "score": "0.47371382", "text": "function lapiz(){\n relleno = false;\n pinta = true;\n borrar = false;\n document.getElementById(\"btnPintar\").style.backgroundColor = \"#FDC208\";\n document.getElementById(\"btnPintar\").style.color = \"black\";\n document.getElementById(\"btnBorrar\").style.backgroundColor = \"transparent\";\n document.getElementById(\"btnBorrar\").style.color = \"#FDC208\";\n document.getElementById(\"btnRelleno\").style.backgroundColor = \"transparent\";\n document.getElementById(\"btnRelleno\").style.color = \"#FDC208\";\n color = document.getElementById(\"colores\").value;\n document.getElementById(\"colores\").removeAttribute(\"disable\");\n}", "title": "" }, { "docid": "824c041e26eaf502528662a3cebf31d8", "score": "0.4736913", "text": "function somar() {\r\n if(verificarEntradasVazias()){\r\n resposta.textContent = 'Erro: preencha os dois campos numéricos'; \r\n //Estilizando resposta com CSS\r\n resposta.classList.remove('certa');\r\n resposta.classList.add('errada'); \r\n } else {\r\n atualizarResposta();\r\n }\r\n }", "title": "" }, { "docid": "daa5623790bb4114f34592a81544a219", "score": "0.47358677", "text": "function activate_the_confirm_button () {\n\t\t\t\t\n\t\t\t\t$('#bouton_confirmtn_modification_architecture').prop('disabled', false).css({\n\t\t\t\t\tcursor: 'default'\n\t\t\t\t});\n\t\t\t}", "title": "" }, { "docid": "0081b90fed99cede12ace11576ea0cef", "score": "0.4732183", "text": "function CWM_ELP_Defect4644_licenseValidation(){\r\n try\r\n {\r\n if(!publicUser){\r\n var activeLic = true;\r\n var boardName = getAsbBoard(appTypeArray[1]);\r\n var boardCode = lookup(\"BOARDS\",boardName);\r\n var changeType = AInfo['Change Type'];\r\n logDebug(\"---- changeType---- \"+changeType);\r\n for (loopk in AppSpecificInfoModels)\r\n {\r\n var appSpecificObj = AppSpecificInfoModels[loopk];\r\n if((appSpecificObj.getCheckboxType() == \"END EXISTING RELATIONSHIP\" && changeType == \"Remove Existing Relationship\") || (appSpecificObj.getCheckboxType() == \"ADD NEW RELATIONSHIP\" && changeType == \"Add New Relationship\"))\r\n { \r\n logDebug(\"---- Inside if condition ---- \");\r\n if(appSpecificObj.checkboxDesc == \"License Number\")\r\n {\r\n var licNumber = appSpecificObj.checklistComment;\r\n if(licNumber)\r\n {\r\n activeLic = isLicenseActive(licNumber, boardCode, \"M1\");\r\n if (!activeLic)\r\n activeLic = isLicenseActive(licNumber, boardCode, \"M2\");\r\n //logDebug(\"Active Lic: \" + activeLic);\r\n if (!activeLic)\r\n {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"The license # provided is not valid. Please contact the board for further details.\");\r\n }\r\n }\r\n }\r\n }\r\n }\r\n /*var licenseNum = AInfo[\"License Number\"];\r\n logDebug(\"boardCode \"+boardCode+\"licenseNum \"+licenseNum);\r\n if (licenseNum != undefined && licenseNum != null && licenseNum != \"\")\r\n {\r\n var isActive = isLicenseActive(licenseNum);\r\n if (!isActive)\r\n {\r\n cancel = true;\r\n showMessage = true;\r\n message = \"\";\r\n comment(\"The license # provided is not valid. Please contact the board for further details.\");\r\n }\r\n }*/\r\n }\r\n else{\r\n logDebug(\"---- Else Part---- \");\r\n }\r\n }\r\n catch(err)\r\n {\r\n showMessage=true;\r\n comment(\"Error on ASB function CWM_ELP_Defect4644_licenseValidation, Please contact administrator\");\r\n }\r\n}", "title": "" } ]
6fc13b045a44173203c8a022a18d43a5
Gets the exact top/bottom for the overlay when not using flexible sizing or when pushing.
[ { "docid": "690bbd98d48d9330e7212ad2460d707f", "score": "0.6131551", "text": "_getExactOverlayY(position, originPoint, scrollPosition) {\n // Reset any existing styles. This is necessary in case the\n // preferred position has changed since the last `apply`.\n let styles = { top: '', bottom: '' };\n let overlayPoint = this._getOverlayPoint(originPoint, this._overlayRect, position);\n if (this._isPushed) {\n overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);\n }\n let virtualKeyboardOffset = this._overlayContainer.getContainerElement().getBoundingClientRect().top;\n // Normally this would be zero, however when the overlay is attached to an input (e.g. in an\n // autocomplete), mobile browsers will shift everything in order to put the input in the middle\n // of the screen and to make space for the virtual keyboard. We need to account for this offset,\n // otherwise our positioning will be thrown off.\n overlayPoint.y -= virtualKeyboardOffset;\n // We want to set either `top` or `bottom` based on whether the overlay wants to appear\n // above or below the origin and the direction in which the element will expand.\n if (position.overlayY === 'bottom') {\n // When using `bottom`, we adjust the y position such that it is the distance\n // from the bottom of the viewport rather than the top.\n const documentHeight = this._document.documentElement.clientHeight;\n styles.bottom = `${documentHeight - (overlayPoint.y + this._overlayRect.height)}px`;\n }\n else {\n styles.top = Object(_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_5__[\"coerceCssPixelValue\"])(overlayPoint.y);\n }\n return styles;\n }", "title": "" } ]
[ { "docid": "0e06782501d77ce0053ecd632986be6d", "score": "0.6468153", "text": "function getBottom(layer) {\r\n\r\n if (NS4) return layer.top + getHeight(layer);\r\n if (IE4) return layer.style.pixelTop + getHeight(layer);\r\n if (NS6) return parseInt (layer.style.top) + getHeight(layer);\r\n return -1;\r\n}", "title": "" }, { "docid": "c2eab7a94b31f9865d648173d7f1bdcb", "score": "0.63900924", "text": "function getTopPosition(props) {\n window[\"__checkBudget__\"]();\n if (props.top || props.top === 0) {\n return props.top;\n }\n else if (props.bottom) {\n return contentHeight - props.bottom - props.height;\n }\n else {\n return 0;\n }\n }", "title": "" }, { "docid": "df541e950ecc1d18ca82acd53d87ab8f", "score": "0.6377961", "text": "getTop() {\n return getTopOverlay(this.toasts);\n }", "title": "" }, { "docid": "a6ab2fcbc86e8d647e002c446d454657", "score": "0.63664365", "text": "_getOverlayPosition() {\n const isLtr = !this._dir || this._dir.value == 'ltr';\n const position = this.position;\n let overlayPosition;\n if (position == 'above') {\n overlayPosition = { overlayX: 'center', overlayY: 'bottom' };\n }\n else if (position == 'below') {\n overlayPosition = { overlayX: 'center', overlayY: 'top' };\n }\n else if (position == 'before' ||\n (position == 'left' && isLtr) ||\n (position == 'right' && !isLtr)) {\n overlayPosition = { overlayX: 'end', overlayY: 'center' };\n }\n else if (position == 'after' ||\n (position == 'right' && isLtr) ||\n (position == 'left' && !isLtr)) {\n overlayPosition = { overlayX: 'start', overlayY: 'center' };\n }\n else if (typeof ngDevMode === 'undefined' || ngDevMode) {\n throw getMatTooltipInvalidPositionError(position);\n }\n const { x, y } = this._invertPosition(overlayPosition.overlayX, overlayPosition.overlayY);\n return {\n main: overlayPosition,\n fallback: { overlayX: x, overlayY: y }\n };\n }", "title": "" }, { "docid": "aebc6b772273b8f95f16dce484cd97a7", "score": "0.62610966", "text": "get bottom() { return this.top + this.height; }", "title": "" }, { "docid": "00c426b9fb8fd209a3281130e9830de0", "score": "0.6241692", "text": "async getTop() {\n return getOverlay(document, 'ion-modal');\n }", "title": "" }, { "docid": "ea6f973631b823dd489a3899246134ab", "score": "0.6183093", "text": "async getTop() {\n return getOverlay(document, 'ion-popover');\n }", "title": "" }, { "docid": "5179d42a1657658ea21ad0451da464d6", "score": "0.6146759", "text": "function getAxisTop(chartHeight) {\n\t\treturn navigatorOptions.top || chartHeight - height - scrollbarHeight - chartOptions.chart.spacingBottom;\n\t}", "title": "" }, { "docid": "fcf3a359c82c921e579b66b65470f42c", "score": "0.61467093", "text": "_getExactOverlayY(position, originPoint, scrollPosition) {\n // Reset any existing styles. This is necessary in case the\n // preferred position has changed since the last `apply`.\n let styles = { top: '', bottom: '' };\n let overlayPoint = this._getOverlayPoint(originPoint, this._overlayRect, position);\n if (this._isPushed) {\n overlayPoint = this._pushOverlayOnScreen(overlayPoint, this._overlayRect, scrollPosition);\n }\n let virtualKeyboardOffset = this._overlayContainer.getContainerElement().getBoundingClientRect().top;\n // Normally this would be zero, however when the overlay is attached to an input (e.g. in an\n // autocomplete), mobile browsers will shift everything in order to put the input in the middle\n // of the screen and to make space for the virtual keyboard. We need to account for this offset,\n // otherwise our positioning will be thrown off.\n overlayPoint.y -= virtualKeyboardOffset;\n // We want to set either `top` or `bottom` based on whether the overlay wants to appear\n // above or below the origin and the direction in which the element will expand.\n if (position.overlayY === 'bottom') {\n // When using `bottom`, we adjust the y position such that it is the distance\n // from the bottom of the viewport rather than the top.\n const documentHeight = this._document.documentElement.clientHeight;\n styles.bottom = `${documentHeight - (overlayPoint.y + this._overlayRect.height)}px`;\n }\n else {\n styles.top = (0,_angular_cdk_coercion__WEBPACK_IMPORTED_MODULE_2__.coerceCssPixelValue)(overlayPoint.y);\n }\n return styles;\n }", "title": "" }, { "docid": "a3ac5f76cbdcc7bb9dd0d4eaabaf8d6f", "score": "0.6143381", "text": "get overlayThickness() {\r\n return this.i.su;\r\n }", "title": "" }, { "docid": "8fabd0b1d39528286cb65bcdef65efe9", "score": "0.61009395", "text": "async getTop() {\n return getOverlay(document, 'ion-alert');\n }", "title": "" }, { "docid": "5cc007bfb4e4bae5ad65a361f29691c3", "score": "0.60874915", "text": "get bottom() {\n return this.top + this.height;\n }", "title": "" }, { "docid": "d90e418212eb43ca2685883a192c0657", "score": "0.6058972", "text": "function getBottomLinePosition() {\n return $pageContent.offset().top + $pageContent.height()\n }", "title": "" }, { "docid": "373306486298b001a4c08a7dfff466ea", "score": "0.60562146", "text": "function getElementBottom(el){\n\tif (typeof(el) != \"object\"){\n\t\tel = eId(el);\n\t}\n\t\n\telTop = getElementY(el);\n\treturn elTop+el.offsetHeight;\n}", "title": "" }, { "docid": "cbdd3fc72cc5e3b99d92eb89b8dd88da", "score": "0.60141295", "text": "function absTopValue(element) {\n const rect = element.getBoundingClientRect();\n return Math.abs(rect.top);\n}", "title": "" }, { "docid": "bccec84a145015c2664a45587860dab2", "score": "0.60005957", "text": "function getBottom(e){\n\t\tvar out = parseFloat(e.clientBottom || e.offsetBottom);\n\t\treturn (isNaN(out))?0:out;\n\t}", "title": "" }, { "docid": "b16c9072b03ede1db83abf28f379c8a7", "score": "0.59995735", "text": "function getTop(layer) {\r\n\r\n if (NS4) return layer.top;\r\n if (IE4) return layer.style.pixelTop;\r\n if (NS6) return layer.style.top;\r\n return -1;\r\n}", "title": "" }, { "docid": "416e03d8b561f4f96005a4d8be9242dd", "score": "0.59639275", "text": "function getTop(e){\n\t\tvar out = parseFloat(e.clientTop || e.offsetTop);\n\t\treturn (isNaN(out))?0:out;\n\t}", "title": "" }, { "docid": "342ddf79731e59d05a3c5ea6631622ed", "score": "0.5959898", "text": "async getTop() {\n return getOverlay(document, 'ion-toast');\n }", "title": "" }, { "docid": "187232cc84efd1bcdc4d031f0ceff4cd", "score": "0.5953934", "text": "function elemTop(elem) {\r\n return elem.top || elem.pixelTop || elem.offsetTop || 0;\r\n }", "title": "" }, { "docid": "3ced3c4d45433a3ca3252d93be36ed0e", "score": "0.5899919", "text": "function getTopPos(el) {\n return el.getTopPos();\n}", "title": "" }, { "docid": "94cd97f8da63e83a64df103e17550172", "score": "0.5864157", "text": "async getTop() {\n return getOverlay(document, 'ion-picker');\n }", "title": "" }, { "docid": "b41b3394e1f912be87944f3986df228f", "score": "0.58473927", "text": "function getScreenCenteredTop(eh) {\n\tvar h = screen.height;\n\treturn (h - eh) / 2;\n}", "title": "" }, { "docid": "489723e067c82ee51e9dc23b6aa6b7c9", "score": "0.5845339", "text": "function contentBottomEdgeY() {\n var bottomElement = storyContainer.lastElementChild;\n return bottomElement ? bottomElement.offsetTop + bottomElement.offsetHeight : 0;\n }", "title": "" }, { "docid": "5abb5874c9b19ede61da0ed6fd00e06f", "score": "0.5831414", "text": "function getTop(e){\n\t\tvar out = parseInt(e.clientTop || e.offsetTop);\n\t\treturn (isNaN(out))?0:out;\n\t}", "title": "" }, { "docid": "6525ed217ff0b937283a82264bcf6e4b", "score": "0.58309007", "text": "function getTopPosition(obj)\n{\n\treturn dojo.position(obj).y;\n}", "title": "" }, { "docid": "e3040469884418358dff627b53832fe0", "score": "0.5787945", "text": "get bottomY() {\n return this.height + this.y\n }", "title": "" }, { "docid": "aae7aa10e70cc717d65c42f9c38e15d2", "score": "0.57821256", "text": "function getBabyHeight() {\n return $('#baby').css('top');\n }", "title": "" }, { "docid": "88b90aa4f421fb6fce1136661dbc87a6", "score": "0.5768643", "text": "get bottom() { return this.y + this.height; }", "title": "" }, { "docid": "88b90aa4f421fb6fce1136661dbc87a6", "score": "0.5768643", "text": "get bottom() { return this.y + this.height; }", "title": "" }, { "docid": "d66bbe9c37477ca024d00a45d34a48c9", "score": "0.57514054", "text": "get insetBottom() {\n return this._insetBottom;\n }", "title": "" }, { "docid": "4c4ad10ae0f9d60355520f9dd16ee05f", "score": "0.5750657", "text": "function get_top ( layername ){\n if ( ie )\n return document.all[layername].style.pixelTop;\n else if ( nn )\n return document[layername].top;\n else if ( ns5 )\n return parseInt(window.document.getElementById(layername).style.top);\n return false;\n}", "title": "" }, { "docid": "51bfb69b50c1bb0acbf7a1af75961ed2", "score": "0.57500356", "text": "_getDialogStrategy() {\n return this._overlay.position().global().centerHorizontally().centerVertically();\n }", "title": "" }, { "docid": "1eba169de6daf2bc9519a4b2888a40b1", "score": "0.57391", "text": "async getTop() {\n return getOverlay(document, 'ion-loading');\n }", "title": "" }, { "docid": "a3feb75a3d83667a03d5b3432f2feab0", "score": "0.57304287", "text": "get top() {\n\n return this.sprite.y - this.sprite.height / 2;\n }", "title": "" }, { "docid": "7325ce0fc24b5cebcaaa2c3996578be8", "score": "0.57187986", "text": "getBottom() { \n return this.y + this.height; \n }", "title": "" }, { "docid": "f8fbe22addee34f93d36c0c5c7721171", "score": "0.5685455", "text": "get bottom() {\n return this.y + this.height;\n }", "title": "" }, { "docid": "64272bf805b896f7c9ce797c65675adb", "score": "0.5673407", "text": "function get_popover_placement(pop, dom_el) {\n\t\tvar elementPositionFromTop = $(dom_el).position().top;\n\t\tvar heightScrolledFromTop = $(window).scrollTop();\n\t\tvar relativeElementPosition = elementPositionFromTop - heightScrolledFromTop;\n\t\tif (relativeElementPosition < 300)\n\t\t{\n\t\t\treturn 'bottom';\n\t\t}\n\t\telse\n\t\t{\n\t\t\treturn 'top';\n\t\t}\n\t}", "title": "" }, { "docid": "6b095ca172b4d28089354fd5dd69edbc", "score": "0.56621933", "text": "async getTop() {\n return getOverlay(document, 'ion-action-sheet');\n }", "title": "" }, { "docid": "6b095ca172b4d28089354fd5dd69edbc", "score": "0.56621933", "text": "async getTop() {\n return getOverlay(document, 'ion-action-sheet');\n }", "title": "" }, { "docid": "5d0497fe1c4053f3ee0b218a5d2f755c", "score": "0.56544", "text": "get insetTop() {\n return this._insetTop;\n }", "title": "" }, { "docid": "68fd2e52a2856187a0ca77f1cd16a0fe", "score": "0.56536734", "text": "function updateOverlayHeight() {\n\t\t\t// Set overlay height\n\t\t\t// We need it in case when you open overlay in the middle of tall page\n\n\t\t\t// Line with `$(\"html\").prop(\"scrollHeight\");` was commented because it does not work when\n\t\t\t// html tag is not covering whole page, for example in case when doctype is <!DOCTYPE html>\n\t\t\t// So had to switch to calculation based on window height\n\t\t\t//var height = getScrollPos() + $(\"html\").prop(\"scrollHeight\");\n\n\t\t\tvar height = getScrollPos() + $(window).height() + getBodyAndHtmlExtraSpace().top;\n\n\t\t\tgetBoxOverlay().css('height', height + 'px');\n\t\t}", "title": "" }, { "docid": "1a33d388bd67ed3319372bfc8951b186", "score": "0.5653422", "text": "getTopPosition(screen, factor=55) {\n if (screen.width < mobileBp) factor = 40;\n return this.props.position * factor;\n }", "title": "" }, { "docid": "8e2162f529dd682af6412d298a9a03dd", "score": "0.5639028", "text": "function getRealTop(el) \r\n{\r\n yPos = el.offsetTop;\r\n tempEl = el.offsetParent;\r\n while (tempEl != null) \r\n\t{\r\n yPos += tempEl.offsetTop;\r\n tempEl = tempEl.offsetParent;\r\n }\r\n return yPos;\r\n}", "title": "" }, { "docid": "3b38865f59e045ef173f342cc60e7ef5", "score": "0.56287146", "text": "async getTop() {\r\n return getOverlay(document, 'ion-loading');\r\n }", "title": "" }, { "docid": "9bc8172092b4cb85ef72550568be3738", "score": "0.56279653", "text": "function getOuterHeight(element) {\n\t return getOuter(\"Top\", element) + getOuter(\"Bottom\", element);\n\t }", "title": "" }, { "docid": "d1d4d2e04d8a7ac21a5903fbb397925b", "score": "0.56123316", "text": "get bottom() {\n return this.y + this.height\n }", "title": "" }, { "docid": "c026c8848b9eed56777d3bc3ce888cfa", "score": "0.5608537", "text": "get bottom() {\n return this.y + this.height;\n }", "title": "" }, { "docid": "c0daa7db7ce99173afe045300b66bef0", "score": "0.56026334", "text": "function distanceToTop(el) { \n return Math.floor(el.getBoundingClientRect().top); \n }", "title": "" }, { "docid": "951c4da190e73cb3bd6848d68821cc26", "score": "0.55900055", "text": "function getMinHeight() {\n\n}", "title": "" }, { "docid": "9e040838c4c6c1008e10824745f5eac3", "score": "0.5564073", "text": "get top() {\n const yComponent = Math.sin(this.offsetAngle);\n const percentageFromTop = mapToPercentage(yComponent);\n\n return `${percentageFromTop}%`;\n }", "title": "" }, { "docid": "7d51ccf13790604296b7cfa1d33c3f84", "score": "0.55589134", "text": "_calculateOverlayPosition() {\n const itemHeight = this._getItemHeight();\n const items = this._getItemCount();\n const panelHeight = Math.min(items * itemHeight, SELECT_PANEL_MAX_HEIGHT);\n const scrollContainerHeight = items * itemHeight;\n // The farthest the panel can be scrolled before it hits the bottom\n const maxScroll = scrollContainerHeight - panelHeight;\n // If no value is selected we open the popup to the first item.\n let selectedOptionOffset = this.empty ? 0 : this._getOptionIndex(this._selectionModel.selected[0]);\n selectedOptionOffset += Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_3__[\"_countGroupLabelsBeforeOption\"])(selectedOptionOffset, this.options, this.optionGroups);\n // We must maintain a scroll buffer so the selected option will be scrolled to the\n // center of the overlay panel rather than the top.\n const scrollBuffer = panelHeight / 2;\n this._scrollTop = this._calculateOverlayScroll(selectedOptionOffset, scrollBuffer, maxScroll);\n this._offsetY = this._calculateOverlayOffsetY(selectedOptionOffset, scrollBuffer, maxScroll);\n this._checkOverlayWithinViewport(maxScroll);\n }", "title": "" }, { "docid": "aaa21bba62e91795daa19e44e3c1bec7", "score": "0.55474734", "text": "getPositionStrategy() {\n return this.overlayRef.getConfig().positionStrategy;\n }", "title": "" }, { "docid": "87fe276e558fc8bc2d81be32e910fad5", "score": "0.55264527", "text": "getBottomPagePosition() {\n if (this.direction === 1 /* BACK */) {\n return { x: this.pageWidth, y: 0 };\n }\n return { x: 0, y: 0 };\n }", "title": "" }, { "docid": "3ea6f04f4b251a12853632a87f94ec9b", "score": "0.55260324", "text": "get overlayHeaderLabelBottomMargin() {\r\n return this.i.c6;\r\n }", "title": "" }, { "docid": "ae084c5848973f0becdcfb3e2c16b7f6", "score": "0.55186564", "text": "function getOffsetTop(el) {\n const rect = el.getBoundingClientRect();\n return rect.top + window.scrollY;\n}", "title": "" }, { "docid": "4d5b4d0893d95e1fe1e471fa10015ff2", "score": "0.551851", "text": "function getArea() {\n\n // get banner and button\n var banner = $('#n-banner')\n var button = $('#menu-btn').position()\n\n return button.top - (banner.position().top + banner.height()) - 8 - 8\n}", "title": "" }, { "docid": "dba15e93a9128528e4d2cd5dc774db5c", "score": "0.55139995", "text": "get height() {\n return this.bottom - this.top;\n }", "title": "" }, { "docid": "2d918ca0e237b967c5ad3313124ea329", "score": "0.54856", "text": "function getModalPosition () {\n var posParts = vm.position.split('-')\n var pos0 = posParts[0]\n var pos1 = posParts[1] || 'center'\n var hostElPos = vm.getPosition()\n var targetElPos = {}\n\n var targetElWidth = vm.size.width\n var targetElHeight = vm.size.height\n\n var shiftWidth = {\n center: widthCenter,\n left: widthLeft,\n right: widthRight\n }\n\n var shiftHeight = {\n center: heightCenter,\n top: heightTop,\n bottom: heightBottom\n }\n\n switch (pos0) {\n case 'right':\n targetElPos = {\n top: shiftHeight[pos1](),\n left: shiftWidth[pos0]()\n }\n break\n case 'left':\n targetElPos = {\n top: shiftHeight[pos1](),\n left: hostElPos.left - targetElWidth\n }\n break\n case 'bottom':\n targetElPos = {\n top: shiftHeight[pos0](),\n left: shiftWidth[pos1]()\n }\n break\n default:\n targetElPos = {\n top: hostElPos.top - targetElHeight,\n left: shiftWidth[pos1]()\n }\n break\n }\n\n return targetElPos\n\n function widthRight () {\n return hostElPos.left + hostElPos.width\n }\n\n function widthLeft () {\n return hostElPos.left\n }\n\n function widthCenter () {\n return hostElPos.left + hostElPos.width / 2 - targetElWidth / 2\n }\n\n function heightBottom () {\n return hostElPos.top + hostElPos.height\n }\n\n function heightTop () {\n return hostElPos.top\n }\n\n function heightCenter () {\n return hostElPos.top + hostElPos.height / 2 - targetElHeight / 2\n }\n }", "title": "" }, { "docid": "fea3b12bb1906a4d026b95db81b3bcf1", "score": "0.5483445", "text": "get top() {\n // origin is at top left so just return y\n return this.y;\n }", "title": "" }, { "docid": "077761f8dc6dac639be8bb2b6a01e3a3", "score": "0.548129", "text": "get top() {\n // origin is at top left so just return y\n return this.y\n }", "title": "" }, { "docid": "ec5db1da539d7714ed6d3d7af7ba2b5b", "score": "0.54751587", "text": "get bottom() {\n\n return this.sprite.y + this.sprite.height / 2;\n }", "title": "" }, { "docid": "3ab4bc1b756b9dc9b439be88a4dd491c", "score": "0.5474943", "text": "get actualWindowPositionVertical() {\r\n return this.i.ec;\r\n }", "title": "" }, { "docid": "3ab32ee8ebe7d2c1aac870b50d5eee8a", "score": "0.546906", "text": "get position() {\n const { offset = { left: 0, top: 0 } } = this;\n const { top = 0, left = 0, width = 0, height = 0 } =\n this.layout || this.style;\n return {\n top: top + offset.top,\n left: left + offset.left,\n width,\n height,\n };\n }", "title": "" }, { "docid": "461c080e803c2a474a6f965bd62f852a", "score": "0.54665726", "text": "_calculateOverlayPosition() {\n const itemHeight = this._getItemHeight();\n const items = this._getItemCount();\n const panelHeight = Math.min(items * itemHeight, SELECT_PANEL_MAX_HEIGHT);\n const scrollContainerHeight = items * itemHeight;\n // The farthest the panel can be scrolled before it hits the bottom\n const maxScroll = scrollContainerHeight - panelHeight;\n // If no value is selected we open the popup to the first item.\n let selectedOptionOffset;\n if (this.empty) {\n selectedOptionOffset = 0;\n }\n else {\n selectedOptionOffset =\n Math.max(this.options.toArray().indexOf(this._selectionModel.selected[0]), 0);\n }\n selectedOptionOffset += Object(_angular_material_core__WEBPACK_IMPORTED_MODULE_3__[\"_countGroupLabelsBeforeOption\"])(selectedOptionOffset, this.options, this.optionGroups);\n // We must maintain a scroll buffer so the selected option will be scrolled to the\n // center of the overlay panel rather than the top.\n const scrollBuffer = panelHeight / 2;\n this._scrollTop = this._calculateOverlayScroll(selectedOptionOffset, scrollBuffer, maxScroll);\n this._offsetY = this._calculateOverlayOffsetY(selectedOptionOffset, scrollBuffer, maxScroll);\n this._checkOverlayWithinViewport(maxScroll);\n }", "title": "" }, { "docid": "4b6f05357176f637030a65ce5c79c6d8", "score": "0.5465545", "text": "get _physicalBottom() {\n return this._physicalTop + this._physicalSize;\n }", "title": "" }, { "docid": "145d5e200971486445425c3fda3aa8fe", "score": "0.54608464", "text": "function getShowingHeight(){\n\tvar h = parseFloat(d3.select('#nowShowing').style('padding-top'));\n\tvar bb = d3.select('#showingStubContainer').node().getBoundingClientRect();\n\th += bb.height;\n\th += parseFloat(d3.select('#showingStubContainer').style('padding-bottom'));\n\n\treturn h;\n}", "title": "" }, { "docid": "f1cb268bea8ed7ef07f7c6bc017e9126", "score": "0.54478294", "text": "get _physicalBottom() {\n return this._physicalTop + this._physicalSize;\n }", "title": "" }, { "docid": "dafb0832ab8b432dedef39a688983de7", "score": "0.54455835", "text": "function getTopDistance(elem) {\n var style = window.getComputedStyle(elem, null);\n return parseInt(style.top.slice(0, -2));\n}", "title": "" }, { "docid": "dedd2234da2f89ac91ec89b07d31942d", "score": "0.5442343", "text": "function blendOverlay(bottom, top) {\n return new ColorRGBA64(blendOverlayChannel(bottom.r, top.r), blendOverlayChannel(bottom.g, top.g), blendOverlayChannel(bottom.b, top.b), 1);\n}", "title": "" }, { "docid": "1a598e8d396928aed1496cc432467ffd", "score": "0.54414135", "text": "getVerticalOffset() {\n return MAP_WIDTH - MAP_HEIGHT;\n }", "title": "" }, { "docid": "bac89d5a318a9a817ebed6e32a3df437", "score": "0.54381555", "text": "function calcul_bouton_top_max() {\n\t\t\t\treturn params.taille_scrollbar - params.taille_bouton\n\t\t\t}", "title": "" }, { "docid": "09e94cb7c1c4bb1e1377713975db9262", "score": "0.5437729", "text": "function calculateDialogTop(options) {\n\n // This is a magic formula I copied from Archetype. Seems to work.\n var $element = options.$element;\n var offset = $element.offset();\n var scrollTop = $element.closest(\".umb-panel-body\").scrollTop();\n if (offset.top < 400) {\n return 300 + scrollTop;\n } else {\n return offset.top - 150 + scrollTop;\n }\n\n}", "title": "" }, { "docid": "dc77580d71c355f58d9fa924b3297ea9", "score": "0.5435101", "text": "isCloseToTop({ layoutMeasurement, contentOffset, contentSize }){\n const paddingToTop = 80;\n return contentSize.height - layoutMeasurement.height - paddingToTop <= contentOffset.y;\n }", "title": "" }, { "docid": "19e153373d97a83e4a98f6326f81c9ae", "score": "0.543247", "text": "function getWindowInnerHeight()\n{\n\tvar toReturn;\n\t// For most modern browsers\n\tif (window.innerHeight)\n\t{\n\t\ttoReturn = window.innerHeight;\n\t}\n\t// For IE8 and lower (which don't support window.innerHeight)\n\telse if (document.documentElement.offsetHeight)\n\t{\n\t\ttoReturn = document.documentElement.offsetHeight;\n\t}\n\treturn toReturn;\n}", "title": "" }, { "docid": "1f2c3ae902252ac76bba4bc37fbf4589", "score": "0.54322463", "text": "function getPositions() {\n var $control = self.$control;\n var $window = $(window);\n\n var control_height = $control.outerHeight(false);\n var control_above = $control.offset().top - $window.scrollTop();\n var control_below = $window.height() - control_above - control_height;\n\n var dropdown_height = self.$dropdown.outerHeight(false);\n\n return {\n control: {\n height: control_height,\n above: control_above,\n below: control_below\n },\n dropdown: {\n height: dropdown_height\n }\n };\n }", "title": "" }, { "docid": "266f50297766ea42c252dc9ae90e3286", "score": "0.5414682", "text": "function getMapHeight() {\n return (window.innerHeight - 120);\n\n }", "title": "" }, { "docid": "1428a2562b1fd104a65fb43ebfbd0353", "score": "0.5408996", "text": "get bottom() {\n return this.bottomPad;\n }", "title": "" }, { "docid": "561869fb7b0bfed6c55eb38d9cc490f2", "score": "0.5407872", "text": "function getAbsolutePosition(el) {\n\t\tvar top = 0;\n\t\tvar left = 0;\n\t\twhile (el != null) {\n\t\t\ttop += el.offsetTop;\n\t\t\tleft += el.offsetLeft;\n\t\t\tel = el.offsetParent;\n\t\t}\n\t\ttop += window.pageYOffset;\n\t\treturn {\n\t\t\t\"top\": top,\n\t\t\t\"left\": left\n\t\t};\n\t}", "title": "" }, { "docid": "d119bb3bc1b16172784cb5c133f4c90c", "score": "0.5404502", "text": "vfunc_get_preferred_height() {\n return [MIN_GRID_SIZE, MIN_GRID_SIZE];\n }", "title": "" }, { "docid": "44656c2f45d1520343a2dbb3b5672d9e", "score": "0.53995115", "text": "get overlayHeaderLabelTopMargin() {\r\n return this.i.c9;\r\n }", "title": "" }, { "docid": "caa3930151f9919c89af34b9626a5bfe", "score": "0.5388365", "text": "function visible_area(){\n\tlet y = parseInt(window.pageYOffset);\n\tlet height = parseInt(window.innerHeight);\n\treturn {top: y, bottom: y + height, height: height}\n}", "title": "" }, { "docid": "cbb6468b603f1ab27c403d53abd488e3", "score": "0.5387385", "text": "_getPositionStrategy() {\n return this._overlayRef.getConfig().positionStrategy;\n }", "title": "" }, { "docid": "5bf5a82d337c7985392fe19e6b32860d", "score": "0.5374442", "text": "function getTop() {\n\t\t\treturn openedDirectives.top();\n\t\t}", "title": "" }, { "docid": "f84a147024db5facc16e774ac909d76f", "score": "0.53728586", "text": "function ensureTop(given, view) {\n return (given == null ? view.contentDOM.getBoundingClientRect().top : given) + view.viewState.paddingTop;\n}", "title": "" }, { "docid": "7e7fa3876319b3894bdfa8f811de71af", "score": "0.53682125", "text": "function xTop(e, iY)\r\n{\r\n if(!(e=xGetElementById(e))) return 0;\r\n var css=xDef(e.style);\r\n if(css && xStr(e.style.top)) {\r\n if(xNum(iY)) e.style.top=iY+'px';\r\n else {\r\n iY=parseInt(e.style.top);\r\n if(isNaN(iY)) iY=xGetComputedStyle(e,'top',1);\r\n if(isNaN(iY)) iY=0;\r\n }\r\n }\r\n else if(css && xDef(e.style.pixelTop)) {\r\n if(xNum(iY)) e.style.pixelTop=iY;\r\n else iY=e.style.pixelTop;\r\n }\r\n return iY;\r\n}", "title": "" }, { "docid": "da59496e28fd6db58e4e1087cf605cf9", "score": "0.5364146", "text": "function fitTop(bottomConstraint,flyoutMeasurements){nextTop=bottomConstraint-flyoutMeasurements.totalHeight;nextAnimOffset=AnimationOffsets.top;return nextTop>=_Overlay._Overlay._keyboardInfo._visibleDocTop&&nextTop+flyoutMeasurements.totalHeight<=_Overlay._Overlay._keyboardInfo._visibleDocBottom;}", "title": "" }, { "docid": "101ef278c62d21751754a85c664553ba", "score": "0.5361687", "text": "get top() {\n return this.topPad;\n }", "title": "" }, { "docid": "4199f71a715064bff0e3807890ecd381", "score": "0.5355081", "text": "function setTop(e){\n\t\t\tif(e.pageY < ($(window).height() / 2)){\n\t\t\t\treturn e.pageY + 10;\n\t\t\t} else {\n\t\t\t\treturn e.pageY - parseInt($('#tooltip').height()) - 20;\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "77cf75a8f9ec617d1b8b09ab7cba7f22", "score": "0.5347925", "text": "getActualWindowScaleVertical() {\r\n let iv = this.i.eh();\r\n return (iv);\r\n }", "title": "" }, { "docid": "3c2f58cfc250b430c90a8950dda4380b", "score": "0.53417534", "text": "get height() {return window.innerHeight - 71;}", "title": "" }, { "docid": "d019c2dda04e1529d808a52407ef0728", "score": "0.5328282", "text": "function _getWindowHeight() {\n var height = interactiveEl.offsetHeight;\n var style = getComputedStyle(interactiveEl);\n\n return height + parseInt(style.marginTop) + parseInt(style.marginBottom);\n}", "title": "" }, { "docid": "f1bc94185acfabc7a6f960c49e9722fb", "score": "0.5319664", "text": "function newTop(windowHeight, pos, adjuster, inertia){\n return (-((windowHeight + pos) - adjuster) * inertia) + \"px\";\n }", "title": "" }, { "docid": "249c52200da3ccfd4dfadd03dd7d75e2", "score": "0.53188187", "text": "function topPosition() {\r\n return typeof window.pageYOffset != 'undefined' ? window.pageYOffset : document.documentElement && document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop ? document.body.scrollTop : 0;\r\n}", "title": "" }, { "docid": "ff3d90fb5ee5649d64a1d9fa058d3233", "score": "0.5311426", "text": "get _visibleDocBottomOffset() {\n\t // For -ms-device-fixed positioned elements, the bottom is just 0 when there's no IHM.\n\t // When the IHM appears, the text input that invoked it may be in a position on the page that is occluded by the IHM.\n\t // In that instance, the default browser behavior is to resize the visual viewport and scroll the input back into view.\n\t // However, if the viewport resize is prevented by an IHM event listener, the keyboard will still occlude\n\t // -ms-device-fixed elements, so we adjust the bottom offset of the appbar by the height of the occluded rect of the IHM.\n\t return exports._KeyboardInfo._extraOccluded;\n\t }", "title": "" }, { "docid": "1fd3fc7f5497ea10ed6fc6f18dc1d22b", "score": "0.5302973", "text": "get isOutsideBottom() {\n return this.bottom > this.windowHeight;\n }", "title": "" }, { "docid": "ba77d3a68620866cbfa4f1a9b8838f21", "score": "0.5300294", "text": "get_bottom_left() {\n this.__bottom_left_c = this.__bottom_left_c || this.__position.add(new SSCD.Vector(0, this.__size.y));\n return this.__bottom_left_c;\n }", "title": "" }, { "docid": "d358cddbe878a618cf56d84117581e36", "score": "0.5297532", "text": "_pushOverlayOnScreen(start, overlay, scrollPosition) {\n // If the position is locked and we've pushed the overlay already, reuse the previous push\n // amount, rather than pushing it again. If we were to continue pushing, the element would\n // remain in the viewport, which goes against the expectations when position locking is enabled.\n if (this._previousPushAmount && this._positionLocked) {\n return {\n x: start.x + this._previousPushAmount.x,\n y: start.y + this._previousPushAmount.y\n };\n }\n const viewport = this._viewportRect;\n // Determine how much the overlay goes outside the viewport on each\n // side, which we'll use to decide which direction to push it.\n const overflowRight = Math.max(start.x + overlay.width - viewport.width, 0);\n const overflowBottom = Math.max(start.y + overlay.height - viewport.height, 0);\n const overflowTop = Math.max(viewport.top - scrollPosition.top - start.y, 0);\n const overflowLeft = Math.max(viewport.left - scrollPosition.left - start.x, 0);\n // Amount by which to push the overlay in each axis such that it remains on-screen.\n let pushX = 0;\n let pushY = 0;\n // If the overlay fits completely within the bounds of the viewport, push it from whichever\n // direction is goes off-screen. Otherwise, push the top-left corner such that its in the\n // viewport and allow for the trailing end of the overlay to go out of bounds.\n if (overlay.width <= viewport.width) {\n pushX = overflowLeft || -overflowRight;\n }\n else {\n pushX = start.x < this._viewportMargin ? (viewport.left - scrollPosition.left) - start.x : 0;\n }\n if (overlay.height <= viewport.height) {\n pushY = overflowTop || -overflowBottom;\n }\n else {\n pushY = start.y < this._viewportMargin ? (viewport.top - scrollPosition.top) - start.y : 0;\n }\n this._previousPushAmount = { x: pushX, y: pushY };\n return {\n x: start.x + pushX,\n y: start.y + pushY,\n };\n }", "title": "" }, { "docid": "d6868cf8fedf63962c268c107412d8c6", "score": "0.5291085", "text": "get calloutPaddingBottom() {\r\n return this.i.oc;\r\n }", "title": "" } ]
0e3c2cfd8265cdc3c1876c954141d764
Returns one or all computed style properties of an element.
[ { "docid": "4bed3cac9b5dccaee76961275a4cab33", "score": "0.6545665", "text": "function getComputedStyle(node, psuedoElement) {\n return (0,_ownerWindow__WEBPACK_IMPORTED_MODULE_0__.default)(node).getComputedStyle(node, psuedoElement);\n}", "title": "" } ]
[ { "docid": "2f381e6ab82053faafdfa9289c205c69", "score": "0.80558544", "text": "function getStyleComputedProperty(element, property) {\n if (element.nodeType !== 1) {\n return [];\n }\n // NOTE: 1 DOM access here\n const window = element.ownerDocument.defaultView;\n const css = window.getComputedStyle(element, null);\n return property ? css[property] : css;\n}", "title": "" }, { "docid": "26c9d9c52564aedb5860829166d84cf3", "score": "0.8051682", "text": "function getStyleComputedProperty(element, property) {\n if (element.nodeType !== 1) {\n return [];\n }\n // NOTE: 1 DOM access here\n var window = element.ownerDocument.defaultView;\n var css = window.getComputedStyle(element, null);\n return property ? css[property] : css;\n}", "title": "" }, { "docid": "f5411847b5d13cf3f542b023e3ee548c", "score": "0.80358416", "text": "function getStyleComputedProperty(element, property) {\n if (element.nodeType !== 1) {\n return [];\n } // NOTE: 1 DOM access here\n\n\n var window = element.ownerDocument.defaultView;\n var css = window.getComputedStyle(element, null);\n return property ? css[property] : css;\n }", "title": "" }, { "docid": "165d1994b45c7f67b5421021b51437b6", "score": "0.8012041", "text": "function getStyleComputedProperty(element, property) {\n if (element.nodeType !== 1) {\n return [];\n }\n // NOTE: 1 DOM access here\n var window = element.ownerDocument.defaultView;\n var css = window.getComputedStyle(element, null);\n return property ? css[property] : css;\n }", "title": "" }, { "docid": "ef2aa9986aab833461155bc3f62a1f40", "score": "0.77868867", "text": "function get(element){return getComputedStyle(element)}", "title": "" }, { "docid": "7bcdfe1b5ccf0899d9ae259453a99493", "score": "0.7676834", "text": "function get(element) {\n return getComputedStyle(element);\n }", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "09c3a914261439c1fe1220283cdd674f", "score": "0.75701684", "text": "function get(element) {\n return getComputedStyle(element);\n}", "title": "" }, { "docid": "15c49d5a4df9035045a3a4a8c1d046b0", "score": "0.75411624", "text": "static get_css_properties_for_element(element){\n\t\tlet copystyle = typeof(element.dataset.copystyle)!=\"undefined\"?parser.trim(element.dataset.copystyle):false;\n\t\tlet style = element.getAttribute('style');\n\t\tif(style!=null){\n\t\t\tstyle = parser.scss_to_array(parser.trim(style));\n\t\t\tif(typeof(style['style'])!=\"undefined\"){\n\t\t\t\tstyle = style['style'];\n\t\t\t\t}\n\t\t\t}\n\t\telse{\n\t\t\treturn {};\n\t\t\t}\n\t\tif(Object.keys(style).length>0 && copystyle!=false && copystyle!=\"\" ){\n\t\t\tlet aout = {};\n\t\t\tcopystyle = parser.scss_to_array(parser.trim(copystyle));\n\t\t\tif(typeof(copystyle['style'])!=\"undefined\"){\n\t\t\t\tcopystyle = copystyle['style'];\n\t\t\t\tfor(let key in style){\n\t\t\t\t\tif(typeof(copystyle[key])=='undefined'||style[key]!=copystyle[key]){\n\t\t\t\t\t\taout[key] = style[key];\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\treturn aout;\n\t\t\t}\n\t\treturn style;\n\t\t}", "title": "" }, { "docid": "0f106abf474bd4ff8728e16fa226daf3", "score": "0.7402594", "text": "function computedStyle(el, prop, getComputedStyle, style) {\n\t getComputedStyle = window.getComputedStyle;\n\t style =\n\t // If we have getComputedStyle\n\t getComputedStyle ?\n\t // Query it\n\t // TODO: From CSS-Query notes, we might need (node, null) for FF\n\t getComputedStyle(el) :\n\t\n\t // Otherwise, we are in IE and use currentStyle\n\t el.currentStyle;\n\t if (style) {\n\t return style\n\t [\n\t // Switch to camelCase for CSSOM\n\t // DEV: Grabbed from jQuery\n\t // https://github.com/jquery/jquery/blob/1.9-stable/src/css.js#L191-L194\n\t // https://github.com/jquery/jquery/blob/1.9-stable/src/core.js#L593-L597\n\t prop.replace(/-(\\w)/gi, function (word, letter) {\n\t return letter.toUpperCase();\n\t })\n\t ];\n\t }\n\t}", "title": "" }, { "docid": "9364b7edaaadd0c685470f72d239e337", "score": "0.72647536", "text": "function _getComputedStyles(element, desiredStyles)\n{\n\tif (!element || element.nodeType != 1 || !element.tagName) return;\n\n\tvar styles = new Object();\n\n\tif (window.getComputedStyle)\n\t{\n\t\tcompStyle = element.ownerDocument.defaultView.getComputedStyle(element, '');\n\n\t\tfor (var i = 0; i < compStyle.length; ++i)\n\t\t{\n\t\t\tvar a = compStyle.item(i),\n\t\t\t\tv = compStyle.getPropertyValue(a);\n\n\t\t\tif (desiredStyles[a]) styles[a] = v;\n\t\t}\n\t}\n\telse if (element.currentStyle)\n\t{\n\t\tfor (var i in desiredStyles)\n\t\t{\n\t\t\tvar v = eval('element.currentStyle.' + desiredStyles[i]);\n\t\t\tif (v)\n\t\t\t{\n\t\t\t\tif (typeof(v) != 'string') v = v.toString();\n\t\t\t\tstyles[i] = v;\n\t\t\t}\n\t\t}\n\t}\n\n\treturn styles;\n}", "title": "" }, { "docid": "8c38130ecd6d2b8f9f5884712b40771f", "score": "0.724479", "text": "function getStyles(elem) {\n return window.getComputedStyle(elem, null);\n }", "title": "" }, { "docid": "f4a562ec776ce463d40b7c61ea435181", "score": "0.7226928", "text": "function getElementComputedStyle(element) {\n const win = getOwnerWindow(element);\n return windowGetComputedStyle.call(win, element);\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "85a2aeb6f4e3ad296ba64483d1f5d2c5", "score": "0.71562374", "text": "function getStyles( elem ) {\n\treturn window.getComputedStyle( elem, null );\n}", "title": "" }, { "docid": "a6f42ae4353db2def5b06f3a483f7466", "score": "0.71408826", "text": "function computedStyle(element, styleProp) {\n var el;\n el = typeof element === 'string' ? document.querySelector(element) : element;\n var value;\n var defaultView = (el.ownerDocument || document).defaultView;\n // W3C standard way:\n if (defaultView && defaultView.getComputedStyle) {\n // sanitize property name to css notation\n // (hypen separated words eg. font-Size)\n styleProp = styleProp.replace(/([A-Z])/g, '-$1').toLowerCase();\n return defaultView.getComputedStyle(el, null).getPropertyValue(styleProp);\n }\n else if (el['currentStyle']) {\n // IE\n // sanitize property name to camelCase\n styleProp = styleProp.replace(/\\-(\\w)/g, function (letter) {\n return letter.toUpperCase();\n });\n value = el['currentStyle'][styleProp];\n // convert other units to pixels on IE\n if (/^\\d+(em|pt|%|ex)?$/i.test(value)) {\n return (function (val) {\n var oldLeft = el.style.left, oldRsLeft = el['runtimeStyle'].left;\n el['runtimeStyle'].left = el['currentStyle'].left;\n el.style.left = val || 0;\n val = el.style['pixelLeft'] + 'px';\n el.style.left = oldLeft;\n el['runtimeStyle'].left = oldRsLeft;\n return val;\n })(value);\n }\n return value;\n }\n}", "title": "" }, { "docid": "43e24be60f4537e47dd9ea346164afa7", "score": "0.7120393", "text": "function getStyles( elem ) {\r\n\treturn window.getComputedStyle( elem, null );\r\n}", "title": "" }, { "docid": "e9abf5c109480a257346383fd36fe2f0", "score": "0.7098065", "text": "function getStyles(element) {\n if (document.defaultView && document.defaultView.getComputedStyle) {\n return document.defaultView.getComputedStyle(element, null);\n }\n return element.currentStyle;\n}", "title": "" }, { "docid": "7b7b5c0f1638932280be11a27d06edc7", "score": "0.70624477", "text": "function i(t){return getComputedStyle(t)}", "title": "" }, { "docid": "7b7b5c0f1638932280be11a27d06edc7", "score": "0.70624477", "text": "function i(t){return getComputedStyle(t)}", "title": "" }, { "docid": "7b7b5c0f1638932280be11a27d06edc7", "score": "0.70624477", "text": "function i(t){return getComputedStyle(t)}", "title": "" }, { "docid": "e75435d72467e6874e452463c83591ef", "score": "0.70546794", "text": "function i(e){return getComputedStyle(e)}", "title": "" }, { "docid": "e75435d72467e6874e452463c83591ef", "score": "0.70546794", "text": "function i(e){return getComputedStyle(e)}", "title": "" }, { "docid": "e75435d72467e6874e452463c83591ef", "score": "0.70546794", "text": "function i(e){return getComputedStyle(e)}", "title": "" }, { "docid": "e75435d72467e6874e452463c83591ef", "score": "0.70546794", "text": "function i(e){return getComputedStyle(e)}", "title": "" }, { "docid": "e75435d72467e6874e452463c83591ef", "score": "0.70546794", "text": "function i(e){return getComputedStyle(e)}", "title": "" }, { "docid": "596bf964eea06ed00d21962e3782a925", "score": "0.6996947", "text": "function r(e){return getComputedStyle(e)}", "title": "" }, { "docid": "596bf964eea06ed00d21962e3782a925", "score": "0.6996947", "text": "function r(e){return getComputedStyle(e)}", "title": "" }, { "docid": "596bf964eea06ed00d21962e3782a925", "score": "0.6996947", "text": "function r(e){return getComputedStyle(e)}", "title": "" }, { "docid": "596bf964eea06ed00d21962e3782a925", "score": "0.6996947", "text": "function r(e){return getComputedStyle(e)}", "title": "" }, { "docid": "596bf964eea06ed00d21962e3782a925", "score": "0.6996947", "text": "function r(e){return getComputedStyle(e)}", "title": "" }, { "docid": "901ed16cc6c34f190e415171905b2b44", "score": "0.69549155", "text": "function getComputedStyle(element, property) {\r\n if (element.currentStyle) {\r\n return element.currentStyle[property];\r\n }\r\n return document.defaultView.getComputedStyle(element, null).getPropertyValue(property);\r\n}", "title": "" }, { "docid": "37faa676f677775d4c11807bbeb4dae3", "score": "0.6922941", "text": "function computeStyle(element: HTMLElement, prop: string): string {\n // TODO: workaround https://bugzilla.mozilla.org/show_bug.cgi?id=548397\n return window.getComputedStyle(element, null).getPropertyValue(prop);\n }", "title": "" }, { "docid": "d8cc56fc05fc75256b5e9bbd97c45c5e", "score": "0.69144017", "text": "function r(t){return getComputedStyle(t)}", "title": "" }, { "docid": "d8cc56fc05fc75256b5e9bbd97c45c5e", "score": "0.69144017", "text": "function r(t){return getComputedStyle(t)}", "title": "" }, { "docid": "d8cc56fc05fc75256b5e9bbd97c45c5e", "score": "0.69144017", "text": "function r(t){return getComputedStyle(t)}", "title": "" }, { "docid": "d8cc56fc05fc75256b5e9bbd97c45c5e", "score": "0.69144017", "text": "function r(t){return getComputedStyle(t)}", "title": "" }, { "docid": "55bd98cda5cea26120ed46066d556d05", "score": "0.69086653", "text": "function getCSS(element, property) {\n\n var elem = document.getElementsByTagName(element)[0];\n var css = null;\n \n if (elem.currentStyle) {\n css = elem.currentStyle[property];\n \n } else if (window.getComputedStyle) {\n css = document.defaultView.getComputedStyle(elem, null).\n getPropertyValue(property);\n }\n \n return css;\n\n}", "title": "" }, { "docid": "eb3c73b7f7327d3f99d674fad6ad8abe", "score": "0.68525636", "text": "function re(t){return getComputedStyle(t)}", "title": "" }, { "docid": "8a7da45ad98e46216a3e2a5a825e5c47", "score": "0.6805757", "text": "function e(t){return getComputedStyle(t)}", "title": "" }, { "docid": "8a7da45ad98e46216a3e2a5a825e5c47", "score": "0.6805757", "text": "function e(t){return getComputedStyle(t)}", "title": "" }, { "docid": "8cbea1f5c7a521fe7e54c425789e2167", "score": "0.67722374", "text": "function n(t){return getComputedStyle(t)}", "title": "" }, { "docid": "8cbea1f5c7a521fe7e54c425789e2167", "score": "0.67722374", "text": "function n(t){return getComputedStyle(t)}", "title": "" }, { "docid": "8cbea1f5c7a521fe7e54c425789e2167", "score": "0.67722374", "text": "function n(t){return getComputedStyle(t)}", "title": "" }, { "docid": "c5044d0f707677aca24555d824847eee", "score": "0.6757913", "text": "function a(t){return getComputedStyle(t)}", "title": "" }, { "docid": "482b7eaf0fd4e21862cfa0c592920bd4", "score": "0.6749491", "text": "function getCSS(element, property) {\n\n var elem = document.getElementById(element);\n var css = null;\n\n if (elem.currentStyle) {\n css = elem.currentStyle[property];\n\n } else if (window.getComputedStyle) {\n css = document.defaultView.getComputedStyle(elem, null).\n getPropertyValue(property);\n }\n\n return css;\n\n}", "title": "" }, { "docid": "a88f1240cdb52ca60a01bd494b860bcc", "score": "0.67486715", "text": "function getElementComputedStyle(el) {\n var _window$getComputedSt, _window;\n\n return el ? null === (_window$getComputedSt = (_window = window).getComputedStyle) || void 0 === _window$getComputedSt ? void 0 : _window$getComputedSt.call(_window, el) : null;\n}", "title": "" }, { "docid": "6146514b3df27189c89fb644bae1bfc9", "score": "0.6740946", "text": "function getStyle(el, prop) {\n return window.getComputedStyle !== undefined ? window.getComputedStyle(el, null).getPropertyValue(prop) : el.currentStyle[prop];\n }", "title": "" }, { "docid": "389915e7d6114616d5c3ee9b2d27e451", "score": "0.67219377", "text": "getComputedStyle(name) {\n\n if (this.#computedStyles[name]) {\n return this.#computedStyles[name]\n }\n\n this.#computedStyles = globalThis.getComputedStyle(this.#element)\n\n return this.#computedStyles[name]\n }", "title": "" }, { "docid": "5796080bbcce252b85772bf58d5ddbab", "score": "0.6719299", "text": "function getElementProperty(element, property) {\n return window.getComputedStyle(element)[property];\n }", "title": "" }, { "docid": "0ce76e5efe6e2412117d91e3a3056584", "score": "0.67179847", "text": "function j(e){return getComputedStyle(e)}", "title": "" }, { "docid": "f081fdf5711f69d81fbd10c7c8f32006", "score": "0.6709896", "text": "function getStyle(el, prop) {\n return el.getStyle(prop);\n}", "title": "" }, { "docid": "f741a8160d9db04ad05508354ec27d41", "score": "0.6696319", "text": "function _getStyle(el, property) {\n if ( window.getComputedStyle ) {\n return document.defaultView.getComputedStyle(el,null)[property];\n }\n if ( el.currentStyle ) {\n return el.currentStyle[property];\n }\n }", "title": "" }, { "docid": "2d2984f5fddb001ca22e3f3f4fee5f55", "score": "0.6672615", "text": "function o(t){return getComputedStyle(t)}", "title": "" }, { "docid": "2d2984f5fddb001ca22e3f3f4fee5f55", "score": "0.6672615", "text": "function o(t){return getComputedStyle(t)}", "title": "" }, { "docid": "687e054895087450f9e59a8e7f05cb7f", "score": "0.6653592", "text": "function Ci(t){return getComputedStyle(t)}", "title": "" }, { "docid": "8afe97acc23ee95b21edf9db40ad061d", "score": "0.663739", "text": "function t(A){return getComputedStyle(A)}", "title": "" }, { "docid": "34f4dd8f5d00131eae466e6add56cac9", "score": "0.6635465", "text": "function Nl(e){return getComputedStyle(e)}", "title": "" }, { "docid": "5337edeea5a61a6185c76a4f4945a53d", "score": "0.66310054", "text": "function css(/* Element */ el, ruleName) {\n return _getComputedStyle(el)[ruleName];\n}", "title": "" }, { "docid": "b7bff0f5dd996e740c0266cc0eddfc3a", "score": "0.6625308", "text": "function getCSS( elem, prop, noVendorPrefix ) {\n var value;\n var doc = ( elem.ownerDocument || document );\n var view = doc.defaultView;\n\n // Try with vendor prefixes\n if ( !noVendorPrefix && isDefined( jQLite.css.vendorPrefix[ prop ] ) ) {\n forEach( jQLite.css.vendorPrefix[ prop ], function( prefix ) {\n if ( isDefined( value ) && value !== \"\" ) {\n return;\n }\n\n value = getCSS( elem, prefix + prop, true );\n });\n\n return value;\n }\n\n // Do we have W3C support (AKA not oldIE)?\n if ( view && view.getComputedStyle ) {\n // Try to get from the computed style first\n value = view.getComputedStyle( elem, null ).getPropertyValue( prop );\n\n // If nothing found and the element is detached,\n // we can go look into the style declaration.\n if ( value === \"\" && !contained( elem ) ) {\n value = elem.style.getPropertyValue( prop );\n }\n } else if ( elem.currentStyle ) {\n // Aaaaw crap, we're at oldIE :(\n // We need to make the property camelCase\n prop = prop.replace( /\\-(\\w)/g, function( str, letter ) {\n return letter.toUpperCase();\n });\n\n value = elem.currentStyle[ prop ];\n\n if ( /^\\d+(em|pt|%|ex)?$/i.test( value ) ) {\n // Convert other units to pixels\n return (function( val ) {\n var oldLeft = elem.style.left;\n var oldRuntimeLeft = elem.runtimeStyle.left;\n\n elem.runtimeStyle.left = elem.currentStyle.left;\n elem.style.left = value || 0;\n value = elem.style.pixelLeft + \"px\";\n elem.style.left = oldLeft;\n elem.runtimeStyle.left = oldRuntimeLeft;\n return val;\n })( value );\n }\n }\n\n return value;\n }", "title": "" }, { "docid": "1e5d493bfd5e8d352f21b14fc36e72c6", "score": "0.6621242", "text": "function i(e) {\n return getComputedStyle(e)\n }", "title": "" }, { "docid": "e47a115625cc1c2afc3ff3ed3b5fe3f6", "score": "0.6598839", "text": "function getComputedStyle(ele, style) {\n if (ele.currentStyle) {\n return ele.currentStyle[style]\n } else {\n return window.getComputedStyle(ele)[style]\n }\n}", "title": "" }, { "docid": "df60895599d3517a89104464a60c7f57", "score": "0.65981877", "text": "function getComputedValue(elem,prop){ // expects syntax like 'background-color'\n \"use strict\";\nif(!elem)return null;\n if(!(\"gcs\" in getComputedValue) && document.defaultView && document.defaultView.getComputedStyle){\n // expects syntax like 'background-color'\n // cache value, since function may be slow if called many times\n getComputedValue.gcs=document.defaultView;\n } else if(!(\"gcs\" in getComputedValue) && window.getComputedStyle){\n // expects syntax like 'background-color'\n getComputedValue.gcs=window;\n } else if(!(\"gcs\" in getComputedValue)){\n getComputedValue.gcs=null;\n }\n if(\"gcs\" in getComputedValue && (typeof getComputedValue.gcs!==\"undefined\" && getComputedValue.gcs!==null))\n return getComputedValue.gcs.getComputedStyle(elem,null).getPropertyValue(prop);\n if(elem){\n try {\n if(\"currentStyle\" in elem){\n // expects syntax like 'backgroundColor'\n if(prop===\"float\"){\n prop=(\"cssFloat\" in elem.currentStyle) ? \"cssFloat\" : \"styleFloat\";\n } else {\n prop=prop.replace(/-([a-z])/g,function(a,b){return b.toUpperCase();});\n }\n return elem.currentStyle[prop];\n }\n } catch(ex){}\n // Just get regular style\n if(\"style\" in elem){\n // expects syntax like 'backgroundColor'\n if(prop===\"float\"){\n prop=(\"cssFloat\" in elem.style) ? \"cssFloat\" : \"styleFloat\";\n } else {\n prop=prop.replace(/-([a-z])/g,function(a,b){return b.toUpperCase();});\n }\n return elem.style[prop];\n }\n }\n return(null);\n}", "title": "" }, { "docid": "c30899f73fb9390b4e174bace1329d5a", "score": "0.65892535", "text": "get styles() {\n if (this.nativeElement && this.nativeElement.style) {\n return this.nativeElement.style;\n }\n return {};\n }", "title": "" }, { "docid": "f780fa90a3c590956473535a84757440", "score": "0.65871614", "text": "function getStyle( element, property ) {\n\t\tvar value;\n\n\t\tif ( document.defaultView && document.defaultView.getComputedStyle ) {\n\t\t\t// The lovely way of retrieving computed style\n\t\t\tvalue = document.defaultView.getComputedStyle( element, \"\" ).getPropertyValue( property );\n\t\t} else {\n\t\t\t// The... other (read: Microsoft) way\n\t\t\tproperty = property.replace(/\\-(\\w)/g, function( match, prop ) { // Artz: match var is unused\n\t\t\t\treturn prop.toUpperCase();\n\t\t\t});\n\n\t\t\tvalue = element.currentStyle[property];\n\t\t}\n\n\t\treturn value;\n\t}", "title": "" }, { "docid": "095be5cf321c0da3599dcc51f1ee0c2e", "score": "0.65858", "text": "function getElementComputedStyle(element, styleProp) {\n var y = null;\n var doc = getOwnerDocument(element);\n\n if (element.currentStyle) {\n y = element.currentStyle[styleProp];\n } else if (doc && doc.defaultView && isFunction(doc.defaultView.getComputedStyle)) {\n y = doc.defaultView.getComputedStyle(element, null).getPropertyValue(styleProp);\n }\n\n return y;\n}", "title": "" }, { "docid": "26e2a308dddd97ddc1760b3733b4c3e2", "score": "0.6533182", "text": "function getUsedValues (element) {\n var matched_rules, rule, computed, style, property,\n used_values = {};\n // get the matched rules from all style sheets\n matched_rules = global.getMatchedCSSRules(element);\n // if nothing is matched we get null so bail out\n if ( ! matched_rules ) return used_values;\n // convert the matched rules into an Array\n matched_rules = toArray(matched_rules);\n // get the actual computed style\n //TODO: not supporting pseudo elements\n computed = global.getComputedStyle(element, null);\n\n // loop over the matched rules from the end since they should come in cascade order\n while ( rule = matched_rules.pop() ) {\n //for each rule convert rule.style into an array\n style = toArray(rule.style);\n // loop over the array of style properties\n while ( property = style.shift() ) {\n // if it's not in used_values and its value equals computed[property]\n if ( ! (property in used_values) && rule.style.getPropertyValue(property) === computed.getPropertyValue(property) ) {\n used_values[property] = rule.style.getPropertyValue(property);\n }\n }\n }\n return used_values;\n }", "title": "" }, { "docid": "3870ea559cc7441c5889afac4a216f47", "score": "0.6519369", "text": "function getNodeComputedStyles(node){\n // TODO USE COMPUTED STYLE AND CSSRULE TO SEE FIND SPECIAL CASES\n // USE PROPERTY VALUE CONTENT TO TEXT FOR :BEFORE/:AFTER\n return {\n 'style_cssText': node.style.cssText,\n 'style_propertyValue': node.style.getPropertyValue(\"\"),\n 'hover': getComputedStyle(node,\":hover\").getPropertyValue(\"\"),\n 'before': getComputedStyle(node,\":before\").getPropertyValue(\"\"),\n 'after': getComputedStyle(node,\" :after\").getPropertyValue(\"\"),\n \"computedStyle\": getComputedStyle(parent).getPropertyValue(\"\"),\n }\n}", "title": "" }, { "docid": "160e9d8055f9ca7cc1ce44f2806c9ee6", "score": "0.650924", "text": "function getComputedStyleCssText(element) {\n\t var style = window.getComputedStyle(element);\n\t var cssText;\n\n\t cssText = \"\";\n\t for (var i = 0; i < style.length; i++) {\n\t\tcssText += style[i] + \": \" + style.getPropertyValue(style[i]) + \"; \";\n\t }\n\n\t return cssText;\n\t}", "title": "" }, { "docid": "75d579c3a0f177929b6b2129e32589c4", "score": "0.64941156", "text": "static getStyles(elem) {\n // Support: IE <=11 only, Firefox <=30 (#15098, #14150)\n // IE throws on elements created in popups\n // FF meanwhile throws on frame elements through \"defaultView.getComputedStyle\"\n let view = elem.ownerDocument.defaultView;\n if (!view || !view.opener) {\n view = win$1;\n }\n return view.getComputedStyle(elem);\n }", "title": "" }, { "docid": "70009cc54772c22debe423fade51a1f2", "score": "0.64932793", "text": "function vo(e) {\n return getComputedStyle(e)\n }", "title": "" }, { "docid": "6d648e8be4fcc833a2258c4accbdd706", "score": "0.64758086", "text": "function abstract_get_computed_style(obj,property)\n{\n\t// LEGACY: IE8\n\tif (obj.currentStyle)\n\t{\n\t\tvar index=property.indexOf('-');\n\t\tif (index!=-1)\n\t\t{\n\t\t\tproperty=property.substring(0,index)+property.substring(index+1,index+2).toUpperCase()+property.substring(index+2,property.length);\n\t\t}\n\t\treturn obj.currentStyle[property];\n\t}\n\n\tvar ret=null;\n\ttry {\n\t\tret=document.defaultView.getComputedStyle(obj,null).getPropertyValue(property);\n\t}\n\tcatch(e) { }\n\tif (ret===null) ret='';\n\n\tif (ret===null) ret='';\n\n\treturn ret;\n}", "title": "" }, { "docid": "4553e8213c1711e5f02eb2182d40079d", "score": "0.64617956", "text": "function Fl(t){return getComputedStyle(t)}", "title": "" }, { "docid": "edd0d723d0124942eb4f4665fd5adc44", "score": "0.6445764", "text": "function getComputedStyle(node, psuedoElement) {\n return ownerWindow(node).getComputedStyle(node, psuedoElement);\n}", "title": "" }, { "docid": "edd0d723d0124942eb4f4665fd5adc44", "score": "0.6445764", "text": "function getComputedStyle(node, psuedoElement) {\n return ownerWindow(node).getComputedStyle(node, psuedoElement);\n}", "title": "" }, { "docid": "66ed22136de8ea229a11e2cdd81d5f4c", "score": "0.64409304", "text": "function getStyle(el, cssprop){\n\t\tif (el.currentStyle) {\n\t\t\treturn el.currentStyle[cssprop];\n\t\t} else if (document.defaultView && document.defaultView.getComputedStyle) {\n\t\t\treturn document.defaultView.getComputedStyle(el, \"\")[cssprop];\n\t\t}\n\t}", "title": "" }, { "docid": "ca5b43260f05aa1896e9c285ad197a82", "score": "0.64002407", "text": "function getStyleProp( element, style ) {\r\n var value = element.style[ style ];\r\n if( value )\r\n \treturn value;\r\n\r\n if( userAgent.hasComputedStyle ) {\r\n var doc = element.ownerDocument || element.document;\r\n value = doc.defaultView.getComputedStyle(element, '').getPropertyValue(style);\r\n } else if( element.currentStyle ) {\r\n value = element.currentStyle[ style ];\r\n }\r\n return value;\r\n}", "title": "" }, { "docid": "e19fc7739d5bcecfa84818ccb6202a65", "score": "0.6399195", "text": "css(el, styles) {\n if (typeof styles === 'string') {\n return window.getComputedStyle(el).getPropertyValue(styles);\n }\n\n // add transform property with vendor prefix\n if (styles.transform) {\n styles['-webkit-transform'] = styles.transform;\n }\n\n Object.keys(styles).forEach((key) => {\n el.style[key] = styles[key];\n });\n return el;\n }", "title": "" }, { "docid": "d505e670380fa7d1e85cee7b1d7c34b7", "score": "0.6382505", "text": "computeStyle(element, solid){\n\n let selectedCSSRules =\n _.filter(this.css,\n r => { return CSSselect.is(element, r.selectors.join(','))})\n\n let computedStyle = {}\n function setProperty(decl){\n\n if (decl.value == 'inherit' && solid.parent){\n // console.log('inherit', element.parent.style)\n // if (element.)\n // console.log(element, element.parent)\n // computedStyle[decl.property] = element.parent.style[decl.property]\n computedStyle[decl.property] = solid.parent.style[decl.property]\n\n\n } else {\n\n computedStyle[decl.property] = decl.value\n\n }\n }\n\n _.forEach(selectedCSSRules, rule => {\n _.forEach(rule.declarations, decl => {\n setProperty(decl)\n })\n })\n return computedStyle\n }", "title": "" }, { "docid": "a4c8d7b8a2c58c8ee6315a0529a8507e", "score": "0.63687736", "text": "function getStyle(el){\n\treturn el.currentStyle || window.getComputedStyle(el);\n}", "title": "" }, { "docid": "ff58bcf4b0b3738384dfe564b1e5e899", "score": "0.6353257", "text": "function getElementStyle(name, element) {\n var computedStyle = (0,_utils_get_computed_style__WEBPACK_IMPORTED_MODULE_0__.default)(element) || {};\n return (0,_utils_type_conversion__WEBPACK_IMPORTED_MODULE_1__.toNumber)(computedStyle[name]);\n}", "title": "" }, { "docid": "d9d3255ea9e39a1de2a741fa8c41d7be", "score": "0.63353837", "text": "_glasscord_getCssProp(propName){\n\t\treturn this.webContents.executeJavaScript(\"(function(){let flag = getComputedStyle(document.documentElement).getPropertyValue('\"+propName+\"'); if(flag) return flag.trim().replace('\\\"','');}())\").then(res => { if(res) return res; else return null;});\n\t}", "title": "" } ]
0c279599821c6f006f82153f1257427a
finds the row which should be switched with the diagonal element of the matrix. calculated by finding maximum number after diagonal element which is to be swapped.
[ { "docid": "6e272d7961caa6c3ca5b8b06c685dc93", "score": "0.0", "text": "function _pivot(/* Matrix */ a, /* integer */ index){\n\t\tvar returnIndex = index;\n\t\tvar value = Math.abs(a.m[index][index]);\n\t\tfor(var i = index + 1; i < a.rows; i++){\n\t\t\tvar temp = Math.abs(a.m[i][index]);\n\t\t\tif(temp > _epsilon && temp > value){\n\t\t\t\tvalue = temp;\n\t\t\t\treturnIndex = i;\n\t\t\t}\n\t\t}\n\n\t\treturn returnIndex;\n\t}", "title": "" } ]
[ { "docid": "8410aa9760dc9c1be4578bb191437144", "score": "0.63333106", "text": "function swapDiagonals(matrix) {\n let row = 0\n let col = 0\n let temp\n \n while(row <= matrix.length - 1){\n temp = matrix[row][col]\n matrix[row][col] = matrix[row][(matrix[row].length - 1) - col]\n matrix[row][(matrix[row].length - 1) - col] = temp\n col ++\n row ++\n }\n return matrix\n}", "title": "" }, { "docid": "d075d43da8b0280c6cbc8cc87ddc804f", "score": "0.6255669", "text": "function swapDiagonals(matrix) {\n let row = 0\n let col = 0\n\n while(row <= matrix.length - 1){\n [matrix[row][col],matrix[row][(matrix[row].length - 1) - col]] = [matrix[row][(matrix[row].length - 1) - col],matrix[row][col]]\n col ++\n row ++\n }\n return matrix\n}", "title": "" }, { "docid": "29901398f05d68cd0f421ddb7963079d", "score": "0.622426", "text": "function greatestProductOfDiagonals(matrix){\n \n}", "title": "" }, { "docid": "432d472f8667d55bd9f263feac2ecde4", "score": "0.6196201", "text": "function flippingMatrix(matrix) {\n let sum = 0;\n let size = matrix.length;\n for (let i = 0; i < size / 2; i++) {\n for (let j = 0; j < size / 2; j++) {\n sum += Math.max(\n matrix[i][j], // upper left\n matrix[i][size - 1 - j], // upper right\n matrix[size - 1 - i][j], // lower left\n matrix[size - 1 - i][size - 1 - j] // lower right\n )\n }\n }\n return sum\n}", "title": "" }, { "docid": "43290eccb577fd008ffe56bf3e9236d8", "score": "0.61561936", "text": "function lesser(matrix, a) {\n let i = 0, j = 0;\n let num = 0;\n row_len = matrix.length;\n while (i < row_len) {\n j = 0;\n while (j < row_len) {\n if (matrix[i][j] <= a) {\n num++;\n } else if (j == 0) {\n return num;\n } else {\n break;\n }\n j++;\n }\n i++;\n }\n return num;\n}", "title": "" }, { "docid": "544ac8dd468064314afd46a613b4e169", "score": "0.61546665", "text": "winConditionDiagonalRight(board) {\n for (let i = 3; i < 6; i++) {\n for (let j = 0; j < 4; j++) {\n if (board[i][j]) {\n if (board[i][j] === board[i - 1][j + 1] && board[i][j] === board[i - 2][j + 2] && board[i][j] === board[i - 3][j + 3]) {\n return board[i][j];\n }\n }\n }\n }\n }", "title": "" }, { "docid": "f2d924e616d9603c619085df8dc7a29d", "score": "0.6090056", "text": "function searchMatrix(matrix, target) {\n // start at bottom left\n let col = 0;\n let row = matrix.length - 1;\n\n // while within boundaries\n while (col < matrix[0].length && row >= 0) {\n if (matrix[row][col] === target) return [row, col];\n\n if (target < matrix[row][col]) {\n // we know its not on the right so we move up\n row--;\n continue;\n }\n if (target > matrix[row][col]) {\n // we know moving left increases the value\n col++;\n }\n }\n return -1;\n}", "title": "" }, { "docid": "4e99c046c34136efc3467fb40a3f4a4b", "score": "0.6047977", "text": "function printMatrixDiagonally(matrix) {\n let r = 0;\n let c = 1;\n let result = [matrix[0][0]];// [1]\n let goUp = false;\n let goDown = true;\n //while length of result < items in matrix and we have not exceeded the last item i.e not beyond matrix[4][4]\n while(result.length < matrix.length * matrix[0].length ) {\n // if c is not < 0 and r is < 4\n while(c >= 0 && r < matrix.length) {\n result.push(matrix[r][c]);\n // if we have not reached the last item in the matrix i.e matrix[4][4] then continue looping otherwise stop and return result\n if (r !== matrix.length -1 || c !== matrix[0].length -1){\n r++;\n c--;\n } else {\n return result;\n }\n }\n // if c < 0 and or r > matrix length, we need to switch direction to up\n goUp = true;\n goDown = false;\n // if going up :\n if (goUp) {\n // if c < 0 and r > matrix length\n if (r >=matrix.length && c < 0){\n r--;\n c+=2;\n }\n // if c < 0\n if (c < 0 ) {\n c++;\n }\n // if r > matrix length\n if (r >= matrix.length) {\n r--;\n c+=2;\n }\n }\n // As we are going up check if we don't exceed the upper-right limit:\n //while c < matrix[0. length and r is >= 0\n while(c < matrix[0].length && r >= 0) {\n result.push(matrix[r][c]);\n // if we have not reached the last item in the matrix i.e matrix[4][4] then continue looping otherwise stop and return result\n if (r !== matrix.length - 1 || c !== matrix[0].length -1){\n c++;\n r--;\n } else {\n return result;\n }\n\n }\n // As c and or r are out of bound, switch direction to down\n goUp = false;\n goDown = true;\n // going down , bring the indces one step back to the previos place and then go down and left\n if(goDown) {\n if (r < 0 && c >= matrix[0].length) {\n r+=2;\n c--;\n }\n if (r < 0) {\n r++;\n }\n if (c >=matrix[0].length){\n c--;\n r+=2;\n }\n }\n }\n return result;\n}", "title": "" }, { "docid": "d9af16ab24db0a1c70e4f2c9c12f47a4", "score": "0.6044941", "text": "function getRow(column){\n highestPosition[column-1] = highestPosition[column-1]+1;\n var row = highestPosition[column-1];\n if(row > MAXROWS){\n return 0;\n }\n\n return row;\n}", "title": "" }, { "docid": "fcb9efa95512de782a98e23d194c5ee2", "score": "0.6036034", "text": "function diagonalsAttack(matrixRows) {\n let matrix = matrixRows.map(\n row => row.split(' ').map(Number));\n \n let sumFirstDiagonal = 0;\n for (let i = 0; i < matrix.length; i++) {\n sumFirstDiagonal = sumFirstDiagonal + matrix[i][i];\n }\n let sumSecondDiagonal = 0;\n for (let j = 0; j < matrix.length; j++) {\n sumSecondDiagonal = sumSecondDiagonal + matrix[j][matrix.length-1-j];\n }\n \n if (sumFirstDiagonal == sumSecondDiagonal){\n for (let q = 0; q < matrix.length; q++) {\n for (let z = 0; z < matrix.length; z++) {\n if( q != z && q != matrix.length-1-z) {\n matrix[q][z] = sumFirstDiagonal;\n }\n }\n }\n printMatrix(matrix);\n }\n else\n {\n printMatrix(matrix);\n }\n \n function printMatrix(matrix) {\n for (let i = 0; i < matrix.length; i++) {\n console.log(matrix[i].join(' '))\n }\n }\n}", "title": "" }, { "docid": "ca4f306ca33c2ead79ae8acc7ad7d445", "score": "0.60070306", "text": "checkDiagnolDecreasing(){ \r\n for(var i=0,j=this.state.matrix[0].length-1;j>=0;j--,i++){\r\n if(this.state.matrix[i][j] !== this.state.player){\r\n return false;\r\n }\r\n }\r\n return true;\r\n }", "title": "" }, { "docid": "84d11c1323f1e098b6eee3976cc49b92", "score": "0.5973258", "text": "winConditionDiagonalLeft(board) {\n for (let i = 3; i < 6; i++) {\n for (let j = 3; j < 7; j++) {\n if (board[i][j]) {\n if (board[i][j] === board[i - 1][j - 1] && board[i][j] === board[i - 2][j - 2] && board[i][j] === board[i - 3][j - 3]) {\n return board[i][j];\n }\n }\n }\n }\n }", "title": "" }, { "docid": "47a26969ed43cf24758d7fb33647e9dc", "score": "0.5946846", "text": "function diagonalBLTR() {\n return checkConnection({i: 1, j: -1}, {i: 1, j: 1})\n }", "title": "" }, { "docid": "5debc6cf3a84d367c19d21983dc5f076", "score": "0.5897032", "text": "function biggestProductRows(matrix){\n\n let greatestProductRow = 1;\n for (let i = 0; i < matrix[0].length; i++) {\n\n let product = biggestProductRowOrColumn(matrix[i])\n\n if(product > greatestProductRow){\n greatestProductRow = product;\n }\n }\n return greatestProductRow;\n}", "title": "" }, { "docid": "100f070b64001437fad5880a777ab85c", "score": "0.5844901", "text": "function checkDiagonalBLtoTR() {\n return checkWin({ i: 1, j: -1 }, { i: 1, j: 1 });\n }", "title": "" }, { "docid": "2437fe567dec5820d5942d5c89cdbca0", "score": "0.580277", "text": "function recalculate(row, col, countingMatrix) {\n let smallestNeighborVal = countingMatrix[row][col - 1]\n if (countingMatrix[row - 1][col - 1] < smallestNeighborVal) {\n smallestNeighborVal = countingMatrix[row - 1][col - 1]\n }\n if (countingMatrix[row - 1][col] < smallestNeighborVal) {\n smallestNeighborVal = countingMatrix[row - 1][col]\n }\n return smallestNeighborVal + countingMatrix[row][col]\n}", "title": "" }, { "docid": "86414a56d1d3fc49bb7e2705ce82901a", "score": "0.5800409", "text": "function diagonalTLBR() {\n return checkConnection({i: 1, j: 1}, {i: -1, j: -1})\n }", "title": "" }, { "docid": "3a431fec8589eaea9fe8bd83d598808b", "score": "0.57616615", "text": "function diagonalCheckDownRight(player, row, column){\n var count=null;\n var winCondition=false;\n row=row+5;\n column = column-5;\n while(row>=0){\n if(row<=5 && column>=0 && column<=6){\n if(masterArray[column][row]===player){\n count++;\n if(count===4){\n winCondition=true;\n return winCondition;\n }\n } else{\n count=0;\n }\n }\n column++;\n row --;\n }\n return winCondition;\n}", "title": "" }, { "docid": "47aba8dff23f4de073a32026b86a8f43", "score": "0.57593447", "text": "sweep()\n {\n let rowCount = 0;\n\n outer: for (let y = this.row - 1; y > 0; --y) {\n for (let x = 0; x < this.column; ++x) {\n if (this.matrix[y][x] === 0) {\n continue outer;\n }\n }\n \n const row = this.matrix.splice(y, 1)[0].fill(0);\n this.matrix.unshift(row);\n ++y;\n\n rowCount ++;\n }\n return rowCount;\n }", "title": "" }, { "docid": "a832f417095f5fae9842db512e9bca69", "score": "0.5748299", "text": "function getTallestLine(matrix) {\n\treturn matrix.length;\n}", "title": "" }, { "docid": "faf419a15e993e9c0ac15fe66cc9c586", "score": "0.5746379", "text": "checkDiagnolIncreasing(){\r\n for(var i=0,j=0;j<this.state.matrix[0].length;j++,i++){\r\n if(this.state.matrix[i][j] !== this.state.player){\r\n return false;\r\n }\r\n }\r\n return true;\r\n }", "title": "" }, { "docid": "6ff7786f9ece078cb2ec933fee6cb057", "score": "0.5744131", "text": "function solution_1 (binaryMatrix) {\r\n const [h, w] = binaryMatrix.dimensions();\r\n let row = 0; // initialize current `row` and `col` at the top right corner\r\n let col = w - 1;\r\n let lowestCol = w; // initialize record-keeping variable at `w` (which is out of bounds)\r\n while (col >= 0 && row < h) { // while in bounds...\r\n const currentNum = binaryMatrix.get(row, col); // ...check current number...\r\n if (currentNum) { // ...if 1, update `lowestCol` and move left (there may be more 1s to your left)\r\n lowestCol = Math.min(lowestCol, col);\r\n col--;\r\n }\r\n else row++; // ...if 0, move down (there are no more 1s to your left, so move down to the next row)\r\n }\r\n return lowestCol === w ? -1 : lowestCol; // if `lowestCol` never changed, then no 1s exist in the matrix so return -1. else, return `lowestCol`\r\n}", "title": "" }, { "docid": "87aa3ef19fb77aeda16544ebd4539884", "score": "0.5741327", "text": "function diagonalDifference(arr) {\n // Write your code here \n // get the diagonal length of arr, lets say m\n const m = arr.length - 1;\n let primarySum = 0, secondarySum = 0;\n // run a for loop,\n for(let i = 0; i <= m; i++) {\n // on each iteration, get primary Value by reading the arr[i][i], add it to primarySum\n primarySum += arr[i][i];\n // on each iteration, get secondary Value by reading the arr[i][m-i], add it to secondarySum\n secondarySum += arr[i][m-i];\n }\n // finally, return primarySum - secondarySum\n return Math.abs(primarySum - secondarySum);\n}", "title": "" }, { "docid": "d528478780a1cbeed03566cf346509ae", "score": "0.5692853", "text": "function diagonalDifference(a) {\n let firstSum=0;\n let secondSum=0;\n for(let i=0; i<a.length;i++){\n firstSum +=a[i][i];\n }\n let i=0;\n for(let j=a.length-1; j>=0;j--){\n secondSum +=a[j][i];\n i++;\n }\n return Math.abs(firstSum - secondSum);\n}", "title": "" }, { "docid": "6c7d83e9f4f830e5abf5c58d816dfaaf", "score": "0.56804335", "text": "function diagonalDifference(arr) {\n const arrlength = arr[0].length;\n let a = 0;\n let b = 0;\n\n for (let i = 0, j = (arrlength - 1) ; i < arrlength, j > -1; i++, j--) {\n a += arr[i][i];\n b += arr[i][j];\n }\n \n return a > b ? a - b : b - a;\n}", "title": "" }, { "docid": "2d81609fed0bc1d17d4a73679bc4df71", "score": "0.5668187", "text": "checkCurrMinorDiagonal() {\n var loc1 = (this.currVectors[0] & 4);\n var loc2 = (this.currVectors[1] & 2);\n var loc3 = (this.currVectors[2] & 1);\n return (loc1 | loc2 | loc3) === WIN_VECTOR;\n }", "title": "" }, { "docid": "d9e9204d798ada6ac3688652ee5a5d31", "score": "0.5661205", "text": "function search2DII(matrix, target){\n const m = matrix[0].length-1\n let i = matrix.length-1\n let j = 0\n\n while(i>=0 && j<=m){\n if(matrix[i][j]>target){\n i--\n }else if(matrix[i][j]<target){\n j++\n }else{\n return true\n }\n }\n return false\n}", "title": "" }, { "docid": "50c0290acc545e3639232a40c7347863", "score": "0.56354517", "text": "function diagonalCheckDownLeft(player, row, column){\n row += 5;\n column += 5;\n var count = 0;\n var winCondition = false;\n while(row >= 0){\n if(row <= 5 && column >= 0 && column <= 6){\n if(player === masterArray[column][row]){\n count++;\n if(count === 4){\n winCondition = true;\n return winCondition;\n }\n } else {\n count = 0;\n }\n }\n column--;\n row--;\n }\n return winCondition;\n}", "title": "" }, { "docid": "9851d025fe486e6c6145431e832bc06b", "score": "0.5622028", "text": "function diagonalDifference(arr) {\n let x = 0;\n let y = 0;\n let j = arr.length - 1\n\n for (let i = 0; i < arr.length; i++) {\n y += arr[i][j]\n x += arr[i][i]\n j -= 1\n }\n return Math.abs(x-y)\n}", "title": "" }, { "docid": "0556b2c70e510004bd82c5c96f2d4be7", "score": "0.5611426", "text": "function diagonalDifference(arr) {\n let rows = arr.length;\n let lastRowIndex = arr[0].length - 1;\n let leftSum = 0;\n let rightSum = 0;\n for(let i = 0; i < rows; i++) {\n leftSum += arr[i][i]\n rightSum += arr[i][lastRowIndex];\n lastRowIndex--;\n }\n return Math.abs(leftSum - rightSum);\n}", "title": "" }, { "docid": "64de4478a41607dc298df4c2a87518e4", "score": "0.5598165", "text": "function longestIsland (matrix) {\n var longest = 0;\n\n var count = 0;\n var isIsland = false;\n\n function findNeighbors (n, m) {\n // check below\n if (matrix[n+1] && matrix[n+1][m] === 1) {\n count++;\n matrix[n+1][m] = 0;\n isIsland = true;\n } else {\n \n }\n }\n\n for (var i = 0; i < matrix.length; i++) {\n \n // iterates left\n for (var n = 0; n < matrix[i].length; n++) {\n if (matix[i][n] === 1) {\n matrix[i][n] = 0;\n isIsland = true;\n count++;\n } else {\n if (isIsland) {\n findLastNeighbor(i, n-1);\n }\n }\n }\n\n }\n\n\n}", "title": "" }, { "docid": "e8ea5e949cec31940834f6f82da333b5", "score": "0.5580849", "text": "checkDiagonals() {\n if (this.board[0][0] === this.board[1][1] && this.board[1][1] === this.board[2][2] && this.board[0][0]) {\n return this.board[0][0];\n } else if (this.board[0][2] === this.board[1][1] && this.board[1][1] === this.board[2][0] && this.board[0][2]) {\n return this.board[0][2];\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "e0a838fa255ae48007db402e3f3f8d07", "score": "0.55753595", "text": "function connectedCell(grid) {\n var len = grid.length;\n var rows = len;\n var cols = grid[0].length;\n //console.log(matrix[0][0]);\n var maxRegion = 0;\n\n for (var i = 0; i < rows; i++) {\n for (var j = 0; j < cols; j++) {\n if (grid[row][col] == 1) {\n var size = findLargestRegion(grid, i, j);\n maxRegion = Math.max(maxRegion, size);\n }\n }\n }\n return maxRegion;\n}", "title": "" }, { "docid": "9733c31ee80b6c2cb9db44bcb3bac39a", "score": "0.55746686", "text": "moveDiagonalRight(){\n let wantedX = this.x;\n let wantedY = this.y;\n switch(this.sight) {\n case \"RIGHT\":\n wantedX++;\n wantedY--;\n break;\n case \"UP\":\n wantedX++;\n wantedY++;\n break;\n case \"LEFT\":\n wantedX--;\n wantedY++;\n break;\n case \"DOWN\":\n wantedX--;\n wantedY--;\n break;\n }\n if(MAP[wantedY][wantedX] != '#'){\n this.y = wantedY;\n this.x = wantedX;\n //this.fitness +=10;\n }\n else{\n this.fitness -= 200;\n }\n }", "title": "" }, { "docid": "4e6f24f4883e2ca46ef4f8ab69b64711", "score": "0.5551618", "text": "function solution(A) {\n if (A.length < 2) return 0;\n\n const sumIntermediateCols = (arr, h, g, start, end) => {\n let sum = 0;\n for (let i = start + 1; i < end; i++) sum += arr[i];\n return h * g - sum;\n }\n const findNextCol = (arr, colIdx, colVal) => {\n let max = 0;\n for (let i = colIdx + 1; i < arr.length; i++) {\n if (arr[i] >= colVal) {\n return i; //return the next column at least as high as A[i]\n } else {\n max = Math.max(max, arr[i]); //track the highest remaining column\n }\n }\n //return index of max if found, otherwise colIdx as last resort\n return Math.max(arr.indexOf(max, colIdx), colIdx);\n }\n const calculator = (arr) => {\n let raindrops = 0;\n let gap = 0;\n let height = 0;\n let nextCol = 0;\n for (let i = 0; i < arr.length; i++) {\n if (arr[i] > 0) {\n nextCol = findNextCol(arr, i, arr[i]);\n if (nextCol !== i) {\n gap = nextCol - i - 1;\n height = Math.min(arr[i], arr[nextCol]);\n raindrops += sumIntermediateCols(arr, height, gap, i, nextCol);\n i = nextCol - 1;\n }\n }\n }\n return raindrops;\n }\n return calculator(A);\n}", "title": "" }, { "docid": "85f8276925f9d4e60fc341277e147329", "score": "0.5544916", "text": "function diagonal_edge(mat, wp) {\n\tlet dw1 = wp[0]*(df(mat[0][2], mat[1][1]) + df(mat[1][1], mat[2][0]) +\n df(mat[1][3], mat[2][2]) + df(mat[2][2], mat[3][1])) +\n\t\t\t\twp[1]*(df(mat[0][3], mat[1][2]) + df(mat[2][1], mat[3][0])) +\n\t\t\t\twp[2]*(df(mat[0][3], mat[2][1]) + df(mat[1][2], mat[3][0])) +\n\t\t\t\twp[3]*df(mat[1][2], mat[2][1]) +\n\t\t\t\twp[4]*(df(mat[0][2], mat[2][0]) + df(mat[1][3], mat[3][1])) +\n\t\t\t\twp[5]*(df(mat[0][1], mat[1][0]) + df(mat[2][3], mat[3][2]));\n\n\tlet dw2 = wp[0]*(df(mat[0][1], mat[1][2]) + df(mat[1][2], mat[2][3]) +\n df(mat[1][0], mat[2][1]) + df(mat[2][1], mat[3][2])) +\n\t\t\t\twp[1]*(df(mat[0][0], mat[1][1]) + df(mat[2][2], mat[3][3])) +\n\t\t\t\twp[2]*(df(mat[0][0], mat[2][2]) + df(mat[1][1], mat[3][3])) +\n\t\t\t\twp[3]*df(mat[1][1], mat[2][2]) +\n\t\t\t\twp[4]*(df(mat[1][0], mat[3][2]) + df(mat[0][1], mat[2][3])) +\n\t\t\t\twp[5]*(df(mat[0][2], mat[1][3]) + df(mat[2][0], mat[3][1]));\n\n\treturn (dw1 - dw2);\n}", "title": "" }, { "docid": "6501d940089d201e102e764f5bf5ad07", "score": "0.5542142", "text": "diagonal(result) { return this.low.vectorTo(this.high, result); }", "title": "" }, { "docid": "6501d940089d201e102e764f5bf5ad07", "score": "0.5542142", "text": "diagonal(result) { return this.low.vectorTo(this.high, result); }", "title": "" }, { "docid": "5c89ce49e77d172fccfbc7607e5c572b", "score": "0.5530473", "text": "function maximalSquare(matrix) {\n let rowLen = matrix.length;\n let colLen = rowLen > 0 ? matrix[0].length : 0;\n let dp = Array(colLen + 1).fill(0);\n let maxLen = 0;\n let prev = 0;\n let temp;\n for (let i = 1; i <= rowLen; i++) {\n for (let j = 1; j <= colLen; j++) {\n temp = dp[j];\n if (matrix[i - 1][j - 1] === \"1\") {\n dp[j] = Math.min(dp[j], dp[j - 1], prev) + 1;\n maxLen = Math.max(maxLen, dp[j]);\n }\n else {\n dp[j] = 0;\n }\n prev = temp;\n }\n }\n return maxLen * maxLen;\n}", "title": "" }, { "docid": "ef18e63f08c836d72349eb3844a36e83", "score": "0.5520575", "text": "function searchMatrix(matrix, target) {\n\t//if no length\n\tif (!matrix.length) return false;\n\n\tlet row = matrix.length,\n\t\tcol = matrix[0].length;\n\n\tif (matrix[0][0] > target || matrix[row - 1][col - 1] < target) return false;\n\n\tlet start = 0,\n\t\tend = row - 1;\n\n\twhile (start <= end) {\n\t\tlet mid = Math.floor((end + start) / 2);\n\t\tif (matrix[mid][col - 1] < target) start = mid + 1;\n\t\telse end = mid - 1;\n\t}\n\t//console.log(start, end);\n\n\tlet arr = matrix[start];\n\t//WHAT DOES THIS MEAN?\n\t(start = 0), (end = arr.length - 1);\n\twhile (start <= end) {\n\t\tlet mid = Math.floor((end + start) / 2);\n\t\t//console.log(start, end, mid);\n\t\tif (arr[mid] === target) return true;\n\t\telse if (arr[mid] < target) start = mid + 1;\n\t\telse end = mid - 1;\n\t}\n\t//console.log(start);\n\t// if(arr[start]===target) return true;\n\treturn false;\n}", "title": "" }, { "docid": "cdb3c702604d35f05f9f451f988f6177", "score": "0.5518797", "text": "function sortedMatrix2(matrix, target) {\n let left = 0;\n let right = matrix[matrix.length - 1][matrix[0].length - 1];\n\n while (left < right) {\n const mid = Math.floor((left + right) / 2);\n const idxR = Math.floor(mid / matrix[0].length);\n const idxC = mid % matrix.length;\n if (matrix[idxR][idxC] === target) {\n return [idxR, idxC];\n }\n\n if (matrix[idxR][idxC] < target) {\n right = mid - 1;\n } else {\n left = mid + 1;\n }\n }\n}", "title": "" }, { "docid": "8a0308c82b25101dd492d9a17425aa50", "score": "0.5515048", "text": "function searchMatrixV2(matrix, target) {\n let rows = matrix.length\n for (let i = 0; i < rows; i++) {\n if (target > matrix[i][matrix[i].length - 1]){\n continue\n }\n if(binarySearch(matrix[i], target, 0, matrix[i].length -1) === true){\n return true\n } else {\n continue\n }\n }\n return false;\n }", "title": "" }, { "docid": "ed5712446f2b57052256716c733acbae", "score": "0.5511044", "text": "function matrix_invert(matrix) {\n var M = matrix.m;\n // I use Guassian Elimination to calculate the inverse:\n // (1) 'augment' the matrix (left) by the identity (on the right)\n // (2) Turn the matrix on the left into the identity by elemetry row ops\n // (3) The matrix on the right is the inverse (was the identity matrix)\n // There are 3 elemtary row ops: (I combine b and c in my code)\n // (a) Swap 2 rows\n // (b) Multiply a row by a scalar\n // (c) Add 2 rows\n\n //if the matrix isn't square: exit (error)\n if (M.length !== M[0].length) {\n return;\n }\n\n //create the identity matrix (I), and a copy (C) of the original\n var i = 0,\n ii = 0,\n j = 0,\n dim = M.length,\n e = 0,\n t = 0;\n var I = [],\n C = [];\n for (i = 0; i < dim; i += 1) {\n // Create the row\n I[I.length] = [];\n C[C.length] = [];\n for (j = 0; j < dim; j += 1) {\n //if we're on the diagonal, put a 1 (for identity)\n if (i == j) {\n I[i][j] = 1;\n } else {\n I[i][j] = 0;\n }\n\n // Also, make the copy of the original\n C[i][j] = M[i][j];\n }\n }\n\n // Perform elementary row operations\n for (i = 0; i < dim; i += 1) {\n // get the element e on the diagonal\n e = C[i][i];\n\n // if we have a 0 on the diagonal (we'll need to swap with a lower row)\n if (e == 0) {\n //look through every row below the i'th row\n for (ii = i + 1; ii < dim; ii += 1) {\n //if the ii'th row has a non-0 in the i'th col\n if (C[ii][i] != 0) {\n //it would make the diagonal have a non-0 so swap it\n for (j = 0; j < dim; j++) {\n e = C[i][j]; //temp store i'th row\n C[i][j] = C[ii][j]; //replace i'th row by ii'th\n C[ii][j] = e; //repace ii'th by temp\n e = I[i][j]; //temp store i'th row\n I[i][j] = I[ii][j]; //replace i'th row by ii'th\n I[ii][j] = e; //repace ii'th by temp\n }\n //don't bother checking other rows since we've swapped\n break;\n }\n }\n //get the new diagonal\n e = C[i][i];\n //if it's still 0, not invertable (error)\n if (e == 0) {\n return;\n }\n }\n\n // Scale this row down by e (so we have a 1 on the diagonal)\n for (j = 0; j < dim; j++) {\n C[i][j] = C[i][j] / e; //apply to original matrix\n I[i][j] = I[i][j] / e; //apply to identity\n }\n\n // Subtract this row (scaled appropriately for each row) from ALL of\n // the other rows so that there will be 0's in this column in the\n // rows above and below this one\n for (ii = 0; ii < dim; ii++) {\n // Only apply to other rows (we want a 1 on the diagonal)\n if (ii == i) {\n continue;\n }\n\n // We want to change this element to 0\n e = C[ii][i];\n\n // Subtract (the row above(or below) scaled by e) from (the\n // current row) but start at the i'th column and assume all the\n // stuff left of diagonal is 0 (which it should be if we made this\n // algorithm correctly)\n for (j = 0; j < dim; j++) {\n C[ii][j] -= e * C[i][j]; //apply to original matrix\n I[ii][j] -= e * I[i][j]; //apply to identity\n }\n }\n }\n\n //we've done all operations, C should be the identity\n //matrix I should be the inverse:\n return I;\n}", "title": "" }, { "docid": "68fa429dcdee475d65c9b046f19e0b85", "score": "0.5506762", "text": "function diagonalDifference(arr) {\n let leftToRightSum = 0;\n let rightToleftSum = 0;\n let result = 0\n\n //row start from left, col start from right\n for (let row = 0, col = arr.length - 1; \n row < arr.length, col > -1; \n row++, col--)\n {\n leftToRightSum += arr[row][row]\n rightToleftSum += arr[row][col] \n\n }\n // find the different\n result = leftToRightSum - rightToleftSum\n\n //return absolute diff\n return Math.abs(result)\n \n}", "title": "" }, { "docid": "ddac71de185fd0c046b0f8fbcf847b17", "score": "0.5506166", "text": "function diagonalDifference(arr){\n let lr = arr.map((val,i)=>val[i]).reduce((accum,el)=>accum+el);\n let rl = arr.map((val,i)=>val[val.length-i-1]).reduce((accum,el)=>accum+el);\n return Math.abs(lr-rl);\n }", "title": "" }, { "docid": "6a30a74f1781f50f71145a2e1cc76912", "score": "0.5499785", "text": "function checkDiagonalTLtoBR() {\n return checkWin({ i: 1, j: 1 }, { i: -1, j: -1 });\n }", "title": "" }, { "docid": "a797058fa741e4f42a5a0bc7a8e479d4", "score": "0.5499387", "text": "function findExit(board, row, col) {\n if (!board.length) return [-1, -1];\n\n const numRows = board.length;\n const numCols = board[0].length;\n\n let visited = new Set();\n\n let q = [{ r: row, c: col, o: 0 }];\n\n while (q.length !== 0) {\n let curr = q.shift();\n let pos = `${curr.r}${curr.c}${curr.o}`;\n if (\n curr.r < 0 ||\n curr.c < 0 ||\n curr.r === numRows ||\n curr.c === numCols ||\n visited.has(pos)\n )\n continue;\n\n if (board[curr.r][curr.c] === \"+\") curr.o++;\n\n if (curr.r === numRows - 1 && curr.c === 0) return [curr.r, curr.c];\n\n if (curr.r === 0 && curr.c === numCols - 1) return [curr.r, curr.c];\n\n q.push({ r: curr.r - 1, c: curr.c, o: curr.o });\n q.push({ r: curr.r + 1, c: curr.c, o: curr.o });\n q.push({ r: curr.r, c: curr.c - 1, o: curr.o });\n q.push({ r: curr.r, c: curr.c + 1, o: curr.o });\n }\n return [-1, -1];\n}", "title": "" }, { "docid": "84d6a2f2d2dd4293f6729815e7d04901", "score": "0.5475342", "text": "function diagonalDifference(a) {\n // Complete this function\n let start = 0;\n let end = 0;\n for (let i = 0; i < a.length; i++) {\n start += a[i][i];\n end += a[i][a.length - (i + 1)];\n // console.log('startValue:%o|start:%o|endValue:%o|end%o|', a[i][i], start, a[i][a.length - (i + 1)], end);\n }\n return Math.abs(end - start);\n}", "title": "" }, { "docid": "02376db33a8f29c66a96919174926842", "score": "0.54733473", "text": "function diagonalDifference(arr) {\n\n let sumOne = 0\n \n let sumTwo = 0\n \n for (let i = 0; i < arr.length; i++) { \n for (let j = 0; j < arr[i].length; j++) {\n if(i === j) {\n sumOne = sumOne + arr[i][j]\n }\n }\n }\n \n for (let i = 0; i < arr.length; i++) { \n for (let j = 0; j < arr[i].length; j++) {\n if(i + j === arr.length - 1) {\n sumTwo = sumTwo + arr[i][j]\n }\n }\n }\n \n return Math.abs(sumOne - sumTwo)\n \n \n }", "title": "" }, { "docid": "c09c1f876f00f64586ed431a565c25ab", "score": "0.5460758", "text": "function nextIndex(row, column, matrixHeight) {\n if (row >= matrixHeight) {\n throw 'Row index must be less than matrix height - 1'\n }\n\n // If we are at the bottom\n if (row === matrixHeight - 1) {\n // Left item\n if (column === 0) {\n // Egde case for the 2x2 matrix scenario.\n // The first element of the last row\n // has to be moved diagonally rather than upwards since it's the element\n // beneath the pivot. \n if (matrixHeight === 2) {\n return {\n row: 0,\n column: 1\n }\n } else {\n // Move upwards\n return {\n row: row - 1,\n column: 0\n }\n } \n } else {\n // Right item\n // Move leftwards\n return {\n row: row,\n column: 0\n }\n }\n } else if (row === 0) {\n // If we are at the top\n if (column === 0) {\n throw 'Invalid index. Index 0-0 is reserved for the pivot'\n }\n // If we are at the item next to the pivot, move downwards\n return {\n row: 1,\n column: 1\n }\n } else if (row === 1 && column === 0) {\n // If we are at the item just below the pivot\n return {\n row: 0,\n column: 1\n }\n } else {\n // We are in the middle\n if (column == 0) {\n // Since we are rotating clockwise, all elements on the left side\n // should move upwards\n return {\n row: row - 1,\n column: column\n }\n } else {\n // Those on the right side move downwards\n return {\n row: row + 1,\n column: column\n }\n }\n }\n}", "title": "" }, { "docid": "842588fda1889c62929bd8b9d0f75750", "score": "0.54600364", "text": "function diagonalDifference(arr) {\n // Write your code here\n \n let i = 0\n let ii = 0\n let iii = 0\n let iiii = 0\n var arrnova1 = []\n var arrnova2 = []\n \n let resD1 = 0\n let resD2 = 0\n let resultado = 0\n\n\n for(i=0; i < arr.length ;i++){\n arrnova1.push(arr[i])\n\n for(ii=0;ii<arr.length;ii++){\n\n arrnova2.push(arr[i][ii]) \n \n } \n } \n \n for(iii = 0; iii< arrnova2.length; iii = iii + arrnova1.length+1){\n resD1 = resD1 + arrnova2[iii] \n\n }\n\n for(iiii = arrnova1.length-1; iiii<(arrnova2.length-(arrnova1.length-1)); iiii = iiii + (arrnova1.length-1)) {\n resD2 = resD2 + arrnova2[iiii]\n } \n \n if(resD1<0){\n\n resD1 = resD1*(-1)\n }\n if(resD2<0){\n resD2=resD2*(-1)\n } \n \n resultado = (resD1-resD2)\n if(resultado<0){\n resultado=resultado*(-1)\n } \n return resultado+1\n}", "title": "" }, { "docid": "0b67fe51b17bd81659e0f837bb6feca8", "score": "0.5454363", "text": "checkCurrMajorDiagonal() {\n var loc1 = (this.currVectors[0] & 1);\n var loc2 = (this.currVectors[1] & 2);\n var loc3 = (this.currVectors[2] & 4);\n return (loc1 | loc2 | loc3) === WIN_VECTOR;\n }", "title": "" }, { "docid": "4fae0b1c61e6c8f4e3a50003d8f977ea", "score": "0.5447815", "text": "function diagonalDifference(arr) {\n let lr = 0\n let rl = 0\n for (let i = 0; i < arr.length; i ++) {\n lr += arr[i][i]\n rl += arr[i][arr.length-i-1]\n }\n return Math.abs(lr-rl)\n}", "title": "" }, { "docid": "3502effa443604dd6182f5bf669db586", "score": "0.54318386", "text": "function diagonalDifference(arr) {\n let n = arr.length\n\n let j = n - 1;\n let resA = 0;\n let resB = 0;\n\n for(let i = 0; i < n; i++){\n resA += arr[i][i]\n resB += arr[i][j]\n j--;\n }\n \n return Math.abs(resA - resB)\n\n}", "title": "" }, { "docid": "2dde76307c44e75778a5751c30523ab1", "score": "0.5429952", "text": "matrix_invert(M) {\n\t\t//if the matrix isn't square: exit (error)\n\t\tif(M.length !== M[0].length){return;}\n\t\t\n\t\t//create the identity matrix (I), and a copy (C) of the original\n\t\tvar i=0, ii=0, j=0, dim=M.length, e=0, t=0;\n\t\tvar I = [], C = [];\n\t\tfor(i=0; i<dim; i+=1){\n\t\t\t// Create the row\n\t\t\tI[I.length]=[];\n\t\t\tC[C.length]=[];\n\t\t\tfor(j=0; j<dim; j+=1){\n\t\t\t\t\n\t\t\t\t//if we're on the diagonal, put a 1 (for identity)\n\t\t\t\tif(i===j){ I[i][j] = 1; }\n\t\t\t\telse{ I[i][j] = 0; }\n\t\t\t\t\n\t\t\t\t// Also, make the copy of the original\n\t\t\t\tC[i][j] = M[i][j];\n\t\t\t}\n\t\t}\n\t\t\n\t\t// Perform elementary row operations\n\t\tfor(i=0; i<dim; i+=1){\n\t\t\t// get the element e on the diagonal\n\t\t\te = C[i][i];\n\t\t\t\n\t\t\t// if we have a 0 on the diagonal (we'll need to swap with a lower row)\n\t\t\tif(e===0){\n\t\t\t\t//look through every row below the i'th row\n\t\t\t\tfor(ii=i+1; ii<dim; ii+=1){\n\t\t\t\t\t//if the ii'th row has a non-0 in the i'th col\n\t\t\t\t\tif(C[ii][i] !== 0){\n\t\t\t\t\t\t//it would make the diagonal have a non-0 so swap it\n\t\t\t\t\t\tfor(j=0; j<dim; j++){\n\t\t\t\t\t\t\te = C[i][j]; //temp store i'th row\n\t\t\t\t\t\t\tC[i][j] = C[ii][j];//replace i'th row by ii'th\n\t\t\t\t\t\t\tC[ii][j] = e; //repace ii'th by temp\n\t\t\t\t\t\t\te = I[i][j]; //temp store i'th row\n\t\t\t\t\t\t\tI[i][j] = I[ii][j];//replace i'th row by ii'th\n\t\t\t\t\t\t\tI[ii][j] = e; //repace ii'th by temp\n\t\t\t\t\t\t}\n\t\t\t\t\t\t//don't bother checking other rows since we've swapped\n\t\t\t\t\t\tbreak;\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//get the new diagonal\n\t\t\t\te = C[i][i];\n\t\t\t\t//if it's still 0, not invertable (error)\n\t\t\t\tif(e===0){return}\n\t\t\t}\n\t\t\t\n\t\t\t// Scale this row down by e (so we have a 1 on the diagonal)\n\t\t\tfor(j=0; j<dim; j++){\n\t\t\t\tC[i][j] = C[i][j]/e; //apply to original matrix\n\t\t\t\tI[i][j] = I[i][j]/e; //apply to identity\n\t\t\t}\n\t\t\t\n\t\t\t// Subtract this row (scaled appropriately for each row) from ALL of\n\t\t\t// the other rows so that there will be 0's in this column in the\n\t\t\t// rows above and below this one\n\t\t\tfor(ii=0; ii<dim; ii++){\n\t\t\t\t// Only apply to other rows (we want a 1 on the diagonal)\n\t\t\t\tif(ii===i){continue;}\n\t\t\t\t\n\t\t\t\t// We want to change this element to 0\n\t\t\t\te = C[ii][i];\n\t\t\t\t\n\t\t\t\t// Subtract (the row above(or below) scaled by e) from (the\n\t\t\t\t// current row) but start at the i'th column and assume all the\n\t\t\t\t// stuff left of diagonal is 0 (which it should be if we made this\n\t\t\t\t// algorithm correctly)\n\t\t\t\tfor(j=0; j<dim; j++){\n\t\t\t\t\tC[ii][j] -= e*C[i][j]; //apply to original matrix\n\t\t\t\t\tI[ii][j] -= e*I[i][j]; //apply to identity\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\t\n\t\t//we've done all operations, C should be the identity\n\t\t//matrix I should be the inverse:\n\t\treturn I;\n\t}", "title": "" }, { "docid": "807eabec9db5a011b246ae1369f3499a", "score": "0.5422789", "text": "function checkDiag() {\n\tvar same = true;\n\tfor (i = 0; i < board.length; i++) {\n\t\tif (board[i][i] === 0 || board[i][i] !== board[0][0]) {\n\t\t\tsame = false;\n\t\t}\n\t}\n\tif (same) {\n\t\treturn same;\n\t}\n\tsame = true;\n\tfor (i = 0; i < board.length; i++) {\n\t\tif (board[i][2 - i] === 0 || board[i][2 - i] !== board[0][2]) {\n\t\t\tsame = false;\n\t\t}\n\t}\n\tif (same) {\n\t\treturn same;\n\t}\n}", "title": "" }, { "docid": "0ac289effb1d4ae63efe898f901533bf", "score": "0.54174525", "text": "function LargestRowColumn(strArr) { \n const maxRow = strArr.length -1;\n const maxCol = strArr[0].length - 1;\n const dirs = [[1,0],[-1,0], [0, 1], [0, -1]];\n let largest = -Infinity;\n\n for (let i = 0; i < strArr.length; i++){\n for (let j = 0; j < strArr[0].length; j++){\n const pos = [i, j]\n const num = parseInt(strArr[i][j]);\n\n dfs(pos, num);\n }\n }\n\n return largest;\n \n function dfs(currPos, sum, prevPos, count=2){\n // console.log(currPos, sum, prevPos, count)\n if (count === 0){\n if (inBound(sum)){\n largest = largest < sum ? sum : largest;\n }\n return;\n }\n\n dirs.forEach((dir) => {\n const [dx, dy] = dir;\n const [nx, ny] = [currPos[0] + dx, currPos[1] + dy];\n if (nx > maxRow || ny > maxCol || nx < 0 || ny < 0) return;\n if (prevPos !== undefined && (prevPos[0] === nx && prevPos[1] === ny) ) return;\n const num = parseInt(strArr[nx][ny])\n return dfs([nx, ny], sum + num, currPos, count - 1);\n })\n }\n\n function inBound(num){\n let row, col;\n \n if (num > 9){\n col = num % 10;\n row = (num - col) / 10\n } else {\n row = 0;\n col = num;\n }\n // console.log(maxRow, row, maxCol, col)\n return maxRow >= row && maxCol >= col\n }\n\n}", "title": "" }, { "docid": "2a8e9a292771c70f2db2f433597514a9", "score": "0.54008776", "text": "function tryDownFistStep(a) {\r\n var first_position = 0;\r\n var second_position = 0; \r\n for (col = 1; col <= MAX_WIDTH_TABLE; col++) { \r\n first_position =second_position =0;\r\n for (line = 1; line <= MAX_WIDTH_TABLE; line++) {\r\n if(a[col][line] > 0) {\r\n if(first_position == 0) {\r\n first_position = line;\r\n } else {\r\n second_position = line; \r\n if (a[col][first_position] == a[col][second_position]) {\r\n a[col][second_position] = a[col][first_position] + a[col][second_position];\r\n a[col][first_position] = 0;\r\n first_position = second_position = 0;\r\n } else { \r\n first_position = second_position;\r\n second_position = 0;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n return a;\r\n}", "title": "" }, { "docid": "98e77938a0a6fb520ba96f6c1ead08c0", "score": "0.5395807", "text": "get maxRow() {\n if (this.row === undefined || this.height === undefined) return 0\n return this.row + this.height - 1\n }", "title": "" }, { "docid": "1b6a84f3864c85dac3456d3234992d55", "score": "0.5389556", "text": "function getLongestIncreasingPathLengthOfCell(row, column, previousNumber) {\n // out of bound\n if (row < 0 || column < 0 || row >= rowsCount || column >= columnsCount) return 0;\n // increasing path\n if (matrix[row][column] <= previousNumber) return 0;\n // Use memo\n if (memo[row][column] > -1) return memo[row][column];\n\n const up = getLongestIncreasingPathLengthOfCell(row + 1, column, matrix[row][column]);\n const down = getLongestIncreasingPathLengthOfCell(row - 1, column, matrix[row][column]);\n const left = getLongestIncreasingPathLengthOfCell(row, column - 1, matrix[row][column]);\n const right = getLongestIncreasingPathLengthOfCell(row, column + 1, matrix[row][column]);\n\n memo[row][column] = Math.max(up, down, left, right) + 1;\n return memo[row][column];\n }", "title": "" }, { "docid": "2856f9c3493c45f2b740a1155673068c", "score": "0.53785485", "text": "function matrix_invert(M){\n // I use Guassian Elimination to calculate the inverse:\n // (1) 'augment' the matrix (left) by the identity (on the right)\n // (2) Turn the matrix on the left into the identity by elemetry row ops\n // (3) The matrix on the right is the inverse (was the identity matrix)\n // There are 3 elemtary row ops: (I combine b and c in my code)\n // (a) Swap 2 rows\n // (b) Multiply a row by a scalar\n // (c) Add 2 rows\n \n //if the matrix isn't square: exit (error)\n if(M.length !== M[0].length){return;}\n \n //create the identity matrix (I), and a copy (C) of the original\n var i=0, ii=0, j=0, dim=M.length, e=0, t=0;\n var I = [], C = [];\n for(i=0; i<dim; i+=1){\n // Create the row\n I[I.length]=[];\n C[C.length]=[];\n for(j=0; j<dim; j+=1){\n \n //if we're on the diagonal, put a 1 (for identity)\n if(i==j){ I[i][j] = 1; }\n else{ I[i][j] = 0; }\n \n // Also, make the copy of the original\n C[i][j] = M[i][j];\n }\n }\n \n // Perform elementary row operations\n for(i=0; i<dim; i+=1){\n // get the element e on the diagonal\n e = C[i][i];\n \n // if we have a 0 on the diagonal (we'll need to swap with a lower row)\n if(e==0){\n //look through every row below the i'th row\n for(ii=i+1; ii<dim; ii+=1){\n //if the ii'th row has a non-0 in the i'th col\n if(C[ii][i] != 0){\n //it would make the diagonal have a non-0 so swap it\n for(j=0; j<dim; j++){\n e = C[i][j]; //temp store i'th row\n C[i][j] = C[ii][j];//replace i'th row by ii'th\n C[ii][j] = e; //repace ii'th by temp\n e = I[i][j]; //temp store i'th row\n I[i][j] = I[ii][j];//replace i'th row by ii'th\n I[ii][j] = e; //repace ii'th by temp\n }\n //don't bother checking other rows since we've swapped\n break;\n }\n }\n //get the new diagonal\n e = C[i][i];\n //if it's still 0, not invertable (error)\n if(e==0){return}\n }\n \n // Scale this row down by e (so we have a 1 on the diagonal)\n for(j=0; j<dim; j++){\n C[i][j] = C[i][j]/e; //apply to original matrix\n I[i][j] = I[i][j]/e; //apply to identity\n }\n \n // Subtract this row (scaled appropriately for each row) from ALL of\n // the other rows so that there will be 0's in this column in the\n // rows above and below this one\n for(ii=0; ii<dim; ii++){\n // Only apply to other rows (we want a 1 on the diagonal)\n if(ii==i){continue;}\n \n // We want to change this element to 0\n e = C[ii][i];\n \n // Subtract (the row above(or below) scaled by e) from (the\n // current row) but start at the i'th column and assume all the\n // stuff left of diagonal is 0 (which it should be if we made this\n // algorithm correctly)\n for(j=0; j<dim; j++){\n C[ii][j] -= e*C[i][j]; //apply to original matrix\n I[ii][j] -= e*I[i][j]; //apply to identity\n }\n }\n }\n \n //we've done all operations, C should be the identity\n //matrix I should be the inverse:\n return I;\n}", "title": "" }, { "docid": "01dfccfeb864bb611832da393f2f7121", "score": "0.53777623", "text": "function diagonalDifference(arr) {\n var sum1=0;\n var sum2=0;\n var final = 0;\n for (var i=0; i<arr.length; i++) {\n sum1+=arr[i][arr.length-i-1];\n }\n for (i=0; i<arr.length; i++) {\n sum2+=arr[i][i];\n console.log('sum2 is', sum2);\n }\n final = sum1 - sum2;\n return Math.abs(final);\n}", "title": "" }, { "docid": "06bf82bd4161ff6f083d9f054c0aed9c", "score": "0.53768265", "text": "function diagonalWin() {\n var x = null,\n y = null,\n xtemp = null,\n ytemp = null,\n currentValue = null,\n previousValue = 0,\n tally = 0;\n\n // Test for down-right diagonals across the top.\n for (x = 0; x <= 6; x++) {\n xtemp = x;\n ytemp = 0;\n\n while (xtemp <= 6 && ytemp <= 5) {\n currentValue = board[ytemp][xtemp];\n if (currentValue === previousValue && currentValue !== 0) {\n tally += 1;\n } else {\n // Reset the tally if you find a gap.\n tally = 0;\n }\n if (tally === config.countToWin - 1) {\n return true;\n }\n previousValue = currentValue;\n\n // Shift down-right one diagonal index.\n xtemp++;\n ytemp++;\n }\n // Reset the tally and previous value when changing diagonals.\n tally = 0;\n previousValue = 0;\n }\n\n // Test for down-left diagonals across the top.\n for (x = 0; x <= 6; x++) {\n xtemp = x;\n ytemp = 0;\n\n while (0 <= xtemp && ytemp <= 5) {\n currentValue = board[ytemp][xtemp];\n if (currentValue === previousValue && currentValue !== 0) {\n tally += 1;\n } else {\n // Reset the tally if you find a gap.\n tally = 0;\n }\n if (tally === config.countToWin - 1) {\n return true;\n }\n previousValue = currentValue;\n\n // Shift down-left one diagonal index.\n xtemp--;\n ytemp++;\n }\n // Reset the tally and previous value when changing diagonals.\n tally = 0;\n previousValue = 0;\n }\n\n // Test for down-right diagonals down the left side.\n for (y = 0; y <= 5; y++) {\n xtemp = 0;\n ytemp = y;\n\n while (xtemp <= 6 && ytemp <= 5) {\n currentValue = board[ytemp][xtemp];\n if (currentValue === previousValue && currentValue !== 0) {\n tally += 1;\n } else {\n // Reset the tally if you find a gap.\n tally = 0;\n }\n if (tally === config.countToWin - 1) {\n return true;\n }\n previousValue = currentValue;\n\n // Shift down-right one diagonal index.\n xtemp++;\n ytemp++;\n }\n // Reset the tally and previous value when changing diagonals.\n tally = 0;\n previousValue = 0;\n }\n\n // Test for down-left diagonals down the right side.\n for (y = 0; y <= 5; y++) {\n xtemp = 6;\n ytemp = y;\n\n while (0 <= xtemp && ytemp <= 5) {\n currentValue = board[ytemp][xtemp];\n if (currentValue === previousValue && currentValue !== 0) {\n tally += 1;\n } else {\n // Reset the tally if you find a gap.\n tally = 0;\n }\n if (tally === config.countToWin - 1) {\n return true;\n }\n previousValue = currentValue;\n\n // Shift down-left one diagonal index.\n xtemp--;\n ytemp++;\n }\n // Reset the tally and previous value when changing diagonals.\n tally = 0;\n previousValue = 0;\n }\n\n // No diagonal wins found. Return false.\n return false;\n}", "title": "" }, { "docid": "c818cc9fee197a6f0c4c5ecb0f9f375f", "score": "0.53752637", "text": "function diagonalWinner() {\n //This will check if there is a diagonal match\n //We need to check the index of each box by using the the .eq method\n var leftDownDiag = checkRow($boxes.eq(0), $boxes.eq(4), $boxes.eq(8));\n var rightUpDiag = checkRow($boxes.eq(2), $boxes.eq(4), $boxes.eq(6));\n\n //Using the || operator let us compare if there is a match in either ways there is a winner\n\n return leftDownDiag || rightUpDiag;\n}", "title": "" }, { "docid": "2967c0218fad3b79db8ba239df49bac9", "score": "0.5375084", "text": "function lightRow(row){\n return GRID[row-1];\n}", "title": "" }, { "docid": "5bd27a129c0a59b525a136a543f2157e", "score": "0.53737426", "text": "function diagonalDifference(arr) {\n let sum1 = 0;\n let sum2 = 0;\n for (let i = 0, j = arr.length - 1; i < arr.length; i++, j--) {\n sum1 += arr[i][i];\n sum2 += arr[i][j];\n }\n return Math.abs(sum1 - sum2);\n}", "title": "" }, { "docid": "ebb8f6a5b3d7ddb02cecc4f691b3f1bf", "score": "0.53722584", "text": "function nextDiagRight(currentPos, up)\n { \n if (up)\n {\n currentPos.row--; \n currentPos.col--; \n }\n else \n {\n currentPos.row++;\n currentPos.col++;\n }\n if ((currentPos.col < minCol) || (currentPos.col > maxCol) ||\n (currentPos.row < minRow) || (currentPos.row > maxRow))\n {\n return null;\n }\n return currentPos; \n }", "title": "" }, { "docid": "09cd28c849871c4cd365a7de3694dced", "score": "0.5372251", "text": "_getRightDiagonal() {\n return this._matrix.reduce((acc, current, index) => {\n return acc.concat(current[this._topRight - index]);\n }, []);\n }", "title": "" }, { "docid": "f96b9e60cc305636ba4a312b9335819d", "score": "0.5361073", "text": "function diagonalDifference(arr) {\n //variables: Result, leftDiag, rightDiag\n let ld = 0;\n let rd = 0;\n\n // //Hard Coded\n let leftDiag = arr[0][0] + arr[1][1] + arr[2][2];\n let rightDiag = arr[0][2] + arr[1][1] + arr[2][0];\n\n let dd = Math.abs(leftDiag - rightDiag);\n console.log(\"dd:\", dd);\n\n\n //double loop \n for (let i = 0; i < arr.length; i++) {\n\n for (let j = 0; j < arr[i].length; j++) {\n\n //First Row\n if (i === 0) {\n if (j === 0) {\n ld = ld + arr[i][j];\n }\n else if (j === 2) {\n rd = rd + arr[i][j];\n }\n }\n //Second Row\n if (i === 1) {\n if (j === 1) {\n ld = ld + arr[i][j];\n rd = rd + arr[i][j];\n }\n }\n //Third Row\n if (i === 2) {\n if (j === 0) {\n rd = rd + arr[i][j];\n }\n else if (j === 2) {\n ld = ld + arr[i][j];\n }\n }\n }\n }\n\n return Math.abs(ld - rd);\n}", "title": "" }, { "docid": "b999204dc2612ed398288d432547d244", "score": "0.5345497", "text": "_calcRow(row) {\n // If a row value is negative (off the top of the world), return the last\n // row.\n if (row < 0) {\n return this.rows - 1\n }\n // If a row value is greater than the last row, return 0 (the value of the\n // first row).\n if (row > this.rows - 1) {\n return 0\n }\n // Otherwise the row value is within the bounds of the world and just fine.\n return row\n }", "title": "" }, { "docid": "91baf35a60e26155a67fb65eed3a56a2", "score": "0.53416866", "text": "moveDiagonalLeft(){\n let wantedX = this.x;\n let wantedY = this.y;\n switch(this.sight) {\n case \"RIGHT\":\n wantedX++;\n wantedY++;\n break;\n case \"UP\":\n wantedX--;\n wantedY++;\n break;\n case \"LEFT\":\n wantedX--;\n wantedY--;\n break;\n case \"DOWN\":\n wantedX++;\n wantedY--;\n break;\n }\n if(MAP[wantedY][wantedX] != '#'){\n this.y = wantedY;\n this.x = wantedX;\n //this.fitness +=10;\n }\n else{\n this.fitness -= 200;\n }\n }", "title": "" }, { "docid": "01c22f40e053ec086625563c76fd6e93", "score": "0.53360564", "text": "function diagonalDifference(arr) {\n // Write your code here\n if (0 === arr.length || arr.length !== arr[0].length) {\n return 0;\n }\n const len1 = arr.length;\n const len2 = arr[0].length;\n let v1 =0, v2 = 0;\n for (let i = 0; i < len1; i++) {\n v1 += arr[i][i];\n v2 += arr[i][len2 - 1 - i];\n }\n return Math.abs(v1 - v2);\n}", "title": "" }, { "docid": "9952882e21be71b6ff2ce362980e98db", "score": "0.533421", "text": "function getWinner (board) {\n const regex = new RegExp('^(.)\\\\1{' + (boardSize - 1) + '}$')\n\n // Check rows\n for (let i = 0; i < boardSize; i++) {\n if (board[i].join('').match(regex)) return board[i][0]\n }\n\n // Check columns\n for (let i = 0; i < boardSize; i++) {\n let column = []\n\n for (let j = 0; j < boardSize; j++) {\n column.push(board[j][i])\n }\n\n if (column.join('').match(regex)) return column[0]\n }\n\n // Check diagonal and anti-diagonal\n let diagonal = []\n let antiDiagonal = []\n\n for (let i = 0; i < boardSize; i++) {\n for (let j = 0; j < boardSize; j++) {\n if (i === j) diagonal.push(board[i][j])\n if (i === boardSize - j - 1) antiDiagonal.push(board[i][j])\n }\n }\n\n if (regex.test(diagonal.join(''))) return diagonal[0]\n else if (regex.test(antiDiagonal.join(''))) return antiDiagonal[0]\n\n return -1\n}", "title": "" }, { "docid": "8146edeb4d98185e479b2c5e1d5cb511", "score": "0.532418", "text": "function diag_top_win(){\r\n for (i=0; i<rows; i++){\r\n for(j=0;j<col;j++){\r\n\r\n pos_row = i\r\n pos_col = j\r\n result = array[i][j]\r\n rep = 1\r\n stp = 0\r\n while (stp == 0){\r\n if (pos_row-1>=0 && pos_col+1>=0 && pos_row-1< rows && pos_col+1< col){\r\n if(array[pos_row][pos_col] == array[pos_row-1][pos_col+1]){\r\n result += array[pos_row-1][pos_col+1]\r\n rep += 1\r\n if (result == 4 && rep == 4){\r\n $(\"#infotext1\").text(p1 + \" WON!\")\r\n start = 0\r\n }else if (result == 8 && rep == 4){\r\n $(\"#infotext1\").text(p2 + \" WON!\")\r\n start = 0\r\n }\r\n }else{\r\n result = array[j][i]\r\n rep = 1\r\n }\r\n }else{\r\n stp = 1\r\n }\r\n pos_row = pos_row - 1\r\n pos_col = pos_col + 1\r\n }\r\n\r\n }\r\n }\r\n}", "title": "" }, { "docid": "0a631244cc8ed54ec78381dddf3e2606", "score": "0.5319182", "text": "function findPivotInCol(startRow, col) {\r\n for(let i = startRow; i < m; i++)\r\n if(A[i][col] != 0)\r\n return i\r\n return -1\r\n }", "title": "" }, { "docid": "88a86d9ea39a1ab003e0fbf339ba2e5a", "score": "0.5293633", "text": "function getDiagonals() {\r\n const diagonalsArray = Array.from({length: 2}, () => []);\r\n const rowsArray = getRows();\r\n rowsArray.forEach((row, index) => {\r\n // index gets bigger\r\n diagonalsArray[0].push(row[index]);\r\n // index gets smaller \r\n diagonalsArray[1].push(row[DIMENSION - 1 - index]);\r\n });\r\n return diagonalsArray;\r\n }", "title": "" }, { "docid": "13589747ab11f8db63d0aa3f62b93181", "score": "0.5293116", "text": "function tryRightFistStep(a) {\r\n var first_position = 0;\r\n var second_position = 0; \r\n\r\n for (line = 1; line<=MAX_WIDTH_TABLE; line++) {\r\n first_position =second_position =0; \r\n for (col = 1; col<=MAX_WIDTH_TABLE; col++) { \r\n if(a[col][line] > 0) {\r\n if(first_position == 0)\r\n first_position = col;\r\n else \r\n second_position = col; \r\n }\r\n if ( first_position > 0 && second_position > 0) { \r\n if (a[first_position][line] == a[second_position][line]) {\r\n a[second_position][line] = a[first_position][line] + a[second_position][line];\r\n a[first_position][line] = 0;\r\n first_position = second_position = 0;\r\n } else { \r\n first_position = second_position;\r\n second_position = 0;\r\n }\r\n } \r\n } \r\n } \r\n return a;\r\n}", "title": "" }, { "docid": "683ddf9db318a30ce8b38bff16d94ba4", "score": "0.5286972", "text": "function lightRow(row) {\n return GRID[row - 1];\n}", "title": "" }, { "docid": "1cd7c73eb549f3f09d02ec2602ec2c5f", "score": "0.5272561", "text": "atEdge() {\n // go through every element in the piece (4x4)\n for (let j=0; j<this.matrix.length; j++) {\n for (let i=0; i<this.matrix[j].length; i++) {\n let value = this.matrix[j][i];\n let x = i+this.pos.x;\n if (value == 1) {\n if (x-1 < 0) {\n return -1;\n }\n else if (x+1 >= gridWidth) {\n return 1;\n }\n }\n }\n }\n return 0;\n }", "title": "" }, { "docid": "85bf758934a3a463c897e50b13ca9b9e", "score": "0.5262645", "text": "function largestPath(){\nvar arrayofTriangle = {\n\t0: [75], \n\t1: [95, 64],\n\t2:\t[17, 47, 82],\n\t3:\t[18, 35, 87, 10],\n\t4:\t[20, 04, 82, 47, 65],\n\t5:\t[19, 01, 23, 75, 03, 34],\n\t6:\t[88, 02, 77, 73, 07, 63, 67],\n\t7:\t[99, 65, 04, 28, 06, 16, 70, 92],\n\t8:\t[41, 41, 26, 56, 83, 40, 80, 70, 33],\n\t9:\t[41, 48, 72, 33, 47, 32, 37, 16, 94, 29],\n\t10:\t[53, 71, 44, 65, 25, 43, 91, 52, 97, 51, 14],\n\t11:\t[70, 11, 33, 28, 77, 73, 17, 78, 39, 68, 17, 57],\n\t12:\t[91, 71, 52, 38, 17, 14, 91, 43, 58, 50, 27, 29, 48],\n\t13:\t[63, 66, 04, 68, 89, 53, 67, 30, 73, 16, 69, 87, 40, 31],\n\t14:\t[04, 62, 98, 27, 23, 09, 70, 98, 73, 93, 38, 53, 60, 04, 23]\n\t}\n\n\t//the initial input, formatted\n\n\tfor (var i = 0; i < 14; i++){\n\t\twhile(arrayofTriangle[i].length < 15){\n\t\t\tarrayofTriangle[i].push(0);\n\t\t}\n\t}\n\t// making this an even matrix so we can find the answer in a bottom-up manner\n\n\tfor(i = 13; i >= 0; i--){\n\t\tfor(var j = 0; j < 14; j++){\n\t\t\tarrayofTriangle[i][j] += Math.max(arrayofTriangle[i+1][j], arrayofTriangle[i+1][j+1])\n\t\t}\n\t}\n\treturn Math.max(...arrayofTriangle[0])\n}", "title": "" }, { "docid": "6fd89f0a2f84ee205610f2ba3b4dc7c5", "score": "0.5257928", "text": "function biggestProductRowOrColumn(row) {\n \n let greatestProduct = 1;\n\n for (let i = 0; i < row.length; i++) {\n \n if (i + 4 > row.length) \n break;\n\n product = row[i] * row[i + 1] * row[i + 2] * row[i + 3];\n\n if (product > greatestProduct) {\n greatestProduct = product;\n }\n }\n return greatestProduct;\n}", "title": "" }, { "docid": "64e4239816f1621d58e034b851b45dee", "score": "0.52511185", "text": "function getClosestIndexRow(currIndex, direction){\n\t\tvar is_right;\n\t\tvar is_left;\n\t\tvar count;\n\t\t\n\t\tvar minIndex = (getRow(currIndex) - 1) * BOARD_SIZE;\n\t\tvar maxIndex = (getRow(currIndex) * BOARD_SIZE - 1);\n\t\t\n\t\tif(direction == CLOSEST) {\n\t\t\tis_right = true;\n\t\t\tis_left = true;\n\t\t\tcount = BOARD_SIZE/2 + 1;\n\t\t} else if (direction == RIGHT) {\n\t\t\tis_right = true;\n\t\t\tis_left = false;\n\t\t\tcount \t = BOARD_SIZE;\n\t\t} else if ( direction == LEFT) {\n\t\t\tis_right = false;\n\t\t\tis_left = true;\n\t\t\tcount \t = BOARD_SIZE;\n\t\t} else {\n\t\t return -1;\n\t\t}\n\t\t\t\n\t\tfor(var i=1 ; i <= count; i++) {\n\t\t\tif(is_left && ((currIndex - i) >= minIndex)) { \n\t\t\t\tif(!($('#slot-'+(currIndex - i)).hasClass('inactive'))) \n\t\t\t\t\treturn (currIndex - i);\n\t\t\t}\n\t\t\tif(is_right && ((currIndex + i) <= maxIndex)) {\n\t\t\t\tif(!($('#slot-'+(currIndex + i)).hasClass('inactive'))) \n\t\t\t\t\treturn (currIndex + i);\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "title": "" }, { "docid": "7ef377f120c18dea4a24c5f0986a24b4", "score": "0.52476996", "text": "function biggestProductColumns(matrix){\n let columnConvertedArr = convertColumnsToRows(matrix);\n let biggestProductColumn = biggestProductRows(columnConvertedArr);\n return biggestProductColumn;\n}", "title": "" }, { "docid": "dd05658a418f4ecfb2d0155816526e3b", "score": "0.5240821", "text": "function sol(matrix, target) {\n // o(m + n ) time\n\n if (!matrix || !matrix.length) return false;\n const m = matrix.length;\n const n = matrix[0].length;\n let curRow = 0;\n let curCol = n - 1;\n\n while (curRow < m && curCol >= 0) {\n if (matrix[curRow][curCol] === target) return true;\n if (matrix[curRow][curCol] > target) {\n curCol--;\n } else if (matrix[curRow][curCol] < target) {\n curRow++;\n }\n }\n\n return false;\n}", "title": "" }, { "docid": "9c4c9b8207b46637e9c087e86fe8c9ac", "score": "0.52367926", "text": "function biggestProduct(matrix){\n if(matrix.length === 0 ) return 0;\n\n if(Array.isArray(matrix)){\n\n let biggestProduct = biggestProductRows(matrix);\n let biggestProductColumn = biggestProductColumns(matrix);\n\n return biggestProductColumn > biggestProduct ? biggestProductColumn : biggestProduct;\n }\n}", "title": "" }, { "docid": "9f72430a3524bc2ddeb843d30460f11b", "score": "0.5225338", "text": "rotateMatrixToTheRight(matrix) {\n // reverse the rows\n matrix = matrix.reverse();\n // swap the symmetric elements\n for (let i = 0; i < matrix.length; i += 1) {\n for (let j = 0; j < i; j += 1) {\n const temp = matrix[i][j];\n matrix[i][j] = matrix[j][i];\n matrix[j][i] = temp;\n }\n }\n return matrix;\n }", "title": "" }, { "docid": "a981e421f9b814cb70b54354bbd5b5fb", "score": "0.5218245", "text": "function diagonalDifference(arr) {\n // the length of all arrays and the length of 1 array\n // has to be the same in order for this to work.\n let numOfArr = arr.length; // 3\n let arrLength = arr[0].length; // 3\n\n if (numOfArr === arrLength) {\n let fullArray = [];\n let iterator = 0;\n let reverseIterator = 0;\n for (var i = 0; i < numOfArr; i++) {\n for (var j = 0; j < arrLength; j++) {\n // push all arrays into one array\n fullArray.push(arr[i][j]);\n }\n }\n\n // iterator is always 1 number greater than arrLength\n iterator = arrLength + 1;\n // reverse iterator isalwyas 1 number less than arrLength\n reverseIterator = arrLength - 1;\n\n let tempLeft = [];\n let tempRight = [];\n let left = 0;\n let right = 0;\n\n // iterate from left to right and create an array of only\n // the diagonal numbers\n for (var x = 0; x < fullArray.length; x = x + iterator) {\n let tempArr = [];\n tempLeft.push(fullArray[x]);\n }\n\n // iterate from right to left and create an array of only\n // the diagonal numbers in reverse order, but use a different\n // starting point.\n for (var y = fullArray.length - arrLength; 0 < y; y = y - reverseIterator) {\n tempRight.push(fullArray[y]);\n }\n\n // add all diagonal numbers in an array for both left and right diagonal\n left = tempLeft.reduce((a, b) => a + b);\n right = tempRight.reduce((a, b) => a + b);\n\n // make it always subtract the small number from the big\n // number.\n if (left < right) {\n return right - left;\n } else {\n return left - right;\n }\n }\n}", "title": "" }, { "docid": "15f67bce2f49bf03f3ec8ee283e3734c", "score": "0.5211885", "text": "function diagonalDifference(arr) {\n let sumDiag1 = 0;\n let sumDiag2 = 0;\n let arrLength = arr.length - 1;\n for (let i = 0; i < arr.length; i++) {\n sumDiag1 = sumDiag1 + arr[i][i];\n sumDiag2 = sumDiag2 + arr[i][arrLength];\n arrLength--;\n }\n //console.log(Math.abs(sumDiag1 - sumDiag2));\n return Math.abs(sumDiag1-sumDiag2);\n}", "title": "" }, { "docid": "e5af5cd37055ea0858353852e740fa7b", "score": "0.5208081", "text": "findSpotForCol(x) {\n for (let y = this.height - 1; y >= 0; y--) {\n if(!this.board[y][x]){return y;} \n }\n return null;\n }", "title": "" }, { "docid": "9b9732eab73500e779398f08bb5af81e", "score": "0.5205645", "text": "movePossible(row_col) {\n\n\n for (let i = 0; i < this.dimension; i++) {\n let j = i+1; \n if (row_col[i] == row_col[j]) { // maybe add condition row_col[i] = 0\n return true;\n } \n\n if (row_col[i] != row_col[j] && j == this.dimension - 1) {\n return false;\n }\n }\n\n return false;\n }", "title": "" }, { "docid": "0e8e7c12d1d8922277cbab18b98fba77", "score": "0.5201278", "text": "function solution_0 (binaryMatrix) {\r\n const [h, w] = binaryMatrix.dimensions();\r\n for (let col = 0; col < w; col++) { // starting at top left, for each column...\r\n for (let row = 0; row < h; row++) { // ...go down the column searching for a 1\r\n if (binaryMatrix.get(row, col)) return col; // if a 1 is found, that column must be the answer\r\n }\r\n }\r\n return -1; // if the entire matrix is exhausted, return -1\r\n}", "title": "" }, { "docid": "15c576c3b7d55730a3b709b9ff69acc8", "score": "0.52005327", "text": "function get_neighbor_value_in_matrix (matrix, coordinates, direction) {\n var output;\n var altered_coordinates;\n var a = coordinates[0];\n var b = coordinates[1];\n \n if (direction === 'left') {\n altered_coordinates = [a, b - 1]; \n } else if (direction === 'right') {\n altered_coordinates = [a, b + 1];\n } else if (direction === 'top') {\n altered_coordinates = [a - 1, b];\n } else if (direction === 'bottom') {\n altered_coordinates = [a + 1, b];\n } else {\n console.log(\"LEET 463 problem, no change in coordinates\")\n altered_coordinate = [a, b];\n }\n \n if ((altered_coordinates[0] < 0) || (altered_coordinates[1] < 0)) {\n output = 0; //out of range, so counts as water\n console.log(\"LEET 463 coordinate < 0 out of range, output = \", output);\n return output;\n } else if ((altered_coordinates[0] > matrix.length) || (altered_coordinates[1] > matrix.length)) {\n output = 0; // out of range so counts as water\n console.log(\"LEET 463 coordinate > length out of range, output = \", output);\n return output;\n }\n \n var output = get_value_in_matrix(matrix, altered_coordinates)\n console.log(\"LEET 463 output = \", output);\n return output;\n}", "title": "" }, { "docid": "1ab37e1f4273444e8ce9c667c06ed67d", "score": "0.5199635", "text": "function zeroDiagonal(matrix) {\n const newMatrix = matrix;\n for (let i = 0; i < matrix[0].length; i++) {\n for (let j = 0; j < matrix[0].length; j++) {\n if (i === j) {\n const currentRow = newMatrix[i];\n currentRow[j] = 0;\n newMatrix[i] = currentRow;\n }\n }\n }\n return newMatrix;\n}", "title": "" }, { "docid": "efaa89ef20e731b8200b9740a68d983c", "score": "0.51982653", "text": "function nearMax(m,n)\n{\n var max=0;\n var value=0;\n var last=null;\n if(m==0&&n>0)\n return {value:matrix[0][n-1].value,position:[0,n-1]};\n if(m>0&&n==0)\n return {value:matrix[m-1][0].value,position:[m-1,0]};\n if(m*n>0)\n {\n max=Math.max(matrix[m-1][n-1].value,matrix[m][n-1].value,matrix[m-1][n].value);\n if(max==matrix[m-1][n-1].value)\n return {value:matrix[m-1][n-1].value,position:[m-1,n-1]};\n if(max==matrix[m][n-1].value)\n return {value:matrix[m][n-1].value,position:[m,n-1]};\n if(max==matrix[m-1][n].value)\n return {value:matrix[m-1][n].value,position:[m-1,n]};\n }\n}", "title": "" }, { "docid": "0423b858a310096396c1f1462ab26073", "score": "0.51943445", "text": "function rowsRearranging(matrix) {\n const sorted = matrix.sort((rowA, rowB) => {\n const scoreFunc = arr => arr.reduce((r, e, i, a) => r + (a.length - i) * e, 0);\n\n return scoreFunc(rowA) - scoreFunc(rowB);\n });\n\n let lastRow = matrix[0]\n for (let i = 1; i < matrix.length; i++) {\n for (let j = 0; j < matrix[i].length; j++) {\n if (matrix[i][j] <= lastRow[j])\n return false;\n }\n lastRow = matrix[i];\n }\n\n return true;\n}", "title": "" }, { "docid": "2e54a02030548c5af6677dda7919ba12", "score": "0.51842934", "text": "function getClosestIndexCol(currIndex, direction, minIndex, maxIndex){\n\t\tvar is_up;\n\t\tvar is_down;\n\t\tvar count;\n\t\tvar minIndex = getCol(currIndex);\n\t\tvar maxIndex = getCol(currIndex) + (BOARD_SIZE - 1) * BOARD_SIZE;\n\t\t\n\t\tif(direction == CLOSEST) {\n\t\t\tis_up = true;\n\t\t\tis_down = true;\n\t\t\tcount = BOARD_SIZE/2 + 1;\n\t\t} else if (direction == UP) {\n\t\t\tis_up = true;\n\t\t\tis_down = false;\n\t\t\tcount = BOARD_SIZE;\n\t\t} else if ( direction == DOWN) {\n\t\t\tis_up = false;\n\t\t\tis_down = true;\n\t\t\tcount = BOARD_SIZE;\n\t\t} else {\n\t\t return -1;\n\t\t}\n\t\t\n\t\tfor(var i=1 ; i <= count; i++) {\n\t\t\tif(is_up && ((currIndex - i*BOARD_SIZE) >= minIndex)) { \n\t\t\t\tif(!($('#slot-'+(currIndex - i*BOARD_SIZE)).hasClass('inactive'))) \n\t\t\t\t\treturn (currIndex - i*BOARD_SIZE);\n\t\t\t}\n\t\t\tif(is_down && ((currIndex + i*BOARD_SIZE) <= maxIndex)) {\n\t\t\t\tif(!($('#slot-'+(currIndex + i*BOARD_SIZE)).hasClass('inactive'))) \n\t\t\t\t\treturn (currIndex + i*BOARD_SIZE);\n\t\t\t}\n\t\t}\n\t\treturn -1;\n\t}", "title": "" }, { "docid": "fae55d7227eda628a69e6b72eb0d2037", "score": "0.51813805", "text": "_getLeftDiagonal() {\n return this._matrix.reduce((acc, current, index) => {\n return acc.concat(current[this._topLeft + index]);\n }, []);\n }", "title": "" }, { "docid": "4d0125dca45fd41d2f0dc126b26f01c4", "score": "0.51742774", "text": "function findValueInMatrix(myValue, myMatrix) {\n var lowPosition = 0;\n var highPosition = myMatrix.length - 1;\n while (lowPosition <= highPosition) {\n var midPosition = lowPosition + Math.floor((highPosition - lowPosition)/2);\n var result = findValue(myValue, myMatrix[midPosition]);\n if (result > -1) { // myValue is found in that row\n return [midPosition, result];\n } else { // myValue is not found in that row, so time to adjust high or low position\n if (myMatrix[midPosition][0] > myValue) {\n highPosition = midPosition - 1;\n } else {\n lowPosition = midPosition + 1;\n }\n }\n }\n return [-1, -1]; // myValue isn't found in myMatrix\n}", "title": "" }, { "docid": "7795f2d76d560e15b78626bcc155bb53", "score": "0.51731", "text": "function nextDiagLeft(currentPos, up)\n { \n if (up)\n {\n currentPos.row--; \n currentPos.col++; \n }\n else \n {\n currentPos.row++;\n currentPos.col--;\n }\n if ((currentPos.col < minCol) || (currentPos.col > maxCol) ||\n (currentPos.row < minRow) || (currentPos.row > maxRow))\n {\n return null;\n }\n return currentPos; \n }", "title": "" }, { "docid": "e6276712a78d9492c6c8ee275c7b2d1d", "score": "0.51696014", "text": "static ref_it(inMatrix) {\n let matrix = this.copy(inMatrix);\n let rows = matrix.length;\n let cols = matrix[0].length;\n\n for (let c = 0; c < cols; c++){\n\n let pivot = 0;\n let scalar = 1;\n for (let r = c; r < rows; r++){\n if (matrix[r][c] != 0.0) { //need to fix for floating point\n pivot = r;\n scalar = matrix[r][c];\n break;\n }\n }\n matrix = this.rowScale(matrix, 1/scalar, pivot);\n if (pivot != c){ //row swap using c\n //matrix = this.rowSwap(matrix, c, pivot);\n }\n\n if (c === cols - 1){\n return matrix;\n }\n\n for (let r = 0; r < matrix.length; r++){\n if (matrix[r][c] != 0.0){\n scalar = -matrix[r][c];\n matrix = this.rowScaleAdd(matrix, scalar, r, c);\n }\n }\n }\n return matrix;\n }", "title": "" }, { "docid": "2d16b242d04742037a2749c65a0c626e", "score": "0.5169037", "text": "function getUp(row, nRows) {\n if (row === 0) {\n return nRows - 1;\n } else {\n return row - 1;\n }\n }", "title": "" } ]
92bec9a137a0abb9bfef75a5cd6606b5
bool needs to be reset when game restarts
[ { "docid": "68d6dc58dfea623d9afa5d51691517a9", "score": "0.0", "text": "resetLevel() {\n this.keyWasPressed = false;\n }", "title": "" } ]
[ { "docid": "c65c74c7b99d3d2f3d7d26f76058e3f0", "score": "0.7444133", "text": "userStartOrReset() {\n if (this.game_started && !this.game_over)\n return false;\n if (!this.game_started) {\n // TODO ensure map is reset etc.\n // start the game\n this.game_started = true;\n this.startGame(this.SPEED_MILISEC);\n }\n else if (this.game_over) {\n this.resetGame();\n }\n return true;\n }", "title": "" }, { "docid": "8f38ad6f5f0d3936050c043194575764", "score": "0.73607904", "text": "gameNeedsReset(){\n if((!this.state.numMines) || (this.state.mines[\"count\"] == this.state.numMines)){\n return false; //game doesn't need to be reset\n }\n return true; //games needs to be reset\n }", "title": "" }, { "docid": "fae036200e3923139bda41a9d76e1888", "score": "0.73207974", "text": "function restart() {\r\n\r\n started = false;\r\n level = 0;\r\n gameSequence = [];\r\n}", "title": "" }, { "docid": "3ff7dffeced05326a32b6ec47f51d711", "score": "0.7262165", "text": "function restart() {\n start = false;\n level = -1;\n gamePattern = [];\n userPattern = [];\n}", "title": "" }, { "docid": "3bc489fa165c040f85c877709e731fd8", "score": "0.7110182", "text": "restartVariableGames() {\n this.inGame = true;\n this.startingGame = false;\n this.flags = 0;\n }", "title": "" }, { "docid": "c95db3d9e5ce8562ad29c0d123a29d00", "score": "0.6894741", "text": "function setFalse(){\r\n startmenu = false;\r\n newGame = false;\r\n loadGame = false;\r\n\toptions = false;\r\n \r\n tutorial = false;\r\n pdfReading = false;\r\n tutorialpage = 0;\r\n\ttutorial_video = false;\r\n credits = false;\r\n \t\r\n \ttwoPlayerGame = false;\r\n \tthreePlayerGame = false;\r\n fourPlayerGame = false;\r\n\r\n\tsetHandFalse();\r\n\r\n\tshouldEndTurn = false;\r\n\tplayerTurn = true;\r\n\tUserCanDiscard = true;\r\n\tgameEnd = false;\r\n boardDone = false;\r\n numberOfMytCards = 28;\r\n numberOfLandCards = 60;\r\n\tnumberOfBonusCards = 20;\r\n\tnumberOfProCards = 8;\r\n\tstartingSpace =false;\r\n\tlandBoardState = [[\"\",\"\",\"\",\"\",\"\"],[\"\",\"\",\"\",\"\",\"\"],[\"\",\"\",\"\",\"\",\"\"],\r\n\t\t\t\t\t[\"\",\"\",\"\",\"\",\"\"],[\"\",\"\",\"\",\"\",\"\"]];\r\n\tmytDiscard = [];\r\n\tmytComplete = [];\r\n\tmytComputerComplete = [];\r\n\tlandDiscard = [];\r\n\tlandDeckState = [];\r\n\tmytDeckState = [];\r\n\tlandHandState = [];\r\n}", "title": "" }, { "docid": "6e28f3dae652d8f89a75901f9ac0b073", "score": "0.6813581", "text": "function allowStartGame() {\n isGameStarted = false;\n currentPlayer = 0;\n clickCounter = 0;\n clearGrid();\n enablePlayerInputs(true);\n enableRestartButton(false);\n updatePlayerName();\n}", "title": "" }, { "docid": "2feaad5fd980ea128aaea87dce97dd93", "score": "0.6811682", "text": "function restart(){\n\n // resetting everything\n level = 0;\n gamePattern = [];\n started = false;\n}", "title": "" }, { "docid": "69d063c4c7405e184b4abbc88de09211", "score": "0.6791352", "text": "function checkResetTime() {\n var now = $.now(); \n if (now - endTime >= lostPause) {\n restartGame();\n }\n }", "title": "" }, { "docid": "449158e39cf5dd1979fae06e0da30470", "score": "0.6760233", "text": "function reset() {\n homeDice = false\n}", "title": "" }, { "docid": "60f5c934c93c8f842890c20cafc87999", "score": "0.6756302", "text": "function restart() {\n startBtn.style.display = 'none'\n restartBtn.addEventListener('click', () => {\n \n // puts girl in her stating point PENDING\n isGameOver = false;\n console.log(`${isgameOver}`);\n return score = 0 // reset the values\n \n })}", "title": "" }, { "docid": "6c7f8e4e623a23980d2161dbf760d91b", "score": "0.6731446", "text": "function startOver() {\n level = 0;\n gamePattern = [];\n\n // when we set this variable to false, the user will be allowed to start the game with ENTER again\n started = false;\n}", "title": "" }, { "docid": "8d15d1f10e5e7b62670e609760cbe88a", "score": "0.6730166", "text": "function resetGameConditions(){\r\n gameStart = false;\r\n playerTurn = false;\r\n level = 1;\r\n lives = 3;\r\n score = 0;\r\n numInputs = 4;\r\n gameSpeed = 925;\r\n onStreak = false;\r\n streakNum = 0;\r\n scoreMultiplier = 1.0;\r\n}", "title": "" }, { "docid": "5ffff27bd2ea37fc0dac9936a8ae774d", "score": "0.67273575", "text": "_restart() {\n level.reset();\n bird.reset();\n\n this.hasStopped = false;\n }", "title": "" }, { "docid": "f2c82d99a7fc0587a509b12e74823506", "score": "0.67237633", "text": "function startGame() {\n gameBegin = true;\n}", "title": "" }, { "docid": "b22e0ccb9a387532ddc5f669f883707d", "score": "0.66906136", "text": "function restart() {\n $('.deck').html('');\n gameData.started = false;\n gameData.openCards = [];\n gameData.moves = 0;\n gameData.matchCount = 0;\n createGrid();\n stopTimer();\n resetStars();\n $('#moves').html('0');\n }", "title": "" }, { "docid": "8bb162da9d4d20474cd8b50719130876", "score": "0.6673138", "text": "restartGame() {\n gameState.score = 0;\n gameState.starRating = 5;\n gameState.currentWaveCount = 1;\n gameState.customersServedCount = 0;\n gameState.readyForNextOrder = true;\n gameState.gameSpeed = 3;\n }", "title": "" }, { "docid": "a723b0cf9b7ca69aa03f8865618a863b", "score": "0.663217", "text": "static setGameOver() {\n this.gameOver = true;\n }", "title": "" }, { "docid": "99651e0ba0be92b3311923bb6348253f", "score": "0.66284513", "text": "function resetGame() {\n }", "title": "" }, { "docid": "fbc2f4b37b5c84fc1e161bc77f681f1e", "score": "0.66178715", "text": "function init(){\r\n if (gameAlready === true) {\r\n game();\r\n }\r\n else{location.reload()}\r\n}", "title": "" }, { "docid": "a6642e0d8cd4808770b5f5f28bdde4ef", "score": "0.66173345", "text": "function restart() {\n // localStorage.clear();\n countDown = 26;\n $('#playerRight').text('');\n $('#playerWrong').text('');\n run();\n $('#q1Choice1').prop('checked', true);\n $('#q2Choice1').prop('checked', true);\n $('#q3Choice1').prop('checked', true);\n $('#q4Choice1').prop('checked', true);\n $('#q5Choice1').prop('checked', true);\n $('#q6Choice1').prop('checked', true);\n $('#q7Choice1').prop('checked', true);\n }", "title": "" }, { "docid": "1995eb7352b10ef44e7a3011f9acfe55", "score": "0.66131395", "text": "function restart() {\n\t\tclearTimeout(gameData.timer.timerId);\n\t\tgameData.timer = {time:0, timerID:0, timerStopped: true};\n\t\tgameData.safeLeft = countSafe(gameData.settings);\n\t\tsetGrid(randomMineGenerator(gameData.settings));\n\t\tsetState(emptyGrid(gameData.settings));\n\t\tsetnumberOfMinesLeft(gameData.settings.mines);\n\t\tsetGameState(\"IDLE\");\n\t}", "title": "" }, { "docid": "524963a5d368bde5203ee461c16dd03f", "score": "0.6582747", "text": "function restartGame() {\r\n level = 0;\r\n gamePattern = [];\r\n flag = true;\r\n}", "title": "" }, { "docid": "63d6ded82b79238fb5f3b5dffc2c039e", "score": "0.6572471", "text": "function restart(){\n\t// * When the game begins again, the player should see a new random number. Also, all the crystals will have four new hidden values. Of course, the user's score (and score counter) will reset to zero.\n\t\trand=0;\n\t\tscore=0;\n\t\tpup=[];\n\t\trandNum();\t\n\t\tsetPupCuteness();\n\t\t$(\"#score\").html(\"0\");\n\t}", "title": "" }, { "docid": "0cf1001ee91c0a05495c5c78792c20ec", "score": "0.65646136", "text": "function resetGame() {\n\tstarted = false;\n\tupdateHeadingMsg(started);\n\t//hide crystal cursor until game starts */\n\t$('.cr').css('cursor','none');\n}", "title": "" }, { "docid": "1f50f395842e5329faa79fc7c11ad93c", "score": "0.6562462", "text": "function restart() {\n randomGen();\n guessesLeft = 9;\n userGuesses = [];\n }", "title": "" }, { "docid": "650f007b34cbde012b91f5d4edb920e8", "score": "0.65574527", "text": "gameIsOver() {\n this.pauseGame = true;\n this.winner = false;\n }", "title": "" }, { "docid": "8efd8a16587e0663e6fd41c9585f422f", "score": "0.65542597", "text": "function checkReset(){\r\n\t\tif(!newFeature2){\r\n\t\t\tsetHistory = false;\r\n\t\t\tmodifyThreat(updateThreat);\r\n\t\t\tif(modifyFeature.feature.attributes.data['valid_start'] == timeCanvasVal.getAttr('time')){\r\n\t\t\t\tloadConfigPanel(modifyFeature.feature.attributes.data['id']);\r\n\t\t\t}\r\n\t\t}\r\n\t}", "title": "" }, { "docid": "4e709d7a4775a2be324378bcb861035e", "score": "0.6553698", "text": "function restartGame() {\n\tgState = {\n\t\tisGameOn: true,\n\t\tshownCellsCount: 0,\n\t\tmarkedCellsCount: 0,\n\t\tclockStarted: false,\n\t\tsecsPassed: 0.0,\n\t\ttimeInterval: null\n\t}\n\trenderSmiley(IMGNORMAL);\n}", "title": "" }, { "docid": "1ffaa8e73915131e22ec0130962a948a", "score": "0.65513915", "text": "function startGame(){\n if (isGameOn === false){\n gameSequencePlayed = [];\n userSequencePlayed = [];\n isGameOn = true;\n simonTurn();\n }\n}", "title": "" }, { "docid": "a32ee2446f9eaeba4f3279a28a59e052", "score": "0.65506124", "text": "function restart(){\n numUnanswered = 0;\n correctAnswers = 0;\n incorrectAnswers = 0;\n load();\n start();\n }", "title": "" }, { "docid": "4c33166dc3380ab11c6d044c94d2e8e5", "score": "0.6549482", "text": "function resetOrContinue(){\n console.log(level);\n if (player.alive && computer.alive == false){\n continueGame();\n drawEverything();\n }\n else {\n resetGame();\n }\n}", "title": "" }, { "docid": "4291d37278f91f26858a7a05e361abdd", "score": "0.65455765", "text": "function restart()\n{\n mRestart = false;\n stop();\n start();\n}", "title": "" }, { "docid": "e4ac4ec80e8fc240bc240d343151367e", "score": "0.6537368", "text": "function gameReset() {\n cpuGuess = cpuGuesses[Math.floor(Math.random() * cpuGuesses.length)];\n console.log(\"Resetting the game...\");\n userLives = 9;\n }", "title": "" }, { "docid": "a7b0e1dc960dbbd9131bcc8bf99d1a27", "score": "0.6489836", "text": "function restart() {\n clear();\n recall();\n newGame = 1;\n gameScore = 0;\n wordScore = 0;\n tiles = [...default_tiles];\n nextRound();\n initialSetUp();\n updateIndicators();\n }", "title": "" }, { "docid": "b60f435fbed7ed519e22d22c4c2b0ba9", "score": "0.6476546", "text": "function startGame() {\n if (!isGameStarted) {\n isGameStarted = true;\n enablePlayerInputs(false);\n enableRestartButton(true);\n }\n}", "title": "" }, { "docid": "77688153a9ab19a7ebf2838d0d34a3ad", "score": "0.6475302", "text": "function resetGame() {\n \n}", "title": "" }, { "docid": "12510420530e889b406b8312dc8ff530", "score": "0.6474047", "text": "function startOver() {\n playing = false;\n level = 0;\n gamePattern = [];\n}", "title": "" }, { "docid": "deb6f208d569f6e73a6d6713274b91f0", "score": "0.6472867", "text": "function game_end() {\n running = false;\n}", "title": "" }, { "docid": "9f8def04d5283055b4a83803a936c5e6", "score": "0.6471649", "text": "function restartGame(freshStart) {\n\tif (freshStart == null) {\n\t\tfreshStart = true;\n\t}\n\t//reset game vares for a fresh run\n\tif (freshStart) {\n\t\tgameActive = true;\n\t\tscore = 0;\t\n\t\tlives = 3;\n\t}\n\tpellets = []\n\tcreatePellets();\n\t\n\t//add an extra life and subtract it to reset player and ghost positions\n\t++lives;\n\tsubtractLife();\n\n\t\n}", "title": "" }, { "docid": "fae7d88bf827b6905272e1b258750cf1", "score": "0.6463625", "text": "gameRestart() {\n\tif (this.restart_game_key) {\n\t\tthis.scene.restart();\n\t}\n}", "title": "" }, { "docid": "66b72640be5d90e5c886790255dad2de", "score": "0.646358", "text": "_clickRestart() {\n this._restart();\n gameOverScreen.hide();\n }", "title": "" }, { "docid": "0d7e7f66adf945278ff69e02bd916e9f", "score": "0.64607155", "text": "function resetGame() {\n playing = false;\n animateLargeCharsOut();\n TweenLite.killDelayedCallsTo(removeBadGuy);\n TweenLite.killDelayedCallsTo(failed);\n TweenLite.killDelayedCallsTo(removeCustomer);\n TweenLite.killDelayedCallsTo(showFinalScore);\n TweenLite.killDelayedCallsTo(generateSuperBadGuy);\n $('.score').css(\"display\",\"none\");\n $('.finalScoreContainer').css(\"display\",\"none\");\n $('.instructions').css(\"display\",\"block\");\n $('.startButton').html(\"Start Game\");\n $('.startButton').css(\"display\",\"block\");\n $('.close').css(\"display\",\"none\");\n $('.gridContainer').css(\"display\",\"none\");\n setInstructions();\n}", "title": "" }, { "docid": "536e4030bb667886163f6eb4e65c8359", "score": "0.6458265", "text": "restartGame(){\n\n this.players[0].restart();\n this.players[1].restart();\n\n this.playerTurn=0;\n\n this.gamePhase = GAME_PHASES.PLACER;\n $(\"#modal-wrapper\").hide();\n this.sidebar.showStashToPlace(this.players[0].giveCurrentStashToPlace());\n this.map.showMapStash(this.players[0]);\n }", "title": "" }, { "docid": "3daa38d957a70c5931eeb63a933e802e", "score": "0.6457849", "text": "function restart() {\n\tliveGame = 1;\n\t$('#start').prop('disabled',false);\n\tscoreCount = 0;\n\tscoreBoard.innerHTML = scoreCount;\n\ttimeleft = 30;\n\thand.style.transform = `rotate(${90}deg)`;\n\tclearInterval(countdown);\n}", "title": "" }, { "docid": "e2896277289ddf68d153f032d201b391", "score": "0.6454097", "text": "function startOver() {\n gamePattern = [];\n userClickPattern = [];\n level = 0;\n started = false;\n}", "title": "" }, { "docid": "170c3fa1ee4accc04497a4d54b6b1b66", "score": "0.64506567", "text": "function restart() {\n softBtnSound.play();\n if ( round > 0 == true && learnMode == false) byeSound.play();\n init();\n}", "title": "" }, { "docid": "ced4e987c68e7a6a45c681ea2ecda432", "score": "0.64370364", "text": "function startOver(){\r\n level=0;\r\n gamePattern = [];\r\n started = false;\r\n}", "title": "" }, { "docid": "1b60909a55ba4372f527b094cf37fadc", "score": "0.64287806", "text": "function _restartGame(){\n $(window).off(\"keypress.connectFour\");\n buttonView.deleteHandlers();\n\tsliderView.deleteHandlers();\n gridView.emptySVG();\n model.currentPlayer = 1;\n location.reload();\n model.init();\n gridView.init();\n buttonView.init();\n sliderView.init();\n}", "title": "" }, { "docid": "4ed06b801693983a0e6e180b30a723e0", "score": "0.6427569", "text": "resetsNothing() {return false}", "title": "" }, { "docid": "877f6a9055d5472a13e2484287aa49df", "score": "0.6423444", "text": "function restartGame() {\n roundNum = 0;\n userHighBal = 0;\n userHighBet = 0;\n compHighBal = 0;\n compHighBet = 0;\n setText('.compBalance', startBalance);\n setText('.userBalance', startBalance);\n userHighBal = getUserBalNum();\n compHighBal = getCompBalNum();\n setText('.userName', userName);\n setText('.compName', compName);\n resetTextInfo();\n resetDieImage();\n resetAnimateDice();\n resetBetScreen();\n $('.compbet').toggle();\n $('.userbet').toggle();\n $('.betArea').toggle();\n $('.outcome').toggle();\n $('.roundMenu').toggle();\n $('.endgame').toggle();\n $('.highlowgame').toggle();\n}", "title": "" }, { "docid": "2de228d7ee077ac873844c4ff0228c3e", "score": "0.6421223", "text": "function resetGame() {\n gameOver = false;\n witch = new Predator(100, 100, 5, playerImage, 40);\n danger = new DangerZone(400, 400, 5, dangerImage, 50, dangerBody);\n speedGuy = new Speedup(100, 100, 9, speedImage, 40);\n\n witch.health = witch.maxHealth;\n witch.preyEaten = 0;\n}", "title": "" }, { "docid": "faa1091e1f932e7a98cdd97f0902ddc9", "score": "0.641658", "text": "function startOver(){\r\n \tlevel = 0;\r\n \tstarted = false;\r\n \tgamePattern = [];\r\n }", "title": "" }, { "docid": "126a285bb8130d494ded83cdc11c3301", "score": "0.6408095", "text": "function startOver() {\r\n level = 0;\r\n gamePattern = [];\r\n started = false;\r\n}", "title": "" }, { "docid": "79ad14d8687c7811f343ce6ffacf245e", "score": "0.64056396", "text": "ResetLevel(){\n if(game.vidas > 0){//si aun le quedan vidas spawneamos todo de nuevo\n this.mario.morir();\n game.state.start('howHigh');\n }\n else this.fin(false);//si no le quedan vidas pierde\n }", "title": "" }, { "docid": "041b565ce2d1479e0eac6c2bbe8d6ebe", "score": "0.640348", "text": "function startOver() {\n level = 0;\n gamePattern = [];\n gameStarted = false;\n}", "title": "" }, { "docid": "55f180f6fdeab21912ab83cbb9c544a3", "score": "0.6396064", "text": "gameIsWon() {\n this.pauseGame = true;\n this.winner = true;\n \n }", "title": "" }, { "docid": "3ad89d742a74ad4eb0f9ba81b60128ec", "score": "0.63960063", "text": "function startOver() {\n level = 0;\n gamePattern = [];\n started = false;\n}", "title": "" }, { "docid": "719e4812ce03a9c9e26b0653b6ca0c2e", "score": "0.6389903", "text": "function resetVarsForNewGame() {\n console.log('-- resetVarsForNewGame --')\n isRunning = true\n distanceMoved = 0\n distanceFromStart = 0\n metersFromStart = 0\n totalDistanceRowed = 0\n}", "title": "" }, { "docid": "35e105dc0bbd059cd196b09aca39e384", "score": "0.6387514", "text": "function reset(){\n gameState = PLAY;\n gameOver.visible = false\n restart.visible = false\n score = 0\n space.visible = true\n player.visible = true\n life = 10\n missileAmmo = 0\n Ammo = 250\n}", "title": "" }, { "docid": "1aa17c4a56f7aac7fe1b6d11219fdd05", "score": "0.6383429", "text": "function EndGame(){\n gameStart = false;\n pile.length = 0;\n pile2.length = 0;\n player1Deck.length = 0;\n player2Deck.length = 0;\n hasPreviousFaceCard = false;\n hadPreviousFaceCard = false;\n count = 0;\n return gameStart;\n}", "title": "" }, { "docid": "4d970506e301f78ced75b488a523ada9", "score": "0.6380082", "text": "function restart() { \n\n start=false;\n flash = 0;\n turn = 0;\n turnGo =false;\n playerGo=[];\n order=[];\n go=0;\n document.getElementById('score').innerHTML=0;\n statusButton.style.background = \"red\"; \n \n}", "title": "" }, { "docid": "ce59d2ba4098f7654069386c2e15ab2e", "score": "0.63784266", "text": "function initializeNewGame() {\r\n gameState.started = true;\r\n gameState.players = initPlayers();\r\n}", "title": "" }, { "docid": "e24ce6d1bc32c03369ec7fc2438a1404", "score": "0.6375684", "text": "function restartGameControl() {\r\n try {\r\n restartGame(pageAttributes, gameSettings);\r\n selected = 0;\r\n selectedPositions = [];\r\n prevPos = 0;\r\n curPos = 0;\r\n range = gameSettings.getTotalCard() - 1;\r\n column = gameSettings.getColumnSize();\r\n flipedCards = 0;\r\n verifing = false;\r\n } catch(e) {\r\n console.error(\"Error in controller(): restartGameControl(): \" + (e && e.message) || e.toString());\r\n }\r\n }", "title": "" }, { "docid": "1047a6e3038fe83847b8b221c8d9e874", "score": "0.6374694", "text": "function gameState () {\n let startGame = false\n if (gamePhase == 0 && !gameOver) {\n console.log('Phase 1 Tutorial')\n gamePhase++\n } else if (gamePhase == 1 && !gameOver) { // Tutorial Phase ie:1\n if (firstClick) {\n console.log('Phase 2 Start')\n startGame = true\n gamePhase++\n } \n } else if (gamePhase == 2 && gameOver) { // Game Phase ie:2\n console.log('Phase 3 Game Over EM')\n gamePhase++\n } else if (gamePhase == 3 && gameOver) { // End Modal Phase ie:3\n if (ctaClicked) {\n console.log('Phase 4 Return Modual')\n returnModual() // call RM\n gamePhase++\n }\n } else { // Return Modal Phase ie:4\n //console.log('Return Modual')\n }\n} // END UPDATE //////////////////////////////////////////////////////////////////////", "title": "" }, { "docid": "c8c63a41c113aa09d1168bb62f9033fb", "score": "0.63668567", "text": "restart() {\r\n // If pacman still has lives restart his position, etc.\r\n if (hud.lives > 0) {\r\n this.d = 30;\r\n this.x = this.starting_x;\r\n this.y = this.starting_y;\r\n this.dir = [0, -1];\r\n this.next_dir = [0, -1];\r\n this.facing_angle = 90;\r\n this.next_facing_angle = 90;\r\n this.is_dying = false;\r\n }\r\n }", "title": "" }, { "docid": "2150b2bbc0bf54615ba320318c949bec", "score": "0.6363444", "text": "function resetGame () {\n setRandom ();\n userPoints = 0;\n }", "title": "" }, { "docid": "4067d1cf8ac501a95474d03c4bf788f1", "score": "0.63622373", "text": "initialVictoryState() {\r\n this.won = false;\r\n return this.won;\r\n }", "title": "" }, { "docid": "eeb076d342cce8b1fe6b31487691ca9b", "score": "0.6356226", "text": "reset() {\r\n return this.activestate = \"normal\";\r\n }", "title": "" }, { "docid": "139ef18e10b683b1152f32424880ec2f", "score": "0.6354772", "text": "function restartGame() {\n resetScore()\n resetStates()\n clearGrid();\n resetTetromino();\n gameInProgress = true\n\n // nextRandom = Math.floor(Math.random() * theTetrominoes.length)\n draw()\n nextRandom = Math.floor(Math.random() * theTetrominoes.length)\n displayShape()\n timerId = setInterval(moveDown, moveDownSpeed)\n gameTimeID = setInterval(timer, 1000)\n startButton.disabled = true;\n }", "title": "" }, { "docid": "313c7452a5f876b6d69b6674624a5e1b", "score": "0.6350801", "text": "function startOver() {\n\n level = 0;\n gamePattern = [];\n started = false;\n\n}", "title": "" }, { "docid": "043a6032bbd702ac9bca96ba721e6a6b", "score": "0.6342682", "text": "function restart(){\n if(gmover){\n init();\n $(\"#restart-btn\").css(\"visibility\", \"hidden\")\n gmover=false;\n }\n}", "title": "" }, { "docid": "7b295ba6cfa0fa3fe441024750da2434", "score": "0.6339328", "text": "function resetGame() {\n gamePattern = [];\n userPattern = [];\n level = 1;\n seq = 0;\n speed = 600;\n started = false;\n}", "title": "" }, { "docid": "5cc6703879b4ee2f5a51770c72934cf1", "score": "0.6330176", "text": "function resetGame() {\n resettingGame = false;\n $('#instruction').css('margin-top','0').show();\n $('#firstTime').show();\n mouseTotal = 0;\n catTotal = 0;\n catWidth = 80;\n $('#mouseScore').empty();\n $('#catScore').empty();\n $('body').css('background-color', backgroundColors[Math.floor((Math.random() * 6))]);\n}", "title": "" }, { "docid": "a0773c2a58c703ba190e3009d0cb5181", "score": "0.6328841", "text": "function restartGame() {\n playSound(files.click2);\n console.log('RESTARTING GAME');\n resetGameVariables();\n renderHistoric(\"hist\");\n playing = false;\n}", "title": "" }, { "docid": "9dfd0e9cff760c24ec29135a21adf332", "score": "0.6325882", "text": "outOfScreenCheck() {\n if ( this.posX > 900 ) {\n this.restart();\n }\n }", "title": "" }, { "docid": "faeb312f1a8356e816a767d0b9d6b3ee", "score": "0.6309729", "text": "function restartGame() {\n resetGameBoard();\n startGame();\n}", "title": "" }, { "docid": "808e61aad5f97952ba931d9f1d098618", "score": "0.63079005", "text": "reset() {\n game.var.pattern = [];\n game.var.input = [];\n game.var.score = 0;\n game.var.position = 2;\n game.var.gamelength = 6;\n game.var.newhighscore = false;\n game.var.live = false;\n game.var.keypause = true;\n game.ui.score.text(\"0\");\n game.ui.button.text(\"Start Game\");\n }", "title": "" }, { "docid": "1b6f9ff102b8e2f4823b10f50d2d014d", "score": "0.6297983", "text": "resetGame() {\r\n // Disable the reset button and reset the game.\r\n this.disableReset();\r\n this.game.reset();\r\n\r\n if (Math.random() < 0.5) {\r\n // Player (user) is 'O' in the next game.\r\n this.playerChoice = 'O';\r\n this.agent.player = 'X';\r\n this.computerMove();\r\n } else {\r\n // Player (user) is 'X' in the next game.\r\n this.playerChoice = 'X';\r\n this.agent.player = 'O';\r\n }\r\n }", "title": "" }, { "docid": "619f34b68b127017d318d4896caa3fbf", "score": "0.6296894", "text": "function resetGame() {\n location.reload();\n return false;\n}", "title": "" }, { "docid": "af21180cc3420d16a1c76805d7bd1027", "score": "0.62940913", "text": "function startOver(){\r\n\tlevel = 0;\r\n\tgamePattern =[];\r\n\tstarted = true;\r\n}", "title": "" }, { "docid": "e43e525784cc89a6a6eb46eadcc66d0e", "score": "0.62932825", "text": "function gameReset() {\n for (var i = 0; i < collectables.length; i++) {\n collectables[i].isFound = false;\n }\n lives = 3;\n scrollPos = 0;\n gameChar_x = 50;\n gameChar_y = floorPos_y;\n flagpole.isReached = false;\n}", "title": "" }, { "docid": "150d84d34cbf8e47b833f7a61fc8ac23", "score": "0.62862355", "text": "function restartGame(){\n arena.forEach(row => row.fill(0));\n player.score = 0;\n player.money = 0;\n player.dropInterval = 1000;\n currentScore = 0;\n updateScore();\n updateMoney();\n player.nextmatrix = null;\n pause = false;\n start = true;\n bomb = false;\n nowbomb = false;\n playerReset();\n update();\n}", "title": "" }, { "docid": "3cf725b7e27599e778835d203477a9cf", "score": "0.62834525", "text": "resetGame() {\n this.ghost_walking.position = ({x: this.GHOST_X, y: this.GHOST_Y});\n this.setupScrollingBG();\n \n this.atHouse = false;\n this.canMove = true;\n this.gameActive = true;\n this.completed = 0;\n \n this.pumpkin.resetPumpkin();\n }", "title": "" }, { "docid": "15cdb2ef1c67096a36ceae6301221551", "score": "0.62749803", "text": "function startOver(){\r\n gamePattern =[];\r\n level =0;\r\n started = false;\r\n}", "title": "" }, { "docid": "f162944dcfc7a78fb00be6b6d2939e96", "score": "0.62724966", "text": "function restartGame() {\n startTime = $.now();\n endTime = startTime;\n playerLost = false;\n $('.ball').css(\"display\", \"block\");\n $('.ball').css(\"animation-play-state\", \"running\");\n $('.ball').css(\"-webkit-animation-play-state\", \"running\");\n $('.vertical').css(\"animation-play-state\", \"running\");\n $('.vertical').css(\"-webkit-animation-play-state\", \"running\");\n $('.computer').css(\"animation-play-state\", \"running\");\n $('.computer').css(\"-webkit-animation-play-state\", \"running\");\n }", "title": "" }, { "docid": "9def6a288cdde4890d1372458f731201", "score": "0.62699115", "text": "function enablePlayAgain(reset, isLose) {\n if (isLose) {\n $('#restart').click(function() {\n $('.game-over').addClass('hidden');\n zeroStats();\n reset();\n });\n } else {\n var button = document.querySelector('.btn');\n button.addEventListener('click', function () {\n button.classList.add('hidden');\n zeroStats();\n reset();\n });\n }\n}", "title": "" }, { "docid": "f5f5ba6842ddd613b7a2da2d40eb9dfc", "score": "0.6269669", "text": "function reStartGameHandler() {\n\n $(\"#restart-button\").css(\"display\", \"none\");\n gameStart();\n}", "title": "" }, { "docid": "98a332ee80dbf944caa0ae57f3838a18", "score": "0.626816", "text": "function resetGame() {\n generateTiles(registerTileEvents);\n startTimer(TIMER_SECONDS);\n toggleGameOverModal();\n}", "title": "" }, { "docid": "1cf413c0160061d4d1a4b8e39565dbdb", "score": "0.62666506", "text": "function start()\n{\n startGame=true;\n playButton.remove();\n}", "title": "" }, { "docid": "1be2f13e62e6f99193e58bf93b54b992", "score": "0.62644196", "text": "function playTrue() {\r\n play = true;\r\n }", "title": "" }, { "docid": "f0e9d043361d048245ed669a6a5c5713", "score": "0.6263661", "text": "function startAgain() {\n STORE.numberQuestion = 0;\n STORE.score = 0;\n}", "title": "" }, { "docid": "ae6ae07b4498fa4733c341eecf23b228", "score": "0.6263349", "text": "function gameRestart() {\n gameTimerStop(gameTimer);\n readyToPlay();\n}", "title": "" }, { "docid": "f90c8d75a7361cdae2a692ba09e9a0b1", "score": "0.62588423", "text": "function init() {\n lastTime = Date.now();\n // checkIfSimonOn\n // if true resetGame();\n // main();\n }", "title": "" }, { "docid": "bc18647526d2c87004fed3db9535f150", "score": "0.6252387", "text": "function restartGame(){if ($( \"#compPlayerRemainderDiv\" ).has( \"img\" ).length){\n return true ;\n} else return false }", "title": "" }, { "docid": "a228480b945a0e2ea7db7f66ee7c76fc", "score": "0.62501264", "text": "function reset(){\n gameState =PLAY;\n distance =0;\n gameOver.visible=false;\n boy.changeAnimation(\"BOYRunning\",boy1Img);\n log.destroyEach()\n log2.destroyEach()\n stone.destroyEach()\n\n\n\n\n\n }", "title": "" }, { "docid": "91a4c98b699f630c41d26eac84f6e695", "score": "0.62498266", "text": "function restart() {\n number = 50; // set number back to 50\n startGame(); // calls the function start\n }", "title": "" }, { "docid": "83c44624f7dcad16596a14293e92a41a", "score": "0.6249379", "text": "function restartLevel() {\n\t\tbuttonClick.play();\n music.stop();\n // Reset all global variables.\n blockCount = 0;\n blockTotal = 0;\n levelComplete = false;\n onBelly = false;\n score = 0;\n time = 0;\n game.time.reset();\n game.state.restart();\n }", "title": "" }, { "docid": "409152e7866a51325f4d0859a2b7389c", "score": "0.6247227", "text": "function gameRestart() {\n maxEnemies = 8;\n minSpeed = 20;\n paused = 0;\n countdown = 0;\n mode = 1;\n\n gameReset();\n\n if(level > 0) gameChoose();\n\n if(level === -1) level = winLevel; //For testing the last level\n else level = 1;\n}", "title": "" }, { "docid": "95ac1af2d9519c93b728881e7c989130", "score": "0.62444836", "text": "function gameReset() {\n\tcurrentObject = 0;\n\tcorrectAnswers = 0;\n\tincorrectAnswers = 0;\n\tcounter = 0;\n\tanswerGuessed = \"\";\n\taudio.pause();\n\taudio.load();\n\tstartGame();\n}", "title": "" }, { "docid": "d2b3f249a6b8cfb1c1a635302d5bd224", "score": "0.62377024", "text": "function restartQuiz() {\n store.quizStarted = false;\n store.currentQuestion = 0;\n store.score = 0;\n}", "title": "" } ]
e820c7424acd0e3cd94b1b035cf36ce4
If template is not there add it, will also remove and change old template
[ { "docid": "efcf37858481e0cc6acc553bea9a4e1b", "score": "0.67112803", "text": "function templateCheck() {\n // Remove or change old template elements\n if ($(iframeID).contents().find('#kl_wrapper').length > 0) {\n var currentTheme = $(iframeID).contents().find('#kl_wrapper').attr('class');\n $('#' + currentTheme).addClass('kl_active_theme');\n } else {\n // Add base html if template doesn't exist\n $(iframeID).contents().find('#tinymce').prepend(templateShell);\n }\n }", "title": "" } ]
[ { "docid": "544baeaa154f2c6bffe9cf0761ac1c9b", "score": "0.71920156", "text": "function registerTemplate() {\n\n} // be able to register a new template", "title": "" }, { "docid": "69e1ff175c4cf92e91b4ff677f16a164", "score": "0.6607995", "text": "function removeTemplate() {\n\n document.querySelector('template').remove();\n\n}", "title": "" }, { "docid": "700e0377c10ff40ad2efb1f9e17bc394", "score": "0.6519157", "text": "function refreshTemplateSection(ginipkgTemplatePosition){\n if (typeof ginipkgTemplatePosition != 'undefined') {\n processTemplate(ginipkgTemplatePosition,ginipkg.template_details); \n }\n }", "title": "" }, { "docid": "281ffe8900339e4797234ac6aaf9ff6a", "score": "0.6510319", "text": "function addNewViewFromTemplate(name){\r\n\tvar j = -1;\r\n\tfor(i = 0; i<viewTemplates.length; i++){\r\n\t\tif(viewTemplates[i].viewName===name){\r\n\t\t\taddNewView(viewTemplates[i]);\r\n\t\t\tbreak;\r\n\t\t}\r\n\t}\t\r\n}", "title": "" }, { "docid": "ea49f73f6d486232212afd50247368d9", "score": "0.65081364", "text": "function changeTemplate() {\n var templateFile = File.openDialog(\"Choose a template file\",\"After Effects Template:*.aet;*.aep,All files:*\", false);\n if ((templateFile != null) && templateFile.exists)\n {\n templateFile = templateFile;\n\n // Remember the template for the next session\n app.settings.saveSetting(scriptName,\"templateFile\", templateFile.absoluteURI);\n return true;\n } else {\n return false;\n }\n }", "title": "" }, { "docid": "d8853ebd6d3becc3d9904f783806e296", "score": "0.6424287", "text": "restoreTemplate() {\n TemplateManager.restoreTemplate(this);\n }", "title": "" }, { "docid": "56741858478f6d679fe9df2941b5a283", "score": "0.633984", "text": "function importTemplate() {\n \n try {\n var masterFolder = app.project.importFile(new ImportOptions(File(app.settings.getSetting(scriptName, \"templateFile\"))));\n app.beginUndoGroup(\"Import template file\");\n }\n catch(e)\n {\n alert(\"Template file does not exist. Please use the \\\"...\\\" button to choose a template file.\");\n var templateChosen = changeTemplate();\n if (templateChosen) importTemplate();\n return;\n }\n mergeFolderContents(masterFolder,app.project.rootFolder);\n masterFolder.remove();\n\n app.endUndoGroup();\n }", "title": "" }, { "docid": "f3d29d3f7688ca6c63e5e9f90d1f599e", "score": "0.63104165", "text": "function remove() {\n template.remove();\n}", "title": "" }, { "docid": "55485bf4a2e60ddaece8b12bbcb80c1a", "score": "0.6301618", "text": "function toggleNewPostTemplate() {\n\tvar templateIsShown = document.getElementById('new-post-template-is-shown');\n\tif (templateIsShown.value !== 'true') {\n\t\ttemplateIsShown.value = 'true'\n\t\tvar timeline = document.getElementById('post-list');\n\t\tvar newPostTemplate = document.getElementById('new-post-template');\n\t\ttimeline.innerHTML = newPostTemplate.innerHTML + timeline.innerHTML;\t\n\t}\n\telse {\n\t\t//Remove the template from the view.\n\t}\n}", "title": "" }, { "docid": "a8fe4febacb028ecb4f13c5f573d18e1", "score": "0.6254897", "text": "function addTemplate(templateid,obj){\n var addTemplate = true;\n \n // *****Hidding templates STATE WISE*************\n if(Wtf.account.companyAccountPref.stateid != Wtf.StateName.MAHARASHTRA ){\n if(templateid == Wtf.template.RETAIL_INVOICE_MH || templateid == Wtf.template.VAT_INVOICE_MH || templateid == Wtf.template.VAT_DO ){\n addTemplate = false;\n }\n } else{\n if(templateid == Wtf.template.RETAIL_INVOICE || templateid == Wtf.template.VAT_INVOICE){\n addTemplate = false;\n }\n }\n // *****Hidding templates on Checks*************\n// if(Wtf.isExciseApplicable){\n// if(templateid == Wtf.template.VAT_INVOICE || templateid == Wtf.template.VAT_DO || templateid == Wtf.template.RETAIL_INVOICE || templateid == Wtf.template.RETAIL_INVOICE_MH){\n// addTemplate = false;\n// }\n// }\n if(!Wtf.account.companyAccountPref.enablevatcst){\n if( templateid == Wtf.template.VAT_DO){\n addTemplate = false;\n }\n }\n if(!Wtf.account.companyAccountPref.enablevatcst && !Wtf.isSTApplicable){\n if(templateid == Wtf.template.VAT_INVOICE_MH || templateid == Wtf.template.VAT_INVOICE ){\n addTemplate = false;\n }\n }\n if(templateid == Wtf.template.SERVICE_TAX_INVOICE){\n addTemplate = false;\n } \n if(templateid == Wtf.template.RULE_11_MANUFACTURER && Wtf.registrationType != Wtf.registrationTypeValues.MANUFACTURER){\n addTemplate = false;\n }\n if(templateid == Wtf.template.DEFAULT_TEMPLATE_INVOICE || templateid == Wtf.template.DEFAULT_TEMPLATE_PI || templateid == Wtf.template.DEFAULT_TEMPLATE_PO || templateid == Wtf.template.DEFAULT_TEMPLATE_CQ ){\n addTemplate = false;\n }\n return addTemplate;\n}", "title": "" }, { "docid": "72c71dc5d618a98939a3c8f8d3b12fbc", "score": "0.62482184", "text": "function loadTemplate() {\n\t\t\t$tpl = /^</.test(settings.template) ? settings.template : $('#' + settings.template).html();\n\t\t}", "title": "" }, { "docid": "434e4ddec5b99a29b0464ebcaa00a0c8", "score": "0.62121737", "text": "static editTask(task, template) {\n $(task).closest(\"li\").empty().append(template);\n }", "title": "" }, { "docid": "4a77542d3f7d172e4bf0fae92887189e", "score": "0.61782223", "text": "function addTemplate(name, number, type) {\n // create new income template\n let input = `<li class=\"inputFormat ${type}\">\n <span class=\"templateName\">${name}</span>\n <span class=\"templateNumber\">$${number}</span>\n <span><i class=\"far fa-trash-alt\"></i></span>\n </li>`;\n\n // add new template to page\n if (type === 'income') {\n let incomeDiv = document.querySelector('#incomeUL');\n incomeDiv.innerHTML += input;\n } else if (type === 'expense') {\n let incomeDiv = document.querySelector('#expenseUL');\n incomeDiv.innerHTML += input;\n } else {\n console.log('template conditional is not working');\n }\n}", "title": "" }, { "docid": "814fd4d9e83a858409232e0f1757b780", "score": "0.61723673", "text": "function toggleNewFollowTemplate() {\n\tvar templateIsShown = document.getElementById('new-follow-template-is-shown');\n\tif (templateIsShown.value !== 'true') {\n\t\ttemplateIsShown.value = 'true'\n\t\tvar timeline = document.getElementById('post-list');\n\t\tvar newPostTemplate = document.getElementById('new-follow-template');\n\t\ttimeline.innerHTML = newPostTemplate.innerHTML + timeline.innerHTML;\t\n\t}\n\telse {\n\t\t//Remove the template from the view.\n\t}\n}", "title": "" }, { "docid": "604976ef97ffa8d688d4909b2b4ecd41", "score": "0.6126623", "text": "function setTemplateField() {\n var templateId = $(\"#templateList\").val();\n var preTemplateId = $(\"#currentTemplateId\").val();\n if (templateId == preTemplateId) {\n return;\n }\n if (isChangedData) {\n saveTemplate(eventTypeEnum.IS_CHANGED_LIST, function (saveStatus) {\n if(saveStatus) {\n pSetTemplateField(templateId);\n } else {\n $(\"#templateList\").val(preTemplateId);\n }\n });\n } else {\n pSetTemplateField(templateId);\n }\n}", "title": "" }, { "docid": "91d51a24b8ede8461cb1cb28da74f28b", "score": "0.60848796", "text": "function insertTemplatedContent(el, templateName){\n el.innerHTML = templates[templateName](el.dataset);\n }", "title": "" }, { "docid": "7c89b0400f0d41e77dcf0df4cecd7d36", "score": "0.60847723", "text": "setCustomTemplate() {}", "title": "" }, { "docid": "8d32b83224462b93dfd42ab3fc38eade", "score": "0.60384357", "text": "function updateTemplate(item) {\n var oldHtmlArray = item.html, // don't overwrite if already existed!\n htmlArray = (item.html = []),\n oldCanvasArray = item.canvas,\n canvasArray = (item.canvas = []),\n oldSdimgArray = item.sdimg,\n sdimgArray = (item.sdimg = []),\n renderer,\n serverItemsArray,\n isNewItem = !oldHtmlArray;\n\n // template level -1 is used for if no templates were specified\n // (the old CXML case).\n if (oldSdimgArray) {\n sdimgArray[-1] = oldSdimgArray[-1];\n }\n templates.forEach(function (template, index) {\n switch (template.type) {\n case \"canvas\":\n htmlArray.push([]);\n canvasArray.push(template.func);\n sdimgArray.push(undefined);\n break;\n case \"img\":\n case \"color\":\n htmlArray.push([]);\n canvasArray.push(makeTemplate(template, item));\n sdimgArray.push(undefined);\n break;\n case \"sdimg\":\n htmlArray.push([]);\n canvasArray.push(undefined);\n sdimgArray.push(sdimgArray[-1]);\n break;\n case \"fakehtml\":\n if (isNewItem) {\n renderer = template.renderer;\n\n // push this item to the server for rendering as part of a dynamic DZC\n serverItemsArray = serverSideItems[index] =\n serverSideItems[index] || [];\n serverItemsArray.push(item);\n\n // get ready to send a request for server-side rendering\n // (not right away, because we want to accumulate all items before\n // launching the request)\n if (serverRenderTimeout === undefined) {\n serverRenderTimeout = true;\n delayFunction(renderOnServer);\n }\n\n htmlArray.push([makeTemplate(template, item)]);\n\n // we have to have fallback content because it takes a long time to render server-side.\n // it would ruin our perf to have the fallback content be actual html, so we'll draw\n // something on the canvas. if nothing else was specified, just draw a gray box to fill\n // the space.\n canvasArray.push(\n makeTemplate(\n template.fallback || {\n type: \"color\",\n template: \"gray\",\n },\n item\n )\n );\n\n sdimgArray.push(undefined);\n } else {\n // this binding already happened once and we're not redoing it.\n // just copy the results over to the new templates.\n htmlArray.push(oldHtmlArray[index]);\n canvasArray.push(oldCanvasArray[index]);\n sdimgArray.push(oldSdimgArray[index]);\n }\n break;\n case \"html\":\n if (oldHtmlArray) {\n // there were already HTML representations of this item. since they might\n // be onscreen and likely have other useful position info and such on them,\n // we'll reuse the container element but replace its inner HTML.\n // In rare cases there might be multiple copies of the element's HTML because\n // it is present in multiple graph bars. TODO optimize templating in this case.\n htmlArray.push(oldHtmlArray[index]);\n oldHtmlArray[index].forEach(function (htmlElement) {\n makeTemplate(template, item, htmlElement);\n });\n } else {\n htmlArray.push([makeTemplate(template, item)]);\n }\n canvasArray.push(undefined);\n sdimgArray.push(undefined);\n break;\n default:\n Seadragon2.Debug.warn(\"updateTemplate: unrecognized template type\");\n }\n });\n\n // find and set the aspect ratio for the item. we assume that the aspect ratio\n // of all template levels will match (or at least approximate) the ratio of\n // the top level.\n if (templates.length) {\n var biggestTemplate = templates[templates.length - 1];\n item.normHeight =\n (biggestTemplate.height || biggestTemplate.width) /\n biggestTemplate.width;\n }\n }", "title": "" }, { "docid": "77ddb225ebc45a121d6db41e6ca69ad6", "score": "0.6002792", "text": "function upgradeTemplate(template,constructor){newInstance=template;Object.setPrototypeOf(template,constructor.prototype);new constructor();newInstance=null;}", "title": "" }, { "docid": "00f0e034eddcf84eb8d2a165922ffad2", "score": "0.5981001", "text": "function cloneTemplate(templateName, destination) {\n $(templateName).clone().attr(\"id\", \"\").appendTo(destination)\n}", "title": "" }, { "docid": "1ac61e2a4fb6d56c91583934f291a552", "score": "0.5978656", "text": "initTemplate() {\n this.template = new Template(\n this.properties.template,\n this.properties.paths.templates\n );\n }", "title": "" }, { "docid": "b73a9323cf23ddd2c5f0ba9c375ead29", "score": "0.5972739", "text": "function newTemplate() {\n\t\tvar realTemplateObject = {\n\t\t\tr: '<span class=\"newsric\" jet=\"JETDATA\" e.RIC=\"%s\">%s</span>',\n\t\t\tst: '<a href=\"cpurl://views.cp./Explorer/NEWSxSTORY.aspx?ric=%s\" class=\"newsSearch\">%s</a>',\n\t\t\tse: '<a href=\"%s\" class=\"newsStory\">%s</a> ',\n\t\t\tl: '<a href=\"%s\" class=\"newsLink\">%s</a> ',\n\t\t\thk: '<b>%s</b>',\n\t\t\thh: '<span style=\"background-color:red\">%s</span>'\n\t\t};\n\n\t\tvar templateObject = {\n\t\t\t//Sets template for a RIC\n\t\t\tric: function (templateString) {\n\t\t\t\tcheckParameter(templateString, \"templateString\", \"string\");\n\t\t\t\trealTemplateObject.r = templateString;\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\t//Sets template for News story link\n\t\t\tnewsStoryLink: function (templateString) {\n\t\t\t\tcheckParameter(templateString, \"templateString\", \"string\");\n\t\t\t\trealTemplateObject.st = templateString;\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\t//Sets template for News search link\n\t\t\tnewsSearchLink: function (templateString) {\n\t\t\t\tcheckParameter(templateString, \"templateString\", \"string\");\n\t\t\t\trealTemplateObject.se = templateString;\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\t//Sets template for link\n\t\t\tlink: function (templateString) {\n\t\t\t\tcheckParameter(templateString, \"templateString\", \"string\");\n\t\t\t\trealTemplateObject.l = templateString;\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\t//Sets template for highlighted headline\n\t\t\thighlightedHeadline: function (templateString) {\n\t\t\t\tcheckParameter(templateString, \"templateString\", \"string\");\n\t\t\t\trealTemplateObject.hh = templateString;\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\t//Sets template for highlighted keyword\n\t\t\thighlightedKeyword: function (templateString) {\n\t\t\t\tcheckParameter(templateString, \"templateString\", \"string\");\n\t\t\t\trealTemplateObject.hk = templateString;\n\t\t\t\treturn this;\n\t\t\t},\n\t\t\t//Returns template object that can be passed to Container\n\t\t\tgetRawTemplate: function () {\n\t\t\t\treturn realTemplateObject;\n\t\t\t}\n\t\t}\n\t\treturn templateObject;\n\t}", "title": "" }, { "docid": "720c0bddbdcb5ff7db6432d3e69dbf07", "score": "0.5939725", "text": "function removeTemplate(target) {\n $(target).remove()\n}", "title": "" }, { "docid": "65c94cf78ead39b1589666f4c8e065cf", "score": "0.59295356", "text": "function addTemplate(req, res) {\n var template = new Template(req.body);\n Template.count({}, function (err, count) {\n template.templateId = commonService.getModelId('Org', count);\n template.save(function (err) {\n if (err) {\n if (err.code == 11000) {\n res.status(409).json(req.body.templateName + '- Template name is already exist'\n );\n\n } else {\n res.status(500).json({ message: \"Please try again after sometime\" });\n }\n\n }\n else {\n res.send({\n message: 'Template created Successfully'\n });\n }\n });\n });\n\n}", "title": "" }, { "docid": "48fa3fdba8e7c485c8fb43b9c87523cc", "score": "0.5910208", "text": "setTemplate(temp, callback, params={} ){\n if(this.isHTML(temp) == false){\n this.loadRemoteTemplate(temp,callback,params);\n\n\n }else{\n\n this.template = this.templateParams(temp, params);\n\n }\n\n }", "title": "" }, { "docid": "d5961951cdd36fc254d33f0f3c3c9110", "score": "0.5900564", "text": "function addTemplate() {\n var templateDiv = document.getElementById(\"template\");\n templateDiv.innerHTML = \"\\n <header>\\n <b>Eric Loux's Portfolio Site</b>\\n </header>\\n <div class=\\\"grid-master\\\">\\n <nav class=\\\"grid-side\\\">\\n Here is the nav.\\n </nav>\\n\\n <div class=\\\"content\\\">\\n Here is the content.\\n </div>\\n\\n <div class=\\\"grid-side\\\">\\n <!--! <img src=\\\"https://github.com/ericloux/portfolio_site/blob/master/assets/headshot.JPG?raw=true\\\" alt=\\\"The man himself\\\"/> -->\\n </div>\\n </div>\\n <footer>\\n Copyright 2019 Eric Loux\\n </footer>\";\n window.scrollTo(0, 0);\n} // Puts footer at the bottom of the page or below content (whichever is lower)", "title": "" }, { "docid": "50744bb3420effb84603d329d217cfff", "score": "0.589741", "text": "onSetTemplate(state, {template}) {\n // `template` will already be an Immutable.Map\n return state.setIn(['doc', 'template'], template);\n }", "title": "" }, { "docid": "d5530c68749399e86dc5ef408fe02224", "score": "0.5892079", "text": "createByTemplate(template){\n this.get('commandRegistry').execute(DOCUMENT_NEW_FROM_TEMPLATE, template, this.currentModel.project);\n }", "title": "" }, { "docid": "04e39b5b354e67c0bca5456715279bbf", "score": "0.5880526", "text": "function onTemplateLoaded(newTemplate) {\n\n template = newTemplate;\n template.isInEditor = true;\n\n Y.log('Form template loaded... ' + template.canonicalId + ' -v- ' + template.formVersionId, 'info', NAME);\n\n // Apply any user language preference\n var formUserLang = Y.dcforms.getUserLang(template.formId);\n\n if (formUserLang && ('' !== formUserLang)) {\n if (template.userLang !== formUserLang) {\n Y.log('Setting form language from stored preference: ' + formUserLang, 'info', NAME);\n template.setUserLang(formUserLang);\n }\n }\n\n lastCategory = template.category;\n\n // set the form title in user language\n setTitle();\n\n // set or update handlers for menu buttons\n jqCache.btnEdit.off('click.forms').on('click.forms', onEditBtnClick);\n jqCache.btnCopyDefault.off('click.forms').on('click.forms', onCopyBtnClick);\n jqCache.btnFill.off('click.forms').on('click.forms', onFillBtnClick);\n jqCache.btnTest.off('click.forms').on('click.forms', onTestBtnClick);\n jqCache.btnTestCats.off('click.forms').on('click.forms', onTestCatsBtnClick);\n jqCache.btnPDF.off('click.forms').on('click.forms', onPDFBtnClick);\n jqCache.btnReset.off('click.forms').on('click.forms', onResetBtnClick);\n jqCache.aAddPage.off('click.forms').on('click.forms', onAddPageBtnClick);\n jqCache.chkFormDevOptions.off('change').on('change', onDebugToggle);\n jqCache.btnApplyMap.off('click').on('click', onApplyMappedObjectBtnClick);\n jqCache.btnUnMap.off('click').on('click', onUnMapObjectBtnClick);\n\n jqCache.aLangEN.off('click').on('click', function() { updateLangOptions( 'en', 'n' ); } );\n jqCache.aLangDE.off('click').on('click', function() { updateLangOptions( 'de', 'n' ); } );\n jqCache.aLangDEF.off('click').on('click', function() { updateLangOptions( 'de', 'f' ); } );\n jqCache.aLangDEM.off('click').on('click', function() { updateLangOptions( 'de', 'm' ); } );\n\n jqCache.btnEditTranslations.off('click').on('click', onEditTranslationsBtnClick);\n\n // load form property panels\n loadEditForm(function(){\n Y.log('Loaded edit form.', 'debug', NAME);\n });\n\n loadEditPageForm('divEditPage', template);\n loadEditPdfForm('divPrintOptions', template);\n loadEditElementForm('divEditElement', template);\n loadBFBPropertiesForm('divBFBAtForm', template);\n loadImageControl('divEditImages', template.canonicalId, 'forms', Y.dcforms.nullCallback);\n onSchemaSet();\n\n // add events to link in 'new element' menu\n addElementMenu();\n\n onModeSet(template.mode);\n\n // enable debug mode automatically if PUC was started with --debug srgument\n if ('true' === $('#ARGV_DEBUG').val()) {\n Y.log('Server started in debug mode, debug controls default on.', 'debug', NAME);\n jqCache.chkFormDevOptions.prop('checked', true);\n onDebugToggle();\n }\n\n // change minicolor default theme to Bootstrap, enable RGB format and opacity\n $.minicolors = {\n defaults: {\n opacity: true,\n format: 'rgb',\n theme: 'bootstrap'\n }\n };\n\n // show edit or copy button (default, read only forms can be copied but not edited)\n if (template.isReadOnly) {\n jqCache.btnEdit.hide();\n jqCache.btnCopyDefault.show();\n jqCache.spanLockButton.hide();\n jqCache.spanUnLockButton.show();\n } else {\n jqCache.btnEdit.show();\n jqCache.btnCopyDefault.hide();\n jqCache.spanLockButton.show();\n jqCache.spanUnLockButton.hide();\n }\n\n jqCache.spanLockButton.off('click').on('click', onLockClick);\n jqCache.spanUnLockButton.off('click').on('click', onUnLockClick);\n\n // draw / refresh it on canvas - when displayed we may need to update the page height for affix / scroll of\n // left column\n\n function onInitialRender() {\n var\n divHeight = $('#divFormsEdit').height(),\n windowHeight = $(window).height(),\n divPadBase = $('#divPadBase');\n\n if (divHeight < windowHeight) {\n divPadBase.css('height', (windowHeight - divHeight) + 'px');\n } else {\n divPadBase.css('height', '0px');\n }\n // MOJ-4848 temporarily disabled\n //template.setFirstSelected('fixed');\n }\n\n function onInitialResize() {\n template.render(onInitialRender);\n }\n\n template.resize( jqCache.formButtonsContainer.width(), onInitialResize );\n }", "title": "" }, { "docid": "c146d6e64ddc9c0838bf3e94fb6b382c", "score": "0.5865297", "text": "setTemplate(temp, callback, params={} ){\n\n if(this.isHTML(temp) == false){\n this.loadRemoteTemplate(temp,callback,params);\n\n\n }else{\n\n this.template = this.templateParams(temp, params);\n\n }\n\n }", "title": "" }, { "docid": "bc21b22ef985eccfc79e3501c1f154a8", "score": "0.58449584", "text": "async newTemplate ({commit, getters}, payload) {\n commit('clearError')\n commit('setLoading', true)\n try {\n // Use helped class\n const newTemplate = new Template(\n payload.title,\n payload.description,\n payload.access\n )\n const template = await firebase.database().ref(getters.user.id + '/templates').push(newTemplate)\n // Send mutations\n commit('setCurrentTemplateId', template.key)\n commit('newTemplate', {\n ...newTemplate,\n id: template.key\n })\n\n commit('setLoading', false)\n } catch (error) {\n commit('setLoading', false)\n commit('setError', error.message)\n throw error\n }\n }", "title": "" }, { "docid": "13e196a3bca1f1d3ef78b33a48d6bcae", "score": "0.5809561", "text": "function addTemplate(templateTitle, greeting, body, signature, postSignature) {\n emailTemplates.push([templateTitle, greeting, body, signature, postSignature]);\n}", "title": "" }, { "docid": "fbba5940b51f08fd299c1961db28b1bc", "score": "0.5777192", "text": "function addTemplate() {\n if ($('#template-form-new .template-input').length == 0) {\n const form = document.getElementById('template-form-new');\n form.hidden = false;\n form.innerHTML += `<div class=\"template-input\">\n <div class=\"template-details form-group\">\n <input type=\"text\" id=\"new-name\" class=\"name form-control\" name=\"templatename\" placeholder=\"Template name\" required/>\n <input type=\"text\" id=\"new-subject\" class=\"subject form-control\" name=\"templatesubject\" placeholder=\"Subject\" required/>\n </div>\n <button type=\"button\" class=\"btn btn-primary\" onclick=\"$('#add-content').modal()\">Add HTML</button>\n <div class=\"template-confirm-btn\"><a class=\"options\" onclick=\"submitAddTemplateForm();\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Confirm\"><ion-icon name=\"checkmark-outline\"></ion-icon></a></div>\n <div class=\"template-cancel-btn\"><a class=\"options\" onclick=\"cancelAddTemplateForm();\" data-toggle=\"tooltip\" data-placement=\"top\" title=\"Cancel\"><ion-icon name=\"close-outline\"></ion-icon></a></div>\n </div>`;\n $('.options').tooltip({ delay: { show: 200, hide: 0 } });\n $('#new-name').focus();\n }\n else {\n $('#new-name').focus();\n }\n}", "title": "" }, { "docid": "60ec09bcd2ac6184604387343e95a071", "score": "0.5775782", "text": "function tag(templateObject) {\n previousObject = templateObject;\n}", "title": "" }, { "docid": "61d97672ad3835ee60882f61fab4e69b", "score": "0.5773627", "text": "render() {\n this.appendChild(this.getTemplate().content.cloneNode(true))\n }", "title": "" }, { "docid": "cc3d0d2207c35cd1a21c8e491aaf1a92", "score": "0.57730836", "text": "copy({projectName, templateFilePath, request, reply}) {\n const {newName} = request.query;\n const [templateName, templateEngine] = this._templateNameAndEngineFromPath(templateFilePath);\n\n reply(this.templateService.copy({projectName, templateName, templateEngine, newName}));\n }", "title": "" }, { "docid": "8e421adc64a5cc221909c9ac765a4bdf", "score": "0.5757667", "text": "function Ractive$resetTemplate ( template ) {\n\t\ttemplateConfigurator.init( null, this, { template: template });\n\n\t\tvar transitionsEnabled = this.transitionsEnabled;\n\t\tthis.transitionsEnabled = false;\n\n\t\t// Is this is a component, we need to set the `shouldDestroy`\n\t\t// flag, otherwise it will assume by default that a parent node\n\t\t// will be detached, and therefore it doesn't need to bother\n\t\t// detaching its own nodes\n\t\tvar component = this.component;\n\t\tif ( component ) component.shouldDestroy = true;\n\t\tthis.unrender();\n\t\tif ( component ) component.shouldDestroy = false;\n\n\t\t// remove existing fragment and create new one\n\t\tthis.fragment.unbind().unrender( true );\n\n\t\tthis.fragment = new Fragment({\n\t\t\ttemplate: this.template,\n\t\t\troot: this,\n\t\t\towner: this\n\t\t});\n\n\t\tvar docFrag = createDocumentFragment();\n\t\tthis.fragment.bind( this.viewmodel ).render( docFrag );\n\n\t\t// if this is a component, its el may not be valid, so find a\n\t\t// target based on the component container\n\t\tif ( component ) {\n\t\t\tthis.fragment.findParentNode().insertBefore( docFrag, component.findNextNode() );\n\t\t} else {\n\t\t\tthis.el.insertBefore( docFrag, this.anchor );\n\t\t}\n\n\t\tthis.transitionsEnabled = transitionsEnabled;\n\t}", "title": "" }, { "docid": "17054abe29d6e3bc378c0d6fa6a24a46", "score": "0.57492435", "text": "function cleanupTemplate() {\n try {\n fs.removeSync(path.join(settings.pathTmp, '.git'));\n fs.copySync(settings.pathTmp, settings.path, { mkdirp: true, clobber: true });\n fs.removeSync(settings.pathTmp);\n } catch (err) {\n logger.info('Template cleanup failed.');\n }\n}", "title": "" }, { "docid": "69a233628c6f22f71cd037f3e3c67050", "score": "0.5749025", "text": "function addTemplate() {\n var templateDiv = document.getElementById(\"template\");\n templateDiv.innerHTML = \"\\n <header>\\n <b>Eric Loux's Portfolio Site</b>\\n </header>\\n <div class=\\\"grid-master\\\">\\n <nav class=\\\"grid-side\\\">\\n Here is the nav.\\n </nav>\\n\\n <div class=\\\"content\\\">\\n Here is the content.\\n </div>\\n\\n <div class=\\\"grid-side\\\">\\n Here is blank space.\\n </div>\\n </div>\\n <footer>\\n Copyright 2019 Eric Loux\\n </footer>\";\n} // Puts footer at the bottom of the page or below content (whichever is lower)", "title": "" }, { "docid": "f6912b5bec41068bfda303fa7b1c878b", "score": "0.5735353", "text": "function templateChanged() {\n generateFields(configModel.templates[vm.model.template].attributes);\n }", "title": "" }, { "docid": "5e2419def5dfd021bbcd61192bdee60d", "score": "0.5734993", "text": "async function createNew(_context, isRenameTemplate) {\n\ttry {\n\t\tconst workspaceRootPath = vscode.workspace.rootPath;\n\n\t\tconst configFilePath = path.resolve(\n\t\t\tworkspaceRootPath,\n\t\t\t\"template.config.js\"\n\t\t);\n\t\tconsole.log(\"configFilePath: \" + path.resolve(\n\t\t\tworkspaceRootPath,\n\t\t\t\"template.config.js\"\n\t\t));\n\n\t\tvar teste = await getDirectories(\".\");\n\n\t\tconsole.log(\"--->\" + teste.toString);\n\n\t\t// // If not exist configuration file, make a default configuration file at workspace.\n\t\tif (!(await fs.pathExists(configFilePath))) {\n\t\t\tawait makeTemplateConfigJs(configFilePath);\n\t\t}\n\n\t\tconst config = require(configFilePath);\n\n\n\n\t\tconst templateRootPath = path.resolve(\n\t\t\tworkspaceRootPath,\n\t\t\tconfig.templateRootPath || config.templatePath // deprecated `config.templatePath`\n\t\t);\n\t\tconsole.log(\"templateRootPath: \" + path.resolve(\n\t\t\tworkspaceRootPath,\n\t\t\tconfig.templateRootPath || config.templatePath // deprecated `config.templatePath`\n\t\t));\n\n\t\t// If not exist `config.templateRootPath`, make `.templates` folder and make sample templates in `.templates`\n\t\tif (!(await fs.pathExists(templateRootPath))) {\n\t\t\tawait makeSampleTemplate(templateRootPath);\n\t\t}\n\n\t\tconst workingPathDir = getWorkingPathDir(\n\t\t\t_context,\n\t\t\tvscode.window.activeTextEditor,\n\t\t\tvscode.workspace\n\t\t);\n\n\t\tconst templatePaths = await fs.readdir(templateRootPath);\n\n\n\t\t//########################\n\t\tconst testeDir = await fs.readdir(\".\");\n\n\t\tconst templateRootPath2 = path.resolve(\n\t\t\tworkspaceRootPath,\n\t\t\t// deprecated `config.templatePath`\n\t\t);\n\n\t\tconst dstPath2 = path.resolve(workingPathDir); /// <<<<<<<<<<<<<<<<<<\n\t\tconst testeDir2 = await fs.readdir(dstPath2);\n\n\t\tvar point = \"\";\n\n\t\t//########################\n\n\t\tconst templateName = await vscode.window.showQuickPick(templatePaths, {\n\t\t\tplaceHolder: \"Choose a template\"\n\t\t});\n\n\t\t// If no input data, do nothing\n\t\tif (templateName === undefined) {\n\t\t\treturn;\n\t\t}\n\n\t\t// Copy a template to path\n\t\tconst srcPath = path.resolve(templateRootPath, templateName);\n\t\tconsole.log(\"source path: \" + path.resolve(templateRootPath, templateName));\n\n\t\t// Input template name from user\n\t\tconst dstTemplateName = isRenameTemplate\n\t\t\t? await vscode.window.showInputBox({\n\t\t\t\tprompt: \"Input a template name\",\n\t\t\t\tvalue: templateName\n\t\t\t})\n\t\t\t: templateName;\n\n\t\tconst dstPath = path.resolve(workingPathDir, dstTemplateName);\n\t\tconsole.log(\"dst path: \" + path.resolve(workingPathDir, dstTemplateName));\n\n\n\t\tawait fs.copy(srcPath, dstPath);\n\t\treplaceTextInFiles(\n\t\t\tdstPath,\n\t\t\tdstTemplateName,\n\t\t\tconfig.replaceFileTextFn,\n\t\t\tconfig.replaceFileNameFn\n\t\t);\n\t\tvscode.window.showInformationMessage(\"Template: copied!\");\n\t} catch (e) {\n\t\tconsole.error(e.stack);\n\t\tvscode.window.showErrorMessage(e.message);\n\t}\n}", "title": "" }, { "docid": "0739311fef37a326a3f92c7b5ec050a8", "score": "0.573019", "text": "_doActionWithTemplateCreation(action) {\n const {projectName, history} = this.props;\n\n return this.save()\n .then(() => action())\n .then(templateFilePath =>\n history.pushState(null, `/templates/editor/${projectName}/${templateFilePath}`));\n }", "title": "" }, { "docid": "e9cafadd598ba8a61343a48ac9e82c4e", "score": "0.57203025", "text": "update({projectName, templateFilePath, request, reply}) {\n const template = this._templateFromTemplatePathAndRequest(templateFilePath, request);\n reply(this.templateService.update({ projectName, template }));\n }", "title": "" }, { "docid": "77700508e18f23c232438ac23e70ded6", "score": "0.57178515", "text": "function apply_templateIndi(id, template1, template2, dataO, dataU) {\n let target = document.getElementById(id);\n let templateA = Handlebars.compile(document.getElementById(template1).textContent);\n target.innerHTML = templateA(dataU);\n let templateB = Handlebars.compile(document.getElementById(template2).textContent);\n target.innerHTML += templateB(dataO);\n\n}", "title": "" }, { "docid": "8a26e89d043b02cf5bd5357cd009418e", "score": "0.5715677", "text": "function insertNodeIntoTemplate(template, node) {\n var refNode = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;\n var content = template.element.content,\n parts = template.parts; // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n\n var walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n var partIndex = nextActiveIndexInTemplateParts(parts);\n var insertCount = 0;\n var walkerIndex = -1;\n\n while (walker.nextNode()) {\n walkerIndex++;\n var walkerNode = walker.currentNode;\n\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n\n return;\n }\n\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}", "title": "" }, { "docid": "90e506631ef179bb5e7bc8183a2d6b2c", "score": "0.5704636", "text": "function injectTemplateRef() {\n return createTemplateRef(getCurrentTNode(), getLView());\n}", "title": "" }, { "docid": "90e506631ef179bb5e7bc8183a2d6b2c", "score": "0.5704636", "text": "function injectTemplateRef() {\n return createTemplateRef(getCurrentTNode(), getLView());\n}", "title": "" }, { "docid": "90e506631ef179bb5e7bc8183a2d6b2c", "score": "0.5704636", "text": "function injectTemplateRef() {\n return createTemplateRef(getCurrentTNode(), getLView());\n}", "title": "" }, { "docid": "90e506631ef179bb5e7bc8183a2d6b2c", "score": "0.5704636", "text": "function injectTemplateRef() {\n return createTemplateRef(getCurrentTNode(), getLView());\n}", "title": "" }, { "docid": "d5c57178f869eacf78a6e15a0284cd0d", "score": "0.57044756", "text": "template() { // this is where our template markup will go.\n return null;\n }", "title": "" }, { "docid": "522ca9fbebc8bb2cd7f1d487ccc2f695", "score": "0.5698509", "text": "function upgradeTemplate(template, constructor) { newInstance = template; Object.setPrototypeOf(template, constructor.prototype); new constructor(); newInstance = null; }", "title": "" }, { "docid": "536e0bc02030a1d76e8a9b56cf89e8da", "score": "0.5691552", "text": "_findTemplate(header, footer, editor) {\n const template = this._selectFirstTemplate(header, footer, editor);\n if (template) {\n if (this.dataHost) {\n // set dataHost to the context where template has been defined\n template._rootDataHost = this.dataHost._rootDataHost || this.dataHost;\n }\n }\n return template;\n }", "title": "" }, { "docid": "c31ead5fd187a99ff4f049baaf6663b4", "score": "0.5686834", "text": "function insertNodeIntoTemplate(template, node, refNode = null) {\n const { element: { content }, parts } = template;\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n return;\n }\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n }", "title": "" }, { "docid": "80bf2611f542d2eca52358f5236e675f", "score": "0.56735337", "text": "function templatePicker(template) {\r\n switch (template) {\r\n case 'template-1':\r\n qlEditor.parentNode.classList.remove('template-2', 'template-3');\r\n qlEditor.parentNode.classList.add('template-1');\r\n break;\r\n case 'template-2':\r\n qlEditor.parentNode.classList.remove('template-1', 'template-3');\r\n qlEditor.parentNode.classList.add('template-2');\r\n break;\r\n case 'template-3':\r\n qlEditor.parentNode.classList.remove('template-1', 'template-2');\r\n qlEditor.parentNode.classList.add('template-3');\r\n break;\r\n default:\r\n qlEditor.parentNode.classList.remove('template-1', 'template-2', 'template-3');\r\n break;\r\n }\r\n}", "title": "" }, { "docid": "46f4d27ea40fd16dcdd1ad2076587b4d", "score": "0.56655335", "text": "function registerTemplate(name, template, dir) {\n cache[name] = function (context, cb) {\n if (/\\.html$/.test(template)){\n dir = dir || '.';\n template = fs.readFileSync(path.join(dir, template), 'utf8');\n }\n\n cb(null, template);\n };\n}", "title": "" }, { "docid": "57c6b608148161cf7e0b6beb2fab7a3e", "score": "0.56639975", "text": "function loadTemplate(jQuerySelector, templateId, context) {\n let template = templateCache[templateId];\n if (template === undefined) {\n //console.log(\"Compile template \" + templateId);\n let source = $('#' + templateId).html();\n template = Handlebars.compile(source);\n templateCache[templateId] = template;\n Handlebars.registerPartial(templateId, template);\n }\n if (jQuerySelector !== \"\") {\n //console.log(\"Updating template \" + templateId);\n var html = template(context);\n $(jQuerySelector).html(html);\n }\n }", "title": "" }, { "docid": "00d86a10abf7e7869f4f22d45dfe1417", "score": "0.56512606", "text": "function apply_template(id, templateid, data) {\n\n let target = document.getElementById(id);\n let template = Handlebars.compile(document.getElementById(templateid).textContent);\n target.innerHTML = template(data);\n \n\n\n\n}", "title": "" }, { "docid": "0e5a07233542144b49fd2b1da9f15f9e", "score": "0.56410545", "text": "function overwriteTemplateFile(templatePath, scope) {\n templatePath = resolveTemplatePath(templatePath);\n var view = renderTemplateFile(templatePath, scope);\n\n return Fs.writeFileSync(templatePath, view);\n}", "title": "" }, { "docid": "b9efe638d141789e47ab41a4f938eae7", "score": "0.56330913", "text": "afterReadTemplates(templateRefs) {\n const index = templateRefs['_results'].length - 1;\n const lastTemplate = templateRefs['_results'][index];\n if (!lastTemplate || !this.lastTemplateName)\n return;\n const matched = this.applyReferences(lastTemplate._def.references, lastTemplate);\n if (!matched) {\n this.templates[this.lastTemplateName] = lastTemplate;\n }\n }", "title": "" }, { "docid": "4ccd9970941804a417a9e43df74aab6a", "score": "0.5616264", "text": "function saveTemplate() {\n if (tempName) {\n firebase\n .firestore()\n .collection(`users/${auth.auth.uid}/templates/`)\n .doc(tempName)\n .set(emailContent);\n } else {\n console.log('template needs a name!');\n }\n }", "title": "" }, { "docid": "e58faa9ef3d6f273b7fcb0210e3aecbb", "score": "0.56153077", "text": "function compileEditNoteTemplate(){\n var editNoteSource = $(\"#editNoteTemplate\").html();\n if ( editNoteSource !== undefined ) {\n editNoteTemplate = Handlebars.compile(editNoteSource); \n }\n}", "title": "" }, { "docid": "faabac795b6257461d45af0d8c38deae", "score": "0.5608153", "text": "function insertNodeIntoTemplate(template, node, refNode = null) {\n const { element: { content }, parts } = template;\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n return;\n }\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}", "title": "" }, { "docid": "faabac795b6257461d45af0d8c38deae", "score": "0.5608153", "text": "function insertNodeIntoTemplate(template, node, refNode = null) {\n const { element: { content }, parts } = template;\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n return;\n }\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}", "title": "" }, { "docid": "faabac795b6257461d45af0d8c38deae", "score": "0.5608153", "text": "function insertNodeIntoTemplate(template, node, refNode = null) {\n const { element: { content }, parts } = template;\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n return;\n }\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}", "title": "" }, { "docid": "ff0fca2e36b29d81cedcf01721510bd6", "score": "0.560576", "text": "function insertNodeIntoTemplate(template, node, refNode = null) {\n const { element: { content }, parts } = template;\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n if (walkerNode === refNode) {\n refNode.parentNode.insertBefore(node, refNode);\n insertCount = countNodes(node);\n }\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n return;\n }\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}", "title": "" }, { "docid": "461b9d7dbf0b17372af0e0a182aeb617", "score": "0.55974615", "text": "function InsertTemplate($container) {\n $container.find('.js-insert-template:not(.js-insert-loaded)').each(function(){\n var $this = $(this); \n var template = $this.data('insert-template');\n var type = $this.data('insert-type');\n if ($.inArray(type, ['html','text','append','prepend']) === -1) {\n type = 'append';\n }\n \n // list of params are passed via data-insert-parameters=\"name,1,2\"\n var parameters_data = '' + $this.data('insert-parameters');\n var parameters_list = parameters_data.split(',');\n var parameters_hash = {};\n var parameters_str = '';\n var i;\n \n // get all parameters value into a hash { param_name => param_value }\n for (i = 0; i < parameters_list.length; i++) {\n var name = parameters_list[i];\n var value = $this.data('insert-parameter-' + name);\n if (typeof value !== 'undefined') {\n parameters_hash[name] = value;\n } else {\n console.error('InsertTemplate: parameter ' + name + ' not found');\n }\n \n }\n // convert all unnamed params into string\n i = 1;\n while(typeof parameters_hash[i] !== 'undefined') {\n parameters_str += '|' + parameters_hash[i];\n delete parameters_hash[i];\n i++;\n }\n // convert all named params into string\n for (var prop in parameters_hash) {\n if( parameters_hash.hasOwnProperty( prop ) ) {\n parameters_str += '|' + prop + '=' + parameters_hash[prop];\n } \n }\n \n // retrieve template for insertion\n $.getJSON('/api.php?format=json&action=parse&text={'+'{'+template+parameters_str+'}}', function(data) {\n var html = data.parse.text['*'];\n $this[type](html);\n $this.find('.js-collapsible-collapsed').hide();\n $this.addClass('js-insert-loaded');\n });\n });\n}", "title": "" }, { "docid": "d80b590cc6f90619155a509e585fc935", "score": "0.55971146", "text": "function insertNodeIntoTemplate(template, node, refNode = null) {\n const {\n element: {\n content\n },\n parts\n } = template; // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n\n if (refNode === null || refNode === undefined) {\n content.appendChild(node);\n return;\n }\n\n const walker = document.createTreeWalker(content, walkerNodeFilter, null, false);\n let partIndex = nextActiveIndexInTemplateParts(parts);\n let insertCount = 0;\n let walkerIndex = -1;\n\n while (walker.nextNode()) {\n walkerIndex++;\n const walkerNode = walker.currentNode;\n\n if (walkerNode === refNode) {\n insertCount = countNodes(node);\n refNode.parentNode.insertBefore(node, refNode);\n }\n\n while (partIndex !== -1 && parts[partIndex].index === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n parts[partIndex].index += insertCount;\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n\n return;\n }\n\n partIndex = nextActiveIndexInTemplateParts(parts, partIndex);\n }\n }\n}", "title": "" }, { "docid": "bfb6a5122811cd01613ca59affd497fc", "score": "0.5592817", "text": "function haalTemplateOp(template) {\n // --- if the template already is in our app cache return it. //\n if (fetchPromises[template]){\n return fetchPromises[template];\n }\n // --- If not get the template from templatecache or http. //\n return (fetchPromises[template] = $q.when($templateCache.get(template) || $http.get(template))\n .then(function (res) {\n // --- When the template is retrieved return it. //\n if (angular.isObject(res)) {\n $templateCache.put(template, res.data);\n return res.data;\n }\n return res;\n }));\n }", "title": "" }, { "docid": "ed1002d968074bbe0c6a40de94dd68dc", "score": "0.5592154", "text": "function _createTemplateFromPage()\n {\n $.PercBlockUI();\n if ($(\".perc-dropdown-option-CreateTemplatefromPage\").hasClass('perc-drop-disabled')) {\n $.unblockUI();\n return;\n } \n var pageId = $(\".perc-imported-page-selected\").attr(\"id\");\n if(!pageId)\n {\n $.perc_utils.alert_dialog({title:I18N.message(\"perc.ui.page.general@Warning\"),content:I18N.message(\"perc.ui.template.design.view@Select Imported Page\")});\n $.unblockUI();\n }\n else\n {\n $.PercWorkflowController().checkOut(\"percPage\", pageId, function(status)\n {\n if(status)//Workflow controller presents the appropriate error message to the user if fails to check out.\n {\n $.PercTemplateService().createTemplateFromPage(pageId, $.PercNavigationManager.getSiteName(), function(status, data){\n if(!status)\n {\n $.perc_utils.alert_dialog({title:I18N.message(\"perc.ui.publish.title@Error\"),content:data.errorMessage});\n }\n else\n {\n var percJump = $(\".perc-unassigned-panel .perc-template-pages-controls .perc-jump\");\n requestUnassignedPages(parseInt(percJump.val()));\n \n if (data.name !== undefined && data.name !== '')\n {\n _cleanMementoView();\n // Invoke the jQuery widget method refresh passing the (optional) template\n // name to fouse is after refreshing the panel\n //This works, but it is seriously cheesy.\n $.cookie(\"templateImport\", data.name);\n $.PercBlockUI();\n location.reload();\n //$(\"#perc-assigned-templates\").template_selected('refresh', data.name);\n }\n }\n });\n } \n }); \n }\n }", "title": "" }, { "docid": "d84a2b888e8e4f28e38931e51860eec1", "score": "0.5579558", "text": "function addMovieTemplate(movieData){\n\n if($(\"#movieTemplate\").length > 0){\n var template = window.templates['public/templates/createmovie']\n ,result = template(movieData);\n $(\"#movieStream\").prepend(result);\n }\n}", "title": "" }, { "docid": "0cab0943f6b8bea893e21251163be2be", "score": "0.55703276", "text": "static set template(template) {\n\t\t// Set the template on the class `template` property.\n\t\tthis.constructor.template = template;\n\t}", "title": "" }, { "docid": "3359ea7896ce4039328d2af0fb0f6cd7", "score": "0.55642956", "text": "_copyHtmlTemplate(type) {\n switch(type) {\n case 'bare':\n this._copyHtmlTemplate_bare();\n break;\n case 'clean':\n this._copyHtmlTemplate_clean();\n break;\n case 'full':\n this._copyHtmlTemplate_full();\n break;\n default:\n console.log('Clean Slate: No HTML template option was selected. No HTML templates were moved into the desired directory.');\n break;\n }\n }", "title": "" }, { "docid": "10982f2a27471b92817a3c4ae35f91b3", "score": "0.5562129", "text": "function template(index, templateFn, consts, vars, tagName, attrs, localRefs, localRefExtractor) {\n // TODO: consider a separate node type for templates\n var tNode = containerInternal(index, tagName || null, attrs || null);\n if (firstTemplatePass) {\n tNode.tViews = createTView(-1, templateFn, consts, vars, tView.directiveRegistry, tView.pipeRegistry, null);\n }\n createDirectivesAndLocals(localRefs, localRefExtractor);\n currentQueries &&\n (currentQueries = currentQueries.addNode(previousOrParentTNode));\n queueLifecycleHooks(tNode.flags, tView);\n isParent = false;\n}", "title": "" }, { "docid": "e37bbd45d959d0e014eaaed11b908a84", "score": "0.55612713", "text": "loadTemplate(template) {\n var me = this;\n $(template).each(function() {\n var element = this;\n if (element.type == 'text') {\n me.addText(element.x,\n element.y,\n element.text,\n element.hyperlink,\n element.fontface,\n element.fontsize);\n } else if (element.type == 'image') {\n me.addImage(element.x,\n element.y,\n element.width,\n element.height,\n element.source,\n element.hyperlink);\n } else {\n throw new Error('Unknown template element type ' \n + element.type);\n }\n });\n }", "title": "" }, { "docid": "b09672c08bdebece475ed734ee3169c2", "score": "0.55511814", "text": "async function addTemplate(id, container, options = {}) {\r\n\tlet template = document.querySelector(`template#${id}`);\r\n\tif (!template) {\r\n\t\tthrow Error(\"Template not found\");\r\n\t}\r\n\t// Clone is the document fragment of the template\r\n\tlet clone = document.importNode(template.content, true);\r\n\r\n\tif (template.dataset.type) {\r\n\t\tawait type(clone.textContent, options, container);\r\n\t} else {\r\n\t\tcontainer.appendChild(clone);\r\n\t}\r\n\r\n\t// We cannot return clone here\r\n\t// https://stackoverflow.com/questions/27945721/how-to-clone-and-modify-from-html5-template-tag\r\n\treturn container.childNodes;\r\n}", "title": "" }, { "docid": "0020bf647e7bbbb4f40562cac5216169", "score": "0.55510396", "text": "function resetLastDeviceTemplateEdit() {\n //Check if lastId is present\n if(!lastDeviceTemplateId) { return false; }\n\n //Revert Changes\n document.getElementById(\"devicetpl_name_\"+lastDeviceTemplateId).innerHTML = lastDeviceTemplateName;\n document.getElementById(\"devicetpl_description_\"+lastDeviceTemplateId).innerHTML = lastDeviceTemplateDescription;\n document.getElementById(\"devicetpl_allow_quickadd_\"+lastDeviceTemplateId).innerHTML = lastDeviceTemplateAllowQuickadd;\n document.getElementById(\"devicetpl_navi_\"+lastDeviceTemplateId).innerHTML = lastDeviceTemplateNavi;\n\n return true;\n}", "title": "" }, { "docid": "2ebbe1f70201c6e1e6fae0df98dfcb91", "score": "0.5549741", "text": "function addTemplate(){ \n var solId = $(\"#solId\").val();\n\tvar templateId = $(\"#templateId\").val();\t\n\tvar templatetype = $(\"#templatetype\").val();\t\n\tvar resourcePackage = localStorage.getItem('data'); // getting realm from web storage (local storage)\n\tconsole.log(\"inside add template function.... \");\n\t\n\tvar body = \"<?xml version=\\\"1.0\\\"?>\"+\n\t\t\t\"<template>\"+\n\t\t\t\"<templateid>\"+templateId+\"</templateid>\"+\n\t\t\t\"<templatetype>\"+templatetype+\"</templatetype>\"+\n\t\t\t\"<solutionid>\"+solId+\"</solutionid>\"+\n\t\t\t\"<isdefault>YES</isdefault>\"+\n\t\t\t\"<resourcepackage>\"+resourcePackage+\"</resourcepackage>\"+\n\t\t\t\"</template>\"; \n\t$.ajax({\n\t type: \"POST\",\n\t url: 'http://'+backendAddr+'/OP-BackEnd-Gateway/opgateway/addTemplate/'+realm+'/'+solId,\n\t contentType:'text/xml',\n\t crossDomain: true,\n\t processData: false,\n\t data: body,\n\t headers: {\n\t\t 'Authorization': 'Bearer '+token\n\t\t }, \n\t}).done(function(res) {\n\t\tconsole.log(\"add template response.... \" +res);\n\t\talert(res);\n\t}).error(function() {\n\t\tconsole.log(\"add template failed.... \");\n\t}).complete(function() {\n\t\t console.log(\"add template completed.... \");\n\t});\t\n}", "title": "" }, { "docid": "b99e7650e5278de899a19e76688e9c59", "score": "0.5545007", "text": "function ImportTemplate(thisObj){\n try{\n function ImportTemplate_buildUI(thisObj){\n // info\n var scriptName = \"ImportTemplate\";\n var scriptVersion = \"v.03\";\n var appVer = app.version;\n \n function getScriptFolder(){ // function to find path to this script\n try { \n var activeScript = File(app.activeScript); \n } catch(e) { \n // running from ESTK ... \n var activeScript = File(e.fileName); \n } \n return activeScript.parent; \n } \n\n // preferences\n \n var defaultTemplateFileLocation =getScriptFolder().toString()+\"/defaultTemplate.aet\";\n \n if (! app.settings.haveSetting(scriptName, \"templateFile\")){app.settings.saveSetting(scriptName,\"templateFile\",defaultTemplateFileLocation);}\n \n \n // functions =================================================\n \n // generic function to merge one folder into another\n function mergeFolderContents(srcFolder, targetFolder)\n {\n var item;\n \n // Loop through srcFolder.items in reverse (so that any removal of folders doesn't mess up the looping)\n for (var i=srcFolder.numItems; i>=1; i--)\n {\n item = srcFolder.item(i);\n \n if (!(item instanceof FolderItem))\t\t\t// Move non-folder items to srcFolder\n item.parentFolder = targetFolder;\n else\t\t\t\t\t\t\t\t\t\t\t// For folders, check for matching named folder in targetFolder and merge if exists\n {\n // Look for first matching named subfolder in targetFolder\n matchingSubFolder = null;\n for (j=1; j<=targetFolder.numItems; j++)\n {\n targetSubItem = targetFolder.item(j);\n if ((targetSubItem instanceof FolderItem) && (targetSubItem.name === item.name))\n {\n matchingSubFolder = targetSubItem;\n break;\n }\n }\n \n // If found a matching subfolder, merge recursively, else merge up directly\n if (matchingSubFolder !== null)\n {\n // Merge subfolder recursively\n mergeFolderContents(item, matchingSubFolder);\n \n // Remove folder (which should be empty, but just checking)\n if (item.numItems === 0)\n item.remove();\n }\n else\n item.parentFolder = targetFolder;\n }\n }\n }\n \n // function to update template file location\n function changeTemplate() {\n var templateFile = File.openDialog(\"Choose a template file\",\"After Effects Template:*.aet;*.aep,All files:*\", false);\n if ((templateFile != null) && templateFile.exists)\n {\n templateFile = templateFile;\n\n // Remember the template for the next session\n app.settings.saveSetting(scriptName,\"templateFile\", templateFile.absoluteURI);\n return true;\n } else {\n return false;\n }\n }\n \n // function to actually import template file set in preferences\n function importTemplate() {\n \n try {\n var masterFolder = app.project.importFile(new ImportOptions(File(app.settings.getSetting(scriptName, \"templateFile\"))));\n app.beginUndoGroup(\"Import template file\");\n }\n catch(e)\n {\n alert(\"Template file does not exist. Please use the \\\"...\\\" button to choose a template file.\");\n var templateChosen = changeTemplate();\n if (templateChosen) importTemplate();\n return;\n }\n mergeFolderContents(masterFolder,app.project.rootFolder);\n masterFolder.remove();\n\n app.endUndoGroup();\n }\n \n // end functions ==================================================\n \n // create window\n var myPanel = (thisObj instanceof Panel) ? thisObj : new Window(\"palette\", scriptName, undefined, {resizeable: true});\n \n // set up initial layout of panel groups\n res = \"group{orientation:'column', alignment:['fill','fill'],\\\n logoGroup: Group{alignment:['fill','top'],alignChildren:['left','bottom'],minimumSize:[100,12],\\\n scriptName: StaticText {preferredSize:[150,12]},\\\n },\\\n mainPanel: Panel{type:'panel',alignment:['fill','fill'],\\\n templateButtonGroup: Group{orientation:'row', alignment:['left','top'],alignChildren:['left','bottom'],spacing:3,\\\n templateButton: Button {preferredSize:[150,-1]},\\\n changeTemplateButton: Button {preferredSize:[18,18]},\\\n },\\\n },\\\n }\";\n \n myPanel.grp = myPanel.add(res);\n\n //Setup panel sizing\n myPanel.layout.layout(true);\n myPanel.grp.minimumSize = myPanel.grp.size;\n \n //Make panel resizeable\n myPanel.layout.resize();\n myPanel.onResizing = myPanel.onResize = function() {this.layout.resize()};\n\n //Version number and script name\n myPanel.grp.logoGroup.scriptName.text = scriptName+\" \"+scriptVersion;\n\n // tools setup\n var buttonPanel = myPanel.grp.mainPanel.templateButtonGroup;\n buttonPanel.spacing = 0;\n \n //Template Button settings\n buttonPanel.templateButton.text = \"Import Project Template\";\n buttonPanel.templateButton.helpTip= \"Click this button to import the contents of your template file\\rNote: This is not undoable\";\n buttonPanel.templateButton.onClick = importTemplate;\n \n //Change Template Location Button settings\n buttonPanel.changeTemplateButton.text = \"...\";\n buttonPanel.changeTemplateButton.helpTip= \"Click this button to change the location of your template file\";\n buttonPanel.changeTemplateButton.onClick = changeTemplate;\n \n buttonPanel.editspacing = 0;\n \n \n \n return myPanel;\n }\n \n var ImportTemplatePal = ImportTemplate_buildUI(thisObj);\n \n if((ImportTemplatePal != null) && (ImportTemplatePal instanceof Window)){\n ImportTemplatePal.center();\n ImportTemplatePal.show();\n }\n } catch (err) {\n alert(err.line+\"\\r\"+err.toString());\n }\n }", "title": "" }, { "docid": "3cdb3957941bcb63eb79cfd4542d8e8e", "score": "0.5544594", "text": "function _loadTemplate(target, template, data) {\n var template = document.getElementById(template).innerHTML;\n var target = document.getElementById(target);\n // target.classList.toggle('hide');\n\n Mustache.parse(template);\n\n var rendered = Mustache.render(template, data);\n target.innerHTML = rendered;\n }", "title": "" }, { "docid": "d5bc582e9b35faff4dc0b8c9452b1f0d", "score": "0.5543392", "text": "function onTemplateSaved() {\n setTitle();\n }", "title": "" }, { "docid": "1c57c090e446b15c33dff5d99cbd5ca4", "score": "0.5537591", "text": "function templater(template, data) {\n\t\t/** get the html */\n\t\tlet html = template.innerHTML;\n\n\t\t/** set the pattern for replacement */\n\t\tconst re = /{{\\s?([\\w\\W]*?)\\s?}}/gmi;\n\n\t\t/** cycle over matches */\n\t\tlet match;\n\t\twhile ((match = re.exec(html)) !== null) {\n\t\t\t/** catch exceptions */\n\t\t\ttry {\n\t\t\t\t/** replace the values in the html and reset the lastIndex of the regex */\n\t\t\t\thtml = html.replace(match[0], using(data, match[1]));\n\t\t\t\tre.lastIndex = 0;\n\t\t\t} catch (ex) {\n\t\t\t\tconsole.log(ex);\n\t\t\t}\n\t\t}\n\n\t\t/** reset the innerHTML */\n\t\ttemplate.innerHTML = html;\n\t}", "title": "" }, { "docid": "cfb813fc6741112322e65de7f9efdd73", "score": "0.5523769", "text": "function HashTemplate(templateData){\n\n }", "title": "" }, { "docid": "2894c75d68f19d7519b3bd9d62948e18", "score": "0.55204153", "text": "processTemplates(oc) {}", "title": "" }, { "docid": "2894c75d68f19d7519b3bd9d62948e18", "score": "0.55204153", "text": "processTemplates(oc) {}", "title": "" }, { "docid": "dec406cc7c3773f619e247de4baab497", "score": "0.5520407", "text": "function insertNodeIntoTemplate(template, node, refNode) {\n return __hook__((template, node, refNode = null) => {\n const {\n element: {content},\n parts\n } = __hook__('#*', template, [], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]);\n // If there's no refNode, then put node at end of template.\n // No part indices need to be shifted in this case.\n if (refNode === null || refNode === $hook$.global(__hook__, __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16], 'undefined', '#get')[__8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[17]]) {\n __hook__('#()', content, [\n 'appendChild',\n [node]\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]);\n return;\n }\n const walker = __hook__('#()', $hook$.global(__hook__, __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[18], 'document', '#get')[__8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[19]], [\n 'createTreeWalker',\n [\n content,\n walkerNodeFilter,\n null,\n false\n ]\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[18]);\n let partIndex = __hook__(nextActiveIndexInTemplateParts, null, [parts], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[20], 0);\n let insertCount = 0;\n let walkerIndex = -1;\n while (__hook__('#()', walker, [\n 'nextNode',\n []\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16])) {\n walkerIndex++;\n const walkerNode = __hook__('#.', walker, ['currentNode'], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[21]);\n if (walkerNode === refNode) {\n insertCount = __hook__(countNodes, null, [node], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16], 0);\n __hook__('#()', __hook__('#.', refNode, ['parentNode'], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]), [\n 'insertBefore',\n [\n node,\n refNode\n ]\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]);\n }\n while (partIndex !== -1 && __hook__('#.', __hook__('#.', parts, [partIndex], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]), ['index'], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]) === walkerIndex) {\n // If we've inserted the node, simply adjust all subsequent parts\n if (insertCount > 0) {\n while (partIndex !== -1) {\n __hook__('#+=', __hook__('#.', parts, [partIndex], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]), [\n 'index',\n insertCount\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]);\n partIndex = __hook__(nextActiveIndexInTemplateParts, null, [\n parts,\n partIndex\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16], 0);\n }\n return;\n }\n partIndex = __hook__(nextActiveIndexInTemplateParts, null, [\n parts,\n partIndex\n ], __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16], 0);\n }\n }\n }, null, arguments, __8f82a98aac99b1875fb5078520b682363a66a6272a90f29f287db756ef6e6d29__[16]);\n}", "title": "" }, { "docid": "8d68e577fecdf4c6c8c3a62126d5a4a3", "score": "0.5506431", "text": "function apply_template(targetid, templateid, data) {\n\n let target = document.getElementById(targetid);\n\n let template = Handlebars.compile(\n document.getElementById(templateid).textContent\n )\n target.innerHTML = template(data);\n}", "title": "" }, { "docid": "580380c0feb3cf7381872070b18b6ec6", "score": "0.55059695", "text": "set templateCache (cache){\n defaultWriter.templateCache = cache;\n }", "title": "" }, { "docid": "36246cce87022048097edee55716b2ce", "score": "0.5491198", "text": "function prepareTemplates () {\n const templates = [\n 'clients/full-form'\n ]\n for (const t of templates) {\n Server.templates.get(t)\n .then(\n (t) => {\n document.getElementsByTagName('head')[0]\n .insertAdjacentHTML('beforeend', t)\n }\n )\n }\n}", "title": "" }, { "docid": "001adab6b859441878746875a383591f", "score": "0.548535", "text": "copyTemplateFor(templateFor, template) {\n const configuredDirectory = this.getDirectoryFor(templateFor);\n if (!configuredDirectory) {\n return;\n }\n if (!template.src || !template.dest) {\n throw new Error('src and dest are required when copying templates');\n }\n const sourcePath = path_1.join(this.templatesSourceDir, template.src);\n const destinationPath = path_1.normalize(`${configuredDirectory}/${template.dest}`);\n const renderer = template.mustache\n ? new Mustache_1.MustacheFile(this.projectRoot, destinationPath, sourcePath)\n : new TemplateLiteral_1.TemplateLiteralFile(this.projectRoot, destinationPath, sourcePath);\n const hasFile = renderer.exists();\n renderer.apply(template.data);\n renderer.commit();\n if (hasFile) {\n logger_1.logger.skip(destinationPath);\n }\n else {\n logger_1.logger.create(destinationPath);\n }\n }", "title": "" }, { "docid": "e65edfef899f27fa055057f93cc8f052", "score": "0.54813313", "text": "function registerTemplate(id, text) {\n templates[id] = text;\n return id;\n }", "title": "" }, { "docid": "f27e1cd4154fcfa3067b883294a5ac5b", "score": "0.5481153", "text": "move({projectName, templateFilePath, request, reply}) {\n const {newName} = request.query;\n const [templateName, templateEngine] = this._templateNameAndEngineFromPath(templateFilePath);\n\n reply(this.templateService.move({projectName, templateName, templateEngine, newName}));\n }", "title": "" }, { "docid": "888721149b1cc50c9445f83faa263005", "score": "0.5480439", "text": "function spb_templateSystem() {\n jQuery( '#spb_save_template' ).live(\n \"click\", function( e ) {\n e.preventDefault();\n\n\n var template_name = prompt( \"Please enter a name to save the template as.\", '' );\n if ( template_name != null && template_name != \"\" ) {\n var template = generateShortcodesFromHtml( jQuery( \".spb_main_sortable\" ) );\n\n removeClassProcessedElements();\n var data = {\n action: 'spb_save_template',\n template: template,\n template_name: template_name\n };\n\n jQuery.post(\n ajaxurl, data, function( response ) {\n jQuery( '.spb_templates_ul' ).html( response );\n }\n );\n } else {\n alert( \"There has been an error. Please try again.\" );\n }\n }\n );\n\n jQuery( '.sf_prebuilt_template a' ).live(\n \"click\", function( e ) {\n e.preventDefault();\n\n var data = {\n action: 'sf_load_template',\n template_id: jQuery( this ).attr( 'data-template_id' )\n };\n\n jQuery.post(\n ajaxurl, data, function( response ) {\n jQuery( '.spb_main_sortable' ).append( response ).find( \".spb_init_callback\" ).each(\n function( index ) {\n var fn = window[jQuery( this ).attr( \"value\" )];\n if ( typeof fn === 'function' ) {\n fn( jQuery( this ).closest( '.spb_content_element' ) );\n }\n }\n );\n\n initDroppable();\n save_spb_html();\n }\n );\n\n jQuery( '.spb-item-slideout' ).slideUp( 400 );\n jQuery( '.spb-prebuilt-pages-fullscreen' ).slideUp( 400 );\n jQuery( '.spb_prebuilt_pages' ).removeClass( 'selected' );\n jQuery( '.spb_prebuilt_pages' ).removeClass( 'open' );\n jQuery( '.spb-prebuilt-pages-fullscreen' ).removeClass( 'selected' );\n jQuery( '.spb-prebuilt-pages-fullscreen' ).removeClass( 'open' );\n jQuery( '.spb-item-slideout' ).removeClass( 'open' );\n jQuery( '.spb-item-slideout' ).removeClass( 'selected' );\n\n\n }\n );\n\n jQuery( '.spb_template_li a' ).live(\n \"click\", function( e ) {\n e.preventDefault();\n var data = {\n action: 'spb_load_template',\n template_id: jQuery( this ).attr( 'data-template_id' )\n };\n\n jQuery.post(\n ajaxurl, data, function( response ) {\n jQuery( '.spb_main_sortable' ).append( response ).find( \".spb_init_callback\" ).each(\n function( index ) {\n var fn = window[jQuery( this ).attr( \"value\" )];\n if ( typeof fn === 'function' ) {\n fn( jQuery( this ).closest( '.spb_content_element' ) );\n }\n }\n );\n //\n initDroppable();\n save_spb_html();\n }\n );\n\n jQuery( this ).parents( '.custom-templates-nav' ).find( '.dropdown' ).removeClass( 'open' );\n }\n );\n\n jQuery( '.spb_remove_template' ).live(\n \"click\", function( e ) {\n e.preventDefault();\n var template_name = jQuery( this ).closest( '.spb_template_li' ).find( 'a' ).text();\n var answer = confirm( \"Confirm deletion of '\" + template_name + \"' template, or press Cancel to leave. This action cannot be undone.\" );\n if ( answer ) {\n\n var data = {\n action: 'spb_delete_template',\n template_id: jQuery( this ).closest( '.spb_template_li' ).find( 'a' ).attr( 'data-template_id' )\n };\n\n jQuery.post(\n ajaxurl, data, function( response ) {\n jQuery( '.spb_templates_ul' ).html( response );\n }\n );\n }\n }\n );\n}", "title": "" }, { "docid": "5cac388bae883aa0a0197adbace864cb", "score": "0.54803693", "text": "visitTemplate(template) { }", "title": "" }, { "docid": "c749eac645f5ad3b31afe9980e54cbc8", "score": "0.54768574", "text": "function populateTemplate(tmppdf, dirtemplate, matcherObj, idl, p) {\n var base_file = fs.readFileSync(dirtemplate, {\n encoding: 'utf8',\n flag: 'r+',\n });\n base_file = multiReplace(base_file, matcherObj);\n fs.writeFileSync(tmppdf + idl + 'page' + p + '.html', base_file);\n}", "title": "" }, { "docid": "a3b758b8161e3bf0aa59394e110824fd", "score": "0.5473174", "text": "function addSelectedTemplate(idx)\n{\n // alert('Selected index ' + idx);\n data={};\n data.command = \"addItemToRundown\";\n data.foldername = document.getElementById('foldername').value;\n data.listname = document.getElementById('filebasename').value;\n data.datafile = document.getElementById('datafile').value;\n data.templateindex = idx;\n post('', data, 'post');\n}", "title": "" }, { "docid": "23f6411a1841d64b140222044b3e8905", "score": "0.54721177", "text": "function appendTpl(tpl, data, target){\n\t\tvar source = tpl.html();\n\t\tvar template = Handlebars.compile(source);\n\t\tvar html = template(data);\n\t\ttarget.html(html);\n\t}", "title": "" }, { "docid": "23f6411a1841d64b140222044b3e8905", "score": "0.54721177", "text": "function appendTpl(tpl, data, target){\n\t\tvar source = tpl.html();\n\t\tvar template = Handlebars.compile(source);\n\t\tvar html = template(data);\n\t\ttarget.html(html);\n\t}", "title": "" }, { "docid": "ec23d56b67bfc8ce2fa2afe3e5821b5f", "score": "0.5466447", "text": "function template(index, templateFn, consts, vars, tagName, attrs, localRefs, localRefExtractor) {\n var lView = getLView();\n var tView = lView[TVIEW];\n // TODO: consider a separate node type for templates\n var tNode = containerInternal(index, tagName || null, attrs || null);\n if (getFirstTemplatePass()) {\n tNode.tViews = createTView(-1, templateFn, consts, vars, tView.directiveRegistry, tView.pipeRegistry, null);\n }\n createDirectivesAndLocals(tView, lView, localRefs, localRefExtractor);\n var currentQueries = lView[QUERIES];\n var previousOrParentTNode = getPreviousOrParentTNode();\n var native = getNativeByTNode(previousOrParentTNode, lView);\n attachPatchData(native, lView);\n if (currentQueries) {\n lView[QUERIES] = currentQueries.addNode(previousOrParentTNode);\n }\n queueLifecycleHooks(tView, tNode);\n setIsParent(false);\n}", "title": "" }, { "docid": "ec23d56b67bfc8ce2fa2afe3e5821b5f", "score": "0.5466447", "text": "function template(index, templateFn, consts, vars, tagName, attrs, localRefs, localRefExtractor) {\n var lView = getLView();\n var tView = lView[TVIEW];\n // TODO: consider a separate node type for templates\n var tNode = containerInternal(index, tagName || null, attrs || null);\n if (getFirstTemplatePass()) {\n tNode.tViews = createTView(-1, templateFn, consts, vars, tView.directiveRegistry, tView.pipeRegistry, null);\n }\n createDirectivesAndLocals(tView, lView, localRefs, localRefExtractor);\n var currentQueries = lView[QUERIES];\n var previousOrParentTNode = getPreviousOrParentTNode();\n var native = getNativeByTNode(previousOrParentTNode, lView);\n attachPatchData(native, lView);\n if (currentQueries) {\n lView[QUERIES] = currentQueries.addNode(previousOrParentTNode);\n }\n queueLifecycleHooks(tView, tNode);\n setIsParent(false);\n}", "title": "" }, { "docid": "337662be5adb107530ac4dd4406ae4e1", "score": "0.5453074", "text": "remove() {\n if (this.template) {\n document.body.removeChild(this.template);\n this.template = null;\n this.loadingFailureMessage = null;\n }\n }", "title": "" } ]
be35a3472ad795cabd8e1bde153b6a41
C++11 raw string literal is "( anything )", where can be a string up to 16 characters long.
[ { "docid": "314acc3040f0c448b5b39543af1d5fa9", "score": "0.6625995", "text": "function tokenRawString(stream, state) {\n // Escape characters that have special regex meanings.\n var delim = state.cpp11RawStringDelim.replace(/[^\\w\\s]/g, '\\\\$&');\n var match = stream.match(new RegExp(\".*?\\\\)\" + delim + '\"'));\n if (match)\n state.tokenize = null;\n else\n stream.skipToEnd();\n return \"string\";\n }", "title": "" } ]
[ { "docid": "bc66e05611c2be996ec3ea4e6437aab3", "score": "0.7046308", "text": "function gobbleStringLiteral() {\n const quote = expr[index];\n index += 1;\n let closed = false;\n let string = '';\n while (index < length) {\n let char = expr[index++];\n if (char === quote) {\n closed = true;\n break;\n }\n string += char;\n }\n if (!closed)\n throwError(`Unclosed quote after \"${string}\"`);\n return { type: NODE_TYPE.Literal, value: string };\n }", "title": "" }, { "docid": "946f69e870fc5a13355c4223133d5b5f", "score": "0.67247117", "text": "function tokenRawString(stream, state) {\n // Escape characters that have special regex meanings.\n var delim = state.cpp11RawStringDelim.replace(/[^\\w\\s]/g, '\\\\$&');\n var match = stream.match(new RegExp(\".*?\\\\)\" + delim + '\"'));\n if (match) state.tokenize = null;else stream.skipToEnd();\n return \"string\";\n }", "title": "" }, { "docid": "994941834b5897eb73dc646dc8e5076a", "score": "0.6411276", "text": "function scanStringLiteral() {\n\t var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n\t quote = source[index];\n\t assert((quote === '\\'' || quote === '\"'),\n\t 'String literal must starts with a quote');\n\n\t start = index;\n\t ++index;\n\n\t while (index < length) {\n\t ch = source[index++];\n\n\t if (ch === quote) {\n\t quote = '';\n\t break;\n\t } else if (ch === '\\\\') {\n\t ch = source[index++];\n\t if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n\t switch (ch) {\n\t case 'u':\n\t case 'x':\n\t if (source[index] === '{') {\n\t ++index;\n\t str += scanUnicodeCodePointEscape();\n\t } else {\n\t unescaped = scanHexEscape(ch);\n\t if (!unescaped) {\n\t throw throwUnexpectedToken();\n\t }\n\t str += unescaped;\n\t }\n\t break;\n\t case 'n':\n\t str += '\\n';\n\t break;\n\t case 'r':\n\t str += '\\r';\n\t break;\n\t case 't':\n\t str += '\\t';\n\t break;\n\t case 'b':\n\t str += '\\b';\n\t break;\n\t case 'f':\n\t str += '\\f';\n\t break;\n\t case 'v':\n\t str += '\\x0B';\n\t break;\n\t case '8':\n\t case '9':\n\t str += ch;\n\t tolerateUnexpectedToken();\n\t break;\n\n\t default:\n\t if (isOctalDigit(ch)) {\n\t octToDec = octalToDecimal(ch);\n\n\t octal = octToDec.octal || octal;\n\t str += String.fromCharCode(octToDec.code);\n\t } else {\n\t str += ch;\n\t }\n\t break;\n\t }\n\t } else {\n\t ++lineNumber;\n\t if (ch === '\\r' && source[index] === '\\n') {\n\t ++index;\n\t }\n\t lineStart = index;\n\t }\n\t } else if (isLineTerminator(ch.charCodeAt(0))) {\n\t break;\n\t } else {\n\t str += ch;\n\t }\n\t }\n\n\t if (quote !== '') {\n\t index = start;\n\t throwUnexpectedToken();\n\t }\n\n\t return {\n\t type: Token.StringLiteral,\n\t value: str,\n\t octal: octal,\n\t lineNumber: startLineNumber,\n\t lineStart: startLineStart,\n\t start: start,\n\t end: index\n\t };\n\t }", "title": "" }, { "docid": "994941834b5897eb73dc646dc8e5076a", "score": "0.6411276", "text": "function scanStringLiteral() {\n\t var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n\t quote = source[index];\n\t assert((quote === '\\'' || quote === '\"'),\n\t 'String literal must starts with a quote');\n\n\t start = index;\n\t ++index;\n\n\t while (index < length) {\n\t ch = source[index++];\n\n\t if (ch === quote) {\n\t quote = '';\n\t break;\n\t } else if (ch === '\\\\') {\n\t ch = source[index++];\n\t if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n\t switch (ch) {\n\t case 'u':\n\t case 'x':\n\t if (source[index] === '{') {\n\t ++index;\n\t str += scanUnicodeCodePointEscape();\n\t } else {\n\t unescaped = scanHexEscape(ch);\n\t if (!unescaped) {\n\t throw throwUnexpectedToken();\n\t }\n\t str += unescaped;\n\t }\n\t break;\n\t case 'n':\n\t str += '\\n';\n\t break;\n\t case 'r':\n\t str += '\\r';\n\t break;\n\t case 't':\n\t str += '\\t';\n\t break;\n\t case 'b':\n\t str += '\\b';\n\t break;\n\t case 'f':\n\t str += '\\f';\n\t break;\n\t case 'v':\n\t str += '\\x0B';\n\t break;\n\t case '8':\n\t case '9':\n\t str += ch;\n\t tolerateUnexpectedToken();\n\t break;\n\n\t default:\n\t if (isOctalDigit(ch)) {\n\t octToDec = octalToDecimal(ch);\n\n\t octal = octToDec.octal || octal;\n\t str += String.fromCharCode(octToDec.code);\n\t } else {\n\t str += ch;\n\t }\n\t break;\n\t }\n\t } else {\n\t ++lineNumber;\n\t if (ch === '\\r' && source[index] === '\\n') {\n\t ++index;\n\t }\n\t lineStart = index;\n\t }\n\t } else if (isLineTerminator(ch.charCodeAt(0))) {\n\t break;\n\t } else {\n\t str += ch;\n\t }\n\t }\n\n\t if (quote !== '') {\n\t index = start;\n\t throwUnexpectedToken();\n\t }\n\n\t return {\n\t type: Token.StringLiteral,\n\t value: str,\n\t octal: octal,\n\t lineNumber: startLineNumber,\n\t lineStart: startLineStart,\n\t start: start,\n\t end: index\n\t };\n\t }", "title": "" }, { "docid": "1aece52f23e22499f2fbf9f073e9c0fd", "score": "0.63761324", "text": "function scanStringLiteral() {\n var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n quote = source[index];\n assert((quote === '\\'' || quote === '\"'),\n 'String literal must starts with a quote');\n\n start = index;\n ++index;\n\n while (index < length) {\n ch = source[index++];\n\n if (ch === quote) {\n quote = '';\n break;\n } else if (ch === '\\\\') {\n ch = source[index++];\n if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n switch (ch) {\n case 'u':\n case 'x':\n if (source[index] === '{') {\n ++index;\n str += scanUnicodeCodePointEscape();\n } else {\n unescaped = scanHexEscape(ch);\n if (!unescaped) {\n throw throwUnexpectedToken();\n }\n str += unescaped;\n }\n break;\n case 'n':\n str += '\\n';\n break;\n case 'r':\n str += '\\r';\n break;\n case 't':\n str += '\\t';\n break;\n case 'b':\n str += '\\b';\n break;\n case 'f':\n str += '\\f';\n break;\n case 'v':\n str += '\\x0B';\n break;\n case '8':\n case '9':\n str += ch;\n tolerateUnexpectedToken();\n break;\n\n default:\n if (isOctalDigit(ch)) {\n octToDec = octalToDecimal(ch);\n\n octal = octToDec.octal || octal;\n str += String.fromCharCode(octToDec.code);\n } else {\n str += ch;\n }\n break;\n }\n } else {\n ++lineNumber;\n if (ch === '\\r' && source[index] === '\\n') {\n ++index;\n }\n lineStart = index;\n }\n } else if (isLineTerminator(ch.charCodeAt(0))) {\n break;\n } else {\n str += ch;\n }\n }\n\n if (quote !== '') {\n index = start;\n throwUnexpectedToken();\n }\n\n return {\n type: Token.StringLiteral,\n value: str,\n octal: octal,\n lineNumber: startLineNumber,\n lineStart: startLineStart,\n start: start,\n end: index\n };\n }", "title": "" }, { "docid": "1aece52f23e22499f2fbf9f073e9c0fd", "score": "0.63761324", "text": "function scanStringLiteral() {\n var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n quote = source[index];\n assert((quote === '\\'' || quote === '\"'),\n 'String literal must starts with a quote');\n\n start = index;\n ++index;\n\n while (index < length) {\n ch = source[index++];\n\n if (ch === quote) {\n quote = '';\n break;\n } else if (ch === '\\\\') {\n ch = source[index++];\n if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n switch (ch) {\n case 'u':\n case 'x':\n if (source[index] === '{') {\n ++index;\n str += scanUnicodeCodePointEscape();\n } else {\n unescaped = scanHexEscape(ch);\n if (!unescaped) {\n throw throwUnexpectedToken();\n }\n str += unescaped;\n }\n break;\n case 'n':\n str += '\\n';\n break;\n case 'r':\n str += '\\r';\n break;\n case 't':\n str += '\\t';\n break;\n case 'b':\n str += '\\b';\n break;\n case 'f':\n str += '\\f';\n break;\n case 'v':\n str += '\\x0B';\n break;\n case '8':\n case '9':\n str += ch;\n tolerateUnexpectedToken();\n break;\n\n default:\n if (isOctalDigit(ch)) {\n octToDec = octalToDecimal(ch);\n\n octal = octToDec.octal || octal;\n str += String.fromCharCode(octToDec.code);\n } else {\n str += ch;\n }\n break;\n }\n } else {\n ++lineNumber;\n if (ch === '\\r' && source[index] === '\\n') {\n ++index;\n }\n lineStart = index;\n }\n } else if (isLineTerminator(ch.charCodeAt(0))) {\n break;\n } else {\n str += ch;\n }\n }\n\n if (quote !== '') {\n index = start;\n throwUnexpectedToken();\n }\n\n return {\n type: Token.StringLiteral,\n value: str,\n octal: octal,\n lineNumber: startLineNumber,\n lineStart: startLineStart,\n start: start,\n end: index\n };\n }", "title": "" }, { "docid": "1aece52f23e22499f2fbf9f073e9c0fd", "score": "0.63761324", "text": "function scanStringLiteral() {\n var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n quote = source[index];\n assert((quote === '\\'' || quote === '\"'),\n 'String literal must starts with a quote');\n\n start = index;\n ++index;\n\n while (index < length) {\n ch = source[index++];\n\n if (ch === quote) {\n quote = '';\n break;\n } else if (ch === '\\\\') {\n ch = source[index++];\n if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n switch (ch) {\n case 'u':\n case 'x':\n if (source[index] === '{') {\n ++index;\n str += scanUnicodeCodePointEscape();\n } else {\n unescaped = scanHexEscape(ch);\n if (!unescaped) {\n throw throwUnexpectedToken();\n }\n str += unescaped;\n }\n break;\n case 'n':\n str += '\\n';\n break;\n case 'r':\n str += '\\r';\n break;\n case 't':\n str += '\\t';\n break;\n case 'b':\n str += '\\b';\n break;\n case 'f':\n str += '\\f';\n break;\n case 'v':\n str += '\\x0B';\n break;\n case '8':\n case '9':\n str += ch;\n tolerateUnexpectedToken();\n break;\n\n default:\n if (isOctalDigit(ch)) {\n octToDec = octalToDecimal(ch);\n\n octal = octToDec.octal || octal;\n str += String.fromCharCode(octToDec.code);\n } else {\n str += ch;\n }\n break;\n }\n } else {\n ++lineNumber;\n if (ch === '\\r' && source[index] === '\\n') {\n ++index;\n }\n lineStart = index;\n }\n } else if (isLineTerminator(ch.charCodeAt(0))) {\n break;\n } else {\n str += ch;\n }\n }\n\n if (quote !== '') {\n index = start;\n throwUnexpectedToken();\n }\n\n return {\n type: Token.StringLiteral,\n value: str,\n octal: octal,\n lineNumber: startLineNumber,\n lineStart: startLineStart,\n start: start,\n end: index\n };\n }", "title": "" }, { "docid": "72762e3d6fe5dd4df2d4647a206ee0d6", "score": "0.6359832", "text": "function scanStringLiteral() {\n var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n quote = source[index];\n assert((quote === '\\'' || quote === '\"'),\n 'String literal must starts with a quote');\n\n start = index;\n ++index;\n\n while (index < length) {\n ch = source[index++];\n\n if (ch === quote) {\n quote = '';\n break;\n } else if (ch === '\\\\') {\n ch = source[index++];\n if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n switch (ch) {\n case 'u':\n case 'x':\n if (source[index] === '{') {\n ++index;\n str += scanUnicodeCodePointEscape();\n } else {\n unescaped = scanHexEscape(ch);\n if (!unescaped) {\n throw throwUnexpectedToken();\n }\n str += unescaped;\n }\n break;\n case 'n':\n str += '\\n';\n break;\n case 'r':\n str += '\\r';\n break;\n case 't':\n str += '\\t';\n break;\n case 'b':\n str += '\\b';\n break;\n case 'f':\n str += '\\f';\n break;\n case 'v':\n str += '\\x0B';\n break;\n case '8':\n case '9':\n str += ch;\n tolerateUnexpectedToken();\n break;\n\n default:\n if (isOctalDigit(ch)) {\n octToDec = octalToDecimal(ch);\n\n octal = octToDec.octal || octal;\n str += String.fromCharCode(octToDec.code);\n } else {\n str += ch;\n }\n break;\n }\n } else {\n ++lineNumber;\n if (ch === '\\r' && source[index] === '\\n') {\n ++index;\n }\n lineStart = index;\n }\n } else if (isLineTerminator(ch.charCodeAt(0))) {\n break;\n } else {\n str += ch;\n }\n }\n\n if (quote !== '') {\n throwUnexpectedToken();\n }\n\n return {\n type: Token.StringLiteral,\n value: str,\n octal: octal,\n lineNumber: startLineNumber,\n lineStart: startLineStart,\n start: start,\n end: index\n };\n }", "title": "" }, { "docid": "72762e3d6fe5dd4df2d4647a206ee0d6", "score": "0.6359832", "text": "function scanStringLiteral() {\n var str = '', quote, start, ch, unescaped, octToDec, octal = false;\n\n quote = source[index];\n assert((quote === '\\'' || quote === '\"'),\n 'String literal must starts with a quote');\n\n start = index;\n ++index;\n\n while (index < length) {\n ch = source[index++];\n\n if (ch === quote) {\n quote = '';\n break;\n } else if (ch === '\\\\') {\n ch = source[index++];\n if (!ch || !isLineTerminator(ch.charCodeAt(0))) {\n switch (ch) {\n case 'u':\n case 'x':\n if (source[index] === '{') {\n ++index;\n str += scanUnicodeCodePointEscape();\n } else {\n unescaped = scanHexEscape(ch);\n if (!unescaped) {\n throw throwUnexpectedToken();\n }\n str += unescaped;\n }\n break;\n case 'n':\n str += '\\n';\n break;\n case 'r':\n str += '\\r';\n break;\n case 't':\n str += '\\t';\n break;\n case 'b':\n str += '\\b';\n break;\n case 'f':\n str += '\\f';\n break;\n case 'v':\n str += '\\x0B';\n break;\n case '8':\n case '9':\n str += ch;\n tolerateUnexpectedToken();\n break;\n\n default:\n if (isOctalDigit(ch)) {\n octToDec = octalToDecimal(ch);\n\n octal = octToDec.octal || octal;\n str += String.fromCharCode(octToDec.code);\n } else {\n str += ch;\n }\n break;\n }\n } else {\n ++lineNumber;\n if (ch === '\\r' && source[index] === '\\n') {\n ++index;\n }\n lineStart = index;\n }\n } else if (isLineTerminator(ch.charCodeAt(0))) {\n break;\n } else {\n str += ch;\n }\n }\n\n if (quote !== '') {\n throwUnexpectedToken();\n }\n\n return {\n type: Token.StringLiteral,\n value: str,\n octal: octal,\n lineNumber: startLineNumber,\n lineStart: startLineStart,\n start: start,\n end: index\n };\n }", "title": "" }, { "docid": "25969ab66ad25359fa8e99beaa86ac8e", "score": "0.62851167", "text": "function _stringLiteral(val) {\n val = JSON.stringify(val);\n\n // escape illegal js but valid json unicode characters\n val = val.replace(/[\\u000A\\u000D\\u2028\\u2029]/g, function (c) {\n return \"\\\\u\" + (\"0000\" + c.charCodeAt(0).toString(16)).slice(-4);\n });\n\n if (this.format.quotes === \"single\") {\n // remove double quotes\n val = val.slice(1, -1);\n\n // unescape double quotes\n val = val.replace(/\\\\\"/g, '\"');\n\n // escape single quotes\n val = val.replace(/'/g, \"\\\\'\");\n\n // add single quotes\n val = \"'\" + val + \"'\";\n }\n\n return val;\n}", "title": "" }, { "docid": "42138923a8fba08a660724fa1b11d805", "score": "0.6283456", "text": "function createSingleQuoteStringLiteral(text) {\n const stringLiteral = ts.createLiteral(text);\n // tslint:disable-next-line:no-any accessing TS internal API.\n stringLiteral.singleQuote = true;\n return stringLiteral;\n }", "title": "" }, { "docid": "e9cd80f3e8cfdb8574588fa9aaa83460", "score": "0.6275648", "text": "function escape_r_literal_string(s) {\n return (s == null) ? \"NULL\" : (\"\\\"\" + s.replace(/\\\\/g, \"\\\\\\\\\").replace(/\"/g, \"\\\\\\\"\") + \"\\\"\");\n}", "title": "" }, { "docid": "0caa047b63ed14ca89445160f53c5693", "score": "0.6261543", "text": "function createStringLiteral(text, singleQuotes) {\n const literal = ts.createStringLiteral(text);\n // See: https://github.com/microsoft/TypeScript/blob/master/src/compiler/utilities.ts#L584-L590\n // tslint:disable-next-line: no-string-literal\n literal['singleQuote'] = singleQuotes;\n return literal;\n}", "title": "" }, { "docid": "5f15747ec1df2c4f0b930b0dae02b3a1", "score": "0.6208793", "text": "function testStringLiterals() {\n STRING_F('no-quotes');\n STRING_F('\"missing-quote');\n STRING_F('missing-quote\"');\n STRING('\"\"', '');\n STRING('\"\\\\\"\\\\\"\"', '\"\"');\n STRING('\"Hello, world!\"', 'Hello, world!');\n STRING('\"Hello\\\\nworld\\\\!\"', 'Hello\\nworld!');\n STRING('\"\\\\0\\\\b\\\\t\\\\n\\\\v\\\\f\\\\r\"', '\\0\\b\\t\\n\\v\\f\\r');\n STRING('\"\\\\a\\\\c\\\\d\\\\e\\\\g\\\\h\\\\\\\\\\\\\\'\\\\\"\"', 'acdegh\\\\\\'\"')\n STRING('\"\\\\u03bb\\\\x0a\\\\x41\\\\u2022\\\\xff\"', '\\u03bb\\nA\\u2022\\xff');\n STRING_F('\"\\\\u04gg');\n}", "title": "" }, { "docid": "687b917a990d2d17e7c31b24ae862730", "score": "0.6151542", "text": "function StringLiteralExpression() {\n}", "title": "" }, { "docid": "bb1aa3ee9196ce10fd19625b9e9acaea", "score": "0.6140511", "text": "function toStringLiteral(value) {\n return `'${value.replace(/\\\\/g, '\\\\\\\\').replace(/'/g, \"\\\\'\")}'`;\n}", "title": "" }, { "docid": "d6fa321ad5e586af81062b792aedac1c", "score": "0.6099453", "text": "function tokenLiteral(quote) {\n return function (stream, state) {\n var escaped = false;\n var ch;\n while ((ch = stream.next()) != null) {\n if (ch == quote && !escaped) {\n state.tokenize = tokenBase;\n break;\n }\n escaped = !escaped && ch == \"\\\\\";\n }\n return \"string string-value\";\n };\n }", "title": "" }, { "docid": "651c385b6fcfc317220a81585051e103", "score": "0.6099386", "text": "function quote_anon(a) {\n if (a == '\"')\n return '\\\\\"';\n if (a == '\\b')\n return '\\\\b';\n if (a == '\\n')\n return '\\\\n';\n if (a == '\\f')\n return '\\\\f';\n if (a == '\\t')\n return '\\\\t';\n if (a == '\\\\')\n return '\\\\\\\\';\n\n // this could actually return a nice hexencoded unicode character\n // then again, I've already wasted enough time :)\n return '?';\n}", "title": "" }, { "docid": "16056dcfca85491d38a72a0a2d7695f5", "score": "0.6091639", "text": "function createStringLiteral(text, singleQuotes) {\n const literal = ts.createStringLiteral(text);\n literal.singleQuote = singleQuotes;\n return literal;\n}", "title": "" }, { "docid": "277b70aa9a0c0cc8ef072e8237407bdc", "score": "0.60557663", "text": "function tokenLiteral( quote ) {\n return function( stream, state ) {\n var escaped = false, ch;\n while ( (ch = stream.next() ) != null ) {\n if ( ch == quote && !escaped ) {\n state.tokenize = tokenBase;\n break;\n }\n escaped = backslashStringEscapes && !escaped && ch == \"\\\\\";\n }\n return \"string\";\n };\n }", "title": "" }, { "docid": "792029632f21634ec1f14793ae9a07f5", "score": "0.6052934", "text": "function visitStringLiteral(node) {\n if (node.hasExtendedUnicodeEscape) {\n return ts.setTextRange(ts.createLiteral(node.text), node);\n }\n return node;\n }", "title": "" }, { "docid": "337c035e812adb6ef611c393e14e9218", "score": "0.60162264", "text": "function getRawLiteral(node) {\n // Find original source text, since we need to emit the raw strings of the tagged template.\n // The raw strings contain the (escaped) strings of what the user wrote.\n // Examples: `\\n` is converted to \"\\\\n\", a template string with a newline to \"\\n\".\n var text = ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, node);\n // text contains the original source, it will also contain quotes (\"`\"), dolar signs and braces (\"${\" and \"}\"),\n // thus we need to remove those characters.\n // First template piece starts with \"`\", others with \"}\"\n // Last template piece ends with \"`\", others with \"${\"\n var isLast = node.kind === 13 /* NoSubstitutionTemplateLiteral */ || node.kind === 16 /* TemplateTail */;\n text = text.substring(1, text.length - (isLast ? 1 : 2));\n // Newline normalization:\n // ES6 Spec 11.8.6.1 - Static Semantics of TV's and TRV's\n // <CR><LF> and <CR> LineTerminatorSequences are normalized to <LF> for both TV and TRV.\n text = text.replace(/\\r\\n?/g, \"\\n\");\n return ts.setTextRange(ts.createLiteral(text), node);\n }", "title": "" }, { "docid": "1993877c1925f21023a5440bd43f03af", "score": "0.60088855", "text": "function visitStringLiteral(node) {\n if (node.hasExtendedUnicodeEscape) {\n return ts.setTextRange(ts.createLiteral(node.text), node);\n }\n return node;\n }", "title": "" }, { "docid": "57a01301623958b27a6bf55bc503cd98", "score": "0.6004003", "text": "function getRawLiteral(node) {\n // Find original source text, since we need to emit the raw strings of the tagged template.\n // The raw strings contain the (escaped) strings of what the user wrote.\n // Examples: `\\n` is converted to \"\\\\n\", a template string with a newline to \"\\n\".\n var text = ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, node);\n // text contains the original source, it will also contain quotes (\"`\"), dolar signs and braces (\"${\" and \"}\"),\n // thus we need to remove those characters.\n // First template piece starts with \"`\", others with \"}\"\n // Last template piece ends with \"`\", others with \"${\"\n var isLast = node.kind === 13 /* NoSubstitutionTemplateLiteral */ || node.kind === 16 /* TemplateTail */;\n text = text.substring(1, text.length - (isLast ? 1 : 2));\n // Newline normalization:\n // ES6 Spec 11.8.6.1 - Static Semantics of TV's and TRV's\n // <CR><LF> and <CR> LineTerminatorSequences are normalized to <LF> for both TV and TRV.\n text = text.replace(/\\r\\n?/g, \"\\n\");\n return ts.setTextRange(ts.createLiteral(text), node);\n }", "title": "" }, { "docid": "3bf4ce8399b0b5bbd0a2b8dee058c963", "score": "0.599944", "text": "function tokenLiteral(quote) {\n return function(stream, state) {\n var escaped = false, ch;\n while ((ch = stream.next()) != null) {\n if (ch == quote && !escaped) {\n state.tokenize = tokenBase;\n break;\n }\n escaped = !escaped && ch == \"\\\\\";\n }\n return \"string\";\n };\n }", "title": "" }, { "docid": "3bf4ce8399b0b5bbd0a2b8dee058c963", "score": "0.599944", "text": "function tokenLiteral(quote) {\n return function(stream, state) {\n var escaped = false, ch;\n while ((ch = stream.next()) != null) {\n if (ch == quote && !escaped) {\n state.tokenize = tokenBase;\n break;\n }\n escaped = !escaped && ch == \"\\\\\";\n }\n return \"string\";\n };\n }", "title": "" }, { "docid": "312734f0449f0bc9d6367d707bcd7ce4", "score": "0.5994068", "text": "function getRawLiteral(node) {\n // Find original source text, since we need to emit the raw strings of the tagged template.\n // The raw strings contain the (escaped) strings of what the user wrote.\n // Examples: `\\n` is converted to \"\\\\n\", a template string with a newline to \"\\n\".\n var text = ts.getSourceTextOfNodeFromSourceFile(currentSourceFile, node);\n // text contains the original source, it will also contain quotes (\"`\"), dolar signs and braces (\"${\" and \"}\"),\n // thus we need to remove those characters.\n // First template piece starts with \"`\", others with \"}\"\n // Last template piece ends with \"`\", others with \"${\"\n var isLast = node.kind === 12 /* NoSubstitutionTemplateLiteral */ || node.kind === 15 /* TemplateTail */;\n text = text.substring(1, text.length - (isLast ? 1 : 2));\n // Newline normalization:\n // ES6 Spec 11.8.6.1 - Static Semantics of TV's and TRV's\n // <CR><LF> and <CR> LineTerminatorSequences are normalized to <LF> for both TV and TRV.\n text = text.replace(/\\r\\n?/g, \"\\n\");\n return ts.setTextRange(ts.createLiteral(text), node);\n }", "title": "" }, { "docid": "a5980433bda471edc43e165a1c10612f", "score": "0.59780145", "text": "function tokenLiteral(quote) {\n return function(stream, state) {\n var escaped = false, ch;\n while ((ch = stream.next()) != null) {\n if (ch == quote && !escaped) {\n state.tokenize = tokenBase;\n break;\n }\n escaped = backslashStringEscapes && !escaped && ch == \"\\\\\";\n }\n return \"string\";\n };\n }", "title": "" }, { "docid": "c5b71f7e2bb2004206ba6c27236c65bc", "score": "0.59633595", "text": "function scanStringLiteral() {\n var str = '', quote, start, ch;\n\n quote = source[index];\n if (quote !== '\\'' && quote !== '\"') {\n return;\n }\n start = index;\n nextChar();\n\n while (index < length) {\n ch = nextChar();\n\n if (ch === quote) {\n quote = '';\n break;\n } else if (ch === '\\\\') {\n ch = nextChar();\n if (!isLineTerminator(ch)) {\n str += '\\\\';\n str += ch;\n }\n } else {\n str += ch;\n }\n }\n\n if (quote !== '') {\n throwError(Messages.UnexpectedToken, 'ILLEGAL');\n }\n\n return {\n type: Token.StringLiteral,\n value: str,\n lineNumber: lineNumber,\n range: [start, index]\n };\n }", "title": "" }, { "docid": "28f882c6f00d44e007d37107b4c27871", "score": "0.59228337", "text": "function literal$4(scanner) {\n const ch = scanner.peek();\n if (isQuote(ch)) {\n scanner.start = scanner.pos++;\n while (!scanner.eof()) {\n if (scanner.eat(ch) || scanner.eat(10 /* LF */ ) || scanner.eat(13 /* CR */ )) {\n break;\n }\n // Skip escape character, if any\n scanner.eat(92 /* Backslash */ );\n scanner.pos++;\n }\n // Do not throw if string is incomplete\n return true;\n }\n }", "title": "" }, { "docid": "1254c2c80a0084c8468abfb4433a8efc", "score": "0.58888376", "text": "static function raw(str : string) : string {\n return MD5._rstr_md5(StringUtil.encode_utf8(str));\n }", "title": "" }, { "docid": "2e026d545877eb153a844babad666b3e", "score": "0.58819044", "text": "_parseString() {\n const m = this.match(/^\"((\\\\\"|[^\"])*)\"/);\n if (m) {\n this.i += m[0].length;\n const s = m[1].replaceAll(/\\\\\\s*\\n\\s*/g, \"\");\n return this._replaceEscapedChars(s);\n } else {\n throw new Unterminated(\"invalid string literal\", this.rest())\n }\n }", "title": "" }, { "docid": "cf1aa2d2affc4def8352a00d4bfa4189", "score": "0.5869562", "text": "function makeTemplateString(template, raw) {\n Object.defineProperty(template, 'raw', {\n value: raw\n });\n return template; // tslint:disable-line:no-any\n}", "title": "" }, { "docid": "66a8cee582d1523d69bb8acd99db1386", "score": "0.58672947", "text": "function QuotedString() {\n return (\n <div>\n <span>\"Quoted string\"</span>\n <span>{\"Quoted string inside braces\"}</span>\n <span>{'single quotes'}</span>\n </div>\n );\n}", "title": "" }, { "docid": "4ea1765d5a9b40765a737449e246f620", "score": "0.585143", "text": "function string ()\n {\n tok.next ();\n var maxSize;\n if (tok.next (\"(\"))\n {\n\t maxSize = tok.require (\"Uint\", \"string max size\");\n\t tok.require (\")\");\n }\n var r = rank ();\n obs.onStringType (r, maxSize, consumeAnnots (), tok.lastLoc ())\n }", "title": "" }, { "docid": "57a611b9346bcdf710049317ac506832", "score": "0.5827017", "text": "_encodeLiteral(literal) {\n // Escape special characters\n var value = literal.value;\n if (escape.test(value)) value = value.replace(escapeAll, characterReplacer); // Write the literal, possibly with type or language\n\n if (literal.language) return '\"' + value + '\"@' + literal.language;else if (literal.datatype.value !== xsd.string) return '\"' + value + '\"^^' + this._encodeIriOrBlank(literal.datatype);else return '\"' + value + '\"';\n }", "title": "" }, { "docid": "0f964db596620424aa2b8f815e2d212b", "score": "0.58136696", "text": "function quoteStr(s){\n let ch,out = \"\\\"\";\n if(isStr(s))\n for(let i=0; i<s.length; ++i){\n ch= s.charAt(i);\n if(ch == \"\\\"\"){\n out += \"\\\\\\\"\"\n }else if(ch == \"\\n\"){\n out += \"\\\\n\"\n }else if(ch == \"\\t\"){\n out += \"\\\\t\"\n }else if(ch == \"\\f\"){\n out += \"\\\\f\"\n }else if(ch == \"\\r\"){\n out += \"\\\\r\"\n }else if(ch == \"\\v\"){\n out += \"\\\\v\"\n }else if(ch == \"\\\\\"){\n out += \"u\" == s.charAt(i+1) ? ch : \"\\\\\\\\\"\n }else{\n out += ch\n }\n }\n return out += \"\\\"\";\n }", "title": "" }, { "docid": "0d3caf2257e121584409df5a82653cda", "score": "0.5811082", "text": "function escapeString(s, quoteChar) {\n var escapedCharsRegExp = quoteChar === 96 /* backtick */ ? backtickQuoteEscapedCharsRegExp : quoteChar === 39 /* singleQuote */ ? singleQuoteEscapedCharsRegExp : doubleQuoteEscapedCharsRegExp;\n return s.replace(escapedCharsRegExp, getReplacement).replace(escapedNullRegExp, nullReplacement);\n }", "title": "" }, { "docid": "44e9163d671d9fe48ba010d1d0c24300", "score": "0.57657206", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "97eda06256b0ac82d39ab183464463fd", "score": "0.57570124", "text": "parsePrimitiveString(inst) {\n if(!(/^(\"([^\"]*)\")/.test(inst) || /^('([^']*)')/.test(inst)))\n return false\n\n const quoted_string = RegExp.$1\n const string = syntax.parsePrimitiveStringSpecialCharacters(RegExp.$2)\n const remain = inst.substr(quoted_string.length)\n\n return {\n remain: remain,\n original: inst,\n parsed: {\n type: 'string',\n args: {\n value: string\n }\n }\n }\n }", "title": "" }, { "docid": "260fb822ed0204f70ecf3daa70a5cc95", "score": "0.57543564", "text": "static __dangerous__rawValue(text) {\n return new SQLQuery([{ type: SQLItemType.RAW, text }]);\n }", "title": "" }, { "docid": "7cb78a6938ce82ef73223f494a0c15f5", "score": "0.57410616", "text": "function quote(s) {\n return '\\\\Q' + s.replace('\\\\E', '\\\\E\\\\\\\\E\\\\Q') + '\\\\E';\n}", "title": "" }, { "docid": "7cb78a6938ce82ef73223f494a0c15f5", "score": "0.57410616", "text": "function quote(s) {\n return '\\\\Q' + s.replace('\\\\E', '\\\\E\\\\\\\\E\\\\Q') + '\\\\E';\n}", "title": "" }, { "docid": "8ed245d2eca3b09b2fe62139caaa8ebb", "score": "0.57372457", "text": "function asString (str) {\n let result = ''\n let last = 0\n let found = false\n let point = 255\n const l = str.length\n if (l > 100) {\n return JSON.stringify(str)\n }\n for (var i = 0; i < l && point >= 32; i++) {\n point = str.charCodeAt(i)\n if (point === 34 || point === 92) {\n result += str.slice(last, i) + '\\\\'\n last = i\n found = true\n }\n }\n if (!found) {\n result = str\n } else {\n result += str.slice(last)\n }\n return point < 32 ? JSON.stringify(str) : '\"' + result + '\"'\n}", "title": "" }, { "docid": "445040a61236de7c00abde59585f294b", "score": "0.57317847", "text": "writeDefaultStringEscapeQuote(str) {\n this.writeInt8(QUOTE);\n let match;\n let lastIndex = 0;\n while ((match = CHARS_GLOBAL_REGEXP.exec(str)) !== null) {\n this.writeString(str.slice(lastIndex, match.index));\n this.writeInt8(SLASH);\n this.writeInt8(match[0].charCodeAt(0));\n lastIndex = CHARS_GLOBAL_REGEXP.lastIndex;\n }\n\n if (lastIndex === 0) {\n // Nothing was escaped\n this.writeString(str);\n this.writeInt8(QUOTE);\n return;\n }\n\n if (lastIndex < str.length) {\n this.writeString(str.slice(lastIndex));\n }\n this.writeInt8(QUOTE);\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "0e774c2430795ef47f39b4e157332d66", "score": "0.5724563", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape)\n + '\"';\n }", "title": "" }, { "docid": "418ff5065d96d8256495214cef4c24fe", "score": "0.57149285", "text": "function quote(s) {\n /*\n * ECMA-262, 5th ed., 7.8.4: All characters may appear literally in a\n * string literal except for the closing quote character, backslash,\n * carriage return, line separator, paragraph separator, and line feed.\n * Any character may appear in the form of an escape sequence.\n *\n * For portability, we also escape escape all control and non-ASCII\n * characters. Note that \"\\0\" and \"\\v\" escape sequences are not used\n * because JSHint does not like the first and IE the second.\n */\n return '\"' + s\n .replace(/\\\\/g, '\\\\\\\\') // backslash\n .replace(/\"/g, '\\\\\"') // closing quote character\n .replace(/\\x08/g, '\\\\b') // backspace\n .replace(/\\t/g, '\\\\t') // horizontal tab\n .replace(/\\n/g, '\\\\n') // line feed\n .replace(/\\f/g, '\\\\f') // form feed\n .replace(/\\r/g, '\\\\r') // carriage return\n .replace(/[\\x00-\\x07\\x0B\\x0E-\\x1F\\x80-\\uFFFF]/g, escape) + '\"';\n }", "title": "" }, { "docid": "ab0e8aba33a56a96a340613f3a5daf49", "score": "0.5711928", "text": "function escapeString(s, quoteChar) {\n var escapedCharsRegExp = quoteChar === 96 /* backtick */ ? backtickQuoteEscapedCharsRegExp :\n quoteChar === 39 /* singleQuote */ ? singleQuoteEscapedCharsRegExp :\n doubleQuoteEscapedCharsRegExp;\n return s.replace(escapedCharsRegExp, getReplacement).replace(escapedNullRegExp, nullReplacement);\n }", "title": "" }, { "docid": "9bd7894e10037027b9d040ecb23c4fa0", "score": "0.5667374", "text": "_encodeLiteral(literal) {\n // Escape special characters\n var value = literal.value;\n if (escape$1.test(value))\n value = value.replace(escapeAll, characterReplacer);\n // Write the literal, possibly with type or language\n if (literal.language)\n return '\"' + value + '\"@' + literal.language;\n else if (literal.datatype.value !== xsd$2.string)\n return '\"' + value + '\"^^' + this._encodeIriOrBlank(literal.datatype);\n else\n return '\"' + value + '\"';\n }", "title": "" }, { "docid": "52b5dba77b3c1678f03c1bb5e0f8afb1", "score": "0.5630661", "text": "_encodeLiteral(literal) {\n // Escape special characters\n let value = literal.value;\n if (escape.test(value))\n value = value.replace(escapeAll, characterReplacer);\n\n // Write a language-tagged literal\n if (literal.language)\n return `\"${value}\"@${literal.language}`;\n\n // Write dedicated literals per data type\n if (this._lineMode) {\n // Only abbreviate strings in N-Triples or N-Quads\n if (literal.datatype.value === xsd.string)\n return `\"${value}\"`;\n }\n else {\n // Use common datatype abbreviations in Turtle or TriG\n switch (literal.datatype.value) {\n case xsd.string:\n return `\"${value}\"`;\n case xsd.boolean:\n if (value === 'true' || value === 'false')\n return value;\n break;\n case xsd.integer:\n if (/^[+-]?\\d+$/.test(value))\n return value;\n break;\n case xsd.decimal:\n if (/^[+-]?\\d*\\.\\d+$/.test(value))\n return value;\n break;\n case xsd.double:\n if (/^[+-]?(?:\\d+\\.\\d*|\\.?\\d+)[eE][+-]?\\d+$/.test(value))\n return value;\n break;\n }\n }\n\n // Write a regular datatyped literal\n return `\"${value}\"^^${this._encodeIriOrBlank(literal.datatype)}`;\n }", "title": "" }, { "docid": "e8a22b8cd052058836b973b30e986d61", "score": "0.5627382", "text": "_encodeLiteral(literal) {\n // Escape special characters\n var value = literal.value;\n if (N3Writer_escape.test(value))\n value = value.replace(escapeAll, characterReplacer);\n // Write the literal, possibly with type or language\n if (literal.language)\n return '\"' + value + '\"@' + literal.language;\n else if (literal.datatype.value !== N3Writer_xsd.string)\n return '\"' + value + '\"^^' + this._encodeIriOrBlank(literal.datatype);\n else\n return '\"' + value + '\"';\n }", "title": "" }, { "docid": "eb3d755364f9b7f7c66c281a3a0a5b80", "score": "0.5616388", "text": "function printStringLiteral(path, { rubySingleQuote }, print) {\n const node = path.getValue();\n\n // If the string is empty, it will not have any parts, so just print out the\n // quotes corresponding to the config\n if (node.body.length === 0) {\n return rubySingleQuote ? \"''\" : '\"\"';\n }\n\n // Determine the quote that should enclose the new string\n let quote;\n if (isQuoteLocked(node)) {\n quote = node.quote;\n } else {\n quote = rubySingleQuote && isSingleQuotable(node) ? \"'\" : '\"';\n }\n\n const parts = node.body.map((part, index) => {\n if (part.type !== \"@tstring_content\") {\n // In this case, the part of the string is an embedded expression\n return path.call(print, \"body\", index);\n }\n\n // In this case, the part of the string is just regular string content\n return join(literalline, normalizeQuotes(part.body, quote).split(\"\\n\"));\n });\n\n return concat([quote].concat(parts).concat(getClosingQuote(quote)));\n}", "title": "" }, { "docid": "fd40e4edb9fcddbd9fcfed9c13c2e8be", "score": "0.55967474", "text": "function TemplateLiteral() {\n return t.stringTypeAnnotation();\n}", "title": "" }, { "docid": "3e46fc5f8eb36ee1091adb6142f37908", "score": "0.5591849", "text": "function tryStringLiteral(cursor, ch)\n{\n var line = cursor.line;\n var column = cursor.column;\n\n if (isComment(line, column - 2)) // Do nothing for comments\n return;\n\n // First of all we have to determinate where we are:\n // 0) new string literal just started, or ...\n // 1) string literal just ends\n\n // Check if the '\"' is a very first char on a line\n var new_string_just_started;\n var raw_string;\n if (column < 2) {\n // Yes, then we have to look to the last char of the previous line\n new_string_just_started = !(line != 0 && isString(line - 1, document.lastColumn(line - 1)));\n } else {\n new_string_just_started = !isString(line, column - 2);\n if (!new_string_just_started && ch === '\"') {\n // we need to scan backwards before R\", [uUL]R\" or u8R\"\n var stringEnd;\n const isRawPrefix = (column >= 2 && document.charAt(line, column - 2) === 'R');\n if (isRawPrefix) {\n const charBeforeRaw = (column >= 3 && document.charAt(line, column - 3));\n if (column >= 4 && charBeforeRaw === '8' && document.charAt(line, column - 4) === 'u') {\n raw_string = true;\n stringEnd = 5;\n } else if (column >= 3 && (charBeforeRaw === 'u' || charBeforeRaw === 'U' || charBeforeRaw == 'L')) {\n raw_string = true;\n stringEnd = 4;\n } else {\n raw_string = true;\n stringEnd = 3;\n }\n }\n if (raw_string)\n new_string_just_started = (column >= stringEnd) ? !isString(line, column - stringEnd) : !(line != 0 && isString(line - 1, document.lastColumn(line - 1)));\n }\n }\n\n // TODO Add a space after possible operator right before just\n // started string literal...\n if (new_string_just_started)\n {\n // Is there anything after just entered '\"'?\n var nc = document.charAt(line, column);\n var need_closing_quote = column == document.lineLength(line)\n || document.isSpace(nc)\n || nc === ',' // user tries to add new string param,\n || nc === ')' // ... or one more param to the end of some call\n || nc === ']' // ... or string literal as subscript index\n || nc === ';' // ... or one more string before end of expression\n || nc === '<' // ... or `some << \"|<<`\n ;\n if (need_closing_quote)\n {\n // Check for 'R' right before '\"'\n if (raw_string)\n {\n // Yeah, looks like a raw string literal\n /// \\todo Make delimiter configurable... HOW?\n /// It would be nice if indenters can have a configuration page somehow...\n document.insertText(cursor, \"~()~\\\"\");\n view.setCursorPosition(line, column + 2);\n }\n else\n {\n document.insertText(cursor, ch);\n view.setCursorPosition(line, column);\n }\n }\n }\n}", "title": "" }, { "docid": "d1a4ef20813e37f3a5d47bc135621c70", "score": "0.5586202", "text": "function quotedString() {\n return wrap('quoted-string', and(invis(opt(cfws)), invis(dquote), star(and(opt(colwsp(fws)), qcontent)), opt(invis(fws)), invis(dquote), invis(opt(cfws)))());\n }", "title": "" }, { "docid": "0ee902c69063a4e6f00950f44be9eb36", "score": "0.557889", "text": "function safeEscape(s) {\n var tmp = [];\n var i, c;\n\n for (i = 0; i < s.length; i++) {\n // When CESU-8 / extended UTF-8 decoding fails, Duktape currently throws\n // for charCodeAt().\n try {\n c = s.charCodeAt(i);\n if (c < 0x20 || c > 0x7e || c == '<' || c == '>' || c == '\"' || c == '\\'') {\n tmp.push('<U+' + (('0000') + c.toString(16)).substr(-4).toUpperCase() + '>');\n } else {\n tmp.push(String.fromCharCode(c));\n }\n } catch (e) {\n tmp.push('<' + e.name + '>');\n }\n }\n\n return '\"' + tmp.join('') + '\"'\n}", "title": "" }, { "docid": "81ba5f32c82eacc9c8af511b95fb0608", "score": "0.5578006", "text": "function string() {}", "title": "" }, { "docid": "c74f4a20bb0eeb8e6ca725c99bd275dd", "score": "0.55582994", "text": "_encodeLiteral(literal) {\n // Escape special characters\n let value = literal.value;\n if (escape.test(value)) value = value.replace(escapeAll, characterReplacer); // Write a language-tagged literal\n\n if (literal.language) return `\"${value}\"@${literal.language}`; // Write dedicated literals per data type\n\n if (this._lineMode) {\n // Only abbreviate strings in N-Triples or N-Quads\n if (literal.datatype.value === xsd.string) return `\"${value}\"`;\n } else {\n // Use common datatype abbreviations in Turtle or TriG\n switch (literal.datatype.value) {\n case xsd.string:\n return `\"${value}\"`;\n\n case xsd.boolean:\n if (value === 'true' || value === 'false') return value;\n break;\n\n case xsd.integer:\n if (/^[+-]?\\d+$/.test(value)) return value;\n break;\n\n case xsd.decimal:\n if (/^[+-]?\\d*\\.\\d+$/.test(value)) return value;\n break;\n\n case xsd.double:\n if (/^[+-]?(?:\\d+\\.\\d*|\\.?\\d+)[eE][+-]?\\d+$/.test(value)) return value;\n break;\n }\n } // Write a regular datatyped literal\n\n\n return `\"${value}\"^^${this._encodeIriOrBlank(literal.datatype)}`;\n }", "title": "" }, { "docid": "cab33d02ced4d59bfddc4760cba454ff", "score": "0.55459905", "text": "static getLiteral(segment) {\n let literal = '';\n for (let i = 0; i < segment.length; i++) {\n const c = segment[i];\n // Escape\n if (c === '\\\\' && !IS_WINDOWS && i + 1 < segment.length) {\n literal += segment[++i];\n continue;\n }\n // Wildcard\n else if (c === '*' || c === '?') {\n return '';\n }\n // Character set\n else if (c === '[' && i + 1 < segment.length) {\n let set = '';\n let closed = -1;\n for (let i2 = i + 1; i2 < segment.length; i2++) {\n const c2 = segment[i2];\n // Escape\n if (c2 === '\\\\' && !IS_WINDOWS && i2 + 1 < segment.length) {\n set += segment[++i2];\n continue;\n }\n // Closed\n else if (c2 === ']') {\n closed = i2;\n break;\n }\n // Otherwise\n else {\n set += c2;\n }\n }\n // Closed?\n if (closed >= 0) {\n // Cannot convert\n if (set.length > 1) {\n return '';\n }\n // Convert to literal\n if (set) {\n literal += set;\n i = closed;\n continue;\n }\n }\n // Otherwise fall thru\n }\n // Append\n literal += c;\n }\n return literal;\n }", "title": "" }, { "docid": "cab33d02ced4d59bfddc4760cba454ff", "score": "0.55459905", "text": "static getLiteral(segment) {\n let literal = '';\n for (let i = 0; i < segment.length; i++) {\n const c = segment[i];\n // Escape\n if (c === '\\\\' && !IS_WINDOWS && i + 1 < segment.length) {\n literal += segment[++i];\n continue;\n }\n // Wildcard\n else if (c === '*' || c === '?') {\n return '';\n }\n // Character set\n else if (c === '[' && i + 1 < segment.length) {\n let set = '';\n let closed = -1;\n for (let i2 = i + 1; i2 < segment.length; i2++) {\n const c2 = segment[i2];\n // Escape\n if (c2 === '\\\\' && !IS_WINDOWS && i2 + 1 < segment.length) {\n set += segment[++i2];\n continue;\n }\n // Closed\n else if (c2 === ']') {\n closed = i2;\n break;\n }\n // Otherwise\n else {\n set += c2;\n }\n }\n // Closed?\n if (closed >= 0) {\n // Cannot convert\n if (set.length > 1) {\n return '';\n }\n // Convert to literal\n if (set) {\n literal += set;\n i = closed;\n continue;\n }\n }\n // Otherwise fall thru\n }\n // Append\n literal += c;\n }\n return literal;\n }", "title": "" }, { "docid": "cab33d02ced4d59bfddc4760cba454ff", "score": "0.55459905", "text": "static getLiteral(segment) {\n let literal = '';\n for (let i = 0; i < segment.length; i++) {\n const c = segment[i];\n // Escape\n if (c === '\\\\' && !IS_WINDOWS && i + 1 < segment.length) {\n literal += segment[++i];\n continue;\n }\n // Wildcard\n else if (c === '*' || c === '?') {\n return '';\n }\n // Character set\n else if (c === '[' && i + 1 < segment.length) {\n let set = '';\n let closed = -1;\n for (let i2 = i + 1; i2 < segment.length; i2++) {\n const c2 = segment[i2];\n // Escape\n if (c2 === '\\\\' && !IS_WINDOWS && i2 + 1 < segment.length) {\n set += segment[++i2];\n continue;\n }\n // Closed\n else if (c2 === ']') {\n closed = i2;\n break;\n }\n // Otherwise\n else {\n set += c2;\n }\n }\n // Closed?\n if (closed >= 0) {\n // Cannot convert\n if (set.length > 1) {\n return '';\n }\n // Convert to literal\n if (set) {\n literal += set;\n i = closed;\n continue;\n }\n }\n // Otherwise fall thru\n }\n // Append\n literal += c;\n }\n return literal;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ba5542b0c6cce668df09194ff920bdfa", "score": "0.55340326", "text": "function SafeString(string) {\n this.string = string;\n }", "title": "" }, { "docid": "ce209c94d725fe384d65d35b19d6caac", "score": "0.55334675", "text": "function removeStringLiterals(code)\n{\n let buildString = \"\";\n let i = 0;\n let shouldEscape = false;\n let quoteType = \"\";\n\n while(i < code.length)\n {\n if(code[i] === \"'\") { quoteType = \"'\"; }\n else if(code[i] === '\"') { quoteType = '\"'; }\n else //outside any string literals\n {\n buildString += code[i];\n i++; continue;\n }\n i++;\n buildString += quoteType;\n\n while(i < code.length)\n {\n //character isn't the quote type, add _ to new string\n if(!(code[i] === quoteType)) { buildString += \"_\"; }\n else //character is quote\n {\n //after escape character, add _ and don't end string\n if(shouldEscape) { buildString += \"_\"; }\n else //end of the string\n {\n buildString += quoteType;\n i++; break;\n }\n }\n\n if(code[i] === \"\\\\\") { shouldEscape = true; }\n else { shouldEscape = false; }\n\n i++;\n }\n }\n return buildString;\n}", "title": "" }, { "docid": "cd72752bf4634f7e7516298bca96bc8a", "score": "0.5526817", "text": "function quotedString() {\n return wrap('quoted-string', and(\n invis(opt(cfws)),\n invis(dquote), star(and(opt(colwsp(fws)), qcontent)), opt(invis(fws)), invis(dquote),\n invis(opt(cfws))\n )());\n }", "title": "" }, { "docid": "cd72752bf4634f7e7516298bca96bc8a", "score": "0.5526817", "text": "function quotedString() {\n return wrap('quoted-string', and(\n invis(opt(cfws)),\n invis(dquote), star(and(opt(colwsp(fws)), qcontent)), opt(invis(fws)), invis(dquote),\n invis(opt(cfws))\n )());\n }", "title": "" }, { "docid": "7832ee842694739c0c9ffbe60e45b6ba", "score": "0.5503979", "text": "function escapeString(value) {\n // SEE: https://stackoverflow.com/a/17808731/11817077\n return value.replace('\"', '\"\"');\n}", "title": "" }, { "docid": "b647a5b35b8be56d736ea27d487792f7", "score": "0.54644006", "text": "function lwiw73920() { return 'ntStr'; }", "title": "" }, { "docid": "a6f7fa4ef8da22e0be544da46cbc6f18", "score": "0.54495484", "text": "function escapeString(rawString) {\n var escapedString = \"\";\n var specialChar = ['&', '.', ':'];\n for (var i = 0; i < rawString.length; i++) {\n if (specialChar.indexOf(rawString[i]) > -1) {\n escapedString = escapedString + '\\\\' + rawString[i];\n } else {\n escapedString = escapedString + rawString[i];\n }\n }\n return escapedString;\n }", "title": "" }, { "docid": "c15144fee641dc54c83344f267541cb3", "score": "0.54383963", "text": "function quote(string) { // 10\n return JSON.stringify(string); // 11\n} // 12", "title": "" }, { "docid": "a4704348195e1bdab1c5c53bdc43f2f9", "score": "0.54275316", "text": "function SafeString(string) {\n\t this.string = string;\n\t}", "title": "" }, { "docid": "a4704348195e1bdab1c5c53bdc43f2f9", "score": "0.54275316", "text": "function SafeString(string) {\n\t this.string = string;\n\t}", "title": "" }, { "docid": "10a33201534520f9e6b3665c6bb78661", "score": "0.5426286", "text": "static escape(string, allSettings){\n let ret = string;\n\n ret = ret.replace(/'/g, '\\'\"\\'\"\\''); // ' to ''\n ret = ret.replace(/\\n/g, '\\\\n'); // newline to \\n\n\n return ret;\n }", "title": "" }, { "docid": "8a4b259755d6fd3d579bb3e67d6da596", "score": "0.5419116", "text": "rawText(str) {\n return {\n inspect() {\n return str;\n }\n\n };\n }", "title": "" }, { "docid": "1a46167d029f2c0e2bd231422cb30a04", "score": "0.54064935", "text": "function n(e){return'\"'+r(e)+'\"'}", "title": "" }, { "docid": "2746517cf52453155e64cd7ed3401250", "score": "0.5404125", "text": "function escape(str) {\n\tif (!str) return '';\n\treturn str\n\t\t.toString()\n\t\t.replace(/\\x1B.*?m/g, '') // eslint-disable-line no-control-regex\n\t\t.replace(/\\|/g, '||')\n\t\t.replace(/\\n/g, '|n')\n\t\t.replace(/\\r/g, '|r')\n\t\t.replace(/\\[/g, '|[')\n\t\t.replace(/\\]/g, '|]')\n\t\t.replace(/\\u0085/g, '|x')\n\t\t.replace(/\\u2028/g, '|l')\n\t\t.replace(/\\u2029/g, '|p')\n\t\t.replace(/'/g, '|\\'');\n}", "title": "" }, { "docid": "94c509b598b20a5ad1f7cbe750e4ddc7", "score": "0.5402896", "text": "function SafeString(string) {\n this.string = string;\n}", "title": "" }, { "docid": "94c509b598b20a5ad1f7cbe750e4ddc7", "score": "0.5402896", "text": "function SafeString(string) {\n this.string = string;\n}", "title": "" } ]
59be76010f16b5d7064086721f9ffcf7
Get typical latlon combo.
[ { "docid": "556314bac5c120bd0007a3017efb1bd5", "score": "0.7283863", "text": "getLatLon() {\r\n\t\tconst ll = `${this._l.lat},${this._l.lon}`;\r\n\t\tif (ll === ',') {\r\n\t\t\treturn '';\r\n\t\t}\r\n\t\treturn ll;\r\n\t}", "title": "" } ]
[ { "docid": "19640f1ec9ec4b6187037ba9688cb388", "score": "0.6837631", "text": "getLon(x, y) {\n return (this.A * x) + (this.B * y) + this.C\n }", "title": "" }, { "docid": "2505aecc20a6de540ac3142193095065", "score": "0.6834524", "text": "function Lon2Merc(lon) {\r\n return 20037508.34 * lon / 180;\r\n}", "title": "" }, { "docid": "ea6a7b29fbe300482042797e76e66112", "score": "0.66242975", "text": "function LatLonToMercator(lat, lon) {\n var rMajor = 6378137; //Equatorial Radius, WGS84\n var shift = Math.PI * rMajor;\n var x = lon * shift / 180;\n var y = Math.log(Math.tan((90 + lat) * Math.PI / 360)) / (Math.PI / 180);\n y = y * shift / 180;\n\n return {\n 'x': x,\n 'y': y\n };\n }", "title": "" }, { "docid": "6d6a1a3d6b09558944067bed8b947a01", "score": "0.65714985", "text": "getLatLong (location) {\n return new google.maps.LatLng(location.split(',')[0], location.split(',')[1]);\n }", "title": "" }, { "docid": "d0d7a0fbfa59466a9b5a74671a6d564f", "score": "0.65250987", "text": "function getLatLonObject(lat, lon) {\n return new google.maps.LatLng(lat, lon);\n }", "title": "" }, { "docid": "fc282ed7d77caa32cd67dedd842cbb15", "score": "0.6507873", "text": "function first_startlon() {\n for (var startlon in startlons) {\n return startlon;\n }\n return null;\n }", "title": "" }, { "docid": "ccd7739b628f32c5da2432a63f71a72d", "score": "0.64840186", "text": "function getLatLngCompass(latlng) {\n if (latlng.lat < 0) var cardinalLat = \"S\";\n else var cardinalLat = \"N\";\n if (latlng.lng < 0) var cardinalLng = \"W\";\n else var cardinalLng = \"E\";\n return {lat: cardinalLat, lng: cardinalLng};\n}", "title": "" }, { "docid": "95fc0e64de02ab9a6f60aa79aa2099eb", "score": "0.6478812", "text": "function MercatorToLatLon(x, y) {\n var x1 = pipeline.sensors[0].x + x;\n var y1 = pipeline.sensors[0].y + y;\n var rMajor = 6378137; //Equatorial Radius, WGS84\n var shift = Math.PI * rMajor;\n\n y = y1 / shift * 180;\n\n var lat = y * (Math.PI / 180);\n\n lat = Math.exp(lat);\n lat = Math.atan(lat) / (Math.PI / 360);\n\n var temp = lat;\n\n lat = -(90 - temp);\n\n var lon = x1 / shift * 180;\n\n return {\n 'lat': lat,\n 'lon': lon\n };\n }", "title": "" }, { "docid": "eb80f9256331b9372594f9bfedaf6eeb", "score": "0.6456756", "text": "function LatLon(lat, lon) {\r\n this.lat = lat;\r\n this.lon = lon;\r\n}", "title": "" }, { "docid": "8596310bb0d15195db202219959915ea", "score": "0.64318043", "text": "function findLon(lon){\n\treturn lon/imgLarg*(imgLONmax-imgLONmin)+imgLONmin;\n}", "title": "" }, { "docid": "70af93429a1f8d599c298249c8a40b8e", "score": "0.6405833", "text": "function checkLon(lon) {\n\t if (lon == -999) {\n\t\t return 170.0;\n\t }\n\t else {\n\t\t return lon;\n\t }\n }", "title": "" }, { "docid": "c05b7d9978ac2ffa3f9110abee93ed0d", "score": "0.63740003", "text": "getLat(x, y) {\n return (this.D * x) + (this.E * y) + this.F\n }", "title": "" }, { "docid": "ffdc36c8591f5c9073c20969ea33c635", "score": "0.6356295", "text": "function createLonLat(lon, lat) {\r\n return new OpenLayers.LonLat(lon, lat).transform(WGS1984, MercatorProjection);\r\n}", "title": "" }, { "docid": "9034fce8728e9d882cf94b625a65fe62", "score": "0.63217634", "text": "function getLatLong() {\n checkParams();\n // Check if geolocation supported and get positions\n if (!navigator.geolocation) {\n element.textContent = \"Geolocation is not supported by your browser\";\n } else {\n navigator.geolocation.getCurrentPosition(\n successLatLong,\n () => error(errorLocation),\n { enableHighAccuracy: true }\n );\n }\n }", "title": "" }, { "docid": "4299538475bdc9cf6d8cf766e458f481", "score": "0.6303713", "text": "function getProjectedCoordinates(lon, lat) {\n\t\t\t\t\t\treturn {\n\t\t\t\t\t\t\t'lon': projection([lon, lat])[0],\n\t\t\t\t\t\t\t'lat': projection([ lon, lat ])[1]\n\t\t\t\t\t\t};\n\t\t\t\t\t}", "title": "" }, { "docid": "f3c605ce1e50c9eba9c00465e508741f", "score": "0.6266662", "text": "function mercX(lon){\n\tlon = radians(lon);\n\tvar a = (256 / PI ) * pow(2, gpsPosition.zoom);\n\tvar b = lon + PI;\n\treturn a * b;\n\n}", "title": "" }, { "docid": "38a461385294587969cc76f9c4688296", "score": "0.62253314", "text": "function UTMLATLNG(_coord) {\n var coordlat = [];\n let i = 0;\n let y = 0;\n let j = 0;\n let cordX = _coord[i][y];\n let cordY = _coord[i][y];\n do {\n cordX = _coord[i][y];\n cordY = _coord[i][y + 1];\n let cord = L.utm({ x: cordX, y: cordY, zone: 14, band: 'Q' });\n let cordd = cord.latLng();\n coordlat[j] = cordd;\n j++;\n i++;\n } while (_coord[i][y] && _coord[i][1] != \"\");\n return coordlat;\n}", "title": "" }, { "docid": "c41eea316ae3ccaeecfab6f729987123", "score": "0.622073", "text": "get longitude() {\n return this.x_;\n }", "title": "" }, { "docid": "45af03cdcc5c50bedec5d8c9f8406d93", "score": "0.6211357", "text": "function getPoint(lat, lon) {\n x = (180 + lon) * (map.width / 360);\n y = (90 - lat) * (map.height / 180);\n return {x:x,y:y};\n}", "title": "" }, { "docid": "6ce6c264886796c37fa6e809581c4b48", "score": "0.6189354", "text": "get longitude() {\r\n\t return this._long;\r\n\t }", "title": "" }, { "docid": "5dd296d178c083db1befc4f8e4c150b0", "score": "0.6174862", "text": "function toLatLon(x, y) {\n// const [map_x, map_y] = window_to_svg(x, y);\n\n const tile = findTileXY(x, y);\n\n var lon_t = x % tileSize / tileSize * (tile.topright.long - tile.topleft.long) + tile.topleft.long;\n var lon_b = x % tileSize / tileSize * (tile.bottomright.long - tile.bottomleft.long) + tile.bottomleft.long;\n var lat_l = y % tileSize / tileSize * (tile.bottomleft.lat - tile.topleft.lat) + tile.topleft.lat;\n var lat_r = y % tileSize / tileSize * (tile.bottomright.lat - tile.topright.lat) + tile.topright.lat;\n\n var lon = lon_t + ((lon_b - lon_t) / (tile.bottomleft.lat - tile.topleft.lat) * (lat_l - tile.topleft.lat));\n var lat = lat_l + ((lat_r - lat_l) / (tile.topright.long - tile.topleft.long) * (lon_t - tile.topleft.long));\n\n return [lat, lon];\n }", "title": "" }, { "docid": "428eb35cab1b3c53d0baa192b9789834", "score": "0.6174721", "text": "getSatCoords() {\n const { tle } = this.state;\n const tleStr = tle;\n const timestampMS = Date.now();\n const latLonObj = tlejs.getLatLon(tleStr, timestampMS);\n this.setState({ coords: latLonObj });\n return latLonObj;\n }", "title": "" }, { "docid": "502ae377d2e35579b1b0c5fb0c228118", "score": "0.61668825", "text": "function translateSimpleToRealCoord(latlng){\r\n\t\tvar lat;\r\n\t\tvar lng;\r\n\t\tlat = latlng.lat - centerlatlng.lat;\r\n\t\tlng = latlng.lng - centerlatlng.lng;\r\n\t\t\r\n\t\treturn L.latLng([lat,lng]);\r\n\t}", "title": "" }, { "docid": "a789185f18cf383ddf735f43738f3742", "score": "0.61643064", "text": "function findLat(lat){\n\treturn ((imgHaut-lat)/imgHaut*(imgLATmax-imgLATmin)+imgLATmin);\n}", "title": "" }, { "docid": "5a866541945b526a8612ce62a8fa451b", "score": "0.61411905", "text": "function coord2leaflet(x, y) {\n // calibration\n var lat1_google = 41.994599,\n long1_google = -87.660353,\n lat2_google = 42.001569,\n long2_google = -87.658586,\n lat1_leaf2 = -251,\n long1_leaf2 = 28,\n lat2_leaf2 = -55,\n long2_leaf2 = 68;\n\n var alpha_long_google = (long2_leaf2 - long1_leaf2) / (long2_google - long1_google);\n var alpha_lat_google = (lat2_leaf2 - lat1_leaf2) / (lat2_google - lat1_google);\n\n return [(alpha_lat_google * (x - lat1_google) + lat1_leaf2 ), (alpha_long_google * (y - long1_google) + long1_leaf2)]\n}", "title": "" }, { "docid": "9f5a5b8f6919ee6a7d8ce039e4b70176", "score": "0.6140248", "text": "function p2ll(p)\n{\n var ll = p.toString();\n var n = ll.indexOf(','); \n var lat = ll.slice(1, n);\n var lon = ll.slice(n+2, ll.length-1);\n return [lat, lon];\n}", "title": "" }, { "docid": "cf29bd92d983231ce03f12613812615d", "score": "0.6093222", "text": "function getLon() {\n const defaultLat = -79.92235920000002\n\n try {\n var lat = new URL(document.URL).searchParams.get('lon')\n console.log('longitud', lat)\n\n if (lat === null || lat === undefined || isNaN(lat))\n return defaultLat;\n\n lonEnviada = true;\n return Number(lat);\n } catch (e) {\n return defaultLat;\n }\n}", "title": "" }, { "docid": "7bb93b6c8fac8677dda3132ace1ae85e", "score": "0.608152", "text": "function latlonToTilenumber(lat, lon)\n{\n\tvar n = Math.pow(2, zoom);\n\tlat_rad = lat * Math.PI / 180;\n\treturn {\n\t\t\"x\": Math.floor(n * ((lon + 180) / 360)), \n\t\t\"y\": Math.floor(n * (1 - (Math.log(Math.tan(lat_rad) + 1/Math.cos(lat_rad)) / Math.PI)) / 2) }\n}", "title": "" }, { "docid": "67e0e38f120b32be241fd69b9e91a4b7", "score": "0.60794485", "text": "function getCoords(point) {\n return [Number(point.lat.toFixed(4)), Number(point.lng.toFixed(4))];\n }", "title": "" }, { "docid": "321ba897556e246337d94ab323e22eaf", "score": "0.6061066", "text": "function getLatLngCoords(x, y) {\n\n var diffLat = LAT_MAX - LAT_MIN;\n var diffLng = LON_MAX - LON_MIN;\n\n var latlng = new google.maps.LatLng(LAT_MIN + diffLat * x, LON_MIN + diffLng * y);\n\n return latlng;\n}", "title": "" }, { "docid": "cf86d6ef358e66ce005d38337134bd95", "score": "0.6051833", "text": "function CTE_latitude(location) {\n if (location === 'peninsula') return CTE_LATPENINSULA;\n if (location === 'canarias') return CTE_LATCANARIAS;\n return null;\n}", "title": "" }, { "docid": "f107e29475c6a0427a1e41917101c05f", "score": "0.60499734", "text": "get longitude() {\n return this.jn;\n }", "title": "" }, { "docid": "d47ccde7344be36bcc0a94640a92305d", "score": "0.6046846", "text": "function latLong(num){\n\tvar url = \"https://api.mapbox.com/geocoding/v5/mapbox.places/\" + num + \".json?access_token=\" + MAPBOXPK + \"&types=postcode&country=us\" //\"&country=us&limit=2&types=postcode\"\n\treturn axios.get(url)\n}", "title": "" }, { "docid": "3e98c6d199e2d88e634ebb1b5bc3aaf1", "score": "0.60417783", "text": "get longitude() {\n return this._long;\n }", "title": "" }, { "docid": "f3eef6c260ffac2909c8df329adb161b", "score": "0.60398805", "text": "function mercX(lon) {\n // converts longitude from degrees to radians since\n // the formula expects radians to correctly convert\n // the longitude\n // https://p5js.org/reference/#/p5/radians\n lon = radians(lon);\n\n // https://p5js.org/reference/#/p5/pow\n var a = (256 / PI) * pow(2, zoom);\n var b = lon + PI;\n return a * b;\n}", "title": "" }, { "docid": "ae6800a248a3c1b3d95397753630eeb8", "score": "0.60384476", "text": "function getPointFromLongLatHidro(lat, long) {\r\n return ol.proj.transform([long, lat], 'EPSG:4326', 'EPSG:3857');\r\n}", "title": "" }, { "docid": "5df37a8fc14e2cb47535aa1e965ea591", "score": "0.60377985", "text": "get longitude() {\n return this.oe;\n }", "title": "" }, { "docid": "780772bd188cd71fef508814031d854a", "score": "0.6016269", "text": "function returnLatLon() {\n\n return new Promise(function (resolve, reject) {\n\n function success(position) {\n \n let latLon = [];\n \n latLon[0] = position.coords.latitude;\n latLon[1] = position.coords.longitude;\n \n resolve(latLon);\n \n }\n \n function failure(err) {\n\n reject(err);\n \n }\n\n navigator.geolocation.getCurrentPosition(success, failure);\n\n }); \n\n }", "title": "" }, { "docid": "8c705daa8596641587a94ac14c314950", "score": "0.59929305", "text": "function latitude() {\n return 0;\n}", "title": "" }, { "docid": "a7fa82bffc01b7b94f711a6ea3cb0b38", "score": "0.59795743", "text": "function getLatBoundsForSingleCoordinate(latExt) {\n const latMin = latExt[0] - PADDING < GEO_BOUNDS.LAT_MIN ? GEO_BOUNDS.LAT_MIN : latExt[0] - PADDING;\n const latMax = latExt[1] + PADDING > GEO_BOUNDS.LAT_MAX ? GEO_BOUNDS.LAT_MAX : latExt[1] + PADDING;\n return [latMin, latMax];\n}", "title": "" }, { "docid": "54756536c84d8af6261a9b3ac4f7cb64", "score": "0.59633434", "text": "function lat(cd,L,U)\t// lat\n {\n var O = d(cd); O.lat = L; O.lat_shift = U;\n }", "title": "" }, { "docid": "f2aaa3c336506d52db02105683b4708b", "score": "0.59624976", "text": "static getSearchLocationsLatLong() {\n return L.latLng(\n SearchLocations.getSearchLocationsLocation().lat,\n SearchLocations.getSearchLocationsLocation().lng\n );\n }", "title": "" }, { "docid": "061553ac8114db27881256d7f5db8543", "score": "0.59622675", "text": "function codeLatLon() { \n\tstr= document.form_mapa.txtEdLongitud.value+\" , \"+document.form_mapa.txtEdLatitud.value;\n\tlatLng2 = new google.maps.LatLng(document.form_mapa.txtEdLatitud.value ,document.form_mapa.txtEdLongitud.value);\n\tmarker.setPosition(latLng2);\n\tmap2.setCenter(latLng2);\n\tgeocodePosition (latLng2);\n\t// document.form_mapa.direccion.value = str+\" OK\";\n}", "title": "" }, { "docid": "59a9ebd1300131577ae7019e4f002730", "score": "0.594865", "text": "function latLon(lat, lon) {\n return fetch(\n\n \"https://api.openweathermap.org/data/2.5/onecall?\"\n\n +\n\n \"lat=\" + lat +\n\n \"&lon=\" + lon +\n\n \"&units=imperial&appid=8bed639fd98c9152d287e65173b6a1c7\"\n\n\n\n )\n\n}", "title": "" }, { "docid": "a4a168a18b4aeeae3d883350f0d02bf0", "score": "0.5942179", "text": "function LatLong(degLat, degLong) {\r\n if (typeof degLat == 'number' && typeof degLong == 'number') { // numerics\r\n this.lat = degLat * Math.PI / 180;\r\n this.lon = degLong * Math.PI / 180;\r\n } else if (!isNaN(Number(degLat)) && !isNaN(Number(degLong))) { // numerics-as-strings\r\n this.lat = degLat * Math.PI / 180;\r\n this.lon = degLong * Math.PI / 180;\r\n } else { // deg-min-sec with dir'n\r\n this.lat = LatLong.degToRad(degLat);\r\n this.lon = LatLong.degToRad(degLong);\r\n }\r\n}", "title": "" }, { "docid": "29378da163e7130f0b47f609a0a3f8b9", "score": "0.59407526", "text": "function transform(wgLon, wgLat) {\n var mgLoc = {};\n if (!isInChina(wgLon, wgLat)) {\n mgLoc = {\n lat: wgLat,\n lng: wgLon\n };\n return mgLoc;\n }\n var dLat = transformLat(wgLon - 105.0, wgLat - 35.0);\n var dLon = transformLon(wgLon - 105.0, wgLat - 35.0);\n var radLat = wgLat / 180.0 * PI;\n var magic = Math.sin(radLat);\n magic = 1 - ee * magic * magic;\n var sqrtMagic = Math.sqrt(magic);\n dLat = (dLat * 180.0) / ((a * (1 - ee)) / (magic * sqrtMagic) * PI);\n dLon = (dLon * 180.0) / (a / sqrtMagic * Math.cos(radLat) * PI);\n mgLoc = {\n lat: wgLat + dLat,\n lng: wgLon + dLon\n };\n return mgLoc;\n }", "title": "" }, { "docid": "35456aefb77b7a536d75fc798a7263ed", "score": "0.59333247", "text": "function convertToLonLat(coords) {\r\n\treturn ol.proj.transform(coords, 'EPSG:3857', 'EPSG:4326');\r\n}", "title": "" }, { "docid": "c35de1105c07adea7aa6c099c7d9aa6d", "score": "0.5921968", "text": "get lat() {\n if (!this.location) {\n return undefined;\n }\n return this.location.lat;\n }", "title": "" }, { "docid": "7ff4c37329e5c40eda0460688d3df5f6", "score": "0.5896939", "text": "function getBreweryLatLong() {\n marker.setLatLng([brewery.latitude, brewery.longitude])\n}", "title": "" }, { "docid": "e68e51a4add9b0e84791abbd0c2a6acd", "score": "0.5895675", "text": "function getPoints() {\n return gon.latLong.map(function(ll) {\n return new google.maps.LatLng(ll.latitude, ll.longitude)\n });\n}", "title": "" }, { "docid": "06e51f5d11c6107a31ff134bb324d4ff", "score": "0.58892566", "text": "function latLngToGl(latlng) {\n var x = (latlng.lng + 180) * 256 / 360;\n var y = 128 - Math.log(Math.tan((latlng.lat + 90) * Math.PI / 360)) * 128 / Math.PI;\n return {x: x, y: y};\n}", "title": "" }, { "docid": "bc47cec3c595ef52e6ea9497b35dc6de", "score": "0.58814234", "text": "function makell(ll) {\n if (ll.match(llpatt)) {\n var arr = ll.split(\",\");\n var d = new google.maps.LatLng(parseFloat(arr[0]), parseFloat(arr[1]));\n return d;\n }\n return false;\n }", "title": "" }, { "docid": "cff06c9207510aa4719d12aee03dbb0f", "score": "0.5879135", "text": "function getLongitude(x,y){\n return Math.atan2(y, x) * 180 / Math.PI;\n}", "title": "" }, { "docid": "5f9d4dae44bf531aabf02b8d6571632b", "score": "0.58787477", "text": "function mill(lat, lng, c) {\n const radius = 6381372;\n const radDeg = Math.PI / 180;\n return {\n x: radius * (lng - c) * radDeg,\n y: -radius * Math.log(Math.tan((45 + 0.4 * lat) * radDeg)) / 0.8 };\n\n}", "title": "" }, { "docid": "e398e55a83210ccc62d5086cafb63033", "score": "0.5858991", "text": "function getPosition(loc){\n\t//console.log(loc);\n var commaPos = loc.indexOf(',');\n var coordinatesLat = parseFloat(loc.substring(0, commaPos));\n var coordinatesLong = parseFloat(loc.substring(commaPos + 1, loc.length));\n\tvar myLatlng = new OpenLayers.Geometry.Point(coordinatesLong, coordinatesLat).transform( fromProjection, toProjection);\n return myLatlng;\n }", "title": "" }, { "docid": "c0337709556e0f54594b73977cdb7b3a", "score": "0.58300716", "text": "function latLonFunc(latDegrees, lonDegrees) {\n return function() {\n return new neon.util.LatLon(latDegrees,lonDegrees);\n };\n }", "title": "" }, { "docid": "c261258291f75272b4be29e88380581e", "score": "0.5829617", "text": "function coords(lat, lon) {\n tilemd = originTile;\n\n var x_t = ((lon - tilemd.topleft.long) / (tilemd.topright.long - tilemd.topleft.long)) * tileSize;\n var x_b = ((lon - tilemd.bottomleft.long) / (tilemd.bottomright.long - tilemd.bottomleft.long)) * tileSize;\n var y_l = ((lat - tilemd.topleft.lat) / (tilemd.bottomleft.lat - tilemd.topleft.lat)) * tileSize;\n var y_r = ((lat - tilemd.topright.lat) / (tilemd.bottomright.lat - tilemd.topright.lat)) * tileSize;\n\n var x_slope = (x_b - x_t) / tileSize;\n var y_slope = (y_r - y_l) / tileSize;\n\n var x = Math.round((y_l * x_slope + x_t) / (1 - x_slope * y_slope));\n var y = Math.round((x_t * y_slope + y_l) / (1 - y_slope * x_slope));\n\n return [x, y];\n }", "title": "" }, { "docid": "cf9d9e0d76d1e9094c86c065714ce7ed", "score": "0.5818112", "text": "function findPoint(lat, long)\n{\n var x, y;\n \n x = 2887.25763497193*long+341389.93622679;\n \n y = lat*(-3215.46310863896)+109383.596739774;\n \n return {x:x, y:y};\n}", "title": "" }, { "docid": "26fee4c3ef81867390ecb5ec2d2a31a0", "score": "0.5810084", "text": "function getLatitude(latLongForm) {\n var neg = 0;\n var degs = parseFloat(latLongForm[\"latDeg\"].value);\n if (latLongForm[\"latDeg\"].value[0] == '-') {\n neg = 1;\n }\n\n var mins = parseFloat(latLongForm[\"latMin\"].value);\n\n var secs = parseFloat(latLongForm[\"latSec\"].value);\n\n if (neg != 1) {\n var decLat = degs + (mins / 60) + (secs / 3600);\n }\n else if (neg == 1) {\n var decLat = degs - (mins / 60) - (secs / 3600);\n } else {\n return -9999;\n }\n return decLat;\n}", "title": "" }, { "docid": "c7c8c2721c4f41a75c16834c506071a9", "score": "0.5786866", "text": "function Latitude(id) {\n\n this.idGb = id;\n this.posiciones = new Array(7);\n}", "title": "" }, { "docid": "bc0a34805e433ee41567d24ddbc9840f", "score": "0.5777788", "text": "function getGPS () {\n if (!realGPS || realGPS.lat < 57 || realGPS.lat > 58 || realGPS.lon < 14 || realGPS.lon > 15) {\n return undefined\n }\n return coords.compress(realGPS.lat, realGPS.lon, approxHDOP, config.centerLat, config.centerLon, false)\n}", "title": "" }, { "docid": "1052984cc968f57fe8aa9f5ebdf26176", "score": "0.5776892", "text": "get longitude () {\r\n\t\treturn this._longitude;\r\n\t}", "title": "" }, { "docid": "bdc9fddd32c398331b6791b892cb1bec", "score": "0.57754666", "text": "getWeatherLatLong(lat, long){\n const APIKEY = '18aaef05aea27a3ddbb3d40975b82b7a';\n let apiUrl = \"http://api.openweathermap.org/data/2.5/weather?lat=\";\n let urlForApi = apiUrl + lat + \"&lon=\" + long + \"&APPID=\" + APIKEY + \"&units=imperial\";\n this.makeApiCall(urlForApi);\n }", "title": "" }, { "docid": "08864f2fdf7774d5d55c038d4c413aa8", "score": "0.57694083", "text": "function getLongitude(latLongForm) {\n var neg = 0;\n var degs = parseFloat(latLongForm[\"lonDeg\"].value);\n if (latLongForm[\"lonDeg\"].value[0] == '-') {\n neg = 1;\n }\n var mins = parseFloat(latLongForm[\"lonMin\"].value);\n var secs = parseFloat(latLongForm[\"lonSec\"].value);\n var decLon = degs + (mins / 60) + (secs / 3600);\n\n if (neg != 1) {\n var decLon = degs + (mins / 60) + (secs / 3600);\n } else if (neg == 1) {\n var decLon = degs - (mins / 60) - (secs / 3600);\n } else {\n return -9999;\n }\n return decLon;\n}", "title": "" }, { "docid": "152789118f133dcd37aeb55aafed14c6", "score": "0.57681537", "text": "function initCoords(){\n \n if (lcly.map.hasForcedState){\n \n lcly.map.coords = forceMapState;\n \n } else if (typeof forceMapState != 'undefined') {\n \n lcly.map.coords = forceMapState;\n \n } else if (typeof userGeo != 'undefined' && typeof userGeo.lat != 'undefined' && typeof userGeo.lng != 'undefined'){\n \n var zoomParam = parseInt(lcly.conversionModule.getMetaParam('zoom'));\n var initialZoom = zoomParam ? zoomParam : lcly.map.initialZoom;\n lcly.map.coords = [userGeo.lat, userGeo.lng, initialZoom];\n }\n \n if (typeof lcly.map.coords[2] != 'undefined') {\n \n lcly.map.coords[2] = lcly.mapService.zoomValueFor(lcly.map.coords[2]);\n }\n \n // adapt this value upon initialization\n lcly.map.locationSwitchZoom = lcly.mapService.zoomValueFor(lcly.map.locationSwitchZoom);\n }", "title": "" }, { "docid": "793489d0c2a12161684e0048803cadf5", "score": "0.57649845", "text": "function UTMXYToLatLon (x, y, zone, southhemi, latlon)\n{\n var cmeridian;\n\n x -= 500000.0;\n x /= UTMScaleFactor;\n\n /* If in southern hemisphere, adjust y accordingly. */\n if (southhemi)\n y -= 10000000.0;\n\n y /= UTMScaleFactor;\n\n cmeridian = UTMCentralMeridian (zone);\n MapXYToLatLon (x, y, cmeridian, latlon);\n\n return;\n}", "title": "" }, { "docid": "69af43871b74a4a823377a43615c838a", "score": "0.5747131", "text": "function longitude(t) {\n const g = mean_anomaly(t);\n const sin_g = Math.sin(g);\n const sin_2g = Math.sin(2 * g);\n return Q0 + Q1 * t + L0 * sin_g + L1 * sin_2g;\n}", "title": "" }, { "docid": "11dc3cddcf418451a783e7564f067deb", "score": "0.5744381", "text": "function glToLatLng(xy) {\n var lat = Math.atan(Math.exp((128 - xy.y) * Math.PI / 128)) * 360 / Math.PI - 90;\n var lng = xy.x * 360 / 256 - 180;\n return {lat: lat, lng: lng};\n}", "title": "" }, { "docid": "01afae1b994d6a9f475053fa6afaa0b5", "score": "0.5744353", "text": "function coords(s) {\n 'use strict';\n\n var p = s.split('|');\n return new L.latLng(parseFloat(p[0]), parseFloat(p[1]));\n}", "title": "" }, { "docid": "0cefea7f804f594e119498d818b37b65", "score": "0.5743242", "text": "function normalizeLon(lon) {\n return ((((Number(lon) + 180) % 360) + 360) % 360) - 180;\n}", "title": "" }, { "docid": "830d90aeab09574016766462725f4a87", "score": "0.5725523", "text": "fromXYtoLatLng (source){\n\t\tvar cmeridian;\n\t\tvar x = source.x - 500000.0; \n\t\tx /= this.UTMScaleFactor;\n\t \tvar y = source.y;\t\t\t\t\n\t\t/* If in southern hemisphere, adjust y accordingly. */\n\t\tif (source.southhemi)\n\t\t\ty -= 10000000.0;\t\t\t\t\t\n\t\ty /= this.UTMScaleFactor;\t\t\t\n\t\tcmeridian = this.UTMCentralMeridian(source.zone);\n\t\tvar result = this.mapXYToLatLon(x, y, cmeridian);\n\t\treturn [this.radToDeg(result[0]), this.radToDeg(result[1])];\n\t}", "title": "" }, { "docid": "356790a53cf934a65308d4cd79b5b588", "score": "0.5725307", "text": "mercX(lon) {\n\t\tlon = this.radians(lon);\n\t\tvar a = (256 / this.PI) * Math.pow(2, this.zoom);\n\t\tvar b = lon + this.PI;\n\t\treturn a * b;\n\t}", "title": "" }, { "docid": "271a4a64d860d5f046010b6be56d9964", "score": "0.57195884", "text": "function createCoordinate(lat, lng) {\n return [lat, lng];\n}", "title": "" }, { "docid": "08167ed0401aebd5868509a37ca44092", "score": "0.57131284", "text": "function LonLatToBounds(LonLat) {\n\tif (LonLat != null) {\n\t\tvar bounds = new OpenLayers.Bounds();\n\t\tvar latlng = LonLat.split(\";\");\n\n\t\tfor (var i in latlng) {\n\t\t\tvar coord = latlng[i].split(\",\");\n\t\t\tbounds.extend( new OpenLayers.LonLat( coord[0], coord[1]).transform(map2.displayProjection, map2.projection));\n\t\t}\n\t\treturn bounds;\t\n\t}\n\treturn null;\n}", "title": "" }, { "docid": "11b76dad8506b44b34067856259a0e88", "score": "0.5703125", "text": "northEast () { return new GeoCoord(this.east(), this.north()) }", "title": "" }, { "docid": "246748f4f776475e6ad6680234580a04", "score": "0.5702648", "text": "function dccdublinbikesstationsgpscoords(StationName, Lat, Lon) {\n this.FieldOne = StationName;\n this.FieldTwo = Lat;\n this.FieldThree = Lon;\n}", "title": "" }, { "docid": "9713b47d18e7d17d1a38f3b7ab762cc7", "score": "0.56982523", "text": "getX(lng, lat) {\n return Math.round(((this.E * lng) - (this.B * lat) + this.xCorrection) / this.AEDB)\n }", "title": "" }, { "docid": "ddf75c4842aedc7aa117b4a342c78e2a", "score": "0.5689826", "text": "function LatLng(lat, lng) {\n this.lat = lat;\n this.lng = lng;\n \n this.distance = LatLngDistance;\n \n this.toOSRef = LatLngToOSRef;\n this.toUTMRef = LatLngToUTMRef;\n \n this.WGS84ToOSGB36 = WGS84ToOSGB36;\n this.OSGB36ToWGS84 = OSGB36ToWGS84;\n \n this.toString = LatLngToString;\n}", "title": "" }, { "docid": "8e427401329eecd5569b222d8d615946", "score": "0.56863797", "text": "function getConstLocation(value) {\r\n //\"Internet: N/A<br>Location: 48.8824615, 2.3498469<br>Phone: N/A<br>Type: hotel\"\r\n var latitude = value.match(\"lat (.*),\")[1];\r\n var longitude = value.match(\"lng (.*)<br><b>P\")[1];\r\n\r\n const myLatLng = { lat: parseFloat(latitude), lng: parseFloat(longitude) };\r\n return myLatLng\r\n}", "title": "" }, { "docid": "8614532dcd710637b5990dae7a19491d", "score": "0.5684124", "text": "getLatLng () {\n return new google.maps.LatLng(this.configuration.latitude, this.configuration.longitude)\n }", "title": "" }, { "docid": "b7fa1fcf0b5c6b84c7932de909927a41", "score": "0.5681037", "text": "function x(d) { return d.longitude; }", "title": "" }, { "docid": "779c5b8a66e13fdc60db8d7e11fdb98b", "score": "0.568102", "text": "function getLngLatFromSiteName(pointName) {\n return 'lat: '+coordlist[pointName].lat + ' | lng: '+coordlist[pointName].lng;\n }", "title": "" }, { "docid": "c75d2a4986a19f415c5191916da6197b", "score": "0.5678813", "text": "static toStringLon(coordinate) {\n let val = Math.abs(coordinate);\n let str = val < 100 ? val.toFixed(1) : val.toFixed(0);\n return coordinate > 0 ? str + \"°E\" : str + \"°W\";\n }", "title": "" }, { "docid": "03b8d52edfd42bcd588cc807caf9abb8", "score": "0.56760323", "text": "function meterToLatLng(mx, my){\r\n\t\tvar lng = (mx / originShift) * 180.0\r\n var lat = (my / originShift) * 180.0\r\n\t\tlat = 180 / Math.PI * (2 * Math.atan( Math.exp( lat * Math.PI / 180.0)) - Math.PI / 2.0)\r\n return {lat:lat, lng:lng};\r\n\t}", "title": "" }, { "docid": "e46678d7245c63f3ff8266759fe3ee62", "score": "0.5661655", "text": "get viewCoordinates() {\n\t\tlet ap = this.availablePlaces;\n\t\tif (!this.isNullOrZero(ap)) {\n\t\t\tlet x = () => {\n\t\t\t\tlet lx = ap.map(p => p.latitude).filter(x => x != null && x != 0);\n\t\t\t\treturn (Math.min(...lx) + Math.max(...lx)) / 2;\n\t\t\t}\n\t\t\tlet y = () => {\n\t\t\t\tlet ly = ap.map(p => p.longitude).filter(x => x != null && x != 0);\n\t\t\t\treturn (Math.min(...ly) + Math.max(...ly)) / 2;\n\t\t\t}\n\t\t\tlet xResult = x();\n\t\t\tlet yResult = y();\n\t\t\tif (!isNaN(xResult) && !isNaN(yResult)) {\n\t\t\t\treturn [xResult, yResult];\n\t\t\t}\n\t\t}\n\t\treturn [44.0521,-123.0868];\n\t}", "title": "" }, { "docid": "cee29084ecb5f9bd602068e81340e9a5", "score": "0.56584924", "text": "function longitude_julian(l) {\n // Make an initial guess based on the mean longitude.\n let t = (l - Q0) / Q1;\n\n // Iteratively improve the guess using Newton's method. (I've never seen\n // any significant accuracy improvement past two iterations, so I use\n // three, just to be safe. :) )\n t = t - (longitude(t) - l) / longitude_prime(t);\n t = t - (longitude(t) - l) / longitude_prime(t);\n t = t - (longitude(t) - l) / longitude_prime(t);\n\n return t;\n}", "title": "" }, { "docid": "c0f7a0c4987549e52b8243c9c687a0e3", "score": "0.5657883", "text": "function getLatitude()\r\r\n{\r\r\n\treturn document.frm_dashboard_mapa.latitude.value;\r\r\n\t// return BAIRES_LATITUD;\r\r\n}", "title": "" }, { "docid": "4113e4186f0eb6a7453150f3d2305349", "score": "0.56442666", "text": "get latitude() {\n return this.N_;\n }", "title": "" }, { "docid": "e2128dcf802b1f9cd91536146426ab45", "score": "0.5636413", "text": "function _longitude_prime(t) {\n const g = _mean_anomaly(t);\n const cos_g = Math.cos(g);\n const cos_2g = 2 * cos_g * cos_g - 1;\n return Q1 + G1 * (L0 * cos_g + 2 * L1 * cos_2g);\n}", "title": "" }, { "docid": "bcf18dcb4840840b0c15c22b0936803c", "score": "0.5635617", "text": "function hexToLatLong(hexValue) {\n return hexValue / (60 * 30000.0);\n}", "title": "" }, { "docid": "831303aa912354c5b7f512e03622f379", "score": "0.5632387", "text": "function getLatLong(position){\n var crd = position.coords;\n\n // console.log('Your current position is:');\n // console.log(`Latitude : ${crd.latitude}`);\n // console.log(`Longitude: ${crd.longitude}`);\n // call handleWeather to form the querystring\n handleWeather(crd.latitude, crd.longitude)\n}", "title": "" }, { "docid": "8d42dca2472a50411743c4c30c5b2c52", "score": "0.56304014", "text": "function buildCoordString2(point) {\n var northamerica=1\n var ngCoords = LLtoUSNG(point.y,point.x, 5);\n var mgrsCoords = LLtoMGRS(point.y,point.x, 5);\n\tvar utmcoords=[]\n\tvar zone\n \tLLtoUTM(point.y,point.x,utmcoords,0)\n\tzone = utmcoords[2]\n\t\n\t// decimal degrees. Originally in buildCoordString1, moved here because D-M.mm is NSARC standard\n var preclng = point.lng().toFixed(precision+2);\n var precLat = point.lat().toFixed(precision+2);\n \t\tcoordStr += \"<br\\/><i>D.d:</i> \"+precLat+ \",\"+preclng;\n\t\n\t//alert(LLtoGARS(point.y,point.x))\n\n if (point.y>13 && point.y<90 && ((point.x<-46 && point.x>-180) || (point.x>169 && point.x<180))) { \n northamerica = 1\n }\n else {\n northamerica = 0\n }\n\n\t//utm coordinates\n\tvar utmx = utmcoords[0];\n var utmy = utmcoords[1];\n\tif (utmy < 0) { utmy+=10000000; }\n\tlatLngStr = \"<i>UTM (zone,x,y)</i>: \" + zone + UTMLetterDesignator(point.y)+\", \" + utmx.toFixed(0) + \", \" + utmy.toFixed(0);\n\n // deg-min-sec\n latLngStr += \"<br><i>D-M-S</i>: \" + lat2dms(point.y)+\", \" + lon2dms(point.x)\n \n\t// GARS\n\tlatLngStr += \"<br><i>GARS:</i> \" + LLtoGARS(point.y,point.x)\n\n return(latLngStr)\n}", "title": "" }, { "docid": "4a5978d3621b906cd459ac3ff65d7904", "score": "0.56266344", "text": "function nylon() {\n}", "title": "" }, { "docid": "d59597485cc834f962c2fb60b63400f3", "score": "0.561828", "text": "function makeRangeBox(lon, lat) {\n var clipPad = constants.clipPad;\n var lon0 = lon[0] + clipPad;\n var lon1 = lon[1] - clipPad;\n var lat0 = lat[0] + clipPad;\n var lat1 = lat[1] - clipPad;\n\n // to cross antimeridian w/o ambiguity\n if(lon0 > 0 && lon1 < 0) lon1 += 360;\n\n var dlon4 = (lon1 - lon0) / 4;\n\n return {\n type: 'Polygon',\n coordinates: [[\n [lon0, lat0],\n [lon0, lat1],\n [lon0 + dlon4, lat1],\n [lon0 + 2 * dlon4, lat1],\n [lon0 + 3 * dlon4, lat1],\n [lon1, lat1],\n [lon1, lat0],\n [lon1 - dlon4, lat0],\n [lon1 - 2 * dlon4, lat0],\n [lon1 - 3 * dlon4, lat0],\n [lon0, lat0]\n ]]\n };\n}", "title": "" }, { "docid": "fff5b0b126105b6b203c9a866692f8dc", "score": "0.56173915", "text": "function latLonFunction(response) {\n\tunixDateTime = (response.dt);\n\tdateObject = new Date(unixDateTime * 1000);\n\tdate = (\"(\" + (dateObject.getMonth() + 1) + \"/\" + dateObject.getDate() + \"/\" + dateObject.getFullYear() + \")\");\n\t$(\".current-city-info\").text(response.name + \" \" + date);\n\t// stores lat and lon so that we can query the onecall api for the rest of the info\n\tlat = (response.coord.lat);\n\tlon = (response.coord.lon);\n}", "title": "" }, { "docid": "ceeff2c654fc466226df24449c3e8de7", "score": "0.56134665", "text": "function getLongitude(lonDeg, lonMin, lonSec)\r\n\t{\r\n\t\tvar neg = 0;\r\n\t\tvar degs = parseFloat(lonDeg);\r\n\t\tif (String(lonDeg).charAt(0) == '-') \r\n\t\t{\r\n\t\t\tneg = 1;\r\n\t\t}\r\n\r\n\t\tvar mins = parseFloat(lonMin);\r\n\t\tvar secs = parseFloat(lonSec);\r\n\r\n\t\tvar decLon;\r\n\t\tif(neg != 1)\r\n\t\t{\r\n\t\t\tvar decLon = degs + (mins / 60) + (secs / 3600);\r\n\t\t} else if(neg == 1)\r\n\t\t{\r\n\t\t\tvar decLon = degs - (mins / 60) - (secs / 3600);\r\n\t\t} else \r\n\t\t{\r\n\t\t\treturn -9999;\r\n\t\t}\r\n\t\treturn decLon;\r\n\t}", "title": "" }, { "docid": "1e4a400dbc30fcb557f3b7852a459c78", "score": "0.56104606", "text": "function XYZToLngLat([x, y, z]) {\n const lat = Math.atan2(z, Math.sqrt(x * x + y * y));\n const lng = Math.atan2(y, x);\n\n return [lng * RADIAN_TO_DEGREE, lat * RADIAN_TO_DEGREE];\n}", "title": "" }, { "docid": "3884e95ff78be8c3b103b3e5ff71d5ef", "score": "0.5605825", "text": "function makeLatLng(lat, lng) {\n return {\n lat: lat,\n lng: lng\n };\n}", "title": "" }, { "docid": "cba559dd2cc9d250acb80314aee766d2", "score": "0.56055874", "text": "function lonToX(lon, zoom) {\n var offset = 256 << (zoom - 1);\n return Math.floor(offset + (offset * lon / 180));\n}", "title": "" }, { "docid": "2229341409fe5ef3308025e8b229a7a9", "score": "0.56046623", "text": "function convLatLong(f) {\n var neg = 0;\n if (f[\"latDeg\"].value[0] == '-') {\n neg = 1;\n }\n\n if (neg != 1) {\n var latSeconds = (parseFloat(f[\"latDeg\"].value)) * 3600\n + parseFloat(f[\"latMin\"].value) * 60\n + parseFloat(f[\"latSec\"].value) * 1;\n\n f[\"latDeg\"].value = Math.floor(latSeconds / 3600);\n f[\"latMin\"].value = Math.floor((latSeconds\n - (parseFloat(f[\"latDeg\"].value) * 3600)) / 60);\n f[\"latSec\"].value = Math.floor((latSeconds\n - (parseFloat(f[\"latDeg\"].value) * 3600)\n - (parseFloat(f[\"latMin\"].value) * 60)) + 0.5);\n }\n else if (parseFloat(f[\"latDeg\"].value) > -1) {\n var latSeconds = parseFloat(f[\"latDeg\"].value) * 3600\n - parseFloat(f[\"latMin\"].value) * 60\n - parseFloat(f[\"latSec\"].value) * 1;\n\n f[\"latDeg\"].value = \"-0\";\n f[\"latMin\"].value = Math.floor((-latSeconds) / 60);\n f[\"latSec\"].value = Math.floor((-latSeconds\n - (parseFloat(f[\"latMin\"].value) * 60)) + 0.5);\n\n }\n else {\n var latSeconds = parseFloat(f[\"latDeg\"].value) * 3600\n - parseFloat(f[\"latMin\"].value) * 60\n - parseFloat(f[\"latSec\"].value) * 1;\n\n f[\"latDeg\"].value = Math.ceil(latSeconds / 3600);\n f[\"latMin\"].value = Math.floor((-latSeconds\n + (parseFloat(f[\"latDeg\"].value) * 3600)) / 60);\n f[\"latSec\"].value = Math.floor((-latSeconds\n + (parseFloat(f[\"latDeg\"].value) * 3600)\n - (parseFloat(f[\"latMin\"].value) * 60)) + 0.5);\n }\n\n neg = 0;\n if (f[\"lonDeg\"].value[0] == '-') {\n neg = 1;\n }\n\n if (neg != 1) {\n var lonSeconds = parseFloat(f[\"lonDeg\"].value) * 3600\n + parseFloat(f[\"lonMin\"].value) * 60\n + parseFloat(f[\"lonSec\"].value) * 1;\n f[\"lonDeg\"].value = Math.floor(lonSeconds / 3600);\n f[\"lonMin\"].value = Math.floor((lonSeconds\n - (parseFloat(f[\"lonDeg\"].value) * 3600)) / 60);\n f[\"lonSec\"].value = Math.floor((lonSeconds\n - (parseFloat(f[\"lonDeg\"].value) * 3600)\n - (parseFloat(f[\"lonMin\"].value)) * 60) + 0.5);\n }\n else if (parseFloat(f[\"lonDeg\"].value) > -1) {\n var lonSeconds = parseFloat(f[\"lonDeg\"].value) * 3600\n - parseFloat(f[\"lonMin\"].value) * 60\n - parseFloat(f[\"lonSec\"].value) * 1;\n\n f[\"lonDeg\"].value = \"-0\";\n f[\"lonMin\"].value = Math.floor((-lonSeconds) / 60);\n f[\"lonSec\"].value = Math.floor((-lonSeconds\n - (parseFloat(f[\"lonMin\"].value) * 60)) + 0.5);\n }\n else {\n var lonSeconds = parseFloat(f[\"lonDeg\"].value) * 3600\n - parseFloat(f[\"lonMin\"].value) * 60\n - parseFloat(f[\"lonSec\"].value) * 1;\n f[\"lonDeg\"].value = Math.ceil(lonSeconds / 3600);\n f[\"lonMin\"].value = Math.floor((-lonSeconds\n + (parseFloat(f[\"lonDeg\"].value) * 3600)) / 60);\n f[\"lonSec\"].value = Math.floor((-lonSeconds\n + (parseFloat(f[\"lonDeg\"].value) * 3600)\n - (parseFloat(f[\"lonMin\"].value) * 60)) + 0.5);\n }\n\n //Test for invalid lat/long input\n\n if (latSeconds > 324000) {\n alert(\"You have entered an invalid latitude.\\n Setting lat= 89.8.\");\n f[\"latDeg\"].value = 89.8;\n f[\"latMin\"].value = 0;\n f[\"latSec\"].value = 0;\n }\n if (latSeconds < -324000) {\n alert(\"You have entered an invalid latitude.\\n Setting lat= -89.8.\");\n f[\"latDeg\"].value = -89.8;\n f[\"latMin\"].value = 0;\n f[\"latSec\"].value = 0;\n }\n if (lonSeconds > 648000) {\n alert(\"You have entered an invalid longitude.\\n Setting lon= 180.\");\n f[\"lonDeg\"].value = 180;\n f[\"lonMin\"].value = 0;\n f[\"lonSec\"].value = 0;\n }\n if (lonSeconds < -648000) {\n alert(\"You have entered an invalid longitude.\\n Setting lon= -180.\");\n f[\"lonDeg\"].value = -180;\n f[\"lonMin\"].value = 0;\n f[\"lonSec\"].value = 0;\n }\n\n}", "title": "" } ]
e534a37e5347c80483fe675cc9bbfda5
When the socket is upgraded while we're probing
[ { "docid": "bb23107a168ead6766d36ff164b1363f", "score": "0.58264995", "text": "function onupgrade(to){\n\t if (transport && to.name != transport.name) {\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n\t freezeTransport();\n\t }\n\t }", "title": "" } ]
[ { "docid": "bde67950e61f2fb1920bc6509edd0e36", "score": "0.64771235", "text": "upgrade(value) {\n this.socket.emit('upgrade', value);\n }", "title": "" }, { "docid": "743e9dedaef2f43f4c00c91cd9124d02", "score": "0.6243038", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush(); // we check for `readyState` in case an `open`\n // listener already closed the socket\n\n if (\"open\" === this.readyState && this.opts.upgrade && this.transport.pause) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "83297aef95b19cf9ebd7b71b8bc0a61e", "score": "0.6192839", "text": "#upgrade(req, socket) {\n\t\tif(is_banned(req.client.remoteAddress)) {\n\t\t\t// TODO: Log this?\n\t\t\tsocket.destroy(); // Immediately terminate the connection\n\t\t\treturn;\n\t\t}\n\n\t\tif(req.headers.upgrade?.toLowerCase() !== 'websocket' || !ServerAuth.is_authorized(req)) {\n\t\t\tsocket.destroy();\n\t\t\treturn;\n\t\t}\n\n\t\t// Accept the connection\n\t\tconst accept = generate_ws_accept(req.headers);\n\n\t\tsocket.write([\n\t\t\t'HTTP/1.1 101 Switching Protocols',\n\t\t\t'Upgrade: WebSocket',\n\t\t\t'Connection: Upgrade',\n\t\t\t`Sec-WebSocket-Accept: ${accept}`\n\t\t].join('\\r\\n') + '\\r\\n\\r\\n');\n\n\t\t// Add the socket to the correct connection list\n\t\tconst url = parse_url(req.url);\n\n\t\tthis.#clean_connections(url.path);\n\t\tconst index = this.#add_connection(url.path, socket);\n\n\t\t// Handle socket events\n\t\tsocket.on('data', this.#data.bind(this, { path: url.path, index }));\n\n\t\tsocket.on('error', (err) => {\n\t\t\tthis.#emitter.emit('error', {\n\t\t\t\tmessage: err.message,\n\t\t\t\tpath: url.path,\n\t\t\t\tindex,\n\t\t\t\tsocket\n\t\t\t});\n\t\t});\n\t}", "title": "" }, { "docid": "23b47f02a8030af9c0f1b3d5038f1728", "score": "0.6122434", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\n \"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause\n ) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "23b47f02a8030af9c0f1b3d5038f1728", "score": "0.6122434", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\n \"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause\n ) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "23b47f02a8030af9c0f1b3d5038f1728", "score": "0.6122434", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\n \"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause\n ) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "23b47f02a8030af9c0f1b3d5038f1728", "score": "0.6122434", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\n \"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause\n ) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "23b47f02a8030af9c0f1b3d5038f1728", "score": "0.6122434", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\n \"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause\n ) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "fc0193f98d273c3b70e999899fa11e4f", "score": "0.60570544", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\"open\" === this.readyState && this.opts.upgrade && this.transport.pause) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for(; i < l; i++)this.probe(this.upgrades[i]);\n }\n }", "title": "" }, { "docid": "6262a11f4538dc726073ac619f296965", "score": "0.60447806", "text": "onOpen() {\n debug(\"socket open\");\n this.readyState = \"open\";\n Socket.priorWebsocketSuccess = \"websocket\" === this.transport.name;\n this.emit(\"open\");\n this.flush();\n\n // we check for `readyState` in case an `open`\n // listener already closed the socket\n if (\n \"open\" === this.readyState &&\n this.opts.upgrade &&\n this.transport.pause\n ) {\n debug(\"starting upgrade probes\");\n let i = 0;\n const l = this.upgrades.length;\n for (; i < l; i++) {\n this.probe(this.upgrades[i]);\n }\n }\n }", "title": "" }, { "docid": "8bb93a6fafd66a69ec743ef20f348fa5", "score": "0.5962921", "text": "onOpen() {\n if (this.readyState = \"open\", lr.priorWebsocketSuccess = this.transport.name === \"websocket\", this.emitReserved(\"open\"), this.flush(), this.readyState === \"open\" && this.opts.upgrade) {\n let t = 0;\n const e = this.upgrades.length;\n for (; t < e; t++)\n this.probe(this.upgrades[t]);\n }\n }", "title": "" }, { "docid": "d15a67ecf92824547e5b16f1de6d0013", "score": "0.59583485", "text": "handleUpgrade(req, socket, upgradeHead) {\n this.prepare(req);\n\n const self = this;\n this.verify(req, true, function(err, success) {\n if (!success) {\n abortConnection(socket, err);\n return;\n }\n\n const head = Buffer.from(upgradeHead); // eslint-disable-line node/no-deprecated-api\n upgradeHead = null;\n\n // delegate to ws\n self.ws.handleUpgrade(req, socket, head, function(conn) {\n self.onWebSocket(req, conn);\n });\n });\n }", "title": "" }, { "docid": "d4fe63b1e7ebbc8559958d5a56841c7a", "score": "0.5953515", "text": "function onerror (err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\n\t freezeTransport();\n\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "ec5a2f332b5e4ce59521051389341378", "score": "0.5814435", "text": "function onerror (err) {\r\n\t var error = new Error('probe error: ' + err);\r\n\t error.transport = transport.name;\r\n\t\r\n\t freezeTransport();\r\n\t\r\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\r\n\t\r\n\t self.emit('upgradeError', error);\r\n\t }", "title": "" }, { "docid": "c6f4d1cb0d1ffa7fa87224338740a228", "score": "0.5787291", "text": "function onupgrade(to) {\n\t if (transport && to.name != transport.name) {\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n\t freezeTransport();\n\t }\n\t }", "title": "" }, { "docid": "47e3fcd2f6f68974267b3b61dd779d9a", "score": "0.57777244", "text": "onSocketFullyConnected() {\n this.debugOut('socketFullyConnected()');\n this.last_socket_error = null;\n this.connected = true;\n this.emit('open');\n }", "title": "" }, { "docid": "47e3fcd2f6f68974267b3b61dd779d9a", "score": "0.57777244", "text": "onSocketFullyConnected() {\n this.debugOut('socketFullyConnected()');\n this.last_socket_error = null;\n this.connected = true;\n this.emit('open');\n }", "title": "" }, { "docid": "b089157ab7ba1fb36fc4efd68e02398c", "score": "0.57733727", "text": "function onerror (err) {\r\n\t var error = new Error('probe error: ' + err);\r\n\t error.transport = transport.name;\r\n\r\n\t freezeTransport();\r\n\r\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\r\n\r\n\t self.emit('upgradeError', error);\r\n\t }", "title": "" }, { "docid": "103293c53ef1b692cc2b88d8651491d6", "score": "0.5773097", "text": "connectedCallback() {\n if (!this.__isUpgradeDisabled) {\n super.connectedCallback();\n }\n }", "title": "" }, { "docid": "103293c53ef1b692cc2b88d8651491d6", "score": "0.5773097", "text": "connectedCallback() {\n if (!this.__isUpgradeDisabled) {\n super.connectedCallback();\n }\n }", "title": "" }, { "docid": "103293c53ef1b692cc2b88d8651491d6", "score": "0.5773097", "text": "connectedCallback() {\n if (!this.__isUpgradeDisabled) {\n super.connectedCallback();\n }\n }", "title": "" }, { "docid": "acaa442b9b8ff2dbdadd7d9fdc3ef5d1", "score": "0.5757047", "text": "function onupgrade(to) {\n\t if (transport && to.name !== transport.name) {\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n\t freezeTransport();\n\t }\n\t }", "title": "" }, { "docid": "42e7a05363a9a92562cf455293236c4b", "score": "0.5721342", "text": "function onerror (err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\t\n\t freezeTransport();\n\t\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\t\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "42e7a05363a9a92562cf455293236c4b", "score": "0.5721342", "text": "function onerror (err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\t\n\t freezeTransport();\n\t\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\t\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "42e7a05363a9a92562cf455293236c4b", "score": "0.5721342", "text": "function onerror (err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\t\n\t freezeTransport();\n\t\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\t\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "55ec599a3e579d91b11c4b1b67d74fd1", "score": "0.57026625", "text": "function onerror(err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\t\n\t freezeTransport();\n\t\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\t\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "55ec599a3e579d91b11c4b1b67d74fd1", "score": "0.57026625", "text": "function onerror(err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\t\n\t freezeTransport();\n\t\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\t\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "5a8f774801979a644527835dc8c7bf4f", "score": "0.56939304", "text": "function devicelost() {}", "title": "" }, { "docid": "0c5b755d371e8671516af7fa47aec160", "score": "0.56838506", "text": "function handleHybiUpgrade(req,socket,upgradeHead,cb){// handle premature socket errors\nvar errorHandler=function errorHandler(){try{socket.destroy();}catch(e){}};socket.on('error',errorHandler);// verify key presence\nif(!req.headers['sec-websocket-key']){abortConnection(socket,400,'Bad Request');return;}// verify version\nvar version=parseInt(req.headers['sec-websocket-version']);if([8,13].indexOf(version)===-1){abortConnection(socket,400,'Bad Request');return;}// verify protocol\nvar protocols=req.headers['sec-websocket-protocol'];// verify client\nvar origin=version<13?req.headers['sec-websocket-origin']:req.headers['origin'];// handle extensions offer\nvar extensionsOffer=Extensions.parse(req.headers['sec-websocket-extensions']);// handler to call when the connection sequence completes\nvar self=this;var completeHybiUpgrade2=function completeHybiUpgrade2(protocol){// calc key\nvar key=req.headers['sec-websocket-key'];var shasum=crypto.createHash('sha1');shasum.update(key+\"258EAFA5-E914-47DA-95CA-C5AB0DC85B11\");key=shasum.digest('base64');var headers=['HTTP/1.1 101 Switching Protocols','Upgrade: websocket','Connection: Upgrade','Sec-WebSocket-Accept: '+key];if(typeof protocol!='undefined'){headers.push('Sec-WebSocket-Protocol: '+protocol);}var extensions={};try{extensions=acceptExtensions.call(self,extensionsOffer);}catch(err){abortConnection(socket,400,'Bad Request');return;}if(Object.keys(extensions).length){var serverExtensions={};Object.keys(extensions).forEach(function(token){serverExtensions[token]=[extensions[token].params];});headers.push('Sec-WebSocket-Extensions: '+Extensions.format(serverExtensions));}// allows external modification/inspection of handshake headers\nself.emit('headers',headers);socket.setTimeout(0);socket.setNoDelay(true);try{socket.write(headers.concat('','').join('\\r\\n'));}catch(e){// if the upgrade write fails, shut the connection down hard\ntry{socket.destroy();}catch(e){}return;}var client=new WebSocket([req,socket,upgradeHead],{protocolVersion:version,protocol:protocol,extensions:extensions});if(self.options.clientTracking){self.clients.push(client);client.on('close',function(){var index=self.clients.indexOf(client);if(index!=-1){self.clients.splice(index,1);}});}// signal upgrade complete\nsocket.removeListener('error',errorHandler);cb(client);};// optionally call external protocol selection handler before\n// calling completeHybiUpgrade2\nvar completeHybiUpgrade1=function completeHybiUpgrade1(){// choose from the sub-protocols\nif(typeof self.options.handleProtocols=='function'){var protList=(protocols||\"\").split(/, */);var callbackCalled=false;var res=self.options.handleProtocols(protList,function(result,protocol){callbackCalled=true;if(!result)abortConnection(socket,401,'Unauthorized');else completeHybiUpgrade2(protocol);});if(!callbackCalled){// the handleProtocols handler never called our callback\nabortConnection(socket,501,'Could not process protocols');}return;}else{if(typeof protocols!=='undefined'){completeHybiUpgrade2(protocols.split(/, */)[0]);}else{completeHybiUpgrade2();}}};// optionally call external client verification handler\nif(typeof this.options.verifyClient=='function'){var info={origin:origin,secure:typeof req.connection.authorized!=='undefined'||typeof req.connection.encrypted!=='undefined',req:req};if(this.options.verifyClient.length==2){this.options.verifyClient(info,function(result,code,name){if(typeof code==='undefined')code=401;if(typeof name==='undefined')name=http.STATUS_CODES[code];if(!result)abortConnection(socket,code,name);else completeHybiUpgrade1();});return;}else if(!this.options.verifyClient(info)){abortConnection(socket,401,'Unauthorized');return;}}completeHybiUpgrade1();}", "title": "" }, { "docid": "a82f8c12ba3b6a2a46e1250c1e2efab4", "score": "0.56805366", "text": "function onupgrade (to) {\n\t if (transport && to.name !== transport.name) {\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n\t freezeTransport();\n\t }\n\t }", "title": "" }, { "docid": "a82f8c12ba3b6a2a46e1250c1e2efab4", "score": "0.56805366", "text": "function onupgrade (to) {\n\t if (transport && to.name !== transport.name) {\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n\t freezeTransport();\n\t }\n\t }", "title": "" }, { "docid": "a82f8c12ba3b6a2a46e1250c1e2efab4", "score": "0.56805366", "text": "function onupgrade (to) {\n\t if (transport && to.name !== transport.name) {\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n\t freezeTransport();\n\t }\n\t }", "title": "" }, { "docid": "7cd69486e7fc106e2d9045e57dffe4b6", "score": "0.5662002", "text": "function onUpgrade(request, socket, head) {\n const { uuid } = getParams(request.url);\n authenticate(uuid, (err, client) => {\n if (err || !client) {\n const errorIsSend = socket.write('HTTP/1.1 401 Unauthorized\\r\\n\\r\\n');\n console.log('Sending Error Msg for unauthenticated WS-Request');\n while (!errorIsSend) {}\n socket.destroy();\n console.log('WS-Socket destroyed');\n\n return;\n }\n request.uuid = client.uuid;\n wss.handleUpgrade(request, socket, head, function done(ws) {\n wss.emit('connection', ws, request, client);\n });\n });\n}", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "3238a787e1af434bcb96370802de5a8f", "score": "0.565519", "text": "function onupgrade(to){\n if (transport && to.name != transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "f95f33a8af42f4f163489e23c4778049", "score": "0.5653729", "text": "function onerror(err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\n\t freezeTransport();\n\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "f95f33a8af42f4f163489e23c4778049", "score": "0.5653729", "text": "function onerror(err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\n\t freezeTransport();\n\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "f95f33a8af42f4f163489e23c4778049", "score": "0.5653729", "text": "function onerror(err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\n\t freezeTransport();\n\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "f95f33a8af42f4f163489e23c4778049", "score": "0.5653729", "text": "function onerror(err) {\n\t var error = new Error('probe error: ' + err);\n\t error.transport = transport.name;\n\n\t freezeTransport();\n\n\t debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n\t self.emit('upgradeError', error);\n\t }", "title": "" }, { "docid": "1f4277c9cea8091752769b6c46391bc6", "score": "0.56494206", "text": "function onupgrade(to) {\n if (transport && to.name !== transport.name) {\n debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\n freezeTransport();\n }\n }", "title": "" }, { "docid": "a67efa8aa96381c3bc156282a655a7a0", "score": "0.5614769", "text": "function onupgrade (to) {\r\n\t if (transport && to.name !== transport.name) {\r\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\r\n\t freezeTransport();\r\n\t }\r\n\t }", "title": "" }, { "docid": "a67efa8aa96381c3bc156282a655a7a0", "score": "0.5614769", "text": "function onupgrade (to) {\r\n\t if (transport && to.name !== transport.name) {\r\n\t debug('\"%s\" works - aborting \"%s\"', to.name, transport.name);\r\n\t freezeTransport();\r\n\t }\r\n\t }", "title": "" }, { "docid": "c3333e24d6346f14c2e5fc8cf7af4a57", "score": "0.56111205", "text": "function handleHybiUpgrade(req, socket, upgradeHead, cb) {\n // handle premature socket errors\n var errorHandler = function() {\n try { socket.destroy(); } catch (e) {}\n }\n socket.on('error', errorHandler);\n\n // verify key presence\n if (!req.headers['sec-websocket-key']) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify version\n var version = parseInt(req.headers['sec-websocket-version']);\n if ([8, 13].indexOf(version) === -1) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify protocol\n var protocols = req.headers['sec-websocket-protocol'];\n\n // verify client\n var origin = version < 13 ?\n req.headers['sec-websocket-origin'] :\n req.headers['origin'];\n\n // handle extensions offer\n var extensionsOffer = Extensions.parse(req.headers['sec-websocket-extensions']);\n\n // handler to call when the connection sequence completes\n var self = this;\n var completeHybiUpgrade2 = function(protocol) {\n\n // calc key\n var key = req.headers['sec-websocket-key'];\n var shasum = crypto.createHash('sha1');\n shasum.update(key + \"258EAFA5-E914-47DA-95CA-C5AB0DC85B11\");\n key = shasum.digest('base64');\n\n var headers = [\n 'HTTP/1.1 101 Switching Protocols'\n , 'Upgrade: websocket'\n , 'Connection: Upgrade'\n , 'Sec-WebSocket-Accept: ' + key\n ];\n\n if (typeof protocol != 'undefined') {\n headers.push('Sec-WebSocket-Protocol: ' + protocol);\n }\n\n var extensions = {};\n try {\n extensions = acceptExtensions.call(self, extensionsOffer);\n } catch (err) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n if (Object.keys(extensions).length) {\n var serverExtensions = {};\n Object.keys(extensions).forEach(function(token) {\n serverExtensions[token] = [extensions[token].params]\n });\n headers.push('Sec-WebSocket-Extensions: ' + Extensions.format(serverExtensions));\n }\n\n // allows external modification/inspection of handshake headers\n self.emit('headers', headers);\n\n socket.setTimeout(0);\n socket.setNoDelay(true);\n try {\n socket.write(headers.concat('', '').join('\\r\\n'));\n }\n catch (e) {\n // if the upgrade write fails, shut the connection down hard\n try { socket.destroy(); } catch (e) {}\n return;\n }\n\n var client = new WebSocket([req, socket, upgradeHead], {\n protocolVersion: version,\n protocol: protocol,\n extensions: extensions\n });\n\n if (self.options.clientTracking) {\n self.clients.push(client);\n client.on('close', function() {\n var index = self.clients.indexOf(client);\n if (index != -1) {\n self.clients.splice(index, 1);\n }\n });\n }\n\n // signal upgrade complete\n socket.removeListener('error', errorHandler);\n cb(client);\n }\n\n // optionally call external protocol selection handler before\n // calling completeHybiUpgrade2\n var completeHybiUpgrade1 = function() {\n // choose from the sub-protocols\n if (typeof self.options.handleProtocols == 'function') {\n var protList = (protocols || \"\").split(/, */);\n var callbackCalled = false;\n var res = self.options.handleProtocols(protList, function(result, protocol) {\n callbackCalled = true;\n if (!result) abortConnection(socket, 401, 'Unauthorized');\n else completeHybiUpgrade2(protocol);\n });\n if (!callbackCalled) {\n // the handleProtocols handler never called our callback\n abortConnection(socket, 501, 'Could not process protocols');\n }\n return;\n } else {\n if (typeof protocols !== 'undefined') {\n completeHybiUpgrade2(protocols.split(/, */)[0]);\n }\n else {\n completeHybiUpgrade2();\n }\n }\n }\n\n // optionally call external client verification handler\n if (typeof this.options.verifyClient == 'function') {\n var info = {\n origin: origin,\n secure: typeof req.connection.authorized !== 'undefined' || typeof req.connection.encrypted !== 'undefined',\n req: req\n };\n if (this.options.verifyClient.length == 2) {\n this.options.verifyClient(info, function(result, code, name) {\n if (typeof code === 'undefined') code = 401;\n if (typeof name === 'undefined') name = http.STATUS_CODES[code];\n\n if (!result) abortConnection(socket, code, name);\n else completeHybiUpgrade1();\n });\n return;\n }\n else if (!this.options.verifyClient(info)) {\n abortConnection(socket, 401, 'Unauthorized');\n return;\n }\n }\n\n completeHybiUpgrade1();\n}", "title": "" }, { "docid": "d377a77d64e44a15e4925f1863fd4bd6", "score": "0.56111205", "text": "function handleHybiUpgrade(req, socket, upgradeHead, cb) {\n // handle premature socket errors\n var errorHandler = function() {\n try { socket.destroy(); } catch (e) {}\n }\n socket.on('error', errorHandler);\n\n // verify key presence\n if (!req.headers['sec-websocket-key']) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify version\n var version = parseInt(req.headers['sec-websocket-version']);\n if ([8, 13].indexOf(version) === -1) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify protocol\n var protocols = req.headers['sec-websocket-protocol'];\n\n // verify client\n var origin = version < 13 ?\n req.headers['sec-websocket-origin'] :\n req.headers['origin'];\n\n // handle extensions offer\n var extensionsOffer = Extensions.parse(req.headers['sec-websocket-extensions']);\n\n // handler to call when the connection sequence completes\n var self = this;\n var completeHybiUpgrade2 = function(protocol) {\n\n // calc key\n var key = req.headers['sec-websocket-key'];\n var shasum = crypto.createHash('sha1');\n shasum.update(key + \"258EAFA5-E914-47DA-95CA-C5AB0DC85B11\");\n key = shasum.digest('base64');\n\n var headers = [\n 'HTTP/1.1 101 Switching Protocols'\n , 'Upgrade: websocket'\n , 'Connection: Upgrade'\n , 'Sec-WebSocket-Accept: ' + key\n ];\n\n if (typeof protocol != 'undefined') {\n headers.push('Sec-WebSocket-Protocol: ' + protocol);\n }\n\n var extensions = {};\n try {\n extensions = acceptExtensions.call(self, extensionsOffer);\n } catch (err) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n if (Object.keys(extensions).length) {\n var serverExtensions = {};\n Object.keys(extensions).forEach(function(token) {\n serverExtensions[token] = [extensions[token].params]\n });\n headers.push('Sec-WebSocket-Extensions: ' + Extensions.format(serverExtensions));\n }\n\n // allows external modification/inspection of handshake headers\n self.emit('headers', headers);\n\n socket.setTimeout(0);\n socket.setNoDelay(true);\n try {\n socket.write(headers.concat('', '').join('\\r\\n'));\n }\n catch (e) {\n // if the upgrade write fails, shut the connection down hard\n try { socket.destroy(); } catch (e) {}\n return;\n }\n\n var client = new WebSocket([req, socket, upgradeHead], {\n protocolVersion: version,\n protocol: protocol,\n extensions: extensions,\n maxPayload: self.options.maxPayload\n });\n\n if (self.options.clientTracking) {\n self.clients.push(client);\n client.on('close', function() {\n var index = self.clients.indexOf(client);\n if (index != -1) {\n self.clients.splice(index, 1);\n }\n });\n }\n\n // signal upgrade complete\n socket.removeListener('error', errorHandler);\n cb(client);\n }\n\n // optionally call external protocol selection handler before\n // calling completeHybiUpgrade2\n var completeHybiUpgrade1 = function() {\n // choose from the sub-protocols\n if (typeof self.options.handleProtocols == 'function') {\n var protList = (protocols || \"\").split(/, */);\n var callbackCalled = false;\n var res = self.options.handleProtocols(protList, function(result, protocol) {\n callbackCalled = true;\n if (!result) abortConnection(socket, 401, 'Unauthorized');\n else completeHybiUpgrade2(protocol);\n });\n if (!callbackCalled) {\n // the handleProtocols handler never called our callback\n abortConnection(socket, 501, 'Could not process protocols');\n }\n return;\n } else {\n if (typeof protocols !== 'undefined') {\n completeHybiUpgrade2(protocols.split(/, */)[0]);\n }\n else {\n completeHybiUpgrade2();\n }\n }\n }\n\n // optionally call external client verification handler\n if (typeof this.options.verifyClient == 'function') {\n var info = {\n origin: origin,\n secure: typeof req.connection.authorized !== 'undefined' || typeof req.connection.encrypted !== 'undefined',\n req: req\n };\n if (this.options.verifyClient.length == 2) {\n this.options.verifyClient(info, function(result, code, name) {\n if (typeof code === 'undefined') code = 401;\n if (typeof name === 'undefined') name = http.STATUS_CODES[code];\n\n if (!result) abortConnection(socket, code, name);\n else completeHybiUpgrade1();\n });\n return;\n }\n else if (!this.options.verifyClient(info)) {\n abortConnection(socket, 401, 'Unauthorized');\n return;\n }\n }\n\n completeHybiUpgrade1();\n}", "title": "" }, { "docid": "d377a77d64e44a15e4925f1863fd4bd6", "score": "0.56111205", "text": "function handleHybiUpgrade(req, socket, upgradeHead, cb) {\n // handle premature socket errors\n var errorHandler = function() {\n try { socket.destroy(); } catch (e) {}\n }\n socket.on('error', errorHandler);\n\n // verify key presence\n if (!req.headers['sec-websocket-key']) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify version\n var version = parseInt(req.headers['sec-websocket-version']);\n if ([8, 13].indexOf(version) === -1) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify protocol\n var protocols = req.headers['sec-websocket-protocol'];\n\n // verify client\n var origin = version < 13 ?\n req.headers['sec-websocket-origin'] :\n req.headers['origin'];\n\n // handle extensions offer\n var extensionsOffer = Extensions.parse(req.headers['sec-websocket-extensions']);\n\n // handler to call when the connection sequence completes\n var self = this;\n var completeHybiUpgrade2 = function(protocol) {\n\n // calc key\n var key = req.headers['sec-websocket-key'];\n var shasum = crypto.createHash('sha1');\n shasum.update(key + \"258EAFA5-E914-47DA-95CA-C5AB0DC85B11\");\n key = shasum.digest('base64');\n\n var headers = [\n 'HTTP/1.1 101 Switching Protocols'\n , 'Upgrade: websocket'\n , 'Connection: Upgrade'\n , 'Sec-WebSocket-Accept: ' + key\n ];\n\n if (typeof protocol != 'undefined') {\n headers.push('Sec-WebSocket-Protocol: ' + protocol);\n }\n\n var extensions = {};\n try {\n extensions = acceptExtensions.call(self, extensionsOffer);\n } catch (err) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n if (Object.keys(extensions).length) {\n var serverExtensions = {};\n Object.keys(extensions).forEach(function(token) {\n serverExtensions[token] = [extensions[token].params]\n });\n headers.push('Sec-WebSocket-Extensions: ' + Extensions.format(serverExtensions));\n }\n\n // allows external modification/inspection of handshake headers\n self.emit('headers', headers);\n\n socket.setTimeout(0);\n socket.setNoDelay(true);\n try {\n socket.write(headers.concat('', '').join('\\r\\n'));\n }\n catch (e) {\n // if the upgrade write fails, shut the connection down hard\n try { socket.destroy(); } catch (e) {}\n return;\n }\n\n var client = new WebSocket([req, socket, upgradeHead], {\n protocolVersion: version,\n protocol: protocol,\n extensions: extensions,\n maxPayload: self.options.maxPayload\n });\n\n if (self.options.clientTracking) {\n self.clients.push(client);\n client.on('close', function() {\n var index = self.clients.indexOf(client);\n if (index != -1) {\n self.clients.splice(index, 1);\n }\n });\n }\n\n // signal upgrade complete\n socket.removeListener('error', errorHandler);\n cb(client);\n }\n\n // optionally call external protocol selection handler before\n // calling completeHybiUpgrade2\n var completeHybiUpgrade1 = function() {\n // choose from the sub-protocols\n if (typeof self.options.handleProtocols == 'function') {\n var protList = (protocols || \"\").split(/, */);\n var callbackCalled = false;\n var res = self.options.handleProtocols(protList, function(result, protocol) {\n callbackCalled = true;\n if (!result) abortConnection(socket, 401, 'Unauthorized');\n else completeHybiUpgrade2(protocol);\n });\n if (!callbackCalled) {\n // the handleProtocols handler never called our callback\n abortConnection(socket, 501, 'Could not process protocols');\n }\n return;\n } else {\n if (typeof protocols !== 'undefined') {\n completeHybiUpgrade2(protocols.split(/, */)[0]);\n }\n else {\n completeHybiUpgrade2();\n }\n }\n }\n\n // optionally call external client verification handler\n if (typeof this.options.verifyClient == 'function') {\n var info = {\n origin: origin,\n secure: typeof req.connection.authorized !== 'undefined' || typeof req.connection.encrypted !== 'undefined',\n req: req\n };\n if (this.options.verifyClient.length == 2) {\n this.options.verifyClient(info, function(result, code, name) {\n if (typeof code === 'undefined') code = 401;\n if (typeof name === 'undefined') name = http.STATUS_CODES[code];\n\n if (!result) abortConnection(socket, code, name);\n else completeHybiUpgrade1();\n });\n return;\n }\n else if (!this.options.verifyClient(info)) {\n abortConnection(socket, 401, 'Unauthorized');\n return;\n }\n }\n\n completeHybiUpgrade1();\n}", "title": "" }, { "docid": "d377a77d64e44a15e4925f1863fd4bd6", "score": "0.56111205", "text": "function handleHybiUpgrade(req, socket, upgradeHead, cb) {\n // handle premature socket errors\n var errorHandler = function() {\n try { socket.destroy(); } catch (e) {}\n }\n socket.on('error', errorHandler);\n\n // verify key presence\n if (!req.headers['sec-websocket-key']) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify version\n var version = parseInt(req.headers['sec-websocket-version']);\n if ([8, 13].indexOf(version) === -1) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n // verify protocol\n var protocols = req.headers['sec-websocket-protocol'];\n\n // verify client\n var origin = version < 13 ?\n req.headers['sec-websocket-origin'] :\n req.headers['origin'];\n\n // handle extensions offer\n var extensionsOffer = Extensions.parse(req.headers['sec-websocket-extensions']);\n\n // handler to call when the connection sequence completes\n var self = this;\n var completeHybiUpgrade2 = function(protocol) {\n\n // calc key\n var key = req.headers['sec-websocket-key'];\n var shasum = crypto.createHash('sha1');\n shasum.update(key + \"258EAFA5-E914-47DA-95CA-C5AB0DC85B11\");\n key = shasum.digest('base64');\n\n var headers = [\n 'HTTP/1.1 101 Switching Protocols'\n , 'Upgrade: websocket'\n , 'Connection: Upgrade'\n , 'Sec-WebSocket-Accept: ' + key\n ];\n\n if (typeof protocol != 'undefined') {\n headers.push('Sec-WebSocket-Protocol: ' + protocol);\n }\n\n var extensions = {};\n try {\n extensions = acceptExtensions.call(self, extensionsOffer);\n } catch (err) {\n abortConnection(socket, 400, 'Bad Request');\n return;\n }\n\n if (Object.keys(extensions).length) {\n var serverExtensions = {};\n Object.keys(extensions).forEach(function(token) {\n serverExtensions[token] = [extensions[token].params]\n });\n headers.push('Sec-WebSocket-Extensions: ' + Extensions.format(serverExtensions));\n }\n\n // allows external modification/inspection of handshake headers\n self.emit('headers', headers);\n\n socket.setTimeout(0);\n socket.setNoDelay(true);\n try {\n socket.write(headers.concat('', '').join('\\r\\n'));\n }\n catch (e) {\n // if the upgrade write fails, shut the connection down hard\n try { socket.destroy(); } catch (e) {}\n return;\n }\n\n var client = new WebSocket([req, socket, upgradeHead], {\n protocolVersion: version,\n protocol: protocol,\n extensions: extensions,\n maxPayload: self.options.maxPayload\n });\n\n if (self.options.clientTracking) {\n self.clients.push(client);\n client.on('close', function() {\n var index = self.clients.indexOf(client);\n if (index != -1) {\n self.clients.splice(index, 1);\n }\n });\n }\n\n // signal upgrade complete\n socket.removeListener('error', errorHandler);\n cb(client);\n }\n\n // optionally call external protocol selection handler before\n // calling completeHybiUpgrade2\n var completeHybiUpgrade1 = function() {\n // choose from the sub-protocols\n if (typeof self.options.handleProtocols == 'function') {\n var protList = (protocols || \"\").split(/, */);\n var callbackCalled = false;\n var res = self.options.handleProtocols(protList, function(result, protocol) {\n callbackCalled = true;\n if (!result) abortConnection(socket, 401, 'Unauthorized');\n else completeHybiUpgrade2(protocol);\n });\n if (!callbackCalled) {\n // the handleProtocols handler never called our callback\n abortConnection(socket, 501, 'Could not process protocols');\n }\n return;\n } else {\n if (typeof protocols !== 'undefined') {\n completeHybiUpgrade2(protocols.split(/, */)[0]);\n }\n else {\n completeHybiUpgrade2();\n }\n }\n }\n\n // optionally call external client verification handler\n if (typeof this.options.verifyClient == 'function') {\n var info = {\n origin: origin,\n secure: typeof req.connection.authorized !== 'undefined' || typeof req.connection.encrypted !== 'undefined',\n req: req\n };\n if (this.options.verifyClient.length == 2) {\n this.options.verifyClient(info, function(result, code, name) {\n if (typeof code === 'undefined') code = 401;\n if (typeof name === 'undefined') name = http.STATUS_CODES[code];\n\n if (!result) abortConnection(socket, code, name);\n else completeHybiUpgrade1();\n });\n return;\n }\n else if (!this.options.verifyClient(info)) {\n abortConnection(socket, 401, 'Unauthorized');\n return;\n }\n }\n\n completeHybiUpgrade1();\n}", "title": "" }, { "docid": "5d6b11986ddb8b1f6a1ab57a2c3c81f8", "score": "0.5606356", "text": "onReConnect() {\r\n // To re-connect to a device, simply destroy the existing VBSocket\r\n // object, and thus the underlying Node.js socket object, then\r\n // create a new VBSocket\r\n // Assume that when the VBSocket object is destroyed, a\r\n // [FIN, ACK] packet will be sent to the device\r\n if (this.vbSocket) {\r\n this.vbSocket.terminate()\r\n }\r\n this.vbSocket = this.doCreateSocket()\r\n }", "title": "" }, { "docid": "2a804323a04f045ef3cf3c048f8f91c2", "score": "0.559777", "text": "function onupgrade (to) {\n\t if (transport && to.name !== transport.name) {\n\t freezeTransport();\n\t }\n\t }", "title": "" }, { "docid": "8651890d69d17a46dab6f1b417e5d9a0", "score": "0.55952513", "text": "function firstHandler(data){if(called||self.readyState===WebSocket.CLOSED)return;called=true;socket.removeListener('data',firstHandler);ultron.on('data',realHandler);if(upgradeHead&&upgradeHead.length>0){realHandler(upgradeHead);upgradeHead=null;}if(data)realHandler(data);}// subsequent packets are pushed straight to the receiver", "title": "" }, { "docid": "2cf390a1f8804f172573456fa387d936", "score": "0.5594688", "text": "function onerror(err) {\n const error = new Error(\"probe error: \" + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit(\"upgradeError\", error);\n }", "title": "" }, { "docid": "2cf390a1f8804f172573456fa387d936", "score": "0.5594688", "text": "function onerror(err) {\n const error = new Error(\"probe error: \" + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit(\"upgradeError\", error);\n }", "title": "" }, { "docid": "2cf390a1f8804f172573456fa387d936", "score": "0.5594688", "text": "function onerror(err) {\n const error = new Error(\"probe error: \" + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit(\"upgradeError\", error);\n }", "title": "" }, { "docid": "2cf390a1f8804f172573456fa387d936", "score": "0.5594688", "text": "function onerror(err) {\n const error = new Error(\"probe error: \" + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit(\"upgradeError\", error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "80fbed243206f3f156bd75daca85f3a1", "score": "0.55736434", "text": "function onerror (err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "7f1e83f739ef863bd4b64d9680354c95", "score": "0.5552459", "text": "_onConnection (err, socket) {\n if (err) {\n if (socket) socket.destroy()\n debug(`discovery connection error: ` + errToString(err))\n this.emit('connectError', err, null) // emit user's event\n // do this in connectPlainWeb:\n //if (isWebSocket(socket) && this.fConnectPlainWeb)\n // this._updateWebAddrState(getWebSocketUrl(socket), undefined, ADDRSTATE.FREE, true) // clear inuse state if connect error\n if (this.connecting) {\n // setImmediate(this._connectPeer.bind(this)) // lets wait for some time before\n debug(`waiting for ${this.retryInterval} ms before connection retry`)\n setTimeout(this._connectPeer.bind(this), this.retryInterval)\n }\n return\n }\n if (this.closed) return socket.destroy()\n let opts = assign({ socket }, this.peerOpts)\n let peer = new Peer(this._params, opts)\n let onPeerError = (err) => {\n console.log('onPeerError called')\n err = err || Error('Connection error')\n debug(`peer connection error: ` + errToString(err))\n peer.removeListener('disconnect', onPeerError)\n this.emit('connectError', err, peer) // emit user's event\n if (isWebSocketPeer(peer) && this.fConnectPlainWeb)\n this._updateWebAddrState(getWebSocketPeerUrl(peer), undefined, ADDRSTATE.FREE, true) // clear inuse state if connect error\n if (this.connecting) this._connectPeer() // try to connect new peer\n }\n\n // wait for socket connection errors:\n peer.once('error', onPeerError)\n peer.once('disconnect', onPeerError)\n // socket connected:\n peer.once('ready', () => {\n if (this.closed) return peer.disconnect()\n // remove once listeners to replace with new ones\n peer.removeListener('error', onPeerError)\n peer.removeListener('disconnect', onPeerError)\n this.addPeer(peer)\n if (isWebSocketPeer(peer) && this.fConnectPlainWeb)\n this._updateWebAddrState(getWebSocketPeerUrl(peer), Date.now())\n // setup getaddr loop\n this.getAddr({}, ()=>{}) // empty opts and cb to pass through _request()\n setInterval(this.getAddr.bind(this, {}, ()=>{}), 120*1000) // same\n })\n }", "title": "" }, { "docid": "54d767d32326b9d0ce89ab441e0537d9", "score": "0.55521506", "text": "listen_for_req() {\n this.peer.on('connection', dataConnection => {\n // adding the newly connected peer to the list\n dataConnection.on('open', () => {\n this.session_peers.push(dataConnection.peer);\n this.session_peers_conn.push(dataConnection);\n\n // If no updates has been received for 5 mins\n clearTimeout(this.updateTimer);\n if (window.location.href.includes('/editor')) {\n console.log('Setting update timer to 5 mins');\n this.updateTimer = setTimeout(() => this.handle_no_updates(), 300000);\n }\n\n dataConnection.on('error', error => {\n this.handle_error_from_peers(error);\n });\n\n dataConnection.on('data', data => {\n this.handle_data_from_peers(data, dataConnection);\n });\n\n // listening to errors on any data connections\n dataConnection.on('close', () => {\n this.handle_peer_disconnect(dataConnection);\n });\n });\n });\n }", "title": "" }, { "docid": "9c3189c79bd1b7f0351f04746355d7dd", "score": "0.55509603", "text": "function onerror(err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "9c3189c79bd1b7f0351f04746355d7dd", "score": "0.55509603", "text": "function onerror(err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "9c3189c79bd1b7f0351f04746355d7dd", "score": "0.55509603", "text": "function onerror(err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" }, { "docid": "9c3189c79bd1b7f0351f04746355d7dd", "score": "0.55509603", "text": "function onerror(err) {\n var error = new Error('probe error: ' + err);\n error.transport = transport.name;\n\n freezeTransport();\n\n debug('probe transport \"%s\" failed because of error: %s', name, err);\n\n self.emit('upgradeError', error);\n }", "title": "" } ]
4ce650ddd852e08729e82a8d0d316007
Lets URLs beginning with ' default to using the ' protocol.
[ { "docid": "6ed75241b01d25ee405a7d19960ffb18", "score": "0.68247193", "text": "function addDefaultProtocolToUrl(url) {\n if (isString(url) && url.indexOf('www.') === 0) {\n return ('http://' + url);\n }\n return url;\n }", "title": "" } ]
[ { "docid": "f7c8ba747de749db5e9f9e87ef293139", "score": "0.6718694", "text": "function addDefaultProtocolToUrl(url) {\n if (url && url.indexOf('www.') === 0) {\n return ('http://' + url);\n }\n return url;\n }", "title": "" }, { "docid": "946b581e8bee35b8ef2a706130b67671", "score": "0.65363467", "text": "function getFirstURLChars() {\n return window.location.href.indexOf('https:') ? 'http://www.' : 'https://ssl.';\n}", "title": "" }, { "docid": "54438b70b26994daaa9498e0f5f8f817", "score": "0.63587517", "text": "function initialurlslicing() {\r\n if (username.includes(\"/\")) {\r\n username = username.substring(0, username.indexOf(\"/\"))\r\n }\r\n username = decodeURI(username)\r\n }", "title": "" }, { "docid": "4e61c8dc0059cb215087fa5bf46a8046", "score": "0.6273733", "text": "function autoLinkUrls(txt) {\n return txt.replace(/(^|\\s)(https?|ftp)(:[^'\">\\s]+)/gi,\n \"$1<a target=\\\"_blank\\\" href=\\\"$2$3\\\">$2$3</a>\");\n }", "title": "" }, { "docid": "aaae947e1a9f45512d3741650acc38de", "score": "0.6270073", "text": "function addProtocol(str) {\n var pattern = new RegExp('^(https?:\\\\/\\\\/).*');\n if (!pattern.test(str)) {\n return 'https://' + str\n } else {\n return str\n }\n}", "title": "" }, { "docid": "acc579a31cdadd13a4e9af5c16642c1e", "score": "0.6229069", "text": "function addhttp(url) {\n if (!/^(f|ht)tps?:\\/\\//i.test(url)) {\n url = \"http://\" + url;\n }\n return url;\n }", "title": "" }, { "docid": "1a5ad13c8971c6671276c9e1146dac4d", "score": "0.62229276", "text": "function autoLinkUrls(txt) {\n return txt.replace(/(^|\\s)(https?|ftp)(:[^'\"<>\\s]+)/gi,\n \"$1<a target=\\\"_blank\\\" href=\\\"$2$3\\\">$2$3</a>\");\n }", "title": "" }, { "docid": "62fe4d2313749bb26863caa3f2a129d5", "score": "0.62084913", "text": "function addHttp(url) {\n\tif ((url.indexOf('http://') == -1) && (url.indexOf('ftp://') == -1) && (url.indexOf('https://') == -1)) {\n\t\turl = 'http://' + url;\n\t}\n\treturn url;\n}", "title": "" }, { "docid": "fb1c93b00241e25d8ed0936216590b33", "score": "0.60837317", "text": "function addhttp(url) {\n\tif (!/^(f|ht)tps?:\\/\\//i.test(url)) {\n\t\turl = \"http://\" + url;\n\t}\n\treturn url;\n}", "title": "" }, { "docid": "adaf2f79a9839e9fcbd88a7dcecdf143", "score": "0.6073872", "text": "function http_helper( field ){\n\tvar value = field.val();\n\tvar has_http = value.indexOf('http') == -1 ? false : true;\n\tif( !has_http ){\n\t\tfield.val('http://' + value);\n }\n}", "title": "" }, { "docid": "adfb4e711c515504dd5a7e1492901890", "score": "0.5997565", "text": "function b(a){return o(a)&&0===a.indexOf(\"www.\")?\"http://\"+a:a}", "title": "" }, { "docid": "e06a7f6bfb621ae2c5259384cf2cc9ac", "score": "0.5843233", "text": "defaultFormat() { return 'http'; }", "title": "" }, { "docid": "d3e98092628dc0eb33f7239895bfe7c8", "score": "0.5813427", "text": "function addProtocol (longURL) {\n let newURL = longURL;\n if (!newURL.match(/^http(s?):\\/\\//)) {\n newURL = \"http://\" + newURL;\n }\n return newURL;\n}", "title": "" }, { "docid": "252ceb5b139496046070a72f7e29e42d", "score": "0.5812825", "text": "function simpleURL(protocol, domain, path) {\n return protocol + \"://\" + domain + \"/\" + path;\n }", "title": "" }, { "docid": "cb3345331b004afaf22a57909f84de03", "score": "0.5786131", "text": "function linkscapePrepUrls_ (urls) {\n if (isArray(urls)) {\n // remove outer array if we get columns\n if (isColumn(urls)) urls = urls[0];\n } else {\n // if we get a string, convert it to an array.\n urls = strToArray(urls);\n }\n // remove protocol or seomoz doesn't work right.\n for (var i = 0; i < urls.length; i++) {\n urls[i] = urls[i].toString().replace(/http(s)?:\\/\\//gi, \"\");\n }\n return urls;\n }", "title": "" }, { "docid": "b179c71cd732a53b51b80fcb7899c1cf", "score": "0.57563704", "text": "function URLify(str) {\n var newStr = ''\n for(var i=0; i < str.length; i++) {\n if(str[i] == ' ') newStr += '%20'\n else newStr += str[i]\n }\n console.log(newStr)\n}", "title": "" }, { "docid": "19d881d2217b33ab615fd17202e7451c", "score": "0.5752545", "text": "function ensureProtocol(url) {\n\t\tif (!url.match(protocolRegExp)) {\n\t\t\turl = \"http://\" + url;\n\t\t}\n\t\treturn url;\n\t}", "title": "" }, { "docid": "21fd71410c42df2101dc6abce7e2ec78", "score": "0.5746413", "text": "function url (s) {\n\treturn (s);\n}", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "b397c283daf082c3dc7a662d86762e33", "score": "0.57421243", "text": "function SafeUrl() { }", "title": "" }, { "docid": "a1acd1b48ae937fc0168073718032eda", "score": "0.57379675", "text": "ensureUrlWithProtocol() {\n\t return ensureUrlWithProtocol(...arguments)\n\t }", "title": "" }, { "docid": "cf84c1734198ad2a19c8e39302af8835", "score": "0.57207656", "text": "function webUrl (thing) {\n return unemptyString(thing) && /^https?:\\/\\/.+/.test(thing);\n }", "title": "" }, { "docid": "d762264a0f052bc6fbb10dab4a9787e6", "score": "0.57189775", "text": "function cleanBaseHref_local(baseHrefIn_local){ \n\tbaseHrefOut_local = baseHrefIn_local;\n\tbaseHrefOut_local = replaceSubstring_local(baseHrefOut_local, \"http://\", \"\");\n\tbaseHrefOut_local = replaceSubstring_local(baseHrefOut_local, \"/\", \"\");\t\n\treturn escape(baseHrefOut_local);\n}", "title": "" }, { "docid": "a7346264e7566c67257050f85f44f9f7", "score": "0.57161564", "text": "function simpleUrl(protocol, domin, path) {\n return protocol + \"://\" + domin + \"/\" + path;\n}", "title": "" }, { "docid": "63741a330271039c515f4c0908b6b858", "score": "0.57055557", "text": "function geturl() {\n var url = document.getElementById('urlinput').value;\n var protocol_ok =\n url.startsWith('http://') ||\n url.startsWith('https://') ||\n url.startsWith('ftp://');\n if (!protocol_ok) {\n newurl = 'http://' + url;\n return newurl;\n } else {\n return url;\n }\n}", "title": "" }, { "docid": "d15d181f1e285c4e9d223c7fd9786a5b", "score": "0.57019883", "text": "function URLify(str){\n\tlet result = \"\", split, newChar;\n\tstr = str.trim();\n\tsplit = str.split(\" \");\n\tfor(let i = 0; i < split.length; i++){\n\t\tnewChar = split[i] + \"%20\";\n\t\tif(split[i] === split[split.length - 1]){\n\t\t\tnewChar = split[i];\n\t\t}\n\t\tresult += newChar;\n\t}\n\treturn result;\n}", "title": "" }, { "docid": "9641d01cc1a54f8e6d1ddd1291048198", "score": "0.5694861", "text": "function URLify(str) {\n return str.split(' ').join('%20')\n}", "title": "" }, { "docid": "22e0354d0dda75e8905e35be0196f087", "score": "0.56923044", "text": "function parity(url)\n{\n\treturn (url !== \"http://\") ? url : \"http:///\";\n}", "title": "" }, { "docid": "28cf18905a355409d1ccf198048bfdfc", "score": "0.5689513", "text": "function URLify(str) {\n str = str.trimRight();\n return str.split(' ').join('%20');\n}", "title": "" }, { "docid": "47819338b2ac23fbd6cabecab05e7240", "score": "0.56768733", "text": "function transformNominatimUrl(str){\n\t\tvar res = \"\";\n\t\tfor(var i = 0; i<str.length; i++){\n\t\t\tres += (str.charAt(i) == \" \") ? \"+\" : str.charAt(i);\n\t\t}\n\t\treturn res;\n\t}", "title": "" }, { "docid": "68672e1f0cc0e652d6ba5d8910671f32", "score": "0.5670537", "text": "function autoURL(message){\n\tvar regex = /\\b((https?|telnet|gopher|file|wais|ftp):[\\w\\/\\#~:.?+=&%@!\\-]+?)*?(?=[.:?\\-]*(?:[^\\w\\/\\#~:.?+=&%@!\\-]|$))/gi;\n\t\n\treturn message.replace(regex, \"<a href=\\\"$1\\\" target=\\\"_blank\\\" title=\\\"Link opens in a new window\\\">$1</a>\");\n}", "title": "" }, { "docid": "b34ffd7cfd9b5064ae0038916dd49c72", "score": "0.5668513", "text": "function SafeUrl() {}", "title": "" }, { "docid": "b34ffd7cfd9b5064ae0038916dd49c72", "score": "0.5668513", "text": "function SafeUrl() {}", "title": "" }, { "docid": "b34ffd7cfd9b5064ae0038916dd49c72", "score": "0.5668513", "text": "function SafeUrl() {}", "title": "" }, { "docid": "b34ffd7cfd9b5064ae0038916dd49c72", "score": "0.5668513", "text": "function SafeUrl() {}", "title": "" }, { "docid": "ae2c83fd2d1c572c2a9570b635386667", "score": "0.56393874", "text": "ensureUrlWithProtocol() {\n return ensureUrlWithProtocol(...arguments)\n }", "title": "" }, { "docid": "a4a72405a35ca12b211ec9786197d992", "score": "0.5620553", "text": "function URLUtils() {}", "title": "" }, { "docid": "8e544000f06219de83e36db9d9290f26", "score": "0.5610108", "text": "function SafeUrl(){}", "title": "" }, { "docid": "c923129a2e3c869d26ea4baa77ad45c2", "score": "0.5590605", "text": "function protocolChecker(url) {\n if (((url.substring(0,7)) === 'http://') || ((url.substring(0,8)) === 'https://')) {\n return url;\n } else {\n let correctedURL = (`http://${url}`);\n return correctedURL;\n }\n}", "title": "" }, { "docid": "3661f0784da8d493599304d4b4519c11", "score": "0.557964", "text": "function URLify2(string) {\n string = string.trim();\n let newString = \"\";\n for (let x = 0; x < string.length; x++) {\n if (string.charAt(x) === \" \") {\n newString += \"%20\";\n } else {\n newString += string.charAt(x);\n }\n }\n return newString;\n}", "title": "" }, { "docid": "9922c33b876a6fd6ffac749a78e31467", "score": "0.55795646", "text": "function urlify(url) {\n if (url.match(/^https?:\\/\\//)) {\n return url;\n }\n\n if (!url.match(/\\//)) {\n url += '/';\n }\n\n return 'http://' + url;\n}", "title": "" }, { "docid": "29473d2c58942a1552fe1a059aa98904", "score": "0.55676633", "text": "function urlify(url) {\n let urlified = '';\n for (let i = 0; i < url.length; i += 1) {\n // Check if url[i] is \" \"\n if (url[i] === ' ') {\n urlified += '%20';\n } else {\n urlified += url[i];\n }\n }\n\n return urlified;\n}", "title": "" }, { "docid": "d0a0808bd88772cd82271194718c9532", "score": "0.5553648", "text": "_cleanUrl (url) {\n // If the url is absolute return it as is...\n if (url.indexOf('://') >= 0) return url\n\n // Assume there is only one \"/\" between _catalogBaseUrl and url.\n return `${this.parentCatalog._catalogBaseUrl}${url}`\n }", "title": "" }, { "docid": "fddcb1be0023c932a210c1693a97e8d1", "score": "0.5545356", "text": "function parseTestSiteUrl(url) {\n if (!/^https?\\:\\/\\//i.test(url)) {\n url = '//' + url;\n }\n return url;\n }", "title": "" }, { "docid": "d70bb01306c7def0f556ec9c179b0cba", "score": "0.55436975", "text": "function fixHyperlink(str, allowedSchemes, domain){\n\t\t\n\t\tvar scheme, lnk, m, i, j, tmp;\n\t\t\n\t\tif(!domain && domain !== 0) domain = window.location.host;\n\t\t\n\t\tif(allowedSchemes && Object.prototype.toString.call(allowedSchemes) === \"[object Array]\" && allowedSchemes.length){\t//allowedSchemes is an array with at least one element\n\t\t\tfor(i=0; i<allowedSchemes.length; i++){\n\t\t\t\tif(typeof(allowedSchemes[i]) !== \"string\" || !(/^[a-z][a-z0-9+.-]*$/i).test(allowedSchemes[i])){\t//invalid scheme\n\t\t\t\t\tallowedSchemes.splice(i,1);\t//remove it from the array\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(!allowedSchemes.length){\n\t\t\t\treturn null;\t//no valid schemes\n\t\t\t}\n\t\t}\n\t\telse if(typeof(allowedSchemes) === \"string\"){\t//allowedSchemes is a string\n\t\t\tif(!(/^[a-z][a-z0-9+.-]*$/i).test(allowedSchemes)) return null;\t//invalid scheme\n\t\t\tallowedSchemes = [allowedSchemes];\t//use it as the only allowed scheme\n\t\t}\n\t\telse{\n\t\t\tif(!allowedSchemes || !allowedSchemes.length){\t//allowed schemes not specified\n\t\t\t\tallowedSchemes = [\"http\", \"https\", \"mailto\"];\t//use default\n\t\t\t}\n\t\t\telse{\n\t\t\t\treturn null;\t//allowedSchemes is not valid\n\t\t\t}\n\t\t}\n\t\t\n\t\t//get scheme\n\t\tscheme = (/^([a-z][a-z0-9+.-]*):/i).exec(str);\n\t\tscheme = scheme ? scheme[1].toLowerCase() : window.location.protocol.slice(0,-1);\t//if the string does not include a valid scheme, assume it's meant to be that of the current page\n\t\tfor(i=0; i<allowedSchemes.length; i++){\n\t\t\tif(scheme === allowedSchemes[i]) break;\n\t\t}\n\t\tif(!allowedSchemes[i]){\t//scheme is not allowed\n\t\t\t//the previous regexp match may have been a DNS host\n\t\t\tif(scheme !== \"http\" && scheme !== \"https\" && (/^(?=([a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?))\\1(?:\\.(?=([a-z0-9](?:[a-z0-9-]{0,61}[a-z0-9])?))\\2)*:/i).test(str)){\n\t\t\t\tscheme = window.location.protocol.slice(0,-1);\t//assume the scheme is meant to be that of the current page\n\t\t\t\tfor(i=0; i<allowedSchemes.length; i++){\n\t\t\t\t\tif(scheme === allowedSchemes[i]) break;\n\t\t\t\t}\n\t\t\t\tif(!allowedSchemes[i]){\t//scheme is not allowed\n\t\t\t\t\treturn null;\n\t\t\t\t}\n\t\t\t}\n\t\t\telse{\n\t\t\t\treturn null;\t//scheme is not allowed\n\t\t\t}\n\t\t}\n\t\t\n\t\t//percent-encode illegal characters\n\t\tstr = str.replace(/([^a-z0-9-._~!$&'()*+,;=:@\\/\\[\\]%?#])|%(?![0-9A-F]{2})/ig, function (match, p1){\n\t\t\t\tif(p1) return \"%\"+p1.charCodeAt(0).toString(16);\n\t\t\t\telse return \"%25\";\t//percent sign\n\t\t\t});\n\t\ti = str.search(/\\?/);\t//index of first question mark\n\t\tj = str.search(/#/);\t//index of first number sign\n\t\tif(j >= 0 && j < i){\t//no query; only a fragment\n\t\t\tstr = str.slice(0,j+1) + str.slice(j+1).replace(/#/g, \"%23\");\t//percent-encode illegal number signs\n\t\t}\n\t\telse if(i >= 0){\t//query\n\t\t\ttmp = j >= 0 ? str.slice(j) : \"\";\n\t\t\tstr = str.slice(0,i+1) + str.slice(i+1,j).replace(/\\?/g, \"%3F\");\t//percent-encode illegal question marks\n\t\t\tif(tmp){\t//fragment\n\t\t\t\tstr = str + \"#\" + tmp.slice(1).replace(/#/g, \"%23\");\t//percent-encode illegal number signs\n\t\t\t}\n\t\t}\n\t\t\n\t\t//fix & normalize\n\t\tif(scheme === \"http\" || scheme === \"https\"){\n\t\t\tif(!(new RegExp(\"^\"+scheme+\"://\", \"i\")).test(str)){\n\t\t\t\tif(str[0] === \"/\"){ \t//path (relative to root)\n\t\t\t\t\tlnk = parseHttp(scheme+\"://\"+domain+str.replace(/\\[/g, \"%5B\").replace(/\\]/g, \"%5D\"));\n\t\t\t\t}\n\t\t\t\telse{\n\t\t\t\t\tlnk = parseHttp(scheme+\"://\"+domain+\"/\"+str.replace(/\\[/g, \"%5B\").replace(/\\]/g, \"%5D\"));\n\t\t\t\t}\n\t\t\t}\n\t\t\telse{\n\t\t\t\tlnk = parseHttp(str);\n\t\t\t\tif(!lnk){\n\t\t\t\t\tlnk = parseHttp(str.replace(/\\[/g, \"%5B\").replace(/\\]/g, \"%5D\"));\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\telse if(scheme === \"mailto\"){\n\t\t\tlnk = parseMailto(str.replace(/^mailto:\\/\\//i, \"mailto:%2F%2F\").replace(/\\[/g,\"%5B\").replace(/\\]/g,\"%5D\"));\n\t\t}\n\t\telse{\n\t\t\tlnk = parseURI(str.replace(/\\[/g,\"%5B\").replace(/\\]/g,\"%5D\"));\n\t\t}\n\t\t\n\t\tif(!lnk) return null;\t//can't be fixed\n\t\treturn lnk.uri;\t//fixed & normalized\n\t}", "title": "" }, { "docid": "8e908f64078950a16ace3bca4e192a36", "score": "0.55336595", "text": "function urlify(str) {\n if (str.length < 1) return \"\"\n let temp = \"\"\n let result = \"\"\n str = str.trim()\n for (let i = 0; i < str.length; i++) {\n if (str[i] === \" \") {\n temp = \"%20\"\n continue\n } else {\n result += temp + str[i]\n temp = \"\"\n }\n }\n return result\n}", "title": "" }, { "docid": "f426473c52d2f4c981289e7fa569eb5b", "score": "0.55194783", "text": "function clean_url(url){\r\n\turl = url.replace(\"https://\",\"\").replace(\"http://\",\"\").replace(\"www.\",\"\")\r\n\turl = url.replace(\".com\",\"\").replace(\".ca\",\"\")\r\n\treturn url\r\n}", "title": "" }, { "docid": "eb6670911d04903f9ac951971206da4e", "score": "0.5519285", "text": "function URLify(string){\n let joiner = '%20'\n let newString = ''\n newString = string.split(' ').join(joiner)\n return newString;\n }", "title": "" }, { "docid": "228751b38b1fcf40b38cf4afad93ecc5", "score": "0.55155295", "text": "function URLify2(str) {\n str = str.trim();\n let str2 = '';\n for (let i = 0; i < str.length; i++) {\n if (str[i] === ' ') {\n if (str[i - 1] !== ' ') {\n str2 = str2 + '%20';\n }\n } else {\n str2 = str2 + str[i];\n }\n }\n return str2;\n}", "title": "" }, { "docid": "26fbab8467670c3fad71c3f73b916ea9", "score": "0.5480185", "text": "function URLify(str) {\n str = str.trim();\n let strSplit = str.split(' '); // [ 'Hello,', 'Good', '', '', '', '', 'Morning' ]\n let strArray = [];\n for (let i = 0; i < strSplit.length; i++) {\n if (strSplit[i] !== '') {\n strArray.push(strSplit[i]);\n }\n }\n let strJoin = strArray.join('%20'); // \"Hello,%20Good%20Morning\"\n return strJoin;\n}", "title": "" }, { "docid": "97d7201e4fc14f0989dc3c4cfdf86c00", "score": "0.5479672", "text": "function URLify(string) {\n //trim the string\n string = string.trim();\n //replace\n let url = string.replace(/\\s/gi, \"%20\");\n\n return url;\n}", "title": "" }, { "docid": "20c367ddd0e133ce0f6f4798c82a1d94", "score": "0.5471887", "text": "function searchStringAsUrl(url) {\n\n if (!/^(https?|chrome):\\/\\/.*/.exec(url)) {\n url = \"http://\" + url;\n }\n\n return url;\n}", "title": "" }, { "docid": "4eb78cef87fb1eea587ae1cc0c5c841f", "score": "0.54702705", "text": "replace(string, prefix) {\n let fixed = super.replace(string, prefix)\n if (prefix === '-webkit-') {\n fixed = fixed.replace(/(\"[^\"]+\"|'[^']+')(\\s+\\d+\\w)/gi, 'url($1)$2')\n }\n return fixed\n }", "title": "" }, { "docid": "d3773b0c778c2a9088b2b0f80680e4d0", "score": "0.5443324", "text": "function normalize(addr) {\n if (0 == addr.indexOf('http')) return addr;\n return 'http://' + addr;\n}", "title": "" }, { "docid": "62dad6736e1c7540ce45da9a8a0b60d2", "score": "0.5432071", "text": "function upgradeUrl(url) {\n return url.replace('http://', 'https://');\n }", "title": "" }, { "docid": "7c5e58f1d46af3b9f326c156818ae2b1", "score": "0.5429972", "text": "function defaultPath(path){// \"2. If the uri-path is empty or if the first character of the uri-path is not\n// a %x2F (\"/\") character, output %x2F (\"/\") and skip the remaining steps.\nif(!path||path.substr(0,1)!==\"/\"){return\"/\";}// \"3. If the uri-path contains no more than one %x2F (\"/\") character, output\n// %x2F (\"/\") and skip the remaining step.\"\nif(path===\"/\"){return path;}var rightSlash=path.lastIndexOf(\"/\");if(rightSlash===0){return\"/\";}// \"4. Output the characters of the uri-path from the first character up to,\n// but not including, the right-most %x2F (\"/\").\"\nreturn path.slice(0,rightSlash);}", "title": "" }, { "docid": "db31ed58dc66d7449fa24ccfb75badec", "score": "0.54125327", "text": "replace(string, prefix) {\n let fixed = super.replace(string, prefix);\n if (prefix === '-webkit-') {\n fixed = fixed.replace(/(\"[^\"]+\"|'[^']+')(\\s+\\d+\\w)/gi, 'url($1)$2');\n }\n return fixed\n }", "title": "" }, { "docid": "98bfddbb80e52be2482f6a93c5cb0e3b", "score": "0.54008365", "text": "function getUrlScheme(url){var match=_split(url);return match&&match[_ComponentIndex.Scheme]||\"\"}// The code below is adapted from Traceur:", "title": "" }, { "docid": "897e0d0090f4720b1d17a299eaac706d", "score": "0.5396462", "text": "function X(t,e){return encodeURIComponent(t).replace(/%40/gi,\"@\").replace(/%3A/gi,\":\").replace(/%24/g,\"$\").replace(/%2C/gi,\",\").replace(/%3B/gi,\";\").replace(/%20/g,e?\"%20\":\"+\")}", "title": "" }, { "docid": "7915c407134fbc9565c935eacb762729", "score": "0.53956544", "text": "function getUrlScheme(url){var match=_split(url);return match&&match[_ComponentIndex.Scheme]||'';}// The code below is adapted from Traceur:", "title": "" }, { "docid": "7915c407134fbc9565c935eacb762729", "score": "0.53956544", "text": "function getUrlScheme(url){var match=_split(url);return match&&match[_ComponentIndex.Scheme]||'';}// The code below is adapted from Traceur:", "title": "" }, { "docid": "33d32e8e52facec862a6821438d72801", "score": "0.5391195", "text": "function autoAddBaseUrl(textbox){\n\tvar value=jQuery(textbox).val();\n\tif(value=='')\n\t\treturn;\n\tif(/(ftp|http|https):\\/\\/(\\w+:{0,1}\\w*@)?(\\S+)(:[0-9]+)?(\\/|\\/([\\w#!:.?+=&%@!\\-\\/]))?/.test(value)==false){\n\t\tvalue=value.replace(/[|\";:\\$\\/#\\?&@%<>\\(\\)\\+~]/g,' ');\n\t\tvalue=value.replace(/\\s+/,'_');\n\t\tjQuery(textbox).attr('labelvalue',value);\n\t\tjQuery(textbox).val(value);\n\t}\n}", "title": "" }, { "docid": "869d000c88a48f6d2f9e3f7e89fbac7e", "score": "0.5388569", "text": "function amperOctoPlus(url) {\n url = url.replace(/%26/g, '%26');\n url = url.replace(/#/g, '%23');\n url = url.replace(/\\+/g, '%2B');\n url = url.replace(/@/g, '%40');\n url = url.replace(/:/g, '%3A');\n return url;\n }", "title": "" }, { "docid": "4ce142c7228910e35068797d71bdfff8", "score": "0.5371422", "text": "function removeProtocolPrefix(url) {\n return url.replace(/^[a-zA-Z]+\\:\\/\\//, '');\n}", "title": "" }, { "docid": "d27bd10467ee6048768f5339e5293cda", "score": "0.53688383", "text": "getAMPUrl(url) {\n return url.replace('www.', 'amp.');\n }", "title": "" }, { "docid": "6d631619ff8f8b3d478bef7e3002812b", "score": "0.53687", "text": "function cleanLinks (rawLink) {\n if (!rawLink) return rawLink\n // Assuming that all the links here use https://\n rawLink = rawLink.replace(/(\\S)(https?:\\/\\/)/g, '$1 $2').split('?fbclid=')[0]\n if (!rawLink.startsWith('http')) rawLink = 'https://' + rawLink\n return rawLink\n}", "title": "" }, { "docid": "03d010058b2ba420966e7e3dcbc4acaa", "score": "0.5364656", "text": "function amperOctoPlus(url) {\n url = url.replace(/&/g, '%26');\n url = url.replace(/#/g, '%23');\n url = url.replace(/\\+/g, '%2B');\n url = url.replace(/@/g, '%40');\n url = url.replace(/:/g, '%3A');\n return url;\n }", "title": "" }, { "docid": "74f376150f11a365c52fd24e59578161", "score": "0.5362564", "text": "function protocol(value) {\n var val = value.slice(-6).toLowerCase();\n return val === 'mailto' || val.slice(-5) === 'https' || val.slice(-4) === 'http';\n}", "title": "" }, { "docid": "c896f34af4a28225e127bc62f0778019", "score": "0.5357677", "text": "function normalizeUrl(url) {\n return url.replace(/https?:\\/\\/[^\\/]+/,'');\n}", "title": "" }, { "docid": "c0bd0b79080b4aa7152b3a8d688ac4b5", "score": "0.534617", "text": "function replaceHttps(data){\n return data ? data.replace(/^http:\\/\\//i, 'https://') : '' \n}", "title": "" }, { "docid": "dafc5cac8e66777c5ca72cd1c5666841", "score": "0.5340393", "text": "function completeProtocol(baseDomain) {\n let domain = url.parse(baseDomain);\n let httpProtocol = 'http:';\n if (!domain.protocol) {\n if (baseDomain.slice(0, 2) !== '//') {\n httpProtocol += '//';\n }\n domain = url.parse(`${httpProtocol}${baseDomain}`);\n }\n return domain;\n}", "title": "" }, { "docid": "d2bd187d8c111b9104282350f6091d11", "score": "0.5332113", "text": "function check_url(str) {\n const a = url.parse(str);\n return a.protocol !== null && types_1.Constants.protocols.indexOf(a.protocol) !== -1;\n}", "title": "" }, { "docid": "d2bd187d8c111b9104282350f6091d11", "score": "0.5332113", "text": "function check_url(str) {\n const a = url.parse(str);\n return a.protocol !== null && types_1.Constants.protocols.indexOf(a.protocol) !== -1;\n}", "title": "" }, { "docid": "8d5485050199da74e94b625e02cc5b38", "score": "0.53281546", "text": "function removeProtocol(href) {\n return href.replace(/.*?:\\/\\//g, \"\");\n }", "title": "" }, { "docid": "b0ced3f55c17566888e120a3f5f54f4b", "score": "0.5312987", "text": "function href_from_string_arg(a) {\r\n\t// The string extraction RE isn't right, but the URLs never seem \r\n\t// to contain escaped apostrophes anyway.\r\n\ta.href = unescape(eval_string(a.href.match(/'(\\\\'|[^'])+'/)[0]));\r\n}", "title": "" }, { "docid": "5b1e5ed0d9b2a7df9865d7c376fc3064", "score": "0.5296369", "text": "function urlify(text) {\n var urlRegex = /(https?:\\/\\/[^\\s]+)/g;\n return text.replace(urlRegex, function (url) {\n return url;\n })\n}", "title": "" }, { "docid": "9d8fdd8ea6d21f6f516167cf3d91492f", "score": "0.5293169", "text": "function browserReady(href){\n href = href.replace(/,/g, \"%2C\");\n href = href.replace(/:/g, \"%3A\");\n href = href.replace(/\\//g, \"%2F\");\n href = href.replace(/ /g, \"%20\");\n href = href.replace(/\\n/g, \"%0D%0A\");\n return href;\n}", "title": "" }, { "docid": "a783d5e79f72b0184fc6cc62d9bb85a7", "score": "0.52894956", "text": "function URLify(string){\n let stringArr = string.trim().split(\" \");\n let result = \"\"\n let i = 0; \n while(i < stringArr.length){\n if(i === stringArr.length - 1){\n result += stringArr[i]\n }else{\n result += stringArr[i] + '%20'\n }\n i++\n }\n\n return result\n}", "title": "" }, { "docid": "b956a24e87fa52fa4104f60f637154dd", "score": "0.52888167", "text": "function fixFirstBadEscapeCharacter(uri) {\n var patt=/\\.([0-9a-fA-F][0-9a-fA-F])/;\n var escapeChar = patt.exec(uri);\n if(escapeChar.length > 0){\n var val = escapeChar[1];\n var patt2=new RegExp(\"\\.\" + val, 'g');\n var ret = uri.replace(patt2, '%' + val);\n return ret;\n }\n return uri;\n \n}", "title": "" }, { "docid": "d6b307f2091aa6ecbb8581a21fb01d0b", "score": "0.52879184", "text": "function properlyEncoded(linkdef) {\r\n\t\t\treturn linkdef.replace(/^\\s*(.*?)(?:\\s+\"(.+)\")?\\s*$/, function (wholematch, link, title) {\r\n\t\t\t\t\r\n\t\t\t\tvar inQueryString = false;\r\n\r\n\t\t\t\t// The last alternative, `[^\\w\\d-./]`, is just a shortcut that lets us skip\r\n\t\t\t\t// the most common characters in URLs. Replacing it with `.` would not change\r\n\t\t\t\t// the result, because encodeURI returns those characters unchanged, but it\r\n\t\t\t\t// would mean lots of unnecessary replacement calls\r\n\t\t\t\tlink = link.replace(/%(?:[\\da-fA-F]{2})|\\?|\\+|[^\\w\\d-./]/g, function (match) {\r\n\t\t\t\t\t// Valid percent encoding. Could just return it as is, but we follow RFC3986\r\n\t\t\t\t\t// Section 2.1 which says \"For consistency, URI producers and normalizers\r\n\t\t\t\t\t// should use uppercase hexadecimal digits for all percent-encodings.\"\r\n\t\t\t\t\t// Note that we also handle (illegal) stand-alone percent characters by\r\n\t\t\t\t\t// replacing them with \"%25\"\r\n\t\t\t\t\tif (match.length === 3 && match.charAt(0) == \"%\") {\r\n\t\t\t\t\t\treturn match.toUpperCase();\r\n\t\t\t\t\t}\r\n\t\t\t\t\tswitch (match) {\r\n\t\t\t\t\t\tcase \"?\":\r\n\t\t\t\t\t\t\tinQueryString = true;\r\n\t\t\t\t\t\t\treturn \"?\";\r\n\t\t\t\t\t\t\r\n\t\t\t\t\t\t// In the query string, a plus and a space are identical -- normalize.\r\n\t\t\t\t\t\t// Not strictly necessary, but identical behavior to the previous version\r\n\t\t\t\t\t\t// of this function.\r\n\t\t\t\t\t\tcase \"+\":\r\n\t\t\t\t\t\t\tif (inQueryString)\r\n\t\t\t\t\t\t\t\treturn \"%20\";\r\n\t\t\t\t\t\t\tbreak;\r\n\t\t\t\t\t}\r\n\t\t\t\t\treturn encodeURI(match);\r\n\t\t\t\t});\r\n\t\t\t\t\r\n\t\t\t\tif (title) {\r\n\t\t\t\t\ttitle = title.trim ? title.trim() : title.replace(/^\\s*/, \"\").replace(/\\s*$/, \"\");\r\n\t\t\t\t\ttitle = title.replace(/\"/g, \"quot;\").replace(/\\(/g, \"&#40;\").replace(/\\)/g, \"&#41;\").replace(/</g, \"&lt;\").replace(/>/g, \"&gt;\");\r\n\t\t\t\t}\r\n\t\t\t\treturn title ? link + ' \"' + title + '\"' : link;\r\n\t\t\t});\r\n\t\t}", "title": "" }, { "docid": "d3e582c37884ad78f491f152570cccfb", "score": "0.52860653", "text": "function protocol(value) {\n var val = value.slice(-6).toLowerCase()\n return val === mailto || val.slice(-5) === https || val.slice(-4) === http\n}", "title": "" }, { "docid": "2dc05b0b58790ba9be1199b8965d5e1b", "score": "0.5277665", "text": "function normalizeUrl (theUrl) {\n // This should work but doesn't due to a bug in the url library\n // see https://github.com/joyent/node/issues/6100\n //var urlObj = url.parse(theUrl);\n //if (!urlObj.protocol) {\n //urlObj.slashes = true;\n //urlObj.protocol = 'http';\n //}\n //return url.format(urlObj);\n\n // Using ugly hack instead\n if (theUrl.match(/^\\/\\//)) {\n theUrl = 'http:' + theUrl; // Not respecting the user and using http protocol regardless, he should have used an absolute url anyway!\n }\n if (!theUrl.match(/^https?:\\/\\//)) {\n theUrl = 'http://' + theUrl;\n }\n return theUrl;\n}", "title": "" }, { "docid": "375ce7ca9f4312d14f743357f05f8575", "score": "0.52769786", "text": "function encoreUrl(url){\r\n\treturn url.replace(/#/g,\"%%23\");\r\n}", "title": "" }, { "docid": "96ce80d718b468d7dca4b9c3d726d203", "score": "0.52751917", "text": "function urlify(text) {\n if (text != undefined) {\n var urlRegex = /(http(s)?:\\/\\/.)(www\\.)?(?!@)([-a-zA-Z0-9@:%._\\+~#=]{2,256}\\.[a-z]{2,6}\\b([-a-zA-Z0-9@:%_\\+.~#?&//=]*))/gim;\n return text.replace(urlRegex, function(url) {\n return '<a href=\"' + url + '\" class=\"link external\" target=\"_blank\">' + url + '</a>';\n });\n }\n\n\n}", "title": "" }, { "docid": "e679ebfbf32b8ab754c5e2c23c9cc07a", "score": "0.526767", "text": "function url_base() {\n\treturn 'http://' + document.URL.split('/')[2];\n}", "title": "" }, { "docid": "c3624a62f88b6bf33df6c3722ea9c154", "score": "0.52452517", "text": "function CanonicalShortURL() {\n}", "title": "" }, { "docid": "d7c7c1f28bae6c0e46dfd3b20d00cc5e", "score": "0.52441674", "text": "function linkscapePrepUrls_ (urls) {\n var retval = [];\n if (SeerJs.Utils.isArray(urls)) {\n // remove outer array if we get columns\n if (SeerJs.Utils.isColumn(urls)) {\n var i = 0; var len = urls.length;\n while (i < len) {\n retval.push(urls[i]);\n i++;\n }\n } else {\n retval = urls;\n }\n } else { \n // if we get a string, convert it to an array.\n retval = SeerJs.Utils.strToArray(urls);\n }\n // remove protocol or seomoz doesn't work right.\n for (var i = 0; i < retval.length; i++) {\n retval[i] = retval[i].toString().replace(/http(s)?:\\/\\//gi, \"\");\n }\n return retval;\n }", "title": "" }, { "docid": "d44f270e08c7a04c67f37799b8096f46", "score": "0.52405083", "text": "function cleanUrl(url) {\n url = url.toLowerCase().trim();\n // remove http/https, parameters, and trailing slash\n var urlParts = url.replace('http://','').replace('https://','').split(/[/?#]/);\n url = urlParts[0]\n\n // todo -> check if necessary\n if (url.startsWith(\"www.\")) {\n url = url.replace(\"www.\", \"\")\n }\n\n return url;\n}", "title": "" }, { "docid": "ebda4d8a050bf5aee2ece46e9e1455b2", "score": "0.5240492", "text": "function URLify(str){\n\n for (let i = 0; i < str.length - 1; i ++){\n if (str.charAt(i) === ' '){\n str = str.replace(' ', '%20');\n }\n }\n\n console.log(str);\n}", "title": "" }, { "docid": "837ea0043eb868a8a4c27e71d9944bd5", "score": "0.5233385", "text": "function buildurl(input) {\n return input ?\n ('\\'' + input + '\\'')\n .replace(/([^:]\\/)\\/+/g, '$1') :\n '';\n}", "title": "" }, { "docid": "0c3f80f14b9639349fdb1d65fd424927", "score": "0.5206882", "text": "replaceUrlHostname(url) {\n return (url && url.replace(\"https://www.apteka24.ua\", this.env.getBitrixHost())) || \"\";\n }", "title": "" }, { "docid": "6aa751b45bcbeb4d84d67a1148f872a2", "score": "0.5204839", "text": "function connectUrl(url) {\n return wcmUrl+\"?url=\"+encodeURIComponent(url);\n}", "title": "" } ]
85f251eb98bfc8595cbe55df96ca16bb
Gets the child [Dialog](xref:botbuilderdialogs.Dialog) dependencies so they can be added to the containers [Dialog](xref:botbuilderdialogs.Dialog) set.
[ { "docid": "810d26611f74ab45c81dab675d63d24e", "score": "0.74518806", "text": "getDependencies() {\n if (this.dialog && this.dialog.value) {\n return [this.dialog.value];\n }\n return [];\n }", "title": "" } ]
[ { "docid": "832dff8f02de6c0b6616ade04574a24a", "score": "0.64052236", "text": "getDialogComponents(){\n\t\treturn this.getDialogManager()\n\t\t\t\t.getDialogs()\n\t\t\t\t.map((dialog, index) => <DialogComponent dialog={dialog} key={index} />);\n\t}", "title": "" }, { "docid": "2170be6b6bf11f511a58fb74bf10c2fc", "score": "0.5906049", "text": "getDialogContainer() {\n throw new Error('DialogRenderer must implement getDialogContainer().');\n }", "title": "" }, { "docid": "950593dcc1e98d8b4777150242332676", "score": "0.57446486", "text": "function FindDialog( inItem ) {\n\tvar w = inItem;\n\twhile ( 'dialog' != w.type ) {\n\t\tif ( undefined == w.parent ) {\n\t\t\tw = null;\n\t\t\tbreak;\n\t\t}\n\t\tw = w.parent;\n\t}\n\treturn w;\n}", "title": "" }, { "docid": "b88208ff5086a76b62eff219a7821962", "score": "0.5674023", "text": "function getClosestDialog(element, openDialogs) {\n let parent = element.nativeElement.parentElement;\n while (parent && !parent.classList.contains('mat-mdc-dialog-container')) {\n parent = parent.parentElement;\n }\n return parent ? openDialogs.find(dialog => dialog.id === parent.id) : null;\n}", "title": "" }, { "docid": "d5133c575c022f614b766190b9723930", "score": "0.5584082", "text": "function getClosestDialog(element, openDialogs) {\n let parent = element.nativeElement.parentElement;\n while (parent && !parent.classList.contains('mat-dialog-container')) {\n parent = parent.parentElement;\n }\n return parent ? openDialogs.find(dialog => dialog.id === parent.id) : null;\n}", "title": "" }, { "docid": "d5133c575c022f614b766190b9723930", "score": "0.5584082", "text": "function getClosestDialog(element, openDialogs) {\n let parent = element.nativeElement.parentElement;\n while (parent && !parent.classList.contains('mat-dialog-container')) {\n parent = parent.parentElement;\n }\n return parent ? openDialogs.find(dialog => dialog.id === parent.id) : null;\n}", "title": "" }, { "docid": "d5133c575c022f614b766190b9723930", "score": "0.5584082", "text": "function getClosestDialog(element, openDialogs) {\n let parent = element.nativeElement.parentElement;\n while (parent && !parent.classList.contains('mat-dialog-container')) {\n parent = parent.parentElement;\n }\n return parent ? openDialogs.find(dialog => dialog.id === parent.id) : null;\n}", "title": "" }, { "docid": "368879dd0c29c4ef9e23db72fdd7f1e2", "score": "0.55216765", "text": "get openDialogs() {\n return this._parentDialog ? this._parentDialog.openDialogs : this._openDialogsAtThisLevel;\n }", "title": "" }, { "docid": "368879dd0c29c4ef9e23db72fdd7f1e2", "score": "0.55216765", "text": "get openDialogs() {\n return this._parentDialog ? this._parentDialog.openDialogs : this._openDialogsAtThisLevel;\n }", "title": "" }, { "docid": "368879dd0c29c4ef9e23db72fdd7f1e2", "score": "0.55216765", "text": "get openDialogs() {\n return this._parentDialog ? this._parentDialog.openDialogs : this._openDialogsAtThisLevel;\n }", "title": "" }, { "docid": "c9a932d4c4977917bee331f4105fc1a1", "score": "0.55040085", "text": "get dependencies() {\n if (this._deps) {\n return this._deps;\n }\n this._deps = this._dependencyIDs.map(id => {\n const dep = this.assembly.tryGetArtifact(id);\n if (!dep) {\n throw new Error(`Artifact ${this.id} depends on non-existing artifact ${id}`);\n }\n return dep;\n });\n return this._deps;\n }", "title": "" }, { "docid": "80106bb51ef9b86fc9f0f42ea99cdede", "score": "0.5503471", "text": "function getDialog(id) {\n if (!_isNullOrUndefined(_dialogs[id])) {\n return _dialogs[id];\n }\n return NULL;\n }", "title": "" }, { "docid": "726081154579c6453bcdb7c4479f9f74", "score": "0.5484252", "text": "getClosestDialog(element) {\n let parent = element.parentElement;\n while (parent && !parent.classList.contains('thy-dialog-container')) {\n parent = parent.parentElement;\n }\n if (parent && parent.id) {\n return this.getDialogById(parent.id);\n }\n return null;\n }", "title": "" }, { "docid": "55cc39caeca41a5a0293b2af4460b979", "score": "0.54499555", "text": "getDialogById(id) {\n return this.openDialogs.find(dialog => dialog.id === id);\n }", "title": "" }, { "docid": "55cc39caeca41a5a0293b2af4460b979", "score": "0.54499555", "text": "getDialogById(id) {\n return this.openDialogs.find(dialog => dialog.id === id);\n }", "title": "" }, { "docid": "55cc39caeca41a5a0293b2af4460b979", "score": "0.54499555", "text": "getDialogById(id) {\n return this.openDialogs.find(dialog => dialog.id === id);\n }", "title": "" }, { "docid": "7c95e8f83525fb153015041807d793e2", "score": "0.5405021", "text": "createChildDialogs() {\n let bot = this.bot;\n //console.log(bot);\n // *************************** BEGINNING OF EXAMPLES ***************************\n new GetStudentsDialog_1.GetStudentsDialog(bot);\n new ExtendDueDateDialog_1.ExtendDueDateDialog(bot);\n new MissingDueDateDialog_1.MissingDueDateDialog(bot);\n new FailingGradesDialog_1.FailingGradesDialog(bot);\n new ResetUserStateDialog_1.ResetUserStateDialog(bot);\n new VSTSAPICallDialog_1.VSTSAPICallDialog(bot);\n new VSTSAuthValidateUserDialog_1.VSTSAuthValidateUserDialog(bot);\n new VSTSLogInDialog_1.VSTSLogInDialog(bot);\n new GetLastDialogUsedDialog_1.GetLastDialogUsedDialog(bot);\n new HelloDialog_1.HelloDialog(bot);\n new HelpDialog_1.HelpDialog(bot);\n new HeroCardDialog_1.HeroCardDialog(bot);\n new MessageBackReceiverDialog_1.MessageBackReceiverDialog(bot);\n new MultiDialog_1.MultiDialog(bot);\n new O365ConnectorCardActionsDialog_1.O365ConnectorCardActionsDialog(bot);\n new O365ConnectorCardDialog_1.O365ConnectorCardDialog(bot);\n new ThumbnailCardDialog_1.ThumbnailCardDialog(bot);\n new TimezoneDialog_1.TimezoneDialog(bot);\n new BeginDialogFlowDialog_1.BeginDialogFlowDialog(bot);\n new ConstructorArgsDialog_1.ConstructorArgsDialog(bot, \"12345\");\n new ListNamesDialog_1.ListNamesDialog(bot);\n new LuisRecognizerNatLanguageDialog_1.LuisRecognizerNatLanguageDialog(bot);\n new PromptDialog_1.PromptDialog(bot);\n new QuizFullDialog_1.QuizFullDialog(bot);\n new QuizQ1Dialog_1.QuizQ1Dialog(bot);\n new QuizQ2Dialog_1.QuizQ2Dialog(bot);\n new QuizQ3Dialog_1.QuizQ3Dialog(bot);\n new AtMentionDialog_1.AtMentionDialog(bot);\n new ChannelDataDialog_1.ChannelDataDialog(bot);\n new DeeplinkDialog_1.DeeplinkDialog(bot);\n new FetchRosterDialog_1.FetchRosterDialog(bot);\n new FetchTeamInfoDialog_1.FetchTeamInfoDialog(bot);\n new ProactiveMsgTo1to1Dialog_1.ProactiveMsgTo1to1Dialog(bot);\n new ProactiveMsgToChannelDialog_1.ProactiveMsgToChannelDialog(bot);\n new UpdateCardMsgDialog_1.UpdateCardMsgDialog(bot);\n new UpdateCardMsgSetupDialog_1.UpdateCardMsgSetupDialog(bot);\n new UpdateTextMsgDialog_1.UpdateTextMsgDialog(bot);\n new UpdateTextMsgSetupDialog_1.UpdateTextMsgSetupDialog(bot);\n new NotifyDialog_1.NotifyDialog(bot);\n new PopupSignInDialog_1.PopupSignInDialog(bot);\n // *************************** END OF EXAMPLES *********************************\n // Add child dialogs\n }", "title": "" }, { "docid": "b29b0fb5069b5f805020953d10bf18c5", "score": "0.52749693", "text": "makeDialog() {\n\t\t\tthis.dialog = {\n\t\t\t\telements: new jsPanelDialogElements(this),\n\t\t\t\tvalues: new jsPanelDialogValues(this),\n\t\t\t\tvalue: undefined\n\t\t\t};\n\t\t\tconst cb = async ev => {\n\t\t\t\tlet el = ev.target.closest(\"[name]\");\n\t\t\t\tev.stopPropagation();\n\t\t\t\tif (el) {\n\t\t\t\t\tconst name = el ? el.getAttribute(\"name\") : \"\";\n\t\t\t\t\tconst cbName = `on${ev.type}_${name}`;\n\t\t\t\t\tif (this.options[cbName])\n\t\t\t\t\t\tjsPanel.processCallbacks(this, this.options[cbName], \"every\", el, ev);\n\t\t\t\t}\n\t\t\t\telse\n\t\t\t\t\tel = ev.target;\n\t\t\t\tif (el.hasAttribute(\"data-dismiss\") && this.parentElement) {\n\t\t\t\t\t// grab any value if not set yet\n\t\t\t\t\tif (this.dialog.value === undefined)\n\t\t\t\t\t\tthis.dialog.value = jsPanel.dialog.helpers.getValue(this, el, false);\n\t\t\t\t\tthis.close();\n\t\t\t\t}\n\t\t\t};\n\t\t\tthis.addEventListener(\"click\", cb);\n\t\t\tthis.addEventListener(\"input\", cb);\n\t\t\tthis.addEventListener(\"dblclick\", ev => {\n\t\t\t\tconst el = this.querySelector(\"[data-dblclick]\");\n\t\t\t\tif (el) {\n\t\t\t\t\tev.stopPropagation();\n\t\t\t\t\tel.click();\n\t\t\t\t}\n\t\t\t});\n\t\t\tthis.options.closeOnEscape = _ => {\n\t\t\t\t// Trigger a data-cancel element if present\n\t\t\t\tconst el = this.querySelector(\"[data-cancel]\");\n\t\t\t\tif (el)\n\t\t\t\t\tel.click();\n\t\t\t\treturn false;\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "30703bd06203cc2294843ab3e01157eb", "score": "0.5197447", "text": "static get dialogElements() {\n SuiLayoutDialog._dialogElements = typeof(SuiLayoutDialog._dialogElements) !== 'undefined' ? SuiLayoutDialog._dialogElements :\n [{\n smoName: 'pageSize',\n parameterName: 'pageSize',\n defaultValue: SmoScore.pageSizes.letter,\n control: 'SuiDropdownComponent',\n label: 'Page Size',\n options: [\n {\n value: 'letter',\n label: 'Letter'\n }, {\n value: 'tabloid',\n label: 'Tabloid (11x17)'\n }, {\n value: 'A4',\n label: 'A4'\n }, {\n value: 'custom',\n label: 'Custom'\n }]\n }, {\n smoName: 'pageWidth',\n parameterName: 'pageWidth',\n defaultValue: SmoScore.defaults.layout.pageWidth,\n control: 'SuiRockerComponent',\n label: 'Page Width (px)'\n }, {\n smoName: 'pageHeight',\n parameterName: 'pageHeight',\n defaultValue: SmoScore.defaults.layout.pageHeight,\n control: 'SuiRockerComponent',\n label: 'Page Height (px)'\n }, {\n smoName: 'orientation',\n parameterName: 'orientation',\n defaultValue: SmoScore.orientations.portrait,\n control: 'SuiDropdownComponent',\n label: 'Orientation',\n dataType: 'int',\n options: [{\n value: SmoScore.orientations.portrait,\n label: 'Portrait'\n }, {\n value: SmoScore.orientations.landscape,\n label: 'Landscape'\n }]\n }, {\n smoName: 'engravingFont',\n parameterName: 'engravingFont',\n defaultValue: SmoScore.engravingFonts.Bravura,\n control: 'SuiDropdownComponent',\n label: 'Engraving Font',\n options: [{\n value: 'Bravura',\n label: 'Bravura'\n }, {\n value: 'Gonville',\n label: 'Gonville'\n }, {\n value: 'Petaluma',\n label: 'Petaluma'\n }, {\n value: 'Leland',\n label: 'Leland'\n }]\n }, {\n smoName: 'leftMargin',\n parameterName: 'leftMargin',\n defaultValue: SmoScore.defaults.layout.leftMargin,\n control: 'SuiRockerComponent',\n label: 'Left Margin (px)'\n }, {\n smoName: 'rightMargin',\n parameterName: 'rightMargin',\n defaultValue: SmoScore.defaults.layout.rightMargin,\n control: 'SuiRockerComponent',\n label: 'Right Margin (px)'\n }, {\n smoName: 'topMargin',\n parameterName: 'topMargin',\n defaultValue: SmoScore.defaults.layout.topMargin,\n control: 'SuiRockerComponent',\n label: 'Top Margin (px)'\n }, {\n smoName: 'interGap',\n parameterName: 'interGap',\n defaultValue: SmoScore.defaults.layout.interGap,\n control: 'SuiRockerComponent',\n label: 'Inter-System Margin'\n }, {\n smoName: 'intraGap',\n parameterName: 'intraGap',\n defaultValue: SmoScore.defaults.layout.intraGap,\n control: 'SuiRockerComponent',\n label: 'Intra-System Margin'\n }, {\n smoName: 'noteSpacing',\n parameterName: 'noteSpacing',\n defaultValue: SmoScore.defaults.layout.noteSpacing,\n control: 'SuiRockerComponent',\n type: 'percent',\n label: 'Note Spacing'\n }, {\n smoName: 'zoomScale',\n parameterName: 'zoomScale',\n defaultValue: SmoScore.defaults.layout.zoomScale,\n control: 'SuiRockerComponent',\n label: '% Zoom',\n type: 'percent'\n }, {\n smoName: 'svgScale',\n parameterName: 'svgScale',\n defaultValue: SmoScore.defaults.layout.svgScale,\n control: 'SuiRockerComponent',\n label: '% Note size',\n type: 'percent'\n }, {\n staticText: [\n { label: 'Score Layout' }\n ]\n }];\n return SuiLayoutDialog._dialogElements;\n }", "title": "" }, { "docid": "4b44fa2600eeb3bd9ec3fa433fe5554e", "score": "0.5145354", "text": "static disposeAll() {\n const clone = Dialog.Instances.slice();\n clone.forEach((dialog) => {\n dialog.dispose();\n });\n }", "title": "" }, { "docid": "342d9644339ad8cdd469ff4dfbec4586", "score": "0.5144562", "text": "function thisDialog() {\n\treturn window.dialogs[window.name];\n}", "title": "" }, { "docid": "bbe46a1e2c4341c7196551fb95396a51", "score": "0.5127795", "text": "findDialog(dialogId) {\n if (this.dialogs.hasOwnProperty(dialogId)) {\n return this.dialogs[dialogId];\n }\n else {\n return promptSet_1.PromptSet.findPromptDialog(dialogId);\n }\n }", "title": "" }, { "docid": "66007ba6d9d745508266709eb19535ad", "score": "0.5107963", "text": "handleOtherOpenDialogs() {\n this.z = Dialog.getTopLayer() + 20;\n this.element.style.zIndex = this.z;\n this.backdrop.style.zIndex = this.z - 5;\n\n // When this dialog is closed, revert the z-index back to its original value.\n this.once(Dialog.EventType.CLOSED, () => {\n this.z = Dialog.Z_BASE;\n this.element.style.zIndex = '';\n this.backdrop.style.zIndex = '';\n\n // Find new top dialog.\n const zTop = Dialog.getTopLayer();\n\n Dialog.Instances.forEach((instance) => {\n if (instance.isOpen && instance.z === zTop) {\n instance.didEnterForeground();\n }\n });\n });\n\n // Tell other dialogs they're going into the background.\n Dialog.Instances.forEach((instance) => {\n if (instance.isOpen && instance.id !== this.id) {\n instance.didEnterBackground();\n }\n });\n }", "title": "" }, { "docid": "f59fd2f69d9e2f21b0189180441bad09", "score": "0.51056534", "text": "getParentDependencies() {\n return Object.keys(\n this.parent.dependencies(this.parent.pkg, !this.parent.isEmberCLIAddon())\n );\n }", "title": "" }, { "docid": "f59fd2f69d9e2f21b0189180441bad09", "score": "0.51056534", "text": "getParentDependencies() {\n return Object.keys(\n this.parent.dependencies(this.parent.pkg, !this.parent.isEmberCLIAddon())\n );\n }", "title": "" }, { "docid": "54349230edab1f68bd2b627734977efb", "score": "0.5064661", "text": "createDialog() {\n let dialog = this.getDialogWrapper();\n\n if (!dialog.length) {\n dialog = $(`<div id=\"${internalDialogId}\" />`)\n .addClass(dialogWrapperClass);\n\n $('body').append(dialog);\n }\n }", "title": "" }, { "docid": "5d83daa6ee88461c0cd85074caa490df", "score": "0.5025662", "text": "function getDialogConstraints() { \n\treturn {\"minheight\":200,\"minwidth\":300,\"h\":20,\"v\":130};\n}", "title": "" }, { "docid": "683120b7c63d5c04822167485086d826", "score": "0.50027233", "text": "initDialogs() {\n this.deleteItemDialog =\n <DeleteItemDialog\n onDeleteClick={this._deleteItem.bind(this)}\n />;\n }", "title": "" }, { "docid": "5c93b1b199c5956731fffdff7a61b186", "score": "0.4994641", "text": "static get dependencies(): Array<any> {\n return []\n }", "title": "" }, { "docid": "eba55a2c82468a82a6f38e7e0af065e6", "score": "0.49701327", "text": "function TDialogControl() {\n\tthis.queue = new Array();\n\tthis.objects = new Array();\n\t\n\tthis.Add = TDialogControl_Add;\n\tthis.Get = TDialogControl_Get;\n\tthis.HideAll = TDialogControl_HideAll;\n\t\n\tthis.AddQueue = TDialogControl_AddQueue;\n\tthis.RunQueue = TDialogControl_RunQueue;\n\t\n\t// add a layer name do an asynchronous queue\n\tfunction TDialogControl_AddQueue( sLayer ) {\n\t\tthis.queue.length ++;\n\t\tthis.queue[ this.queue.length - 1 ] = sLayer;\n\t}\n\n\t// creates the dialog controllers based on the previous queue\t\n\tfunction TDialogControl_RunQueue() {\n\t\tfor ( var i = 0; i < this.queue.length; i ++ ) {\n\t\t\tthis.Add( new TDialogBox( this.queue[ i ] ) );\n\t\t}\n\t\tthis.HideAll();\n\t}\n\t\n\t// add a new dialog box to the queue\n\tfunction TDialogControl_Add( objDialog ) {\n\t\tif ( !objDialog ) { return }\n\t\tvar i = this.objects.length;\n\t\tthis.objects.length = i + 1;\n\t\tthis.objects[ i ] = objDialog;\n\t\tobjDialog.parent = this;\n\t}\n\t\n\t// return the handler of the dialog box\n\tfunction TDialogControl_Get( sLabel ) {\n\t\tfor ( var i = 0; i < this.objects.length; i ++ ) {\n\t\t\tif ( this.objects[ i ].Name() == sLabel ) {\n\t\t\t\treturn this.objects[ i ];\n\t\t\t}\n\t\t}\n\t\treturn null;\n\t}\n\t\n\t// hide all dialogs controls\n\tfunction TDialogControl_HideAll() {\n\t\tif ( this.objects.length > 0 ) {\n\t\t\tfor ( var i = 0; i < this.objects.length; i ++ ) {\n\t\t\t\tthis.objects[ i ].Hide();\n\t\t\t}\n\t\t}\n\t}\n}", "title": "" }, { "docid": "83693e412fe22dedc25872f3f69ee7c6", "score": "0.49676734", "text": "function Dialog(props) {\n var _classNames;\n\n var children = props.children,\n classes = props.classes,\n className = props.className,\n fullScreen = props.fullScreen,\n fullWidth = props.fullWidth,\n disableBackdropClick = props.disableBackdropClick,\n disableEscapeKeyDown = props.disableEscapeKeyDown,\n maxWidth = props.maxWidth,\n onBackdropClick = props.onBackdropClick,\n onClose = props.onClose,\n onEnter = props.onEnter,\n onEntered = props.onEntered,\n onEntering = props.onEntering,\n onEscapeKeyDown = props.onEscapeKeyDown,\n onExit = props.onExit,\n onExited = props.onExited,\n onExiting = props.onExiting,\n open = props.open,\n PaperProps = props.PaperProps,\n TransitionProp = props.transition,\n transitionDuration = props.transitionDuration,\n other = (0, _objectWithoutProperties3.default)(props, ['children', 'classes', 'className', 'fullScreen', 'fullWidth', 'disableBackdropClick', 'disableEscapeKeyDown', 'maxWidth', 'onBackdropClick', 'onClose', 'onEnter', 'onEntered', 'onEntering', 'onEscapeKeyDown', 'onExit', 'onExited', 'onExiting', 'open', 'PaperProps', 'transition', 'transitionDuration']);\n\n\n return _react2.default.createElement(\n _Modal2.default,\n (0, _extends3.default)({\n className: (0, _classnames2.default)(classes.root, className),\n BackdropProps: {\n transitionDuration: transitionDuration\n },\n disableBackdropClick: disableBackdropClick,\n disableEscapeKeyDown: disableEscapeKeyDown,\n onBackdropClick: onBackdropClick,\n onEscapeKeyDown: onEscapeKeyDown,\n onClose: onClose,\n open: open,\n role: 'dialog'\n }, other),\n _react2.default.createElement(\n TransitionProp,\n {\n appear: true,\n 'in': open,\n timeout: transitionDuration,\n onEnter: onEnter,\n onEntering: onEntering,\n onEntered: onEntered,\n onExit: onExit,\n onExiting: onExiting,\n onExited: onExited\n },\n _react2.default.createElement(\n _Paper2.default,\n (0, _extends3.default)({\n elevation: 24,\n className: (0, _classnames2.default)(classes.paper, (_classNames = {}, (0, _defineProperty3.default)(_classNames, classes['paperWidth' + (maxWidth ? (0, _helpers.capitalize)(maxWidth) : '')], maxWidth), (0, _defineProperty3.default)(_classNames, classes.fullScreen, fullScreen), (0, _defineProperty3.default)(_classNames, classes.fullWidth, fullWidth), _classNames))\n }, PaperProps),\n children\n )\n )\n );\n}", "title": "" }, { "docid": "322fb850d5a8707549c2f62efe79426d", "score": "0.4965198", "text": "function getParents() {\n\n return Object.keys(depends)\n .map(q => [q].concat(depends[q]))\n\n }", "title": "" }, { "docid": "1f8e5be16d73dc1187adbbfc9a970568", "score": "0.49555135", "text": "initDialogs() {\n this.deleteСategoryDialog =\n <DeleteCategoryDialog\n onDeleteClick={this._deleteCategory.bind(this)}\n />;\n\n this.uploadFileDialog =\n <UploadFileDialog\n path={config.staticFiles}\n onUploadSuccess={(file) => this.addCategoryPictureHandler(this.state.selected, file)}\n onUploadFail={(file) => {\n dispatch('notification:throw', {\n type: 'danger',\n title: 'Ошибка',\n message: JSON.stringify(file)\n });\n }}\n />;\n\n this.deletePictureDialog =\n <DeletePictureDialog\n onDeleteClick={this._doDeletePicture.bind(this)}\n />;\n }", "title": "" }, { "docid": "f0e79407575c914c9aeff9cb6c7ec913", "score": "0.49457896", "text": "getKnownDependants() {\n return this._dependants;\n }", "title": "" }, { "docid": "7be5ef98540b84e0aa5de46bebbba050", "score": "0.4924861", "text": "function getTopModalDialog() {\n var dialog = stack.slice(-1)[0];\n if (!dialog) {\n // Something has gone wrong - recover gracefully\n hideModal();\n return null;\n }\n if (!dialog.$dialog.is(':visible')) {\n // Again, this shouldn't happen, ignore this one and get the next\n stack.pop();\n return getTopModalDialog();\n }\n\n return dialog;\n }", "title": "" }, { "docid": "f5e1365e59d27531959a08b807cc21b1", "score": "0.49222305", "text": "_listenEvents() { \n this._unlistenEvents();\n if (this.type !== 'modal') {\n super._listenEvents();\n return;\n }\n let el = this.renderRoot.querySelector('#dialogContainer');\n el.addEventListener('MDCDialog:opened', this._onDialogOpened);\n el.addEventListener('MDCDialog:closed', this._onDialogClosed);\n\n //Bind scroll event of dialog content.\n let scrollEl = this.renderRoot.querySelector('#dialog-content');\n scrollEl.addEventListener('scroll', this._onDialogScroll);\n }", "title": "" }, { "docid": "f07a5298e6e48858441e0d963eba686f", "score": "0.49062982", "text": "extendDependencies() {\n const newDependencies = new inversify_1.Container({ autoBindInjectable: true });\n newDependencies.parent = this.dependencies;\n return newDependencies;\n }", "title": "" }, { "docid": "a7725b75b0eb958a3e8241efbb190998", "score": "0.48703837", "text": "getOwnDependencies() {\n return this.cache.getOrAdd(`ownScriptImports`, () => {\n const value = this.dependencyGraph.getAllDependencies(this.dependencyGraphKey, [this.parentComponentDependencyGraphKey]);\n return value;\n });\n }", "title": "" }, { "docid": "532ca916c45fbcb56271a315094997cc", "score": "0.48649704", "text": "function Dialog(props) {\n var _classNames;\n\n var children = props.children,\n classes = props.classes,\n className = props.className,\n fullScreen = props.fullScreen,\n fullWidth = props.fullWidth,\n disableBackdropClick = props.disableBackdropClick,\n disableEscapeKeyDown = props.disableEscapeKeyDown,\n maxWidth = props.maxWidth,\n onBackdropClick = props.onBackdropClick,\n onClose = props.onClose,\n onEnter = props.onEnter,\n onEntered = props.onEntered,\n onEntering = props.onEntering,\n onEscapeKeyDown = props.onEscapeKeyDown,\n onExit = props.onExit,\n onExited = props.onExited,\n onExiting = props.onExiting,\n open = props.open,\n TransitionProp = props.transition,\n transitionDuration = props.transitionDuration,\n other = (0, _objectWithoutProperties3.default)(props, ['children', 'classes', 'className', 'fullScreen', 'fullWidth', 'disableBackdropClick', 'disableEscapeKeyDown', 'maxWidth', 'onBackdropClick', 'onClose', 'onEnter', 'onEntered', 'onEntering', 'onEscapeKeyDown', 'onExit', 'onExited', 'onExiting', 'open', 'transition', 'transitionDuration']);\n\n\n return _react2.default.createElement(\n _Modal2.default,\n (0, _extends3.default)({\n className: (0, _classnames2.default)(classes.root, className),\n BackdropProps: {\n transitionDuration: transitionDuration\n },\n disableBackdropClick: disableBackdropClick,\n disableEscapeKeyDown: disableEscapeKeyDown,\n onBackdropClick: onBackdropClick,\n onEscapeKeyDown: onEscapeKeyDown,\n onClose: onClose,\n open: open,\n role: 'dialog'\n }, other),\n _react2.default.createElement(\n TransitionProp,\n {\n appear: true,\n 'in': open,\n timeout: transitionDuration,\n onEnter: onEnter,\n onEntering: onEntering,\n onEntered: onEntered,\n onExit: onExit,\n onExiting: onExiting,\n onExited: onExited\n },\n _react2.default.createElement(\n _Paper2.default,\n {\n elevation: 24,\n className: (0, _classnames2.default)(classes.paper, classes['paperWidth' + (0, _helpers.capitalizeFirstLetter)(maxWidth)], (_classNames = {}, (0, _defineProperty3.default)(_classNames, classes.fullScreen, fullScreen), (0, _defineProperty3.default)(_classNames, classes.fullWidth, fullWidth), _classNames))\n },\n children\n )\n )\n );\n}", "title": "" }, { "docid": "0e38cf93d68f4c959a33dfe93b8144ca", "score": "0.4855932", "text": "static resolveDependencies(dependencies) {\n let resolveDependencies = [];\n\n if (dependencies.length > 0) {\n for (let dependency of dependencies) {\n resolveDependencies.push(DI.resolve(dependency)); \n }\n }\n\n return resolveDependencies;\n }", "title": "" }, { "docid": "24ec92d930128b0367a1468dbcd7bc04", "score": "0.484728", "text": "_initDialogueManager() {\n return new DialogueManager(this, this.#client);\n }", "title": "" }, { "docid": "9dae739c3b1584cb3bd45fd915f35634", "score": "0.48331687", "text": "initDialogs() {\n this.deletePageDialog = <DeletePageDialog onDeleteClick={this._deletePage.bind(this)} />;\n }", "title": "" }, { "docid": "9e191d6709766f434d305789ca80dce5", "score": "0.48228216", "text": "function addDialogs() {\n\n // add ShowCommentDialog to /LineItemGroups/Manage to show Line Item comments\n $(\"#CommentsDisplayDialog\").dialog({\n autoOpen: false,\n height: 200,\n width: 400,\n buttons: {\n \"Okay\": function () {\n $(this).dialog(\"close\");\n }\n }\n });\n\n // add Add Vendor dialog and link to /LineItemGroups/Manage\n $('#addVendorDialog').dialog({\n autoOpen: false,\n height: 350,\n width: 800,\n close: function (event, ui) {\n $(\"#VendorSelector\").show();\n $(\"#ContractTypeSelector\").show();\n }\n });\n $('#addVendorLink').click(function () {\n $('#addVendorDialog').dialog(\"open\");\n });\n\n // add Edit Vendor dialog and link to /LineItemGroups/Manage\n $('#editVendorDialog').dialog({\n autoOpen: false,\n height: 350,\n width: 800,\n close: function (event, ui) {\n $(\"#VendorSelector\").show();\n $(\"#ContractTypeSelector\").show();\n }\n });\n $('#editVendorLink').click(function () {\n $('#editVendorDialog').dialog(\"open\");\n });\n\n // add Contract dialog to /LineItemGroups/Manage\n $(\"#ContractDialog\").dialog({\n autoOpen: false,\n width: 1200,\n resizable: false,\n title: 'Contract Information',\n modal: true,\n open: function (event, ui) {\n var url = \"/LineItemGroups/NewContractPartial\";\n if ($(\"#ContractID\").val() > 0) {\n url = \"/LineItemGroups/NewContractPartial/\" + $(\"#ContractID\").val();\n }\n $(this).load(url, function () {\n initContractControls();\n $(\"#ContractNumber\").focus();\n });\n //Contract Types\n $(\"#ContractTypeSelector\").zIndex = $(\"#ContractDialog\").zIndex + 1;\n //Vendors\n $(\"#VendorSelector\").zIndex = $(\"#ContractDialog\").zIndex + 1;\n $(\"#ContractNumber\").focus();\n },\n buttons: {\n \"Cancel\": function () {\n $(this).dialog(\"close\");\n },\n \"Save Contract\": function () {\n if (validateContractDialog()) {\n saveContractModal();\n $(this).dialog(\"close\");\n }\n }\n }\n });\n // ContractSelector is showing when modal is open, so I explicitly show and hide it when ContractDialog is opened/closed\n $(\"#ContractDialog\").on('dialogclose', function (event) {\n $(\"#ContractSelector\").show();\n });\n\n // add LineItem dialog to /LineItemGroups/Manage\n $(\"#LineItemDialog\").dialog({\n autoOpen: false,\n width: 1200,\n resizable: false,\n title: 'Financial Information',\n modal: true,\n open: function (event, ui) {\n // put autocorrect controls on top of dialog\n $(\"#CategorySelector\").zIndex = $(\"#LineItemDialog\").zIndex + 1;\n $(\"#OCASelector\").zIndex = $(\"#LineItemDialog\").zIndex + 1;\n $(\"#FundSelector\").zIndex = $(\"#LineItemDialog\").zIndex + 1;\n },\n buttons: {\n \"Cancel\": function () {\n $(this).dialog(\"close\");\n $(\"#ContractSelector\").show();\n },\n \"Save Line\": function () {\n if (validateLineItem()) {\n saveLineItemModal();\n $(this).dialog(\"close\");\n $(\"#ContractSelector\").show();\n }\n }\n }\n }).load(\"/LineItemGroups/NewLineItemPartial\", function () {\n // very important to initForms() to enable date pickers and autocompletes\n initLineItemControls();\n });\n}", "title": "" }, { "docid": "532a693ebc56dd95e39ae9a2a80b68c4", "score": "0.47962472", "text": "getContent(){\n\t\tif(!!this.getDialogManager()){\n\t\t\treturn this.getDialogComponents();\n\t\t}\n\t\treturn (<p style={{display: 'none'}}>set dialogManager prop</p>);\n\t}", "title": "" }, { "docid": "ff3feab31aabb800e20ad91f5c4ecefb", "score": "0.4794113", "text": "function setDependencies(isAppStyles) {\n var controls = [];\n var controlDependencies = ['base'];\n if (isAppStyles) {\n APP_CONTROLS.forEach((controlName) => {\n if (!isFiltered(controlName)) {\n controls.push(controlName);\n }\n });\n if (currentTheme === BOOTSTRAP4 || currentTheme === 'tailwind') {\n ['switch', 'accordion'].forEach((controlName) => {\n if (!isFiltered(controlName)) {\n controls.push(controlName);\n }\n });\n }\n var isCommonTheme = currentTheme.startsWith(MATERIAL) || currentTheme.startsWith(MATERIAL3) || currentTheme.startsWith('fabric') || currentTheme.startsWith('fluent') || currentTheme.startsWith('bootstrap') || currentTheme.startsWith('tailwind');\n if (!isFiltered('radio-button') && isCommonTheme) {\n controls.push('radio-button');\n }\n }\n else {\n controls = getFilteredControls();\n }\n var controlsInfo = getControlsInfo(controls, window.dependentCollection['styles'], window.dependentCollection['resources']);\n controlDependencies = dependencyList(controlDependencies, controlsInfo);\n if (!isAppStyles) {\n window.dependencies = controlDependencies;\n }\n return controlDependencies;\n}", "title": "" }, { "docid": "59c46b234103fda6c01afe7e52107e20", "score": "0.47905344", "text": "_attachDialogContainer(overlay, config) {\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const injector = _angular_core__WEBPACK_IMPORTED_MODULE_2__[\"Injector\"].create({\n parent: userInjector || this._injector,\n providers: [{ provide: MatDialogConfig, useValue: config }]\n });\n const containerPortal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__[\"ComponentPortal\"](this._dialogContainerType, config.viewContainerRef, injector, config.componentFactoryResolver);\n const containerRef = overlay.attach(containerPortal);\n return containerRef.instance;\n }", "title": "" }, { "docid": "59c46b234103fda6c01afe7e52107e20", "score": "0.47905344", "text": "_attachDialogContainer(overlay, config) {\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const injector = _angular_core__WEBPACK_IMPORTED_MODULE_2__[\"Injector\"].create({\n parent: userInjector || this._injector,\n providers: [{ provide: MatDialogConfig, useValue: config }]\n });\n const containerPortal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__[\"ComponentPortal\"](this._dialogContainerType, config.viewContainerRef, injector, config.componentFactoryResolver);\n const containerRef = overlay.attach(containerPortal);\n return containerRef.instance;\n }", "title": "" }, { "docid": "59c46b234103fda6c01afe7e52107e20", "score": "0.47905344", "text": "_attachDialogContainer(overlay, config) {\n const userInjector = config && config.viewContainerRef && config.viewContainerRef.injector;\n const injector = _angular_core__WEBPACK_IMPORTED_MODULE_2__[\"Injector\"].create({\n parent: userInjector || this._injector,\n providers: [{ provide: MatDialogConfig, useValue: config }]\n });\n const containerPortal = new _angular_cdk_portal__WEBPACK_IMPORTED_MODULE_1__[\"ComponentPortal\"](this._dialogContainerType, config.viewContainerRef, injector, config.componentFactoryResolver);\n const containerRef = overlay.attach(containerPortal);\n return containerRef.instance;\n }", "title": "" }, { "docid": "aef0211dcdf6804e767f0c35dd196c6a", "score": "0.47690716", "text": "function watchDialogsToControlScroll(riot) {\n var openedDialogsCount = 0;\n var bodyEl = document.getElementsByTagName('BODY')[0];\n\n riot.app.on('dialog:opened', function() {\n openedDialogsCount++;\n bodyEl.classList.add('app-dialog-opened');\n });\n\n riot.app.on('dialog:closed', function() {\n openedDialogsCount--;\n if (openedDialogsCount === 0) {\n bodyEl.classList.remove('app-dialog-opened');\n }\n });\n }", "title": "" }, { "docid": "708130ce7a77960b565af7baca0a9f11", "score": "0.47674042", "text": "function getProjectDependencies(id) {\n return $.getJSON(\"/api/project/\" + id + \"/dependencies/\").done(function (data) {\n logger.logSuccess(\"Retrieve Project Dependencies\", data, MODULE_NAME, true);\n }).fail(function (jqxhr, status, ex) {\n logger.logError(\"Error retrieving Project Dependencies\", jqxhr, MODULE_NAME, true);\n });\n }", "title": "" }, { "docid": "380c90e6a786ad1505e095d7bae7258b", "score": "0.47323737", "text": "function TDialogControl_Add( objDialog ) {\n\t\tif ( !objDialog ) { return }\n\t\tvar i = this.objects.length;\n\t\tthis.objects.length = i + 1;\n\t\tthis.objects[ i ] = objDialog;\n\t\tobjDialog.parent = this;\n\t}", "title": "" }, { "docid": "4cb83d72c60a7f3af8dc86e545417cc9", "score": "0.4702535", "text": "_initDialog() { \n if (this.type !== 'modal') {\n return;\n }\n const el = this.renderRoot.querySelector('.mdc-dialog');\n this._mdcDialogInstance = new MDCDialog(el);\n this._mdcDialogInstance.scrimClickAction = this.noCancelOnOutsideClick ? '' : 'close';\n this._mdcDialogInstance.escapeKeyAction = this.noCancelOnEscKey ? '' : 'close';\n }", "title": "" }, { "docid": "a6e72477c56655e9d5c08f62ce86eafc", "score": "0.4683245", "text": "function setUpDialogs() {\n var dialogOpts = {\n width: \"auto\",\n autoOpen: false,\n modal: true,\n resizable: false\n };\n\n $(\"[id^='wdk-dialog-']\").dialog(dialogOpts);\n\n // connect dialogs\n $(\"body\").on(\"click\", \"[class*='open-dialog-']\", function(e) {\n e.preventDefault();\n var match = this.className.match(/\\bopen-dialog-(\\w+-\\w+)\\b/);\n if (match) {\n $(\"#wdk-dialog-\" + match[1]).dialog(\"open\");\n }\n }).on(\"click\", \"[class*='close-dialog-']\", function(e) {\n e.preventDefault();\n var match = this.className.match(/\\bclose-dialog-(\\w+-\\w+)\\b/);\n if (match) {\n $(\"#wdk-dialog-\" + match[1]).dialog(\"close\");\n }\n });\n }", "title": "" }, { "docid": "e94f0c584cf07139d758d8cb1c291a2a", "score": "0.46770403", "text": "function winDependency(opcion) { // Aqui es donde se declara la funcion del boton Adicionar\r\n switch (opcion) {\r\n case 'Dep':\r\n {\r\n if (!winDep)\r\n {\r\n winDep = Ext.create('Ext.window.Window',{// aqui es donde se declara la ventana de Windows\r\n modal: false, // la ventana se convierte en modal, es decir lo que esta por debajo de ellas no se ve, sobresaltando solamente la ventana\r\n closeAction: 'hide', //Acción de ocultar ventana cuando la cerramos \r\n layout: 'fit', //Ayuda a que el formulario que insertaremos quede ajustado a perfeccion de la ventana\r\n title: 'Gestionar Dependencia',\r\n border: true, //Elimina el borde del interior de la ventana\r\n width: '80%',\r\n height: '80%',\r\n minimizable: true, //muestra los botones de minimizar la ventana\r\n maximizable: true, //muestra los botones de maximizar la ventana\r\n x: 100, //especifica la posicion de la ventana\r\n y: 100, //especifica el top de la ventana\r\n buttons: [// asi es como se declaran los botones que van dentro de la ventana Windows\r\n {\r\n icon: perfil.dirImg + 'cancelar.png',\r\n iconCls: 'btn',\r\n text: 'Cancelar',\r\n handler: function() {\r\n winDep.hide();\r\n }\r\n },\r\n {\r\n icon: perfil.dirImg + 'aceptar.png',\r\n iconCls: 'btn',\r\n text: 'Aceptar',\r\n handler: function() {\r\n adicionarLocal();\r\n }\r\n }]\r\n });\r\n }\r\n //formservice.getForm().reset();\r\n winDep.add(panelDependency); // incluye el formulario dentro de la ventana Windows\r\n winDep.doLayout();\r\n winDep.show(); // permite mostrar la ventana\r\n }\r\n break;\r\n }\r\n }", "title": "" }, { "docid": "f69653aaa2ee0ca09263b62f37572504", "score": "0.46744567", "text": "function getStyleDependencies(dependencies, styles, controlsInfo, packageName) {\n var package = '';\n var controlName = '';\n for (var dependency of dependencies) {\n var depSplit = dependency.split('/');\n if (depSplit[0].indexOf('ej2-') !== -1) {\n if (depSplit.length === 2) {\n package = getPackageName(depSplit[0]);\n controlName = depSplit[1];\n controlsInfo = updateControlsInfo(controlName, package, controlsInfo, styles);\n } else if (depSplit.length === 1) {\n package = getPackageName(dependency);\n var controls = styles[package] ? Object.keys(styles[package]) : [];\n for (var control of controls) {\n controlsInfo = updateControlsInfo(control, package, controlsInfo, styles);\n }\n controlsInfo.fullPackages.push(package);\n }\n } else if (dependency.indexOf('../') !== -1) {\n controlName = dependency.replace(/(\\.\\/\\.\\.\\/)|(\\.\\.\\/)/, '');\n controlsInfo = updateControlsInfo(controlName, packageName, controlsInfo, styles);\n }\n }\n return controlsInfo;\n}", "title": "" }, { "docid": "03b1aa36b420292f91c29aa9af2f389e", "score": "0.46707264", "text": "function onGuideDialogLoad(e) {\n var $dialog;\n if (e.target != null && ($(e.target).hasClass(\"guide-dialog\") || $(e.target).hasClass(\"cq-dialog\") || $(e.target).hasClass(\"cq-Dialog\"))) {\n if ($(e.target).hasClass(\"cq-Dialog\")) {\n $dialog = $(e.target).find(\"form.cq-dialog\");\n } else {\n $dialog = $(e.target);\n }\n //Get the current dialog\n var currentDialog = utils.getCurrentDialog($dialog);\n\n if (currentDialog != null) {\n //Register Coral 3 dynamic events\n //Calling framework based function to register dynamic functions\n utils.registerGenericDynamicEvents($dialog, currentDialog.editable.type);\n\n if (currentDialog.editable.type != \"independentDialog\" && currentDialog.editable.type != \"subDialog\") {\n //Function to handle colspan show/hide for resposive layout container\n utils.handleColspan(currentDialog);\n\n //Function to handle dorColspan show/hide for dor column layout of parent panel\n utils.handleDoRColspan(currentDialog);\n\n //Trigger coral-component:attached event for first time load and adjust popover\n utils.performInitialDialogModifications(currentDialog.editable.type);\n }\n }\n }\n }", "title": "" }, { "docid": "97bd443f286c142c6fddad7231f5e7d8", "score": "0.46703845", "text": "function get_deps(egg_name) {\n// Get deps of 1st-level ul, remove after, repeat as long as not filled\n var parents = $('body > ul > li:first-child')\n var paris = ''\n var deps = null\n // Get corresponding ul of li (same name):\n for(var i=0; i<parents.length; i++) {\n paris = parents[i]\n paris_name = $.trim(paris.firstChild.nodeValue)\n\n if(egg_name == paris_name && paris_name != 'Products.CMFPlone') {\n // Get deps:\n deps = $(paris).find('ul')[0]\n // Remove paris:\n $(paris).remove()\n }\n }\n return deps\n}", "title": "" }, { "docid": "5c76256be113315086c8fe242e20190c", "score": "0.46663573", "text": "dispose() {\n if (this.isOpen) {\n this.close(true);\n }\n\n this.element = null;\n this.content = null;\n this.backdrop = null;\n this._closers.length = 0;\n\n pull(Dialog.Instances, this);\n\n // If this is the last dialog (being disposed), remove the body listener.\n if (Dialog.Instances.length === 0) {\n document.body.removeEventListener('click', Dialog._handleTriggerClick);\n }\n }", "title": "" }, { "docid": "de2bd578476412c3c9d9ae66066f405c", "score": "0.4664991", "text": "function wrapDialog(target){\n\t\tvar t = $(target);\n\t\tt.wrapInner('<div class=\"dialog-content\"></div>');\n\t\tvar contentPanel = t.find('>div.dialog-content');\n\t\t\n\t\tcontentPanel.css('padding', t.css('padding'));\n\t\tt.css('padding', 0);\n\t\t\n\t\tcontentPanel.ta3panel({\n\t\t\tborder:false\n\t\t});\n\t\t\n\t\treturn contentPanel;\n\t}", "title": "" }, { "docid": "417fc71fd3386dd294ebe6c205a450a3", "score": "0.46594754", "text": "initDialog() {\n // any dialog has a her own unique id\n this.confDialog_id = 'datamerge-' + Math.floor(Math.random() * 999999);\n this.confDialog = document.createElement('div');\n this.confDialog.setAttribute('id',this.confDialog_id);\n this.confDialog.className = 'datamerge-confDialog';\n this.confDialog.innerHTML = DataMergeModule_template;\n\n document.documentElement.appendChild(this.confDialog);\n\n // if the path changes => reload fields list\n $('#' + this.confDialog_id + ' .datamerge-confDialog-name').change((ev) => {\n let path = $('#' + this.confDialog_id + ' .datamerge-confDialog-name').val();\n this.setFieldsList(path);\n });\n\n // the click on close\n $('#' + this.confDialog_id + ' .datamerge-confDialog-close').click((ev) => {\n this.closeConfDialog();\n });\n\n // the click on ok\n $('#' + this.confDialog_id + ' .datamerge-confDialog-ok').click((ev) => {\n let path = $('#' + this.confDialog_id + ' .datamerge-confDialog-name').val();\n let fields = $('#' + this.confDialog_id + ' .datamerge-confDialog-fields').val();\n if (this.confDialog.blot) {\n this.confDialog.blot.format('path',path);\n this.confDialog.blot.format('fields',fields);\n } else {\n this.quill.insertEmbed(this.confDialog.range.index, 'datamerge', {path: path, fields: fields}, Quill.sources.USER)\n }\n this.closeConfDialog();\n });\n\n // the click outside the dialog\n window.onclick = (event) => {\n if (event.target === this.confDialog) {\n this.closeConfDialog();\n }\n };\n }", "title": "" }, { "docid": "14db8770b96cbe4400574429bab2f2f8", "score": "0.46492466", "text": "function dependentsOf(callback, context) {\n dependencies.push([]);\n callback.call(context);\n return _.unique(dependencies.pop());\n}", "title": "" }, { "docid": "ca003c8c17170115647e2c6554f72c45", "score": "0.46461025", "text": "get children() {\n return DriveItems(this, \"children\");\n }", "title": "" }, { "docid": "ca003c8c17170115647e2c6554f72c45", "score": "0.46461025", "text": "get children() {\n return DriveItems(this, \"children\");\n }", "title": "" }, { "docid": "8ad07cf7f5f1e5fcfd59185ce3568aa6", "score": "0.46431765", "text": "async getDependencies( path ) {\n let pathID = this.getIDForPath( path );\n return this._dependencies[pathID] || [];\n }", "title": "" }, { "docid": "2a9cea33053dba2ffa7fb7550bfb0837", "score": "0.4635387", "text": "bindDialogs () {\n // initialize\n $('.jsFieldDialog').each((index, fieldDialog) => {\n // get id\n const id = $(fieldDialog).attr('id')\n\n // only when set\n if (id !== '') {\n const $dialog = $('#' + id)\n\n $dialog.find('.jsFieldDialogSubmit').on('click', (e) => {\n e.preventDefault()\n\n // save/validate by type\n // @todo must be refactored\n switch (id) {\n case 'textboxDialog':\n this.saveTextbox()\n break\n case 'textareaDialog':\n this.saveTextarea()\n break\n case 'datetimeDialog':\n this.saveDatetime()\n break\n case 'headingDialog':\n this.saveHeading()\n break\n case 'paragraphDialog':\n this.saveParagraph()\n break\n case 'submitDialog':\n this.saveSubmit()\n break\n case 'dropdownDialog':\n this.saveDropdown()\n break\n case 'radiobuttonDialog':\n this.saveRadiobutton()\n break\n case 'mailmotorDialog':\n this.saveMailmotorbutton()\n break\n case 'checkboxDialog':\n this.saveCheckbox()\n break\n }\n })\n\n $dialog.on('shown.bs.modal', (e) => {\n // bind special boxes\n if (id === 'dropdownDialog') {\n const options = {\n splitChar: '|',\n emptyMessage: window.backend.locale.msg('NoValues'),\n errorMessage: StringUtil.ucfirst(window.backend.locale.err('AddTextBeforeSubmitting')),\n addLabel: StringUtil.ucfirst(window.backend.locale.lbl('Add')),\n removeLabel: StringUtil.ucfirst(window.backend.locale.lbl('Delete')),\n showIconOnly: false,\n afterBuild: this.multipleTextboxCallback\n }\n MultiTextBox.multipleTextbox(options, $('input#dropdownValues'))\n } else if (id === 'radiobuttonDialog') {\n const options = {\n splitChar: '|',\n emptyMessage: window.backend.locale.msg('NoValues'),\n addLabel: StringUtil.ucfirst(window.backend.locale.lbl('Add')),\n removeLabel: StringUtil.ucfirst(window.backend.locale.lbl('Delete')),\n errorMessage: StringUtil.ucfirst(window.backend.locale.err('AddTextBeforeSubmitting')),\n showIconOnly: false,\n afterBuild: this.multipleTextboxCallback\n }\n MultiTextBox.multipleTextbox(options, $('input#radiobuttonValues'))\n } else if (id === 'checkboxDialog') {\n const options = {\n splitChar: '|',\n emptyMessage: window.backend.locale.msg('NoValues'),\n addLabel: StringUtil.ucfirst(window.backend.locale.lbl('Add')),\n removeLabel: StringUtil.ucfirst(window.backend.locale.lbl('Delete')),\n errorMessage: StringUtil.ucfirst(window.backend.locale.err('AddTextBeforeSubmitting')),\n showIconOnly: false,\n afterBuild: this.multipleTextboxCallback\n }\n MultiTextBox.multipleTextbox(options, $('input#checkboxValues'))\n } else if (id === 'datetimeDialog') {\n $('#datetimeType').change((event) => {\n if ($(event.currentTarget).val() === 'time') {\n $('#datetimeDialog').find('.jsDefaultValue').hide()\n $('#datetimeValidation').val('time')\n $('.jsValidationErrorMessage').show()\n $('#datetimeErrorMessage').val(window.backend.locale.err('TimeIsInvalid'))\n } else {\n $('#datetimeDialog').find('.jsDefaultValue').show()\n $('.jsValidationErrorMessage').hide()\n $('#datetimeErrorMessage').val('')\n $('#datetimeValidation').val('')\n }\n }).trigger('change')\n\n $('#datetimeValueType').change((event) => {\n if ($(event.currentTarget).val() === 'today') {\n $('#datetimeValueAmount').prop('disabled', true).val('')\n } else {\n $('#datetimeValueAmount').prop('disabled', false)\n }\n }).trigger('change')\n }\n\n // focus on first input element\n if ($(e.currentTarget).find(':input:visible').length > 0) {\n $(e.currentTarget).find(':input:visible')[0].focus()\n }\n\n // toggle error messages\n this.toggleValidationErrors(id)\n })\n\n $dialog.on('hide.bs.modal', (e) => {\n // no items message\n this.toggleNoItems()\n\n // reset\n this.resetDialog(id)\n\n // toggle error messages\n this.toggleValidationErrors(id)\n })\n }\n })\n\n // bind clicks\n $('.jsFieldDialogTrigger').on('click', (e) => {\n // prevent default\n e.preventDefault()\n\n // get id\n const id = $(e.currentTarget).attr('data-field-id')\n\n // bind\n if (id !== '') {\n $('#' + id).show()\n }\n })\n\n $('.jsRecaptchaTrigger').on('click', (e) => {\n e.preventDefault()\n\n this.saveRecaptcha()\n })\n }", "title": "" }, { "docid": "fffd889275316a8034be12f9d959e714", "score": "0.46350217", "text": "function Dialog(props) {\n var children = props.children,\n classes = props.classes,\n className = props.className,\n fullScreen = props.fullScreen,\n ignoreBackdropClick = props.ignoreBackdropClick,\n ignoreEscapeKeyUp = props.ignoreEscapeKeyUp,\n enterTransitionDuration = props.enterTransitionDuration,\n leaveTransitionDuration = props.leaveTransitionDuration,\n maxWidth = props.maxWidth,\n open = props.open,\n onBackdropClick = props.onBackdropClick,\n onEscapeKeyUp = props.onEscapeKeyUp,\n onEnter = props.onEnter,\n onEntering = props.onEntering,\n onEntered = props.onEntered,\n onExit = props.onExit,\n onExiting = props.onExiting,\n onExited = props.onExited,\n onRequestClose = props.onRequestClose,\n transition = props.transition,\n other = (0, _objectWithoutProperties3.default)(props, ['children', 'classes', 'className', 'fullScreen', 'ignoreBackdropClick', 'ignoreEscapeKeyUp', 'enterTransitionDuration', 'leaveTransitionDuration', 'maxWidth', 'open', 'onBackdropClick', 'onEscapeKeyUp', 'onEnter', 'onEntering', 'onEntered', 'onExit', 'onExiting', 'onExited', 'onRequestClose', 'transition']);\n\n\n var createTransitionFn = typeof transition === 'function' ? _react2.default.createElement : _react2.default.cloneElement;\n\n return _react2.default.createElement(\n _Modal2.default,\n (0, _extends3.default)({\n className: (0, _classnames2.default)(classes.root, className),\n backdropTransitionDuration: open ? enterTransitionDuration : leaveTransitionDuration,\n ignoreBackdropClick: ignoreBackdropClick,\n ignoreEscapeKeyUp: ignoreEscapeKeyUp,\n onBackdropClick: onBackdropClick,\n onEscapeKeyUp: onEscapeKeyUp,\n onRequestClose: onRequestClose,\n show: open\n }, other),\n createTransitionFn(\n /* $FlowFixMe - FIXME See Snackbar for similar create vs clone example */\n transition, {\n in: open,\n transitionAppear: true,\n enterTransitionDuration: enterTransitionDuration,\n leaveTransitionDuration: leaveTransitionDuration,\n onEnter: onEnter,\n onEntering: onEntering,\n onEntered: onEntered,\n onExit: onExit,\n onExiting: onExiting,\n onExited: onExited\n }, _react2.default.createElement(\n _Paper2.default,\n {\n elevation: 24,\n className: (0, _classnames2.default)(classes.paper, classes['paperWidth' + (0, _helpers.capitalizeFirstLetter)(maxWidth)], (0, _defineProperty3.default)({}, classes.fullScreen, fullScreen))\n },\n children\n ))\n );\n}", "title": "" }, { "docid": "231f826f37c7412881ba102f78f1344b", "score": "0.4630291", "text": "GetComponentsInChildren() {}", "title": "" }, { "docid": "231f826f37c7412881ba102f78f1344b", "score": "0.4630291", "text": "GetComponentsInChildren() {}", "title": "" }, { "docid": "3ff933659ba475f7fed5cda31a8252c1", "score": "0.46170014", "text": "function findCloseButton(){return element[0].querySelector('.dialog-close, md-dialog-actions button:last-child');}", "title": "" }, { "docid": "9cbc0b23eaeb23d6251de59705639a18", "score": "0.46092427", "text": "GetComponentsInParent() {}", "title": "" }, { "docid": "9cbc0b23eaeb23d6251de59705639a18", "score": "0.46092427", "text": "GetComponentsInParent() {}", "title": "" }, { "docid": "b7db1ccd060fb77e7c9126f788942ec1", "score": "0.46018893", "text": "function fillDialog() {\n var dialog = document.querySelector('dialog');\n\n if (!dialog.showModal) {\n dialogPolyfill.registerDialog(dialog);\n }\n dialog.showModal();\n\n let closeElements = dialog.querySelectorAll('.close');\n\n for (let i = 0; i < closeElements.length; i++) {\n\n closeElements[i].addEventListener('click', function () {\n dialog.close();\n });\n }\n}", "title": "" }, { "docid": "582b6ca0cf0b39cee47b0a2e54d23deb", "score": "0.45973", "text": "function DialogInventoryBuild(C) {\n\n\t// Make sure there's a focused group\n\tDialogInventory = [];\n\tif (C.FocusGroup != null) {\n\n\t\t// First, we add anything that's currently equipped\n\t\tfor(var A = 0; A < C.Appearance.length; A++)\n\t\t\tif (C.Appearance[A].Asset.Group.Name == C.FocusGroup.Name)\n\t\t\t\tDialogInventoryAdd(C.Appearance[A].Asset, true);\n\n\t\t// Second, we add everything from the victim inventory\n\t\tfor(var A = 0; A < C.Inventory.length; A++)\n\t\t\tif ((C.Inventory[A].Asset != null) && (C.Inventory[A].Asset.Group.Name == C.FocusGroup.Name))\n\t\t\t\tDialogInventoryAdd(C.Inventory[A].Asset, false);\n\t\t\t\n\t\t// Third, we add everything from the player inventory if the player isn't the victim\n\t\tif (C.ID != 0)\n\t\t\tfor(var A = 0; A < Player.Inventory.length; A++)\n\t\t\t\tif ((Player.Inventory[A].Asset != null) && (Player.Inventory[A].Asset.Group.Name == C.FocusGroup.Name))\n\t\t\t\t\tDialogInventoryAdd(Player.Inventory[A].Asset, false);\n\n\t}\n\n}", "title": "" }, { "docid": "89dbbe39218b32e089998845eb2d1ef5", "score": "0.4575069", "text": "getDependencies() {\n return this.actions;\n }", "title": "" }, { "docid": "a556a1836078319ce942bdcccb387125", "score": "0.45601568", "text": "getName() {\n return kebabCase(this.constructor.name).replace(/(dialog|-dialog)/g, '');\n }", "title": "" }, { "docid": "51b18f192e733fcc929d297eb064602f", "score": "0.45477867", "text": "async getDependencies() {\n await this.collectDependencies();\n }", "title": "" }, { "docid": "d89fefadc41057163bc59dea9dfb85d7", "score": "0.45328838", "text": "function cambiaDependiente() {\n var dep;\n //var tDep = id(\"tDependiente\"); //OBSOLETO, ahora se usa un campo en Local.\n var nombreDependiente;\n \n for (var t=0;t<Local.max_dep;t++) {\n\t\tdep = id (\"dep_\"+t);\n\t\tif (dep && dep.getAttribute(\"checked\")){\n\t\t\tnombreDependiente = dep.getAttribute(\"label\");\n\t\t\t\n\t\t\t//Etiqueta visual dependiente (dependiento del theme puede estar visible)\n\t\t\t//tDep.setAttribute( \"value\",nombreDependiente);\n\t\t\t\n\t\t\t//Boton visible\n\t\t\tid(\"depLista\").setAttribute(\"label\",nombreDependiente);\n\t\t\t\n\t\t\treturn;\n\t\t} \n }\n}", "title": "" }, { "docid": "d5b67be68759911c8da1049b34d63ff2", "score": "0.45131835", "text": "function resizeDialog() {\n // Timeout to trigger the dialog resize after all the data have been loaded on\n // first run.\n setTimeout(() => {\n // Check if the dialog was opened as a SubDialog.\n if (parent.gSubDialog) {\n parent.gSubDialog._topDialog.resizeVertically();\n } else {\n sizeToContent();\n }\n }, 230);\n}", "title": "" }, { "docid": "4941ce785045dc7089f9f6d7914557f5", "score": "0.45124885", "text": "getChildren() {\n const child = this.oneChild();\n if (child) {\n return child.getChildren();\n }\n const array = [];\n for (let child of this._children.values()) {\n array.push(child);\n }\n return Promise.resolve(array.sort((a, b) => this.compare(a, b)));\n }", "title": "" }, { "docid": "4ae6908893e51495e7db0b1290436d96", "score": "0.4509517", "text": "function dialogConstructor (dialogId) {\n var mySelf = this;\n // Header elements\n var myButtons = createButtons(mySelf);\n var myButtonsBalance = $('<div>').addClass('dialog-buttons-balance').append(' ').get(0);\n var myTitle = $('<div>').addClass('dialog-title').get(0);\n\n var myHeader = $('<div>')\n .addClass('dialog-header')\n .append(myButtons)\n .append(myButtonsBalance)\n .append(myTitle)\n .get(0);\n\n // Contents elements\n var myContents = $('<div>').addClass('dialog-contents').get(0);\n var myBody = $('<div>').addClass('dialog-body').append(myContents).get(0);\n\n // Main frame\n var myInterior = $('<div>').addClass('dialog-interior').append(myHeader).append(myBody).get(0);\n var myDialog = $('<div>').addClass('dialog').attr(\"id\", dialogId).append(myInterior).get(0);\n\n var myDrag = new Drag(myDialog);\n\n var fixHeights = function () {\n var dialogWidth = parseInt(DomLibrary.getStyleProperty(myDialog, \"width\"), 10);\n var interiorWidth = parseInt(DomLibrary.getStyleProperty(myInterior, \"width\"), 10);\n var dialogHeight = parseInt(DomLibrary.getStyleProperty(myDialog, \"height\"), 10);\n var headerHeight = parseInt(DomLibrary.getStyleProperty(myHeader, \"height\"), 10);\n myInterior.style.height = ((dialogHeight - (dialogWidth - interiorWidth)) + \"px\");\n myBody.style.height = ((dialogHeight - (dialogWidth - interiorWidth) - headerHeight) + \"px\");\n };\n\n // Put the dialog on top\n myDialog.style.zIndex = Drag.getZIndex();\n\n // Make available for later\n myDialog.xFixHeights = fixHeights;\n\n // Allow the dialog header for dragging\n myHeader.onmousedown = makeHeaderMousedown(myDrag);\n\n // Attach the borders\n for (i in ourBorders) {\n var adjust = ourBorders[i];\n var className = (\"dialog-border dialog-border-\" + i);\n var border = $('<div>').addClass(className).get(0);\n\n border.onmousedown = function (e) {\n return myDrag.start(this, e, adjust);\n };\n \n myDialog.appendChild(border);\n }\n\n //\n // Public instance functions\n //\n\n // Set the title of the dialog.\n mySelf.setTitle = function (title) {\n myTitle.innerHTML = title;\n };\n\n // Set the contents of the dialog.\n mySelf.setContents = function (contents) {\n var contents = (contents || \"\");\n myContents.innerHTML = \"\";\n if (isString(contents)) {\n myContents.innerHTML = contents;\n } else {\n myContents.appendChild(contents);\n }\n };\n\n // Size the dialog to the contents with an optional width and\n // height.\n mySelf.sizeToContents = function (width, height) {\n myDialog.style.minWidth = \"0px\";\n myDialog.style.minHeight = \"0px\";\n myButtonsBalance.style.width = DomLibrary.getStyleProperty(myButtons, \"width\");\n myButtonsBalance.style.height = DomLibrary.getStyleProperty(myButtons, \"height\");\n\n var dialogWidth = parseInt(DomLibrary.getStyleProperty(myDialog, \"width\"), 10);\n var dialogHeight = parseInt(DomLibrary.getStyleProperty(myDialog, \"height\"), 10);\n var contentsWidth = parseInt(DomLibrary.getStyleProperty(myContents, \"width\"), 10);\n var contentsHeight = parseInt(DomLibrary.getStyleProperty(myContents, \"height\"), 10);\n var titleWidth = parseInt(DomLibrary.getStyleProperty(myTitle, \"width\"), 10);\n var headerHeight = parseInt(DomLibrary.getStyleProperty(myHeader, \"height\"), 10);\n var contentsEdgeHeight = (dialogHeight - (contentsHeight + headerHeight));\n\n // Set the width\n sizeBox(myDialog,\n Math.max(dialogWidth + (myContents.scrollWidth - myContents.clientWidth), (dialogWidth - contentsWidth) + (width || 0), dialogWidth + (myTitle.scrollWidth - myTitle.clientWidth), (dialogWidth - titleWidth) + (parseInt(myButtonsBalance.style.width, 10) * 5)),\n dialogHeight,\n // Minimum width is determined by the contents and the size of the buttons\n Math.max(dialogWidth + (myContents.scrollWidth - myContents.clientWidth), (dialogWidth - titleWidth) + (parseInt(myButtonsBalance.style.width, 10) * 5)));\n\n // Update values\n dialogWidth = parseInt(DomLibrary.getStyleProperty(myDialog, \"width\"), 10);\n contentsHeight = parseInt(DomLibrary.getStyleProperty(myContents, \"height\"), 10);\n headerHeight = parseInt(DomLibrary.getStyleProperty(myHeader, \"height\"), 10);\n\n // Set the height\n sizeBox(myDialog,\n dialogWidth,\n contentsEdgeHeight + headerHeight + (height || (contentsHeight + (myContents.scrollHeight - myContents.clientHeight))),\n 0, // igored\n contentsEdgeHeight + headerHeight + contentsHeight + (myContents.scrollHeight - myContents.clientHeight));\n fixHeights();\n };\n\n // Centers the dialog in the browser window.\n mySelf.center = function () {\n centerBox(myDialog);\n };\n\n // Shows the dialog.\n mySelf.show = function () {\n attachDialog(dialogId, myDialog, mySelf);\n };\n\n // Closes the dialog.\n mySelf.close = function (e) {\n (mySelf.onclose && mySelf.onclose(e));\n removeDialog(dialogId, myDialog);\n };\n return mySelf;\n }", "title": "" }, { "docid": "d5d6c5011ab9111c1ff4c46ebb2ebe02", "score": "0.4485556", "text": "children() {\n if (!this.components) {\n this.components = [];\n this.formioComponent.columns.forEach(col => Array.prototype.push.apply(this.components, col.components));\n }\n return this.components;\n }", "title": "" }, { "docid": "d5d6c5011ab9111c1ff4c46ebb2ebe02", "score": "0.4485556", "text": "children() {\n if (!this.components) {\n this.components = [];\n this.formioComponent.columns.forEach(col => Array.prototype.push.apply(this.components, col.components));\n }\n return this.components;\n }", "title": "" }, { "docid": "83fca9c6dc14b3e72ff56a2d1cb9faed", "score": "0.447674", "text": "function deleteDialog() {\n dlgHide2();\n showDialog5();\n}", "title": "" }, { "docid": "d31b533e89862f402d0c6530556f8cdb", "score": "0.44764075", "text": "function getInputDialog(dialog) {\n try {\n if (dialog.SUBCLASS_OF_ID === 0xa21c9795) { // crc32(b'InputDialogPeer')\n return dialog\n }\n if (dialog.SUBCLASS_OF_ID === 0xc91c90b6) { // crc32(b'InputPeer')\n return new types.InputDialogPeer({ peer: dialog })\n }\n } catch (e) {\n _raiseCastFail(dialog, 'InputDialogPeer')\n }\n\n try {\n return new types.InputDialogPeer(getInputPeer(dialog))\n // eslint-disable-next-line no-empty\n } catch (e) {\n\n }\n _raiseCastFail(dialog, 'InputDialogPeer')\n}", "title": "" }, { "docid": "4e94890db66ccdcf1a69dd373aeccdac", "score": "0.44640356", "text": "function swapDialog(prevDialog, newDialog, effect) {\n newDialog.insertAfter(prevDialog);\n var height = Math.max(prevDialog.outerHeight(),\n newDialog.outerHeight());\n newDialog.parent().css(\"height\", height); // XXX: context-dependent\n newDialog.hide().velocity(effect);\n prevDialog.remove();\n}", "title": "" }, { "docid": "74edbfd6b7d42cb992d0c499361f935a", "score": "0.4463565", "text": "function loadDependencies() {\n [\n ...charts,\n ...chartDependencies,\n ].forEach(_safeLoadDependency);\n\n if (errors.length) {\n domHelpers.showErrors(errors);\n }\n}", "title": "" }, { "docid": "5cc8d0f3fb18911220874772e0979fa0", "score": "0.44604442", "text": "layout() { \n if (this.type !== 'modal') {\n super.layout && super.layout()\n return;\n }\n this._mdcDialogInstance && this._mdcDialogInstance.layout();\n this._manageFullHeight();\n }", "title": "" }, { "docid": "093ef01eb64c4839577440033baa5da6", "score": "0.44552854", "text": "function getAllDeps() {\n return new Promise((resolve, reject) => {\n db.query(\"SELECT id, name FROM departments;\", function (err, results) {\n if (err) {\n console.log(err);\n }\n\n // Map through the array and return the name from each index\n let allDeps = results.map(i => { return i.name })\n resolve(allDeps);\n });\n });\n}", "title": "" }, { "docid": "b5be1db534cba610a5404a70dddb88eb", "score": "0.4448756", "text": "constructor(dialogs, dialogId, defaultOptions) {\n this.dialogs = dialogs;\n this.dialogId = dialogId;\n this.defaultOptions = defaultOptions;\n }", "title": "" }, { "docid": "de56483c5f752199fd659faa50f7598c", "score": "0.44284457", "text": "function hideMenuDialog() {\r\n\t$.each(_openMenuDialog, function(i, val) {\r\n\t\t// hide dialogs\t\r\n\t});\r\n}", "title": "" }, { "docid": "ecf70789680235a2785bcd701096489d", "score": "0.4425907", "text": "add(dialogId, dialogOrSteps) {\n if (this.dialogs.hasOwnProperty(dialogId)) {\n throw new Error(`DialogSet.add(): A dialog with an id of '${dialogId}' already added.`);\n }\n this.dialogs[dialogId] = Array.isArray(dialogOrSteps) ? new waterfall_1.Waterfall(dialogOrSteps) : dialogOrSteps;\n return this;\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.4415128", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44149137", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44149137", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44144493", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44144493", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44144493", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44144493", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44144493", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" }, { "docid": "64af59a5770af7031071503f9c300192", "score": "0.44144493", "text": "get widgets() {\n return this.__widgets.get();\n }", "title": "" } ]
84bce09c3a9cf2fa61b8fc7d718334bf
function to search text
[ { "docid": "1653c9eca66327f6e1f5e4a7f5476f9d", "score": "0.7240413", "text": "search(search_text){\n\t\tfor(let note_id in this.noteList){\n\t\t\tif (this.noteList[note_id].includes(search_text)){\n\t\t\t\tconsole.log('Showing result for search: ' + '['+search_text+']');\n\t\t\t\tconsole.log('Note ID: '+ note_id);\n\t\t\t\tconsole.log(this.noteList[note_id]);\n\t\t\t\tconsole.log('By Author ' + this.author)\n\t\t\t}\n\t\t\treturn 'Not Found'\n\t\t}\n}", "title": "" } ]
[ { "docid": "ed86db1e9a85dbf9fb3f1db65c6ab2e4", "score": "0.88094574", "text": "search (text) {\n\n\n }", "title": "" }, { "docid": "3f7c159084c2f552332d0acfa64fab0f", "score": "0.80140907", "text": "function WordSearch () {}", "title": "" }, { "docid": "deb001b07daaad0dfd5f42fc581b0aaa", "score": "0.7327294", "text": "function StringContainsSearch() {\n}", "title": "" }, { "docid": "53e779e7ae4b695c86b184035f6d0511", "score": "0.70939344", "text": "searchNote(search_text) {\n\t\tfor (var i =0; i < this.notes.length; i+=1 ){\n\t\t\tif (this.notes[i].note_content.includes(search_text) === true) {\n\t\t\t\tconsole.log(\"Showing results for search <\"+ search_text +\">\\n\\n\"+ \"Note ID: \"+i+\" \\n\"+this.notes[i].note_content+\"\\n\\nBy Author \"+this.notes[i].author );\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "2216107738a58f302a88a046b5f750bf", "score": "0.7067746", "text": "static textContains(text) {\n return (finder) =>\n Condition.compose(Condition.present(finder),\n () => Condition.getText(finder).then((elText) =>\n elText.indexOf(text) > -1\n ));\n }", "title": "" }, { "docid": "db0f0c8f95ae6791526f2addd8b9bee0", "score": "0.7059325", "text": "search() { }", "title": "" }, { "docid": "ed46b6b860e6343d17d376881c4a5a50", "score": "0.69670105", "text": "function search() {\n \n }", "title": "" }, { "docid": "1740d01300bbd1f104aed2678cca786b", "score": "0.6945779", "text": "findWordSearched(){\n}", "title": "" }, { "docid": "8cd63bd633645833a9e27e5636ec9fb9", "score": "0.69239306", "text": "function Search(wordtxt) {\n if (wordtxt) {\n //$(\"#source\").select(function(){\n\n //word=document.selection.createRange().text;\n if (!(typeof wordtxt == 'string'))\n wordtxt = document.getSelection().toString();\n\n //word= document.execCommand('Copy');\n word = wordtxt.toLocaleLowerCase().trim();\n if (word && word.length <= 30) {\n //追加单词解释\n BuildMeans(word);\n // 追加单词联想(词组短语等)\n BuildSuggst(word);\n //保存历史\n BuildHistory(word);\n }\n }\n}", "title": "" }, { "docid": "bf101210daa08c7972aab2bf1c34b19a", "score": "0.69190747", "text": "function wordSearchChecker(txt) {\n var userKeyWord = document.getElementById('userKeyWord').value;\n var wordSearch = '';\n var array = txt.match(new RegExp(userKeyWord, 'gi'));\n\n if (array == null) {\n //var userResult = userKeyWord + \" does not appear in this text.\";\n wordSearch = userKeyWord + \" does not appear in this file.\";\n\n } else if (array.length == 1) {\n wordSearch = userKeyWord + \" appears \" + array.length + \" time.\";\n wordSearch += \"<br/>\";\n wordSearch += \"<br/>\";\n //var userResult = userText.replace(new RegExp(userKeyWord, 'gi'), \"<strong class='word-highlight'>\" + userKeyWord + \"</strong>\");\n wordSearch += txt.replace(new RegExp(userKeyWord, 'gi'), \"<strong class='word-highlight'>\" + userKeyWord + \"</strong>\");\n } else {\n wordSearch = userKeyWord + \" appears \" + array.length + \" times.\";\n wordSearch += \"<br/>\";\n wordSearch += \"<br/>\";\n wordSearch += txt.replace(new RegExp(userKeyWord, 'gi'), \"<strong class='word-highlight'>\" + userKeyWord + \"</strong>\");\n }\n\n return wordSearch;\n }", "title": "" }, { "docid": "3df4c2e31460b82d0fa3fd23dd62c413", "score": "0.69142973", "text": "function searchForString() {\n $(\"#search_string\").click(function () {\n // input string\n var inputString = $(\"#gsearch\").val();\n // input string regex\n var inputReg = new RegExp(inputString, \"ig\");\n var text = $(\"#transcriptionViewer\").html();\n var count;\n if (inputString == \"\") {\n if ($(\"#en-butt\").hasClass(\"active\")) {\n alert(\"Try to search for any word or sentence inserting it in the search bar\");\n return;\n } else {\n alert(\"Prova a cercare una parola o una frase nel testo inserendola nella barra di ricerca\");\n return;\n }\n }\n if (inputString == inputString.toUpperCase()) {\n inputString = inputString.toLowerCase();\n }\n // substitution of the input string in the text\n text = text.replace(inputReg, \"<span class='noActiveQuery'>\" + '<span class=\"upper\">' + inputString + \"</span></span>\");\n // set class p_+n for scrolling to next/prev occurrence\n setTimeout(function() {\n i = 1;\n $(\".noActiveQuery\").each(function() {\n // if the result corresponds to a person\n if ($(\".tooltiptext:contains('\" + inputString + \"')\")) {\n var temp = $(this).parent().parent();\n $(temp).addClass(\"p_\" + i);\n } else {\n // if the result does not correspond to a person\n $(this).addClass(\"p_\" + i);\n }\n i++;\n // /\n })\n }, 500)\n // /\n // show number of results\n $(\"#query-info\").show();\n if (text.indexOf(inputString) == -1) {\n if ($(\"#en-butt\").hasClass(\"active\")) {\n $(\"#query-info\").hide();\n alert(\"There are 0 results, try to search for something else :)\");\n } else {\n $(\"#query-info\").hide();\n alert(\"Ci sono 0 risultati, prova a cercare un'altra parola o frase :)\");\n }\n $(\"#reset_button\").click();\n } else {\n $(\"#prev-string\").removeClass(\"search-prev-next\").addClass(\"search-prev-next-active\");\n $(\"#next-string\").removeClass(\"search-prev-next\").addClass(\"search-prev-next-active\");\n $(\"#query-info\").show();\n }\n count = (text.match(new RegExp(inputString, \"g\")) || []).length;\n $(\"#query-results-n\").text(count);\n $(\"#query-string\").text('\"' + inputString + '\"');\n $(\"#transcriptionViewer\").html(text);\n })\n // press 13 key\n $(\"#gsearch\").keypress(function(e) {\n var key = e.which;\n if (key === 13) {\n $(\"#search_string\").click();\n e.preventDefault();\n }\n })\n}", "title": "" }, { "docid": "144ce06f8a10c6c276ef6b28653c707c", "score": "0.6851137", "text": "function p() {\nvar str = \"Lets find where 'where' begins\";\nvar pos = str.search(\"where\");\ndocument.getElementById(\"search_method\").innerHTML = pos;\n}", "title": "" }, { "docid": "397d6bbc5c2c69eb6cdde37fa2f47fdb", "score": "0.67877024", "text": "performSearch(text) {\n let anyMatches = false;\n const searchTokens = text.toLowerCase().trim().split(' ');\n\n this.elements.forEach((el) => (anyMatches = el.performSearch(searchTokens) || anyMatches));\n\n if (anyMatches) {\n this.noMatches.hide();\n } else {\n this.noMatches.show();\n }\n }", "title": "" }, { "docid": "fe82fea612ea93d7114195ac156266a7", "score": "0.67843205", "text": "onTextSearch(text) {\n debug('onTextSearch');\n _textSearch = text;\n ProductsActions.search(_textSearch, _sortBy, _tags, _tab);\n ProductsActions.resetCache();\n ProductsActions.setCache(_tab);\n }", "title": "" }, { "docid": "c94eeaa025fe136452d9442584d9964a", "score": "0.678324", "text": "function RegExSearch() {\n}", "title": "" }, { "docid": "7061c516e061809b24e4c8bc9cbed920", "score": "0.6770789", "text": "function searchingFor(sText) {\n return function(x){\n return x.nombre.toLowerCase().includes(sText.toLowerCase()) ||\n x.text.toLowerCase().includes(sText.toLowerCase()) || false\n }\n}", "title": "" }, { "docid": "b6527114d6f436ac8dd2e352c456a76c", "score": "0.67181826", "text": "searchTextForActivity(text, activity){\n const regex = new RegExp(\"\\\\b\"+activity+\"\\\\b\");\n let result = text.search(regex) !== -1;\n if (result){\n this.log(`Found [${activity}] in \"${text}\"`);\n }\n return result;\n }", "title": "" }, { "docid": "32a7c060073f05fd7e73ea9434bc8be1", "score": "0.67047215", "text": "function smartSearch(searchText, findTextList) {\n for (var i = 0; i < findTextList.length; i++) {\n var findText = findTextList[i];\n //findText = \" \" + findText + \" \";\n searchText = \" \" + searchText.toLowerCase() + \" \";\n if (searchText.search(findText) != -1) {\n if (!(searchText.charAt((searchText.search(findText) - 1)).match(/[a-z]/)) && !(searchText.charAt((searchText.search(findText) + findText.length)).match(/[a-z]/))){\n return true;\n }\n\n }\n }\n return false;\n}", "title": "" }, { "docid": "6e8f23a972d66e296f5f239de9db6c2b", "score": "0.6703482", "text": "function strContains(pSearchText,pCompleteText,pCaseSensitve){\n\t/*var igonrecase=\"\";\n\tif(pCaseSensitve == false){\n\t\tigonrecase='i';\n\t}\n\t try { \n\t\tif(pCompleteText.search(new RegExp(pSearchText,igonrecase))>0){\n\t\t\t//alert(\"inside if::\"+pSearchText+\"::-::\"+pCompleteText);\n\t\t\treturn true;\n\t\t}else{\n\t\t\t//alert(\"inside else if::\"+pSearchText+\"::-::\"+pCompleteText);\n\t\t}\n\t }catch(e) { \n\t\t\t//alert(e); \n\t\t}*/ \n\t\n\tif(pCaseSensitve == false){\n\t\tif(pCompleteText.toUpperCase().indexOf(pSearchText.toUpperCase())!=-1){\n\t\t\treturn true;\n\t\t}\n\t}else{\n\t\tif(pCompleteText.indexOf(pSearchText)!=-1){\n\t\t\treturn true;\n\t\t}\n\t}\n\t\n\treturn false;\n}", "title": "" }, { "docid": "3acb74832d8f16a3958b25ead7de4dc2", "score": "0.6691655", "text": "function search(input) {\n\n let searchlist = $('.note-li');\n\n for (let findText of searchlist) {\n let foundText = $(findText).find('h2').text();\n let foundDate = $(findText).find('h3').text();\n let foundContent = $(findText).find('p').text();\n\n if (foundText.toLowerCase().includes(input.toLowerCase()) || foundDate.includes(input.toLowerCase()) || foundContent.toLowerCase().includes(input.toLowerCase())) {\n $(findText).show();\n } else {\n $(findText).hide();\n }\n }\n}", "title": "" }, { "docid": "57935a7a950e29c5caed1ec549ff8eda", "score": "0.6617134", "text": "function searchWord(c) {\n regexp = /^Bagaimana cara memulai usaha bisnis$|^Bootcamp Impact Byte$|^Status covid hari ini$/;\n if(regexp.test(c)) {\n alert(\"kata yang anda cari berhasil ditemukan\");\n } else {\n alert(\"maaf kata yang anda cari tidak dapat ditemukan\");\n }\n}", "title": "" }, { "docid": "4b7df8e6302def284da84280b2ddc58d", "score": "0.66027987", "text": "function isMatch( itemText, query ){\n if (query.length >= 0) {\n return itemText.indexOf(query) >= 0;\n }\n return false\n \n }", "title": "" }, { "docid": "f59a2b90527a97b8cfe532a89abb5981", "score": "0.6591523", "text": "function searchInSentence(searchTerm) {\n return sentence.indexOf(searchTerm); \n}", "title": "" }, { "docid": "f4b0748bf7c9e3bff3df80f6755f4249", "score": "0.6581037", "text": "static search(text) {\n if ((!text) || (text.length() < 1)) { return []; }\n\n let results = [];\n\n for (let o of Object.values(this.cache)) {\n for (let f of this.fields) {\n switch (f.type) {\n case 'number':\n if (Number(text) === o[f.name]) {\n results.push(o);\n }\n break;\n case 'stringarray':\n for (let s of o[f.name]) {\n if (s.toUpperCase().indexOf(text.toUpperCase()) >= 0) {\n results.push(o);\n break;\n }\n }\n break;\n case 'string':\n if (o[f.name].toUpperCase().indexOf(text.toUpperCase()) >= 0) {\n results.push(o);\n }\n break;\n default:\n break;\n }\n }\n }\n return results;\n }", "title": "" }, { "docid": "9e407ff858a693f6e2f7aa981e0c22e6", "score": "0.65131205", "text": "function doSearchChar() { doSearch('characterdesc'); }", "title": "" }, { "docid": "a572df5a79983d487e2f0ab69f99f3b4", "score": "0.65099716", "text": "function FIND() {\n \n if (arguments.length == 0) // Non parameter\n {\n alert(\" Please Enter parameter Into The Function \");\n return \"=FIND()\";\n } else\n if (arguments.length > 3 || arguments.length == 1) // 1 or more then 3 parameters\n {\n alert(\"Please You Must Pass Three parameter To This Function\");\n return \"=FIND()\";\n }\n \n var find_text = arguments[0] , within_text = arguments[1];\n \n if (arguments.length == 2) var start_index = 0;\n else var start_index = arguments[2] - 1;\n \n if ((start_index < 0) || (find_text.length > within_text.length) || (start_index > within_text.length))\n \n return \"#Value!\";\n \n else {\n var pos = within_text.indexOf(find_text, start_index);\n \n if (pos == -1)\n return \"#Value!\";\n else\n return pos + 1;\n }\n }", "title": "" }, { "docid": "ffe1cb1c5af89e8e43120c7fe93c5f74", "score": "0.6494868", "text": "function _searchData(text) { \n setRows(data.filter(row => Object.values(row).join(' ').toLowerCase().includes(text.toString().toLowerCase()))); //-> Join values to before filter\n setSearch(text);\n setPage(0);\n }", "title": "" }, { "docid": "b17f6da616a30f6df14134e38faf8a4c", "score": "0.64918727", "text": "function textSearch()\n {\n $.mobile.changePage($('#findMaps'), { transition: \"flip\", changeHash: true });\n search = 6;\n initializeMap(search);\n searchString = document.getElementById(\"searchinput3\").value;\n console.log('I searched for anything');\n }", "title": "" }, { "docid": "deae09fc86732554cb643dff731ae7a7", "score": "0.64057195", "text": "function searchAll(word) {\n var wordCount = 0;\n escapeSpecialCases(word);\n var regExWord = new RegExp(word, 'g');\n\n var stringOfText = searchText.textContent;\n var matches = stringOfText.match(regExWord);\n\n if (matches) {\n wordCount = matches.length;\n }\n return wordCount;\n}", "title": "" }, { "docid": "8f89d106c120013cc87b6c361089276b", "score": "0.6397283", "text": "search(value) {\n // YOUR WORK HERE\n }", "title": "" }, { "docid": "46998eed58b861a07e2d602da6117e3c", "score": "0.6391463", "text": "function findit(what)\n{\n\tshow_indicator();\n\twhat = what.toLowerCase();\n\tfinds = new Array();\n\tif(HelpText.length == 0)\n\t{\n\t\talert('No results');\n\t}\n\telse\n\t{\n\t\tfound = 0;\n\t\tfor(var i=0; i<HelpText.length; i++)\n\t\t{\n\t\t\tTopicText[i].style.display = 'none';\n\t\t\tfinds = what.split(\" \");\n\t\t\twasfound = true;\n\t\t\tfor(var j=0; j<finds.length;j++)\n\t\t\t{\n\t\t\t\tif(SearchText[i].indexOf(finds[j]) < 1 && finds[j] != \"\")\n\t\t\t\t{\n\t\t\t\t\twasfound = false;\n\t\t\t\t}\n\t\t\t}\n\t\t\tif(wasfound)\n\t\t\t{\n\t\t\t\tHelpText[i].style.display = 'block';\n\t\t\t\tfinds[found] = i;\n\t\t\t\tfound++;\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\t//Effect.Fade(HelpText[i]);\n\t\t\t\tHelpText[i].style.display = 'none';\n\n\t\t\t}\n\t\t}\n\t\tif(found < 4)\n\t\t{\n\t\t\tfor(var i=0; i<TopicText.length; i++)\n\t\t\t{\n\t\t\t\t//Effect.SlideDown(TopicText[i]);\n\t\t\t\tTopicText[i].style.display = 'block';\n\t\t\t\t$('PM_toggle_' + TopicText[i].id.replace(/PM_help_topic_/, '')).style.background = 'url(/mason/admin/images/app/bullet_toggle_minus.png) top left no-repeat';\n\t\t\t}\n\t\t}\n\t\telse\n\t\t{\n\t\t\tfor(var i=0; i<TopicText.length; i++)\n\t\t\t{\n\t\t\t\t//Effect.SlideDown(TopicText[i]);\n\t\t\t\t$('PM_toggle_' + TopicText[i].id.replace(/PM_help_topic_/, '')).style.background = 'url(/mason/admin/images/app/bullet_toggle_plus.png) top left no-repeat';\n\t\t\t}\n\t\t}\n\t\t$('PM_no_search_results').style.display = found == 0 ? 'block' : 'none';\n\t\thide_indicator();\n\t}\n}", "title": "" }, { "docid": "0d2d31a7668f587ebcc959fdcdcd55d1", "score": "0.636744", "text": "function checkSearchBoxText(SearchText){\n SearchText = (SearchText!=\"Enter Application Names, Keywords...\")?SearchText:'*';\n return SearchText;\n}", "title": "" }, { "docid": "daa32a9c12180e0b524d649dee89e9e7", "score": "0.6348261", "text": "function textSearch(cssSelector) {\n /*Starting function to get search query*/\n var searchQuery = getSearchQuery();\n /*Selecting all HTML elements that contain strings which we need to\n * compare with search query*/\n var studentName = document.querySelectorAll(cssSelector); /*cssSelector*/\n /*Start cycling through all selected HTML elements*/\n for (var i = 0; i < studentName.length; i++) {\n /*Getting text from every HTML element that contains text we need*/\n var currentName = studentName[i].innerHTML;\n /*Transforming HTML element's text*/\n currentName = currentName.toUpperCase().split(\" \");\n /*Start cycling through search query, it can be more than one word*/\n for (var j = 0; (j < searchQuery.length) && searchQuery[j]; j++) {\n /*Start cycling through HTML element's text, it can be more than one word*/\n for (var k = 0; k < currentName.length && currentName[k]; k++) {\n /*Comparing part of search query and part of HTML element's text*/\n var sub = currentName[k].indexOf(searchQuery[j]);\n if (sub !== -1) {\n /*If there is mach then we add class .search-result to selected predecessor*/\n var nodeFound = studentName[i].parentNode.parentNode;\n nodeFound.classList.add(\"search-result\");\n }\n }\n }\n }\n}", "title": "" }, { "docid": "2f7c031c31cdebd887611efdeef3e8f4", "score": "0.6344242", "text": "function searchForListings(searchTerm) {\n\n}", "title": "" }, { "docid": "0a2bc9dd33e7043b0be5aadf3f6604b2", "score": "0.63117963", "text": "function Search() {\n if (ActiveSection === \"#HomeDiv\")\n return;\n var text = $(`${ActiveSection} input[name=\"tableSearch\"]`).val().toString().toLowerCase();\n var txtValue = \"\";\n var find = false;\n for (var i = 0; i < $(`${ActiveSection} .tableBody tr`).length; i++) {\n txtValue = $(`${ActiveSection} .tableBody tr`)[i].textContent.toLowerCase();\n if (txtValue.indexOf(text) > -1) {\n $(`${ActiveSection} .tableBody tr`)[i].style.display = \"\";\n }\n else {\n $(`${ActiveSection} .tableBody tr`)[i].style.display = \"none\";\n }\n }\n}", "title": "" }, { "docid": "c82fb7987557802cce8aa4b79f1cdc1d", "score": "0.6298138", "text": "function searchPoiBasedText(){\r\r\n\t\r\r\n if(validateSearchText())\r\r\n {\r\r\n\t \t\r\r\n\t showSlider = true; // diset true untuk mencegah wipesliderout efek\r\r\n\t showFullIndonesiaMap(); // kembali ke full map indonesia\r\r\n\t \r\r\n\t // bersihkan pilihan di checkbox, area select dan list destinasi\r\r\n\t uncheckAllCategoryCheckbox();\r\r\n\t cleanPickPlaceInformation();\r\r\n\t cleanListDestination();\r\r\n\t \r\r\n\t // get poi dengan ajax\r\r\n\t getPoi();\r\r\n }\r\r\n}", "title": "" }, { "docid": "6883c2874dea54bf716223bfa76924a6", "score": "0.62657326", "text": "function search_word(searchval) {\n //dbg(\"search_word: \" + searchval);\n var a = \"\";\n if (searchval.charAt(0)==\"-\") {\n a=\"-\";\n searchval=searchval.substr(1);\n }\n //dbg(\"search_word: negation=\" + a);\n search_word_using_mode(match_wholewords, a, searchval);\n search_word_using_mode(match_subwords, a, searchval);\n result_stacks[match_subwords][0] = NOT_results(result_stacks[match_subwords][0], result_stacks[match_wholewords][0]);\n}", "title": "" }, { "docid": "7cb17af582df221a83250146cea708d6", "score": "0.62390167", "text": "function grabWord() {\n var word = document.getElementById('search_input').value;\n if (word.length > 0) {\n var number = searchAll(word);\n phrase.innerHTML = 'Found ' + number + ' occurances of the word \"' + word + '\" in the below text.' \n } else {\n phrase.innerHTML = 'Please enter in a word.';\n }\n}", "title": "" }, { "docid": "e34cf44c17cad753b0c3ce3756a15d74", "score": "0.6234415", "text": "function search(text) {\n results = [];\n text = fixText(text);\n for (let i = 0; i < text.length; i++) {\n for (let j = text[i].length; j > 0; j--) {\n text[i] = text[i].slice(0, j);\n const resultsA = profiles.filter(value => {\n const name = fixText(value.name);\n return (name.find((value, index) => {return name[index].indexOf(text[i]) !== -1}));\n });\n const resultsB = profiles.filter(value => {\n const user = fixText(value.user);\n return (user.find((value, index) => {return user[index].indexOf(text[i]) !== -1}));\n });\n results = results.concat(resultsA,resultsB);\n };\n };\n results = results.filter((value, index) => {\n return results.indexOf(value, 0) === index;\n });\n console.log(results);\n return results;\n}", "title": "" }, { "docid": "a5e6e89b1fe88c0dfd0ae8420e468d78", "score": "0.6197115", "text": "function userType(text) {\n if ( text ) {\n return new Promise(async (resolve, reject) => {\n await Grammer.find().then(arr => {\n const ans = arr.filter(obj => {\n if ( obj.word.toUpperCase().search(text.toUpperCase()) > -1 ) {\n return obj;\n }\n });\n\n if ( ans.length === 0 ) {\n reject({ status: false, message: \"Nothing Found\" });\n } else {\n resolve({ status: true, statusCode: 200, array: ans });\n }\n }).catch(err => console.log('Failed to Getting Data'));\n });\n } else throw new Error(\"Function expects an a parameter\");\n}", "title": "" }, { "docid": "19edd8b3ab83dc66568ca2ef496eda25", "score": "0.619376", "text": "searchFor(text) {\n this.fillIn(text).focus();\n }", "title": "" }, { "docid": "b1f432bc43594496f0f70940c82cbf39", "score": "0.6193251", "text": "doSearch(text) {\n if ( text ) {\n var args = {};\n if (this.form.animated.isChecked) {\n args.animated = true;\n }\n if (this.form.rigged.isChecked) {\n args.rigged = true;\n }\n this.search(text, args);\n }\n this.clearForm();\n }", "title": "" }, { "docid": "74169f635c00503e0d2c8e9cea72ef68", "score": "0.6192521", "text": "function SubStrSearchCmd() {\n}", "title": "" }, { "docid": "12b605ad407532bce8ac49ff28cb99f3", "score": "0.61737585", "text": "function searchConcordance() {\n let searchWord = wordSearch.value().toLowerCase();\n for (let i = 0; i < wordSpans.length; i++) {\n if ((searchWord.length === 0 && i > maxWords) || !wordSpans[i].html().startsWith(searchWord)) {\n wordSpans[i].style('display', 'none');\n } else {\n wordSpans[i].style('display', 'inline');\n }\n }\n}", "title": "" }, { "docid": "7d868b931cb4ebf5d77479f310b56094", "score": "0.6171521", "text": "function searchInSentence(searchTerm) {\n return sentence.includes(searchTerm);\n}", "title": "" }, { "docid": "323a21590f962ff9167b0428b8f7284c", "score": "0.61692494", "text": "function search(){\n\n\tvar searchWord = searchBox.value.toLowerCase();\n\tconsole.log(searchWord);\n\tvar primaryHash = hash.getPrimaryHash(searchWord);\n\n\ttry{\n\t\tif(hash.secondaryKeys[primaryHash] == null){\n\t\t\tthrow 'Word Not Found';\n\t\t}\n\n\t\tvar a = hash.secondaryKeys[primaryHash][0];\n\t\tvar b = hash.secondaryKeys[primaryHash][1];\n\t\tvar m = hash.secondaryKeys[primaryHash][2];\n\n\t\tvar secondaryHash = hash.getSecondaryHash(a,b,m,searchWord);\n\n\t\tif(hash.hashTable[primaryHash][secondaryHash]!=null && dictionary.words[hash.hashTable[primaryHash][secondaryHash]].en == searchWord){\n\t\t\tinput.innerHTML = searchWord;\n\t\t\tresult.innerHTML = dictionary.words[hash.hashTable[primaryHash][secondaryHash]].bn;\n\t\t}\n\t\telse{\n\t\t\tthrow 'Word Not Found';\n\t\t}\n\t}catch(err){\n\t\tinput.innerHTML = searchWord;\n\t\tresult.innerHTML = \"Sorry, word not found :(\";\n\t}\t\n\t\n}", "title": "" }, { "docid": "1b2a6c30c03a00e0459ba0bfe5e57e18", "score": "0.61574686", "text": "function findLine (fileName, wordSearch) {\r\n\tfs.readFile(fileName, function(err, data) {\r\n\t\tif (err) {\r\n\t\t\tconsole.log(\"unable to read file\");\r\n\t\t} else {\r\n\t\t\tdata = data.toString().split(\"\\n\");\r\n\t\t\tfor (var str of data) {\r\n\t\t\t\tif (str.includes(wordSearch)) {\r\n\t\t\t\t\tconsole.log(str);\r\n\t\t\t\t}\r\n\t\t\t}\r\n\t\t}\r\n\t});\r\n}", "title": "" }, { "docid": "c08167ae3d943b11f7f6c73fa3c958dd", "score": "0.61438394", "text": "function searchNames(txt) {\r\n const names = document.getElementsByTagName('h3'); // all the names\r\n text = txt.target.value; // input of text from the event listener\r\n text = text.toUpperCase();\r\n console.log(`text = ${text}`); // check value of captured tesxt in var stuff: works.\r\n for ( let i=0; i<names.length; i++ ) { // loops through all h3s first to last\r\n let name = names[i].textContent;\r\n nameCap = name.toUpperCase();\r\n if (nameCap.includes(text)){ // \r\n names[i].parentNode.parentNode.style.display = 'block'; // display yay\r\n } else { \r\n names[i].parentNode.parentNode.style.display = 'none'; // display nay\r\n }\r\n }\r\n }", "title": "" }, { "docid": "1078a709c914c2ac5c563510fe718146", "score": "0.6139682", "text": "getTextFromSearchField(callback, text) {\n http.get(`${this.apiUrl}?q=${text}&apiKey=${this.apiKey}`, callback);\n }", "title": "" }, { "docid": "8df409919033f37361db8f27f273ffcb", "score": "0.61330336", "text": "function search() {\n // extract all search terms\n getQtermsFromUrlQuery();\n\n /** \n * For each document ID that has some match, contains a bitmap of matched terms and cumulative relevance.\n * @type {Object.<number, {matchBitmap:Array.<number>, relevance:number} >} */\n var candidates = {};\n\n for (let qtermIndex in qterms) {\n /** @type {string} */\n let term = qterms[qtermIndex];\n let onlyWholeWord = false;\n // Read the user setting, whether he wants to always match whole words, even if no quotes around are used.\n // The user can define it in the CSS, e.g. in vsdocman_overrides.css:\n // :root {\n // --searchAlwaysWholeWord: true;\n // }\n onlyWholeWord = getCssCustomProperty(\"--searchAlwaysWholeWord\", \"boolean\");\t\n if (term.length > 2 && term.startsWith(\"\\\"\") && term.endsWith(\"\\\"\")) {\n term = term.substr(1, term.length - 2);\n onlyWholeWord = true;\n }\n\n // index= \"term1\":\"[[docId1, relevance1],.., [docIdN, relevanceN]]\", ..., \"term5\":\"[[docId1, relevance1],.., [docIdN, relevanceN]]\"\"\n\n // whole words\n let termDocs=index[term];\t// serialized string (instead of a direct array) for much faster parsing of search_index.js\n if (termDocs !== undefined) {\n termDocs = JSON.parse(termDocs); // deserialize\n for (let i in termDocs) {\n let docId = termDocs[i][0];\n let relevance = termDocs[i][1];\n if (candidates[docId] === undefined) {\n candidates[docId] = {};\n candidates[docId].matchBitmap = get_bitmap(qtermIndex, qterms.length);\n candidates[docId].relevance = relevance;\n }\n else {\n candidates[docId].matchBitmap[qtermIndex] = 1;\n candidates[docId].relevance += relevance;\n }\n }\n }\n\n // parts of words\n if (!onlyWholeWord) {\n for (let indexedTerm in index) {\n if (indexedTerm.indexOf(term) >= 0) {\n termDocs = index[indexedTerm];\t// serialized string (instead of a direct array) for much faster parsing of search_index.js\n \ttermDocs = JSON.parse(termDocs); // deserialize\n for (let i in termDocs) {\n let docId = termDocs[i][0];\n let relevance = termDocs[i][1];\n if (candidates[docId] === undefined) {\n candidates[docId] = {};\n candidates[docId].matchBitmap = get_bitmap(qtermIndex, qterms.length);\n candidates[docId].relevance = relevance;\n }\n else {\n candidates[docId].matchBitmap[qtermIndex] = 1;\n candidates[docId].relevance += relevance;\n }\n }\n }\n }\n }\n }\n\n let results = [];\n // sort by relevance in descending order\n let sortedDocIds = [];\n for (let key in candidates) sortedDocIds.push(key);\n sortedDocIds.sort(function (a, b) {\n return candidates[b].relevance - candidates[a].relevance;\n });\n for (let i = 0; i < sortedDocIds.length; i++) {\n let docIndex = sortedDocIds[i];\n let on = 1;\n for (let i in qterms) {\n on = on && candidates[docIndex].matchBitmap[i];\n }\n if (on) {\n results.push(docIndex);\n }\n }\n let resultsCount = results.length;\n\n document.getElementById(\"search-results-heading-count\").appendChild(document.createTextNode(resultsCount)); // safe way of setting un-escaped text\n let sPhrase = getQueryParameterByName(\"search\");\n sPhrase = \"\\\"\" + sPhrase + \"\\\"\";\n document.getElementById(\"search-results-heading-phrase\").appendChild(document.createTextNode(sPhrase)); // safe way of setting un-escaped text\n\n var appendPromise = loadAndAppendSearchResultItems(results, 0, paginationSize);\n}", "title": "" }, { "docid": "26ba0b59995ca282f4eef942cc4548b6", "score": "0.6131553", "text": "function search(value) {\n // to do\n}", "title": "" }, { "docid": "95eff970bd0c1d9bd897426b586ec55b", "score": "0.6127687", "text": "function tocSearchExec(text) {\n var re,\n results,\n ul = document.createElement('ul'),\n oldUl,\n txt, pre, t,\n isStart,\n reNS,\n tSt = performance.now(), tS;\n\n text = text.replace(/\\s+/g, '');\n\n pre = text.charAt(0);\n if (pre === t2Info.CSEP || pre === t2Info.ISEP) {\n text = text.slice(1);\n if (pre === '.') pre = '\\\\.';\n } else pre = null;\n\n isStart = /[A-Z]/.test(text.charAt(0));\n\n // create RegEx for search, dependent on whether 1st letter is uppercase\n // escapes ? * + ^ | . $ [ ] ( ) { } in search string\n txt = text.replace(/([\\?*+^|\\.\\$\\[\\]\\(\\)\\{\\}])/g, \"\\\\$1\");\n if (isStart) {\n if (pre)\n re = new RegExp('^' + pre + txt, 'i');\n else\n re = new RegExp('(^' + re_csep + txt + '|^' + re_isep + txt + '|^' + txt + ')', 'i');\n } else {\n if (pre)\n re = new RegExp('^' + pre + '.*?' + txt, 'i');\n else\n re = new RegExp(txt, 'i');\n }\n results = tocSearchInfo.filter( function (o) { return re.test(o.text); } );\n\n if (results.length > 0) {\n // sort objects via name then namespace\n results = results.sort();\n\n ul.className = LIST_ENUM[LIST_METHOD];\n\n // Create RegEx (re) for search string highlight\n txt = txt.replace(/&/g, '&amp;');\n txt = txt.replace(/</g, '&lt;');\n txt = txt.replace(/>/g, '&gt;');\n if (isStart) {\n if (pre)\n re = new RegExp('^(' + pre + txt + ')', 'i');\n else\n re = new RegExp('^([#\\.]?' + txt + ')', 'i');\n } else {\n re = new RegExp('(' + txt + ')', 'ig');\n }\n }\n\n if (dbgSearchLoad) {\n tS = fmtTL(performance.now() - tSt, results.length);\n console.log('Search exec ' + tS + ' ' + text);\n }\n\n oToc.items.style.display = 'none';\n ul.id = 'toc_search_items';\n oldUl = _id('toc_search_items');\n ul.appendChild( tocSearchCreate(results, re) );\n if (oldUl)\n oToc.nav.replaceChild(ul, oldUl);\n else\n oToc.nav.appendChild(ul);\n// listSearchExec2();\n\n// t = null;\n}", "title": "" }, { "docid": "10ba23e28d3192cf66e2857cc1b735c1", "score": "0.6126994", "text": "function occurrenceInText(text, searched) {\n var occurrence = 0,\n index = -1;\n\n searched = searched.toLowerCase();\n text = text.toLowerCase();\n\n // if searched is '' (nothing) the cycle becomes endless so if the length of searched is 0 (falsie) never start the cycle\n while (searched.length) {\n index = text.indexOf(searched, index + 1);\n if (index >= 0) {\n occurrence += 1;\n } else {\n break\n }\n }\n\n return occurrence;\n }", "title": "" }, { "docid": "1a18af1799453b839cde38abf1d9c87a", "score": "0.6126788", "text": "function RegExpSearchCmd() {\n}", "title": "" }, { "docid": "a56edf5f5e0fae4b86c53f35f3493e12", "score": "0.6122498", "text": "searchContacts(text) {\n return this.contacts.filter(contact => {\n for (let property in contact) {\n if (contact[property].toLowerCase().includes(text.toLowerCase())) {\n return contact;\n }\n }\n });\n }", "title": "" }, { "docid": "a70e80056fdb82f6ffdfd7e465a8508d", "score": "0.61218804", "text": "function searchFunction(searchInput, names) {\n for(let i = 0; i < names.length; i++) {\n names[i].parentNode.parentNode.classList.remove(\"match\");\n if(searchInput.value.length !== 0 && names[i].textContent.toLowerCase().includes(searchInput.value.toLowerCase())) {\n names[i].parentNode.parentNode.className += ' match';\n }\n }\n}", "title": "" }, { "docid": "ece3357822c4bd13d1a875c974d0fe4b", "score": "0.61207056", "text": "function highlightSearchTerms(searchText, treatAsPhrase, warnOnFailure,targetObjectID)\n{\n // if the treatAsPhrase parameter is true, then we should search for \n // the entire phrase that was entered; otherwise, we will split the\n // search string so that each word is searched for and highlighted\n // individually\n \n targetObject=document.getElementById(targetObjectID);\n if (!targetObject || typeof(targetObject.innerHTML) == \"undefined\") {\n if (warnOnFailure) {\n alert(\"页面尚未加载完成,请稍候再试.\");\n }\n return false;\n }\n searchText=trim(searchText);\n \n if (treatAsPhrase) {\n searchArray = [searchText];\n } else {\n searchArray = searchText.split(\" \");\n }\n //alert(searchArray.length);\n \n var bodyText = targetObject.innerHTML;\n bodyText=trim(bodyText);\n for (var i = 0; i < searchArray.length; i++) \n {\n \n if(searchArray[i].length==0) continue;\n text=trim(searchArray[i]);\n bodyText = doHighlight(bodyText, searchArray[i], false, false);\n }\n \n targetObject.innerHTML = bodyText;\n return true;\n}", "title": "" }, { "docid": "c48b2ff0d3dc6ca9632081340594756a", "score": "0.6116904", "text": "function search(str, source) {\r\n \r\n if (!source)\r\n {\r\n var source = options.targetElement;\r\n }\r\n\r\n var nodes = getChildrenBySelector(CSS_SLCTS.FOUND_CLS, source);\r\n\r\n clearfound(nodes);\r\n\r\n //walk throw nodes and search string\r\n nodewalk(source[0].childNodes, str);\r\n\r\n //create cursor with founded elements top coordinat\r\n var elsTop = $.map(getChildrenBySelector(CSS_SLCTS.FOUND_CLS, source), elemTop);\r\n findElementsCursor = new FindCursor(elsTop);\r\n\r\n return findElementsCursor.getLastPos() > -1 ? true : false;\r\n }", "title": "" }, { "docid": "e05ad0b419f12651949cdf7960a05d5b", "score": "0.61118066", "text": "function highlightSearchTerms(searchText, treatAsPhrase, warnOnFailure, highlightStartTag, highlightEndTag)\n{\n // if the treatAsPhrase parameter is true, then we should search for \n // the entire phrase that was entered; otherwise, we will split the\n // search string so that each word is searched for and highlighted\n // individually\n if (treatAsPhrase) {\n searchArray = [searchText];\n } else {\n searchArray = searchText.split(\" \");\n }\n\n //Make sure that all toggle panels are expanded\n if (document.getElementById(\"trTogglePanel_Body\") != null) {\n expand_Toggle_Panels();\n }\n \n if (!document.body || typeof(document.body.innerHTML) == \"undefined\") {\n if (warnOnFailure) {\n alert(\"Sorry, for some reason the text of this page is unavailable. Searching will not work.\");\n }\n return false;\n }\n \n var bodyText = document.body.innerHTML;\n for (var i = 0; i < searchArray.length; i++) {\n bodyText = doHighlight(bodyText, searchArray[i], highlightStartTag, highlightEndTag);\n }\n \n document.body.innerHTML = bodyText;\n return true;\n}", "title": "" }, { "docid": "d9716fddae9fc61cd282bb2f5f5aabd9", "score": "0.61106986", "text": "function searchTitle(name, input) {\r\n var matched = 0;\r\n if (name.match(new RegExp(\"\\\\b\" + input + \".*\", \"i\"))) matched = 1;\r\n return matched;\r\n}", "title": "" }, { "docid": "6fb5253f6655c70890c896a2b6e5bf75", "score": "0.6105646", "text": "function doSearch ({ query = null } = {}) {\n\n // Check enable.\n if ($('#searchWord').is('[disabled]')) {\n console.log('Search function is not enabled yet.')\n return\n }\n\n resetUI()\n\n let text\n let isCaseSensitive\n let useRegexp\n if (_searchType === 'text') {\n text = $('#searchWord').val()\n isCaseSensitive = $('.js-search-case-sensitive')[0].checked\n useRegexp = $('.js-search-regexp')[0].checked\n } else {\n text = query\n isCaseSensitive = $('.js-dict-match-case-sensitive')[0].checked\n useRegexp = true\n }\n\n console.log(`doSearch: _searchType=${_searchType} text=\"${text}\", caseSensitive=${isCaseSensitive}, regexp=${useRegexp}`)\n\n // Reset.\n _searchPosition = -1\n\n // The min length of text for searching.\n const MIN_LEN = 2\n if (!text || text.length < MIN_LEN) {\n return\n }\n\n _hitCount = 0\n _pages.forEach(page => {\n\n // Search.\n const _positions = search({ hay : page.body, needle : text, isCaseSensitive, useRegexp })\n _searchResultRenderer(_positions, page, text)\n _hitCount += _positions.length\n })\n\n if (_searchType === 'text') {\n $('.search-hit').removeClass('hidden')\n $('.search-current-position').text(_searchPosition + 1)\n $('.search-hit-count').text(_hitCount)\n } else {\n // Dict matching.\n $('.js-dict-match-cur-pos').text(_searchPosition + 1)\n $('.js-dict-match-hit-counts').text(_hitCount)\n }\n}", "title": "" }, { "docid": "f2359f96bb5317829ec7258dec1877cc", "score": "0.6105002", "text": "search(text, options) {\n if (typeof text === 'undefined') {\n return Promise.reject(new Error('Please provide a text to search.'));\n }\n\n options = options || {};\n options.type = options.type || null;\n\n if(this._cats[options.type]) {\n extend(options, this._cats[options.type]);\n }\n\n return new Promise((resolve, reject) => {\n this.client.search(text, options, (err, result) => {\n if(err) {\n return reject(err);\n }\n\n return resolve(this.parse(result));\n });\n });\n }", "title": "" }, { "docid": "1a38604cbdedbe27fb498a60b42a1549", "score": "0.6097136", "text": "function modifySearch(text){\r\n \r\n return text.trim().split(' ').join('+');\r\n\r\n}", "title": "" }, { "docid": "2f78599f63e20dafec5a2ba5f0d438f1", "score": "0.6085472", "text": "function searchText(){\n var input = document.getElementById(\"keyword\").value;\n var sortMethod = document.getElementById(\"sortMethod\").value;\n\n if(input != \"\" || keyTag.length != 0){\n //切割關鍵字,分別搜尋\n keyTitle = input.match(/\\S+/g) || [];\n\n searchKey(keyTitle, keyTag, sortMethod);\n }\n else{\n window.alert(\"please enter a search value!\");\n return false;\n }\n}", "title": "" }, { "docid": "c17d81de1b96785b255515f06cb954e1", "score": "0.60716957", "text": "static textMatches(regex) {\n return (finder) =>\n Condition.compose(Condition.present(finder),\n () => Condition.getText(finder).then((elText) =>\n R.test(regex, elText)\n ));\n }", "title": "" }, { "docid": "2f4651a5f03c7fc363d7d8475496f5ab", "score": "0.60683936", "text": "function icontains( elem, text ) {\n return (\n elem.textContent ||\n elem.innerText ||\n $( elem ).text() ||\n \"\"\n ).toLowerCase().indexOf( (text || \"\").toLowerCase() ) > -1;\n }", "title": "" }, { "docid": "794c9659103302e5c5e573da456377bd", "score": "0.6067334", "text": "function doSearch(text, reverse, caseSensitive, callback)\n{\n FW.Firebug.chrome.$(\"fbSearchBox\").value = text;\n FBTest.setPref(\"searchCaseSensitive\", caseSensitive);\n\n // Press enter key within the search box.\n FBTest.focus(FW.Firebug.chrome.$(\"fbSearchBox\"));\n FBTest.sendKey(\"RETURN\", \"fbSearchBox\");\n}", "title": "" }, { "docid": "1ff0826fb40c8130a3a35c60b61a2be9", "score": "0.606421", "text": "function doSearch(text) {\n clearTimeout(delayTimer);\n delayTimer = setTimeout(function() {\n getListAppsByName(text);\n }, 100);\n}", "title": "" }, { "docid": "4fb54700be3329b6bda2d0d7d9772081", "score": "0.6061257", "text": "function handle_search(text){\n // block future searches, and setup the search text\n if(is_blocked){return;}\n is_blocked = true;\n $(\"#build, #save\").attr('disabled', true);\n $('#sentence').val(text);\n search = text;\n location.hash = '#'+encodeURIComponent(text);\n\n // setup the laoding text\n $('#output').empty().append(\n $('<div class=\"center-align\">').text('Looking for songs'),\n $('<div class=\"progress\">').append($('<div class=\"indeterminate\">'))\n );\n\n\n get_songs_by_sentence(text, undefined, function(results){\n // save the resulting items\n songs = results['items'];\n $(\"#output\").empty().append(render_into_list(results['items']));\n\n // and unblock\n is_blocked = false;\n $(\"#build, #save\").removeAttr('disabled');\n })\n}", "title": "" }, { "docid": "bac4b58e630ecf8c54d92ee6caa452c7", "score": "0.6060719", "text": "function findByText(css, text, element=false) {\n var els = findAll(css, element);\n for (var i = 0; i < els.length; i++) {\n if (els[i].innerText != \"\" && els[i].innerText.includes(text)) {\n return els[i];\n }\n }\n}", "title": "" }, { "docid": "ba209a5f98997b1f94b281cd21b2509e", "score": "0.6053054", "text": "function searchFunc(searchString){\n \n //searchedWord = document.querySelector(\"#search\").value; \n \n searchedList=[]; \n for(let std= 0; std < data.length; std++){\n \n let fullName =\"\";\n fullName =data[std].name.first;\n fullName += \" \";\n fullName += data[std].name.last;\n\n if (fullName.toLowerCase().includes(searchString.toLowerCase())){ \n searchedList.push(data[std]);\n \n }\n }\n return searchedList;\n}", "title": "" }, { "docid": "b5d58f3d8cdb6e23759b2b6b08495fc9", "score": "0.6049649", "text": "search(str) {\n return this.childSearch.search(str);\n }", "title": "" }, { "docid": "4741be98f0083cbebe3c7af2bf08630b", "score": "0.60458905", "text": "async search(text) {\n try {\n const res = await api.get('/api/course/search', { query: { text } });\n return res.data;\n } catch (err) {\n throw err.response.data;\n }\n }", "title": "" }, { "docid": "192f005bc8a9afd6bf473971427f2570", "score": "0.60391134", "text": "function search(evt) {\n var q = $searchInput.val();\n if (q === searchList.q) return true;\n searchList.q = q;\n words = _.compact(q.split(/\\W/));\n if (!words.length) return searchListHide(evt, false);\n var re = new RegExp(_.map(words, _.escapeRegExp).join('.*'), \"i\");\n var results = _.filter(searchData, function(o) {\n return (o.text.search(re) >= 0 || o.href.search(re) >= 0);\n })\n if (!results.length) return searchListHide(evt, false);\n searchList.$list\n .addClass('show')\n .html(_.map(results, renderSearchItem).join(''));\n\n searchList.length = results.length;\n return true;\n }", "title": "" }, { "docid": "62f51dc3f23a6bfb4e0a076007aa5a81", "score": "0.60377234", "text": "filterSearch(text){\n const newData = this.state.data.filter(function(item){\n const itemData = item.name.toUpperCase();\n const textData = text.toUpperCase();\n return itemData.includes(textData)\n\n });\n this.setState({\n outputData: newData,\n text: text\n })\n }", "title": "" }, { "docid": "5bfeedf9a007565f0f0f2af933d86367", "score": "0.603027", "text": "function search(){\n\t//get text form search textbox\n \tvar text = document.getElementById(\"search\").value;\n \n\t//navigate to map tab\n \tnav_menu(\"map\");\n \n\t//show search result\n \tshow_search_result(text);\n}", "title": "" }, { "docid": "c4bc8e20d55018b5c47bc99adccb5907", "score": "0.6027822", "text": "function icons_modal_text_filter( $search_text ){\n\n var $modal = $( '#better-icon-modal'),\n $options_list = $modal.find('.icons-list');\n\n if( $search_text ){\n $options_list.find(\".label:not(:Contains(\" + $search_text + \"))\").parent().hide();\n $options_list.find(\".label:Contains(\" + $search_text + \")\").parent().show();\n } else {\n $options_list.find(\"li\").show();\n }\n\n }", "title": "" }, { "docid": "047c06126d8f207ceeebd1063b658189", "score": "0.60227895", "text": "function doSearch(text, reverse, caseSensitive, responseBody, callback)\n{\n FW.Firebug.chrome.$(\"fbSearchBox\").value = text;\n FBTest.setPref(\"searchCaseSensitive\", caseSensitive);\n FBTest.setPref(\"netSearchResponseBody\", responseBody);\n\n // Press enter key within the search box.\n FBTest.focus(FW.Firebug.chrome.$(\"fbSearchBox\"));\n FBTest.sendKey(\"RETURN\", \"fbSearchBox\");\n}", "title": "" }, { "docid": "d357c8d42536c28aeb4658d1b598bdb0", "score": "0.6016945", "text": "function search() {\n var list = document.getElementsByClassName('searchstring');\n var item = document.getElementsByClassName('item');\n var input = document.getElementById('searchbox');\n var filter = input.value.toUpperCase(); \n var string;\n\n for (i = 0; i < item.length; i++) {\n\n string = list[i].innerHTML;\n\n if (\n string.toUpperCase().indexOf(filter) > -1\n )\n {\n item[i].style.display = \"block\";\n } else {\n item[i].style.display = \"none\";\n }\n }\n }", "title": "" }, { "docid": "89dde486ea6ded13f9fe9507e85d26b6", "score": "0.60140485", "text": "function setHighlight(searchResult){\r\n\r\n strings = searchResult.split(\" \");\r\n\r\n jQuery(\".regularWord\").each(function(){\r\n\r\n textWord = jQuery(this).text()\r\n\r\n for(i = 0; i < strings.length; i++){\r\n\r\n //alert(\"searchWord: \" + strings[i]);\r\n\r\n if(contains(textWord.toLowerCase(), strings[i].toLowerCase())){\r\n\r\n //alert(\"adding highlight for word: \" + jQuery(this).text() )\r\n jQuery(this).addClass(\"highlight\");\r\n }\r\n\r\n }\r\n\r\n })\r\n\r\n}", "title": "" }, { "docid": "6d0aa29f45a038c47306a1e6ad8b79fe", "score": "0.6012452", "text": "function search($query) {\n\t\n\t// get target corpus\n\tvar corpusName = _para['corpus'];\n\tvar anchorName = _para['aligntype'];\n\tvar mode = _para['mode'];\n\tif (corpusName === 'error' || anchorName === 'error' || mode === 'error') {\n\t\talert(\"[Error] 讀取搜尋設定錯誤。\");\n\t\treturn;\n\t}\n\n\t// pick up the block that contain keyword and show\n\tvar searchResults = searchInCorpus(corpusName, anchorName, mode, $query);\n\tdisplaySearchResult(corpusName, searchResults, $query);\n\tdisplaySearchAnalysis(searchResults, mode, $query);\n}", "title": "" }, { "docid": "bbf71a2a1453b95f75c62e3b6358f5d1", "score": "0.60120577", "text": "function searchOnText(books, searchText) {\n let searchedBooks = [];\n searchText = searchText.toLowerCase();\n for (let b of books) {\n if (b.title.toLowerCase().indexOf(searchText) != -1) {\n searchedBooks.push(b);\n continue;\n }\n if (b.author.toLowerCase().indexOf(searchText) != -1) {\n searchedBooks.push(b);\n continue;\n }\n if (b.details.toLowerCase().indexOf(searchText) != -1) {\n searchedBooks.push(b);\n continue;\n }\n }\n console.log(\"searchedBooks \" + searchedBooks);\n return searchedBooks;\n}", "title": "" }, { "docid": "2208992451022b196b176a45686fb9fe", "score": "0.600858", "text": "function findKeyword(text) {\n\ttext = text.replace(\"[?!\\\\.]\",\"\");\n\t\n\tfor(var key in dialogueTable) {\n\t\tif(text.indexOf(key) > -1) {\n\t\t\treturn key;}}\n\t\n\treturn null;\n}", "title": "" }, { "docid": "ee770ed959e582560db8700486510cfa", "score": "0.60020876", "text": "function textSearchArrayElements(array) {\n \tlet searchIndex = -1;\n \tfor (var l = 0; l < array.length; l++) {\n \t\tlet currentEval = array[l].toString();\n \t\tif (currentEval.includes('lace')) {\n \t\t\tsearchIndex = l;\n \t\t\tbreak;\n \t\t};\n \t};\n \treturn searchIndex;\n }", "title": "" }, { "docid": "9e764efb3f01a52a53ed3a16e439483f", "score": "0.59952325", "text": "function findAll() {\n // $(\"#status\").text(\"\"); $(\"#status\").removeClass();\n // ----- build search regex -----\n var reg;\n var mod;\n if(rX) {\n \t// build mod\n \tmod=\"\";\n \tif($(\"#global-toggle\").is(\":checked\")) mod+=\"g\";\n \tif($(\"#case-toggle\").is(\":checked\")) mod+=\"i\";\n \tif($(\"#multiline-toggle\").is(\":checked\")) mod+=\"m\";\n \t\n \t// check inputted regex\n \ttry {\n \t\tnew RegExp(curWord);\n \t} catch(e) {\n \t\t// console.log(\"Invalid Regular Expression\");\n UHLAll();\n \t\t$(\"#status\").text(\"Error\");\n $(\"#status\").addClass(\"error\");\n \t\treturn;\n \t}\n\n \tif(empty(curWord, mod)) {\n \t\t// console.log(\"Empty Regular Expression\");\n UHLAll();\n \t\t$(\"#status\").text(\"Infinite\");\n $(\"#status\").addClass(\"error\");\n \t\treturn;\n \t}\n \treg = quotes(escapeRegExp(curWord));\n }\n else {\n \tmod=\"g\";\n if(wW) {\n reg = \"\\\\\\\\b\" + quotes(spaces(escapeLit(curWord))) + \"\\\\\\\\b\";\n }\n else {\n reg = quotes(spaces(escapeLit(curWord)));\n }\n if(!mC) mod+=\"i\";\n }\n // console.log(\"findAll(\"+reg+\", \"+mod+\")\");\n // ----- find and focus -----\n chrome.tabs.executeScript({code: 'fAll(\"'+ reg+ '\", \"' + mod + '\");'});\n}", "title": "" }, { "docid": "aeba4fa9d34801ea7c9099291f649b88", "score": "0.5994944", "text": "function getTermSearch(term)\n\t{\n\t\tif(typeof term !== 'undefined')\n\t\t{\n\t\t\tvar chaines = term.split(' '),\n\t\t\t\ttaille = chaines.length,\n\t\t\t\tresponse = [];\n\t\t\tfor(var i=0; i < taille; ++i)\n\t\t\t{\n\t\t\t\tif(chaines[i].length > 2)\n\t\t\t\t\tresponse.push(chaines[i]);\n\t\t\t}\n\t\t\tret = '';\n\t\t\tif(taille > 1)\n\t\t\t\tret = '(' + term + ')|';\n\n\t\t\treturn ret + '(' + response.join(')|(') + ')';\n\n\t\t}\n\n\t\treturn texte;\n\n\t}", "title": "" }, { "docid": "daf50ec63578bb7657a2087622305e6a", "score": "0.59943444", "text": "function searchBlog() {\n var searchText = document.getElementById(\"searchtext\").value;\n for (var i = 0; i < blog.length; i++) {\n // See if the blog entry contains the search text\n if (blog[i].containsText(searchText)) {\n alert(blog[i]);\n break;\n }\n }\n\n // If the search text wasn't found, display a message\n if (i == blog.length)\n alert(\"Sorry, there are no blog entries containing the search text.\");\n }", "title": "" }, { "docid": "a3e4c429fcd08f84ff7d90009f3c52a8", "score": "0.5985458", "text": "function search(keyword){\n\n //Mark or unmark an element\n function mark(log, bool){\n\n //Mark the given element\n if (bool){\n\n //If the log is already marked, no reason to mark again\n if (log.marked){\n return;\n }\n log.marked = true;\n log.element.style.background = '#d93b34';\n log.element.style.border = '2px solid black';\n log.originalColor = log.element.style.color;\n log.element.style.color = 'white';\n log.originalWeight = log.element.style.fontWeight;\n log.element.style.fontWeight = 'bold';\n }\n\n //Unmark the element\n else{\n log.marked = false;\n log.element.style.background = 'none';\n log.element.style.border = 'none';\n log.element.style.color = log.originalColor;\n log.element.style.fontWeight = log.originalWeight;\n\n }\n }\n\n let count = 0;\n for (let i = 0; i < logs.length; i++){\n\n let log = logs[i];\n\n //Check for empty string\n if (keyword != \"\"){\n\n //Case-sensitive search\n if (caseSensitive){\n\n //Look for exact-match\n if (log.data.includes(keyword)){\n mark(log, true);\n count++;\n continue;\n }\n }\n\n //Not case-sensitive\n else{\n //Transform to upper-case in order to compare the two strings\n let upperCaseData = log.data.toUpperCase();\n let upperCaseKeyword = keyword.toUpperCase();\n\n //If there is a match\n if (upperCaseData.includes(upperCaseKeyword)){\n mark(log, true);\n count++;\n continue;\n }\n }\n }\n\n //Unmark the element\n mark(log, false);\n };\n\n return count;\n}", "title": "" }, { "docid": "b5ca5f7f1255b6dc23fcb4a5cbd0c7be", "score": "0.59766513", "text": "function searchWord(word, text) {\n if (arguments.length < 2) {\n return 0\n }\n regex = new RegExp('\\\\b'+word+'\\\\b', 'ig')\n matches = text.match(regex)\n return matches === null ? 0 : matches.length;\n\n}", "title": "" }, { "docid": "e2b44209c4a5cf5d3d4f7183323808d3", "score": "0.59615", "text": "function _getElemByText(oTree, sSearch){\n return oTree.filter(function () {return $(this).text() === sSearch})\n}", "title": "" }, { "docid": "7a1ad021e5124fb3a809167424b88d9d", "score": "0.59536403", "text": "function filterTextFunc(recipe) {\n if (recipe.name.toLowerCase().indexOf(filterText.toLowerCase()) !== -1) {\n return true;\n } else {\n let containsFilterText = false;\n recipe.ingredients.forEach(ingredient => {\n if (ingredient.name.toLowerCase().indexOf(filterText.toLowerCase()) !== -1) {\n containsFilterText = true;\n return;\n }\n });\n recipe.sources.forEach(source => {\n if (source.toLowerCase().indexOf(filterText.toLowerCase()) !== -1) {\n containsFilterText = true;\n return;\n }\n });\n return containsFilterText;\n }\n }", "title": "" }, { "docid": "71623f1ff89a68a2ac44a046de1d458e", "score": "0.59514254", "text": "function highlightSearchTerms(searchText, treatAsPhrase, warnOnFailure, highlightStartTag, highlightEndTag)\r\n{\r\n // if the treatAsPhrase parameter is true, then we should search for \r\n // the entire phrase that was entered; otherwise, we will split the\r\n // search string so that each word is searched for and highlighted\r\n // individually\r\n\r\n if (treatAsPhrase) {\r\n searchArray = [searchText];\r\n } else {\r\n searchArray = searchText.split(\" \");\r\n }\r\n \r\n if (!document.body || typeof(document.body.innerHTML) == \"undefined\" || typeof(document.getElementById('page_section_body').innerHTML) == \"undefined\") {\r\n if (warnOnFailure) {\r\n alert(\"Sorry, for some reason the text of this page is unavailable. Highlighting will not work.\");\r\n }\r\n return false;\r\n }\r\n\r\n var bodyText = document.getElementById('page_section_body').innerHTML;\r\n for (var i = 0; i < searchArray.length; i++) {\r\n\t if(searchArray[i]){\r\n\t\t bodyText = doHighlight(bodyText, searchArray[i], highlightStartTag, highlightEndTag);\r\n\t }\r\n }\r\n document.getElementById('page_section_body').innerHTML = bodyText;\r\n return true;\r\n}", "title": "" }, { "docid": "532e7e016caf8658fdc788efea560cc8", "score": "0.5950423", "text": "function highlightSearchTerms()\r\n{\r\n//tableRows(); \r\n var searchText='';\r\n if(location.search != '')\r\n searchText=location.search.substring(1);\r\n else\r\n return;\r\nvar st = decodeURIComponent(searchText);\r\n searchText=st;\r\n// searchText=unescape(searchText);\r\n\r\n //we will split the\r\n // search string so that each word is searched for and highlighted\r\n // individually\r\n searchArray = searchText.split(\" \");\r\n \r\n var bodyText = document.body.innerHTML;\r\n for (var i = 0; i < searchArray.length; i++) {\r\n bodyText = doHighlight(bodyText, searchArray[i]);\r\n }\r\n document.body.innerHTML = bodyText;\r\n\r\n return true;\r\n}", "title": "" }, { "docid": "7e4ba5106c8dde4ad5d5b45fab8fb78d", "score": "0.5941335", "text": "function compareText(critere, text) {\n\treturn (text.indexOf(critere) !== -1);\n}", "title": "" }, { "docid": "9d9d2d6c0b18f286424ad874347919e5", "score": "0.59376705", "text": "function MyApp_HighlightAllOccurencesOfStringForElement(element,keyword) {\nif (element) {\nif (element.nodeType == 3) { // Text node\nwhile (true) {\nvar value = element.nodeValue; // Search for keyword in text node\nvar idx = value.toLowerCase().indexOf(keyword);\n\nif (idx < 0) break; // not found, abort\n\nvar span = document.createElement(\"span\");\nvar text = document.createTextNode(value.substr(idx,keyword.length));\nspan.appendChild(text);\nspan.setAttribute(\"class\",\"MyAppHighlight\");\nspan.style.backgroundColor=\"yellow\";\nspan.style.color=\"black\";\ntext = document.createTextNode(value.substr(idx+keyword.length));\nelement.deleteData(idx, value.length - idx);\nvar next = element.nextSibling;\nelement.parentNode.insertBefore(span, next);\nelement.parentNode.insertBefore(text, next);\nelement = text;\nMyApp_SearchResultCount++;\t// update the counter\n}\n} else if (element.nodeType == 1) { // Element node\nif (element.style.display != \"none\" && element.nodeName.toLowerCase() != 'select') {\nfor (var i=element.childNodes.length-1; i>=0; i--) {\nMyApp_HighlightAllOccurencesOfStringForElement(element.childNodes[i],keyword);\n}\n}\n}\n}\n}", "title": "" }, { "docid": "7706faeea064ce22f31b7825e2f7abba", "score": "0.5936337", "text": "function evalstrings(searchterm,docstring){\n\t//\tconsole.log(\"EVAL: \" + searchterm + \" \" + docstring);\n\n\tsearchterm = searchterm.toLowerCase();\n\tdocstring = docstring.toLowerCase();\n\n\tvar hits = 0;\n\t//console.log(searchterm.length);\n\tfor(j = 0; j < searchterm.length;j++){\n\n\t\t//search within docstring: (ignore order and multiple hits for now)\n\t\tif(docstring.indexOf(searchterm.charAt(j))>-1)\n\t\thits++;\n\n\t}\n\n\t//Assume that if hits is over 70% of the length of search term, this is a match:\n\tvar hitpercent = 70;\n\n\tvar evalhit = (searchterm.length/100)*hitpercent;\n\tif(hits >= evalhit)\n\treturn true;\n\telse\n\t\treturn false;\n\n\t}", "title": "" }, { "docid": "7e46b98fbea482ed1347bfb004a20a2f", "score": "0.59242", "text": "function searchWord(word, text) {\n let regex = new RegExp(word, \"gi\");\n return text.replace(regex, `**${word.toUpperCase()}**`);\n}", "title": "" }, { "docid": "99e9389dd522258ad51cab2823a8156e", "score": "0.5923779", "text": "function searchPattern(query, text) {\n const m = query.length;\n const n = text.length;\n\n // preprocess query to get lps with longest prefix suffix for the pattern\n const lps = computeLSPArray(query);\n\n // set indices for text and query\n // index for text\n let i = 0;\n // index for query\n let j = 0;\n\n while (i < n) {\n if (query[j] === text[i]) {\n i++;\n j++;\n if (j === m) {\n return true;\n }\n } else if (query[j] !== text[i]) {\n if (j === 0) {\n i++;\n } else {\n j = lps[j - 1];\n }\n }\n }\n return false;\n}", "title": "" }, { "docid": "0597fcbcf71fd9ef2b37b124c6cd6802", "score": "0.5919386", "text": "function searchWord(word, text) {\n let regex = new RegExp(word, 'gi');\n return text.replace(regex, `**${word.toUpperCase()}**`);\n}", "title": "" }, { "docid": "5c311b78181baa375261e2f38b037c3b", "score": "0.5908175", "text": "function WordFilter(){\n}", "title": "" } ]
5fdeaa052fcc2374de3aab26b5962728
sol 2 create prefix trie with the small strings
[ { "docid": "8cb0c3e4f9129e6f3a41784f2805696c", "score": "0.0", "text": "function multiStringSearch(bigString, smallStrings) {\n const trie = new Trie()\n for (let string of smallStrings) {\n trie.insert(string)\n }\n const containedStrings = {}\n for (let i = 0; i < bigString.length; i++) {\n findSmallStringsIn(bigString, i, trie, containedStrings)\n }\n return smallStrings.map(string => string in containedStrings)\n } // O(ns + bs) time, O(ns) space", "title": "" } ]
[ { "docid": "16ed578703d1ef9d1a91a90970731dc3", "score": "0.68116313", "text": "helperUsingTrie(str, root, start, cache) {\n if(start > str.length) return [];\n if(cache[start]) return cache[start];\n const ret = [];\n const ps = this.getPrefixes(str, root, start);\n for(let p of ps) {\n if(start + p.length == str.length) {\n ret.push(p);\n } else {\n const remainComb = this.helperUsingTrie(str, root, start + p.length, cache);\n for(let comb of remainComb) {\n ret.push(p + \" \" + comb);\n }\n }\n }\n cache[start] = ret;\n return ret;\n }", "title": "" }, { "docid": "5e35ce895dcd11b0b3207fff6c0e7e85", "score": "0.6349674", "text": "function generateTrie(array){\n trie = new TrieNode();\n for(let i = 0; i < array.length; i++) {\n let word = array[i];\n addWord(word);\n }\n}", "title": "" }, { "docid": "a709d629dcc3a5635f08fecfac23bad2", "score": "0.6325183", "text": "function Trie() {\n\t}", "title": "" }, { "docid": "8ce4937fc0a841a8d874702771c4c6c1", "score": "0.63241464", "text": "function Trie(){\n\tthis.word = null;\n\tthis.children = {};\n}", "title": "" }, { "docid": "2d1c3493d5ba03089dfab96d33e6ecd1", "score": "0.63238406", "text": "function wordTrie (p) {\n if (typeof p === 'string') {\n this.addPhrase(p);\n } else if ( Object.prototype.toString.call(p) === '[object Array]' ) {\n this.addPhraseByArray(p, 0);\n }\n}", "title": "" }, { "docid": "399611f5dc9eb15c2aa93c047c3f5f75", "score": "0.631548", "text": "function Trie() {\n this.words = 0;\n this.prefixes = 0;\n this.children = [];\n }", "title": "" }, { "docid": "6770aa3b6644e0b7b43ce1e45d53ea59", "score": "0.6265038", "text": "populateSuffixTrieFrom(string) {\n for (let i = 0; i < string.length; ++i) {\n this.insert(i, string);\n }\n }", "title": "" }, { "docid": "0662b3e5f81bad6cde68a160f6991403", "score": "0.6260897", "text": "function TrieNodeConstructor (wordIn) {\n if (!(this instanceof TrieNodeConstructor)) {\n return new TrieNodeConstructor(word);\n }\n this.word = wordIn || null;\n this.children = [];\n\n for (var i = 0; i < 26; i+=1) {\n this.children[i] = null;\n }\n //console.log(\"adding node\", this.word);\n}", "title": "" }, { "docid": "e590dba2a3aaaba2d4ca0f88181df011", "score": "0.61907446", "text": "function findSmallStringsIn(string, startIdx, trie, containedStrings) {\n let node = trie.root\n for (let i = startIdx; i < string.length; i++) {\n const letter = string[i]\n if (!(letter in node)) break\n node = node[letter]\n if (trie.endSymbol in node) containedStrings[node[trie.endSymbol]] = true\n }\n }", "title": "" }, { "docid": "85f66fb3319792e54f26a40766c79c38", "score": "0.6171242", "text": "populateSuffixTrieFrom(string) {\n for (let i = 0; i < string.length; i++) {\n this.insertSubstringStartingAt(i, string)\n }\n }", "title": "" }, { "docid": "2bd2f667f07f559d1735b550d913369a", "score": "0.60913384", "text": "function Trie() {\n this.wordTree = {};\n this.words = 0;\n}", "title": "" }, { "docid": "b6551aa0e9f84198d5b025956928e0c4", "score": "0.6075949", "text": "function addTrie(word) {\n const splitWord = word.split('');\n\n // Loop to dig through the JSON object\n var tempTrieProgress = trie;\n for (i=0; i<splitWord.length; i++) {\n if (!(splitWord[i] in tempTrieProgress)) {\n tempTrieProgress.addNode(splitWord[i]);\n }\n tempTrieProgress = tempTrieProgress[splitWord[i]];\n }\n\n tempTrieProgress.endOfWord = true;\n\n saveTrie();\n}", "title": "" }, { "docid": "0b9475f4fc9a3c30a6e1af2b6ece14ac", "score": "0.60624367", "text": "find(prefix) {\n let currentNode = this.root;\n let output = [];\n\n // for each letter in prefix\n for(let idx = 0; idx < prefix.length; idx++){\n // decend into trie until weve reached node at prefix end\n let nextLettersIndex = prefix.charCodeAt(idx) - 97;\n // if no node at prefix end\n if (!currentNode.nextLetters[nextLettersIndex]) {\n return output;\n }\n currentNode = currentNode.nextLetters[nextLettersIndex];\n }\n // weve found a node at prefix end\n // find all words that decend from a node\n findWords(currentNode, output);\n }", "title": "" }, { "docid": "24020ce37b163843932022a183e8c0f5", "score": "0.60077393", "text": "function PhoneBookTrie(){\n\tvar t = this;\n\tvar uuid = 1;\n\t\n\tt.contacts = [];\n\tt.trie = new TrieNode();//prefix $ for address, # for number, @ for name\n\t\n\tvar insertTrieNode = function (key, val){\n\t\tvar cur = t.trie;\n\t\t\n\t\tfor (var i = 0; i < key.length; i++){\n\t\t\t//already there, then traverse down\n\t\t\tif (typeof cur.lookup[key[i]] == 'undefined'){\n\t\t\t\tcur.lookup[key[i]] = new TrieNode();\n\t\t\t}\n\t\t\t\n\t\t\tcur = cur.lookup[key[i]];\n\t\t}\n\t\t\n\t\tcur.val.push(uuid);\n\t}\n\t\n\tvar searchTrieNode = function (key){\n\t\tvar cur = t.trie;\n\t\t\n\t\tfor (var i = 0; i < key.length; i++){\n\t\t\tif (typeof cur.lookup[key[i]] == 'undefined'){\n\t\t\t\treturn [];//nothing like this\n\t\t\t}\n\t\t\t\n\t\t\tcur = cur.lookup[key[i]];\n\t\t}\n\t\t\n\t\treturn cur.val;//return matching uuid\t\t\n\t}\n\t\n\tt.add = function (name, phone, address){\n\t\tt.contacts[uuid] = {name : name, phone : phone, address : address};\n\t\t\n\t\t//work on the trie;\n\t\t//name\n\t\tname = '@' + name;\n\t\tinsertTrieNode(name);\n\t\t\n\t\t\n\t\t//phone\n\t\tphone = '#' + phone;\n\t\tinsertTrieNode(phone);\n\t\t\n\t\t//address\n\t\taddress = '$' + address;\n\t\tinsertTrieNode(address);\n\t\t\n\t\t\n\t\tuuid++;\n\t}\n\t\n\tt.search = function(category, searchTerm){\n\t\tswitch(category.toLowerCase()){\n\t\t\tcase 'name':\n\t\t\t\tsearchTerm = '@' + searchTerm;\n\t\t\t\tbreak;\n\t\t\n\t\t\tcase 'phone':\n\t\t\t\tsearchTerm = '#' + searchTerm;\n\t\t\t\tbreak;\n\t\t\n\t\t\tcase 'address':\n\t\t\t\tsearchTerm = '$' + searchTerm;\t\t\t\t\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\t\n\t\tvar matches = searchTrieNode(searchTerm); //uuid\n\t\tvar ret = [];\n\t\tfor (var i = 0; i < matches.length; i++){//lookup for contact from uuid for name\n\t\t\tret.push(t.contacts[matches[i]]);\n\t\t}\n\t\t\n\t\treturn ret;\n\t}\n}", "title": "" }, { "docid": "24020ce37b163843932022a183e8c0f5", "score": "0.60077393", "text": "function PhoneBookTrie(){\n\tvar t = this;\n\tvar uuid = 1;\n\t\n\tt.contacts = [];\n\tt.trie = new TrieNode();//prefix $ for address, # for number, @ for name\n\t\n\tvar insertTrieNode = function (key, val){\n\t\tvar cur = t.trie;\n\t\t\n\t\tfor (var i = 0; i < key.length; i++){\n\t\t\t//already there, then traverse down\n\t\t\tif (typeof cur.lookup[key[i]] == 'undefined'){\n\t\t\t\tcur.lookup[key[i]] = new TrieNode();\n\t\t\t}\n\t\t\t\n\t\t\tcur = cur.lookup[key[i]];\n\t\t}\n\t\t\n\t\tcur.val.push(uuid);\n\t}\n\t\n\tvar searchTrieNode = function (key){\n\t\tvar cur = t.trie;\n\t\t\n\t\tfor (var i = 0; i < key.length; i++){\n\t\t\tif (typeof cur.lookup[key[i]] == 'undefined'){\n\t\t\t\treturn [];//nothing like this\n\t\t\t}\n\t\t\t\n\t\t\tcur = cur.lookup[key[i]];\n\t\t}\n\t\t\n\t\treturn cur.val;//return matching uuid\t\t\n\t}\n\t\n\tt.add = function (name, phone, address){\n\t\tt.contacts[uuid] = {name : name, phone : phone, address : address};\n\t\t\n\t\t//work on the trie;\n\t\t//name\n\t\tname = '@' + name;\n\t\tinsertTrieNode(name);\n\t\t\n\t\t\n\t\t//phone\n\t\tphone = '#' + phone;\n\t\tinsertTrieNode(phone);\n\t\t\n\t\t//address\n\t\taddress = '$' + address;\n\t\tinsertTrieNode(address);\n\t\t\n\t\t\n\t\tuuid++;\n\t}\n\t\n\tt.search = function(category, searchTerm){\n\t\tswitch(category.toLowerCase()){\n\t\t\tcase 'name':\n\t\t\t\tsearchTerm = '@' + searchTerm;\n\t\t\t\tbreak;\n\t\t\n\t\t\tcase 'phone':\n\t\t\t\tsearchTerm = '#' + searchTerm;\n\t\t\t\tbreak;\n\t\t\n\t\t\tcase 'address':\n\t\t\t\tsearchTerm = '$' + searchTerm;\t\t\t\t\n\t\t\t\tbreak;\n\t\t}\n\t\t\n\t\t\n\t\tvar matches = searchTrieNode(searchTerm); //uuid\n\t\tvar ret = [];\n\t\tfor (var i = 0; i < matches.length; i++){//lookup for contact from uuid for name\n\t\t\tret.push(t.contacts[matches[i]]);\n\t\t}\n\t\t\n\t\treturn ret;\n\t}\n}", "title": "" }, { "docid": "0c8d277df2b1edf2c56f0957dd34a0b1", "score": "0.5999556", "text": "traverse (str, callbackfn, thisArg) {\n let cur = this.trie\n for (let i = 0; i < str.length; i++) {\n const retChar = callbackfn.call(thisArg, str[i], i, cur)\n const tmp = cur.children[retChar]\n if (!tmp || tmp.countPrefix <= 0) return\n cur = tmp\n }\n }", "title": "" }, { "docid": "57d128986a548828ef8aba2cb7fd5b56", "score": "0.5982704", "text": "function Trie(caseSensitive) {\n\tthis.dictionary = {};\n\tthis.$ = false;\n\n\tif(typeof caseSensitive === \"undefined\") {\n\t\tcaseSensitive = true;\n\t}\n\n\tthis.cs = caseSensitive;\n}", "title": "" }, { "docid": "44ee7b96e732853989cb979787200402", "score": "0.5978137", "text": "function queryTrie(word) {\n // Loop to dig through the JSON object\n\n var searchResults = searchTrie(word, false, true);\n\n // Checks if the pathing exists in the trie, if not return empty\n var tempTrieProgress = searchResults[1];\n if(!searchResults[0]) {\n return [\"100x\",[]];\n }\n\n // Arrays to store the words constructed and the list building the words\n var wordList = [];\n var wordBuildingList = [];\n\n if (tempTrieProgress.endOfWord) {\n wordList.push(word);\n } else {\n wordBuildingList.push(word);\n }\n\n // Recursive function to construct letters and work backwards to set up to construct the next letter\n function queryList(tempTrie) {\n\n var sideBranches = Object.keys(tempTrie).filter(t=>t!=\"endOfWord\");\n\n sideBranches.forEach(branch=> {\n wordBuildingList.push(branch);\n if (\"endOfWord\" in tempTrie[branch]) {\n wordList.push(wordBuildingList.join(\"\"));\n }\n queryList(tempTrie[branch]);\n wordBuildingList.pop();\n });\n }\n\n queryList(tempTrieProgress);\n return [\"100x\",wordList];\n}", "title": "" }, { "docid": "395ed15b14cc134620667db498b0bd5c", "score": "0.5966189", "text": "function buildTrieFast(words, trieOptions) {\n const root = (0, trie_util_1.createTriFromList)(words, trieOptions);\n return new trie_1.Trie(root, undefined);\n}", "title": "" }, { "docid": "51b868c3c4c20202abaa49bee52df5b1", "score": "0.5942644", "text": "startsWith(string,node){\n node = node || this.root\n //base case \n if(string.length === 0){\n return true;\n }\n\n if(node.keys.get(string[0])){\n return this.startsWith(string.substr(1),node.keys.get(string[0]));\n }\n else{\n return false\n }\n }", "title": "" }, { "docid": "596796e5ecbaf4fc2ee375d6c0548591", "score": "0.5923352", "text": "function Trie() {\n this.rootNode = {};\n}", "title": "" }, { "docid": "aa80983eddb32f08fc27ae13f8e5511a", "score": "0.59071463", "text": "function build() {\n for (var i = 0; i < Object.keys(object).length; i++) {\n var k = Object.keys(object)[i];\n object[k] = {};\n for (var j = 0; j < k.length; j++) {\n var w = k.replaceAt(j, wildcard);\n object[k][w] = new Number();\n for (var l = 0; l < alphabet.length; l++) {\n var nw = w.replaceAt(j, alphabet[l]);\n if (nw != k && trie.find(nw)) {\n pos = (alphabet[l].charCodeAt(0) - 'a'.charCodeAt(0));\n object[k][w] = object[k][w] | (1 << pos);\n }\n }\n }\n }\n}", "title": "" }, { "docid": "567780d7eb5094d451ba2964498fa736", "score": "0.5893914", "text": "insert_to_trie(word){\n if (this.is_word(word) == false) {\n return false;\n }\n let currentNode = this.root;\n\n for (let char=0; char < word.length; char++){\n let char_index = this.char_to_index(word[char]);\n // print(f\"char: {char} | Char Index - {char_index}\")\n if (!currentNode.children[char_index]){ \n // If the character doesn't exist in the Trie; create it\n currentNode.children[char_index] = this.get_node();\n currentNode.children[char_index].ch = word[char];\n currentNode.children[char_index].word = currentNode.word + word[char];\n currentNode.children[char_index].parent = currentNode;\n } \n currentNode = currentNode.children[char_index] ;\n }\n \n currentNode.isLeaf = true; // current node is the last character\n }", "title": "" }, { "docid": "d21b09d07cf9ec1d1865dd6c1aa15e8d", "score": "0.5875996", "text": "function TrieSetConstructor () {\n if (!(this instanceof TrieSetConstructor)) {\n return new TrieSetConstructor(word);\n }\n this.root = new TrieNodeConstructor(\"\");\n this.trieSize = 0;\n this.radixTable = {};\n this.radixLength = 26;\n for (var i = 0; i < this.radixLength; i+=1) {\n var letter = String.fromCharCode(97 + i);\n this.radixTable[letter] = i;\n }\n}", "title": "" }, { "docid": "87f59e6594ae6e7b78940a20fd1f90d9", "score": "0.58658457", "text": "constructor(words) {\n this.words = new SuffixTree(words);\n this.pointers = [];\n }", "title": "" }, { "docid": "32a9b961efb6131ff551dfd9ef535c6f", "score": "0.5761645", "text": "insert(word){\n\t\tword = word.toUpperCase();\n\t\tvar subtrie = this.tree;\n\t\tfor(var j = 0; j < word.length; j++){\n\t\t\tvar letter = word[j];\n\t\t\t// insert letter if not already present\n\t\t\tif(subtrie.hasOwnProperty(letter) === false){ \n\t\t\t\tsubtrie[letter] = {} \n\t\t\t};\n\t\t\t// continue descending into tree\n\t\t\tsubtrie = subtrie[letter];\n\t\t}\n\t\t// finished iterating over word, add star at this depth\n\t\tsubtrie[\"*\"] = true;\n\t}", "title": "" }, { "docid": "c28ea83be98d6425c2c5242c8c1d7a7b", "score": "0.5757998", "text": "function convertToTrie(entries) {\n\t\tvar trie = {}, url, urlFixed, i, value, letters, letter, cur, node;\n\n\t\tfor (url in entries) {\n\t\t\turlFixed = url;\n\n\t\t\t// find any strings to break\n\t\t\tfor (i = 0; i < impl.xssBreakWords.length; i++) {\n\t\t\t\t// Add a xssBreakDelim character after the first letter. optimizeTrie will\n\t\t\t\t// ensure this sequence doesn't get combined.\n\t\t\t\turlFixed = urlFixed.replace(impl.xssBreakWords[i], \"$1\" + xssBreakDelim + \"$2\");\n\t\t\t}\n\n\t\t\tif (!entries.hasOwnProperty(url)) {\n\t\t\t\tcontinue;\n\t\t\t}\n\n\t\t\tvalue = entries[url];\n\t\t\tletters = urlFixed.split(\"\");\n\t\t\tcur = trie;\n\n\t\t\tfor (i = 0; i < letters.length; i++) {\n\t\t\t\tletter = letters[i];\n\t\t\t\tnode = cur[letter];\n\n\t\t\t\tif (typeof node === \"undefined\") {\n\t\t\t\t\t// nothing exists yet, create either a leaf if this is the end of the word,\n\t\t\t\t\t// or a branch if there are letters to go\n\t\t\t\t\tcur = cur[letter] = (i === (letters.length - 1) ? value : {});\n\t\t\t\t}\n\t\t\t\telse if (typeof node === \"string\") {\n\t\t\t\t\t// this is a leaf, but we need to go further, so convert it into a branch\n\t\t\t\t\tcur = cur[letter] = { \"|\": node };\n\t\t\t\t}\n\t\t\t\telse {\n\t\t\t\t\tif (i === (letters.length - 1)) {\n\t\t\t\t\t\t// this is the end of our key, and we've hit an existing node. Add our timings.\n\t\t\t\t\t\tcur[letter][\"|\"] = value;\n\t\t\t\t\t}\n\t\t\t\t\telse {\n\t\t\t\t\t\t// continue onwards\n\t\t\t\t\t\tcur = cur[letter];\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\treturn trie;\n\t}", "title": "" }, { "docid": "847512c99e3d57a4229154ad4e2c4621", "score": "0.5740568", "text": "constructor(prefix) {\n this.prefix = prefix;\n this.counter = 0;\n this.existing = {};\n }", "title": "" }, { "docid": "847512c99e3d57a4229154ad4e2c4621", "score": "0.5740568", "text": "constructor(prefix) {\n this.prefix = prefix;\n this.counter = 0;\n this.existing = {};\n }", "title": "" }, { "docid": "f445396f3b4a375d48db336f3e315114", "score": "0.5670797", "text": "function insert(node, chars, ipa, i) {\n\t\tif (chars.length === i) {\n\t\t\tvar n = new Node(undefined, ipa);\n\t\t\tif (node && node.val) { /* We are dealing with a prefix: adopt */\n\t\t\t\tn.hi = node; /* existing node as hi kid of new node. */\n\t\t\t}\n\t\t\treturn n;\n\t\t}\n\n\t\tif (node === null) {\n\t\t\tnode = new Node(chars[i], undefined);\n\t\t}\n\n\t\t/* The else branch also catches the condition when val is undefined.\n\t\t * This happens when an existing key is a prefix of the new key. New\n\t\t * nodes will be inserted in the hi kid. */\n\t\tif (chars[i] < node.val) {\n\t\t\tnode.lo = insert(node.lo, chars, ipa, i);\n\t\t} else if (chars[i] === node.val) {\n\t\t\tnode.eq = insert(node.eq, chars, ipa, i+1);\n\t\t} else { /* both for hi and val==undefined */\n\t\t\tnode.hi = insert(node.hi, chars, ipa, i);\n\t\t}\n\n\t\treturn node;\n\t}", "title": "" }, { "docid": "287f3341a51aee32ff6c9aca8ce4f793", "score": "0.566313", "text": "function _build_turtle_prefixes(){\n\t\t\tvar turtle_prefixes = \"\";\n\t\t\tfor (var i = 0; i < browser_conf_json.prefixes.length; i++) {\n\t\t\t\tvar pref_elem = browser_conf_json.prefixes[i];\n\t\t\t\tturtle_prefixes = turtle_prefixes+\" \"+\"PREFIX \"+pref_elem[\"prefix\"]+\":<\"+pref_elem[\"iri\"]+\"> \";\n\t\t\t}\n\t\t\treturn turtle_prefixes;\n\t\t}", "title": "" }, { "docid": "5c08a7179e4d56f082234d6e97fb6615", "score": "0.56529486", "text": "addPrefixes(prefixes, done) {\n var prefixIRIs = this._prefixIRIs,\n hasPrefixes = false;\n\n for (var prefix in prefixes) {\n var iri = prefixes[prefix];\n if (typeof iri !== 'string') iri = iri.value;\n hasPrefixes = true; // Finish a possible pending quad\n\n if (this._subject !== null) {\n this._write(this._inDefaultGraph ? '.\\n' : '\\n}\\n');\n\n this._subject = null, this._graph = '';\n } // Store and write the prefix\n\n\n prefixIRIs[iri] = prefix += ':';\n\n this._write('@prefix ' + prefix + ' <' + iri + '>.\\n');\n } // Recreate the prefix matcher\n\n\n if (hasPrefixes) {\n var IRIlist = '',\n prefixList = '';\n\n for (var prefixIRI in prefixIRIs) {\n IRIlist += IRIlist ? '|' + prefixIRI : prefixIRI;\n prefixList += (prefixList ? '|' : '') + prefixIRIs[prefixIRI];\n }\n\n IRIlist = IRIlist.replace(/[\\]\\/\\(\\)\\*\\+\\?\\.\\\\\\$]/g, '\\\\$&');\n this._prefixRegex = new RegExp('^(?:' + prefixList + ')[^\\/]*$|' + '^(' + IRIlist + ')([a-zA-Z][\\\\-_a-zA-Z0-9]*)$');\n } // End a prefix block with a newline\n\n\n this._write(hasPrefixes ? '\\n' : '', done);\n }", "title": "" }, { "docid": "143d9a581ce55f262d9f6e3cafdb5eac", "score": "0.562178", "text": "parsePrefixString() {\n const matches = this.prefixString.trim().match(this._prefixRegex);\n this.short = matches[1];\n this.long = matches[2].replace(/[<>]/g, \"\");\n this.representations.push(matches[1], matches[2]);\n }", "title": "" }, { "docid": "47daee13bcbd8e7916585428af2539a8", "score": "0.559867", "text": "function Trie() {\n \n this.root = {\n children: {},\n values: []\n };\n \n }", "title": "" }, { "docid": "b8dc0b50eac80085c7c2989efe8fb2f0", "score": "0.55984503", "text": "function trie ( data ) {\n const root = {};\n for (key in data) {\n let val = data[key];\n if (val !== null && typeof val === 'object') {\n data[key] = trie(data[key]);\n } else {\n if (root[key.slice(0, 1)]) {\n trie_recurse(root[key.slice(0, 1)], key.slice(1, key.length), val);\n } else {\n const obj = {};\n trie_recurse(obj, key.slice(1, key.length), val);\n root[key.slice(0, 1)] = obj;\n }\n }\n }\n return root;\n}", "title": "" }, { "docid": "deacceb292809a5ab89d873349d2b0de", "score": "0.5574284", "text": "constructor(){\n // length three prefixes\n this.p3 = [\n \"\\u0643\\u0627\\u0644\",\n \"\\u0628\\u0627\\u0644\",\n \"\\u0648\\u0644\\u0644\",\n \"\\u0648\\u0627\\u0644\",\n ]\n\n // length two prefixes\n this.p2 = [\"\\u0627\\u0644\", \"\\u0644\\u0644\"];\n\n // length one prefixes\n this.p1 = [\n \"\\u0644\",\n \"\\u0628\",\n \"\\u0641\",\n \"\\u0633\",\n \"\\u0648\",\n \"\\u064a\",\n \"\\u062a\",\n \"\\u0646\",\n \"\\u0627\",\n ];\n\n // length three suffixes\n this.s3 = [\n \"\\u062a\\u0645\\u0644\",\n \"\\u0647\\u0645\\u0644\",\n \"\\u062a\\u0627\\u0646\",\n \"\\u062a\\u064a\\u0646\",\n \"\\u0643\\u0645\\u0644\",\n ];\n\n // length two suffixes\n this.s2 = [\n \"\\u0648\\u0646\",\n \"\\u0627\\u062a\",\n \"\\u0627\\u0646\",\n \"\\u064a\\u0646\",\n \"\\u062a\\u0646\",\n \"\\u0643\\u0645\",\n \"\\u0647\\u0646\",\n \"\\u0646\\u0627\",\n \"\\u064a\\u0627\",\n \"\\u0647\\u0627\",\n \"\\u062a\\u0645\",\n \"\\u0643\\u0646\",\n \"\\u0646\\u064a\",\n \"\\u0648\\u0627\",\n \"\\u0645\\u0627\",\n \"\\u0647\\u0645\",\n ];\n\n // length one suffixes\n this.s1 = [\"\\u0629\", \"\\u0647\", \"\\u064a\", \"\\u0643\", \"\\u062a\", \"\\u0627\", \"\\u0646\"];\n\n // groups of length four patterns\n this.pr4 = {\n 0: [\"\\u0645\"],\n 1: [\"\\u0627\"],\n 2: [\"\\u0627\", \"\\u0648\", \"\\u064A\"],\n 3: [\"\\u0629\"],\n };\n\n // Groups of length five patterns and length three roots\n this.pr53 = {\n 0: [\"\\u0627\", \"\\u062a\"],\n 1: [\"\\u0627\", \"\\u064a\", \"\\u0648\"],\n 2: [\"\\u0627\", \"\\u062a\", \"\\u0645\"],\n 3: [\"\\u0645\", \"\\u064a\", \"\\u062a\"],\n 4: [\"\\u0645\", \"\\u062a\"],\n 5: [\"\\u0627\", \"\\u0648\"],\n 6: [\"\\u0627\", \"\\u0645\"],\n };\n\n this.re_short_vowels = new RegExp(\"[\\u064B-\\u0652]\");\n this.re_hamza = new RegExp(\"[\\u0621\\u0624\\u0626]\");\n this.re_initial_hamza = new RegExp(\"^[\\u0622\\u0623\\u0625]\");\n\n this.stop_words = [\n \"\\u064a\\u0643\\u0648\\u0646\",\n \"\\u0648\\u0644\\u064a\\u0633\",\n \"\\u0648\\u0643\\u0627\\u0646\",\n \"\\u0643\\u0630\\u0644\\u0643\",\n \"\\u0627\\u0644\\u062a\\u064a\",\n \"\\u0648\\u0628\\u064a\\u0646\",\n \"\\u0639\\u0644\\u064a\\u0647\\u0627\",\n \"\\u0645\\u0633\\u0627\\u0621\",\n \"\\u0627\\u0644\\u0630\\u064a\",\n \"\\u0648\\u0643\\u0627\\u0646\\u062a\",\n \"\\u0648\\u0644\\u0643\\u0646\",\n \"\\u0648\\u0627\\u0644\\u062a\\u064a\",\n \"\\u062a\\u0643\\u0648\\u0646\",\n \"\\u0627\\u0644\\u064a\\u0648\\u0645\",\n \"\\u0627\\u0644\\u0644\\u0630\\u064a\\u0646\",\n \"\\u0639\\u0644\\u064a\\u0647\",\n \"\\u0643\\u0627\\u0646\\u062a\",\n \"\\u0644\\u0630\\u0644\\u0643\",\n \"\\u0623\\u0645\\u0627\\u0645\",\n \"\\u0647\\u0646\\u0627\\u0643\",\n \"\\u0645\\u0646\\u0647\\u0627\",\n \"\\u0645\\u0627\\u0632\\u0627\\u0644\",\n \"\\u0644\\u0627\\u0632\\u0627\\u0644\",\n \"\\u0644\\u0627\\u064a\\u0632\\u0627\\u0644\",\n \"\\u0645\\u0627\\u064a\\u0632\\u0627\\u0644\",\n \"\\u0627\\u0635\\u0628\\u062d\",\n \"\\u0623\\u0635\\u0628\\u062d\",\n \"\\u0623\\u0645\\u0633\\u0649\",\n \"\\u0627\\u0645\\u0633\\u0649\",\n \"\\u0623\\u0636\\u062d\\u0649\",\n \"\\u0627\\u0636\\u062d\\u0649\",\n \"\\u0645\\u0627\\u0628\\u0631\\u062d\",\n \"\\u0645\\u0627\\u0641\\u062a\\u0626\",\n \"\\u0645\\u0627\\u0627\\u0646\\u0641\\u0643\",\n \"\\u0644\\u0627\\u0633\\u064a\\u0645\\u0627\",\n \"\\u0648\\u0644\\u0627\\u064a\\u0632\\u0627\\u0644\",\n \"\\u0627\\u0644\\u062d\\u0627\\u0644\\u064a\",\n \"\\u0627\\u0644\\u064a\\u0647\\u0627\",\n \"\\u0627\\u0644\\u0630\\u064a\\u0646\",\n \"\\u0641\\u0627\\u0646\\u0647\",\n \"\\u0648\\u0627\\u0644\\u0630\\u064a\",\n \"\\u0648\\u0647\\u0630\\u0627\",\n \"\\u0644\\u0647\\u0630\\u0627\",\n \"\\u0641\\u0643\\u0627\\u0646\",\n \"\\u0633\\u062a\\u0643\\u0648\\u0646\",\n \"\\u0627\\u0644\\u064a\\u0647\",\n \"\\u064a\\u0645\\u0643\\u0646\",\n \"\\u0628\\u0647\\u0630\\u0627\",\n \"\\u0627\\u0644\\u0630\\u0649\",\n ];\n }", "title": "" }, { "docid": "1159e9162f7b39ccec1e65dcc0f6c77c", "score": "0.55741477", "text": "function prefixer(prefix){\n\tthis.prefix=prefix;\n}", "title": "" }, { "docid": "644d4223bcd1c6139272e255c4afc20f", "score": "0.5545973", "text": "function queryList(tempTrie) {\n\n var sideBranches = Object.keys(tempTrie).filter(t=>t!=\"endOfWord\");\n\n sideBranches.forEach(branch=> {\n wordBuildingList.push(branch);\n if (\"endOfWord\" in tempTrie[branch]) {\n wordList.push(wordBuildingList.join(\"\"));\n }\n queryList(tempTrie[branch]);\n wordBuildingList.pop();\n });\n }", "title": "" }, { "docid": "bd1dfbef5a51c2ed102ac5b9c88c12e3", "score": "0.55149716", "text": "function trie (arr, itemToTokens) {\n const map = new Map();\n for (const item of arr) {\n const tokens = itemToTokens(item);\n for (const token of tokens) {\n let currentMap = map;\n for (let i = 0; i < token.length; i++) {\n const char = token.charAt(i);\n let nextMap = currentMap.get(char);\n if (!nextMap) {\n nextMap = new Map();\n currentMap.set(char, nextMap);\n }\n currentMap = nextMap;\n }\n let valuesAtCoda = currentMap.get(CODA_MARKER);\n if (!valuesAtCoda) {\n valuesAtCoda = [];\n currentMap.set(CODA_MARKER, valuesAtCoda);\n }\n valuesAtCoda.push(item);\n }\n }\n\n const search = (query, exact) => {\n let currentMap = map;\n for (let i = 0; i < query.length; i++) {\n const char = query.charAt(i);\n const nextMap = currentMap.get(char);\n if (nextMap) {\n currentMap = nextMap;\n } else {\n return []\n }\n }\n\n if (exact) {\n const results = currentMap.get(CODA_MARKER);\n return results || []\n }\n\n const results = [];\n // traverse\n const queue = [currentMap];\n while (queue.length) {\n const currentMap = queue.shift();\n const entriesSortedByKey = [...currentMap.entries()].sort((a, b) => a[0] < b[0] ? -1 : 1);\n for (const [key, value] of entriesSortedByKey) {\n if (key === CODA_MARKER) { // CODA_MARKER always comes first; it's the empty string\n results.push(...value);\n } else {\n queue.push(value);\n }\n }\n }\n return results\n };\n\n return search\n}", "title": "" }, { "docid": "f2bbb573c7ce07ca6f19a5ab4841f446", "score": "0.5504371", "text": "construct_chain(list) {\n let chain = {}\n\n for (let i = 0; i < list.length; i++) {\n let names = list[i].split(/\\s+/)\n\n chain = this.incr_chain(chain, 'parts', names.length)\n\n for (let j = 0; j < names.length; j++) {\n let name = names[j]\n\n chain = this.incr_chain(chain, 'name_len', name.length)\n\n let c = name.substr(0,1)\n\n chain = this.incr_chain(chain,'initial',c)\n\n let string = name.substr(1)\n let last_c = c\n\n while (string.length > 0) {\n let c = string.substr(0,1)\n chain = this.incr_chain(chain,last_c,c)\n\n string = string.substr(1)\n last_c = c\n }\n }\n }\n return this.scale_chain(chain)\n }", "title": "" }, { "docid": "de32b171deac7aa414b74e414fa57442", "score": "0.550191", "text": "function _findNodeForAdd(trie, startNode, path) {\n var result = {\n node: null,\n lastIndex: -1,\n isPartialMatch: false\n };\n\n var strLength = path.length;\n var rootLength = startNode.str ? startNode.str.length : 0;\n\n if (strLength === rootLength && path === startNode.str) {\n result.node = startNode;\n return result;\n }\n\n var i = rootLength;\n var nexti = 0;\n\n var curNode = startNode;\n var lastNode = null;\n var matchStr = null;\n\n while (curNode && i < strLength) {\n lastNode = curNode;\n // attempt to find a node with the same starting character\n curNode = curNode.binarySearch(path.charCodeAt(i));\n\n // if no node starts with the same character, we add to curNode\n if (!curNode) {\n result.node = lastNode;\n result.lastIndex = i;\n break;\n }\n\n matchStr = curNode.str;\n nexti = i + matchStr.length;\n\n // if we get here, we know at least 1 character matches. check if the whole thing matches\n // make sure the remaining path is long enough to match, then verify the match\n if (nexti > strLength || matchStr !== path.substring(i, nexti)) {\n // we don't have an exact match, so curNode needs to be split\n result.node = curNode;\n result.lastIndex = i;\n result.isPartialMatch = true;\n break;\n }\n\n i = nexti;\n\n // if we havent done the whole path...\n if (i < strLength) {\n // and if there are no more children to search...\n if (!curNode.childrenCount) {\n // then add the remainder as a child to curNode\n result.node = curNode;\n result.lastIndex = i;\n break;\n }\n // otherwise, the loop will search the children next\n } else {\n // if we have done the whole path, then we found an exact node\n result.node = curNode;\n break;\n }\n }\n\n return result;\n }", "title": "" }, { "docid": "651d3341302051643ad4f0452c29fd92", "score": "0.5488953", "text": "function SuffixTrie(rules) {\n this.exceptions = Object.create(null);\n this.rules = Object.create(null);\n\n if (rules) {\n for (var i = 0; i < rules.length; i += 1) {\n var rule = rules[i];\n if (rule.exception) {\n insertInTrie(rule, this.exceptions);\n } else {\n insertInTrie(rule, this.rules);\n }\n }\n }\n}", "title": "" }, { "docid": "c049f3c26265a1881ec94370449ab201", "score": "0.54419285", "text": "addNode(letter,eod=false) {\n this[letter] = new trieNode(eod);\n }", "title": "" }, { "docid": "ea367bd6a3e236e9738f54a7c0a68821", "score": "0.54381", "text": "function addWord(word) {\n let current = trie.children\n for(let i = 0; i < word.length; i++) {\n // if the letter is not on our tree\n if(!(word[i] in current)) {\n // lets add the letter with an empty Node\n current[word[i]] = new TrieNode();\n }\n // Count the number of seen\n current[word[i]].count++;\n // Move to the next node\n current = current[word[i]].children;\n }\n // Se the the word as ended.\n current.isWordEnd = true;\n}", "title": "" }, { "docid": "82d486635e01a8842f0cc52ab705b9f2", "score": "0.5396851", "text": "getPrefix(word) {\n validate(word);\n const retValue = getLastLetterNode(this.head, word);\n return !!retValue.value && retValue.word;\n }", "title": "" }, { "docid": "7cdecceefde0f7da68b1758629b1ef85", "score": "0.53904873", "text": "constructor(prefix, existing = new Map(), counter = 0) {\n this.prefix = prefix;\n this._existing = existing;\n this.counter = counter;\n }", "title": "" }, { "docid": "bf5d0f8ae2853a4756ac315096de7272", "score": "0.5381788", "text": "function buildPatternTable(word) {\n const patternTable = [0];\n let prefixIndex = 0;\n let suffixIndex = 1;\n while (suffixIndex < word.length) {\n if (word[prefixIndex] === word[suffixIndex]) {\n patternTable[suffixIndex] = prefixIndex + 1;\n suffixIndex += 1;\n prefixIndex += 1;\n }\n else if (prefixIndex === 0) {\n patternTable[suffixIndex] = 0;\n suffixIndex += 1;\n }\n else {\n prefixIndex = patternTable[prefixIndex - 1];\n }\n }\n return patternTable;\n}", "title": "" }, { "docid": "55abb0b2062e9582533716202a88412d", "score": "0.5380903", "text": "function longestCommonPrefix(words) {\n var prefix = '';\n var letters = {};\n var shortest = Infinity\n for (var k = 0; k < words.length; k++) {\n if (words[k].length < shortest) {\n shortest = words[k].length;\n }\n }\n var j = 0;\n var prefix = '';\n var temp;\n while (j < shortest) {\n var i = 0;\n while (i < words.length) {\n letters[words[i][j]] = words[i][j];\n temp = words[i][j]\n i++;\n }\n if (Object.keys(letters).length === 1) {\n prefix += temp;\n } else {\n return prefix;\n }\n letters = {};\n j++;\n }\n return prefix;\n}", "title": "" }, { "docid": "5f55cd46d973219886c7261b4cb34548", "score": "0.53807724", "text": "randomTrie(num) {\n\t\tif (num > 993) num = 993\n\t\tlet allWords = words['words']\n\t\tlet upper = 0\n\t\tlet lower = num * 2 + 10\n\t\tlet elements = new Set()\n\t\tfor (let i = 0; i < num; i++) {\n\t\t\tlet value =\n\t\t\t\tMath.floor(Math.random() * (upper - lower + 1)) + lower\n\t\t\twhile (elements.has(value) || value > 993) {\n\t\t\t\tvalue =\n\t\t\t\t\tMath.floor(Math.random() * (upper - lower + 1)) + lower\n\t\t\t}\n\t\t\telements.add(value)\n\t\t\tthis.insert(allWords[value])\n\t\t}\n\t}", "title": "" }, { "docid": "ab2389d3433294e7f6ba683eca9d4b42", "score": "0.53773737", "text": "addPrefixes(prefixes, done) {\n // Ignore prefixes if not supported by the serialization\n if (!this._prefixIRIs) return done && done();\n\n // Write all new prefixes\n let hasPrefixes = false;\n for (let prefix in prefixes) {\n let iri = prefixes[prefix];\n if (typeof iri !== 'string') iri = iri.value;\n hasPrefixes = true;\n // Finish a possible pending quad\n if (this._subject !== null) {\n this._write(this._inDefaultGraph ? '.\\n' : '\\n}\\n');\n this._subject = null, this._graph = '';\n }\n // Store and write the prefix\n this._prefixIRIs[iri] = prefix += ':';\n this._write(`@prefix ${prefix} <${iri}>.\\n`);\n }\n // Recreate the prefix matcher\n if (hasPrefixes) {\n let IRIlist = '',\n prefixList = '';\n for (const prefixIRI in this._prefixIRIs) {\n IRIlist += IRIlist ? `|${prefixIRI}` : prefixIRI;\n prefixList += (prefixList ? '|' : '') + this._prefixIRIs[prefixIRI];\n }\n IRIlist = escapeRegex(IRIlist, /[\\]\\/\\(\\)\\*\\+\\?\\.\\\\\\$]/g, '\\\\$&');\n this._prefixRegex = new RegExp(`^(?:${prefixList})[^\\/]*$|` + `^(${IRIlist})([_a-zA-Z][\\\\-_a-zA-Z0-9]*)$`);\n }\n // End a prefix block with a newline\n this._write(hasPrefixes ? '\\n' : '', done);\n }", "title": "" }, { "docid": "add0ae5d41ea9c3725f17a5c9d13b684", "score": "0.53630346", "text": "function indexStringAndPrefixes(str, doc, distance=0) {\n let length = str.length;\n indexString(str, doc, distance);\n const MIN_CHAR_MATCH = 3;\n for (let i = MIN_CHAR_MATCH; i < length; i++) {\n const charDistance = length - i;\n indexString(str.substr(0, i), doc, charDistance * .1 + distance);\n }\n}", "title": "" }, { "docid": "ff30ce6bf3c49bc713a9f81cab03e450", "score": "0.53585327", "text": "function prefixer(match, p1, offset, string) {\n return ('00000000000000000000' + match).substr(-20);\n }", "title": "" }, { "docid": "e55cc367f4e66a852f3a80c994c37d51", "score": "0.53562653", "text": "function prefixer(match, p1, offset, string) {\n\t\t\t\t\treturn ('00000000000000000000'+match).substr(-20);\n\t\t\t\t}", "title": "" }, { "docid": "701dfb293f01ca280cf4c1b01ab2ecce", "score": "0.53527325", "text": "function longestCommonPrefix(words) {\n var prefix = '';\n var letters = {};\n var shortest = Infinity\n for (var k = 0; k < words.length; k++) {\n if (words[k].length < shortest) {\n shortest = words[k].length;\n }\n }\n var j = 0;\n var prefix = '';\n var temp;\n while (j < shortest) {\n var i = 0;\n while (i < words.length) {\n if (i === 0) {\n temp = words[i][j]\n }\n if (words[i][j] !== temp || words[i][j].length === 0) {\n return prefix;\n }\n i++\n }\n prefix += words[i-1][j]\n j++;\n }\n return prefix;\n}", "title": "" }, { "docid": "646612c9c4fa67801aa907385466cb38", "score": "0.5350081", "text": "insert (prefix, item) {\n if (!this.items[prefix]) {\n const index = findIndex(this.prefixes, (e) => {\n if (prefix.length === e.length) {\n return prefix > e\n }\n return prefix.length > e.length\n })\n\n if (index === -1) {\n this.prefixes.push(prefix)\n } else {\n this.prefixes.splice(index, 0, prefix)\n }\n }\n this.items[prefix] = item\n return item\n }", "title": "" }, { "docid": "7d0d263613f88a73d52f6af5d2b0b727", "score": "0.5337908", "text": "function find(prefix) {\n var matches = [];\n\n if (!prefix) {\n return matches;\n }\n\n var current = root;\n\n for (var i = 0; i < prefix.length; i++) {\n var j = _getKeyFromChar(prefix[i]);\n\n if (!current.children[j]) {\n return matches;\n }\n\n current = current.children[j];\n }\n\n var limit = void 0; // How far the lookahead should proceed\n\n if (/^[\\x00-\\x7F]+$/.test(prefix)) {\n // prefix is ASCII only\n limit = options.limitAlpha;\n } else if (/^[\\u3040-\\u30FF]+$/.test(prefix)) {\n // prefix is hiragana/katakana only\n limit = options.limitKana;\n } else {\n // prefix is likely to be kanjis or a mix\n limit = options.limitKanji;\n }\n\n (function lookAhead(str, node) {\n if (node.isLeaf) {\n node.transforms.forEach(function (w) {\n return matches = _merge(matches, [w]);\n });\n }\n\n if (str.length - prefix.length <= limit) {\n for (var k in node.children) {\n lookAhead(str + _getCharFromKey(k), node.children[k]);\n }\n }\n })(prefix, current);\n\n return matches;\n }", "title": "" }, { "docid": "dfcf3e85cf60fb427e07f8eda2c61cb3", "score": "0.5321562", "text": "constructor(prefix) {\n this.prefix_ = prefix;\n }", "title": "" }, { "docid": "feaea45d0601753fab25995edf7ccc39", "score": "0.53106517", "text": "function SecureTrie () {\n CheckpointTrie.apply(this, arguments)\n secureInterface(this)\n}", "title": "" }, { "docid": "a5b153c7e86153de3c0694263ef3641d", "score": "0.5252455", "text": "startsWith(t){}", "title": "" }, { "docid": "30a941d2cd2eba9fca99f1722cc366d4", "score": "0.5243403", "text": "function buildTrie(words, trieOptions) {\n return new TrieBuilder(words, trieOptions).build();\n}", "title": "" }, { "docid": "18daab877c8552ce019af0788505442e", "score": "0.52414316", "text": "addPrefix(prefix, iri, done) {\n var prefixes = {};\n prefixes[prefix] = iri;\n this.addPrefixes(prefixes, done);\n }", "title": "" }, { "docid": "70dcd43b7a6587f4b408c96090a0d8c0", "score": "0.52340496", "text": "addPrefix(prefix, iri, done) {\n const prefixes = {};\n prefixes[prefix] = iri;\n this.addPrefixes(prefixes, done);\n }", "title": "" }, { "docid": "db3990c97cd58e93c3c96cb31abdea42", "score": "0.5219806", "text": "checkTrie(word) {\n return searchTrie(word, true)[0];\n }", "title": "" }, { "docid": "72300132fc81a156b7d4481693bf9cc4", "score": "0.52190584", "text": "function makePrefixer(prefijo){\n return function ponerPrefijo (palabra){\n console.log(prefijo + palabra)\n }\n}", "title": "" }, { "docid": "998d6031ae4c66d054af2ce9b8b2361e", "score": "0.52140737", "text": "function prefix(s) {\r\n return gm_prefix+s;\r\n }", "title": "" }, { "docid": "3521c79c9101f23be93161cb21e8302e", "score": "0.52105975", "text": "function prefixes(defaultPrefixes, factory) {\n // Add all of the default prefixes\n const prefixes = Object.create(null);\n for (const prefix in defaultPrefixes) processPrefix(prefix, defaultPrefixes[prefix]);\n // Set the default factory if none was specified\n factory = factory || _N3DataFactory.default;\n\n // Registers a new prefix (if an IRI was specified)\n // or retrieves a function that expands an existing prefix (if no IRI was specified)\n function processPrefix(prefix, iri) {\n // Create a new prefix if an IRI is specified or the prefix doesn't exist\n if (typeof iri === 'string') {\n // Create a function that expands the prefix\n const cache = Object.create(null);\n prefixes[prefix] = local => {\n return cache[local] || (cache[local] = factory.namedNode(iri + local));\n };\n } else if (!(prefix in prefixes)) {\n throw new Error(`Unknown prefix: ${prefix}`);\n }\n return prefixes[prefix];\n }\n return processPrefix;\n}", "title": "" }, { "docid": "397d8782a54f0698b6be588b37e794b4", "score": "0.52100396", "text": "function construct_chain (list) {\n var chain = {};\n\n var i; for (i = 0; i < list.length; i++) {\n var names = list[i].split(/\\s+/);\n chain = incr_chain(chain,'parts',names.length);\n\n var j; for (j = 0; j < names.length; j++) {\n var name = names[j];\n chain = incr_chain(chain,'name_len',name.length);\n\n var c = name.substr(0,1);\n chain = incr_chain(chain,'initial',c);\n\n var string = name.substr(1);\n var last_c = c;\n\n while (string.length > 0) {\n var c = string.substr(0,1);\n chain = incr_chain(chain,last_c,c);\n\n string = string.substr(1);\n last_c = c;\n }\n }\n }\n return scale_chain(chain);\n }", "title": "" }, { "docid": "a5676ea401bfa4245809bcdc55ec8757", "score": "0.52008724", "text": "function randomPrefix(){\n var prefix = choose(choose(selected).prefixes);\n // Add a space if the prefix doesn't end with the special | character\n if (prefix[prefix.length-1] == '|')\n return prefix.slice(0, prefix.length-1);\n return prefix + ' ';\n}", "title": "" }, { "docid": "704e687709524ef94feb9464e5f31be9", "score": "0.51821446", "text": "insert(string,node){\n node = node || this.root;\n\n //Base case -> Reach the end of the word\n if(string.length === 0){\n node.setEnd();\n return;\n }\n //Conditions => add character to node\n // if the node does not have the character add\n else if(!node.keys.has(string[0])){\n node.keys.set(string[0],new Node());\n return this.insert(string.substr(1), node.keys.get(string[0]));\n }\n else{\n // if the node does have the character add\n return this.insert(string.substr(1), node.keys.get(string[0]));\n }\n \n }", "title": "" }, { "docid": "eb007d604117c8bc71522b6c97273622", "score": "0.51803154", "text": "function s2(beginWord, endWord, wordList) {\n /* \n make forms hashmap\n '*ot': [ 'hot', 'dot', 'lot' ],\n 'h*t': [ 'hot' ],\n 'ho*': [ 'hot' ],\n 'd*t': [ 'dot' ],\n 'do*': [ 'dot', 'dog' ],\n '*og': [ 'dog', 'log', 'cog' ],\n 'd*g': [ 'dog' ],\n 'l*t': [ 'lot' ],\n 'lo*': [ 'lot', 'log' ],\n 'l*g': [ 'log' ],\n 'c*g': [ 'cog' ],\n 'co*': [ 'cog' ]\n */\n\n // time, o(nm2), o(length of wordlist * length of word * length of word)\n // word of m length, will appear in m forms (3 letter word will appear 3 times in the graph)\n // will be at most nm entries in graph\n // BETTER THAN ABOVE if length of wordlist is greater than the length of the word (ASSUMING ALL SAME LENGTH)\n\n // space, o(nm2)\n const graph = makeGraph();\n console.log(graph);\n\n function makeGraph() {\n const out = {};\n for (let i = 0; i < beginWord.length; i++) {\n const form = `${beginWord.substring(0, i)}*${beginWord.substring(i + 1)}`;\n out[form] ? out[form].push(beginWord) : (out[form] = [beginWord]);\n }\n for (let word of wordList) {\n for (let i = 0; i < word.length; i++) {\n const form = `${word.substring(0, i)}*${word.substring(i + 1)}`;\n out[form] ? out[form].push(word) : (out[form] = [word]);\n }\n }\n return out;\n }\n\n const set = new Set();\n set.add(beginWord);\n const q = [[beginWord, 0]];\n while (q.length) {\n console.log(q);\n const [word, level] = q.shift();\n if (word === endWord) return level;\n for (let i = 0; i < word.length; i++) {\n const form = `${word.substring(0, i)}*${word.substring(i + 1)}`;\n for (let nextWord of graph[form]) {\n if (!set.has(nextWord)) {\n set.add(nextWord);\n q.push([nextWord, level + 1]);\n }\n }\n }\n }\n}", "title": "" }, { "docid": "109517ccb974730986dc894f6189c2b1", "score": "0.5170121", "text": "function Trie () {\n if (!(this instanceof Trie)) return new Trie()\n this.trie = { nodes: {} }\n}", "title": "" }, { "docid": "bb0c49907b79423475d0be5757a8dde3", "score": "0.5167514", "text": "function findSimilarPrefix(queue){\n var foundSamePrefix = false;\n // the first ancestor that contains the 3 highlighted elements\n var prePrefixElement;\n var commonPrefix = [];\n var firstLength = queue[0].length - 1;\n var secondLength = queue[1].length - 1;\n var thirdLength = queue[2].length - 1;\n var sameElement = isSameElement(queue);\n\n for(var j = firstLength; j >= 0; j--){\n for(var k = secondLength; k >= 0; k--){\n for(var l = thirdLength; l >= 0; l--){\n // Looks for the most specific common prefix from the\n // 3 highlighted elements.\n if(queue[0][j][0] == queue[1][k][0] &&\n queue[0][j][0] == queue[2][l][0] &&\n queue[0][j][2] == queue[1][k][2] &&\n queue[0][j][2] == queue[2][l][2] && !foundSamePrefix){\n commonPrefix.push(queue[0][j]); // element tag name\n commonPrefix.push(queue[1][k]); // element number\n commonPrefix.push(queue[2][l]); // child number\n foundSamePrefix = true;\n }\n // Goes up the DOM to look for the first common element that\n // contains the 3 highlighted elements.\n if(queue[0][j][0] == queue[1][k][0] &&\n queue[0][j][0] == queue[2][l][0] &&\n queue[0][j][1] == queue[1][k][1] &&\n queue[0][j][1] == queue[2][l][1]){\n prePrefixElement = queue[0][j];\n var prefixObject = {\n prePrefixElement: prePrefixElement,\n prefixArr: commonPrefix,\n sameElement: sameElement\n };\n return prefixObject;\n }\n }\n }\n }\n}", "title": "" }, { "docid": "48a621d2135034f0b14eec27270c2433", "score": "0.5159097", "text": "process(node) {\n let parent = this.parentPrefix(node)\n\n for (let prefix of this.prefixes) {\n if (!parent || parent === prefix) {\n this.add(node, prefix)\n }\n }\n }", "title": "" }, { "docid": "d38c50206eae72b0718d0b283f8a3a40", "score": "0.5135342", "text": "function Trie() {\n this.root = new TrieNode(null);\n }", "title": "" }, { "docid": "3e38dfd1f3c6a4ab641d36e78a85f376", "score": "0.5129855", "text": "function findCommonPrefix(str) {\n lastChar = commonPrefix.length - 1;\n commonPrefix = commonPrefix.substring(0, lastChar);\n }", "title": "" }, { "docid": "2a3d190300b55796c369d94ec348b07c", "score": "0.51291907", "text": "addWord(word) {\n // Initialize a node starting at storage\n let node = this.storage;\n // Iterate through the characters in the word\n for (let i = 0; i < word.length; i++) {\n const letter = word[i];\n // If the character does not exist at this level in our node, \n if (!node[letter]) {\n // then we create the node.\n node[letter] = {};\n }\n // Traverse to the next node\n node = node[letter];\n }\n // Signify that the node is the end of a word\n node.end = true;\n }", "title": "" }, { "docid": "725d2d6a07ebc04554d56d08896c4390", "score": "0.5126905", "text": "function addGrafterPrefixer(name, prefixString, parentPrefix) {\n var prefixer;\n\n if (parentPrefix.toString().trim() === '') {\n prefixer = new jsedn.List([\n jsedn.sym('def'),\n jsedn.sym(name),\n new jsedn.List([jsedn.sym('prefixer'), prefixString])\n ]);\n\n } else {\n\n prefixer = new jsedn.List([\n jsedn.sym('def'),\n jsedn.sym(name),\n new jsedn.List(\n [jsedn.sym('prefixer'), new jsedn.List([jsedn.sym(parentPrefix), prefixString])])\n ]);\n }\n\n prefixers.push(prefixer);\n}", "title": "" }, { "docid": "4a02e0d53874a7d54ce1035c873fe6d9", "score": "0.51244146", "text": "function addClasses() {\r\n\t\t\t\tvar str, firstChar, spl, $this, hasPrefixes = (opts.prefixes.length > 0);\r\n\t\t\t\t$($list).children().each(function() {\r\n\t\t\t\t\t$this = $(this), firstChar = '', str = $.trim($this.text()).toLowerCase();\r\n\t\t\t\t\tif (str) {\r\n\t\t\t\t\t\tif (hasPrefixes) {\r\n\t\t\t\t\t\t\tspl = str.split(' ');\r\n\t\t\t\t\t\t\tif ((spl.length > 1) && ($.inArray(spl[0], opts.prefixes) > -1)) {\r\n\t\t\t\t\t\t\t\tfirstChar = spl[1].charAt(0);\r\n\t\t\t\t\t\t\t\taddLetterClass(firstChar, $this, true);\r\n\t\t\t\t\t\t\t}\r\n\t\t\t\t\t\t}\r\n\t\t\t\t\t\tfirstChar = str.charAt(0);\r\n\t\t\t\t\t\taddLetterClass(firstChar, $this);\r\n\t\t\t\t\t}\r\n\t\t\t\t});\r\n\t\t\t}", "title": "" }, { "docid": "28b2642803ea268faa0006ebb49ed9e7", "score": "0.5124099", "text": "addLeft(str){\n for (var i = str.length-1; i >= 0; i--){\n this.list.unshift(str[i]);\n this.hash = this.hash^shift(getTranslatedHash(str[i]), this.length);\n this.length++;\n }\n }", "title": "" }, { "docid": "d1512b1992d8e7a63dc9d0103fc7eb2a", "score": "0.5120062", "text": "function addPrefixMapping(prefix, arangoEdges) {\n var namespace = vocabularyMapping[prefix].namespace;\n\n var nameHash = namespace.hashCode().toString();\n var alreadyMappedPrefix = false;\n for(var pref in arangoPrefixes){\n if (pref === nameHash) {\n alreadyMappedPrefix = true;\n }\n }\n\n if (!alreadyMappedPrefix && nameHash !== undefined){\n arangoPrefixes[nameHash] = {\n _key: nameHash, \n namespaceURI: namespace,\n prefix: prefix,\n type: 'Prefix'\n };\n }\n\n}", "title": "" }, { "docid": "6b53a0d7db1bc4d43374f54bc4ec8c8a", "score": "0.51159436", "text": "constructor(prefix) {\n let existing = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new Map();\n let counter = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;\n this.prefix = prefix;\n this._existing = existing;\n this.counter = counter;\n }", "title": "" }, { "docid": "bd5b66375cb7518185a5550a6a848cb5", "score": "0.51159084", "text": "function anagrams(prefix, str){\n if(str.length <= 1){\n // console.log(`The anagram is ${prefix}${str}`);\n } else {\n for(let i=0; i<str.length; i++){\n let currentLetter = str.substring(i, i+1);\n let previousLetters = str.substring(0,i);\n let afterLetters = str.substring(i+1);\n anagrams(prefix+currentLetter, previousLetters+afterLetters);\n }\n }\n\n}", "title": "" }, { "docid": "7051056e237a659d8c1295a08403b4a0", "score": "0.5108088", "text": "function findSubstrings(words, parts) {\n function leaf(x) {\n this.value = x;\n this.end = false;\n this.children = []\n }\n function createTree(root,parts){\n if(!parts.length){\n return []\n }\n\n var childArray = [];\n //var endArray = []\n var children = [];\n parts.forEach((ele,i)=>{\n var index = children.indexOf(ele[0]);\n if (index == -1){\n root.children.push(new leaf(ele[0]))\n children.push(ele[0]);\n if(ele.length>1){\n childArray.push([ele.substr(1)])\n }else{\n root.children[root.children.length-1].end = true;\n //this.end = true;\n childArray.push([])\n }\n }else{\n if(ele[0] == \"i\"){\n console.log(ele[0])\n //root.children[root.children.length-1]\n }\n if(ele.length>1){\n childArray[index].push(ele.substr(1))\n }else{\n //console.log(root.children[index])\n root.children[index].end =true;\n }\n }\n })\n //console.log(childArray);\n root.children.forEach((ele,index) =>{\n if (childArray[index].length>0){\n createTree(ele,childArray[index])\n }\n })\n }\n var root = new leaf('');\n //createTree(root,[\"a\", \"mel\", \"lon\", \"el\", \"An\"]);\n createTree(root,parts);\n //console.log(root)\n function search(word,tree){\n var startIndex = 0,maxLength=-1;\n for(var start=0; start<word.length;start++){\n var root = tree;\n for(var i = start; i< word.length ;i++){\n // console.log(word[i] + ' ' + start)\n var index = root.children.findIndex(ele=>{\n return ele.value == word[i] })\n if(index==-1){\n break;\n }else{\n //console.log(root);\n root = root.children[index];\n if(\"myopic\" == word){\n // console.log(root.value);\n // console.log(root.end);\n }\n\n if(root.end == true && ((i-start)> maxLength)){//&& startIndex<start\n startIndex = start;\n maxLength = i-start;\n }\n }\n }\n }\n //console.log(maxLength + \" \" + startIndex)\n if(maxLength!=-1){\n word = word.substr(0,startIndex) + '[' + word.substr(startIndex,maxLength+1) + \"]\" + word.substr(startIndex+maxLength+1)\n }\n return word;\n }\n //search('Watermelon',root)\n // console.log(tree);\n words.forEach((ele,index)=>{\n words[index] = search(ele,root);\n })\n return words;\n}", "title": "" }, { "docid": "304380d969be4fea853c346586021303", "score": "0.509752", "text": "Add(word) {\n const characters = Array.from(word);\n let currNode = this.head;\n for (let i = 0; i < characters.length; i++) {\n const isComp = charIndex === characters - 1;\n currNode = currNode.addChild(characters[charIndex], isComp);\n }\n return this;\n }", "title": "" }, { "docid": "d47198d9460f25b37e5b2aad51867ad2", "score": "0.5091225", "text": "function lc1mkt(xs) { return mkt(xs.map(function (x) {\n return x[0].toLowerCase()+x.substr(1) })) }", "title": "" }, { "docid": "8c73eff370dab179e9c61ee51655e6f7", "score": "0.5087246", "text": "function anagram(prefix, word) {\n if (word.length === 1) {\n console.log(prefix + word);\n }\n\n for (let i = 0; i < word.length; i++) {\n const firstChar = word.charAt(i);\n const remainder = word.substring(0, i) + word.substring(i + 1);\n anagram(prefix + firstChar, remainder);\n }\n}", "title": "" }, { "docid": "355eaaf986531832c50fd869e6c421d1", "score": "0.50753945", "text": "function removeCommonPrefix(strings) {\n if (strings.length < 2) {\n return strings;\n }\n var index = 0;\n var largestIndex = 0;\n // Find the shortest name across all strings.\n var minLength = _.min(_.map(strings, function (str) { return str.length; }));\n var _loop_1 = function () {\n index++;\n var prefixes = _.map(strings, function (str) { return str.substring(0, index); });\n var allTheSame = prefixes.every(function (prefix, i) {\n return (i === 0 ? true : prefix === prefixes[i - 1]);\n });\n if (allTheSame) {\n if (index >= minLength) {\n return { value: strings };\n }\n largestIndex = index;\n }\n else {\n return \"break\";\n }\n };\n while (true) {\n var state_1 = _loop_1();\n if (typeof state_1 === \"object\")\n return state_1.value;\n if (state_1 === \"break\")\n break;\n }\n return _.map(strings, function (str) { return str.substring(largestIndex); });\n }", "title": "" }, { "docid": "905ad0c9c855e73dfc85b12c2bfa2a21", "score": "0.50741696", "text": "function longestCommonPrefix(strs) {\n if (strs.length === 0) {\n return null;\n }\n if (strs.length === 1) {\n return strs[0];\n }\n let result = '';\n\n strs = strs.sort(); // nlogn\n\n for (let i = 0; i < strs[0].length; i++) {\n //n\n if (strs[0][i] === strs[strs.length - 1][i]) {\n result += strs[0][i];\n } else {\n break;\n }\n }\n return result;\n}", "title": "" }, { "docid": "90eb60a48118d975d1bc71012c138ba7", "score": "0.5065084", "text": "get_node(){\n return new TrieNode()\n }", "title": "" }, { "docid": "917f6227fd168eb726bd6484fc889a7a", "score": "0.5060948", "text": "_startWith (string, prefix) {\n if (typeof string != 'string') {\n return false;\n\n } else {\n for (var i = 0, length = prefix.length; i < length; i += 1) {\n var p = prefix[i];\n var s = string[i];\n if (p !== s) {\n return false;\n }\n }\n }\n return true;\n }", "title": "" }, { "docid": "6a354d9cca080b26eb8245e48ee7a721", "score": "0.5060823", "text": "constructor(prefix, keys = []) {\n this.prefix = prefix;\n this.keys = keys;\n }", "title": "" }, { "docid": "4bbb0e6952130324794220faae3f4ea2", "score": "0.50477856", "text": "addPrefix(prefix) {\n if (!prefix) {\n return this;\n }\n this.input = `${prefix}_${this.input}`;\n return this;\n }", "title": "" }, { "docid": "56d01d64b4f173d4885d05e25e1cb692", "score": "0.50466704", "text": "startsWith(t) { return true }", "title": "" }, { "docid": "d4f7844127487d99a24399d0ac8ec87b", "score": "0.5041709", "text": "makeStartChains() {\n this.startChains = {}\n for (let key of Object.keys(this.chains))\n if (key.charAt(0) === key.charAt(0).toUpperCase())\n this.startChains[key] = this.chains[key]\n }", "title": "" }, { "docid": "44366a6556f23c394506ad6b95504507", "score": "0.5038597", "text": "function newWord(){\n textInput = \"\";\n letters = {};\n topNode = 0;\n nodes = [];\n objectsList = [];\n}", "title": "" }, { "docid": "a2a891812a37246266f295d6b97718c1", "score": "0.5036913", "text": "function solution(A) {\n var terms = A.length;\n var match = 1;\n var prefix = \"\";\n while (match == 1) {\n for (var c = 0; c < 100; c++) {\n for (var i = 0; i < terms-1; i++) {\n if (A[i][c] != A[i+1][c]) {\n match = 0 \n }\n } \n }\n }\n return prefix;\n}", "title": "" }, { "docid": "cc94198e0b3b40b730ada3ca6c415e39", "score": "0.5007248", "text": "function toWylieOneTsekbar(str, len, i) {\n var orig_i = i;\n var warns = [];\n var stacks = [];// ArrayList<ToWylieStack>;\n ITER:\n while (true) {\n var st = toWylieOneStack(str, len, i);\n stacks.push(st);\n warns = warns.concat(st.warns);\n i += st.tokens_used;\n if (st.visarga) {\n break ITER;\n }\n if (i >= len || null == tib_top(str.charAt(i))) {\n break ITER;\n }\n }\n // figure out if some of these stacks can be prefixes or suffixes (in which case\n // they don't need their \"a\" vowels)\n var last = stacks.length - 1;\n if (stacks.length > 1 && stacks[0].single_cons != null) {\n // we don't count the wazur in the root stack, for prefix checking\n var cs = stacks[1].cons_str.replace(/\\+w/g, '');\n if (prefix(stacks[0].single_cons, cs)) {\n stacks[0].prefix = true;\n }\n }\n if (stacks.length > 1 && stacks[last].single_cons != null\n && isSuffix(stacks[last].single_cons)) {\n stacks[last].suffix = true;\n }\n if (stacks.length > 2 && stacks[last].single_cons != null\n && stacks[last - 1].single_cons != null\n && isSuffix(stacks[last - 1].single_cons)\n && suff2(stacks[last].single_cons, stacks[last - 1].single_cons)) {\n stacks[last].suff2 = true;\n stacks[last - 1].suffix = true;\n }\n // if there are two stacks and both can be prefix-suffix, then 1st is root\n if (2 == stacks.length && stacks[0].prefix && stacks[1].suffix) {\n stacks[0].prefix = false;\n }\n // if there are three stacks and they can be prefix, suffix and suff2, then check w/ a table\n if (3 == stacks.length && stacks[0].prefix && stacks[1].suffix && stacks[2].suff2) {\n var strb = [];\n for (var si = 0; si < stacks.length; si++) {\n strb.push(stacks[si].single_cons);\n }\n var ztr = strb.join('');\n var root = ambiguous_key(ztr);\n if (null == root) {\n warns.push('Ambiguous syllable found: root consonant not known for \\\"' + ztr + '\\\".');\n // make it up... (ex. \"mgas\" for ma, ga, sa)\n root = 1;\n }\n stacks[root].prefix = stacks[root].suffix = false;\n stacks[root + 1].suff2 = false;\n }\n // if the prefix together with the main stack could be mistaken for a single stack, add a \".\"\n if (stacks[0].prefix && tib_stack(stacks[0].single_cons + '+' + stacks[1].cons_str)) {\n stacks[0].dot = true;\n }\n // put it all together\n var out = '';\n for (var si = 0; si < stacks.length; si++) {\n out += putStackTogether(stacks[si]);\n }\n var ret = new ToWylieTsekbar();\n ret.wylie = out;\n ret.tokens_used = i - orig_i;\n ret.warns = warns;\n return ret;\n}", "title": "" }, { "docid": "6846f5adcab0503ee1d6a4f2b1a69150", "score": "0.49897093", "text": "function makeAnagram(inProgress, leftovers) {\n // if in-progress's length === string's length\n if (inProgress.length === string.length) {\n // push in-progress into results array\n results.push(inProgress);\n }\n\n\n\n // loop through leftover letters\n for (let i = 0; i < leftovers.length; i++) {\n // recursively call helper. Args: 1) letter from loop with in-progress prepended, 2) leftover letters minus the letter from loop.\n let inProgressWithAddedLetter = inProgress + leftovers[i];\n\n let remainingLettersAfterAdd = leftovers.slice(0,i) + leftovers.slice(i+1);\n\n makeAnagram(inProgressWithAddedLetter, remainingLettersAfterAdd);\n }\n }", "title": "" }, { "docid": "43473f9096d0507de6b88fa0cd834fa3", "score": "0.49829918", "text": "function createSuggestionsArray(value) {\n // PREFIX: \n suggestions = [];\n\n allTitleWords.forEach(word => {\n if (word.endsWith('.')) {\n word = word.slice(0, -1);\n } \n if (word.startsWith(value) === true && word.length >= 3) {\n suggestions.push(word);\n } \n });\n}", "title": "" }, { "docid": "b87a5cfc6f5714f479318ca0687bbd59", "score": "0.49821207", "text": "function readWords() {\n readText(document.getElementById(\"inBox\").value);\n\n if(mainText !== savedText){\n trieMade = false;\n clearNode(root);\n }\n\n\n var longestWords = [];\n numWords = 0;\n numCharacters = 0;\n longestWordString = \"\";\n\n var tmpWords = mainText.match(/\\S+/g);\n numCharacters = mainText.split(\"\").length;\n\n if(tmpWords !== null) {\n for (var i = 0; i < tmpWords.length; i++) {\n var word = CleanWord(tmpWords[i]);\n\n //Find the longest word\n if (i === 0) {\n longestWords[0] = word;\n } else {\n if (word.length > longestWords[0].length) {\n longestWords = [];\n longestWords.push(word);\n } else if (word.length === longestWords[0].length && !containsWord(word,longestWords)) {\n longestWords.push(word);\n }\n }\n\n var found = false;\n if(!trieMade){\n found = search(this.root, word, true);\n }else {\n found = search(this.root, word, false);\n }\n\n //add word to trie\n if (found) {\n numWords++;\n } else {\n if (addWord(this.root, word) === 0) {\n numWords++;\n }\n }\n }\n\n //get longest word definition for RESTful api call\n if(!trieMade) {\n //This get all the longest words if there are multiple words\n for (var j = 0; j < longestWords.length; j++) {\n getDefinition(longestWords[j]);\n }\n }\n\n //get word frequency from trie\n if(!trieMade) {\n topWords = [];\n mostUsedWords = \"\";\n getWordFrequency(this.root);\n for (var k = 0; k < topWords.length; k++) {\n mostUsedWords += topWords[k][0] + \": \" + topWords[k][1] + \"<br/>\";\n }\n console.log(topWords.toString());\n }\n\n if (numWords > 0) {\n wordsRead = true;\n trieMade = true;\n savedText = mainText;\n }\n\n }\n}", "title": "" }, { "docid": "271235d14f90879ab068565e7645bdce", "score": "0.49764675", "text": "function processPrefix(prefix, iri) {\n // Create a new prefix if an IRI is specified or the prefix doesn't exist\n if (typeof iri === 'string') {\n // Create a function that expands the prefix\n const cache = Object.create(null);\n prefixes[prefix] = local => {\n return cache[local] || (cache[local] = factory.namedNode(iri + local));\n };\n } else if (!(prefix in prefixes)) {\n throw new Error(`Unknown prefix: ${prefix}`);\n }\n return prefixes[prefix];\n }", "title": "" } ]
1a8c4a89e168e885eb5a1dbc2f099396
a cup contains a specific drink chosen by the customer using the wizard the customer can interact with the cup : drink, refill or choose something else also, a timer (located in the controller) will decrease the temperature of the cup contents
[ { "docid": "1f6325a6b0fdd8defe7de34b64a4d812", "score": "0.59203637", "text": "function cup(Constants) {\n\n\tconsole.log(\"cup is being initialized\");\n\n\t// the reference to the instance cannot be called directly from within the functions/methods\n this.constantsInstance = Constants;\n\n\t// definition of the drink being served :\n this.recommendedTemperature = this.constantsInstance.get(\"temperature_cold\");\n this.cupType = this.constantsInstance.get(\"cupform_default\");\n this.drinkName = null;\n this.drinkId = null;\n\n // temporary definition of the drink that may get served :\n // in order to be able to cancel an order being processed,\n // the retrieval of characteristics needs to be copied to a temporary location\n // so that the current drink served is not overwritten before the order is confirmed by the customer\n // (there is only one cup, so only one drink may get served at a time)\n this.temporaryRecommendedTemperature = this.constantsInstance.get(\"temperature_cold\");\n this.temporaryCupType = this.constantsInstance.get(\"cupform_default\");\n this.temporaryDrinkName = null;\n this.temporaryDrinkId = null;\n\n // does the customer have a drink to go back to\n this.served = false;\n // how much liquid the cup still contains in percentage\n this.amount = 0;\n // how warm the content of the cup is\n this.temperature = this.constantsInstance.get(\"temperature_cold\");\n\n // cleanup resources before leaving\n var self = this;\n $(window).unload(function () {\n \tif (self.exists) {\n \t\tself.clearDrink();\n \t}\n });\n}", "title": "" } ]
[ { "docid": "3a6d72a0c280cd601aa0a17b0241f2c1", "score": "0.57287097", "text": "function drinkCoffee() {\r\n let text = document.getElementById(\"dynamictext\");\r\n let description = \"\";\r\n\r\n // Lower height of coffee.\r\n if (coffeeHeight > 25) {\r\n coffeeHeight -= 5;\r\n drawMug();\r\n\r\n // Build description based on current coffee conditions.\r\n description += decideCreaminess();\r\n description += decideSweetness();\r\n description += decideTaste();\r\n\r\n // Add the description to the dynamictext.\r\n text.innerHTML = description;\r\n } else {\r\n text.innerHTML = \"Nothing left to drink\";\r\n }\r\n }", "title": "" }, { "docid": "8b4b8091d4179c74883b4daff6e9e779", "score": "0.56762296", "text": "function eat(){\n $timeout.cancel(timer);\n currentMeal++;\n self.colorCurrent = \"white\";\n oldCount = angular.copy(currentMeal);\n mealQuantity[self.current.label].weight--;\n if (currentMeal >= mealQuantity[self.current.label].limit || currentMeal >= mealQuantity[self.current.label].weight){\n $rootScope.message = 'n' // n pour next plate\n if (self.current.label.indexOf('d') == -1) {\n $rootScope.disableNext = false;\n }\n if (mealQuantity[self.current.label].weight == 0){\n $rootScope.message = 'n' // n pour next plate\n mealQuantity[self.current.label].weight = 0;\n if (self.current.label.indexOf('d') == -1){\n self.clickNext();\n } else {\n $rootScope.turnPlate = {label: \"end\"};\n }\n }\n } else {\n self.msgToSend = \"\";\n }\n countWeight(function (){\n if (oldCount == currentMeal){\n $rootScope.message = 'l'; //l pour too long\n }\n });\n }", "title": "" }, { "docid": "5afb92b168daf963e6dbf63e66c964cc", "score": "0.55850786", "text": "function tempo() {\n console.log(\"poop\");\n var temperature = new five.Thermometer({\n controller: \"TMP36\",\n pin: \"A0\"\n });\n\n temperature.on(\"change\", function () {\n console.log(this.celsius + \"°C\", this.fahrenheit + \"°F\");\n $('#tempo').html(this.fahrenheit + \"°\");\n\n if (this.fahrenheit > 102) {\n $('#wrapper_alert').hide(0);\n\n if (this.fahrenheit > 106) {\n console.log(\"hyperthermia\");\n // alertLights();\n $('#final').text(c_name + ' has HIGH FEVER. Immediate attention required');\n $('#wrapper_alert').show(0);\n $('#police').click(function () {\n $('#final_m').text('Emergency services have been notified');\n alertLights();\n });\n $('#emergency').click(function () {\n $('#final_m').text('The doctor is on his way');\n alertLights();\n });\n }\n else {\n $('#tempo').effect(\"shake\");\n setColor(0);\n console.log(\"hot bois\");\n sweep(150);\n // $('#outer').toggleClass('red');\n $('#outer').attr('class', 'red');\n }\n }\n\n\n else if (this.fahrenheit < 100.4 && this.fahrenheit > 97.7) {\n $('#wrapper_alert').hide(0);\n setColor(1);\n console.log(\"safe bois\");\n sweep(90);\n // $('#outer').toggleClass('green');\n $('#outer').attr('class', 'green');\n }\n\n\n else if (this.fahrenheit < 96) {\n $('#wrapper_alert').hide(0);\n setColor(2);\n console.log(\"cold bois\");\n sweep(30);\n $('#outer').attr('class', 'blue');\n if (this.fahrenheit < 93) {\n console.log(\"hypothermia\");\n // alertLights();\n $('#final').text(c_name + ' has hypothermia. Immediate attention required');\n $('#wrapper_alert').show(0);\n $('#police').click(function () {\n $('#final_m').text('Emergency services have been notified');\n alertLights();\n });\n $('#emergency').click(function () {\n $('#final_m').text('The doctor is on his way');\n alertLights();\n });\n // \n }\n // $('#outer').toggleClass('blue');\n \n }\n\n\n });\n}", "title": "" }, { "docid": "4309cb35837e50887b832914d79678f8", "score": "0.557952", "text": "function buzzed(event, client, team, cd){\n if (excluded)\n return;\n\n if (true) {\n countdown = cd;\n self.buzzerText = countdown;\n\n contdownDecreaseInterval = $interval(function(){\n countdownDecrease();\n },1000);\n } else {\n self.buzzerText = '';\n }\n\n if (client == self.deviceName){\n self.buzzerState = buzzerState.selfBuzzed;\n audioFactory.buzz();\n return;\n }\n\n if (team == self.teamName){\n self.buzzerState = buzzerState.teamBuzzed;\n audioFactory.buzz();\n return;\n }\n\n self.buzzerState = buzzerState.lateBuzzed;\n\n }", "title": "" }, { "docid": "60c9b032f8389ef10dd8ac1a323152c7", "score": "0.5552294", "text": "function controle() {\n\n var T1 = sensor.readSimpleC(1); //Q roof\n var T2 = 0;// sensor.readSimpleC(2)// //Heatpipe\n// var T3 = 0; //sensor.readSimpleC(2)//§ //ventiline\n var min1 = 35; //onderboilerthermometer\n var min2 = 32; //bovenboilerthermometer\n console.log(`${T1} degC`); //live temperatuur\n\n\n if (T1 > min1 && T2 > min1) {\n\n\n setup1();\n\n }\n\n else if (T1 < min2) {\n setup3();\n }\n\n\n else if (T2 < min2) {\n setup2();\n }\n\n setInterval(controle,3000);\n\n}", "title": "" }, { "docid": "5fb1fd638a0c11e8e958f1cf8c8dec98", "score": "0.55312866", "text": "function tempController(data) {\n const unit = document.querySelector('.unit');\n switch (true) {\n case unit.textContent === 'C':\n fetchTempCelcius(data);\n break;\n default:\n fetchTempFahrenheit(data);\n }\n }", "title": "" }, { "docid": "e87b5b62ca917553bcd28d6a753d50d1", "score": "0.55156004", "text": "function updatedrinks() { \n currentDrink=randomarray(drinks);\n drinkTokens-=1;\n if(drinkTokens==0){\n\n currentDayaction=\"some sleep\"\n document.querySelector(\".value_dayaction\").innerText = currentDayaction;\n\n }\n\n updatespaceshipvalues();\n checktokens();\n\n}", "title": "" }, { "docid": "629bd61a80a6e4ff230295a46113cf1a", "score": "0.55006975", "text": "function WGCetus(data){\n\t//checks if the cycle has swaped\n\tif(wGetLog.cetus != data.isDay){\n\t\t//change the day night value\n\t\twGetLog.cetus = data.isDay;\n\t\tif(wGetLog.cetus == true){\n\t\t\tnoteChan.send(\"Cetus has returned to day and the Eidolons have gone back into hiding\");\n\t\t}else{\n\t\t\tnoteChan.send(\"Night has befallen Cetus and the Eidolons have been agitated and must be stoped\");\t\n\t\t}\n\t}\n}", "title": "" }, { "docid": "7ea1d7c21ac5d50cc6ed877eadd4a71d", "score": "0.5492663", "text": "function whatDrink () {\n if (espressoCount == 1 && milkCount == 0 && !foamAdded) {\n drink = \"espresso (30ml espresso) <br/>or ristretto (22ml concentrated espresso)\";\n }\n else if (espressoCount == 1 && milkCount == 1 && foamAdded) {\n drink = \"cappucino (60ml espresso | 60ml steamed milk | 60ml foam) <br/>or cafe latte (60ml espresso | 300ml steamed milk | 2ml foam)\";\n }\n else if (espressoCount == 1 && milkCount == 2 && !foamAdded) {\n drink = \"flat white (60ml espresso | 120ml steamed milk)\";\n }\n else if (espressoCount == 2 && milkCount == 0 && !foamAdded){\n drink = \"espresso doppio (60ml espresso)\";\n }\n else if (espressoCount == 2 && milkCount == 0 && foamAdded){\n drink = \"cafe cortado (60ml espresso | 30ml foam) <br/>or cafe macchiato (60ml espresso | dot of foam) <br/>or dry cappucino (60ml espresso | 120ml foam)\";\n }\n else if (espressoCount == 2 && milkCount == 1 && !foamAdded) {\n drink = \"cafe noisette (60ml espresso | 30ml hot milk)\";\n }\n else if (espressoCount == 3 && milkCount == 0 && !foamAdded) {\n drink = \"lungo (90ml less concentrated espresso)\";\n }\n else {\n drink = \"no name\";\n }\n $('#virtual-barrista-intro p:last-of-type').html(drink);\n }", "title": "" }, { "docid": "c1bddf51918c35087414111dd4dda5d9", "score": "0.5396387", "text": "function Human (option){\nlet opt = option || {};\nthis.alertness = opt.alertness || 0;\n\nthis.hasCoffee = opt.hasCoffee || false;\nthis.needsCoffee = opt.needsCoffee || true;\n\n\n//allowing Coffee into Human\nthis.buy = function (purchase) {\n this.Coffee = purchase;\nthis.hasCoffee = true}\n//ben drinking coffee\n\n\nthis.drink = function () {\nthis.alertness =+ 0.31\nthis.Coffee.full = false;\nthis.Coffee.empty = false;\n\n//kenny/rodney\n\nthis.Coffee.carafs++;\n\nif (this.Coffee.carafs === 3){\n this.Coffee.empty = true;\n this.alertness = 0.99;\n }\n//end of Rodney's coffee\n }\n//end of drink()\n}", "title": "" }, { "docid": "b742d1adb974b92465fa63923a59a1fb", "score": "0.5379083", "text": "updateDevJauge(checklist){\n\tDevJauge.setIn(this.carte)\n}", "title": "" }, { "docid": "f502daec5b4db4f92a3a502a4873f09c", "score": "0.5355622", "text": "pickUpDirt() {\n\t\tthis.dirtCount++;\n\t}", "title": "" }, { "docid": "e02077e2f9ea8e686b12dd71baaa6d52", "score": "0.5329423", "text": "function showCountDown(thermostat) {\r\n var interv = setInterval(CountDown,1000,thermostat);\r\n \r\n function CountDown(thermostat) {\r\n\r\n // Get todays date and time\r\n var now = new Date().getTime() / 1000;\r\n\r\n // Find the distance between now an the count down date\r\n var distance = thermostats[thermostat][2] - now;\r\n\r\n var hours = Math.floor(distance / 3600);\r\n var minutes = Math.floor((distance - (hours * 3600)) / 60);\r\n var seconds = Math.floor((distance - (hours * 3600) - (minutes * 60)));\r\n\r\n document.getElementById(\"CountDown\"+thermostat).innerHTML = hours + \" h \"+ minutes + \" m \" + seconds + \" s\";\r\n\r\n if (distance < 0) {\r\n $(\"div#ThermostatTimerSettings\"+thermostat).css(\"display\",\"none\");\r\n clearInterval(interv);\r\n communicateREST(\"/PHP/ba-simple-proxy.php?url=<Fibaro HC2 IP>:<Fibaro Hc2 port>/api/devices/\"+thermostats[thermostat][0],\"GET\",\"\",RESTcallback,false);\r\n thermostats[thermostat][1] = Number(RESTresponse[\"contents\"][\"properties\"][\"targetLevel\"]);\r\n emptyObject(RESTresponse);\r\n $('input[type=range]#Temperatura'+thermostat).val(thermostats[thermostat][1]);\r\n showTemperature(thermostat);\r\n }\r\n }\r\n}", "title": "" }, { "docid": "b8e5eef50010c76d5e8e6a7ed253832e", "score": "0.53234744", "text": "handleDrink(energy) {\n // Calculate distance from this predator to the cobra\n let d = dist(this.x, this.y, energy.x, energy.y);\n // Check if the distance is less than their two radii (an overlap)\n if (d < this.radius + energy.radius) {\n // increase predator health and constrain it to its possible range\n this.health = this.maxHealth;\n this.health = constrain(this.health, 0, this.maxHealth);\n\n // double the tiger speed after each drink\n this.speed = this.energySpeed;\n\n // so the drink looses it's health and disapears once consumed\n energy.health -= energy.maxHealth;\n // Check if the energy drink is consumed and dont reset it\n if (energy.health < 10) {\n // play roar sound after each enrgy drink consumption\n tigerSound.play();\n }\n }\n\n }", "title": "" }, { "docid": "33578f27d89ecdddf039f86f70cf3b55", "score": "0.53198415", "text": "inputCharged(){\n // console.log('inputCharged', this.chargingFor);\n this.chargeAttackLeft = false;\n this.chargeAttackRight = false;\n this.chargeTime < this.chargingFor ? this.dashReset() : this.attack('charge');\n }", "title": "" }, { "docid": "761f01b8f682fb8bf4bbaca90f6fedcd", "score": "0.5317634", "text": "adicionarProdutoChiffonDress() {\n cy.get(productsElements.btnMenuDresses()).click()\n cy.get(productsElements.btnAddChiffonDress()).click()\n }", "title": "" }, { "docid": "15ac64794bffb14c74ad4a34c424369e", "score": "0.5314568", "text": "checkDrinks() {\n if (this.drinks === \"alcohol\" && this.catNum < 3) {\n this.catNum = this.catNum + 1;\n\n }\n else if (this.drinks === \"soda\" && this.catNum < 3) {\n this.catNum = this.catNum + 1;\n\n }\n\n else if (this.drinks === \"artificial\") {\n this.catNum = 2;\n\n }\n\n\n }", "title": "" }, { "docid": "f9dbc7426afe1a8958a300c52c1bd552", "score": "0.52791864", "text": "function buzz(){\n connectFactory.buzzBuzzTrial(buzzerRound);\n $rootScope.$emit(rootScopeEvents.buzzTriggered);\n }", "title": "" }, { "docid": "c3c7940c8b2312b8d2134c15dbb9f39b", "score": "0.52506655", "text": "function donateClick(e) {\n\tupdateTrophy(1); // donate10\n}", "title": "" }, { "docid": "51af2bc6b312ce2134facde774e14c59", "score": "0.5229548", "text": "function autopilot()\n{ \n if (seatCtr > 0)\n { \n // autoPickup\n // ==========\n \n var time_id1 = setInterval( function(){\n \n // to ensure successful pickup\n var ctrBefore = seatCtr;\n \n // call autoPickup\n autoPickup();\n \n if (seatCtr === 0 || seatCtr === ctrBefore)\n { \n clearInterval(time_id1);\n \n // autoDropoff\n // ===========\n var time_id2 = setInterval( function(){\n \n // to ensure successful dropoff\n var ctrBefore = seatCtr;\n \n // call autoDropoff\n autoDropoff();\n if (seatCtr === 10 || seatCtr === ctrBefore)\n { \n console.log(\"dropCtr: \"+dropCtr);\n clearInterval(time_id2);\n } \n }, 1000 ); \n \n }\n }, 1000 ); \n } \n // only autoDropoff if seats are full\n // =============================\n else if (seatCtr === 0)\n {\n var time_id2 = setInterval( function(){\n \n // to ensure successful dropoff\n var ctrBefore = seatCtr;\n \n // call autoDropoff\n autoDropoff();\n if (seatCtr === 10 || seatCtr === ctrBefore)\n { \n console.log(\"dropCtr: \"+dropCtr);\n clearInterval(time_id2);\n } \n }, 1000 ); \n }\n}", "title": "" }, { "docid": "df3ca44e96b4d656d607e7659de4a860", "score": "0.5225284", "text": "function pourCoffee() {\r\n let roast = document.getElementsByName(\"roast\");\r\n coffeeHeight = 50;\r\n sugarContent = 0;\r\n creamerContent = 0;\r\n updateCreamAndSugar();\r\n\r\n // Logic to see the color of the coffee to be filled.\r\n for (let i = 0; i < roast.length; i++) {\r\n if (roast[i].checked && roast[i].value === \"light\") {\r\n coffeeColor[0] = 162;\r\n coffeeColor[1] = 114;\r\n coffeeColor[2] = 80;\r\n } else if (roast[i].checked && roast[i].value === \"medium\") {\r\n coffeeColor[0] = 111;\r\n coffeeColor[1] = 78;\r\n coffeeColor[2] = 55;\r\n } else if (roast[i].checked && roast[i].value === \"dark\") {\r\n coffeeColor[0] = 60;\r\n coffeeColor[1] = 42;\r\n coffeeColor[2] = 30;\r\n } else if (roast[i].checked && roast[i].value === \"night\") {\r\n coffeeColor[0] = 0;\r\n coffeeColor[1] = 0;\r\n coffeeColor[2] = 0;\r\n }\r\n }\r\n\r\n // Render the coffee and enable drink options.\r\n drawMug();\r\n enableDrinkOptions();\r\n }", "title": "" }, { "docid": "a7db553ea6c038496f5d25266b90c9f9", "score": "0.5202091", "text": "function C101_KinbakuClub_RopeGroup_CassiCuffs() {\n\tif (ActorGetValue(ActorSubmission) >= 1) {\n\t\tOverridenIntroText = GetText(\"CassiCuffed\");\n\t\tActorAddInventory(\"Cuffs\");\n\t}\n\tC101_KinbakuClub_RopeGroup_PlayerSusExpression();\n}", "title": "" }, { "docid": "abb6e6b9ab9a838d0ecea15d091cf533", "score": "0.5189957", "text": "function CoffeeMachine(power) {\n\tvar waterAmount = 0;\n\tvar WATER_HEAT_CAPACITY = 4200;\n function getTimeToBoil() {\n\t\treturn waterAmount * WATER_HEAT_CAPACITY * 80 / power;\n\t}\n}", "title": "" }, { "docid": "dfe818d5f97c684ebd4c158cf21daa28", "score": "0.51882845", "text": "function setupTower(){\n //you code here\n crateManager = new CrateManager();\n}", "title": "" }, { "docid": "1758246b567cd899ac02cbc1c8793594", "score": "0.51650023", "text": "function Cricket(captain,vicecaptain,wk_Kepper,bowler) {\n this.captain = captain;\n this.vicecaptain = vicecaptain;\n this.wk_Kepper = wk_Kepper;\n this.bowler = bowler;\n this.spinnerDefind = 'aswin';// adding properties for constructor(defind)\n }", "title": "" }, { "docid": "b2edb3ad18d3c67a8beff205d43b78bd", "score": "0.5162627", "text": "function ch1scenario(){\n $('.ch1 .approbation').hide();\n $('.ch1__screen1 .btn-next').hide();\n $('.ch1__screen2 .bottle img:nth-of-type(2)').hide();\n\n // TODO: Typed dialog\n // $('.typed--ch1').typed({\n // strings: $('.typed--ch1'),\n // typeSpeed: 0\n // });\n\n // 'OK' button listener, triggers next bubble\n $('.ch1 .dialog-ok').click(function(){\n $('.ch1 .dialog').hide('slow');\n $('.ch1 .approbation').show('slow');\n $('.ch1__screen1 .btn-next').show('slow');\n });\n // 'Ready' button listener, starting mini-game\n $('.ch1__screen1 .btn-next').click(function(){\n $('.ch1 .screen').toggleClass('screen--is-visible');\n });\n\n var shakes = 0;\n $('.ch1__screen2 .bottle').click(function(){\n $('.ch1__screen2 .bottle').addClass('bottle--is-shaking');\n setTimeout(function(){\n $('.bottle--is-shaking').removeClass('bottle--is-shaking');\n }, 1000);\n shakes++;\n if (shakes>=3) {\n $('.ch1__screen2 .bottle').addClass('bottle--is-popping');\n setTimeout(function(){\n $('.ch1__screen2 .bottle img:nth-of-type(2)').show('slow');\n $('.ch1__screen2 .btn-next').css('display', 'flex');\n }, 1000);\n }\n });\n }", "title": "" }, { "docid": "5cfad731966effeab362b4bc15d17e7d", "score": "0.51550466", "text": "selectDessert3() {\n I.waitForElementLeaveDom(settings.config.helpers.Appium.platform, commonObjects.progressBar);\n //I.downScroller(foodObjects.hersheysBrownie);\n I.tap(foodObjects.hersheysBrownie);\n I.waitForElementLeaveDom(settings.config.helpers.Appium.platform, commonObjects.progressBar);\n }", "title": "" }, { "docid": "e672c9bfe8933afbabe25cef8286f9bf", "score": "0.5137969", "text": "pickUp(powerUp) {\n powerUp.pickedUp = true;\n if (powerUp.powerUpText == 'weapon') {\n this.setWeapon(powerUp.contents);\n this.playPickUpSound();\n } else if (powerUp.powerUpText == 'shield') {\n let content = powerUp.contents;\n this.health += content.health;\n if (this.health > this.maximumHealth) {\n this.health = this.maximumHealth;\n }\n this.playPickUpSound();\n }\n }", "title": "" }, { "docid": "7b191c1b1490b063fc2572182b408686", "score": "0.5123326", "text": "function cyclePower(){\n\tif(globalInfoType == \"JSON\"){\n devicesArr = getDevicesNodeJSON();\n deviceArr = getDevicesNodeJSON();\n\t}\n\n\tvar url= getURL(\"Power\", \"JSON\");\n\tvar action=\"powercycle2\";\n\tvar devQuery=\"\";\n\tif($(\"#gracefulIDCycle\").is(\":checked\")){\n\t\tvar gracefulCycle=true;\n\t}else{\n\t\tvar gracefulCycle=false;\n\t}\n\tfor(var a=0; a<devicesArr.length; a++){\n\t\tvar hostOff = devicesArr[a].DeviceName;\n\t\tvar mngtIPOff = devicesArr[a].ManagementIp;\n\t\tvar newCtrl = getControllerInfo(hostOff);\n\t\tif(PowerDeviceCon.length!=0){\n\t\t\tif(PowerDeviceCon[a].name == hostOff){\n\t\t\t\tvar devconCycle=PowerDeviceCon[a].url;\n\t\t\t}else{\n\t\t\t\tvar devconCycle=\"\";\n\t\t\t}\n\t\t}else{\n\t\t\tvar devconCycle=\"\";\n\t\t}\n\t\tif(PowerLoadImage.length!=0){\n\t\t\tif(PowerLoadImage[a].name == hostOff){\n\t\t\t\tvar loadImgCycle=PowerLoadImage[a].url;\n\t\t\t}else{\n\t\t\t\tvar loadImgCycle=\"\";\n\t\t\t}\n\t\t}else{\n\t\t\tvar loadImgCycle=\"\";\n\t\t}\n\t\tif(PowerImageCon.length!=0){\n\t\t\tif(PowerImageCon[a].name == hostOff){\n\t\t\t\tvar imgconCycle=PowerImageCon[a].url.split(\"&\");\n\t\t\t\tvar newImgconCycle=imgconCycle[0];\n\t\t\t\tvar destCycle=imgconCycle[1];\n\t\t\t}else{\n\t\t\t\tvar newImgconCycle=\"\";\n\t\t\t\tvar destCycle=\"\";\n\t\t\t}\n\t\t}else{\n\t\t\tvar newImgconCycle=\"\";\n\t\t\tvar destCycle=\"\";\n\t\t}\n\t\tif(globalInfoType=='XML'){\n devQuery += \"<DEVICES Hostname='\"+hostOff+\"' ManagementIp='\"+mngtIPOff+\"' ControllerInfo='\"+newCtrl+\"' SaveConfigPath='\"+devconCycle+\"' LoadConfigPath='\"+loadImgCycle+\"' LoadImagePath='\"+newImgconCycle+\"' Destination='\"+destCycle+\"' GracefulShutdown='\"+gracefulCycle+\"'/>\";\n }else{\n devQuery += \"'DEVICES': [{'Hostname': '\"+hostOff+\"', 'ManagementIp': '\"+mngtIPOff+\"', 'ControllerInfo': '\"+newCtrl+\"', 'SaveConfigPath': '\"+devconCycle+\"', 'LoadConfigPath': '\"+loadImgCycle+\"', 'LoadImagePath': '\"+newImgconCycle+\"', 'Destination': '\"+destCycle+\"', 'GracefulShutdown': '\"+gracefulCycle+\"'}]\";\n }\n\t}\n\tfor(var a=0; a<globalMAINCONFIG.length;a++){\n\t\tif(globalMAINCONFIG[a].MAINCONFIG[0].UserName==globalUserName){\n\t\t\tvar email = false;\n\t\t\tvar newUser = \"\";\n\t\t}else{\n\t\t\tvar email= true;\n\t\t\tvar newUser = UserName;\n\t\t}\n\t}\n\tif(globalInfoType=='XML'){\n var query = \"<MAINCONFIG ResourceId='\"+window['variable' + dynamicResourceId[pageCanvas]]+\"' ConfigName='\"+Name+\"' User='\"+globalUserName+\"' Delay='5' Email='\"+email+\"' NewUser='\"+newUser+\"'>\"+devQuery+\"</MAINCONFIG>\";\n }else{\n var query = \"{'MAINCONFIG': [{'ResourceId': '\"+window['variable' + dynamicResourceId[pageCanvas]]+\"', 'ConfigName': '\"+Name+\"', 'User': '\"+globalUserName+\"', 'Delay': '5', 'Email': '\"+email+\"', 'newUser': '\"+newUser+\"', \"+devQuery+\"}]}\";\n }\n\t\n\t$.ajax({\n url: url,\n\t\tdata: {\n\t\t\t\"action\": action,\n\t\t\t\"query\": query,\n\t\t},\n dataType: 'html',\n\t\tmethod: 'POST',\n\t\tproccessData: false,\n\t\tasync:false,\n success: function(data) {\n\t\t\tvar dat = data.replace(/'/g,'\"');\n\t\t\tvar data = $.parseJSON(dat);\n\t\t\tvar result = $.trim(data.RESULT[0].Result);\n\t\t\tif(result != 1){\n\t\t\t\t$(\"#powerAlertDiv\").dialog({\n\t\t\t\t\tmodal: true,\n\t\t\t\t\twidth: 300,\n\t\t\t\t\tautoResize: true,\n\t\t\t\t\tmaxHeight: \"auto\",\n\t\t\t\t\tbuttons: {\n\t\t\t\t\t\t'OK': function(){$(this).dialog('destroy');},\n\t\t\t\t\t\t'Cancel': function(){$(this).dialog('destroy');}\n\t\t\t\t\t}\n\t\t\t\t});\n\t\t\t\t$(\"#powerAlertDiv\").text(result);\n\t\t\t}else{\n\t\t\t\tshowPower();\n\t\t\t\t$(\"#deviceMenuPopUp\").dialog('destroy');\n\t\t\t}\n\t\t}\n\t});\n\n\n}", "title": "" }, { "docid": "e789c2f67fe412dcadad61d3ee42410a", "score": "0.51114595", "text": "if(this.props.onDrinkChange){\n const { glasses, toppings } = this;\n const { glassPos, toppingPos } = this.state;\n const drink = {\n glass: glasses[glassPos % glasses.length],\n liquid: '',\n topping: toppings[toppingPos % toppings.length]\n }\n this.props.onDrinkChange(drink);\n }", "title": "" }, { "docid": "7779fcc91c3dca1524b394b837b3d30f", "score": "0.5105607", "text": "function runMotorATC(){\r\n\r\n if(shade != 'FIXED SHADE'){\r\n motor = document.getElementById(\"motor_clutch\").value;\r\n control_system = document.getElementById(\"control_system\").value;\r\n }\r\n else{\r\n motor = null;\r\n control_system = null;\r\n }\r\n\r\n if(control_system == 'Motor' && selectedMotor != motor && visitedAdd == false){\r\n show_motor();\r\n selectedMotor = document.getElementById('motor_clutch').value;\r\n }\r\n else{\r\n addToCart();\r\n }\r\n\r\n}", "title": "" }, { "docid": "092673aa28310043226968e93965eb06", "score": "0.50711954", "text": "function getCocktail() {\n // variable for cocktailDB URL\n var requestCocktail = 'https://www.thecocktaildb.com/api/json/v1/1/random.php';\n\n // ajax call for drink data\n $.ajax({\n url: requestCocktail,\n method: \"GET\",\n }).then(function (response) {\n // run display drink function\n displayDrink(response);\n });\n }", "title": "" }, { "docid": "012caab845f125fa2cbad795a1558b81", "score": "0.5064828", "text": "function C101_KinbakuClub_RopeGroup_CassiChangeTechnique() {\n\tC101_KinbakuClub_RopeGroup_Random = Math.floor(Math.random() * 2);\n\tif (C101_KinbakuClub_RopeGroup_Random == 0 && C101_KinbakuClub_RopeGroup_fingerinsertion) {\n\t\tif (PlayerHasLockedInventory(\"VibratingEgg\")) C101_KinbakuClub_RopeGroup_Options = 4;\n\t\telse C101_KinbakuClub_RopeGroup_Options = 3;\n\t\tC101_KinbakuClub_RopeGroup_Random = Math.floor(Math.random() * C101_KinbakuClub_RopeGroup_Options);\n\t\tif (C101_KinbakuClub_RopeGroup_LastFingerTechnique == C101_KinbakuClub_RopeGroup_Random) C101_KinbakuClub_RopeGroup_CassiChangeTechnique();\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 0) OverridenIntroText = GetText(\"FingerInOut\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 1) OverridenIntroText = GetText(\"FingerPressUp\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 2) OverridenIntroText = GetText(\"FingerComeHither\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random >= 3) OverridenIntroText = GetText(\"FingerVibrator\");\n\t\tC101_KinbakuClub_RopeGroup_LastFingerTechnique = C101_KinbakuClub_RopeGroup_Random;\n\t} else {\n\t\tC101_KinbakuClub_RopeGroup_Random = Math.floor(Math.random() * 7);\n\t\tif (C101_KinbakuClub_RopeGroup_LastTongueTechnique == C101_KinbakuClub_RopeGroup_Random) C101_KinbakuClub_RopeGroup_CassiChangeTechnique();\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 0) OverridenIntroText = GetText(\"ChangeToLickUp\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 1) OverridenIntroText = GetText(\"ChangeToCircular\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 2) OverridenIntroText = GetText(\"ChangeToABC\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 3) OverridenIntroText = GetText(\"ChangeToElectricslide\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 4) OverridenIntroText = GetText(\"ChangeToSuck\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 5) OverridenIntroText = GetText(\"ChangeToCircularFlick\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 6) OverridenIntroText = GetText(\"ChangeToHardLick\");\n\t\tif (C101_KinbakuClub_RopeGroup_Random == 7) OverridenIntroText = GetText(\"ChangeToNibble\");\n\t\tC101_KinbakuClub_RopeGroup_LastTongueTechnique = C101_KinbakuClub_RopeGroup_Random;\n\t}\n}", "title": "" }, { "docid": "98686ed0547287f4d708d120d612598f", "score": "0.5060528", "text": "if(this.props.onDrinkChange){\n const { glasses, toppings } = this;\n const { glassPos, toppingPos } = state;\n const drink = {\n glass: glasses[glassPos % glasses.length],\n liquid: '',\n topping: toppings[toppingPos % toppings.length]\n }\n this.props.onDrinkChange(drink);\n }", "title": "" }, { "docid": "c72a07889e290e03dc0c32c1286a5b0b", "score": "0.5047956", "text": "function rentADrone() {\n onDroneAction();\n }", "title": "" }, { "docid": "263ace137324e6583bc4b81bb935d91d", "score": "0.5043026", "text": "function energyBoost(player, drink) {\n\t\tdrink.kill();\n\t\tdrinkmusic.play();\n\t\tif(playerSpeed == 150) {\n\t\tplayerSpeed = playerSpeed * 2;\n\n\t\tthis.time.events.add(2000, function() {\n\t\t\tplayerSpeed = playerSpeed * 0.5;\n\t\t});\n\t\t}\n\t}", "title": "" }, { "docid": "7ca491b822de4a41b57ae934b658b106", "score": "0.5038185", "text": "function truckStop(){\n truckSpeed = 10;\n}", "title": "" }, { "docid": "036cb2778ee4f3f5e8d3f9094632ccfd", "score": "0.5031902", "text": "function Coffee(type, ounces) {\r\n this.type = type;\r\n this.ounces = ounces;\r\n\r\n if (ounces == 0.2) {\r\n this.size = 'small';\r\n } else if (ounces == 0.4) {\r\n this.size = 'medium';\r\n } else if (ounces == 0.6) {\r\n this.size == 'large';\r\n }\r\n\r\n //Save the HTML elements from the coffee drink card in a variable\r\n let coffeeDrinkCard = document.getElementById('coffee-drink-card');\r\n\r\n //Erase the text previously displayed in the coffee drink card\r\n coffeeDrinkCard.innerHTML = '';\r\n\r\n this.getString = () => {\r\n coffeeDrinkCard.innerHTML = `You have ordered a ${this.size} <span style=\"text-transform: capitalize;\">${this.type}</span> coffee.<br>Enjoy it!`;\r\n };\r\n}", "title": "" }, { "docid": "246d3c33f464389978d068079080a243", "score": "0.502594", "text": "static dexter_user_interface_cb(vals){\n //out(\"dui_cb got clicked_button_value: \" + vals.clicked_button_value +\n // \" which has val: \" + vals[vals.clicked_button_value])\n let dui_instance = dui2.show_window_elt_id_to_dui_instance(vals.show_window_elt_id)\n //inspect(dui2.dui_instance_under_mouse())\n if(vals.clicked_button_value == \"close_button\"){\n let inst_index = dui2.instances.indexOf(dui_instance)\n if(inst_index == -1) { shouldnt(\"in dexter_user_interface_cb with close_button\") }\n else { dui2.instances.splice(inst_index, 1) } //cut out the instance from the instances list\n return\n }\n else if([\"xy_2d_slider\", \"z_slider\"].includes(vals.clicked_button_value)){\n let cir_xy_obj = vals.xy_2d_slider\n //out(JSON.stringify(cir_xy_obj))\n let x = parseFloat(cir_xy_obj.cx)\n x = dui_instance.x_px_to_meters(x)\n let y = parseFloat(cir_xy_obj.cy) //a num between 0 and 300\n //out(\"got cy of: \" + y)\n y = dui_instance.y_px_to_meters(y)\n let z = vals.z_slider\n let [inner_r, outer_r, outer_circle_center_xy] = Kin.xy_donut_slice_approx(z, dui_instance.direction)\n let new_xy_radius = Math.hypot(x, y)\n if((new_xy_radius < inner_r) ||\n (new_xy_radius > outer_r)){ //the new x and y are out of range. do nothing\n //don't print warning message, just refresh display by calling update_all way below\n }\n else {\n let xyz = [x, y, z]\n try {\n let j_angles = Kin.xyz_to_J_angles(xyz, dui_instance.direction) //returns just 5 angles\n //out(\"j_angles \" + j_angles)\n if(j_angles.length === 5) { j_angles.push(vals.j6_angle_num) }\n if(j_angles.length === 6) { j_angles.push(vals.j7_angle_num) }\n dui_instance.set_maj_angles(j_angles)\n }\n catch(err) { //with the above test for new_xy_radius, this catch should never hit.\n if(vals.clicked_button_value === \"z_slider\"){\n warning(\"Sorry, Dexter can't go to Z position: \" + z +\n \" given X position: \" + x +\n \" and Y position: \" + y)\n }\n else {\n warning(\"Sorry, Dexter can't go to X position: \" + x +\n \" and/or Y position: \" + y +\n \" given Z position: \" + z)\n }\n return\n }\n }\n //dui2.update_xyz_nums(vals.show_window_elt_id, xyz)\n //dui2.update_range_and_angle_nums(vals.show_window_elt_id, maj_angles)\n }\n else if(vals.clicked_button_value.endsWith(\"_num\") && //x_num, y_num, z_num the typein boxes\n !vals.clicked_button_value.endsWith(\"_angle_num\")){ //an x,y,or z number input\n let x = vals.x_num\n let y = vals.y_num\n let z = vals.z_num\n let xyz = [x, y, z]\n let [inner_r, outer_r, outer_circle_center_xy] = Kin.xy_donut_slice_approx(z, dui_instance.direction)\n let new_xy_radius = Math.hypot(x, y)\n if((new_xy_radius < inner_r) ||\n (new_xy_radius > outer_r)){ //the new x and y are out of range. do nothing\n //don't print warning message, just refresh display by calling update_all way below\n }\n else {\n try {\n let j_angles = Kin.xyz_to_J_angles(xyz, dui_instance.direction) //returns just 5 angles\n if(j_angles.length === 5) { j_angles.push(vals.j6_angle_num) }\n if(j_angles.length === 6) { j_angles.push(vals.j7_angle_num) }\n dui_instance.set_maj_angles(j_angles)\n }\n catch(err) {\n let x_y_or_z = vals.clicked_button_value[0]\n let other_dimensions\n if(x_y_or_z == \"x\") { other_dimensions = \"y and z\" }\n else if(x_y_or_z == \"y\") { other_dimensions = \"x and z\" }\n else if(x_y_or_z == \"z\") { other_dimensions = \"x and y\" }\n let val = vals[vals.clicked_button_value]\n warning(\"Sorry, Dexter can't go to \" + x_y_or_z + \" position: \" + val +\n \" given the positions of \" + other_dimensions + \".\")\n return\n }\n }\n //dui2.update_xyz_circle(vals.show_window_elt_id, xyz)\n //dui2.update_range_and_angle_nums(vals.show_window_elt_id, maj_angles)\n }\n else if(vals.clicked_button_value == \"ready\"){\n dui_instance.set_maj_angles([0, 0, 90, 0, 0, 0, 0])\n }\n else if(vals.clicked_button_value == \"home\"){\n dui_instance.set_maj_angles([0, 0, 0, 0, 0, 0, 0])\n }\n else if(vals.clicked_button_value == \"go_to_start\"){\n let continue_running = dui2.go_to_start_button_click_action(dui_instance)\n if(!continue_running) { return }\n }\n else if(vals.clicked_button_value == \"step_backward\"){\n let continue_running = dui2.step_backward_button_click_action(dui_instance)\n if(!continue_running) { return }\n }\n else if(vals.clicked_button_value == \"step_forward\"){\n let continue_running = dui2.step_forward_button_click_action(dui_instance)\n if(!continue_running) { return } //either a bad instruction or not a maj or mt instruction so stop processing here\n /* let full_src = Editor.get_javascript()\n let start_pos = Editor.selection_start()\n let start_char = full_src[start_pos]\n if((start_char == \"\\n\") && (start_pos > 0)) { //treat clicking on the end of a line, as if\n //its really IN the line, not the next line or in between\n start_pos -= 1\n start_char = full_src[start_pos]\n }\n if(start_pos == (full_src.length - 1)) { return } //at end of buffer, so no expression\n let prev_newline_pos = full_src.lastIndexOf(\"\\n\", start_pos)\n if (prev_newline_pos == -1) { prev_newline_pos = 0 } //an aproximation! start_pos is on first line\n let next_newline_pos = full_src.indexOf(\"\\n\", start_pos)\n let open_paren_pos = full_src.indexOf(\"(\", prev_newline_pos)\n if(open_paren_pos === -1) { return } //no instruction\n if(open_paren_pos > next_newline_pos) { return } //no instr starting on the same line as prev_newline_pos\n let expr_start_pos = Editor.skip_forward_over_whitespace(full_src, prev_newline_pos)\n\n let close_paren_pos = Editor.find_matching_delimiter(full_src, open_paren_pos)\n if(!close_paren_pos) { return } //no close paren so no expression.\n let maj_pos = full_src.indexOf(\"move_all_joints(\", expr_start_pos)\n if(maj_pos > next_newline_pos) { maj_pos = -1 } //too far away\n let mt_pos = full_src.indexOf(\"move_to(\", expr_start_pos)\n if(mt_pos > next_newline_pos) { mt_pos = -1 } //too far away\n\n let instr_type = null //means no valid instruction\n if(maj_pos == -1) {\n if(mt_pos > -1) { instr_type = \"mt\" }\n }\n else { instr_type = \"maj\" }\n if(!instr_type) { return } //didn't get an maj or mt instruction\n else { //good to go!\n let instr_src = full_src.substring(expr_start_pos, close_paren_pos + 1)\n let instr_obj\n let angles\n try{\n instr_obj = eval(instr_src)\n }\n catch(err) { return } //invalid instruction so just ignore it\n if((instr_obj instanceof Instruction.Dexter.move_all_joints) ||\n (instr_obj instanceof Instruction.Dexter.pid_move_all_joints)){\n angles = instr_obj.array_of_angles\n }\n else if ((instr_obj instanceof Instruction.Dexter.move_to) ||\n (instr_obj instanceof Instruction.Dexter.pid_move_to)) {\n angles = Kin.xyz_to_J_angles(instr_obj.xyz, instr_obj.J5_direction,\n instr_obj.config, instr_obj.workspace_pos)\n }\n else{ return } //not one of the instructtion we need\n Editor.select_javascript(expr_start_pos, close_paren_pos + 1)\n dui_instance.set_maj_angles(angles)\n */\n }\n\n else if(vals.clicked_button_value == \"run_forward\"){\n let continue_running\n for(var i = 0; i < 100000; i++){\n continue_running = dui2.step_forward_button_click_action(dui_instance) //dui2.run_forward_button_click_action(dui_instance)\n if(!continue_running) { return } //error in processing next instr, perhaps syntactic, perhaps already did last instruction\n else if (continue_running == \"already_inserted_instruction\"){ //instruction was a valid instr but not a move instruction\n }\n else { //got a move instruction, keep going to bottom of this method for the instruction selection and insertion\n dui_instance.update_all(dui_instance.should_point_down) // do update_all before move_all_joints because update_all may modify ui2_instance.maj_angles if the direction_checkbox is checked\n let instr = Dexter.pid_move_all_joints(dui_instance.maj_angles)\n Job.insert_instruction(instr, {job: vals.job_name, offset: \"end\"})\n }\n }\n //let show_win_elt = window[vals.show_window_elt_id]\n //show_win_elt.focus() //so that is_dui_the_focus will work after setting the selection.\n //is_dui_the_focus needed by dui_instruction_callback\n return\n }\n else if(vals.clicked_button_value.endsWith(\"_range\")){ //a joint slider\n dui_instance.set_maj_angles([vals.j1_range, vals.j2_range, vals.j3_range, vals.j4_range,\n vals.j5_range, vals.j6_range, vals.j7_range])\n\n }\n else if(vals.clicked_button_value.endsWith(\"_angle_num\")){ /// the num input for a joint angle\n dui_instance.set_maj_angles([vals.j1_angle_num, vals.j2_angle_num, vals.j3_angle_num, vals.j4_angle_num,\n vals.j5_angle_num, vals.j6_angle_num, vals.j7_angle_num])\n }\n else if(vals.clicked_button_value == \"direction_checkbox\"){\n dui_instance.should_point_down = vals.direction_checkbox\n dui_instance.set_maj_angles([vals.j1_angle_num, vals.j2_angle_num, vals.j3_angle_num, vals.j4_angle_num,\n vals.j5_angle_num, vals.j6_angle_num, vals.j7_angle_num]) //no actual change here, but just to ensure consistency\n }\n else if(vals.clicked_button_value == \"dui_instr_type_id\"){\n dui_instance.update_editor_maybe()\n }\n else if (vals.clicked_button_value == \"insert_instruction\"){\n let full_src = Editor.get_javascript()\n let start_pos = Editor.selection_start()\n let start_char = full_src[start_pos]\n let end_pos = Editor.selection_end()\n let has_selection = (start_pos !== end_pos)\n let prev_newline_pos = full_src.lastIndexOf(\"\\n\", start_pos)\n let prefix_sans_comma\n let needs_comma_before_insert = dui2.needs_comma_before_insert(full_src, end_pos)\n\n let end_char = full_src[end_pos]\n let end_char_is_comma = (end_char == \",\")\n let prev_end_char = ((end_pos == 0) ? null : full_src[end_pos - 1])\n let first_back_non_whitespace_from_start_pos = Editor.backup_over_whitespace(full_src, start_pos - 1)\n\n let insert_before_start_pos\n if(has_selection) { insert_before_start_pos = false }\n else if(start_pos == 0) { insert_before_start_pos = true }\n else if(start_char == \"\\n\") { insert_before_start_pos = false }\n else {\n if(first_back_non_whitespace_from_start_pos == null) { //no whitespace before start_pos, but not at 0\n insert_before_start_pos = false\n }\n else if(start_char == \"\\n\") { insert_before_start_pos = false }\n else if (first_back_non_whitespace_from_start_pos < prev_newline_pos){ //between start_pos and the\n //back newline, there is only whitespace, so we've clicked on the same line as an item,\n //but before its actual text, so we want to insert before start_pos on that same line.\n insert_before_start_pos = true\n }\n else { insert_before_start_pos = false }\n }\n if(insert_before_start_pos) {\n if(start_pos == 0) {//leave sel where it is\n Editor.select_javascript(0, 0)\n needs_comma_before_insert = false\n prefix_sans_comma = \"\\n \"\n }\n else {\n //let first_back_non_whitespace_char = full_src[first_back_non_whitespace_from_start_pos]\n Editor.select_javascript(prev_newline_pos, prev_newline_pos)\n needs_comma_before_insert = false\n prefix_sans_comma = \"\\n \"\n }\n }\n else if(end_char_is_comma) {\n Editor.select_javascript(end_pos + 1, end_pos + 1)\n needs_comma_before_insert = false\n prefix_sans_comma = \"\\n \"\n }\n else if(prev_end_char == \"[\") { //end_char is probably just after the [ that begins the do_list\n needs_comma_before_insert = false\n Editor.select_javascript(end_pos, end_pos)\n prefix_sans_comma = \"\\n \"\n }\n else if(prev_end_char == \",\") { //end_char is probably just after the [ that begins the do_list\n needs_comma_before_insert = false\n Editor.select_javascript(end_pos, end_pos)\n prefix_sans_comma = \"\\n \"\n }\n else {\n Editor.select_javascript(end_pos, end_pos)\n needs_comma_before_insert = true\n prefix_sans_comma = \"\\n \"\n }\n\n let prefix = (needs_comma_before_insert ? \",\" : \"\") + prefix_sans_comma\n let instr_src = dui_instance.make_instruction_source()\n let on_last_instr = dui2.is_on_last_instruction(full_src, end_pos)\n let total_insert = prefix + instr_src + (on_last_instr ? \"\" : \",\")\n Editor.insert(total_insert)\n //let new_start_pos = end_pos + prefix.length //+ (on_last_instr? 0 : 1)\n //let new_end_pos = new_start_pos + instr_src.length\n full_src = Editor.get_javascript()\n let new_start_open_paren_pos = //get past comma on prev line if any and to new first open paran\n full_src.indexOf(\"(\", end_pos)\n let new_start_pos = Editor.backup_to_whitespace(full_src, new_start_open_paren_pos)\n let new_end_pos = Editor.find_matching_delimiter(full_src, new_start_open_paren_pos) + 1\n Editor.select_javascript(new_start_pos, new_end_pos)\n return\n }\n else if (vals.clicked_button_value == \"insert_job\"){\n let job_prefix_src =\n`\\nnew Job({\n name: \"my_job\",\n do_list: [\n `\n let instr_src = dui_instance.make_instruction_source()\n let job_src = job_prefix_src + instr_src + '\\n]})\\n'\n let cur_pos = Editor.selection_start()\n Editor.insert(job_src)\n let inst_start_pos = cur_pos + job_prefix_src.length\n let inst_end_pos = inst_start_pos + instr_src.length\n //end of job def, now back up to start of where next instruction should be inserted.\n Editor.select_javascript(inst_start_pos, inst_end_pos)\n return\n }\n else if (vals.clicked_button_value == \"close_button\"){\n let job_instance = Job[vals.job_name]\n if(job_instance){\n if(job_instance.is_active()){\n job_instance.stop_for_reason(\"interrupted\", \"User closed dui show_window.\")\n setTimeout(function() {\n job_instance.undefine_job()\n }, 200)\n }\n else {\n job_instance.undefine_job()\n }\n }\n return\n }\n dui_instance.update_all(dui_instance.should_point_down) // do update_all before move_all_joints because update_all may modify ui2_instance.maj_angles if the direction_checkbox is checked\n let instr = Dexter.pid_move_all_joints(dui_instance.maj_angles)\n Job.insert_instruction(instr, {job: vals.job_name, offset: \"end\"})\n //out(\"inserted instr: \" + instr)\n}", "title": "" }, { "docid": "6c3c4bee8dced4831be3c1be335a608b", "score": "0.50230736", "text": "function autoWatering()\n{\n if(shouldAutoWatering)\n {\n let lowerLimit = 500;//assume the plan needs moisture over 500\n currentMoistureObject = moistureSensorData[moistureSensorData.length-1];\n currentMoisture = currentMoistureObject[\"Moisture\"]\n if (currentMoisture < lowerLimit)\n {\n motorStart();\n setTimeout(motorEnd, 2000);\n }\n else{\n motorEnd();\n }\n }\n}", "title": "" }, { "docid": "52d1484161d6f04a2fa0c7899d57b3d8", "score": "0.50175107", "text": "function addCream() {\r\n let text = document.getElementById(\"dynamictext\");\r\n let choiceText = \"\";\r\n\r\n if (coffeeColor[0] !== 0 && coffeeHeight > 25) {\r\n coffeeColor[0] += 10;\r\n coffeeColor[1] += 10;\r\n coffeeColor[2] += 10;\r\n creamerContent += 1;\r\n\r\n // Increase amount if less than 50.\r\n if (coffeeHeight < 50) {\r\n coffeeHeight += 5;\r\n }\r\n\r\n // Render the new mug.\r\n drawMug();\r\n } else if (coffeeColor[0] === 0 && coffeeHeight > 25) { // Special 'night' coffee case.\r\n let choice = Math.floor(Math.random() * 3);\r\n\r\n // Logic for which text to be diplayed.\r\n if (choice === 0) {\r\n choiceText = \"Night is eternal\";\r\n } else if (choice === 1) {\r\n choiceText = \"This creamer is almost as dark as my soul\";\r\n } else {\r\n choiceText = \"You can't change who I am!\";\r\n }\r\n }\r\n // Either change text to a random set, or reset it to nothing.\r\n text.innerHTML = choiceText;\r\n // Update display.\r\n updateCreamAndSugar();\r\n }", "title": "" }, { "docid": "885125338056be0f3b365b155ef2a8e0", "score": "0.501735", "text": "function ClickWashOil(celector) {\n $(\".wash-oil\").removeClass(\"label-txt-selected\");\n $(\".row-wash-oil-tr\").removeClass(\"disable-item\");\n $(\".row-wash-oil-tr\").addClass(\"disable-item\");\n celector.removeClass(\"disable-item\");\n celector.find(\"label\").addClass(\"label-txt-selected\");\n celector.find(\"input\").prop(\"checked\", true);\n washOilPrise = 0;\n washOilTime = 0;\n washOilPrise = celector.find(\"input\").val();\n washOilTime = celector.find(\"input\").data(\"time\");\n var sumP = +washOilPrise + +razMasloPrise;\n var sumT = +washOilTime + +razMasloTime;\n SumPrice();\n $(\"#wash-services_price-value\").html(\n sumP.toLocaleString(\"ru\") + \"<span>грн</span>\"\n );\n if (sumT > 0) {\n $(\"#washOilTime\").parent().css(\"display\", \"flex\");\n $(\"#washOilTime\").html(sumT);\n } else {\n $(\"#washOilTime\").parent().css(\"display\", \"none\");\n }\n var select = $(\".row-wash\");\n selectNewOil(select, sumP);\n }", "title": "" }, { "docid": "14014bd9702f0eae4d3690e37c488d98", "score": "0.5010081", "text": "suitPicked(suit){\r\n this.human.suitPicked(suit)\r\n this.completeMyTurn();\r\n }", "title": "" }, { "docid": "fd63d6f7075afc2824b56dc2ea287fc2", "score": "0.50098205", "text": "attack() {\n let input = this.aspect.get(Component.Input);\n let armed = this.aspect.get(Component.Armed);\n let prevAttacking = input.attack;\n // start charging if haven't\n if (!prevAttacking) {\n input.attack = true;\n return;\n }\n // if charging and ready to swing, release to swing\n if (armed.state == Weapon.SwingState.ChargeReady) {\n input.attack = false;\n return;\n }\n // if charging and not ready to swing, keep charging\n input.attack = true;\n }", "title": "" }, { "docid": "a756df7489d215541ac55f2a68869d8a", "score": "0.49941617", "text": "function C101_KinbakuClub_RopeGroup_PantiesCut(CassiAction) {\n\tC101_KinbakuClub_RopeGroup_FullyExposed = true;\n\tC101_KinbakuClub_RopeGroup_PlayerPose = \"SusPlr_LookDownLeft\";\n\tif (CassiAction == 1) C101_KinbakuClub_RopeGroup_ToBeChasteAgain = true;\n\tif (CassiAction == 2) {\n\t\tC101_KinbakuClub_RopeGroup_TsuriFrogTied = true;\n\t\tCurrentTime = CurrentTime + 60000;\n\t}\n}", "title": "" }, { "docid": "9d6e615d6bf096dbc658ad2abb60e2eb", "score": "0.4990147", "text": "function countDown() {\n let hour = hours.value;\n let minute = minutes.value;\n let second = seconds.value;\n let count = new Count(hour, minute, second, compte);\n count.getStart();\n}", "title": "" }, { "docid": "6d61f61bac759a02cadb107dcf3b5454", "score": "0.49868166", "text": "function compute(levelAsk, directionAsk) {\n\n var cage_1 = cage1.counterStep(levelAsk, directionAsk);\n console.log(\"Step Cage1 :\" + cage_1);\n var cage_2 = cage2.counterStep(levelAsk, directionAsk);\n console.log(\"Step Cage2 :\" + cage_2);\n battery_compute_BestTimingCage(cage_1, cage_2);\n\n if (cage_1 < cage_2 && directionAsk === \"up\") {\n if (cage1.levelActual < levelAsk) {\n cage1.listUp.push(levelAsk);\n console.log(cage1.listUp);\n cage1.move();\n } else if (cage1.levelActual > levelAsk) {\n cage1.listDown.push(levelAsk);\n console.log(\"lisDown cage1 : \" + cage1.listDown);\n cage1.move();\n } else {\n cage1.direction = \"idle\";\n cage1.open_door();\n }\n\n\n\n\n } else if (cage_1 < cage_2 && directionAsk === \"down\") {\n if (cage1.levelActual < levelAsk) {\n cage1.listUp.push(levelAsk);\n console.log(cage1.listUp);\n cage1.move();\n } else if (cage1.levelActual > levelAsk) {\n cage1.listDown.push(levelAsk);\n console.log(\"lisDown cage1 : \" + cage1.listDown);\n cage1.move();\n } else {\n cage1.direction = \"idle\";\n cage1.open_door();\n }\n cage1.move();\n } else if (cage_2 <= cage_1 && directionAsk === \"up\") {\n if (cage2.levelActual < levelAsk) {\n cage2.listUp.push(levelAsk);\n console.log(cage2.listUp);\n cage2.move();\n } else if (cage1.levelActual > levelAsk) {\n cage2.listDown.push(levelAsk);\n console.log(\"lisDown cage1 : \" + cage2.listDown);\n cage2.move();\n } else {\n cage2.direction = \"idle\";\n cage2.open_door();\n }\n cage2.move();\n\n\n } else if (cage_2 <= cage_1 && directionAsk === \"down\") {\n if (cage2.levelActual < levelAsk) {\n cage2.listUp.push(levelAsk);\n console.log(cage2.listUp);\n cage2.move();\n } else if (cage1.levelActual > levelAsk) {\n cage2.listDown.push(levelAsk);\n console.log(\"lisDown cage1 : \" + cage2.listDown);\n cage2.move();\n } else {\n cage2.direction = \"idle\";\n cage2.open_door();\n }\n\n }\n\n\n}", "title": "" }, { "docid": "22fd82006769dc1e834a01ec27af7a83", "score": "0.4985842", "text": "function beeHIt(){\n \n if (!ShieldP1){\n ReduceMana();\n BeecolliderActive = false;\n this.time.addEvent({\n delay: 500,\n callback: ()=>{\n BeecolliderActive = true;\n },\n loop: false\n });\n }\n }", "title": "" }, { "docid": "b3bada34bde02129e80f8307b9de446d", "score": "0.49741703", "text": "function onDrugDtart(evnt) {\r\n appendStatus(\"Drug'n'drop started. Page is going to be drugged: \" + evnt.dragindex)\r\n}", "title": "" }, { "docid": "fd333fa7e78e4e6e065bd6de525836e7", "score": "0.49608356", "text": "function danceHustle() {\n let timeoutId;\n // Start Dance (Hustle)\n // STEP 1: 4 count backward\n moveBackwards(4);\n // STEP 2: 4 count forward\n timeoutId = window.setTimeout(() => moveForwards(4), 5000);\n // STEP 3: spin left 4 count\n timeoutId = window.setTimeout(() => turnLeft(4), 10000);\n // TODO: add a function or step to *clap*\n // STEP 4: spin right 4 count\n timeoutId = window.setTimeout(() => turnRight(4), 15000);\n // \tSTEP 5B: Turn left and head down 1 count\n timeoutId = window.setTimeout(() => discoLeft(1), 20000);\n // \tSTEP 5A: Turn right 90deg and head up 1 countt\n timeoutId = window.setTimeout(() => discoRight(1), 22000);\n // STEP 6: Spin 8 Counts land facing 90 to left. maybe flash led colors while spinnig.\n timeoutId = window.setTimeout(() => turnLeft(8), 24000);\n // End Dance (Hustle)\n\n // *clap*\n // STEP 5: REPEAT FOR 8 COUNTS:\n }", "title": "" }, { "docid": "7544c350cca46337ac2a72aa49e31d5a", "score": "0.49495137", "text": "function adjustThermometer(mainTemp){\n \n\n if(mainTemp > 99) // display message for out of range temp > 100\n {\n document.querySelector('.current-temp h1').innerText = \"Temp > 100\"+ \"°\"\n positiveBar.style.width = 0 \n document.querySelector('#myProgress').style.backgroundColor = 'rgba(255, 48, 33, 0.5)'\n } \n else if(mainTemp < 1) // display message for out of range temp < 0\n {\n document.querySelector('.current-temp h1').innerText = \"Temp < 0\"+ \"°\"\n positiveBar.style.width = 0\n document.querySelector('#myProgress').style.backgroundColor = 'rgba(63, 110, 252)'\n }\n else if(mainTemp > 0 && mainTemp > width) // increment thermometer\n { \n incFunc = setInterval(function(){incrementThermometer(mainTemp)}, 25)\n }\n else // decrement thermometer\n {\n decFunc = setInterval(function(){decrementThermometer(mainTemp)}, 25)\n }\n\n}", "title": "" }, { "docid": "e73cea490442fea50d9025c9a34b49fc", "score": "0.4934543", "text": "function processCategoryDrink(drinkChoice) {\n // Getting options by category\n var drinkURL =\n \"https://www.thecocktaildb.com/api/json/v1/1/filter.php?c=\" + drinkChoice;\n $.ajax({\n url: drinkURL,\n method: \"GET\",\n }).then(function (response) {\n // Selecting a random drink from within the category\n var drinkCount = response.drinks.length;\n var drinkPick = Math.floor(Math.random() * drinkCount);\n var drinkRand = response.drinks[drinkPick].idDrink;\n // URL for specific drink\n var newDrinkURL =\n \"https://www.thecocktaildb.com/api/json/v1/1/lookup.php?i=\" + drinkRand;\n // Function call to get the specific drink\n drinkAjax(newDrinkURL);\n });\n\n }", "title": "" }, { "docid": "fab13cf0eff797f01d5b01f8c16291ee", "score": "0.49334764", "text": "function C101_KinbakuClub_RopeGroup_CassiLegTie(PlayerAction) {\n\tif (ActorGetValue(ActorLove) <= 1) {\n\t\tC101_KinbakuClub_RopeGroup_TsuriFrogTied = true;\n\t\tif (PlayerAction == 1) OverridenIntroText = GetText(\"CassiLegTieA\");\n\t\tif (PlayerAction == 2) OverridenIntroText = GetText(\"CassiLegTieB\");\n\t\tif (PlayerAction == 3) OverridenIntroText = GetText(\"CassiLegTieC\");\n\t\tif (PlayerAction == 4) OverridenIntroText = GetText(\"CassiLegTieD\");\n\t\tif (PlayerAction == 5) OverridenIntroText = GetText(\"CassiLegTieE\");\n\t\tif (PlayerAction == 6) OverridenIntroText = GetText(\"CassiLegTieF\");\n\t\tCurrentTime = CurrentTime + 60000;\n\t}\n\tif (!C101_KinbakuClub_RopeGroup_FullyExposed) {\n\t\tC101_KinbakuClub_RopeGroup_CurrentStage = 673;\n\t\tC101_KinbakuClub_RopeGroup_PlayerPose = \"\";\n\t} else C101_KinbakuClub_RopeGroup_PlayerPose = \"SusPlr_LookDownLeft\";\n}", "title": "" }, { "docid": "b124695fab670a3723bd33f022d6f9e7", "score": "0.4927906", "text": "function processRandDrink() {\n var drinkURL =\n \"https://www.thecocktaildb.com/api/json/v1/1/random.php\"\n drinkAjax(drinkURL);\n }", "title": "" }, { "docid": "54eb6b3a4d670680105e15d56e170779", "score": "0.49247006", "text": "function buyChisel(objKey) {\n let chiselElem = shopUpgradesObj[objKey]\n if (cheese >= chiselElem.price) {\n chiselElem.quantity++;\n cheese -= chiselElem.price;\n chiselElem.price += 50;\n multiplied += chiselElem.multiplier;\n drawInfoUpgrades();\n drawInfoWindow();\n }\n}", "title": "" }, { "docid": "7fa3d3273b99a212f24f7d8583e326a4", "score": "0.49246648", "text": "function coolDown(currentRunTimes) {\n restartStopWatch(coolDownTime, coolDownMessage);\n // Extra vibration because of final run\n vibration.start(\"confirmation-max\");\n currentTimer = new Timer(function() {\n finishUpAfterCooldown(currentRunTimes);\n }, currentCountDown);\n currentTimer.resume();\n}", "title": "" }, { "docid": "8ce24cedac1929a4b72e7e7ae9ae4fa7", "score": "0.492353", "text": "function drumGen(drumKit) {\n drumKitLog.innerText = drumKit;\n loadedKit = drumKit;\n console.log(`selected drums: ${drumKit}`)\n\n}", "title": "" }, { "docid": "2bec9d74a26cbe9eb08b803fb39317ef", "score": "0.491909", "text": "on_signal(signal_type, amount){\n // amount positive, nose up.\n // engine location on the drone.\n // 4\n // / \\\n // 3 1\n // \\ /\n // 2\n if(signal_type === Remote.signals().pitch){\n if(amount > 0){\n this.drone.engines[4].power_up(amount); // gradually\n this.drone.engines[2].power_down(amount);\n }else{ //tail up\n this.drone.engines[4].power_down(amount);\n this.drone.engines[2].power_up(amount);\n }\n }else if(signal_type === Remote.signals().roll){\n if(amount > 0){\n this.drone.engines[3].power_up(amount); // gradually\n this.drone.engines[1].power_down(amount);\n }else{\n this.drone.engines[3].power_down(amount);\n this.drone.engines[1].power_up(amount);\n }\n }else if(signal_type === Remote.signals().forward){\n let engines = [this.engines[0], this.engines[1], this.engines[2]];\n engines.map(engine => engine.power_up(amount));\n\n // .... similar for back, left, right, etc.\n }else if(signal_type === Remote.signals().hover){\n this.stabilize(this.location);\n }\n }", "title": "" }, { "docid": "0c9a0311c6da440653327f5fa3090301", "score": "0.49183318", "text": "function changeInput(vehicle) { //this function assigns a value (vehicle) to each icon, depending on which one is selected\n tank.value = vehicle; //the value of the input bar will be equal to the parameter set in (vehicle)\n }", "title": "" }, { "docid": "4b0afc41c95d05c242d5b85df1199baf", "score": "0.49170688", "text": "function updateStepperMotor(data) {\n // ... add code here ...\n }", "title": "" }, { "docid": "490d094fba0fc175a7c6fe926c0de423", "score": "0.49113128", "text": "function on(){\n temper = 1;\n print(\"Pet box is feeling aqua!\");\n}", "title": "" }, { "docid": "e5c77660dd00c08ecd12b8bd82d99dc1", "score": "0.4907998", "text": "function PrisonSubHandcuffing() {\n\tif (Math.random() > 0.5) {\n\t\tInventoryWear(PrisonSub, \"MetalCuffs\", \"ItemArms\");\n\t\tPrisonSubSelfCuffed = true;\n\t\tPrisonSub.CurrentDialog = DialogFind(PrisonSub, \"PrisonSubInterrest\");\n\t} else {\n\t\tPrisonSub.CurrentDialog = DialogFind(PrisonSub, \"PrisonSubNoInterrest\");\n\t}\n\tPrisonSubAskedCuff = true;\n}", "title": "" }, { "docid": "d571e73d3ca4714ca2a2af0c85ef6bb1", "score": "0.49067605", "text": "static coolDown(socket, modelTanks) {\n \n if (modelTanks.data.player1.coolDown > 0) {\n modelTanks.data.player1.coolDown -= COOL_DOWN_SPEED;\n } else if (modelTanks.data.player1.coolDown == 0) {\n modelTanks.data.player1.coolDown = 0;\n }\n if (modelTanks.data.player2.coolDown > 0) {\n modelTanks.data.player2.coolDown -= COOL_DOWN_SPEED;\n } else if (modelTanks.data.player2.coolDown == 0) {\n modelTanks.data.player2.coolDown = 0;\n }\n\n }", "title": "" }, { "docid": "bcc0c3a5e1fe26233750697f9adb66b5", "score": "0.4900063", "text": "function hunt(Food){\n var type = Food.toLowercase;\n switch(type){\n case \"O\":\n console.log(\"Damn son you're eating both\")\n\n break\n case \"C\":\n console.log(\"Damn son you're eating both\")\n\n break\n case \"H\":\n sleep(5);\n\n break\n default:\n console.log(\"Hunting season is over\")\n\n\n }\n \n}", "title": "" }, { "docid": "7dcdfbf33b5b831982700c8b36f0a955", "score": "0.4898682", "text": "function selecionaDificuldade() {\n\n\tif (dificuldade === 'normal') {\n\t\tspawnMosca = 1500\n\t\ttempo = 15\n\t} else if (dificuldade === 'dificil') {\n\t\tspawnMosca = 1000\n\t\ttempo = 20\n\t} else if (dificuldade === 'chucknorris') {\n\t\tspawnMosca = 750\n\t\ttempo = 25\n\t}\n\n}", "title": "" }, { "docid": "283c0e8b45849431330c8a0ac2386ac1", "score": "0.4891249", "text": "function addCrust(runningPrice) {\n var crustPrice = 0;\n var crustChoice = $(\"input[type='radio'][name='crust']:checked\").val();\n if (crustChoice == \"Cheese Stuffed Crust\") {\n crustPrice += 3;\n document.getElementById('selectedCrust').innerHTML = crustChoice + \" +$3.00\";\n } else {\n document.getElementById('selectedCrust').innerHTML = crustChoice;\n }\n runningPrice += crustPrice;\n updateRunning(runningPrice);\n addSauce(runningPrice);\n}", "title": "" }, { "docid": "81cc9af2def38fbbc43f8a910adf34fb", "score": "0.48872125", "text": "function Adopt(){\n\n\t// Set transition time=\n\tchickenStats.gameObject.GetComponent(ChickenAgeScript).GetTransitionTime();\n\n\t// Set up the chicken\n\tvar chicken : Chicken = chickenStats.chicken;\n\n\t// Play Sound Effect\n\taudioController.PlaySound(audioController.money);\n\n\t// Disable Blutton\n\tgameObject.GetComponent(UI.Button).interactable = false;\n\n\t// Set PopupLayout to confirm purchase\n\n\t// Play button press noise\n\taudioController.PlaySound(audioController.button);\n\n\t// Set chicken's box number to empty box number\n\tchicken.box = parseInt(emptyBoxes[0]);\n\n\t// remove money from bank;\n\tPlayerPrefs.SetInt(\"Buttons\", PlayerPrefs.GetInt(\"Buttons\") - chicken.price);\n\n\t// Save Chicken\n\tvar saveChickenList : List.<Chicken> = List.<Chicken>();\n\tsaveChickenList.Add(chicken);\n\tSaveChickens.SetChicken(0, PlayerPrefs.GetInt(\"TotalChickens\").ToString(), saveChickenList);\n\t// Iterate the total number of chickens\n\tPlayerPrefs.SetInt(\"TotalChickens\", PlayerPrefs.GetInt(\"TotalChickens\") + 1); \n\n\t// Change Scene\n\t//changeScene.ChangeScene(\"ChickenBoxManager\");\n}", "title": "" }, { "docid": "3e175520164565f23c4cc194e22d4d3a", "score": "0.48857844", "text": "function cont(name,protein,price,quantity){\n\tfood.call(this, name, protein, price, quantity);\n\tthis.drink=\"orange juice\" \n}", "title": "" }, { "docid": "9eb686979bcf4e8eb4298a285afc5e6f", "score": "0.4885606", "text": "updateForm(increase) {\n this.$step.innerText = this.currentStep;\n\n if (increase) {\n switch (this.currentStep - 1) {\n case 1:\n const $formCheckboxes = $('.form-group--checkbox input:checked');\n const $descriptions = $formCheckboxes.siblings('.description');\n const arrayLength = this.$donation.categories.length;\n this.$donation.categories.splice(0, arrayLength);\n\n for (let i = 0; i < $formCheckboxes.length; i++) {\n this.$donation.categories.push({\n id: $formCheckboxes.get(i).value,\n name: $descriptions.get(i).innerText\n });\n }\n break;\n\n case 2:\n this.$donation.quantity = $('.form-group--inline input[name=\"bags\"]').val();\n break;\n\n case 3:\n const $checkedRadio = $('input[type=\"radio\"]:checked');\n this.$donation.institution.id = $checkedRadio.val();\n this.$donation.institution.name = $checkedRadio.siblings().find('.title').text();\n this.$donation.institution.description = $checkedRadio.siblings().find('.subtitle').text();\n break;\n\n case 4:\n this.$donation.street = $('input[name=\"address\"]').val();\n this.$donation.city = $('input[name=\"city\"]').val();\n this.$donation.zipCode = $('input[name=\"postcode\"]').val();\n this.$donation.pickUpDate = $('input[name=\"data\"]').val();\n this.$donation.pickUpTime = $('input[name=\"time\"]').val();\n this.$donation.pickUpComments = $('textarea[name=\"more_info\"]').val();\n\n let summaryText = '';\n for (let i = 0; i < this.$donation.categories.length; i++){\n summaryText += `${this.$donation.categories[i].name}, `;\n }\n\n switch (this.$donation.quantity) {\n case '1':\n summaryText += `${this.$donation.quantity} worek do oddania`;\n break;\n\n case '2':\n case '3':\n case '4':\n summaryText += `${this.$donation.quantity} worki do oddania`;\n break;\n\n default:\n summaryText += `${this.$donation.quantity} worków do oddania`;\n break;\n }\n\n const $span = $('span.summary--text');\n $span.first().text(summaryText);\n $span.last().text(`Dla fundacji ${this.$donation.institution.name}`);\n $('#street').text(this.$donation.street);\n $('#city').text(this.$donation.city);\n $('#zip-code').text(this.$donation.zipCode);\n $('#phone').text($('input[name=\"phone\"]').val());\n $('#pick-date').text(this.$donation.pickUpDate);\n $('#pick-time').text(this.$donation.pickUpTime);\n $('#pick-comments').text(this.$donation.pickUpComments);\n break;\n\n default:\n break;\n }\n }\n\n // TODO: Validation\n\n this.slides.forEach(slide => {\n slide.classList.remove(\"active\");\n\n if (slide.dataset.step == this.currentStep) {\n slide.classList.add(\"active\");\n }\n });\n\n this.$stepInstructions[0].parentElement.parentElement.hidden = this.currentStep >= 5;\n this.$step.parentElement.hidden = this.currentStep >= 5;\n\n }", "title": "" }, { "docid": "c78995bb0e91bd8118afe7955bd7263b", "score": "0.4881064", "text": "toonFancyChange(kaart){\n if(kaart.getWaarde == \"skip\"){\n \n }\n }", "title": "" }, { "docid": "afade4c7b4f321c3e4e72f03da2341d1", "score": "0.4880113", "text": "function Shield() {\r\n var shieldPrice = 500;// initial price\r\n /**\r\n * accessor and mutator to the variable price of the shield\r\n * @param {number} p the price of the shield\r\n * @return the current price of the shield\r\n */ \r\n this.getShieldPrice = function() {\r\n return shieldPrice;\r\n };// end accessor\r\n this.setShieldPrice = function(p) {\r\n shieldPrice = p;\r\n };// end mutator \r\n /**\r\n * triggered when the shield upgrade is bought in the shop \r\n */\r\n this.shieldBuy = function() {\r\n var temp = character.getShieldUpgrade() + 1;\r\n character.setShieldUpgrade(temp); \r\n temp = character.getMoney() - shieldPrice; \r\n character.setMoney(temp);\r\n shieldPrice = parseInt(shieldPrice) + parseInt(500);// the price goes up\r\n document.getElementById(\"moneySound\").load();\r\n document.getElementById(\"moneySound\").play();\r\n $(\"#showMoney\").text(\"Argent: $\" + character.getMoney());\r\n $(\"#buyShield\").text(\"Surclasse: \" + shield.getShieldPrice() + \"$\");// the price changes\r\n };// end shieldBuy\r\n /**\r\n * Determines whether the user evades the monster's attack upon giving a wrong answer \r\n * @return whether the hit was evaded or not\r\n */\r\n this.isEvaded = function() {\r\n var temp1 = Math.random();\r\n var temp2 = 0.5-0.5*Math.pow(0.5, character.getShieldUpgrade());\r\n if(temp1<temp2)\r\n return true;// P(s) = 0.5 - 0.5^(s+1), where P represents the probability of an evasion, and s represent the level of the shield upgrade\r\n else\r\n return false;\r\n };// end shield \r\n}// end constructor", "title": "" }, { "docid": "654cb149abe469ab18a33378ec6bf91b", "score": "0.487676", "text": "function autoCatnipFunction() {\n if (gamePage.bld.get(\"field\").val>0) {return;}\n var tab;\n\n for (var i in gamePage.tabs) {\n tab = gamePage.tabs[i];\n if (tab.tabName == \"Bonfire\") {break;}\n }\n buttons = tab.buttons;\n if (buttons.length==0) {return;}\n for (var b in buttons) {\n if (buttons[b].model.name==\"Gather catnip\") {\n console.log(\"Gathering catnip manually!\");\n //buttons[b].handler(buttons[b]);\n var gather = buttons[b];\n gather.controller.buyItem(gather.model, genericEvent, function() {});\n }\n }\n}", "title": "" }, { "docid": "f875e96a3c9dfa052eead7a27324b113", "score": "0.48738134", "text": "timer() {\n\t\tconst timer = setInterval(() => {\n\n\t\t\t\tthis.hunger++;\n\t\t\t\tthis.boredom++;\n\t\t\t\tthis.sleepiness++;\n\t\t\t\tthis.age += 2;\n\n\t\t\tconst $currentSleep = $('#current-sleep').text(this.sleepiness);\n\t\t\tconst $currentBoredom = $('#current-boredom').text(this.boredom);\n\t\t\tconst $currentHunger = $('#current-hunger').text(this.hunger);\n\t\t\tconst $currentAge = $('#current-age').text(this.age);\n\n\t\t\t//if hunger or boredom or sleepiness get to 10 then your buddy dies\n\t\t\tthis.gettingOlder();\n\t\t\tif(this.hunger === 10 || this.boredom === 10 || this.sleepiness === 10) {\n\t\t\t\tthis.buddyDies();\n\t\t\t\tclearInterval(timer);\n\t\t\t}\n\t\t}, 2500)\n\t\t\n\t}", "title": "" }, { "docid": "273bda1cfd8e840aaf9732ccaf4558ef", "score": "0.4873448", "text": "beat(){\n this.heartrate = this.Generate_Random_num(60,100);\n //Display the patient details and their respective heartrate.\n console.log('Biosensor Details of patient number '+ this.patient_num);\n console.log('The hearbeat of patient '+ this.patient + ' is ' + this.heartrate);\n }", "title": "" }, { "docid": "e6b4ae5db73ccaf7a89107235e02e139", "score": "0.48710626", "text": "function start() {\n squidUpDown();\n countdown();\n}", "title": "" }, { "docid": "b25adc61a67e765c19871568791192ff", "score": "0.48689127", "text": "function handleCharacteristicValueChanged(event) {\n // Output the value for each event differently\n let tempValue = event.target.value.getFloat32(0, true);\n console.log('Arduino Output for ' + \n uuidLookup[event.target.uuid] + ': ' + tempValue.toFixed(2));\n if (uuidLookup[event.target.uuid] == 'temp') {\n // Increments the values every time they come in\n // In this case, ticks is the number of seconds\n ++time;\n document.getElementById('timer').textContent = time;\n line_config.data.labels.push(time);\n\n // Changes the pressure value each time it comes in\n tempText.textContent = tempValue.toFixed(2);\n line_config.data.datasets[0].data.push(tempValue.toFixed(2));\n\n // Gauge chart updating values\n gauge_config.options.title.text = tempValue.toFixed(2);\n\n // Updating the label values\n document.getElementById('time-val').innerHTML = `${time} s`;\n document.getElementById('pressure-val').innerHTML = `${tempValue.toFixed(2)} bar`;\n\n // Updating the gauge chart values\n gauge_config.options.title.text = tempValue.toFixed(2);\n\n // 20 is the max bar value\n let first_val = (tempValue / 20) * 100;\n let second_val = ((20 - tempValue) / 20) * 100;\n\n // Emptying the dataset every time\n gauge_config.data.datasets[0].data = [];\n\n gauge_config.data.datasets[0].data.push(first_val);\n gauge_config.data.datasets[0].data.push(second_val);\n\n myChart.update();\n myChart1.update();\n\n\n } else if (uuidLookup[event.target.uuid] == 'newChar') {\n newText.textContent = tempValue.toFixed(2);\n tempHTML.textContent = tempValue.toFixed(2);\n }\n}", "title": "" }, { "docid": "6ac97579b75bccf5f0b1d2f6b241427a", "score": "0.4867295", "text": "function ac_control(){\n\tconsole.log(\"* Adjusting AC at \" + new Date);\n\tif(ac_state == 1){\n\t\tif(temp_json.fahrenheit >= config.threshold - config.goal){\n\t\t\tconsole.log(\"* \" + temp_json.fahrenheit + \" is >= config.threshold - config.goal (\" + (config.threshold - config.goal) + \"). AC is staying ON.\");\n\t\t\tconsole.log(\"\");\n\t\t\treturn;\n\t\t} else { \n\t\t\tconsole.log(\"* \" + temp_json.fahrenheit + \" is < config.threshold - config.goal (\" + (config.threshold - config.goal) + \"). AC is turning OFF.\");\n\t\t\twrite_off();\n\t\t\tconsole.log(\"\");\n\t\t\treturn;\n\t\t}\n\t}\n\telse if(temp_json.fahrenheit >= config.threshold)\n\t{\n\t\tif(time_turned_on == -1){\n\t\t\ttime_turned_on = (+ new Date);\n\t\t\tconsole.log(\"* Turning AC on for first time!\");\n\t\t\twrite_on();\n\t\t}\n\t\telse{\n\t\t\tif((+new Date) - time_turned_off > config.min_time_off){\n\t\t\t\ttime_turned_on = (+ new Date);\n\t\t\t\tconsole.log(\"* Turning AC on!\");\n\t\t\t\twrite_on();\n\t\t\t} else {\n\t\t\t\tconsole.log(\"* Temperature is > Threshold, but compressor still cooling down! :(\");\n\t\t\t}\n\t\t}\n\t}\n\telse {\n\t\tif(ac_state == 0){\n\t\t\tconsole.log(\"* \" + temp_json.fahrenheit + \" is < config.threshold, and AC is already OFF\");\n\t\t\tconsole.log(\"\");\n\t\t\treturn;\n\t\t} else {\n\t\t\tconsole.log(\"* \"+ temp_json.fahrenheit + \" < config.threshold (\" + config.threshold + \")\");\n\t\t\twrite_off();\n\t\t\ttime_turned_off = (+new Date);\n\t\t}\n\t}\n\tconsole.log(\"\");\n}", "title": "" }, { "docid": "bf4722507d2dec827106270e7ec29eb8", "score": "0.48610148", "text": "function changeVariableDown(id) {\n\tif(id == \"points\") {\t\t\t\t\t\t\t\t\t\t//\"points\" is the id of the HTML input field in the bottomToolBar associated with the javascript pointsElement variable\n\t\tif(points > 0) {\t\t\t\t\t\t\t\t\t\t//If the points are <= 0 there's no need to do anything\n\t\t\tpoints--;\t\t\t\t\t\t\t\t\t\t\t//The javascript points variable is decremented by 1\n\t\t\tpointsElement.value = points;\t\t\t\t\t\t//The HTML points input field is updated with the new value\n\t\t} else\n\t\t\tshowMessage(\"EASTER EGG\", \"Contali meglio...\");\n\t\treturn; \t\t\t\t\t\t\t\t\t\t\t\t//There's no need to check other options because the HTML elements' ids are unique\n\t}\n\n\tif(id == \"timer\" & !timerStarted) {\t\t\t\t\t\t\t//\"timer\" is the id of the HTML input field in the topToolBar associated with the javascript topToolBarElement variable and can be modified only when it's not running\n\t\tif(timerRemaningMinutes > timerMinValue) {\t\t\t\t//If the timer is already set to the minumum accepted value there's no need to update its value\n\t\t\ttimerRemaningMinutes--;\t\t\t\t\t\t\t\t//The javascript timer variable is decremented by 1\n\t\t\tstartingTime = timerRemaningMinutes;\t\t\t\t//The javascript startingTime variable is updated to the new timer value so that when we'll press the resetGameButton the timer will be restore to the correct value\n\t\t\ttimerElement.value = timerRemaningMinutes + \":00\";\t//The HTML timer input field's value is updated: is faster to add \":00\" than to look for the timerRemaningSeconds javascript variable value\n\t\t\ttimerHasBeenModified = true;\t\t\t\t\t\t//The javascript timerHasBeenModified variable is set to true so that the next time the countDown function will be called it will work correctly\n\t\t} else\n\t\t\tshowMessage(\"EASTER EGG\", \"Fidati, ti serve tempo...\");//If the user tries to set an incorrect value: EASTER EGG\n\t\treturn;\t\t\t\t\t\t\t\t\t\t\t\t\t//There's no need to check other options because the HTML elements' ids are unique\n\t}\n}", "title": "" }, { "docid": "bb4e96fc0d5a284e137b721271fbab59", "score": "0.4860729", "text": "function collectFuel(){\n powerUpSound.play();\n playerFuel += 20;\n if(playerFuel > 100){\n playerFuel = 100;\n }\n updateFuel();\n}", "title": "" }, { "docid": "ddad1602fe199d92f3a6f4846ea62277", "score": "0.48602414", "text": "function cook(sec) {\n setTimeout(() => {\n console.log(this.kind + \" cooked for \" + sec + \" seconds.\");\n }, sec * 1000);\n }", "title": "" }, { "docid": "67b1e809d20d26ec23d8716ff096226a", "score": "0.48570207", "text": "function delay2(){\r\n\t\t\t\tif (delaySwitch === true && cycle === 3){\r\n\t\t\t\t\tclock = clearInterval(clock);\r\n\t\t\t\t\tcycle = 4;\r\n\t\t\t\t\t$('.exercise-title').html('Military Pushups');\r\n\t\t\t\t\t$('.exercise-icon').show();\r\n\t\t\t\t\ttimer = 7000;\r\n\t\t\t\t\tconsole.log(\"Delay 2\");\r\n\t\t\t\t\tclock = setInterval(workoutProgram, 1000);\r\n\t\t\t\t\tconsole.log(\"I am the timed cycle 4 :)\");\r\n\t\t\t\t\thideComplete = false;\r\n\t\t\t\t\t$('.next-form').html('<form id=\"exercise-count\"> <input id=\"militarycount1\" type=\"number\" name=\"militarycountcount\"></form>')\r\n\t\t\t\t\t$('.next').html('<a class=\"exercise5 next-btn\" href=\"timer.html\">Level Up</a>');\r\n\t\t\t\t\tcycle = 5;\r\n\t\t\t\t\tupdateUser(\"cycle\",cycle);\r\n\t\t\t\t\t$(\".exercise5.next-btn\").click(function(){\r\n\t\t\t\t\t\tmilitary1 = document.getElementById(\"militarycount1\").value;\r\n\t\t\t\t\t\tconsole.log(\"I work\");\r\n\t\t\t\t\t\tupdateUser(\"militarycount1\", military1);\r\n\t\t\t\t\t\t});\r\n\t\t\t\t}else{\r\n\t\t\t\t\tconsole.log('No delay part two');\r\n\t\t\t\t}\r\n\t\t\t}", "title": "" }, { "docid": "2446b6d17543a2505913bbf427816a15", "score": "0.4855217", "text": "function calMoney() {\n //get kilometers, times from input boxes\n var kmField = document.getElementById(\"totalKm\").innerHTML;\n var totalKm = parseFloat(document.getElementById(\"totalKm\").value);\n console.log(totalKm);\n var minuteWaited = document.getElementById(\"minuteWaited\").value;\n if (minuteWaited === \"\") {\n minuteWaited = 0;\n } else {\n minuteWaited = parseFloat(document.getElementById(\"minuteWaited\").value);\n }\n console.log(minuteWaited);\n\n //display the div ThanhTien block when tinhTien button is clicked\n var divThanhTien = document.getElementById(\"divThanhTien\");\n divThanhTien.style.display = \"block\";\n\n\n //get uber car type\n var loaiXe = getType();\n console.log(getType());\n\n //every type of uber has different prices\n var totalMoney;\n switch (loaiXe) {\n case 'uberX':\n if (totalKm <= 1) {\n totalMoney = (totalKm * 8000) + (minuteWaited * 2000);\n } else if (totalKm > 1 && totalKm <= 20) {\n totalMoney = 8000 + ((totalKm - 1) * 12000) + (minuteWaited * 2000);\n } else if (totalKm > 20) {\n totalMoney = 8000 + (19 * 12000) + ((totalKm - 20) * 10000) + (minuteWaited * 2000);\n }\n break;\n\n case 'uberSUV':\n if (totalKm <= 1) {\n totalMoney = (totalKm * 9000) + (minuteWaited * 3000);\n } else if (totalKm > 1 && totalKm <= 20) {\n totalMoney = 9000 + ((totalKm - 1) * 14000) + (minuteWaited * 3000);\n } else if (totalKm > 20) {\n totalMoney = 9000 + (19 * 14000) + ((totalKm - 20) * 12000) + (minuteWaited * 3000);\n }\n break;\n\n case 'uberBlack':\n if (totalKm <= 1) {\n totalMoney = (totalKm * 10000) + (minuteWaited * 4000);\n } else if (totalKm > 1 && totalKm <= 20) {\n totalMoney = 10000 + ((totalKm - 1) * 16000) + (minuteWaited * 4000);\n } else if (totalKm > 20) {\n totalMoney = 10000 + (19 * 16000) + ((totalKm - 20) * 14000) + (minuteWaited * 4000);\n }\n break;\n }\n\n //display total money on totalMoney span tag\n if (totalMoney > 0) {\n spanTien.innerHTML = \"\";\n spanTien.innerHTML = parseFloat(totalMoney).toLocaleString('it-IT', { style: 'currency', currency: 'VND' });\n } else if (kmField === \"\") {\n spanTien.innerHTML = \"Bạn chưa đi được cây số nào mà :3\";\n }\n}", "title": "" }, { "docid": "b8c5889d6ff0921ec33c7b982d937a2b", "score": "0.4854849", "text": "renewDrawPlant(crossPoint_x, crossPoint_y) {\n const screenWidth = app.globalData.screenWidth\n let min_distance = screenWidth / 4 //the range of the shovel\n let min_distance_index = 5\n\n for (let i = 0; i < this.data.cropsID[this.data.currentLevel].length; i++) {\n //detected counted\n if (this.data.usedCrop[this.data.currentLevel][i] == 1) {\n continue\n }\n // Calculating Euclidean distance\n let x_dis = Math.abs(this.data.position[this.data.currentLevel][i][0] - crossPoint_x)\n let y_dis = Math.abs(this.data.position[this.data.currentLevel][i][1] - crossPoint_y)\n let distance = Math.sqrt(Math.pow(x_dis, 2) + Math.pow(y_dis, 2))\n if (distance < min_distance) {\n min_distance = distance\n min_distance_index = i\n }\n }\n\n //if crop is in the range\n let collectSuccess = false\n let cropCollected = this.data.cropsID[this.data.currentLevel][min_distance_index]\n let gainedEnergy = 0\n if (min_distance < screenWidth / 4) {\n let usedCrop = this.data.usedCrop\n usedCrop[this.data.currentLevel][min_distance_index] = 1\n let currentNumberOfCrop = this.data.currentNumberOfCrop\n gainedEnergy = parseInt(this.data.cropsData[cropCollected]['val'])\n this.addEnergy(gainedEnergy)\n\n currentNumberOfCrop--\n collectSuccess = true\n this.setData({\n usedCrop,\n currentNumberOfCrop\n })\n wx.setStorage({\n data: {\n currentLevel: this.data.currentLevel,\n currentNumberOfCrop: currentNumberOfCrop,\n usedCrop: usedCrop\n },\n key: 'crop',\n })\n } else {\n collectSuccess = false\n }\n\n // upload game setting to db\n wx.cloud.callFunction({\n name: 'addGameResult',\n data: {\n value: gainedEnergy\n },\n success: function (res) {\n console.log({\n addGameResult: res.result\n })\n },\n fail: console.error\n })\n\n this.setData({\n modalName: \"share\",\n collectSuccess,\n cropCollected,\n })\n\n // Continue to next level \n if (this.data.currentNumberOfCrop == 0 && this.data.currentLevel < 2) {\n let currentLevel = this.data.currentLevel\n currentLevel++\n let currentNumberOfCrop = this.data.usedCrop[currentLevel].length\n this.setData({\n currentLevel,\n currentNumberOfCrop\n })\n wx.setStorage({\n data: {\n currentLevel: currentLevel,\n currentNumberOfCrop: currentNumberOfCrop,\n usedCrop: this.data.usedCrop\n },\n key: 'crop',\n })\n }\n\n // end of three levels\n if (this.data.currentNumberOfCrop == 0 && this.data.currentLevel == 2) {\n this.generateCropPosition()\n this.setData({\n currentLevel: 0,\n currentNumberOfCrop: 3,\n usedCrop: [\n [0, 0, 0],\n [0, 0, 0, 0],\n [0, 0, 0]\n ]\n })\n\n wx.setStorage({\n data: {\n currentLevel: 0,\n currentNumberOfCrop: 3,\n usedCrop: [\n [0, 0, 0],\n [0, 0, 0, 0],\n [0, 0, 0]\n ]\n },\n key: 'crop',\n })\n }\n }", "title": "" }, { "docid": "47432140df4d57a4e001b9208043cae0", "score": "0.48525932", "text": "collect(type, condition, player) {\n while (condition) {\n setInterval(() => {\n if (type === 'timber') {\n player.timber += this.interactSpeed;\n } else {\n player.wheat += this.interactSpeed;\n }\n }, 1000);\n }\n }", "title": "" }, { "docid": "9c3eaedeed837ef86e5e14287f8b770b", "score": "0.4850872", "text": "function c_c(){\n let air_cn = air.data.current.pollution.aqius;\n let air_us = air.data.current.pollution.aqicn;\n let color ;\n let concern;\n if(0 <=air_cn||air_us<=50){\n color = \"#2EC467\"; //green\n concern = \"good\";\n }\n else if(51<=air_cn||air_us<=100){\n color = \"#CECC09\"; //yellow\n concern = \"moderate\";\n }\n else if(101<=air_cn||air_us<=150){\n color = \"#FF9C29\"; // qrange\n concern = \"unhealty for sensitive groups\";\n }\n else if(151<=air_cn||air_us<=200){\n color = \"#FF1616\"; // red\n concern = \"unhealthy\";\n }\n else if(201<=air_cn||air_us<=300){\n color = \"#8A00A8\"; // purple\n concern = \"very unhealthy\";\n }\n else if(301<=air_cn||air_us<=500){\n color = \"#8A00A8\"; // maroon;\n concern = \"hazardous\";\n };\n let info ={color,concern};\n return info;\n }", "title": "" }, { "docid": "9f07b2e6877187bd66ce6073a4f325bd", "score": "0.4841849", "text": "function cook(sec) {\n setTimeout(function() {\n console.log(this.kind + \" cooked for \" + sec + \" seconds.\");\n }, sec * 1000);\n }", "title": "" }, { "docid": "b4193289bce3c613aab472ee1b5d9c53", "score": "0.4841173", "text": "powerUp() {\n if (this.remainingDots !== 0) {\n this.soundManager.setAmbience('power_up');\n }\n\n this.removeTimer({ detail: { timer: this.ghostFlashTimer } });\n\n this.ghostCombo = 0;\n this.scaredGhosts = [];\n\n this.ghosts.forEach((ghost) => {\n if (ghost.mode !== 'eyes') {\n this.scaredGhosts.push(ghost);\n }\n });\n\n this.scaredGhosts.forEach((ghost) => {\n ghost.becomeScared();\n });\n\n const powerDuration = Math.max((7 - this.level) * 1000, 0);\n this.ghostFlashTimer = new Timer(() => {\n this.flashGhosts(0, 9);\n }, powerDuration);\n }", "title": "" }, { "docid": "0e4d40554af0156df0f6e2cc288f42dd", "score": "0.48386768", "text": "function docks()\n{\n\t\tvar dialogue = [\"Arrow: So you are in my city!\", // narrative comes here i = 5\n\t \"Ras Al Ghul: The robber gave me away huh? He was suppose to keep you busy\",\n\t \"Arrow: What are you doing in my city!\",\n\t \"Ras Al Ghul: Well things don't always go in your favor. I needed some stuff\",\n\t \"Arrow: I'll ask you once, get out of my city!\",\n\t \"Ras Al Ghul: Well. We'll have to see about that. I have bombs set up around here.\",\n\t \"Arrow: What? \",\n\t \"Ras Al Ghul: Yes. It will go off in a bit. Do you want to stay here?\"\n\t ]; \n\t // now they should fight?\n\t // when does the robber get knocked out\n\tif (line%2 === 0 && line < dialogue.length)\n\t{\t// left person is speaking\n\t\t$(\".speech-lp\").text(dialogue[line++]);\n\t\t$(\".speech-r\").fadeOut('slow'); // fade this out\n\t\t$(\".speech-l\").fadeIn('slow'); // fade this in\n\t}\n\telse if (line%2 != 0 && line < dialogue.length)\n\t{\n\t\t// else right person is speaking\n\t\t$(\".speech-rp\").text(dialogue[line++]);\n\t\t$(\".speech-l\").fadeOut('slow'); // fade this out\n\t\t$(\".speech-r\").fadeIn('slow');\n\t}\n\n\t// prompt the user\n\tif (line > dialogue.length)\n\t{\n\t\t$('.choice-l').text('Stay here and fight Ras');\n\t\t$('.choice-r').text('Leave and avoid the explosion');\n\t\t$('.decision').fadeIn('slow');\n\t\t$('.choice-l').fadeIn('slow');\n\t\t$('.choice-r').fadeIn('slow');\n\t\t$('.choice-l').click(function(){\n\t\t\tscenceSelection = 'docksFight';\n\t\t\t$('.choice-l').fadeOut('slow');\n\t\t\t$('.choice-r').fadeOut('slow');\n\t\t\t$('.decision').fadeOut('slow');\n\t\t});\n\t\t$('.choice-r').click(function(){\n\t\t\tscenceSelection = 'docksLeave';\n\t\t\t$('.choice-l').fadeOut('slow');\n\t\t\t$('.choice-r').fadeOut('slow');\n\t\t\t$('.decision').fadeOut('slow');\n\t\t});\n\t\tline = 0;\n\t\t// change the image to the next scene\n\t\t$(\".speech-l\").fadeOut('slow'); // fade this out\n\t\t$(\".speech-r\").fadeOut('slow');\n\t\t// document.getElementsByClassName(\"image-left\")[0].src = \"arrow/scene2-A.jpg\";\n\t\t// document.getElementsByClassName(\"image-right\")[0].src = \"arrow/scene2-R.jpg\";\n\t\tscene++; // we move to the next scene\n\t\t$(\".scene\").text(\"Scene \" + scene);\n\t\tline = 0;\n\t\t// change the image to the next scene\n\t\t$(\".narrative\").fadeOut('slow');\n\t\t$(\".speech-l\").fadeOut('slow'); // fade this out\n\t\t$(\".speech-r\").fadeOut('slow');\n\t\t\n\t\t// document.getElementsByClassName(\"image-left\")[0].src = \"arrow/scene2-A.jpg\";\n\t\t// document.getElementsByClassName(\"image-right\")[0].src = \"arrow/scene2-R.jpg\";\n\t\tscene++; // we move to the next scene\n\t\t$(\".scene\").text(\"Scene \" + scene);\n\t}\n\tif (line === dialogue.length)\n\t\t++line; // used for error cking\n}", "title": "" }, { "docid": "4c1dcdc30db1c9a225e7198ef3a3f690", "score": "0.48373625", "text": "function updateData() {\n action.drink();\n health.thirstDeath();\n}", "title": "" }, { "docid": "fa479a7861ed006b7966063ae99286a1", "score": "0.48338842", "text": "function getCracking() {\t\n\tstartClick.play();\n\n\tconsole.log('globalVibrate:', globalVibrate);\n\n\t// $(\"#eggWrapper\").fadeOut(1000);\n\t$(\"#eggWrapperActive\").fadeIn(200);\n\t\n\tvar value = $(\"#amount\").html();\n\t\t\n\t// $(\".flip-container\").addClass(\"hover\"); \n\t$(\"#sliderWrapper\").fadeOut(\"slow\");\n\t$(\".wrapperStart\").fadeOut(\"slow\");\n\t$(\".wrapperCancel\").fadeIn(200);\n\t$(\"#timeWrapper\").fadeIn(\"slow\");\n\t$(\"#eggWrapperActive .gloss\").fadeTo(100, 0.7);\n\n\t\t\n\tif (value == 0){\n\t\t$(\".hardnessWrapper\").attr(\"id\", \"soft\");\n\t\t$(\"#eggWrapperActive .yolkColor\").addClass(\"softFade\");\t\n\t\t$(\".time\").attr(\"id\", \"countdown1\");\n\t\tcountdown(\"countdown1\", 0, 3);\n\t\t$(\"#eggWrapperActive .gloss\").fadeOut(3000);\n\t}\n\telse if (value == 1){\n\t\t$(\".hardnessWrapper\").attr(\"id\", \"softMedium\");\n\t\t$(\"#eggWrapperActive .yolkColor\").addClass(\"softMediumFade\")\n\t\t$(\".time\").attr(\"id\", \"countdown2\");\n\t\tcountdown(\"countdown2\", 6, 30);\n\t\t$(\"#eggWrapperActive .gloss\").fadeOut(3000);\n\t}\n\telse if (value == 2){\n\t\t$(\".hardnessWrapper\").attr(\"id\", \"medium\");\n\t\t$(\"#eggWrapperActive .yolkColor\").addClass(\"mediumFade\")\n\t\t$(\".time\").attr(\"id\", \"countdown3\");\n\t\tcountdown(\"countdown3\", 7, 30);\n\t\t$(\"#eggWrapperActive .gloss\").fadeOut(3000);\n\t}\n\telse if (value == 3){\n\t\t$(\".hardnessWrapper\").attr(\"id\", \"mediumHard\");\n\t\t$(\"#eggWrapperActive .yolkColor\").addClass(\"mediumHardFade\")\n\t\t$(\".time\").attr(\"id\", \"countdown4\");\n\t\tcountdown(\"countdown4\", 8, 30);\n\t\t$(\"#eggWrapperActive .gloss\").fadeOut(3000);\n\t}\n\telse {\n\t\t$(\".hardnessWrapper\").attr(\"id\", \"hard\");\n\t\t$(\"#eggWrapperActive .yolkColor\").addClass(\"hardFade\")\n\t\t$(\".time\").attr(\"id\", \"countdown5\");\n\t\tcountdown(\"countdown5\", 0, 10);\n\t\t$(\"#eggWrapperActive .gloss\").fadeOut(8000);\n\t};\n}", "title": "" }, { "docid": "52bc5a4067164b7f03c4d3b07b3a7d49", "score": "0.48284826", "text": "function cookAndDeliverFood(cb) {\n setTimeout(cb, 5000);\n}", "title": "" }, { "docid": "1e989c33db147e46cd968a1f65c008e1", "score": "0.48231992", "text": "calculateTempClass(value, reference) {\n const delta = 3\n let tempClass = \"medium-temp\"\n if (value > reference + 3) {\n tempClass = \"hot-temp\"\n } else if (value < reference - 3) {\n tempClass = \"cool-temp\"\n }\n\n return tempClass\n }", "title": "" }, { "docid": "2ed9e67be7b6e93d303123b60972906a", "score": "0.48177475", "text": "function Truck(make, model, year, color, seats, capacity) {\n\tCar.call(this, make, model, year, color, seats);\n\tthis.capacity = capacity || 0;\n\tthis.cargo = 0;\n\tthis.seats = 3;\n\t\n\t\n}", "title": "" }, { "docid": "12489c6fd8da487d694718e9299e05ea", "score": "0.48139098", "text": "function goGo() {\n data.totalRevs += data.totalTech;\n data.totalCurrent += data.totalTech;\n $(\"#earf\").css({ 'transform': 'rotate(' + data.totalRevs + 'deg)'});\n updateReport();\n // unHide();\n}", "title": "" }, { "docid": "b177d0851dfbf16c4b5bce539ac6f1b5", "score": "0.48131412", "text": "selectDessert() {\n I.waitForElement(foodObjects.cinnabonMinis);\n I.tap(foodObjects.cinnabonMinis);\n I.waitForElementLeaveDom(settings.config.helpers.Appium.platform, commonObjects.progressBar);\n }", "title": "" }, { "docid": "dab97a3ff392f9f6bbe8a26b32a4bbe4", "score": "0.48128963", "text": "function addDrink(){\n \"use strict\";\n \n // Gets the chosen tea and milk from the dropdowns\n var teaIndex = getOptionIndex(\"tea\", teaOptions[0]);\n var milkIndex = getOptionIndex(\"milk\", milkOptions[0]);\n \n // Creates a new Drink and adds it to the drinks array\n drinks.push(new Drink(teaOptions[0][teaIndex], toppingList, milkOptions[0][milkIndex]));\n \n // Update the page\n updatePage();\n}", "title": "" }, { "docid": "7d1c5c9a3a479b3cfaf8ef0f5ac31434", "score": "0.48040777", "text": "function do_cheat(){ \n\t//set cheat\n\tMeteor.call('players.cheat');\n\tdocument.getElementById(\"bar_cheat\").classList.add(\"shown\");\n\n\tif(Session.get(\"lastest_cheat_timer\") == null)\n\t\tSession.set(\"lastest_cheat_timer\", 0);\n\n\tvar timer_index = Session.get(\"lastest_cheat_timer\") + 1;\n\tSession.set(\"lastest_cheat_timer\", timer_index);\n\tSession.set(\"cheat_timer\", CHEAT_TIMER_COUNTDOWN_FROM);\n\n\tfor(var i = 0; i <= CHEAT_TIMER_COUNTDOWN_FROM; i++){\n\t\tMeteor.setTimeout(()=>{\n\t\t\t\t\t//store lastest timer index to prevent having multiple timers modify the time at the same time\n\t\t\t\t\tif(timer_index == Session.get(\"lastest_cheat_timer\")){\n\t\t\t\t\t\tif(Session.get(\"cheat_timer\") == 0){\n\t\t\t\t\t\t\tSession.set(\"cheat_timer\", null);\n\n\t\t\t\t\t\t\t//remove cheat\n\t\t\t\t\t\t\tMeteor.call('players.cheat_recover');\n\t\t\t\t\t\t\tdocument.getElementById(\"bar_cheat\").classList.remove(\"shown\");\t\n\t\t\t\t\t\t}else{\n\t\t\t\t\t\t\tSession.set(\"cheat_timer\", Session.get(\"cheat_timer\")-1);\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}, i * 1000 );\n\t}\n}", "title": "" }, { "docid": "1393422926afc68940cdd5ac85d979ff", "score": "0.48038894", "text": "function calculateOutputDrink() {\n var { drink, price, calory } = drinksNode.querySelector('input:checked').dataset\n\n var quantity = drinksNode.querySelector('.input-quantity');\n\n targetDrinkName.textContent = drink;\n targetDrinkPrice.textContent = (price * quantity.value) + ' ' + VALUE_PRICE;\n targetDrinkCalory.textContent = (calory * quantity.value) + ' ' + VALUE_CALORY;\n}", "title": "" }, { "docid": "bef1d0e07ba74aa6b02d43d351b30565", "score": "0.48029488", "text": "function timer1(){\n position = json.PULL_OCEAN;\n simply.vibe('double');\n simply.title('PULL UP!');\n}", "title": "" }, { "docid": "943a07e5ffe7f947c62c79c0ee12b921", "score": "0.4800392", "text": "constructor(capacitance, connections, chargeResistance, dischargeResistance) {\r\n //capacitance in Farad, array containing anode and cathode, resistance between\r\n //anode and voltage source and resistance between anode and ground\r\n this.connection1 = connections[0];\r\n this.groundConn = connections[1];\r\n this.state = 'discharging';\r\n this.timerOffset = 0;\r\n this.capacitance = capacitance;\r\n //resistance between capacitor and ground when it is charging\r\n this.chargeResistance = chargeResistance;\r\n //resistance between capacitor and ground when it is discharging\r\n this.dischargeResistance = dischargeResistance;\r\n //the voltage of the capacitor in the previous frame\r\n this.prevVoltage = 0;\r\n }", "title": "" } ]
33c6bddcedb4df64f20ab44f888a9f36
This function is used to get the last block
[ { "docid": "45c4858a6998cb1c8a6e77367386e299", "score": "0.71780205", "text": "getPreviousBlock() {\n return this.#chain[this.#chain.length - 1];\n }", "title": "" } ]
[ { "docid": "5127943cfc7676273720e56e53af46f3", "score": "0.84710693", "text": "getLastBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "f2d29e41bc0fa7d7c1a3057c64adb7ac", "score": "0.8391022", "text": "getLastBlock(){\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "db6da0ccd505a07b7c3478b255bce232", "score": "0.8223488", "text": "obtainLatestBlock(){\n //fetches value of the last block\n return this.chain [this.chain.length - 1]\n }", "title": "" }, { "docid": "db717660ebc8c8642cf81d728dbb22ac", "score": "0.8207887", "text": "getLastBlock() {\n if (this.chain.length == 0) {\n return null;\n }\n\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "d809052d5a1de14772fbba6e1eeb28eb", "score": "0.8168594", "text": "function getLastBlock() {\n return RestApi\n .getState(restApiUrl, Address.HCHAIN1_NAMESPACE)\n .then(function(body) {\n\n\treturn body.head;\n })\n }", "title": "" }, { "docid": "d78a5b4575d5bda239ebea47e07f447a", "score": "0.8055251", "text": "getLatestBlock(){\n\t\treturn this.chain[this.chain.length - 1];\n\t}", "title": "" }, { "docid": "c55c1a94691943f185c280290568f80a", "score": "0.79353774", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "c55c1a94691943f185c280290568f80a", "score": "0.79353774", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "c55c1a94691943f185c280290568f80a", "score": "0.79353774", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "c55c1a94691943f185c280290568f80a", "score": "0.79353774", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "63698bc8dd5d0f782155446c3d530ac8", "score": "0.79110026", "text": "getLatestBlock(){\r\n return this.chain[this.chain.length-1];\r\n }", "title": "" }, { "docid": "f6633f5214cdd23cbb465c7a2bfee817", "score": "0.78890145", "text": "getLatestBlock() {\n return this.chain[this.chain.length -1];\n }", "title": "" }, { "docid": "0668142e83c7332717c011a17b4daea7", "score": "0.7887635", "text": "getLatestBlock(){\r\n return this.chain[this.chain.length - 1];\r\n }", "title": "" }, { "docid": "0668142e83c7332717c011a17b4daea7", "score": "0.7887635", "text": "getLatestBlock(){\r\n return this.chain[this.chain.length - 1];\r\n }", "title": "" }, { "docid": "5e02ce2b87d8a825d7f828934ba79509", "score": "0.7876204", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "5e02ce2b87d8a825d7f828934ba79509", "score": "0.7876204", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "5e02ce2b87d8a825d7f828934ba79509", "score": "0.7876204", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "5e02ce2b87d8a825d7f828934ba79509", "score": "0.7876204", "text": "getLatestBlock() {\n return this.chain[this.chain.length - 1];\n }", "title": "" }, { "docid": "a3a40231e8630b84190405fb7b0ccc42", "score": "0.73829067", "text": "getSecondLastBlock (callback) {\n if (this.chainLength <= 1) {\n let err = new Error('this.chainLength <= 1, failed to get second last block')\n return callback(err, null)\n }\n this.getBlock(this.chainLength - 2, callback)\n }", "title": "" }, { "docid": "6bcad0f1bac84b0e769ff7de68da494c", "score": "0.73566", "text": "async getBestBlock() {\n let blocks = await this.getBlocks()\n return blocks.pop()\n }", "title": "" }, { "docid": "95b9821dcf259b5914d3bd2636715e0b", "score": "0.7199617", "text": "getBlockchainLastBlock() {\n return rxjs_1.Observable.of(\"last-block\")\n .flatMap((url) => requestPromise.get(this.nextNode() + url, { json: true }))\n .retryWhen(this.replyWhenRequestError)\n .map((result) => {\n return Block_1.Block.createFromBlockDTO(result);\n });\n }", "title": "" }, { "docid": "4f6a5732c92434617f3f124d5afffba9", "score": "0.7170639", "text": "function peekBlock() {\n return ts.lastOrUndefined(blockStack);\n }", "title": "" }, { "docid": "2a9d03519890f57297cd45d847313fb3", "score": "0.70748323", "text": "getLatestBlock() {\n return new Promise((resolve, reject) => {\n let hash = (this.blocks.length <= 0) ? undefined : this.blocks[this.blocks.length - 1].hash;\n resolve(hash);\n });\n }", "title": "" }, { "docid": "306a54e8afe4f6716e0c034da71367b1", "score": "0.69991934", "text": "getCurHeightSync() {\n return this.blockchain.length - 1;\n }", "title": "" }, { "docid": "0c2fa3655dadcb685f464f3b818ffd07", "score": "0.68496764", "text": "getHeadBlockIdSync() {\n let length = this.blockchain.length;\n return length ? this.blockchain[length - 1] : undefined;\n }", "title": "" }, { "docid": "3d558ca19929a07038aea3b0d023bbea", "score": "0.6827541", "text": "getCurrentBlock() {\n return this.instance.blocks.getBlockByIndex(this.instance.blocks.getCurrentBlockIndex())\n }", "title": "" }, { "docid": "99f6ef82687ba3c78f97bcc414d2ad3e", "score": "0.679119", "text": "async function getLatestBlockNumber()\n{\n\ttry{\n\t\t// get the highest block\n\t\tconst number = await web3.eth.getBlockNumber();\n\t\treturn number;\n\t}catch(error)\n\t{\n\t\tconsole.log(error);\n\t}\n}", "title": "" }, { "docid": "3a6400fd93b74a9409efb3498f1ae78f", "score": "0.6676067", "text": "function getNextBlock () {\n\n // ensure something to pull from\n fillBag();\n\n // take block from next pieces queue\n let nextBlock = nextPieces.pop();\n\n // ensure STILL something to pull from\n fillBag();\n \n return nextBlock;\n}", "title": "" }, { "docid": "2932a076a95b7b5bea9ae9e0a2501d5c", "score": "0.66397625", "text": "function getLastBox(bed) {\n\tif (isEmpty(bed))\n\t\treturn undefined;\n\telse {\n\t\treturn bed.boxes.slice(-1).pop();\n\t}\n}", "title": "" }, { "docid": "c4f0637677a724f65f7fe2d1e21e350d", "score": "0.6621205", "text": "function getLastBlockheightAtStartup() {\n if (!source) return;\n rise.blocks\n .getHeight()\n .then(({ height }) => {\n chrome.storage.local.set({ lastseenblockheight: height });\n })\n .catch(() => {\n notifyConnectionProblems('RISE node');\n });\n}", "title": "" }, { "docid": "1dbeef8e8db80a3dbf8a2a3293b48279", "score": "0.6616102", "text": "async latestDsBlock() {\n return await this.baseJsonRpcRequest('GetLatestDsBlock');\n }", "title": "" }, { "docid": "3aca72002c055d2c2d7dbef15641fd89", "score": "0.6611238", "text": "async latestTxBlock() {\n return await this.baseJsonRpcRequest('GetLatestTxBlock');\n }", "title": "" }, { "docid": "a25d5a20eb4e21a57a35dab2fe08a42c", "score": "0.65804833", "text": "last() {\r\n return this.storage[this.storage.length - 1];\r\n }", "title": "" }, { "docid": "065abd7e90165b9d15da444ae17f1a4a", "score": "0.6577737", "text": "last () {\n var len = this.len()\n return this.at(len - 1)\n }", "title": "" }, { "docid": "34235fe1c2eadb29f0dbf9ff96063525", "score": "0.6518915", "text": "async getCurrentBlock (callback) {\n const _this = this;\n _this.ticker += 1;\n\n await this.web3.eth.getBlockNumber(function (error, result) {\n if (!error) {\n callback(result - 1);\n } else {\n console.log(error);\n }\n });\n }", "title": "" }, { "docid": "66f7df419cb66588283428ba1f71cfd7", "score": "0.65082043", "text": "async getCurHeight() {\n let block = await this.getHeadBlock();\n return block ? block.height : -1;\n }", "title": "" }, { "docid": "0c3390412a5218097f3a81e436a7548d", "score": "0.65024066", "text": "last() {\n return this.list[this.length() - 1];\n }", "title": "" }, { "docid": "0c2fa0008c1c8b056d560525c938e9dd", "score": "0.64922094", "text": "function getLastSection(){\n var sectionList = $.personneListe.sections;\n var sectionCount = sectionList.length;\n var lastSection = sectionList[sectionCount - 1];\n\n return lastSection;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "3bf38b75660c2f6df7d7a23f052b5963", "score": "0.6456904", "text": "function getLastLeaf(node) {\n while (node.lastChild && (\n // data-blocks has no offset\n node.lastChild instanceof Element && node.lastChild.getAttribute('data-blocks') === 'true' || getSelectionOffsetKeyForNode(node.lastChild))) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "f68b0f559e56e3d4faaf036f944ee926", "score": "0.6451929", "text": "function lastNoneSpaceChild(block) {\n var childNodes = block.childNodes,\n lastIndex = childNodes.length,\n last = childNodes[lastIndex - 1];\n while (last &&\n (last.nodeType === 3 && !util.trim(last.nodeValue) ||\n last.nodeType === 1 && isEmptyElement(last))) {\n last = childNodes[--lastIndex];\n }\n return last;\n }", "title": "" }, { "docid": "adf519b3a9f8b3adbe8a8b33e8a0d5ea", "score": "0.64455277", "text": "function getLastLeaf(node: any): Node {\n while (\n node.lastChild &&\n // data-blocks has no offset\n ((isElement(node.lastChild) &&\n node.lastChild.getAttribute('data-blocks') === 'true') ||\n getSelectionOffsetKeyForNode(node.lastChild))\n ) {\n node = node.lastChild;\n }\n return node;\n}", "title": "" }, { "docid": "fab0d61392781ed6d647c56fd5f05e89", "score": "0.64246935", "text": "function getLastChunk(chunks) {\n return chunks[chunks.length - 1];\n}", "title": "" }, { "docid": "cbe61999be307efc66df53763b076054", "score": "0.6376634", "text": "function Latest(options, callback) {\n if (options.base) {\n var req = options.base + 'blocks/';\n request(req, function (error, response, body) {\n if (error) callback(error, null);\n try {\n if (JSON.parse(body).status === 200) {\n var data = JSON.parse(body).data.blocks;\n var result = [];\n for (var i = 0; i < data.length; i++) {\n result.push({\n blockHex: null,\n blockId: data[i].hash\n });\n }\n callback(null, result);\n }\n else {\n callback(JSON.parse(body).messages, null);\n }\n }\n catch (err) {\n callback(err, null);\n }\n });\n }\n else {\n callback('error: no address provided', null);\n }\n}", "title": "" }, { "docid": "beb213fac431894a60f46b3b46bc97a1", "score": "0.634664", "text": "static async getLatest() {\n let block = await Block.query()\n .orderBy(\"height\", \"desc\")\n .first();\n\n return block;\n }", "title": "" }, { "docid": "94ae5c9d09bf119711c71082f3702645", "score": "0.6312424", "text": "function last(item){\r\n return item[item.length-1];\r\n }", "title": "" }, { "docid": "94ae5c9d09bf119711c71082f3702645", "score": "0.6312424", "text": "function last(item){\r\n return item[item.length-1];\r\n }", "title": "" }, { "docid": "d8f1041d379e76b615e57f9aa15c8878", "score": "0.6285677", "text": "function last(item){return item[item.length-1];}", "title": "" }, { "docid": "9dbe7f098919a357e7908e17baa26aa1", "score": "0.62732524", "text": "get lastItem() {\n let retv = null\n\n if (this.items.length > 0) retv = this.items[this.items.length -1];\n\n return retv;\n }", "title": "" }, { "docid": "d0dac23596745b4a150e81949f8ef103", "score": "0.62630934", "text": "function last(item){\n return item[item.length-1];\n }", "title": "" }, { "docid": "d0dac23596745b4a150e81949f8ef103", "score": "0.62630934", "text": "function last(item){\n return item[item.length-1];\n }", "title": "" }, { "docid": "abe3d0e9fe0e6bd1970cdc383ce071af", "score": "0.6251379", "text": "function endBlock() {\n var block = peekBlock();\n ts.Debug.assert(block !== undefined, \"beginBlock was never called.\");\n var index = blockActions.length;\n blockActions[index] = 1 /* Close */;\n blockOffsets[index] = operations ? operations.length : 0;\n blocks[index] = block;\n blockStack.pop();\n return block;\n }", "title": "" }, { "docid": "52e3195b7357817d4b46ffe301c87c8b", "score": "0.62374175", "text": "last() { return this.#last; }", "title": "" }, { "docid": "a1ac510cf037b298746fb7ec73b98bf4", "score": "0.6231984", "text": "last () {\r\n return this._last && this._last.value\r\n }", "title": "" }, { "docid": "b1b5ea3c9658f36f45c54cfca2412552", "score": "0.62166095", "text": "last() {\n let result;\n result = this.queue.pop();\n return result;\n }", "title": "" }, { "docid": "a1dd0424861e4a21c399351773a4a6f2", "score": "0.62038684", "text": "tail() {\n return this.body[this.body.length - 1];\n }", "title": "" }, { "docid": "a79e76859f7e20ff6e9b09b562ed3f03", "score": "0.6168519", "text": "last() {\n this.current = this.tail;\n return this.current;\n }", "title": "" }, { "docid": "3343c71a9d80050425248056afa5f8d3", "score": "0.6168324", "text": "last(editor, at) {\n var path = Editor.path(editor, at, {\n edge: 'end'\n });\n return Editor.node(editor, path);\n }", "title": "" }, { "docid": "12dcf7088723d474fe90cafc5296afcf", "score": "0.61484", "text": "last () {\n return this._last && this._last.value\n }", "title": "" }, { "docid": "634c92c1715968c96e08687f1657e345", "score": "0.6140766", "text": "last(editor, at) {\n var path = Editor.path(editor, at, {\n edge: 'end'\n });\n return Editor.node(editor, path);\n }", "title": "" }, { "docid": "cafd1008ab8566d7bb683c0a0e334408", "score": "0.61283416", "text": "getBlockchain(lastBlock = undefined) {\n console.log('getBlockchain');\n if(this.blockchainState != 'init' && this.blockchainState != \"stop\") return;\n console.log(this.blockchainState);\n for(var address of Object.keys(this.nodeRoom)) {\n var socket = this.nodeRoom[address].socket;\n socket.emit('getLastBlockID');\n }\n setTimeout(() => {\n if(this.lastBlockIDArray && this.lastBlockIDArray.length) {\n this.blockchainState = 'processing';\n console.log(this.blockchainState);\n this.lastBlockIDArray.sort((a, b) => Number(b.id) - Number(a.id));\n console.log('last block: ' + this.lastBlockIDArray[0].id)\n this.lastBlockIDArray[0].socket.emit('getBlockchain', lastBlock);\n delete this.lastBlockIDArray;\n this.blockchain_receive_timer = setTimeout(() => {\n console.log('getBlockchain again');\n this.blockchainState = 'stop';\n this.getBlockchain(lastBlock);\n }, config.timegap_for_send_blocks * 10);\n }\n else {\n this.getBlockchain(lastBlock);\n }\n }, 1000);\n }", "title": "" }, { "docid": "f6c4073d37ec4a384dc8e187e7a15896", "score": "0.6125608", "text": "last () {\n return adopt(this.node.lastChild)\n }", "title": "" }, { "docid": "e0a180646a3ffe9a9b90872e0548b094", "score": "0.61019933", "text": "getLast() {\n return this.array[this.length - 1];\n }", "title": "" }, { "docid": "e0a180646a3ffe9a9b90872e0548b094", "score": "0.61019933", "text": "getLast() {\n return this.array[this.length - 1];\n }", "title": "" }, { "docid": "c26dcfba6bae8aa92a7d8a5a9a37677f", "score": "0.6100949", "text": "invalidateLatestBlock() {\n return new Promise((resolve, reject) => {\n if (this.blocks.length <= 0) {\n reject(new Error('no block available'));\n } else {\n let lastBlock = this.blocks[this.blocks.length - 1];\n this._calculate(lastBlock, true);\n this.blocks.pop();\n\n resolve(null);\n }\n });\n }", "title": "" }, { "docid": "bf56b739b8221103fa001dea892becf9", "score": "0.6097", "text": "function last() {\n return _navigationStack[_navigationStack.length - 1];\n }", "title": "" }, { "docid": "f9704fba3d511f67b7a375b8d947771d", "score": "0.609278", "text": "last() {\n return this._last && this._last.value;\n }", "title": "" }, { "docid": "e7078ca467c9b7e197e6c08831e30be2", "score": "0.60909504", "text": "_lastNode() {\n let node = this.rootNode\n while (node.next !== undefined) {\n node = node.next\n }\n return node\n }", "title": "" }, { "docid": "0b240cc7c80bcb715ddd650340840d22", "score": "0.6088484", "text": "last () {\r\n return adopt(this.node.lastChild)\r\n }", "title": "" }, { "docid": "98c784729252f4eb6fa8dd55a6231972", "score": "0.6075796", "text": "getLast() {\n let lastNode = this.head;\n if (lastNode) {\n while (lastNode.next) {\n lastNode = lastNode.next; //this it's at the end we need to keep going to until the moment we hit the a null as lastNode.next.\n }\n return lastNode;\n }\n }", "title": "" }, { "docid": "3c916231b8b5fe1bafc062c9af950cfc", "score": "0.6069625", "text": "getBlock(blockHeight) {\n\t\treturn level.getLevelDBData(blockHeight);\n\t}", "title": "" }, { "docid": "9ad58a89580170d73335feebd202b78d", "score": "0.6053899", "text": "top() {\n return this.contents[this.contents.length - 1]\n }", "title": "" }, { "docid": "e91953d4c22f6c0cfe6e16779ef0090c", "score": "0.6053587", "text": "getUltimoBloco() {\n return this.blocos[this.blocos.length - 1]\n }", "title": "" }, { "docid": "1f74886a94985f55922d6daa51ab9262", "score": "0.6051683", "text": "peek(){\n console.log(`The last item is ${this.items[this.count - 1]}`);\n return this.items[this.count - 1];\n }", "title": "" }, { "docid": "a729fb29c528f9a453600231c84109e4", "score": "0.60499567", "text": "function getIthBlockFromEnd(i, file) {\n let blockSizeInBytes = 16;\n if (fs.existsSync(file)) {\n let fileSizeInBytes = fs.statSync(file)[\"size\"];\n if (fileSizeInBytes >= i * blockSizeInBytes) {\n let start = fileSizeInBytes - i * blockSizeInBytes;\n let length = Math.min(fileSizeInBytes - start, blockSizeInBytes);\n return readBytesFromFile(file, start, length);\n }\n }\n\n return null;\n}", "title": "" }, { "docid": "13e48ef9342bf13dd2631cebe7c110e4", "score": "0.60396457", "text": "last() {\n return adopt(this.node.lastChild);\n }", "title": "" }, { "docid": "98ee29ce244efd44214228444956c023", "score": "0.60247165", "text": "getBlock(blockHeight){\n var self = this;\n return getLevelDBData(blockHeight).then(function(data) {\n var getBlock_msg = \"Your Block is: \" + data;\n //console.log(\"=\".repeat(10));\n console.log(self.comments().replace(\"{0}\", getBlock_msg));\n //console.log(\"=\".repeat(10));\n\n return data;\n });\n }", "title": "" }, { "docid": "6c5e4c6cea49e1b008d8a536b9abc1c6", "score": "0.6024372", "text": "get lastChild() { return this.childBefore(this.end + 1); }", "title": "" }, { "docid": "159231f5cb24e92792c1291619704446", "score": "0.6018408", "text": "lastChild() {\n return this.enterChild(-1, 0, 4 /* Side.DontCare */)\n }", "title": "" }, { "docid": "d54f852d919c94dff69b5df92b0b2052", "score": "0.60038877", "text": "function get_last_item_in_row(elem){\n \tvar last = $();\n \tvar same_scope = false; \n\t\t\n\t\t$(run_on).find(elem).each(function(index, value){\n\t \t\teach_from_top = $(this).offset().top;\n\t \t\tif(each_from_top == abs_from_top){\n\t \t\t\tlast = $(this);\n\t \t\t}\n\t });\n\n \trecent_item_id = $(last).attr('id');\n\t return last;\n\t}", "title": "" }, { "docid": "3f3ecfcc2e32ef4f1b50b8e0a019bb3b", "score": "0.59891796", "text": "getCurrentHeight () {\n return this.chainLength - 1\n }", "title": "" }, { "docid": "4267f9496a135e605d5f8b0b4ad69407", "score": "0.59835714", "text": "getBlockHeight(){\n return new Promise((resolve, reject) => { \n\t\tthis.db.getBlocksCount().then((blockCount)=>{\n\t\t\tif(blockCount>=0) resolve(blockCount-1);\n\t\t}).catch((err) => { console.log(err); reject(\"Block count error\");}); \n\t });\n }", "title": "" }, { "docid": "e48f17182b9f7d340832e6b9025d0f35", "score": "0.5974605", "text": "getSelectedBlock(editorState) {\n if (editorState) {\n return this.getSelectedBlocksList(editorState).get(0)\n }\n return undefined\n }", "title": "" }, { "docid": "692447c7cb3a31f5113bcf893d70366e", "score": "0.59675115", "text": "function get_block_position( itm_block ){\n\t\t\t\tvar min_index = stack_length.indexOf( get_min_val(stack_length) );\n\t\t\t\tvar size = get_size_block( itm_block );\n\t\t\t\tvar out = [];\n\n\t\t\t\t// если в одну колонку влезает\n\t\t\t\tif( size[0] == 1 )\n\t\t\t\t{\n\t\t\t\t\tout.push( stack_length[min_index] * ( single_size + opt.distance ) );\n\t\t\t\t\tout.push( min_index * (single_size + opt.distance) );\n\t\t\t\t\tstack_length[min_index] = stack_length[min_index] + size[1];\n\n\t\t\t\t\t// более чем в один блок\n\t\t\t\t} else {\n\t\t\t\t\tvar time_steck_length = stack_length.concat(); \t\t//\tвременная переменная для хранения длинн\n\t\t\t\t\tvar sub_max = get_max_val( time_steck_length.slice(min_index,min_index+size[0]) );\n\n\t\t\t\t\twhile( out.length == 0 )\n\t\t\t\t\t{\n\t\t\t\t\t\tmin_index = time_steck_length.indexOf( get_min_val(time_steck_length.slice(0, time_steck_length.length - size[0] + 1)) );\n\t\t\t\t\t\tsub_max = get_max_val( time_steck_length.slice(min_index,min_index+size[0]) );\n\n\t\t\t\t\t\tif( sub_max != time_steck_length[min_index] ){\n\t\t\t\t\t\t\ttime_steck_length[min_index] = time_steck_length[min_index] + 1;\n\t\t\t\t\t\t\tmin_index = time_steck_length.indexOf( get_min_val(time_steck_length) );\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tout.push( time_steck_length[min_index] * ( single_size + opt.distance ) );\n\t\t\t\t\t\t\tout.push( min_index*(single_size + opt.distance) );\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\n\t\t\t\t\tsub_max = size[1] + time_steck_length[min_index];\n\t\t\t\t\tfor (var i = min_index; i < min_index + size[0]; i++) {\n\t\t\t\t\t\tstack_length[i] = sub_max;\n\t\t\t\t\t}\n\n\t\t\t\t}\n\n\n\t\t\t\treturn out;\n\t\t\t}", "title": "" }, { "docid": "fe5d95de5dea8ccf36660a668f0d0f70", "score": "0.59559685", "text": "async getBlock(blockheight) {\n let block = await this.chain.get(this.lexi(blockheight))\n return JSON.parse(block);\n }", "title": "" }, { "docid": "0ad289aaacbade40bd34bff50af5d60a", "score": "0.59494257", "text": "getBlockHeight()\n {\n var self = this;\n return getCompleteBlocksDBData().then(function(data) {\n var blockchain_height = \"Your Blockchain height is: \" + (data ? data.length : -1);\n console.log(self.comments().replace(\"{0}\", \"=\".repeat(blockchain_height.length)));\n console.log(self.comments().replace(\"{0}\", blockchain_height));\n console.log(self.comments().replace(\"{0}\", \"=\".repeat(blockchain_height.length)));\n\n return data ? data.length : -1;\n })\n }", "title": "" }, { "docid": "59c6faabefb1e76948bfdfd6e655fa35", "score": "0.5928502", "text": "function blkDefHere() {\r\n return blkDefAt(idxHere());\r\n }", "title": "" }, { "docid": "5ebbfc78c3f189e36c574f457483816c", "score": "0.5922548", "text": "get end() {\n return this._jumps[this._jumps.length - 1];\n }", "title": "" }, { "docid": "ce8b1ed6753640c0b5b73956003f590f", "score": "0.5922286", "text": "function end() {\n doc.blocks.push(currentBlock);\n\n setCurrentBlock();\n // console.log(...doc.blocks.map(b => b.tags));\n // reset block var (new it)\n // end of read, handle end of class/file\n // get function name as this is after comment block\n }", "title": "" }, { "docid": "f9127646d695dbfec2013236613874c6", "score": "0.5920876", "text": "getLast () {\n\t\tlet lastNode = this.head;\n\t\t\n\t\tif (lastNode) {\n\t\t\twhile (lastNode.next) {\n\t\t\t\tlastNode = lastNode.next;\n\t\t\t}\n\t\t}\n\n\t\treturn lastNode;\n\t}", "title": "" }, { "docid": "f0a6fe3347777b14645e5ecb16242f03", "score": "0.59199256", "text": "function FetchNextLogicalBlock(keyfactory, callback) {\n var data = null;\n var i = 0;\n\n\t// Given a key, fetches and authenticates a block before returning it.\n\tfunction FetchPhysicalBlock(key, callback) {\n\t blockstore.get(key, function HMACCheckerCallback(err, data) {\n\t if (err)\n\t return callback(err);\n\t var calculated_hmac_value = GetHMAC(key, data).digest('hex');\n\t var block_hmac_value = data.slice(data.length - 32, data.length);\n\t if (calculated_hmac_value != block_hmac_value.toString('hex')) {\n\t return callback(\"Block HMAC mismatch. (\" +\n\t\t\t calculated_hmac_value + \" != \" +\n\t\t\t block_hmac_value.toString('hex') + \")\");\n\t }\n\t callback(null, data.slice(0, data.length - 32));\n\t });\n\t}\n\n function ReplicaAttempt(err, data) {\n i++;\n if (err) {\n if (i < num_replicas)\n FetchPhysicalBlock(keyfactory.next(), ReplicaAttempt);\n else\n callback(\"Error reading block: \" + err);\n } else {\n // Skip remaining replicas.\n while (i < num_replicas) {\n keyfactory.next();\n i++;\n }\n callback(null, data);\n }\n }\n FetchPhysicalBlock(keyfactory.next(), ReplicaAttempt);\n }", "title": "" }, { "docid": "f5056d986a0006b4cd24ba29b135bbd1", "score": "0.591657", "text": "function aaObtainFurthestBlock(p, formattingElementEntry) {\n\t var furthestBlock = null;\n\t\n\t for (var i = p.openElements.stackTop; i >= 0; i--) {\n\t var element = p.openElements.items[i];\n\t\n\t if (element === formattingElementEntry.element)\n\t break;\n\t\n\t if (p._isSpecialElement(element))\n\t furthestBlock = element;\n\t }\n\t\n\t if (!furthestBlock) {\n\t p.openElements.popUntilElementPopped(formattingElementEntry.element);\n\t p.activeFormattingElements.removeEntry(formattingElementEntry);\n\t }\n\t\n\t return furthestBlock;\n\t}", "title": "" }, { "docid": "c5aa5184deceafd23b07fa5d5c3ea2fe", "score": "0.5915782", "text": "_readEndBlockData() {\n this._readBlock([constants.TC_ENDBLOCKDATA]);\n }", "title": "" }, { "docid": "bf26a2e174709a6f24d94aef902252ed", "score": "0.59060496", "text": "function last(stack) {\n\t return stack[stack.length - 1];\n\t}", "title": "" }, { "docid": "01203eb4a4dd5e20b5aa70a9d2adfc33", "score": "0.58987933", "text": "function getBlock(blockHeight){\n\t\tdb.get(blockHeight,function(err,value){\n\t\t\tif(!err){\n let block = JSON.parse(value);\n console.log('block: '+block);\n return block;\n\t\t\t}else{\n console.log('something wrong when get Block');\n\t\t\t}\n\t\t});\n\t}", "title": "" } ]
3441215ea4c1d3610088dcd827feb9bc
It will be Triggered when the user says "Alexa, open neuro centre"
[ { "docid": "2497d73d06788fd775b4a2cbd46605f1", "score": "0.0", "text": "'LaunchRequest'() {\n this.emit(':ask', instructions);\n }", "title": "" } ]
[ { "docid": "8651378ac40bf1450e0d4c3ece398f06", "score": "0.60848945", "text": "function onYesClick() {\n\n\tif(sectionIndex < storySections.length) {\n\t\tconsole.log(\"ony_yes_click - section index: \" + sectionIndex);\n\t\tlet innerText = injectNameToSection( \"I like the way you think! <br/><br/>\" + getCurrentSection());\n\t\tsetInnerText(storySectionID, innerText);\n\t\tutter(getUtteraance(innerText));\n\t\tsectionIndex++;\n\t\tsetInterface()\n\t}\n\telse if(sectionIndex >= storySections.length){\n\t\tsetInnerText(storySectionID, endOfExperiment);\n\t\tsetEndOfStoryInterface();\n\t}\n}", "title": "" }, { "docid": "56f42a7ba082d8ed07e9a12049da154b", "score": "0.59992903", "text": "function handleWelcomeRequest(response) {\n var whichCityPrompt = \"Which city would you like tide information for?\",\n speechOutput = {\n speech: \"<speak>Welcome to Tide Pooler. \" +\n \"<audio src='https://s3.amazonaws.com/ask-storage/TvGuide/OceanWaves.mp3'/>\" +\n whichCityPrompt +\n \"</speak>\",\n type: AlexaSkill.speechOutputType.SSML\n },\n repromptOutput = {\n speech: \"I can lead you through providing a city and \" +\n \"day of the week to get tide information, \" +\n \"or you can simply open Tide Pooler and ask a question like, \" +\n \"get tide information for Seattle on Saturday. \" +\n \"For a list of supported cities, ask what cities are supported. \" +\n whichCityPrompt,\n type: AlexaSkill.speechOutputType.PLAIN_TEXT\n };\n\n response.ask(speechOutput, repromptOutput);\n}", "title": "" }, { "docid": "5f734a635ad272888aaf71ccb2479846", "score": "0.5940123", "text": "function welcomeIntent(assistant){\n assistant.ask('Welcome to action snippets. say a number')\n }", "title": "" }, { "docid": "b3b02386fa4265a5e58d8bba34543921", "score": "0.59173745", "text": "areYouSure(cb, ev) {\n\n this.textbox.addMessage(\n ev.loc.dialogue.general[3]\n );\n this.textbox.activate((ev, state) => {\n\n cb(ev, state);\n });\n this.textbox.doNotResumeMusic();\n }", "title": "" }, { "docid": "0396c3ba7bbe0f8aa05902319cfb9452", "score": "0.58945686", "text": "function aliceClimateOpinion() {\n let beginOpinion = beginOpinions[Math.floor(Math.random() * beginOpinions.length)];\n\n let generatingClimateOpinion = climateOpinions[Math.floor(Math.random() * climateOpinions.length)];\n responsiveVoice.speak(beginOpinion + generatingClimateOpinion, 'UK English Female');\n}", "title": "" }, { "docid": "a162c49091df004c9563f96eb9089a79", "score": "0.5837835", "text": "function makeAnnouncement() {\n responsiveVoice.speak(`You are hacking into the mainframe`, `UK English Female`, voiceParameters);\n}", "title": "" }, { "docid": "ca9ed93dbbef8cf89876547715d2b07d", "score": "0.5800395", "text": "function identify() {\r\n\tspeak(\"I am a smart suitcase designed by Bits Please. I am currently under the ownership of \" + title + \" \" + user);\r\n}", "title": "" }, { "docid": "6487d89fd3b6e8faf122d052cef354cc", "score": "0.57818264", "text": "[Actions.WELCOME] () {\n return this.app.ask(BasicResponses.GREET_USER);\n }", "title": "" }, { "docid": "c69ede689061f2fdbc841097813f4034", "score": "0.5775999", "text": "function myIntentHandler(session, msg) {\r\n session.sendTyping();\r\n builder.LuisRecognizer.recognize(msg, LuisModelUrl,\r\n function (err, intents, entities) {\r\n if (err) {\r\n console.log(\"LUI Error: \"+ err);\r\n session.send('Something went wrong. Type **Hello** to start over.');\r\n }\r\n \r\n if(intents[0].intent!=null && intents[0].score > (process.env.INTENTSCORETHRLD)){\r\n \r\n if(process.env.SPLUNKTOGGLE==\"ON\")\r\n {\r\n splunk.log('Conversation: ', { \"conversationId\": session.message.address.conversation.id,\"userid\" : session.message.address.user.userid,\"username\" : session.message.address.user.name ,\"UserMessage\" : session.message.text, \"Intent_Score\": intents[0].score,\"Intent\": intents[0].intent ,\"type\": \"PredictedIntent\", env: process.env.SPLUNK_ENV});\r\n }\r\n \r\n bActiveNone = false;\r\n switch (intents[0].intent) {\r\n case'quote.new':\r\n session.beginDialog('quote.new',{intent:intents[0].intent , entities:entities});\r\n break;\r\n case'report.order':\r\n session.beginDialog('report.order',{intent:intents[0].intent , entities:entities});\r\n break;\r\n case'training.find':\r\n session.beginDialog('training.find',{intent:intents[0].intent , entities:entities});\r\n break;\r\n case'term.define':\r\n session.beginDialog('term.define',{intent:intents[0].intent , entities:entities});\r\n break;\r\n case'policy.umbrella.add':\r\n session.beginDialog('policy.umbrella.add',{intent:intents[0].intent , entities:entities});\r\n break;\r\n case'None':\r\n bActiveNone = true;\r\n if (msg.match(process.env.REGEXEXP)) // Check whether the input contains a 10 digit US phone number\r\n \r\n {\r\n noneSecondResp(session);\r\n break;\r\n }\r\n else\r\n {\r\n session.beginDialog('None',{intent:intents[0].intent , entities:entities});\r\n break;\r\n }\r\n default:\r\n if (msg.match(process.env.REGEXEXP)) // Check whether the input contains a 10 digit US phone number\r\n \r\n {\r\n noneSecondResp(session);\r\n break;\r\n }\r\n else\r\n {\r\n session.beginDialog('defaultDialog',{\"intent\":intents[0].intent , \"entities\":entities});\r\n break;\r\n }\r\n }\r\n }\r\n else{\r\n if(bActiveNone==false){\r\n bActiveNone = true;\r\n if (msg.match(process.env.REGEXEXP)) // Check whether the input contains a 10 digit US phone number\r\n \r\n {\r\n noneSecondResp(session);\r\n }\r\n else\r\n {\r\n session.beginDialog('None',{intent:intents[0].intent , entities:entities});\r\n }\r\n }\r\n else{\r\n bActiveNone = false;\r\n noneSecondResp(session); \r\n }\r\n }\r\n });\r\n}", "title": "" }, { "docid": "445b8ace53f6ddd41de566db277291b9", "score": "0.57612765", "text": "say(text) {\n const event = { event_name: 'furhatos.event.actions.ActionSpeech', text };\n this.send(event);\n }", "title": "" }, { "docid": "5467423f2544353c113b50295774af7f", "score": "0.57227284", "text": "function onStartAttentionGame(e) {\n\tTi.API.info('onStartAttentionGame : ', JSON.stringify(e));\n\tif (e.itemIndex == 0) {\n\t\tif (e.bindId == \"mindGameViewLeft\" || e.bindId == \"mindGameLabel1\") {\n\t\t\tAlloy.Globals.NAVIGATION_CONTROLLER.openWindow('cognitionInstruction', {\n\t\t\t\t'gameID' : 13,\n\t\t\t});\n\n\t\t} else if (e.bindId == \"mindGameViewRight\" || e.bindId == \"mindGameLabel2\") {\n\t\t\tAlloy.Globals.NAVIGATION_CONTROLLER.openWindow('cognitionInstruction', {\n\t\t\t\t'gameID' : 15,\n\t\t\t});\n\n\t\t}\n\n\t} else if (e.itemIndex == 1) {\n\t\tif (e.bindId == \"mindGameViewLeft\" || e.bindId == \"mindGameLabel1\") {\n\t\t\tAlloy.Globals.NAVIGATION_CONTROLLER.openWindow('jewelsTrailsIntro');\n\n\t\t} else if (e.bindId == \"mindGameViewRight\" || e.bindId == \"mindGameLabel2\") {\n\n\t\t\tAlloy.Globals.NAVIGATION_CONTROLLER.openWindow('jewelsTrailsIntroB');\n\t\t}\n\n\t} else if (e.itemIndex == 2) {\n\t\tif (e.bindId == \"mindGameViewLeft\" || e.bindId == \"mindGameLabel1\") {\n\t\t\tAlloy.Globals.NAVIGATION_CONTROLLER.openWindow('cognitionInstruction', {\n\t\t\t\t'gameID' : 2,\n\t\t\t});\n\n\t\t} else if (e.bindId == \"mindGameViewRight\" || e.bindId == \"mindGameLabel2\") {\n\t\t\tAlloy.Globals.NAVIGATION_CONTROLLER.openWindow('cognitionInstruction', {\n\t\t\t\t'gameID' : 7,\n\t\t\t});\n\n\t\t}\n\n\t}\n}", "title": "" }, { "docid": "1b929eb15e705a72946545592f3bd715", "score": "0.5711", "text": "function byeResponse (app) {\n app.tell({speech: 'Okay see you later',\n displayText: 'OK see you later!'});\n }", "title": "" }, { "docid": "24c0dd9cde7cdac8928fedeed7934cf0", "score": "0.57050705", "text": "nirvana() {\n playAudio(soundsLikeTeenSpirit)\n $restartBtn.style.display = 'inherit';\n $restartBtn.innerText = \"REINCARNATE ANYWAYS\"\n $messageOverlay.style.display = 'inherit';\n $messageOverlay.innerText = \"CONGRATS! YOU HAVE REACHED NIRVANA.\"\n }", "title": "" }, { "docid": "eb35bafd2f3381857da94457612f3604", "score": "0.5699695", "text": "handleYesClick() {\n this.postUserInterest(true);\n this.clearBookSuggestion();\n this.getBookSuggestion();\n }", "title": "" }, { "docid": "36f32f9a6e519ffdd0926cdc20641297", "score": "0.568318", "text": "function runAnnyang(){if (annyang) {\n\t //carriage return on the command comma\n\t \tvar commands = {\n\t\t 'comma': function() {\n\t\t \tFSGlobal.$handJammerNumbers.val( FSGlobal.$handJammerNumbers.val() + '\\n');\n\t\t \tconsole.log(\"i hear you\");\n\t\t \treturn FSGlobal.$handJammerNumbers.val();\n\t\t \t }\n\t \t };\n\n\t // Add our commands to annyang\n\t \t annyang.addCommands(commands);\n\t // Start listening. You can call this here, or attach this call to an event, button, etc.\n\t \tannyang.start();\n\t\t}\n\n\t}", "title": "" }, { "docid": "007804931b2ed99469b7c90a02b63178", "score": "0.568261", "text": "function helpTheUser(intent, session, response) {\n var speechText = \"I can remind you about upcoming Indian festivals. You just need to ask me, which are upcoming festivals?\";\n var repromptText = \"<speak> I'm sorry I didn't understand that. You can say things like, \" +\n \"Which are upcoming festivals ? <break time=\\\"0.2s\\\" /> \" +\n \"Which festivals are coming now ? <break time=\\\"0.2s\\\" /> \" +\n \"Now, what can I help you with? </speak>\";\n\n var speechOutput = {\n speech: speechText,\n type: AlexaSkill.speechOutputType.PLAIN_TEXT\n };\n var repromptOutput = {\n speech: repromptText,\n type: AlexaSkill.speechOutputType.PLAIN_TEXT\n };\n response.ask(speechOutput, repromptOutput);\n}", "title": "" }, { "docid": "0b37142acb15120e40eb1a7c44decda6", "score": "0.56766015", "text": "function optionOneWasClicked() {\n console.log(\"Jumped into the chasm\");\n\n // check if Gungurk still appears as an ally of if he fell first.\n\n // if he did go here\n\n // if he is still with you go here\n}", "title": "" }, { "docid": "2f646993139b7923dcd84a155a93f068", "score": "0.5657253", "text": "function C008_DramaClass_AmandaIntro_Click() {\t\n\n\t// Regular and inventory interactions\n\tClickInteraction(C008_DramaClass_AmandaIntro_CurrentStage);\n\tvar ClickInv = GetClickedInventory();\n\t\n\t// Amanda can take the keys if the player is too submissive\n\tif (ClickInv == \"CuffsKey\")\n\t\tC008_DramaClass_AmandaIntro_TakeKey();\n\n\t// Amanda will not accept any item when she's dressed\n\tif (((ClickInv == \"Rope\") || (ClickInv == \"Armbinder\") || (ClickInv == \"Cuffs\") || (ClickInv == \"TapeGag\") || (ClickInv == \"BallGag\") || (ClickInv == \"ClothGag\") || (ClickInv == \"ChastityBelt\") || (ClickInv == \"VibratingEgg\")) && (C008_DramaClass_AmandaIntro_CurrentStage < 20))\n\t\tOverridenIntroText = GetText(\"StripBeforeFun\");\n\n\t// Amanda will not accept any item when she's costumed\n\tif (((ClickInv == \"Rope\") || (ClickInv == \"Armbinder\") || (ClickInv == \"Cuffs\") || (ClickInv == \"TapeGag\") || (ClickInv == \"BallGag\") || (ClickInv == \"ClothGag\") || (ClickInv == \"ChastityBelt\") || (ClickInv == \"VibratingEgg\")) && (C008_DramaClass_AmandaIntro_CurrentStage == 50))\n\t\tOverridenIntroText = GetText(\"CostumeBlocksFun\");\n\t\n\t// Amanda can be restrained on stage 40\n\tif ((C008_DramaClass_AmandaIntro_CurrentStage == 40) && (ClickInv != \"\") && (ClickInv != \"Player\") && !Common_PlayerRestrained) {\n\t\n\t\t// Amande doesn't like the crop but becomes more submissive\n\t\tif ((ClickInv == \"Crop\") && (!C008_DramaClass_AmandaIntro_CropDone)) {\n\t\t\tC008_DramaClass_AmandaIntro_CropDone = true;\n\t\t\tActorChangeAttitude(-1, 1);\n\t\t\treturn;\n\t\t}\n\n\t\t// Amande cannot be tied up if she's not at least a little submissive\n\t\tif ((ActorGetValue(ActorSubmission) < 2) && (ClickInv != \"CuffsKey\")) {\n\t\t\tOverridenIntroText = GetText(\"RefuseBondage\");\n\t\t\treturn;\t\t\t\n\t\t}\n\n\t\t// Amanda can refuse the belt if she's not submissive enough or not tied up\n\t\tif ((ClickInv == \"ChastityBelt\") && !C008_DramaClass_AmandaIntro_IsRestrained && (ActorGetValue(ActorSubmission) < 10)) {\n\t\t\tOverridenIntroText = GetText(\"RefuseBelt\");\n\t\t\treturn;\n\t\t}\n\t\n\t\t// Apply the clicked restrain\n\t\tActorApplyRestrain(ClickInv);\n\t\tC008_DramaClass_AmandaIntro_CalcParams();\n\n\t}\n\n}", "title": "" }, { "docid": "187d5578a3250adc1c1164a6c56b33ba", "score": "0.56541497", "text": "function C008_DramaClass_AmandaIntro_Changing() {\n\tC008_DramaClass_AmandaIntro_ChangingCount++;\n\tif (C008_DramaClass_AmandaIntro_ChangingCount >= 3) {\n\t\tOverridenIntroText = GetText(\"ChangeComplete\");\n\t\tActorChangeAttitude(1, 0);\n\t\tC008_DramaClass_AmandaIntro_CurrentStage = 50;\n\t\tC008_DramaClass_AmandaIntro_Costume();\n\t\tLeaveIcon = \"Leave\";\n\t}\n}", "title": "" }, { "docid": "3ddeff977d9d66582e7c606378e0edf0", "score": "0.56503516", "text": "function annyangSetup() {\n // Making sure annyang is available\n if (annyang) {\n // Add commands to annyang - it should listen\n let commands = {\n // Saying 'My name is X' triggers the name function\n \"My name is *tag\": name,\n // Saying 'Yes' triggers topics function\n \"Yes\": topics,\n // Saying 'No' triggers tryAgain function - simply asking them to try again\n \"No\": tryAgain,\n // Saying 'Climate' triggers tryAgain showClimateContent function\n \"Climate\": showClimateContent,\n // Saying 'Politics' triggers tryAgain showPoliticsContent function\n \"Politics\": showPoliticsContent,\n // Saying 'Medicine' triggers tryAgain showMedicineContent function\n \"Medicine\": showMedicineContent\n };\n\n // The name command has been defined so give it to annyang\n // by using the .addCommands() function\n annyang.addCommands(commands);\n\n // Tell annyang to start listening\n // by using the .start() function\n annyang.start();\n }\n}", "title": "" }, { "docid": "22fa7654e52d56bcdd527fc133acbe58", "score": "0.56487924", "text": "function help(intentRequest, callback) {\n \tconst outputSessionAttributes = intentRequest.sessionAttributes;\n\tconst source = intentRequest.invocationSource;\n\t\n\tif (source === 'DialogCodeHook') {\n\t\t// perform validation on the slot values we have\n\t\tconst slots = intentRequest.currentIntent.slots;\t\t\n\t\t\n\t\t// if we've come this far, then we simply defer to Lex\n\t\tcallback(delegate(outputSessionAttributes, slots));\n\t\treturn;\n\t\t\n\t}\n\t\n\tcallback(close(outputSessionAttributes, 'Fulfilled', {\n\t\tcontentType: 'PlainText',\n\t\tcontent: 'To get started, says something like: \"I would like to make a payment.\" And you will be guided to complete the process.'\n\t}));\t\n }", "title": "" }, { "docid": "cfc1838ca979cf5ddfac9c2eb3673bf5", "score": "0.56425", "text": "function title() {\n background(255);\n\n push();\n textSize(30);\n fill(0);\n text(`A Game of guessing cars`, width / 2 - 10, height / 7);\n push();\n textSize(10);\n text(`Click on the picture`, width / 2 - 10, 700);\n pop();\n\n image(brandsImage, width / 2, height / 2, 700, 550);\n\n // if the user says yes, the state switches to the game\n // if the user says no, the user is prompted to basically say yes\n if (annyang) {\n let commands = {\n 'Yes': function() {\n state = `play`;\n },\n 'No': function() {\n alert(`Say yes please i wrote a lot of codes for this`);\n }\n };\n annyang.addCommands(commands);\n annyang.start();\n }\n}", "title": "" }, { "docid": "9788301cb5a29704d1f01ca66df67e19", "score": "0.5635468", "text": "function addAI(event) {\n let $draft = draft;\n if ($draft) $draft += \"\\n\";\n $draft += `@${ai_owner}: ${ai_text}`;\n\n setAiOwner(item.shepherd);\n setAiText('');\n setDraft($draft);\n }", "title": "" }, { "docid": "d69f05684da13fb65768e3cfdbcd1979", "score": "0.5623902", "text": "function handleStatusRequest(intent, session, response) {\n\t var setpoint = intent.slots.setpoint;\n var temp = intent.slots.temp;\n\t \n\t\n var repromptText = \"With Aprilaire, you can control thermostat. For example, you could say set heat point to 70 Fahrenheit . Now, what do you want to change?\";\n \n var sessionAttributes = {};\n // Read the first 3 events, then set the count to 3\n sessionAttributes.index = paginationSize;\n \n // If the user provides a date, then use that, otherwise use today\n // The date is in server time, not in the user's time zone. So \"today\" for the user may actually be tomorrow\n var cardTitle=\"Aprilaire\";\n var content = \"Events On\";\n \n getJsonEvents(setpoint, temp, function (events) {\n var prefixContent =\"\"\n\t \n\t var speechText = \"\";\n sessionAttributes.text = events;\n session.attributes = sessionAttributes;\n if (events.length == 0) {\n speechText = \"There is a problem connecting to thermostat at this time. Please try again later.\";\n response.tell(speechText);\n } else {\n for (i = 0; i < 1; i++) {\n speechText = speechText + events[i] + \" \";\n }\n // speechText = speechText + \" Wanna go deeper in history?\";\n response.askWithCard(prefixContent + speechText, repromptText, cardTitle, speechText);\n }\n });\n }", "title": "" }, { "docid": "e89e4907a724a6d67b72a232309da13b", "score": "0.5618718", "text": "function start() {\n $('#click-to-start').remove();\n\n // Initialise annyang with no commands (because we just want to listen to whatever it hears)\n annyang.init({});\n // Whenever something is heard, handle it as input to Eliza\n annyang.addCallback('result', handleSpeech);\n // Start the engine\n annyang.start();\n // Create our eliza chatbot for processing the responses\n eliza = new ElizaBot();\n // Get Eliza's opening statement\n let initial = eliza.getInitial();\n // Say it\n responsiveVoice.speak(initial, currentVoice);\n}", "title": "" }, { "docid": "dbaf768ec972d8da5266d254785f96ec", "score": "0.5617717", "text": "function receivedMessage(event) {\n let sender = event.sender.id;\n let text = event.message.text;\n\n let apiai = apiaiApp.textRequest(text, {\n sessionId: 'tabby_cat'\n });\n\n apiai.on('response', (response) => {\n let aiText = response.result.fulfillment.speech;\n console.log(aiText);\n\n switch (aiText) {\n case 'SHOW_BIOGRAPHY':\n prepareSendBio(sender);\n break;\n\n default:\n prepareSendAiMessage(sender, aiText);\n }\n\n });\n\n apiai.on('error', (error) => {\n console.log(error);\n });\n\n apiai.end();\n}", "title": "" }, { "docid": "c614c7d24ce65884b0519f41e4968a29", "score": "0.5600312", "text": "function introText() {\n console.log('\\n*************** - Welcome LiriBot - *************** \\n\\n - Here are your options, please select one of the commands to run below - \\n');\n console.log('** Type \\'my-tweets\\' to see the last 20 Tweets I wrote **');\n console.log('** Type \\'spotify-this-song\\' \\'Song Name\\' to get information about a song from Spotify **');\n console.log('** Type\\'movie-this\\' \\'movie title\\' to get information about a movie from IMDB **');\n console.log('** Type \\'do-what-it-says\\' to generate a predefined function and parameter **');\n console.log('\\n**************** - Thanks - ********************** \\n');\n}", "title": "" }, { "docid": "5eeb7ff2b7539b657e0211dfff734fb6", "score": "0.5588776", "text": "handleInteraction() {\n //when a letter is clicked, check if it matches anything in the phrase\n}", "title": "" }, { "docid": "bcefcfbb1f125f45331895701bf57509", "score": "0.5580821", "text": "function onOpen(e) {\n if(TwtrService.isUserConnectedToTwitter()) {\n SlidesApp.getUi().createAddonMenu().addItem(\"Launch Player\", \"openPlayer\").addItem(\"Disconnect Account\" , \"disconnect\").addToUi();\n } else {\n SlidesApp.getUi().createAddonMenu().addItem(\"Connect Account\", \"setup\").addToUi();\n }\n}", "title": "" }, { "docid": "1c1f471f58954fc52a39e3f6a541b4bf", "score": "0.55598336", "text": "handleInteraction(e) {\n // Handle interacted events\n if (e.data.statement.verb.id !== \"http://adlnet.gov/expapi/verbs/interacted\") {\n return;\n }\n\n // Make sure there was a results response\n let results = e.data.statement.result.response;\n\n // Trim if string\n if (results.trim) {\n results = results.trim();\n }\n\n this.answered = !!results.length;\n this.trigger('handledInteraction');\n }", "title": "" }, { "docid": "f3312e31dfb5691b2db36ce8809a6126", "score": "0.55575055", "text": "function askQuestionOnClick(code){\n 'use strict';\n var regionName = app.map.getRegionName(code);\n swalPrompt(regionName, code);\n }", "title": "" }, { "docid": "5dbf4611e4ab0f37bc17dd07835166bd", "score": "0.55556756", "text": "handlesMessage(event, message){\n const intent = FirstEntity(event.message.nlp, 'intent');\n const news = \"wants_news\";\n\n if (intent && intent.value == news && intent.confidence > 0.8) {\n return true;\n }\n return false;\n }", "title": "" }, { "docid": "409248d691c1beea05807ec45f2c1eba", "score": "0.55463344", "text": "function robotwelcome() {\n const welcomeSpeech = new SpeechSynthesisUtterance();\n welcomeSpeech.text = \"Welcome to MDX Financial Support\"\n window.speechSynthesis.speak(welcomeSpeech);\n welcome(welcomeSpeech.text);\n}", "title": "" }, { "docid": "da89d90a58cee0fc13f2efe7b4fa8d0d", "score": "0.55369306", "text": "function changeHandler(event) {\n var userInput = event.target.value; /*reading the input*/\n\n var meaning = emojiDictionary[userInput]; /*matching the meaning*/\n\n if (meaning === undefined) {\n meaning = \"Senator,sorry! we do not know about him.\";\n }\n /*console.log(meaning)logging the meaning in console*/\n\n setEmojiMeaning(meaning);\n }", "title": "" }, { "docid": "048fe1c0eb4d53724a156b5e427d3275", "score": "0.553276", "text": "function C003_MorningDetention_Yuki_Annoyed() {\n\tif (ActorGetValue(ActorLove) <= -4) {\n\t\tPlayerLockInventory(\"Cuffs\");\n\t\tOverridenIntroText = GetText(\"Annoyed\");\n\t}\n}", "title": "" }, { "docid": "887d7cb2fedbeb13c32b978bca916cd1", "score": "0.5519772", "text": "onAttack(){\n\n }", "title": "" }, { "docid": "025e4d548b0db5eb9fd35890c3e8fdfb", "score": "0.55170816", "text": "function chatajastin() {\n\thae_chat();\n}", "title": "" }, { "docid": "9f27e44d88f3000a3bd1395b52f9bed0", "score": "0.55107343", "text": "function startInterview(){\n\tinquirer.prompt([\n\t\t{\n\t\t\ttype: 'list',\n\t\t\tmessage: 'Select Action:',\n\t\t\tchoices: [\n\t\t\t\t'View Products for Sale', \n\t\t\t\t'View Low Inventory',\n\t\t\t\t'Add to Inventory',\n\t\t\t\t'Add to Product',\n\t\t\t],\n\t\t\tname: 'selected'\n\t\t}\n\t]).then( (choice)=>{\n\n\t\tswitch(choice.selected){\n\n\t\t\tcase 'View Products for Sale':\n\t\t\t\tviewProducts();\n\t\t\t\tbreak;\n\n\t\t\tcase 'View Low Inventory':\n\t\t\t\tviewLowInventory();\n\t\t\t\tbreak;\n\n\t\t\tcase 'Add to Inventory':\n\t\t\t\taddToInventory();\n\t\t\t\tbreak;\n\n\t\t\tcase 'Add to Product':\n\t\t\t\taddToProduct();\n\t\t\t\tbreak;\n\n\t\t}\n\t});\n}", "title": "" }, { "docid": "1d238bb35de92cd5342646557eab3e8b", "score": "0.550317", "text": "clicked() {\n if (this.get('onOpen')) {\n this.get('onOpen')();\n }\n }", "title": "" }, { "docid": "73b1372b5b9ca4f7ed0e7b43ec5e5282", "score": "0.5491502", "text": "notifyInteracted() {}", "title": "" }, { "docid": "5ca7b722ef199c4376f2ecb49da891b9", "score": "0.5481686", "text": "function askForAction() {\n return readlineSync.question(\"What would you like to do now? Type the number of the corresponding option: \" + \n \"\\n1-Make a transaction\"+\n \"\\n2- Make a card payment\"+\n \"\\n3-See outstanding balance for given day\"+\n \"\\n4-See all credit card data:\\n\\n\");\n}", "title": "" }, { "docid": "3e0915b4436e90abc7a9650117d43558", "score": "0.5477412", "text": "openAnswer(e){this.correct=!this.correct}", "title": "" }, { "docid": "acff59de362ff69dc146e76ce0a0ee30", "score": "0.5471397", "text": "function emojiClickHandler(emo) {\r\n setMeaning(emo.description);\r\n }", "title": "" }, { "docid": "c3e2e88d5541d3e37c6c4a700db50674", "score": "0.5471026", "text": "onSupportClicked() {\n // Deconstruct state and state variables\n const { currentSpecificApp, courseId } = this.state;\n const {\n appId,\n supportEmail,\n title,\n } = currentSpecificApp;\n\n const subject = `I need support for ${title} in course with Canvas ID: ${courseId}`;\n this.showSupportModal(supportEmail, subject);\n\n // Log the event in the server\n writeLog(\n 'support-clicked',\n {\n appId,\n supportEmail,\n appName: title,\n }\n );\n }", "title": "" }, { "docid": "ee09005302d5de61faa3ae198e74b5cc", "score": "0.54660237", "text": "function action_trigger() {\n url_nya = url_link+\":5005/conversations/${user_id}/execute\"\n // send an event to the bot, so that bot can start the conversation by greeting the user\n $.ajax({\n url: url_nya,\n type: \"POST\",\n contentType: \"application/json\",\n data: JSON.stringify({ \"name\": action_name }),\n success: function(botResponse, status) {\n console.log(\"Response from Rasa: \", botResponse, \"\\nStatus: \", status);\n\n if (botResponse.hasOwnProperty(\"messages\")) {\n setBotResponse(botResponse.messages);\n }\n $(\"#userInput\").prop('disabled', false);\n },\n error: function(xhr, textStatus, errorThrown) {\n\n // if there is no response from rasa server\n setBotResponse(\"\");\n console.log(\"Error from bot end: \", textStatus);\n $(\"#userInput\").prop('disabled', false);\n }\n });\n}", "title": "" }, { "docid": "58462884a28fae0fd59b12df0ed8ba93", "score": "0.54594916", "text": "function handleOnMessage(message){\n // console.log(message);\n newModuleGlobal.ask(message.text, (err, res) => {\n if(err){\n console.log(err);\n return;\n }\n if(!res.intent){\n return rtm.sendMessage(\"Sorry I dont know what you are talking about\", message.channel);\n }\n else if(res.intent[0].value == 'time' && res.location){\n return rtm.sendMessage(\"Sorry I yet do not know the time in ${res.location[0].value}\", message.channel);\n }\n else{\n\n console.log(res);\n return rtm.sendMessage(\"Sorry I dont know what you are talking about\", message.channel);\n }\n rtm.sendMessage('Sorry I did not understand ', message.channel)\n \n } );\n}", "title": "" }, { "docid": "829ec1125115d0fbf98b0abd564a0157", "score": "0.5459237", "text": "function alicePoliticsOpinion() {\n let beginOpinion = beginOpinions[Math.floor(Math.random() * beginOpinions.length)];\n\n let generatingPoliticsOpinion = politicsOpinions[Math.floor(Math.random() * politicsOpinions.length)];\n responsiveVoice.speak(beginOpinion + generatingPoliticsOpinion, 'UK English Female');\n}", "title": "" }, { "docid": "f29b6451cea41ea2dd7d58d1df18beff", "score": "0.54467684", "text": "function start(){\n// function that starts the game\n totalGuesses = 10;\n inquire.prompt({\n type : 'list',\n name : 'Choose',\n message : changeToChalk('Do you want to play?','M'),\n choices : [\"YES\",\"NO\"]\n }).then(answers =>{\n if(answers.Choose === 'YES'){\n generateWord();\n promptForLetter();\n }\n })\n}// end start ******************************************************************************************", "title": "" }, { "docid": "bca56b881d0f8403030c6c656dfe26ad", "score": "0.54445326", "text": "function onShowTutorialHelp(){\n\t\tanalytics.fireEvent(\"action.showTutorialHelp\");\n\t}", "title": "" }, { "docid": "37d466be99fb7adf2b224f6eaa8d57ad", "score": "0.5440798", "text": "function onClick() {\n alert('You clicked on the ' + cardNoToCard( cardItem.cardNo ) + ' of ' + game.cardSuitsToText(cardItem.cardSuit));\n }", "title": "" }, { "docid": "2875f6601cdac727d973f72543c47a53", "score": "0.54405975", "text": "function ovation() {\n const encore = prompt('I had to leave the show early due to a tambourine related injury. Did we get an encore?').toLowerCase();\n console.log('encore: ' + encore);\n\n if (encore === 'yes' || encore.startsWith('y')){\n alert('Congrats, ' + name + '! You\\'re a rock star now.');\n } else if (encore === 'no' || encore.startsWith('n')){\n alert('Sorry, ' + gigLocation + ' was a boring audience and they ruined my tambourine!');\n } else {\n alert(name + ', it\\'s either yes or no. We either got an encore or we didn\\'t.');\n }\n}", "title": "" }, { "docid": "3c66d6c0ff8fa72b74aabed0f6fdba19", "score": "0.5440016", "text": "function voiceFeedback(editor) {\n // console.log(toggle);\n // console.log('a');\n var row, col, char;\n myEditor.onDidChangeCursorPosition((e) => {\n row = myEditor.getPosition().lineNumber;\n col = myEditor.getPosition().column;\n char = myEditor.getModel().getValueInRange({\n startLineNumber: row,\n startColumn: col - 1,\n\n endLineNumber: row,\n endColumn: col,\n });\n // console.log(char);\n if (voiceFbToggole === 't') {\n // console.log(toggle);\n // console.log('b');\n easySpeak(charSpeak(char));\n }\n });\n }", "title": "" }, { "docid": "85f3b55e4f6e10e42885a552b13ee32a", "score": "0.5438774", "text": "function handleFirstEventRequest(intent, session, response) {\n channel = intent.slots.channel;\n\n var repromptText = \"With slack you can post a message to a channel. Now which channel would you like to post to?\";\n\n response.ask('Ok, great. What message would you like to post?', repromptText);\n}", "title": "" }, { "docid": "1f919304b5a2072774bd1f9d570df9a4", "score": "0.54381824", "text": "function startListening() {\n if (annyang) {\n // Let's define a command.\n var commands = {\n 'hi': function () { alert('Hello'); },\n\n // ------------------------------------------------------------ Clock Speech Recognition ------------------------------------------------------------\n 'show me the time': function(city) {\n setCurrentlyViewing(\"time\");\n focusWidget(1);\n createClock();\n },\n 'what time is it': function(city) {\n setCurrentlyViewing(\"time\");\n focusWidget(1);\n createClock();\n },\n 'what\\'s the time': function(city) {\n setCurrentlyViewing(\"time\");\n focusWidget(1);\n createClock();\n },\n // ------------------------------------------------------------ Weather Speech Recognition ------------------------------------------------------------\n 'show me the weather': function() {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = true; // Flag in weather.js\n focusWidget(2);\n getWeather(\"\");\n },\n 'get me the weather': function() {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = true; // Flag in weather.js\n focusWidget(2);\n getWeather(\"\");\n },\n 'what\\'s the weather (like)': function() {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = true; // Flag in weather.js\n focusWidget(2);\n getWeather(\"\");\n },\n 'show me the weather for *destination': function(destination) {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = false; // Flag in weather.js\n focusWidget(2);\n getWeather(destination);\n },\n 'show me the weather in *destination': function(destination) {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = false; // Flag in weather.js\n focusWidget(2);\n getWeather(destination);\n },\n 'get me the weather in *destination': function(destination) {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = false; // Flag in weather.js\n focusWidget(2);\n getWeather(destination);\n },\n 'get me the weather for *destination': function(destination) {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = false; // Flag in weather.js\n focusWidget(2);\n getWeather(destination);\n },\n 'what\\'s the weather (like) in *destination': function(destination) {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = false; // Flag in weather.js\n focusWidget(2);\n getWeather(destination);\n },\n 'what\\'s the weather (like) for *destination': function(destination) {\n setCurrentlyViewing(\"weather\");\n getCurrentLocationForWeather = false; // Flag in weather.js\n focusWidget(2);\n getWeather(destination);\n },\n // ------------------------------------------------------------ News Speech Recognition ------------------------------------------------------------\n // Get next article for the news\n '(go to)(next)(article)': function() {\n if(currentlyViewing() === \"news\"){\n nextArticle();\n }\n },\n // Get previous article for the news\n '(go to)(previous)(article)': function () {\n if(currentlyViewing() === \"news\"){\n previousArticle();\n }\n },\n // Get the news\n '(what is) (what\\'s) (show me) (the) (most) (:filter) (today\\'s) news (story) (of) (today) (from) (:dataSource)': function(filter, dataSource) {\n setCurrentlyViewing(\"news\");\n focusWidget(4);\n var sortedBy = \"\";\n switch (filter) {\n case 'recent':\n sortedBy = 'latest';\n break;\n case 'today\\'s':\n sortedBy = 'latest';\n break;\n case 'latest':\n sortedBy = 'latest';\n break;\n case 'top':\n sortedBy = 'top';\n break;\n case 'popular':\n sortedBy = 'popular';\n break;\n default:\n sortedBy = 'top';\n break;\n\n }\n getNews(sortedBy, dataSource);\n },\n // ------------------------------------------------------------ News AND Maps Speech Recognition ------------------------------------------------------------\n // Scroll down on the article/steps for the news OR Maps\n 'scroll down': function() {\n if(currentlyViewing() === \"news\"){\n scrollOnNews(1); // 1 = Scroll down\n } else if(currentlyViewing() === \"maps\") {\n scrollOnMaps(1); // 1 = Scroll down\n }\n },\n // Scroll up on the article/steps for the news or Maps\n 'scroll up': function() {\n if(currentlyViewing() === \"news\"){\n scrollOnNews(0); // 0 = Scroll up\n } else if(currentlyViewing() === \"maps\") {\n scrollOnMaps(0); // 0 = Scroll up\n }\n },\n // ------------------------------------------------------------ Map Speech Recognition ------------------------------------------------------------\n 'how do I get to :destination from :source': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'how do I get from :source to :destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'navigate from :source to :destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'navigate to :destination from :source': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'show me directions from :source to :destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },'show me directions to :destination from :source': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'show me how to get to :destination from :source': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'show me how to get from :source to :destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, source);\n },\n 'how (do)(can) I get to *destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = true; // Flag in maps.js\n focusWidget(3);\n showMap(destination, \"\");\n },\n 'take me to *destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = true; // Flag in maps.js\n focusWidget(3);\n showMap(destination, \"\");\n },\n 'navigate to *destination': function(destination, source) {\n setCurrentlyViewing(\"maps\");\n directions = true; // Flag in maps.js\n getCurrentLocation = true; // Flag in maps.js\n focusWidget(3);\n showMap(destination, \"\");\n },\n 'where is *destination': function(destination) {\n setCurrentlyViewing(\"maps\");\n directions = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, \"\"); // Pass source as blank, not used\n },\n 'show me the map of *destination': function(destination) {\n setCurrentlyViewing(\"maps\");\n directions = false; // Flag in maps.js\n focusWidget(3);\n showMap(destination, \"\"); // Pass source as blank, not used\n }\n };\n // Update the speech-spitter widget with command said\n annyang.addCallback('resultMatch', function(userSaid, commandText, phrases) {\n spitToSpitter(userSaid);\n });\n\n annyang.addCallback('resultNoMatch', function(phrases) {\n spitToSpitter(\"Not a command!\");\n });\n\n // Add our commands to annyang\n annyang.addCommands(commands);\n //https://www.talater.com/annyang/ for more examples\n // Start listening.\n annyang.start();\n }\n}", "title": "" }, { "docid": "b3ad345789bf8375b334f12584b05794", "score": "0.5437215", "text": "function responseHandler (assistant) {\n // Complete your fulfillment logic and send a response\n assistant.tell('Hello, World!');\n }", "title": "" }, { "docid": "cd31f09e0ff430d737cb77e1c4cbba81", "score": "0.54335433", "text": "onOpen() {\n }", "title": "" }, { "docid": "71df2fd2a9c4c12754c8f864acbc3e0a", "score": "0.5430537", "text": "function onIntent(intentRequest, session, callback) {\n const intent = intentRequest.intent;\n const intentName = intentRequest.intent.name;\n\n // Dispatch to your skill's intent handlers\n switch (intentName) {\n case \"GetHoliday\":\n case \"GetHolidayDate\":\n case \"GetHolidayNextYear\":\n case \"HolidaySlotOnlyIntent\":\n if (intent.slots && intent.slots.Holiday && intent.slots.Holiday.value && intent.slots.Holiday.value.length > 1) {\n const holidayName = intent.slots.Holiday.value.toLowerCase();\n if (holidayName === 'shabbat' || holidayName === 'shabbos') {\n getCandleLightingResponse(intentRequest, session, callback);\n } else {\n getHolidayResponse(intent, session, callback);\n }\n } else {\n getWhichHolidayResponse(session, callback);\n }\n break;\n case \"GetParsha\":\n getParshaResponse(intentRequest, session, callback);\n break;\n case \"GetHebrewDate\":\n case \"MyDateSlotOnlyIntent\":\n getHebrewDateResponse(intent, session, callback);\n break;\n case \"GetCandles\":\n case \"SetLocation\":\n case \"CityNameSlotOnlyIntent\":\n case \"ZipCodeSlotOnlyIntent\":\n getCandleLightingResponse(intentRequest, session, callback);\n break;\n case \"GetHavdalah\":\n getHavdalahResponse(intentRequest, session, callback);\n break;\n case \"GetOmer\":\n getOmerResponse(intent, session, callback);\n break;\n case \"GetDafYomi\":\n getDafYomiResponse(intent, session, callback);\n break;\n case \"AMAZON.CancelIntent\":\n case \"AMAZON.StopIntent\":\n const ssmlContent = 'Thanks for using ' +\n hebcal.getPhonemeTag(\"'hibkæl\", 'Hebcal') +\n '. Goodbye.';\n session.attributes.specialGreeting = undefined;\n const response = respond('Goodbye',\n 'Thanks for using Hebcal. Goodbye.', ssmlContent);\n callback(session, response);\n break;\n case \"AMAZON.HelpIntent\":\n getWelcomeResponse(session, callback, true);\n break;\n default:\n callback(session, buildSpeechletResponse(\"Invalid intent\", `Invalid intent ${intentName}. Goodbye`, null, true));\n break;\n }\n}", "title": "" }, { "docid": "c2807676f937e9e56febb5b8dd438134", "score": "0.5428582", "text": "function handleGloriousMysteryIntent(intent, session, response) {\nconsole.log(\"The mystery attribute is: \" + session.attributes.mystery + \"The prayer count attribute is: \" + session.attributes.prayercount);\n \n var repromptText = \"<speak>\" + \"To continue praying the mystery please say. Amen. To pray a different mystery, please say stop. and then say the mystery you would like me to pray. Now, say stop, amen, or help\" + \"</speak>\" ;\n var speechText = \"\";\n var utterance = \"\";\n var user_utterance = \"\";\n if (intent.slots)\n {\n \tutterance = intent.slots.Utterances.value;\n \tuser_utterance = utterance.toLowerCase(); \n }\n \n session.attributes.mystery = 'Glorious';\n console.log(\"User Utterance: \" + user_utterance);\n if ( (user_utterance == 'amen' || user_utterance == 'pray for us' || user_utterance == 'continue') || (session.attributes.prayercount === 0) ){\n if (session.attributes.mystery === 'Glorious'){\n console.log(\"I am inside the Glorious Mystery\");\n switch(session.attributes.prayercount){\n case 0: \n console.log(\"I am inside the SWITCH\" + PRAYER_INDEX.indexOf(\"Our Father\"));\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"The Sign of the Cross\")].prayer + \"</speak>\"\n session.attributes.prayercount = 1;\n break;\n case 1:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Apostles Creed\")].prayer + \"</speak>\"\n session.attributes.prayercount = 2;\n break;\n case 2:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Church\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 3;\n break;\n case 3:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Faith\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 4;\n break;\n case 4:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hope\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 5;\n break; \n case 5:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Charity\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 6;\n break; \n case 6:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 7;\n break; \n case 7:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"First Glorious\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer +\"</speak>\"\n session.attributes.prayercount = 9;\n break; \n /**case 8:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 9;\n break;*/\n case 9:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 10;\n break;\n case 10:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 11;\n break;\n case 11:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 12;\n break;\n case 12: \n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 13;\n break;\n case 13:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 14;\n break; \n case 14:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 15;\n break; \n case 15:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 16;\n break;\n case 16:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 17;\n break;\n case 17:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 18;\n break; \n case 18:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 19;\n break; \n case 19:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 20;\n break; \n case 20:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fatima Prayer\")].prayer + \"</speak>\"\n session.attributes.prayercount = 21;\n break; \n case 21:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Second Glorious\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 23;\n break; \n /**case 22:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 23;\n break;*/\n case 23:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 24;\n break;\n case 24:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 25;\n break;\n case 25:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 26;\n break;\n case 26: \n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 27;\n break;\n case 27:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 28;\n break; \n case 28:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 29;\n break; \n case 29:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 30;\n break;\n case 30:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 31;\n break;\n case 31:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 32;\n break; \n case 32:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 33;\n break; \n case 33:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 34;\n break; \n case 34:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fatima Prayer\")].prayer + \"</speak>\"\n session.attributes.prayercount = 35;\n break;\n case 35:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Third Glorious\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 37;\n break;\n /**case 36:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 37;\n break;*/\n case 37:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 38;\n break;\n case 38:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 39;\n break;\n case 39:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 40;\n break;\n case 40: \n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 41;\n break;\n case 41:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 42;\n break; \n case 42:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 43;\n break; \n case 43:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 44;\n break;\n case 44:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 45;\n break;\n case 45:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 46;\n break; \n case 46:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 47;\n break; \n case 47:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 48;\n break; \n case 48:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fatima Prayer\")].prayer + \"</speak>\"\n session.attributes.prayercount = 49;\n break; \n case 49:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fourth Glorious\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 51;\n break; \n /** case 50:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 51;\n break; */\n case 51:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 52;\n break;\n case 52:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 53;\n break;\n case 53:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 54;\n break;\n case 54: \n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 55;\n break;\n case 55:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 56;\n break; \n case 56:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 57;\n break; \n case 57:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 58;\n break;\n case 58:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 59;\n break;\n case 59:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 60;\n break; \n case 60:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 61;\n break; \n case 61:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 62;\n break; \n case 62:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fatima Prayer\")].prayer + \"</speak>\"\n session.attributes.prayercount = 63;\n break; \n case 63: \n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fifth Glorious\")].prayer + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 65;\n break; \n /** case 64:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 65;\n break;*/\n case 65:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 66;\n break;\n case 66:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 67;\n break;\n case 67:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 68;\n break;\n case 68: \n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 69;\n break;\n case 69:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 70;\n break; \n case 70:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 71;\n break; \n case 71:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 72;\n break;\n case 72:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 73;\n break;\n case 73:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 74;\n break; \n case 74:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 75;\n break; \n case 75:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 76;\n break; \n case 76:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Fatima Prayer\")].prayer + \"</speak>\"\n session.attributes.prayercount = 77;\n break;\n\t\t\t\tcase 77:\n speechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Holy Queen\")].prayer + \"</speak>\"\n session.attributes.prayercount = 78;\n break;\n case 78:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"The Breviary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 79;\n break;\n case 79:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Holy Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 80;\n break;\n\t\t\t\tcase 80:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 81;\n break;\n case 81:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 82;\n break;\n case 82:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 83;\n break;\n case 83:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Bishop\")].prayer + \"</speak>\"\n session.attributes.prayercount = 84;\n break;\n case 84:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 85;\n break;\n case 85:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 86;\n break;\n case 86:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Glory Be\")].prayer + \"</speak>\"\n session.attributes.prayercount = 87;\n break; \n case 87:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Souls in Purgatory\")].prayer + \"</speak>\"\n session.attributes.prayercount = 88;\n break; \n case 88:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Our Father\")].prayer + \"</speak>\"\n session.attributes.prayercount = 89;\n break; \n case 89:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"</speak>\"\n session.attributes.prayercount = 90;\n break; \n case 90:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"Hail Mary\")].prayer + \"Rest in peace\" + \"</speak>\"\n session.attributes.prayercount = 91;\n break; \n case 91:\n \tspeechText = \"<speak>\" + PRAYERS[PRAYER_INDEX.indexOf(\"The Sign of the Cross\")].prayer + \"</speak>\"\n break; \n\n }\n } \n\t}\t\n\telse\n\t{\n\t\tvar repromptText = \"<speak>\" + \"To continue praying the mystery please say. Amen. To pray a different mystery, please say stop. and then say the mystery you would like me to pray. Now, say stop, amen, or help\" + \"</speak>\";\n \tvar speechText = \"<speak>\" + \"I didn't understand what you just said. To continue praying the mystery please say Amen. To pray a different mystery please say stop and then say the mystery you would like me to pray. Now say stop, amen, or help\" + \"</speak>\";\n\t}\n var speechOutput = {\n speech: speechText,\n type: AlexaSkill.speechOutputType.SSML\n };\n var repromptOutput = {\n speech: repromptText,\n type: AlexaSkill.speechOutputType.SSML\n };\n // For the repromptText, play the speechOutput again\n response.ask(speechOutput, repromptOutput); \n}", "title": "" }, { "docid": "4af84e28499ec37da3b5a66c17af8801", "score": "0.54233795", "text": "async requestSuggestion(evt) {\n if (!evt.ctrlKey) {\n \n }\n const doc = this.cm;\n if (doc.somethingSelected()) {\n return;\n }\n const cursorPos = doc.getCursor();\n const index = doc.indexFromPos(cursorPos)\n const allCode = doc.getValue()\n const code = allCode.substring(Math.max(0, index-500), index)\n\n lively.notify(code, 'code')\n\n const result = await OpenAI.completeCode(code)\n if (result.isError) {\n lively.error(result.error, 'Error during OpenAI Completion')\n return;\n }\n\n lively.notify(result.completion)\n }", "title": "" }, { "docid": "f5c68f1f258c01c5bf80532798831635", "score": "0.5420093", "text": "onPowerwashClicked_() {\n this.userActed('powerwash');\n }", "title": "" }, { "docid": "a4f6d44faa1ce86018d898b11c268ced", "score": "0.54199594", "text": "function onNicknameChanged(nickname) {\n document.getElementById(\"nicknameInputText\").textContent = nickname\n console.log(\"Event: nickname changed: \" + nickname);\n //Only call start the 1st time the app is loaded\n if (!ready){ start();};\n}", "title": "" }, { "docid": "74070378e3dc9e328b19c4827b966dd1", "score": "0.5416427", "text": "function onClicked(){\n Menu.triggerOption('Help...')\n }", "title": "" }, { "docid": "730e0db4527b92554037d7d616c4d8d8", "score": "0.54016536", "text": "function showUserToGroupMenu(){\n indexFuncs.rl.question('\\nIn the Association menu. Now what? ', dealWithAssoInput);\n console.log(menuAsso);\n}", "title": "" }, { "docid": "0f82b6f7b4bf1a4aa3cf7a8b0e2311c9", "score": "0.5398921", "text": "function handleQuizApp() {\n listenForContinueClick()\n listenForRadioClick()\n}", "title": "" }, { "docid": "93eb0b3fd6c3ae38012b08180bbd1357", "score": "0.53975576", "text": "function ACCEPT() {\r\n alert(\"REQUEST ACCEPTED, CLICK MENTORSHIP CONNECTION LINK\");\r\n}", "title": "" }, { "docid": "9c544dc075b753d83b304c4d8d1468db", "score": "0.53974277", "text": "function aliceMedicineOpinion() {\n let beginOpinion = beginOpinions[Math.floor(Math.random() * beginOpinions.length)];\n\n let generatingMedicineOpinion = medicineOpinions[Math.floor(Math.random() * medicineOpinions.length)];\n responsiveVoice.speak(beginOpinion + generatingMedicineOpinion, 'UK English Female');\n}", "title": "" }, { "docid": "33739d1871f3ec5ed0504697c35b5111", "score": "0.5392389", "text": "function On(){}", "title": "" }, { "docid": "d64abf2ec4cc7709a5a3ff976794dd6e", "score": "0.53784263", "text": "function startGame() {\n let answer = window.prompt(\"Make your first move\"); alert(\"your\");\n let userInput = (resp) => {\n console.log(\"What's your move?\"\n if(resp === \"attack\") {\n console.log(Math.random().toFixed(2));\n \n }\n }", "title": "" }, { "docid": "cf3f4fb51186d2c8e956f8c6edd29294", "score": "0.53757536", "text": "onActivated() {}", "title": "" }, { "docid": "77a42e294247a5807b995ee6c5fb2611", "score": "0.53749907", "text": "function onOk(event){\n\t\tvar view = this;\n\t\tsetAnswer.call(view,true);\n\t}", "title": "" }, { "docid": "f972a18dd2088f7104b947facc5fb5fc", "score": "0.5374145", "text": "activate() {\n console.log(\"RestGoal activated\");\n // this.owner.ui.currentGoal.textContent = this.REST;\n // this.owner.ui.currentSubgoal.textContent = this.PLACEHOLDER;\n }", "title": "" }, { "docid": "8c21c0625b5626c25f00823240f8f364", "score": "0.5372499", "text": "onInput(input) {}", "title": "" }, { "docid": "29a09bc14d5c2ba4baf6474bf19792fc", "score": "0.5371134", "text": "function onIntent(intentRequest, session, callback) {\n\tconsole.log(\"onIntent requestId=\" + intentRequest.requestId\n\t\t\t\t+ \", sessionId=\" + session.sessionId);\n\t\t\t\t\n\tvar intent = intentRequest.intent,\n\tintentName = intentRequest.intent.name.toString();\n\n\tvar slot_name = intent.slots;\n\tvar jsonSlots = {};\n\tvar strSlots='';\n\tif(slot_name !== undefined){\n\t\tfor(var key in slot_name) {\n\t\t\tvar slot_value = (intent.slots)[key].value;\n\t\t\tif(slot_value && key) {\n\t\t\t jsonSlots[key]=slot_value.replace(/#/g,'');\n\t\t\t strSlots += '\"name\":\"'+key+'\",\"value\":\"'+slot_value.replace(/#/g,\"\")+'\"';\n\t\t\t}\n\t\t}\n\t}\n\t\n\tvar slots = JSON.stringify(jsonSlots);\n\tvar lambdaResponse = JSON.stringify(buildSpeechletResponse(\"text\", \"reprompt\", false));\n\tlambdaResponse = encodeURI(lambdaResponse);\n\tvar lambdaRequest = encodeURI('{\"session\":'+JSON.stringify(session)+',\"request\":'+JSON.stringify(intentRequest)+',\"version\":\"1.0\"}');\n\n\t\n\t//Get Answer from vocalapps API\n\tvar req;\n\tvar session_id = session.sessionId;\n\tvar user_id = session.user.userId;\n\tvar skill_id = '2894';\n\t//var input = JSON.stringify(jsonSlots[\"Text\"]);\n\tvar input = JSON.stringify(intentName);\n\tinput = input.replace(/#/g,'');\n\tvar inputEncoded = encodeURI(input);\n\tslots = encodeURI(slots);\n\tvar options = {\n\t host: 'www.alexa-designer.com',\n\t\tport: 80,\n\t\tpath: '/dialog_engine/api.php?user_id='+user_id+'&session_id='+session_id+'&skill_id='+skill_id+'&lang=en-gb'+'&event_name=NEW_INPUT&input='+inputEncoded+'&slots='+slots+'&lambdaResponse='+lambdaResponse+'&lambdaRequest='+lambdaRequest,\n\t\tmethod: 'GET'\n\t};\n\t\t\t\n\t\n\treq = http.request(options, function(res) {\n\t\tres.setEncoding('utf8');\n\t\tres.on('data', function (chunk) {\n\t\t\tvar json = JSON.parse(chunk); \n\t\t\tvar answer = \"<speak>\"+json.answer+\"</speak>\";\n\t\t\tvar reprompt = \"<speak>\"+json.reprompt+\"</speak>\";\n\t\t\tvar shouldEndSession = false; \n\t\t\t\n\t\t\tif(json.end_session)\n\t\t\t\tshouldEndSession = true; \t\n\t\t\tgetResponse(answer, reprompt,intent, session, shouldEndSession, callback);\n\t\t\t\t\n\t\t});\n\t});\n\t\n\treq.on('error', function(e) {\n\t\tconsole.log('problem with request: ' + e.message);\n\t});\n\treq.end();\n\t\t\n}", "title": "" }, { "docid": "c749ce5dd01e24451e2da6de73bff688", "score": "0.53699446", "text": "function OnGUI() {\n\tif (triggerscript.showDialog == true) {\n\t\tGUILayout.BeginArea(Rect(700,50,200,200)); //starts a GUI area in which the folliwing buttons and rects are located\n\t\t\n\t\tGUILayout.Label(\"Hello, my dear friend.\");\n\t\tGUILayout.Label(\"Please let me eat you!\");\n\t\t\n\t\tif (GUILayout.Button(\"Ok\")) { //target is being eaten (reset)\n\t\t\tpacmanscript.resetPlayer();\n\t\t\tAudioSource.PlayClipAtPoint(eatenSound, gameObject.transform.position);\n\t\t\ttriggerscript.showDialog = false;\n\t\t\t\n\t\t}\n\t\t\n\t\tif (GUILayout.Button(\"No, not today.\")) { //BonusEnemy is being destroyed and player gets a point by calling the itemscript\n\t\t\tDestroy(gameObject);\n\t\t\tAudioSource.PlayClipAtPoint(eatGhost, gameObject.transform.position);\n\t\t\titemscript.setPoints(1);\n\t\t\ttriggerscript.showDialog = false;\n\t\t}\n\t\t\n\t\tGUILayout.EndArea();\n\t}\n}", "title": "" }, { "docid": "0ddc7dcb9883da809cec066e032adee4", "score": "0.5369366", "text": "function initialPrompt() {\n // get some user input specfically a word for us to score\n console.log(\"Let's play some scrabble! Enter a word:\");\n}", "title": "" }, { "docid": "f1fec1414a6adad427dceb8684f8c506", "score": "0.5368986", "text": "handleClick() {\n if (this.sendToImageCallback(this.word)) {\n $(\".app-instructions\").show();\n }\n }", "title": "" }, { "docid": "20432171805983a247bccfbb2042db14", "score": "0.5365831", "text": "function question(text) {\n clicked = true;\n const textAndBot = document.querySelector(\"#wordMeaning\");\n const reply = document.querySelector('.word-meaning__text');\n let meaning = null;\n for (const words in dictionaryRet){\n if (dictionaryRet[words].name === text){\n meaning = dictionaryRet[words].meaning;\n break;\n }\n }\n reply.innerHTML = meaning;\n let x = event.clientX + document.body.scrollLeft + document.documentElement.scrollLeft; // Get the horizontal coordinate\n let y = event.clientY + document.body.scrollTop + document.documentElement.scrollTop;\n setBot(x,y);\n textAndBot.classList.remove('inactive');\n}", "title": "" }, { "docid": "c29e72d2389c7467320872e03d90fd32", "score": "0.5364763", "text": "function note() {\n\tif(noteOn == 1) {\t\n\t\tif((learnNoteOpen == 0 && arguments[0] == noteTrigger && arguments[1] > arguments[2])) {\n\t\tbang();\n\t\t\t}\t\n\tif(learnNoteOpen == 1) {\n\t\t\t\tnoteTrigger = arguments[0];\n\t\t\t\tlearnNoteOpen = 0;\n\t\t\t\tshowLearnNote.message(\"text\", noteTrigger);\n\t\t\t\tshowNoteNumber.message(\"set\", noteTrigger);\n\t\t\t\tshowNoteNumber.message(\"bang\");\n\t\t\t\tshowLearnNote.message(0);\n\t\t\t}\n\t\t} \n}", "title": "" }, { "docid": "b6f4ed01e027efa05b52502a8d4a7c21", "score": "0.5362327", "text": "function commandLiri() {\n if (userChoice === \"concert-this\") {\n concertSearch(input);\n } else if (userChoice === \"spotify-this-song\") {\n if (input) {\n spotifySearch(input);\n } else {\n input = \"The Sign by ace of base\";\n spotifySearch(input);\n }\n } else if (userChoice === \"movie-this\") {\n movieSearch(input);\n } else if (userChoice === \"do-what-it-says\") {\n doWhatItSays();\n } else {\n console.log(`Thank you for checking out my LIRI Node application. Please start by typing \"node liri.js\" into the command line and then enter any of the commands below:\n \\n concert-this \"name of an artist\"\n \\n spotify-this-song \"name of a song\"\n \\n movie-this \"name of a movie\"\n \\n \"do-what-it-says\"`); // this command will run whatever is in the \"random.txt\" file\n }\n}", "title": "" }, { "docid": "ffd5bfad169bcd63b357c40a4cdee8ca", "score": "0.5360213", "text": "function checkForIntent() {\n\t\t\t// calculate mouse position difference\n\t\t\tvar xDifference = Math.abs(session.previousX - session.currentX),\n\t\t\t\tyDifference = Math.abs(session.previousY - session.currentY),\n\t\t\t\ttotalDifference = xDifference + yDifference;\n\n\t\t\t// check if difference has passed the sensitivity threshold\n\t\t\tif (totalDifference < options.intentSensitivity) {\n\t\t\t\tcancelClose();\n\t\t\t\tcloseAnyDelayed();\n\t\t\t\ttipController.showTip(element);\n\t\t\t} else {\n\t\t\t\t// try again\n\t\t\t\tsession.previousX = session.currentX;\n\t\t\t\tsession.previousY = session.currentY;\n\t\t\t\topenTooltip();\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "c2d2b2412f08ea33def3c96ba6f12573", "score": "0.53589195", "text": "function onOpen() {\n console.log('Conectado..');\n}", "title": "" }, { "docid": "5e38097475676ee757d92146e7c82566", "score": "0.5354558", "text": "function painintent(intent, session, callback) {\n var cardTitle = intent.name;\n var repromptText = \"\";\n var sessionAttributes = {};\n var shouldEndSession = true;\n var speechOutput = \"\";\n var pain = intent.slots.pain.value;\n var validpain = [ \"pain medication\", \"medication\", \"pain medications\", \"medications\"];\n\n //This checks to see if the request that was said matches to what is in the intent slots.\n if (validpain.indexOf(pain) == -1) {\n speechOutput = \"I'm not sure what you are asking for. Please something like, I need pain medication\";\n repromptText = \"I'm not sure what you are asking for.\" +\n \"Please something like, I am having pain or I need pain medication\";\n callback(sessionAttributes,\n buildSpeechletResponse(cardTitle, speechOutput, repromptText, shouldEndSession));\n } \n //If request is, a SMS and message to IOT is sent. \n else { \n painCMD(pain, function(speechOutput){\n speechOutput = \"I am making your nurse aware that you require \" + pain + \". Your nurse should arrive shortly to speak with you.\";\n callback(sessionAttributes,\n buildSpeechletResponse(cardTitle, speechOutput, repromptText, shouldEndSession));\n });\n } \n}", "title": "" }, { "docid": "e20f05471acb8b397649cbedbfa0dedb", "score": "0.53508145", "text": "checkOffenceResult({ row, col, cell }) {\n const colLetter = getNthLetter(col);\n this.promptUser(\n `Does opponent have a ship at <code>${colLetter}${row + 1}</code>?`,\n 'Yes!',\n 'no.',\n (isHit) => {\n if (isHit){\n var audio = new Audio('../../lib/audio/shipFire.mp3');\n audio.play();\n cell.classList.add('ship');\n } \n this.addBorder();\n if (!isHit || !this.checkWin('opponent')) {\n var audio = new Audio('../../lib/audio/shipMiss.mp3');\n audio.play();\n this.turn('player');\n \n }\n }\n );\n }", "title": "" }, { "docid": "62e98369d7d5aa6ea9640d7e896b2029", "score": "0.5344433", "text": "function enterQuestion() {\r\n return chatbot.actions.displayChatbotMessage({\r\n type: 'answer',\r\n message: 'enter-question',\r\n translate: true\r\n });\r\n }", "title": "" }, { "docid": "a58f0bad3062453e517cc542e27cc92b", "score": "0.53427", "text": "onChallengeClicked() {\n this.props.onChallenge();\n }", "title": "" }, { "docid": "88e7593ac43d6f317c198460f70d40d0", "score": "0.53393614", "text": "function onIntent(intentRequest, session, callback) {\n console.log(\"onIntent requestId=\" + intentRequest.requestId +\n \", sessionId=\" + session.sessionId);\n\n var intent = intentRequest.intent,\n intentName = intentRequest.intent.name;\n\n if (\"TextMeIntent\" === intentName) {\n console.log(\"TextMeIntent received\");\n setMessageInSession(intent, session, callback);\n } else if (\"AMAZON.HelpIntent\" === intentName) {\n getWelcomeResponse(callback);\n } else {\n throw \"Invalid intent\";\n }\n}", "title": "" }, { "docid": "80c3c53878a656fb1d4ae7a7638f4bf4", "score": "0.53385663", "text": "function about() {\r\n\talert('This is the mission control similator 3000. A multiplayer simulation that allows you to take a seat in mission control! \\n Click join to join a game or host to learn how to host your own');\r\n}", "title": "" }, { "docid": "a37ab5a8d79b5bf9da532f031c97783f", "score": "0.5330581", "text": "function startLiri(userCommand, userInput) {\n switch (userCommand) {\n case 'concert-this':\n concertThis(userInput)\n break;\n case 'spotify-this-song':\n spotifyThis(userInput)\n break;\n case 'movie-this':\n movieThis(userInput)\n break;\n case 'do-what-it-says':\n doRandomTxt()\n break;\n default:\n console.log(\"Not one of liris functions\")\n }\n}", "title": "" }, { "docid": "d1976d6cf7a9e6e15309062474f4784d", "score": "0.53303474", "text": "function turnOnInput () {\n function getImageDoc () {\n imageDoc = $rdf.sym(\n chatDocument.dir().uri + 'Image_' + Date.now() + '.png'\n )\n return imageDoc\n }\n\n async function tookPicture (imageDoc) {\n if (imageDoc) {\n await sendMessage(imageDoc.uri)\n }\n }\n\n // Body of turnOnInput\n\n let menuButton\n if (options.menuHandler) {\n const menuButton = widgets.button(\n dom, icons.iconBase + 'noun_243787.svg', 'More')\n menuButton.setAttribute('style', style.buttonStyle + 'float: right;')\n // menuButton.addEventListener('click', _event => sendMessage(), false) (done in turnoninput)\n rhs.appendChild(menuButton)\n }\n\n if (options.menuHandler && menuButton) {\n const me = authn.currentUser()\n const menuOptions = {\n me,\n dom,\n div: null, // @@ was: div\n newBase: messageTable.chatDocument.dir().uri\n }\n menuButton.addEventListener(\n 'click',\n event => {\n options.menuHandler(event, channelObject.chatChannel, menuOptions)\n },\n false\n )\n }\n\n const me = authn.currentUser() // If already logged on\n creatorAndDate(lhs, me, '', null)\n\n field = dom.createElement('textarea')\n middle.innerHTML = ''\n middle.appendChild(field)\n field.rows = 3\n if (originalMessage) {\n field.value = store.anyValue(originalMessage, ns.sioc('content'), null, originalMessage.doc())\n }\n // field.cols = 40\n field.setAttribute('style', messageBodyStyle + 'background-color: #eef;')\n\n // Trap the Enter BEFORE it is used ti make a newline\n\n field.addEventListener(\n 'keydown',\n async function (e) {\n // User preference?\n if (e.code === 'Enter') {\n // if (e.keyCode === 13) { // deprocated https://developer.mozilla.org/en-US/docs/Web/API/KeyboardEvent/keyCode\n if ((!e.shiftKey && !options.shiftEnterSendsMessage) || (e.shiftKey && options.shiftEnterSendsMessage)) {\n // Shift-Enter just adds a new line\n // (note alt-enter doesn't add newline anyway on my setup - so have to use shift.\n await handleFieldInput(e)\n }\n }\n },\n false\n )\n\n widgets.makeDropTarget(field, droppedURIHandler, droppedFileHandler)\n\n rhs.innerHTML = ''\n\n sendButton = widgets.button(dom, sendIcon, 'Send')\n sendButton.style.float = 'right'\n sendButton.addEventListener('click', _event => handleFieldInput(), false)\n rhs.appendChild(sendButton)\n\n if (originalMessage) { // Are we editing another message?\n const cancelButton = rhs.appendChild(widgets.cancelButton(dom))\n cancelButton.style.float = 'left'\n // cancelButton.firstChild.style.opacity = '0.3' // moved to buttons\n cancelButton.addEventListener('click', _event => revertEditing(messageEditor), false)\n rhs.appendChild(cancelButton)\n }\n\n const chatDocument = channelObject.dateFolder.leafDocumentFromDate(new Date())\n let imageDoc\n\n middle.appendChild(\n media.cameraButton(dom, store, getImageDoc, tookPicture)\n )\n\n pad.recordParticipation(channelObject.channel, channelObject.channel.doc()) // participation =\n } // turn on inpuut", "title": "" }, { "docid": "0f1fbf07d3a28132534bd69d64f5c567", "score": "0.5328598", "text": "function avocadoInfo()\n{\n\tvar info = \"Avocado contains many essential nutrients, and can help regulate blood-sugar levels. Research has also been done that shows avocados satiate your hunger for hours, which all leads to you feeling better and not stress-eating when you’re under pressure.\";\n\tconfirm(info);\n\tateFood();\n}", "title": "" }, { "docid": "76a14d5cc3d614e7a8cb462392f21284", "score": "0.53248924", "text": "function youGetTaco(action){\n\tif(action===\"eat\"){\n\treturn \"Eat Tacos\";\n }\n}", "title": "" }, { "docid": "c6f0d613b70271cdb9e41e0ebb02cef3", "score": "0.53223157", "text": "function buttonHandler() {\n agree();\n }", "title": "" }, { "docid": "9457369877e414577421003a8f021851", "score": "0.5321299", "text": "function app(){\n inquirer.prompt([{\n type: \"list\",\n name: \"goodness\",\n message: \"Sign in\",\n choices: ['Admin','User']\n }]).then(answer=>{\n const Atm = new ATM(user,admin);\n Atm.chooseOperation(answer.goodness)\n \n \n })\n \n}", "title": "" }, { "docid": "edb7ae1df91c84ccfcc54bf3326512b5", "score": "0.5316803", "text": "onAgree() {\n sendNativeMessage('onAgreed', {\n isMetricsEnabled: this.metricsCheckbox_.isChecked(),\n isBackupRestoreEnabled: this.backupRestoreCheckbox_.isChecked(),\n isLocationServiceEnabled: this.locationServiceCheckbox_.isChecked()\n });\n }", "title": "" }, { "docid": "16ea1e1b8b5bc6abd6ecbb2bb967ac32", "score": "0.5315468", "text": "function handleAnswer(answer) {\n console.log(\"handleAnswer\",connectedUser);\n // EN este momemnto se lanza el evento onicecandidate\n webRTConnection.setRemoteDescription(new RTCSessionDescription(answer));\n}", "title": "" }, { "docid": "dcb5584d4f42f121f10fe887629badb9", "score": "0.5312611", "text": "function talkedTo()\n{\n //final stage prompt.\n if(stage >= 3)\n {\n //stuff for populating possible criminals for player to stop.\n }\n //non-final stages\n talkedToCount++;\n if(countryChoice != criminal.country)\n {\n talkedToCount += 3;\n buildSpeechletResponse(\"They keep walking by\", false),\n {}\n //exit from country on 2nd talk in wrong country\n if(talkedToCount >= 6) //2nd time should evaluate to 7\n {\n //response that you're in the wrong country\n }\n }\n else {\n if (r_person.seenValue == 0) {\n generateResponse\n (\n buildSpeechletResponse(\"They keep walking by\", false),\n {}\n )\n if (talkedToCount >= 5) {\n //closing response for countryChoice then choice for next countries\n }\n\n }\n else\n {\n generateResponse\n (\n {},buildSpeechletResponse(greetings[rand(0, greetings.length - 1)], false)\n )\n //not sure if this is how to capture subsequent questioning intents so this will just be here for concept sake\n //Chad TODO\n //Could you help me check to see if this actually listens for next prompt? I'm hoping it does haha.\n //it SHOULD allow the user to ask questions about the crime, looks, where criminal is heading, etc.\n //Alan TODO\n //set flags to indicatte you're in questioning state so no other intents except stop, help, restart should register.\n //May need to include similar state checks on all intents.\n switch (event.request.type.name) {\n case \"CrimeBackgroundQuestionIntent\":\n generateResponse\n (\n {},buildSpeechletResponse(\"You're in crime background question intent\", false)\n )\n //random info about criminal given --still thinking about how to randomize this atm\n break;\n case \"CriminalLooksQuestionIntent\":\n generateResponse\n (\n {},buildSpeechletResponse(\"You're in criminal look question intent\", false)\n )\n //random info about criminal looks given -- also still thinking about how to for this.\n break;\n case \"FinishTalkingIntent\":\n generateResponse\n (\n {},buildSpeechletResponse(\"You're in finished talking intent\", false)\n )\n //break convo\n break;\n }\n if (talkedToCount >= 5) {\n //closing response for the country and request next country intent\n }\n }\n }\n //reset counter after 5 people\n if(talkedToCount >= 5)\n {\n talkedToCount = 0;\n //reassign criminal country values, create a new method for that.\n }\n else\n {\n r_person = new PopulateResponsePerson();\n //build response for next person walking by.\n }\n}", "title": "" }, { "docid": "9d0d1eea34bd31ac4fba0bfe4ea0b2cc", "score": "0.5310955", "text": "speak(){\n console.log('meow');\n }", "title": "" }, { "docid": "00b7e72595424a0b9e7a07303b69399b", "score": "0.5308409", "text": "function autoPlayActionResult(aData) {\n //console.log(JSON.stringify(aData)); // {\"action\":\"bot_call\",\"amount\":0}\n console.log(\"AutoPlay action: \" + aData.action);\n switch (aData.action) {\n case 'bot_fold':\n foldBtnClick();\n break;\n case 'bot_check':\n checkBtnClick();\n break;\n case 'bot_call':\n checkBtnClick();\n break;\n case 'bot_raise':\n setRaise(aData.amount);\n break;\n case 'remove_bot': // Bot run out of money\n location.reload(); // Run out of money basically\n break;\n default:\n checkBtnClick();\n break;\n }\n autoPlayCommandRequested = false; // reset always\n}", "title": "" }, { "docid": "b74a6fefd8aabd91fe7f780f69d266d9", "score": "0.53083646", "text": "userSpeechStart() {\n const event = { event_name: 'furhatos.event.senses.SenseTypingStart' };\n this.send(event);\n }", "title": "" }, { "docid": "6db67aedf9ea987ff5b17d6a62f379e7", "score": "0.53081065", "text": "function youWon () {\n\t$('#MainTitle').text(\"You Won!!!!\");\n}", "title": "" }, { "docid": "6ce1816e63befc2733a634aeaabc1365", "score": "0.53080815", "text": "function handleAnswer(answer) {\n yourConn.setRemoteDescription(new RTCSessionDescription(answer));\n callAccept.style.display = \"block\";\n //ansBtn.style.display = \"none\";\n ansBtn.disabled = true;\n document.querySelector('#callAccept p.message').textContent = callToUsernameInput.value + ' is Connected';\n document.querySelector('#callReq').style.display = \"none\";\n callPage.style.display = \"block\"; \n //callPage.style.display = \"block\";\n\n }", "title": "" } ]
cc301bc08426303c03d64e02f17aab04
All functions to be called on $(window).resize() should be in this function
[ { "docid": "ac6c2f3efd5f41f22633da471714380f", "score": "0.73931634", "text": "function qodeOnWindowResize() {\n }", "title": "" } ]
[ { "docid": "f29663224a11edc35a30288fa859044e", "score": "0.77580404", "text": "function InitializeResizeHandler() {\n $(window).resize(Screen.reposition);\n }", "title": "" }, { "docid": "a48859904a9d4765732c822897aec942", "score": "0.7713837", "text": "function windowReSize(){\r\n $(window).resize(function() {\r\n disableScrollBy();\r\n dropdownNavP();\r\n if ($(window).width() > 979) {\r\n hoverBrand();\r\n }\r\n });\r\n}", "title": "" }, { "docid": "d04e4af4ea7f9f79ef7b84ae1e820979", "score": "0.76635975", "text": "function resizeHandler(){\n //checking if it needs to get responsive\n responsive();\n\n // rebuild immediately on touch devices\n if (isTouchDevice) {\n var activeElement = $(document.activeElement);\n\n //if the keyboard is NOT visible\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\n var currentHeight = $window.height();\n\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\n FP.reBuild(true);\n previousHeight = currentHeight;\n }\n }\n }else{\n //in order to call the functions only when the resize is finished\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\n clearTimeout(resizeId);\n\n resizeId = setTimeout(function(){\n FP.reBuild(true);\n }, 350);\n }\n }", "title": "" }, { "docid": "e20be744f4bf35f13cb17943a19cf154", "score": "0.75779843", "text": "function resizeHandler(){\r\n //checking if it needs to get responsive\r\n responsive();\r\n\r\n // rebuild immediately on touch devices\r\n if (isTouchDevice) {\r\n var activeElement = $(document.activeElement);\r\n\r\n //if the keyboard is NOT visible\r\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\r\n var currentHeight = $window.height();\r\n\r\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\r\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\r\n FP.reBuild(true);\r\n previousHeight = currentHeight;\r\n }\r\n }\r\n }else{\r\n //in order to call the functions only when the resize is finished\r\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\r\n clearTimeout(resizeId);\r\n\r\n resizeId = setTimeout(function(){\r\n FP.reBuild(true);\r\n }, 350);\r\n }\r\n }", "title": "" }, { "docid": "e396aeb3684425226e687848f48c526c", "score": "0.7563087", "text": "function resizeHandler(){\n //checking if it needs to get responsive\n responsive();\n\n // rebuild immediately on touch devices\n if (isTouchDevice) {\n var activeElement = $(document.activeElement);\n\n //if the keyboard is NOT visible\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\n var currentHeight = $window.height();\n\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\n reBuild(true);\n previousHeight = currentHeight;\n }\n }\n }else{\n //in order to call the functions only when the resize is finished\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\n clearTimeout(resizeId);\n\n resizeId = setTimeout(function(){\n reBuild(true);\n }, 350);\n }\n }", "title": "" }, { "docid": "e396aeb3684425226e687848f48c526c", "score": "0.7563087", "text": "function resizeHandler(){\n //checking if it needs to get responsive\n responsive();\n\n // rebuild immediately on touch devices\n if (isTouchDevice) {\n var activeElement = $(document.activeElement);\n\n //if the keyboard is NOT visible\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\n var currentHeight = $window.height();\n\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\n reBuild(true);\n previousHeight = currentHeight;\n }\n }\n }else{\n //in order to call the functions only when the resize is finished\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\n clearTimeout(resizeId);\n\n resizeId = setTimeout(function(){\n reBuild(true);\n }, 350);\n }\n }", "title": "" }, { "docid": "e396aeb3684425226e687848f48c526c", "score": "0.7563087", "text": "function resizeHandler(){\n //checking if it needs to get responsive\n responsive();\n\n // rebuild immediately on touch devices\n if (isTouchDevice) {\n var activeElement = $(document.activeElement);\n\n //if the keyboard is NOT visible\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\n var currentHeight = $window.height();\n\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\n reBuild(true);\n previousHeight = currentHeight;\n }\n }\n }else{\n //in order to call the functions only when the resize is finished\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\n clearTimeout(resizeId);\n\n resizeId = setTimeout(function(){\n reBuild(true);\n }, 350);\n }\n }", "title": "" }, { "docid": "e396aeb3684425226e687848f48c526c", "score": "0.7563087", "text": "function resizeHandler(){\n //checking if it needs to get responsive\n responsive();\n\n // rebuild immediately on touch devices\n if (isTouchDevice) {\n var activeElement = $(document.activeElement);\n\n //if the keyboard is NOT visible\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\n var currentHeight = $window.height();\n\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\n reBuild(true);\n previousHeight = currentHeight;\n }\n }\n }else{\n //in order to call the functions only when the resize is finished\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\n clearTimeout(resizeId);\n\n resizeId = setTimeout(function(){\n reBuild(true);\n }, 350);\n }\n }", "title": "" }, { "docid": "3102c291bab7626422f5f7bd2754c03e", "score": "0.75400025", "text": "function qodefOnWindowResize() {\n\n }", "title": "" }, { "docid": "0e5cac475711573573126bb97d7c45b7", "score": "0.74985963", "text": "function onWindowResize(){\n\t/*\n\t * On news pop up page set the width of NEWS table.\n\t */\n\tif($('.newspopup').length > 0){\n\t\tsetDisplayableNewsTableArea();\n\t}\n\t/*\n\t * Place the info icon on My Account -> Your targets tab close to the text when window size changes.\n\t */\n\tif($('#input-suffix-text').length > 0){\n\t\tplaceInfoIconOnAcctTargets();\n\t}\n\n\t/* \n\t * If current page is health.html initialize the Graph UI as per the current width\n\t * of the screen\n\t */\n\tif($('#respirationRate_chart_container').length > 0){\n\t\tredrawGraphs();\n\t\tinitializeGraphUI();\n\t}\n\n}", "title": "" }, { "docid": "579a135d8a8b9c27fd6f585ab07a2d32", "score": "0.7479208", "text": "function resizeHandler(){\r\n //checking if it needs to get responsive\r\n responsive();\r\n\r\n // rebuild immediately on touch devices\r\n if (isTouchDevice) {\r\n var activeElement = $(document.activeElement);\r\n\r\n //if the keyboard is NOT visible\r\n if (!activeElement.is('textarea') && !activeElement.is('input') && !activeElement.is('select')) {\r\n var currentHeight = $window.height();\r\n\r\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\r\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\r\n reBuild(true);\r\n previousHeight = currentHeight;\r\n }\r\n }\r\n }else{\r\n //in order to call the functions only when the resize is finished\r\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\r\n clearTimeout(resizeId);\r\n\r\n resizeId = setTimeout(function(){\r\n reBuild(true);\r\n }, 350);\r\n }\r\n }", "title": "" }, { "docid": "48342e309ac9ae18237bd2f30852c451", "score": "0.7456228", "text": "function onResize() {\n\n\t\t\t// Check window width has actually changed and it's not just iOS triggering a resize event on scroll\n\t if ($(window).width() != windowWidth) {\n\n\t // Update the window width for next time\n\t windowWidth = $(window).width();\n\n\t\t\t\t// If window size is okay, allow click event\n\t\t\t\t// and hide main navigation.\n\t\t\t\tif ( $( window ).width() < 841 ) {\n\t\t\t\t\tclickAllowed = true;\n\t\t\t\t\t$( '.main-navigation, .social-links' ).hide();\n\t\t\t\t} else {\n\t\t\t\t\t// If window size is not okay, disallow click\n\t\t\t\t\t// event and display main navigation.\n\t\t\t\t\tclickAllowed = false;\n\t\t\t\t\t$( '.main-navigation, .social-links' ).show();\n\t\t\t\t}\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "a6bd9ea7b14811fd167d1898b3136c33", "score": "0.74507254", "text": "function myResize() {\n\t\t\t\n mqSync();\n\t\t\tif(!processed) {\n\t\t\t\t// Note: This only support one round of bs processing so resizing does not undo bootstrap / collapse\n\t\t\t\t// TODO: Build undo that is applied only when going from mobile to M or L\n\t\t\t\tbootstrapify(activeMQ);\n\t\t\t}\n\t\t\texpand(); // process collapse\n\t\t\tif(!processed) {\n\t\t\t\tif($('#thumb-section').length !== 0) {\n\t\t\t\t\tthumbify(activeMQ,'#thumb-section','section','.panel-heading',false);\n\t\t\t\t}\n\t\t\t}\n\t\t\t\n\t\t\trefresh_right_panel(); // Affects page types with body.has-shadow-am\n\t\t\t\n\t\t\tprocessed = true;\n\t\t} // /myResize()", "title": "" }, { "docid": "94f7eb64439135a3469c7724ef08045b", "score": "0.7408962", "text": "function qodeOnWindowResize() {\n\n\t}", "title": "" }, { "docid": "b909cca0ea5fa7a4e852f3c718bb1015", "score": "0.73614043", "text": "function resizeHandler(){\r\n //checking if it needs to get responsive\r\n responsive();\r\n\r\n // rebuild immediately on touch devices\r\n if (isTouchDevice) {\r\n var activeElement = document.activeElement;\r\n\r\n //if the keyboard is NOT visible\r\n if (!matches(activeElement, 'textarea') && !matches(activeElement, 'input') && !matches(activeElement, 'select')) {\r\n var currentHeight = getWindowHeight();\r\n\r\n //making sure the change in the viewport size is enough to force a rebuild. (20 % of the window to avoid problems when hidding scroll bars)\r\n if( Math.abs(currentHeight - previousHeight) > (20 * Math.max(previousHeight, currentHeight) / 100) ){\r\n resizeId = setTimeout(function(){\r\n reBuild(true);\r\n previousHeight = currentHeight;\r\n\r\n //issue #3336\r\n //when using Chrome we add a small timeout to get the right window height \r\n //https://stackoverflow.com/a/12556928/1081396\r\n //https://stackoverflow.com/questions/13807810/ios-chrome-detection\r\n }, navigator.userAgent.match('CriOS') ? 50 : 0);\r\n }\r\n }\r\n }else{\r\n //in order to call the functions only when the resize is finished\r\n //http://stackoverflow.com/questions/4298612/jquery-how-to-call-resize-event-only-once-its-finished-resizing\r\n clearTimeout(resizeId);\r\n\r\n resizeId = setTimeout(function(){\r\n reBuild(true);\r\n }, 350);\r\n }\r\n }", "title": "" }, { "docid": "610488f6e85e7a7aa95877d131987271", "score": "0.73584104", "text": "function handleResize() {\n if (resizeTimer) clearTimeout(resizeTimer);\n\n if (windowHeight != $(window).height() || windowWidth != $(window).width())\n {\n resizeTimer = setTimeout(init, 100);\n }\n }", "title": "" }, { "docid": "8415501b76dd97b412a807d1e72d3162", "score": "0.73067516", "text": "onWindowResize() {\n this.recalculate();\n }", "title": "" }, { "docid": "0af06c83016dfc91343366015866bbd2", "score": "0.7292801", "text": "onResize() { }", "title": "" }, { "docid": "56d7dc1aac676b690f8f7dcef3a960b8", "score": "0.72324896", "text": "function mkdfOnWindowResize() {\n\t mkdfTourGalleryMasonry();\n }", "title": "" }, { "docid": "34409d7f98e7f025c78785d3cbdc7f64", "score": "0.7225385", "text": "function handleResize() {\n\t\t\tif (resizeTimer) clearTimeout(resizeTimer);\n\t\t\t\n\t\t\tif (windowHeight != $(window).height() || windowWidth != $(window).width()) \n\t\t\t\tresizeTimer = setTimeout(reinit, 100);\n\t\t}", "title": "" }, { "docid": "c1d19ea067e6d9dc66ec2cf3f3d45084", "score": "0.72159004", "text": "function qodeOnWindowResize() {\n\t qodeTourGalleryMasonry();\n }", "title": "" }, { "docid": "e00235eae27bbd7696b84cfad3d2fdfb", "score": "0.72017485", "text": "function resizeHelper(){\n\t\t/* Global Nav rebuild the slides */\n\t\tif(typeof _GN != 'undefined'){\n\t\t\t_GN.createSlides(_GN.initSwipe); \n\t\t}\t\t\n\t\t/* Episode Guide - episode-guide.js */\n\t\tif(typeof _EG != 'undefined'){\n\t\t\t_EG.resizeEG(); \n\t\t}\n\t\t/* coming soon module swipe - video-home.js */\n\t\tif (typeof _csmS != 'undefined') {\n\t\t\t_csmS.resizeSwipe();\n\t\t}\n\t\t/* homepage navgation bar - /static/homepage/js/nav-bar.js */\n\t\tif (typeof _hpNav != 'undefined'){\n\t\t\t_hpNav.checkSize();\n\t\t}\n\t\t/* Apps card and other mobile cards */\n\t\tif (typeof _cnglobal.homepage != 'undefined'){\n\t\t\t_cnglobal.homepage.checkSize();\n\t\t}\n\t\t/* Apps card */\n\t\tif (typeof gameCardDisplay != 'undefined'){\n\t\t\tgameCardDisplay();\n\t\t}\t\n\t\t/* campaign video card */\n\t\tif (typeof homepageCampaignVideo != 'undefined'){\n\t\t\tif ($('#overlay').hasClass('active') === true){\n\t\t\t\thomepageCampaignVideo.centerVideo();\n\t\t\t}\n\t\t}\n\t\t/* multi use card */\n\t\tif (typeof _multiCard != 'undefined'){\n\t\t\t_multiCard.checkSize();\n\t\t} \n\t\t/* video home page's unlocked module */\n\t\tif (typeof _UM != 'undefined'){\n\t\t\t_UM.resetSlider();\n\t\t}\n\t}", "title": "" }, { "docid": "b83717935c265614928d172b11ca9a51", "score": "0.7200146", "text": "function windowResizeEventHandler() {\n adjustToContainer();\n }", "title": "" }, { "docid": "a911c116d7a9a93630e4c8dc22f15976", "score": "0.71853775", "text": "onResize() {}", "title": "" }, { "docid": "a911c116d7a9a93630e4c8dc22f15976", "score": "0.71853775", "text": "onResize() {}", "title": "" }, { "docid": "d7f224a11910b06469a828401dd1873c", "score": "0.71818686", "text": "function onresize(){\r\n\trefresh(); // refresh after any window size changed\r\n}", "title": "" }, { "docid": "546dd1f388b5a9520f5470d1506635ee", "score": "0.71309125", "text": "function resizeEvents() {\r\n repositionFooter();\r\n mainMargin();\r\n}", "title": "" }, { "docid": "a2e33836692b505c4b0678ed8fb95b87", "score": "0.7119496", "text": "function window_resize_handler() {\n\t\t\tvar window_height = $(window).height();\n\t\t\tvar window_width = $(window).width();\n\n\t\t\t// fit left menu\n\t\t\tvar left_menu = $(\"#leftMenu\");\n\t\t\tvar new_height = \n\t\t\t\twindow_height - \n\t\t\t\t$(\"#left-menu-footer\").height() - \n\t\t\t\tleft_menu.offset().top;\n\t\t\tleft_menu.height(new_height);\n\n\t\t\t// fit main container\n\t\t\tvar main_container = $(\"#main-container\");\n\t\t\tvar new_width = \n\t\t\t\twindow_width -\n\t\t\t\t$(\"#leftCol\").width();\n\t\t\tmain_container.width(new_width);\n\n\t\t\tvar main_view = $(\"#main-view\");\n\t\t\t$(\"#main-view\").css(\"min-height\", window_height - 10);\n\t\t}", "title": "" }, { "docid": "6349d393cbec041ebebd2e0b959ade2f", "score": "0.7118498", "text": "function edgtfOnWindowResize() {\n edgtfInitBlogListMasonry();\n\t\t//edgtfInitBlogSlider();\n edgtfCustomFontResize();\n edgtfInitPortfolioListMasonry();\n edgtfInitPortfolioListPinterest();\n edgtfInitMessageHeight();\n }", "title": "" }, { "docid": "252c5b3fb9970abef3cfe5bd9cdd2e0a", "score": "0.70948106", "text": "onResize() {\n this.shutdown();\n this.init();\n }", "title": "" }, { "docid": "6a66e9ec835348af3f77d02d39a5cdb2", "score": "0.70893013", "text": "function doneResize(t){$(window).resize(function(){clearTimeout(window.resizeHandler),window.resizeHandler=setTimeout(function(){t()},250)})}", "title": "" }, { "docid": "9e02da251128851831980a69f87b9c6e", "score": "0.7083247", "text": "function window_resize(elem) {\n\telem.css(\"height\", \"auto\");\n\telem.reset_height();\n\telem.reset_width();\n\tif ($(\"body\").innerWidth() > 640) {\n\t\t$(\"body\").unbind(\"swipeleft\");\n\t\t$(\"body\").unbind(\"swiperight\");\n\t} else {\n\t\t$(\"body\").swipeleft(function() { show_right(elem); });\n\t\t$(\"body\").swiperight(function() { show_left(elem); });\n\t}\n}", "title": "" }, { "docid": "0c1f6c9c73182964d06c4512d11bec03", "score": "0.70826113", "text": "_resizeHandler() {\n this._updateMetrics();\n this.trigger('resize', {width: this.width, height: this.height});\n this._detectBreakpoint();\n }", "title": "" }, { "docid": "bd0722eb0982f92081f79f141c2580fc", "score": "0.7078533", "text": "function resize() {\n smallScreen = width(body) < SMALL_SCREEN_WIDTH;\n refitSidebar();\n refitContent();\n switch (mode) {\n case VISUALISE:\n refitVisualise();\n break;\n case CONFIGURE:\n refitConfigure();\n break;\n }\n }", "title": "" }, { "docid": "f825e77cf148740644775efe86f2c3c6", "score": "0.7071548", "text": "function resizeListener(){\n\t/* add resize listener with a timeout so that it doesn't fire constantly */\n\t$(window).resize(function(e) {\n\t if(this.resizeDone) {\n\t \tclearTimeout(this.resizeDone);\n\t }\n\t\tthis.resizeDone = setTimeout(resizeHelper,200);\t\t\n\t});\n\n\t/* check to see if object/function exists before using it */\n\tfunction resizeHelper(){\n\t\t/* Global Nav rebuild the slides */\n\t\tif(typeof _GN != 'undefined'){\n\t\t\t_GN.createSlides(_GN.initSwipe); \n\t\t}\t\t\n\t\t/* Episode Guide - episode-guide.js */\n\t\tif(typeof _EG != 'undefined'){\n\t\t\t_EG.resizeEG(); \n\t\t}\n\t\t/* coming soon module swipe - video-home.js */\n\t\tif (typeof _csmS != 'undefined') {\n\t\t\t_csmS.resizeSwipe();\n\t\t}\n\t\t/* homepage navgation bar - /static/homepage/js/nav-bar.js */\n\t\tif (typeof _hpNav != 'undefined'){\n\t\t\t_hpNav.checkSize();\n\t\t}\n\t\t/* Apps card and other mobile cards */\n\t\tif (typeof _cnglobal.homepage != 'undefined'){\n\t\t\t_cnglobal.homepage.checkSize();\n\t\t}\n\t\t/* Apps card */\n\t\tif (typeof gameCardDisplay != 'undefined'){\n\t\t\tgameCardDisplay();\n\t\t}\t\n\t\t/* campaign video card */\n\t\tif (typeof homepageCampaignVideo != 'undefined'){\n\t\t\tif ($('#overlay').hasClass('active') === true){\n\t\t\t\thomepageCampaignVideo.centerVideo();\n\t\t\t}\n\t\t}\n\t\t/* multi use card */\n\t\tif (typeof _multiCard != 'undefined'){\n\t\t\t_multiCard.checkSize();\n\t\t} \n\t\t/* video home page's unlocked module */\n\t\tif (typeof _UM != 'undefined'){\n\t\t\t_UM.resetSlider();\n\t\t}\n\t}\n}", "title": "" }, { "docid": "935d7fb587a9048c11bffed311415de9", "score": "0.70671266", "text": "function edgtfOnWindowResize() {\n }", "title": "" }, { "docid": "935d7fb587a9048c11bffed311415de9", "score": "0.70671266", "text": "function edgtfOnWindowResize() {\n }", "title": "" }, { "docid": "ddefc3b9e375e7995444764de65f88c2", "score": "0.7065012", "text": "function resizeFunction() {\n\n if (isMobile && window.innerWidth >= MOBILE_BREAKPOINT) {\n console.log(\"going to bigger layout\")\n isMobile =false;\n redraw()\n\n }else if (!isMobile && window.innerWidth <= MOBILE_BREAKPOINT) {\n console.log(\"going to smaller layout\")\n isMobile =true;\n redraw()\n } else {\n\n }\n }", "title": "" }, { "docid": "ce8d282f1677f8b59d05c6a641692ae8", "score": "0.70589083", "text": "function resize(e) {\n var vw = $(window).width();\n if(vw <= config.breakingPoint) unrustic();\n else rerustic();\n }", "title": "" }, { "docid": "0f541238ed71272f067f7e52f15dccfe", "score": "0.70502234", "text": "onWindowResize() {\n debugLog('ForceHorseViewer:onWindowResize');\n\n this.calcFixAspectRatio();\n this.updateGraphInDOM();\n }", "title": "" }, { "docid": "6c16c82587551236462da68e7cc72bdc", "score": "0.7033151", "text": "function onResize(event) {\n}", "title": "" }, { "docid": "414581e5b644fc1a77f486e94421a71d", "score": "0.7030388", "text": "function resizeHandler() {\n /* console.clear()\n console.log($(window).width()) */\n\n if ($(window).width() < 485) {\n if (windowSize == \"Large\") {\n $(\"#sidebar\").hide()\n $(\"#menu\").show()\n $(\"#sidebar a\").css({\"font-size\":\"24pt\", \"border\":\"1px solid black\",\"width\":\"4em\"})\n $(\"#sidebar a:hover\").css({\"width\":\"9em\", \"z-index\":\"10001\"})\n $(\"h2\").css(\"width\",\"70vw\")\n $(\"h1\").css(\"width\",\"70%\")\n windowSize = \"Small\"\n }\n $(\"#contactMain\").css(\"left\", \"2%\")\n $(\"#contactMain p\").css({\"font-size\":\"100%\", \"margin-top\":\"1%\"})\n $(\"#sidebar\").css({\"position\":\"absolute\", \"left\":\"-220%\", \"top\":\"0%\", \"width\":\"4em\", \"z-index\":\"10000\"})\n } else {\n if (windowSize = \"Small\") {\n hideMenu()\n $(\"#menu\").hide()\n $(\"#contactMain\").css(\"left\", \"8em\")\n $(\"#sidebar a\").css({\"font-size\":\"18pt\", \"border\":\"none\",\"width\":\"4em\"})\n $(\"#sidebar\").show()\n $(\"#contactMain\").before($(\"#sidebar\"))\n windowSize = \"Large\"\n $(\"h1\").css(\"width\",\"100%\")\n }\n $(\"#contactMain p\").css({\"font-size\":\"120%\", \"margin-top\":\"0%\"})\n screenWidth = $(window).width()/parseFloat($(\"#contactMain\").css(\"font-size\"));\n mainWidth = (0.8 * (screenWidth - 12)).toString() + \"em\";\n h2Width = (0.4 * (screenWidth - 6)).toString() + \"em\";\n $(\"#contactMain p\").css(\"width\", mainWidth)\n $(\"h2\").css(\"width\", h2Width)\n $(\"#sidebar\").css({\"position\":\"relative\", \"left\":\"1em\", \"top\":\"250%\", \"width\":\"4em\", \"z-index\":\"9999\"})\n }\n}", "title": "" }, { "docid": "47bff96fb5de30d3c4df33706f34fb4a", "score": "0.70133656", "text": "function resize() {\n positionSectionTitles();\n positionCategoriesFooter();\n resizeTracker();\n // resizeSectionHeader();\n}", "title": "" }, { "docid": "3c73762a8ae370014a995fdeb47ac7b6", "score": "0.7001779", "text": "function edgtfOnWindowResize() {\n\t edgtfInitGridMasonryListLayout();\n \tedgtfSelfHostedVideoSize();\n }", "title": "" }, { "docid": "48d38d7093e40009cff8685169b490d4", "score": "0.69853824", "text": "function edgtfOnWindowResize() {\n edgtfInitPortfolioMasonry();\n }", "title": "" }, { "docid": "dc4add7fe4964aa64892bbe799832db0", "score": "0.6984154", "text": "function resize() {\n \n}", "title": "" }, { "docid": "11e433088d91d21707ac76c6f6f1a5c2", "score": "0.6965093", "text": "updated() {\n window.onresize()\n }", "title": "" }, { "docid": "c8c6eb3bbf64e0582e589eea082525b7", "score": "0.69464535", "text": "function edgtfOnWindowResize() {\n\n }", "title": "" }, { "docid": "aae72d159a12b3b3e8e4f87b33992d6f", "score": "0.69458175", "text": "function resizer()\n{\n\t\n\n\t//welcomeScreen2 jQuery media query\n\tif(window.innerWidth > 769 && $('#header').hasClass('welcome2'))\n\t{\n\t\t$('#lockImg').fadeIn(0);\n\t}\n\t//congratsScreen jQuery media query\n\telse if(window.innerWidth > 769 && $('#header').hasClass('congrats'))\n\t{\n\t\t$('#trophyImg').fadeIn(0);\n\t}\n\t//welcomeScreen1 jQuery media query\n\telse if(window.innerWidth > 769 && $('#header').hasClass('welcome'))\n\t{\n\t\t$('#bulbImg').fadeIn(0);\n\t}\n\t//welcomeScreens jQuery media query\n\telse\n\t{\n\t\t$('#lockImg').fadeOut(0);\n\t\t$('#bulbImg').fadeOut(0);\n\t\t$('#trophyImg').fadeOut(0);\n\t}\n\t//uploadContainer jQuery media query\n\tif((window.innerWidth*0.9)<500)\n\t{\n\t\t\t$('#uploadContainer').css({marginLeft:'-45%'});\n\t\t\t$('#uploadContainer div#uploadProgress').css({width:'55%'});\n\t}\n\t//uploadContainer jQuery media query\n\telse\n\t{\n\t\t$('#uploadContainer').css({marginLeft:'-250px'});\n\t\t\t$('#uploadContainer div#uploadProgress').css({width:'75%'});\n\t}\n\t//welcomeScreens jQuery media queries for Window height and #main div height\n\tif($('#header').hasClass('welcome') || $('#header').hasClass('congrats') || $('#header').hasClass('welcome2'))\n\t{\n\t\tif((window.innerHeight-100) > parseInt($('#welcomeScreen1').css('height')))\n\t\t{\n\t\t\t$('#main').height((window.innerHeight-100));\n\t\t\t$('#welcomeScreens').height((window.innerHeight-100));\n\t\t\tconsole.log(parseInt($('#welcomeScreen1').css('height')));\n\n\t\t}\n\t\telse\n\t\t{\n\t\t\t$('#main').height(parseInt($('#welcomeScreen1').css('height'))+10);\n\t\t\t$('#welcomeScreens').height(parseInt($('#welcomeScreen1').css('height'))+10);\n\t\t\t\n\t\t}\n\n\t}\n\t//NON welcomeScreens jQuery media queries for Window height and #main div height\n\t//when menu is active\n\tif($('#main').hasClass('fullHeight') && !$('#header').hasClass('welcome') && !$('#header').hasClass('welcome2') && !$('#header').hasClass('congrats') )\n\t{\n\t\tif(window.innerWidth < 768)\n\t\t{\n\t\t\t$('#main').height((window.innerHeight-100));\n\n\t\t\tif($('#formContainer').hasClass('menuActive'))\n\t\t\t{\n\n\t\t\t\tif((window.innerHeight-100)>350)\n\t\t\t\t{\n\t\t\t\t\t$('#main').height((window.innerHeight-100));\n\t\t\t\t}\n\t\t\t\t\t\t\t\t\n\t\t\t\telse\n\t\t\t\t{\n\t\t\t\t\t$('#main').height(350);\t\t\t\t\t\t\n\t\t\t\t}\t\t\t\t\t\t\n\t\t\t\t\t\t\t\t\t\t\t\t\t\n\t\t\t}\n\n\t\t\telse\n\t\t\t{\n\t\t\t\n\t\t\t\t$('#main').css({\n\t\t\t\t\theight: 'auto'\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\t\t\n\t}\n\n\t/**The media queries for activeScreens **/\n\tif($('.activeScreen').attr('id')=='review')\n\t{\n\t\t$('#screensContainer').height($('.activeScreen').height());\n\t}\n\telse\n\t{\n\t\tif(window.innerWidth<769)\n\t\t\t{\n\t\t\t\tif($('#gettingPaid').hasClass('activeScreen'))\n\t\t\t\t{\n\t\t\t\t\t\tvar screenViewHeight=($('.activeScreen').height() )+'px';\n\t\t\t\t}\n\t\t\t\tvar screenViewHeight=($('.activeScreen').height() )+'px';\n\t\t\t}\n\t\t\telse\n\t\t\t{\n\t\t\t\tvar screenViewHeight=($('.activeScreen').height() )+'px';\n\t\t\t}\n\t\t$('#screensContainer').animate({height:screenViewHeight},30);\n\t}\n\n\tvar offsetPos=$('.activeScreen').offset().top-$('#screensContainer').offset().top;\n\t$('#screensContainer').animate({scrollTop:$('#screensContainer').scrollTop()+offsetPos},0);\n}", "title": "" }, { "docid": "2b92b49827d63ecf8469e905f55322aa", "score": "0.6940621", "text": "function onResize() {\r\n\tif (projectGallery) {\r\n\t\tprojectGallery.onResize();\r\n\t}\r\n\r\n\tif (navigation) {\r\n\t\tnavigation.onResize();\r\n\t}\r\n}", "title": "" }, { "docid": "e963f336ceb359bb0be42c7254ed6186", "score": "0.6937328", "text": "function onWindowResize( event ) {\n\n layout();\n\n }", "title": "" }, { "docid": "dbf4edd2280f4149932eb600b05ad48c", "score": "0.693094", "text": "function resizeCall(){\r\n\t\tpageCalculations();\r\n\t}", "title": "" }, { "docid": "24fa3344715d84feb171989cb06bd0e1", "score": "0.692452", "text": "function windowResized() {\n resize();\n redraw();\n}", "title": "" }, { "docid": "263704f94a62ddd4fd1dbcb0e52dad95", "score": "0.6924511", "text": "function x_navigation_onresize(){ \n \n var inner_port = window.innerWidth || $(document).width();\n \n if(inner_port < 1025){ \n $(\".page-sidebar .x-navigation\").removeClass(\"x-navigation-minimized\");\n $(\".page-container\").removeClass(\"page-container-wide\");\n $(\".page-sidebar .x-navigation li.active\").removeClass(\"active\");\n \n \n $(\".x-navigation-horizontal\").each(function(){ \n if(!$(this).hasClass(\"x-navigation-panel\")){ \n $(\".x-navigation-horizontal\").addClass(\"x-navigation-h-holder\").removeClass(\"x-navigation-horizontal\");\n }\n });\n \n \n }else{ \n if($(\".page-navigation-toggled\").length > 0){\n x_navigation_minimize(\"close\");\n } \n \n $(\".x-navigation-h-holder\").addClass(\"x-navigation-horizontal\").removeClass(\"x-navigation-h-holder\"); \n }\n \n}", "title": "" }, { "docid": "263704f94a62ddd4fd1dbcb0e52dad95", "score": "0.6924511", "text": "function x_navigation_onresize(){ \n \n var inner_port = window.innerWidth || $(document).width();\n \n if(inner_port < 1025){ \n $(\".page-sidebar .x-navigation\").removeClass(\"x-navigation-minimized\");\n $(\".page-container\").removeClass(\"page-container-wide\");\n $(\".page-sidebar .x-navigation li.active\").removeClass(\"active\");\n \n \n $(\".x-navigation-horizontal\").each(function(){ \n if(!$(this).hasClass(\"x-navigation-panel\")){ \n $(\".x-navigation-horizontal\").addClass(\"x-navigation-h-holder\").removeClass(\"x-navigation-horizontal\");\n }\n });\n \n \n }else{ \n if($(\".page-navigation-toggled\").length > 0){\n x_navigation_minimize(\"close\");\n } \n \n $(\".x-navigation-h-holder\").addClass(\"x-navigation-horizontal\").removeClass(\"x-navigation-h-holder\"); \n }\n \n}", "title": "" }, { "docid": "13a82939cfe421873fe860517cfb4bb1", "score": "0.69148684", "text": "function _setEvents(){\n var _self = this;\n \n var resizeTimeout;\n \n $(window).resize(function(){\n clearTimeout(resizeTimeout);\n resizeTimeout = setTimeout(_handleResize.call(_self), 500);\n });\n\n }", "title": "" }, { "docid": "8f4efe87d4f20909bc43ae989c69c17f", "score": "0.6896014", "text": "function addOnresizeEvent(func){addEvent(window, 'resize', func);}", "title": "" }, { "docid": "8c20197a2d78c1d321f0716fa5262f7b", "score": "0.6888212", "text": "function checkSizeHandler() {\n checkSize();\n $(window).resize(checkSize); \n}", "title": "" }, { "docid": "fe44ec0fad64613b7017a6a5dc292c93", "score": "0.68814373", "text": "on_resize_started() {\n }", "title": "" }, { "docid": "63293560495ac8627070f8b20938441e", "score": "0.6880108", "text": "function adjustForWidth(){\n \n /* Called every time there is a change in window width */\n $(window).resize(function(){\n //console.log($(window).width());\n if($(window).width() <= 700){\n console.log(\"It's less!\");\n $(\".my-btn\").css(\"font-size\", \"20px\"); \n $(\"#start\").css(\"font-size\", \"20px\");\n $(\".text\").css(\"font-size\", \"20px\");\n }\n else if($(window).width() >= 700){\n console.log(\"It's more!\");\n $(\".my-btn\").css(\"font-size\", \"40px\");\n $(\"#start\").css(\"font-size\", \"40px\");\n $(\".text\").css(\"font-size\", \"40px\"); }\n });\n\n /* Check screen width on launch */\n if($(window).width() <= 700){\n console.log(\"It's less!\");\n $(\".my-btn\").css(\"font-size\", \"20px\"); \n $(\"#start\").css(\"font-size\", \"20px\");\n $(\".text\").css(\"font-size\", \"20px\");\n }\n else if($(window).width() >= 700){\n console.log(\"It's more!\");\n $(\".my-btn\").css(\"font-size\", \"40px\");\n $(\"#start\").css(\"font-size\", \"40px\");\n $(\".text\").css(\"font-size\", \"40px\");\n }\n\n}", "title": "" }, { "docid": "0d7508355f099796ccfae84079722723", "score": "0.68774927", "text": "runOnResize() {\n var totHeight = this.inner.clientHeight + this.topMargin + this.margin,\n docElem = document.documentElement;\n this.winW = Math.max(docElem.clientWidth, window.innerWidth || 0);\n this.winH = Math.max(docElem.clientHeight, window.innerHeight || 0);\n // if desktop size\n if (this.winW > 992) {\n this.noScroll = (this.winH - totHeight) >= 0;\n // if switching from mobile or positioned on bottom\n if (this.mobile || this.positionVal === 'bottom') {\n this.mobile = false;\n this.innerTop = -1;\n this.hold = false;\n this.runOnScroll();\n }\n // if mobile size position is static\n } else {\n this.mobile = true;\n if (this.inner.style.position !== 'static') {\n this.inner.style.position = 'static';\n }\n }\n }", "title": "" }, { "docid": "4f475020962d82bbc0ae6fa9b26ac229", "score": "0.6865565", "text": "function renderBugFix()\n{\n\t$(window).resize();\n\t\n }", "title": "" }, { "docid": "9ece5db49c9f0d1272a667c16901c192", "score": "0.6864151", "text": "function onResize() {\n World.onResize();\n\tController.onResize();\n}", "title": "" }, { "docid": "9b3d6c2bf3d68ee9eff53a4b3c6364c5", "score": "0.68606323", "text": "function handleWindowResize() {\n // These are not initialized in Jasmine Spec Runner window until a test\n // is run that creates a mock document.\n if (!$windowContent || !$editorHolder) {\n return;\n }\n\n // FIXME (issue #4564) Workaround https://github.com/codemirror/CodeMirror/issues/1787\n triggerUpdateLayout();\n\n if (!windowResizing) {\n windowResizing = true;\n\n // We don't need any fancy debouncing here - we just need to react before the user can start\n // resizing any panels at the new window size. So just listen for first mousemove once the\n // window resize releases mouse capture.\n $(window.document).one(\"mousemove\", function () {\n windowResizing = false;\n updateResizeLimits();\n });\n }\n }", "title": "" }, { "docid": "4591b8b3bf17e12d3c688b6ec6568615", "score": "0.685673", "text": "function onResize() {\n\n removeStickyHeader();\n\n $frozenTables.each( function() {\n\n \tvar $table = $(this);\n\n \tif( isSmallDevice() ) {\n\n \t\tif( !$table.hasClass( 'split' ) ) {\n\n \t\t\tfrozenTable( $table );\n \t\t}\n\n \t} else {\n\n \t\tif( $table.hasClass( 'split' ) ) {\n \t\t\t\n \t\t\toriginalTable( $table );\n \t\t}\n\n \t}\n\n });\n }", "title": "" }, { "docid": "06e48d3f9f9a34c6a3630b486325a50b", "score": "0.68554044", "text": "function onResize(){\n\t//Get available space\n\tvar availableWidth = $(window).width() ;\n\tvar availableHeight = $(window).height() ;\n\t\n\tif(!(availableWidth <= 700 || availableHeight <= 500)){\n\t\tavailableWidth *= 0.8;\n\t\tavailableHeight *= 0.9;\n\t}\n\telse{\n\t\tavailableWidth -= 20;\n\t\tavailableHeight -= 20;\n\t}\n\n\t\n\t//Final sizes\n\tvar width = contentOriginalWidth;\n\tvar height = contentOriginalHeight;\n\t\n\t//Resize image\n\tif(width > availableWidth || height > availableHeight){\n\t\tvar ratio = contentOriginalHeight / availableHeight;\n\t\t\n\t\twidth = contentOriginalWidth / ratio;\n\t\theight = contentOriginalHeight / ratio;\n\t\t\n\t\tif(width > availableWidth){\n\t\t\tratio = contentOriginalWidth / availableWidth;\n\t\t\t\n\t\t\twidth = contentOriginalWidth / ratio;\n\t\t\theight = contentOriginalHeight / ratio;\n\t\t}\n\t}\n\t\n\t//Update image size\n\tif(type == \"sound\" || type == \"soundcloud\"){\n\t\timg.css({\n\t\t\t\"width\": width+\"px\",\n\t\t\t\"height\": \"auto\"\n\t\t});\n\t\theight = img.height();\n\t}\n\telse\n\t\timg.css({\n\t\t\t\"width\": width+\"px\",\n\t\t\t\"height\": height+\"px\"\n\t\t});\n\t\n\t//Update content position\n\tvar fromTop = -height/2;\n\t$content.css({\n\t\t\"top\": fromTop + \"px\",\n\t\t\"left\": -width/2 + \"px\"\n\t});\n\n\t//description height\n\tif(description != false){\n\t\tvar descriptionHeight = description.height();\n\t\tdescription.css(\"margin-top\", (height/2-descriptionHeight/2)+\"px\");\n\t}\n}", "title": "" }, { "docid": "06e48d3f9f9a34c6a3630b486325a50b", "score": "0.68554044", "text": "function onResize(){\n\t//Get available space\n\tvar availableWidth = $(window).width() ;\n\tvar availableHeight = $(window).height() ;\n\t\n\tif(!(availableWidth <= 700 || availableHeight <= 500)){\n\t\tavailableWidth *= 0.8;\n\t\tavailableHeight *= 0.9;\n\t}\n\telse{\n\t\tavailableWidth -= 20;\n\t\tavailableHeight -= 20;\n\t}\n\n\t\n\t//Final sizes\n\tvar width = contentOriginalWidth;\n\tvar height = contentOriginalHeight;\n\t\n\t//Resize image\n\tif(width > availableWidth || height > availableHeight){\n\t\tvar ratio = contentOriginalHeight / availableHeight;\n\t\t\n\t\twidth = contentOriginalWidth / ratio;\n\t\theight = contentOriginalHeight / ratio;\n\t\t\n\t\tif(width > availableWidth){\n\t\t\tratio = contentOriginalWidth / availableWidth;\n\t\t\t\n\t\t\twidth = contentOriginalWidth / ratio;\n\t\t\theight = contentOriginalHeight / ratio;\n\t\t}\n\t}\n\t\n\t//Update image size\n\tif(type == \"sound\" || type == \"soundcloud\"){\n\t\timg.css({\n\t\t\t\"width\": width+\"px\",\n\t\t\t\"height\": \"auto\"\n\t\t});\n\t\theight = img.height();\n\t}\n\telse\n\t\timg.css({\n\t\t\t\"width\": width+\"px\",\n\t\t\t\"height\": height+\"px\"\n\t\t});\n\t\n\t//Update content position\n\tvar fromTop = -height/2;\n\t$content.css({\n\t\t\"top\": fromTop + \"px\",\n\t\t\"left\": -width/2 + \"px\"\n\t});\n\n\t//description height\n\tif(description != false){\n\t\tvar descriptionHeight = description.height();\n\t\tdescription.css(\"margin-top\", (height/2-descriptionHeight/2)+\"px\");\n\t}\n}", "title": "" }, { "docid": "cdec2d2c7721638e8a54b593eba79650", "score": "0.6855267", "text": "function doneResizing(){\n\t\t\tif($(window).width() < 768){\n\t\t\t\tif(firstInit){\n\t\t\t\t\tbodyTag.on(\"click\", '.dropdown__title', slideToggeDropdownDefinition);\n\t\t\t\t\tfirstInit = false;\n\t\t\t\t}\n\t\t\t\telse if(!destroyedDesktopFunctions) {\n\t\t\t\t\tdropdown.css('display','none');\n\t\t\t\t\tlinksRemoveClass();\n\t\t\t\t\tbodyTag.off(\"mouseover\", '.dropdown__definition-list', showDropdownDefinition);\n\t\t\t\t\tbodyTag.off(\"mouseover\", '.dropdown__title', makeHeightEqual);\n\t\t\t\t\tbodyTag.on(\"click\", '.dropdown__title', slideToggeDropdownDefinition);\n\t\t\t\t\tdestroyedDesktopFunctions = true;\n\t\t\t\t\tdestroyedMobileFunctions = false;\n\t\t\t\t};\n\t\t\t}\n\t\t\telse if($(window).width() >= 768){\n\t\t\t\tif(firstInit){\n\t\t\t\t\tbodyTag.on(\"mouseover\", '.dropdown__title', makeHeightEqual);\n\t\t\t\t\tbodyTag.on(\"mouseover\", '.dropdown__definition-list', showDropdownDefinition);\n\t\t\t\t\tfirstInit = false;\n\t\t\t\t}\n\t\t\t\telse if(!destroyedMobileFunctions) {\n\t\t\t\t\tnavClose();\n\t\t\t\t\tdropdown.css('display','none');\n\t\t\t\t\tlinksRemoveClass();\n\t\t\t\t\tbodyTag.off(\"click\", '.dropdown__title', slideToggeDropdownDefinition);\n\t\t\t\t\tbodyTag.on(\"mouseover\", '.dropdown__definition-list', showDropdownDefinition);\n\t\t\t\t\tbodyTag.on(\"mouseover\", '.dropdown__title', makeHeightEqual);\n\t\t\t\t\tdestroyedMobileFunctions = true;\n\t\t\t\t\tdestroyedDesktopFunctions = false;\n\t\t\t\t};\n\t\t\t}\n\t\t}", "title": "" }, { "docid": "62432016c5b6fdf7ab68f909d78bab12", "score": "0.6851413", "text": "function sizing() {\n\n\t\tif($(window).width()>766){\n\t\t\t$('.menu_column').removeClass('menu_hidden');\n\t\t\t$('.menu_column').removeClass('menu_active');\n\t\t\t$('.main_wrap .nav_bar .get_out_cont').css('display','block');\n\t\t}\n\t\telse{\n\t\t\t$('.main_wrap .nav_bar .get_out_cont').css('display','none');\n\t\t}\n\n\n\t\tif($(window).width()<991){\n\n\t\t}\n\n\t\telse{\n\t\t\t$(\".main_search\").css('display','block');\n\t\t}\n\n\t}", "title": "" }, { "docid": "2a6b98f89096661193ca7e4def7c0550", "score": "0.6850352", "text": "function handleResize() {\n\t\t$(window).resize(function() {\n\t\t\twindowHalfX = window.innerWidth / 2;\n\t\t\twindowHalfY = window.innerHeight / 2;\n\t\t\t// update camera\n\t\t\tcamera.aspect = window.innerWidth / window.innerHeight;\n\t\t\tcamera.updateProjectionMatrix();\n\t\t\t// adjust canvas size\n\t\t\trenderer.setSize(window.innerWidth, window.innerHeight);\n\t\t});\n\t}", "title": "" }, { "docid": "6dbde39b49757ed3b12218a805090ee9", "score": "0.6833682", "text": "function doneResizing(){\n responsiveNavigation();\n $(\".tse-scrollable\").TrackpadScrollEmulator(\"recalculate\");\n tseWrapperHeight();\n galleryCarouselWidth();\n}", "title": "" }, { "docid": "9c1684b69d0941f6dfe347fb1199d432", "score": "0.6831656", "text": "function resizeFix() {\n\t\t\t\tif($el.parent().length > 0)\n\t\t\t\t\treRender($el);\n\t\t\t\telse{\n\t\t\t\t\t$(window).off('resize', resizeFix);\n\t\t\t\t}\n\t\t\t}", "title": "" }, { "docid": "6e82f037464d3d4b5c7d4fafe09e3ae8", "score": "0.6825828", "text": "function mkdfOnWindowResize() {\n\n\t}", "title": "" }, { "docid": "799e802989ee2affe44000d746437980", "score": "0.68197703", "text": "resizeHandler(event) {\n this.scrollTop = this.getScrollTop();\n this.scrollHeight =\n document.documentElement.scrollHeight -\n document.documentElement.clientHeight;\n this.positionParllaxElements(this.parallaxElements, this.pRatio);\n this.responsive = window.innerWidth < this.breakpoint;\n }", "title": "" }, { "docid": "741724ac1aa0997e762c02abc44b77af", "score": "0.6818908", "text": "function resize() {\n init();\n animation();\n}", "title": "" }, { "docid": "4db68ee1ea1b1a9c471fee5f43bd2ab3", "score": "0.68178684", "text": "function initializeResize() {\n verticalPosition();\n slides();\n landingVideo();\n}", "title": "" }, { "docid": "8849a71aebf507cb968871ebce187e70", "score": "0.6808475", "text": "function mkdfOnWindowResize() {\n\n }", "title": "" }, { "docid": "c6a183900460b82de6530ccf0b8a2f4c", "score": "0.68004286", "text": "function resizeHandler() {\n if(resizeTimeout) clearTimeout(resizeTimeout);\n resizeTimeout = setTimeout(resizeAll, 200);\n }", "title": "" }, { "docid": "2cc70f0870f0e1b51e8d65db9ed020f3", "score": "0.6799854", "text": "function setWindowResizeEvent() {\r\n\t$(window).resize(function () {\r\n\t\tresizeFrames();\r\n\t});\r\n}", "title": "" }, { "docid": "66fe96868590fa4e246a2d6ea2948e4b", "score": "0.6791431", "text": "function winResize() {\r\n\t\t\t\twidth = $(window).width();\r\n\t\t\t\theight = $(window).height();\r\n\t\t\t}", "title": "" }, { "docid": "80067ac6190f3168c3a3020032ed7367", "score": "0.6783782", "text": "function onParentWindowResize (){ }", "title": "" }, { "docid": "5db3b891931cb4575f9d222c8ec7c780", "score": "0.6781221", "text": "function monthResizeListener() {\n var resizetimeout;\n window.onresize = function () {\n clearTimeout(resizetimeout);\n resizetimeout = setTimeout(function () {\n self.responsiveMonths();\n\n }, 250);\n\n }\n }", "title": "" }, { "docid": "1bf908e8595f3b0a2867123da6dc4a07", "score": "0.67805827", "text": "function edgtfOnWindowResize() {\n edgtfInitBlogMasonry();\n }", "title": "" }, { "docid": "040adba9eee31e9af856067a83cfaaeb", "score": "0.6777023", "text": "function onresize() {\n $element.css({ \"height\": \"initial\" });\n\n default_h =\n get_total_height($element.find(\"h1\")) +\n get_total_height($element.find(\".plr-sponsor\")) +\n parseFloat($element.find(\".topic\").css(\"height\"));\n initial_h = get_total_height($element);\n\n start_y = 2 * window.innerHeight / 4;\n }", "title": "" }, { "docid": "4898f674a9a3ffd1dccc1b2452439cad", "score": "0.67764056", "text": "function responsiveResizeEvents() {\n let resizeTimeout;\n function resizeThrottler() {\n if (!resizeTimeout) {\n resizeTimeout = setTimeout(() => {\n resizeTimeout = null;\n if ($(window).width() > 719) {\n closeEverything();\n }\n }, 66);\n }\n }\n window.addEventListener('resize', resizeThrottler, false);\n }", "title": "" }, { "docid": "fcfb21e6942b258b9d278e8f2884da6c", "score": "0.6773345", "text": "function setupResizing() {\n window.addEventListener('resize', function(e) { frameResized(false) });\n }", "title": "" }, { "docid": "064c05870c801efa6723bea0cd170bea", "score": "0.67708546", "text": "initWindowResizeEvent() {\r\n $(window).on('resize.scrollmap', () => {\r\n this.checkScreenSize();\r\n if (this.isToggled) {\r\n this.isToggled = this.ToggleMap.toggle(this.map);\r\n }\r\n });\r\n }", "title": "" }, { "docid": "fd9af3d3e40918d4c37d011241d82fe7", "score": "0.67699367", "text": "refresh() {\n this.__onResize();\n }", "title": "" }, { "docid": "16a2075767b670795e541d5621673061", "score": "0.67586297", "text": "function handleResize() { \n if (window.innerWidth <= 480) {\n setSize(25)\n } else {\n setSize(40)\n }\n }", "title": "" }, { "docid": "d327ed32e4723de6c622617f74d9d1ca", "score": "0.6758522", "text": "static setupResize() {\n if (tetresse == null) Tetresse.envSetup();\n if (tetresse.listeners.resize != null) return;\n tetresse.listeners.resize = {\n active: false, \n onResize: {}, // [label]: func, args\n // Pause drawing the screen\n pause() {\n if (tetresse.listeners.resize.active) {\n tetresse.listeners.resize.active = false;\n tetresse.utils.removeEvent(window, \"resize\", tetresse.listeners.resize.func);\n }\n },\n // Resume drawing the screen\n resume() {\n if (!tetresse.listeners.resize.active) {\n tetresse.listeners.resize.active = true;\n tetresse.utils.addEvent(window, \"resize\", tetresse.listeners.resize.func);\n }\n },\n add(label, func, args) {\n var onResize = tetresse.listeners.resize.onResize;\n if (onResize[label] != null) console.log(\"overwriting resize\"); // TODO reportError\n onResize[label] = {func: func, args: args};\n },\n remove(label) {\n var onResize = tetresse.listeners.resize.onResize;\n if (onResize[label] == null) return false;\n return delete onResize[label];\n },\n // Executes func function in every element with specified args\n func() {\n var r = tetresse.listeners.resize.onResize;\n for (var v in r)\n r[v].func(r[v].args);\n }\n };\n }", "title": "" }, { "docid": "34d3cbe8a6f3d4b04a90a698989cf6ac", "score": "0.67526287", "text": "function onWindowResize() {\n \t\tconsole.log(\"resizing\");\n\t\t\t$(\".background-2d\").css(\"height\", \"100%\");\n\t\t\t$(\"#wrapper\").css(\"height\", \"100%\");\n\t\t}", "title": "" }, { "docid": "ca39520e27699b2b13b44a31eb23f4f3", "score": "0.6743227", "text": "function handleWindowResize(baseObj) {\n\t\tvar $this = baseObj;\n\t\tvar $orig_width = $this.width(), \n\t\t\t$orig_height = $this.height();\n\n\t\t$(window).resize( function(){\n\t\t\t// Cache the widths of the original layout and the window\n\t\t\tvar $window = $( window );\n\t\t\tvar $window_width = $window.width(), \n\t\t\t\t$window_height = $window.height();\n\n\t\t\t// If the browser's width becomes less than the layout's width, alter the layout's width\n\t\t\tif ($window_width < $orig_width + 50) {\n\t\t\t\tconsole.log(\"Altering layout width.\");\n\t\t\t\t$this.css('width', \"95%\");\n\t\t\t} else if ($window_width >= $orig_width) {\n\t\t\t\t$this.css('width', $orig_width);\n\t\t\t}\n\t\t\tif ($window_height < $orig_height + 50) {\n\t\t\t\tconsole.log(\"Altering layout height.\");\n\t\t\t\t$this.css('height', $window_height - 20);\n\t\t\t\t$this.children().css('height', $this.height());\n\t\t\t} else if ($window_height >= $orig_height) {\n\t\t\t\t$this.css('height', $orig_height);\n\t\t\t\t$this.children().css('height', $this.height());\n\t\t\t}\n\t\t});\n\t}", "title": "" }, { "docid": "7b0542695dc1d5b820d1d9fc23714b4e", "score": "0.6742915", "text": "function resizeListener() {\n window.onresize = function(e) {\n toggleMenuOff();\n toggleTMenuOff();\n\n };\n}", "title": "" }, { "docid": "a1bcf6d18e0b89a7a64440deefb5b200", "score": "0.67399263", "text": "function resize() {\n\n if (!running) {\n running = true;\n\n if (window.requestAnimationFrame) {\n window.requestAnimationFrame(runCallbacks);\n } else {\n setTimeout(runCallbacks, 66);\n }\n }\n\n }", "title": "" }, { "docid": "48a76f2bcdc94d9cdc71da2a5e6c3de2", "score": "0.6734879", "text": "$_initResizeEvent () {\n window.addEventListener('resize', this.$_resizeHandler)\n }", "title": "" }, { "docid": "c1f3df28cd412a483aca527da210b6c0", "score": "0.6726406", "text": "function resize() {\n // update something\n}", "title": "" }, { "docid": "f85942885404f5dce21c8886e5f7bb7f", "score": "0.6719789", "text": "onResize(){\n }", "title": "" }, { "docid": "8932796e4bfaa1f81741cb152ec9ee97", "score": "0.67154986", "text": "function handleWindowResize () {\n ctrl.lastSelectedIndex = ctrl.selectedIndex;\n ctrl.offsetLeft = fixOffset(ctrl.offsetLeft);\n $mdUtil.nextTick(function () {\n ctrl.updateInkBarStyles();\n updatePagination();\n });\n }", "title": "" }, { "docid": "8932796e4bfaa1f81741cb152ec9ee97", "score": "0.67154986", "text": "function handleWindowResize () {\n ctrl.lastSelectedIndex = ctrl.selectedIndex;\n ctrl.offsetLeft = fixOffset(ctrl.offsetLeft);\n $mdUtil.nextTick(function () {\n ctrl.updateInkBarStyles();\n updatePagination();\n });\n }", "title": "" }, { "docid": "8932796e4bfaa1f81741cb152ec9ee97", "score": "0.67154986", "text": "function handleWindowResize () {\n ctrl.lastSelectedIndex = ctrl.selectedIndex;\n ctrl.offsetLeft = fixOffset(ctrl.offsetLeft);\n $mdUtil.nextTick(function () {\n ctrl.updateInkBarStyles();\n updatePagination();\n });\n }", "title": "" } ]
e4c3c6e6e0e70c9377da6eb52db73c21
Read the user settings for the `periodicnotes` plugin to keep behavior of creating a new note insync.
[ { "docid": "5b743f77a6833b662d0fd350f187c731", "score": "0.6192959", "text": "function getMonthlyNoteSettings() {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const pluginManager = window.app.plugins;\n try {\n const settings = (shouldUsePeriodicNotesSettings(\"monthly\") &&\n pluginManager.getPlugin(\"periodic-notes\")?.settings?.monthly) ||\n {};\n return {\n format: settings.format || DEFAULT_MONTHLY_NOTE_FORMAT,\n folder: settings.folder?.trim() || \"\",\n template: settings.template?.trim() || \"\",\n };\n }\n catch (err) {\n console.info(\"No custom monthly note settings found!\", err);\n }\n}", "title": "" } ]
[ { "docid": "c4556541e15434687a1164a6b4aab241", "score": "0.6739746", "text": "function getDailyNoteSettings() {\n try {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const { internalPlugins, plugins } = window.app;\n if (shouldUsePeriodicNotesSettings(\"daily\")) {\n const { format, folder, template } = plugins.getPlugin(\"periodic-notes\")?.settings?.daily || {};\n return {\n format: format || DEFAULT_DAILY_NOTE_FORMAT,\n folder: folder?.trim() || \"\",\n template: template?.trim() || \"\",\n };\n }\n const { folder, format, template } = internalPlugins.getPluginById(\"daily-notes\")?.instance?.options || {};\n return {\n format: format || DEFAULT_DAILY_NOTE_FORMAT,\n folder: folder?.trim() || \"\",\n template: template?.trim() || \"\",\n };\n }\n catch (err) {\n console.info(\"No custom daily note settings found!\", err);\n }\n}", "title": "" }, { "docid": "c4556541e15434687a1164a6b4aab241", "score": "0.6739746", "text": "function getDailyNoteSettings() {\n try {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const { internalPlugins, plugins } = window.app;\n if (shouldUsePeriodicNotesSettings(\"daily\")) {\n const { format, folder, template } = plugins.getPlugin(\"periodic-notes\")?.settings?.daily || {};\n return {\n format: format || DEFAULT_DAILY_NOTE_FORMAT,\n folder: folder?.trim() || \"\",\n template: template?.trim() || \"\",\n };\n }\n const { folder, format, template } = internalPlugins.getPluginById(\"daily-notes\")?.instance?.options || {};\n return {\n format: format || DEFAULT_DAILY_NOTE_FORMAT,\n folder: folder?.trim() || \"\",\n template: template?.trim() || \"\",\n };\n }\n catch (err) {\n console.info(\"No custom daily note settings found!\", err);\n }\n}", "title": "" }, { "docid": "340bb65157ca9abdb625b9e72df4af50", "score": "0.6394891", "text": "function getUserSettings() {\n\n var userSettings = App.currentUser.get('notificationsSettings');\n alert(\"userId=\" + App.currentUser.url() + \"; userSettings=\" + userSettings)\n if ( ! userSettings) {\n alert(\"create userSettings=\")\n userSettings = {\n comments : -1,\n favoriting : -1,\n reposting : -1,\n editing : -1,\n following : -1\n }\n App.currentUser.set('notificationsSettings',userSettings)\n //App.currentUser.save()\n // update session\n \n // update database\n \n }\n var u = App.currentUser.get('notificationsSettings');\n alert(\"UUUUUUUUUUUU \" + u.comments)\n return App.currentUser.get('notificationsSettings');\n }", "title": "" }, { "docid": "1621ea3be5207903b860b9f143e48ab3", "score": "0.6382518", "text": "function getSettings (){\n\t\tvar todays = document.querySelectorAll('input[name=\"today\"]');\n\t\tvar tracks = document.querySelectorAll('input[name=\"track\"]');\n\t\tvar refresh_times = document.querySelectorAll('#refresh-time option')\n\t\tvar trackIds = [];\n\n\t\tvar settings = JSON.parse(originalFs.readFileSync(__dirname + \"/../notebooks.json\"));\n\n\t\tfor(var i = 0; i < todays.length; i++){\n\t\t\tif(todays[i].checked){\n\t\t\t\tsettings.today_progress = todays[i].value;\n\t\t\t}\n\n\t\t\tif(tracks[i].checked){\n\t\t\t\ttrackIds.push(tracks[i].value);\n\t\t\t}\n\t\t}\n\n\t\tfor(var i = 0; i < refresh_times.length; i++){\n\t\t\tif(refresh_times[i].selected){\n\t\t\t\tsettings.refresh_time = refresh_times[i].value;\n\t\t\t}\n\t\t}\n\n\t\tsettings.misc_progress = trackIds;\n\n\t\toriginalFs.writeFileSync(__dirname + \"/../notebooks.json\", JSON.stringify(settings));\n\t}", "title": "" }, { "docid": "74b768b5f1560aade5685a1bd8afe027", "score": "0.62754333", "text": "function getWeeklyNoteSettings() {\n try {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const pluginManager = window.app.plugins;\n const calendarSettings = pluginManager.getPlugin(\"calendar\")?.options;\n const periodicNotesSettings = pluginManager.getPlugin(\"periodic-notes\")\n ?.settings?.weekly;\n if (shouldUsePeriodicNotesSettings(\"weekly\")) {\n return {\n format: periodicNotesSettings.format || DEFAULT_WEEKLY_NOTE_FORMAT,\n folder: periodicNotesSettings.folder?.trim() || \"\",\n template: periodicNotesSettings.template?.trim() || \"\",\n };\n }\n const settings = calendarSettings || {};\n return {\n format: settings.weeklyNoteFormat || DEFAULT_WEEKLY_NOTE_FORMAT,\n folder: settings.weeklyNoteFolder?.trim() || \"\",\n template: settings.weeklyNoteTemplate?.trim() || \"\",\n };\n }\n catch (err) {\n console.info(\"No custom weekly note settings found!\", err);\n }\n}", "title": "" }, { "docid": "74b768b5f1560aade5685a1bd8afe027", "score": "0.62754333", "text": "function getWeeklyNoteSettings() {\n try {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const pluginManager = window.app.plugins;\n const calendarSettings = pluginManager.getPlugin(\"calendar\")?.options;\n const periodicNotesSettings = pluginManager.getPlugin(\"periodic-notes\")\n ?.settings?.weekly;\n if (shouldUsePeriodicNotesSettings(\"weekly\")) {\n return {\n format: periodicNotesSettings.format || DEFAULT_WEEKLY_NOTE_FORMAT,\n folder: periodicNotesSettings.folder?.trim() || \"\",\n template: periodicNotesSettings.template?.trim() || \"\",\n };\n }\n const settings = calendarSettings || {};\n return {\n format: settings.weeklyNoteFormat || DEFAULT_WEEKLY_NOTE_FORMAT,\n folder: settings.weeklyNoteFolder?.trim() || \"\",\n template: settings.weeklyNoteTemplate?.trim() || \"\",\n };\n }\n catch (err) {\n console.info(\"No custom weekly note settings found!\", err);\n }\n}", "title": "" }, { "docid": "8e36f853d452a83fae2f591c52b64a89", "score": "0.6210252", "text": "function _get_user_settings() {\n return {\n export_all_fields: STORAGE_UTILS.config_get('export_all_fields'),\n export_hidden_fields: STORAGE_UTILS.config_get('export_hidden_fields'),\n language: STORAGE_UTILS.config_get('language')\n };\n}", "title": "" }, { "docid": "82238179d61f812143db333894ce7b87", "score": "0.61306137", "text": "function readSettings() {\n //read settings from somewhere\n return ;\n}", "title": "" }, { "docid": "36a1184f171f8ec10ec4907c39334d09", "score": "0.5930752", "text": "function loadSettings(){\n //If no settings, create\n checkSettingsExist();\n\n //Apply cookie settings to app\n settings = JSON.parse(document.cookie);\n\n //Italic\n //TODO: Update italics?\n if(settings.italic){\n document.getElementById('type_board').classList.toggle('italics');\n }\n\n //Font-Size\n updateSize(settings.fontSize);\n\n //Sample Text\n updateSample(settings.sampleText);\n\n //Theme\n updateTheme(settings.theme);\n\n console.log(settings);\n}", "title": "" }, { "docid": "00ae93aa6cc136de5574514d369374d8", "score": "0.59241396", "text": "function load_settings() {\n let defaults = { words: '' }\n return wkof.Settings.load(script_id, defaults)\n }", "title": "" }, { "docid": "799e9cb5bd62b2c65d9622211612cb85", "score": "0.5899285", "text": "function getConfig() {\n return JSON.parse(ScriptProperties.getProperty('config')) ||\n { numDays: 7, markUnread: false, addUnsnoozed: false };\n}", "title": "" }, { "docid": "9501218db02b71c98738febc51692ed4", "score": "0.589227", "text": "get settings() {}", "title": "" }, { "docid": "dd0b8a846625ee97f3ea66fc126d8f73", "score": "0.58624905", "text": "function load_settings() {\n //delete wkof.settings[script_id] // for testing purposes\n //wkof.Settings.save(script_id) // for testing purposes\n const defaults = {\n active_sequence: 0,\n prioritize: 'none',\n active_queue: 10,\n back2back: true,\n srs_breakdown: true,\n streak: true,\n }\n return wkof.Settings.load(script_id, defaults).then((settings) => {\n // Inject default sequences if user don't have any\n if (!settings.sequences) settings.sequences = default_sequences\n })\n }", "title": "" }, { "docid": "c53d1343923f71e7a5c5564fa73f09d4", "score": "0.5826635", "text": "function getSettings(){\n const settingsLS = JSON.parse(localStorage.getItem('settings'));\n\n // If the user has no settings \n if(settingsLS === null){\n // Create some default settings for the user\n const defaultSettings = {\n confirmDelete: true,\n completionSound: false,\n theme: 'Light Mode',\n hideCompleted: false,\n fontType: 'Roboto Condensed'\n }\n\n // Save those settings to local storage\n localStorage.setItem('settings', JSON.stringify(defaultSettings));\n\n return defaultSettings;\n }else{\n // If there are actual settings that the user has modified\n return settingsLS;\n }\n }", "title": "" }, { "docid": "2079a0487d78d25943abc253b9daba57", "score": "0.57077134", "text": "function load_settings() {\n\tvar home = process.env.HOME || process.env.USERPROFILE,\n\t\tconfig = path.join( home, '.derrick.d' );\n\n\t// Make sure the configuration file exists.\n\tverify_file( config );\n\n\t// Read the file\n\tvar data = fs.readFileSync( config );\n\n\t// Parse its contents and save them in our settings object.\n\tsettings = JSON.parse( data );\n\tloaded = true;\n}", "title": "" }, { "docid": "9a8e38ca6c77afedd31551ccf22e8cd6", "score": "0.5676279", "text": "function readUserSettings(applicationPath) {\n if (!applicationPath) {\n applicationPath = path.join(process.env.LOCALAPPDATA, 'Microsoft', 'PowerAppsCli');\n }\n const userSettingFilePath = path.join(applicationPath, userSettingsFileName);\n if (fs.existsSync(userSettingFilePath)) {\n const stream = fs.readFileSync(userSettingFilePath, 'utf8');\n try {\n settings = JSON.parse(stream);\n if (settings.uniqueId === '') {\n writeUserSettings(settings, applicationPath);\n }\n }\n catch (err) {\n fs.unlinkSync(userSettingFilePath);\n writeUserSettings(settings, applicationPath);\n }\n }\n else {\n writeUserSettings(settings, applicationPath);\n }\n return settings;\n}", "title": "" }, { "docid": "c49651c992b5f7c6a66a055b8868e7ea", "score": "0.56118846", "text": "function loadNotes() {\n if (localStorage.getItem('notes')) {\n savedNotes = JSON.parse(localStorage.getItem('notes'));\n }\n}", "title": "" }, { "docid": "e96ddce1ab9be7471a5795e96a6b8660", "score": "0.5597689", "text": "async function init() {\n\tusers = await work.getUserList();\n\n\t// Initialize user setting\n\tusers.forEach(user => {\n\t\tuserSetting[user.id] = {\n\t\t\tlocation: '09140550',\n\t\t\tday: 1\n\t\t};\n\t});\n\tconsole.log(`Total ${users.length} users detected`);\n\n\t// If user setting file already exists, override it.\n\ttry {\n\t\tconst settingJSONStr = await fs.readFile(SETTING_FILE_PATH);\n\t\tuserSetting = { ...userSetting, ...JSON.parse(settingJSONStr) };\n\t} catch (_) {\n\n\t}\n}", "title": "" }, { "docid": "b9ec1ede0eef0d8e87a9a9dc009d0676", "score": "0.55865335", "text": "function readPreferences() {\n // f.e isDemoMode\n var d = $.Deferred();\n var preferencesService = new PreferencesStore();\n preferencesService.read({success: function (p) {\n d.resolve(p);\n }\n });\n return d.promise();\n }", "title": "" }, { "docid": "31ddf90809ea4d0fb365018f3caf32a7", "score": "0.5546723", "text": "function getUserSetting(){\n var setting = {};\n if(typeof(scope.newsUrl)=='undefined') {\n if(typeof(attrs.url)=='undefined') {\n newsTitle.html(\"Error: No news link specifized.\");\n setting.url = '';\n }\n else {\n setting.url = attrs.url;\n }\n }\n else {\n setting.url = scope.newsUrl;\n }\n if(typeof(scope.showInterval)=='undefined') {\n if(typeof(attrs.showInterval)=='undefined') {\n //default showInterval 3000ms\n setting.showInterval = 3000;\n }\n else {\n setting.showInterval = attrs.showInterval;\n }\n }\n else {\n setting.showInterval = scope.showInterval;\n }\n\n return setting;\n }", "title": "" }, { "docid": "2ea2c1b2cb3711fac6fe61b7ab13a71b", "score": "0.55310506", "text": "function loadNotes() {\n var notes = JSON.parse( fs.readFileSync( './db/db.json', 'utf8' ) )\n return notes;\n}", "title": "" }, { "docid": "dadd58fe9f468e03ff52bb33d4868f9a", "score": "0.5526511", "text": "static getUserSettings() {\n return [\n SimulatorSettings.UAC_DOUBLE_TAP_SETTING,\n SimulatorSettings.UAC_JAM_SETTING\n ];\n }", "title": "" }, { "docid": "241095d842b520ba5af54504a3bbd082", "score": "0.5517167", "text": "function load_settings()\n{\n let file_data = fs.readFileSync('settings.json')\n let settings = JSON.parse(file_data)\n NwKey = settings['NwKey'].replace(/\\s/g, '')\n AppKey = settings['AppKey'].replace(/\\s/g, '')\n DevAdd = settings['DevAdd'].replace(/\\s/g, '')\n LFC = settings['FrameCounter']\n Server_IP = settings['Server_IP']\n Server_Port = settings['Server_Port']\n GW_MAC = settings['GW_MAC']\n console.log(\"Sending Lora pkts to:\\nNetwork Server: \" + Server_IP + \":\" + Server_Port)\n // console.log(NwKey, AppKey, DevAdd, LFC, Server_IP, Server_Port, GW_MAC)\n}", "title": "" }, { "docid": "74d0a7f17401cfc33dc98eea30a10b98", "score": "0.54939306", "text": "function readSystem() {\n if (hasReadSystem) {\n return;\n }\n\n imports.prefBranch.getChildList('').forEach(function(name) {\n var setting = new Setting(name);\n settingsAll.push(setting);\n settingsMap.set(name, setting);\n });\n\n settingsAll.sort(function(s1, s2) {\n return s1.name.localeCompare(s2.name);\n });\n\n hasReadSystem = true;\n}", "title": "" }, { "docid": "5aac418f4ba2e17f42a1b26c569141ca", "score": "0.5481088", "text": "_onSettingsChanged() {\n const settings = this._settings;\n const defaults = this._defaults;\n const user = this._user;\n defaults.editor.model.value.text = settings.annotatedDefaults();\n user.editor.model.value.text = settings.raw;\n }", "title": "" }, { "docid": "ae535fb7eae8ddc51235dba9ec87aa97", "score": "0.5470503", "text": "static async read() {\n // Settings\n let json = await IO.parseFileJSON(Platform.ROOT_DIRECTORY + Paths\n .FILE_SETTINGS);\n this.kb = {};\n let jsonObjs = json[Utils.numToString(TitleSettingKind.KeyboardAssigment)];\n for (let id in jsonObjs) {\n this.kb[id] = jsonObjs[id];\n }\n }", "title": "" }, { "docid": "03fb9060a0d0f22a14d78fe4d0b8c6a8", "score": "0.54684293", "text": "function loadSettings() {\n try {\n const data = fs.readFileSync(__dirname+'/settings.json', 'utf8')\n const settings = JSON.parse(data)\n return settings\n } catch (err) {\n console.error(err)\n }\n }", "title": "" }, { "docid": "059789b8c43f20171e4a6014d5727fe1", "score": "0.54624", "text": "static loadConfig() {\n for (const key of Config.SETTINGS._keys()) {\n const val = Config.getStorage(key);\n if (val === null)\n Config.setElement(key, Config.getDefault(key));\n else\n Config.setElement(key, val);\n\n Config.updateControl(document.getElementById(key));\n }\n }", "title": "" }, { "docid": "3bbe08fb4d426ffa42f8718b0bc8726f", "score": "0.54617727", "text": "function loadSettings() {\n var $file = File(SETTINGS_FILE.folder + SETTINGS_FILE.name);\n if ($file.exists) {\n try {\n $file.open('r');\n var data = $file.read().split('\\n'),\n $main = data[0].split(',');\n copiesVal.text = $main[0];\n spacingVal.text = $main[1];\n } catch (e) {}\n $file.close();\n }\n }", "title": "" }, { "docid": "cfe463b9f90f7655298743235d818b50", "score": "0.5449652", "text": "function fnLoadUserSettings() {\n\tif (uid == null) {return;}\n\tvar docRef = db.collection(\"users\").doc(uid);\n\tdocRef.get().then(function(doc) {\n\t\tif (doc.exists) {\n\t\t\t// Read data\n\t\t\tconsole.log(\"Document data:\", doc.data());\n\t\t\tvar backgroundColor = doc.data()[\"backgroundColor\"];\n\t\t\tvar textColor = doc.data()[\"textColor\"];\n\t\t\tvar bgN = doc.data()[\"backgroundImage\"];\n\t\t\t// Data processing\n\t\t\t//\n\t\t\t// Set data\n\t\t\t$(\"#color-backs\").spectrum(\"set\", backgroundColor);\n\t\t\t$(\"#color-texts\").spectrum(\"set\", textColor);\n\t\t\t// Data processing\n\t\t\tbackgroundColor = backgroundColor.replace(\"rgba\", \"rgb\");\n\t\t\ttextColor = textColor.replace(\"rgba\", \"rgb\");\n\t\t\t// Set data\n\t\t\tchangeBackgroundColors(backgroundColor);\n\t\t\tchangeTextColors(textColor);\n\t\t\tchangeBackgroundImage(bgN);\n\t\t} else {\n\t\t\t// doc.data() will be undefined in this case\n\t\t\tconsole.log(\"No document stored for current user! Creating default document!\");\n\t\t\tfnSaveUserSettings()\n\t\t}\n\t}).catch(function(error) {\n\t\tconsole.log(\"Error getting document:\", error);\n\t});\n}", "title": "" }, { "docid": "e9a7b45c455c0bc25b090576bd14880a", "score": "0.54447734", "text": "updatePersistentSettings() {\n let changed = false;\n if (!this.stats.hybridMods) {\n changed = true;\n this.stats.hybridMods = {};\n }\n if (typeof this.stats.userLimit === 'undefined') {\n changed = true;\n this.stats.userLimit = false;\n this.stats.userLimitNum = 10;\n }\n if (typeof this.stats.disallow === 'undefined') {\n changed = true;\n this.stats.disallow = {};\n }\n\n if (Object.prototype.toString.call(this.stats.disallow) === '[object Object]') {\n const tempDisallow = [];\n for (const key in this.stats.disallow) {\n if (this.stats.disallow.hasOwnProperty(key)) {\n tempDisallow.push(key);\n }\n }\n this.stats.disallow = tempDisallow;\n changed = true;\n }\n\n if (changed) {\n this.writePersistentSettings();\n }\n }", "title": "" }, { "docid": "cca5812e1ecd5f33e5078fda2abbda47", "score": "0.5411245", "text": "function getSettingsFromPageControls() {\r\n\r\n // \"isForeignFirst\":\r\n settings.isForeignFirst = Boolean(document.getElementById(\"radioForeignFirst\").checked);\r\n \r\n // \"isAutoNext\":\r\n settings.isAutoNext = Boolean(document.getElementById(\"checkboxAutoNext\").checked);\r\n \r\n // \"timeDelay\":\r\n settings.timeDelay = Number(document.getElementById(\"selectTimeDelay\").value);\r\n \r\n // \"isInteractive\":\r\n settings.isInteractive = Boolean(document.getElementById(\"checkboxInteractive\").checked);\r\n \r\n // \"isOriginalOrder\":\r\n settings.isOriginalOrder = Boolean(document.getElementById(\"radioOriginalOrder\").checked);\r\n\r\n}", "title": "" }, { "docid": "0136be3b89decb66b92239e60031db7a", "score": "0.5409028", "text": "function readJambiSettings() {\n // Call the jambi file system function to read in the json\n jambifs.readJSON('jambi.json', function(err, data) {\n // if there was an error reading the file, alert the user and set the default version to 1.0\n if(err) {\n alert(\"Failed to read Jambi settings\");\n version = \"1.0\";\n }\n else {\n // else set the version to the user settings file - this gets updated/ checked with Jambi Servers\n version = data.version;\n // Set the editor font size and update inline CSS to override all other CSS\n editorFontSize = data.editor_settings.fontsize;\n $('#instyled').append(\".CodeMirror { font-size:\" + editorFontSize + \"px; }\");\n }\n });\n }", "title": "" }, { "docid": "ce520a7fa3624bc128df82c9a6f6490a", "score": "0.54048556", "text": "function settingsInit() {\n var settingsFile = appPath + 'settings.json';\n app.settings = {\n v: {}, // Values are saved to/from here\n defaults: {\n window: {\n width: 980,\n height: 600,\n y: 'center',\n x: 'center'\n },\n lastFile: '',\n flatten: 15, // Flatten curve value (smaller value = more points)\n shutoff: 20, // Remaining line length threshold for pump shutoff\n startwait: 450, // Time to wait for batter flow begin\n endwait: 250, // Time to wait for batter flow at end of line\n changewait: 35, // Number of seconds to wait between shade changes.\n botspeed: 70, // Locked stepper speed percentage written to GCODE\n fillspacing: 15, // Space between each trace fill line\n fillangle: 23, // Angle of line for trace fill\n fillthresh: 27 // Threshold to group zig zags\n },\n clear: function() {\n fs.removeSync(settingsFile);\n },\n save: function() {\n fs.writeFileSync(settingsFile, JSON.stringify(this.v));\n },\n load: function() {\n this.v = {};\n try {\n if (fs.existsSync(settingsFile)) {\n this.v = JSON.parse(fs.readFileSync(settingsFile));\n }\n } catch(e) {}\n\n // Comb in defaults\n for(var i in this.defaults) {\n if (!_.has(this.v, i)) {\n this.v[i] = this.defaults[i];\n }\n }\n\n this.save(); // Resave when we're done loading.\n }\n };\n\n app.settings.load();\n}", "title": "" }, { "docid": "c02229e608b8ac8a96bf09847539086b", "score": "0.5393977", "text": "loadSettings() {\n this.settings.forEach(option => {\n if(option.password) {\n option.value = this.getPassword(option.key);\n } else {\n option.value = this.getSetting(option.key) || option.default;\n }\n });\n }", "title": "" }, { "docid": "f8e504a902b503f271caf86a30bc23ec", "score": "0.5389072", "text": "function getSettings(userID) {\n\n}", "title": "" }, { "docid": "bdebc9efc40dab4aa0c4a8f8bdc114e3", "score": "0.5386678", "text": "function getSettings() {\r\n\tDISTINCT_HEADERS = GM_getValue('DISTINCT_HEADERS',false);\t\t// Shows colored and highlighted headers; coded by Cromagnon\r\n\tAVATARS_IN_HEADERS = GM_getValue('AVATARS_IN_HEADERS',false);\t\t// Shows avatar only on the header; coded by Cromagnon\r\n\tCOMPACT_HEADERS = GM_getValue('COMPACT_HEADERS',false);\t\t\t// Show compact headers which save space; coded by Cromagnon\r\n\tISOLATE_STATUS_UPDATES = GM_getValue('ISOLATE_STATUS_UPDATES',false);\t// Shows status updates only on the status tab; created by Cromagnon\r\n\tMAX = GM_getValue('MAX',3);\t\t\t\t\t\t// Number of pages of updates to load by default\r\n\r\n\tORGANIZE_EVERYTHING = GM_getValue('ORGANIZE_EVERYTHING',true);\r\n\tORGANIZE_GROUP = GM_getValue('ORGANIZE_GROUP',true);\r\n\tORGANIZE_STATUSES = GM_getValue('ORGANIZE_STATUSES',true);\r\n\tORGANIZE_WRITING = GM_getValue('ORGANIZE_WRITING',true);\r\n\tORGANIZE_PICTURES = GM_getValue('ORGANIZE_PICTURES',true);\r\n\tORGANIZE_VIDEOS = GM_getValue('ORGANIZE_VIDEOS',true);\r\n\r\n\tHOTLIST = GM_getValue('HOTLIST','').split(\"\\n\");\t\t\t// List of users which appear at the top of the list; coded by Cromagnon\r\n\tCOLDLIST = GM_getValue('COLDLIST','').split(\"\\n\");\t\t\t// List of users which appear at the bottom of the list; coded by Cromagnon\t\t\t\r\n\tHIDDENLIST = GM_getValue('HIDDENLIST','').split(\"\\n\");\t\t\t// List of users which are hidden; inspired by Cromagnon\r\n\r\n\tUPDATE_ON = GM_getValue('update_on',true);\r\n\tUPDATE_DAYS = GM_getValue('update_days',1);\r\n}", "title": "" }, { "docid": "c3e210705fe744348d4a85c8b3cf93bb", "score": "0.5386556", "text": "function getSettings() {\n let settings = JSON.parse(localStorage.getItem(\"trivia-settings\"));\n return settings;\n }", "title": "" }, { "docid": "78513191474be8b06555030860265a04", "score": "0.53815573", "text": "function restoreUserPrefs() {\n // localStorage stores char-only values so need to translate Bool-as-char to true Boolean\n jsct.application.set(\"useDualPane\", (localStorage.getItem(\"jsctUseDualPane\") === \"false\") ? false : true);\n jsct.application.set(\"splitterLocation\", localStorage.getItem(\"jsctSplitterLocation\"));\n // Special handling for the developer option that writes diagnostic messages to console.\n // Save in the Application model but also store in an app-global var, allows enable/disable\n // through simple boolean assignment (doesn't require knowledge of Backbone model's setter).\n jsct.showDiags = localStorage.getItem(\"jsctShowDiagnostics\") === \"true\" ? true : false;\n jsct.application.set(\"showDiagnostics\", jsct.showDiags);\n if (jsct.showDiags) {\n console.log(\"\\n%cAPP CONTROLLER(PRE-INIT): ***** STARTING JSCT APPLICATION LOAD *****\", logCSS);\n console.log(\"%cAPP CONTROLLER(PRE-INIT): user preferences loaded from localStorage (if exist)\", logCSS);\n }\n }", "title": "" }, { "docid": "d24496900aaed3532795ca591ee8f434", "score": "0.5358779", "text": "loadSettings() {\n\t\t// skip if we cannot find a cookie\n\t\tif (!document.cookie) {\n\t\t\tthis.saveSettings();\n\t\t\treturn;\n\t\t}\n\t\tvar cookieRaw = document.cookie.split(';');\n\t\tvar cookie = {};\n\t\tfor (var k = 0; k < cookieRaw.length; k++) {\n\t\t\tcookieRaw[k] = cookieRaw[k].split('=');\n\t\t\tcookie[cookieRaw[k][0].trim()] = cookieRaw[k][1];\n\t\t}\n\t\t\n\t\tthis.settings.scrollDirection = cookie['scrollDirection'];\n\t\tthis.settings.scrollSpeed = +cookie['scrollSpeed'];\n\t\tthis.settings.scrollSpeedFactor = this.settings.scrollSpeed/1000;\n\t\tthis.settings.globalOffset = +cookie['globalOffset'];\n\t\tthis.settings.noteskin = cookie['noteskin'];\n\t\tthis.settings.volume = cookie['volume'] ?? 100;\n\n\t\tthis.settings.keyBind[0] = +cookie['keyBind0'];\n\t\tthis.settings.keyBind[1] = +cookie['keyBind1'];\n\t\tthis.settings.keyBind[2] = +cookie['keyBind2'];\n\t\tthis.settings.keyBind[3] = +cookie['keyBind3'];\n\t\tthis.settings.keyBind[4] = +cookie['keyBind4'];\n\t\tthis.settings.keyBind[5] = +cookie['keyBind5'];\n\t\tthis.settings.keyBind['pause'] = +cookie['keyBindPause'];\n\t\tthis.settings.keyBind['seekLeft'] = +cookie['keyBindSeekLeft'];\n\t\tthis.settings.keyBind['seekRight'] = +cookie['keyBindSeekRight'];\n\n\t}", "title": "" }, { "docid": "9eeb21ff18b041565a95e383f2543138", "score": "0.5350579", "text": "fetchUserSettings() {\n dbg('Fetching user settings');\n\n return new Bluebird((resolve, reject) => {\n this.api.account('settings', {user_id: this.user.user_id},\n this.tokens.accessToken,\n this.tokens.accessTokenSecret,\n (err, data) => {\n if (err) {\n dbg('error: ', err);\n reject(err);\n } else {\n this.data.pseudo = data.screen_name;\n dbg(`Pseudo ${this.data.pseudo}`);\n resolve(this.data);\n }\n }\n );\n });\n }", "title": "" }, { "docid": "24ffa50ba613468ec0e5a7c99cfe743a", "score": "0.5338861", "text": "function getSettings() {\n\tchrome.storage.sync.get('settings', function(response) {\n\t\tfor (var key in response.settings) {\n\t\t\tsettings[key] = response.settings[key];\n\t\t}\n\t\t// Create RegExps for the imperial units\n\t\tfor (var key in imperialUnits) {\n\t\t\tvar madeRegex = createRegex(imperialUnits[key]);\n\t\t\tvar currRegex = new RegExp(madeRegex, \"gi\");\n\t\t\tregexps[key] = currRegex;\n\t\t}\n\t\t// Create RegExps for the metric units\n\t\tfor (var key in metricUnits) {\n\t\t\tvar madeRegex = createRegex(metricUnits[key]);\n\t\t\tvar currRegex = new RegExp(madeRegex, \"gi\");\n\t\t\tregexps[key] = currRegex;\n\t\t}\n\t\tparse(document.body);\n\t});\n}", "title": "" }, { "docid": "e9d7042b68f76e28b43e253cdabf1d27", "score": "0.5331297", "text": "getConfig() {\n this.$snotify.setDefaults({\n global: {\n newOnTop: this.newTop,\n maxAtPosition: this.blockMax,\n maxOnScreen: this.dockMax,\n }\n })\n return {\n bodyMaxLength: this.bodyMaxLength,\n titleMaxLength: this.titleMaxLength,\n backdrop: this.backdrop,\n position: this.notificationPosition,\n timeout: this.timeout,\n showProgressBar: this.progressBar,\n closeOnClick: this.closeClick,\n pauseOnHover: this.pauseHover\n }\n }", "title": "" }, { "docid": "e06055ecf54bcbef15a7abd3dddaebd8", "score": "0.5324241", "text": "function getSettings() {\n var path = hexo.base_dir + '_admin-config.yml'\n if (!fs.existsSync(path)) {\n hexo.log.d('admin config not found, creating one')\n fs.writeFile(hexo.base_dir+'_admin-config.yml', '')\n return {}\n } else {\n var settings = yml.safeLoad(fs.readFileSync(path))\n\n if (!settings) return {}\n return settings\n }\n }", "title": "" }, { "docid": "513250ec6ca3d0506b4521585e77d4d5", "score": "0.5323774", "text": "getUserPreferences() {\r\n if (this._userPreferences == null) {\r\n this._userPreferences = {\r\n quotePreference: this.getQuoteKind() === compiler_1.QuoteKind.Double ? \"double\" : \"single\",\r\n providePrefixAndSuffixTextForRename: this.getUsePrefixAndSuffixTextForRename()\r\n };\r\n }\r\n return Object.assign({}, this._userPreferences);\r\n }", "title": "" }, { "docid": "36adf44c3b814d72c4657411570dd878", "score": "0.5315568", "text": "function getSettings() {\n\t\t\tif (isWindowOrDocument()) return $('body').data(getId() + '-notificationPipe-settings');\n\t\t\t\n\t\t\treturn target.data('notification-settings');\n\t\t}", "title": "" }, { "docid": "699f2ad99b55e23a6737fe7c40af79ad", "score": "0.5315013", "text": "function fetchSettings(){\n\tvar cfg= {}\n\tfor(var i in SETTINGS){\n\t\tvar setting= SETTINGS[i],\n\t\t val= localStorage.getItem(setting) // lords above & below, forgive me: this had been IndexedDB, but the M17 chrome in Spotify used the old setVersion stuff & \"this,\" loathsome this, was easier than rewriting that.\n\t\tif(val === undefined || val === null)\n\t\t\tcontinue\n\n\t\tval= JSON.parse(val)\n\t\tcfg[setting]= val\n\t}\n\treturn cfg\n}", "title": "" }, { "docid": "051dd6d9a7c6a625d1fa3d1f4d64e49f", "score": "0.53023386", "text": "loadSettings() {\n const name = config.clientName;\n const query = this.connection.storage.get(name, `${name}:settings`, config.xmpp.timeout);\n return query.then(stanza => {\n const data = stanza.querySelector(`query > ${name} > data`);\n return this.connection.storage.read(data);\n });\n }", "title": "" }, { "docid": "feaa78d7a2667c57757d9be49e34bbd1", "score": "0.5301363", "text": "async function updateUserSettings(){\n\tsettings = await getStorageItem('userSettings','sync');\n}", "title": "" }, { "docid": "9d5c9978f490be875dae1a0ed98aa00a", "score": "0.52966154", "text": "_readConfig() {\n const config_path = this.utils.getConfigPath();\n const config_content = this.fs_manager.readFile(config_path);\n if(config_content == \"\") {\n vscode.window.showWarningMessage(\"Please enter details in config file before starting to operate.\");\n return {\n \"url\" : \"https://<instance>.service-now.com/\",\n \"username\" : \"\",\n \"password\" : \"\",\n \"app_name\" : \"\"\n }\n }\n const config = JSON.parse(config_content);\n return config;\n }", "title": "" }, { "docid": "fda3688ca85a54bf79075c6d5cde1511", "score": "0.5290546", "text": "function loadSettings(){\n var set = JSON.parse(settings._55);\n\n if(set != null){ \n maxDet = set[\"settings\"].maxDet;\n maxElev = set[\"settings\"].maxElev;\n minElev = set[\"settings\"].minElev;\n maxFlow = set[\"settings\"].maxFlow;\n minFlow = set[\"settings\"].minFlow;\n\n // notification alarms\n alarmEMax = set[\"settings\"].alarmEMax;\n alarmEMin = set[\"settings\"].alarmEMin;\n alarmFMax = set[\"settings\"].alarmFMax;\n alarmFMin = set[\"settings\"].alarmFMin;\n\n console.log('Succesfully loaded settings')\n }\n else {\n console.log('Failed to load settings');\n }\n}", "title": "" }, { "docid": "31ebd9ce250a36eb143b02ad7e017b09", "score": "0.52901864", "text": "loadDefaults() {\n settings.get(settingKeys.ROW_START);\n settings.get(settingKeys.COLUMN_TRANSACTION_DATE);\n settings.get(settingKeys.COLUMN_DESCRIPTION);\n settings.get(settingKeys.COLUMN_AMOUNT);\n settings.get(settingKeys.COLUMN_BALANCE);\n }", "title": "" }, { "docid": "fb020e1fda3c774f75b7cbfc1464111e", "score": "0.52875596", "text": "function getSettings() {\n\tchrome.extension.sendRequest({action: \"getSettings\"}, function(res) {\n\t\tconsole.log('setting from background', res)\n\t\t$.extend(prefs, res);\n\t});\t\n}", "title": "" }, { "docid": "85a55a9c0063ba6f7a5370d7d5f996d5", "score": "0.52856946", "text": "function syncUserOptions() {\n chrome.storage.sync.get([\"plainTextFontSize\", \"plainTextColour\", \"defaultTextColour\", \"plainTextFont\"], function (result) {\n textFontSize = result.plainTextFontSize;\n textColor = result.plainTextColour;\n defaultTextColour = result.defaultTextColour;\n textFont = result.plainTextFont;\n });\n}", "title": "" }, { "docid": "ca89d22e2a58cad5e8f23b4355d89e4e", "score": "0.52854013", "text": "function loadSettings() {\n try {\n return fs.readFileSync(SETTINGS_FILE, SETTINGS_TYPE);\n } catch (ex) {\n return {};\n }\n}", "title": "" }, { "docid": "ca89d22e2a58cad5e8f23b4355d89e4e", "score": "0.52854013", "text": "function loadSettings() {\n try {\n return fs.readFileSync(SETTINGS_FILE, SETTINGS_TYPE);\n } catch (ex) {\n return {};\n }\n}", "title": "" }, { "docid": "2dfd90b8ee58523d3104b90f0ab88c2c", "score": "0.52806705", "text": "async readNotes() {\n const notes = await readFileAsync(\"db/db.json\")\n return JSON.parse(notes);\n }", "title": "" }, { "docid": "36de1bd44b212e83e3f34e2cf44fe3ba", "score": "0.52481586", "text": "function getNotes() {\n // If local storage is empty than load new notes with untitled - title and notes body with notes.\n var notes = [];\n var note = [];\n var mode;\n\n notes = JSON.parse(localStorage.getItem(\"notes\"));\n if (notes == null || notes.length == 0) {\n\n defaultNotes();\n } else {\n notes = JSON.parse(localStorage.getItem(\"notes\"));\n\n notes.forEach((note) => {\n createNote(note);\n });\n }\n\n mode = localStorage.getItem(\"mode\");\n if (mode === \"day\") {\n bodyColor.style.backgroundColor = \"#FFFFFF\";\n\n } else {\n bodyColor.style.backgroundColor = \"#181d22\";\n }\n\n}", "title": "" }, { "docid": "feb4b306d9232ebaf5dab5a41ad48570", "score": "0.5234493", "text": "function _settings(){\n //------------------------------UPDATE nate dont use ACTIVE in production-----------!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!\n var ss = SpreadsheetApp.getActive(), // Select the current Spreadsheet \n sheet = ss.getSheetByName('settings'),\n\n appURL = sheet.getRange(3,2).getValue(),\n ctAmChecks = sheet.getRange(5,2).getValue(),\n ctPmChecks = sheet.getRange(6,2).getValue(),\n staffAmChecks = sheet.getRange(7,2).getValue(),\n staffPmChecks = sheet.getRange(8,2).getValue()\n ;\n\n var settings = { 'appurl' : appURL, \n 'ctAmChecks' : ctAmChecks, \n 'ctPmChecks' : ctPmChecks, \n 'staffAmChecks' : staffAmChecks,\n 'staffPmChecks' : staffPmChecks \n };\n\n return settings;\n}", "title": "" }, { "docid": "1ded770305e029a76790a31aa0d15cc5", "score": "0.5228911", "text": "function importUserSettings(sessionId) {\n //call API\n var jsonString = readFromServer(sessionId); // jsonString is read in from the correct file in php/settings folder\n //Set value of userObj (global)\n userObj = JSON.parse(jsonString);\n userData = userObj['fileName'];\n init(); //refresh the view\n}", "title": "" }, { "docid": "1af51e9811e75488fdd602e9000a5aea", "score": "0.5217503", "text": "function saveSettings() {\n\tfs.writeFile(path.join(app.getPath(\"userData\"),\"config.json\"), JSON.stringify(settings), (err) => {\n\t\tif(err) \n\t\t\tconsole.log(err);\n\t});\n}", "title": "" }, { "docid": "94f4f6ed299b70ae5bb2c56cda5d742e", "score": "0.5212696", "text": "function saveSettings() {\n\t\t\tif (isWindowOrDocument()) $('body').data(getId() + '-notificationPipe-settings', settings);\n\t\t\telse target.data('notification-settings', settings);\n\t\t}", "title": "" }, { "docid": "be9143d164e26735f116ab1984d62ec8", "score": "0.51906115", "text": "function loadNotes() {\n return API.get(\"notes\", \"/notes\");\n }", "title": "" }, { "docid": "dea68f7a2ad563030c334f5ace04ff0e", "score": "0.51853096", "text": "function settings() {\n try {\n var file = fs.readFileSync(__dirname + '/../config/krin.json');\n this.raw = JSON.parse(file);\n } catch(err) {\n if(err.code == 'ENOENT')\n console.error('Unable to open \\'krin.json\\'. Check if the file exists or if Krin have the permission to read it.');\n else if(err.name == \"SyntaxError\")\n console.error('Unable to read \\'krin.json\\' because the file is not a valid JSON file.');\n\n process.exit(1);\n }\n}", "title": "" }, { "docid": "094efa952e4cc1db159e906b84278fad", "score": "0.51838773", "text": "function get_config_data() {\n\tvar options = {\n\t\t'buses-first': parseInt(buses_first_field.val()),\n\t\t'closest-things': parseInt(closest_things_field.val()),\n\t\t'safetrack-warning': safetrack_warning_field.val(),\n\t\t'selection-color': selection_color_field.val(),\n\t\t'saved-bus': JSON.stringify(saved_bus),\n\t\t'saved-rail': JSON.stringify(saved_rail),\n\t\t'date': new Date()\n\t};\n\treturn options;\n}", "title": "" }, { "docid": "7893adfc50085aa35dd3c55cf29878d5", "score": "0.518301", "text": "function prepare(access) {\n storage.sync.get('userSettings', function(value) {\n var defined = false;\n var userSettings = {};\n for (var prop in value) {\n if (value.hasOwnProperty(prop)) {\n defined = true;\n break;\n }\n }\n if (defined === true) {\n userSettings = value.userSettings;\n } else {\n var newUserSettings = {'unit': 150, 'dwellTime': 750};\n storage.sync.set({'userSettings': newUserSettings}, function() {console.log('USER SETTINGS CREATED')});\n userSettings = newUserSettings;\n }\n access.start = start;;\n access.userSettings = userSettings;\n console.log(access.userSettings);\n start(access);\n });\n }", "title": "" }, { "docid": "1080bc98ee61507d1d549b0c13c0441b", "score": "0.51795304", "text": "function loadPrefs() {\n for (var i = 0; i < fields.length; i++) {\n var field = fields[i];\n if (typeof widget.preferences[field.name] !== \"undefined\") {\n if (field.getAttribute('type') == 'radio') {\n if (widget.preferences.getItem(field.name) == field.value) field.checked = 'checked';\n } else field.value = widget.preferences.getItem(field.name)\n }\n\n field.addEventListener(\"change\", savePrefs, false);\n }\n\n updateIntervalValue();\n}", "title": "" }, { "docid": "401eab8abcf96ffc95f0c50f61cef1b4", "score": "0.51793146", "text": "function getSettings() {\n if ($scope.user.settings === null) {\n console.log('no settings found. ');\n } else {\n SettingsService.getSettingsUser($scope.user.settings)\n .then(function (response) {\n var settings = [];\n for (var property in response.data.settings) {\n if (response.data.settings.hasOwnProperty(property) && property !== \"_id\" && property !== \"__v\") {\n settings.push({option: property, state: response.data.settings[property]});\n }\n }\n modalSettingsOpen($scope.user, settings);\n })\n .catch(function (error) {\n addAlert('danger', 'Unable to get user settings.');\n console.log('error: ');\n console.log(error);\n });\n }\n }", "title": "" }, { "docid": "02972144ad0f4e5d614da966cdbff9e0", "score": "0.5176486", "text": "function getSavedSettings() {\n\t//if the user has set a speed before, reuse it\n\tif (localStorage.getItem(\"speed\") !== null) {\n\t\t//store the recovered speed\n\t\tplayback.speed = parseInt(localStorage.getItem(\"speed\"));\n\t}\n\n\t//if the user has set a font size before, reuse it\n\tif (localStorage.getItem(\"size\") !== null) {\n\t\tplayback.fontSize = parseInt(localStorage.getItem(\"size\"));\n\t}\n}", "title": "" }, { "docid": "f32bfc413164ff85a73e1be1d79af647", "score": "0.51663923", "text": "function get_setting() {\n\tconst get_simon_setting = localStorage.getItem(\"simon_setting\");\n\tconst simon_setting = JSON.parse(get_simon_setting);\n\treturn simon_setting;\n}", "title": "" }, { "docid": "1f356721ed783550cada411c1aa40efd", "score": "0.5154876", "text": "load() {\n SC_UserOpt = JSON.parse(localStorage.UserPreferences);\n }", "title": "" }, { "docid": "3689c6b5ccd026aed162fde477d816c5", "score": "0.5146897", "text": "function loadSettings() {\n var g = cncserver.conf.global;\n var b = cncserver.conf.bot;\n\n // Pull settings over from CNC server / RoboPaint defaults (defined here)\n robopaint.settings = {\n // CNC Server specific settings\n invertx: g.get('invertAxis:x'),\n inverty: g.get('invertAxis:y'),\n swapmotors: g.get('swapMotors'),\n serialpath: g.get('serialPath'),\n httpport: g.get('httpPort'),\n httplocalonly: g.get('httpLocalOnly'),\n latencyoffset: 20,\n servowash: parseFloat(b.get('servo:presets:wash'))*10,\n servopaint: parseFloat(b.get('servo:presets:draw'))*10,\n servoup: parseFloat(b.get('servo:presets:up'))*10,\n servotime: b.get('servo:duration'),\n movespeed: parseFloat(b.get('speed:moving')),\n paintspeed: parseFloat(b.get('speed:drawing')),\n\n // Robopaint specific defaults\n filltype: 'line-straight',\n fillangle: 0,\n penmode: 0,\n openlast: 0,\n showcolortext: 0,\n colorset: 'generic-standard',\n maxpaintdistance: 8040,\n fillspacing: 10,\n fillprecision: 14,\n strokeovershoot: 5,\n tsprunnertype: 'OPT',\n strokeprecision: 6,\n enabledmodes: {},\n remoteprint: 0,\n gapconnect: 1,\n refillmode: 0,\n refillaction: 0\n };\n\n // Allow machine specific overrides of initial default settings\n settingsDefaultAlter(robopaint.settings);\n\n // Set the visibility/enabled status of color/mediasets\n verifyColorsetAbilities();\n\n // Are there existing settings from a previous run? Mesh them into the defaults\n if (localStorage[settingsStorageKey()]) {\n var s = getSettings();\n for (var key in robopaint.settings) {\n if (typeof s[key] != 'undefined' && s[key] !== null) {\n robopaint.settings[key] = s[key];\n }\n }\n }\n\n // Actually match the form elements to the given settings\n for (var key in robopaint.settings) {\n var $input = $('#' + key);\n switch (key) {\n case 'enabledmodes':\n for (var i in robopaint.settings.enabledmodes) {\n $('#' + i + 'modeenable')\n .prop('checked', robopaint.settings.enabledmodes[i])\n .change();\n }\n break;\n default:\n if ($input.attr('type') == 'checkbox') {\n $input.prop('checked', robopaint.settings[key]);\n } else {\n $input.val(robopaint.settings[key]);\n }\n }\n $input.change();\n }\n\n afterSettings();\n}", "title": "" }, { "docid": "299b99dfd059e4d6c4638dae9fedba5f", "score": "0.513615", "text": "function exerciseSettingsHelper() {\n var node = getIncludedNode(exSettingsDialog.dialog(\"option\", \"nodeId\"));\n var settings = {\n points: Number.parseFloat($(\"#exercise-settings-points\").val())\n };\n if (node.type !== \"extr\") {\n settings.required = $(\"#exercise-settings-required\").is(\":checked\");\n if (node.type === \"ka\") {\n settings.threshold = Number.parseInt(\n $(\"#exercise-settings-threshold\").val()\n );\n }\n if (node.type === \"pe\") {\n settings.threshold = Number.parseFloat(\n $(\"#exercise-settings-threshold\").val()\n );\n var feedback = $(\"#exercise-settings-feedback\").val();\n if (feedback === \"continuous\") {\n settings[\"JXOP-feedback\"] = feedback;\n settings[\"JXOP-fix\"] = $(\"#exercise-settings-fix\").val();\n }\n if ($(\"#exercise-settings-code\").is(\":checked\")) {\n settings[\"JXOP-code\"] = \"none\";\n }\n }\n }\n setExerciseSettings(node, settings);\n exSettingsDialog.dialog(\"close\");\n }", "title": "" }, { "docid": "ca042ca20c420f4db7e93035711b1870", "score": "0.5132422", "text": "get settings() {\n return AppUIState.appSettings;\n }", "title": "" }, { "docid": "9d696397982d8676449fa22171fc2193", "score": "0.5128498", "text": "function loadSettings() {\n if (localStorage.email === \"yes\") {\n emailOn()\n } \n if (localStorage.email === \"no\") {\n emailOff()\n }\n if (localStorage.public === \"yes\") {\n publicOn()\n } \n if (localStorage.public === \"no\") {\n publicOff()\n }\n timeZoneSelection.selectedIndex = localStorage.timeZone;\n}", "title": "" }, { "docid": "ceb7da70ff43e800d81873767b483a9d", "score": "0.5121645", "text": "async function loadSettingsFromFile(strFileName) {\n try {\n let fmSettings;\n try {fmSettings = FileManager.iCloud()} catch (e) {fmSettings = FileManager.local()}\n try {fmSettings.documentsDirectory()} catch(e) {fmSettings = FileManager.local()}\n \n let filePath = fmSettings.documentsDirectory();\n filePath = fmSettings.joinPath(filePath, \"News-Widget-Settings\");\n filePath = fmSettings.joinPath(filePath, strFileName);\n \n if (fmSettings.fileExists(filePath) && fmSettings.isFileStoredIniCloud(filePath)) {\n await fmSettings.downloadFileFromiCloud(filePath);\n \n const jsonConfig = await JSON.parse(fmSettings.readString(filePath));\n\n if (jsonConfig.CHECK_FOR_SCRIPT_UPDATE !== undefined) {CHECK_FOR_SCRIPT_UPDATE = jsonConfig.CHECK_FOR_SCRIPT_UPDATE;}\n if (jsonConfig.PARAM_LINKS !== undefined) {PARAM_LINKS = jsonConfig.PARAM_LINKS;}\n if (jsonConfig.PARAM_WIDGET_TITLE !== undefined) {PARAM_WIDGET_TITLE = jsonConfig.PARAM_WIDGET_TITLE;}\n if (jsonConfig.PARAM_BG_IMAGE_NAME !== undefined) {PARAM_BG_IMAGE_NAME = jsonConfig.PARAM_BG_IMAGE_NAME;}\n if (jsonConfig.PARAM_BG_IMAGE_BLUR !== undefined) {PARAM_BG_IMAGE_BLUR = jsonConfig.PARAM_BG_IMAGE_BLUR;}\n if (jsonConfig.PARAM_BG_IMAGE_GRADIENT !== undefined) {PARAM_BG_IMAGE_GRADIENT = jsonConfig.PARAM_BG_IMAGE_GRADIENT;}\n if (jsonConfig.PARAM_SHOW_NEWS_IMAGES !== undefined) {PARAM_SHOW_NEWS_IMAGES = jsonConfig.PARAM_SHOW_NEWS_IMAGES;}\n if (jsonConfig.CONF_LARGE_WIDGET_MAX_NEWS !== undefined) {CONF_LARGE_WIDGET_MAX_NEWS = jsonConfig.CONF_LARGE_WIDGET_MAX_NEWS;}\n if (jsonConfig.CONF_POSTS_PER_LINK !== undefined) {CONF_POSTS_PER_LINK = jsonConfig.CONF_POSTS_PER_LINK;}\n if (jsonConfig.CONF_DATE_TIME_LOCALE !== undefined) {CONF_DATE_TIME_LOCALE = jsonConfig.CONF_DATE_TIME_LOCALE;}\n if (jsonConfig.CONF_12_HOUR !== undefined) {CONF_12_HOUR = jsonConfig.CONF_12_HOUR;}\n \n if (jsonConfig.CONF_BG_COLOR.lightMode !== undefined && jsonConfig.CONF_BG_COLOR.darkMode !== undefined) {\n CONF_BG_COLOR = Color.dynamic(new Color(jsonConfig.CONF_BG_COLOR.lightMode), new Color(jsonConfig.CONF_BG_COLOR.darkMode));\n }\n \n if (jsonConfig.CONF_BG_GRADIENT !== undefined) {CONF_BG_GRADIENT = jsonConfig.CONF_BG_GRADIENT;}\n if (jsonConfig.CONF_BG_GRADIENT_COLOR_TOP.lightMode !== undefined && jsonConfig.CONF_BG_GRADIENT_COLOR_TOP.darkMode !== undefined) {\n CONF_BG_GRADIENT_COLOR_TOP = Color.dynamic(new Color(jsonConfig.CONF_BG_GRADIENT_COLOR_TOP.lightMode), new Color(jsonConfig.CONF_BG_GRADIENT_COLOR_TOP.darkMode));\n }\n if (jsonConfig.CONF_BG_GRADIENT_COLOR_BTM.lightMode !== undefined && jsonConfig.CONF_BG_GRADIENT_COLOR_BTM.darkMode !== undefined) {\n CONF_BG_GRADIENT_COLOR_BTM = Color.dynamic(new Color(jsonConfig.CONF_BG_GRADIENT_COLOR_BTM.lightMode), new Color(jsonConfig.CONF_BG_GRADIENT_COLOR_BTM.darkMode));\n }\n \n if (jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.lightMode !== undefined && jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.darkMode !== undefined) {\n if (jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.lightModeAlpha !== undefined && jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.darkModeAlpha !== undefined) {\n CONF_BG_GRADIENT_OVERLAY_TOP = Color.dynamic(new Color(jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.lightMode, jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.lightModeAlpha),\n new Color(jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.darkMode, jsonConfig.CONF_BG_GRADIENT_OVERLAY_TOP.darkModeAlpha));}\n }\n if (jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.lightMode !== undefined && jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.darkMode !== undefined) {\n if (jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.lightModeAlpha !== undefined && jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.darkModeAlpha !== undefined) {\n CONF_BG_GRADIENT_OVERLAY_BTM = Color.dynamic(new Color(jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.lightMode, jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.lightModeAlpha),\n new Color(jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.darkMode, jsonConfig.CONF_BG_GRADIENT_OVERLAY_BTM.darkModeAlpha));}\n }\n \n if (jsonConfig.CONF_FONT_WIDGET_TITLE !== undefined) {CONF_FONT_WIDGET_TITLE = jsonConfig.CONF_FONT_WIDGET_TITLE;}\n if (jsonConfig.CONF_FONT_WEIGHT_WIDGET_TITLE !== undefined) {CONF_FONT_WEIGHT_WIDGET_TITLE = jsonConfig.CONF_FONT_WEIGHT_WIDGET_TITLE;}\n if (jsonConfig.CONF_FONT_SIZE_WIDGET_TITLE !== undefined) {CONF_FONT_SIZE_WIDGET_TITLE = jsonConfig.CONF_FONT_SIZE_WIDGET_TITLE;}\n if (jsonConfig.CONF_FONT_COLOR_WIDGET_TITLE.lightMode !== undefined && jsonConfig.CONF_FONT_COLOR_WIDGET_TITLE.darkMode !== undefined) {\n CONF_FONT_COLOR_WIDGET_TITLE = Color.dynamic(new Color(jsonConfig.CONF_FONT_COLOR_WIDGET_TITLE.lightMode), new Color(jsonConfig.CONF_FONT_COLOR_WIDGET_TITLE.darkMode));\n }\n \n if (jsonConfig.CONF_FONT_DATE !== undefined) {CONF_FONT_DATE = jsonConfig.CONF_FONT_DATE;}\n if (jsonConfig.CONF_FONT_WEIGHT_DATE !== undefined) {CONF_FONT_WEIGHT_DATE = jsonConfig.CONF_FONT_WEIGHT_DATE;}\n if (jsonConfig.CONF_FONT_SIZE_DATE !== undefined) {CONF_FONT_SIZE_DATE = jsonConfig.CONF_FONT_SIZE_DATE;}\n if (jsonConfig.CONF_FONT_COLOR_DATE.lightMode !== undefined && jsonConfig.CONF_FONT_COLOR_DATE.darkMode !== undefined) {\n CONF_FONT_COLOR_DATE = Color.dynamic(new Color(jsonConfig.CONF_FONT_COLOR_DATE.lightMode), new Color(jsonConfig.CONF_FONT_COLOR_DATE.darkMode));\n }\n \n if (jsonConfig.CONF_FONT_HEADLINE !== undefined) {CONF_FONT_HEADLINE = jsonConfig.CONF_FONT_HEADLINE;}\n if (jsonConfig.CONF_FONT_WEIGHT_HEADLINE !== undefined) {CONF_FONT_WEIGHT_HEADLINE = jsonConfig.CONF_FONT_WEIGHT_HEADLINE;}\n if (jsonConfig.CONF_FONT_SIZE_HEADLINE !== undefined) {CONF_FONT_SIZE_HEADLINE = jsonConfig.CONF_FONT_SIZE_HEADLINE;}\n if (jsonConfig.CONF_FONT_COLOR_HEADLINE.lightMode !== undefined && jsonConfig.CONF_FONT_COLOR_HEADLINE.darkMode !== undefined) {\n CONF_FONT_COLOR_HEADLINE = Color.dynamic(new Color(jsonConfig.CONF_FONT_COLOR_HEADLINE.lightMode), new Color(jsonConfig.CONF_FONT_COLOR_HEADLINE.darkMode));\n }\n } else {\n return null;\n }\n } catch(err) {\n log(\"try loadSettingsFromFile: \"+err);\n return null;\n }\n}", "title": "" }, { "docid": "dc325e70fceabb4dc7d402a0048c61ac", "score": "0.512025", "text": "constructor() {\n // internal settings object settings\n this._loaded = false; // ONLY persist if we have been loaded!\n this.events = new EventHandler();\n let thisObject = this;\n\n // Notification routines.\n \n let externalName = function(n) {\n // private function, hence, not assigned to \"this\"\n n += \"\";\n if (n.substr(0,1) !== \"_\") return n;\n return n.substr(1);\n }\n\n this.attachSettingChangeHandler = function(propertyName, eventHandler) {\n return thisObject.events.addEventHandler(\"onSettingChange\", propertyName, eventHandler);\n }\n\n this.removeSettingChangeHandler = function(propertyName, eventHandler) {\n thisObject.events.removeEventHandler(\"onSettingChange\", propertyName, eventHandler);\n }\n\n this.notify = function(propertyName) {\n thisObject.events.callHandlers(\"onSettingChange\", propertyName, null);\n thisObject.events.callHandlers(\"onSettingChange\", \"*\", null);\n }\n\n // Persistence routines.\n this.persist = function() {\n //-- Called internally by putSetting and putSettingArray to auto-save new settings.\n if (thisObject.hasOwnProperty(\"_noPersistence\") && thisObject._noPersistence) return; // allow non-global objects to set the noPersistence property to ensure that they don't get saved\n if (!thisObject._loaded) return; // we have to be loaded before we persist\n localStorage.setItem(\"appSettings\", JSON.stringify(thisObject));\n }\n\n this.load = function () {\n //-- Called publicly to load the settings on startup.\n // Does NOT send midi messages or set up instruments -- caller has to do that.\n if (thisObject.hasOwnProperty(\"_noPersistence\") && thisObject._noPersistence) return; // allow non-global objects to set the noPersistence property to ensure that they don't get saved\n if (!localStorage.getItem(\"appSettings\")) {\n thisObject._loaded = true; // if not saved yet, just set loaded flag and return\n return; \n }\n //-- we can't just assign the whole object since that will remove all the methods.\n // we put the settings in a separate method and copy over the properties.\n try {\n let p = JSON.parse(localStorage.getItem(\"appSettings\"));\n for (let thisItem in p) {\n if (thisItem === \"events\") continue;\n // ^ don't mess with event handlers, they are regenerated anew each time\n try {\n thisObject[thisItem] = p[thisItem];\n thisObject.notify(externalName(thisItem));\n } catch(e) { }\n }\n\n thisObject._loaded = true;\n } catch(e) { }\n }\n\n // Access routines.\n let internalName = function(n) {\n // private function, hence, not assigned to \"this\"\n return \"_\" + n;\n }\n\n this.putSetting = function(n, v) {\n // Puts a setting value for the given name.\n thisObject[internalName(n)] = v;\n thisObject.persist();\n thisObject.notify(n);\n return v;\n }\n\n this.getSetting = function(n) {\n // Gets a setting.\n return thisObject[internalName(n)];\n }\n\n this.putSettingArray = function(n, idx, v) {\n // Puts a setting value in an array for the given name.\n thisObject[internalName(n)][idx] = v;\n thisObject.persist();\n thisObject.notify(n);\n return v;\n }\n\n this.getSettingArray = function(n, idx) {\n // Gets a setting array element.\n return thisObject[internalName(n)][idx];\n }\n }", "title": "" }, { "docid": "eac25c53b009a433593c6b63309c2e77", "score": "0.5118319", "text": "function readConfig(){\n try {\n var configFile = os.homedir() + path.sep + \".config\" + path.sep + \"emmetp\"; // ex: \"~/.config/emmetp\"\n whitelist = JSON.parse(fs.readFileSync(configFile));\n } catch(e) { /* totally optional nothing to do here */ }\n}", "title": "" }, { "docid": "b97f1b87befaed86e4243f3842ccf9a6", "score": "0.51137435", "text": "_loadSettings() {\n // Read configuration file.\n this._readConfigFile();\n // Merge global and local settings in each tasks.\n for (const name of utils_1.modules) {\n const settings = this._settings[name];\n if (settings && !settings.tasks) {\n settings.cwd = this._options.cwd;\n }\n else if (settings && settings.tasks) {\n for (const taskName of Object.keys(settings.tasks)) {\n const task = settings.tasks[taskName];\n task.settings = merge_1.default(settings.settings || {}, task.settings || {});\n for (const option of [\"cwd\", \"revision\", \"sizes\", \"sourcemaps\", \"sourcemapFiles\"]) {\n /* eslint-disable @typescript-eslint/no-explicit-any */\n if (typeof task[option] === \"undefined\") {\n task[option] = this._options[option];\n }\n /* eslint-enable @typescript-eslint/no-explicit-any */\n }\n settings[taskName] = task;\n }\n delete settings.tasks;\n delete settings.settings;\n }\n }\n }", "title": "" }, { "docid": "d01418f81fa2e245b732a82e5ca6dcd0", "score": "0.51007015", "text": "function getSettings() {\r\n\tif(settings == null) {\r\n\t\tvar newSettings = createSettings();\r\n\t\tsetSettings(newSettings, true);\r\n\t}\r\n\treturn settings;\r\n}", "title": "" }, { "docid": "93551dd1317d39115056a816cce4baa8", "score": "0.50968987", "text": "getAllSettings() {\n return this.config.getUserSetting(this.configKey);\n }", "title": "" }, { "docid": "dd4843326f2708138de8daea62228bd3", "score": "0.5090193", "text": "function config() {\n // only run this if it's not running inside Now.sh\n if (Boolean(process.env.NOW)) return\n\n const secrets = loadSecrets()\n const required = loadRequired()\n\n // load environment variables from now.json\n const hasLoaded = loadNowJSON(secrets, required)\n\n // if now.json doesn't exists\n if (!hasLoaded) {\n // load from package.json\n loadPkgJSON(secrets, required)\n }\n}", "title": "" }, { "docid": "c4e0fd28b99e777268af78588185d3ec", "score": "0.50874287", "text": "get defaultUserSettingsInput() {\n return this._defaultUserSettings;\n }", "title": "" }, { "docid": "80059958c71ba0c5cc80e36d0c45ff89", "score": "0.50805205", "text": "function getUserProps() {\n var p = PropertiesService.getUserProperties();\n var allOK = true;\n \n var dftRangeLength = \"21\"; // 3 weeks by default\n var dftDateFormat = \"2\"; // US date format by default\n var dftLogLevel = \"02\"; // default log level to \"Warnings\"\n var dftWeekStart = \"S\"; // week starts on Sunday by default\n\n // read user specific properties and initialize them if needed\n var newp = {\n destTaskListId: p.getProperty(\"destTaskListId\") || (allOK = false) || Tasks.Tasklists.list().items[0].id,\n dateRangeLength: p.getProperty(\"dateRangeLength\") || (allOK = false) || dftRangeLength,\n dateFormat: p.getProperty(\"dateFormat\") || (allOK = false) || dftDateFormat, \n logVerboseLevel: p.getProperty(\"logVerboseLevel\") || (allOK = false) || dftLogLevel,\n weekStartsOn: p.getProperty(\"weekStartsOn\") || (allOK = false) || dftWeekStart,\n ignoreDeleted: p.getProperty(\"ignoreDeleted\") || (allOK = false) || \"Y\", \n slideOverdue: p.getProperty(\"slideOverdue\") || (allOK = false) || \"N\",\n userTMZ: p.getProperty(\"userTMZ\") || (allOK = false) || \"GMT\",\n appendRecPattern: p.getProperty(\"appendRecPattern\") || (allOK = false) || \"N\"\n };\n \n logIt(LOG_DEV, \"Props loaded %s\",JSON.stringify(newp));\n \n // check values\n if (newp.dateRangeLength.toString().search(/^(?:00|14|21|28|42|56)$/) == -1) { \n newp.dateRangeLength = dftRangeLength;\n logIt(LOG_DEV, \"Date range defaulted to %s\",newp.dateRangeLength);\n allOK = false;\n }\n \n // handling of property value saved in old format\n if (newp.dateFormat.toString().search(/^(?:1|2|3)$/) == -1 ) { \n newp.dateFormat = dftDateFormat;\n logIt(LOG_DEV, \"Date format defaulted to %s\",newp.dateFormat);\n allOK = false;\n }\n \n // handling of property values saved in old format\n if (newp.logVerboseLevel.toString().search(/^(?:01|02|03|04|10|20)$/) == -1) {\n newp.logVerboseLevel = dftLogLevel;\n logIt(LOG_DEV, \"Log verbose level defaulted to %s\",newp.logVerboseLevel);\n allOK = false;\n }\n\n //if not all properties were written in the property store\n if (!allOK) {\n p.setProperties(newp, true); //then write them and delete all other properties (if any)\n logIt(LOG_WARN,'User properties re-initialized. %s', JSON.stringify(newp));\n }\n \n return newp\n}", "title": "" }, { "docid": "4803016f8eb009d704041ee08276aea9", "score": "0.5067479", "text": "async getSetting(req = {}) { // TODO: DONE; UT;\n try {\n const authed = await this.getFreshAuthedUserDetails(req, c.LEAN);\n if (!authed.valid) return errorObject(authed.error);\n\n const setting = _.get(req, 'params.setting');\n if (!setting) return errorObject(sc.SPECIFY_ONE_SETTING);\n const validation = Validate.settingIsInStore(setting, 'user.settings');\n if (!validation) return errorObject(sc.INVALID_SETTINGS);\n\n const settings = authed.user.settings || {};\n return statusObject(sc.SUCCESS, settings[setting] || false);\n\n // const setting = this.getProperty('settings', authed.user, req.params.setting);\n // if (!setting.valid) return errorObject(setting.error);\n // return statusObject(sc.SUCCESSFUL_UPDATE, setting.data);\n } catch (e) {\n return h.unhandledErrorObject(e);\n }\n }", "title": "" }, { "docid": "a1f918b390ae0733e32872db6509d0d9", "score": "0.5062466", "text": "function initNotes(notes){\n loadSavedNotes(notes);\n }", "title": "" }, { "docid": "54fec5e7b0c52fa61b655406a9b0bb26", "score": "0.5061171", "text": "static storeConfig() {\n for (const key of Config.SETTINGS._keys()) {\n Config.setStorage(key, Config.getElement(key));\n }\n }", "title": "" }, { "docid": "0dce85012bd7312c0472e6a1335b581c", "score": "0.5053386", "text": "function loadSettings () {\n let checkEmail = localStorage.getItem(\"sendEmails\");\n if (checkEmail == \"true\") {\n sendEmailCheckbox.checked = true;\n } else {\n sendEmailCheckbox.checked = false;\n }\n \n let saveProfile = localStorage.getItem(\"saveProfile\");\n if(saveProfile == \"true\") {\n saveProfileCheckbox.checked = true;\n } else {\n saveProfileCheckbox.checked = false;\n }\n timezone.value = localStorage.getItem('savedTimezone');\n}", "title": "" }, { "docid": "5bc384e2dd9c2617002b8fcc89b8d0f8", "score": "0.505141", "text": "function readUser() {\r\n // TODO load user data from file\r\n fs.readFile('./resources/login.config', 'utf8', (err, data) => {\r\n user.username = data.split(\"\\r\\n\")[0].replace(\"username: \", \"\");\r\n user.password = data.split(\"\\r\\n\")[1].replace(\"password: \", \"\");\r\n });\r\n }", "title": "" }, { "docid": "97bcc4ff8d6484cb4a2ba60171c60c05", "score": "0.50437343", "text": "function restoreSettings() {\n // Use default values\n chrome.storage.sync.get({\n workTime: 60,\n workRepeats: 8,\n shortBreak: 5,\n longBreak: 15,\n longBreakAfter: 2,\n showNotifications: true,\n blockSites: false,\n blockListSites: ['facebook.com', 'reddit.com', 'twitter.com'],\n autoStartTime: '09:00',\n autoStartParam: false\n }, (items) => {\n $('#workTime').val(items.workTime);\n $('#workRepeats').val(items.workRepeats);\n $('#shortBreak').val(items.shortBreak);\n $('#longBreak').val(items.longBreak);\n $('#longBreakAfter').val(items.longBreakAfter);\n $('#showNotifications').prop('checked', items.showNotifications);\n $('#blockSites').prop('checked', items.blockSites);\n $('#autoStartParam').prop('checked', items.autoStartParam);\n $('#autoStartTime').val(items.autoStartTime);\n\n globalBlockList = items.blockListSites;\n updateBlockListView();\n\n $('#endAutoStartTime').text(calcAllTime(items));\n });\n}", "title": "" }, { "docid": "dd3d75d0a8fd195093fd735f25504967", "score": "0.5032561", "text": "function plugins_settings_read(name, type) {\n\t// take note that this setting was used by a plugin\n\tif(plugins_settings[type].indexOf(name) < 0)\n\t\tplugins_settings[type].push(name);\n\n\tswitch(type) {\n\t\tcase TYPE_IMAGES:\n\t\t\treturn settings.images[name];\n\t\tcase TYPE_MUSIC:\n\t\t\treturn settings.music[name];\n\t\tdefault:\n\t\t\treturn null;\n\t}\n}", "title": "" }, { "docid": "0c6be05c3bd730832cba5ea0704a430f", "score": "0.5014401", "text": "function loadSettings(callback){\n\tchrome.storage.sync.get(['domain',\n\t\t\t\t'domain_path',\n\t\t\t\t'protocol',\n\t\t\t\t'tt_rss_username',\n\t\t\t\t'port',\n\t\t\t\t'interval']\n\t\t\t\t,result => {\n\t\t\t\t\tdomain = result.domain;\n\t\t\t\t\tdomain_path = result.domain_path;\n\t\t\t\t\tprotocol = result.protocol;\n\t\t\t\t\ttt_rss_username = result.tt_rss_username;\n\t\t\t\t\tport = result.port;\n\t\t\t\t\tinterval = result.interval;\n\t\t\t\t\tconsole.log('Loaded settings from storage');\n\t\t\t\t\tcallback();\n\t\t\t\t})\n}", "title": "" }, { "docid": "42ca2682121d1ebdfe80ddbfe53644c6", "score": "0.5009783", "text": "function loadUserSettings(setting) {\n //if settings already exists, resolve instantly\n if(settings) \n if(typeof setting !== 'undefined')\n if(settings[setting])\n return Promise.resolve(settings[setting]); \n else {\n console.log(\"Requested setting does not exist.\");\n return Promise.reject(\"Requested setting does not exist.\");\n }\n else\n return Promise.resolve(settings);\n \n //else read settings from file\n return new Promise(function(resolve, reject) {\n readFile(settingsFilepath)\n .then(data => {\n //load file content into javascript object\n userSettings = JSON.parse(data);\n //if specific setting was asked for\n if(typeof setting !== 'undefined') {\n //return specific setting\n if(userSettings[setting])\n resolve(userSettings[setting]); \n else {\n console.log(\"Requested setting does not exist.\");\n reject(\"Requested setting does not exist.\");\n }\n } else {\n //else return all settings\n resolve(userSettings);\n }\n }).catch(err => {\n console.log(\"Failed to read file. Could not load settings.\");\n console.log(err);\n //inform caller\n reject(err);\n });\n });\n}", "title": "" }, { "docid": "8daf973844207e4ef1845b0b190d7107", "score": "0.4999501", "text": "function get() {\n return settings;\n }", "title": "" }, { "docid": "983fda6ea21f344bb4954be098bfaa34", "score": "0.49968863", "text": "function save_settings() {\n\t// Make sure our settings exist, first.\n\tloaded || load_settings();\n\n\tvar home = process.env.HOME || process.env.USERPROFILE,\n\t\tconfig = path.join( home, '.derrick.d' );\n\n\t// Make sure the configuration file exists.\n\tverify_file( config );\n\n\t// Save the settings out\n\tfs.writeFileSync( config, JSON.stringify( settings ), {flag: 'w' } );\n}", "title": "" }, { "docid": "948b332ef5aa1ef6069d588e475f2129", "score": "0.49944943", "text": "static getAllNotes() {\r\n const notes = JSON.parse(localStorage.getItem(\"notesapp-notes\") || \"[]\");\r\n \r\n //sorting notes newest to oldest\r\n return notes.sort((a, b) => {\r\n return new Date(a.updated) > new Date(b.updated) ? -1 : 1;\r\n });\r\n }", "title": "" }, { "docid": "c96a4b48e22499a461768564925d789d", "score": "0.49863696", "text": "function parsePrefs(prefs) {\n try {\n userData = JSON.parse(prefs || \"{}\");\n } catch (ex) {\n console.warn(\"CodeLoad: invalid user prefs:\", ex.message);\n }\n }", "title": "" }, { "docid": "237f715ddeebb1dabfc928eeb53f54f9", "score": "0.49824697", "text": "function update_settings()\r\n{\r\n script_config.rbot_active = UI.IsHotkeyActive(\"Rage\", \"General\", \"Enabled\");\r\n script_config.script_active = UI.GetValue(js_items, \"Enable semirage assist\");\r\n script_config.autowall_active = UI.IsHotkeyActive(js_items, \"Autowall\");\r\n script_config.autowall_mode = UI.GetValue(js_items, \"Default mode (no autowall key)\");\r\n script_config.legitaa_active = UI.GetValue(js_items, \"Enable legit AA\");\r\n script_config.legitaa_lby_mode = UI.GetValue(js_items, \"LBY Mode\");\r\n script_config.legitaa_juke_active = UI.IsHotkeyActive(js_items, \"Legit AA juke\");\r\n script_config.indicator_picks = UI.GetValue(js_items, \"Semirage assist indicators\");\r\n script_config.trashtalk = UI.GetValue(js_items, \"Trashtalk\");\r\n}", "title": "" }, { "docid": "367265892b9020be2c4aec9d79b200a7", "score": "0.49803558", "text": "function manageSettingsLoadSettings() {\n //Sets default checked values for the form that displays the app's current settings\n setupSettingsMenuFormDefaults(); //dispatches some asyncs\n //Sets up the submit button in the settings menu to update app settings\n setupSettingsMenuSubmitButton();\n}", "title": "" } ]
205eaab17b5e656cd2650cd37f336b1e
Sets the year/month/date/etc values of the moment from the given array. Inefficient because it calls each individual setter.
[ { "docid": "eff44e208f96b0086225ca1a1e7458dc", "score": "0.69316596", "text": "function setMomentValues(mom, a) {\n\tmom.year(a[0] || 0)\n\t\t.month(a[1] || 0)\n\t\t.date(a[2] || 0)\n\t\t.hours(a[3] || 0)\n\t\t.minutes(a[4] || 0)\n\t\t.seconds(a[5] || 0)\n\t\t.milliseconds(a[6] || 0);\n}", "title": "" } ]
[ { "docid": "f31ecc96bb2824dc89ebdd8701e124e3", "score": "0.69687814", "text": "function setMomentValues(mom, a) {\n\t\tmom.year(a[0] || 0)\n\t\t\t.month(a[1] || 0)\n\t\t\t.date(a[2] || 0)\n\t\t\t.hours(a[3] || 0)\n\t\t\t.minutes(a[4] || 0)\n\t\t\t.seconds(a[5] || 0)\n\t\t\t.milliseconds(a[6] || 0);\n\t}", "title": "" }, { "docid": "e69bfe3ea501fc952ec49d4a586f9b86", "score": "0.6880037", "text": "function setMomentValues(mom, a) {\n mom.year(a[0] || 0)\n .month(a[1] || 0)\n .date(a[2] || 0)\n .hours(a[3] || 0)\n .minutes(a[4] || 0)\n .seconds(a[5] || 0)\n .milliseconds(a[6] || 0);\n }", "title": "" }, { "docid": "ad58b6a3f556924922ed0494eb60d78b", "score": "0.5977894", "text": "_setupValue() {\n let val = get(this, 'value');\n let isRange = get(this, 'range');\n\n if (val) {\n if (getTypeOf(val) !== 'array') {\n val = array([val]);\n }\n } else {\n val = array();\n }\n\n set(this, '_dates', val);\n\n if (val.length > 0) {\n let month = val[0] ? val[0].clone().startOf('month') : moment().startOf('month');\n set(this, 'currentMonth', month);\n } else {\n let month = moment().startOf('month');\n set(this, 'currentMonth', month);\n }\n\n if (val.length === 1 && isRange) {\n set(this, 'isToStep', true);\n val.pushObject(null);\n } else if (val.length === 0 && isRange) {\n val.pushObjects([null, null]);\n }\n }", "title": "" }, { "docid": "35a8d8dd4abb29b93a0130907eb12a6e", "score": "0.5790201", "text": "[CALENDAR_MUTATIONS.SET_YEAR](state, year) {\n state.year = year\n }", "title": "" }, { "docid": "d57b4504f87ac00ed78d62df3fb82b0c", "score": "0.57232827", "text": "function setDate(day, month, year) {\n // TODO: write api for setting date externally \n }", "title": "" }, { "docid": "009e83dc437d2181368fae94aee36ac6", "score": "0.5714898", "text": "set_date(year, month) {\n if (year == null) {\n var d = new Date(),\n month = d.getMonth(),\n year = d.getFullYear();\n }\n\n var d1 = new Date(year, month + 1, 0);\n this.month = d1.getMonth();\n this.year = d1.getFullYear();\n this.num_days = d1.getDate();\n this.show_date(d1);\n }", "title": "" }, { "docid": "a4835de159945ac79b36ae4053d17df1", "score": "0.5702393", "text": "_updateValuesFromDate() {\n this.day = this.date.getDate();\n this.month = this.date.getMonth();\n this.year = this.date.getFullYear();\n this.hour = this.date.getHours();\n this.minute = this.date.getMinutes();\n this.seconds = this.date.getSeconds();\n }", "title": "" }, { "docid": "bf6c4630fe754fa7a65a8d36464c3d95", "score": "0.56721073", "text": "function setDate(data) {\n let d = new Date();\n for (let i = 0; i < data.length; i++) {\n let dayName = new Date(data[i].dt).getDay();\n let dayNumber = new Date(data[i].dt).getDate();\n let dayShort = new Date(data[i].dt).getDay();\n let month = new Date(data[i].dt).getMonth();\n let year = new Date(data[i].dt).getFullYear();\n\n data[i].dayName = changeDay(dayName);\n data[i].dayShort = shortDay(dayShort);\n data[i].dayNumber = dayNumber;\n data[i].month = changeMonth(month);\n data[i].year = year;\n }\n return data;\n }", "title": "" }, { "docid": "4aab84b118b8db16d7dcfc68aa81c389", "score": "0.56534654", "text": "function makeDates (array) {\n newArray = []\n newArray[0] = new Date()\n newArray[0].setFullYear(2017, 11, 31)\n for (var i = 1; i < array.length - 1; i++) {\n newArray[i] = new Date()\n newArray[i].setFullYear(2017+i, 05, 30)\n }\n var exitDate = new Date()\n exitDate.setFullYear(2017+(array.length-2), 11, 31)\n newArray.push(exitDate)\n return newArray\n}", "title": "" }, { "docid": "3be275f7354b45e22f5981bee232cb1b", "score": "0.56113774", "text": "set Date(value) {}", "title": "" }, { "docid": "7445827706ee904ae933db476f06f31b", "score": "0.5580606", "text": "static setMonth(value) {\r\n this.month = value;\r\n }", "title": "" }, { "docid": "ddc90ff70b5bde5e95d75398063de157", "score": "0.5533162", "text": "setMonths(state) {\n let months = [\"01\",\"02\",\"03\",\"04\",\"05\",\"06\",\"07\",\"08\",\"09\",\"10\",\"11\",\"12\"]\n this.commit(\"setMonths\", months)\n }", "title": "" }, { "docid": "ec7d2848ebbdd4e6563aefa279321a72", "score": "0.5510017", "text": "_setToDate(date) {\n let dates = get(this, '_dates');\n let [dateFrom] = dates;\n let vals;\n\n if (date) {\n date = date.endOf('day');\n }\n\n if (date && (dateFrom && date.valueOf() < dateFrom.valueOf())) {\n vals = array([date, dateFrom]);\n } else {\n vals = array([dateFrom, date]);\n }\n\n set(this, '_dates', vals);\n }", "title": "" }, { "docid": "d356a0a4d56f311994f331d2195b7e89", "score": "0.54693377", "text": "[CALENDAR_MUTATIONS.SET_MONTH](state, month) {\n state.month = month\n }", "title": "" }, { "docid": "53c43167cec6f967edc6a1dcbe0f1c1f", "score": "0.5423868", "text": "setYears(state) {\n let currentYear = new Date().getFullYear();\n let years = [];\n for(let year = currentYear; year <= currentYear + 19 ; year++){\n years.push(year)\n }\n this.commit('setYears', [...years]);\n }", "title": "" }, { "docid": "d8ab198c5843a6c79b1fc3b4d88b0424", "score": "0.54222035", "text": "function setterDate(){\n console.log(\"----- EJEMPLO DATE -----\");\n alert(\"----- EJEMPLO DATE -----\");\n var fechaAyer=new Date(2017,10,17); //nueva fecha\n alert(\"El año fue antes de cambiarlo: \"+fechaAyer.getFullYear());\n fechaAyer.setFullYear(2016);\n alert(\"El año fue después de cambiarlo: \"+fechaAyer.getFullYear());\n }", "title": "" }, { "docid": "0dd633b34d83b84c11596fae2f786e7e", "score": "0.53944254", "text": "function resetValues () {\r\n startMonth = undefined;\r\n endMonth = undefined;\r\n year = options.val(\"0\");\r\n }", "title": "" }, { "docid": "5e2d0b6a8537c2af575e6ddbb251bfc2", "score": "0.53871995", "text": "static setYear(value) {\r\n this.year = value;\r\n }", "title": "" }, { "docid": "1b0be96eb0e586aecfaa0c27ee78db59", "score": "0.5385686", "text": "setFromArray(array) {\n for(let i = 0; i < this.elements.length; i++) {\n this.elements[i] = array[i];\n }\n\n return this;\n }", "title": "" }, { "docid": "9a5dc75c5bd0ce153896cf09c435990d", "score": "0.5361278", "text": "updateSelection() {\n const {dates, rangepicker} = this.picker.datepicker;\n this.selected = dates.reduce((selected, timeValue) => {\n const date = new Date(timeValue);\n const year = date.getFullYear();\n const month = date.getMonth();\n if (selected[year] === undefined) {\n selected[year] = [month];\n } else {\n pushUnique(selected[year], month);\n }\n return selected;\n }, {});\n if (rangepicker && rangepicker.dates) {\n this.range = rangepicker.dates.map(timeValue => {\n const date = new Date(timeValue);\n return isNaN(date) ? undefined : [date.getFullYear(), date.getMonth()];\n });\n }\n }", "title": "" }, { "docid": "b2947555b2b73fb7c5924bcc241edd83", "score": "0.5348298", "text": "[CALENDAR_MUTATIONS.SET_DATE](state, date) {\n state.date = date\n }", "title": "" }, { "docid": "109f47b1cce66466c357ac33ffe71a6f", "score": "0.53204304", "text": "function DateTimeArray() {\n\tvar dateTime = [1,2,3];\n\tthis.setDateTime = function(init) {\n\t\tdateTime = [];\n\t\tif(!init.length) return false;\n\t\tdateTime[0] = init[0]; //year\n\t\tdateTime[1] = (init.length>1)?init[1]:1; //month\n\t\tdateTime[2] = (init.length>2)?init[2]:1; //day\n\t\tdateTime[3] = (init.length>3)?init[3]:0; //hour\n\t\tdateTime[4] = (init.length>4)?init[4]:0; //minute\n\t\tdateTime[5] = (init.length>5)?init[5]:0; //second\n\t\tvalidate();\n\t}\n\t\n\t//adds an array date to the current date. so if the array date added is [0,0,1] it would add one day.\n\t//if it was [1,0,0] it would add one year. \n\tthis.addDateTime = function (arr) {\n\t\tfor(var i = arr.length-1; i>=0; i--) {\n\t\t\tdateTime[i]+=arr[i];\n\t\t}\n\t\tvalidate();\n\t}\n\n\t//accessor for the array at its core\n\tthis.getDateTime = function () {\n\t\treturn dateTime;\n\t}\n\t\n\t//validates a date -- e.g. shifts it around until it is valid\n\t//currently only counts UP\n\tfunction validate() {\n\t\tif(typeof dateTime == \"undefined\") return false;\n\t\tif(!dateTime.length) return false;\n\t\t//check if too big\n\t\tif(dateTime[5]>59) adjustUp(5,59); //second\n\t\tif(dateTime[4]>59) adjustUp(4,59); //minute\n\t\tif(dateTime[3]>23) adjustUp(3,23); //hour\n\t\tif(dateTime[2]>monthMax(dateTime[1],dateTime[0])) adjustUp(2,monthMax(dateTime[1],dateTime[0])-1); //day\n\t\tif(dateTime[1]>12) adjustUp(1,11); //month\n\t\t//check if too small\n\t\tif(dateTime[5]<0) adjustDown(5,0,59); //second\n\t\tif(dateTime[4]<0) adjustDown(4,0,59); //minute\n\t\tif(dateTime[3]<0) adjustDown(3,0,23); //hour\n\t\tif(dateTime[2]<1) adjustDown(2,1,monthMax(dateTime[1]-1,dateTime[0])); //day\n\t\tif(dateTime[1]<1) adjustDown(1,1,12); //month\n\t}\n\t\n\t//gets the max days of a month, accounts for leap years\n\tfunction monthMax(month,year) {\n\t\twhile (month<1) month = 12+month;\n\t\tswitch(month) {\n\t\t\tcase 1: case 3: case 5: case 7: case 8: case 10: case 12:\n\t\t\t\treturn 31; break;\n\t\t\tcase 4: case 6: case 9: case 11:\n\t\t\t\treturn 30; break;\n\t\t\tcase 2: //february, always being a pill\n\t\t\t\tif(year % 4 !== 0) {\n\t\t\t\t\treturn 28;\n\t\t\t\t} else if( year % 100!== 0) {\n\t\t\t\t\treturn 29;\n\t\t\t\t} else if( year % 400!== 0) {\n\t\t\t\t\treturn 28;\n\t\t\t\t} else {\n\t\t\t\t\treturn 29;\n\t\t\t\t}\n\t\t\tbreak;\n\t\t}\n\t}\n\t\n\t//internal adjusters\n\tfunction adjustUp(index,max) {\n\t\twhile(dateTime[index]>max) {\n\t\t\tdateTime[index]-=max+1;\n\t\t\tdateTime[index-1]++;\n\t\t}\n\t}\n\tfunction adjustDown(index,min,max) {\n\t\twhile(dateTime[index]<min) {\n\t\t\tdateTime[index-1]-=1;\n\t\t\tdateTime[index]+=max;\n\t\t}\n\t}\n\t\n\t//returns a big number that corresponds with the date info — allows comparisons\n\tthis.compareDate = function() {\n\t\tvar cd = dateTime[0];\n\t\tfor(var i = 1; i<dateTime.length;i++) {\n\t\t\tcd+=String(\"00\"+dateTime[i]).slice(-2);\n\t\t}\n\t\treturn +cd;\n\t}\n\t\n\t//outputs an iso8601 formatted date (which can be read by Javascript's Date() object)\n\tthis.formatDate = function() {\n\t\tif(typeof dateTime == \"undefined\") return false;\n\t\tif(!dateTime.length) return false;\n\t\tvar dl = dateTime.length;\n\t\tvar iso8601 = \"\";\n\t\tiso8601+=dateTime[0]; //year\n\t\tif(dl>1) iso8601+=\"-\"+String(\"00\"+Math.max(1,dateTime[1])).slice(-2); //month\n\t\tif(dl>2) iso8601+=\"-\"+String(\"00\"+Math.max(1,dateTime[2])).slice(-2); //day\n\t\tif(dl>3) iso8601+=\"T\"+String(\"00\"+dateTime[3]).slice(-2); //hour\n\t\tif(dl>4) iso8601+=\":\"+String(\"00\"+dateTime[4]).slice(-2); //min\n\t\treturn iso8601;\n\t}\n}", "title": "" }, { "docid": "109f47b1cce66466c357ac33ffe71a6f", "score": "0.53204304", "text": "function DateTimeArray() {\n\tvar dateTime = [1,2,3];\n\tthis.setDateTime = function(init) {\n\t\tdateTime = [];\n\t\tif(!init.length) return false;\n\t\tdateTime[0] = init[0]; //year\n\t\tdateTime[1] = (init.length>1)?init[1]:1; //month\n\t\tdateTime[2] = (init.length>2)?init[2]:1; //day\n\t\tdateTime[3] = (init.length>3)?init[3]:0; //hour\n\t\tdateTime[4] = (init.length>4)?init[4]:0; //minute\n\t\tdateTime[5] = (init.length>5)?init[5]:0; //second\n\t\tvalidate();\n\t}\n\t\n\t//adds an array date to the current date. so if the array date added is [0,0,1] it would add one day.\n\t//if it was [1,0,0] it would add one year. \n\tthis.addDateTime = function (arr) {\n\t\tfor(var i = arr.length-1; i>=0; i--) {\n\t\t\tdateTime[i]+=arr[i];\n\t\t}\n\t\tvalidate();\n\t}\n\n\t//accessor for the array at its core\n\tthis.getDateTime = function () {\n\t\treturn dateTime;\n\t}\n\t\n\t//validates a date -- e.g. shifts it around until it is valid\n\t//currently only counts UP\n\tfunction validate() {\n\t\tif(typeof dateTime == \"undefined\") return false;\n\t\tif(!dateTime.length) return false;\n\t\t//check if too big\n\t\tif(dateTime[5]>59) adjustUp(5,59); //second\n\t\tif(dateTime[4]>59) adjustUp(4,59); //minute\n\t\tif(dateTime[3]>23) adjustUp(3,23); //hour\n\t\tif(dateTime[2]>monthMax(dateTime[1],dateTime[0])) adjustUp(2,monthMax(dateTime[1],dateTime[0])-1); //day\n\t\tif(dateTime[1]>12) adjustUp(1,11); //month\n\t\t//check if too small\n\t\tif(dateTime[5]<0) adjustDown(5,0,59); //second\n\t\tif(dateTime[4]<0) adjustDown(4,0,59); //minute\n\t\tif(dateTime[3]<0) adjustDown(3,0,23); //hour\n\t\tif(dateTime[2]<1) adjustDown(2,1,monthMax(dateTime[1]-1,dateTime[0])); //day\n\t\tif(dateTime[1]<1) adjustDown(1,1,12); //month\n\t}\n\t\n\t//gets the max days of a month, accounts for leap years\n\tfunction monthMax(month,year) {\n\t\twhile (month<1) month = 12+month;\n\t\tswitch(month) {\n\t\t\tcase 1: case 3: case 5: case 7: case 8: case 10: case 12:\n\t\t\t\treturn 31; break;\n\t\t\tcase 4: case 6: case 9: case 11:\n\t\t\t\treturn 30; break;\n\t\t\tcase 2: //february, always being a pill\n\t\t\t\tif(year % 4 !== 0) {\n\t\t\t\t\treturn 28;\n\t\t\t\t} else if( year % 100!== 0) {\n\t\t\t\t\treturn 29;\n\t\t\t\t} else if( year % 400!== 0) {\n\t\t\t\t\treturn 28;\n\t\t\t\t} else {\n\t\t\t\t\treturn 29;\n\t\t\t\t}\n\t\t\tbreak;\n\t\t}\n\t}\n\t\n\t//internal adjusters\n\tfunction adjustUp(index,max) {\n\t\twhile(dateTime[index]>max) {\n\t\t\tdateTime[index]-=max+1;\n\t\t\tdateTime[index-1]++;\n\t\t}\n\t}\n\tfunction adjustDown(index,min,max) {\n\t\twhile(dateTime[index]<min) {\n\t\t\tdateTime[index-1]-=1;\n\t\t\tdateTime[index]+=max;\n\t\t}\n\t}\n\t\n\t//returns a big number that corresponds with the date info — allows comparisons\n\tthis.compareDate = function() {\n\t\tvar cd = dateTime[0];\n\t\tfor(var i = 1; i<dateTime.length;i++) {\n\t\t\tcd+=String(\"00\"+dateTime[i]).slice(-2);\n\t\t}\n\t\treturn +cd;\n\t}\n\t\n\t//outputs an iso8601 formatted date (which can be read by Javascript's Date() object)\n\tthis.formatDate = function() {\n\t\tif(typeof dateTime == \"undefined\") return false;\n\t\tif(!dateTime.length) return false;\n\t\tvar dl = dateTime.length;\n\t\tvar iso8601 = \"\";\n\t\tiso8601+=dateTime[0]; //year\n\t\tif(dl>1) iso8601+=\"-\"+String(\"00\"+Math.max(1,dateTime[1])).slice(-2); //month\n\t\tif(dl>2) iso8601+=\"-\"+String(\"00\"+Math.max(1,dateTime[2])).slice(-2); //day\n\t\tif(dl>3) iso8601+=\"T\"+String(\"00\"+dateTime[3]).slice(-2); //hour\n\t\tif(dl>4) iso8601+=\":\"+String(\"00\"+dateTime[4]).slice(-2); //min\n\t\treturn iso8601;\n\t}\n}", "title": "" }, { "docid": "7608227bc16de3b9c5691ea67ea2f3e4", "score": "0.52993107", "text": "function setValues( values ) {\n }", "title": "" }, { "docid": "b373730f15f46a7fac8c14d55529704f", "score": "0.5269138", "text": "function formatData(array, index) {\n\tfor (var i in array) {\n var temp = array[i][0];\n array[i][0] = new Date(array[i][1]);\n array[i][1] = temp;\n }\n return array;\n}", "title": "" }, { "docid": "4a4f73da7c76235cd17175150aa2b55c", "score": "0.5238287", "text": "function setMonthYear(date) {\n var month = date.getMonth();\n var year = date.getFullYear();\n\n // update properties if different\n if (month !== that.selectedMonth || year !== that.selectedYear) {\n that.selectedMonth = month;\n that.selectedYear = year;\n\n return true;\n }\n\n return false;\n }", "title": "" }, { "docid": "50aedff2fbf7c6025b04d51245ebba20", "score": "0.5218504", "text": "function _modAssetSet(data) {\n var i, j;\n\n // Pass assets/dates one at a time to setBorrowerName and formatDueDate\n for (i = 0; i < data.length; i++) {\n _setBorrowerName(data[i]);\n\n for (j = 0; j < data[i]['active_reservations'].length; j++) {\n data[i]['active_reservations'][j].end =\n UtilService.formatDueDate('', data[i]['active_reservations'][j].end);\n }\n }\n }", "title": "" }, { "docid": "b1be1a1181e2bf813f9b4e84a787a347", "score": "0.52174973", "text": "convertDates(moments) {\n for (let m in moments) {\n const dateArray = moments[m].date.split(\"-\")\n moments[m].date = new Date(`${dateArray[0]}/${dateArray[1]}/${dateArray[2]}`);\n }\n\n return moments;\n }", "title": "" }, { "docid": "8d60578f883fb8b68014cea475431e03", "score": "0.5213451", "text": "createDtArray() {\n this.dtArray = this.priceArray.map(function(d){return d.Date;});\n }", "title": "" }, { "docid": "f0d9cf8b0896d3f3e33c0e5524e6ef8e", "score": "0.5209541", "text": "function setDate(year, month) {\n $(\"#years option\").prop('selected', false);\n $(\"#years option[value=\\\"\" + year + \"\\\"]\").prop('selected', true);\n $(\"#months option\").prop('selected', false);\n $(\"#months option[value=\\\"\" + month + \"\\\"]\").prop('selected', true);\n club();\n}", "title": "" }, { "docid": "3bd19bbb93e77520f3cd5835f2a72ef0", "score": "0.519808", "text": "function CP_setMonthAbbreviations() {\r\n for (var i = 0; i < arguments.length; i++) { this.monthAbbreviations[i] = arguments[i]; }\r\n this.copyMonthNamesToWindow();\r\n}", "title": "" }, { "docid": "aa843cf1f3863ce6b273149f5da5baa9", "score": "0.519386", "text": "set interimSegments(segments) {\n const interimSegments = segments.map(segment => DateTimeSegment.fromDateTimeSegment(segment));\n this._interimSegments = interimSegments;\n // cannot populate calendar if from is after to, it looks broken\n this.calendarValues = this.isFromBeforeTo() ? interimSegments.map(segment => segment.dateSegment) : [];\n this.timepickerValues = interimSegments.map(segment => segment.timeSegment);\n }", "title": "" }, { "docid": "fa20ec1a57d4d65e19adaec0537da8c6", "score": "0.5187492", "text": "function setDateSettings() {\n let state = STATE.get();\n // Set the \"last\" day and month to be the last of the getCapabilities data\n const dailyDates = `g02135_extent_raster_daily_n`;\n const lastDay = util.getLast(state.validDates[dailyDates]).split('T')[0];\n STATE.set('DEFAULTS.daily.end', moment(lastDay));\n const monthlyDates = `g02135_extent_raster_monthly_n`;\n const lastMonth = util.getLast(state.validDates[monthlyDates]).split('T')[0];\n STATE.set('DEFAULTS.monthly.end', moment(lastMonth));\n const lastYear = util.getLast(state.validDates[dailyDates]).split('-')[0];\n $('#sYear').attr({'max': lastYear});\n $('#eYear').attr({'max': lastYear, 'value': lastYear});\n\n document.querySelector('input[name=\"sDate\"]').value = state.DEFAULTS[state.temporality].start.format('YYYY-MM-DD');\n document.querySelector('input[name=\"eDate\"]').value = state.DEFAULTS[state.temporality].end.format('YYYY-MM-DD');\n}", "title": "" }, { "docid": "a94fb7e49b68ae75063c1cbf2933988d", "score": "0.5179796", "text": "function fillYears() {\n var today = new Date();\n var twoYearsFromCurrentYear = today.getFullYear() - 1;\n var yearChooser = form.chooseYear;\n for (var i = twoYearsFromCurrentYear; i <= twoYearsFromCurrentYear + 2; i++) {\n yearChooser.options[yearChooser.options.length] = new Option(i, i);\n }\n form.chooseYear.selectedIndex = 1;\n setCurrMonth(today);\n }", "title": "" }, { "docid": "7f2c6faac1f9b348465703067eeabe73", "score": "0.51779586", "text": "set date(aValue) {\n this._logger.debug(\"date[set]\");\n this._date = aValue;\n }", "title": "" }, { "docid": "64780b5b48148c0994a242dda09b9281", "score": "0.51745045", "text": "function CP_setMonthNames() {\r\n for (var i = 0; i < arguments.length; i++) { this.monthNames[i] = arguments[i]; }\r\n this.copyMonthNamesToWindow();\r\n}", "title": "" }, { "docid": "dfb03a94632b36e3ba9469d71a7fe2f4", "score": "0.51677245", "text": "function calSetDays(year, month) {\n\tvar firstday = getFirstday(year, month);\n\tvar dayCount = arrayMonthDayCountNLY;\n\tvar currdate = new Date().getDate();\n\tvar curryear = new Date().getFullYear();\n\tvar currmonth = new Date().getMonth();\n\tvar setDays = new Array(42);\n\tvar counter = 1;\n\tif(year%4==0) {\n\t\tdayCount = arrayMonthDayCountLY;\n\t}\n\n\t//This loop gives values logically to the squares in the Calendar UI.\n\tfor (var i = 0; i < 42; i++) {\n\t\tif(i < firstday || counter > dayCount[month]) {\n\t\t\tsetDays[i] = null;\n\t\t}\n\t\telse {\n\t\t\tsetDays[i] = counter;\n\t\t\tcounter++;\n\t\t}\n\t}\n\n\t//I concatinate zero(0) to the month and date that is less than 10 because I need two digits\n\t//in and adding zero(0) at the beggining of it makes it a two-digit number.\n\tif(currdate < 10) {\n\t\tcurrdate = \"0\" +currdate;\n\t}\n\tif(currmonth < 9) {\n\t\tthismonth = currmonth+1;\n\t\tthismonth = \"0\" +thismonth;\n\t}\n\telse {\n\t\tthismonth = currmonth+1;\n\t}\n\tif(month < 9) {\n\t\tothermonth = month+1;\n\t\tothermonth = \"0\" +othermonth;\n\t}\n\telse {\n\t\tothermonth = month+1;\n\t}\n\n/*\tfor (var i = 0; i < 42; i++) {\n\t\t$('')\n\t}\n*/\n\t//This loop get will get the logical value of every squares in the Calendar UI.\n\tfor (var i = 0; i < 42; i++) {\n\t\t//unbind the previous event first\n\t\t$('#' +i).unbind();\n\t\t//Since some of the value in the array are null, we have to trap it\n\t\t//in order not to return an undefined value.\n\t\tif(setDays[i] == null) {\n\t\t\tsetDays[i] = \"\";\n\t\t\t$('#' +i).addClass(\"empty\");\n\t\t\t$('#' +i).removeClass(\"datevalid\");\n\t\t\t$('#p' +i).text(setDays[i]);\n\t\t\t$('#' +i).click(function() {\n\t\t\t\t$('input[name=\"date\"]').val(\"\");\n\t\t\t\talert('Invalid Date');\n\t\t\t});\n\t\t}\n\t\telse {\n\t\t\t$('#' +i).removeClass(\"empty\");\n\t\t\tif(setDays[i] < 10) {\n\t\t\t\td = \"0\" +setDays[i];\n\t\t\t}\n\t\t\telse {\n\t\t\t\td = setDays[i];\n\t\t\t}\n\t\t\t//This section below is needed since we just make use of the future dates.\n\t\t\t//That exludes the date today and the date older than yesterday.\n\t\t\tvar thisday = parseInt(\"\"+curryear+thismonth+currdate);\n\t\t\tvar otherday = parseInt(\"\"+year+othermonth+d);\n\t\t\tvar dif = otherday - thisday;\n\t\t\tif(thisday > otherday) {\n\t\t\t\t$('#' +i).removeClass(\"datevalid\");\n\t\t\t\t$('#' +i).addClass(\"yesterday\");\n\t\t\t\t$('#p' +i).text(setDays[i]);\n\t\t\t\t$('#' +i).click(function() {\n\t\t\t\t\t$('input[name=\"date\"]').val(\"\");\n\t\t\t\t\talert('Invalid Date');\n\t\t\t\t});\n\t\t\t}\n\t\t\telse {\n\t\t\t\t$('#' +i).removeClass(\"yesterday\");\n\t\t\t\t$('#' +i).addClass(\"datevalid\");\n\t\t\t\t$('#p' +i).text(setDays[i]);\n\t\t\t\t$('#' +i).click(function() {\n\t\t\t\t\tvar day = $(this).find('p').text();\n\t\t\t\t\tif(day < 10) {\n\t\t\t\t\t\tday = \"0\" +day;\n\t\t\t\t\t}\n\t\t\t\t\tvar date = year+ \"-\" +othermonth+ \"-\" +day;\n\t\t\t\t\t$('input[name=\"date\"]').val(date);\n\t\t\t\t});\n\t\t\t}\n\t\t}\n\n\t\t//I use this condition to locate the date today.\n\t\tif(year == curryear && month == currmonth && currdate == setDays[i]) {\n\t\t\t$('#' +i).addClass(\"thisday\");\n\t\t\t$('#' +i).removeClass(\"datevalid\");\n\t\t\t$('p#' +i).text(setDays[i]);\n\t\t\t$('#' +i).click(function() {\n\t\t\t\t$('input[name=\"date\"]').val(\"\");\n\t\t\t\talert('Invalid Date');\n\t\t\t});\n\t\t}\n\t\telse {\n\t\t\t$('#' +i).removeClass(\"thisday\");\n\t\t}\n\t}\n\tconsole.log(dayCount[month]);\n}", "title": "" }, { "docid": "f525eaf8a304ec73d70958126cf92fed", "score": "0.5151792", "text": "function setDaysInMonth(){\n i = 1;\nlet dayone = firstDay();\nlet daysInThisMonth = daysInMonth();\nvar nameOfMonth = month[my_date.getMonth()]; \n \nfor (let x = dayone.getDay(); i <= daysInThisMonth; ++x){\n tiles[x].today = i;\n tiles[x].month = nameOfMonth;\n tiles[x].year = this_year();\n i++;\n }\n \n \n\n}", "title": "" }, { "docid": "62231e9d4879dd7811f7267cd2fd612e", "score": "0.5145751", "text": "function YWakeUpSchedule_set_months(newval)\n { var rest_val;\n rest_val = String(newval);\n return this._setAttr('months',rest_val);\n }", "title": "" }, { "docid": "304713996f6b725dcc54ae2e6293e06e", "score": "0.51189995", "text": "function setData( o, v ) {\n\n\t\t\t\to[ \"date\" ] = v;\n\t\t\t}", "title": "" }, { "docid": "50e360995c1608f14db8c0826b092ec9", "score": "0.51189274", "text": "function updateSelectedDate(year, month) {\r\n Array.from(selectMonth.children).forEach((el, index) => {\r\n el.selected = false;\r\n if (index === month - 1) {\r\n el.selected = true;\r\n selectMonth.style.width = el.textContent.length + 2 + \"rem\";\r\n }\r\n });\r\n Array.from(selectYear.children).forEach((el) => {\r\n el.selected = false;\r\n if (el.value === String(year)) {\r\n el.selected = true;\r\n }\r\n });\r\n}", "title": "" }, { "docid": "384c1f11ea3276c11083b70c1fae488b", "score": "0.51182836", "text": "function spreadInConstructors(){\n\n let dt = new Date(2019,10,15);\n console.log(dt);\n\n let dateFields = [2019,11,15];\n dt = new Date(...dateFields);\n console.log(dt);\n\n}", "title": "" }, { "docid": "04772d306a4ab4c93f034b7593804f09", "score": "0.5113925", "text": "_setFromDate(date) {\n let dates = get(this, '_dates');\n let [, dateTo] = dates;\n let vals;\n\n if (dateTo && date.valueOf() > dateTo.valueOf()) {\n vals = array([date, null]);\n } else {\n vals = array([date, dateTo || null]);\n }\n\n set(this, '_dates', vals);\n }", "title": "" }, { "docid": "366f5ce8574c91b96e307692398e3fb5", "score": "0.5069741", "text": "resetDates() {\n var reset = new Array(32);\n for(var i=0; i<32; i++)\n reset[i] = i;\n\n var id = MCalendar.find({room: this.state.roomNumber}).fetch()[0]._id;\n MCalendar.update({_id: id}, {\n $set: { array: reset },\n })\n\n this.update();\n }", "title": "" }, { "docid": "f6891c539930165f87e52e01db428e19", "score": "0.5067302", "text": "_assignValueProgrammatically(value) {\n value = this._dateAdapter.deserialize(value);\n this._lastValueValid = this._isValidValue(value);\n value = this._dateAdapter.getValidDateOrNull(value);\n this._assignValue(value);\n this._formatValue(value);\n }", "title": "" }, { "docid": "282d3e8944deadc3fd24cd67c061ec81", "score": "0.50563467", "text": "set(a00,a01,a02,a10,a11,a12,a20,a21,a22){\n\t\t\t\t this.a00=a00;\n\t\t\t\t this.a01=a01;\n\t\t\t\t this.a02=a02;\n\t\t\t\t this.a10=a10;\n\t\t\t\t this.a11=a11;\n\t\t\t\t this.a12=a12;\n\t\t\t\t this.a20=a20;\n\t\t\t\t this.a21=a21;\n\t\t\t\t this.a22=a22;\n\t\t\t }", "title": "" }, { "docid": "289271d00fc9cc5f3346c02f07126ec8", "score": "0.5049272", "text": "function setAbusers(mdbres) {\n\n var newElementsSet = [];\n\n\n mdbres.forEach(element => {\n \n let dateTime = element.date;\n\n let theSet = dateTime.toString().split(\" \");\n\n let date = \"\" + theSet[0] + \", \" + theSet[1] + \" \" + theSet[2] + \" \" + theSet[3];\n\n let time = theSet[4];\n\n let difference = parseInt(element.difference);\n\n newElementsSet.push({_id : element._id, name : element.name, date : date, time : time, difference : difference});\n }); \n\n return newElementsSet;\n}", "title": "" }, { "docid": "5a04dcede3ec5c8ffa3e219d730b05aa", "score": "0.50457346", "text": "function adjustDates(dates, arr, func) {\n if (!arr) {\n return dates;\n }\n var result = [];\n for (var i=0; i < dates.length; i++) {\n var d = dates[i];\n for (var j=0; j < arr.length; j++) {\n func(d, arr[j], result, j);\n }\n }\n return result;\n }", "title": "" }, { "docid": "008c458764dd856003302f51ddaed695", "score": "0.50386935", "text": "function setAnimPatternArray(array) {\n\t\t\tmAnimPatternArray = array;\n\t\t\t//get Max value\n\t\t\tvar max = 0;\n\t\t\tfor (var i = 0; i < array.length; ++i) {\n\t\t\t\tif (max < array[i]) {\n\t\t\t\t\tmax = array[i];\n\t\t\t\t}\n\t\t\t}\n\t\t\tmAnimPatternIndexMax = max + 1;\n\t\t}", "title": "" }, { "docid": "cd0874a232559124477a78a378c381ca", "score": "0.5024191", "text": "function update_date_field_for_sort(arr) {\n for (let entry of arr) {\n entry.Date = {\n str: build_date_with_dow_string(entry.Date),\n timestamp : new moment(entry.Date, K_DateFormat_Moment, true).valueOf()\n }\n }\n}", "title": "" }, { "docid": "de8b48c9170b8bd761622cb0885e09ec", "score": "0.50187004", "text": "function set(ms, lat, lon) {\n return julian.from(\n _rise_and_set(julian.to(ms), lat * RAD, lon * RAD).moonset\n );\n}", "title": "" }, { "docid": "c14b3746fc39cfc74e9ebb91bf6316dc", "score": "0.49869883", "text": "function test() {\n var d = new Date();\n print('about to set year');\n d.setFullYear(123912921921321);\n print('year set ok');\n print(d);\n}", "title": "" }, { "docid": "cd7145a9a6efbd3ba9580335c0bbf501", "score": "0.49845028", "text": "setValues(values) {\n values.forEach((value, index) => {\n this.setColumnValue(index, value);\n });\n }", "title": "" }, { "docid": "cd7145a9a6efbd3ba9580335c0bbf501", "score": "0.49845028", "text": "setValues(values) {\n values.forEach((value, index) => {\n this.setColumnValue(index, value);\n });\n }", "title": "" }, { "docid": "fc61f73f74641f11543396a579225951", "score": "0.4978682", "text": "function setYear() {\n\tvar element = document.getElementById(\"selected_year\");\n\tYEAR = element.options[element.selectedIndex].value;\n\tsetDateContent(MONTH, YEAR);\n}", "title": "" }, { "docid": "18c66024b3448040e83b1d8cea541c47", "score": "0.49579743", "text": "function setFiveDayObjectVals (nameofCity, dailyWeatherArray){\n\n // Set days 1 - 5 only\n for (var i = 1; i < 6; i++) {\n cityWeatherObject.dailyArray[i].date = moment.unix(dailyWeatherArray[i].sunset).format(\"MM/DD/YY\");\n cityWeatherObject.dailyArray[i].iconURL = `http://openweathermap.org/img/w/${dailyWeatherArray[i].weather[0].icon}.png`;\n cityWeatherObject.dailyArray[i].temp = \"Temp: \" + dailyWeatherArray[i].temp.day + \" \\u00B0F\";\n cityWeatherObject.dailyArray[i].humidity = \"Humidity: \" + dailyWeatherArray[i].humidity + \"%\";\n }\n}", "title": "" }, { "docid": "25fa87f77c6b6b246e78f39ce73e63a1", "score": "0.49544492", "text": "setDate(now = new Date()) {\n let startDay = new Date(now.getFullYear(), now.getMonth(), 1).getDay() - 1;\n startDay = startDay < 0 ? 6 : startDay;\n\n this.date = {\n year: now.getFullYear(),\n month: now.getMonth(),\n day: now.getDate(),\n startDay: startDay,\n daysOfMonth: new Date(now.getFullYear(), now.getMonth()+1, 0).getDate()\n }\n }", "title": "" }, { "docid": "f6a29856223cc4ccaea4599c2459752d", "score": "0.49461693", "text": "function updateMonths(minMonth, maxMonth) {\n var selectedyear = getValue('year') || 0;\n var fmt;\n\n if (minMonth == null) {\n minMonth = 0;\n }\n\n if (maxMonth == null) {\n maxMonth = 11;\n }\n\n function _dateRange(year, range) {\n range -= 1;\n\n if ($('#year').is(':visible')) {\n return function (m) {\n return $.datepick.formatDate('M y',\n new Date(selectedyear, m - range)) + ' &ndash; ' +\n $.datepick.formatDate('M y',\n new Date(selectedyear, m));\n }\n } else {\n return function (m) {\n return $.datepick.formatDate('M',\n new Date(selectedyear, m - range)) + ' &ndash; ' +\n $.datepick.formatDate('M',\n new Date(selectedyear, m));\n }\n }\n }\n\n switch (ocean.period) {\n case 'hourly':\n fmt = function (m) {\n return $.datepick.formatDate('MM',\n new Date(selectedyear, m));\n };\n break;\n\n case 'monthly':\n fmt = function (m) {\n return $.datepick.formatDate('MM',\n new Date(selectedyear, m));\n };\n break;\n\n case '3monthly':\n fmt = _dateRange(selectedyear, 3);\n break;\n\n case '6monthly':\n fmt = _dateRange(selectedyear, 6);\n break;\n\n case '12monthly':\n fmt = _dateRange(selectedyear, 12);\n break;\n\n case 'yearly':\n /* ignore */\n return;\n\n default:\n console.error(\"ERROR: should not be reached\");\n return;\n }\n\n var month = $('#month');\n\n month.find('option').remove();\n\n for (m = minMonth; m <= maxMonth; m++) {\n $('<option>', {\n value: m,\n html: fmt(m)\n }).appendTo(month);\n }\n\n var selectedmonth = ocean.date.getMonth();\n\n if (selectedmonth < minMonth) {\n selectFirstIfRequired('month');\n } else if (selectedmonth > maxMonth) {\n month.find('option:last').attr('selected', true);\n month.change();\n } else {\n setValue('month', selectedmonth);\n }\n}", "title": "" }, { "docid": "376d94e9d8d67da386cbdbcd8399c415", "score": "0.49450946", "text": "set date(value) {\n this._date = value;\n }", "title": "" }, { "docid": "f41f9dc08662cb7bdebd0a7312388c3d", "score": "0.49441478", "text": "function selectYear(){\n console.log(this.value);\n\n dateInfo.year = this.value\n //console.log(dateInfo.year);\n\n this.value = this[0].value;\n console.log(this.value);\n \n \n\n document.getElementById(\"yearSelect\").style.display = \"none\"\n\n document.getElementById(\"monthSelect\").style.display = \"inline\"\n\n \n}", "title": "" }, { "docid": "72a32d8b63cf3324bb5fffef29e98182", "score": "0.49287772", "text": "setPoints(points) {\n points.forEach(point => {\n this.setPoint(point[0], point[1])\n })\n }", "title": "" }, { "docid": "406c51010563927a081035d40c2628b2", "score": "0.49208596", "text": "handleYearMonthChange(month) {\n this.setState({ month });\n }", "title": "" }, { "docid": "87d7cd5ee05534b112dc97455cc45627", "score": "0.49160007", "text": "function setUTCValuesInDate(date) {\n return new Date(\n date.getUTCFullYear(),\n date.getUTCMonth(),\n date.getUTCDate(),\n date.getUTCHours(),\n date.getUTCMinutes(),\n date.getUTCSeconds(),\n );\n }", "title": "" }, { "docid": "8c377e4496e7be382797c9d970c5e6a8", "score": "0.49135968", "text": "@action setObjectBP(date, data) {\n var thisDate = moment(date).format('YYYY-MM-DD')\n this.allDataObject[thisDate] = data;\n }", "title": "" }, { "docid": "abc972924f86474a0580a601e34386a9", "score": "0.49070883", "text": "function set_dateViewer(buffer){\n var day_buffer=Array(),month_buffer=Array(),year_buffer=Array();\n if(buffer==null){\n if(!currentMonth)\n month_buffer.push(null);\n if(!currentDay)\n day_buffer.push(null);\n for(var i=1;i<=31;i++)\n day_buffer.push(i);\n for(var j=1;j<13;j++)\n month_buffer.push(j)\n for(var k=2001;k<=2013;k++)\n year_buffer.push(k);\n }\n else{\n var temp_array = ParseDate_dateViewer(buffer);\n day_buffer=temp_array[0],month_buffer=temp_array[1],year_buffer=temp_array[2];\n }\n for(var i=0;i<day_buffer.length;i++){\n var day = document.createElement('option');\n day.innerHTML = day_buffer[i];\n day.id=\"day\"+day_buffer[i];\n document.getElementById('manualDay').appendChild(day);\n }\n for(var j=0;j<month_buffer.length;j++){\n var month = document.createElement('option');\n month.innerHTML=month_buffer[j];\n month.id=\"month\"+month_buffer[j];\n document.getElementById('manualMonth').appendChild(month);\n }\n for(var k=0;k<year_buffer.length;k++){\n var year = document.createElement('option');\n year.innerHTML=year_buffer[k];\n year.id=\"year\"+year_buffer[k];\n document.getElementById('manualYear').appendChild(year);\n }\n}", "title": "" }, { "docid": "95f45eec0058792551090f6c74041083", "score": "0.49049163", "text": "function putMask_YearMonthDate(oElement)\n{\n var lstrValue = oElement.value;\n if(lstrValue == \"\" || !isInteger(lstrValue))\n return;\n\n re = new RegExp(\"/\",\"g\");\n lstrValue = lstrValue.replace(re,\"\");\n if (lstrValue.length == 6) {\n partOne = lstrValue.substring(0,4);\n partTwo = lstrValue.substring(4);\n oElement.value = partOne + \"/\" +partTwo;\n }\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "c19dd6e886f85f14109467b1baa75b3f", "score": "0.49039775", "text": "function set$1(date, unit, to) {\n return date.set(unit, to);\n}", "title": "" }, { "docid": "05c03cb2bd38fcc38e4e454286f12865", "score": "0.4902052", "text": "_setSelectedMonth(value) {\n if (value instanceof DateRange) {\n this._selectedMonth = this._getMonthInCurrentYear(value.start) ||\n this._getMonthInCurrentYear(value.end);\n }\n else {\n this._selectedMonth = this._getMonthInCurrentYear(value);\n }\n }", "title": "" }, { "docid": "064b80f1f76000b53a5c016c70544906", "score": "0.4892726", "text": "function updateNonDailyDateBasedOnDataset(){\n updateYearBasedOnDataset();\n updateMonthBasedOnDataset();\n updateOceanDate();\n}", "title": "" }, { "docid": "84f1092dcb40f6ad11d30932f610aa7b", "score": "0.48926565", "text": "function setupMonths(){\n for(var i = 0; i < months.length; i++){\n for(var x = months[i].firstDay; x < months[i].lastDay + months[i].firstDay; x++){\n months[i].days.push({cell: {}, todos: [], events:[]});\n }\n }\n}", "title": "" }, { "docid": "361584e86a38628d5a659f1edef84dc6", "score": "0.4883514", "text": "function setRange(range){\n\t\t\t\t\tif(range === 'custom'){return;}\n\t\t\t\t\t//This is because I just need one edge case of years, not fully fleshed out for other date types\n\t\t\t\t\tvar rangeAsString = String(range);\n\t\t\t\t\tif(rangeAsString.length === 4){\n\t\t\t\t\t\t$scope.stringDates.startDate = '01/01/'+rangeAsString;\n\t\t\t\t\t\t$scope.stringDates.endDate = '12/31/'+rangeAsString;\n\t\t\t\t\t\treturn;\n\t\t\t\t\t}\n\t\t\t\t\tvar momentFormattedRange = range.split(' ');\n\t\t\t\t\t$scope.stringDates.startDate = moment().format('MM/DD/YYYY');\n\t\t\t\t\t$scope.stringDates.endDate = moment().add(momentFormattedRange[0],momentFormattedRange[1]).format('MM/DD/YYYY');\n\t\t\t\t}", "title": "" }, { "docid": "7d366485928aa872505d5b4ea2accd96", "score": "0.48706424", "text": "_setAll(attr, value) {\n this._forEach(event => {\n event[attr] = value;\n });\n }", "title": "" }, { "docid": "776fc84377c4b40cabc3316da213a380", "score": "0.48683083", "text": "function rise_and_set(ms, lat, lon) {\n const x = _rise_and_set(julian.to(ms), lat * RAD, lon * RAD);\n x.moonrise = julian.from(x.moonrise);\n x.moonset = julian.from(x.moonset);\n return x;\n}", "title": "" }, { "docid": "4375b32c08fe901ac001b150397450f0", "score": "0.48652828", "text": "changeYear(sign, value) {\n const oldYear = this.date.getUTCFullYear(); // FullYear gets round the 1900 issue\n const modifier = useSign[sign](oldYear, value);\n this.date.setUTCFullYear(modifier);\n }", "title": "" }, { "docid": "c7d25b6e5e84dea5419b305c5dae9d6d", "score": "0.48558104", "text": "function setDateToCalendar(obj,objID) \n\t{\n\t\tvar splitValue\t= \"/\";\n\t\tvar dateArray = obj.value.split(splitValue);\n\t\tif( obj.value!=\"\" )\n\t\t{\n\t\t\tobjID.day\t= Number( dateArray[0] ) ;\n\t\t\tobjID.month = Number( dateArray[1] ) ;\n\t\t\tdateArray[2] = Number( dateArray[2] ) > 2500 ? Number( dateArray[2] ) - 543 : Number( dateArray[2] ) ;\n\t\t\tobjID.year = Number( dateArray[2] ) ;\n\n\t\t}\n\t}", "title": "" }, { "docid": "618ac88c3d9e3439618085bfb5d6b4eb", "score": "0.48528856", "text": "function setYear() {\n\n // GET THE NEW YEAR VALUE\n var year = tDoc.calControl.year.value;\n\n // IF IT'S A FOUR-DIGIT YEAR THEN CHANGE THE CALENDAR\n if (isFourDigitYear(year)) {\n calDate.setFullYear(year);\n\n\t// GENERATE THE CALENDAR SRC\n\tcalDocBottom = buildBottomCalFrame();\n\n // DISPLAY THE NEW CALENDAR\n writeCalendar(calDocBottom);\n }\n else {\n // HIGHLIGHT THE YEAR IF THE YEAR IS NOT FOUR DIGITS IN LENGTH\n tDoc.calControl.year.focus();\n tDoc.calControl.year.select();\n }\n}", "title": "" }, { "docid": "e205e136485cde70c318658388b7310c", "score": "0.4843613", "text": "function updateYearBounds() {\n document.getElementById(\"dateMin\").max = document.getElementById(\"dateMax\").value;\n document.getElementById(\"dateMax\").min = document.getElementById(\"dateMin\").value;\n}", "title": "" }, { "docid": "a66f6e72635733e992692d1e0800bc28", "score": "0.4836201", "text": "function setMonth() {\n\tvar element = document.getElementById(\"selected_month\");\n\tMONTH = element.options[element.selectedIndex].value;\n\tsetDateContent(MONTH, YEAR);\n}", "title": "" }, { "docid": "e145cdb914a4e654d7f0fceb5e98bbf5", "score": "0.48310134", "text": "function assignDatesToEvent(start,end,allDay,event){event.start=start,event.end=end,event.allDay=allDay,normalizeEventDates(event),backupEventDates(event)}", "title": "" }, { "docid": "bb4d232bfa3e882804fe9e47d007b485", "score": "0.48265466", "text": "setMobs(mobs){\r\n this.mobs = mobs\r\n this.startTime = 0.0\r\n }", "title": "" }, { "docid": "a07d79b302df65c34277a1829c48b8aa", "score": "0.48265246", "text": "function callBackForSettingMonth(monthID){\n //Remember these will get merged into a single object\n setMonth(monthID)\n }", "title": "" }, { "docid": "12a0449847e22a61c8e64dccab6d421f", "score": "0.48247692", "text": "function setMonth(picker, m, notFire) {\n var selectMonthElement = monthElement(picker);\n monthBackEnd = m - 1;\n selectMonthElement.selectedIndex = monthBackEnd;\n\n var numOfDays = lastDayInMonth(yearBackEnd, monthBackEnd);\n if (dateBackEnd > numOfDays)\n dateBackEnd = numOfDays;\n\n if (!notFire) {\n fireOnchange(selectMonthElement);\n }\n }", "title": "" }, { "docid": "0a8ff3c9bd32b52fa7f152f57f3766a8", "score": "0.48155376", "text": "function fixRadMonthYearPicker() {\n fixRadMonthYearPicker_2(uiStartYearMonthID);\n fixRadMonthYearPicker_2(uiEndYearMonthID);\n}", "title": "" }, { "docid": "ce5ad4afc56557680f75fb8336ac5ca0", "score": "0.4807817", "text": "static setSeasons(season_list) {\n\t\tif (Period.seasons == undefined) {\n\t\t\tPeriod.seasons = season_list;\n\t\t}\n\t\telse {\n\t\t\tif (Period.seasons.length != season_list.length) {\n\t\t\t\tconsole_warn_safe(\"Period Object Seasons List has been changed.\", \"Original: \", Period.seasons, \"New: \", season_list);\n\t\t\t}\n\t\t\tfor (let i in season_list) {\n\t\t\t\tif (season_list[i] != Period.seasons[i]) {\n\t\t\t\t\tconsole_warn_safe(\"Period Object Seasons List has been changed.\", \"Original: \", Period.seasons, \"New: \", season_list);\n\t\t\t\t}\n\t\t\t}\n\t\t\t// season_list.map((val, i) => val == Period.seasons[i]).reduce((a,c) => a && c)\n\t\t}\n\t\tPeriod.seasons = season_list;\n\t}", "title": "" } ]
306ccef9cceef3344d5a9687f1a5ddab
Removes characters that are not digits, then removes leading zeros
[ { "docid": "ee435f1e5d917f16a7b77b7c17c0fbbe", "score": "0.0", "text": "function sanitizeInteger (val) {\n return String(parseInt(removeNonDigits(val) || '0', 10))\n}", "title": "" } ]
[ { "docid": "b0439e3b64eeb518f1f4a06a9242ca55", "score": "0.7554283", "text": "function removeLeadingZeros(value) {\n var i = 0;\n var lastLeadingZeroPos = -1;\n for (i = 0; i < value.length; i++) {\n if (value.charAt(i) === '0') {\n\tlastLeadingZeroPos = i;\n } else {\n\tbreak;\n }\n }\n var result = value.substring(lastLeadingZeroPos + 1);\n // Add zero before . back in\n if (result === \"\" || result.charAt(0) === '.') {\n result = '0' + result;\n }\n return result;\n }", "title": "" }, { "docid": "32ed17a048914c540df0da79727f43da", "score": "0.7224868", "text": "function trimLeadingZeroes(value) {\n value = value.replace(/^0+/, '');\n if (value === '') {\n return '0';\n }\n return value;\n}", "title": "" }, { "docid": "2f82fa9e8af521df36aba0f6a2687056", "score": "0.70014673", "text": "function zeroSuppress (num, digit) {\n var tmp = num.toString();\n while (tmp.length < digit) {\n\t\ttmp = \"0\" + tmp;\n\t}\n return tmp;\n}", "title": "" }, { "docid": "0bb11e09e8049b795de3d5469d59bfda", "score": "0.68750584", "text": "function stripleadingzeroes(segments) {\n\t\tvar numsegs = segments.length;\n\t\tvar segment;\n\n\t\tfor (i=0; i<numsegs; i++)\t// for each of the segments\n\t\t{\n\t\t\tsegs=segments[i].split(\"\");\t// split the segment apart\n\t\t\tfor (j=0; j<3 ; j++)\t// scan through at most three characters\n\t\t\t{\n\t\t\t\t// alert(segs);\n\t\t\t\tif ((segs[0] == \"0\") && (segs.length > 1))\t// if leading zero and not last character\n\t\t\t\t\tsegs.splice(0,1);\t// take it out\n\t\t\t\telse break;\t// non-zero or last character - break out\n\t\t\t}\n\t\t\tsegments[i] = segs.join(\"\");\t// put 'em back together\n\t\t}\n\t}", "title": "" }, { "docid": "a6948fcdf4dd95b8943a1e755e611c16", "score": "0.6850478", "text": "function LeadingZeros(str)\n{\n\tvar retval = \"\"\n\tstr += \"\"\n\n\tfor(var i=0;i<str.length;i++)\n\t{\n\t\tif (str.charAt(i) == \" \")\n\t\t\tretval += \"0\"\n\t\telse retval += str.charAt(i)\n\t}\n\n\treturn retval\n}", "title": "" }, { "docid": "90721233010a25379525c2147abdd6ab", "score": "0.68220556", "text": "function reduceDigits(s) {\n return s.replace(/[^0-9]/g, '');\n}", "title": "" }, { "docid": "6cd5dd85531239f2fed3f50a1c9dd079", "score": "0.6769071", "text": "function retainNumberChars(str) {\n if (_.isString(str)) {\n return Array.prototype.slice.call(str)\n .filter(function (char) {\n // Only keep the chars that are numerical digits\n return char.charCodeAt(0) >= \"0\".charCodeAt(0) && char.charCodeAt(0) <= \"9\".charCodeAt(0);\n })\n .join('');\n }\n\n return str;\n }", "title": "" }, { "docid": "c21249f66249dfb11bd4e2c40bd72b82", "score": "0.67404306", "text": "function rmZeroLeft(sStr){\n\t var i;\n\t for(i=0;i<sStr.size;i++)\n\t \tif(sStr.charAt(i)!='0')\n\t \t\treturn sStr.substring(i);\n\t \treturn sStr;\n\t}", "title": "" }, { "docid": "560422b848ce88ce5c3f8ad16795e502", "score": "0.67117083", "text": "function removeLeadingZeroes(param) {\n return `${toNum(param)}`;\n}", "title": "" }, { "docid": "2164669445bde8926c957331a68cf3ce", "score": "0.6679998", "text": "function removeLeadingZero( string ) {\n\t\tlet p1 = getSign( string );\n\t\tlet s1 = splitNumber( removeSign( string ) );\n\n\t\tlet i = 0;\n\t\twhile( s1[0].charAt(i) == \"0\" ) { i++; }\n\n\t\ts1[0] = ( i == s1[0].length ) ? \"0\" : ( s1[0].substr(i, s1[0].length - i ) );\n\n\t\treturn p1 + s1.join( \".\" );\n\t}", "title": "" }, { "docid": "e7f3b9057e732dd73ce810f2421bec9a", "score": "0.6545467", "text": "function removeTrailZero(number) {\n if (number[0] === '-') {\n return '-' + number.substring(1).replace(/^0+/, '');\n }\n const newString = number.replace(/^0+/, '');\n return newString === '' ? '0' : newString;\n}", "title": "" }, { "docid": "2c481f88aace3d8336dde9e7a239bf1a", "score": "0.6474161", "text": "function with_leading_zero(d) {\n\td = ''+d;\n\treturn d.length === 1 ? '0' + d : d;\n}", "title": "" }, { "docid": "128d5be8efe3e68054d8a4790415c7fa", "score": "0.640061", "text": "function leadingZero(number) {\r\n return (`0${number}`).slice(-2);\r\n}", "title": "" }, { "docid": "3fcc1843c06a7f04b65aa4a793aec555", "score": "0.6385615", "text": "function stripNonNumeric(text){\n text = text.replace(/\\D/g,'');\n return text;\n}", "title": "" }, { "docid": "d03bcfc925148d7594bb733d64856bf5", "score": "0.63828987", "text": "removeNumbers(string) {\n return string.replace(/[0-9](\\ )*/g, '');\n }", "title": "" }, { "docid": "bb98a3aa729f9485d7fe9f76ea1b32b1", "score": "0.6353597", "text": "function clean_phone(phone_number) {\n let input_array = phone_number.split('');\n\n let cleaned = input_array.reduce( (output, char) => {\n if (isNaN(char)) {\n return output;\n } else {\n return output + char;\n }\n }, '1');\n\n return cleaned\n}", "title": "" }, { "docid": "c3da16f96d78b5a0b9a88fbd7fbd0de0", "score": "0.6336636", "text": "function cleanDigit(val,num){\n if (EXISTS(val)){\n var tmp = FIXED(NUM(val),num, true);\n var tmp2 = str2Num(tmp);\n return tmp2;\n }\n return '';\n}", "title": "" }, { "docid": "c719ca64f262793d53ec2fd688126f7a", "score": "0.63149244", "text": "function removeZeros(arr) {\n let len = arr.length;\n for (let i = 0; i < len; i++) {\n if (arr[i] === 0 || arr[i] === '0') {\n moveZeroToEnd(arr, i);\n i--;\n len--;\n }\n }\n return arr;\n}", "title": "" }, { "docid": "3ed1aa0d5b3c6c01bb90fe8e0149e099", "score": "0.62957585", "text": "function delTrailingZeros(theStr)\n{\n\tvar z = ''\n\tvar trailingZeroesComplete=false\n\tfor (var x=theStr.length; x>0;x--)\n\t{\n\tif (theStr.substring(x-1,x) != '0')\n\t\ttrailingZeroesComplete=true\n\n\tif (theStr.substring(x-1,x) != '0' || trailingZeroesComplete)\n\t\tz = theStr.substring(x-1,x)\t+ z \n\t}\t\n\treturn z\n}", "title": "" }, { "docid": "3f0e4c8c39b70f52b8a7a2d39a21bf6c", "score": "0.6293097", "text": "function noBoringZeros(n){\n return Number(`${n}`.replace(/0+$/, ''));\n}", "title": "" }, { "docid": "a0e9d798c2beaf5aa33b41bf2d1d8a8a", "score": "0.6288265", "text": "function noBoringZeros(n) {\n return +n.toString().replace(/0+$/g, '');\n}", "title": "" }, { "docid": "6a9c14c82aac8e98cc20dac3a99cd8c0", "score": "0.6274132", "text": "function cleanUp( string ) {\n\t\treturn removeLeadingZero( removeSign( string == undefined ? \"0\" : string ) );\n\t}", "title": "" }, { "docid": "4db14076c90e795bb29f65ee81b623f9", "score": "0.62629545", "text": "function zeroPad(num) {\n return (\"0\" + num).slice(-2);\n}", "title": "" }, { "docid": "4bfd552fd45e439e7f593e7e0bafcac6", "score": "0.6250522", "text": "function strip0x(input) {\n return input.replace(/^0x/, \"\")\n}", "title": "" }, { "docid": "cee6fca86c4903df674b118e485d4d2a", "score": "0.62440145", "text": "function normalizeStr(myString){\n\tfor(var i = myString.length; i < 17; i++){\n\t\tmyString += \"0\";\n\t\t\n\t}\n\treturn myString;\n}", "title": "" }, { "docid": "efb3ab3e13b87e7b085bcf67c4d0d254", "score": "0.62252396", "text": "function zeroPad(number, digits) {\n\t\t\tvar num = number + \"\";\n\t\t\twhile( num.length < digits ) {\n\t\t\t\tnum = '0' + num;\n\t\t\t}\n\t\t\treturn num;\n\t\t}", "title": "" }, { "docid": "2baaf5150f1c0e960a8d1be20dbe75eb", "score": "0.6208777", "text": "function leadingZero(a){return a<10?\"0\"+a:+a}", "title": "" }, { "docid": "8c1e635b1a5b87484eaee165cae83ddc", "score": "0.6192439", "text": "function zeroPadding(num, digit) {\n var zero = \"\";\n for (var i = 0; i < digit; i++) {\n zero += \"0\";\n }\n return (zero + num).slice(-digit);\n}", "title": "" }, { "docid": "614bdc6eb2841d17ed6ce7400ad53934", "score": "0.6190011", "text": "function removeNumbers(str) {\n return str.replace(/\\d/g, '');\n}", "title": "" }, { "docid": "c8de1aca74108d9b1c5816a68613dcd5", "score": "0.61857945", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n }", "title": "" }, { "docid": "500c87e1dd6c72ed9920a8898c2ec65b", "score": "0.61658895", "text": "function leadingZero(time){\n if (time <= 9){\n time = \"0\" + time;\n }\n return time;\n }", "title": "" }, { "docid": "b3535a77b8f35b10e14ee7ae80b9898c", "score": "0.6165685", "text": "function zeroPad(value) {\n\t\tvar returnValue = value.substring(0, 1) + '0' + value.substring(1);\n\t\t// console.log(returnValue);\n\t\treturn returnValue;\n\t}", "title": "" }, { "docid": "7a75c30c460ad7f8307e9c856fe7c295", "score": "0.6156876", "text": "function leadingZero(time) {\n if(time<=9){\n time = '0' + time;\n }\n return time;\n}", "title": "" }, { "docid": "14f6a03086a5285be0b7fea89035fc50", "score": "0.6156589", "text": "function shortenZeroes(numb)\n{\n char=[\"\",\"K\",\"M\",\"B\",\"T\"];\n index = 0;\n //Remove 3 mumbers from the back\n while(numb > 1000) \n {\n numb /= 1000;\n index++; //With each 3 deleted numbers, change to K, M, B, ...\n }\n numb = numb.toString(); //Convert to string\n money = [numb.slice(0,5),char[index]].join('')\n console.log(money);\n}", "title": "" }, { "docid": "63536ef84a7be0087397bff934f3864c", "score": "0.6156398", "text": "function add_leading_zero (el) {\n el = el.toString();\n if (el && el < 10) {el = '0' + el;}\n return el;\n }", "title": "" }, { "docid": "34a942ed05fd530f27fff86608bcf804", "score": "0.6140442", "text": "leading0(num) {\n return num < 10 ? '0' + num :num;\n }", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "36d2642677615f55a3bc0fdec327836e", "score": "0.61282694", "text": "function zeros(val) {\n if (/^-*0+$/.test(val.toString())) {\n return '0';\n }\n return val;\n}", "title": "" }, { "docid": "0b97d7b036ba4ebd8f91abf3754161c3", "score": "0.61235565", "text": "getNumeric(s) {\n return s.replace(/\\D/g, '');\n }", "title": "" }, { "docid": "bb8b4de5d5dfc4ae305d548d496c5bba", "score": "0.6115878", "text": "function onlyDigit2(obj) {\n reg = /[^0-9.]/g;\n obj.value = obj.value.replace(reg, \"\");\n}", "title": "" }, { "docid": "6dc060208e1ff4ab47be910c64bfb9ae", "score": "0.6112954", "text": "function numPad0(str) { //0~60\n var cStr = str.toString(); \n if (cStr.length < 2) {\n str = 0 + cStr;\n }\n return str;\n}", "title": "" }, { "docid": "fb6598b20a993e7e9c8d9525210110e0", "score": "0.6108505", "text": "function strip0x (input) {\n return input.replace(/^0x/, '')\n}", "title": "" }, { "docid": "4fc5d7ad286e3211e9232f6a61f2ad03", "score": "0.61072165", "text": "function padzeros(num) {\n\tvar s = \"000000\" + num;\n return s.substr(s.length-6);\n}", "title": "" }, { "docid": "aa6647ebfe3f6f6fba681067a26d3de6", "score": "0.61038566", "text": "function stripTelephoneFormatting(phoneNumber) {\n return phoneNumber.replace(/[^0-9]/g, '').substring(0, 10);\n}", "title": "" }, { "docid": "0b5023a01d9ae9c8d686882264f6628c", "score": "0.6102384", "text": "function darFormatoSoloNumeros(idCampo) {\n $('#' + idCampo).on('input', function () {\n this.value = this.value.replace(/[^0-9]/g, '');\n });\n}", "title": "" }, { "docid": "fcc3b7146da7ad773ef1e2a12c7c1bf5", "score": "0.60993916", "text": "function numberCleaner(input) {\n var validNum = /[^0-9] -\\.()/;\n\n}", "title": "" }, { "docid": "ae55d841bcf80b9af0d4cf81a9d8ccfe", "score": "0.60968196", "text": "function digitsOnly(str) {\n\t\tstr = str.replace(/[^0-9]/g, '');\n\t\tif (str[0] === '1') {\n\t\t\tstr = str.substring(1);\n\t\t}\n\t\treturn str;\n\t}", "title": "" }, { "docid": "493cf04f94ced5dcd9af658aa0f15692", "score": "0.6093058", "text": "function unusedDigits () {\n\t\n\tvar str = Array.prototype.slice.call(arguments).toString();\n\tconsole.log(str, 'str');\n\tvar digits = [0,1,2,3,4,5,6,7,8,9];\n\t\n\tfor(var i = 0; i < str.length; i++){\n\t\tif(digits.indexOf(str[i])){\n\t\t\tdigits[digits.indexOf(+str[i])] = undefined;\n\t\t}\n\t}\n\t\n\tconsole.log(digits);\n \n return digits.filter(function(val){\n\t\t\t{ return val || val === 0; }\n\t}).join('');\n \n}", "title": "" }, { "docid": "90bddda01e76bbabeafa3b807c40cc3b", "score": "0.6084468", "text": "function zeros(val) {\r\n if (/^-*0+$/.test(val.toString())) {\r\n return '0';\r\n }\r\n return val;\r\n}", "title": "" }, { "docid": "aa16562d18411105d250a132556a21a7", "score": "0.60838455", "text": "function forceInt( Text, leftZeros )\r\n{\r\n Text += '';\r\n\tleftZeros = (leftZeros == undefined) ? false : leftZeros;\r\n\r\n\tNumbers = \"1234567890\\n\";\r\n\tNewText = \"\";\r\n\tfor( i = 0 ; i < Text.length ; i++ ){\r\n\t\tif( Numbers.indexOf( Text.charAt(i) ) != -1 ){\r\n\t\t\tNewText += Text.charAt(i);\r\n\t\t}\r\n\t}\r\n\tif (NewText == \"\"){\r\n\t\treturn \"\";\r\n\t}\r\n\r\n\tif(!leftZeros){\r\n\t\t// a base tem de ser forcada para 10\r\n\t\t// porque o default ? base 8 caso NewText comece com 0\r\n\t\tNewText = parseInt(NewText,10);\r\n\t}\r\n\r\n\treturn( NewText );\r\n}", "title": "" }, { "docid": "aa16562d18411105d250a132556a21a7", "score": "0.60838455", "text": "function forceInt( Text, leftZeros )\r\n{\r\n Text += '';\r\n\tleftZeros = (leftZeros == undefined) ? false : leftZeros;\r\n\r\n\tNumbers = \"1234567890\\n\";\r\n\tNewText = \"\";\r\n\tfor( i = 0 ; i < Text.length ; i++ ){\r\n\t\tif( Numbers.indexOf( Text.charAt(i) ) != -1 ){\r\n\t\t\tNewText += Text.charAt(i);\r\n\t\t}\r\n\t}\r\n\tif (NewText == \"\"){\r\n\t\treturn \"\";\r\n\t}\r\n\r\n\tif(!leftZeros){\r\n\t\t// a base tem de ser forcada para 10\r\n\t\t// porque o default ? base 8 caso NewText comece com 0\r\n\t\tNewText = parseInt(NewText,10);\r\n\t}\r\n\r\n\treturn( NewText );\r\n}", "title": "" }, { "docid": "018933983b7e7bb29964c164d7e6e900", "score": "0.60783875", "text": "function leadingZero(time) {\n if (time <= 9) {\n time = \"0\" + time\n }\n return time\n}", "title": "" }, { "docid": "5e42b1910d047ce3d3a38c9e254e125e", "score": "0.6071697", "text": "function zeroPad ( num, digit ){\n var tmp = num.toString();\n while (tmp.length < digit) { tmp = \"0\" + tmp;}\n return tmp;\n}", "title": "" }, { "docid": "108250e3c41cfffc1cf6ae4c6d6a29ef", "score": "0.60674036", "text": "function leadingZero(time) {\n if (time <= 9) {\n time = \"0\" + time\n }\n\n return time\n}", "title": "" }, { "docid": "2cf8af260ef296cbe488e64a93e212ef", "score": "0.6062495", "text": "function leadingZero(time) {\n if (time <= 9) {\n time = \"0\" + time;\n }\n return time;\n}", "title": "" }, { "docid": "54b9be3d1293653c5dfa1f729154fd0c", "score": "0.60605097", "text": "number(s) {\n\t\tlet n = s.toString();\n\t\tlet reg = /\\D/g;\n\t\tlet v = n.replace(reg, '');\n\n\t\treturn v;\n\t}", "title": "" }, { "docid": "a3656d47e87dddba9257460d2825e981", "score": "0.6051288", "text": "function leadingZero(time){\n if(time <= 9){\n time = \"0\" + time;\n }\n return time;\n}", "title": "" }, { "docid": "6e42e809c4d68121f8cef45fa59b19fb", "score": "0.60510135", "text": "zeroPad(num) {\n if (num<10) { return \"0\"+num;}\n return num;\n }", "title": "" }, { "docid": "9808d3dfd16336f56e50692247d26421", "score": "0.6050559", "text": "function zeros(val) {\n\t if (/^-*0+$/.test(val.toString())) {\n\t return '0';\n\t }\n\t return val;\n\t}", "title": "" }, { "docid": "9808d3dfd16336f56e50692247d26421", "score": "0.6050559", "text": "function zeros(val) {\n\t if (/^-*0+$/.test(val.toString())) {\n\t return '0';\n\t }\n\t return val;\n\t}", "title": "" }, { "docid": "809e040062e0b6b69cadf574d7dea4f2", "score": "0.6049876", "text": "function leadingZero(time) {\n if (time <= 9) {\n time = \"0\" + time;\n }\n return time;\n}", "title": "" }, { "docid": "809e040062e0b6b69cadf574d7dea4f2", "score": "0.6049876", "text": "function leadingZero(time) {\n if (time <= 9) {\n time = \"0\" + time;\n }\n return time;\n}", "title": "" }, { "docid": "031af699286d536fa55503dbbfb1c793", "score": "0.6039212", "text": "function FFAjouteZeros(nombre,nb_digits)\r\n\t{\r\n\t\tvar ret=\"0000000000\"+nombre;\r\n\t\treturn ret.slice(-nb_digits);\r\n\t}", "title": "" }, { "docid": "81a817b11e89162018da5aebfaa90afb", "score": "0.60383767", "text": "function leadingZero(time) {\n if(time <= 9) {\n time = \"0\" + time;\n }\n return time;\n}", "title": "" }, { "docid": "5d04cbef9a863a43984d0eb8fece5564", "score": "0.60380137", "text": "function numHandler(numString) {\n var numArray = numString.split(\"\");\n for (var i = numString.length; i < MAX_DIGIT; i++) numArray.unshift(\"0\");\n return numArray.join(\"\");\n}", "title": "" }, { "docid": "81a95017922a1c05dce533d367a3eb83", "score": "0.60159945", "text": "function unformatNumber(pNum)\n{\n\treturn String(pNum).replace(/\\D/g, \"\");\n}", "title": "" }, { "docid": "a84f296019faf684ebfc95227cd5cc18", "score": "0.6015832", "text": "function add_prefix_zero (el) {\n el = el.toString();\n if (el && el < 10) {el = '0' + el;}\n return el;\n}", "title": "" }, { "docid": "0a27a5d5b316926cd0f4ba4c588882ab", "score": "0.60156316", "text": "function zeroFill( number, width )\n{\n width -= number.toString().length;\n if ( width > 0 )\n {\n return new Array( width + (/\\./.test( number ) ? 2 : 1) ).join( '0' ) + number;\n }\n return number + \"\"; // always return a string\n}", "title": "" }, { "docid": "0f1a9c5d28850cf0f8af003834a33cd0", "score": "0.60112447", "text": "function onlyNums(value = '') {\n return value.replace(/[^\\d]/g, '');\n}", "title": "" }, { "docid": "29aafeb7bbf638ea1b1b436645cba1f6", "score": "0.6006363", "text": "getNumeric (s) {\n return s.replace(/\\D/g, '');\n }", "title": "" }, { "docid": "336495214b391234df04f81238831d04", "score": "0.6005243", "text": "function digitPadding(num){\n return (\"0\" + num).slice(-2);\n}", "title": "" }, { "docid": "5ab29a876f81720a2f456eba46e6194c", "score": "0.6000278", "text": "function zeroPad(n, digits) {\n\tn = n.toString();\n\twhile (n.length < digits) {\n\t\tn = '0' + n;\n\t}\n\treturn n;\n}", "title": "" }, { "docid": "b4a7533b6684d7c6bcd1e95734c3b03e", "score": "0.59925896", "text": "function zeroFill( number, width ) {\n width -= number.toString().length;\n if ( width > 0 ) {\n return new Array( width + (/\\./.test( number ) ? 2 : 1) ).join( '0' ) + number;\n }\n return number + \"\"; // always return a string\n }", "title": "" }, { "docid": "7b9851f255a14956491a34db17dac8a1", "score": "0.5991309", "text": "function preserveZerosNF(val)\n{\n var i;\n\n // make a string - to preserve the zeros at the end\n val = val + '';\n if (this.places <= 0) return val; // leave now. no zeros are necessary - v1.0.1 less than or equal\n\n var decimalPos = val.indexOf('.');\n if (decimalPos == -1)\n {\n val += '.';\n for (i=0; i<this.places; i++)\n {\n val += '0';\n }\n }\n else\n {\n var actualDecimals = (val.length - 1) - decimalPos;\n var difference = this.places - actualDecimals;\n for (i=0; i<difference; i++)\n {\n val += '0';\n }\n }\n\n return val;\n}", "title": "" }, { "docid": "9d177fe843382f94d7cb612e0c6ef271", "score": "0.59911007", "text": "function zeroPrefixer(num) {\n return (num < 10 ? '0' : '') + num;\n}", "title": "" }, { "docid": "901507ff9cfe3aaa979b4a4bc49d1b2f", "score": "0.59878486", "text": "function onlyDigit(obj) {\n reg = /[^0-9]/g;\n obj.value = obj.value.replace(reg, \"\");\n}", "title": "" }, { "docid": "38e0ccfe2979d8a7f6d98569563b424f", "score": "0.5973339", "text": "function stringToZero(text){\n text=(text+\"\").trim();\n if(text==\"\"){\n text=0;\n }\n return text;\n}", "title": "" }, { "docid": "3264219892e4ec3d52745676c5920a7d", "score": "0.5969464", "text": "function padZero(num) {\n return ('0' + num).slice(-2);\n }", "title": "" }, { "docid": "ffd21452f2889d04a7527c4b3dbe57ec", "score": "0.5952047", "text": "function RemoveSpace(Num)\n{\n\tvar Val = \"\"\n\n\tfor (var i=0;i<Num.toString().length;i++)\n\t{\n\t\tif (Num.charAt(i) != \" \")\n\t\t\tVal += Num.charAt(i)\n\t}\n\tif (Val == \"\") Val = 0\n\n\tvar retVal = parseInt(Val,10)\n\n\tif (isNaN(retVal))\n\t\treturn Num\n\telse\n\t\treturn parseInt(Val,10)\n}", "title": "" }, { "docid": "7e52f5718d5d452f8a0cec995ce9c695", "score": "0.5938565", "text": "function zeroFill( number, width ) {\n\t\twidth -= number.toString().length;\n\t\tif ( width > 0 ) {\n\t\t\treturn new Array( width + (/\\./.test( number ) ? 2 : 1) ).join( '0' ) + number;\n\t\t}\n\t\treturn number;\n\t}", "title": "" }, { "docid": "0ad3fbbba1be5cc557f80079ba438777", "score": "0.5930238", "text": "function zeroPad(number, width){\n let num = String(number);\n while(num.length < width){\n num = \"0\" + num;\n }\n return num;\n}", "title": "" }, { "docid": "c8280e95fe3bcfd9f589456d9528a561", "score": "0.5929827", "text": "function trimNulls(str) {\n return str.replace(/\\0/g, '');\n}", "title": "" }, { "docid": "9e0567706a5f2ea837d2369ee8801b30", "score": "0.5921996", "text": "function addPrefixZero(num){\n if(num<10){\n return \"0\"+num;\n }\n return num;\n}", "title": "" }, { "docid": "6c769927cd5fd468d354722714f0f42a", "score": "0.59197015", "text": "function zeroPad(input) {\n\tif (input < 10) {\n\t\tinput = \"0\" + input\n\t}\n\treturn input\n}", "title": "" }, { "docid": "1c0dd43c51a03e3f5a831ef3e6999e6a", "score": "0.5910186", "text": "function zeroPadding(x) {\n return (x < 10) ? '0' + x : x;\n}", "title": "" }, { "docid": "7494aeb054913312c9f739f219518c26", "score": "0.5900998", "text": "function prependZero(num) {\n\treturn (num < 10) ? '0' + num : num; \n}", "title": "" }, { "docid": "ea6b7948941893de1c22fe7405d3262a", "score": "0.59007186", "text": "function get_string00(num) {\n\treturn (num === 0) ? num = \"00\" : num;\n}", "title": "" }, { "docid": "71f21f9b81d090b78b4120c4f729a46e", "score": "0.5892137", "text": "function addLeadingZero( n ){\r\n if( n < 10 ){\r\n return '0' + n;\r\n } else {\r\n return '' + n;\r\n }\r\n }", "title": "" }, { "docid": "a7622000697f963f5da9fbad6445be1c", "score": "0.58715695", "text": "function zeroFill(num) {\n return (num < 10 ? '0' : '') + num\n}", "title": "" }, { "docid": "fa6061a5e729b6f4a9beae35f1b8563d", "score": "0.5868298", "text": "function zeroLeftPad(num) {\n return (num<10) ? '0'+num : num;\n}", "title": "" }, { "docid": "fe41bb74821f0a0423e6aa4619ad7de6", "score": "0.58607155", "text": "function zeropad(s, length = 1) {\n s = String(s) || '';\n while (s.length < length) {\n s = '0' + s;\n }\n return s;\n}", "title": "" }, { "docid": "b6c11487c06e66e521d9d57b3ccbee95", "score": "0.58601576", "text": "function zeroPad (number, width) {\n let string = string(number)\n while (string.length < width) {\n string = \"0\" + string \n }\n return string \n }", "title": "" }, { "docid": "823b487a6bb4af0b6b6cf7a91828caf1", "score": "0.5856267", "text": "function fill_with_zeroes (str)\n\t\t\t{\n\t\t\t\twhile (str.length<(parseInt(centsLimit)+1)) str = '0'+str;\n\t\t\t\treturn str;\n\t\t\t}", "title": "" }, { "docid": "62bd7b35ed693d9c3451f34c4b9f132d", "score": "0.5846795", "text": "function strip(number) {\n var no = parseFloat(number).toPrecision(12)\n return (no * 1).toString();\n}", "title": "" }, { "docid": "d0fa32a8c6dcfeddf313b68df279c8ac", "score": "0.584493", "text": "function leadingZero(time) {\n if (time <= 9) { // if the counting digit equal to 9 or less then 9\n time = \"0\" + time; // put a zero if front of the variable time\n }\n return time; //return will stop the execution because the zero will be replace once the time it goes to 10 or higher)\n}", "title": "" }, { "docid": "d468f7ba9fef2b59f3e547376c5f7504", "score": "0.5838402", "text": "function zfill(num) {\n // jsperf indicates this is generally the fasted way to zfill\n // presumably because function calls are harder to optimize.\n while (num.length < 6) {\n num = '0' + num\n }\n return num\n}", "title": "" } ]
c2042c3917b66fbc7d0aabd44c5d9e96
HTMLMediaElement and HTMLVideoElement backported from Facebook's Jest project: They are not expected to be perfectly tospec, and PRs to improve them over time are certainly appreciated.
[ { "docid": "718c48cf0323d6c67127def34c7e1588", "score": "0.0", "text": "function getTimeRangeDummy() {\n return {\n length: 0,\n start: function() { return 0; },\n end: function() { return 0; }\n };\n}", "title": "" } ]
[ { "docid": "f96300ba49cf5f9ce075246a3bc25c9e", "score": "0.6211479", "text": "get _videoEl() {\n return videoEl\n }", "title": "" }, { "docid": "311c1a3255c769c1ef2173c489dd7fc7", "score": "0.61641663", "text": "function getVideo(weex) {\n var extractComponentStyle = weex.extractComponentStyle;\n var mapNativeEvents = weex.mapNativeEvents;\n var ref = weex.utils;\n var dispatchNativeEvent = ref.dispatchNativeEvent;\n\n return {\n name: 'weex-video',\n props: {\n src: String,\n playStatus: {\n type: String,\n default: 'pause',\n validator: function validator(value) {\n return ['play', 'pause'].indexOf(value) !== -1;\n }\n },\n autoplay: {\n type: [String, Boolean],\n default: false\n },\n autoPlay: {\n type: [String, Boolean],\n default: false\n },\n playsinline: {\n type: [String, Boolean],\n default: true\n },\n controls: {\n type: [String, Boolean],\n default: false\n }\n },\n\n render: function render(createElement) {\n if (this.playStatus === 'play') {\n this.$nextTick(function () {\n try {\n this.$el && this.$el.play();\n } catch (err) {\n dispatchNativeEvent(this && this.$el, 'error', {\n message: err.message\n });\n }\n });\n } else if (this.playStatus === 'pause') {\n this.$nextTick(function () {\n this.$el && this.$el.pause();\n });\n }\n\n return createElement('html:video', {\n attrs: {\n 'weex-type': 'video',\n autoplay: this.autoplay !== 'false' && this.autoplay !== false || this.autoPlay !== 'false' && this.autoPlay !== false,\n 'webkit-playsinline': this.playsinline,\n controls: this.controls,\n src: this.src\n },\n on: mapNativeEvents(this, {\n play: 'start',\n error: 'fail'\n }),\n staticClass: 'weex-video weex-el',\n staticStyle: extractComponentStyle(this)\n });\n }\n };\n }", "title": "" }, { "docid": "c91375c20e2de3081a644d1bf772f862", "score": "0.61593837", "text": "generateVideoPlayer(element) {\n element.appendChild(this.videoElement);\n }", "title": "" }, { "docid": "27c509ae4337eec27b9d0edf8622e2d3", "score": "0.6143995", "text": "initVideo() {\n this.video = document.createElement('video');\n this.video.id = 'video';\n this.containerElement.appendChild(this.video);\n\n // call startVideo() when the video can play\n this.video.addEventListener('canplay', () => {\n this.startVideo();\n });\n }", "title": "" }, { "docid": "2a01aea767c791ed0e0a6a79d1099f65", "score": "0.6127788", "text": "function supports_video() {\n return !!document.createElement('video').canPlayType;\n}", "title": "" }, { "docid": "2a01aea767c791ed0e0a6a79d1099f65", "score": "0.6127788", "text": "function supports_video() {\n return !!document.createElement('video').canPlayType;\n}", "title": "" }, { "docid": "891e7a0e056dcd623e72268c4cef5537", "score": "0.6069041", "text": "componentDidMount() {\n const isVideoSupported = !!document.createElement(\"video\").canPlayType;\n if (isVideoSupported) {\n this.videoRef.current.controls = false;\n this.setState({ videoSupported: true });\n }\n }", "title": "" }, { "docid": "7d462d147c1856750d213dd36daa4e13", "score": "0.6050954", "text": "createVideoElement(path, format){\n let videoDOM = document.createElement(\"video\");\n videoDOM.src = path;\n videoDOM.format = \"video/\" + format;\n return videoDOM;\n }", "title": "" }, { "docid": "d6637918df1ea52e6a8442564e91c2f4", "score": "0.6041982", "text": "function CanvasHackVideoElementWrapper(videoElement) {\n this._videoElement = videoElement;\n this._drawElement = document.createElement('canvas');\n}", "title": "" }, { "docid": "9877471da3b7ed7c019d7e4ca7fd737e", "score": "0.60111123", "text": "function supports_video() {\n return !!document.createElement('video').canPlayType && !oldIE;\n}", "title": "" }, { "docid": "ac31d25903ea7d58685b8d5619f73e8f", "score": "0.5977394", "text": "render() {\n return (\n <div>\n <div data-vjs-player>\n <video\n ref={node => this.videoNode = node}\n className=\"video-js vjs-big-play-centered\"\n ></video>\n </div>\n </div>\n )\n }", "title": "" }, { "docid": "e61aa262a3e240a16f1e72e15d285d8f", "score": "0.59685826", "text": "render() {\n return (\n <div data-vjs-player>\n <video\n ref={node => (this.videoNode = node)}\n className=\"video-js vjs-16-9 vjs-default-skin\"\n // controls={true}\n // autoPlay={true}\n >\n {/* <source src={this.props.src} type=\"video/mp4\" /> */}\n </video>\n </div>\n );\n }", "title": "" }, { "docid": "bc98f653c232c2d8a1717a858dda7a3f", "score": "0.59591705", "text": "function understandsVideo() {\n return !!document.createElement('video').canPlayType; // boolean\n}", "title": "" }, { "docid": "33d2f1c851ffe203cfa09ab29fb45757", "score": "0.59262204", "text": "render() {\n return (\n <div> \n <div data-vjs-player> {/*这个带有属性的div目前没看到作用,可以去掉*/}\n <video ref={ node => this.videoNode = node } className=\"video-js vjs-big-play-centered vjs-fluid \"></video>\n </div>\n </div>\n )\n }", "title": "" }, { "docid": "a645914c701af5e79abc71b71491c553", "score": "0.5877769", "text": "render() {\n return (\n <div id=\"videoContainer\" className=\"shakaContainer\" ref={this.videoContainer}>\n <video id=\"video\" ref={this.videoComponent} />\n </div>\n\n // <div id=\"videoContainer\" className=\"shakaContainer\" data-shaka-player-container data-shaka-player-cast-receiver-id=\"7B25EC44\" ref={this.videoContainer}>\n // <video id=\"video\" data-shaka-player autoPlay playsInline\n // ref={this.videoComponent} />\n // </div>\n )\n }", "title": "" }, { "docid": "3c89dfd3ff7009ec23880c56606f54e6", "score": "0.5867462", "text": "render() {\n return (\n <div className=\"container-player\">\n <div className=\"html5-video-player\">\n <div data-vjs-player className=\"html5-video-container video-js vjs-big-play-centered\">\n <a onClick={this._sendSideMenuToggleMsg} className=\"playlist-schedule\">Playlist</a>\n <a onClick={this._skipToNextVideo}><i className=\"fa fa-chevron-right fa-3x nextVideo\"></i></a>\n <video ref={ node => this.videoNode = node } className=\"\"></video>\n <a onClick={this._skipToPreviousVideo}><i className=\"fa fa-chevron-left fa-3x prevVideo\"></i></a>\n </div>\n </div>\n </div>\n )\n }", "title": "" }, { "docid": "409d74b7a842b353243dfcd20a7305d7", "score": "0.5852737", "text": "addVideo(src) {\n //TODO!\n }", "title": "" }, { "docid": "96aa0e1c55ec6e400271a531bb6defec", "score": "0.5845828", "text": "function UnitTestPlayer(video, testConfig) {\n this.video = video;\n this.testConfig = testConfig;\n}", "title": "" }, { "docid": "525af6d9fb0d068e6a62944d8f5c360f", "score": "0.5828418", "text": "function setupButtons(element) {\n var video = element.getElementsByTagName(\"video\")[0];\n var play = element.getElementsByClassName(\"play\")[0];\n var stop = element.getElementsByClassName(\"stop\")[0];\n var progressBar = element.getElementsByClassName(\"progress\")[0];\n var backward = element.getElementsByClassName(\"previous\")[0];\n var forward = element.getElementsByClassName(\"next\")[0];\n var fullscreen = element.getElementsByClassName(\"fullscreen\")[0];\n\n var videoPlay = function () {\n if (video.paused) {\n video.play();\n play.innerText = \"pause\"\n } else {\n video.pause();\n play.innerText = \"play_arrow\"\n }\n };\n\n play.onclick = videoPlay;\n video.onclick = videoPlay;\n video.onended = function () {\n play.innerText = \"play_arrow\";\n };\n\n stop.onclick = function () {\n video.pause();\n video.currentTime = 0;\n play.innerText = \"play_arrow\"\n };\n\n var timeSkip = function (operation) {\n var stamp = operation(video.currentTime, video.duration / 10);\n if (stamp < 0) {\n stamp = 0;\n } else if (stamp > video.duration) {\n stamp = video.duration;\n }\n video.currentTime = stamp;\n };\n\n backward.onclick = function () {\n timeSkip(function (left, right) {\n return left - right\n })\n };\n\n forward.onclick = function () {\n timeSkip(function (left, right) {\n return left + right\n })\n };\n\n fullscreen.onclick = function () {\n // a fall through method to try fullscreen in various browsers - note the capital S in moz/firefox.\n if (video.requestFullscreen) {\n video.requestFullscreen();\n } else if (video.mozRequestFullScreen) {\n video.mozRequestFullScreen();\n } else if (video.webkitRequestFullscreen) {\n video.webkitRequestFullscreen();\n } else if (video.msRequestFullscreen) {\n video.msRequestFullscreen();\n }\n };\n\n /* To justify myself, in case someone reads that:\n There is an ontimeupdate event, but it's restricted to update between 4hz to 66hz (sic!), based on the\n event loop timing of the DOM. In most browsers this sucks ass and looks super choppy. So, what do we do?\n We just update that every 33ms - which makes it look smooth.\n Probably could cause issues with too many video groups at once.\n */\n setInterval(function () {\n progressBar.style.width = video.currentTime / video.duration * 100 + \"%\";\n }, 33)\n }", "title": "" }, { "docid": "cbddb6af5041ceb232fa79d4203bb2e8", "score": "0.5819122", "text": "function testVideoRendering(ctx) {\n return testPixel(ctx, 18, 82, 255, 255, 255, 255, 64) &&\n testPixel(ctx, 50, 82, 0, 255, 0, 255, 64) &&\n testPixel(ctx, 18, 114, 0, 0, 255, 255, 64) &&\n testPixel(ctx, 50, 114, 255, 0, 0, 255, 64);\n}", "title": "" }, { "docid": "d51cf8be54ace57773d7a94fc5525221", "score": "0.5809406", "text": "installAutoplayElements_() {\n const {video} = this;\n const {element, win} = this.video;\n\n if (\n element.hasAttribute(VideoAttributes_Enum.NO_AUDIO) ||\n element.signals().get(VideoServiceSignals_Enum.USER_INTERACTED)\n ) {\n return;\n }\n\n const animation = renderIcon(win, element);\n const children = [animation];\n\n /** @param {boolean} shouldDisplay */\n function toggleElements(shouldDisplay) {\n video.mutateElementSkipRemeasure(() => {\n children.forEach((child) => {\n toggle(child, shouldDisplay);\n });\n });\n }\n\n /** @param {boolean} isPlaying */\n function toggleAnimation(isPlaying) {\n video.mutateElementSkipRemeasure(() =>\n animation.classList.toggle('amp-video-eq-play', isPlaying)\n );\n }\n\n const unlisteners = [\n listen(element, VideoEvents_Enum.PAUSE, () => toggleAnimation(false)),\n listen(element, VideoEvents_Enum.PLAYING, () => toggleAnimation(true)),\n listen(element, VideoEvents_Enum.AD_START, () => {\n toggleElements(false);\n video.showControls();\n }),\n listen(element, VideoEvents_Enum.AD_END, () => {\n toggleElements(true);\n video.hideControls();\n }),\n listen(element, VideoEvents_Enum.UNMUTED, () =>\n userInteractedWith(video)\n ),\n ];\n\n if (video.isInteractive()) {\n video.hideControls();\n\n const mask = renderInteractionOverlay(element, this.metadata_);\n children.push(mask);\n unlisteners.push(listen(mask, 'click', () => userInteractedWith(video)));\n }\n\n video.mutateElementSkipRemeasure(() => {\n children.forEach((child) => {\n element.appendChild(child);\n });\n });\n\n if (this.isRollingAd_) {\n toggleElements(false);\n }\n\n video\n .signals()\n .whenSignal(VideoServiceSignals_Enum.USER_INTERACTED)\n .then(() => {\n this.firstPlayEventOrNoop_();\n if (video.isInteractive()) {\n video.showControls();\n }\n video.unmute();\n unlisteners.forEach((unlistener) => {\n unlistener();\n });\n video.mutateElementSkipRemeasure(() => {\n children.forEach((child) => {\n removeElement(child);\n });\n });\n });\n }", "title": "" }, { "docid": "367aeca3e0648950c1b9df15b58d397b", "score": "0.5800884", "text": "function Video({videoSrc}) {\n // const videoDuration = () => {\n // }\n\n return (\n <>\n <div className=\"video-holder\">\n <iframe\n src={videoSrc.url}\n id=\"videos\"\n title={videoSrc.title}\n width=\"100%\"\n height=\"100%\"\n frameBorder=\"0\"\n duration=\"1\"\n />\n {/* <img src={videoSrc} className=\"video featured-video\" alt=\"\" /> */}\n {/* <PlayButton /> */}\n </div>\n </>\n )\n}", "title": "" }, { "docid": "21cea57445852387c89be23212c3d1d0", "score": "0.57895714", "text": "function createVideo() {\n const video = document.createElement(\"video\");\n video.setAttribute(\"id\", \"video\");\n getVideoWrapper().appendChild(video);\n\n}", "title": "" }, { "docid": "7cdecf32348a596e1df8419e6db82947", "score": "0.5784227", "text": "function getVideo(element) {\n\t\tvar videoElement = null;\n\n\t\tif (element.tagName === 'VIDEO') {\n\t\t\tvideoElement = element;\n\t\t}\n\t\telse {\n\t\t\tvar videos = element.getElementsByTagName('video');\n\t\t\tif (videos[0]) {\n\t\t\t\tvideoElement = videos[0];\n\t\t\t}\n\t\t}\n\n\t\treturn videoElement;\n\t}", "title": "" }, { "docid": "3276baa7fdf97cd961b9cc2761698bb9", "score": "0.5782333", "text": "function Player(video_element, media_source) {\n this.v = video_element;\n this.ms = media_source;\n this.v.startTime = 0;\n this.v.endTime = Infinity;\n this.active_set_id = -1;\n}", "title": "" }, { "docid": "f6a6cacce07ef27e7c818acafa35ecc7", "score": "0.5774672", "text": "function videoCheck() {\n\t return !!docment.createElement('video').canPlayType;\n}", "title": "" }, { "docid": "4f4f6fe6c882e1049a8b726eeb16d734", "score": "0.5766985", "text": "renderPlayerWithSRC() {\n const {\n sources,\n url,\n preload,\n poster,\n className,\n } = this.props;\n\n if (sources && Array.isArray(sources) && sources.length) {\n return this.renderPlayerWithSRCWithSources(sources);\n } else {\n return (\n <video\n className={className}\n src={url}\n preload={preload}\n poster={poster}\n />\n );\n }\n }", "title": "" }, { "docid": "f61e2de560e63c7d78cdc40e7f802854", "score": "0.575917", "text": "_createVideoElem(container)\n\t{\n\t\tlet newElem = $(document.createElement('video')).attr('playsinline', '').attr('muted', '')[0];\n\t\tcontainer.append(newElem);\n\t\treturn newElem;\n\t}", "title": "" }, { "docid": "ccc7ddfccb4038f0acae5c7f790aa8ca", "score": "0.57538515", "text": "async function selectMediaStream() {\r\n try {\r\n const mediaStream = await navigator.mediaDevices.getDisplayMedia();\r\n videoElement.srcObject = mediaStream;\r\n videoElement.onloadedmetadata = () => {\r\n videoElement.play();\r\n }\r\n } catch (error) {\r\n // Cath the errors here\r\n console.log('whoops, do you even know how to code?', error);\r\n }\r\n}", "title": "" }, { "docid": "2f39861f8d7be764bb824e79dd504f99", "score": "0.5748873", "text": "render() {\n return (\n <div data-vjs-player>\n <video ref={node => this.videoNode = node} className=\"video-js vjs-default-skin\" controls />\n </div>\n );\n }", "title": "" }, { "docid": "74a66dfdd45a0576528b1c7b68cd589f", "score": "0.5743603", "text": "function Video() {\n return (\n <div className=\"video\">\n {/* <video loop autoplay='' muted src=\"https://youtu.be/inpok4MKVLM\"></video> */}\n {/* <ReactPlayer className='video-player' url=\"https://www.youtube.com/watch?v=O3ioZz_Vsug\"/> */}\n <ReactPlayer className='video-player' url=\"https://vimeo.com/243556536\"/>\n </div>\n )\n}", "title": "" }, { "docid": "88d2f6eecb78a0b09ef50de866ffcdf4", "score": "0.5743563", "text": "playVideo(){\n this.scheduleHideControls();\n this.videoElement.current.play();\n }", "title": "" }, { "docid": "a732b37fe35b4dfdf9055e4bb5c65763", "score": "0.5723709", "text": "function clickVideo(el){\n if( (' ' + el.className + ' ').indexOf(' playing ') > -1){\n el.className = el.className.replace( /(?:^|\\s)playing(?!\\S)/g , '' );\n var video = el.getElementsByTagName('video')[0];\n video.setAttribute(\"src\",\"\");\n video.pause();\n while (video.firstChild) {\n video.removeChild(video.firstChild);\n }\n } else {\n el.className += \" playing\";\n var source = document.createElement('source');\n source.src = el.getAttribute('data-src');\n source.type = \"video/mp4\";\n el.getElementsByTagName('video')[0].setAttribute(\"src\", el.getAttribute('data-src'));\n el.getElementsByTagName('video')[0].appendChild(source);\n el.getElementsByTagName('video')[0].play();\n\n if(el.hasAttribute('data-threadid')){\n listThreadId.push(el.getAttribute('data-threadid'));\n el.removeAttribute('data-threadid');\n updateView();\n }\n }\n}", "title": "" }, { "docid": "6fc12f9605e7fbbdf0f0513a3bc57013", "score": "0.57055", "text": "async function selectMediaStream() {\n try {\n const mediaStrean = await navigator.mediaDevices.getDisplayMedia();\n videoElem.srcObject = mediaStrean;\n videoElem.onloadedmetadata = () => {\n videoElem.play();\n }\n } catch (error) {\n console.log('Something went wrong', error);\n }\n}", "title": "" }, { "docid": "c35a1c6e404ec5f6b9a0bc2d414e38c9", "score": "0.57007265", "text": "function createVideoElement(container, mediaStream, muted=false) {\r\n const videoElement = document.createElement('video')\r\n videoElement.autoplay = true\r\n videoElement.srcObject = mediaStream\r\n videoElement.muted = muted\r\n container.appendChild(videoElement)\r\n return videoElement\r\n}", "title": "" }, { "docid": "36509f0619e596719463fd80a94e10bf", "score": "0.5697769", "text": "attachMediaElement(media) {\n this.detachMedia();\n this.mediaElement = media;\n }", "title": "" }, { "docid": "b7215fccc67d3c75846df7e11d75a65d", "score": "0.5679849", "text": "function pannellumVideoElem(videoUri) {\n var videoElem = document.createElement(\"video\");\n videoElem.setAttribute(\"id\", VIDEOID);\n videoElem.setAttribute(\"class\", \"video-js vjs-default-skin vjs-big-play-centered\");\n videoElem.setAttribute(\"controls\", \"\");\n videoElem.setAttribute(\"preload\", \"none\");\n videoElem.setAttribute(\"style\", \"width:100%;height:400px;\");\n // This is if we have somekind of a background photo (we don't)\n //videoElem.setAttribute(\"poster\", \"none\");\n videoElem.setAttribute(\"crossorigin\", \"anonymous\");\n\n var videoSrc = document.createElement(\"source\");\n videoSrc.setAttribute(\"src\", videoUri);\n\n videoElem.appendChild(videoSrc);\n\n return videoElem;\n}", "title": "" }, { "docid": "e95df3139e34bb000cfcaaa03fd9edf6", "score": "0.56638986", "text": "async function selectMediaStream() { // this function will prompt user to select video source then play it\r\n try {\r\n const mediaStream = await navigator.mediaDevices.getDisplayMedia(); // mediaStream will be assigned which window or screen the user will select to share\r\n videoElement.srcObject = mediaStream; // the mediaSteam will then be passed onto the videoElement as its source object\r\n videoElement.onloadedmetadata = () => { // then when the video has loaded its metadata, it will call a function that will play the video (next line)\r\n videoElement.play();\r\n }\r\n } catch (error) {\r\n // Catch Error Here\r\n console.log('Select media stream error:', error); \r\n }\r\n}", "title": "" }, { "docid": "152e2132e0f1cf4995b255a9ba595b0a", "score": "0.565531", "text": "async function selectMediaStream() {\n try {\n const mediaStream = await navigator.mediaDevices.getDisplayMedia()\n videoElement.srcObject = mediaStream\n \n videoElement.onloadedmetadata = () => {\n videoElement.play()\n }\n\n \n\n } catch (error) {\n //Catch errors\n console.log(error)\n }\n}", "title": "" }, { "docid": "1a8ef62699a3d6fc7f3c18746b37307b", "score": "0.56513524", "text": "createHTMLVideo() {\n let myVidFrame = document.createElement('iframe');\n let vidDiv = document.createElement('div');\n let dragIcon = document.createElement('icon');\n vidDiv.className = \"vidDiv\"\n dragIcon.className = \"fas fa-arrows-alt\";\n\n myVidFrame.src = this.content;\n myVidFrame.frameborder = \"0\";\n myVidFrame.className = \"vidElement\";\n myVidFrame.allow = 'encrypted-media, autoplay';\n myVidFrame.setAttribute('allowFullScreen', '');\n\n vidDiv.appendChild(myVidFrame);\n vidDiv.appendChild(dragIcon);\n return vidDiv;\n\n //https://www.youtube.com/embed/xbhCPt6PZIU works\n //https://www.youtube.com/embed/dmKeIlJq4gM doesn't\n }", "title": "" }, { "docid": "b95d8a2ce9ef3cf820babdf8d294cd20", "score": "0.5640285", "text": "render() {\n let className = \"video-js\"\n // if (!this.props.show) {\n // className += \" hide-player\"\n // }\n return (\n // <div>\n <div data-vjs-player>\n <video ref={node => (this.videoNode = node)} className={className} />\n </div>\n // </div>\n )\n }", "title": "" }, { "docid": "7985ea577f05b3d9a6ef793e4d48505d", "score": "0.56307185", "text": "function clickVideo(e){if(-1<(\" \"+e.className+\" \").indexOf(\" playing \")){e.className=e.className.replace(/(?:^|\\s)playing(?!\\S)/g,\"\");var t=e.getElementsByTagName(\"video\")[0];for(t.setAttribute(\"src\",\"\"),t.pause();t.firstChild;)t.removeChild(t.firstChild)}else{e.className+=\" playing\";var s=document.createElement(\"source\");s.src=e.getAttribute(\"data-src\"),s.type=\"video/mp4\",e.getElementsByTagName(\"video\")[0].setAttribute(\"src\",e.getAttribute(\"data-src\")),e.getElementsByTagName(\"video\")[0].appendChild(s),e.getElementsByTagName(\"video\")[0].play(),e.hasAttribute(\"data-threadid\")&&(listThreadId.push(e.getAttribute(\"data-threadid\")),e.removeAttribute(\"data-threadid\"),updateView())}}", "title": "" }, { "docid": "6bf46247609e8de8eb17715f07b0f270", "score": "0.5626161", "text": "function getVideoElement(){\n\t\n\t\tvar video_ele = document.getElementsByTagName('video');\n\t\tfor(var ele of video_ele){\n\t\t\t\tele.addEventListener('mouseenter',addBorder);\n\t\t\t\tele.addEventListener('mouseleave',removeBorder)\n\t\t}\n\t\tif(video_ele.length !== 0){\n\t\t\ttextNode.textContent = 'Select the video player (just click on the player)';\n\t\t\tdocument.addEventListener('click',getClickedElement);\n\t\t}else{\n\t\t\ttextNode.textContent = '!!! No video Element Found';\n\t\t}\n}", "title": "" }, { "docid": "0e277e6e72e54db2ac9ae18521c6e153", "score": "0.55813384", "text": "function initializeDOM() {\n videoElement = document.querySelector('video');\n videoTitle = document.querySelector('h1.video-title');\n videoDescription = document.querySelector('h3.video-description');\n thumbnailElements = document.querySelectorAll('div.thumbnails');\n body = document.querySelector('body');\n // set up video thumbnails\n let initialThumbImgClasses = thumbnailElements[0]\n .querySelector('img').classList;\n initialThumbImgClasses.add('current-video');\n for (let i = 0; i < thumbnailElements.length; i++) {\n let imgElement = thumbnailElements[i].querySelector('img');\n imgElement.src = content.thumbnailUrls[i];\n imgElement.addEventListener('click', (event) => {\n event.preventDefault();\n body.scrollTop = 0;\n playSpecificVideo(i);\n });\n let imgTitle = thumbnailElements[i].querySelector('h4');\n imgTitle.innerHTML = content.data[i]['title'];\n }\n // set up video element\n videoElement.src = content.videoUrls[0];\n videoElement.poster = content.thumbnailUrls[0];\n content.currentVideo = 0;\n videoElement.addEventListener('ended', (event) => {\n event.preventDefault();\n playNextVideo();\n });\n // set up video info section\n videoTitle.innerHTML = content.data[0]['title'];\n videoDescription.innerHTML = content.data[0]['summary'];\n}", "title": "" }, { "docid": "b8a4df994bb1c4ac33d6390eb507bfa2", "score": "0.5581085", "text": "prepareVideoElement(){\n\t\tthis.applyDefaultClasses();\n\t\tthis.applyParameters();\n\n\t\tif(this.util.isYoutubePlayer(this.videoelement)){\n\t\t\tthis.applyYoutubeClasses();\n\t\t}\n\n\t\telse if(this.util.isVimeoPlayer(this.videoelement)){\n\t\t\tthis.applyVimeoClasses();\n\t\t}\n\t}", "title": "" }, { "docid": "9ebc2d4ec372f350c8410567c386285e", "score": "0.55805004", "text": "function MediaContext () {\n this.element = void 0;\n this.elIdx = 0;\n\n /**\n * parses the URL String and returns an object containing useful path items\n */\n this.getUri = function ( href ){\n var l = document.createElement(\"a\");\n l.href = href;\n return l;\n };\n\n /**\n * get media file extension\n */\n this.fileType = function ( src ){\n var ytRE = new RegExp(\"ytimg\");\n // var t = /.+\\.([^?]+)(\\?|$)/; //old\n var t = /.+\\.([^?]+)/;\n // check if is youtube thumb, if so, return video type\n if(ytRE.test(src)){\n return \"youtube\";\n }\n return src.match(t)[1];\n };\n\n /**\n * Pass in a dom element, get media type\n */\n this.getType = function ( elem ) {\n var _self = this;\n var _type = \"\", finalType, _file, _src;\n var providers = [\"youtube\",\"vimeo\",\"spotify\",\"soundcloud\"];\n var typeMap = {\n quote: \"link\",\n img: \"image\",\n jpg: \"image\",\n jpeg: \"image\",\n png: \"image\", \n gif: \"image\",\n webp: \"image\",\n youtube: \"video\",\n vimeo: \"video\",\n spotify: \"audio\",\n soundcloud: \"audio\"\n };\n\n elem = elem || this.element;\n _type = elem.nodeName;\n _src = elem.src;\n\n if(_type === \"IMG\"){\n _file = (elem.src) ? _self.fileType(elem.src) : \"img\";\n finalType = (_file !== \"img\") ? typeMap[_file] + \"/\" + _file : typeMap[_type];\n } else {\n var found;\n \n for (var i = providers.length - 1; i >= 0; i--) {\n var prI = providers[i];\n var pR = new RegExp( prI );\n \n found = pR.test( elem.src );\n \n if(found){\n _file = _src.match( pR )[0];\n break;\n }\n }\n \n finalType = (_file) ? typeMap[_file] + \"/\" + _file : typeMap[_type];\n }\n\n return (finalType) ? finalType.toLowerCase() : null;\n };\n\n /**\n * get the src and url correctly for media types other than image\n */\n this.getMediaSrcUrl = function ( data, type ){\n // setup correct src and url structure based on type\n // - video sources will be video ID\n var specialType = (type) ? type.split(\"/\")[1] : type;\n var src, url;\n\n // setup formatting for each type\n switch (specialType){\n case \"youtube\":\n src = MediaFormat().getYoutubeID( data.src );\n url = MediaFormat().getYoutubeUrl( src );\n break;\n case \"vimeo\":\n src = MediaFormat().getVimeoID( data.src );\n url = MediaFormat().getVimeoUrl( src );\n break;\n case \"spotify\":\n src = MediaFormat().getSpotifyID( data.src );\n url = MediaFormat().getSpotifyUrl( src );\n break;\n case \"soundcloud\":\n src = MediaFormat().getSoundcloudID( data.src );\n url = MediaFormat().getSoundcloudUrl( src );\n break;\n }\n\n return {\n src: src,\n url: url\n };\n };\n}", "title": "" }, { "docid": "1e84263fca0b84e7e8c2ee7cd03d1c5e", "score": "0.5578245", "text": "function videos() {\n const extensions = ['mp4', 'webm']\n return function transformer(tree) {\n visit(tree, 'image', (node) => {\n if (extensions.some((ext) => node.url.endsWith(ext))) {\n node.type = 'html'\n node.value = `\n <video \n src=\"${node.url}\"\n autoplay\n muted\n playsinline\n loop\n title=\"${node.alt}\"\n />\n `\n }\n })\n }\n}", "title": "" }, { "docid": "f51c2d7d9860721e532b0b9be24b8ee7", "score": "0.55722636", "text": "function play_html5_video($element){\n $($element).get(0).play();\n }", "title": "" }, { "docid": "2c546c01e1084613b7c44777e2d0436a", "score": "0.55637234", "text": "function sbi_supports_video() {\r\n return !!document.createElement('video').canPlayType;\r\n }", "title": "" }, { "docid": "09d69967ee46dc0cda7b747173a19a73", "score": "0.5559279", "text": "function detectYtEmbed() {\n var frames = document.documentElement.getElementsByTagName('iframe');\n for (var i=0; i<frames.length; i++) {\n var isrc = frames[i].getAttribute('src');\n if (isrc.slice(0, 2) === '//') {\n isrc = \"http:\" + isrc\n }\n var data = new Object({'type':'iframe'});\n data.isrc = isrc;\n navigator.qt.postMessage(JSON.stringify(data));\n\n // Detect html5 video tags hidding in iframes. This only works for iframes from the same server\n var iframeDoc = (frames[i].contentWindow || frames[i].contentDocument);\n if (iframeDoc.document) iframeDoc = iframeDoc.document;\n var iframeVideoElement = iframeDoc.getElementsByTagName('video');\n for (var k=0; k<iframeVideoElement.length; k++) {\n var _ivonplaying = iframeVideoElement[k].onplaying;\n iframeVideoElement[k].onplaying = function () {\n _ivonplaying();\n // We need to unmute all with multiple elements\n for (var j=0; j<iframeVideoElement.length; j++) {\n iframeVideoElement[j].muted = false;\n }\n };\n if (iframeVideoElement[k].hasChildNodes()) {\n console.debug(\"Has children\");\n var children = iframeVideoElement[k].childNodes;\n for (var j = 0; j < children.length; j++) {\n if (children[j].tagName === 'SOURCE') {\n var data = new Object({'type': 'video'})\n if (children[j].hasAttribute('src')) data.video = getImgFullUri(children[j].getAttribute('src'));\n navigator.qt.postMessage( JSON.stringify(data) );\n continue;\n }\n }\n }\n else if (iframeVideoElement[k].hasAttribute('src')) {\n var data = new Object({'type': 'video'})\n data.video = getImgFullUri(iframeVideoElement[k].getAttribute('src'));\n navigator.qt.postMessage( JSON.stringify(data) );\n }\n }\n }\n\n // mobilegeeks.de uses this\n var frames = document.documentElement.getElementsByTagName('pagespeed_iframe');\n for (var i=0; i<frames.length; i++) {\n var isrc = frames[i].getAttribute('src');\n if (isrc.slice(0, 2) === '//') {\n isrc = \"http:\" + isrc\n }\n var data = new Object({'type':'iframe'});\n data.isrc = isrc;\n navigator.qt.postMessage(JSON.stringify(data));\n }\n}", "title": "" }, { "docid": "c8e72449d250657e578b7deb9f231f56", "score": "0.55573505", "text": "get getVideoConstraints() {\n return {\n audio: false,\n video: {\n width: { exact: 832 },\n height: { exact: 440 }\n }\n };\n }", "title": "" }, { "docid": "50ccaf1c3cc1b27715294910daccb478", "score": "0.5555966", "text": "async function stream() {\n\n try{\n const media = await navigator.mediaDevices.getDisplayMedia();\n videoElement.srcObject = media;\n videoElement.onloadedmetadata = () => {\n videoElement.play();\n }\n\n }catch (error){\n\n }\n}", "title": "" }, { "docid": "28e0c1a7cdeb0b4119cc25ded077aafb", "score": "0.55472994", "text": "async function selectMediaStream() {\n try {\n const mediaStream = await navigator.mediaDevices.getDisplayMedia();\n // videoElement.hidden = false // able the video\n // add the seleced media to the srcObject of the video\n videoElement.srcObject = mediaStream;\n \n videoElement.onloadedmetadata = ()=>{\n videoElement.play();\n }\n \n } catch (error) {\n console.log(\"whoooops a error here :\" + error)\n }\n}", "title": "" }, { "docid": "d850b348b4655236cfdb6c216d118d6e", "score": "0.5543862", "text": "async function selectMediaStream(){\n try{\n const mediaStream= await navigator.mediaDevices.getDisplayMedia();\n videoElement.srcObject = mediaStream\n videoElement.onloadedmetadata = ()=>{\n videoElement.play();\n }\n\n }catch (error){\n console.log('whoops, eror here , ', error)\n }\n\n}", "title": "" }, { "docid": "680ea6e1254f37c90436d5e74a1b8494", "score": "0.55435616", "text": "async function webRTC_playVideoFromCamera() {\n try {\n const constraints = { 'video': true, 'audio': true };\n const stream = await navigator.mediaDevices.getUserMedia(constraints);\n const videoElement = document.querySelector('video#localVideoPlayback');\n videoElement.srcObject = stream;\n\n //Adding to the peerconnection\n stream.getTracks().forEach(track => {\n peerConnection.addTrack(track, stream);\n });\n } catch (error) {\n console.error('Error opening video camera.', error);\n }\n}", "title": "" }, { "docid": "19924e9137eee027e918ea8f31861939", "score": "0.55417186", "text": "function video() {\n return (\n <div>\n \n </div>\n )\n}", "title": "" }, { "docid": "41200f97a8e73bfc0f86279d0eae9e93", "score": "0.5538147", "text": "function initializeDOMElements() {\n\t\n video = document.createElement('video');\n video.setAttribute('autoplay', true);\n video.style.display = 'none';\n \n rawCanvas = document.createElement('canvas');\n rawCanvas.setAttribute('id', 'rawCanvas');\n rawCanvas.setAttribute('width', mWidth);\n rawCanvas.setAttribute('height', mHeight);\n rawCanvas.style.display = SHOW_RAW ? 'block' : 'none';\n document.getElementById('canvasesdiv').appendChild(rawCanvas);\n rawContext = rawCanvas.getContext('2d');\n // mirror horizontally, so it acts like a reflection\n rawContext.translate(rawCanvas.width, 0);\n rawContext.scale(-1,1);\t\n \n shadowCanvas = document.getElementById('shadowCanvas');\n shadowCanvas.setAttribute('width', mWidth);\n shadowCanvas.setAttribute('height', mHeight);\n shadowCanvas.style.display = SHOW_SHADOW ? 'block' : 'none';\n document.getElementById('canvasesdiv').appendChild(shadowCanvas);\n shadowContext = shadowCanvas.getContext('2d');\n \n backgroundCanvas = document.getElementById('backgroundCanvas');\n backgroundCanvas.setAttribute('width', mWidth);\n backgroundCanvas.setAttribute('height', mHeight);\n backgroundCanvas.style.display = SHOW_SHADOW ? 'block' : 'none';\n backgroundContext = backgroundCanvas.getContext('2d');\n //console.log(testCanvas);\n //console.log(testContext);\n}", "title": "" }, { "docid": "bbc756190bcf7a53bb607ffd40ae6008", "score": "0.5537237", "text": "async function selectMediaStream(){\r\n try{\r\n const mediaStream = await navigator.mediaDevices.getDisplayMedia();\r\n videoElement.srcObject = mediaStream;\r\n videoElement.onloadedmetadata = () =>{\r\n videoElement.play();\r\n }\r\n }catch (error){\r\n console.log('error in selectMediaStream function -- ',error);\r\n }\r\n}", "title": "" }, { "docid": "cd33f6816222c2ae393c01174336d85c", "score": "0.55364835", "text": "function createVideoElement() {\n var video = document.createElement(\"video\");\n video.autoPlay = true;\n video.controls = true;\n video.classList.add(\"hidden\");\n return video;\n }", "title": "" }, { "docid": "8b5708b319ba670671093df67af98997", "score": "0.5529369", "text": "function getVideo(){\n // mediaDevices.getUserMedia() are the webAPI property which allows us to use media input mediastream and returns as a promises\nnavigator.mediaDevices.getUserMedia({video: true, audio: false})\n .then(localMediaStream => {\n console.log(localMediaStream);\n video.srcObject = localMediaStream; //localMediaStream is an object and it doesnt work automatically, \n //and we have to convert it to url, and finally we play it;\n video.play();\n })\n .catch(err=>{ // we catch any error to handle that error\n console.error('OH NO!!!', err);\n })\n}", "title": "" }, { "docid": "ef52efe0ed3f2deb4a4164e23fa7c9d9", "score": "0.5528095", "text": "function htmlFromEl(el) {\n let textValue = el.innerText.trim();\n // test if this is a stand alone, valid URL\n if (validURL(textValue) && (\n textValue.includes('youtube.com') ||\n textValue.includes('youtu.be') ||\n textValue.includes('youtube-nocookie.com') ||\n textValue.includes('vimeo.com') ||\n textValue.toLowerCase().includes('.mp4')\n )\n ) {\n return `<video-player source=\"${textValue}\"></video-player>`;\n }\n // image\n else if (validURL(textValue) && (\n textValue.toLowerCase().includes('.jpg') ||\n textValue.toLowerCase().includes('.jpeg') ||\n textValue.toLowerCase().includes('.png') ||\n textValue.toLowerCase().includes('.webp')\n )\n ) {\n return `<img src=\"${textValue}\" loading=\"lazy\" decoding=\"async\" fetchpriority=\"high\" alt=\"\" />`;\n }\n // gif\n else if (validURL(textValue) && textValue.toLowerCase().includes('.gif')) {\n return `\n <a11y-gif-player src=\"${textValue}\" style=\"width: 300px;\">\n <simple-img width=\"300\" src=\"${textValue}\"></simple-img>\n </a11y-gif-player>`;\n }\n // test for a common convention for a place holder\n else if (textValue.startsWith('[') && textValue.endsWith(']')) {\n let tmp = textValue.split(':');\n // test for a type definition vs just rendering a basic textual one\n if (tmp.length > 1) {\n let type = tmp.shift().replace('[','');\n let text = tmp.join(':').replace(']','').trim();\n // we only support these types, if it is not one of these then we test other\n // things and could ultimately end on a less specific placeholder\n // I don't trust spelling things :p\n switch(type) {\n case 'math':\n case 'mathjax':\n return `<lrn-math>${text}</lrn-math>`;\n break;\n case 'video':\n case 'audio':\n case 'document':\n case 'text':\n case 'image':\n return `<place-holder type=\"${type}\" text=\"${text}\"></place-holder>`;\n break;\n }\n }\n // see if maybe they put placeholder brackets on the material\n textValue = textValue.replace('[','').replace(']','').trim();\n // video test\n if (validURL(textValue) && (\n textValue.includes('youtube.com') ||\n textValue.includes('youtu.be') ||\n textValue.includes('youtube-nocookie.com') ||\n textValue.includes('vimeo.com') ||\n textValue.includes('twitch.tv') ||\n textValue.toLowerCase().includes('.mp4')\n )\n ) {\n return `<video-player source=\"${textValue}\"></video-player>`;\n }\n // image test\n else if (validURL(textValue) && (\n textValue.toLowerCase().includes('.jpg') ||\n textValue.toLowerCase().includes('.jpeg') ||\n textValue.toLowerCase().includes('.png') ||\n textValue.toLowerCase().includes('.webp')\n )\n ) {\n return `<img src=\"${textValue}\" loading=\"lazy\" decoding=\"async\" fetchpriority=\"high\" alt=\"\" />`;\n }\n // gif test\n else if (validURL(textValue) && textValue.toLowerCase().includes('.gif')) {\n return `\n <a11y-gif-player src=\"${textValue}\" style=\"width: 300px;\">\n <simple-img width=\"300\" src=\"${textValue}\"></simple-img>\n </a11y-gif-player>`;\n }\n // just use a place holder tag since we don't know or they just wanted a note\n // for a resource they don't have yet\n else {\n return `<place-holder type=\"text\" text=\"${textValue}\"></place-holder>`; \n }\n }\n // test for ! which implies a specififc tag is going to be inserted\n // this is basically just for developers\n else if (textValue.startsWith('!') && textValue.includes('-')) {\n let tag = textValue.replace('!', '').trim();\n return `<${tag}></${tag}>`;\n }\n // allow for inline math replacement\n let content = el.outerHTML.replace(/\\t/g, '').trim().replace(/\\[math:(.*?)\\]/g,'<lrn-math>$1</lrn-math>');\n return content;\n}", "title": "" }, { "docid": "b9ce37f4680b9d1e9f2ea88cec8f2801", "score": "0.5524097", "text": "function createVideoElement(divElement,stream){\n\tconsole.log('creating a video element to display peer video');\n\tconsole.log('div element id :'+divElement.id);\n\tvar remoteVideo = document.createElement('video');\n\tremoteVideo.width = 320;\n\tremoteVideo.height = 240;\n\tremoteVideo.autoplay = true;\n\tremoteVideo.src = window.URL.createObjectURL(stream);\n\t//remoteStream = stream;\n\tdivElement.appendChild(remoteVideo);\n}", "title": "" }, { "docid": "0f510e99ecad6d3fb0db38da4b707023", "score": "0.5520887", "text": "function removeIE9VideoShim(picture) {\n var videos = collectionToArray(picture.getElementsByTagName('video'));\n videos.forEach(function(video) {\n var vsources = video.getElementsByTagName('source');\n while (vsources.length) {\n picture.insertBefore(vsources[ 0 ], video);\n }\n video.parentNode.removeChild(video);\n });\n}", "title": "" }, { "docid": "d15dd93f0833dd1af973f5eadbf9bb84", "score": "0.55144125", "text": "displayMedia(elem) {\n let factory = null;\n if (elem.hasOwnProperty(\"image\")) {\n factory = new ImgFactory();\n } else if (elem.hasOwnProperty(\"video\")) {\n factory = new VideoFactory();\n }\n return factory.createElement(elem);\n }", "title": "" }, { "docid": "a26a8dd5f930c88d0014d63345aacb5a", "score": "0.55086803", "text": "async video(element, run = true, delay = 0) {\n if (run) {\n if (!__privateGet(this, _loops)[element.id]) {\n if (this.config.debug)\n log(\"video start\", element.id);\n __privateGet(this, _loops)[element.id] = true;\n }\n if (!element.paused && __privateGet(this, _loops)[element.id] && element.readyState >= 2)\n await this.detect(element);\n if (delay > 0)\n await this.sleep(delay);\n if (__privateGet(this, _loops)[element.id])\n requestAnimationFrame(() => this.video(element, run, delay));\n } else {\n if (this.config.debug)\n log(\"video stop\", element.id);\n __privateGet(this, _loops)[element.id] = false;\n }\n }", "title": "" }, { "docid": "c87804e6ec00e012bf551e82998c0713", "score": "0.5508004", "text": "clickCloseVideo() {\n return this\n .waitForElementVisible('@videoCloseBtn')\n .assert.visible('@videoCloseBtn')\n .click('@videoCloseBtn');\n }", "title": "" }, { "docid": "95973364491bf4b7231dec16d5b9f386", "score": "0.54993004", "text": "function pluginElement() {\n\n // Media Player Elements\n videoElement();\n function videoElement() {\n $('.video').mediaelementplayer({\n loop: true,\n enableKeyboard: false,\n iPadUseNativeControls: false,\n pauseOtherPlayers: false,\n iPhoneUseNativeControls: false,\n AndroidUseNativeControls: false,\n enableAutosize: true\n });\n $('.bg-video').mediaelementplayer({\n loop: true,\n enableKeyboard: false,\n iPadUseNativeControls: false,\n pauseOtherPlayers: false,\n iPhoneUseNativeControls: false,\n AndroidUseNativeControls: false,\n enableAutosize: true,\n alwaysShowControls: false,\n });\n\n $('.audio').mediaelementplayer({\n audioWidth: '100%',\n pauseOtherPlayers: false,\n });\n };\n\n // Responsive Media Elements\n $(\".video, .audio, .post-media, .post-media iframe\").fitVids();\n\n\n\n}", "title": "" }, { "docid": "67fda31cd03782520f639b5b6c533d7c", "score": "0.54862785", "text": "async function selectMediaStream() {\n const { video } = elements;\n try {\n const mediaStream = await navigator.mediaDevices.getDisplayMedia();\n video.srcObject = mediaStream;\n video.onloadedmetadata = () => {\n video.play();\n };\n } catch (err) {\n console.log(`Error: ${err}`);\n }\n}", "title": "" }, { "docid": "2d1eb350850c52f4985d7c24f99124b9", "score": "0.54698265", "text": "function playPauseHTMLVideos(HTMLVideo) {\n if ((HTMLVideo.hasAttribute(\"desktopVideo\") && window.innerWidth > 991)\n || (HTMLVideo.hasAttribute(\"tabVideo\") && window.innerWidth < 991 && window.innerWidth >575)\n || (HTMLVideo.hasAttribute(\"mobileVideo\") && window.innerWidth < 575)\n ) {\n if (HTMLVideo.getBoundingClientRect().top < 0 && HTMLVideo.paused === false) {\n HTMLVideo.pause();\n }\n else if (HTMLVideo.getBoundingClientRect().top >= 0 && HTMLVideo.paused === true) {\n HTMLVideo.play();\n }\n }\n}", "title": "" }, { "docid": "3bd4c6401c15cd92ac98ac69c2513f68", "score": "0.5454787", "text": "async function setupVideo() {\n if (!navigator.mediaDevices || !navigator.mediaDevices.getUserMedia) {\n throw new Error(\n 'Browser API navigator.mediaDevices.getUserMedia not available');\n }\n\n const video = document.getElementById('video');\n video.width = videoWidth;\n video.height = videoHeight;\n\n // const mobile = isMobile();\n // const stream = await navigator.mediaDevices.getUserMedia({\n // 'audio': false,\n // 'video': {\n // facingMode: 'user',\n // width: mobile ? undefined : videoWidth,\n // height: mobile ? undefined : videoHeight,\n // },\n // });\n\n const myMediaSource = new MediaSource();\n console.log(myMediaSource.readyState); // closed\n const url = URL.createObjectURL(myMediaSource);\n console.log(\"url initiated.\")\n\n // video.srcObject = stream;\n video.src = url;\n myMediaSource.addEventListener('sourceopen', function (_) {\n console.log(\"Source opened, can procede with adding video source\")\n\n const videoSourceBuffer = myMediaSource\n .addSourceBuffer('video/mp4; codecs=\"avc1.4D401F\"');\n fetch(\"dance3_frag_silent.mp4\").then(function (response) {\n // The data has to be a JavaScript ArrayBuffer\n console.log(\"video fetched\")\n videoSourceBuffer.addEventListener('updateend', function (_) {\n myMediaSource.endOfStream();\n //video.play();\n //console.log(mediaSource.readyState); // ended\n });\n return response.arrayBuffer();\n }).then(function (videoData) {\n videoSourceBuffer.appendBuffer(videoData);\n });\n })\n \n\n return new Promise((resolve) => {\n video.onloadedmetadata = () => {\n console.log(\"we resolved our request i.e. video is now loaded this async op is complete.\")\n resolve(video);\n };\n });\n}", "title": "" }, { "docid": "8a91f6f6685bbf13dec64e07d6f88b77", "score": "0.54527307", "text": "isComponent(el) {\n var result = \"\";\n if (el.tagName === \"VIDEO\") {\n result = { type: \"my-video\" };\n }\n return result;\n }", "title": "" }, { "docid": "c6c7421639e274d81912dc344501f17c", "score": "0.54478854", "text": "load() {\n notImplemented(\"HTMLMediaElement.prototype.load\", this._ownerDocument._defaultView);\n }", "title": "" }, { "docid": "3397c086bca6830cd84fe125f3fe47f8", "score": "0.5447645", "text": "function getVideo() {\n video = document.querySelector('video[src]');\n if (video) {\n video.onplay = () => {\n ws.send(JSON.stringify({\n operation: 'playpause',\n value: 'play'\n }));\n }\n video.onpause = () => {\n ws.send(JSON.stringify({\n operation: 'playpause',\n value: 'pause'\n }));\n }\n /*\n * When seek message is received - we remove the event listener from\n * the video then update the video time and then we add the event \n * listner back\n */\n video.oncanplay = (event) => {\n video.onseeked = (event) => {\n event.stopPropagation();\n event.preventDefault();\n ws.send(JSON.stringify({\n operation: 'seek',\n value: event['target']['currentTime']\n }));\n }\n }\n } else {\n console.error('Video not found in website');\n }\n}", "title": "" }, { "docid": "144a60194778d5d1909d74c8361b4c43", "score": "0.54361004", "text": "render() {\n // const {\n // data: {\n // url,\n // title\n // }\n // } = this.props;\n\n return (\n <div className=\"video-hldr\">\n <video src=\"http://v2v.cc/~j/theora_testsuite/320x240.ogg\" controls>\n Your browser does not support the <code>video</code> element.\n </video>\n </div>\n );\n }", "title": "" }, { "docid": "48c437deae68556ede5412743001b507", "score": "0.54353136", "text": "function fixUpMediaElement (mediaEl) {\n // Cross-origin.\n var newMediaEl = setCrossOrigin(mediaEl);\n\n // Plays inline for mobile.\n if (newMediaEl.tagName && newMediaEl.tagName.toLowerCase() === 'video') {\n newMediaEl.setAttribute('playsinline', '');\n newMediaEl.setAttribute('webkit-playsinline', '');\n }\n\n if (newMediaEl !== mediaEl) {\n mediaEl.parentNode.appendChild(newMediaEl);\n mediaEl.parentNode.removeChild(mediaEl);\n }\n return newMediaEl;\n}", "title": "" }, { "docid": "9c05835a2aa3ccea137bab5ff0acd91f", "score": "0.5434377", "text": "async function selectMediaStream(){\n try {\n const mediaStream = await navigator.mediaDevices.getDisplayMedia();\n //console.log(mediaStream);\n videoElement.srcObject = mediaStream;\n videoElement.onloadedmetadata = () => {\n videoElement.play();\n }\n \n\n }catch(error){\n\n console.log(\"error from SelectMediaStream\", error);\n\n }\n}", "title": "" }, { "docid": "b3615202958738c546e342cade4746a8", "score": "0.5420214", "text": "_getMediaStream(videoElem)\n\t{\n\t\tif (videoElem.captureStream) {\n\t\t\treturn videoElem.captureStream();\n\t\t}\n\t\telse if (videoElem.mozCaptureStream) {\n\t\t\treturn videoElem.mozCaptureStream();\n\t\t}\n\t\telse {\n\t\t\tthrow new Error('Stream capture is not supported!');\n\t\t}\n\t}", "title": "" }, { "docid": "df5289c40a13fddbd5a142a1a54f3265", "score": "0.541794", "text": "function videoSetup(){\n var queueCode = `\n var storedVideo = null;\n var possibleClasses = [\"vjs-tech\", \"jw-video jw-reset\", \"video-stream html5-main-video\"];\n for (var i = 0; i < possibleClasses.length; i++){\n try{\n var possibleClass = possibleClasses[i];\n document.getElementsByClassName(possibleClass)[0].className \n storedVideo = document.getElementsByClassName(possibleClass)[0];\n console.log(\"Found video from tag, it is now stored\");\n break;\n \n }catch (error2){\n }\n }\n\n if (!storedVideo){\n try{\n document.getElementsByTagName(\"video\")[0].ClassName;\n storedVideo = document.getElementsByTagName(\"video\")[0]\n console.log(\"Normal video found\");\n }catch(error){\n console.log(\"No video found\");\n }\n }\n\n if (storedVideo){\n storedVideo.onplay = function() {\n chrome.runtime.sendMessage(\"started\");\n }\n \n storedVideo.onpause = function() {\n chrome.runtime.sendMessage(\"paused\");\n }\n }\n `;\n\n chrome.tabs.query({active: true, currentWindow: true}, function(tabs) {\n chrome.tabs.executeScript(tabs[0].id, {code: queueCode});\n });\n\n}", "title": "" }, { "docid": "459f8f24d05e04a8184d52f959be11fe", "score": "0.5408355", "text": "_meReady (media, domNode) {\n\n\t\tconst\n\t\t\tt = this,\n\t\t\tautoplayAttr = domNode.getAttribute('autoplay'),\n\t\t\tautoplay = !(autoplayAttr === undefined || autoplayAttr === null || autoplayAttr === 'false'),\n\t\t\tisNative = media.rendererName !== null && /(native|html5)/i.test(t.media.rendererName)\n\t\t;\n\n\t\tif (t.controls) {\n\t\t\tt.enableControls();\n\t\t}\n\n\t\tif (t.container.querySelector(`.${t.options.classPrefix}overlay-play`)) {\n\t\t\tt.container.querySelector(`.${t.options.classPrefix}overlay-play`).style.display = '';\n\t\t}\n\n\t\t// make sure it can't create itself again if a plugin reloads\n\t\tif (t.created) {\n\t\t\treturn;\n\t\t}\n\n\t\tt.created = true;\n\t\tt.media = media;\n\t\tt.domNode = domNode;\n\n\t\tif (!(IS_ANDROID && t.options.AndroidUseNativeControls) && !(IS_IPAD && t.options.iPadUseNativeControls) && !(IS_IPHONE && t.options.iPhoneUseNativeControls)) {\n\n\t\t\t// In the event that no features are specified for audio,\n\t\t\t// create only MediaElement instance rather than\n\t\t\t// doing all the work to create a full player\n\t\t\tif (!t.isVideo && !t.options.features.length) {\n\n\t\t\t\t// force autoplay for HTML5\n\t\t\t\tif (autoplay && isNative) {\n\t\t\t\t\tt.play();\n\t\t\t\t}\n\n\n\t\t\t\tif (t.options.success) {\n\n\t\t\t\t\tif (typeof t.options.success === 'string') {\n\t\t\t\t\t\twindow[t.options.success](t.media, t.domNode, t);\n\t\t\t\t\t} else {\n\t\t\t\t\t\tt.options.success(t.media, t.domNode, t);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\treturn;\n\t\t\t}\n\n\t\t\t// two built in features\n\t\t\tt.buildposter(t, t.controls, t.layers, t.media);\n\t\t\tt.buildkeyboard(t, t.controls, t.layers, t.media);\n\t\t\tt.buildoverlays(t, t.controls, t.layers, t.media);\n\n\t\t\t// grab for use by features\n\t\t\tt.findTracks();\n\n\t\t\t// cache container to store control elements' original position\n\t\t\tt.featurePosition = {};\n\n\t\t\t// add user-defined features/controls\n\t\t\tfor (let i = 0, total = t.options.features.length; i < total; i++) {\n\t\t\t\tconst feature = t.options.features[i];\n\t\t\t\tif (t[`build${feature}`]) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tt[`build${feature}`](t, t.controls, t.layers, t.media);\n\t\t\t\t\t} catch (e) {\n\t\t\t\t\t\t// TODO: report control error\n\t\t\t\t\t\tconsole.error(`error building ${feature}`, e);\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\n\t\t\tconst event = createEvent('controlsready', t.container);\n\t\t\tt.container.dispatchEvent(event);\n\n\t\t\t// reset all layers and controls\n\t\t\tt.setPlayerSize(t.width, t.height);\n\t\t\tt.setControlsSize();\n\n\t\t\t// controls fade\n\t\t\tif (t.isVideo) {\n\n\t\t\t\t// create callback here since it needs access to current\n\t\t\t\t// MediaElement object\n\t\t\t\tt.clickToPlayPauseCallback = () => {\n\n\t\t\t\t\tif (t.options.clickToPlayPause) {\n\t\t\t\t\t\tconst\n\t\t\t\t\t\t\tbutton = t.container\n\t\t\t\t\t\t\t.querySelector(`.${t.options.classPrefix}overlay-button`),\n\t\t\t\t\t\t\tpressed = button.getAttribute('aria-pressed')\n\t\t\t\t\t\t;\n\n\t\t\t\t\t\tif (t.media.paused && pressed) {\n\t\t\t\t\t\t\tt.pause();\n\t\t\t\t\t\t} else if (t.media.paused) {\n\t\t\t\t\t\t\tt.play();\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tt.pause();\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\tbutton.setAttribute('aria-pressed', !(pressed));\n\t\t\t\t\t}\n\t\t\t\t};\n\n\t\t\t\tt.createIframeLayer();\n\n\t\t\t\t// click to play/pause\n\t\t\t\tt.media.addEventListener('click', t.clickToPlayPauseCallback);\n\n\t\t\t\tif ((IS_ANDROID || IS_IOS) && !t.options.alwaysShowControls) {\n\n\t\t\t\t\t// for touch devices (iOS, Android)\n\t\t\t\t\t// show/hide without animation on touch\n\t\t\t\t\tt.node.addEventListener('touchstart', () => {\n\n\t\t\t\t\t\t// toggle controls\n\t\t\t\t\t\tif (t.controlsAreVisible) {\n\t\t\t\t\t\t\tt.hideControls(false);\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tif (t.controlsEnabled) {\n\t\t\t\t\t\t\t\tt.showControls(false);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\n\t\t\t\t} else {\n\n\t\t\t\t\t// show/hide controls\n\t\t\t\t\tt.container.addEventListener('mouseenter', () => {\n\t\t\t\t\t\tif (t.controlsEnabled) {\n\t\t\t\t\t\t\tif (!t.options.alwaysShowControls) {\n\t\t\t\t\t\t\t\tt.killControlsTimer('enter');\n\t\t\t\t\t\t\t\tt.showControls();\n\t\t\t\t\t\t\t\tt.startControlsTimer(t.options.controlsTimeoutMouseEnter);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\tt.container.addEventListener('mousemove', () => {\n\t\t\t\t\t\tif (t.controlsEnabled) {\n\t\t\t\t\t\t\tif (!t.controlsAreVisible) {\n\t\t\t\t\t\t\t\tt.showControls();\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t\tif (!t.options.alwaysShowControls) {\n\t\t\t\t\t\t\t\tt.startControlsTimer(t.options.controlsTimeoutMouseEnter);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t\tt.container.addEventListener('mouseleave', () => {\n\t\t\t\t\t\tif (t.controlsEnabled) {\n\t\t\t\t\t\t\tif (!t.media.paused && !t.options.alwaysShowControls) {\n\t\t\t\t\t\t\t\tt.startControlsTimer(t.options.controlsTimeoutMouseLeave);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\n\t\t\t\tif (t.options.hideVideoControlsOnLoad) {\n\t\t\t\t\tt.hideControls(false);\n\t\t\t\t}\n\n\t\t\t\t// check for autoplay\n\t\t\t\tif (autoplay && !t.options.alwaysShowControls) {\n\t\t\t\t\tt.hideControls();\n\t\t\t\t}\n\n\t\t\t\t// resizer\n\t\t\t\tif (t.options.enableAutosize) {\n\t\t\t\t\tt.media.addEventListener('loadedmetadata', (e) => {\n\t\t\t\t\t\t// if the <video height> was not set and the options.videoHeight was not set\n\t\t\t\t\t\t// then resize to the real dimensions\n\t\t\t\t\t\tif (t.options.videoHeight <= 0 && !t.domNode.getAttribute('height') &&\n\t\t\t\t\t\t\te.target !== null && !isNaN(e.target.videoHeight)) {\n\t\t\t\t\t\t\tt.setPlayerSize(e.target.videoWidth, e.target.videoHeight);\n\t\t\t\t\t\t\tt.setControlsSize();\n\t\t\t\t\t\t\tt.media.setSize(e.target.videoWidth, e.target.videoHeight);\n\t\t\t\t\t\t}\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t}\n\n\t\t\t// EVENTS\n\n\t\t\t// FOCUS: when a video starts playing, it takes focus from other players (possibly pausing them)\n\t\t\tt.media.addEventListener('play', () => {\n\t\t\t\tt.hasFocus = true;\n\n\t\t\t\t// go through all other players\n\t\t\t\tfor (const playerIndex in mejs.players) {\n\t\t\t\t\tif (mejs.players.hasOwnProperty(playerIndex)) {\n\t\t\t\t\t\tconst p = mejs.players[playerIndex];\n\n\t\t\t\t\t\tif (p.id !== t.id && t.options.pauseOtherPlayers && !p.paused && !p.ended) {\n\t\t\t\t\t\t\tp.pause();\n\t\t\t\t\t\t\tp.hasFocus = false;\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t});\n\n\t\t\t// ended for all\n\t\t\tt.media.addEventListener('ended', () => {\n\t\t\t\tif (t.options.autoRewind) {\n\t\t\t\t\ttry {\n\t\t\t\t\t\tt.media.setCurrentTime(0);\n\t\t\t\t\t\t// Fixing an Android stock browser bug, where \"seeked\" isn't fired correctly after\n\t\t\t\t\t\t// ending the video and jumping to the beginning\n\t\t\t\t\t\tsetTimeout(() => {\n\t\t\t\t\t\t\tconst loadingElement = t.container.querySelector(`.${t.options.classPrefix}overlay-loading`);\n\t\t\t\t\t\t\tif (loadingElement && loadingElement.parentNode) {\n\t\t\t\t\t\t\t\tloadingElement.parentNode.style.display = 'none';\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}, 20);\n\t\t\t\t\t} catch (exp) {\n\t\t\t\t\t\tconsole.log(exp);\n\t\t\t\t\t}\n\t\t\t\t}\n\n\t\t\t\tif (typeof t.media.stop === 'function') {\n\t\t\t\t\tt.media.stop();\n\t\t\t\t} else {\n\t\t\t\t\tt.media.pause();\n\t\t\t\t}\n\n\t\t\t\tif (t.setProgressRail) {\n\t\t\t\t\tt.setProgressRail();\n\t\t\t\t}\n\t\t\t\tif (t.setCurrentRail) {\n\t\t\t\t\tt.setCurrentRail();\n\t\t\t\t}\n\n\t\t\t\tif (t.options.loop) {\n\t\t\t\t\tt.play();\n\t\t\t\t} else if (!t.options.alwaysShowControls && t.controlsEnabled) {\n\t\t\t\t\tt.showControls();\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// resize on the first play\n\t\t\tt.media.addEventListener('loadedmetadata', () => {\n\n\t\t\t\tcalculateTimeFormat(t.duration, t.options, t.options.framesPerSecond || 25);\n\n\t\t\t\tif (t.updateDuration) {\n\t\t\t\t\tt.updateDuration();\n\t\t\t\t}\n\t\t\t\tif (t.updateCurrent) {\n\t\t\t\t\tt.updateCurrent();\n\t\t\t\t}\n\n\t\t\t\tif (!t.isFullScreen) {\n\t\t\t\t\tt.setPlayerSize(t.width, t.height);\n\t\t\t\t\tt.setControlsSize();\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// Only change the time format when necessary\n\t\t\tlet duration = null;\n\t\t\tt.media.addEventListener('timeupdate', () => {\n\t\t\t\tif (duration !== t.media.duration) {\n\t\t\t\t\tduration = t.media.duration;\n\t\t\t\t\tcalculateTimeFormat(duration, t.options, t.options.framesPerSecond || 25);\n\n\t\t\t\t\t// make sure to fill in and resize the controls (e.g., 00:00 => 01:13:15\n\t\t\t\t\tif (t.updateDuration) {\n\t\t\t\t\t\tt.updateDuration();\n\t\t\t\t\t}\n\t\t\t\t\tif (t.updateCurrent) {\n\t\t\t\t\t\tt.updateCurrent();\n\t\t\t\t\t}\n\t\t\t\t\tt.setControlsSize();\n\t\t\t\t}\n\t\t\t});\n\n\t\t\tt.container.addEventListener('focusout', (e) => {\n\t\t\t\tsetTimeout(() => {\n\t\t\t\t\t//FF is working on supporting focusout https://bugzilla.mozilla.org/show_bug.cgi?id=687787\n\t\t\t\t\tif (e.relatedTarget) {\n\t\t\t\t\t\tif (t.keyboardAction && !e.relatedTarget.closest('.mejs-container')) {\n\t\t\t\t\t\t\tt.keyboardAction = false;\n\t\t\t\t\t\t\tif (t.isVideo && !t.options.alwaysShowControls) {\n\t\t\t\t\t\t\t\tt.hideControls(true);\n\t\t\t\t\t\t\t}\n\t\t\t\t\t\t}\n\t\t\t\t\t}\n\t\t\t\t}, 0);\n\t\t\t});\n\n\t\t\t// webkit has trouble doing this without a delay\n\t\t\tsetTimeout(() => {\n\t\t\t\tt.setPlayerSize(t.width, t.height);\n\t\t\t\tt.setControlsSize();\n\t\t\t}, 0);\n\n\n\t\t\t// adjust controls whenever window sizes (used to be in fullscreen only)\n\t\t\tt.globalBind('resize', () => {\n\n\t\t\t\t// don't resize for fullscreen mode\n\t\t\t\tif (!(t.isFullScreen || (HAS_TRUE_NATIVE_FULLSCREEN && document.webkitIsFullScreen))) {\n\t\t\t\t\tt.setPlayerSize(t.width, t.height);\n\t\t\t\t}\n\n\t\t\t\t// always adjust controls\n\t\t\t\tt.setControlsSize();\n\t\t\t});\n\n\t\t\t// Disable focus outline to improve look-and-feel for regular users\n\t\t\tt.globalBind('click', (e) => {\n\t\t\t\tif (e.target.matches(`.${t.options.classPrefix}container`)) {\n\t\t\t\t\tdom.addClass(e.target, `${t.options.classPrefix}container-keyboard-inactive`);\n\t\t\t\t} else if (e.target.closest(`.${t.options.classPrefix}container`)) {\n\t\t\t\t\tdom.addClass(e.target.closest(`.${t.options.classPrefix}container`), `${t.options.classPrefix}container-keyboard-inactive`);\n\t\t\t\t}\n\t\t\t});\n\n\t\t\t// Enable focus outline for Accessibility purposes\n\t\t\tt.globalBind('keydown', (e) => {\n\t\t\t\tif (e.target.matches(`.${t.options.classPrefix}container`)) {\n\t\t\t\t\tdom.removeClass(e.target, `${t.options.classPrefix}container-keyboard-inactive`);\n\t\t\t\t} else if (e.target.closest(`.${t.options.classPrefix}container`)) {\n\t\t\t\t\tdom.removeClass(event.target.closest(`.${t.options.classPrefix}container`), `${t.options.classPrefix}container-keyboard-inactive`);\n\t\t\t\t}\n\t\t\t});\n\t\t}\n\n\t\t// force autoplay for HTML5\n\t\tif (autoplay && isNative) {\n\t\t\tt.play();\n\t\t}\n\n\t\tif (t.options.success) {\n\n\t\t\tif (typeof t.options.success === 'string') {\n\t\t\t\twindow[t.options.success](t.media, t.domNode, t);\n\t\t\t} else {\n\t\t\t\tt.options.success(t.media, t.domNode, t);\n\t\t\t}\n\t\t}\n\t}", "title": "" }, { "docid": "f0856ffc2fb69b9cc85efa96fff00466", "score": "0.54018015", "text": "function waitForVideo() {\n const { playerControls, chatShell, liveChat, vodChat } = TW_CLASSES\n const timeNow = Date.now()\n const int = setInterval(() => {\n if (Date.now() - timeNow > 100000000) {\n console.errpr('timed out: waiting for video')\n clearInterval(int)\n }\n let controls = document.querySelector(`.${playerControls}`),\n chat = document.querySelector(`.${chatShell}`)\n\n if (controls && chat) {\n let isLiveChat = !!document.querySelector(`.${liveChat}`)\n let isVodChat = !!document.querySelector(`.${vodChat}`)\n\n if (isVodChat && window.location.pathname.includes('videos')) {\n isLive = false\n init(false)\n clearInterval(int)\n elementReady(`.${TC_CLASSES.overlayButton}`, document).then(\n detectNeedGC()\n )\n } else if (isLiveChat) {\n isLive = true\n init()\n clearInterval(int)\n elementReady(`.${TC_CLASSES.overlayButton}`, document).then(\n detectNeedGC()\n )\n }\n }\n }, 500)\n}", "title": "" }, { "docid": "97a2c7ec0cbe530fa13d1cc2df393adf", "score": "0.5383694", "text": "async function selectMediaStream() {\n try {\n // setting const that will have media stream data, waiting to assign until user selects which screen or window they want to share. navigator.mediaDevices is a web API\n const mediaStream = await navigator.mediaDevices.getDisplayMedia();\n // passing that mediastream into video object as its source object.\n videoElement.srcObject = mediaStream;\n // when video loads its metadata it will call a function that will call and play a video\n videoElement.onloadedmetadata = () => {\n videoElement.play();\n }\n } catch (error) {\n // Catch Error Here\n }\n}", "title": "" }, { "docid": "e2c72024b5ec70620c9d80c60d80a84f", "score": "0.53804266", "text": "function checkinMediaElement(mediaElem){\n\tmediaElem = mediaElem.get ? mediaElem.get(0) : mediaElem;\t\t// in case it's jQuery object, make it a DOM element\n\tvar idSave = mediaElem.id;\n\n\tvar checkedIn = f;\n\tvar mediaPoolDiv = triv$('#mediaPool', getDisplayDocument().body);\n\tif ( mediaPoolDiv[0] )\n\t{\n\t\ttriv$('source', mediaElem).remove();\n\t\ttriv$('track', mediaElem).remove();\n\t\ttriv$(mediaElem).removeAttr('id name src style controls hidden autoplay loop');\n\n\t\tif ( mediaElem.__listeners ) for ( var i = 0; i < mediaElem.__listeners.length; i++ )\n\t\t{\n\t\t\tvar listn = mediaElem.__listeners[i];\n\t\t\tmediaElem.removeEventListener(listn.type, listn.listener);\n\t\t}\n\t\tdelete mediaElem.__listeners;\n\n\t\ttriv$(mediaElem).appendTo(mediaPoolDiv);\n\t\tvar source = document.createElement('source');\n\t\tsource.src = 'media/blank.mp4';\n\n\t\tvar track = document.createElement('track');\n\t\ttriv$(track).attr('srclang', 'en');\n\t\ttriv$(track).attr('kind', 'subtitles');\n\n\t\ttriv$(source).appendTo(mediaElem);\n\t\ttriv$(track).appendTo(mediaElem);\n\t\tcheckedIn = t;\n\t}\n\n\t// Clean up... delete the attributes that ME player added\n\tvar tagName = mediaElem.tagName.toLowerCase();\n\tvar arAttrs = mediaElem.parentElement.__origAttribs && mediaElem.parentElement.__origAttribs[tagName];\n\tfor ( var x in mediaElem )\n\t{\n\t\tif ( triv$.inArray(x, arAttrs) == -1 )\n\t\t{\n\t\t\tdelete mediaElem[x];\n\t\t\tif ( window.console )\n\t\t\t\tconsole.log('cleaning up after ME, id: [' + idSave + '], deleted attrib: ' + x);\n\t\t}\n\t}\n\n\treturn checkedIn;\n}", "title": "" }, { "docid": "a4cdb6aa6e669dcec0af420d83ef62b9", "score": "0.5380224", "text": "function setupVideoModal(){\n var modal = document.querySelectorAll('[data-modal=\"video-modal\"]'),\n modalVideo;\n\n modal.forEach(function(element, index) {\n new Modal(element, function(isOpen, target) {\n if (isOpen) {\n element.querySelector('video').play();\n } else {\n element.querySelector('video').load();\n }\n });\n });\n\n}", "title": "" }, { "docid": "d2a9076d11beb3e0750a1904b4770376", "score": "0.5377999", "text": "function getVideo() {\n // Accessing Your Webcam https://developer.mozilla.org/en-US/docs/Web/API/MediaDevices/getUserMedia\n navigator.mediaDevices\n .getUserMedia({ video: true, audio: false })\n .then(localMediaStream => {\n console.log(localMediaStream);\n // take our video, and set the source to be that \"localMediaStream\". Now, that's not\n // going to work automatically, because this is an object. In order for\n // our video to work, it actually needs to be converted into some sort of URL.\n // This is a little bit weird, because you might be used to having a video like a .mp4. But\n // this is how you set it to be a live video feed. So we're going to wrap this\n // \"localMediaStream\" in window.url caps \".createObjectURL\". That's going to\n // convert that media stream into something that this video player can understand.\n\n // video.src = window.URL.createObjectURL(localMediaStream);\n // video.play();\n\n // DEPRECIATION :\n // The following has been depreceated by major browsers as of Chrome and Firefox.\n // video.src = window.URL.createObjectURL(localMediaStream);\n // Please refer to these:\n // Depreceated - https://developer.mozilla.org/en-US/docs/Web/API/URL/createObjectURL\n // Newer Syntax - https://developer.mozilla.org/en-US/docs/Web/API/HTMLMediaElement/srcObject\n\n video.srcObject = localMediaStream;\n video.play(); // now you should see yourself in the actual video element in the top right-hand corner!!\n // If you inspect video tag, you'll see that the video source is a blob. That just means that it's the raw\n // data being piped in off this webcam.\n })\n .catch(err => {\n console.error('OH NO!!', err);\n });\n // We need to handle that error, just in case someone doesn't allow you to access their webcam.\n}", "title": "" }, { "docid": "2f9dce956e47578c2e4c7ed100d1f026", "score": "0.53769994", "text": "render () {\n return (\n <Container>\n <TitleWithLine label=\"WELCOME TO THE FUTURE\" titleColor=\"white\" style={{ alignSelf: 'flex-start', marginBottom: 30 }} />\n <CloseBtn src={closeImg} onClick={this.onClose} />\n\n <div data-vjs-player className=\"elastos-video-container\" style={{ position: 'relative', width: '100%', height: 'calc(100% * 1080/1920 + 6%)' }}>\n <video ref={ node => this.videoNode = node } className=\"video-js\"></video>\n </div>\n </Container>\n )\n }", "title": "" }, { "docid": "3822f2a560fd7f24fb1bd8415228ccd9", "score": "0.5376783", "text": "render() {\n return (\n <View\n style={[\n styles.player.parentContainer,\n {height: this.state.videoHeight},\n ]}>\n {this.state.isSourcePresent && (\n <TouchableWithoutFeedback\n onPress={this.events.onScreenTouch}\n style={[\n styles.player.container,\n this.styles.containerStyle,\n styles.player.videoBackground,\n ]}>\n <View\n style={[\n styles.player.container,\n this.styles.containerStyle,\n styles.player.videoBackground,\n ]}>\n <Video\n {...this.props}\n ref={videoPlayer => (this.player.ref = videoPlayer)}\n resizeMode={this.state.resizeMode}\n volume={this.state.volume}\n paused={this.state.paused}\n muted={this.state.muted}\n rate={this.state.rate}\n onLoadStart={this.events.onLoadStart}\n onProgress={this.events.onProgress}\n onError={this.events.onError}\n onLoad={this.events.onLoad}\n onEnd={this.events.onEnd}\n style={styles.player.video}\n source={{uri: this.state.source}}\n onSeek={() => {\n this.setState({\n seekLoading: false,\n });\n }}\n />\n {this.renderLoader()}\n {this.renderPlayPauseControls()}\n {this.props.showBottomcontrol && this.renderBottomControls()}\n </View>\n </TouchableWithoutFeedback>\n )}\n </View>\n );\n }", "title": "" }, { "docid": "886548fb7ddce36fb5b3acef2031900a", "score": "0.53757155", "text": "autoplayVideoBuilt_() {\n // Hide controls until we know if autoplay is supported, otherwise hiding\n // and showing the controls quickly becomes a bad user experience for the\n // common case where autoplay is supported.\n if (this.video.isInteractive()) {\n this.video.hideControls();\n }\n\n isAutoplaySupported(this.ampdoc_.win).then((isAutoplaySupported) => {\n if (!isAutoplaySupported && this.video.isInteractive()) {\n // Autoplay is not supported, show the controls so user can manually\n // initiate playback.\n this.video.showControls();\n return;\n }\n\n // Only muted videos are allowed to autoplay\n this.video.mute();\n\n this.installAutoplayElements_();\n });\n }", "title": "" }, { "docid": "01f52f0900854841597a461f7119410f", "score": "0.5374863", "text": "function addVideoTagIfMissing() {\n if (!video) {\n var videoTag = common.createElement(\"video\", {className: \"fp-engine\",\n crossOrigin: \"anonymous\",\n 'x-webkit-airplay': \"allow\",\n preload: player.splash ? 'none' : 'metadata',\n autoplay: player.splash ? 'autoplay' : false,\n 'webkit-playsinline': true\n });\n\n common.prepend(common.find(\".fp-player\", root)[0], videoTag);\n\n video = common.find(\"video\", root)[0];\n }\n }", "title": "" }, { "docid": "3a39c9add2d1e09c2bfda1550d210764", "score": "0.53593063", "text": "loadVideo() {\n\t\tif (this._videoRequested) return false\n\t\tthis._videoRequested = true\n\n\t\tthis._source = dom.source({\n\t\t\tsrc: this.options.video,\n\t\t\ttype: this.options.mimeType,\n\t\t})\n\t\tthis._video = dom.video(this._source)\n\n\t\tthis.dom.removeChild(this._preview)\n\t\tthis.dom.appendChild(this._video)\n\n\t\tthis._video.crossOrigin = 'anonymous'\n\t\tthis._video.addEventListener('canplay', this._handleVideoCanPlay, false)\n\t\tthis._video.load()\n\n\t\tthis.trigger(VideoComponent.VideoInitializedEvent, this)\n\t\treturn true\n\t}", "title": "" }, { "docid": "3c25088fd0582985fc4651ada8ab580f", "score": "0.5358993", "text": "watchVideo(src) {\n this.router.navigate(['/video', { src: src }]);\n }", "title": "" }, { "docid": "5728b16c8ef8d30f6833c84aca689569", "score": "0.5357094", "text": "async function selectMediaStream(){\n try{\n const mediaStream= await navigator.mediaDevices.getDisplayMedia();\n videoElement.srcObject = mediaStream;\n videoElement.onloadedmetadata = () =>{\n videoElement.play();\n }\n }catch(error){\n // catch Error here \n console.log(\" Error found here\",error);\n }\n }", "title": "" }, { "docid": "4c877ed6e500518ada9fe567e53a8616", "score": "0.5352519", "text": "cameraSetUp() {\n //Checking the navigator such as depending on what naviagtor each browser is using that different methods are used to get WebRTC.\n navigator.getUserMedia = navigator.getUserMedia ||\n navigator.webkitGetUserMedia ||\n navigator.mozGetUserMedia ||\n navigator.msGetUserMedia;\n if (!navigator.getUserMedia) { return false; }\n //Getting the canvas context for drawing on to the canvas\n const ctx = this.refs.canvas.getContext('2d');\n //A black rect to cover init time before init the video stream\n ctx.fillRect(0, 0, this.refs.canvas.height, this.refs.canvas.width);\n //Creating the video html element in order to allow streaming from the camera into the video htmlelement\n const video = document.createElement(\"video\");\n video.setAttribute(\"height\", this.refs.canvas.height)\n video.setAttribute(\"width\", this.refs.canvas.width)\n //Creating audio nodes for Audiocontext, which this is the first init node.\n var audioCtx = new AudioContext();\n this.getWebcam(video, audioCtx);\n //Creating the audio destinaction node and connecting them up from the init node.\n var dest = audioCtx.createMediaStreamDestination();\n dest.connect(audioCtx.destination);\n window.video = video\n this.setState({ ...this.state, audioMediaStreamDestination: dest, height: this.refs.canvas.height, width: this.refs.canvas.width, video: video, ctx: ctx });\n this.startAnimationLoop();\n }", "title": "" }, { "docid": "7e4d077a27900c591c1e0c085bd68373", "score": "0.5341233", "text": "findElements() {\n try {\n this.elements.controls = getElement.call(this, this.config.selectors.controls.wrapper);\n\n // Buttons\n this.elements.buttons = {\n play: getElements.call(this, this.config.selectors.buttons.play),\n pause: getElement.call(this, this.config.selectors.buttons.pause),\n restart: getElement.call(this, this.config.selectors.buttons.restart),\n rewind: getElement.call(this, this.config.selectors.buttons.rewind),\n fastForward: getElement.call(this, this.config.selectors.buttons.fastForward),\n mute: getElement.call(this, this.config.selectors.buttons.mute),\n pip: getElement.call(this, this.config.selectors.buttons.pip),\n airplay: getElement.call(this, this.config.selectors.buttons.airplay),\n settings: getElement.call(this, this.config.selectors.buttons.settings),\n captions: getElement.call(this, this.config.selectors.buttons.captions),\n fullscreen: getElement.call(this, this.config.selectors.buttons.fullscreen)\n };\n\n // Progress\n this.elements.progress = getElement.call(this, this.config.selectors.progress);\n\n // Inputs\n this.elements.inputs = {\n seek: getElement.call(this, this.config.selectors.inputs.seek),\n volume: getElement.call(this, this.config.selectors.inputs.volume)\n };\n\n // Display\n this.elements.display = {\n buffer: getElement.call(this, this.config.selectors.display.buffer),\n currentTime: getElement.call(this, this.config.selectors.display.currentTime),\n duration: getElement.call(this, this.config.selectors.display.duration)\n };\n\n // Seek tooltip\n if (is.element(this.elements.progress)) {\n this.elements.display.seekTooltip = this.elements.progress.querySelector(`.${this.config.classNames.tooltip}`);\n }\n return true;\n } catch (error) {\n // Log it\n this.debug.warn('It looks like there is a problem with your custom controls HTML', error);\n\n // Restore native video controls\n this.toggleNativeControls(true);\n return false;\n }\n }", "title": "" }, { "docid": "1ed31f2432e2a8985a28dcc5a03ef40a", "score": "0.5340812", "text": "function setupDom() {\n mainContainer = document.getElementById('main-container');\n exitHandler = document.getElementById('exit');\n video0 = {};\n vidContainer = document.getElementById('video-container-0');\n vid = document.getElementById('video-0');\n vidPlayBtn = document.getElementById('playBtn');\n vidPauseBtn = document.getElementById('pauseBtn');\n vidStopBtn = document.getElementById('stopBtn');\n vidReplayBtn = document.getElementById('replayBtn');\n vidUnmuteBtn = document.getElementById('unmuteBtn');\n vidMuteBtn = document.getElementById('muteBtn');\n //vidProgressBar = document.getElementById('progress-bar-0');\n}", "title": "" }, { "docid": "f153a985d5bafe9dc8c98eab0e0346c7", "score": "0.5326468", "text": "function createVideoContainer() {\n let container = document.createElement(\"div\");\n container.className = \"video-container\";\n return container;\n}", "title": "" }, { "docid": "ce64e1d2a5ae48e2c6b1ca1261783667", "score": "0.53262097", "text": "function getVideo() {\n navigator.mediaDevices.getUserMedia({ video: true, audio: false })\n .then(localMediaStream => {\n video.src = window.URL.createObjectURL(localMediaStream);\n video.play();\n })\n .catch(err => {\n console.err(`OH NO!!!`, err);\n });\n //nastavenie src pre video element na zdroj z webkamery\n //spustenia videa\n //zachytenie chyby v pripade ak nie je povolena webkamera\n}", "title": "" }, { "docid": "0e523abc472d17bb018da78bd7884238", "score": "0.5325325", "text": "clickOnYoutubeVideo() {\n return this\n .waitForElementVisible('@youTubeVideo')\n .assert.visible('@youTubeVideo')\n .click('@youTubeVideo');\n }", "title": "" }, { "docid": "ee0694cb1043973a495acdfe5452745e", "score": "0.5321859", "text": "setupAutoAdvanceForPreview_() {\n let autoAdvanceAfter = this.getAutoAdvanceAfterSeconds_();\n\n const firstVideo = this.getFirstAmpVideo_();\n if (!firstVideo) {\n this.element.setAttribute('auto-advance-after', autoAdvanceAfter + 's');\n return;\n }\n\n const maxPrev = this.getMaxVideoPreview_();\n if (maxPrev > 0) {\n // Comply with max-video-preview, but never to lengthen the page preview\n autoAdvanceAfter = Math.min(maxPrev, autoAdvanceAfter);\n } else if (maxPrev === 0) {\n // TODO(masanto): Prevent video from playing when maxVideoPreview is 0\n }\n this.element.setAttribute('auto-advance-after', autoAdvanceAfter + 's');\n\n whenUpgradedToCustomElement(firstVideo)\n .then(() => firstVideo.getImpl())\n .then((videoImpl) => {\n this.loadPromise(firstVideo).then(() => {\n const duration = videoImpl.getDuration();\n const tooShort = duration < autoAdvanceAfter;\n const videoEl = firstVideo.querySelector('video');\n videoEl.loop ||= tooShort;\n });\n });\n }", "title": "" }, { "docid": "b7b39ce737959d36c53aacf3b0c3f7aa", "score": "0.53214115", "text": "function onPlayerReady(event) {\n //event.target.playVideo();\n}", "title": "" }, { "docid": "7249aa3858677368900ca6becbab1bfd", "score": "0.5318864", "text": "function onPlayerReady(event) {\n //event.target.playVideo();\n}", "title": "" }, { "docid": "4265cc0f0037a0772e89dfc253adb244", "score": "0.5306369", "text": "function startVideo (domName) {\n const dom = document.querySelector(`#${domName} a`)\n const video = document.querySelector(`#${domName} video`)\n if (window.innerWidth >= 768) {\n addClass(dom, 'large')\n video.pause()\n video.currentTime = 0\n }\n video.play()\n video.addEventListener('ended', () => {\n video.currentTime = 0\n }, false)\n }", "title": "" } ]
ab4b659715915eda340066bdfd768b65
deletes an ski_areas_events relationship
[ { "docid": "818355a61fb6584486584011fa3c633d", "score": "0.64844865", "text": "function deleteSkiAreasEvents(said,eid){\n $.ajax({\n url: '/ski-areas-events/' + said + '/' + eid,\n type: 'DELETE',\n success: function(result){\n window.location.reload(true);\n }\n })\n}", "title": "" } ]
[ { "docid": "4e20919be32f050f407364ee3f5ac4ad", "score": "0.58954674", "text": "deleteEvent(state, eventId) {\n let event = state.events.find(event => event.event_id === eventId)\n if(event != undefined) { \n event.delete = true \n state.touched = !state.touched\n }\n }", "title": "" }, { "docid": "14462fd794f6977c28215641e3654780", "score": "0.5847356", "text": "function deleteAreaFromMapObj(clickedID) {\n var obj = map.areas;\n map.areas = obj.filter(function (e) {\n return e.zoneID !== clickedID;\n });\n jQuery('#zoneMaps #map_' + clickedID).remove();\n if (clickedID.indexOf('area_') === 0) {\n jQuery('div[data-zoneid=' + clickedID + ']').remove();\n }\n //jQuery('map').find('area#' + clickedID).remove();\n //hightlight();\n createNewBox();\n click = true;\n }", "title": "" }, { "docid": "1977d70a6f5959112892be1fcb85cba4", "score": "0.570491", "text": "delete(e) {\n var id = e.target.id;\n API_Calls.__post({ id: id }, '/delete', this.props.token)\n .then(res => {\n this.getMarkersTable();\n });\n }", "title": "" }, { "docid": "80d6ba4a485a86c2c4ab87dcdde2c9f0", "score": "0.56984687", "text": "function delete_event(e) {\n if (e === null){\n alert_screen(\"info\", \"Please select the event you want to delete first\");\n } else {\n if ('schedule_block_id' in e) {\n current_proposal.deleted.push(e.schedule_block_id);\n remove_block_from_array(\n current_proposal.moved, event_to_schedule_block(e));\n } else {\n remove_block_from_array(\n current_proposal.new, event_to_schedule_block(e));\n }\n calendar_remove_event(e);\n }\n}", "title": "" }, { "docid": "a5b461d5f45af45338769dbbcada4d13", "score": "0.5593881", "text": "deleteShapes() {\n this.regions_info.deleteShapes();\n }", "title": "" }, { "docid": "d31007360ce99cc9d0c17cd4af4f0ec6", "score": "0.55457866", "text": "function deleteEvents(toDelete, client){\n\tglobals.editJSON(scheduleDb, function(data){\n\t\tlet obj = JSON.parse(data);\n\t\tfor(let i = 0; i < toDelete.length; i++){\n\t\t\tlet events = obj.guilds[toDelete[i][0]].events;\n\t\t\tfor(let j = 0; j < events.length; j++){\n\t\t\t\tif(events[j].id === toDelete[i][1].id){\n\t\t\t\t\tevents.splice(j, 1);\n\t\t\t\t\tglobals.botLog(client, 'Event deleted: \\\"'+toDelete[i][1].name+'\\\" '+toDelete[i][0]);\n\t\t\t\t\tbreak;\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t\treturn JSON.stringify(obj);\n\t});\n}", "title": "" }, { "docid": "79c63768622dd489d5a425294e88f0b7", "score": "0.5521366", "text": "onAreaMarkerContextClick(areaID, e) {\n doActionsInOrder([\n () => this.props.deleteArea(areaID),\n () => {\n this.props.getClipsMatchingFilter();\n this.props.getFilter();\n },\n ]);\n }", "title": "" }, { "docid": "66578c9e25aa371a0905eebebbdf4462", "score": "0.5475361", "text": "function deletePgFromCrs(e) {\n // remove from table\n let tr = findAncestor(e.target, 'node', 'TR');\n let tbody = findAncestor(tr, 'node', 'TBODY');\n tbody.removeChild(tr);\n\n // add to array to delete when updates are saved\n let deleteObj = {\n 'pg_Id': e.target.getAttribute('data-page-id'),\n 'crs_Id': e.target.getAttribute('data-course-id')\n }\n crsPgToDelete.push(deleteObj);\n}", "title": "" }, { "docid": "2ff4e0d7356db54690d4fc7a1236f225", "score": "0.5434217", "text": "function deleteEvent(eventID){\n db.events.delete(eventID);\n console.log('Event deleted succesfully');\n}", "title": "" }, { "docid": "ec2ba88cb2e0f67d1a2becbade59d6c6", "score": "0.5426179", "text": "async deleteTarea({commit, state}, id){\n try{\n await fetch(`https://vue-api-rest-udemy-default-rtdb.firebaseio.com/tareas/${state.user.localId}/${tarea.id}.json?auth=${state.user.idToken}`, {\n method: 'DELETE'\n })\n }catch(error){\n console.log(error);\n }\n \n commit('delete', id)\n }", "title": "" }, { "docid": "7ddfe44efcf957c44bd5648e8f7226b4", "score": "0.53915644", "text": "function deleteEvent(events, deleteIndex) {\n events.splice(deleteIndex, 1);\n}", "title": "" }, { "docid": "c1b81db95e598923ba00786c966f7495", "score": "0.5373599", "text": "async delete(ctx) {\n const { id } = ctx.params;\n\n const [events] = await strapi.services.events.find({\n id: ctx.params.id,\n \"user.id\": ctx.state.user.id,\n });\n\n if (!events) {\n return ctx.unauthorized(`You can't update this entry`);\n }\n\n const entity = await strapi.services.events.delete({ id });\n return sanitizeEntity(entity, { model: strapi.models.events });\n }", "title": "" }, { "docid": "675663458110c0fc56b9ef06fe4ebec4", "score": "0.5364034", "text": "removaAllEvents() {\n this.removeEvents(this.props);\n }", "title": "" }, { "docid": "972d85f57d60bdf27409773517dcc3c1", "score": "0.53504896", "text": "function deleteEvent(id){\r\n\r\n for (let ev of eventList) {\r\n\r\n if (ev.id == id) {\r\n eventList.splice(eventList.indexOf(ev),1);\r\n console.log(`Delete event with name ${ev.name}`); \r\n }\r\n }\r\n}", "title": "" }, { "docid": "277beb2a6a673b93bfff66057cec2d92", "score": "0.5341507", "text": "off(eventName) {\n // delete the entire event property off the object\n delete this.events[eventName]\n }", "title": "" }, { "docid": "ade7e824c99db4f3e5b01ece04eceff4", "score": "0.5339452", "text": "deleteEvent(event) {\n let selectedEventId = event.id;\n let errorOccurred = false;\n window.gapi.client.load('calendar', 'v3', () => {\n var request = window.gapi.client.calendar.events.delete({\n 'calendarId': 'primary',\n 'eventId': selectedEventId\n });\n request.execute((response) => {\n if (response.error || response == false) {\n errorOccurred = true;\n alert(\"An error occurred. Please try again.\");\n }\n else {\n this.updateList();\n }\n });\n })\n }", "title": "" }, { "docid": "78f23f5c2b1008559731838c863ec2a4", "score": "0.53357", "text": "async function deleteEvent(data){\n\n}", "title": "" }, { "docid": "51bba8a464607baeba672b5777810965", "score": "0.53123546", "text": "function onEntityDelete() {}", "title": "" }, { "docid": "3c5d7f6577844a66f88c3fd8321424d9", "score": "0.5305372", "text": "delete(state, payload){\n //Utilizamos filter de javascript \n state.tareas = state.tareas.filter( item => item.id !== payload)\n }", "title": "" }, { "docid": "0c4c98f8b43909f37fad3a6e965026ed", "score": "0.5300182", "text": "async function deleteOne(req, res) {\n\tArea.findOneAndDelete({ id: { $eq: req.params.id } }, (error, area) => {\n\n\t\t// case: DB error\n\t\tif (error) {\n\t\t\trespond.withFailure(res, `${controllerConfig.entityNameSingle} could not be deleted.`, error);\n\t\t}\n\n\t\t// fill in eval / aggregate based fields.\n\t\t// no need here.\n\t\t// area = areasService.fillInAdditionalFieldsForArea(area);\n\n\t\trespond.withSuccess(res, {\n\t\t\tarea: area\n\t\t});\n\t});\n}", "title": "" }, { "docid": "e780b08d1842a6977f3483070fe0dec2", "score": "0.5283806", "text": "static deleteEvent(req, res) {\n database.event.findOne({\n where: {\n id: req.params.id,\n userId: req.body.userId,\n },\n })\n .then((event) => {\n if (!event) return res.status(404).json({ err: 'event not found' });\n jsonHandle(event);\n unmountImages(event);\n return database.event.destroy({\n where: {\n id: req.params.id,\n userId: req.body.userId,\n },\n })\n .then((num) => {\n if (num > 0) return res.json({ status: 'success' });\n return res.status(404).json({ err: 'event not found' });\n })\n .catch(err => res.status(404).json({ err: err.message || 'problem occured deleting event' }));\n })\n .catch(err => res.status(404).json({ err: err.message || 'problem occured deleting event' }));\n }", "title": "" }, { "docid": "8797d0ddc185182a569fe8c86ac2e333", "score": "0.5272355", "text": "_deleteGroup(event) {\n $(event.currentTarget).closest('tr').remove();\n }", "title": "" }, { "docid": "a373e4be25ef57a5f2b6f177de8893ad", "score": "0.52722156", "text": "deleteElement(evt) {\n this.collection.remove(this._getId(evt));\n }", "title": "" }, { "docid": "86307e6c9aa42fa99798b163d1bc0a06", "score": "0.52692384", "text": "function removeAreasFromMapObj() {\n //map.areas = [];\n map = {'imgName': '', 'areas': []};//map object\n areas = {};//area object\n seats = [];//seats object\n jQuery('#mainForm #drawCanvas > div').remove();\n }", "title": "" }, { "docid": "0634012da17cf6690da480c18aa3fb02", "score": "0.5255717", "text": "function deleteEvents(){\n var events_id = $(this).attr('name');\n performRequest( \"deleteEvents.php?events=\"+events_id, function(data){\n showErrorMessage(data[0].del); \n });\n $('.read-events').remove();\n setTimeout(function(){\n window.location.reload(1);\n }, 1000);\n}", "title": "" }, { "docid": "5c1f0e226ef6bc87b20a55105c2aff96", "score": "0.5241871", "text": "function deleteJoke(event) {\n //event.stopPropogation();\n var id = $(this).data(\"id\");\n $.ajax({\n method: \"DELETE\",\n url: \"/api/jokelist/\" + id\n }).then(getJokeList);\n\n }", "title": "" }, { "docid": "8f6557ca395969641953e1b0d316cb1d", "score": "0.5229994", "text": "function deleteAgence(nom_agence) {\n console.log(\"Suppression de l'agence \" + nom_agence);\n\n database.ref(\"Agences/\"+nom_agence.trim()).set(null);\n database.ref(\"Comments/\"+nom_agence.trim()).set(null);\n document.forms[\"agenceAdmin2\"].submit();\n}", "title": "" }, { "docid": "b97e42e3cb4f94d39fa2597e07a08006", "score": "0.5228025", "text": "function deleteSubmitEventHeader(){\n $(\"#event_panel_link\").remove();\n $(\"#route_panel_link\").remove();\n $(\"#alarm_panel_link\").remove();\n}", "title": "" }, { "docid": "8f0933d1680f266f40de92d3cdb6ed9e", "score": "0.52245766", "text": "function deleteClicked(event){\n\tif (confirm('Are you sure you want to delete this record?')) {\n\t\tvar order_id = event.target.id.split(\"_\")[1];\n\t\t$.ajax({\n\t\t\ttype: 'put',\n\t\t\turl: '/sales/cashsales',\n\t\t\tdata: {\n\t\t\t\torderID : order_id,\n\t\t\t\tdateToDistribute : \"\",\t\n\t\t\t\tlastName : \"\",\t\n\t\t\t\temail : \"\",\t\n\t\t\t\tsmallBoxQuantity :\"\",\t\n\t\t\t\tphoneNumber : \"\",\t\n\t\t\t\thostSiteOrderID : \"-99\",\n\t\t\t\tdateCreated :\"\",\t\n\t\t\t\tdonations : \"\",\t\n\t\t\t\thostSitePickupID :\"\",\t\n\t\t\t\ttotalPaid : \"\",\t\n\t\t\t\tshouldSendNotifications : \"\",\t\n\t\t\t\tdonationReceipt :\"\",\t\n\t\t\t\tfirstName :\"\",\t\n\t\t\t\tlargeBoxQuantity :\"\",\t\n\t\t\t\tcustomerID : \"\",\t\n\t\t\t},\n\t\t\tcomplete: function(response) {\n\t\t\t\tif (response.success == \"false\"){\n\t\t\t\t\talert(response.message);\n\t\t\t\t} else {\n\t\t\t\t\tlocation.reload();\n\t\t\t\t}\n\t\t\t}\n\t\t});\n\t}\n}", "title": "" }, { "docid": "ff84b037253f5719ef9d3e5be7508ef7", "score": "0.5223291", "text": "function removeFromCollection (event) {\n event.preventDefault();\n console.log(_id)\n API.deleteObject(_id)\n //loadCollection()\n .then(res => {\n console.log(res);\n loadCollection()\n }).catch(err => console.log(err))\n\n console.log(\"Object deleted\")\n }", "title": "" }, { "docid": "294db8b0867c426bfecd9e70cd51f850", "score": "0.5221191", "text": "function deleteEvent(eventId) {\n DeleteService.deleteEvent(eventId).then((res) => {\n $state.reload($state.current);\n })\n }", "title": "" }, { "docid": "6899d53ef76512f57f496c297cc82dde", "score": "0.52145225", "text": "function removeReferences(evt) {\n if (!tournament.events) return;\n tournament.events.forEach(e => { \n Object.keys(e.links).forEach(key => { \n if (e.links[key] == evt.euid) {\n\n // if an elminiation draw has been deleted that was linked to a RR draw, then RR draw is no longer qualifying draw\n if (['E', 'S'].indexOf(e.draw_type) >= 0 && e.draw_type == 'R' && e.draw) {\n dfx.tallyBracketAndModifyPlayers({ matches: e.matches });\n }\n\n delete e.links[key]; \n // TODO: is it necessary to regenerate a draw when its linked/ draw is deleted?\n // IF a qualifying draw is removed then, yes, maybe...\n // e.regenerate = true;\n }\n }); \n });\n }", "title": "" }, { "docid": "a3a783e3bcc0a9d070e1d83774bf9e71", "score": "0.5209128", "text": "function deleteArea(){\n loadArea(true, \"Eliminando archivo\", true);\n fetch(direccion + `doc/${fileCheck.value}`,{\n method: 'DELETE'\n }).then(function(res){\n return res.json();\n }).then(function(myRes){\n pdfToolsCnt.style.opacity = \"\";\n pdfToolsCnt.style.zIndex = \"\";\n loadArea(false, \"\",true);\n })\n}", "title": "" }, { "docid": "684638ae1aff8036387d07512ceaf913", "score": "0.51933086", "text": "_handleButtonRemoveAll()\n {\n $(this.getRegion('regionAssignedResources').el).find('tr').trigger('dblclick');\n }", "title": "" }, { "docid": "86b817ac7ba9552ff33b5cafb963eaa6", "score": "0.5180821", "text": "function deleteEvents(id) {\n $.ajax({\n method: \"DELETE\",\n url: \"/api/schedule/\" + id\n }).then(function() {\n getSchedule();\n });\n }", "title": "" }, { "docid": "0e764f38f10c574c70b1a6ce63b79a7c", "score": "0.5174283", "text": "deleteEvent(id) {\n const { eventList } = this.props;\n (\n axios.delete(`http://localhost:5000/events/${id}`)\n .then(() => {\n const newEventList = eventList\n .filter((event) => event.id !== id);\n this.props.deleteOneEvent(newEventList);\n //delete one event state\n })\n );\n }", "title": "" }, { "docid": "b5d1276923301bf9f323a1dcd89c4199", "score": "0.5156564", "text": "function DestroyEditAreaInstance(eid)\n{\n\tif (!Gx__EditAreaInstances_CanvasSupported)\n\t{\n\t\tif (typeof(Gx__EditAreaInstances[eid]) == 'object' && typeof(Gx__EditAreaInstances[eid].initoptid) == 'undefined')\n\t\t{\n\t\t\teditAreaLoader.delete_instance(eid + '_edit');\n\t\t\tif (Gx__EditAreaInstances[eid].created) $('#' + eid).html('');\n\n\t\t\tdelete Gx__EditAreaInstances[eid];\n\t\t}\n\t}\n}", "title": "" }, { "docid": "432a86fcb343e4920a107995158837b4", "score": "0.51549363", "text": "function deleteWorkout(event){\n\t//send delete request\n\tvar req = new XMLHttpRequest();\n\n\treq.open(\"POST\", \"/delete\", true)\n\treq.setRequestHeader(\"Content-Type\", \"application/json\");\n\n\tvar id = event.target.parentNode.firstElementChild.value;\n\t\n\treq.addEventListener(\"load\", function(){\n\t\tif(req.status >= 200 && req.status < 400){\n\n\t\t\tconsole.log(\"success\");\n\t\t\t//delete from table\n\t\t\tevent.target.parentNode.parentNode.parentNode.remove();\n\n\t\t}\n\t});\n\t\n\treq.send( JSON.stringify( { \"id\": id }));\n\t\n}", "title": "" }, { "docid": "7cd47d5baf4881702cdbf4f13055e9a4", "score": "0.5149627", "text": "'click #delete'(event, instance) {\n \tPrimary.remove(this._id)\n }", "title": "" }, { "docid": "14cccaf18227b7579a13ded31713e9b3", "score": "0.51258415", "text": "handleDelete() {\n var reportedStoriesRef = firebase.database().ref('reportedStories/');\n reportedStoriesRef.child(this.props.reportKey).remove();\n var storyRef = firebase.database().ref('/stories');\n storyRef.child(this.props.storyKey).remove();\n }", "title": "" }, { "docid": "517567706b34413872a2907f92c1b08f", "score": "0.5112882", "text": "removeFromMyEvents({ commit, dispatch }, payload) {\n api.put('/user-events/' + payload.event._id, payload.event)\n .then(res => {\n console.log('this event has been removed from user events')\n dispatch('authenticate')\n dispatch('getMyEvents')\n dispatch('getMySchedule', payload.event)\n })\n .catch(err => {\n commit('handleError', err)\n })\n }", "title": "" }, { "docid": "ead2da8671df29053a38c7e5d7251972", "score": "0.5109749", "text": "function deleteEvent(index) {\n if (index > -1){\n _eventsList.splice(index, 1);\n }\n\n}", "title": "" }, { "docid": "e7758177ede92716930d4febc053997f", "score": "0.51086193", "text": "function deleteForm(event) {\n\tvar forms = Ti.App.Properties.getList(\"completedForms\");\n\tforms.splice(forms.indexOf(event.rowData.TDP_id), 1);\n\tTi.App.Properties.setList(\"completedForms\", forms);\n}", "title": "" }, { "docid": "93224a7cec06bc3fe90e06640fc2d878", "score": "0.5104221", "text": "function deleteOverlays() {\r\n \tmap.clearOverlays();\r\n\t\r\n}", "title": "" }, { "docid": "4f7c6b135ad3597889c9b84f8b91db26", "score": "0.5100123", "text": "removeHandler(event) {\n const del = event.target.dataset.val;\n //console.log(\"items \" + this.recordData);\n let sel_rec = this.recordData;\n let records = this.selectedRecords;\n records.splice(del, 1);\n sel_rec.splice(del, 1);\n this.selectedRecords = records;\n this.recordData = sel_rec;\n this.countItem = this.countItem - 1\n if(this.countItem <= MAXLIMIT)\n this.hitLimit = false;\n //console.log(\"deleted item \");\n if (this.recordData.length === 0) {\n this.recordVisibility = false;\n this.btn_clear = false;\n }\n const removeEvent = new CustomEvent('remove',{detail:this.selectedRecords});\n this.dispatchEvent(removeEvent);\n \n }", "title": "" }, { "docid": "b37111131560ad28cfdf529aa183fd0b", "score": "0.5098024", "text": "function deleteApartment(id, name)\n{\n // Confirm deletion\n if(confirm(\"Are you sure you want to delete \" + name + \"?\"))\n {\n //Delete & forms associated to that flat\n $.post(\"/apartment_information/db\", {action: \"delete\", _id: id }, function()\n {\n \n });\n }\n refreshList();\n}", "title": "" }, { "docid": "53444bf7881771f064d513ee38e1a00d", "score": "0.5080871", "text": "function deleteWorkout(event, excerciseTable) {\r\n var req = new XMLHttpRequest();\r\n var form = event.target.parentNode;\r\n var inputs = form.getElementsByTagName('input');\r\n var id = inputs[0].value;\r\n req.open(\"GET\", \"/delete?deleteId=\" + id, true);\r\n req.addEventListener(\"load\", function() {\r\n var table = document.getElementById(\"excerciseTable\");\r\n var rowCount = table.rows.length;\r\n for (var i = 0; i < rowCount; i++) {\r\n var row = table.rows[i];\r\n if (row == event.target.parentNode.parentNode.parentNode) {\r\n table.deleteRow(i);\r\n rowCount--;\r\n i--;\r\n }\r\n }\r\n });\r\n req.send(null);\r\n event.preventDefault();\r\n}", "title": "" }, { "docid": "68e72a218cdf0a50f5ad495a18f605e1", "score": "0.5074076", "text": "function removeEvent(access_token, id, callback) {\r\n var delURL = BASE_URL + calendar_settings.calID + '/events/' +\r\n id + '?access_token=' + access_token;\r\n request.del({ url: delURL, json: true }, callback);\r\n}", "title": "" }, { "docid": "0f323d8402ccc8d66e3dcfcc50ffd4dd", "score": "0.50671005", "text": "async delete()\n {\n //Impossible call\n if (this.create) {\n return;\n }\n\n this.deletingEvent = true;\n try\n {\n await this.EventService.delete(this.event);\n this.toastr.success(`Der Anlass ${this.event.title} wurde erfolgreich gelöscht`, \"Löschen\");\n this.$scope.$close(true);\n } catch (e)\n {\n this.toastr.error(`Der Anlass ${this.event.title} konnte nicht gelöscht werden`, \"Fehler\");\n } finally\n {\n this.deletingEvent = false;\n }\n }", "title": "" }, { "docid": "c649ccaba31d784729feb0b9d8368dfb", "score": "0.5063303", "text": "function eliminar_evento(req, res) {\n let id_evento = req.query.id_evento;\n Evento.findById(id_evento, (err, eventos) => {\n if (err) res.status(500).send(`Error de base de datos ${err}`);\n eventos.remove(err => {\n if (err) res.status(500).send(`Error de base de datos ${err}`);\n res.status(200).send('El evento ha sido eliminado exitosamente');\n })\n })\n}", "title": "" }, { "docid": "0d259a0e3aea156e6d4d30511e5e490a", "score": "0.5060362", "text": "function deleteObject(event) {\n console.debug(\"# deleteObject\");\n console.debug(event);\n\n var object_id = event.target.parentNode.parentNode.getAttribute('object_id');\n\n var indexedDbName = event.target.parentNode.parentNode.parentNode.parentNode.getAttribute('indexedDbName');\n\n var objectStoreName = event.target.parentNode.parentNode.parentNode.parentNode.getAttribute('objectStoreName');\n\n var p = deleteFromIndexedDB_async(indexedDbName, objectStoreName, object_id);\n\n p.then(function (res) {\n console.debug(res)\n });\n\n // send update message to in-memory database\n\n\n // send message to background, to request a refresh of the in-memory databases for this policy object\n browser.runtime.sendMessage({\n request: {\n \"policy\": \"single_delete\",\n \"delete_details\": {\n \"database\": indexedDbName,\n \"datastore\": objectStoreName,\n \"object_id\": object_id\n }\n }\n }, function (response) {\n console.debug(\"message sent to backgroup.js with response: \" + JSON.stringify(response));\n });\n\n // remove item from table\n\n var object_table = document.querySelector('table[indexeddbname=\"' + indexedDbName + '\"]');\n //console.debug(object_table);\n\n var object_row = object_table.querySelector('tr[object_id=\"' + object_id + '\"]');\n //\tconsole.debug(object_row);\n\n object_row.remove();\n\n}", "title": "" }, { "docid": "361a49c77fcc7fe61967b2b719432859", "score": "0.50566083", "text": "function removerDestaqueEstado(e) {\n geojson.resetStyle(e.target);\n cardDeInformacao.update();\n }", "title": "" }, { "docid": "dfae6060944e5f1711bdf8556d52b806", "score": "0.5045335", "text": "async deleteStressor(e){\n e.preventDefault();\n let completed = document.getElementById(`${e.target.id}`);\n let stressorText = document.getElementById(`t${e.target.id}`);\n fetchCall.deleteStressor(e);\n completed.remove();\n stressorText.remove();\n e.target.remove();\n }", "title": "" }, { "docid": "d5b8bed82286a708fa6a168ac5585452", "score": "0.5043321", "text": "function deletePolygons() {\n clearPolygons();\n polygons = [];\n}", "title": "" }, { "docid": "56f44bc652828c5d717ecd7c7596d1f2", "score": "0.50427324", "text": "function deleteEvent(){\n let eventArr = currEventArr;\n const data = { \n 'user_id': user_id,\n 'token': token,\n 'event_id': eventArr.event_id\n };\n \n fetch(\"DeleteEvent.php\", {\n method: 'POST', \n body: JSON.stringify(data),\n headers: { 'content-type': 'application/json' }\n })\n .then(response => response.json())\n .then(function(data){\n alert(data.success ? \"Event deleted\" : `Event not deleted ${data.message}`);\n console.log(data.success ? \"Event deleted\" : `Event not deleted ${data.message}`);\n if(data.success){\n //removes event from the calendar\n $(\"#event\"+eventArr.event_id).remove();\n $(\"#displayeventdiv\").slideUp();\n $(\"#displayeventinfodiv\").empty();\n $(\"#addeventdiv\").show();\n }\n })\n .catch(err => console.error(err)); \n}", "title": "" }, { "docid": "43f0fda713bdb65d760fc9674e53d2e9", "score": "0.5041804", "text": "function deleteEvent() {\n let thisEvent = this.parentElement;\n thisEvent.parentElement.removeChild(thisEvent);\n updateCount();\n }", "title": "" }, { "docid": "89c2914c74565c495aac5f2d729105d4", "score": "0.50373584", "text": "delete(arg) {\n return this.httpClient\n .url(`/event_destinations/${arg.id}`)\n .delete()\n .json(payload => util.deserializeResult(payload))\n .then(f => f, util.onRejected);\n }", "title": "" }, { "docid": "a8b637047c43940d4140126a93056514", "score": "0.5028988", "text": "handleDeleteButtonClick(event, index) {\n\t\tconst { places, dispatch } = this.props\n\n\t\tif (places.length === 2) {\n\t\t\talert('最少一个目的地')\n\t\t\treturn\n\t\t}\n\n\t\tdispatch(deletePlace(index))\n\t}", "title": "" }, { "docid": "9c4c9522dcdc70933651df9730cc5779", "score": "0.5022763", "text": "_handleButtonRemoveSelected()\n {\n $(this.getRegion('regionAssignedResources').el).find('tr.active').trigger('dblclick');\n }", "title": "" }, { "docid": "527f3e0ccff6a4c744ca9a016501066c", "score": "0.5015511", "text": "async deleteInsats() {\n this.freePersonnel(\n this.state.insats.fromTime,\n this.state.insats.toTime,\n this.state.insats.date\n );\n for (let i = 0; i < this.state.layouts.length; ++i) {\n if (this.state.layouts[i].key == this.state.insats.key) {\n this.state.layouts.splice(i, 1);\n }\n }\n const dbRef = firebase\n .firestore()\n .collection(\"insatser\")\n .doc(this.state.insats.key);\n dbRef.delete().then((res) => {\n // console.log(\"Item removed from database\");\n });\n this.sendNotification();\n }", "title": "" }, { "docid": "be34856f2b08f521a0f8cdeaa592dc1f", "score": "0.50121033", "text": "delete() {\n\n $.ajax({\n url : '/calendar/delete',\n method : \"POST\",\n data : { event_id : this.state.deleteEventId },\n dataType : \"JSON\",\n headers : { \"prg-auth-header\" : this.state.user.token},\n success : function (data, text) {\n if (data.status.code == 200) {\n this.setState({deleteEventId: ''});\n this.closeModal();\n this.loadEvents();\n }\n }.bind(this),\n error: function (request, status, error) {\n console.log(error);\n }\n });\n }", "title": "" }, { "docid": "e404f69247c49c3bb371d2f5c8cac545", "score": "0.5006468", "text": "function deleteRoomBooking(req, res) {\n Room.find({room_number: req.params.room_number}, function(err, room) {\n if (err) throw err;\n\n var schedules = room[0].room_schedules;\n for(var i = 0; i < schedules.length; i ++) {\n if(schedules[i].user == req.params.booking_id\n && schedules[i].start_time == req.params.start_time) {\n\n room[0].room_schedules.splice(i, 1);\n }\n }\n room[0].save(function(err, room) {\n if (err) throw err;\n res.send(room);\n });\n\n\n });\n}", "title": "" }, { "docid": "fbca6fbf84debed6d5ad603144b386d1", "score": "0.50027436", "text": "delete(req, res) {\n console.log(req);\n let queryVars = req.query;\n Location.destroy({\n where: {\n id: queryVars.id\n }\n })\n .then(function (deletedRecords) {\n res.status(200).json(deletedRecords);\n })\n .catch(function (error){\n res.status(500).json(error);\n });\n }", "title": "" }, { "docid": "9dbe688922c76639dabb563ba80f8e0d", "score": "0.4998979", "text": "destroy(req, res) {\n\n if (!req.can(\"event.manage\")) return res.forbidden();\n\n let id = req.param(\"id\");\n\n Event.findById(id, (error, event) => {\n if (error) return res.serverError(error);\n if (!event) return res.notFound(req.lang(\"event.errors.event_not_found\"));\n\n event.remove(error => {\n if (error) res.serverError(error);\n return res.message(req.lang(\"event.events.deleted\")).ok(id);\n });\n\n });\n }", "title": "" }, { "docid": "bb689ad57a9200c48aea18fdd5ff3418", "score": "0.4998954", "text": "function deleteUnitHandler(event) {\n // Declare a local variable to store the ID of the current deliverable\n var deliverable;\n\n deliverable = event.data.param1;\n\n if( confirm(\"You are about to delete the Deliverable: \" + deliverable.Name +\". Are you sure you wish to continue\")){\n\n var newDeliverable = new Deliverable();\n // newDeliverable = event.data.param1;\n newDeliverable.ID = event.data.param1.ID;\n newDeliverable.ProjectID = event.data.param1.ProjectID;\n newDeliverable.Name = deliverable.Name;\n newDeliverable.Description = deliverable.Description;\n newDeliverable.CrossReference = deliverable.CrossReference;\n newDeliverable.isActive = false;\n newDeliverable.UserId = UserID;\n\n// deliverable.isActive = false;\n saveUpdatedDeliverable(newDeliverable);\n }\n else{\n\n }\n\n// alert(\"Delete '\" + event.data.param1.Name + \"' - Feature Not Yet Implemented\");\n event.stopPropagation();\n\n // Update the current record and set it to inactive\n }", "title": "" }, { "docid": "4c1956052feddede84dd144b89fdf8ce", "score": "0.49837232", "text": "delete(e){validateName(e=`${e}`);const t=find(this[MAP],e);void 0!==t&&delete this[MAP][t]}", "title": "" }, { "docid": "f83e78d2bec5394d4afa0b313e5b953a", "score": "0.49792185", "text": "function deleteEvent(event)\n{\n $.ajax({\n url: '/1/calendar/delete_event',\n type: 'POST',\n data:{\n id:event.data.eventID,\n tag:event.data.tag\n },\n success: function(data) {\n if(data.deleted === '')\n {\n $('.'+event.data.eventID).remove();\n $('#extraInfo_triangle').hide();\n $('#extraInfo').hide();\n }\n else{\n alert(data.deleted);\n }\n }\n });\n}", "title": "" }, { "docid": "2df780cc35d5a97a33f8cb21d5024eee", "score": "0.49789238", "text": "deleteLocation(id, success, fail) {\n api.shared().delete('/locations/' + id)\n .then(function (response) {\n success(response.data);\n })\n .catch(function (error) {\n console.log(error.response)\n if (error.response != undefined) {\n fail(error.response.data);\n }\n });\n }", "title": "" }, { "docid": "ad3c6075931e2f5cc25ba290d30bcdb6", "score": "0.49751022", "text": "removeEvent() {\n events = events.filter(e => e.date !== clicked);\n localStorage.setItem(\"events\", JSON.stringify(events));\n this.deleteEvent();\n }", "title": "" }, { "docid": "5438b62d45ac7c92e3619c30ada7e41d", "score": "0.49737093", "text": "async delete(filters) {\n // Find all matched events.\n const events = await this.eventsModel.aggregate(filters);\n\n if (events.length === 0) {\n return;\n }\n\n const objKeys = [];\n\n // Collect of the object keys stored in the contents.\n forEach(events, (event) => {\n forEach(event.content, (value) => {\n // Each type of events has its own content structure. To\n // generalize, we assume object key is stored in string type.\n if (isString(value)) {\n objKeys.push(value);\n }\n });\n });\n\n // Delete all objects by keys.\n if (objKeys.length > 0) {\n await deleteObjects(objKeys);\n\n console.log(`Delete objects: ${objKeys}`);\n }\n\n const eventIds = map(events, event => event._id);\n\n // Delete all events.\n await this.eventsModel.remove({\n _id: {\n $in: eventIds,\n },\n });\n\n console.log(`Delete ${eventIds.length} event records: ${eventIds}`);\n }", "title": "" }, { "docid": "6cffebf9e01908c684d9f5f04482cce6", "score": "0.49704614", "text": "function borrarItem(event) {\n let numeroTarea = (event.target).parentNode.dataset.id;\n let indice = listaTareas.findIndex(function (tarea) {\n console.log(numeroTarea);\n return tarea.id == numeroTarea;\n\n })\n\n listaTareas.splice(indice, 1);\n\n let tareaBorrada = document.getElementById('Tarea' + numeroTarea);\n tareaBorrada.remove();\n}", "title": "" }, { "docid": "fbf3cc90ebadb25f1d7b6ff044509835", "score": "0.49676913", "text": "async function deleteGame(game_time){\n try{\n let gameid_to_delete = await DButils.execQuery(`SELECT gameid FROM Games Where GameDateTime = '${game_time}'`)\n await DButils.execQuery(`DELETE FROM Games Where gameid = '${gameid_to_delete[0][\"gameid\"]}'`)\n let eventids_to_delete = await DButils.execQuery(`SELECT eventid FROM GamesEvents Where gameid = '${gameid_to_delete[0][\"gameid\"]}'`)\n await DButils.execQuery(`DELETE FROM GamesEvents Where gamesids = '${gameid_to_delete[0][\"gameid\"]}'`)\n //MISSING CORRESPONDING EVENTS DELETION FELL BEFORE (reason -> wrong column input [gamesids])\n eventids_to_delete.map(async (eventid) =>{\n await DButils.execQuery(`DELETE From Events WHERE \n eventid = '${eventid}'`);\n });\n return true\n }\n catch(error){\n next(error);\n }\n}", "title": "" }, { "docid": "780234cbcfdf971b64e7e61ab78be7cd", "score": "0.49523184", "text": "function deleteItem(e) {\n let $selectedCatch = $(e.target);\n let $parent = $selectedCatch.parent();\n let id = $parent.attr(\"data-id\");\n request.delete(id, onSucced, onError);\n}", "title": "" }, { "docid": "2cb0aa9d94824248887765ddf9eb12f4", "score": "0.49463812", "text": "function confirmDelete() {\n\t\t\t// hide the alert modal,\n\t\t\t$('#alert-modal').modal('hide');\n\t\t\t// grab the index of the event in our $scope.events array,\n\t\t\tlet index = $scope.events.indexOf($scope.event);\n\t\t\t// and delete it from the array\n\t\t\t$scope.events.splice(index, 1);\n\t\t}", "title": "" }, { "docid": "dec8143e78a7416133bc16931bdb9945", "score": "0.49447685", "text": "function click_shared_pending_mission_delete(context, event) {\n\tshared_pending_mission = context\n\n\thttp_actions.sharedPendingMissionDelete(shared_pending_mission)\n}", "title": "" }, { "docid": "3457612e02cedaf0800fcd1eb94290bf", "score": "0.4944091", "text": "removeClient(trainerId, memberId) {\n const trainer1 = this.getTrainerById(trainerId);\n const assessmentsTemp = trainer1.clients;\n let index =-1;\n // just in case the clients object does not exist\n if(trainer1.clients === null || trainer1.clients === undefined) {\n //do nothing\n } else if(trainer1.clients.length === 0){\n //do nothing\n } else {\n for (let i = 0; i < trainer1.clients.length; i++) {\n if(trainer1.clients[i].id === memberId) {\n index = i;\n }\n \n }\n }\n \n if (index != -1) {\n assessmentsTemp.splice(index, 1);\n trainer1.clients = assessmentsTemp;\n }\n \n this.store.save();\n\n}", "title": "" }, { "docid": "04182db1d4dce3838ffc02e62e547027", "score": "0.49426553", "text": "removeRow(e) {\n if (this.eventSave = \"update\") {\n var idDetail = $($(e.target).parents(\"tr\")).attr(\"iddetail\");\n if (idDetail != null) {\n var path = \"/outwarddetail/delete/\" + idDetail;\n this.outward.deleteData(path);\n } \n }\n $('tbody tr.row-focus').remove();\n this.totalRow();\n this.totalQuatityMoney();\n this.detectPresentScroll();//check scroll present\n }", "title": "" }, { "docid": "12a0953300dfca6e95ccea55ff256dd5", "score": "0.49375793", "text": "'delete regional analysis' (state, action) {\n const id = action.payload\n return {\n ...state,\n regionalAnalyses: state.regionalAnalyses.filter(r => r._id !== id)\n }\n }", "title": "" }, { "docid": "c1c3c04cbc89fd3e6cec64fab05731f6", "score": "0.4933269", "text": "function clearareas()\n{\n\tfor (i in watchareas) {\n\t\twatchareas[i].remove();\n\t}\n\twatchareas = [];\n}", "title": "" }, { "docid": "b04be8e8f1885d5ea3e87f3880940cf6", "score": "0.4932651", "text": "static deleteDino(e) {\n const id = e.target.dataset.id\n const byeDino = document.getElementById(id)\n fetch(`${this.ALL_DINOSAURS_URL}/${id}`, {\n method: \"DELETE\",\n headers: { \"Content-Type\": \"application/json\" }\n })\n .then(response => response.json())\n .then(byeDino.remove())\n }", "title": "" }, { "docid": "825938de535ced4150ae25b59b79c87c", "score": "0.49272507", "text": "DeleteFixture() {\n console.log(\"[FIXTURE] DELETE START\");\n\n let self = this;\n\n for (var i = self.ProductGroupArray.length - 1; i >= 0; i--) {\n var productGroup = self.ProductGroupArray[i];\n productGroup.DeleteProduct();\n }\n\n switch (self.Type.toUpperCase()) {\n case \"SHELF\": {\n self.Group.destroy();\n self.ClientRect.destroy();\n }\n break;\n case \"PEGBAR\": {\n self.Group.destroy();\n self.ClientRect.destroy();\n }\n case \"PEGBOARD\": {\n\n }\n break;\n }\n self.Store_RemoveFixtureFromGondola(self);\n\n self.CallFixture_CalculateShelfHeightsForGondola(self.GondolaID);\n self.Layer.draw();\n console.log(\"[FIXTURE] DELETED\");\n }", "title": "" }, { "docid": "dd699f9d995ba9ba9e7498d39aa05721", "score": "0.49271098", "text": "removeEvents(){\n\n }", "title": "" }, { "docid": "5e9d51871f9545c17a543af9768837f4", "score": "0.49253207", "text": "function eliminarTarea(id){\n\tconsole.log('eliminarTarea(' + id + ')');\n\tfor(var i = 0; i<tareasDB.length; i++)\n\t{\n\t\tif(tareasDB.id==id){\n\t\t\ttareasDB.splice(i,1);\n\t\t\treturn;\n\t\t}\n\t}\n}", "title": "" }, { "docid": "43475137b2578486eb4a54b6885f13c0", "score": "0.49229032", "text": "deleteOrg(orgId){\n if(window.confirm('Are you sure?')){\n fetch('/organizations/'+orgId, {\n method:'DELETE',\n headers: {'Accept':'application/json','Content-Type':'application/json'}\n })\n }\n this.refreshOrgs();\n }", "title": "" }, { "docid": "a77317c4372146588a581d9f91685f94", "score": "0.49195036", "text": "_handleDeleteRow(e) {\n this.deleteRow(e.detail);\n }", "title": "" }, { "docid": "fd672be069ea005a1376d59772c37baa", "score": "0.49146253", "text": "function deleteCallback(targetEvent){\n var scene=targetEvent.scene;\n if(!targetEvent.target) return;\n if(targetEvent.target.connectors)\n if(targetEvent.target.connectors.count>0){\n var dialog=new AlertDialog(AlertMsg.disableToDelete_Title_CN);\n dialog.show();\n return;\n }\n\n var target=targetEvent.target;\n var args={};args.obj=target;\n args.scene=scene;\n var revmoveAction=new RemoveAction(args);\n JTopo.editor.toolManager.addUndoAction(revmoveAction)\n //if(target.removeFromScene) target.removeFromScene(scene);\n \n //else scene.remove(target);\n scene.remove(target);\n }", "title": "" }, { "docid": "0b0ad8c6d3f5bba784af29f4de89f718", "score": "0.49100107", "text": "function deleteTask(e) {\n e.currentTarget.remove();\n}", "title": "" }, { "docid": "6132d6cf74aa1030feba3624fdde3483", "score": "0.49085498", "text": "function deleteRoad() {\r\n\tfor(var i = 0; i < drumDescris.length ; i++)\r\n\t{\r\n\t\tdrumDescris[i].setMap(null);\r\n\t}\r\n\tdistanceR = 0;\r\n}", "title": "" }, { "docid": "9c41f322f58ba59f78d6ce050e9d832a", "score": "0.49072763", "text": "function removeListing(){\n let listingId = event.target.parentElement.id \n // debugger \n event.preventDefault()\n \n const configObj = {\n method: 'DELETE',\n headers:{\n 'Content-Type': 'application/json',\n 'Accept':'application/json'\n }\n }\n \n fetch(BASE_URL + `/${listingId}`,configObj) //DELETE request to listings \n event.target.parentElement.remove()\n \n}", "title": "" }, { "docid": "f6d07e4100fd31224b347ccd4b6f910b", "score": "0.48988333", "text": "async deleteEvent(req, res) {\n // Pegar o id do evento\n const { id } = req.params\n // Deletar evento\n const deletedEvent = await Events.findByIdAndDelete(id).catch(() => { error = true })\n // Ver se deletou alguma coisa\n if (!deletedEvent || error) {\n return res.status(404).json({ error: 'event not found' })\n }\n // Deletar a postagem deste evento\n const deletedPost = await Posts.findByIdAndDelete(deletedEvent.postId).catch(() => { error = true })\n // Ver se deletou\n if (!deletedPost || error) {\n return res.status(404).json({ error: 'this event post was not found, delete manualy' })\n }\n // Deletar imagem da aws\n deletedPost.image && awsFunctions.deleteFile(deletedPost.image, bucketName)\n // Confirmação\n return res.status(200).json({ message: 'event deleted' })\n }", "title": "" }, { "docid": "41718fca25520b4a34bd7adb9caa5100", "score": "0.48954746", "text": "async removeAlertTableRow() {\n const target = parseInt(this.props.state.clickedAlertTableRowID);\n\n if (this.state.maxNumberOfAlertTableRows < 1\n || isNaN(target) || (target === null || target === undefined))\n return;\n\n\n let pointer;\n let start = 0;\n let end = this.state.alertTableStocks.length - 1;\n let alertTableStocks = [];\n\n let deleteId;\n\n for (pointer = start; pointer <= end; pointer++) {\n // console.log('alertTableId ' + pointer + ' target ' + target);\n if (pointer === target) {\n deleteId = pointer;\n continue;\n }\n else\n alertTableStocks.push(this.state.alertTableStocks[pointer]);\n }\n\n await fetch('deletesavedstocks/'.concat(this.map.get(target)))\n .then(response => response.status)\n .then(response => {\n if (!response.ok) {\n // 404 \n return;\n }\n })\n .catch(error => {\n console.log(\"error \" + error) // 404\n return;\n }\n );\n\n console.log('delete id ' + deleteId);\n\n if ((deleteId !== null || deleteId !== undefined))\n this.map.delete(deleteId);\n else\n return;\n\n this.setState({ maxNumberOfAlertTableRows: this.state.maxNumberOfAlertTableRows - 1 });\n this.setState({ alertTableStocks: alertTableStocks });\n this.setState({ removeAlertTableRowBool: true });\n }", "title": "" }, { "docid": "4de1fab0a69f40fa0f8a1094536276be", "score": "0.48920962", "text": "uninterested(id) {\n var data = {eventID: id, username: this.props.userData.username};\n fetch(\"http://localhost:5000/users/uninterestedEvents/\" + id + \"/\" + this.props.userData.username, {\n method: 'DELETE',\n headers: {\n 'content-type': 'application/json'\n }\n })\n .then(res => res.json())\n .catch(error => console.error('Error:', error))\n .then(response => {\n this.props.notInterested(id)\n this.getAllEvents()\n });\n }", "title": "" }, { "docid": "8290b94737886319f4c42aba1d7986cc", "score": "0.4890419", "text": "deleteConfig(id) {\n console.log(`Deleting ${id}`);\n delete this.store.items[id];\n Object.keys(this.store.map).forEach((mapKey) => {\n if (this.store.map[mapKey] === id) {\n delete this.store.map[mapKey];\n }\n });\n\n this._save();\n }", "title": "" }, { "docid": "9eac8c334f01dd5323c91177dd6a669b", "score": "0.48886323", "text": "function removeArea(product){\r\n const removeProduct = document.getElementById('remove-' + product);\r\n removeProduct.addEventListener('click', function(){\r\n const productArea = document.getElementById(product + '-area');\r\n productArea.style.display = \"none\";\r\n })\r\n}", "title": "" }, { "docid": "7550c1baa186fc569938eedb800dfd55", "score": "0.48865166", "text": "deleteByKey(key) {\n const item = this.ID[key] || this.SN[key];\n if (item) {\n delete this.ID[item.id];\n delete this.SN[item.system_name];\n const index = this.sections.findIndex(item => item.id === section.id);\n delete this.sections[index];\n }\n }", "title": "" }, { "docid": "5c826bf408b75b75e8e63b5662385c47", "score": "0.48848328", "text": "onUnload(callback) {\n var _a;\n try {\n for (const id in this.scheduleIdToSchedule.keys()) {\n (_a = this.scheduleIdToSchedule.get(id)) === null || _a === void 0 ? void 0 : _a.removeAllTriggers();\n }\n this.scheduleIdToSchedule.clear();\n this.log.info('cleaned everything up...');\n callback();\n }\n catch (e) {\n callback();\n }\n }", "title": "" }, { "docid": "5b66aa4f5e836e4f891ae4a05e9bc996", "score": "0.48783836", "text": "del(e)\n {\n var movieId = e.currentTarget.id;\n var self = this;\n request.delete('/movie/delete').send({id: movieId}).end(function(err, res) {\n if(err){\n console.log(\"error:\" + err);\n }else{\n for(var i=0;i<self.state.movieArr.length;i++){\n if(self.state.movieArr[i]._id === movieId){\n self.state.movieArr.splice(i, 1);\n }\n }\n self.setState({\n movieArr: self.state.movieArr\n })\n }\n })\n }", "title": "" }, { "docid": "a4c87a2d34d7728a58ef8025ddb88269", "score": "0.48738465", "text": "function deleteSaved() {\n console.log(\"Unsave Clicked!\")\n var savedArticle = $(this).data(\"id\");\n console.log(savedArticle);\n $(this)\n .parents(\".newsArticle\")\n .remove();\n $.ajax({\n method: \"PUT\",\n url: \"/api/unsave/\" + savedArticle,\n }).then(function (data) {\n if (!data.saved) {\n console.log(\"unsaved\")\n }\n });\n }", "title": "" }, { "docid": "66772228020ef415e10424363b2dfd0d", "score": "0.48690027", "text": "function deleteSensorData() {\n deleteCollection(firestore, \"sensors\", 100);\n}", "title": "" }, { "docid": "bd8c7cfdc2863720dd1c7b34baba16c7", "score": "0.4865352", "text": "function delete_enclosure(id){\n const key = datastore.key([ENCL, parseInt(id,10)]);\n return datastore.delete(key);\n}", "title": "" } ]
88151d9f3d1921d55250eeddf914949d
access methods get categories
[ { "docid": "df7c5ea113548681fefd97ebc99bbc5a", "score": "0.0", "text": "function find() {\n return db('categories').orderBy('category_id')\n}", "title": "" } ]
[ { "docid": "602092fc34db495a26bd7c341d59a488", "score": "0.76957566", "text": "getCategories() {\n return fetch(this.baseURL + '/categories').then(res => res.json()\n );\n }", "title": "" }, { "docid": "66dde356626bebcc523c2110b5d5cbeb", "score": "0.76660305", "text": "category () {\n\t\t\treturn this.categoryItems;\n\t\t}", "title": "" }, { "docid": "ac169c751d01493ee722f2e3fb37ce9a", "score": "0.7643748", "text": "categories () {\n\t\t\treturn this.categoriesObj;\n\t\t}", "title": "" }, { "docid": "419338b8083335d20cda39200388f1ac", "score": "0.760073", "text": "function getCategories(){\n\t\treturn $http.get(host+\"/categories\", []).\n\t\t\tthen(end);\n\t}", "title": "" }, { "docid": "1377d0d0b7c42d85df8c7ed5edd17b6d", "score": "0.7599246", "text": "getAllCategories() {\n return this.categories;\n }", "title": "" }, { "docid": "bc4346433160f64f786a852f3556cef4", "score": "0.7598257", "text": "function getCategories(){\n categoryService.getCategories({parent_slug: 'promotions'})\n .then(function (data) {\n $scope.categories =data.categories;\n $scope.cat_loading = false;\n })\n .catch(function (data) {\n\n })\n }", "title": "" }, { "docid": "d838a17913d1912ce5827f868de4d913", "score": "0.74797577", "text": "GetAllCategories(){\n return this.category;\n }", "title": "" }, { "docid": "6932c025361cbe067d7f3d9d112f5dbc", "score": "0.741961", "text": "function loadCategories() {\n return Object(_http_services__WEBPACK_IMPORTED_MODULE_0__[\"http\"])().get('/api/get-categories');\n}", "title": "" }, { "docid": "07476aa1e40d683a8e8ca798b3ed2d62", "score": "0.741567", "text": "function get_categories() {\n return $http.get('/api/books/categories/').then(function(response){\n angular.forEach(response.data, function(category){\n s.categories[category.id] = category;\n });\n });\n }", "title": "" }, { "docid": "3aa98f4c1879816e08f8a65f33021cfa", "score": "0.74034214", "text": "function getCategory() {\n $.get(\"/api/category\", renderCategoryList);\n }", "title": "" }, { "docid": "05cd4db4456416f4dcdb14cb7aa2ec1b", "score": "0.7275761", "text": "function GetCategories() {\r\n var accountNumber = \"\";\r\n services.getService(apiUrl.category.Get(accountNumber)).then(function (response) {\r\n });\r\n}", "title": "" }, { "docid": "1ab8fabfb8d3a27f4512684d1ad9295b", "score": "0.7247235", "text": "async function getCategories() {\n let categories = await request(\n `${process.env.REACT_APP_SERVER_URL}${endpoints.categories}`,\n getAccessTokenSilently,\n loginWithRedirect,\n \"GET\",\n );\n\n if (categories && categories.length > 0) {\n console.log(categories);\n setCategories(categories);\n }\n }", "title": "" }, { "docid": "bad0f09c99ba2cfb188f58af4d78a862", "score": "0.7190675", "text": "function getCategory(c){ //*D4EL\n debugger;\n\treturn getCategoryObject(categorizeArticle(printArticle(c.term)));\n}", "title": "" }, { "docid": "8297885c25ffa8a7c98fc887525620e4", "score": "0.7152196", "text": "getCategoria(){\n return this.l_categoria;\n }", "title": "" }, { "docid": "a7624ca517023353a21967c3c9dc4dd6", "score": "0.7110101", "text": "get category () {\n\t\treturn this._category;\n\t}", "title": "" }, { "docid": "a7624ca517023353a21967c3c9dc4dd6", "score": "0.7110101", "text": "get category () {\n\t\treturn this._category;\n\t}", "title": "" }, { "docid": "5afc6c868c6bc1632e24d91293ae1e62", "score": "0.7072334", "text": "get category(){\n\t\treturn this._category;\n\t}", "title": "" }, { "docid": "88c332c2ad4f6b0a58ded1f134b7b57f", "score": "0.707002", "text": "getCategories() {\n\n\t\tlet xmlHttp = new XMLHttpRequest();\n\t\tlet c = null;\n\t\txmlHttp.open(\"GET\", \"https://developers.zomato.com/api/v2.1/categories\", true);\n\t\txmlHttp.setRequestHeader(\"user-key\", this.state.key);\n\t\txmlHttp.setRequestHeader(\"Accept\", \"application/json\");\n\t\txmlHttp.onload = function () {\n\t\t\tif (xmlHttp.readyState === 4) {\n\t\t\t\tif (xmlHttp.status === 200) {\n\t\t\t\t\tlet categories = JSON.parse(xmlHttp.response).categories;\n\t\t\t\t\tc = categories.map(function (element) {\n\t\t\t\t\t\treturn element.categories.name;\n\t\t\t\t\t});\n\t\t\t\t\t// console.log(c);\n\t\t\t\t} else {\n\t\t\t\t\tconsole.error(\"not ok\");\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\n\t\txmlHttp.onloadend = () => {\n\t\t\tlet newState = this.state.showZomatoCategoies\n\t\t\tthis.setState({\n\t\t\t\tcategories: c,\n\t\t\t\tshowZomatoCategoies: !newState\n\t\t\t}\n\t\t\t)\n\t\t}\n\t\txmlHttp.send();\n\t}", "title": "" }, { "docid": "4bacbbb414768281d03a332bcabd1bb6", "score": "0.7066146", "text": "async function getCategories() {\n // const response = await services.getAllAds();\n // console.log(response.categories)\n const categories = [{_id: 3, category: \"Робота\"},{_id: 2, category: \"Транспорт\"},{_id: 4, category: \"Електроніка\"},{_id: 5, category: \"Бізнес та послуги\"},{_id: 7, category: \"Віддам безкоштовно\"},{_id: 8, category: \"Обмін\"},{_id: 6, category: \"Відпочинок і спорт\"},{_id: 1, category: \"Нерухомість\"},];\n return categories;\n }", "title": "" }, { "docid": "f80bedb2635f30d7751223e8eb94d2ae", "score": "0.70644045", "text": "extractCategories() {\r\n return Array.from(\r\n this._page.getElementById(\"catlinks\").getElementsByTagName(\"a\")\r\n ).map( link =>\r\n new Category(link.innerHTML, link.href)\r\n )\r\n }", "title": "" }, { "docid": "1d1339c79768dfb1582a664b0be34a57", "score": "0.7053379", "text": "get category() {\n\t\treturn this.__category;\n\t}", "title": "" }, { "docid": "2074d1aa03bff6d8dcfaab5cb265bea5", "score": "0.70110524", "text": "getCategories(){\n var url = Meteor.settings.spotify.url + '/browse/categories'\n\n var spotifySync = Meteor.wrapAsync(spotifyAsync);\n return spotifySync(url);\n }", "title": "" }, { "docid": "e8c160c62b6526a4ab5f67a0aa92cd81", "score": "0.7001537", "text": "function _getCatogary(){\n\t\t\tsalesfactoryData.getData(categorylisturl,'GET',{action : \"productCatEdit\"})\n\t\t\t.then((r)=>{\n\t\t\t\tif(r.data)\n\t\t\t\t $scope.prdData.cateTree=r.data;\n\t\t\t},(err)=>_error());\n\t\t}", "title": "" }, { "docid": "9afaee2782e2731969c65cce273f0b3e", "score": "0.698206", "text": "einsteinCategories() {\n return this.endpoint.get(this.path('/einstein/unlocked-categories'));\n }", "title": "" }, { "docid": "74d9c20da6254efcfcd546600c3ee3ee", "score": "0.6971525", "text": "function manage_categories() {\r\n\tvar data = {};\r\n\tdata.categories = app.getObjects(\"Category\",{},{sort:{title:\"asc\"}});\r\n\treturn this.manage_wrap({content: this.manage_categories_view(data) });\r\n}", "title": "" }, { "docid": "77e6229b4f128a75c5a26fd042b17cb6", "score": "0.6971084", "text": "get isCategory() {\n return this.i.cl;\n }", "title": "" }, { "docid": "3ccf595de02a07ba20cac48627fc0e18", "score": "0.69648325", "text": "async function getCategories() {\n const result = await axios\n .get(\"http://localhost:5000/api/video-categories\")\n .catch((error) => {\n throw error?.response?.data\n })\n\n // Set the state if categories are available\n if (result && result.data) setCategories(result.data.data)\n }", "title": "" }, { "docid": "defc47872d9e0495d13f61f1e5addbf2", "score": "0.69602287", "text": "getCategories(pages, cb){\n\t this.api(this.categoriesEndPoint).then((response)=>{\n const categories \t= response\n const pagesAndcats \t= { pages, categories };\n // rightio, send this on to the getPosts method\n this.getPosts(pagesAndcats, cb)\n\t \t});\t\t\n return true; \n\t}", "title": "" }, { "docid": "39ea6bd1cc9dc247ea0364927979cc16", "score": "0.6959366", "text": "function getCategories() {\n var api = 'http://www.bestbuy.ca/api/v2/json/category/Departments';\n return $http({\n method:'GET',\n url: api\n })\n\n }", "title": "" }, { "docid": "f6122e783eb943d4433d4a5eef27b7ce", "score": "0.69550705", "text": "function fetchCategories() {\n fetch(API + \"categories\")\n .then(checkStatus)\n .then(JSON.parse)\n .then(function(categories) {\n displayCategories(categories);\n mapCategories(categories);\n })\n .catch(displayError);\n }", "title": "" }, { "docid": "15a0893e3696c29a54f3e981d93cef50", "score": "0.6928462", "text": "function getProductCategory(){\n return Restangular.all('product/category').getList().then((data) =>{\n $log.info('success', 'Products category fetched');\n return data;\n }, function(err) {\n toaster.pop('error', 'Api error.', 'error connect to api to fetching product category.');\n });\n }", "title": "" }, { "docid": "3a856260b6d3e40e2599d7854fe441bf", "score": "0.6905528", "text": "async getCategories(){\r\n const apiResponce = await fetch('https://www.thecocktaildb.com/api/json/v1/1/list.php?c=list');\r\n\r\n const categories = await apiResponce.json();\r\n\r\n return{\r\n categories\r\n }\r\n }", "title": "" }, { "docid": "514919fd170cbedd13d4462bd63bed0c", "score": "0.6887829", "text": "function listCategories () {\n return norrisClient.then(_mapToEndpoints()).then(_listCategories).then(prop('body'))\n}", "title": "" }, { "docid": "45073e3411659beee428c9d41f4eef9d", "score": "0.6861463", "text": "async obtener_categorias() {\n\n //consultar las categorias a la REST API\n const respuesta = await fetch(`https://app.ticketmaster.com/discovery/v2/classifications?apikey=${this.api_key}&locale=*`);\n\n //esperar la rta de las categorias y devolver un json\n const categorias = await respuesta.json();\n\n return {\n categorias\n };\n }", "title": "" }, { "docid": "3dc9476b2d4d7cb753eec6db89c7a485", "score": "0.6838223", "text": "async getCategoriesAPI() {\n // Query the API\n const categoriesResponse = await fetch(`https://www.eventbriteapi.com/v3/categories/?token=${this.auth_token}`);\n\n // Hold for the response and then return as json\n const categories = await categoriesResponse.json();\n\n return {\n categories\n }\n }", "title": "" }, { "docid": "7d78bcebd87010b99642a67e69559dde", "score": "0.67933095", "text": "function getCategories() {\n $.getJSON('api/categories/', (categories) => {\n\n $.each(categories, (index, category) => {\n $(\"#categoryList\").append($(\"<a />\")\n .text(category.Category)\n .attr(\"class\", \"dropdown-item\")\n .attr(\"href\", \"#\")\n .on(\"click\", (e) => {\n e.preventDefault();\n //$(\"body\").removeClass(\"home\");\n $(\"#categoryName\").text(category.Category);\n getServices(category.Value);\n }));\n });\n });\n }", "title": "" }, { "docid": "958544024c9a6b23d14bf0cd71e6adba", "score": "0.6785666", "text": "async obtenerCategorias() {\n // Consultar las categorias a la REST API de eventbrite\n const respuestaCategorias = await fetch(`https://www.eventbriteapi.com/v3/categories/?token=${ this.token_auth }`);\n\n // Esperar la respuesta de as categorias y devolver el JSON\n const categorias = await respuestaCategorias.json();\n\n // Devolvemos el resultado\n return {\n categorias\n }\n }", "title": "" }, { "docid": "f4620f8e926370498659c364a14fd51c", "score": "0.6778474", "text": "getAllBlogCategories() {\n return this.repository.getAllBlogCategories();\n }", "title": "" }, { "docid": "b916919b0d7c89873fd203da66072f50", "score": "0.67561257", "text": "function GetCategories2() {\r\n var accountNumber = \"\";\r\n services.getService(apiUrl.category.Get(accountNumber)).then(function (response) {\r\n });\r\n}", "title": "" }, { "docid": "05fc3ecab652730e3e74aec00d483153", "score": "0.67527664", "text": "function getCategories(key, callbackFunc){\n\t\t\tvar dir = 'https://api.themoviedb.org/3/genre/movie/list?api_key=' + key + content;\n\t\t\tcallApi(dir, callbackFunc);\n\t\t}", "title": "" }, { "docid": "aafb4e300d5aadfd6f213fbf085ceb66", "score": "0.6744505", "text": "function getCategories() {\n categories.forEach(function(category) {\n \n categoryName = category.category.charAt(0).toUpperCase() + category.category.substr(1);\n\n $(\"#category-list\").append(`\n <li class=\"category list-group-item\" data=${category.class}>${category.class} - ${categoryName}</li>\n `)\n })\n}", "title": "" }, { "docid": "436409274f5e5287c4aa4f601da99815", "score": "0.6732334", "text": "async function getAllTheCategories() {\n const API_URL = \"https://www.themealdb.com/api/json/v1/1/categories.php\";\n let response = await fetch(API_URL);\n let categoryData = await response.json();\n setMenuCategory(categoryData.categories);\n }", "title": "" }, { "docid": "c80763412644ce3fd5005d53cf89f7d7", "score": "0.67307127", "text": "async getCategories() {\n\n try {\n let url = `https://www.thecocktaildb.com/api/json/v1/1/list.php?c=list`;\n\n const apiResponse = await fetch(url);\n const categories = await apiResponse.json();\n // return console.log(recipeInfo) \n return {\n categories\n }\n } catch (error) {\n ui.printMessage(error.message, 'alert-danger')\n }\n }", "title": "" }, { "docid": "4a5bc1f2b702c7730ac7f38fcd902b7e", "score": "0.6722057", "text": "function getCategories() {\n return $.get(\"https://opentdb.com/api_category.php\")\n .then(res => res.json())\n .then(res => res.trivia_categories);\n}", "title": "" }, { "docid": "142bfd971eb61cb7b629354d473c5521", "score": "0.67109954", "text": "function requestGetAllCategories() {\n return { type: REQUEST_GET_ALL_CATEGORIES };\n}", "title": "" }, { "docid": "dcfe4e6879be71669418340463703504", "score": "0.6708727", "text": "function getCategories(q) {\n let url = buildUrl(\"categories\");\n getData(url).done(result => {\n renderDrinkInfo(result);\n });\n}", "title": "" }, { "docid": "9820866059a04da70af4540ab10ad419", "score": "0.6706076", "text": "getAllBriefcaseCategories() {\n\n if (!this.briefcaseCategories) {\n this.briefcaseCategories = this.getAllBriefcaseSlides().then(slides => {\n return slides.map(slide => slide.category)\n }).then(categories => {\n return Array.from(new Set(categories));\n })\n }\n\n return this.briefcaseCategories;\n }", "title": "" }, { "docid": "9cb0212cfa9ecdc91b451805f390b548", "score": "0.66805804", "text": "getAvailableCategories() {\n\t\tfetch(`https://maximum-arena-3000.codio-box.uk/api/categories`, {\n\t\t\tmethod: \"GET\",\n\t\t\tbody: null,\n\t\t\theaders: {\n\t\t\t\t\"Authorization\": \"Basic \" + btoa(this.context.user.username + \":\" + this.context.user.password)\n\t\t\t}\n\t\t})\n\t\t\t.then(status)\n\t\t\t.then(json)\n\t\t\t.then(dataFromServer => {\n\t\t\t\tthis.setState({\n\t\t\t\t\tcategories: dataFromServer,\n\t\t\t\t});\n\t\t\t\tconsole.log(dataFromServer, 'categories here')\n\t\t\t})\n\t\t\t.catch(error => {\n\t\t\t\tconsole.log(error)\n\t\t\t\tmessage.error('Could not get the available categories. Try Again!', 5);\n\t\t\t});\n\t}", "title": "" }, { "docid": "2ae1ef1b731b320c7d3bb2203f43c7c3", "score": "0.6673921", "text": "function mooGetCategories()\n{\n if(window.moo_theme_setings.onePage_show_more_button === 'off') {\n jQuery.get(moo_RestUrl+\"moo-clover/v1/categories?expand=all_items\", function (data) {\n if(data!=null && data.length>0) {\n moo_renderCategories(data,false);\n } else {\n var element = document.getElementById(\"moo-onlineStore-items\");\n var html = 'You don\\'t have any category please import your inventory';\n jQuery(element).html(html);\n }\n });\n } else {\n jQuery.get(moo_RestUrl+\"moo-clover/v1/categories?expand=five_items\", function (data) {\n if(data!=null && data.length>0) {\n moo_renderCategories(data,true);\n } else {\n var element = document.getElementById(\"moo-onlineStore-items\");\n var html = 'You don\\'t have any category please import your inventory';\n jQuery(element).html(html);\n jQuery('#MooLoadingSection').hide();\n }\n });\n }\n\n\n}", "title": "" }, { "docid": "003c78343daf8ca7c99c240bf48b6e01", "score": "0.6648406", "text": "function Category() {\n}", "title": "" }, { "docid": "e1aa043c625a0de41146b8fd5703a84b", "score": "0.66366744", "text": "async function categories(){\n const response = await fetch(\"https://cccpharma-api-jjlm.herokuapp.com/categories\");\n try{\n const json = await response.json();\n return json;\n\n }catch(e){\n return \"Não foram encontradas categorias\";\n }\n}", "title": "" }, { "docid": "c019d6abb5547572ac060cd630835142", "score": "0.66289955", "text": "async function getCategories() {\n let catArr = [];\n const response = await fetch(catUrl);\n const data = await response.json();\n catArr = data.trivia_categories;\n return catArr;\n}", "title": "" }, { "docid": "75c951db49029edd8465ff814b010a11", "score": "0.6627876", "text": "function getCategories(menu) {\n return Object.keys(menu); \n //use Object.keys() to run through menu and get keys, return \n}", "title": "" }, { "docid": "8d0994d77ecea44bd50d31e664a21ebf", "score": "0.66183484", "text": "function getCategories() {\n Office.context.mailbox.masterCategories.getAsync((asyncResult) => {\n if (asyncResult.status === Office.AsyncResultStatus.Failed) {\n console.log(asyncResult.error.message);\n return;\n }\n\n let selection = document.createElement(\"select\");\n selection.name = \"applicable-categories\";\n selection.id = \"applicable-categories\";\n selection.multiple = true;\n let label = document.createElement(\"label\");\n label.innerHTML =\n \"<br/>Select the applicable categories.<br/><br/>Select and hold <b>Ctrl</b> to choose multiple categories.<br/>\";\n label.htmlFor = \"applicable-categories\";\n\n asyncResult.value.forEach((category, index) => {\n let displayName = category.displayName;\n if (displayName.includes(\"Office Add-ins Sample: \")) {\n let option = document.createElement(\"option\");\n option.value = index;\n option.text = category.displayName;\n selection.appendChild(option);\n selection.size++;\n }\n });\n\n document\n .getElementById(\"categories-container\")\n .appendChild(label)\n .appendChild(selection);\n });\n}", "title": "" }, { "docid": "f1e22a76717ac314d747c2487aacb287", "score": "0.66137123", "text": "function getAccountingCategoryList(){\n api.expenseAccountSetting.getAccountingCategoryList()\n .success(function(data){\n $scope.categoryList = data;\n });\n }", "title": "" }, { "docid": "8007797205f2685ef4b70f036c76bfe2", "score": "0.6600843", "text": "async getCategory() {\n\t\t//getting 100 categories from Jeopardy API\n\t\tconst result = await axios.get('http://jservice.io/api/categories?count=100'); // is it neccessary to get 100 when number of categories is already defined?\n\t\tconst categoryIds = [];\n\t\tfor (let x = 0; x < this.width; x++) {\n\t\t\tconst random = Math.floor(Math.random() * result.data.length);\n\t\t\tcategoryIds.push(result.data[random].id);\n\t\t\tthis.topMostRowStyling(x, random, result);\n\t\t}\n\n\t\treturn categoryIds;\n\t}", "title": "" }, { "docid": "93b6e12ec18e026dab75b0619172c230", "score": "0.65770286", "text": "fetchCategories() {\n return fetch(WM_API_TAXONOMY_FULL_PATH)\n .then((response) => {\n if (!response.ok) throw response;\n return response.json();\n })\n .then(result => result.categories)\n .then((categories) => {\n this.categories = categories;\n })\n .catch((err) => { this.error = err; });\n }", "title": "" }, { "docid": "2e031a6a191d11292f92302281d4c67d", "score": "0.6563038", "text": "function getAllCategoryList(){\n return $q.when(db.allDocs({include_docs:true,startkey: 'category-', endkey: 'category-\\uffff'}))\n .then(function(docs){\n console.log('%%% get all categories',docs.rows)\n return $q.when(_.map(docs.rows, function(l){return l.doc.catName}))\n })\n }", "title": "" }, { "docid": "0acb7b115197d4bc3c90b38eaa0b8aa6", "score": "0.6560761", "text": "function get_categories(titles){\r\n\tvar filter = titles ? new OrFilter(titles.map(function(i){return new Filter({title: i})})) : {};\r\n\treturn app.getObjects(\"Category\", filter, {sort:{id:\"asc\"}});\r\n}", "title": "" }, { "docid": "9dbd5f9db592d4d245f46f9388447870", "score": "0.65484536", "text": "function get_category_list() {\n let cat_list = [];\n \n config.categories.map((category) => {\n let data = {}; \n data.text = category.name;\n data.value = category.id;\n cat_list.push(data);\n })\n \n return cat_list;\n }", "title": "" }, { "docid": "90e2e55b9b22560b4abec1d10ef127c7", "score": "0.65431136", "text": "function getAccountingCategoryList(){\n api.expenseAccountSetting.getAccountingCategoryList()\n .success(function(data){\n itemHasChildren(data);\n $scope.AccountCategoryList = data;\n });\n }", "title": "" }, { "docid": "e520a5fcb22bfec5b36e29178ad8ef07", "score": "0.6529105", "text": "getCats() {\n\t\treturn this.$http.get('/cats-data.json')\n\t}", "title": "" }, { "docid": "9cc6f4d9f6c54ab52f2876d72f03cf87", "score": "0.6518222", "text": "function getAllCategories() {\n $.get('/category/all/' + localStorage.getItem('token'), (allCategories) => {\n displayAllCategories(allCategories);\n });\n}", "title": "" }, { "docid": "0f2c6a1c3a9e3699c8ed85358c5f3f96", "score": "0.65148276", "text": "function fetchCategories() {\n $.get(BASE_URL + '/sellers/prod_categories_partial', function (res) {\n $('#categories').html(res);\n });\n }", "title": "" }, { "docid": "b88f7e4f17b3aa75aa1bc1fdd6c52656", "score": "0.6514537", "text": "_handleGetCategories() {\n const categoriesLoader = this.getCategories();\n\n categoriesLoader.then((categoriesData) => {\n let categoriesDataStr = JSON.stringify(categoriesData);\n this._eventLoop.emit(EventNames.CATEGORIES_GET_LOADED, this._buildEventData(categoriesDataStr));\n }, (errorData) => {\n let errorDataStr = errorData.toString();\n this._eventLoop.emit(EventNames.CATEGORIES_GET_LOADED, this._buildEventData(errorDataStr));\n });\n }", "title": "" }, { "docid": "065ee804cffb9aed9d005ea6d95ddcf6", "score": "0.6510384", "text": "async loadCategories() {\n this.setState({ loading: true })\n try {\n const res = await fetch(`/admin-data?categories`)\n const { error, data } = await res.json()\n if (error) this.setState({ error })\n else {\n const categories = data.map(({ _id, title }) => ({\n value: _id,\n title,\n }))\n this.setState({ categories })\n }\n } catch (error) {\n this.setState({ error })\n } finally {\n this.setState({ loading: false })\n }\n }", "title": "" }, { "docid": "e2b8b37267f5042d91bbbc90a3544e1a", "score": "0.6509424", "text": "async obtenerCategorias(){\n // Consultar las categorias a la REST API de event brite\n const responseCategorias = await fetch(`https://www.eventbriteapi.com/v3/categories/?token=${this.tokenOAuth}`);\n // Esperar la respuesta de las categorias y devolver un JSON\n console.log(responseCategorias);\n const categorias = await responseCategorias.json();\n console.log(categorias);\n // Devolvemos el resultado\n return{\n categorias\n }\n }", "title": "" }, { "docid": "d3066a1515639c615d4190a3884ecf1b", "score": "0.6507027", "text": "function getMainCategories() {\n\t\tAdminService.categories().get({ sort: 'name', type: 'video', isActive: true }, function (response) {\n\t\t\tif (response.code == 200) {\n\t\t\t\tvm.mainCategoryList = response.data;\n\t\t\t}\n\t\t})\n\t}", "title": "" }, { "docid": "a2c4639d0db1a07c5ef56c05c62e053e", "score": "0.64623463", "text": "static loadCategoriesFromServer() {\n return fetch(`${API.serverHost}/categories`, { headers: { Authorization: 'whatever-you-want' } }).then(response => {\n if (!response.ok) {\n throw Error(response.statusText);\n }\n return response;\n }).then(response => response.json());\n }", "title": "" }, { "docid": "a8584d6e6a8a80a9b7ccd14251d97c8e", "score": "0.64547884", "text": "static getCategoryTag() { return SessionMgr.get('CategoryTag')}", "title": "" }, { "docid": "dd1612db23695f8cb6268a6b03fb10a5", "score": "0.6454294", "text": "function retrieveCategories(dictUrl){\n var ss = SpreadsheetApp.openByUrl(dictUrl)\n var sheet = ss.getSheets()[0];\n var values = sheet.getSheetValues(1, 1, -1, -1);\n var categories = [];\n for each(var value in values){\n cat = new Category(value[0], value[1], value[2]);\n categories.push(cat);\n }\n return categories;\n}", "title": "" }, { "docid": "d935ba33ff888d273af5a158f0d8de2c", "score": "0.64530116", "text": "async getCategories(){\n // get the category of each item\n var categories = [];\n var data = await this.getItems();\n data.forEach(function (item) {\n //console.log(!categories.includes(item.catalogCategory));\n if(!categories.includes(item.catalogCategory)){\n categories.push(item.catalogCategory);\n }\n \n });\n return categories;\n }", "title": "" }, { "docid": "f793845ffd78cad7034dd148a9abd67f", "score": "0.6442806", "text": "get_category_stores(res) {\n this.categoryStore.getCategory((err, store_data) => {\n if (err) {\n responseServices_1.mongoError(err, res);\n }\n else {\n responseServices_1.successResponse(responseServices_1.sms_get, store_data, res);\n }\n });\n }", "title": "" }, { "docid": "0872504dfd63dd5a8efa5fe4307acbf8", "score": "0.6421997", "text": "@action\n getCategoryList(budgetId) {\n return budgetService.getCategoryList(budgetId)\n .then((response) => {\n if (response.data.success) {\n return _.map(response.data.categories, category => ({\n value: category.id,\n label: category.name,\n id: category.id,\n key: 'Category',\n clearableValue: false,\n }));\n }\n return [];\n })\n .catch((err) => {\n console.error(err);\n });\n }", "title": "" }, { "docid": "960073e6fd18d0116a62c165805bf284", "score": "0.6420781", "text": "function getCategories(classifieds) {\n // set vategories to an empty array\n var categories = [];\n angular.forEach(classifieds, function(item) {\n angular.forEach(item.categories, function(category) {\n categories.push(category);\n });\n });\n // alert(categories); // Vehicles, Parts and Accessories, Clothing, Furniture, Electronics, Computer Parts and Accessories, Vehicles, Cars\n return _.uniq(categories); // Returns only unique categories (no duplicates)\n }", "title": "" }, { "docid": "55e337283d7a5108127a4a8c78b9bf81", "score": "0.641936", "text": "function getCategories(assetId) {\n js_api.getMetadata({\n \"asset_id\": assetId,\n \"dataCallback\": storeToArray\n });\n\n function storeToArray(object) {\n if (object[\"Selected.Topics.Nospace\"]) {\n arrayCategories = object[\"Selected.Topics.Nospace\"].split('; ');\n $('ul.topics-list .topics-list__item').each(function () {\n var $this = $(this);\n var category = $this.data('subscription').toString();\n if (arrayCategories.indexOf(category) != -1) {\n $this.addClass('active');\n }\n });\n }\n }\n}", "title": "" }, { "docid": "0f4d48420423b9a7f1a888daa99a97af", "score": "0.64165497", "text": "function pesquisarCategoria() {\n\n\n apiService.get('/api/subcategoria/categoria', null,\n categoriaLoadCompleted,\n categoriaLoadFailed);\n }", "title": "" }, { "docid": "1c7c42fe5449b9a9640643d8dda2220c", "score": "0.64105606", "text": "function getCategorias (req, res) {\n\tif (Object.keys(req.query).length > 0) {\t\t\n\t\tvar sql = `SELECT * FROM categorias `;\n\t\tvar connection = conectar();\n\t\tconnection.query(sql, function (err, result) {\n\t\t\tif (err) return res.status(500).send({ message: `Error al recuperar categorias: ${err}` });\n\t\t res.status(200).send({ result })\n\t\t});\n\t\tconnection.end();\n\t} else {\n\t\tvar sql = `SELECT * FROM categorias`;\n\t\tvar connection = conectar();\n\t\tconnection.query(sql, function (err, result) {\n\t\t\tif (err) return res.status(500).send({ message: `Error al recuperar categorias: ${err}` });\n\t\t res.status(200).send({ result })\n\t\t});\n\t\tconnection.end();\n\t}\n}", "title": "" }, { "docid": "e6c1212ce9c52c9c8be73b5a2b56f539", "score": "0.64096683", "text": "async getCategories(req, res, next) {\n const categories = await categoriesModel.find();\n res.json(categories);\n }", "title": "" }, { "docid": "22750d0009ef08655f6b56e49fea42e3", "score": "0.6405356", "text": "get subCategory () {\n return this._subCategory\n }", "title": "" }, { "docid": "fbab7a8c3b4b6ed22351d8c1de983528", "score": "0.64025605", "text": "async function getCategories (req, res) {\n //fetch data\n try {\n //get list of categories\n const response = await axios\n .get('https://www.eventbriteapi.com/v3/categories',\n {headers: { Authorization: oathString} });\n\n const data = await response.data.categories;\n res.json(data);\n\n } catch (error) {\n res.status(400).json('getCategories', error.response.status);\n }\n}", "title": "" }, { "docid": "f172749328afce87ef8bfea9d2c77131", "score": "0.64005405", "text": "function categorias() {\n var deferred = $q.defer();\n\n $http.get('/api/categoriasProductos/?format=json')\n .success(function (data) {\n deferred.resolve(data);\n });\n return deferred.promise;\n }", "title": "" }, { "docid": "a3051290dda0f597d617a1d374e7937b", "score": "0.6394689", "text": "function getCategories() {\n return new Promise(function (resolve, reject) {\n request.get(url)\n .end(function (res) {\n if (!res.ok) return reject(res.error);\n\n var $ = cheerio.load(res.text);\n var links = $('a.info-link');\n\n var categories = _.map(links, function (link, i) {\n $link = $(link);\n var href = urlResolve(url, $link.attr('href'));\n var title = $('h2', $link).html();\n title = title.replace(/(emoticons|emojis)/ig, '').trim().toLowerCase();\n return { title: title, href: href };\n });\n\n resolve(categories);\n });\n });\n}", "title": "" }, { "docid": "df64bcf151fa43261911107c89d6e34d", "score": "0.6384742", "text": "function getCategories(selectedCatID) {\n //var selectedCatID = \"cat00000\";\n kony.print(\"########## Selected Key:\" + selectedCatID);\n // Let's first check that the user picked a valid value\n if (!kony.string.equalsIgnoreCase(selectedCatID, \"none\")) {\n // Populating the input params for the service call and invoking the service\n var operationName = mobileFabricConfiguration.integrationServices[0].operations[0];\n var inputParams = {\n \"key\": mobileFabricConfiguration.bestByAPIKey,\n \"categoryID\": selectedCatID\n };\n //if (!kony.string.equalsIgnoreCase(selectedKey, \"none\")){\n //\tinputParams= {\"newsType\": selectedKey};\n // }else{\n //\t// The user didn't pick a value so we'll show the alert\n // kony.ui.Alert({ message: \"Please select a valid news type\",alertType:constants. ALERT_TYPE_INFO, alertTitle:\"Categories\",yesLabel:\"OK\"}, {});\n // }\n if (!mobileFabricConfiguration.isKonySDKObjectInitialized) {\n initializeMobileFabric(getCategories, selectedCatID);\n } else if (mobileFabricConfiguration.isKonySDKObjectInitialized) {\n getServiceResponse(operationName, inputParams, \"getting Best By Categories\", getCategoriesSuccessCallback);\n }\n } else {\n // The user didn't pick a value so we'll show the alert\n kony.ui.Alert({\n message: \"Please select a valid cat type\",\n alertType: constants.ALERT_TYPE_INFO,\n alertTitle: \"Categories\",\n yesLabel: \"OK\"\n }, {});\n }\n}", "title": "" }, { "docid": "e49ba92beb4d852f03bfef7bd416b611", "score": "0.63819635", "text": "function getCategories(callback) {\n $.ajax({\n url: getCategoryLookupIndexPath,\n cache: false,\n success: function(data) {\n categoryList = data;\n callback();\n }\n });\n }", "title": "" }, { "docid": "c3726ff8e9ff12cbe041fe082c64bde3", "score": "0.63685143", "text": "function loadCategories(){\n\t\t//Pega ano atual\n\t\tvar ano = new Date().getFullYear();\n\n\t\t//Carrega categorias\n\t\t$.ajax({\n\t\t\ttype: 'POST',\n\t\t\turl: 'modules/CashFlow/php/loadCategories.php',\n\t\t\tdata:{\n\t\t\t\tuserId: userId,\n\t\t\t\tano: ano\n\t\t\t},\n\t\t\tsuccess: function (data){\t\t\t\n\t\t\t\tvar json = $.parseJSON(data);\n\n\t\t\t\t//Cria variavel para guardar options de despesas\n\t\t\t\tvar optExpenses = \"\";\n\t\t\t\tvar optIncomes = \"\";\n\n\t\t\t\t//Itero retorno\n\t\t\t\tfor(var i = 0; i < json.length; i++){\n\t\t\t\t\t//Caso a categoria seja do tipo 'despesa', a mesma é adicionada no combo box de despesa\n\t\t\t\t\tif(json[i].categoryTypeId == 1){\n\t\t\t\t\t\toptExpenses += \"<option value = \" + json[i].id + \">\" + json[i].categoryName + \"</option>\";\n\t\t\t\t\t} else {\n\t\t\t\t\t\t//Caso a categoria seja do tipo 'receita', a mesma é adicionada no combo box de receita\n\t\t\t\t\t\toptIncomes += \"<option value = \" + json[i].id + \">\" + json[i].categoryName + \"</option>\";\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t\t//Guarda no DOM todas as opções de categoria\n\t\t\t\texpenseCategory.append(optExpenses);\n\t\t\t\tincomeCategory.append(optIncomes);\n\t\t\t}\n\t\t});\n\t}", "title": "" }, { "docid": "144eb23677a6d2dd18533078c16f5027", "score": "0.6367065", "text": "getCategories () {\n var categories = []\n categories.push(\n <ListGroupItem key='/'>\n <Link to='/'>\n All Posts\n </Link>\n </ListGroupItem>\n )\n for(let category in this.props.categories){\n let url = `/${category}`\n categories.push(\n <ListGroupItem key={category}>\n <Link to={url}>\n {category}\n </Link>\n </ListGroupItem>\n )\n }\n return categories\n }", "title": "" }, { "docid": "7beda5a316ae905866d30e089681b4da", "score": "0.6350602", "text": "findCategory(name) {\n return super.findCategory(name);\n }", "title": "" }, { "docid": "ef41db97d9d5d4a3c232661964283b2b", "score": "0.63497347", "text": "categoryItems()\n {\n return this.globalList.filter( (item) => { return item.type == \"category\" } );\n }", "title": "" }, { "docid": "eea53e7ccb7b9343e386aba5f344fe2a", "score": "0.63491464", "text": "static async getFullCategories(domain) {\n const categories = await this.where({ parentid_kategoriproduk: 0 }).fetchAll({ withRelated: ['subcategories'] });\n if (!categories) throw getCategoryError('category', 'not_found');\n return categories.map((category) => {\n const subCategories = category.related('subcategories').map(sub => sub.serialize(domain));\n return {\n ...category.serialize(domain),\n sub_categories: subCategories,\n };\n });\n }", "title": "" }, { "docid": "b3eab66899dc204c969243e3bf860cb4", "score": "0.634506", "text": "static getAllCategories(projectId){\n return new Promise(async (resolve, reject) => {\n try {\n const res = await axios.get(reqURL + '/projects/'+ projectId + '/categories?per_page=1000');\n const data = res.data;\n resolve(data);\n } catch (err){\n reject(err);\n }\n })\n }", "title": "" }, { "docid": "bcfe59bd89c32f2a6a75acecd6174e02", "score": "0.6334529", "text": "function storeCategories() {\n const holders = document.querySelectorAll('.js-store-category');\n\n for (let i = 0; i < holders.length; i++) {\n getCategory(holders[i]);\n }\n}", "title": "" }, { "docid": "0d0777745bd7a4cf912f2589c5f1df42", "score": "0.63315016", "text": "async function categoryLists(req, res) {\n try {\n var info = await models.Categories.findAll();\n if (info !== null && info.length > 0) {\n return res.status(200).json({\n info,\n code: 'CAT_200',\n msg: 'Listado de categorías.'\n });\n }\n\n return res.status(200).json({\n code: 'CAT_403',\n msg: 'Algo pasó al mostrar las categorías.'\n });\n } catch (error) {\n console.log(error);\n }\n}", "title": "" }, { "docid": "ddb2ff31dd48443e9030b09d20c1efdf", "score": "0.63199615", "text": "function get_db_itemcategories () {\n\n\tif (Object.keys(item_categories).length < 1 ) {\n\n\t\t$.ajax({\n\t\t\t\turl: base_url + '/api/itemcategories',\n\t\t\t\ttype: 'get',\n\t\t\t\tdata: {},\n\t\t\t\tsuccess: function (get_data) {\n\n\t\t\t\t\t$.each(get_data['data'], function(index, obj) {\n\t\t\t\t\t\titem_categories[obj['id']] = obj['description'];\n\t\t\t\t\t});\n\t\t\t\t}\n\t\t\t});\n\t} else {\n\t\t// do nothing if it's already been retrieved\n\t}\n}", "title": "" }, { "docid": "f69b8ef9a40eadedc11bc590c8aa28d6", "score": "0.6314749", "text": "async function getCategories() {\n try {\n const response = await fetch('/categories');\n return response.json();\n } catch (err) {\n console.log(err);\n }\n}", "title": "" }, { "docid": "bf819d79f7164748f2ac9366c12610fe", "score": "0.6313587", "text": "function getCategory() {\n $.get(\"/api/category\", function (data) {\n //console.log(data[0]);\n var categoryId = data[0].id;\n categoryArray.push(categoryId);\n });\n }", "title": "" }, { "docid": "f14a9430bf5e6d9d55991a13dfd32b5b", "score": "0.6310976", "text": "categories(user) {\n\t\treturn UserModel.getCategories(getDBDriver(), user.id)\n\t\t\t.then(res => res)\n\t\t\t.catch(err => [])\n\t}", "title": "" }, { "docid": "59ef9375769a2ff65059d98a4bc2a2d9", "score": "0.6305354", "text": "function getCategories(callback) {\n mongo.connect();\n var categories = [];\n models.CategoryModel.find(function (err, data) {\n if (err) {\n callback(err);\n console.log(err);\n } else {\n categories = data;\n }\n mongo.close();\n callback(null, categories);\n });\n}", "title": "" }, { "docid": "58d0274c9f25d3052e8c637d0bbe0f62", "score": "0.6302823", "text": "getSubCategories(category) {\n const itemsArray = this.getItemsInCategory(category);\n\n return StashCollection.sortCategories(itemsArray.map((item) => item.category[category]));\n }", "title": "" }, { "docid": "19e6ffea60e89c23b6bba700534c8d8f", "score": "0.6278951", "text": "function returnCategoryNames() {\n var displayedCategoryNames = []\n for (i = 0; i < GLOBAL_DISPLAYED_CATEGORY.length; i++) {\n displayedCategoryNames.push(GLOBAL_DISPLAYED_CATEGORY[i][1])\n }\n return displayedCategoryNames\n\n}", "title": "" }, { "docid": "5c148e38b1bb60d92639183645ce5084", "score": "0.62691283", "text": "getCategories() {\n const responseLoader = Q.defer();\n\n try {\n const categories = JSON.parse(requireRaw(kCategoriesJsonFile));\n\n responseLoader.resolve(categories);\n } catch(err) {\n const errDesc = ExceptionsFactory.buildErrorDescriptor(ExceptionsFactory.CATEGORIES_ERR_DESC_NOTFOUND,\n err.toString());\n responseLoader.reject(errDesc);\n }\n\n return responseLoader.promise;\n }", "title": "" } ]